Skip to content

Tell agents not to quote signal markers - #467

Merged
umputun merged 4 commits into
masterfrom
prompt-signal-quoting
Oct 20, 2026
Merged

umputun merged 4 commits into
masterfrom
prompt-signal-quoting

Conversation

@umputun

@umputun umputun commented Oct 20, 2026

Copy link
Copy Markdown
Owner

an agent explaining why it is not sending a signal can quote the full <<<RALPHEX:...>>> marker in that sentence. detectSignal matches a marker anywhere in the output, so the quote counts as sent. In #466 this ended the external review loop through custom_eval.txt, with the fixes uncommitted and never re-reviewed.

the fix is prompt only, same as #92 and #293. Every prompt that defines signals now says a marker takes effect wherever it appears, and that a signal is referred to by its bare name (CODEX_REVIEW_DONE), never the full marker:

  • review_first.txt and review_second.txt extend the existing irreversible-marker paragraph, naming REVIEW_DONE and TASK_FAILED
  • codex.txt, custom_eval.txt and task.txt get a short SIGNALS paragraph

the wording proposed in #466 said never to name a signal at all. The bare name gives the agent something safe to write instead, and detection never matches it. make_plan.txt is left out since no plan-mode case was reported; it is in the backlog.

also in this branch:

  • two web tests assert the nil error read from a channel, golangci-lint 2.15.0 flags the discarded receives (CI pins 2.13.0)
  • two backlog items from the review: wrong signal examples in docs/custom-providers.md, and the make_plan.txt follow-up

Related to #466

detectSignal matches a marker anywhere in the output, so an agent that writes the full marker inside a sentence explaining it is not sending it sends the signal anyway. In custom_eval.txt this ended the external review loop with the fixes uncommitted and never re-reviewed.

each prompt that defines signals now says a marker takes effect wherever it appears, and that a signal is referred to by its bare name (REVIEW_DONE), never the full marker. review_first.txt and review_second.txt extend their existing irreversible-marker paragraph; codex.txt, custom_eval.txt and task.txt get a short SIGNALS paragraph. This is prompt mitigation, consistent with how #92 and #293 were handled; the detection contract is unchanged.

Related to #466
golangci-lint 2.15.0 reports the discarded receives from errCh in the dashboard port-conflict test and from done in the watcher close test as unchecked errors. Both channels deliver nil on these paths, so the tests now assert it. CI pins 2.13.0, which does not flag them.
review_first.txt and review_second.txt define both REVIEW_DONE and TASK_FAILED, but the bare-name rule gave only REVIEW_DONE as its example. A quoted TASK_FAILED marker is detected the same way and would fail the review, so the rule now names both, matching task.txt.

Related to #466
Copilot AI balanced review requested due to automatic review settings October 20, 2026 16:21

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@umputun
umputun merged commit fa6dd6f into master Oct 20, 2026
4 checks passed
@umputun
umputun deleted the prompt-signal-quoting branch October 20, 2026 16:25
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.

2 participants