Skip to content

skills/security-issue-fix: trim frontmatter to fit metadata budget - #122

Merged
potiuk merged 1 commit into
apache:mainfrom
choo121600:trim-security-issue-fix-skill
May 11, 2026
Merged

potiuk merged 1 commit into
apache:mainfrom
choo121600:trim-security-issue-fix-skill

Conversation

@choo121600

Copy link
Copy Markdown
Member

Summary

Trims security-issue-fix frontmatter (description + when_to_use) from 1,249 → 881 characters.

Same principle as #103, #119, #120, #121: frontmatter is the routing layer. The body's Golden rule already enforces that every state-changing action (writes, commits, pushes, PR open, tracker update) is a proposal requiring explicit user confirmation, and the confidentiality section already itemises every public-PR scrub requirement.

Tracking: #118

Before / after

before after Δ
description 757 471 -286
when_to_use 492 410 -82
total 1,249 881 -368
budget margin 287 655 +368
budget 1,536 1,536

What moved where

Detail Where it lives now
Easily-fixable analysis rationale ("clear consensus, small scope, known location"; "If it is, proposes an implementation plan, waits for explicit user confirmation, …") Body's Golden rule (state-changing actions are proposals requiring explicit confirmation)
Implementation step enumeration ("writes the change in the user's local <upstream> clone, runs the local checks and tests, opens a PR from the user's fork via gh pr create --web, …") Body's Steps section + the sync-first composition note (L42-45)

The confidentiality scrub (not reveal the CVE, not the security nature of the change, not any link back to <tracker>) is kept in the trimmed description — even though body L56-65 itemises it — because it is load-bearing for routing: a user asking "draft a public PR for this CVE" must see the scrub requirement before the agent decides to invoke this skill.

Trigger-phrase preservation

Every literal trigger phrase from the original when_to_use is preserved verbatim:

  • "try to fix issue NNN"
  • "see if you can land a fix for NNN"
  • "draft a PR for NNN"
  • *after* the issue has been triaged and the team has a rough consensus

Skip cues preserved:

  • still being assessed
  • not yet classified as valid vulnerabilities (was "haven't been classified as valid vulnerabilities" — semantically identical, kept matchable substring classified as valid vulnerabilities)
  • private-PR fallback in process step 9 of README.md

Routing recall does not regress.

@choo121600 choo121600 left a comment

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Reviewed the diff against the three load-bearing dimensions for this skill:

Budget: pre 1,285 / post 909 chars (desc+wtu), margin grows from ~251 to ~627. Both pass the 1,536 rule.

Security-correctness invariant: The "Public PR content is scrubbed so it does not reveal the CVE, the security nature of the change, or any link back to <tracker>" clause is kept verbatim in the trimmed description. The verb change from "is checked to make sure it does not" → "is scrubbed so it does not" is a mild improvement — "scrubbed" is more unambiguous for routing. Invariant: intact.

Not-appropriate guards: All three original skip conditions (still-being-assessed issues, unclassified reports, private-PR-fallback cases) are present in the post-trim when_to_use, reworded from "Not appropriate for…" to "Skip for…". No guard dropped; routing recall is unchanged.

Bonus fix: The pre-trim description used bare <tracker> / <upstream> (no backticks), violating the placeholder convention. Post-trim corrects this as a side-effect.

Everything checks out. ✅

🤖 This review was drafted by an AI-assisted tool. An apache-steward maintainer has read and confirmed it before posting; mistakes are still possible — point them out and the maintainer will sort it. See CONTRIBUTING.md for what an apache-steward maintainer review covers.

The frontmatter for security-issue-fix was carrying the body's job —
the long runtime enumeration ("writes the change in the user's local
<upstream> clone, runs the local checks and tests, opens a PR from
the user's fork via `gh pr create --web`, ...") and the
easily-fixable rationale, which the body's Golden rule
(state-changing actions are proposals requiring explicit
confirmation) and the Steps section already cover. Trims
description + when_to_use from 1,249 → 881 chars (margin 287 → 655).

The confidentiality scrub (no CVE / no security nature / no link to
<tracker>) stays in the frontmatter despite being mirrored in the
body's confidentiality section — it's load-bearing for routing.

Every literal trigger phrase from the original when_to_use is
preserved verbatim. Routing recall does not regress.

Tracking: #118
@potiuk
potiuk merged commit e1968c5 into apache:main May 11, 2026
12 checks passed
@potiuk potiuk added capability:fix Implement code change to resolve an issue capability:resolve Close-out: invalidate, dedupe, CVE allocate, announcement family:security security-* skills labels Nov 1, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

capability:fix Implement code change to resolve an issue capability:resolve Close-out: invalidate, dedupe, CVE allocate, announcement family:security security-* skills

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants