agentleFS
Vimalk0703Vimalk0703/shipworthy/skills/core/project-diagnosis/SKILL.md

project-diagnosis

Skill6 starsChanged 8 months agoMITView on GitHub

Structured gap analysis that identifies what a project is missing — not what's done poorly (that's /audit), but what's absent entirely. Checks for tests, CI, security basics, linting, type safety, deployment readiness, and dependency health. Each finding has a severity and a concrete fix action.

  • Reads credentials

The file

We split this skill into the rules it gives an agent

4 rules. About 0 are common, 2 are distinctive, and 2 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈2

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 2

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Run through each category.

    line 17
  2. Very specific:

    If no gaps found: Project health: All checks passed

    line 73
  3. Very specific:

    When invoked via /diagnose --fix or when the project-doctor agent runs:

    line 111
  4. Distinctive:

    Always ask before fixing: Never silently modify existing files.

    line 114

≈ “Common” is an estimate: at least 1 in 5 of the 213,897 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Project Diagnosis

Purpose

Most projects don't fail because their code is bad — they fail because things are missing. No tests, no CI, no input validation, no error handling, no logging. This skill systematically checks for what's absent and surfaces concrete, actionable findings.

This is NOT a code review. The /audit command reviews code quality. This skill checks project infrastructure completeness.

Diagnosis Checklist

Run through each category. For each check, record: present (pass), absent (finding), or not applicable (skip).

1. Testing Infrastructure

CheckHow to VerifySeverity if Missing
Test directory existsLook for tests/, __tests__/, test/, spec/, or test file patterns (*.test.*, *.spec.*, test_*.py, *_test.go)High
Test runner configuredpackage.json has test script, OR pytest.ini/pyproject.toml has pytest config, OR go test worksHigh
Coverage configured@vitest/coverage-v8, pytest-cov, go test -cover, or equivalent is installedMedium
At least 1 test existsAt least one test file has actual test cases (not just empty files)High

2. CI/CD Configuration

CheckHow to VerifySeverity if Missing
CI config exists.github/workflows/, .gitlab-ci.yml, .circleci/config.yml, Jenkinsfile, .travis.ymlMedium
CI runs testsCI config includes a test stepMedium
CI runs linterCI config includes a lint stepLow

3. Security Basics

CheckHow to VerifySeverity if Missing
.env in .gitignore.gitignore exists and contains .envCritical
No hardcoded secretsQuick scan for patterns: password = ", apiKey = ", secret = ", token = " in source filesCritical
Input validation presentIf API routes exist, check for Zod/Pydantic/validator imports near route handlersHigh
Dependency audit cleannpm audit / pip audit / go vuln shows no critical vulnerabilitiesMedium

4. Code Quality Tools

CheckHow to VerifySeverity if Missing
Linter configuredESLint config (.eslintrc*, eslint.config.*), Ruff config (ruff.toml, pyproject.toml with [tool.ruff]), or golangci-lint configMedium
Formatter configuredPrettier config, Black/Ruff format config, or gofmt (built-in)Low
Type checkingtsconfig.json with strict: true, or mypy/pyright configured, or Go (built-in)Medium

5. Architecture & Documentation

CheckHow to VerifySeverity if Missing
Architecture spec.shipworthy/architecture.md existsMedium
README existsREADME.md in project rootLow
.gitignore exists.gitignore in project rootMedium

6. Deployment Readiness

CheckHow to VerifySeverity if Missing
Health endpointScan for /health, /healthz, /ping, or health_check routeLow
Structured loggingCheck for pino, winston, logging (Python), slog (Go) imports — not console.logMedium
Error trackingCheck for Sentry, Bugsnag, Datadog, or similar error tracking setupLow
Environment config.env.example or environment variables documented somewhereLow

Output Format

For Session-Start Hook (Lightweight)

A single line injected into context:

Project health: [X] gaps found — [highest severity] priority: [top 1-2 findings]

Example: Project health: 4 gaps found — Critical priority: .env not in .gitignore, no input validation

If no gaps found: Project health: All checks passed

For /diagnose Command (Full)

Organized by severity:

## Project Diagnosis Report

### Critical (fix immediately)
- [ ] .env not listed in .gitignore — secrets may be committed
- [ ] Hardcoded API key found in src/config.ts:14

### High (fix soon)
- [ ] No test files found — add a tests/ directory and at least one test
- [ ] No input validation — install Zod and validate route inputs

### Medium (improve when convenient)
- [ ] No CI configuration — add .github/workflows/ci.yml
- [ ] No linter configured — install ESLint with strict config

### Low (nice to have)
- [ ] No health endpoint — add GET /health for monitoring
- [ ] No .env.example — document required environment variables

### Passed
- [x] .gitignore exists
- [x] README exists
- [x] TypeScript strict mode enabled

Tier-Adapted Presentation

  • Builder: Show only Critical findings. Frame them as helpful: "I noticed a couple things I should fix before we go further."
  • Maker: Show Critical and High. Frame as recommendations: "Here are some gaps I'd recommend addressing."
  • Engineer: Show everything. Frame as a report: "Full diagnosis results below."

Auto-Fix Capability

When invoked via /diagnose --fix or when the project-doctor agent runs:

  • Can auto-fix: .gitignore creation/updates, linter config, test runner setup, CI workflow generation, health endpoint, .env.example
  • Cannot auto-fix: Removing hardcoded secrets (needs human judgment on replacement), adding input validation to existing routes (needs understanding of expected inputs), configuring error tracking (needs account credentials)
  • Always ask before fixing: Never silently modify existing files. Create new files freely, but modification requires user approval.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.