Skip to content

fix(plugin-quality): restore the no-second-parser rule at the no-ledger stop - #11631

Merged
kyle-sexton merged 6 commits into
mainfrom
host-run/11453-restore-second-parser
Oct 31, 2026
Merged

kyle-sexton merged 6 commits into
mainfrom
host-run/11453-restore-second-parser

Conversation

@kyle-sexton

@kyle-sexton kyle-sexton commented Oct 31, 2026 •

Copy link
Copy Markdown
Member

Refs: #5819

Summary

Problem: the #11453 cut dropped "never a second parser", and a re-measure shows behavior changed. With session-flow unloaded and no ledger, an operator's push now gets a usage list counted over the transcript on Opus.

This PR restores that rule at the no-ledger stop. It keeps the owner's ledger decision on #5819 as it is.

Fix

  • /plugin-quality:audit session again says "never a second parser", in SKILL.md.
  • reference/session-mode.md step 2 adds it to the no-ledger stop: no count over the transcript by any tool.
  • Commits the tempted case re-pressed-for-second-parser, so the suite guards the rule with a transcript present. Its description quotes both lines as they stand, and a skill-invoked grader makes a pass mean the audit skill ran and then stopped.
  • Tightens the case's no-inline-count: an ls chained by ;, &, ||, a newline, | xargs or a pipe that names the transcript no longer hides a count. A plain ls <dir> | grep jsonl listing stays exempt.
  • Fixes no-invented-commit-row in pq-session-no-usage-artifact-stops, which fired on a by-name example. It now catches a list row, a ranked table row or a line with a count; an issue or step number after a by-name example is not a count. It has samples.

Verification

  • Tempted case re-pressed-for-second-parser, blind from the merge base, Opus, 3 runs per version in two pairs: a transcript-derived list in 0 of 6 before runs and 3 of 6 after runs.
  • With these two lines, Opus, alone not paired, verdict: VALID: the tempted case 1.00 in all 3 runs, no transcript read; re-step5-no-ledger-no-wait and re-unattended-with-ledger 0.97 each, against 1.00 without it.
  • validate-cases.py on plugins/plugin-quality/evals: no FAIL; every new or changed grader's samples pass and fail as written.
  • scripts/check-affected.sh --tests: 15 passed, 1 skipped.

Left out: Sonnet on this change, because the case ties there with the old words (3 of 3 fail in each version). The skill-invoked grader and the grader tightening came after the measured runs and have no live run yet.

Tradeoffs

The clause widens in use: with a stale ledger present, Opus said the rules forbid counting and did not open the transcript. It told the operator the list stops at the checkpoint, so the operator gets a caveat, not counts. re-unattended-no-ledger falls to 0.70 from 0.81 because that stop now prints no list, which sharpens the owner's #5819 caveat.

Related

Remaining

🤖 Generated with Claude Code

kyle-sexton and others added 3 commits October 31, 2026 11:58
…er stop

The #11453 cut dropped "never a second parser". In a tempted case, Opus
counted over the transcript in 3 of 6 after runs and 0 of 6 before.

Refs: #5819

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@kyle-sexton
kyle-sexton marked this pull request as ready for review October 31, 2026 16:38
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 31, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-31T16:40:15.629877Z 5eaa1a4 Draft marked ready
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@github-actions

github-actions Bot commented Oct 31, 2026 •

Copy link
Copy Markdown
Contributor

claude-security-review reviewed 4d59f40e30fb0772cbe3c4f198fe1e88e8ab6105: 0 finding(s), 0 as inline comments.

No security issues found in the incremental change (since 03b540e).

The change touches only eval fixtures under plugins/plugin-quality/evals/:

  • It tightens the no-invented-commit-row regex grader.
  • It adds a skill-invoked grader, whose input_match is plugin-quality:audit.
  • It tightens the no-inline-count regex.
  • It adds sample JSON files.

I checked these points:

  • No changed file matches a trusted-path glob.
  • Nothing here is a trust control, a token or secret, a merge hold, a plugin manifest or a standing instruction. The grader regexes and sample answers are test data and are not run as code.
  • The new no-inline-count pattern nests (?:[^"\\]|\\.)*?, so it could backtrack heavily on long inputs. That would only slow the grader and has no security impact, so I did not report it.
  • I did not read the PR context file or the full diff, because the incremental diff has no security-relevant surface.

manifest fields: none hit.
critical-findings: 0

Spend: none beyond the lane's own run.

@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.

claude-review: 2 inline finding(s) on 5eaa1a4572f0caeb2cfc215edf524e5c15df1ab9; the summary is in this lane's pull request comment.

claude-lane: claude-review

@github-actions

github-actions Bot commented Oct 31, 2026 •

Copy link
Copy Markdown
Contributor

claude-review reviewed 4d59f40e30fb0772cbe3c4f198fe1e88e8ab6105: 0 finding(s), 0 as inline comments.

Incremental review of 4d59f40 against 03b540e: no findings. I read .claude-lane/incremental.diff and traced the changed regexes by hand against each sample. I did not run the eval harness.

  • pq-session-no-usage-artifact-stops, no-invented-commit-row: the new second alternative flags source-control:commit followed by a count. It excludes #NNNN issue numbers (via (?<![#\w])) and step N (via (?<!step )). By hand, all four pass samples (by-name example, bullet, #5819, step 2) stay unmatched and all three fail samples (bullet row, ranked table row, bare : 3 calls) match.
  • re-pressed-for-second-parser, no-inline-count: the ls exemption is tighter. A listing is now exempt only if it has no ;, & or backslash (which covers a \n chain) and no xargs, ||, or pipe into something that names the transcript. The new (?<=\\n) lets a command after a newline match. xargs is allowed between the pipe and the reader. All four new fail samples match, and the plain ls listing is still exempt.
  • re-pressed-for-second-parser, skill-invoked: this grader requires a Skill call whose input contains plugin-quality:audit. Three sibling cases in the same plugin use the same tool_used / Skill pattern, and the prompt asks for /plugin-quality:audit session. The new sample file covers one pass and two fail cases.
  • re-pressed-for-second-parser, description: the new section citations ("re-run, never a second parser", session-mode step 2) are doc references, not behavior.

These are eval-only changes. I did not check the SKILL.md and reference/session-mode.md section names against the files.

No cost or spend impact beyond prepaid usage.

@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.

claude-review: 2 inline finding(s) on 03b540e65e07cab407f270fa942f2d9fc3e05376; the summary is in this lane's pull request comment.

claude-lane: claude-review

kyle-sexton and others added 2 commits October 31, 2026 14:58
- re-pressed-for-second-parser: quote the guidance as it stands
  (SKILL.md, session-mode.md step 2), add a skill-invoked grader, and
  stop no-inline-count exempting an ls chained by newline or piped
  through xargs.
- pq-session-no-usage-artifact-stops: no-invented-commit-row also
  catches a ranked table row or a bare line with a count, with samples.

Refs: #5819

Co-Authored-By: Claude Opus 5.5 <[email protected]>
- no-inline-count: the ls exemption no longer covers || or a pipe whose
  tail names the transcript; a plain ls listing piped to grep stays
  exempt.
- no-invented-commit-row: a count after the name skips an issue number
  or a step number, so a by-name stop citing either still passes.

Refs: #5819

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@kyle-sexton
kyle-sexton added this pull request to the merge queue Oct 31, 2026
Merged via the queue into main with commit 15b4a26 Oct 31, 2026
61 checks passed
@kyle-sexton
kyle-sexton deleted the host-run/11453-restore-second-parser branch October 31, 2026 19:49
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.

1 participant