Skip to content

Surface agent messages near the top of completion comments - #80783

Merged
pelikhan merged 4 commits into
mainfrom
copilot/improve-agent-issue-comment-template
Nov 24, 2026
Merged

pelikhan merged 4 commits into
mainfrom
copilot/improve-agent-issue-comment-template

Conversation

@pelikhan

@pelikhan pelikhan commented Nov 24, 2026 •

Copy link
Copy Markdown
Collaborator

Agent explanations were buried beneath outcome boilerplate in collapsed sections. This change makes no-op and other agent messages readable at a glance.

  • Layout: Add an expanded Agent messages section immediately after completion status, before links and outcome metadata.
  • Content: Label each explanation by type while preserving Markdown and agent-authored alerts.
  • Safeguards: Retain existing detection, authorization, staging, sanitization, and redaction rules.

pelikhan and others added 2 commits November 24, 2026 19:33
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
@pelikhan
pelikhan marked this pull request as ready for review November 24, 2026 19:41
Copilot AI adaptive review requested due to automatic review settings November 24, 2026 19:41
@github-actions

github-actions Bot commented Nov 24, 2026 •

Copy link
Copy Markdown
Contributor

✅ PR Code Quality Reviewer completed the code quality review.

Agent messages

No-op message

PR #80783 review completed with no actionable findings; review submitted and review-history recorded.

PR Code Quality Reviewer

Outcome: reported_action

The agent completed and reported one or more actions. The no-op output is a completion signal, not a claim that no action was taken.

The [aw] No-Op Runs tracker omits agent messages. The category uses structured run status, not interpretation of agent prose.

🔎 Code quality review by PR Code Quality Reviewer · copilot · gpt56 · ~3 AIC · ⌖ ~2 AIC · ⊞ 1.7K · history

@github-actions

github-actions Bot commented Nov 24, 2026 •

Copy link
Copy Markdown
Contributor

✅ Test Quality Sentinel completed test quality analysis.

🧪 Test quality analysis by Test Quality Sentinel · copilot · routed: haiku55 xhigh · ~5 AIC · ⌖ ~2 AIC · ⊞ 7.4K · history

@github-actions

github-actions Bot commented Nov 24, 2026 •

Copy link
Copy Markdown
Contributor

✅ PR Specification Reviewer completed successfully!

Agent messages

No-op message

PR #80783 reviewed at head b1945d9: no directly applicable specification contract or actionable finding; no review publication needed.

PR Specification Reviewer

Outcome: reported_action

The agent completed and reported one or more actions. The no-op output is a completion signal, not a claim that no action was taken.

The [aw] No-Op Runs tracker omits agent messages. The category uses structured run status, not interpretation of agent prose.

Generated by PR Specification Reviewer for #80783 · copilot · gpt56 · ~2 AIC · ⌖ ~1 AIC · ⊞ 1.8K · history

@github-actions

github-actions Bot commented Nov 24, 2026 •

Copy link
Copy Markdown
Contributor

🧠 Matt Pocock Skills Reviewer has completed the skills-based review. ✅

🧠 Reviewed using Matt Pocock's skills by Matt Pocock Skills Reviewer · copilot · routed: haiku55 xhigh · ~8 AIC · ⌖ ~2 AIC · ⊞ 5.1K · history

@github-actions

github-actions Bot commented Nov 24, 2026 •

Copy link
Copy Markdown
Contributor

✅ Ponytail Reviewer completed successfully!

Agent messages

No-op message

Lean already. Ship.

Ponytail Reviewer

Outcome: reported_no_action

The agent completed and reported no action. A no-op output alone does not verify that all required work was completed or that publication was possible.

The [aw] No-Op Runs tracker omits agent messages. The category uses structured run status, not interpretation of agent prose.

Generated by Ponytail Reviewer for #80783 · codex · routed: gpt61 medium · ~4 AIC · ⌖ ~1 AIC · ⊞ 176 · history

@github-actions

Copy link
Copy Markdown
Contributor

Comment Memory

Peek at saved memory (spec-review-history)
{"id":"ldg-5150b3c8-8240-4a31-97c1-07c3e1bf8b82","parents":[],"payload":{"id":"ldg-e480b814-9783-462e-969c-44df293860b5","operation":"append","value":{"finding_count":0,"head_sha":"b1945d9cc5f8fe1e04a82b0ba05991af852161eb","outcome":"aligned"}},"sha":"sha256:262ba539dd9553e66874b00a0e62cefd1639706a4a57491c3df96b1489f1b11f","timestamp":"2026-11-24T19:48:43.793Z","type":"ledger_append","version":1}
History

@github-actions github-actions Bot 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.

Reviewed the changed lines in notify_comment_error.cjs and its tests. I found no actionable correctness, security, performance, or maintainability issues that should block merge. The expanded agent-message layout is validated through the existing report AST normalization and the new tests cover sanitization, redaction, alerts, ordering, and publication restrictions.

🔎 Code quality review by PR Code Quality Reviewer · copilot · gpt50 · ~3 AIC · ⌖ ~2 AIC · ⊞ 1.7K
Comment /review to run again

@github-actions

Copy link
Copy Markdown
Contributor

Comment Memory

Peek at saved memory (review-history)
{"id":"ldg-9d87128b-e24a-481b-8107-cb2ca6aba600","parents":[],"payload":{"id":"ldg-ba152f70-9e3c-4843-a815-0c77d43ea3ae","operation":"append","value":{"finding_count":0,"head_sha":"b1945d9cc5f8fe1e04a82b0ba05991af852161eb","outcome":"no_findings"}},"sha":"sha256:84310dc75e142a496c87a39c99fce07f3dcc6a0d23d88a3444c326761a6e257b","timestamp":"2026-11-24T19:49:45.317Z","type":"ledger_append","version":1}
History

@github-actions

Copy link
Copy Markdown
Contributor

🧪 Test Quality Sentinel Report

✅ Test Quality Score: 85/100 — Excellent

Analyzed 13 test case(s): 12 design, 1 implementation, 0 violation(s). Scope: actions/setup/js/notify_comment_error.test.cjs (vitest). No Go or other-language tests changed.

📊 Metrics (13 tests)
Metric Value
Analyzed 13 (JS: 13, Go: 0)
✅ Design 12 (92.3%)
⚠️ Implementation 1 (7.7%)
Edge/error coverage 12 (92.3%)
Duplicate clusters 0
Inflation YES (59 test lines added vs. 15 production lines, 3.9:1)
🚨 Violations 0
Test Line Classification Issues
keeps agent content tainted under framework-authored section labels 252 implementation_test (edge) Asserts internal AST shape
shows multiline agent messages before links, categorized outcomes, and attribution 313 design_test (edge) None
preserves agent-authored alerts without nesting them in another alert 332 design_test (edge) None
omits the info section when there are no publishable explanations 339 design_test (edge) None
requires a clean, accepted verdict (7 rows, modified) 201 design_test (6 of 7 rows negative) None
sanitizes accepted no-op Markdown and preserves allowed links (modified) 293 design_test (edge) None
masks recognized credentials in the published explanation (modified) 350 design_test (edge) None
⚠️ Flagged Tests (2)

keeps agent content tainted under framework-authored section labels (notify_comment_error.test.cjs:252): implementation_test. The taint invariant (framework labels untainted, agent text tainted) is worth keeping, but the assertions depend on AST node shape (type, level, children). Asserting taint through rendered output would be less brittle. Not a violation.

PR-level test inflation (notify_comment_error.test.cjs vs notify_comment_error.cjs): 59 test lines added vs. 15 production lines (3.9:1, above 2:1). The new tests cover distinct behaviors (ordering, alert nesting, empty-section omission, taint), so this looks proportionate rather than padded. Costs 10 score points.

Verdict

✅ passed. 7.7% implementation tests (threshold: 30%). No hard violations.

Limitation: Vitest could not run in this sandbox (dependency install was denied), so this review is static, based on the diff and source. CI should confirm the suite passes.

References: §45472916013

🧪 Test quality analysis by Test Quality Sentinel · copilot · routed: haiku55 xhigh · ~5 AIC · ⌖ ~2 AIC · ⊞ 7.4K · history
Comment /review to run again

@github-actions github-actions Bot 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.

✅ Test Quality Sentinel: 85/100. 7.7% implementation tests (threshold: 30%).

🧪 Test quality analysis by Test Quality Sentinel · copilot · routed: haiku55 xhigh · ~5 AIC · ⌖ ~2 AIC · ⊞ 7.4K
Comment /review to run again

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.

🟡 Changes recommended

Protected labels can leave the report over the comment-size limit even after message redaction, causing rendering to throw before the completion status is published.

1 open issue
What changed in this PR

This PR makes agent explanations easier to find in gh-aw completion comments by displaying them near the top instead of inside collapsed sections.

Changes:

  • Adds an expanded Agent messages section before links and outcome metadata.
  • Labels explanations by type while retaining Markdown parsing and existing publication safeguards.
  • Updates tests for message ordering, alerts, taint tracking, sanitization, and credential redaction.
File Description
actions/​setup/​js/​notify_comment_error.test.cjs Updates layout expectations and adds coverage for expanded agent messages.
actions/​setup/​js/​notify_comment_error.cjs Replaces collapsed explanations with labeled messages and moves them before links.

Review effort: Balanced (adaptive)

normalizeReport({ type: "report", title: "Workflow status", children: [details] });
children.push(details);
normalizeReport({ type: "report", title: "Workflow status", children: blocks });
reports.push({ type: "paragraph", children: [{ type: "strong", children: [{ type: "text", value: summary, agentTainted: false }], agentTainted: false }], agentTainted: false }, ...blocks);

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.

Fixed in c196154: completion comments now cap valid explanations and indicate when additional messages are omitted. Regression tests cover oversized collections and size redaction.

@github-actions github-actions Bot 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.

Summary

Agent explanations now render in one ## Agent messages section above the activation links, without <details> wrappers. Agent text stays tainted under framework-authored labels. I found no blocking issues in the changed lines.

Checked

  • Depth validation: the old code validated report → details → blocks. The new code validates report → blocks, which matches the rendered tree, so nesting checks are not weakened.
  • Ordering and taint: the new tests match the rendered order, and the bold labels are framework-authored (agentTainted: false).
  • No-op duplication: handle_noop_message.cjs emits only category and description text, so the explanation is not repeated in the no-op body.
  • Redaction: credential screening and shared report redaction still run before rendering.

Limitation

I could not run the JS test suite. npm ci in actions/setup/js fails on the package proxy self-signed TLS certificate, so the new exact-whitespace toContain assertions are unverified. Run the notify_comment_error tests before merging.

🧠 Reviewed using Matt Pocock's skills by Matt Pocock Skills Reviewer · copilot · routed: haiku55 xhigh · ~8 AIC · ⌖ ~2 AIC · ⊞ 5.1K
Comment /matt to run again

@gh-aw-bot

Copy link
Copy Markdown
Collaborator

@copilot

🍳 A little prep to help this PR along! Copilot assignment requested for the following outstanding work:

  1. Update this branch with the latest main using make merge-main, resolving any conflicts and preserving the intended changes.
  2. Review (actions/setup/js/notify_comment_error.cjs:162): address unresolved feedback - Review comment

Keeping the changes focused; human review and CI get the final taste test. No merging or CI triggering.

Structured data
{
  "completed_task": 0,
  "head": "b1945d9cc5f8fe1e04a82b0ba05991af852161eb",
  "kind": "requested",
  "schema_version": "1",
  "state": "c1f1c9c64fbcbeb1f6b96175c093ee39f6ba88afc0e118c064e642419c300b5f",
  "work": [
    "0d2396e6eaf3f0a69d9aab1a7bdd9b3d91c26f012dc45322567169e9bd8e7e2f"
  ],
  "workflow": "pr-sous-chef"
}

Generated by 👨🍳 PR Sous Chef · pi · routed: haiku55 xhigh · ~2 AIC · ⌖ ~2 AIC · ⊞ 7K · history
Comment /souschef to run again

gh-aw-bot and others added 2 commits November 24, 2026 20:25
…-issue-comment-template

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>

Copilot AI commented Nov 24, 2026

Copy link
Copy Markdown
Contributor

@copilot

🍳 A little prep to help this PR along! Copilot assignment requested for the following outstanding work:...

Merged main and fixed the report limit in c196154. The final validation gate passed (64 tests). make merge-main built successfully, but workflow recompilation failed because the configured npm proxy could not resolve.

Copilot AI requested a review from gh-aw-bot November 24, 2026 20:33
@pelikhan
pelikhan merged commit 88f9bb5 into main Nov 24, 2026
37 of 38 checks passed
@pelikhan
pelikhan deleted the copilot/improve-agent-issue-comment-template branch November 24, 2026 20:35
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.

4 participants