karpathy-guidelines by forrestchang/andrej-karpathy-skills
npx skills add https://github.com/forrestchang/andrej-karpathy-skills --skill karpathy-guidelines旨在减少常见 LLM 编码错误的行为准则,源自 Andrej Karpathy 对 LLM 编码陷阱的观察。
权衡取舍: 这些准则偏向于谨慎而非速度。对于简单任务,请自行判断。
不要假设。不要隐藏困惑。明确权衡取舍。
在实现之前:
用最少的代码解决问题。不要做推测性编码。
问问自己:"资深工程师会说这过于复杂吗?" 如果是,就简化它。
只修改必须修改的部分。只清理自己造成的混乱。
编辑现有代码时:
当你的修改产生了冗余项时:
检验标准:每一处修改的行都应该能直接追溯到用户的需求。
广告位招租
在这里展示您的产品或服务
触达数万 AI 开发者,精准高效
将任务转化为可验证的目标:
对于多步骤任务,陈述一个简要计划:
1. [步骤] → 验证: [检查点]
2. [步骤] → 验证: [检查点]
3. [步骤] → 验证: [检查点]
强有力的成功标准让你可以独立循环工作。弱的标准("让它工作")则需要不断澄清。
每周安装量
1.9K
代码仓库
GitHub 星标数
7.5K
首次出现
2026年1月28日
安全审计
安装于
claude-code1.5K
opencode1.4K
gemini-cli1.4K
codex1.3K
github-copilot1.2K
cursor1.2K
Behavioral guidelines to reduce common LLM coding mistakes, derived from Andrej Karpathy's observations on LLM coding pitfalls.
Tradeoff: These guidelines bias toward caution over speed. For trivial tasks, use judgment.
Don't assume. Don't hide confusion. Surface tradeoffs.
Before implementing:
Minimum code that solves the problem. Nothing speculative.
Ask yourself: "Would a senior engineer say this is overcomplicated?" If yes, simplify.
Touch only what you must. Clean up only your own mess.
When editing existing code:
When your changes create orphans:
The test: Every changed line should trace directly to the user's request.
Define success criteria. Loop until verified.
Transform tasks into verifiable goals:
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.
Weekly Installs
1.9K
Repository
GitHub Stars
7.5K
First Seen
Jan 28, 2026
Security Audits
Gen Agent Trust HubPassSocketPassSnykPass
Installed on
claude-code1.5K
opencode1.4K
gemini-cli1.4K
codex1.3K
github-copilot1.2K
cursor1.2K
97,600 周安装