Skip to content

feat(retro): retro-filing-policy skill (#525) - #674

Draft
rh-hemartin wants to merge 1 commit into
mainfrom
agent/525-retro-filing-policy
Draft

feat(retro): retro-filing-policy skill (#525)#674
rh-hemartin wants to merge 1 commit into
mainfrom
agent/525-retro-filing-policy

Conversation

@rh-hemartin

Copy link
Copy Markdown
Member

Summary

  • Add retro-filing-policy skill that the retro agent reads before deciding which proposals to file as GitHub issues. Each proposal gets a filing_decision field (file: bool, reason: string); the post-script skips proposals with file=false and folds them into the summary comment.
  • The evidence-for gate remains as a hard safety net after the filing policy gate; filing_decision.file=true cannot override it.
  • Extract sanitize_for_gha() in post-retro.sh to deduplicate GHA workflow command sanitization across 6 call sites.
  • Backward compatible: when filing_decision is absent, all proposals are filed (current default).

Closes #525
Related: fullsend-ai/fullsend#5723

Test plan

  • 10 new post-retro tests covering skip, count, summary folding, mixed proposals, explicit approval, backward compat, injection sanitization, and evidence-for gate override
  • 5 new schema validation tests covering file=true, file=false, absent field, missing reason rejected, extra field rejected
  • All 37 post-retro tests pass
  • All 55 schema validation tests pass

🤖 Generated with Claude Code

…#525)

Add an optional retro-filing-policy skill that the retro agent reads
before deciding which proposals to file as GitHub issues. Each proposal
gets a filing_decision field (file: bool, reason: string). The
post-script skips proposals with file=false and folds them into the
summary comment. When the field is absent, all proposals are filed
(backward compatible).

The evidence-for gate remains as a hard safety net that runs after the
filing policy gate and cannot be overridden by filing_decision.file=true.

Extract sanitize_for_gha() in post-retro.sh to deduplicate GHA workflow
command sanitization across 6 call sites.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Hector Martinez <hemartin@redhat.com>
@fullsend-ai-review

fullsend-ai-review Bot commented Aug 5, 2026

Copy link
Copy Markdown

🤖 Finished Review · ✅ Success · Started 1:55 PM UTC · Completed 2:12 PM UTC
Commit: c310276 · View workflow run →

@fullsend-ai-review

Copy link
Copy Markdown

Review

Findings

High

  • [stale-schema-documentation] skills/retro-analysis/SKILL.md:232 — The retro-analysis skill documentation states proposal objects allow "ONLY the six fields shown above" and lists the six required fields (target_repo, title, what_happened, what_could_go_better, proposed_change, validation_criteria). This PR adds filing_decision as a seventh optional field to schemas/retro-result.schema.json, making the "ONLY six fields" claim incorrect. Since the retro agent reads retro-analysis as its primary output format reference, the explicit prohibition will likely prevent the agent from populating filing_decision, rendering the new feature inoperative. The example JSON at line 214 also needs updating.
    Remediation: Update skills/retro-analysis/SKILL.md — change line 232 to reference seven fields (or "six required fields plus one optional field") and add filing_decision to the example JSON at line 214.

Medium

  • [protected-path] agents/retro.md, harness/retro.yaml, scripts/post-retro.sh, scripts/post-retro-test.sh, scripts/validate-output-schema-test.sh, skills/retro-filing-policy/SKILL.md — Six of eight changed files are under protected paths (agents/, harness/, scripts/, skills/). The PR links to issue feat(retro): accept a skill to control proposal filing behavior #525 and provides clear rationale for the changes. Human approval is always required for protected-path changes, regardless of context.

Low

  • [edge-case] scripts/post-retro.sh — When a proposal has both filing_decision.file=false AND a title matching the evidence-for pattern, the filing policy gate (which runs first) catches the proposal via continue, so the evidence-for gate never evaluates it. The functional outcome is correct (not filed), but the proposal is classified under "Proposals skipped by filing policy" rather than "Evidence notes." No test covers this combination.
    Remediation: Consider moving the evidence-for gate before the filing policy gate, or add a test documenting this ordering as intentional.

  • [GHA-workflow-command-injection] scripts/post-retro.sh:97 — The sanitize_for_gha() function handles ::, %0A/%0D, and newlines but does not strip ANSI escape sequences or other control characters. Not exploitable in GHA Actions UI (rendered literally), but a defense-in-depth gap for raw log consumers.

  • [scope-overshoot] scripts/post-retro.sh — The retro-filing-policy skill text says filtering applies "after you have generated candidate proposals," meaning full proposal content is generated before the filing decision is made. Issue feat(retro): accept a skill to control proposal filing behavior #525 envisioned filtering "before token-expensive proposal writing." The post-script gate is a reasonable safety net, but the agent still generates full proposals for filtered items.


Labels: PR modifies the retro agent subsystem (agent definition, harness, skill, schema, post-script) and adds a new feature


Next steps:

  • /fs-fix — agent addresses review findings automatically
  • /fs-fix <your instruction> — agent fixes with your specific guidance
  • Push commits directly — review re-runs automatically on push
  • /fs-fix-stop — disable automatic fix runs for this PR

@fullsend-ai-review fullsend-ai-review Bot 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.

See the review comment for full details.

Comment thread scripts/post-retro.sh
fi
echo "All ${PROPOSAL_COUNT} proposal(s) validated"

# Sanitize a string for use in GHA workflow commands. Strips newlines,

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

[low] GHA-workflow-command-injection

sanitize_for_gha() does not strip ANSI escape sequences or control characters. Not exploitable in GHA Actions UI but a defense-in-depth gap for raw log consumers.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat(retro): accept a skill to control proposal filing behavior

1 participant