unlegacy-cli
Installable CLI for connecting local coding agents to Unlegacy MCP.
Unlegacy generates repository documentation, API references, knowledge graph data, and Vault investigation docs in the platform. This CLI configures external coding agents so they can consume that MCP surface.
Install
Published package:
uv tool install unlegacy-cli
or:
pip install unlegacy-cli
After install, the command is saved on the user's machine as:
unlegacy --help
From a checkout:
pip install .
or:
uv tool install .
One-shot setup without preinstalling:
uv tool run --from unlegacy-cli unlegacy setup --token mcp_live_xxx --endpoint https://app.unlegacy.ai/ai/mcp
Distribution
Build the package artifacts:
uv build
The build creates dist/unlegacy_cli-<version>.tar.gz and
dist/unlegacy_cli-<version>-py3-none-any.whl. Publish those artifacts to the
Python package index used by Unlegacy clients.
Setup
unlegacy setup
The flow:
- Shows the Unlegacy logo.
- Prompts for the MCP token from the Unlegacy frontend.
- Prompts for the MCP endpoint. Press Enter to use the local app endpoint:
http://localhost:5173/ai/mcp. - Lets the user select supported clients.
- Writes or merges MCP config.
- Installs the packaged Unlegacy and Forge skill bundle.
- Runs
unlegacy doctor.
Non-interactive usage:
UNLEGACY_MCP_TOKEN=mcp_live_xxx \
unlegacy setup --client claude-code --client codex --endpoint https://app.unlegacy.ai/ai/mcp
For local development:
UNLEGACY_MCP_TOKEN=mcp_live_xxx \
unlegacy setup --client claude-code --client codex --endpoint http://localhost:5173/ai/mcp
Supported client values:
claude-codecodexcursorvscode-copilotopencodeall
Commands
unlegacy setup
unlegacy doctor
unlegacy install-skills --client codex
unlegacy status
Bundled skills
unlegacy setup and unlegacy install-skills install one versioned skill bundle:
unlegacy- repository and Vault knowledge retrievalusing-forge- Forge modernization routing and design readinesspreparing-forge-build- complete artifact-only ledger and workspace gateexecuting-forge-build- lifecycle-first, bounded obligation slices and checkpointsdeveloping-forge-obligations- behavior-preserving RED-GREEN-REFACTORdebugging-forge-build- root-cause-first failure investigationreviewing-forge-slices- separate specification and quality reviewsverifying-forge-build- evidence and obligation reconciliationfinishing-forge-build- assembled replacement and cutover verificationusing-forge-subagents- preferred fresh-context execution when supported
The bundle is self-contained; installing the external Superpowers plugin is not
required. Subagents are strongly encouraged on clients that support them, while
the sequential workflow enforces the same gates on every supported client.
The methodology is inspired by obra/superpowers; attribution is packaged in
assets/skills/NOTICE.md.
Forge builds maintain committed coordination state under .forge/, including a
locked manifest, build state, obligation evidence, decisions, and slice reviews.
This state is builder-owned local evidence, not independent Forge certification.
Preparation cannot edit target files: an integrity-checked validator bundled with
the skill reconciles fetched payloads against the authoritative manifest index
and requires a stable digest, all-pending state, safe path boundaries, and an
artifact-only Git diff from the captured preparation base before execution begins.
The CLI is not used during modernization. Its responsibility ends after it installs/updates the skills, configures MCP, and diagnoses bundle integrity. The coding agent performs modernization with the installed skills, Unlegacy MCP, Git, and the target repository's native toolchain.
unlegacy doctor validates every required skill and supporting executable
against the packaged bundle and reports missing, stale, or modified files per
client. Reinstall the bundle with unlegacy install-skills when doctor reports
an integrity issue.
Vault-aware MCP tools
The packaged unlegacy skill now teaches agents how to use both repo-scoped
and Vault-scoped tools.
Repo-scoped tools are still the right starting point for single-repository work:
list_reposrepo_brieflist_docssearch_docsdoc_outlineread_docrepo_infosearchsymbol_contextimpactcypherget_code
Vault-scoped tools are the right starting point for product, migration, or system questions that cross repository boundaries:
list_vaultsvault_brieflist_vault_reposlist_vault_docsread_vault_docsearch_vault_docssearch_repo_kglist_needs_input
Typical Vault flow for an installed coding agent:
- Call
list_vaultsunless the user gave an exact Vault id. - Call
vault_brief(vault_id)to load the Vault summary, member repos, generated docs, missing evidence, and Needs Input. - Use
list_vault_docsandread_vault_docbefore drilling into source. - Use
list_vault_reposto keep follow-up repo reads inside the Vault. - Use
search_repo_kgfor code-graph verification within a Vault member repo. - Use
list_needs_inputbefore presenting cross-repo conclusions that depend on missing docs, API refs, or KG evidence.
unlegacy doctor also validates that the connected MCP endpoint exposes the
required repo and Vault tools.
Development
uv run pytest
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file unlegacy_cli-0.6.0.tar.gz.
File metadata
- Download URL: unlegacy_cli-0.6.0.tar.gz
- Upload date:
- Size: 63.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via:
uv/0.6.11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
2577d7d6bc5346d8dbd5721151220d55616298a4f99471ad1688f4df2e5caaca
|
|
| MD5 |
7cebfa8ed7a86cf5727f2c03a5bec003
|
|
| BLAKE2b-256 |
af1fcab7098ac5f1589cae34ba4ad4395815ebb8fa60737bf7ab1cb93e1d7826
|
File details
Details for the file unlegacy_cli-0.6.0-py3-none-any.whl.
File metadata
- Download URL: unlegacy_cli-0.6.0-py3-none-any.whl
- Upload date:
- Size: 57.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via:
uv/0.6.11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
bd7a6f5bc3583dcd35cbc119b361237111885c4001a08591168d4e1b161357d8
|
|
| MD5 |
37fd0f594b1d8cd5977ed19b08f1bb67
|
|
| BLAKE2b-256 |
b014b5d1ff89865bc39ff0e07da552e5669a78bab52f7f04f274cb5f5d9fa6d7
|