* fix: wrap custom messages with system notification prefix in LLM context Background job completion notifications (delivered as custom messages via sendMessage with deliverAs: "followUp") were converted to plain role: "user" messages in convertToLlm(), making the LLM indistinguishable from actual human input. This caused the agent to confuse background task output with user messages, responding to job completions as if the user had typed them. Wrap all custom messages with a clear system notification prefix that includes the customType and an explicit instruction that the content is an automated system event, not user input. This follows the same pattern used by branchSummary and compactionSummary messages which already use structured prefixes/suffixes. Closes #3026 Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> * fix: resolve TS import extension and type errors in messages test Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com> |
||
|---|---|---|
| .. | ||
| daemon | ||
| mcp-server | ||
| native | ||
| pi-agent-core | ||
| pi-ai | ||
| pi-coding-agent | ||
| pi-tui | ||
| rpc-client | ||