karpathy-education-first

karpathy-education-first is a skill for Claude Code from LearnPrompt/andrej-karpathy-skills. It costs 113 tokens per session (1,756 once invoked), scanned A, original, MIT.

An education-first writing approach that turns software projects and technical ideas into explanations a curious beginner can follow. It favors small teaching examples, clear comments, and step-by-step guidance.

In plain words
What is it for?
Use it to write beginner tutorials, explain code, create small learning projects, and add exercises or reasoning to a technical project.
Why use it?
It helps readers understand how and why code works instead of merely receiving a finished solution. This makes unfamiliar systems easier to learn and modify.

Skill for Claude Code

Written for Claude Code: disable-model-invocation in frontmatter.

Part of the karpathy-skills plugin — 15 skills shipped together

Good fit Use it to write beginner tutorials, explain code, create small learning projects, and add exercises or reasoning to a technical project.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/learnprompt/andrej-karpathy-skills/karpathy-education-first
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add LearnPrompt/andrej-karpathy-skills --skill karpathy-education-first
Clone the repo
git clone --depth 1 https://github.com/LearnPrompt/andrej-karpathy-skills

Made for: Claude Code.

Or install karpathy-skills, the plugin that ships this one along with the rest of its 15 skills.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for karpathy-education-first

README.md
[![agentmods](https://agentmods.dev/badge/skills/learnprompt/andrej-karpathy-skills/karpathy-education-first/github.svg)](https://agentmods.dev/skills/learnprompt/andrej-karpathy-skills/karpathy-education-first)
Your own site
<a href="https://agentmods.dev/skills/learnprompt/andrej-karpathy-skills/karpathy-education-first"><img src="https://agentmods.dev/badge/skills/learnprompt/andrej-karpathy-skills/karpathy-education-first/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for karpathy-education-first

Your own site · 80×15
<a href="https://agentmods.dev/skills/learnprompt/andrej-karpathy-skills/karpathy-education-first"><img src="https://agentmods.dev/badge/skills/learnprompt/andrej-karpathy-skills/karpathy-education-first.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 113 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,756 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00113 $0.01756
Opus 5 $0.00056 $0.00878
Sonnet 5 $0.00023 $0.00351
Haiku 4.5 $0.00011 $0.00176

Measured 12d ago against content hash 5a511435c79b, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-12, from the pricing page.

Security

Grade A, and why

karpathy-education-first scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 12d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

karpathy-education-first/SKILL.md · 192 lines

How it starts

The opening of the file, as written. The whole thing — 192 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Skill 12: Education-First Mindset(教育至上)

Source: https://x.com/karpathy/status/2021694437152157847 | https://x.com/karpathy/status/2056753169888334312 243-line pure Python GPT | "education热情不变" even at Anthropic

Core Principle

If you can't teach it, you don't own it. Make everything a nano-project.

Karpathy's signature move: take a complex system and reimplement it from scratch in minimal, readable code with maximal explanation. Not for production. For understanding.

The 243-line GPT wasn't the fastest implementation. It was the most comprehensible implementation. That's the goal.

The Teaching Version Prompt

After completing any project, generate its teaching version:

I just built [PROJECT/CONCEPT]. Now create a teaching version of it.

[PASTE CODE OR DESCRIBE PROJECT]

Teaching version requirements:
1. Target audience: curious beginner who knows [PREREQUISITE LEVEL]
2. Start with: "Here's what we're building and why it matters" (2 paragraphs)
3. Walk through the code line-by-line in the most important sections
4. For every non-obvious decision: add a comment explaining WHY, not just WHAT
5. Add a "Try this yourself" section at the end with 3 small exercises
6. Maximum complexity rule: if a beginner would say "wait, what?" — add an explanation

Output: the teaching version as a complete annotated script or tutorial.

The Nano-Project Pattern

Karpathy's approach to making anything understandable:

Create a nano-project that demonstrates [COMPLEX CONCEPT].

Rules:
- Under 200 lines of code (pure Python / stdlib preferred)
- Zero external dependencies
- Every line earns its place
- Annotated: inline comments explain the key insight of each section
- Complete: runs from scratch, shows meaningful output
- Pedagogical: the code's structure mirrors the concept's structure

The concept to demonstrate: [CONCEPT]
What should the reader understand after running this? [LEARNING GOAL]

Also provide:
- 3-sentence explanation at the top of the file
- What to try next (3 suggestions for extending it)

Read the full file on GitHub · 192 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 12d ago First seen · 192 lines · 113 tokens per session scan A 5a511435c79b

Subscribe to this mod's changes

karpathy-education-first is a skill published in the GitHub repository LearnPrompt/andrej-karpathy-skills (97 stars, last pushed 2mo ago), licensed MIT. It adds 113 tokens to every session and 1,756 once invoked, about $0.0006 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

hr-onboarding

A new-hire onboarding plan as a single page — first week schedule, buddy + manager intro, learning track, equipment checklist, and "you're set when…" outcomes. Use when the brief mentions "onboarding", "new hire", "first week plan", or "入职".

nexu-io/open-design · 62 tokens

book-mirror

Take any book (EPUB/PDF), produce a personalized chapter-by-chapter analysis. Each chapter is preserved in detail (The Chapter) and mirrored back to the reader's actual life (The Mirror) using brain context. The mirror observes and resonates — a friend pointing out parallels, NOT a consultant rearranging the reader's…

garrytan/gbrain · 138 tokens

miniapp

Build a tiny interactive HTML playground only when someone asks to see, play with, or step through a mechanism.

yc-software/qm · 25 tokens

eli5

Explain research, papers, or technical ideas in plain English with minimal jargon, concrete analogies, and clear takeaways. Use when the user says "ELI5 this", asks for a simple explanation of a paper or research result, wants jargon removed, or asks what something technically dense actually means.

companion-inc/feynman · 63 tokens

deck-course-module

A course or workshop slide template with persistent learning goals, teaching pages, multiple-choice self-tests, and a wrap-up.

nexu-io/html-anything · 25 tokens

master-yinguang

A reference-based assistant for questions about Yinguang and Pure Land Buddhism, a Buddhist tradition focused on faith, ethical living, and practice connected with rebirth in the Pure Land. It can answer in Yinguang’s historical teaching style.

xr843/Master-skill · 274 tokens