// Agent profile
nanochat (karpathy/nanochat) is Andrej Karpathy's answer to the question 'what's the best ChatGPT you can build for $100?' It is a minimal, self-contained Python chat application that wires together a capable LLM backend with a clean conversational interface — no enterprise bloat, no SaaS subscriptions, just a focused implementation of what matters. The project embodies Karpathy's philosophy of building from first principles: understand the stack, keep it simple, own the code. 551 stars on GitHub.
nanochat is Andrej Karpathy’s take on building a personal ChatGPT alternative from scratch. The premise is straightforward: rather than paying monthly subscriptions for hosted chat products, what is the best conversational AI experience you can build yourself for around $100 in compute costs? The result is a Python application that connects to LLM APIs and provides a clean chat interface, with all the code visible and modifiable.
The project follows Karpathy’s well-known approach to ML education — strip away the abstractions, build from the ground up, and make every component understandable. nanochat is not a framework or a platform; it is a single, readable codebase that does one thing well.
nanochat provides a conversational interface backed by modern LLMs, implemented in straightforward Python. The codebase is deliberately minimal — there is no plugin system, no agent framework, no enterprise feature set. This makes it easy to read end-to-end, understand how every piece works, and modify it for your own needs. The project demonstrates how little code is actually required to build a capable chat application when you focus on the essentials.
Personal chat assistant: Run your own ChatGPT-style interface without ongoing subscription costs — just API usage fees.
Learning resource: The codebase is one of the clearest examples of how to build an LLM chat application from scratch. Ideal for developers learning how chat UIs, conversation management, and API integration work together.
Starting point for custom tools: Because the code is minimal and well-structured, it is a clean foundation for building specialized chat applications — add retrieval, tool use, or domain-specific prompts on top of a codebase you fully understand.
nanochat requires API keys for its LLM backend, so costs depend on usage volume. It is intentionally minimal — if you need multi-user support, authentication, persistent memory, or enterprise features, you will need to build those yourself or choose a more full-featured platform. The project assumes comfort with Python and running local applications.
Developers who want to understand how chat applications work at the code level, Karpathy followers who appreciate first-principles builds, and anyone who wants a personal ChatGPT alternative they fully own and control.
Open protocol for connecting AI agents to frontend applications — a universal contract for streaming events, tool calls, and state between agents and UIs.
Rust-based browser automation CLI from Vercel Labs that lets AI agents drive browsers one command at a time via accessibility-tree snapshots.
Rust-based desktop computer-use framework from Vercel Labs — agents control apps via accessibility trees instead of screenshots.