complexity-audit SKILL.md skillA
complexity-audit from lixiuxiu559/agentforge is an agent skill: a SKILL.md folder an AI agent loads when a task calls for it.
mdr add lixiuxiu559/agentforge/complexity-audit@git:20260928.1f1d004Pins git:20260928.1f1d004 in mdr.lock. Pin the fingerprint instead.
- Audit grade
- A, 17 of 17 checks passed
- Kind
- SKILL.md skill
- Repository
- lixiuxiu559/agentforge
- Path
skills/complexity-audit/SKILL.md- Versions recorded
- 3
- Latest version
- git:20260928.1f1d004, committed Sep 28, 2026
- First version recorded
- Sep 23, 2026
- Size
- 3,712 bytes
- Repository stars
- 4
- License
- MIT
代码复杂度风险审计能力。当需要评估函数是否难以安全修改、分析复杂度与测试覆盖率、定位高 CRAP 值方法,或执行 Java、Python、Go、JavaScript、TypeScript 复杂度体检时使用。该能力只生成审计报告,不修改代码。.
Collected from public GitHub. Every version is saved exactly as it was and never changes. Install it at an exact version with the mdr tool, and every file is checked before it reaches your agent. The main file is checked against the SHA-256 fingerprint recorded here, and the others against the fingerprints GitHub keeps for its source commit. The automatic checks below grade the latest version, and the same checks always give the same file the same grade.
What the file says
# 代码复杂度风险审计 ## 目标 定位**复杂度高且测试保护不足**的函数或方法,帮助主 Agent 决定: - 应该拆分函数降低复杂度 - 应该补充测试提高覆盖率 - 还是当前风险可以接受 本技能不负责修改代码。修改由实施子任务执行。 ## 委派 需要独立上下文时,用宿主通用子 agent 工具实际派发。传入目标项目的绝对路径、范围/基线、约束、所需技能资源的绝对路径和交付要求(资源不可读时附必要方法);子 agent 只做分配的任务,回报证据、完成状态与未验证项。仅在任务及文件/工具产物互不冲突时并行;无派发能力时自行执行并说明。 ## 指标说明 ### CRAP 当能拿到函数级复杂度和函数级覆盖率时,使用: ```text CRAP(m) = complexity(m)² × (1 - coverage(m))³ + complexity(m) ``` 默认阈值为 `30`。CRAP 不是单纯的复杂度排序:复杂但测试充分的方法,风险可能低于复杂度中等但没有测试保护的方法。 ### 无法计算完整 CRAP 时 不同语言的覆盖率工具粒度不同。必须明确区分: | 结果等级 | 含义 | |---|---| | `full-crap` | 函数级复杂度 + 函数级覆盖率都可匹配 | | `complexity-only` | 只有复杂度,不能伪造 CRAP | | `file-level-risk` | 只有文件级覆盖率,只能做近似风险排序 | | `unavailable` | 缺少工具、报告或项目配置,停止并报告 | 如果只能退化分析,报告中必须写清楚实际等级。 ## 支持矩阵 | 语言 | 复杂度来源 | 覆盖率来源 | 当前能力 | 适配文档 | |---|---|---|---|---| | Java | JaCoCo complexity | JaCoCo XML | `full-crap` | `references/java-jacoco.md` | | Python | radon / xenon | coverage.py | 默认 `file-level-risk` | `references/python-radon-coverage.md` | | Go | gocyclo / gocognit | `go test -coverprofile` + `go tool cover -func` | `full-crap` 或近似 | `references/go-complexity-coverage.md` | …
Read the whole file at its exact version.
How to install
mdr add lixiuxiu559/agentforge/complexity-audit@sha256:d9f3d72ec2b59b18The line at the top of this page pins the label git:20260928.1f1d004, which is what most people want. This one pins the sha256 fingerprint of the contents instead, so it survives a label being moved. Either way the exact version is written to mdr.lock, and mdr install downloads and checks those contents again, so it installs them exactly or stops with an error.
[](https://markdownregistry.com/a/art_r4isyl4ydwformcz)
2 badge image fetches in 30 days. What the badge shows.
Versions
The registry has recorded 3 versions of this file, between Sep 23, 2026 and Sep 28, 2026, about one every 3 days.
| version | committed | commit | size | audit | |
|---|---|---|---|---|---|
| git:20260928.1f1d004 latest | 2026-09-28 | 1f1d004 | 3,712 B | A | view · diff |
| git:20260923.229dd5d | 2026-09-23 | 229dd5d | 4,869 B | A | view · diff |
| git:20260923.e5d9c6e | 2026-09-23 | e5d9c6e | 3,393 B | A | view |
Audit of the latest version
- pass: Frontmatter block present
- pass: Frontmatter declares a name
- pass: Frontmatter declares a description
- pass: Size between 200 bytes and 200 KB (3712 bytes)
- pass: No zero-width or bidi control characters
- pass: No instruction hidden inside an HTML comment
- pass: No link to an exfiltration or paste host
- pass: No credential-shaped string
- pass: No instruction to send local credentials anywhere
- pass: No text hidden with inline styles
- pass: No prompt-injection phrasing
- pass: No curl or wget piped into a shell
- pass: No recursive delete of root, home or parent
- pass: No instruction to read or print local credentials
- pass: No base64 blob over 200 characters
- pass: No link to a raw IP address
- pass: No script tag
Source
lixiuxiu559/agentforge · 4 stars · license MIT · pushed 2026-10-31 · branch main
API
GET https://markdownregistry.com/api/v1/artifacts/art_r4isyl4ydwformcz GET https://markdownregistry.com/api/v1/resolve?ref=lixiuxiu559/agentforge/complexity-audit GET https://markdownregistry.com/api/v1/blob/d9f3d72ec2b59b1883211b0fe27fdf0f29f1c2ec03ecf59bf8eeb6020198ca80
Your AI assistant does the legwork. You hear about the deals worth your word. Hand yours the standing instructions at modelranch.com and it joins the network that reads files like this one.
Guides: the SKILL.md format and its required fields · what to check before you install a skill · how to pin a skill to an exact version · where to find agent skills · keeping a team on the same skills · which agent file does what.