Skip to content

feat(replan): deliver core Goal and dense typed decision evidence - #5536

Open
huangruiteng wants to merge 3 commits into
mainfrom
codex/replan-evidence-context
Open

huangruiteng wants to merge 3 commits into
mainfrom
codex/replan-evidence-context

Conversation

@huangruiteng

@huangruiteng huangruiteng commented Oct 3, 2026 •

Copy link
Copy Markdown
Collaborator

Replan could require an agent to discover a separate evidence command and guess its JSON fields, while the delivered context kept only a small recent coverage window. The current obligation now carries the core Goal, scoped acceptance, and dense decision evidence through the existing TypeScript work-item owner.

  • Retire evidence-log without an alias; keep historical receipt decoding and internal supervisor/recovery readers. Exact optional reads use bound history --goal-id ... --agent-id ... --evidence-ref ... actions and fail on stale or wrong-scope references.
  • Reduce repeated observations before selecting up to 24 distinct results/routes from the complete compact index. Show omitted coverage explicitly; novelty admission still checks complete available history. Read receipts and unchanged/prose-only claims gain no settlement authority.
  • Preserve stable obligation assignment and receipt-bound Agent identity through settlement. Full review packets carry structured context; handoff forwarding avoids duplicating it.

This intentionally changes the CLI and replan projection defaults. It adds no provider, setting, frontend screen, Lark operation, or write authority. The existing quota/review-packet journey owns delivery; the Python codec only adapts existing Goal/history sources and the private snapshot transport. Durable legacy receipts remain readable, with faithful old-format negative fixtures rather than invented command placeholders.

Validation: focused Python run 321 passed, 2 failed; both failures in test_replan_successor_durable_ack.py (file/SQLite periodic successor closeout) reproduce on untouched b21929c4f16c13530aa270a4bfbf082ed8d925dc. Subsequent affected receipt/blocker tests, real CLI reference/retirement checks, quota/review/handoff smokes, 44 TypeScript tests, control-plane typecheck, Ruff, semantic vocabulary and registry-I/O checks passed. Base/head CLI differential passed with the intentional migration signals. Rebased onto e55489c7791f326abe63e7b9b2952a134d652cf7; the incoming Lark change has no overlapping files.

The same crowded required-replan fixture grows 26,844 → 33,523 characters; ordinary quota fixtures are unchanged and handoff-only output shrinks. The documented budget increase is restricted to decision context, not a general guard allowance. These measurements do not prove token savings or long-horizon score gains. This is a reviewable S3/S6 increment; controlled long-horizon quality/cost qualification remains S11 work. No benchmark or live-model jobs were launched.

The production frontend bundle built and passed source-provenance verification. The isolated real installer smoke passed installed CLI help, generated/compressed manpage readback and command-catalog retirement. Post-integration registry-I/O, semantic checks and 16 real CLI/reentry cases passed. Final CI is pending; this runtime/control-plane PR is left for maintainer review and merge.

Signed-off-by: huangruiteng <huangrt01@163.com>
Signed-off-by: huangruiteng <huangrt01@163.com>
Signed-off-by: huangruiteng <huangrt01@163.com>
@mergify

mergify Bot commented Oct 3, 2026

Copy link
Copy Markdown

This pull request has merge conflicts with main and cannot be merged
until they are resolved. Please rebase or merge the base branch, @huangruiteng.

Choose the remote for the base repository, not an out-of-date fork.
For a fork clone, first inspect git remote -v; upstream must point
to https://github.com/loopx-project/loopx.git. If it is absent, add it
with git remote add upstream https://github.com/loopx-project/loopx.git.
Then run:

git fetch upstream
git rebase upstream/main
# Resolve each conflict, git add the resolved files, then git rebase --continue.
git push --force-with-lease origin HEAD

For a same-repository clone whose origin points to
https://github.com/loopx-project/loopx.git, use origin instead of
upstream for fetch/rebase. If you prefer merging the base, use
git merge <base-remote>/main and push normally.

Keep the DCO Signed-off-by trailer on every commit when you rebase.
https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/working-with-forks/syncing-a-fork

@mergify mergify Bot added the needs-rebase Mergify: the pull request has merge conflicts with its base branch label Oct 3, 2026

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

needs-rebase Mergify: the pull request has merge conflicts with its base branch

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant