migrate-aiboarding
Skill2 starsChanged 3 months agoMITView on GitHub
Use when a repo has a legacy AIBOARDING.md (v1 layout) and should move to the standard AGENTS.md + CLAUDE.md layout with the .aiboarding/state.json sidecar. One-shot, preview-first migration that preserves the existing onboarding content and rewires the hooks.
In this repository31 other files it gives its agents.
- AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- cutting-a-releaseSkill
- more-with-lessSkill
- openspec-apply-changeSkill
- openspec-archive-changeSkill
- openspec-continue-changeSkill
- openspec-exploreSkill
- openspec-ff-changeSkill
- openspec-new-changeSkill
- openspec-onboardSkill
- openspec-proposeSkill
- openspec-sync-specsSkill
- openspec-update-changeSkill
- openspec-verify-changeSkill
- cutting-a-releaseSkill
- openspec-apply-changeSkill
- openspec-archive-changeSkill
- openspec-continue-changeSkill
- openspec-exploreSkill
- openspec-ff-changeSkill
- openspec-new-changeSkill
- openspec-onboardSkill
- openspec-proposeSkill
- openspec-sync-specsSkill
- openspec-update-changeSkill
- openspec-verify-changeSkill
- audit-agent-onboardingSkill
- compress-onboardingSkill
- create-agent-onboardingSkill
- update-agent-onboardingSkill
The file
We split this skill into the rules it gives an agent
10 rules. About 0 are common, 2 are distinctive, and 8 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈2
Distinctive · estimate
This author's own choices. Worth a look.
8
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 19
Read the AIBOARDING.md frontmatter (aiboarding_version, generated, last_synced_commit).
- Very specific: line 44
Follow create-agent-onboarding Phase 6: CLAUDE.md (@AGENTS.md + fenced Claude-notes block), state.json, config.json, …
- Very specific: line 58
Add the SubagentStart and InstructionsLoaded entries from the template.
- Very specific: line 59
Delete <repo>/.aiboarding/hooks/pre-task and <repo>/.aiboarding/hooks/post-commit.
- Very specific: line 60
All edits idempotent: match aiboarding entries by command containing .aiboarding/hooks/run-hook.cmd.
- Distinctive: line 64
Ask the user to choose (default: archive):
- Very specific: line 68
Keep as legacy: leave AIBOARDING.md in place and prepend a deprecation banner via inject-fenced AIBOARDING.md deprecation <banner-file> …
- Very specific: line 72
Never delete AIBOARDING.md outright unless the user explicitly asks.
- Distinctive: line 75
Before writing ANYTHING, present the full migration plan in one preview: every file to be created, modified (with the settings diff), …
- Very specific: line 80
Run create-agent-onboarding's Phase 7 validation gate, then audit-agent-onboarding if available.
≈ “Common” is an estimate: at least 1 in 5 of the 213,897 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Migrating AIBOARDING.md → AGENTS.md + CLAUDE.md
One-shot migration from the v1 custom-injection layout to the standard-files
layout. The onboarding knowledge in AIBOARDING.md is an investment - carry it
over; never regenerate from scratch and never delete anything without approval.
Announce at start: "Using migrate-aiboarding to move this repo to the AGENTS.md layout."
Precondition: AIBOARDING.md exists at the repo root. If it does not, stop and
suggest create-agent-onboarding. If AGENTS.md also already exists, stop and ask
the user which file is authoritative before writing anything.
Step 1: Carry over state
Read the AIBOARDING.md frontmatter (aiboarding_version, generated,
last_synced_commit). These seed .aiboarding/state.json:
aiboarding_version: 2generated: today's datelast_synced_commit: carried over verbatim (empty stays empty - the repair semantics of an empty pointer are preserved).
Step 2: Map the body
Map the three v1 H1 sections onto the v2 schema (see create-agent-onboarding's Shared contracts for the exact section list and order):
| v1 source | v2 target sections |
# 1. Engineering Basics | Stack and Runtime, Build, Test, Run, Architecture Map |
# 2. Domain & Business Logic | Project Purpose, Domain Model |
# 3. AI-Specific Context | Agent Guardrails, Known Failure Modes |
Preserve the compressed density of the source text; split it, don't rewrite it. Backtick-quote any command, identifier, path, or error string that isn't already.
Two v2 sections have no v1 source: Verification Before Completion and
Escalation - Ask the User When. Run a short, scoped grilling pass (the
one-question-at-a-time style from create-agent-onboarding) ONLY for these gaps.
Step 3: Generate the wrapper and lifecycle files
Follow create-agent-onboarding Phase 6: CLAUDE.md (@AGENTS.md + fenced
Claude-notes block), state.json, config.json, .aiboarding/.gitignore, the six
hook files, and its complete current tool set including write-evidence.
Repo-local hook/settings steps are Claude Code-only. Codex plugin hooks are native,
optional, and require /hooks trust review; standalone skills use manual
update-agent-onboarding after meaningful commits.
Step 4: Rewire hooks and settings (Claude Code runtimes)
In <repo>/.claude/settings.json:
- Replace the
SessionStartfull-injection entry with the current template's entry (the modernsession-startis a fallback warner, not an injector). - Delete the
PreToolUse[Task]entry (pre-taskis retired -SubagentStartis native now). - Replace the
PostToolUseentry so it dispatchesdrift-check(notpost-commit). - Add the
SubagentStartandInstructionsLoadedentries from the template. Delete<repo>/.aiboarding/hooks/pre-taskand<repo>/.aiboarding/hooks/post-commit. All edits idempotent: match aiboarding entries bycommandcontaining.aiboarding/hooks/run-hook.cmd; never duplicate; leave non-aiboarding hooks alone.
Step 5: Retire the legacy document
Ask the user to choose (default: archive):
- Archive (default): move
AIBOARDING.mdtodocs/archive/AIBOARDING.mdunchanged. Git history preserves it either way; nothing at the root keeps stale onboarding discoverable by tools. - Keep as legacy: leave
AIBOARDING.mdin place and prepend a deprecation banner viainject-fenced AIBOARDING.md deprecation <banner-file>pointing toAGENTS.md. The drift hook keeps honoring the legacy layout only whenstate.jsonis absent, so with both present the sidecar wins. Never deleteAIBOARDING.mdoutright unless the user explicitly asks.
Step 6: Single approval gate, then write
Before writing ANYTHING, present the full migration plan in one preview: every file to be created, modified (with the settings diff), moved, or deleted. One approval covers the whole batch; a rejection means nothing was touched.
Step 7: Exit check
Run create-agent-onboarding's Phase 7 validation gate, then audit-agent-onboarding
if available. Report the file-by-file outcome, and remind the user to commit the new
layout (the drift hook stays silent for onboarding-only commit ranges).
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

