karpathy

karpathy is a skill for Claude Code, Codex from Onelevenvy/flock. It costs 57 tokens per session (528 once invoked), scanned A, a copy of andrej-karpathy, Apache-2.0.

A set of coding guidelines that tells an agent to clarify assumptions, choose the simplest solution, and make narrowly focused edits.

In plain words
What is it for?
Use it when you want an agent to think through unclear requirements, keep implementations small, and define how to check that the work is correct.
Why use it?
It helps prevent overcomplicated code, unrequested features, and changes to unrelated parts of a project.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

About the project

Flock is a desktop application for visually designing and running teams of AI agents, with a Rust backend and Tauri and React interface. It is used to orchestrate agent workflows that can perform tasks such as handling files, running commands, browsing the web, and executing pipelines, and the catalogue entries extend its agent and workflow setup.

Onelevenvy/flock · 1,103 stars · on GitHub

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.

agentmods
npx agentmods add skills/onelevenvy/flock/karpathy
Any agent
npx skills add Onelevenvy/flock --skill karpathy
Clone the repo
git clone --depth 1 https://github.com/Onelevenvy/flock

Made for: Claude Code, Codex.

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

README.md
[![agentmods](https://agentmods.dev/badge/skills/onelevenvy/flock/karpathy.svg)](https://agentmods.dev/skills/onelevenvy/flock/karpathy)
Your own site
<a href="https://agentmods.dev/skills/onelevenvy/flock/karpathy"><img src="https://agentmods.dev/badge/skills/onelevenvy/flock/karpathy.svg" alt="Measured on agentmods" height="20"></a>
Per session 57 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 528 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin 83% copy Near-identical to another mod 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.00057 $0.00528
Opus 5 $0.00028 $0.00264
Sonnet 5 $0.00011 $0.00106
Haiku 4.5 $0.00006 $0.00053

Measured 6d ago against content hash 4057f78e8ff7, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-06, from the pricing page.

Security

Grade A, and why

karpathy 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 6d 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.

Origin

This is a copy

83% identical to andrej-karpathy — 76 lines differ, which has more behind it and is treated as the original. This page carries a canonical link to it rather than competing with it.

flock-data/skills/karpathy/SKILL.md · 78 lines

How it starts

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

Karpathy Coding Principles

Principles for writing clean, minimal, and purposeful code.


1. Think Before Coding

Don't assume. Don't hide confusion. Surface tradeoffs.

Before implementing:

  • State your assumptions explicitly. If uncertain, ask.
  • If multiple interpretations exist, present them - don't pick silently.
  • If a simpler approach exists, say so. Push back when warranted.
  • If something is unclear, stop. Name what's confusing. Ask.

2. Simplicity First

Minimum code that solves the problem. Nothing speculative.

  • No features beyond what was asked.
  • No abstractions for single-use code.
  • No "flexibility" or "configurability" that wasn't requested.
  • No error handling for impossible scenarios.
  • If you write 200 lines and it could be 50, rewrite it.

Ask yourself: "Would a senior engineer say this is overcomplicated?" If yes, simplify.


3. Surgical Changes

Touch only what you must. Clean up only your own mess.

When editing existing code:

  • Don't "improve" adjacent code, comments, or formatting.
  • Don't refactor things that aren't broken.
  • Match existing style, even if you'd do it differently.
  • If you notice unrelated dead code, mention it - don't delete it.

When your changes create orphans:

  • Remove imports/variables/functions that YOUR changes made unused.
  • Don't remove pre-existing dead code unless asked.

The test: Every changed line should trace directly to the user's request.


4. Goal-Driven Execution

Define success criteria. Loop until verified.

Transform tasks into verifiable goals:

  • "Add validation" -> "Write tests for invalid inputs, then make them pass"
  • "Fix the bug" -> "Write a test that reproduces it, then make it pass"
  • "Refactor X" -> "Ensure tests pass before and after"

For multi-step tasks, state a brief plan:

1. [Step] -> verify: [check]
2. [Step] -> verify: [check]
3. [Step] -> verify: [check]

Strong success criteria let you loop independently. Weak criteria ("make it work") require constant clarification.

Read the full file on GitHub · 78 lines

Files

What ships with it

1 file beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

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. 6d ago First seen · 78 lines · 57 tokens per session scan A 4057f78e8ff7

Subscribe to this mod's changes

karpathy is a skill published in the GitHub repository Onelevenvy/flock (1,103 stars, last pushed 2mo ago), licensed Apache-2.0. It adds 57 tokens to every session and 528 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. It is 83% identical to andrej-karpathy, differing in 76 lines, and is treated as a copy.

Related

Other skills, from other repositories

code-review

This skill should be used when the user asks for a code review of a change — a pull request, merge request, branch, commit range, working-tree change, or pasted diff — covering correctness, security, performance, structure, and repository-specific rules. Trigger on phrases like "review this PR", "review this MR"…

srtab/daiv · 164 tokens

plan

This skill should be used when the user asks to explore a codebase and design implementation plans without making any changes. Trigger when users say 'plan how to implement X', 'design an approach for Y', 'explore the codebase before changing Z', 'create an implementation strategy', 'analyze how to refactor X', 'map…

srtab/daiv · 90 tokens

security-audit

This skill should be used when the user asks to review code for security vulnerabilities, audit a pull request or merge request for risks, check if code is safe, find injection flaws or hardcoded secrets, or assess the security posture of a feature or codebase area. Use this skill even when the user doesn't say…

srtab/daiv · 153 tokens

init

This skill should be used when a user asks to initialize a repository for AI agents, create or update an AGENTS.md file, scaffold agent instructions for a codebase, or improve existing agent guidance. Triggers include phrases like 'create an AGENTS.md', 'set up agent instructions', 'initialize this repo for coding…

srtab/daiv · 86 tokens

blog_creator

创作高质量的技术博客文章。擅长将复杂的技术概念转化为通俗易懂的内容,结构清晰,案例丰富,适合不同层次的技术读者。.

liuyueyi/spring-ai-demo · 48 tokens

modern_poetry

创作优美的现代诗歌。使用富有想象力的语言,表达情感、意境和哲思。擅长运用意象、隐喻、节奏和韵律,创作打动人心的诗篇。.

liuyueyi/spring-ai-demo · 61 tokens