Back to all concepts

Lacunar Code

Brief

Lacunar Code is a computation paradigm where systems are defined by intentional absence (lacunae) inside a semantic graph, rather than complete instruction sets. Execution is the emergent resolution or traversal of incomplete structure, mediated by constraint satisfaction, resonance, and AI-driven inference rather than deterministic control flow.

WHY THIS MATTERS

  • Traditional software assumes completeness first, execution second; Lacunar Code inverts this: incompleteness is the operating condition.
  • It reframes bugs, TODOs, and missing logic as first-class structural signals, not failures.
  • It aligns computation with modern AI systems that already operate in partial specification + probabilistic completion regimes.
  • It enables a shift from:
  • writing procedures → shaping possibility fields
  • debugging logic → curating incompleteness
  • It suggests a new software class: systems that are stable precisely because they are incomplete but structurally constrained.

Deep synthesis

Operating Logic

Lacunar Code systems operate as partial semantic graphs:

  1. Specification phase (intent deposition)
  • Developers define:
  • intent nodes
  • partial transformations
  • constraints
  • Missing logic is explicitly declared as lacuna.
  1. Graph formation
  • Code is represented as a directed constraint graph
  • Nodes may be:
  • fully specified
  • partially specified
  • completely absent (lacuna nodes)
  1. Execution as traversal
  • “Running” the system means:
  • traversing graph paths
  • selecting valid constraint-satisfying routes
  • activating minimal subgraphs
  1. AI-mediated completion
  • AI acts as:
  • gap resolver
  • topology completer
  • resonance matcher
  • It proposes:
  • missing nodes
  • missing edges
  • viable execution paths
  1. Semantic settling
  • System behavior emerges when:
  • constraint satisfaction converges
  • attractor states stabilize
  • Execution is thus a relaxation process in a structured field

Key inversion:

Code does not run. The graph settles.

Pattern Language

Choice: Represent missing logic as structured objects, not nulls.

Missing function execution.

Boundary Conditions

Key boundaries include Risks and Failure Modes.

Patterns

1. Explicit Lacuna Modeling

  • Choice: Represent missing logic as structured objects, not nulls
  • Why it matters: Prevents hidden assumptions and silent failures
  • What to do:
  • Lacuna { intent, constraints, state, confidence }
  • store unresolved nodes in graph
  • What to avoid:
  • null/undefined fallbacks
  • implicit TODO comments as “meaning”

2. Graph as Execution Medium

  • Choice: Replace call stacks with traversal
  • Why it matters: Enables global reasoning and emergent execution
  • What to do:
  • execute via path selection in graph
  • allow multiple valid execution trajectories
  • What to avoid:
  • linear control flow as core model
  • hidden branching inside nodes

3. Separation of Structure and Resolution

  • Choice: Distinguish intent graph from completed graph
  • Why it matters: Preserves incompleteness safely
  • What to do:
  • immutable “intent graph”
  • overlay “resolved execution graph”
  • What to avoid:
  • overwriting original intent during AI completion

4. Resonance-Based Matching

  • Choice: Use embeddings / structural similarity instead of exact matches
  • Why it matters: Enables cross-domain synthesis and flexible completion
  • What to do:
  • hybrid search: graph constraints + vector similarity
  • rank completion candidates by structural fit
  • What to avoid:
  • pure keyword or schema matching

5. AI as Structural Resolver (not generator)

  • Choice: AI fills gaps rather than writing full programs
  • Why it matters: Maintains graph coherence and prevents uncontrolled generation
  • What to do:
  • propose minimal completion sets
  • reject incoherent expansions
  • What to avoid:
  • free-form code generation detached from graph state

6. Execution Gating via Coherence

  • Choice: Require full-path validity before activation
  • Why it matters: Prevents partial or unsafe execution
  • What to do:
  • validate end-to-end constraint satisfaction
  • What to avoid:
  • speculative execution from incomplete paths

7. Persistence of Incompleteness

  • Choice: Allow unresolved lacunae to remain active artifacts
  • Why it matters: Incompleteness is a system signal, not waste
  • What to do:
  • log inactive lacuna states with reasons
  • What to avoid:
  • garbage collection of “unimplemented” structure

EXAMPLES AND SCENARIOS

  • Missing function execution
  • A node exists with intent + constraints, but no implementation
  • AI resolves it into a compatible transformation at runtime
  • Graph traversal instead of API calls
  • Request = pathfinding problem across semantic nodes
  • Partial system that still runs
  • System executes via fallback routes through lacuna nodes
  • Intent → completion pipeline
  • “Make this true” expands into graph traversal + minimal diff resolution
  • Self-expanding graph
  • Missing edges spawn candidate nodes based on structural similarity
  • Execution as equilibrium
  • System behaves like a field settling into a stable configuration

Primitives

Structural Primitives

  • Node (Partial Transform): A computation unit that may be incomplete or undefined internally.
  • Edge (Intent Link): A constraint or transformation relation, not a strict call dependency.
  • Graph / Semantic Field: The primary substrate where computation lives.
  • Lacuna: Explicitly represented absence (missing node, edge, or transformation).

Semantic Primitives

  • Intent Node (::intent): Attractor defining “what should be true.”
  • Attractor State: Stable configuration satisfying constraints.
  • Constraint Field: Rules that govern which completions are valid.
  • Semantic Completion Path: A valid traversal that resolves or bypasses lacunae.

Inference Primitives

  • Resolution Operator: AI/runtime mechanism that fills or routes around lacunae.
  • Semantic Similarity / Resonance: Matching mechanism replacing exact symbolic binding.
  • MVP Path (Minimum Viable Path): Smallest coherent traversal through incomplete structure.

HOW THE CONCEPT WORKS

Lacunar Code systems operate as partial semantic graphs:

  1. Specification phase (intent deposition)
  • Developers define:
  • intent nodes
  • partial transformations
  • constraints
  • Missing logic is explicitly declared as lacuna.
  1. Graph formation
  • Code is represented as a directed constraint graph
  • Nodes may be:
  • fully specified
  • partially specified
  • completely absent (lacuna nodes)
  1. Execution as traversal
  • “Running” the system means:
  • traversing graph paths
  • selecting valid constraint-satisfying routes
  • activating minimal subgraphs
  1. AI-mediated completion
  • AI acts as:
  • gap resolver
  • topology completer
  • resonance matcher
  • It proposes:
  • missing nodes
  • missing edges
  • viable execution paths
  1. Semantic settling
  • System behavior emerges when:
  • constraint satisfaction converges
  • attractor states stabilize
  • Execution is thus a relaxation process in a structured field

Key inversion:

Code does not run. The graph settles.

Product and business

  • Lacuna-native IDE
  • Code editor where missing logic is visual, indexable, and AI-completable
  • Graph execution runtime
  • Replace microservices orchestration with traversal engine
  • AI gap compiler
  • Converts partial specs into runnable systems
  • Intent-first backend framework
  • APIs defined as attractors + constraints, not endpoints
  • Self-healing software systems
  • Production systems that evolve by filling lacunae dynamically
  • Knowledge graph computation engines
  • “Codebase as evolving semantic ecosystem”

Research directions

  • Formal semantics of absence-as-computation
  • Type systems for structured voids (lacuna types)
  • Graph-native execution engines vs call-stack models
  • AI-driven semantic completion compilers
  • Constraint-field computation and attractor dynamics
  • Hybrid symbolic + embedding execution systems
  • Probabilistic traversal as program semantics
  • Minimal-diff graph transformation systems
  • Emergent computation vs explicit orchestration
  • Temporal semantics of deferred execution (“kairos time” models)

Risks and contradictions

Risks

  • Over-generation risk
  • AI may fill lacunae incorrectly, hallucinating structure
  • Semantic drift
  • Intent graph may diverge from original meaning during completion
  • Underdeterminism
  • Too many lacunae → system cannot stabilize
  • Non-falsifiability
  • “Anything can be completed” can collapse rigor

Failure Modes

  • Lacuna explosion (everything becomes a gap)
  • Infinite inference loops in completion phase
  • Over-resonant matching (false structural analogies)
  • Execution deadlocks due to unresolved constraints

Open Questions

  • What formal guarantees define a “valid completion”?
  • How is safety enforced in a partially specified system?
  • When should lacunae not be filled?
  • Can resonance-based execution be made deterministic enough for production systems?

Worldbuilding

  • Cities that “run programs” by resolving architectural gaps
  • AI systems that refuse execution until semantic coherence emerges
  • Living software ecosystems where missing functions are biological growth sites
  • Programming as a form of ecological gardening of incomplete systems
  • Debugging as “cultivating lacunae until they stabilize”
  • Software that “dreams” missing modules into existence via resonance fields

EXAMPLES AND SCENARIOS

  • Missing function execution
  • A node exists with intent + constraints, but no implementation
  • AI resolves it into a compatible transformation at runtime
  • Graph traversal instead of API calls
  • Request = pathfinding problem across semantic nodes
  • Partial system that still runs
  • System executes via fallback routes through lacuna nodes
  • Intent → completion pipeline
  • “Make this true” expands into graph traversal + minimal diff resolution
  • Self-expanding graph
  • Missing edges spawn candidate nodes based on structural similarity
  • Execution as equilibrium
  • System behaves like a field settling into a stable configuration