Skip to content

[aw] Harden PR Sous Chef safe-output emission path#39951

Merged
pelikhan merged 2 commits into
mainfrom
copilot/aw-fix-pr-sous-chef-outputs
Jun 18, 2026
Merged

[aw] Harden PR Sous Chef safe-output emission path#39951
pelikhan merged 2 commits into
mainfrom
copilot/aw-fix-pr-sous-chef-outputs

Conversation

Copilot AI commented Jun 18, 2026

Copy link
Copy Markdown
Contributor

PR Sous Chef reported successful runs with no safe outputs because the agent drifted into non-safe-output write paths (gh/safeoutputs shell usage), so no persisted safe-output action was recorded. This change tightens prompt constraints to keep all write behavior on MCP safe-output tools and preserve the required end-of-run noop summary.

  • Problem framing

    • Clarified that PR Sous Chef must never complete without at least one safe-output call and that write actions must go through MCP safe-output tools, not shell wrappers.
  • Prompt contract hardening

    • Added an explicit rule to use only add_comment, update_pull_request, push_to_pull_request_branch, noop, and report_incomplete for write/signaling behavior.
    • Explicitly disallowed gh pr comment, gh api ... -X POST, and safeoutputs ... shell wrappers for writes.
  • Example payload alignment

    • Updated add_comment guidance to show tool-call-shaped payloads.
    • Added a concrete noop tool-call summary example to reinforce final-run signaling format.
{"add_comment":{"pr_number":12345,"body":"<!-- gh-aw-pr-sous-chef-nudge -->\n@copilot review all comments and address unresolved review feedback."}}

Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Copilot AI changed the title [WIP] Fix workflow failure in PR Sous Chef due to no safe outputs [aw] Harden PR Sous Chef safe-output emission path Jun 18, 2026
Copilot AI requested a review from pelikhan June 18, 2026 05:00
@pelikhan pelikhan marked this pull request as ready for review June 18, 2026 05:08
Copilot AI review requested due to automatic review settings June 18, 2026 05:08

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Hardens the PR Sous Chef workflow prompt contract to keep all “write” behavior on MCP safe-output tools, preventing successful runs that fail to persist any safe-output actions and reinforcing the required end-of-run signaling.

Changes:

  • Adds an explicit rule requiring direct use of safe-output MCP tools and disallowing gh / safeoutputs shell write wrappers.
  • Updates the add_comment example to match tool-call-shaped payloads.
  • Adds a concrete end-of-run noop tool-call summary example.
Show a summary per file
File Description
.github/workflows/pr-sous-chef.md Tightens PR Sous Chef prompt constraints and examples to steer writes through MCP safe-output tools and reinforce end-of-run signaling.
.github/workflows/pr-sous-chef.lock.yml Regenerates the compiled lock metadata to reflect the updated markdown workflow body hash.

Copilot's findings

Tip

Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

  • Files reviewed: 2/2 changed files
  • Comments generated: 1

@@ -178,6 +178,7 @@ Move open non-draft PRs toward a state where a maintainer can investigate quickl
6. If a `pr-processor` call returns non-JSON or an error, record `{pr_number: <N>, skip_reason: "sub_agent_error"}` in the `skipped` array of the run-summary noop payload and move to the next PR without retrying.
7. Do not fetch full PR diffs or large file lists unless absolutely required for a skip decision.
8. **Never finish without at least one safe-output tool call.** If you have not called `add_comment` or `update_pull_request`, you must call the run-summary `noop` (see **Run summary** below) before finishing.
@pelikhan pelikhan merged commit 003f6c3 into main Jun 18, 2026
1 check passed
@pelikhan pelikhan deleted the copilot/aw-fix-pr-sous-chef-outputs branch June 18, 2026 05:13
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.

3 participants