Skip to content

Fix goal lifecycle changes during live execution - #65

Merged
Brian Krabach (bkrabach) merged 1 commit into
mainfrom
fix/live-goal-lifecycle
Sep 28, 2026
Merged

Brian Krabach (bkrabach) merged 1 commit into
mainfrom
fix/live-goal-lifecycle

Conversation

@bkrabach

Copy link
Copy Markdown
Collaborator

A host can create or revise a goal while a conversation turn is already running. The streaming loop previously initialized bookkeeping only at execute entry; a later goal could crash on missing progress_evidence after the answer and evaluator had succeeded. It could also apply a stale evaluator result to a replacement goal.

Normalize goals when consumed, defer completion when a goal appears mid-turn, and verify goal identity/revision after evaluator, judge, and summary awaits. A changed goal ends the current evaluation and preserves its successor for the next explicit execution. Cancellation and pause stop continuation without replaying work. Original four-field goals remain supported; no app-cli dependency is added.

Validation: 436 passed, 3 skipped in the full streaming suite, including 31 new lifecycle cases. The skips require the optional context-simple module, absent locally. Also passed 8 companion Unified RuntimeControls + real loop-live integration cases for Work and Anchors overlay plans using synthetic providers. git diff --check passed.

Scope review: loop-live inherits this engine; current loop-basic and loop-events have no shared goal-state implementation and are unchanged. This PR does not modify saved sessions or claim installed-host adoption.

@bkrabach
Brian Krabach (bkrabach) merged commit dd91649 into main Sep 28, 2026
5 checks passed
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.

1 participant