Unit 4 of 9 · about 6 hours · measure
Identifiable run matrices under a fixed budget and held-out configuration tests
The fixture has already taught the mechanics. Now the evidence must come from your machine, with enough independent variation to challenge the fit.
You'll be able to
- Design a sparse matrix that varies capacity and exposure independently enough for the chosen fit.
- Run a bounded measured decoder sweep with versioned data, tuning and all-attempt accounting.
- Freeze a prediction and acceptance rule before training a configuration excluded from all fitting.
Covers
Read
In this order, only the parts listed
0 of 3 done
- CS336 Spring 2026 Assignment 3: designing a scaling experimentCS336 Assignment 3 - Scaling
Version 26.0.5, Sections 3.1 and 3.3, problem
scaling_laws, including the run-selection and predicted-loss questionsReplace the enrollment-only service with the local sweep below. The public
test_api.pyandtest_scheduler.pytest the training service itself and need a local PostgreSQL server; they are not an offline fitter test suite. Never publish solutions. - Porian et al.: grid, tuning and transfer limitsResolving Discrepancies in Compute-Optimal Scaling of Language Models (Porian et al., 2024)
arXiv:2406.19146v1, Sections 2.2, 2.3, 3.3, 3.5 and 5.2
- Applied Science Research Laboratory: precommitment and lineageApplied Science Research Laboratory - Scaling Study
Core requirements; Architecture constraints; Milestones B and C
Borrow the experiment protocol only, not the capstone scale or its full experiment program.
Focus on
- Use the tested decoder and versioned corpus from lmlab. In PyTorch 2.14.1, pilot three same-family sizes near 10, 20 and 40 million total parameters at a common context of 128 and three terminal token budgets near 0.25, 0.5 and 1 million. Record actual counts, not size labels.
- Reserve a middle-size, middle-token cell before outcomes. Train the other eight cells independently with schedules ending at their own token budgets. Repeat two contrasting fitting cells with three seeds total. Keep one tokenizer, document-disjoint evaluation set, loss mask and loss denominator throughout.
- Cap the measured sweep at a few hours using pilot throughput. If CPU-only or memory-limited, shrink all sizes, contexts or token budgets before freezing the matrix. Preserve three sizes and three exposures, record the reduced regime and avoid frontier claims. Count tuning, retries and evaluation in the budget.
- For a five-parameter surface, inspect the scaled prediction Jacobian for deficient rank and small singular values. Eight cells do not guarantee practical identifiability. If weak, fit one capacity slice or a simpler local model and report the unresolved terms rather than manufacturing exponents.
Common mistakes · 3
- Varying only along one compute contour, then claiming independent capacity and data effects without checking identifiability.
- Counting checkpoints from one trajectory as independently trained terminal runs. A schedule designed for the longest run changes the treatment at earlier checkpoints.
- Tuning the fit after seeing the reserved loss and still calling the configuration held out. A revised fit needs a new confirmatory configuration.
Try it yourself
Closed-book, before checking anything
Quiz yourself
Answer first, then mark it. Missed ones go to Review.
0 got · 0 missed
1.Why is holding out documents not the same as holding out a configuration?Answer
Document holdout tests language-model generalization. Configuration holdout tests the fitted response model on a model-and-token setting it did not use. Both boundaries are needed.
2.Can a full-rank Jacobian certify the scaling law?Answer
No. It is a local identifiability diagnostic under the assumed form and parameter values. Conditioning, noise, optimization and misspecification can still make estimates unstable.
3.What should you do when the fitted surface is unstable?Answer
Report the instability. Narrow the question to an identifiable slice or simpler model, or use the reserved experiment budget to vary the confounded factors. Do not report a precise joint allocation.
You're done when
Your fitting runs are measured and versioned, your fit has a defensible identifiability audit, and the reserved configuration has a committed prediction but has not yet been run.
Only when you can do this without notes.
Leads to
Notes
Resources · 3 for this unit, 14 more in the section
- CS336 Assignment 3 - ScalingStanford University · primary
Read the handout Sections 2 and 3, then fit IsoFLOP profiles and a scaling law to the public
data/isoflops_curves.jsonwith residuals and one held-out prediction. The hosted training API and leaderboard need enrollment, and the tests need postgres and keys, so the graded half is out of reach; add a small local sweep of your own and keep the failed runs. Pair it with the Lecture 9 and 11 slides (lecture_09.pdf,lecture_11.pdfinstanford-cs336/lectures). - Resolving Discrepancies in Compute-Optimal Scaling of Language Models (Porian et al., 2024)Tel Aviv University and University of Washington · required
Read Figure 1 and Sections 3 to 5: the Kaplan and Chinchilla allocation gap closes once last-layer FLOPs, warmup length and scale-dependent optimizer tuning are fixed. It also gives learning-rate and batch-size fits and shows AdamW beta2 matters at small batches.
- Applied Science Research Laboratory - Scaling StudyRoadmap-Final · support
Borrow the preregistration, matched-budget, uncertainty, residual and negative-result requirements for the scaling experiment.
Also in this section
- Scaling Laws for Neural Language ModelsOpenAI · required
Read Sections 1 and 2 (the three power laws in Equations 1.1 to 1.3), Figure 1 and Section 6 (optimal allocation). Reproduce one fit and list every assumption that differs from your experiment: fixed batch size, one schedule length and single-epoch data. Read Porian et al. before trusting its allocation rule.
- Training Compute-Optimal Large Language ModelsGoogle DeepMind · required
Study Figure 1, Section 3.2 (IsoFLOP profiles over nine compute budgets), Section 3.3 (the parametric loss in Equation 2) and Appendix D.2 (the fitted constants in Equation 10). Recreate the conclusion only within the range your run matrix supports; read Besiroglu et al. on the Approach 3 fit.
- Chinchilla Scaling: A Replication Attempt (Besiroglu et al., 2024)Epoch AI · support
Read all seven pages after Chinchilla: the Approach 3 estimates disagree with Approaches 1 and 2, the reported intervals are implausibly narrow, and refitting reconstructed data restores agreement. It targets Approach 3, not the IsoFLOP evidence.
- DeepSeek LLM, Section 3 (Scaling Laws)DeepSeek-AI · support
Read Sections 3.1 and 3.2: batch-size and learning-rate trends with compute, and the model and data allocation fit. Its data mix is bilingual, so the exponents are specific to it.
- Data Mixing Laws: Optimizing Data Mixtures by Predicting Language Modeling Performance (Ye et al., 2024)Fudan University · support
Read Section 3 (the exponential law for per-domain loss as a function of mixture proportions, Equations 1 and 6) and Table 1. It interpolates within tested proportions; it does not extrapolate.
- The Curse of Recursion: Training on Generated Data Makes Models Forget (Shumailov et al.; Nature 2024)University of Oxford · support
Read Sections 1 to 4 on model collapse: training on generated data loses the tails of the original distribution. Keep it beside every synthetic-data decision; it does not show that any synthetic data collapses a model.
- The Smol Training Playbook - Scaling Laws and Data MixtureHugging Face · support
Read the scaling-laws section and the SmolLM3 data-mixture ablations for how a small team chose model size, token count and mixture under a fixed budget. Cite section names; the numbers are specific to SmolLM3.
- 2 OLMo 2 Furious, Section 4 (Mid-training Recipe)Allen Institute for AI · support
Read Sections 4.1 to 4.5: learning-rate annealing, the Dolmino mid-training mix, math microanneals and checkpoint soups. It is the curriculum and annealing case the scaling papers lack.
- Modern LLM Notebook - Scaling LawsWalking Labs · support
Use
notebooks-en/part2-training/14-scaling-laws.ipynbfor a compact bridge among Kaplan, Chinchilla, muP, FLOPs and memory. Treat its calculations as exercises to verify, not as evidence for extrapolation; its prices are dated samples. - TensorTonic - Scaling Laws I and IITensorTonic · support
Solve Fit a Data Power Law with a Noise Floor (
cs336-l09-fit-data-power-law), Extrapolate Data-Mixture Scaling Curves (cs336-l09-data-mixture-extrapolation), Estimate Critical Batch Size (cs336-l09-critical-batch-size), Recover an IsoFLOP Compute-Optimal Frontier (cs336-l09-isoflop-optimal-frontier), Fit Learning-Rate and Batch-Size Scaling (cs336-l11-hyperparameter-scaling-fit) and Diagnose muP Width Invariants (cs336-l11-mup-invariant-diagnostics). Supplied-data drills are preparation, not a measured scaling result. Public test cases check the listed edge cases, not gradients or the hidden grader, so keep your own tests beside each solution. - Scaling Data-Constrained Language ModelsHugging Face Research · depth
Read Section 3 (the data-constrained law, in which repeated tokens lose value at a fitted rate), Appendix A (its derivation) and Sections 5 and 6 (up to about four epochs of repetition cost little; returns fall quickly after that), then inspect the reproducibility repository (https://github.com/huggingface/datablations). Use one small repeated-data experiment to challenge the compute-optimal assumption.
- DoReMi: Optimizing Data Mixtures Speeds Up Language Model Pretraining (Xie et al., 2023)Stanford and Google · depth
Read Section 2 (Group DRO over domain weights with a small proxy) and Section 4. A larger proxy can do worse, so proxy scale does not transfer automatically.
- Beyond Chinchilla-Optimal: Accounting for Inference in Language Model Scaling Laws (Sardana et al., 2024)Databricks · optional
Read Section 2 (training plus inference cost for a target quality and inference demand) and Sections 4 and 6 (results and real-world cost). Its demand model is illustrative.
- Maximal Update Parametrization: width-transfer checksMicrosoft Research · support
Read Basic Usage, How mup Works Under the Hood, Current Limitations, and Coord Check through Tips for Coord Check at commit 1981497. Use as a design reference, not an installation requirement; skip Wider is Always Better, which is not a finite-run guarantee.