Metaproject protocol for migrating the state infrastructure of an existing project to the Metaproject standard.
This is not a mechanical script — it is a protocol of analysis and conversation. The migration may take several sessions.
The standard separates two spaces with fixed absolute paths:
| Space | Path | Contents |
|---|---|---|
| State | /home/claude/state/ |
Continuity infrastructure: handoffs, conventions, skills, project map, to-dos. Travels in a zip that the user uploads at the start of each session. |
| Project | /home/claude/project/ |
The project's own material — whatever the project is made of. Either a zip shipped alongside state (standalone), or kept at a source hosted elsewhere — a repository to clone, a zip to download — and obtained when the session needs it (external). |
This separation is key for two reasons:
In many existing projects, this separation does not exist — state (if any) is mixed with the project, scattered across several documents, or lives only in Claude's project Instructions. The goal of the migration is to extract or create that state layer as an independent space.
The standard defines this state structure:
state/
├── handoff.md — what's been done, what's left
├── setup.md — introduction, paths, state files,
│ what to read on startup, project
│ setup, session closing protocol
├── router.md — skill router (only points, never explains)
├── agents.md — map of the project's material
├── conventions.md — working language and project conventions
├── todo.md — to-dos ordered by priority
├── closing/
│ └── readme.md — startup file, handed over at each session
├── handoffs/
│ └── handoff-*.md — history (never deleted)
└── skills/
├── core/ — skills about the metaproject itself
│ (distributed, synchronised by `update`)
├── personal/ — the project's own skills
│ (never travelled, never synchronised)
├── *.md — imported skills (from external collections)
└── subdir/ — imported skills with a subrouter
Note on skills: the skills/ folder
contains the full collection of available skills for a project. What
determines which are active is router.md: a skill
is active if it has a row in the router table, inactive if it
doesn't.
The three layers of skills/ have different origins and
lifecycles:
skills/core/ — skills about the metaproject's own
processes (how to maintain the todo, how to write handoffs, etc.). These
are distributed with Metaproject and synchronised by
update.skills/*.md and subdirectories at the root — skills
imported from external collections (published sets of skills on some
subject, maintained elsewhere). Each has a row in the router's
Imported section, whose Source column names
its collection; update synchronises them against it.
Metaproject itself does not ship domain skills.skills/personal/ — the project's own skills, never
travelled from Metaproject and never synchronised back. This is the
space for anything project-local.The reference templates are in templates/ within
Metaproject.
Ask the user what language they want to work in (English, Spanish, Catalan, etc.). Default is English — if the user doesn't specify, use English. From this point on, conduct the entire interaction in that language.
Look for the project's state transfer conventions. They may be anywhere:
For each piece of information you find, note:
Also identify the project hosting:
Establish the project slug: a short prefix
(lowercase, no spaces) that will be used in zip filenames (e.g.
yaml-state-20260409-v3.zip). Propose one derived from the
project name and let the user confirm or change it.
Also check whether there are project files (the
Files/Knowledge section of the Claude project). These files are mounted
at /mnt/project/ — list their contents. If there are files,
present them to the user and propose for each one whether it should go
into state (skills, conventions, references), project (the project's own
material), or be discarded. The goal is to leave the Files section
empty, if at all possible: everything that matters should travel in the
zips, where it is versioned and under control. If
/mnt/project/ is empty, no need to mention it.
If the project already has skills, classify each one: does it come
from an external collection (then it is an imported skill, and its
collection is its Source), or is it the project's own
(then it goes to skills/personal/)?
Also look for information that has no equivalent in the standard (such as release notes, decision logs, or any project-specific artefact). Do not discard it — it may make sense to keep it, integrate it, or drop it, but that is the user's call.
Present the user with a report containing:
The user reviews the proposal. They may:
Do not execute anything without the user's explicit agreement.
Apply the agreed changes. After each change:
Generate closing/readme.md from
templates/closing/readme.md as soon as
setup.md exists (for an external project, remove from it
everything about the project zip: the sentence about it, and every line
of the guard that handles $P).
When done (or at the end of each session if the migration spans
multiple sessions), apply the session closing protocol described in the
setup.md that has been generated or migrated (continuity
check, archiving by copy, new handoff, packaging, and the startup file
delivered loose). The check of handoffs in the outgoing zip needs an
incoming state zip in the standard format; in the first session of a
migration there is none, and the check is skipped.
When the migration is complete:
closing/readme.md exists (see Phase 5), and
tell the user how sessions start from now on: upload the zip(s)
and that readme.md, loose, at the start of
each session. Then ask them to remove every startup instruction
from the Claude project instructions (unzipping, reading
setup): some orchestrators reinject them on every turn, and a reinjected
unzip overwrites the session's work. Recommend instead the
harmless line that points to the startup file; see
create.md (step 5) for the wording.setup.md contains the version marker for
the current Metaproject standard (line
*Metaproject standard: vN.* near the top). The templates
in templates/ already carry the current version, so if
setup.md was generated from them this is automatic; if it
was hand-assembled, add the marker.