CodeClone
Structural change control and code-health analysis for AI-assisted Python development
- Pricing
- Open source
- Platforms
- CLI, self-hosted
- Runs
- Locally
- Version
- 2.0.3
- Listing updated
- 2 days ago
About CodeClone
CodeClone is an open-source MCP server for developer tools. It runs locally on your machine and is started by your AI client.
Most review tools start after a patch exists. CodeClone starts earlier: an agent declares an intent, the tool maps its structural blast radius and an explicit edit boundary, and afterwards compares the real patch with that scope and verifies for regressions. It leaves an audit trail and says it never rewrites source or asks an LLM whether a change is safe; findings come from deterministic repository facts.
The base analysis report covers clones, complexity, coupling, cohesion, dead code, a module map, API inventory and coverage joins, with baselines that separate accepted legacy debt from new regressions. Output goes to the CLI, HTML, JSON, Markdown, SARIF, MCP and GitHub Actions. The documentation lists 38 MCP tools. Alpha 2.1 features add intent control, live call-graph context, local engineering memory and multi-agent conflict handling.
It needs Python 3.10 or newer and runs with no hosted service or account; state is stored locally. Documented clients include Claude Code, Claude Desktop, Cursor, Codex and VS Code.
Install
Run in a terminal
claude mcp add codeclone -- uvx codecloneAdd to claude_desktop_config.json
{
"mcpServers": {
"codeclone": {
"command": "uvx",
"args": [
"codeclone"
]
}
}
}Add to ~/.cursor/mcp.json
{
"mcpServers": {
"codeclone": {
"command": "uvx",
"args": [
"codeclone"
]
}
}
}Add to .vscode/mcp.json
{
"servers": {
"codeclone": {
"type": "stdio",
"command": "uvx",
"args": [
"codeclone"
]
}
}
}Add to ~/.codeium/windsurf/mcp_config.json
{
"mcpServers": {
"codeclone": {
"command": "uvx",
"args": [
"codeclone"
]
}
}
}Add to your client's MCP settings (most use this shape)
{
"mcpServers": {
"codeclone": {
"command": "uvx",
"args": [
"codeclone"
]
}
}
}What it does
- Intent-first editing
- Declares scope before edits and verifies the patch stays inside it (2.1 alpha).
- Structural analysis
- Reports clones, complexity, coupling, cohesion, dead code and API inventory.
- Baseline-aware gates
- Separates accepted legacy debt from regressions in the current change.
- Many report formats
- Emits HTML, JSON, Markdown and SARIF from one canonical payload.
- Engineering Memory
- Keeps local, evidence-linked decisions and past findings (2.1 alpha).
- Agent coordination
- Handles conflict-safe multi-agent intents and queues (2.1 alpha).
Good for
- Keep an agent's edit inside the files it declared
- Fail CI on new structural regressions only
- Find duplicated code and dead code in a Python project
- Review the blast radius of a refactor
- Share past decisions between agent sessions
Pricing
Open source
Free PyPI package
Prices change. Check orenlab.github.io before you buy.
CodeClone FAQ
Does it use an LLM to judge changes?
No. Findings and gates come from deterministic repository facts.
Do I need an account?
No hosted service or cloud account is needed; analysis state is stored locally.
How do I try it?
Run uvx codeclone@latest . from the repository; Python 3.10 or newer is required.
Which parts are alpha?
The controller, live context, engineering memory and agent coordination sections need the 2.1 prerelease.
Is CodeClone free?
Yes. CodeClone is open source, so you can use and self-host it for free.
How do I add CodeClone to Claude Code?
Run this command in your terminal: claude mcp add codeclone -- uvx codeclone
What are the best alternatives to CodeClone?
The closest alternatives to CodeClone are REA, Codebase Memory, GitHub, Serena MCP: the IDE for your agent and XERJ.
Alternatives to CodeClone

REA
MCP serverCLI and MCP server that lets coding agents reverse engineer apps and binaries
Runs locally- Open source
- 464K GitHub stars
- Developer tools

Codebase Memory
MCP serverLocal MCP server that builds a code knowledge graph for AI coding agents
Runs locally- Open source
- 48.7K GitHub stars
- Knowledge and memory

GitHub
MCP serverOfficial MCP server connecting AI assistants to GitHub repos, issues and workflows
Not checked yet- Remote
- Open source
- 34.5K GitHub stars
- Developer tools

Serena MCP: the IDE for your agent
MCP serverMCP toolkit giving coding agents symbol-level code retrieval and editing
Runs locally- Open source
- 31.5K GitHub stars
- Developer tools

XERJ
MCP serverLocal search engine for AI agents with cited answers over your code and docs
Runs locally- Open source
- 19.2K GitHub stars
- Knowledge and memory

Ouroboros
MCP serverSpec-first layer that pins requirements and verifies results of AI coding agent work
Runs locally- Open source
- 6.4K GitHub stars
- Developer tools