Recursion: how a run closes its gaps

The state a run carries before Routing — the request, its open gaps, grounded connections, assumptions, contradictions, confidence, sources, who can answer, fixed decisions and budget — how each stage adds one finding to it, the seven stop rules, the two re-entries, and why every stage still answers in its own form.

Status: design, 2026-10-07. Every stage below already produces its part of the state; the shared record, the stop rules checked between stages and the two re-entries are the work in progress.

An answer given in one pass hides what it assumed. Recursion (recursive self-improvement, RSI) makes the unknowns the work: each step closes one named gap, records how the finding connects to what the Space already holds, and rewrites the request with one more "given that …" clause. The next step starts from the richer request, not from zero. The run stops when a rule says so, never when it feels done.

R(n) = R(n-1) + the nth finding

The state a run carries

The record R has these fields. The first eleven describe any question; the rest are specific to the stages that run before Routing.

Three more ride inside the fields above: the source frontier (sources named but not yet read, inside s), what the Space already holds as an answer (inside c), and deviations between what a company says and what its site shows (inside k).

One step

  1. Pick one gap from e: the one whose answer changes the answer most; the cheapest check breaks ties. One gap. A step that closes two has hidden a connection.
  2. Touch a source; s grows. A guess is not a source and goes to a.
  3. Record the finding as connections in c with a confidence. If it contradicts an existing connection, the pair goes to k.
  4. Append one "given that …" clause to q. If the finding licenses none, the step changed nothing.
  5. Re-derive e: close the gap, add the gaps the finding opened, tag each as in the Space, not in the Space, needs a person, or belongs to a sibling request.
  6. Check the stop rules.

Fixed decisions are never reopened. A gap that belongs to a sibling request is recorded and not descended. A gap no source in the Space can close becomes a question to the person who can.

Stop rules

The first that holds ends the recursion; the reason is recorded.

The stages before Routing are the steps

Read as a recursion, the stages that run before Routing are one R walked once; each stage is the nth finding.

Two re-entries make the walk a recursion rather than a line, each allowed once:

  • Company Consistency reopens Clarification. A contradiction between two sources cannot be resolved by a model. Each unresolved one becomes a question to the person who can settle it; the answer either resolves it (a supersedes connection with a date) or leaves it as a condition.
  • Problem State reopens Decompose. Entities the model found but the decomposition missed are label gaps. One more pass labels them or, if nothing changes, that is the fixed point and the names become conditions.

The rest stays forward. Inference's low-confidence connections are not sent back as questions; they ride on as assumptions and are recorded when an interface commits.

Clarification on its own

Clarification already runs the recursion in miniature, one step per turn. Its questions are gaps routed to you; your answer is the finding, recorded as an assumption with higher confidence than a model's; a question you skip stays open and becomes a condition on the answer. The question budget is b. "Enough" is stop rule 1 or 4; every question skipped is rule 2; the budget is rule 7. What the pause looks like from your side is on Pausing and answering.

What changes under recursion: questions are ordered by how much the answer would change, the decision records which stop rule ended it and the conditions it leaves, and the expanded request is written out so Routing reads the clauses, not only the title.

What the run returns

Chain Summary prints the recursion's output: the expanded request with its clauses, the answer, the conditions it holds under, the stop reason, and what the Space now holds. Conditions are written against the same condition graph as observations, so the next request in the Space starts from what this one established rather than from zero.

Every stage still answers in its own form

Each stage has a fixed contract: the keys it emits, the schema its prompt receives, and the parser that reads its answer. Recursion changes none of them. The state arrives at a stage as one more input section, after the stage's own inputs, so the cacheable head of the prompt and the schema are untouched; a stage that does not use it ignores it. After the stage's own parser has produced the stage's own answer, a reducer in code reads the finding out of that answer and merges it into R, by id, so a re-entry keeps history while the stage output stays a plain decision. The request itself stays your words; the clauses travel in the state and in the orientation Routing already reads. A fixed point is judged on the reducer's delta, never on the wording.