Skip to content

Add common-mistakes skill from chat history analysis#1

Open
sceiler wants to merge 1 commit intomainfrom
feature/common-mistakes-skill
Open

Add common-mistakes skill from chat history analysis#1
sceiler wants to merge 1 commit intomainfrom
feature/common-mistakes-skill

Conversation

@sceiler
Copy link
Copy Markdown
Owner

@sceiler sceiler commented Feb 8, 2026

Summary

  • Adds a new common-mistakes skill with 25+ concrete wrong/correct rules across 8 categories
  • Rules were extracted by analyzing user corrections across 500+ Claude Code chat sessions in 21 project directories (~768 MB of JSONL history)
  • Complements the existing agent-best-practices skill (high-level principles) with specific, actionable anti-patterns
  • Updates README.md to document the new skill

How it was built

  1. Wrote a Python script to scan all ~/.claude/projects/ JSONL chat history files
  2. Pattern-matched user messages for corrections (e.g., "no, that's wrong", "revert", "why did you", "I said")
  3. Extracted ~145 raw correction instances, filtered to ~50 genuine mistakes (excluding false positives like context continuations, feature requests, skill loading messages)
  4. Categorized mistakes into 8 themes and wrote concrete wrong/correct examples

Categories

Priority Category # Rules
CRITICAL File & Project Awareness 4
CRITICAL Multi-Target Instructions 2
HIGH Deprecated & Outdated APIs 3
HIGH Output Formatting 4
HIGH Debugging Anti-Patterns 5
HIGH Wrong Optimizations 2
MEDIUM Content & Data Integrity 5
MEDIUM Security Scope 2

Most frequent mistakes found

  1. Not following all instructions — skipping projects, over/under-scoping changes
  2. Using deprecated APIs — e.g., Next.js Image priority prop instead of loading="eager"
  3. Inconsistent output formatting — markdown in first half, plain text in second
  4. Repeated failed fix attempts — trying the same approach 4+ times without changing strategy
  5. Applying client-side optimizations to Server Componentsmemo(), Suspense where they do nothing

Test plan

  • SKILL.md follows the required format (frontmatter + sections)
  • SKILL.md is under 500 lines (currently ~250 lines)
  • metadata.json is valid JSON with required fields
  • README.md updated to list new skill
  • Manual review of rule quality and accuracy

🤖 Generated with Claude Code

New skill with 25+ concrete wrong/correct rules across 8 categories,
extracted by analyzing user corrections in Claude Code chat histories
across 21 projects. Complements agent-best-practices (principles) with
specific, actionable anti-patterns.

Categories: file awareness, multi-target instructions, deprecated APIs,
output formatting, debugging anti-patterns, wrong optimizations,
content integrity, and security scope.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant