← TinyGPT · docs · devlog · roadmap · speedup
source: docs/prds/5.1-reasoning-on-22M.md · view on GitHub ↗

PRD — Reasoning training on a 22M-class model

Goal

Train a 22M-class model with reasoning-style supervision (GRPO / DAPO on verifiable rewards; SFT-on-traces as the warm-up), publish the negative result if (as expected) chain-of-thought capability does not emerge at this scale. Publishable shape: “smallest model where RLVR demonstrably fails to elicit CoT; here’s the scaling-curve intercept.”

Tier-5 research arc. Estimated 5–7 days end-to-end. The deliverable is a paper-shaped artifact + reproducible code + a single scaling-curve data point — not a polished UX feature.

Why now

Scope — in

Scope — out

Files to touch

FileChange
Sources/TinyGPT/Grpo.swiftnew — RL loop
Sources/TinyGPTModel/AdvantageNormalizer.swiftnew — group-relative advantage compute
Sources/TinyGPT/TinyGPT.swiftcase "grpo"
Sources/TinyGPT/SftOnTraces.swiftnew (or extend SFT.swift) — load DeepSeek-R1-distill JSONL, sequence-pack
docs/research/reasoning-22m-results.mdnew — the paper-shaped artifact
evals/grpo-smoke.shnew — 20-step GRPO on a 10-prompt GSM8K subset; assert reward signal is non-degenerate
docs/PLAN.mdflip 5.1 ⬜ → ✅ on ship (regardless of positive/negative result)

Don’t touch

Acceptance criteria

Reference patterns

Open questions