Skip to content

feat(loops): planner-declared edge lineage — TopologyMove.parentIndex (#82)#85

Merged
tangletools merged 2 commits into
mainfrom
feat/planner-declared-lineage
May 31, 2026
Merged

feat(loops): planner-declared edge lineage — TopologyMove.parentIndex (#82)#85
tangletools merged 2 commits into
mainfrom
feat/planner-declared-lineage

Conversation

@tangletools
Copy link
Copy Markdown
Contributor

Closes #82. Adds an optional parentIndex to refine/fanout TopologyMoves; describePlan surfaces it; the kernel prefers a declared parent over the inferred branchPoint. Nothing emits a non-trivial value yet (no revisit/goto move ships) so refine/fanout behavior is unchanged — but lineage is faithful the moment such a move exists. Test proves a declared parentIndex=0 overrides the inferred best-valid branch point. Shipped 0.40.0.

drewstone added 2 commits May 31, 2026 03:58
…#82)

Closes #82. The kernel-inferred parentIndex is exact for every topology the
current move vocabulary (refine/fanout/stop) can produce, but a future
revisit/goto move (or any planner branching off a non-winner) needs the planner
to DECLARE the branch source. The hook is now in place, additively:

- TopologyMove refine/fanout gain optional `parentIndex` (the iteration this
  round branches from).
- LoopPlanDescription gains `parentIndex`; createDynamicDriver.describePlan
  surfaces the pending move's value.
- run-loop prefers a declared parentIndex over the inferred branchPoint:
  `planDesc?.parentIndex ?? (round 0 ? root : branchPoint(...))`.

Nothing emits a non-trivial parentIndex yet (no revisit/goto move ships), so
behavior is unchanged for refine/fanout — but the lineage is now faithful the
moment such a move exists. Test: a declared parentIndex=0 overrides the inferred
best-valid branch point. Full suite green, tsc + biome clean.
@tangletools tangletools merged commit 7df13c0 into main May 31, 2026
1 check failed
@tangletools tangletools deleted the feat/planner-declared-lineage branch May 31, 2026 09:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat(loops): let drivers declare topology edges (planner-declared parentIndex)

2 participants