:thread: AutoResearch: This thread will be for dis...
# ml-and-mlops-questions
p
🧵 AutoResearch: This thread will be for discussing and sharing about building with AutoResearch
The idea: give an AI agent a small but real LLM training setup and let it experiment autonomously overnight. It modifies the code, trains for 5 minutes, checks if the result improved, keeps or discards, and repeats.
https://github.com/karpathy/autoresearch Try to learn or build something with Tavily by April 17th!
f
So far I'm having good success on this project. I deployed a T4 in Google Cloud and have the training results going to a Google Firestore nosql db. I'll then use prior Gradio investments to show results
🦜 1
p
Awesome! Are you using claude for the LLM/agent? I am, but looking to try an open model too that I can run so I don't burn all my credits!
f
i'm using claude
šŸ‘ 1
I stated my prod run about 40 min ago. its working
šŸ”„ 1
p
Awesome!!!
f
results are looking good
p
This is a cool chart!
I just did a test run with local qwen coder and getting some ok results. going to try gemma 4. I provide more instructions in the markdown than to claude.
Are you training LLM the example from the repo or something else? So far I'm just testing the example
f
Started from Karpathy's nanoGPT-style example as the base architecture, not just running it as-is. With the help from Claude, built an autonomous agent loop on top of it that: • Reads the current
train.py
• Asks Claude to propose one focused change (hyperparameters, architecture, optimizer settings, etc.) • Runs training, measures validation loss • Keeps the change if it improves, reverts if it doesn't • Repeats overnight on a GCP T4 GPU So the model being trained is a small GPT (~25M params) on the TinyStories dataset — because of using the T4 GPU
🦜 1
Here is the complete list of changes from the base (Kaparthy's original) Hardware compatibility (T4 vs H100) • Replaced Flash Attention 3 kernel with
F.scaled_dot_product_attention
— T4 doesn't support the custom FA3 kernel •
WINDOW_PATTERN
changed from
"SSSL"
to
"LLLL"
— sliding window attention requires Flash Attn 3 •
DEVICE_BATCH_SIZE
reduced from 128 → 16 to fit T4's 16GB VRAM Training loop fixes Fixed
train_loss
to accumulate correctly across all
GRAD_ACCUM_STEPS
micro-batches — original only captured the last micro-batch loss • Added a 3-step warmup probe at startup to dynamically estimate
total_steps
for the LR schedule — original assumed a fixed step count Dataset • Pointed data loading at TinyStories
data/
directory instead of the original dataset Agent-discovered at runtime (not our code changes) •
TOTAL_BATCH_SIZE
reduced from
2^17 → 2^14
across three consecutive experiments — smaller batches = more optimizer steps in the 5-minute window = better convergence on a time-budgeted T4 run