PATTERN Cited by 1 source
Migration as Agent Skill¶
Pattern¶
Ship migration tooling (source framework → target framework; deprecated API → new API; v1 → v2) as an Agent Skill that runs inside any supported AI coding tool, rather than as a one-tool-specific codemod script or CLI.
Installation + invocation collapse to two verbs:
Forces¶
- Migration tools have historically been language- / tool-specific (jscodeshift, ts-migrate, Rector, Quarkus migration scripts, …).
- AI coding agents have become the developer's primary interface for anything non-mechanical — "migrate this project" is the natural prompt.
- Agent Skills (agentskills.io) provide a cross-tool standard for publishing task-instructional documents at a fixed well-known URL (concepts/agent-skills-discovery).
- Migrations benefit from remediation-aware guidance — "here's why this issue exists; here's the fix" — which an AI skill can do but a codemod script cannot.
Solution shape¶
- Publish an Agent Skill at
<org>/<skill-name>(npm package / GitHub repo). - The skill ships:
- Compatibility-check logic.
- Dependency-install commands.
- Config-generation templates / rules.
- Known-limitations documentation the AI reads before flagging issues.
- User runs
npx skills add <skill>to install. - User prompts the coding tool to migrate.
- The coding tool invokes the skill; the skill does the work in-session.
Canonical application — cloudflare/vinext¶
npx skills add cloudflare/vinext
# in Claude Code / OpenCode / Cursor / Codex / others:
"migrate this project to vinext"
The skill:
- Checks compat with vinext's 94 % API coverage.
- Installs deps.
- Generates vinext + Worker config.
- Starts dev server.
- Flags anything needing manual attention based on vinext's known limitations.
Consequences¶
- Cross-tool by construction — works in every tool that supports Agent Skills; user doesn't pick a specific tool's codemod flavour.
- Explainable — when the skill flags a migration issue, it can explain the why with prose that the AI can then reason about with the user.
- Updatable like a package —
npx skillsrefresh. - Single-prompt UX — user says "migrate" once.
- Requires Agent Skills adoption — limited to tools supporting the standard.
- Dependency on the underlying AI model's capability to apply the skill competently.
Seen in¶
- sources/2026-02-24-cloudflare-how-we-rebuilt-nextjs-with-ai-in-one-week
— canonical wiki instance. Cloudflare ships
cloudflare/vinextwith the vinext launch as the blessed migration path from Next.js → vinext.
Related¶
- systems/agent-skills — the underlying standard.
- systems/vinext-agent-skill — the canonical instance.
- systems/vinext — the migration target.
- systems/claude-code / systems/opencode / systems/cursor / systems/codex-cli — supported coding-tool hosts.
- concepts/agent-skills-discovery — the discovery primitive.