CodeDelta MCP server — lets AI agents (Claude Code, Cursor, etc.) call the real CodeDelta engine instead of improvising their own churn scripts. Speaks the Model Context Protocol over stdio: newline-delimited JSON-RPC 2.0.
CodeDelta MCP defines 3 tools with complete input schemas and descriptions. Tool names follow verb_noun convention (churn_scan, agent_scan, ai_audit). Descriptions are substantive (150-250 chars) and explain WHEN to use each tool. However, output schemas are not formally documented, responses are described narratively rather than as structured JSON Schema. Parameters lack granular type constraints (e.g., threshold is integer but no min/max bounds). Error handling returns error objects but lacks recovery guidance. No tool annotations (readOnlyHint, destructiveHint, idempotentHint) despite all tools being read-only operations.
Inventory AI agent usage in a codebase: files that import AI SDKs or run agents (with risk ratings and an SDK inventory), plus documentary git-history evidence of agent-signed commits (Co-Authored-By trailers, bot accounts — Claude Code, Copilot, Cursor, Aider and others). Use for questions like 'does this code use AI?' or 'how much of this repo was written by agents?'
Scan source files for characteristics associated with AI-generated code (heuristics + per-language ML models). Returns per-file risk ratings (HIGH/ELEVATED/NORMAL) and an overall AI%. Results are pointers for human review, not verdicts.
Measure code churn with the CodeDelta engine — deterministic, reproducible numbers (SLOC/LLOC changed, deleted, added, replacement churn) plus HTML reports. Compare two directories, or two git refs of a repository (tags, branches, hashes). Use this instead of improvising diff scripts when the user asks how much code changed.
Output schemas not formally documented. Tool responses are described narratively (e.g., 'returns totals, interpretation, reports') but lack JSON Schema definitions. LLMs cannot reliably extract fields or plan downstream operations without explicit output structure.
No tool annotations (readOnlyHint, destructiveHint, idempotentHint). All three tools are read-only operations but lack explicit readOnlyHint annotation. This prevents agents from optimizing retry logic and understanding safety guarantees.
Parameter constraints incomplete. 'threshold' parameter (ai_audit) is integer but lacks min/max bounds. 'git_range' format is described in prose ('v1.7..v1.8') but not enforced via regex pattern. LLMs may pass invalid values.
| Scored | Grade | Overall | Spec posture | Rubric |
|---|---|---|---|---|
| 2026-09-23 | C | 69 | 2026-07-28+ | v2 |
Error responses lack recovery guidance. Errors return 'error' field with message but do not suggest next steps (e.g., 'engine binary not found, ensure codedelta is installed in the same directory'). LLMs cannot self-correct.
Mutually exclusive parameters not documented. churn_scan accepts either (old_dir + new_dir) OR git_range, but the schema does not declare this constraint. LLMs may pass both or neither, causing ambiguous failures.