Version: 0.2
Date: 2026-05-22
Status: First formalization
Depends on: 0.1.md (Internal Literature Review)
Grounded in: Few Become One $\S$V (DOI: 10.5281/zenodo.20328374), Tree Distance Cophenetic $\S$2 (DOI: 10.5281/zenodo.20213043), Q-PNA $\S$2-3 (DOI: 10.5281/zenodo.20287742)
This document provides the formal mathematical definitions for the Nested Semantic Graph (NSG) — a language-neutral representation of meaning as an ultrametric tree of conceptual primitives. The definitions are grounded in three prior works:
- Few Become One $\S$V — the conceptual proposal: "represent text as a tree of nested concepts rather than a flat sequence of tokens" (V.B), with nodes as conceptual primitives and edges encoding scope/modification relationships
-
Tree Distance Cophenetic $\S$2 — the formal proof that cophenetic distance
$d(x,y) = h(\text{lca}(x,y))$ satisfies the ultrametric inequality and implies triadic rigidity - Q-PNA $\S$2-3 — the computational architecture: p-adic valuation encoding maps tokens to leaves of a Bruhat-Tits tree; the ultrametric attention mechanism computes distances without learned parameters
All definitions below are accompanied by Python verification in 0.2.py.
Definition 1 (Conceptual Primitive). A conceptual primitive is an atomic unit of meaning corresponding roughly to the semantic content carried by an individual morpheme, regardless of whether that morpheme is a free-standing word (as in isolating languages) or a bound affix (as in polysynthetic languages).
Definition 2 (Node). A node
Definition 3 (Node Categories). Nodes belong to one of the following semantic categories
| Category | Description | Example Labels |
|---|---|---|
| ENTITY | Participants in an event | dog, man, stick |
| ACTION | The event or process itself | bite, run, give |
| TENSE | Temporal frame | past, present, future |
| ASPECT | Internal temporal structure | completive, progressive, iterative |
| EVIDENTIAL | Source of information | witnessed, reported, inferred |
| LOCATIVE | Spatial reference | here, there, upward |
| MANNER | How the action is performed | quickly, together, repeatedly |
| LOGICAL | Logical relations between propositions | because, if, although |
Definition 4 (Node Set). The set of all nodes in a semantic graph is denoted
Definition 5 (Scope Edge). An ordered pair
Definition 6 (Argument Edge). A special case of scope edge where
Definition 7 (Modifier Edge). A scope edge where
Definition 8 (Root Node). The root of a nested semantic graph is the unique node
Definition 9 (Leaf Node). A node with no incoming edges (i.e., nothing is in its scope).
Definition 10 (Nested Semantic Tree). A nested semantic tree (NST) is a triple
-
$V$ is a finite set of nodes (Definition 2) -
$E \subseteq V \times V$ is a set of directed scope edges (Definition 5) -
$r \in V$ is the unique root node (Definition 8) - The directed graph
$(V, E)$ forms a rooted tree: every node$v \in V \setminus {r}$ has exactly one outgoing edge, and there is a unique directed path from any node to$r$ - For all
$(a, b) \in E$ ,$a$ is in the scope of$b$
Definition 11 (Height Function). A height function on a tree
-
$h(r) = H$ where$H > 0$ is the height of the tree - For any edge
$a \to b$ ,$h(a) < h(b)$ (children are strictly lower than parents) - For leaf nodes
$\ell$ ,$h(\ell) = 0$
Definition 12 (Lowest Common Ancestor). For nodes
- Both
$x$ and$y$ are in the subtree rooted at$z$ (i.e., there are directed paths from$x$ to$z$ and from$y$ to$z$ ) - No proper descendant of
$z$ satisfies condition (1)
Equivalently,
Definition 13 (Ultrametric Distance on an NST). For nodes
That is, the distance between two nodes is the height of their lowest common ancestor — a measure of how far back toward the root one must travel before the two nodes' ancestral paths converge.
Intuition: Two morphemes within the same polysynthetic word-sentence share a shallow LCA (the word-level root), so
Theorem 1 (Ultrametric Inequality). For any three nodes
Proof. (Following Tree Distance Cophenetic $\S$2.) Let
Now
Corollary 1 (Triadic Rigidity). For any three nodes
Proof. This follows directly from the ultrametric inequality and is verified computationally in 0.2.py.
Property 1 (All Triangles Are Isosceles). Let
Property 2 (Balls Are Clopen). For any
Property 3 (Nesting). Two ultrametric balls are either disjoint or one contains the other. Partial overlap is impossible. This is the geometric basis for the Threshold Principle (How Geometry Creates Memory, DOI: 10.5281/zenodo.20061155).
Definition 14 (Scope Depth). For a node
Definition 15 (Conceptual Distance). For two conceptual primitives represented by nodes
Example. In the semantic graph for "dog bit man yesterday":
- Nodes
dog[agent]andman[patient]share LCAbite[action](the event root). Their distance is$h(\text{bite})$ . - Nodes
dog[agent]andyesterday[tense]also share LCAbite[action]. Their distance is the same. - The ultrametric structure captures that both arguments are equally close to the event — there is no "the agent is closer than the patient" in the tree, which reflects the semantic symmetry of participation.
Definition 16 (Tree-Alignment Lattice). Given two nested semantic trees
Definition 17 (Graph Distance). The ultrametric graph distance between two nested semantic trees is:
where
Definition 18 (Sub-Graph Matching). Given a query graph
where the minimum is taken over all valid subtree isomorphisms. A perfect match has
Definition 19 (Ranking). For a query graph
Proposition 1 (Equivalence). The ultrametric distance on a nested semantic tree (Definition 13) is exactly the cophenetic distance defined in Tree Distance Cophenetic $\S$2:
All theorems from Tree Distance Cophenetic apply directly to the NSG formalism.
Proposition 2 (Resolution-Dependence). The height function
Definition 20 (Token Encoding, from Q-PNA $\S$3.2). Each conceptual primitive (node) is mapped to a semantic prime set, then to a prime product, then to a valuation vector:
-
Semantic prime assignment: Node label
$\lambda(n)$ determines semantic primes$p_1, \ldots, p_k$ with strengths$f_i(n)$ -
Prime product:
$P(n) = \prod_{i=1}^{k} p_i^{f_i(n)}$ -
Valuation vector:
$\vec{v}(n) = (v_{p_1}(P(n)), \ldots, v_{p_k}(P(n))) = (f_1(n), \ldots, f_k(n))$
Proposition 3 (Encoding Preserves Ultrametric Structure). The Q-PNA encoding maps the NST into the Bruhat-Tits tree
Proof sketch: This follows from the tree-p-adic correspondence (Ultrametric Cognition, Proposition 2.5). The valuation vector's
Definition 21 (Linearization). For a nested semantic tree
Different languages correspond to different linearizations of the same NST:
| Language | Linearization Rule | Surface Form |
|---|---|---|
| English (SVO) | Agent precedes action, patient follows | "dog bit man yesterday" |
| Mohawk (polysynthetic) | Root verb, prefixes for agent/patient, suffixes for tense/aspect | Wakatonhkariá:ton ("I have finished eating") |
| Turkish (SOV) | Agent, patient, action, tense suffix | "köpek adamı dün ısırdı" |
Theorem 2 (Language Neutrality). For any two languages
Proof. This is the core claim of Few Become One $\S$V.B. The proof requires constructing a semantic parser that maps surface forms in any language to the same NST. For the purposes of this document, we treat this as a design goal and verify it for specific examples in 0.2.py.
All definitions above are computationally verified in 0.2.py. The verification suite tests:
- Tree construction — Nodes, edges, height, root
-
LCA computation — Efficient
$\mathcal{O}(n \log n)$ preprocessing,$\mathcal{O}(1)$ queries - Ultrametric inequality — Exhaustive verification on all triples
- Triadic rigidity — All triangles are isosceles
- Language neutrality — English and Mohawk trees are isomorphic
- Token encoding — Semantic prime assignment and p-adic valuation
- Few Become One: Polysynthetic Communication and the Ultrametric Architecture of Language (2026-05-22). DOI:
10.5281/zenodo.20328374. Section V. - The Tree Distance Cophenetic: A Unified Framework for Hierarchical Ontology (2026-05-15). DOI:
10.5281/zenodo.20213043. Section 2. - Q-PNA: Quantum-Native p-Adic Neural Architecture — Research Specification v2.0 (2026-05-19). DOI:
10.5281/zenodo.20287742. Sections 2-3. - How Geometry Creates Memory (2026-05-06). DOI:
10.5281/zenodo.20061155. - Ultrametric Cognition (2026-04). Archive:
G:\My Drive\Archive\projects\2026\04\Ultrametric Cognition\. Proposition 2.5.
Formal Definitions v0.2 — Grounded in the published ultrametric-language corpus. Python verification in 0.2.py.