Replay assistant tool calls as native tool messages, pair missing results, compact oversized arguments, and drop forged call text from history.
Correct a false deliverable claim twice, then append a notice instead of accepting it. base.deliverables is now v5.
Test plan
go test ./internal/ctxasm/ ./internal/runtime/ ./internal/prompts/
go test ./... in Agent-System-Backend
Dev worktree make test (boundaries, core, backend, frontend, ui, agent-command)
## Summary
- Replay assistant tool calls as native tool messages, pair missing results, compact oversized arguments, and drop forged call text from history.
- Correct a false deliverable claim twice, then append a notice instead of accepting it. base.deliverables is now v5.
## Test plan
- [x] go test ./internal/ctxasm/ ./internal/runtime/ ./internal/prompts/
- [x] go test ./... in Agent-System-Backend
- [x] Dev worktree make test (boundaries, core, backend, frontend, ui, agent-command)
Why: Flattened "[调用工具 …]" history taught the model to imitate calls and invent artifact ids. A single regex correction then accepted the second false claim.
Evidence: ctxasm replay tests cover native tool messages, missing-result pairing, argument compaction, demoted text, and forged-marker stripping. Runtime tests cover forged markers, extension-less claims, two corrections, and the fallback notice.
Impact: Assistant history sent to the model no longer contains flattened tool calls. The direct runner corrects a false deliverable twice, then appends a notice instead of accepting the claim. The squad entry still fails closed on the same predicate. base.deliverables is now v5.
Refs: feature/agent-harness-p0
Co-authored-by: Cursor <cursoragent@cursor.com>
weichen
merged commit f007c95a03 into main2026-10-01 12:43:27 +00:00
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Summary
Test plan