pi-mono/packages/coding-agent/src
Armin Ronacher aef5fc429b
fix(coding-agent): keep prompt and tool state across context handlers (#9846)
Since 0.86 the prompt and tool declarations live in transcript system
messages, so a context handler that filters or slices messages could drop
them. After extension-driven compaction this sent requests without built-in
tools and made Codex emit raw tool-call text.

context handlers now see the conversation only. An unchanged list keeps the
transcript as is; a changed list gets the replayed prompt sections and tool
declarations as one leading system message. Handler-added system messages
are kept after it.

Add context_with_system, which runs after every context handler on the full
transcript and sends its result verbatim, for extensions that need to edit
system messages per request. Dropping the leading system message is reported
as an extension error.

closes #9789, closes #9822
2026-09-21 17:14:22 +02:00
..
bun fix(coding-agent): keep remote harness dependencies development-only 2026-09-05 12:45:04 +02:00
cli feat(ai,coding-agent): add image input limits (closes #9631) 2026-09-20 22:59:16 +02:00
client fix(coding-agent): restore client compatibility entrypoint 2026-08-28 13:31:05 +02:00
core fix(coding-agent): keep prompt and tool state across context handlers (#9846) 2026-09-21 17:14:22 +02:00
experimental feat: add transactional replicated state 2026-09-21 16:07:59 +02:00
extensions fix(coding-agent): detect llama.cpp chat-template thinking 2026-09-18 14:54:17 +02:00
modes feat: add canonical session context boundaries 2026-09-21 16:59:20 +02:00
utils fix: require complete GIF image signatures 2026-09-21 10:30:42 +02:00
cli.ts fix(coding-agent): keep remote harness dependencies development-only 2026-09-05 12:45:04 +02:00
config.ts fix(coding-agent): update repository links to "earendil-works/pi" (#9278) 2026-09-07 14:09:39 +02:00
index.ts fix(coding-agent): keep prompt and tool state across context handlers (#9846) 2026-09-21 17:14:22 +02:00
main.ts feat(ai,coding-agent): add image input limits (closes #9631) 2026-09-20 22:59:16 +02:00
migrations.ts fix(coding-agent): update repository links to "earendil-works/pi" (#9278) 2026-09-07 14:09:39 +02:00
package-manager-cli.ts feat(coding-agent): update managed installations in place 2026-08-24 09:34:34 +02:00
rpc-entry.ts feat(coding-agent): set AI_AGENT environment variable (#7493) 2026-08-03 13:45:32 +02:00