Karpathy-Inspired Claude Code Guidelines

A single CLAUDE.md file to transform your AI coding assistant, derived from Andrej Karpathy's observations on LLM coding pitfalls.

140,518
Stars
14,423
Forks
761
Subscribers

The Problems with AI Coding

Wrong Assumptions

"The models make wrong assumptions on your behalf and just run along with them without checking. They don't manage their confusion, don't seek clarifications..."

Overcomplication

"They really like to overcomplicate code and APIs, bloat abstractions, don't clean up dead code... implement a bloated construction over 1000 lines when 100 would do."

Unintended Changes

"They still sometimes change/remove comments and code they don't sufficiently understand as side effects, even if orthogonal to the task."

The Solution: Four Powerful Principles

🧠

Think Before Coding

State assumptions explicitly, present multiple interpretations, push back when warranted, stop when confused.

✨

Simplicity First

Minimum code that solves the problem. No speculative features, no unnecessary abstractions, no overengineering.

🔪

Surgical Changes

Touch only what you must. Match existing style. Don't refactor things that aren't broken. Clean up only your own mess.

🎯

Goal-Driven Execution

Define success criteria. Write tests first. Loop until verified. Transform "what to do" into "what success looks like".

Get Started in Minutes

Claude Code Plugin (Recommended)

From within Claude Code, add the marketplace and install the plugin:

/plugin marketplace add forrestchang/andrej-karpathy-skills /plugin install andrej-karpathy-skills@karpathy-skills

Makes the guidelines available across all your projects.

CLAUDE.md File (Per-Project)

New project:

curl -o CLAUDE.md https://raw.githubusercontent.com/forrestchang/andrej-karpathy-skills/main/CLAUDE.md

Existing project:

echo "" >> CLAUDE.md curl https://raw.githubusercontent.com/forrestchang/andrej-karpathy-skills/main/CLAUDE.md >> CLAUDE.md

How You'll Know It's Working

✅

Cleaner Code Reviews

Fewer unnecessary changes in diffs. Only requested changes appear in pull requests.

🚀

First-Time Success

Fewer rewrites due to overcomplication. Code is simple and correct from the start.

💬

Better Communication

Clarifying questions come before implementation, not after costly mistakes.

🎯

Precise Execution

Clean, minimal PRs with no drive-by refactoring or unnecessary improvements.

Transform Your AI Coding Assistant Today

Join thousands of developers already using these guidelines to build better, cleaner code with AI assistance.