Skip to content

feat(skill-management): add migrate-config-to-opus-5 skill - #562

Merged
wkoutre merged 4 commits into
nextfrom
nickkoutrelakos/add-migrate-config-to-opus-5-skill
Aug 4, 2026
Merged

feat(skill-management): add migrate-config-to-opus-5 skill#562
wkoutre merged 4 commits into
nextfrom
nickkoutrelakos/add-migrate-config-to-opus-5-skill

Conversation

@wkoutre

@wkoutre wkoutre commented Aug 4, 2026

Copy link
Copy Markdown
Contributor

Summary

Ports the migrate-config-to-opus-5 skill into the skill-management plugin for team-wide use. The skill audits and migrates a Claude Code configuration (CLAUDE.md, rules, skills, commands, agents, settings.json, hooks, statusline, CI scripts) for Claude Opus 5's behavioral changes.

What the skill does:

  • Interviews for scope first: global ~/.claude vs the current project
  • Inventories every file that loads into context, plus scripts/CI embedding model IDs or API params
  • Audits against references/audit-patterns.md — the four Opus 5 behavioral deltas (self-verification, delegation, literal instruction-following, output length) with concrete search patterns and fix shapes
  • Classifies every finding: fix mechanically / rewrite / user decision (policy vs compensation — never silently removes a gate) / leave alone with rationale
  • Executes with one granular commit per logical change, then verifies with a fresh claude -p probe

Plugin changes:

  • New skill at packages/plugins/skill-management/skills/migrate-config-to-opus-5/ (SKILL.md + references/audit-patterns.md)
  • plugin.json: skill registered, version bumped 1.0.2 → 1.1.0 (minor: new backward-compatible skill)
  • Plugin CLAUDE.md + README updated; root CLAUDE.md version table updated

Why skill-management: this plugin is the curation layer over the Claude Code customization surface (inventory, audit, improve). A model-migration audit of that same surface fits its charter; claude-setup is about bootstrapping new repos, not migrating existing config.

Test plan

  • node scripts/validate-plugin.cjs packages/plugins/skill-management passes
  • bunx markdownlint-cli2 clean on all touched files
  • bunx nx format:write --uncommitted applied
  • Pre-commit hooks (format, lint, lint-markdown, test, typecheck, lockfile) all green
  • Skill content exercised in a real end-to-end migration of a large personal config (2026-08-04) before porting

🤖 Generated with Claude Code

Adds a skill that audits and migrates a Claude Code configuration
(CLAUDE.md, rules, skills, commands, agents, settings.json, hooks,
statusline, CI scripts) for Claude Opus 5's behavioral changes.

The skill interviews for scope first (global ~/.claude vs the current
project), inventories the surface, classifies findings as mechanical
fixes / rewrites / user decisions / deliberate keeps, executes with
granular commits, and verifies with a fresh `claude -p` probe. Bundles
references/audit-patterns.md covering the four Opus 5 behavioral deltas
(verification, delegation, literal instruction-following, output
length) plus mechanical checks (stale model IDs, pricing ratios, API
params).

Bumps skill-management to 1.1.0 (minor: new skill, backward
compatible).

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@wkoutre
wkoutre requested a review from a team as a code owner August 4, 2026 22:03
@vercel

vercel Bot commented Aug 4, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
ai-toolkit-slack-oauth-backend Ready Ready Preview Aug 4, 2026 10:25pm

Request Review

@github-actions

github-actions Bot commented Aug 4, 2026

Copy link
Copy Markdown
Contributor

📚 Documentation Check ✅

Verdict: Passed

The plugin version was correctly bumped (1.0.2 → 1.1.0) as a minor bump for the new migrate-config-to-opus-5 skill, matching semver rules for "new skill added." The bump is reflected consistently in both plugin.json and the root CLAUDE.md version table. Plugin-level CLAUDE.md and README.md were both updated to describe the new skill, and the new skill files (SKILL.md, references/audit-patterns.md) were added to the plugin.json skills array correctly (not commands). Naming convention (verb-noun: "migrate-config-to-opus-5") is satisfied.


Documentation Review — PR #562

Plugin version bump (CRITICAL check): PASS

  • packages/plugins/skill-management/.claude-plugin/plugin.json version bumped 1.0.21.1.0.
  • This is a minor bump, correct per repo semver rules since a brand-new skill (migrate-config-to-opus-5) was added — new skills/agents/commands require a minor bump, not patch.
  • The new skill is correctly registered in the skills array (not commands), and was not added to commands.
  • Root CLAUDE.md version table (line ~231) was updated in the diff to match (1.0.21.1.0), keeping the two sources of truth consistent.

Plugin CLAUDE.md: PASS

  • packages/plugins/skill-management/CLAUDE.md was updated with a new bullet describing the migrate-config-to-opus-5 skill, its purpose, and the reference file it bundles — matches the "Plugin Components" documentation pattern used for the existing skill-doctor entry.

Plugin README.md: PASS

  • packages/plugins/skill-management/README.md intro paragraph and skills table were both updated to include the new skill with an accurate description.

Naming convention: PASS

  • migrate-config-to-opus-5 follows the required verb-noun pattern for skills (verb: "migrate", noun phrase: "config-to-opus-5").

Changelog: N/A

  • No CHANGELOG.md exists for this plugin, and changelog entries are informational/non-blocking per the validator config (fail_on_missing_docs: false). Nothing to flag.

Root CLAUDE.md plugin-count snapshot: Unaffected — no plugins were added/removed (only a skill within an existing plugin), so the "8 plugins" snapshot line and marketplace.json parity are untouched and still correct.

No missing documentation updates found. This PR fully satisfies the mandatory version-bump and documentation-sync rules in CLAUDE.md and .claude/rules/plugin-docs.md.

✨ No Documentation Updates Needed

All documentation appears to be up to date with the code changes.


🤖 Generated by Claude Documentation Validator | Mode: suggest

@github-actions

github-actions Bot commented Aug 4, 2026

Copy link
Copy Markdown
Contributor

● Reviewed · against 923fad4 · 2026-08-04 22:28 UTC · 3 reviews · view run ↗

Latest: ✅ approved ← prior: ✅ approved ← 🚨 changes requested (4)

Note

Approved — one doc-parity nit on the delivery rule, tracked in an open thread.

Adds a migrate-config-to-opus-5 skill to skill-management that inventories, audits, and rewrites a Claude Code configuration for Opus 5, plus the manifest registration, 1.0.2 → 1.1.0 bump, and doc sync.

Assessment

The publishing contract checks out: manifest matches disk in both directions, the minor bump ships in the same commit, and all three doc surfaces agree. Every mechanical-fix claim in references/audit-patterns.md — model IDs, pricing, context windows, the budget_tokens → adaptive-thinking migration, the effortLevel default split — matches the current model reference, which matters because that bucket is applied without an interview. The delivery rule now branches off the repo's default branch rather than the current checkout; what remains on the open thread is that its claim of parity with skill-doctor's rule still omits the draft-PR and clean-worktree requirements.

Suggestions

  • SKILL.md:21 — the parity claim with skill-doctor's delivery rule omits the draft-PR and clean-worktree requirements, and names origin/main where skill-doctor resolves the default branch because it is not always main.
Iteration history · 3 reviews
2026-08-04 22:28 UTC · ✅ approved · 0 findings · 923fad4 · run ↗

(no findings)

2026-08-04 22:19 UTC · ✅ approved · 0 findings · 5c4eb22 · run ↗

(no findings)

2026-08-04 22:12 UTC · 🚨 changes requested · 4 findings · 4bcb123 · run ↗
  • packages/plugins/skill-management/skills/migrate-config-to-opus-5/references/audit-patterns.md:58 — warning · correctness
  • packages/plugins/skill-management/skills/migrate-config-to-opus-5/references/audit-patterns.md:61 — warning · security
  • packages/plugins/skill-management/skills/migrate-config-to-opus-5/SKILL.md:54 — warning · security
  • packages/plugins/skill-management/skills/migrate-config-to-opus-5/SKILL.md:21 — info · consistency

Tip

Teach the reviewer. React 👍 on findings that helped, 👎 on false positives. Reply to push back or add context — we aggregate this weekly to tune the bot.

Comment @request-claude-review to re-run.

- Widen plugin-level descriptions (plugin.json, README, CLAUDE.md) to
  cover full-config migration, so the new skill is discoverable from
  the plugin listing
- Date-stamp the model-ID and pricing facts in audit-patterns.md so
  future staleness is visible

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

@chatgpt-codex-connector chatgpt-codex-connector 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.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 2670e105e8

ℹ️ 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".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".


**Keep (policy):** cost-routing tables (cheap models for mechanical steps — that's economics), and adversarial-review/verification dispatches the user explicitly wants in fresh contexts. If the user has such a policy, write the cap language _with an explicit carve-out_ naming it, or the cap will silently eat the gate.

**Related stale fact:** pre-2026 configs often justify model routing with "Opus costs ~5x Sonnet". Claude 5 pricing: Opus 5 $5/$25 per MTok vs Sonnet 5 $3/$15 → ~1.7x. Haiku ($1/$5) is still ~5x under Opus. Update any cost-ratio claims and thresholds derived from them.

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Correct the current Sonnet 5 pricing ratio

As of August 4, 2026, this mechanical pricing fix hard-codes the post-September 1 Sonnet 5 price. Anthropic's current pricing page lists Sonnet 5 introductory pricing through August 31, 2026 at $2/$10 per MTok while Opus 5 is $5/$25, so the current Opus/Sonnet ratio is 2.5x, not ~1.7x. If someone runs this migration before September 1, the skill can rewrite cost-routing claims and thresholds to the wrong ratio; date-qualify this guidance or include both current and future prices. Source: Anthropic pricing.

Useful? React with 👍 / 👎.


## Settings that need a user decision

- **effortLevel** (Claude Code setting): Opus 5's default is xhigh; low/medium are unusually strong on this model, so a pinned `high` from the 4.x era is worth revisiting. Never change this one mechanically — present the trade (cost/latency vs depth) in the Step 3 interview and let the user pick; log a checkpoint to revisit after a week of use.

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Correct the Opus 5 effort default

This tells the migration skill that Opus 5 defaults to xhigh, but Anthropic's migration guide says the Opus 5 default is high on both the Claude API and Claude Code. That false baseline will mislead the required user-decision interview for effortLevel and can make an existing pinned high look like a downshift from the default when it is actually the default; keep the useful "re-run an effort sweep" advice without claiming xhigh is the default. Source: Anthropic migration guide.

Useful? React with 👍 / 👎.


## Mechanical checks (no judgment, just fix)

- **Model IDs:** `/usr/bin/grep -rE 'claude-(opus|sonnet|haiku)-[0-9]' <scope>` across scripts, CI, statuslines, agent frontmatter, scheduled-task registrations. Current IDs (as of 2026-08): `claude-opus-5`, `claude-sonnet-5`, `claude-haiku-4-5`. Aliases (`opus`, `sonnet`, `haiku`) are self-updating — prefer them where a pin isn't required.

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.

⚠️ warning · correctnessclaude-(opus|sonnet|haiku)-[0-9] never matches Claude 3.x IDs, which put the tier after the version (claude-3-opus-20240229, claude-3-5-sonnet-20241022). Those are exactly the retired, now-404 pins most likely to be in a pre-Opus-5 config, and this "mechanical, no judgment" check reports clean on them.

Suggested change
- **Model IDs:** `/usr/bin/grep -rE 'claude-(opus|sonnet|haiku)-[0-9]' <scope>` across scripts, CI, statuslines, agent frontmatter, scheduled-task registrations. Current IDs (as of 2026-08): `claude-opus-5`, `claude-sonnet-5`, `claude-haiku-4-5`. Aliases (`opus`, `sonnet`, `haiku`) are self-updating — prefer them where a pin isn't required.
- **Model IDs:** `/usr/bin/grep -rE 'claude-(opus|sonnet|haiku|fable|mythos)-[0-9]|claude-[0-9]' <scope>` across scripts, CI, statuslines, agent frontmatter, scheduled-task registrations. The second alternative catches the Claude 3.x scheme (`claude-3-opus-…`, `claude-3-5-sonnet-…`), where the tier follows the version. Current IDs (as of 2026-08): `claude-opus-5`, `claude-sonnet-5`, `claude-haiku-4-5` (plus `claude-fable-5` where the top tier is wanted). Aliases (`opus`, `sonnet`, `haiku`) are self-updating — prefer them where a pin isn't required.

- **Model IDs:** `/usr/bin/grep -rE 'claude-(opus|sonnet|haiku)-[0-9]' <scope>` across scripts, CI, statuslines, agent frontmatter, scheduled-task registrations. Current IDs (as of 2026-08): `claude-opus-5`, `claude-sonnet-5`, `claude-haiku-4-5`. Aliases (`opus`, `sonnet`, `haiku`) are self-updating — prefer them where a pin isn't required.
- **Context-window logic:** scripts branching on model ID for window size. All current non-Haiku models are 1M; Haiku 4.5 is 200K. Keying "haiku → 200K, else 1M" beats enumerating model names. Test with synthetic payloads for both branches.
- **API params:** `budget_tokens` is rejected with a 400 on the Claude 5 family — replace `thinking: {type: "enabled", budget_tokens: N}` with `thinking: {type: "adaptive"}`. Also flag hardcoded `temperature` alongside thinking, and Priority Tier assumptions (not supported on Opus 5).
- **Dead weight:** vendored commands referencing nonexistent agents, archive directories, `.backup`/`.bak` settings snapshots (these often pin old models), marketplace entries pointing at dead repos. Delete; git holds history.

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.

⚠️ warning · data-loss — "git holds history" is false for the global scope this skill offers first: skill-doctor/SKILL.md:43 documents ~/.claude as the user's non-git config, and SKILL.md:51 itself hedges "if the surface is a git repo". With dead entries classified as "fix mechanically — no interview needed" (SKILL.md:40), deleting .backup/.bak snapshots there is unapproved and unrecoverable.

Suggested change
- **Dead weight:** vendored commands referencing nonexistent agents, archive directories, `.backup`/`.bak` settings snapshots (these often pin old models), marketplace entries pointing at dead repos. Delete; git holds history.
- **Dead weight:** vendored commands referencing nonexistent agents, archive directories, `.backup`/`.bak` settings snapshots (these often pin old models), marketplace entries pointing at dead repos. Delete only when the surface is a git repo with a clean tree — git holds history there. On a non-git surface (a plain `~/.claude`), list them for the Step 3 interview instead of deleting.

- One granular commit per logical change (if the surface is a git repo). Never one big migration commit — the user needs to be able to revert a single decision.
- For shared/synced files, apply the machine-agnostic path rule from Step 0.
- When editing `settings.json`, validate with `python3 -c "import json; json.load(open('...'))"` after every edit, and check `git diff` first so pre-existing drift from other sessions is named in the commit message rather than silently swept in.
- Delete dead things outright (superseded commands, archives, backup files) — git history is the recovery path; "kept for recovery" copies keep loading into context.

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.

⚠️ warning · data-loss — "git history is the recovery path" only holds on line 51's branch where the surface is a git repo. Condition the delete rule on that, or a global-scope run destroys backup files with nothing to restore from.


If the user picked global and `~/.claude` is a git repo shared across machines, every path fix must be machine-agnostic (`$HOME`, `~/`, resolver scripts) — a literal home-dir path that is correct on this machine is silently wrong on the others.

In the same interview, ask one execution question: apply edits directly with granular commits (the default), or propose the full diff for review first.

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.

🔵 info · consistency — Defaulting to "apply edits directly with granular commits" inverts the sibling skill's delivery rule (skill-doctor/SKILL.md:47: repo files ship as a draft PR, never an in-place edit on the working branch). On project scope this commits straight to whatever branch is checked out.

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

Caution

⚠️ Changes requested — see full review in the sticky comment ↑

- Widen the model-ID grep to also match Claude 3.x-era IDs
  (claude-3-opus-..., claude-3-5-sonnet-...) where the version
  precedes the tier
- Note Sonnet 5 introductory pricing ($2/$10 through 2026-08-31,
  ratio ~2.5x) so the mechanical pricing fix isn't wrong pre-September
- Condition dead-weight deletion on a git surface; on non-git configs
  require a confirmed backup or a user decision
- Align project-scope delivery with skill-doctor: edits land on a
  branch + PR, not the checked-out branch
- Disambiguate effortLevel: Claude Code defaults Opus 5 to xhigh,
  the raw API default is high

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

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

Note

Approved — see full review in the sticky comment ↑

Tightens the project-scope delivery rule to match skill-doctor exactly:
the PR branch comes off origin/<default>, not whatever is checked out.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@wkoutre
wkoutre merged commit e90165b into next Aug 4, 2026
18 checks passed
@wkoutre
wkoutre deleted the nickkoutrelakos/add-migrate-config-to-opus-5-skill branch August 4, 2026 22:28
wkoutre added a commit that referenced this pull request Aug 5, 2026
…stions for migrate-config-to-opus-5 (#564)

* fix(skill-management): apply residual review suggestions to migrate-config-to-opus-5

Applies the two github-actions[bot] inline suggestions from PR #562 that
were not fully adopted before merge:

- Model-ID grep now also matches fable/mythos tier IDs, and the current-IDs
  list mentions claude-fable-5 for top-tier use
- Dead-weight deletion now requires a clean tree on git surfaces, and routes
  non-git dead weight to the Step 3 interview

Patch bump skill-management 1.1.0 -> 1.1.1.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* fix(skill-management): mirror clean-tree deletion rule in SKILL.md Step 4

Codex review flagged that the executable workflow text still permitted
outright deletion on any git repo while the reference required a clean
tree. Both now agree: clean tree required, dirty/non-git dead weight
routes to the Step 3 interview.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* feat(skill-management): subagent read-every-file audit in migrate-config-to-opus-5

Step 2 now mandates a subagent fan-out that reads each in-scope file in
full, audits it against references/audit-patterns.md, and reports
structured per-file findings (quoted text, proposed change,
classification, rationale) back to the main thread. Grep sweeps are
demoted to a completeness cross-check — a hit in an unreported file
means a missed batch, never a patch source.

Bump becomes minor (1.1.1 -> 1.2.0) since this is a feature-level
enhancement; plugin CLAUDE.md and README updated to match.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* fix(skill-management): include classification buckets in subagent payload

AI review caught that the contract referenced 'the four buckets below'
while the enumerated payload omitted them — subagents never see the
rest of SKILL.md, so each would invent its own labels.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* fix(skill-management): forward-looking destination for mid-execution dead weight

Step 4 routed dirty-tree/non-git dead weight back to the Step 3
interview, which has already run by then. Now a follow-up
AskUserQuestion, with Step 3 as the ideal earlier surfacing point.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
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