otherCurated Benchmark & ReviewUpdated: October 2026AISpotNav Editorial Team

Andrej Karpathy's Skills: The Four Principles Behind the Viral CLAUDE.md

The Karpathy Skills repository is a single CLAUDE.md that encodes four engineering principles for coding agents. Here is what each principle does and how to install it.

andrej karpathy skillskarpathy skillskarpathy skills githubclaude.mdagent skills

The most widely adopted AI coding rule file right now is a single CLAUDE.md derived from Andrej Karpathy's published observations on how language models fail at coding. It is a short file with four principles, and it is worth understanding each one before you copy it, because a rule file that you do not understand is a rule file you will disable in a week.

The wider context is in Agent Skills for AI Coding, and the host application is covered in the Claude profile.


What the Repository Actually Contains

The upstream repository is multica-ai/andrej-karpathy-skills, and it holds exactly one file: CLAUDE.md. The README credits the derivation to Karpathy's observations on LLM coding pitfalls and links the source post.

Its stated motivation is that models make wrong assumptions on your behalf and run along with them without checking, do not manage their confusion, do not surface inconsistencies, do not present tradeoffs, and do not push back when they should. It also notes the habit of overcomplicating code and APIs, bloating abstractions, leaving dead code behind, and changing or removing code that was not sufficiently understood as a side effect.

That is a specific and unusually accurate list of failure modes, which is why the file spread.


The Four Principles

PrincipleAddresses
Think Before CodingWrong assumptions, hidden confusion, missing tradeoffs
Simplicity FirstOvercomplication, bloated abstractions
Surgical ChangesOrthogonal edits, touching code you should not
Goal-Driven ExecutionLeverage through tests-first, verifiable success criteria

Think Before Coding. State assumptions explicitly instead of guessing, present multiple interpretations rather than silently picking one, push back when a simpler approach exists, and stop when confused instead of improvising.

Simplicity First. Write the minimum code that solves the stated problem. No speculative features, no abstraction for single-use code, no error handling for impossible scenarios. The test in the file is blunt: if 200 lines could be 50, rewrite it.

Surgical Changes. Touch only what the task requires. Do not reformat adjacent code, do not refactor things that are not broken, match the surrounding style even when you would write it differently, and if you notice unrelated dead code, mention it rather than deleting it. When your own changes create orphans, clean up your own orphans.

Goal-Driven Execution. Leverage the model's ability to verify work. Write the test first, let the test define success, and keep iterating until the criterion is met rather than declaring the task done when it looks done.


Installing It

Project scope. Copy CLAUDE.md into the root of your repository. It applies to every session in that project and is committed alongside the code, which keeps it consistent across the team.

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

User scope. Copy it to ~/.claude/CLAUDE.md to apply it to every project you open on that machine. Keep the project-level file when you want project-specific rules to win.

Other editors. The content is plain Markdown, so the same text can be adapted into an AGENTS.md file for Codex or a rules file for Cursor. Expect to adjust a few tool-specific references; the principles themselves are editor-neutral.

Review before you trust it. Read the file before copying it into a repository you care about. It is a prompt, and prompts are instructions an agent will follow.


Where It Helps and Where It Hurts

The principles pay off most in long-running sessions on unfamiliar code, where the default failure mode is confident drift. They also cost something: "stop when confused" and "present multiple interpretations" produce more questions in early sessions, and "no error handling for impossible scenarios" will conflict with an existing house style that expects defensive code.

If you want to pair it with something narrower, Taste Skill covers the frontend design side of the same problem, and Cursor is the profile for the other major coding agent.


Frequently Asked Questions

Where is the Karpathy skills repository?

The upstream repository is multica-ai/andrej-karpathy-skills. It contains a single CLAUDE.md file and a README that credits the derivation from Karpathy's published observations.

What are the four Karpathy principles?

Think Before Coding, Simplicity First, Surgical Changes and Goal-Driven Execution. The first three address overconfident assumptions and overengineering; the last one pushes toward tests and verifiable success criteria.

How do I install it in Claude Code?

Copy CLAUDE.md into your project root for project scope, or into ~/.claude/CLAUDE.md to apply it to every project on that machine.

Does it work with Cursor or Codex?

The file is plain Markdown, so it can be adapted into an AGENTS.md file for Codex or a rules file for Cursor. Expect to adjust the few tool-specific references.