andrej-karpathy-skills  by vtroisWhite

Guidelines for enhancing LLM coding agent behavior

Created 1 month ago
305 stars

Top 87.5% on SourcePulse

GitHubView on GitHub
Project Summary

This repository provides a CLAUDE.md file and Claude Code plugin designed to mitigate common pitfalls in Large Language Model (LLM) generated code. It addresses issues like incorrect assumptions, over-engineering, and unintended code modifications by enforcing structured reasoning and coding principles. The project targets users of LLM coding assistants, aiming to improve the quality, focus, and maintainability of AI-generated code.

How It Works

The core of the project lies in four principles derived from Andrej Karpathy's observations on LLM coding behavior: "Think Before Coding," "Simplicity First," "Surgical Changes," and "Goal-Driven Execution." These principles guide LLMs to explicitly state assumptions, prioritize minimal viable solutions, restrict modifications to only what is necessary for the task, and define clear, verifiable success criteria. This structured approach aims to prevent LLMs from making silent errors, overcomplicating solutions, or introducing unintended side effects.

Quick Start & Requirements

  • Installation:
    • Claude Code Plugin (Recommended):
      1. Add marketplace: /plugin marketplace add forrestchang/andrej-karpathy-skills
      2. Install plugin: /plugin install andrej-karpathy-skills@karpathy-skills
    • CLAUDE.md (Per-project):
      • New project: curl -o CLAUDE.md https://raw.githubusercontent.com/forrestchang/andrej-karpathy-skills/main/CLAUDE.md
      • Existing project (append): echo "" >> CLAUDE.md && curl https://raw.githubusercontent.com/forrestchang/andrej-karpathy-skills/main/CLAUDE.md >> CLAUDE.md
  • Prerequisites: Requires an LLM environment like Claude Code that supports plugins or interprets CLAUDE.md files. No specific hardware or OS dependencies are listed.
  • Setup Time: Minimal, involving simple command-line operations.

Highlighted Details

  • Provides a structured framework based on Andrej Karpathy's insights into LLM coding limitations.
  • Focuses on four key principles to improve LLM code generation: explicit reasoning, simplicity, minimal edits, and verifiable goals.
  • Leverages LLMs' ability to loop until success criteria are met via the "Goal-Driven Execution" principle.
  • Guidelines are customizable and can be merged with project-specific instructions.

Maintenance & Community

No specific details regarding maintainers, sponsorships, or community channels (like Discord/Slack) are provided in the README. The project is presented as a set of guidelines derived from external observations.

Licensing & Compatibility

  • License: MIT.
  • Compatibility: The MIT license is permissive and generally compatible with commercial use and closed-source projects.

Limitations & Caveats

These guidelines intentionally prioritize caution and thoroughness over raw speed, potentially slowing down the implementation of very simple tasks. Their effectiveness is contingent on the LLM's capability to understand and adhere to the structured instructions within the CLAUDE.md file or plugin format.

Health Check
Last Commit

1 month ago

Responsiveness

Inactive

Pull Requests (30d)
1
Issues (30d)
0
Star History
199 stars in the last 30 days

Explore Similar Projects

Starred by Eric Zhu Eric Zhu(Coauthor of AutoGen; Research Scientist at Microsoft Research) and Chip Huyen Chip Huyen(Author of "AI Engineering", "Designing Machine Learning Systems").

PromptWizard by microsoft

0.1%
4k
Agent-driven framework for task-aware prompt optimization
Created 2 years ago
Updated 7 months ago
Feedback? Help us improve.