Pre‑Change Complexity Mapping with CXCAP
说明与用途
CXCAP 是一个本地静态分析 CLI,帮助开发者在 AI 代理进行更改前映射仓库复杂度,揭示热点和依赖,防止隐藏技术债务。
问题
AI coding agents often pass tests but can silently increase repository complexity, making future changes harder.
结果
CXCAP provides deterministic, local insight into repository complexity, helping developers avoid hidden debt that AI agents can introduce.
工作流
- 1. Run
cxcap audit .to map overall complexity and hotspots. - 2. Run
cxcap audit . --intent "<task description>"to discover likely touchpoints for a specific change. - 3. Run
cxcap audit . --focus <path>to see how a target file or component is connected to the rest of the repo. - 4. Review the verdict (LOW/MODERATE/HIGH/SEVERE) and decide whether to proceed, refactor, or add tests.
- 5. If using an AI agent, feed the JSON report (
--json) as structured evidence before generating code.
证据
cxcap audit . --intent "change currency rounding" returned 3 likely touchpoints and a reasoning surface of 15 files across 5 components.
cxcap audit . --focus core/money.py showed that one file is imported by 23 outside files and reaches 19 further files transitively – 42 files exposed.
Historical --intent validation on 31 completed changes across 7 repositories scored Recall@10 0.70 and MRR 0.47.
- 记录日期: 2026-09-22T15:15:43.772Z