{
  "access": "public",
  "type": "reference",
  "format": "markdown",
  "title": "Latent: Navigation Instruments for Concept Space",
  "url": "https://labs.datagrout.ai/papers/latent",
  "summary": "Agents use language models as oracles: pose a question, take the answer. This pattern discards most of what a model contains. Its latent space holds a dense terrain of isomorphisms between distant domains, structural oppositions, and boundaries where one framing gives way to another, but one-shot prompting samples that terrain blindly: without position, without direction, and without memory of where it has been.\n\nThe Latent toolsuite treats concept space as territory to be navigated rather than an oracle to be queried. Four instruments (**expand**, **orient**, **horizon**, and **atlas**) supply the primitives: expansion of a concept into its neighborhood, orientation along a chosen semantic axis at a chosen angle, detection of the horizon where the current framing runs out, and a self-driving loop that composes the first three into a growing, resumable map. Each separates a deterministic navigation frame (axes, angles, addressable identifiers, the boundary classification rule) from the stochastic content it organizes, and an orientation, once computed, can be reloaded and extended without re-spending inference.\n\nNavigation results are structured facts, not transient prose: nodes, typed relations, boundary markers, weighted edges. Orient and horizon persist them into the agent's Logic Cell, where symbolic queries traverse them. The language model draws the map; logic programming reads it.",
  "topics": [
    "latent-space",
    "concept-navigation",
    "divergent-reasoning",
    "neuro-symbolic",
    "prolog"
  ],
  "content_markdown": "## Abstract\n\nAgents use language models as oracles: pose a question, take the answer. This pattern discards most of what a model contains. Its latent space holds a dense terrain of isomorphisms between distant domains, structural oppositions, and boundaries where one framing gives way to another, but one-shot prompting samples that terrain blindly: without position, without direction, and without memory of where it has been.\n\nThe Latent toolsuite treats concept space as territory to be navigated rather than an oracle to be queried. Four instruments (**expand**, **orient**, **horizon**, and **atlas**) supply the primitives: expansion of a concept into its neighborhood, orientation along a chosen semantic axis at a chosen angle, detection of the horizon where the current framing runs out, and a self-driving loop that composes the first three into a growing, resumable map. Each separates a deterministic navigation frame (axes, angles, addressable identifiers, the boundary classification rule) from the stochastic content it organizes, and an orientation, once computed, can be reloaded and extended without re-spending inference.\n\nNavigation results are structured facts, not transient prose: nodes, typed relations, boundary markers, weighted edges. Orient and horizon persist them into the agent's Logic Cell, where symbolic queries traverse them. The language model draws the map; logic programming reads it.\n\n---\n\n## Problem Landscape\n\n### One-Shot Prompting Treats Concept Space as an Oracle\n\nWhen an agent needs conceptual material, the standard move is a brainstorming prompt: \"give me ten ideas related to X.\" The output is a flat list with no structure the agent can act on: no notion of *where* those ideas sit relative to the seed, no distinction between well-established isomorphisms and speculative long-tail connections, and no way to ask for \"the same neighborhood, rotated ninety degrees.\"\n\nThe deeper problem is statelessness. An agent that explored a concept's negation yesterday has no address for that exploration today; it can only re-prompt and hope the sampling lands nearby.\n\n### Exploration Without Position\n\nHuman researchers navigate idea space with an implicit reference frame: this idea is the *opposite* of that one; this field is *adjacent* to that field; this analogy holds *up to a boundary* and breaks beyond it. Agent toolchains have no equivalent. Retrieval ranks by similarity, a single scalar, which collapses exactly the structure that matters: an idea's most useful neighbors are often its structured opposites and orthogonal complements, ranked poorly precisely because they are far away.\n\n### The Retrieval Mismatch\n\nEmbedding search and RAG operate over a *corpus* the user has collected and indexed. They cannot retrieve what the model knows but the corpus does not contain. For cross-domain analogy, reframing, and boundary-finding, the relevant knowledge base is the model's own training distribution, which no external index covers.\n\n### Divergence Needs Discipline\n\nDivergent thinking is how a stuck plan gets reframed, but undisciplined divergence is expensive noise: repeated sampling overlaps, exploration has no completion criterion, and nothing records which directions have been exhausted. Divergence becomes useful when it has coordinates: which axis, at what angle, how far, and where the boundary was found.\n\n---\n\n## Design Principles\n\n### 1. Deterministic Frame, Stochastic Content\n\nThe frame (axis and angle vocabularies, orientation identifiers, boundary classification, coverage analysis) is deterministic and inspectable; the content it organizes is sampled. Two runs of the same orientation may surface different concepts, but they are organized by the same frame, addressed by the same identifier, and classified by the same rules. The frame is what makes exploration cumulative rather than episodic.\n\n### 2. The Horizon Is an Output, Not a Failure\n\nEvery framing runs out somewhere. Traditional expansion treats the edge of relevance as noise to filter; the Latent suite treats it as the most valuable navigational signal. Boundary nodes, concepts that relate to the seed by contrast or orthogonality rather than shared structure, mark where the current frame stops explaining, and each is a candidate departure point for the next orientation.\n\n### 3. Positions Are Addressable and Re-Enterable\n\nAn orientation is identified by a stable hash of its seed, axis, and angle, with their descriptions; levels, passes, and the domain hint are not part of the identifier, so re-orienting at a different fidelity upserts into the same position. Persisted orientations reload by identifier at no inference cost, so a multi-session investigation accumulates a navigable atlas rather than a pile of transcripts.\n\n### 4. Two Passes, Separately Sampled, Jointly Reported\n\nOrientation runs two passes against the same position: a **canonical** pass that samples high-confidence, well-established connections (the reference frame), and an **exploratory** pass that deliberately samples low-probability connections (the long tail). Every node carries its source pass as provenance, so the agent can ground on the canonical frame and mine the exploratory tail for novelty; the two distributions never mix anonymously. A concept both passes reach is one node marked as found by both, with its weight raised, since independent agreement is the cheapest trust signal the instrument has.\n\n### 5. Maps Persist as Symbolic Facts\n\nNavigation output is emitted as typed nodes, weighted relations, and boundary markers: facts suitable for assertion into a Logic Cell. Once asserted, the map is queryable, joinable, and traversable by rules at zero token cost.\n\n---\n\n## The Instruments\n\n![The four instruments as glyphs: expand radiating typed nodes, orient as a compass, horizon as a dashed ring with outward markers, atlas as a graph of orientations with a budget bar](/images/labs/latent_instruments.svg)\n\n*The four instruments: grow a neighborhood, take a bearing, mark where the frame runs out, drive the loop under a budget.*\n\n### latent.expand — Grow a Neighborhood\n\nExpansion takes a seed concept and grows its neighborhood in one of three modes:\n\n- **breadth**: survey the widest set of adjacent concepts across domains\n- **depth**: follow one conceptual thread down through its layers\n- **bridge**: connect the seed to a named target: shared structure, where the analogy carries, where it breaks\n\nEach node carries a label, a domain, a typed relation to the seed (`isomorphic`, `orthogonal`, `hierarchical`, `contrast`, `enables`, `constrains`), and a weight; edges between nodes may also be typed `analogous`. Output formats include a summary graph, a rendered context block for prompt injection, and Prolog facts (nodes, boundaries, edges). Expand returns those facts but does not persist them; only orient and horizon write to the Logic Cell.\n\nAsked to bridge *cartography* and *program comprehension*, it returns the shared structure (representation of complex systems, abstraction and simplification, exploration and orientation), and the contrast node where the analogy fails (physical-spatial versus logical-structural mapping). The breakpoint is reported with the same confidence as the bridge.\n\n### latent.orient — Take a Bearing\n\nOrientation navigates to a specific angular position in a concept's neighborhood, specified by an **axis**, the semantic dimension of movement, and an **angle**, how far to rotate along it:\n\n- Axes: `negation`, `abstraction`, `agency`, `scale`, `formality`, `narrative`, or `custom` (caller-described)\n- Angles: `opposite` (180°), `orthogonal` (90°), `complement`, `45`, or `custom`\n\n\"The negation of context-window compaction, at the opposite pole\" is a different, repeatable position than \"concepts near context-window compaction.\" The instrument runs the two passes in parallel, merges them with per-node provenance, classifies boundary nodes by a deterministic rule over the relation labels the model emitted (the frame decides how to treat a boundary, not whether the model saw one), and returns the frame under a stable `orientation_id`. With persistence enabled, the orientation is written into a Logic Cell namespace as typed facts.\n\n![The orientation frame as a compass: seed at center, the negation axis as a diameter, the opposite angle as a 180 degree arc, filled canonical and hollow exploratory nodes placed by relation-type sector and weight, a dashed horizon ring, and boundary markers with recommended-axis arrows](/images/labs/latent_frame.svg)\n\n*One orientation frame: the frame fixes axis, angle, sectors, and horizon; the two passes populate it; each boundary marker carries the departure axis the horizon instrument recommends for it.*\n\n### latent.horizon — Map the Edge\n\nHorizon-finding answers the question the other instruments raise: *where does this framing run out?* Given a seed or a persisted `orientation_id`, the instrument identifies the boundary of the neighborhood and enriches each boundary marker with a **recommended next move**: which axis and angle to orient along to continue past that edge. The recommendation follows a fixed table from the boundary's relation type (a contrast boundary departs along negation at the opposite pole, a hierarchical one along abstraction), and an orthogonal boundary chooses its axis from the marker's domain rather than from the relation alone. An identifier is replayed from the Logic Cell without new inference when its facts are present at the requested level; when they are missing, the horizon falls back to a fresh pass and the receipt records that the frame was regenerated rather than replayed, with relation loads bounded either way.\n\nTwo further capabilities make the horizon actionable:\n\n- **expand_beyond**: take the top-weighted boundary nodes and expand past them, bounded by an explicit limit, turning the edge of one neighborhood into the interior of the next\n- **coverage gap analysis**: a deterministic report of the relation types underrepresented and the domains absent so far; the atlas loop reads this report to choose its departures\n\n```mermaid\nflowchart TB\n  seed[\"seed concept<br/>axis and angle\"] --> orient[\"latent.orient\"]\n  orient --> canon[\"canonical pass<br/>reference frame\"]\n  orient --> explo[\"exploratory pass<br/>long tail\"]\n  canon --> frame[\"orientation frame<br/>stable orientation_id<br/>typed, weighted nodes\"]\n  explo --> frame\n  frame --> horizon[\"latent.horizon\"]\n  horizon --> markers[\"boundary markers<br/>each with a recommended axis\"]\n  horizon --> gaps[\"coverage gaps<br/>ready-to-run parameters\"]\n  markers -- \"expand_beyond\" --> beyond[\"interior of the<br/>next neighborhood\"]\n  gaps -- \"next departure, driven by atlas\" --> orient\n```\n\n*The navigation loop: the two sampled passes feed one deterministic frame, the horizon reads that frame's edges, and each recommended departure becomes the next orientation.*\n\n### latent.atlas — Drive the Loop\n\nThe three primitives imply a loop; `atlas` runs it. Given a seed, it orients, finds the horizon, selects a coverage gap from the recommended departures, orients again, and repeats, accumulating a persistent, queryable map. Three properties keep the loop bounded:\n\n- **Budgeted.** `max_orientations` caps the fresh inference a single call may spend. At the budget, the loop stops and returns its untraveled **frontier**, the unexplored recommendations, as the resume point.\n- **Idempotent.** Orientation identifiers are deterministic, so a candidate whose identifier is already persisted is replayed rather than re-expanded, at zero inference cost. Re-calling atlas with the same seed resumes the frontier instead of starting over. The check is on the identifier, not on the facts behind it, so a position persisted with an empty frame is treated as explored today; distinguishing the two is queued work.\n- **Self-terminating.** When no unexplored departures remain, the loop reports the frontier as *dry* rather than churning.\n\nAn atlas call returns the orientations it traversed (each with axis, angle, facts written, and inference cost), the frontier it left behind, and whether that frontier ran dry.\n\n![The atlas as a map: the seed orientation with departure arrows to three explored orientations, one replayed at zero credits, dashed arrows to three frontier orientations drawn as dashed circles, and a budget bar](/images/labs/latent_atlas.svg)\n\n*An atlas call with a budget of three fresh orientations: the seed and two departures spend it, a third departure is replayed free because it was already persisted, and the untraveled frontier is returned as the resume point.*\n\n---\n\n## Worked Example: Navigating \"Context Window Compaction\"\n\nAn agent investigating memory architecture orients on *context window compaction* along the negation axis at the opposite angle.\n\nThe canonical pass returns the reference frame: memory expansion (cognitive psychology, isomorphic, 0.95), verbose encoding (data storage, contrast, 0.92), panoramic montage (visual arts, isomorphic, 0.85), extensive legal discovery (law, contrast, 0.78), distributed-systems consensus (orthogonal, 0.74), with boundary markers at quantum decoherence and non-local communication, the edges \"where context window concepts lose local meaning.\" The exploratory pass adds the long tail: permissive forgetting, data bloat, bureaucratic proliferation, hypertextual overload, maximalist collage.\n\nThe agent then requests the horizon for the same orientation, replayed by identifier at no new inference cost, and receives eight boundary markers, each with a recommended departure: *entropy in thermodynamics* (contrast; orient along negation), *fractal boundaries* (orthogonal; orient along abstraction), *palimpsest rewriting*, *holographic storage*, *social crowd memory*.\n\n![The horizon and a departure: the compaction frame as a dashed ring with three boundary markers and their recommended axes, an expand_beyond arrow from fractal boundaries into a fainter second frame, and a coverage gap report beneath](/images/labs/latent_horizon.svg)\n\n*The horizon of the worked example: each marker names where the frame breaks and which axis to turn along; expand_beyond carries one into the next neighborhood.*\n\nEvery node's relation to the seed is typed and weighted, so \"opposite of compaction\" is a place, not a vibe; the orientation persists under its identifier, so tomorrow's session continues from it; and the boundary markers are the deliverable, not a filtered-out residue.\n\n---\n\n## Maps as Facts: The Symbolic Half\n\nEvery instrument can emit its results as structured facts, and orient and horizon persist them into a Logic Cell namespace: node entities with domain and weight attributes, typed relations connecting nodes to the seed and to each other, boundary markers, and a session entity recording the orientation's parameters and provenance. A single node from the orientation above persists as:\n\n```prolog\n% one node of one orientation: the entity is scoped to the orientation,\n% so the same concept found from two positions is two nodes, not one\nentity(\"onode_a3f2c9_5a4c8f1e2b90\").\nattribute(\"onode_a3f2c9_5a4c8f1e2b90\", label, \"memory expansion\").\nattribute(\"onode_a3f2c9_5a4c8f1e2b90\", domain, \"cognitive psychology\").\nattribute(\"onode_a3f2c9_5a4c8f1e2b90\", relation_type, isomorphic).\nattribute(\"onode_a3f2c9_5a4c8f1e2b90\", source_pass, both).\nattribute(\"onode_a3f2c9_5a4c8f1e2b90\", orientation_id, \"a3f2c9…\").\nmetric(\"onode_a3f2c9_5a4c8f1e2b90\", weight, 1.0).\nrelation(\"context window compaction\", orientation_result, \"onode_a3f2c9_5a4c8f1e2b90\").\nrelation(\"orient_session_a3f2c9\", has_node, \"onode_a3f2c9_5a4c8f1e2b90\").\n\n% the atlas records where each orientation came from\nrelation(\"orient_session_a3f2c9\", departs_to, \"orient_session_b71e04\").\nattribute(\"orient_session_b71e04\", via_marker, \"entropy in thermodynamics\").\n```\n\nA node's identity is the pair of orientation and label, hashed into the entity name, with the label kept as an attribute. This is what makes cross-orientation questions answerable: the same concept reached from two positions is two nodes carrying their own relation type and weight, and a rule that asks which labels recur across orientations joins on the `label` attribute rather than colliding on it. A node found by both sampling passes carries `source_pass` of `both` and a small weight bonus, so agreement between the passes is visible in the map. A boundary node persists identically but under an `orientation_boundary` relation, so a rule can select the horizon of any orientation by matching a single functor. The orientation itself is an `orient_session` entity carrying the seed, axis, angle, and identifier, and the atlas links sessions with `departs_to` and records the boundary marker each departure went through, so the map is a graph of positions, not a set. That adjacency is the same shape the memory layer's persisted partitions use for cells (*Attention Cloud: Memory as a Rendering Problem*), one vocabulary for two territories.\n\n```mermaid\nflowchart TB\n  orient[\"latent.orient<br/>persist enabled\"] --> oid[\"orientation_id<br/>stable hash of seed, axis, angle\"]\n  orient --> nodes[\"node facts, one entity per orientation and label<br/>orientation_result or orientation_boundary<br/>label, domain, relation_type, source_pass, weight\"]\n  oid --> session[\"orient_session entity<br/>seed, axis, angle, identifier\"]\n  session --> cell[\"Logic Cell namespace<br/>upserted typed facts\"]\n  nodes --> cell\n  cell -- \"reload by orientation_id, no inference\" --> horizon[\"latent.horizon<br/>replays the frame\"]\n  horizon -- \"persists boundary markers\" --> cell\n  cell -- \"scan persisted identifiers\" --> atlas[\"latent.atlas<br/>skips explored positions\"]\n  cell -- \"logic.query\" --> rules[\"Prolog rules<br/>cross-orientation joins\"]\n```\n\n*How a position becomes re-enterable: the orientation writes a session entity and node facts into a namespace, and three readers consume them by identifier without touching the model.*\n\nA rule can traverse edges transitively, join nodes against facts from other sources (code structure, business data, prior investigations), and answer questions no single expansion answers: *which concepts appear in the boundary sets of more than one orientation? Which domains recur across every axis explored? What connects the negation frame of concept A to the abstraction frame of concept B?*\n\nThe division of labor mirrors *Forensic Inference: Structured Agent Reasoning Over Accumulated Facts*: the language model observes (here, its own latent terrain) and logic performs the exhaustive, deterministic reasoning over what was observed. A rule can also request more map mid-inference: the Logic Cell's tool-callout primitive lets a proof that runs out of asserted facts invoke a further expansion and continue with the result bound.\n\n---\n\n## Economics\n\nLatent calls are inference-priced: the measured token cost of each generation pass, surfaced per call. Representative production costs: a two-pass orientation at moderate depth runs mid-single-digit credits; a horizon pass slightly less; a bridge expansion less still. Three properties keep exploration bounded:\n\n- **Replay is free.** Reloading a persisted orientation by identifier costs no inference; only new terrain costs tokens, and a frame whose facts are missing at the requested level counts as new terrain (it is regenerated, and the receipt says so).\n- **Depth is a dial.** In orient, horizon, and expand's breadth and depth modes, level 1 uses a lighter model with a smaller output budget and higher levels escalate model and budget; bridge uses the full model at every level, and only its output budget scales.\n- **Symbolic traversal is free.** Once the map is facts, querying it, including cross-orientation joins, costs nothing.\n\nThe baseline, repeated brainstorming, re-pays full inference on every attempt and terminates only when the caller gives up; navigation converts the same spend into a durable, addressable artifact.\n\n---\n\n## Comparison with Existing Approaches\n\n| Approach | Operates over | Structure of results | Cumulative? | Boundary awareness |\n|---|---|---|---|---|\n| Embedding / RAG retrieval | User's corpus | Similarity-ranked chunks | Index persists; exploration does not | None |\n| Brainstorming prompts | Model's knowledge | Flat prose lists | No | None |\n| Knowledge graphs | Hand-curated triples | Typed edges | Yes | Only what was authored |\n| Latent navigation | Model's knowledge | Typed, weighted, provenance-tagged frames | Yes: addressable orientations, persisted facts | First-class output |\n\nKnowledge graphs are the closest structural relative, but they contain only what someone authored. Latent navigation generates graph-shaped structure on demand from the model's training distribution, then persists the slices worth keeping: a knowledge-graph *writer* whose author is the model and whose editor is the navigation frame.\n\n---\n\n## Limitations and Trade-Offs\n\n**Content is sampled.** The frame is deterministic; the concepts populating it are not. Applications requiring reproducible content should persist and replay rather than regenerate.\n\n**Weights are asserted, not measured.** Node weights express the model's confidence in a connection, not an empirical measurement of it. They order exploration well; they are not probabilities.\n\n**Nodes are ungrounded.** An expansion can surface a plausible connection that is factually wrong. Where downstream reasoning depends on a node's truth, the platform's grounding machinery, which verifies claims against asserted facts before they propagate, is the recommended pairing.\n\n**Not a substitute for retrieval.** When the answer lives in the user's data, retrieval over that data is the right tool. Latent navigation covers the complementary case: when the answer lives in the model.\n\n---\n\n## Future Directions\n\n### Program-Space Duals\n\nThe navigation grammar of orienting, finding the horizon, and expanding across it is not specific to concept space. Codebases lensed into structural facts present the same needs: orient within a module's neighborhood, find the boundary of a subsystem, bridge between an entry point and a data store. A forthcoming line of work applies the same instrument pattern to program space, where the underlying map is extracted deterministically rather than sampled.\n\n### Grounded Expansion\n\nExpansion nodes could be checked against the agent's fact base at generation time, tagging each as corroborated, contradicted, or novel relative to what the agent already knows: a diff against existing knowledge rather than an undifferentiated stream.\n\n### Orientation as Memory\n\nPersisted orientations are already durable facts; integrating them with the platform's memory retrieval would let past explorations surface associatively during new work: an agent beginning a design task finds, alongside its factual recall, the map of the last time it explored this territory.\n\n---\n\n*This document describes the conceptual architecture of the Latent navigation toolsuite. Prompt construction, pass orchestration, boundary-classification rules, and cost-routing internals are part of the operational implementation and are not specified here.*\n",
  "last_updated": "2026-07-01T00:00:00Z"
}