What it does
Legacy Migration is for the migration that has been six months from done for the last two years. You give it a scan of the repository — the files, the legacy constructs detected in each one, line counts and complexity — along with the campaign you are running: Vue 2 to Vue 3, jQuery to React, PHP 7 to 8, or class components to hooks. Instead of a plan in a document, you get the work shaped as a series of pull requests that can each be reviewed and merged on its own. Per-file risk is scored deterministically from line count, complexity and which legacy constructs appear. Those scores drive the batching: files are grouped into PRs of 20 to 40, sized so a reviewer can actually hold one in their head, each carrying its own worst-case risk level. Alongside the PR series comes a progress board — total files, how many remain, and the characterization-test coverage fraction — so a campaign that would otherwise be measured in vibes has a number that moves. The guardrail worth knowing about: every PR containing a critical-risk file is flagged as requiring a behaviour-equivalence test before it merges. Proving equivalence is the entire point of a migration, and merging a mechanical rewrite without it is how migrations quietly break production. `equivalence_test_coverage` reports what fraction of the planned series carries that requirement, which is a useful number to show a sceptical stakeholder. Each step stands alone. `analyze` returns the per-file risk ranking. `plan_pr_series` returns just the batches. `run_full` does the whole thing. Scoring and batching are fully deterministic — the same scan always produces the same plan, and the agent never invents file counts or risk levels. The language model only narrates the root cause, the merge order and where to focus tests, with a template fallback when no model is available. It plans and narrates; it has no repository access and no merge authority. No connectors and no credentials. Built for tech leads and developers running a migration campaign that needs a shape.
Example prompts
- Here is our repo scan — plan the Vue 2 to Vue 3 migration as reviewable PRs
- Which files are the riskiest to migrate first?
- Split this jQuery to React campaign into 30-file pull requests