本文へ移動
cccskills
無料GitHub で公開

karpathy-guidelines

Behavioral guidelines to reduce common LLM coding mistakes. Use when writing, reviewing, or refactoring code to avoid overcomplication, make surgical changes, surface assumptions, and define verifiable success criteria.

インストール方法を見る

含まれるファイル(1)

  • SKILL.md2.3 KB

SKILL.md(原文)

インストールする前に、エージェントに与えられる指示の中身を確認できます。

Karpathy Guidelines

Derived from Andrej Karpathy's observations on common LLM coding mistakes. Biases toward caution over speed. Apply judgment on trivial tasks.

1. Think before coding

  • State assumptions explicitly. Uncertain → ask before proceeding
  • Multiple interpretations → present them, don't pick silently
  • Simpler approach exists → say so and push back
  • Unclear requirement → stop, name what's confusing, ask
  • Unknown API, method, or type → verify existence before using. Never hallucinate interfaces

2. Simplicity first

  • No features beyond what was asked
  • No abstractions for single-use code
  • No unrequested "flexibility" or "configurability"
  • No error handling for impossible scenarios
  • 200 lines that could be 50 → rewrite it

3. Surgical changes

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
  • Unrelated dead code → mention it, don't delete it

When your changes create orphans:

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

Every changed line must trace directly to the user's request.

4. Destructive operations

  • Deletes, drops, truncates, overwrites → confirm explicitly before executing
  • Irreversible actions → state what will be lost and wait for approval
  • When in doubt, show the plan, don't run it

5. Goal-driven execution

Transform tasks into verifiable goals before starting:

  • "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 first:

1. [Step] → verify: [check]
2. [Step] → verify: [check]
3. [Step] → verify: [check]

Strong success criteria → loop independently to completion.

レビュー

まだレビューはありません。使ってみた感想をお寄せください。

同じリポジトリのスキル

概要と使いどころ

aws

無料

AWS best practices: IAM, secrets, networking, security, compute, IaC, ops. Use when building, reviewing, or modifying AWS resources.

日本語の概要は準備中です。原文の説明を表示しています。

SumonMSelim/agentguard542026年10月12日 更新

docker

無料

Docker best practices: image security, build efficiency, runtime hardening, Compose, local tooling (Colima, OrbStack). Use when writing or reviewing Dockerfiles and Compose files.

日本語の概要は準備中です。原文の説明を表示しています。

SumonMSelim/agentguard542026年10月12日 更新

gcp

無料

GCP best practices: IAM, secrets, networking, security, compute, IaC, ops. Use when building, reviewing, or modifying GCP resources.

日本語の概要は準備中です。原文の説明を表示しています。

SumonMSelim/agentguard542026年10月12日 更新

go

無料

Idiomatic Go 1.25 practices: errors, interfaces, concurrency, generics, testing, security, tooling. Use when writing or reviewing Go code.

日本語の概要は準備中です。原文の説明を表示しています。

SumonMSelim/agentguard542026年10月12日 更新

java

無料

Modern Java practices: design, errors, concurrency, security, testing, tooling. Targets Java 21 LTS baseline; Java 25 LTS features called out explicitly. Use when writing or reviewing Java code.

日本語の概要は準備中です。原文の説明を表示しています。

SumonMSelim/agentguard542026年10月12日 更新

Kubernetes best practices: security, workloads, networking, config, operations, GitOps. Use when writing or reviewing K8s manifests and configurations.

日本語の概要は準備中です。原文の説明を表示しています。

SumonMSelim/agentguard542026年10月12日 更新

SumonMSelim のスキルをすべて見る

このスキルの問題を報告する