Refresh the anchor-derived marker sections in this project's CLAUDE.md and AGENTS.md by re-fetching the latest anchors, diffing against on-disk content, and applying confirmed changes. Supports --dry-run.
How this skill is triggered — by the user, by Claude, or both
Slash command
/claude-onboarding-agent:anchorsThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
Refresh the marker sections of CLAUDE.md / AGENTS.md that were originally rendered by a setup skill from anchor content.
Refresh the marker sections of CLAUDE.md / AGENTS.md that were originally rendered by a setup skill from anchor content.
This skill is the sole writer of anchor-derived marker sections (section=anchor-<slug> inside CLAUDE.md / AGENTS.md). Other skills — including /upgrade-setup — detect anchor markers but never rewrite them; they delegate any refresh to this skill. The boundary is: /upgrade-setup refreshes plugin-template-derived sections only, and /anchors refreshes anchor-derived sections only. Running /upgrade-setup never mutates anchor bodies, so a user who wants both kinds of refresh runs /upgrade-setup followed by /anchors (or just /anchors if only anchor content needs updating).
Detect language from the user's first message in this invocation and respond in it throughout. All file content written to disk stays in English (repo language rule).
The invocation may contain --dry-run anywhere in the argument string.
dry_run: true. Print diffs but write nothing.dry_run: false.Any other argument is ignored silently.
Read ./.claude/onboarding-meta.json if it exists. Expected shape per skills/_shared/write-meta.md.
setup_type is a recognized slug (one of: coding, data-science, design, knowledge-base, devops, content-voice, office, research, academic-writing, web-development) → set detected_setup: <setup_type>, meta_source: meta-file.setup_type is graphify → print "/anchors has no work to do for a standalone graphify setup — anchor sections only apply to primary setups." and exit cleanly.detected_setup. Any other reply → exit without changes.Read skills/_shared/anchor-mapping.md. Parse the mapping table. Extract the anchor list for detected_setup → anchors_for_setup.
If the list is empty (unmapped setup type): print "No anchors mapped for setup <detected_setup> — nothing to refresh." and exit cleanly.
For each anchor_slug in anchors_for_setup:
For each target file in ["./CLAUDE.md", "./AGENTS.md"]:
skills/_shared/render-anchor-section.md with setup_type: detected_setup, skill_slug: anchors, anchor_slug, target_file, and the embedded fallback snapshot provided at the bottom of this SKILL. Do not write yet — compute the proposed excerpt body only. Capture the protocol's render_freshness output.<!--\s*onboarding-agent:start\s+setup=\S+\s+skill=\S+\s+section=anchor-<anchor_slug>\s*-->. If no match → skip this (target_file, anchor_slug) pair. /anchors only refreshes sections that already exist.{change_id, anchor_slug, file, proposed_body, existing_body, render_freshness} entry to proposed_changes.render_freshness is anything other than network or cache, record the pair (anchor_slug, render_freshness) in anchor_freshness_notes (deduplicate across target files).If proposed_changes is empty:
Nothing to refresh — your anchor sections are already up to date.
Update ./.claude/onboarding-meta.json with anchors_refreshed_at: <ISO-8601 UTC timestamp> (unless dry_run) and exit.
Print:
Found <N> anchor section(s) to refresh. Answer y / n / all / skip-rest for each.
For each entry (stable order: by file path, then by anchor_slug):
[<change_id>] <file> · anchor-<anchor_slug>
<unified diff of existing_body → proposed_body, 3 lines of context>
apply? (y/n/all/skip-rest)
Interpret replies: y/yes → accept; n/no → reject; all → accept this and all remaining; skip-rest → reject this and all remaining. Any other reply → re-prompt once, default to n.
After the loop:
Accepted: <A> · Skipped: <S> · Total: <N>
If A == 0 → go to Pass 5 without writing.
If dry_run: true → print Dry-run mode — no files written. and go to Pass 5.
timestamp = <YYYYMMDD-HHMMSS> in local time. For each unique file in accepted changes, mkdir -p ./.claude/backups/<timestamp>/ and copy the current on-disk file preserving relative path.
For each accepted change, rewrite only the body between the existing marker pair to the proposed_body. Never touch bytes outside the markers. If any single file write throws → stop immediately, print:
⚠ Write failed for <file>: <error>. Refresh halted.
Backup of the pre-refresh state is at .claude/backups/<timestamp>/
Do not attempt on-the-fly rollback. The backup is the recovery path.
Read ./.claude/onboarding-meta.json. Set anchors_refreshed_at: <ISO-8601 UTC timestamp>. Leave all other keys unchanged. Write back with 2-space indent.
✓ Anchors <refreshed | dry-run complete>
Summary:
Applied: <A>
Skipped: <S>
Dry-run only: <D>
Backup folder: <./.claude/backups/<timestamp>/ | n/a — nothing applied>
Anchor freshness:
[omit the whole block if anchor_freshness_notes is empty; otherwise one line per unique entry:
Anchor <anchor_slug> served from <render_freshness> — upstream was unreachable or malformed; re-run /anchors once connectivity returns.]
Next:
- Run /checkup to audit the updated setup.
- /anchors is idempotent — safe to re-run any time.
These fallback snapshots are passed to render-anchor-section.md when the network and cache are both unavailable. Each is a minimal shape that parses through Step R2 and Step R3 of the render protocol. They are intentionally short — fallbacks are last-resort.
claude-models---
name: claude-models
description: Minimal embedded fallback
last_updated: 2026-06-12
sources: []
version: 2
---
## Model IDs
| Tier | Model ID | Alias | Input/Output (MTok) |
|--------|-----------------------|---------|---------------------|
| Fable | `claude-fable-5` | `fable` | $10 / $50 |
| Opus | `claude-opus-4-8` | `opus` | $5 / $25 |
| Sonnet | `claude-sonnet-4-6` | `sonnet`| $3 / $15 |
| Haiku | `claude-haiku-4-5-20251001` | `haiku` | $1 / $5 |
## Retiring soon
- `claude-sonnet-4-0` and `claude-opus-4-0` retire 2026-06-15 (imminent)
- `claude-opus-4-1` retires 2026-08-05
## Defaults
- Everyday coding: `claude-sonnet-4-6`
- Deep reasoning: `claude-opus-4-8`
- Maximum capability: `claude-fable-5`
- Fast subagent scans: `claude-haiku-4-5-20251001`
mcp-servers---
name: mcp-servers
description: Minimal embedded fallback
last_updated: 2026-04-21
sources: []
version: 1
---
## Recommended
- `filesystem` — scoped filesystem access
- `git` — git history and diffs
- `github` — issues and PRs
claude-tools---
name: claude-tools
description: Minimal embedded fallback
last_updated: 2026-04-21
sources: []
version: 1
---
## Recommendations
- Keep CLAUDE.md short — point to separate files for detail.
- Use `.claude/settings.json` `permissions.allow` rather than blanket wildcards.
- Hooks handle automation; memory files handle preferences.
subagents---
name: subagents
description: Minimal embedded fallback
last_updated: 2026-04-21
sources: []
version: 1
---
## Recommendations
- Delegate broad exploration (3+ queries) to an Explore subagent.
- Dispatch independent tasks in parallel in a single message.
- Keep subagent prompts self-contained — they have no conversation context.
knowledge-base---
name: knowledge-base
description: Minimal embedded fallback
last_updated: 2026-04-21
sources: []
version: 1
---
## Recommended layout
- PARA-inspired with numeric prefixes: `00_inbox/`, `10_areas/`, `20_resources/`, `30_archive/`.
- Keep daily notes separate from topical notes.
npx claudepluginhub a2ngerer/claude_onboarding_agent --plugin claude-onboarding-agentGuides creation, editing, and verification of skills for AI coding agents using test-driven development with subagent scenarios. Use when authoring or debugging skills.