attributes-collect

v2026.09.24

Collect codebase health attributes as structured JSON. Use when assessing project health before routing to specialized agents via attributes-route.

GitHub
安装命令
npx skhub add laurigates/attributes-collect
Markdown
SKILL.md

/attributes:collect

Collect structured codebase health attributes with severity and remediation actions.

When to Use This Skill

Use this skill when...Use another approach when...
Need structured health assessment before routingQuick health score only (use /health:check)
Want machine-readable attribute JSONHuman-readable report (use /attributes:dashboard)
Planning which agents to invokeAlready know what needs fixing
Comparing health across reposChecking specific component only

Parameters

ParameterDescription
--output <path>Write JSON to file (default: stdout)
--categories <list>Comma-separated categories to check: docs,tests,security,quality,ci

Execution

Perform these checks and output structured JSON.

Step 1: Documentation Attributes

Check for these files and emit attributes:

CheckAttribute IDSeverity
README.md existsmissing-readmehigh
README.md > 200 charsshort-readmelow
CLAUDE.md existsmissing-claude-mdmedium
docs/ directory existsno-docs-directorylow
LICENSE file existsmissing-licenselow

Score: Start at 0, add points per check (max 20).

Step 2: Testing Attributes

CheckAttribute IDSeverity
tests/ or test/ directory existsno-test-directoryhigh
Test config file exists (vitest, jest, pytest, etc.)no-test-configmedium
CI workflow runs testsno-ci-testshigh

Test configs to look for: vitest.config.{ts,js}, jest.config.{js,ts}, pytest.ini, conftest.py, playwright.config.ts

Step 3: Security Attributes

CheckAttribute IDSeverity
.gitignore existsmissing-gitignorehigh
.env file NOT committedenv-file-committedcritical
Pre-commit hooks configuredno-pre-commit-hooksmedium
Security scanning in CIno-security-scanninghigh
Dependabot configuredno-dependabotlow

Step 4: Code Quality Attributes

CheckAttribute IDSeverity
Linter configured (eslint, biome, ruff)no-linter-configuredmedium
Formatter configured (prettier, biome, ruff)no-formattermedium
Type checking (tsconfig, pyright, mypy)no-type-checkinglow

Step 5: CI/CD Attributes

CheckAttribute IDSeverity
CI workflows existno-ci-workflowshigh
Workflows dir has filesempty-workflows-dirmedium

Step 6: Output

Output JSON matching this schema:

{
  "version": "1",
  "repo": "<path>",
  "timestamp": "<ISO 8601>",
  "attributes": [
    {
      "id": "missing-readme",
      "category": "docs",
      "severity": "high",
      "description": "Missing README.md",
      "source": "attributes-collect",
      "actions": [
        {"type": "agent", "target": "docs", "args": "create README.md", "auto_fixable": true}
      ]
    }
  ],
  "scores": {
    "overall": 72,
    "grade": "C",
    "max_score": 100,
    "categories": {"docs": 15, "tests": 12, "security": 8, "quality": 17, "ci": 20}
  }
}

If --output is specified, write the JSON to that file.

Agentic Optimizations

ContextCommand
Full attribute collection/attributes:collect
Save to file/attributes:collect --output .claude/attributes.json
Specific categories/attributes:collect --categories security,tests
Check README existstest -f README.md && echo exists || echo missing
Check test dirtest -d tests || test -d test && echo exists || echo missing
Count README charswc -c < README.md 2>/dev/null || echo 0
发现
标签

此技能尚未发布标签。

版本
最新版本元数据

版本

v2026.09.24

发布时间

2026年9月24日

分类

未分类

许可证

MIT

源路径

codebase-attributes-plugin/skills/attributes-collect

默认分支

main

最新提交

1668324

Tree SHA

b2d4cc3