craft-project-audit-full
Skill2 starsChanged 7 months agoMITView on GitHub
Deep Claude Code setup audit. Fetches latest docs, analyzes session history, usage patterns, and feature adoption. Runs 4 parallel agents — takes 2-20 minutes and uses significant token budget. For a fast local check, use /craft-project-audit.
In this repository10 other files it gives its agents.
- CLAUDE.mdCLAUDE.md
- craft-global-auditSkill
- craft-project-auditSkill
- craft-project-dreamSkill
- craft-project-exploreSkill
- craft-project-rememberSkill
- craft-project-setupSkill
- craft-project-statusSkill
- craft-session-solidifySkill
- craft-update-selfSkill
The file
We split this skill into the rules it gives an agent
10 rules. About 0 are common, 10 are distinctive, and 0 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈10
Distinctive · estimate
This author's own choices. Worth a look.
0
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 15
Run this bash command first:
- Distinctive: line 78
Run all of the following analyses:
- Distinctive: line 130
All configured MCP servers with type, command, purpose.
- Distinctive: line 138
Check if this project correctly uses craft patterns.
- Distinctive: line 163
Check specifically — quote the offending line(s) for each finding: a.
- Distinctive: line 182
After all 4 agents complete, synthesize into a compact action table.
- Distinctive: line 219
Ask: "Apply this change? (y/n)"
- Distinctive: line 222
After all selected items: "Done.
- Distinctive: line 226
Never remove files or content that was not created by craft
- Distinctive: line 241
Every claim cites a source.
≈ “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.
Files
Token budget notice: This skill runs 4 parallel research agents at high effort. A full audit takes 2-20 minutes and uses significant token budget. Do not run simultaneously across multiple projects.
For a fast local health check (~15 seconds, no agents):
/craft-project-audit
Step 1: Locate session directory
Run this bash command first:
CWD=$(pwd)
PROJECT_KEY=$(echo "$CWD" | sed 's|/|-|g; s|_|-|g')
SESSIONS_DIR="$HOME/.claude/projects/$PROJECT_KEY"
if [ -d "$SESSIONS_DIR" ] && [ -f "$SESSIONS_DIR/sessions-index.json" ]; then
echo "FOUND:$SESSIONS_DIR"
else
BASENAME=$(basename "$CWD" | sed 's|_|-|g')
CANDIDATE=$(ls "$HOME/.claude/projects/" 2>/dev/null | grep -- "-$BASENAME$" | head -1)
if [ -n "$CANDIDATE" ]; then
echo "FOUND:$HOME/.claude/projects/$CANDIDATE"
else
echo "NOT_FOUND"
fi
fiAlso run: pwd and detect project name from CLAUDE.md or directory name.
Record the actual SESSIONS_DIR. Embed it in the agent prompts below.
Step 2: Launch 4 agents in parallel (single message, all at once)
Critical: spawn all 4 agents in one message. Do not wait.
Agent A: Feature Researcher
Fetch ALL of these. Do not skip any:
- https://docs.anthropic.com/en/release-notes/claude-code
- https://docs.anthropic.com/en/docs/claude-code/overview
- https://docs.anthropic.com/en/docs/claude-code/settings
- https://docs.anthropic.com/en/docs/claude-code/hooks
- https://docs.anthropic.com/en/docs/claude-code/mcp
- https://docs.anthropic.com/en/docs/claude-code/slash-commands
- https://docs.anthropic.com/en/docs/claude-code/memory
- https://docs.anthropic.com/en/docs/claude-code/cli-reference
- https://api.github.com/repos/anthropics/claude-code/releases?per_page=30
Build a complete feature inventory organized by category:
- Built-in slash commands (every one)
- Hook events (every type with triggers and data)
- MCP capabilities
- Skill system (all frontmatter fields)
- Agent/subagent system
- CLI flags and modes
- Settings options
- Status line
- Memory system
- Recent launches (last 60 days)
Anti-hallucination rule: every feature must quote exact text from a fetched source. Never invent version numbers or feature descriptions.
Agent B: Usage Analyst
Sessions directory: [SESSIONS_DIR from Step 1]
Run all of the following analyses:
B1. Session overview (read sessions-index.json, show last 25 sessions with date, message count, branch, summary)
B2. Tool call frequency:
ls -t "SESSIONS_DIR"/*.jsonl 2>/dev/null | head -25 | xargs grep -hoE '"name":"[A-Za-z_][A-Za-z0-9_]*"' 2>/dev/null | sed 's/"name":"//;s/"//' | sort | uniq -c | sort -rn | head -40B3. Slash commands used:
ls -t "SESSIONS_DIR"/*.jsonl 2>/dev/null | head -25 | xargs grep -hoE '"text"\s*:\s*"/[a-z][a-z0-9_/-]*' 2>/dev/null | grep -oE '/[a-z][a-z0-9_/-]*' | sort | uniq -c | sort -rn | head -30B4. Repeated user prompts (patterns worth automating): Parse JSONL for user messages 15-150 chars, find duplicates.
B5. Error patterns:
ls -t "SESSIONS_DIR"/*.jsonl 2>/dev/null | head -25 | xargs grep -hoE 'String to replace not found|permission denied|requires permission|not allowed|ENOENT' 2>/dev/null | sort | uniq -c | sort -rn | head -20Return all raw data. Do not truncate.
Agent C: Config Auditor
Read everything fully:
C1. Global config:
- ~/.claude/CLAUDE.md (full content, line count)
- ~/.claude/settings.json (full content)
- List ~/.claude/skills/ with frontmatter of each SKILL.md
- List ~/.claude/agents/ if exists
C2. Project config:
- [CWD]/CLAUDE.md (full content, line count)
- [CWD]/.claude/settings.json if exists
- List [CWD]/.claude/skills/ if exists
- [CWD]/.mcp.json if exists
- [CWD]/.craft/ directory structure
C3. Project stack detection:
- package.json (name, scripts, all deps)
- Any CI/CD files (.github/workflows/)
- File extensions present (detect stack)
C4. Hook configuration detail: List every hook: event type, matcher, command, global vs project.
C5. MCP server detail: All configured MCP servers with type, command, purpose.
Return full file contents, not summaries.
Agent D: craft-pattern Check
Check if this project correctly uses craft patterns. Read these files if they exist:
- [CWD]/CLAUDE.md
- [CWD]/.craft/PROJECT_STATE.md
- [CWD]/.craft/BACKLOG.md
- [CWD]/.craft/DECISIONS.md
- [CWD]/.craft/HANDOVER.md
- [CWD]/.claude/settings.json
- [CWD]/.craft/memory/ (list and read all files)
Also run:
wc -l [CWD]/CLAUDE.md 2>/dev/null || echo "CLAUDE.md not found"
ls [CWD]/.craft/rules/ 2>/dev/null || echo "no .craft/rules/"Score each dimension (0-3):
CLAUDE.md quality: CLAUDE.md is a prompt that loads on every session. Treat it as a context budget, not a document.
- Score 3: exists, ≤150 lines, rules include WHY, no linter-duplicated rules, no one-off feature rules
- Score 2: exists, 151-200 lines OR most rules lack WHY
- Score 1: exists but >200 lines OR mostly prose/architecture description OR too vague to verify
- Score 0: missing
Check specifically — quote the offending line(s) for each finding: a. Line count: flag if >200 (adherence degrades; every line burns context on every session) b. WHY missing: rules without a reason. Bad: "use pnpm not npm". Good: "use pnpm not npm — repo uses pnpm workspaces and npm breaks the lockfile" c. Linter duplication: formatting or style rules that ESLint, Prettier, or similar already enforce d. One-off rules: instructions scoped to a single file or feature — these belong in
.craft/rules/e. Stale content: decisions or instructions that look superseded or no longer relevant f. Path-scoped rules: if CLAUDE.md has feature-specific sections, suggest moving them to.craft/rules/- Project docs: Are STATE, BACKLOG, HANDOVER, DECISIONS present and recently updated?
- Memory system: Is .craft/memory/ set up? Does learned-rules.md have content?
- Hooks: Is the SessionStart hook configured? (Stop hook is intentionally absent in craft defaults — it was dropped in 2.0.0 as noise. Flag only if user explicitly added their own and it is broken.)
- Scope discipline: Does CLAUDE.md show evidence of scope discipline (no unrelated changes)?
For each dimension: score + specific finding + recommended improvement.
Step 3: Synthesize and produce default output
After all 4 agents complete, synthesize into a compact action table.
Column definitions:
- Action: what to do -- max 60 characters, no verbose explanations. Pad with spaces to exactly 60 chars.
- Cat: Adopt / Improve / Remove / Security
- Quality: will Claude's output on this project improve? ↑↑↑ = high / ↑↑ = medium / ↑ = low
- Efficiency: will the workflow get faster or smoother? ↑↑↑ = high / ↑↑ = medium / ↑ = low
- Effort: how much work to implement? Low / Med / High
Quality and Efficiency must be grounded in evidence from this specific project (Agents B, C, D). No generic advice.
Sort by combined Quality + Efficiency score, highest first. Maximum 12 items.
craft-project-audit-full -- [project name] -- [date]
This is a menu, not a checklist. Pick what makes sense for your project.
Not everything here needs to be done.
| # | Action | Cat | Quality | Efficiency | Effort |
|----|--------------------------------------------------------------|----------|---------|------------|--------|
| 1 | ... | Adopt | ↑↑↑ | ↑↑↑ | Low |
| 2 | ... | Improve | ↑↑↑ | ↑↑ | Med |
| 3 | ... | Improve | ↑↑ | ↑↑↑ | Low |
...End with:
Reply with item numbers to implement (e.g. "1 3 5"), or "show full report" for the complete analysis.Step 4: Implementation (when user replies with numbers)
For each selected item:
- Show exact change (what file, what content, diff-style preview)
- Ask: "Apply this change? (y/n)"
- Apply only if confirmed
- Confirm what was done
- After all selected items: "Done. Run /craft-project-audit-full again to verify improvements."
Per-item rules:
- Complexity-to-benefit check: "A 30-second config change that saves 5 minutes per session is worth it. A 2-hour refactor that saves 10 seconds is not."
- Never remove files or content that was not created by craft
- Sensitive data: never output TOKEN, KEY, SECRET, PASSWORD values
Step 5: Full report (when user says "show full report")
Show all 8 sections:
- Project Profile Dashboard (versions, sessions analyzed, tool calls, skills, MCPs, hooks)
- Feature Adoption Matrix (every Claude Code capability with status: Using / Configured / Not set up / Dead weight)
- Recent Launches (last 60 days, with "applies to you" verdict)
- Dead Weight (configured but unused)
- Workflow Automation Opportunities (from repeated prompts)
- CLAUDE.md Gaps (what belongs there that isn't there)
- Configuration Improvements
- craft-pattern Assessment (from Agent D)
Every claim cites a source. Every recommendation includes exact implementation steps.
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
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.

