正在自动登录…
streaxrxoutlook-coder/ code-master
code-master 是一个本地代码情报分析工具,用于测量代码复杂度、依赖关系、克隆检测和上下文预算,适用于开发者对代码库进行维护和审查。它零运行时依赖,Python 3.11+ 标准库即可运行。
AI 中文解读 · 根据仓库描述与 README 生成 · 2026/11/5 20:21:26 · 查看原文
- 累计 Stars
- 60
- 当前热度
- 1 天内 · 小火
- 仓库创建时间
选用指南
AI 根据 README 整理 · 2026/11/5 20:21:26
- 使用方式
通过命令行使用,提供scan、graph、clones、budget、brief等命令。
查看 README 依据
`code-master` exits 0, or 2 when the path does not exist. `NO_COLOR` disables color. `--json` writes schema `code-master.report.v1`. `brief` writes schema `code-master.brief.v1`. ## Commands | command | the question it answers | | --- | --- | | `scan` | Where is the control flow dense? McCabe, nesting, Halstead, maintainability. | | `graph` | Who depends on whom? Tarjan cycles, PageRank hubs, Martin instability. | | `clones` | Which stretches are the same program with the names swapped? | | `budget` | What fits in a context window, and what should be read first? |
- 部署要求
需要 Python 3.11 或更高版本,仅依赖标准库。
查看 README 依据
# code-master 本地、确定性的代码情报. 复杂度、依赖、type-2 克隆、上下文预算. 零运行时依赖, 不出网, 同一棵树得到同一份报告. A local code-intelligence engine. Each number names the paper it comes from, and the report names the cases the scanner does not cover. Python 3.11 or newer. The standard library is the whole runtime. ## Install ```bash pip install -e . code-master scan . ``` `pip install -e ".[dev]"` adds pytest and mypy. CI installs that extra, runs mypy, runs pytest, then runs `code-master scan src`, on Python 3.11, 3.12, and 3.13.
[docs/ALGORITHMS.md](docs/ALGORITHMS.md) is the specification. If that file and the code disagree, the code is wrong. | decision | where | | --- | --- | | A scanner, because an AST for fourteen languages is fourteen parsers to be wrong about. | [ADR 0001](docs/adr/0001-scanner-not-parser.md) | | The standard library only. pytest and mypy are development extras. The token estimate is not a model tokenizer. | [ADR 0002](docs/adr/0002-stdlib-only.md) | | Risk is scaled by the repository under the cursor. Centrality is a separate report. | [ADR 0003](docs/adr/0003-risk-scale-is-the-repo.md) |
- 已知限制
扫描器不是解析器,对某些语言特性存在限制,如Python的match/case、Rust match等计数不精确;JavaScript正则表达式未被词法分析;C++原始字符串不受支持;克隆检测为type-2级别。
查看 README 依据
## Limits These are the boundaries of the 0.1.0 scanner. They are also printed at the bottom of every brief. - Comments and strings do not leak into keyword counts. The scan is still not a parse. - Python `match` and `case` are soft keywords and stay identifiers, so structural pattern matching is under-counted. - A Rust `match` or a Kotlin `when` counts as one decision, not one per arm. - JavaScript regular-expression literals are not lexed. A keyword-shaped ident between slashes can be over-counted. - C++ raw strings (`R"(...)"`) are not supported.
- Ruby `?` and `!` stay on the identifier, so `empty?` is not a ternary. `??` is a decision. `?.` is optional chaining and is not one. Rust's `?` is the try operator and is not a decision. - Ruby and SQL report nesting 0. Their blocks are not brace-reliable. - Clones are type-2. A reordered body is a different program to this detector. - A module suffix that maps to two files is left unresolved, rather than guessed. - Discover skips `.git`, virtualenvs, `node_modules`, dotfiles, lockfiles, binaries, and files over 400 KB, and it stops at 5,000 files. ## Layout ```text
README
正在加载 README…
收录信息
- 仓库创建时间
- 2026/11/5 19:09:44
- 首次达标收录
- 2026/11/5 20:16:56
- 统计更新时间
- 2026/11/5 22:01:59
按创建时长与累计 Stars 判断等级。首次达标收录后,即使未达当前门槛仍保留;累计 Stars 和仓库状态会定期更新。确认只有 README 及辅助文件的仓库会停止公开。
模型评估
值得看加权总分 4.0 / 5
由 Jev 模型根据仓库描述与 README 评估,2026/11/5 20:16:56 生成。评分仅供参考,不是代码、安全或许可证审查;热度等级另按创建时长与累计 Stars 计算。
仓库信息
- 最近推送
- 2026/11/5 19:41:58
- 许可证标识
- MIT
- Fork 数
- 0
- 当前状态
- 未归档
收录记录
按创建时长与累计 Stars 首次收录:小火
首次发现项目