nanogpt

Educational GPT implementation in ~300 lines. Reproduces GPT-2 (124M) on OpenWebText. Clean, hackable code for learning transformers. By Andrej Karpathy. Perfect for understanding GPT architecture from scratch. Train on Shakespeare (CPU) or OpenWebText (multi-GPU).

by Orchestra-Research 12k GitHub stars MIT Updated Jun 16, 2026
nanogpt skill by Orchestra-Research
nanogpt — Productivity skill by Orchestra-Research

Overview

nanogpt is an open-source productivity skill for Claude Code and compatible agents, published by Orchestra-Research. Its author describes it as: “Educational GPT implementation in ~300 lines. Reproduces GPT-2 (124M) on OpenWebText. Clean, hackable code for learning transformers. By Andrej Karpathy. Perfect for understanding GPT architecture from scratch. Train…”. The project has 12k stars on GitHub and is available under the MIT license. Add it to your setup with `/plugin marketplace add Orchestra-Research/AI-Research-SKILLs`.

What nanogpt does

nanoGPT is a simplified GPT implementation designed for learning and experimentation.

What’s inside

The SKILL.md for nanogpt is organised into these sections:

  • Quick start
  • Common workflows
  • Workflow 1: Character-level Shakespeare
  • Workflow 2: Reproduce GPT-2 (124M)
  • Workflow 3: Fine-tune pretrained GPT-2
  • Workflow 4: Custom dataset
  • When to use vs alternatives
  • Common issues
  • Advanced topics
  • Hardware requirements
  • Resources

Installation

Add nanogpt to your agent with:

/plugin marketplace add Orchestra-Research/AI-Research-SKILLs

Review a skill’s source before installing it — skills can instruct your agent to run commands. This command comes from the skill’s public repository, which is the source of truth for setup steps. New to skills? Read how to install Claude Code skills.

Supported agents

  • Claude Code — ships a claude code plugin marketplace
  • Codex — declared in the repository topics

License

nanogpt is published under the MIT license.

Strengths

  • Clear MIT license — safe to read and adapt within its terms
  • Ships in Orchestra-Research/AI-Research-SKILLs, an established project with 11,807 GitHub stars
  • Works with Claude Code, Codex

Author

Orchestra-Research 41 skills in the catalog · GitHub profile ↗
View skills

Topics

Need a skill like this, tailored to your team?Build a custom skill →

Frequently asked questions

What does nanogpt do?
Educational GPT implementation in ~300 lines. Reproduces GPT-2 (124M) on OpenWebText. Clean, hackable code for learning transformers. By Andrej Karpathy. Perfect for understanding GPT architecture from scratch. Train on Shakespeare (CPU) or OpenWebText (multi-GPU).
How do I install nanogpt?
Run /plugin marketplace add Orchestra-Research/AI-Research-SKILLs in your agent, then reload your skills. Review the source at https://github.com/Orchestra-Research/AI-Research-SKILLs before installing.
Is nanogpt free to use?
Yes. nanogpt is free and open source under the MIT license, so you can read, run, and adapt it within that license's terms.
Which agents does nanogpt work with?
nanogpt lists Claude Code and Codex — named in its SKILL.md, its plugin marketplace or its repository topics. Skills use the portable SKILL.md format, so other agents that read that format may load it too.
Where does nanogpt come from?
nanogpt ships inside Orchestra-Research/AI-Research-SKILLs, a repository that contains 41 catalogued skills in total. The repository's 11,807 GitHub stars apply to that whole collection, not to this skill on its own.

State-space model with O(n) complexity vs Transformers' O(n²). 5× faster inference, million-token sequences, no KV cache. Selective SSM with hardware-aware design. Mamba-1 (d_state=16) and Mamba-2 (d_state=128, multi-head). Models 130M-2.8B on HuggingFace.

Claude CodeCodex
12k GitHub stars MIT Updated Jun 16, 2026 Free

RNN+Transformer hybrid with O(n) inference. Linear time, infinite context, no KV cache. Train like GPT (parallel), infer like RNN (sequential). Linux Foundation AI project. Production at Windows, Office, NeMo. RWKV-7 (March 2025). Models up to 14B parameters.

Claude CodeCodex
12k GitHub stars MIT Updated Jun 16, 2026 Free

Orchestrates end-to-end autonomous AI research projects using a two-loop architecture. The inner loop runs rapid experiment iterations with clear optimization targets. The outer loop synthesizes results, identifies patterns, and steers research direction. Routes to domain-specific skills for execution, supports continuous agent operation via Claude Code /loop and OpenClaw heartbeat, and produces research presentations and papers. Use when starting a research project, running autonomous experiments, or managing a multi-hypothesis research effort.

Claude CodeCodex
12k GitHub stars MIT Updated Jun 16, 2026 Free

Provides guidance for interpreting and manipulating neural network internals using nnsight with optional NDIF remote execution. Use when needing to run interpretability experiments on massive models (70B+) without local GPU resources, or when working with any PyTorch architecture.

Claude CodeCodex
12k GitHub stars MIT Updated Jun 16, 2026 Free

Provides guidance for training and analyzing Sparse Autoencoders (SAEs) using SAELens to decompose neural network activations into interpretable features. Use when discovering interpretable features, analyzing superposition, or studying monosemantic representations in language models.

Claude CodeCodex
12k GitHub stars MIT Updated Jun 16, 2026 Free