karpathy-guidelines

Featured

Behavioral guidelines to reduce common LLM coding mistakes. Use when writing, reviewing, or refactoring code. Derived from Andrej Karpathy's LLM coding pitfalls.

Code & Development 117 stars 0 forks Updated today MIT

Install

View on GitHub

Quality Score: 88/100

Stars 20%
69
Recency 20%
100
Frontmatter 20%
70
Documentation 15%
80
Issue Health 10%
50
License 10%
100
Description 5%
100

Skill Content

# Karpathy Guidelines Derived from [Karpathy on LLM coding pitfalls](https://x.com/karpathy/status/2015883857489522876). Bias: caution over reckless speed. Trivial tasks — use judgment. ## 1. Think Before Coding Don't assume. Don't hide confusion. Surface tradeoffs. - State assumptions explicitly. If uncertain, ask. - Multiple interpretations → present them; don't pick silently. - Prefer simpler approaches; push back when warranted. - Unclear → stop, name the confusion, ask. ## 2. Simplicity First Minimum code that solves the problem. Nothing speculative. - No features beyond the ask. - No single-use abstractions or fake "flexibility". - No error handling for impossible cases. - 200 lines that could be 50 → rewrite. ## 3. Surgical Changes Touch only what you must. Clean up only your own mess. - Don't "improve" adjacent code, comments, or formatting. - Don't refactor what isn't broken. - Match existing style. - Unrelated dead code → mention, don't delete. - Remove only what **your** change made unused. **Test:** every changed line traces to the user request. ## 4. Goal-Driven Execution Define success criteria. Loop until verified. - "Add validation" → tests for invalid inputs, then make them pass. - "Fix the bug" → failing test first, then green. - Multi-step: `step → verify: command` list. Strong criteria → autonomous loop. Weak ("make it work") → clarify first. ## Autonomy zone (MAY) Inside the task scope, decide tech details, edit or...

Details

Author
VKirill
Repository
VKirill/claude-lane-stack
Created
2 months ago
Last Updated
today
Language
Python
License
MIT

Integrates with

Bundled in these plugins

Similar Skills

Semantically similar based on skill content — not just same category