Skip to content
Skills Library
AI & agents · Planning

karpathy-agentic-engineering

/karpathy-agentic-engineering

Apply Karpathy-style agentic engineering to any coding or building task. Use this skill when the user wants to set up an agent-driven workflow, needs to write a CLAUDE.md or AGENTS.md, wants to orchestrate agents with clear success criteria, or says things like "agent loop", "let the agent handle it", "agentic coding", "set up agent workflow". Includes the 7-step inner loop from Karpathy claude coding notes.

Licence
MIT
Last repository change
11.07.2026

Assessment and security

100/ 100Class: good
Format25 / 25
Frontmatter with name and description, valid name, description up to 1,024 characters, name matching the folder.
Discoverability25 / 25
Description explains when to use the skill, has a reasonable length and uses third person.
Content35 / 35
At least 150 words and at most 500 lines, headings, step lists, examples or code.
Hygiene15 / 15
No placeholders such as TODO, no Windows paths, with a licence.
Riskno signals detected in the scan
Files in this package
1
Scripts
0
HTML comments
0
URLs in SKILL.md
3
Deprecation

No signals detected. Repository changed on 11.07.2026, without references to retired models or APIs.

Licence

MIT, open: use and modify while retaining author attribution.

What it does and when to use it

Apply Karpathy-style agentic engineering to any coding or building task. Use this skill when the user wants to set up an agent-driven workflow, needs to write a CLAUDE.md or AGENTS.md, wants to orchestrate agents with clear success criteria, or says things like "agent loop", "let the agent handle it", "agentic coding", "set up agent workflow". Includes the 7-step inner loop from Karpathy claude coding notes.

Triggers from the description

agent looplet the agent handle itagentic codingset up agent workflow
Original author description

Apply Karpathy-style agentic engineering to any coding or building task. Use this skill when the user wants to set up an agent-driven workflow, needs to write a CLAUDE.md or AGENTS.md, wants to orchestrate agents with clear success criteria, or says things like "agent loop", "let the agent handle it", "agentic coding", "set up agent workflow". Includes the 7-step inner loop from Karpathy claude coding notes.

How it works

  1. Core Principle
  2. The 7-Step Inner Loop (Karpathy's Incremental Coding Rhythm)
  3. CLAUDE.md / AGENTS.md Template
  4. Master Prompt Template
  5. Common Failure Modes to Prevent
  6. Workflow
  7. Prompt Contract
  8. Verification Checklist
  9. When to Apply This Skill
Original SKILL.md headings · 117 lines, 641 words
SKILL.md preview
---
name: karpathy-agentic-engineering
description: 'Apply Karpathy-style agentic engineering to any coding or building task. Use this skill when the user wants to set up an agent-driven workflow, needs to write a CLAUDE.md or AGENTS.md, wants to orchestrate agents with clear success criteria, or says things like "agent loop", "let the agent handle it", "agentic coding", "set up agent workflow". Includes the 7-step inner loop from Karpathy claude coding notes.'
disable-model-invocation: false
user-invocable: true
related_skills:
  - karpathy-idea-files
  - karpathy-minimalism
  - karpathy-supply-chain-hygiene
  - karpathy-vibe-to-agentic
  - karpathy-understanding-first
---

# Skill 1: Agentic Engineering(代理工程)

> Source: https://x.com/karpathy/status/2004607146781278521 | https://x.com/karpathy/status/2015883857489522876 | https://x.com/karpathy/status/2026731645169185220
> "It is hard to communicate how much programming has changed." — ~37k likes

## Core Principle

You are no longer writing code. You are **directing a team of tireless junior engineers**.

The shift: `write code` → `write tasks with success criteria` → `agent loops` → `human taste review`

## The 7-Step Inner Loop (Karpathy's Incremental Coding Rhythm)

This is the micro-loop for every coding session:

1. **Stuff context** — Load entire project into context (`files-to-prompt`, relevant docs, recent diffs)
2. **Discuss plan** — Ask agent for high-level approaches with pros/cons before any code
3. **Request first draft** — Pick one approach, get a minimal first implementation
4. **Inline learning** — Manually review the diff; ask agent to explain any API you don't recognize
5. **Test** — Run tests, check outputs, verify success criteria
6. **Commit** — Only commit what you understand and have verified
7. **Ask for next** — Let agent suggest the next incremental step

**Never skip step 4.** Understanding atrophies if you rubber-stamp every diff.

## CLAUDE.md / AGENTS.md Template

Write this file at the project root to prevent the most common agent failure modes:

```markdown
# Agent Instructions for [Project Name]

## Behavior Rules
- Make one incremental change at a time. Do NOT refactor unrelated code.
- Always explain WHY you're making a change before the diff.
- If unsure about intent, ASK before implementing.
- Do NOT add new dependencies without explicit approval.
- Prefer simple, readable solutions over clever ones.

## Success Criteria (task-specific — fill in per session)
- [ ] Tests pass: `[test command]`
- [ ] No new lint errors: `[lint command]`
- [ ] Behavior matches: [description of expected output]

## Project Context
- Stack: [language, framework, key libs]
- Entry point: [file]
- Test command: [command]
- Forbidden: [list things agent must never do]
```

## Master Prompt Template

```
You are an agentic engineer on this project.

Project context: [paste relevant files or use files-to-prompt output]

Task: [specific, unambiguous description]

Success criteria (ALL must be true when done):
1. [verifiable check 1]
2. [verifiable check 2]
3. [verifiable check 3]

Constraints:
- Only change files relevant to this task
- No new dependencies without asking
- Output: one incremental diff at a time

Start by proposing a high-level plan with 2-3 options and trade-offs. Wait for approval before writing code.
```

## Common Failure Modes to Prevent

| Agent Sin | Prevention |
|-----------|-----------|
| Over-refactoring | "Only touch files directly related to the task" |
| Sycophantic confirmation | "Tell me what could go wrong with this plan" |
| Hallucinated APIs | "Cite the exact line in the docs for any API you use" |
| Dependency creep | "No new pip/npm installs without asking" |
| No success criteria | Always define DONE before starting |

## Workflow

**属于工作流:想法到上线(开发者)**

| 位置 | 上游 | 下游 |
|------|------|------|
| 第2步 | `karpathy-idea-files`(先定义想法) | `karpathy-minimalism`(极简实现) |

完整链路:`idea-files → agentic-engineering → minimalism → supply-chain-hygiene → vibe-to-agentic`

也常在反偏见决策工作流中作为执行层出现——当决策完成后需要落地时,切换到本 Skill。

## Prompt Contract

```text
You are an agentic engineer. Project context: <files, constraints, current state>. Task: <specific goal>. Success criteria: <verifiable checklist>. First propose a high-level plan with tradeoffs. Then make only the next incremental change. After each change, run the relevant verification and report: changed files, evidence of success, remaining risk, and next step.
```

## Verification Checklist

- [ ] 成功标准已经写成可检查项目(不是模糊描述)
- [ ] 每轮变更都有实际验证证据:测试通过、lint clean、diff 范围正确
- [ ] Agent 没有修改任务范围外的文件
- [ ] 人类已 review 每个 diff 中不理解的部分(不跳步)
- [ ] 最终提交前,能用一句话向同事解释改了什么、为什么

## When to Apply This Skill

- Starting any coding task > 30 minutes
- Setting up a new project with agent assistance
- Debugging a complex issue (agent as rubber duck + implementer)
- Writing CLAUDE.md / AGENTS.md for a repo

Versions

The database has no other skills named karpathy-agentic-engineering.

Database snapshot: 13.11.2026 · package version 6ab98816e811 (SHA-256 digest of the entire package)

Downloads in the last 30 days: 3 · ranking

Report a problem with this skill: harmful content, incorrect descriptions or an author’s removal request.

Similar skills

  • 100karpathy-methodology
    Apply Andrej Karpathy AI methodology and principles from his 2023-2026 insights. Use this skill when the user wants to apply Karpathy-style thinking, needs guidance on agentic engineering, LLM knowledge bases, minimalist coding, understanding-first principles, or any of the 14…
  • 100karpathy-ideas
    Look up Andrej Karpathy's public ideas on working with LLMs and AI agents (agentic coding, verification loops, context, output formats, knowledge bases, agent-native software) and apply them to the current task. Use when designing an agent workflow, a prompt, a coding process, a…
  • 100karpathy-vibe-to-agentic
    Transition from vibe coding (fast prototyping) to agentic engineering (rigorous iteration). Use this skill when the user has a rough prototype and wants to level it up, needs to go from "it kind of works" to production-quality, wants to understand the difference between vibe…
  • 100karpathy-skills-extended
    Always-on check for any coding agent, including Codex, Claude, Cursor, Antigravity, Gemini, and Grok. Before code, writing, a plan, or an answer, find knowledge gaps that would change the outcome and that you cannot resolve from the repo, tools, or the conversation. Ask only…
  • 100agentic-scaffolding
    Use when designing, auditing, or evolving a repository and its engineering workflow for coding agents — AGENTS.md or CLAUDE.md, repo-local skills, agent-readable documentation, plans and memory, scripts and guardrails, isolated workspaces, sandboxing, observability,…
  • 90karpathy-guidelines
    Behavioral guidelines to reduce common LLM coding mistakes. Use when writing, reviewing, or refactoring code. Derived from Andrej Karpathy's LLM coding pitfalls.

Feedback and reports

Your message goes to Bartosz Sokoliński. An email address is needed only for a reply. See the privacy policy.