autoresearch — nanoGPT-based autonomous ML research loop (research prototype)
What this is: a fork of Karpathy's nanoGPT / nanochat plus an autonomous research-orchestration layer driven by a Claude Code
program.mdplaybook. The goal is to have an LLM agent iterate ontrain.pyinside a fixed time budget and hunt for lowerval_bpb.What this is NOT (v1.0.0): a finished Tribunal-evaluated, Silicon-fused research stack. Read the honest-scope section before depending on any specific feature.
Honest scope for v1.0.0
This release ships a clean installable skeleton around the parts that really work, plus honest documentation of what does not.
| Component | Status | Notes |
|---|---|---|
nanoGPT-style training core (train.py) |
Works | Requires H100-class GPU and flash-attn3 kernels for real runs. |
CPU-friendly toy training (autoresearch toy-train) |
Works | No GPU required. Useful for CI and smoke-tests. |
CLI (info, config, toy-train) |
Works | No network, no GPU. |
JSON metrics sidecar (run_metrics.json) |
Works | Replaces brittle stdout-regex parsing. |
| P2PCLAW Silicon integration | PARTIAL (inert) | silicon/grid_generator.py is a placeholder. Do not rely on it. |
| Tribunal evaluation | NOT IMPLEMENTED | Stub only (autoresearch.tribunal), raises on use. |
| Railway P2PCLAW API | OPTIONAL | Core loop and tests do not need it. |
See ROADMAP.md for the full gap list.
Install
pip install autoresearch
# or, with optional extras:
pip install "autoresearch[full]" # transformers, datasets, wandb
pip install "autoresearch[dev]" # pytest, build, twine
Requires Python >= 3.10. Core deps: torch, numpy, requests.
Quickstart (CPU, no GPU, no network)
# 1. See environment + dependency status
autoresearch info
# 2. Show the default config
autoresearch config
# 3. Run a tiny nanoGPT training smoke-test (writes run_metrics.json)
autoresearch toy-train --steps 20 --verbose
You should see the loss drop across steps and a run_metrics.json written
to the current directory.
Running the real nanoGPT training loop
The top-level train.py is unchanged from the nanochat-derived original and
requires an NVIDIA GPU with flash-attn3 kernels (H100 recommended; other
Hopper/Blackwell-class cards may work via kernels-community/flash-attn3).
CPU is not supported for train.py — use autoresearch toy-train for CPU.
uv run prepare.py # prepares data under ~/.cache/autoresearch/
uv run train.py # runs the 5-minute time-budgeted training loop
The autonomous research loop itself is orchestrated via Claude Code following
program.md.
Structured metrics (preferred over stdout regex)
Earlier versions parsed training results out of stdout using regex against
the --- block. That path is now a fallback. Primary path:
from autoresearch.metrics import write_metrics, read_metrics
write_metrics("run_metrics.json", {"val_bpb": 0.9979, "num_steps": 953})
read_metrics("run_metrics.json") # -> {"val_bpb": 0.9979, "num_steps": 953}
The legacy parser is still available as
autoresearch.metrics.parse_stdout_summary(text) for old run logs.
Tribunal and Silicon
autoresearch.tribunal.evaluate(...)raisesTribunalNotImplementedError.silicon/grid_generator.pydoes not currently emit a usable grid.
Both are tracked in ROADMAP.md.
Testing
pip install -e .[dev]
pytest
All tests are offline and CPU-only. CUDA-requiring cases are skip-marked.
License
Apache License 2.0 — see LICENSE.
Credits
- Andrej Karpathy — nanoGPT and nanochat (MIT).
- Francisco Angulo de Lafuente (Agnuxo1) — autoresearch orchestration layer, P2PCLAW integration work.
Metadata
Release files for autoresearch-nano 1.0.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| autoresearch_nano-1.0.0.tar.gz | 19.0 kB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| autoresearch_nano-1.0.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 36.6 kB
Release files / autoresearch_nano-1.0.0.tar.gz
| Download URL | autoresearch_nano-1.0.0.tar.gz |
|---|---|
| Size | 19.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
21307ffa1178cc5c1a94db7845e6f3c99486420b75c57206886d1d9b7b906a41
|
|
BLAKE2b-256 checksum How to use checksums |
fa7176342fcbffc29355d057153a68f16ac77aa04f9e23fe90d5e54539ed8e55
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.13.7
|
Release files / autoresearch_nano-1.0.0-py3-none-any.whl
| Download URL | autoresearch_nano-1.0.0-py3-none-any.whl |
|---|---|
| Size | 17.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
9ffd67c29b382e256617c32e1fb4732528323d576807e0b7435347840d233968
|
|
BLAKE2b-256 checksum How to use checksums |
03ab1f5a96580ca02235e6f50c605258fe2849313b7ecb784a93fa521ef2223c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.13.7
|
Security for autoresearch-nano 1.0.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.