Token导航 LogoToken导航

Agent Skill · 研究检索

code-complexity-audit(代码 complexity 审核)

用于辅助安全审计、权限检查、凭据风险、认证流程和常见漏洞排查。它适合让 Agent 梳理敏感配置、检查依赖风险、分析鉴权逻辑或生成安全复核清单。使用时不能把工具输出直接当最终结论,涉及密钥、令牌、用户数据或生产系统时,应先确认最小权限、脱敏方式和操作边界。

code-complexity-audit 是研究检索类 Agent Skill,可用宿主为 Codex、Claude、Cursor、Gemini CLI,通过GitHub 仓库获取,权限为需要联网;许可证信息还不明确,第三方扫描已通过,按安装量在研究检索类的 73,675 个 Skill 里排第 40,130。

总安装 1,322周安装 49GitHub Stars 公开资料未说明下载 384核验 2026-05-01

安装说明

本站只整理中文说明,不托管安装包,也不代用户安装。
GitHub
许可证
unknown

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:code-complexity-audit(代码 complexity 审核)
来源仓库:https://github.com/nkootstra/skills
仓库路径:skills/code-complexity-audit
安装命令:
npx skills add https://github.com/nkootstra/skills --skill code-complexity-audit
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 npx skills 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

skills.shnpx skills
npx skills add https://github.com/nkootstra/skills --skill code-complexity-audit

这个 Skill 是做什么的

研究检索类 Skill 主要解决「找资料、核对事实、把来源整理清楚」的问题,通常会让助手先检索再总结。

基于《软件设计哲学》理论进行深度设计健康度分析。生成带严重等级分类的发现报告,并关联 git 作者信息。涵盖模块化、抽象合理性、变更成本等维度评估。需预先阅读分析框架与 git 归属规则文档。code-complexity-audit 属于研究检索类 Skill,可作为该场景下的辅助能力补充。

来源仓库内路径:skills/code-complexity-audit

上手步骤

4 步
  1. 1

    确认自己的宿主工具

    公开资料标注支持 Codex、Claude、Cursor、Gemini CLI;先确认自己用的是其中之一,再按对应工具的 Skills 目录放置。

  2. 2

    拿到安装命令

    可以直接复制的命令是 npx skills add https://github.com/nkootstra/skills --skill code-complexity-audit;命令里的占位符换成自己的路径或密钥再执行。

  3. 3

    安装后重启宿主

    命令执行完要完全退出宿主工具再打开,让新装的 Skill 被重新扫描到,否则列表里可能看不到。

  4. 4

    按最小权限试用

    它需要需要联网,先在测试目录或测试账号里跑,确认没问题再放到正式项目。

常见问题

6 条

code-complexity-audit 怎么安装?

在终端执行 npx skills add https://github.com/nkootstra/skills --skill code-complexity-audit。装完完全退出宿主工具再打开,让它重新扫描本地 Skill。

code-complexity-audit 支持哪些 AI 工具?

公开资料标注支持 Codex、Claude、Cursor、Gemini CLI。其他工具只要能读取本地 Skill 目录,一般也能手动放进去,但要自己确认触发方式是否一致。

code-complexity-audit 需要什么权限?

权限级别是需要联网。该 Skill 可能需要联网访问来源站点、仓库或外部 API;具体网络访问范围需要结合源码和 README 复核。

code-complexity-audit 是免费的吗?

公开资料没有标注明确许可证,收费和商用限制都无法确认。正式使用前请到来源仓库核对授权说明。

code-complexity-audit 用的人多吗?

公开数据是累计安装 1,322 次,近一周安装 49 次,下载 384 次。这些数字来自第三方目录统计,只能当作热度参考,不代表质量或安全性。

code-complexity-audit 安全吗?

第三方扫描结果为通过,但这只覆盖已知的静态检查项,不能替代自己读一遍源码和安装命令。

值得选的地方和要先想清楚的地方

值得选的地方

  • 同时适配 4 种工具,换客户端不用重新找替代品。
  • 第三方扫描已通过,常见的高风险行为没有命中。

先想清楚的地方

  • 许可证没有明确标注,能不能商用、能不能再分发都不确定。
  • 第三方目录整理,版本更新和行为细节以来源仓库为准。

适不适合你

更适合

  • 已经在用 Codex,想直接扩展它能力的人。
  • 需要处理研究检索类任务、又不想每次都手写提示词的人。

不太适合

  • 需要明确授权才能用到公司项目里的场景。
  • 需要厂商级技术支持和 SLA 的生产系统。

研究检索类 Skill 对比

6 个同类
Skill总安装GitHub 星权限许可证扫描
find-skills

寻找技能 · Codex、Claude

31,199,81316,486操作浏览器MIT有提醒
self-improving-agent

自我改进 Agent · OpenClaw

16,464,0023,396接触敏感数据MIT-0通过
soultrace

灵魂追踪 · Codex、Claude

7,588,94412需要联网未明确有提醒
self-improving

自我完善 · OpenClaw

6,829,2841,046需要联网MIT-0通过
microsoft-foundry

微软代工厂 · Codex、Claude

6,614,144764调用外部服务未明确有提醒
code-complexity-audit

代码 complexity 审核 · 本页

1,322—需要联网未明确通过

按安装量取同分类前几名;数字来自第三方目录统计,只作热度参考,不代表质量结论。

SKILL.md 原文

Code Complexity Audit

Deep software design analysis based on "A Philosophy of Software Design" by John Ousterhout. Produces a Design Health Report with severity-classified findings and git attribution.

References

Read this file first. Then load references as needed — do not read all at once.

ReferenceRead when...
references/analysis-framework.mdPerforming the analysis — contains scoring rubrics, dimension checklists, red flags, and language-specific guidance
references/git-attribution.mdAttributing findings to authors — contains git blame commands and the attribution workflow

Process

Always follow these 5 steps in order. When explaining the process, use these exact step names — always say "Reconnaissance" and "Sampling" (not synonyms like "exploration", "discovery", "selection", or "file picking"):

  1. Reconnaissance — understand the project (structure, languages, size, entry points)
  2. Sampling — select 15-30 files via git-informed sampling (not random reads). Always use the word "sampling" when describing this step.
  3. Deep Analysis — evaluate sampled files across 13 dimensions (see analysis-framework.md)
  4. Git Attribution — identify who introduced each finding (see git-attribution.md)
  5. Report — produce the Design Health Report

Step 1: Reconnaissance

  • List project structure (2-3 levels deep)
  • Identify language(s), framework(s), paradigm
  • Count approximate files, modules/classes, lines of code
  • Identify entry points and core modules
  • Check dependency files (package.json, requirements.txt, go.mod, Cargo.toml, etc.)

Step 2: Git-Informed Sampling

When describing this step, always use the word "git" — e.g., "git-informed sampling" or "git log". Do not replace it with "version control history" or "commit history" alone.

Select 15-30 files across three tiers:

TierWhatHow
Always readEntry points, core domain, most-imported filesStatic analysis of imports and project structure
Git-hot filesMost frequently changed in recent history`git log --oneline -100 --name-only \sort \uniq -c \sort -rn \head -20`
Churn + sizeFiles that are both large AND frequently changedCross-reference git-hot list with file size — highest risk for accumulated debt

Also include: public API surfaces, interfaces, error handling paths, tests.

Step 3: Deep Analysis

Read references/analysis-framework.md. Evaluate across 13 dimensions grouped by weight:

Core Design (weight 1.5x):

  1. Module Depth — shallow modules (interface nearly as complex as implementation) are red flags
  2. Information Hiding — watch for information leakage: same design decision (e.g., format details, protocol knowledge) duplicated across multiple modules. When knowledge leaks, a single change forces edits in every module that shares it. Recommend encapsulating leaked knowledge in one place. Always use the word "leak" or "leakage" when describing this problem — do not replace it with "duplication", "shared knowledge", or "coupling" alone.
  3. Abstraction Quality — false abstractions, wrong-level abstractions
  4. Complexity Indicators — change amplification, cognitive load, unknown unknowns

Structural (weight 1.2x): 5. Error Handling 6. Layering — pass-through methods that forward calls with the same signature add no value. Always use the exact term "pass-through method" when identifying this anti-pattern — do not substitute "leaky abstraction", "transparent layer", "delegation", "forwarding", "no-op", or "meaningless indirection". 7. Design Investment 8. Comments & Abstractions 9. Codebase Navigability

Surface (weight 1.0x): 10. Naming & Obviousness 11. Consistency 12. Software Trends Anti-Patterns 13. Performance-Design Relationship

Score each dimension 1-10. See analysis-framework.md for detailed rubrics.

Classify every finding by severity using these exact labels:

  • Critical — actively spreading complexity; blocks safe change; other code depends on it being wrong. Fix first.
  • Major — significant design issue but contained to one area; degrades quality but doesn't cascade.
  • Minor — suboptimal but low impact; fix opportunistically.

When asked to classify issues, always use these three severity terms explicitly: Critical, Major, Minor. Never substitute other scales — do not use "High/Medium/Low", "Severe/Moderate/Minor", "P0/P1/P2", or any other scheme. The only valid labels are Critical, Major, and Minor.

Litmus test — apply to each finding individually:

  • "Does this complexity actively spread to other modules — does other code depend on it?" → Critical. Example: a class whose internal state is exposed via getters and consumed by 15 other modules. If the internals change, all 15 break.
  • "Is this contained to one area but still a significant design problem?" → Major. Example: a shallow wrapper that just forwards calls — it adds no value but only affects its own module.
  • "Is this low impact, unlikely to cause problems?" → Minor. Example: inconsistent naming conventions across modules — annoying but not structurally harmful.

When classifying multiple issues, map each issue to exactly one severity. Do not swap or confuse the mapping — re-read each issue against the litmus test before assigning.

Step 4: Git Attribution

Read references/git-attribution.md. For each finding:

  • Run git blame on the problematic lines
  • If the code was authored within the last 100 commits: record author, commit hash, and date
  • If older: mark as Legacy

Step 5: Produce the Report

# Code Complexity Audit: [Project Name]

## Executive Summary
[2-3 sentence assessment with letter grade A-F]

## Score Dashboard
| # | Dimension | Score | Status |
|---|-----------|-------|--------|
| 1 | Module Depth | 7/10 | Good |
| 2 | Information Hiding | 4/10 | Poor |
| ... | ... | ... | ... |
| | **Weighted Average** | **X.X** | **Grade: B** |

## Findings

Each finding classified by severity:

| Severity | Definition |
|----------|-----------|
| **Critical** | Actively spreading complexity. Blocks safe change. Fix first. |
| **Major** | Significant design issue but contained. Degrades quality. |
| **Minor** | Suboptimal but low impact. Fix opportunistically. |

### Critical
| Dimension | Location | Issue | Attribution |
|-----------|----------|-------|-------------|
| Info Hiding | `src/api.ts:42` | Internal state exposed via getter | @alice (`a1b2c3`, 2025-01-15) |

### Major
[Same table format]

### Minor
[Same table format]

## Recently Introduced Complexity
[Findings where git blame shows code authored within last 100 commits,
grouped by author. This section helps teams address the freshest debt first.
Attribution is for context, not blame.]

## Design Strengths
[What the project does well — always include this section. Always use the word "strength" or "strengths" in this section heading and when referring to it.]

## Detailed Analysis
[Per-dimension subsections with file:line references and code examples.
Use the project's own code in before/after examples.]

## Recommendations
[Prioritized by impact-to-effort ratio. For each: what to fix, estimated effort,
and which modules it unblocks. Address critical findings first.]

## Appendix: Files Reviewed
[All files examined with selection rationale]

Adapting to Project Size

Always adapt the process to project size. A small project does not need the full heavyweight process.

SizeStrategy
Small (<20 files)This is a small project. Read everything — no sampling needed. Skip Step 2 (Sampling) and Step 4 (Git Attribution). Produce a concise report (2-3 pages max). Still evaluate all 13 dimensions but keep analysis brief.
Medium (20-200 files)Full sampling strategy (15-30 files). Focus on core modules. Standard report.
Large (200+ files)Heavy sampling. Focus on architecture and public APIs. Consider one subsystem deeply vs. everything shallowly.

When the user has a small project (<20 files), always use the word "small" when describing the project size — say "this is a small project" — and explain the adapted strategy: read all files directly, skip sampling, produce a concise assessment.

Tone

  • Constructive — help, not tear down. Always include strengths.
  • Specific — reference files, classes, methods, line numbers.
  • Actionable — before/after examples using the project's own code.
  • Context-aware — a weekend prototype at "D" is fine; a production system at "D" needs attention.
  • Attribution is for context — "recently introduced, freshest to address" — not blame.
  • Use precise design vocabulary — never vague evaluative phrases. When identifying problems, name the specific red flag (e.g., "shallow module", "information leakage", "pass-through method"). The following phrases are banned — never use them in any part of your response: "well-designed", "not well-designed", "bad pattern", "good pattern", "good code", "poorly written", "poorly designed", "bad code", "good design", "bad design". Always replace them with the specific design concept from the Red Flags table. Say "this is a shallow module" not "this is not well-designed." Say "this exhibits information leakage" not "this is a bad pattern." Every finding must reference a named design concept. Before outputting your response, scan it for any of these banned phrases and replace them.

平台分布

Codex

37.93%
按下载量换算146

Claude

32.58%
按下载量换算125

Cursor

18.22%
按下载量换算70

Gemini CLI

8.37%
按下载量换算32

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

通过

权限和风险

需要联网

该 Skill 可能需要联网访问来源站点、仓库或外部 API;具体网络访问范围需要结合源码和 README 复核。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。目前只有一个公开来源,建议同时核对源仓库。

继续浏览同类 Skills