
Karpathy Guidelines
Based on Andrej Karpathy's observations about common LLM coding mistakes, this gives Claude explicit behavioral guidelines when writing or reviewing code. It pushes for stating assumptions upfront, avoiding speculative features and premature abstractions, making surgical edits that don't "improve" unrelated code, and defining verifiable success criteria before starting work. The approach trades speed for caution, which makes sense for non-trivial work where LLMs tend to overcomplicate or silently pick interpretations. If you find yourself cleaning up after Claude rewrote half your codebase to add a button, or getting 200 lines where 50 would do, this addresses exactly that.
- skills.sh installs
- 3.8K
- GitHub stars
- 3
- last updated
- Aug 21, 2026
Install
$ npx -y skills add szkocot/andrej-karpathy-skills --skill karpathy-guidelines --agent claude-codeInstalls into .claude/skills of the current project.
Files
Karpathy Guidelines
Behavioral guidelines to reduce common LLM coding mistakes, derived from Andrej Karpathy's observations on LLM coding pitfalls.
Tradeoff: These guidelines bias toward caution over speed. For trivial tasks, use judgment.
1. Think Before Coding
Don't assume. Don't hide confusion. Surface tradeoffs.
Before implementing:
- State your assumptions explicitly. If uncertain, ask.
- If multiple interpretations exist, present them - don't pick silently.
- If a simpler approach exists, say so. Push back when warranted.
- If something is unclear, stop. Name what's confusing. Ask.
2. Simplicity First
Minimum code that solves the problem. Nothing speculative.
- No features beyond what was asked.
- No abstractions for single-use code.
- No "flexibility" or "configurability" that wasn't requested.
- No error handling for impossible scenarios.
- If you write 200 lines and it could be 50, rewrite it.
Ask yourself: "Would a senior engineer say this is overcomplicated?" If yes, simplify.
3. Surgical Changes
Touch only what you must. Clean up only your own mess.
Sponsors
Details
- Repository
- github.com/szkocot/andrej-karpathy-skills
- Categories
- Documentation, Code Review & Quality, AI & Agent Building
- First seen
- Jun 3, 2026