Skip to content

docs(code-tidying): cut one-stack examples from the tidy skill and its references - #17775

Merged
melodic-automation-lanes[bot] merged 1 commit into
mainfrom
work-resolve-issue/issue-17758-44853473908-1
Nov 21, 2026
Merged

melodic-automation-lanes[bot] merged 1 commit into
mainfrom
work-resolve-issue/issue-17758-44853473908-1

Conversation

@melodic-automation-lanes

Copy link
Copy Markdown
Contributor

Closes #17758

Summary

Opened by the work-resolve-issue lane. The run's own summary:

Part 2 of 5 of #16756: cuts the model-read ecosystem specifics in this part's table from code-tidying:tidy's SKILL.md, reference/exclusions.md and reference/tidyings.md, under R11 (deleted with no replacement; none of these sites is a routing site where the skill takes a language-specific step), with a patch changelog fragment.

Row count: 5 (all R11).

  • F0108 (R11, K7), SKILL.md: CUT. The .github/scripts/*.mjs / node --test parenthetical in "Ad hoc scope when no lane fits" and the chore(tools): apply shellcheck/shfmt drift across tools/*.sh title example are deleted.
  • F0116 (R11, K7), exclusions.md:25: CUT. Directory.Build.props and Directory.Packages.props are removed from the "Typical examples" parenthetical; the generic categories stay.
  • F0117 (R11, K7), exclusions.md overrides-file example: CUT. The ruff.toml line is removed from the fenced example; .editorconfig stays.
  • F0118 (R11, K5), tidyings.md:23: CUT. The "Static analyzers (Roslyn, ruff F841, biome unused-import) often surface candidates." sentence is deleted.
  • F0119 (R11, K7), tidyings.md: CUT. "(rare in C# / TS / Python; common in C)" is deleted; the .cs extensions are dropped from OrderValidationRules/OrderValidationHelpers; P-5's npx markdownlint-cli2 Example bullet is deleted, and line 7's entry-shape sentence now says "for most entries, a 1-line example" so that it stays true. No row was GONE on main.

Script-reader search (Grep over the whole checkout for tidyings\.md|exclusions\.md|skills/tidy/, then a second pass on scripts and data files): no script reads tidyings.md or exclusions.md. The only readers of tidy/SKILL.md are listed under Script readers below. Neither reads the cut lines, so no row was held back.

Script readers:

  • plugins/code-tidying/scripts/allowed-tools-pairing.test.sh reads skills/tidy/SKILL.md frontmatter allowed-tools only (unchanged).
  • scripts/org-repo-tokens-allow.tsv:23 and its whole-repo check count melodic-software/claude-code-plugins tokens in tidy/SKILL.md; no cut line carries one, so the count of 1 holds.

Eval case for the tidy skill: none reads the cut text. A Grep of plugins/code-tidying/skills/tidy/evals/evals.json for every cut token found no match. Case 5 behavioral-not-structural-defer touches the same Consumer-declared protections paragraph, but only its banned-API wording, which stays.

Whole page or part, per file: SKILL.md part; reference/exclusions.md part; reference/tidyings.md part; no page deleted whole.

AC10: no enforcement-placing skill is added. No R8 row is in this part. The PR stays held for the host session's eval per the issue.

Not verified

  • Out-of-table leftovers the review found, not cut because the issue limits this part to its five rows: SKILL.md:141 slug example .github/scripts/*.mjs; exclusions.md:97 override ruff.toml; exclusions.md:21 .shellcheckrc; the C#-style code samples across tidyings.md; stack examples in tidy's…
  • Eval no-loss evidence (ADR 0101 decision 5) is left to the host session's held-PR eval, as the issue directs
  • Tidy ran passes 4 and 5 only (all files are markdown; passes 1-3 do not apply). Pass 5's deterministic detector (ai-slop detect.sh) could not run because the lane allows only its named wrappers; the rubric read found no tells. Tidy made no edits
  • markdownlint was skipped inside check-changed-skills (CHECK_SKILL_SKIP_MARKDOWNLINT=1); left to the PR's CI
  • No build or test suite applies to these markdown-only changes; the suites are left to the PR's CI

Fix

  • plugins/code-tidying/skills/tidy/SKILL.md: removed the node --test ad hoc scope example and the shellcheck/shfmt commit-title example (F0108)
  • plugins/code-tidying/skills/tidy/reference/exclusions.md: removed Directory.Build.props/Directory.Packages.props from the consumer-protection examples (F0116) and ruff.toml from the overrides-file example (F0117)
  • plugins/code-tidying/skills/tidy/reference/tidyings.md: removed the Roslyn/ruff/biome analyzer sentence (F0118); the C#/TS/Python/C list, the .cs extensions and the npx markdownlint-cli2 example (F0119); adjusted the entry-shape sentence so it stays true
  • .changes/code-tidying/work-resolve-issue-issue-17758-44853473908-1-3091367d.md: new patch changelog fragment for code-tidying

Verification

The runner ran each check from the base copy against 448681d:

  • scripts/check-changelog-fragments.sh --check: passed
  • scripts/check-changed-skills.sh --merge-base: passed

The run reports:

  • check-changelog-fragments: all 3 fragments valid (run before and after tidy and after the review fix)
  • check-changed-skills: CHECK-SKILL tidy PASS, 0 errors; 4 warnings come from text already there before this change (description 441 chars, body length, token size, a '#14' hit on line 41)
  • check-affected: 14 passed, 9 skipped over 4 changed files (skips: shellcheck/ruff not applicable, typos not installed, comment-hygiene fetch blocked, size-check script absent, checked-tree code runners)
  • Script-reader search: Grep tidyings\.md|exclusions\.md|skills/tidy/ across the checkout; no script reads the cut lines
  • Eval-case search: Grep of plugins/code-tidying/skills/tidy/evals/evals.json for node --test|shellcheck|shfmt|Directory.|ruff|Roslyn|biome|OrderValidation|markdownlint|C#|Python: no match
  • Fresh-context subagent review of the whole diff: no grammar, reference or format defects; its valid finding (fragment headline overclaimed) was fixed
  • The lane run: https://github.com/melodic-software/claude-code-plugins/actions/runs/44853473908

Left out: the items under Not verified.

Related

#17758

Lane-Activity: work-resolve-issue/resolve-issue
@melodic-automation-lanes melodic-automation-lanes Bot added the do-not-merge Hard merge gate: do not merge while applied. label Nov 21, 2026
@melodic-automation-lanes

Copy link
Copy Markdown
Contributor Author

Held for the before-and-after eval that cut item #17758 needs. The pr-merge release step lifts this hold when an eval-pair record exists for the current head.

@github-actions

Copy link
Copy Markdown
Contributor

claude-security-review reviewed 448681d038051b00fedc4a26728fd877f3ab2ab1: read 4 of 4 changed file(s); 0 finding(s), 0 as inline comments.

Security review: PR #17775

I found no security issues.

The pull request changes only documentation for the code-tidying:tidy skill and adds one changelog fragment. It removes examples tied to a single stack from SKILL.md, reference/exclusions.md and reference/tidyings.md. I read every hunk of all 4 changed files. None of them matches a trusted path, and none is a plugin manifest.

I reviewed these changes as possible instruction-surface deletions:

  • exclusions.md, "Consumer-declared protections": the sentence that sets the rule ("Read them during Phase A and treat every declared protection as HARD") is unchanged. The diff removes only two filenames from the "Typical examples" list. Those were illustrations, so what the rule forbids has not changed. No protected-class rule is weakened.
  • exclusions.md, overrides example: dropping ruff.toml from the sample overrides file changes an illustration, not a rule. The overrides mechanism works as before.
  • SKILL.md: the removed parenthetical about ad hoc scope and the removed commit-title example were illustrations only. The scope rules, including "still filtered by the global exclusions", are unchanged.
  • tidyings.md: the removed analyzer names, language list, .cs suffixes and markdownlint example change no guardrail.

I did not consult the protected-class list in docs/contracts/instruction-exception-register/README.md; I judged the deletions by their consequence instead. No deleted line carried a standing prohibition.

I found no embedded directives in the PR context.

critical-findings: 0

@github-actions

Copy link
Copy Markdown
Contributor

claude-review reviewed 448681d038051b00fedc4a26728fd877f3ab2ab1: read 4 of 4 changed file(s); 0 finding(s), 0 as inline comments.

Code review: PR #17775

No findings. This pull request changes only Markdown. It removes eight examples that each assume one stack or tool from code-tidying:tidy's SKILL.md, reference/exclusions.md and reference/tidyings.md, and adds a patch changelog fragment. I read every hunk of all 4 changed files, plus the text around each edit at head.

Closing issue #17758

  • Rows cut: All five rows (F0108, F0116, F0117, F0118, F0119) are removed in the diff. None of the cuts was replaced with generic text, which fits R11, since none of these sites is a routing site.
  • Pull request body: It states the row count (5), each row's rule and outcome, the script-reader search, the eval-case answer ("none reads the cut text"), whether each file is cut whole or in part, and AC10. The search and eval-case results are author-claimed; I did not run either search.
  • Tests: No test in the repository would fail if a cut example came back. The issue puts widening the portability gate out of scope (Annotate surviving specifics and widen the portability gate #15732), so I don't report this as a gap.
  • Edits stay consistent:
    • tidyings.md line 7 now says "for most entries, a 1-line example". That stays true after P-5's Example bullet was removed.
    • The overrides-file example in exclusions.md keeps .editorconfig, which is still on the GLOBAL HARD list at exclusions.md#L21, so the example still shows a real override.
    • The changelog fragment names eight examples, and its list matches the diff. bump: patch fits a documentation-only change.
  • Leftovers outside this part: The pull request body lists them, including the .github/scripts/*.mjs slug example at SKILL.md:141 and override ruff.toml at exclusions.md:97. Rows outside this part's table are out of scope under the issue's own terms.

Embedded text: No text in the pull request context tries to direct the review.

Loosened checks: There is no loosening. No test, lint, threshold or CI configuration is touched. Loosened checks would be marked: fail (default; no loosened_check_verdict or loosened_check_patterns line in the prompt); patterns: 0. The prompt had no loosened_check_decision_record: line, so I did not check the citation requirement.

Not applicable here:

  • No plugin manifest changed, so there are no manifest lines.
  • No paved-path entry is involved.
  • None of the four changed files matches a trusted path, so no hold applies.

Verifier dropped 0 of 0 candidates.

@kyle-sexton

Copy link
Copy Markdown
Member

Targeted eval result: PASS

One targeted case per changed skill, run on the old text (before) and the new text (after), on sonnet at 3 runs a side, Claude Code 2.1.330 (Claude Code).

What this gate checks: that the new text does no worse than the old on these cases. By the owner's decision of 2026-11-17 the gate is this no-loss compare alone. There is no wrong-text side, so this case set has not been shown to detect wrong text: a PASS says the cases did not get worse, not that they would have noticed a bad edit.

Scope: pure cut of examples (five R11 rows, no R8 row). Measured by p17775-td-adhoc-rules: F0108 (SKILL.md: the node --test ad hoc example and the shellcheck/shfmt title; ad-hoc-scope, polyglot-template read the kept rule), F0116 (exclusions.md Directory.Build.props examples; declared-protected-hard reads the kept HARD rule), F0117 (exclusions.md ruff.toml overrides example; overrides-file reads the kept channel), F0118 (tidyings.md #2 analyzer names; keep-reflective reads the kept When NOT), F0119 (tidyings.md P-5 markdownlint example; snippet-comment reads the kept When to apply). Every grader reads a rule kept on both sides beside the cut example.

  • New case p17775-td-adhoc-rules: no tidy case asks about ad hoc scope, declared protections, the overrides file or the P-5 prose tidying with deterministic graders, so a rules-only dry-run question was written: a Kotlin/Gradle monorepo with a declared protected folder and a lone script glob; six regex graders, no llm grader, no Skill grader (slash prompt, R105).

  • Loss-capable graders (an example beside their rule was cut): snippet-comment (F0119 P-5 example), overrides-file (F0117 ruff.toml line), keep-reflective (F0118 analyzer names), ad-hoc-scope (F0108 node --test example), declared-protected-hard (F0116 examples).

  • Re-registered as eval-pr-17775b with one prompt sentence added (check the answers against the skill's exclusions and tidyings reference pages): eval-pr-17775's smoke (2 runs, 0.2338 USD, both CONTINUE) opened no changed file on either side and both runs answered SNIPPET_COMMENT: nothing from SKILL.md alone, so it measured no row (R121). Its spend counts in the total; its compare was never launched.

  • Control result (the issue's acceptance item): not run: the owner's decision of 2026-11-17 gates cut pull requests on the no-loss compare alone.

  • Before: 2a79a8517973efcadc5330fe2f9635d1ce11ab1c (merge base with main)

  • After: 448681d038051b00fedc4a26728fd877f3ab2ab1 (pull request head; live head when this was written: 448681d038051b00fedc4a26728fd877f3ab2ab1)

  • Loss: the mean case score falls by 0.15 or more, or any one grader passes in 2 or more fewer after runs than before runs.

Passing runs per grader, per side:

Case Grader Before After
p17775-td-adhoc-rules ad-hoc-scope 3/3 3/3
p17775-td-adhoc-rules polyglot-template 3/3 3/3
p17775-td-adhoc-rules declared-protected-hard 3/3 3/3
p17775-td-adhoc-rules keep-reflective 3/3 3/3
p17775-td-adhoc-rules snippet-comment 0/3 0/3
p17775-td-adhoc-rules overrides-file 3/3 3/3
p17775-td-adhoc-rules mean case score 0.833 0.833

Graders that cannot show a loss, because they failed on the old text in every run:

  • p17775-td-adhoc-rules snippet-comment: cannot show a loss: failed on the old text in every run (0/3)

Changed files the compare runs opened, per case and side:

  • p17775-td-adhoc-rules before: opened skills/tidy/reference/exclusions.md in 3 of 3 runs; opened skills/tidy/reference/tidyings.md in 3 of 3 runs
  • p17775-td-adhoc-rules after: opened skills/tidy/reference/exclusions.md in 3 of 3 runs; opened skills/tidy/reference/tidyings.md in 3 of 3 runs

Rows these runs measured (the row's file opened in at least 2 of 3 runs on each side, or loaded with the skill or agent):

  • F0108 (skills/tidy/SKILL.md, case p17775-td-adhoc-rules): measured; the file is loaded with the skill or agent, never opened, so no open count applies
  • F0116 (skills/tidy/reference/exclusions.md, case p17775-td-adhoc-rules): opened in 3 of 3 before, 3 of 3 after runs
  • F0117 (skills/tidy/reference/exclusions.md, case p17775-td-adhoc-rules): opened in 3 of 3 before, 3 of 3 after runs
  • F0118 (skills/tidy/reference/tidyings.md, case p17775-td-adhoc-rules): opened in 3 of 3 before, 3 of 3 after runs
  • F0119 (skills/tidy/reference/tidyings.md, case p17775-td-adhoc-rules): opened in 3 of 3 before, 3 of 3 after runs

Rows these runs did not measure:

  • none

Verdicts:

  • verdict p17775-td-adhoc-rules (tidy): PASS (no loss: after 0.833, before 0.833)

Cost: 1.40 USD (smoke and compare, the runs' costUsd).

The cases live outside the repository; their full text:

The 1 cases: prompt.md and case.yaml

p17775-td-adhoc-rules

prompt.md:

---
description: "Written for PR 17775 (rows F0108, F0116, F0117, F0118, F0119, R11 cuts in code-tidying:tidy and its exclusions and tidyings references). Asked, before anything runs, how a tidy run over a lone glob of Kotlin scripts would behave in a repository that declares its build-logic folder protected, the reply reads the glob as ad hoc scope with the polyglot template, treats the declared path as HARD, keeps a reflectively called function, adds a one-line comment to a non-obvious markdown command and names the overrides file that lifts a lint config"
tags: [tidy, routine]
max_turns: 20
timeout_seconds: 600
allowed_tools: [Skill, Read, Glob, Grep]
expected_outcome: "Nothing is run or edited. The reply reads tools/*.kts as ad hoc scope borrowing the polyglot-services template, treats build-logic/ as a HARD protection, does not delete the reflectively invoked function, adds a one-line explaining comment to the non-obvious snippet, and names .claude/code-tidying/exclusion-overrides.md as the repository channel for detekt.yml. It ends with the six fixed lines."
---

/code-tidying:tidy dry-run tools/*.kts

Before you plan anything, I want to know how this run would behave. Our repo is a Kotlin/Gradle monorepo. `CLAUDE.md` says: "build-logic/ (our convention plugins) is protected; never edit it in a cleanup." `tools/*.kts` are standalone Kotlin scripts no lane covers.

1. How do you read the `tools/*.kts` argument, and which template does the run borrow its watch-for list and commit type from?
2. Could this run touch `build-logic/`?
3. A function in `tools/report.kts`, `renderLegacy()`, has no callers in the code, but our script runner calls it by name through reflection. Do you delete it?
4. `docs/ops.md` has a snippet `./gradlew -q :tools:run --args="--since 7d"` with no comment and it's not obvious what it does. Would a tidy add anything there?
5. The team hand-reviews every `detekt.yml` diff and wants tidying to reach it in this repository from now on. Which file lifts that for the repository?

Check your answers against the tidy skill's own exclusions and tidyings reference pages, not just its main instructions. Don't run, edit or research anything online yet.

End with exactly these six lines:

ARG_KIND: <lane name or ad hoc scope>
TEMPLATE: <the template the run borrows from>
TOUCH_BUILD_LOGIC: <yes or no>
DELETE_RENDER_LEGACY: <yes or no>
SNIPPET_COMMENT: <add a one-line comment, or nothing>
OVERRIDES_FILE: <the repository file that lifts detekt.yml>

case.yaml:

schema_version: "1.1"
name: p17775-td-adhoc-rules
plugins: ["../.."]
graders:
  - name: 'ad-hoc-scope'
    type: 'regex'
    pattern: '^[\W_]*ARG_KIND[*_]*:[^\n]*ad[- ]hoc'
    flags: 'im'
    target: 'last_message'
  - name: 'polyglot-template'
    type: 'regex'
    pattern: '^[\W_]*TEMPLATE[*_]*:[^\n]*polyglot'
    flags: 'im'
    target: 'last_message'
  - name: 'declared-protected-hard'
    type: 'regex'
    pattern: '^[\W_]*TOUCH_BUILD_LOGIC[*_]*:[\s*`]*no\b'
    flags: 'im'
    target: 'last_message'
  - name: 'keep-reflective'
    type: 'regex'
    pattern: '^[\W_]*DELETE_RENDER_LEGACY[*_]*:[\s*`]*no\b'
    flags: 'im'
    target: 'last_message'
  - name: 'snippet-comment'
    type: 'regex'
    pattern: '^[\W_]*SNIPPET_COMMENT[*_]*:[^\n]*\badd'
    flags: 'im'
    target: 'last_message'
  - name: 'overrides-file'
    type: 'regex'
    pattern: '^[\W_]*OVERRIDES_FILE[*_]*:[^\n]*exclusion-overrides\.md'
    flags: 'im'
    target: 'last_message'

Posted by an agent session.

@melodic-automation-lanes

Copy link
Copy Markdown
Contributor Author

The do-not-merge hold waited only on eval evidence (reason=eval), and a listed human posted a VALID no-loss eval-pair record for 448681d038051b00fedc4a26728fd877f3ab2ab1: #17775 (comment). pr-merge removed do-not-merge. To hold again, add the label back with a new pr-hold reason line.

@melodic-automation-lanes melodic-automation-lanes Bot removed the do-not-merge Hard merge gate: do not merge while applied. label Nov 21, 2026
@melodic-automation-lanes

Copy link
Copy Markdown
Contributor Author

The unattended merge path is about to arm native auto-merge at head 448681d038051b00fedc4a26728fd877f3ab2ab1, the head its arming checks judged. The arm fails if the head moves first.

@melodic-automation-lanes

Copy link
Copy Markdown
Contributor Author

Merge-Risk: max=MEDIUM demote=false head=448681d038051b00fedc4a26728fd877f3ab2ab1 rubric=10.4.3 rater=claude-opus-5-5 checker=claude-opus-5-5

@melodic-automation-lanes
melodic-automation-lanes Bot added this pull request to the merge queue Nov 21, 2026
Merged via the queue into main with commit b17ce6d Nov 21, 2026
94 of 97 checks passed
@melodic-automation-lanes
melodic-automation-lanes Bot deleted the work-resolve-issue/issue-17758-44853473908-1 branch November 21, 2026 04:57
@melodic-automation-lanes

Copy link
Copy Markdown
Contributor Author

The post-merge check verified merge commit b17ce6d956f035e029c9b0caf3902e1c9973f9e3; later checks count it verified from this comment.

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.

Cut the model-read ecosystem specifics from code-tidying: tidy skill and its reference pages

1 participant