The Skill Blind Spot in AI Scaling Laws
Why Knowledge and Code Grow Smarter in Opposite Directions
#AIScalingLaws #ComputeOptimalTraining #LLMPretraining #KnowledgeVsReasoningAI #AIEvaluationLiteracy
Warm-Up: Before reading further, make a quick prediction. Imagine you have a fixed compute budget to train a language model and you must choose between two goals. Goal A is a model that recalls factual trivia accurately. Goal B is a model that writes correct code. For each goal, decide whether you would spend more of your budget on making the model bigger (more parameters) or on feeding it more training text (more tokens), and write down your reasoning in one sentence per goal. Hold onto that prediction. By the end of this lesson you will find out whether your intuition matches what a controlled experiment across nine compute scales and nineteen datasets actually found, and the answer runs counter to how most training budgets get planned.
Who This Is For: This lesson is for machine learning engineers, pretraining researchers and applied scientists who set the parameter count and token budget for a new model and need evidence beyond a single validation loss number. It is equally relevant to AI product leaders and infrastructure planners who approve compute budgets and want to know whether a 'compute optimal' recommendation actually applies to the skill their product depends on. Data scientists who select or build validation sets for model evaluation will find direct guidance on a hidden source of bias in their process. Policy researchers, technical auditors and AI literacy educators who need a rigorous, non-marketing account of how training decisions get made will also benefit. The shared challenge across these roles is that most compute allocation decisions rely on an aggregate loss metric that assumes every downstream skill scales the same way, an assumption this lesson shows to be false.
Real-World Applications
Large AI labs have published scaling law methodologies that treat a single validation loss curve as the basis for deciding how many parameters and how many training tokens a model should use at a given compute budget. The research behind this tests that methodology by comparing the 'compute optimal' point derived from a general validation set against the optimal point measured separately for knowledge-based question answering and for code generation, using the same models and the same compute scales. The results show that these two skills prefer opposite tradeoffs and that the gap between the general recommendation and the skill-specific one can reach nearly fifty percent in parameter count at smaller compute scales. Anyone building a foundation model intended to be strong at both retrieving facts and writing functional code needs to understand this divergence before locking in a training plan.
Lesson Goal
You will learn why a single number for 'optimal model size' breaks down once you separate model performance by skill rather than averaging across a validation set. You will be able to explain the difference between data-hungry and capacity-hungry skills and identify which category a target skill likely falls into. You will also gain a framework for questioning any published scaling law recommendation based on what validation data produced it.
The Problem and Its Relevance
Standard scaling law practice picks one 'compute optimal' parameter count and token budget for an entire model based on the loss measured against a single validation set, treating that number as if it represents every capability the model will eventually be asked to perform. But knowledge-based question answering and code generation, when measured directly rather than through an aggregate proxy, follow scaling behaviors that point in opposite directions under the identical compute budget. A second and separate problem compounds the first: the specific validation set chosen to represent 'general' performance is itself a hidden lever, since swapping one open validation corpus for another changed the estimated optimal parameter count by close to fifty percent at the smallest compute scale tested. In other words, organizations are not just averaging away real differences between skills, they may be encoding the accidental composition of whichever validation corpus they happened to select and calling the result an objective law of model scaling.
Why Does This Matter?
Aggregate loss hides skill-specific tradeoffs. A model optimized against a general validation set will be systematically undersized for knowledge tasks and oversized for code tasks relative to what each skill needs at that compute budget. Teams optimizing for one skill using a general recommendation are working from the wrong starting point.
Knowledge and code are fundamentally different, not just differently represented in training data. Even after correcting for how much knowledge or code content appears in the pretraining mix, knowledge tasks remained more capacity hungry than code tasks. This rules out the simpler explanation that the difference was only an artifact of data proportions.
Validation set choice functions as an unacknowledged design decision. Because different open validation corpora disagreed with each other by more than ten percent even at the largest compute scales tested, the act of choosing a validation set is effectively choosing which skill your training run will be optimized toward, whether or not that choice is made consciously.
Knowledge appears harder to compress than code. As the proportion of knowledge-relevant data in the pretraining mix increased, the optimal parameter count for knowledge tasks grew faster than the optimal parameter count for code grew as code data increased. This suggests memorizing facts requires more raw capacity than learning code patterns, which tend to be more compressible.
Skill alignment through datamix ratio is possible but has tradeoffs. Researchers found that setting code data to roughly 2.1 times the volume of knowledge data caused the two skills to reach the same optimal parameter count, but every validation set tested tracked only one skill or the other, meaning no single validation set actually confirmed that this alignment produced balanced real-world performance.
The gap persists at scale, just smaller. While the parameter count mismatch between validation sets shrinks as compute scale grows, it still exceeded ten percent even at the three largest compute scales tested, showing this is not simply a small-model problem that disappears with more resources.
Core Concepts
Start with the idea of a compute budget. Training a model costs a roughly fixed amount of computation once you decide how many parameters the model has and how many tokens of text it will train on, so for any fixed budget there is a tradeoff between making the model bigger or feeding it more data. Researchers call the specific combination that produces the lowest loss for a given compute budget the 'compute optimum', and traditionally this optimum has been chosen by watching how loss changes on a general validation set as different parameter and token combinations are tried at the same budget. This lesson calls that traditional approach an aggregate performance estimator, since it is estimating a model's overall quality using one number that blends together many different underlying skills.
The key move is separating that one blended number into skill-specific optimums. Instead of only tracking loss on a general validation set, it is important to also track loss specifically on knowledge question answering datasets and specifically on code generation datasets, and find the 'best' parameter and token combination for each skill independently. When a skill's optimal point calls for more parameters than the general aggregate recommendation, that skill is described as capacity hungry. When a skill's optimal point calls for more training tokens instead, that skill is described as data hungry. Knowledge question answering turned out to be capacity hungry across every dataset tested, while code generation turned out to be data hungry across every dataset tested, and this held true whether the researchers looked at their initial hypothesis datasets or a completely separate held-out set of datasets used to confirm the finding.
Three Critical Questions to Ask Yourself
Can you explain, in plain language, the difference between a skill being 'capacity hungry' and a skill being 'data hungry' using the knowledge versus code example from this lesson?
Do you understand why researchers needed to test skill-dependent scaling on a held-out set of datasets before accepting the pattern as real rather than coincidental?
Are you able to identify why the choice of validation set is itself a design decision that shapes which skill a training run gets optimized toward?
Roadmap
Identify the skill your model needs to serve. Before adopting any published compute optimal recommendation, list the specific downstream tasks your model must perform well and classify each one as closer to a knowledge retrieval task or a code or reasoning task based on the patterns described in this lesson. Guidance: If your product mixes both kinds of tasks, expect a single parameter and token combination to underserve at least one of them.
Audit the validation set behind any scaling recommendation you plan to use. Determine what kind of content dominates that validation set, since a knowledge-heavy validation corpus will push you toward larger models while a code-heavy corpus will push you toward more training tokens. Guidance: Ask whether the validation set composition matches the skill composition of your deployment use case, not just whether the validation set is large or well known.
Design a small skill-specific evaluation before committing to a final training budget. Working individually or with a team, sketch what a lightweight held-out evaluation would look like for your target skill, following the hypothesis and held-out split structure used in this lesson's source research, and describe what parameter or token adjustment you would make if your skill turned out to be capacity hungry versus data hungry. Guidance: You do not need to train nine compute scales like the original researchers did, even one additional skill-specific check at your planned compute scale reduces the risk of a mismatched training run.
The Bottom Line
A single compute optimal number is not a fact about a model, it is a fact about whatever validation set produced it, and treating it as a universal law leads organizations to systematically miscalibrate models for the skills those models are actually meant to serve. At the same time, the finding that knowledge and code genuinely differ in how they compress, even after controlling for data proportions, suggests scaling laws may need to become skill-aware as a matter of engineering rigor rather than convenience. The uncomfortable implication worth sitting with is that every published scaling recommendation you have relied on so far was quietly shaped by a validation set nobody asked you to examine.