# AGENTS.md

Implement a ChatGPT-like LLM in PyTorch from scratch, step by step

## Setup

```
pip install -r requirements.txt
```

## Commands

```
ruff check .   # lint
```

## Layout

- `ch05/`       41 source files
- `pkg/`        37 source files
- `ch04/`       32 source files
- `ch06/`       16 source files
- `ch07/`       9 source files
- `appendix-A/` 2 source files

## Conventions

- Tests live alongside the code they cover, following `.github/scripts/test_check_links.py`.
- CI defines what passing means. See `.github/workflows/basic-tests-latest-python.yml`, and keep it green.
- TODO: add the two or three conventions a newcomer always gets wrong here.

## Gotchas

- No lockfile is committed, so an install here may not match what CI produced.

---

Drafted by agentreadme.com from what is in this repository. Everything marked TODO
needs a human. Check it in as AGENTS.md at the root.
