health-check

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

/health-check — 8-Dimension Project Assessment

/health-check — 八维度项目评估

What

功能说明

Runs a data-driven health assessment across 8 dimensions, each graded A-F with the specific data points that produced the grade, and rolls them into a GPA. Gut feeling is not a grade: every dimension uses MCP tools or CLI commands, and every grade below A comes with specific, prioritized, effort-estimated fixes — "add test classes for OrderService, PaymentProcessor, ShippingCalculator" is actionable; "improve test coverage" is not.
This skill owns the canonical grading system for the kit. The full rubrics, GPA scale, and report template live in
references/grading-rubric.md
— load that file when running an assessment.
Tone is diagnostic, not punitive: a C grade is an improvement path, not a failure.
基于数据驱动对8个维度进行健康评估,每个维度采用A-F评级,并附上生成该评级的具体数据点,最终汇总为GPA(平均绩点)。主观感受不能作为评级依据:每个维度均使用MCP工具或CLI命令进行评估,所有低于A的评级都会附带具体、按优先级排序且估算了工作量的修复建议——例如“为OrderService、PaymentProcessor、ShippingCalculator添加测试类”是可执行的,而“提高测试覆盖率”则不是。
此技能拥有工具包的标准评级体系。完整的评分细则、GPA换算标准和报告模板存放在
references/grading-rubric.md
中——执行评估时需加载该文件。
语气侧重诊断而非指责:C级代表改进方向,而非失败。

When

适用场景

  • Onboarding to an unfamiliar or new project — set the baseline
  • "How healthy is this?", "grade this project", "codebase review", "report card"
  • Pre-release quality gate, or monthly/quarterly maintenance review
  • After a cleanup sprint (
    /de-sloppify
    ) — re-grade to show progress
  • Tech-debt prioritization — lowest grades get the next sprint's attention
  • 接手陌生或新项目时——建立基准线
  • 提出“How healthy is this?”、“grade this project”、“codebase review”、“report card”等需求时
  • 发布前质量检查,或月度/季度维护评审
  • 完成清理迭代(
    /de-sloppify
    )后——重新评级以展示进展
  • 技术债务优先级排序——评级最低的维度获得下一轮迭代的关注

How

操作步骤

Step 1: Choose Scope

步骤1:选择评估范围

ScenarioDimensions
Full assessment (onboarding, pre-release, monthly review)All 8
Quick health (mid-sprint checkpoint, before a demo, after a merge)1-4 only
After major refactor1 (Build), 3 (Architecture), 4 (Tests)
Post-dependency update1 (Build), 7 (Security)
After cleanup sprintRe-grade only the cleaned dimensions
场景评估维度
全面评估(项目接手、发布前、月度评审)全部8个维度
快速健康检查(迭代中期检查、演示前、合并后)仅1-4维度
重大重构后1(构建健康度)、3(架构)、4(测试)
依赖更新后1(构建健康度)、7(安全态势)
清理迭代后仅对已清理的维度重新评级

Step 2: Run the Dimensions

步骤2:执行维度评估

Read
references/grading-rubric.md
for the grade thresholds, then collect data per dimension. For deep code-quality dimensions, delegate to the
code-reviewer
agent with the
code-review
skill.
#DimensionData source
1Build Health
dotnet build --no-restore
— errors + warnings
2Code QualityMCP
detect_antipatterns
— read
summary
, grade high-confidence only
3ArchitectureMCP
get_project_graph
+
detect_circular_dependencies
(projects AND types)
4Test CoverageMCP
get_test_coverage_map
check
applicable
first
(structural, not line coverage)
5Dead CodeMCP
find_dead_code(scope: "solution")
— grade high-confidence; ignore
conventionFiltered
6API SurfaceMCP
get_public_api
+
find_references
— overexposure, return-type consistency
7Security Posture
dotnet list package --vulnerable --include-transitive
+ secrets/auth spot check (deep dive:
/security-scan
)
8DocumentationXML doc coverage on public APIs + README currency
查阅
references/grading-rubric.md
中的评级阈值,然后按维度收集数据。对于深度代码质量维度,委托给带有
code-review
技能的
code-reviewer
agent处理。
序号维度数据来源
1构建健康度
dotnet build --no-restore
— 错误 + 警告
2代码质量MCP
detect_antipatterns
— 仅读取
summary
,仅对高置信度结果评级
3架构MCP
get_project_graph
+
detect_circular_dependencies
(项目及类型层面)
4测试覆盖率MCP
get_test_coverage_map
先检查
applicable
字段
(结构覆盖率,非行覆盖率)
5死代码MCP
find_dead_code(scope: "solution")
— 仅对高置信度结果评级;忽略
conventionFiltered
结果
6API接口面MCP
get_public_api
+
find_references
— 过度暴露问题、返回类型一致性
7安全态势
dotnet list package --vulnerable --include-transitive
+ 密钥/认证抽查(深度扫描:
/security-scan
8文档公共API的XML文档覆盖率 + README时效性

Step 2.5: Triage Gate (before any grade is assigned)

步骤2.5:分级筛选 gate(评级前执行)

Detector output is evidence, not a grade. Pass every finding through this gate first — it is what stops a noisy count becoming a wrong letter.
  1. Read
    summary
    , not the violation list.
    summary.byId
    is complete even when the list is truncated. Never sample a truncated list and extrapolate.
  2. Drop
    suppressed
    .
    Record the count and
    summary.suppressionConfig
    in the report so suppression stays visible.
  3. Set aside
    medium
    .
    These are review items, not grade inputs. Summarise them by category; do not fix or count them.
  4. Grade
    high
    only.
    These are wrong regardless of context.
  5. Check invariants. If a signal contradicts something the target repo's CLAUDE.md documents as deliberate, the invariant wins — verify before grading.
  6. Read before asserting. Never describe a finding you have not opened. If you cannot open all of them, report the ones you did and say so.
Fill in the triage table from
references/grading-rubric.md
as you go. If the table cannot be filled, the dimension is not ready to grade.
检测工具的输出是证据,而非直接评级。所有发现需先通过以下筛选——避免因大量噪声数据导致错误评级。
  1. 读取
    summary
    ,而非违规列表
    。即使列表被截断,
    summary.byId
    仍包含完整信息。切勿对截断列表采样并推断整体情况。
  2. 排除
    suppressed
    。在报告中记录其数量和
    summary.suppressionConfig
    ,以便保留抑制操作的可见性。
  3. 暂存
    medium
    。这些是待评审项,而非评级依据。按类别汇总,无需修复或计数。
  4. 仅对
    high
    项评级
    。此类问题无论上下文均属错误。
  5. 检查不变量。若检测信号与目标仓库CLAUDE.md中记录的 deliberate(有意设计)内容矛盾,以不变量为准——评级前需验证。
  6. 先阅读再断言。切勿描述未查看的发现。若无法查看所有发现,需报告已查看的部分并说明情况。
评估过程中填写
references/grading-rubric.md
中的分级筛选表。若无法填写完整表格,则该维度暂不具备评级条件。

Step 3: Grade and Aggregate

步骤3:评级与汇总

Apply the rubric thresholds exactly — never grade on a curve ("pretty good for a project this size" is how standards erode; 15 warnings is a C regardless of project size). Convert to GPA (A=4.0 … F=0.0), averaging only the dimensions actually graded — a dimension marked "Not assessed" is excluded from the GPA, never scored as an F.
严格应用评分细则阈值——切勿按曲线评级(“对于这个规模的项目已经不错了”会导致标准下降;无论项目规模,15个警告即为C级)。转换为GPA(A=4.0 … F=0.0),仅对实际评级的维度取平均值——标记为“未评估”的维度不计入GPA,也不会按F级计分。

Step 4: Report

步骤4:生成报告

Produce the report card from the template in
references/grading-rubric.md
: grades table with key findings, overall GPA, and priority recommendations — each with named types/files, priority order, and effort estimates. If a previous report exists, append the trend comparison table.
根据
references/grading-rubric.md
中的模板生成评估报告:包含评级表及关键发现、整体GPA、优先级建议——每项建议需指定类型/文件名称、优先级排序和工作量估算。若存在历史报告,需附加趋势对比表。

Example

示例

User: /health-check

Claude: Running full 8-dimension assessment...

| Dimension | Grade | Key Finding |
|-----------|-------|-------------|
| Build Health | A | 0 errors, 2 warnings |
| Code Quality | B | 3 high-confidence findings in 4.2K lines; 31 medium untriaged |
| Architecture | A | Clean direction, 0 cycles |
| Test Coverage | Not assessed | Integration-driven suite — structural metric invalid |
| Dead Code | B | 5 unused methods (79 convention-discovered, not counted) |
| API Surface | B | 2 overexposed service types |
| Security | A | 0 vulnerable packages |
| Documentation | D | 12/30 public APIs documented |

Overall GPA: 3.1 (B) — averaged over 7 graded dimensions.

Triage: 44 AP005 raw → all log-and-rethrow wrappers (medium); 2 AP004 real.

Priority: (1) `SystemSeeder` → `TimeProvider`, ~15 min; (2) XML docs on the 8
endpoint classes, ~1 day; (3) review the 44 catch blocks or suppress by path.
用户: /health-check

Claude: 正在执行全8维度评估...

| 维度 | 评级 | 关键发现 |
|-----------|-------|-------------|
| 构建健康度 | A | 0个错误,2个警告 |
| 代码质量 | B | 4.2K行代码中存在3个高置信度问题;31个中等问题未分级 |
| 架构 | A | 结构清晰,0个循环依赖 |
| 测试覆盖率 | 未评估 | 集成驱动测试套件——结构指标无效 |
| 死代码 | B | 5个未使用方法(79个按规则发现的未计入) |
| API接口面 | B | 2个过度暴露的服务类型 |
| 安全态势 | A | 0个易受攻击的包 |
| 文档 | D | 30个公共API中仅12个有文档 |

整体GPA: 3.1(B级)——基于7个已评级维度计算平均值。

分级筛选结果: 44个原始AP005问题 → 均为日志重抛包装器(中等);2个真实AP004问题。

优先级建议: (1) `SystemSeeder` → `TimeProvider`,约15分钟;(2) 为8个端点类添加XML文档,约1天;(3) 评审44个catch块或按路径抑制。

Related

关联内容

  • references/grading-rubric.md
    — canonical rubrics, GPA scale, report template
  • /de-sloppify
    — cleanup pipeline for the issues a health check surfaces
  • /security-scan
    — deep 6-layer scan behind Dimension 7
  • /code-review
    — per-change review (this skill grades the whole project)
  • /verify
    — pass/fail pipeline for a change set, not a graded assessment
  • references/grading-rubric.md
    — 标准评分细则、GPA换算标准、报告模板
  • /de-sloppify
    — 针对健康检查发现问题的清理流水线
  • /security-scan
    — 维度7背后的6层深度扫描
  • /code-review
    — 针对代码变更的评审(本技能针对整个项目评级)
  • /verify
    — 针对变更集的通过/失败检查,非评级类评估