The Scaling Laws of Skills in LLM Agent Systems

arXiv cs.CL Papers

Summary

This paper identifies two coupled scaling laws for skill libraries in LLM agent systems: routing accuracy decays logarithmically with library size, and execution dynamics show a rescue effect. The laws are validated across 15 models and over a million decisions, and law-guided optimization significantly improves performance.

arXiv:2605.16508v1 Announce Type: new Abstract: As agent systems scale, skills accumulate into large reusable libraries, yet their scaling laws remain poorly understood. Across 15 frontier LLMs, 1,141 real-world skills, and over 3M routing or execution decisions, we identify two coupled laws. Routing law: single-step routing accuracy decays logarithmically with library size ($R^2{>}0.97$ for all models), with errors progressing from local skill competition to cross-family drift and capture by overly general "black-hole skills". Execution law: before state realization, joint routing is approximately multiplicative, whereas correct execution can improve difficult downstream decisions by about $4{\times}$. A single parameter, the routing logarithmic decay slope $b$, couples the two laws: routing-side fits predict execution-side rescue across models, showing that the same library property controls both pre-execution collapse and downstream recoverability. The laws are actionable: law-guided optimization raises held-out routing accuracy from 71.3% to 91.7%, reduces hijack from 22.4% to 4.1%, and transfers directionally to downstream ClawBench and ClawMark execution settings, improving mean pass rate from 49.3% to 61.6% on ClawBench and from 28.4% to 34.5% on ClawMark. These results show that agent performance depends not only on model capability, but also on the structure, granularity, and exposure policy of the skill library.
Original Article
View Cached Full Text

Cached at: 05/19/26, 06:34 AM

# The Scaling Laws of Skills in LLM Agent Systems
Source: [https://arxiv.org/html/2605.16508](https://arxiv.org/html/2605.16508)
\\papertags\\evolventtag

LLM Agents\\evolventtagSkill Libraries\\evolventtagScaling Laws

###### Abstract

As agent systems scale, skills accumulate into large reusable libraries, yet their scaling laws remain poorly understood\. Across 15 frontier LLMs, 1,141 real\-world skills, and over 3M routing or execution decisions, we identify two coupled laws\.Routing law: single\-step routing accuracy decays logarithmically with library size \(R2\>0\.97R^\{2\}\{\>\}0\.97for all models\), with errors progressing from local skill competition to cross\-family drift and capture by overly general “black\-hole skills”\.Execution law: before state realization, joint routing is approximately multiplicative, whereas correct execution can improve difficult downstream decisions by about4×4\{\\times\}\. A single parameter, the routing logarithmic decay slopebb, couples the two laws: routing\-side fits predict execution\-side rescue across models, showing that the same library property controls both pre\-execution collapse and downstream recoverability\. The laws are actionable: law\-guided optimization raises held\-out routing accuracy from 71\.3% to 91\.7%, reduces hijack from 22\.4% to 4\.1%, and transfers directionally to downstreamClawBenchandClawMarkexecution settings, improving mean pass rate from 49\.3% to 61\.6% onClawBenchand from 28\.4% to 34\.5% onClawMark\. These results show that agent performance depends not only on model capability, but also on the structure, granularity, and exposure policy of the skill library\.

![[Uncaptioned image]](https://arxiv.org/html/2605.16508v1/x1.png)## 1Introduction

As agent systems develop, skills increasingly accumulate into reusable libraries\[wang2024survey,xu2025llm,yehudai2025survey\]\. Early action\-selection systems\[schick2023toolformer,qin2023toolllm,patil2023gorilla\]and benchmarks\[li2023apibank,shen2023taskbench\]showed that language models can select from large sets of callable interfaces\. More recent skill\-centric work\[li2026skillsbench,zheng2026skillrouter\]further treats reusable skills as a central abstraction for building capable agents\[chen2025towards,chen2025ai4research,gao2025survey,xu2026agent\]\. Together, these systems suggest a natural scaling premise: expanding a skill library should enlarge the space of behaviors available to an agent, while remaining failures can be attributed to limited model capability or imperfect routing\.

This shifts the central question from “can the model use a skill?” to “how does a growing skill library reshape the agent’s routing and execution dynamics?” Existing benchmarks typically vary tasks, models, or action formats, but keep the library as background infrastructure\. We instead make library size and structure the object of study\. The resulting failure mode is not ordinary hallucination\. In our plain\-text routing protocol, vague prompts can yield 0% hallucinated skill names while task\-level routing accuracy falls to 18\.3% and in\-library hijack exceeds 80%\. The model stays inside the library, but lands in the wrong part of it\.

![Refer to caption](https://arxiv.org/html/2605.16508v1/x2.png)Figure 1:Skill\-library scaling laws and optimization implications\.\(a\)Reusable skills accumulate into larger exposed libraries\. Routing accuracy decays approximately linearly withlog⁡N\\log N, with model\-dependent slopebb\.\(b\)Errors progress from local competition to cross\-family drift and finally capture by overly general “black\-hole” skills\.\(c\)Execution separates pre\-state compounding from post\-state rescue\.\(d\)The same library property links routing collapse and execution rescue:bbpredicts rescue across models without refitting\.\(e\)The laws suggest concrete optimization actions: audit neighbors, rewrite confused pairs, strengthen prompts, and apply additional manager actions\.To address this problem, we characterize this behavior through empirical laws of skill libraries\. Across 15 frontier LLMs, 1,141 real\-world skills, and over 3M routing or execution decisions, we find two coupled empirical laws\. The*routing law*governs the pre\-execution regime: single\-step accuracy followsA​c​c​\(N\)=a−b​ln⁡NAcc\(N\)=a\-b\\ln NwithR2\>0\.97R^\{2\}\{\>\}0\.97for every model, while errors progress from local competition among neighboring skills to cross\-family drift and finally capture by overly general “black\-hole” skills\. The*execution law*starts after state is realized\. Before any artifact exists, multi\-skill routing composes approximately multiplicatively; after correct execution, concrete state can rescue difficult downstream decisions, producing about a4×4\{\\times\}gain on hard pairs\. Thus execution does not simply add another chance to fail\. It can either propagate bad state or provide evidence that disambiguates the next route\. The two laws are connected by a single interpretable parameter: the routing decay slopebb\. A largerbbmeans that accuracy collapses sooner as the library grows, reducing the probability that correct upstream state is available for downstream rescue\. Conversely, when routing\-side fits are combined with an independently measured rescue coefficient,bbpredicts execution\-side rescue across models without refitting \(ρ=0\.74\\rho\{=\}0\.74,p<0\.001p\{<\}0\.001\)\. This coupling is the central result of the paper: the same library property that controls pre\-execution routing collapse also controls whether execution can provide useful downstream state\. It turns the laws from retrospective descriptions into design constraints: reduce local competition, sharpen skill boundaries, remove abstract attractors, and expose execution state when it is likely to help\.

Guided by these laws, we instantiate a law\-guided auto skill manager at the law\-predicted transition point for median\-bbagents\. The manager applies four library\-side actions: nearest\-neighbor auditing, description\-boundary rewriting, abstract\-skill removal, and prompt anchoring\. On 1,600 held\-out tasks, it improves routing accuracy from 71\.3% to 91\.7% and reduces the hijack rate from 22\.4% to 4\.1%\. Factorial ablations identify boundary rewriting \(\+12\.8%\) and abstract\-skill removal \(\+4\.9%\) as the main contributors, consistent with the predicted failure stages\. The same design transfers directionally to downstreamClawBench/ClawMarkexecution settings: mean pass rate improves from 49\.3% to 61\.6% onClawBench, and from 28\.4% to 34\.5% onClawMark\.

Our contributions are:

- •Two\-stage laws of skill libraries\.We establish coupled routing and execution laws that characterize how large skill libraries fail before state is realized and recover after correct execution\.
- •A unified law structure for skill libraries\.We show that the routing decay slopebblinks library\-scale routing collapse to execution\-side rescue across models without refitting\.
- •Guidance for optimizing skill\-based agent systems\.We turn the laws into library optimization methods for exposure control, boundary rewriting, attractor removal, and execution\-state use, with downstream validation\.

## 2Related Work

Our work sits at the intersection of skill routing, execution\-aware agent systems, and scaling laws\. Existing work studies how agents select or use external capabilities, but not the coupled routing and execution laws that appear as the skill library itself scales\.

Routing over external capabilities has been studied through callable\-interface systems, agent benchmarks, and skill\-centric agents\. Toolformer\[schick2023toolformer\], ToolLLM\[qin2023toolllm\], ToolAlpaca\[tang2023toolalpaca\], Gorilla\[patil2023gorilla\], API\-Bank\[li2023apibank\], TaskBench\[shen2023taskbench\], OpenAgents\[xie2023openagents\], AgentBench\[liu2023agentbench\], and recent surveys and skill\-focused work\[wang2024survey,xu2025llm,yehudai2025survey,xu2026agent,jiang2026agenticskills,li2026skillsbench,zheng2026skillrouter\]establish large external action spaces as a core agent interface\. Closest to our routing setting, ComplexFuncBench\[zhong2025complexfuncbench\]studies multi\-step function selection, BiasBusters\[blankenstein2025biasbusters\]studies systematic selection bias, and xRouter, EvoRoute, AutoTool, and MetaToolAgent optimize routing or tool choice\[qian2025xrouter,zhang2026evoroute,jia2025autotool,fang2026metatoolagent\]\. These works usually vary task difficulty, router policy, or benchmark domain rather than treating skill\-library size and geometry as the scaling axis\.

Execution\-aware agent systems study how intermediate state, feedback, and multi\-step interaction change downstream behavior\. ReAct\[yao2023react\], Plan\-and\-Solve\[wang\-etal\-2023\-plan\], Reflexion\[shinn2023reflexion\], HuggingGPT\[shen2023hugginggpt\], MetaGPT\[hong2023metagpt\], and Voyager\[wang2023voyager\]show that traces, artifacts, feedback, and orchestration can improve end\-to\-end completion\[qiao2023taskweaver,wang2023mint,du2024anytool,yehudai2025survey,shen2025evaluationbenchmarkingllmagents\]\. Our execution law isolates a narrower mechanism: before concrete state appears, multi\-skill routing is close to multiplicative composition; after correct execution, realized artifacts can rescue difficult downstream routing\.

Our contribution is to connect these strands through empirical laws for skill\-library scaling\. Prior scaling laws study compute, data, model size, or training allocation\[kaplan2020scaling,hoffmann2022chinchilla,wei2022emergent,roberts2025compute,wu2026educational\]; retrieval and representation work explains dense candidate neighborhoods\[karpukhin2020dpr,lewis2020rag,reimers2019sbert,muennighoff2023mteb\]; and the Hick\-Hyman law gives a logarithmic analogue for capacity\-limited choice\[hick1952rate,hyman1953stimulus\]\. We instead scale the inference\-time skill library and show that routing decay, error cascades, black\-hole capture, and execution\-side rescue are coupled by a unified parameter\.

## 3Problem Formulation & Experimental Setup

##### Problem formulation\.

Let𝒮N=\{s1,…,sN\}\\mathcal\{S\}\_\{N\}=\\\{s\_\{1\},\\ldots,s\_\{N\}\\\}be the exposed skill library, where each skill has a selectable name, a natural\-language description, and an execution interface\. Each taskqqhas a gold skills⋆​\(q\)∈𝒮Ns^\{\\star\}\(q\)\\in\\mathcal\{S\}\_\{N\}; that is, the required skill is present in the exposed library by construction\. We therefore study availability\-preserving failures: the model has access to the necessary skill but may select a wrong in\-library alternative\. We study two regimes\. In a*routing trial*, the model sees onlyqqand the skill descriptions, and the routerℛθ\\mathcal\{R\}\_\{\\theta\}\(LLMθ\\theta\) proposes

s^=ℛθ​\(q,𝒮N\),\\hat\{s\}=\\mathcal\{R\}\_\{\\theta\}\(q,\\mathcal\{S\}\_\{N\}\),\(1\)wheres^\\hat\{s\}may be correct, wrong but in\-library, out\-of\-library, or an abstention\. In an*execution trial*, routing and execution are interleaved acrossKKsteps or sub\-tasks within a pipeline\. At stepkk, the model routes with contextckc\_\{k\}and then executes the selected skill:s^k=ℛθ​\(qk,𝒮N,ck\),yk=ℰθ​\(qk,s^k,ck\),\\hat\{s\}\_\{k\}=\\mathcal\{R\}\_\{\\theta\}\(q\_\{k\},\\mathcal\{S\}\_\{N\},c\_\{k\}\),\\qquad y\_\{k\}=\\mathcal\{E\}\_\{\\theta\}\(q\_\{k\},\\hat\{s\}\_\{k\},c\_\{k\}\),whereyky\_\{k\}is the realized artifact andckc\_\{k\}contains the task, skill descriptions, and, after execution begins, upstream artifactsy<ky\_\{<k\}\. Thus routing trials isolate selection before state realization, while execution trials test how realized state changes downstream routing\.

The primary routing metric is

A​c​c​\(N\)=Pr⁡\[ℛθ​\(q,𝒮N\)=s⋆​\(q\)\]\.Acc\(N\)=\\Pr\[\\mathcal\{R\}\_\{\\theta\}\(q,\\mathcal\{S\}\_\{N\}\)=s^\{\\star\}\(q\)\]\.\(2\)Errors are partitioned into*in\-library hijack*\(s^∈𝒮N\\hat\{s\}\\in\\mathcal\{S\}\_\{N\},s^≠s⋆\\hat\{s\}\\neq s^\{\\star\}\),*hallucination*\(s^∉𝒮N\\hat\{s\}\\notin\\mathcal\{S\}\_\{N\}\), and abstention\. For route\-only pipelines, withsk⋆=s⋆​\(qk\)s^\{\\star\}\_\{k\}=s^\{\\star\}\(q\_\{k\}\),

A​c​c​\(N,K\)=Pr⁡\[s^k=sk⋆​for all​k=1,…,K\]\.Acc\(N,K\)=\\Pr\[\\hat\{s\}\_\{k\}=s^\{\\star\}\_\{k\}\\;\\text\{for all \}k=1,\\ldots,K\]\.\(3\)We compare joint success to the multiplicative baseline implied by independent routing\. Execution trials additionally score artifact correctnessQk∈\{0,1\}Q\_\{k\}\\in\\\{0,1\\\}; in two\-step analyses,AAdenotes the upstream step andBBthe downstream step, and we measure how correct or wrong state fromAAchanges routing or quality onBB\. See Append\.[A](https://arxiv.org/html/2605.16508#A1)for more mathematical details\.

##### Experimental setup\.

The scaled library contains 1,141 real\-world software\-agent skills from public Agent Skills, Claude Code, MCP, and community GitHub repositories after near\-duplicate removal\[anthropic2025skillsrepo,anthropic2025claudecode,anthropic2024mcp,trailofbits2025skills,daymade2025skills,aaronontheweb2025dotnetskills,team2026pinchbench,robhunter2026agentdeals\]\. Near\-duplicates are removed with BAAI/bge\-m3 embeddings\[bge2023\]\(cosine\>0\.95\>0\.95\), and the resulting skills are organized into 14 software\-automation domains\. Human annotators constructed 4,075 tasks from predefined skill combinations, with GPT\-5\.4 assistance only for task synthesis; we retain only tasks with unanimous gold\-skill annotations \(κ=0\.91\\kappa\{=\}0\.91,∼9%\{\\sim\}9\\%excluded\)\. In addition, we integrate queries from Terminal\-Bench\[merrill2026terminal\],τ\\tau\-Bench\[yao2024tau\],τ2\\tau^\{2\}\-Bench\[barres2025tau\], FlowBench\[xiao\-etal\-2024\-flowbench\], PinchBench\[team2026pinchbench\], and related sources, further expanding them and adding tool annotations\.

For a size\-NNrouting condition, we include the gold skill for each task and fill the remainingN−1N\{\-\}1slots with domain\-stratified distractors sampled without replacement; this keeps the target distribution fixed while changing library exposure\. We use deterministic decoding where provider APIs permit it, parse the first skill\-name span returned by the model, and score unmatched names as hallucinations rather than forcing a nearest match\. Unless otherwise specified, each case is evaluated an average of four times\. Main routing curves sweepN∈\{10,20,50,100,200,500\}N\\in\\\{10,20,50,100,200,500\\\}andK∈\{1,2,3,5,10\}K\\in\\\{1,2,3,5,10\\\}withn=500n\{=\}500domain\-stratified tasks per condition\. We fitA​c​c​\(N\)=a−b​ln⁡NAcc\(N\)=a\-b\\ln Nby ordinary least squares over the swept sizes and report Wilson intervals for binomial rates; cross\-model correlations use Spearmanρ\\rhowith percentile bootstrap confidence intervals\. Appendix[C\.1](https://arxiv.org/html/2605.16508#A3.SS1)reports per\-model fits, and Appendix[C\.3](https://arxiv.org/html/2605.16508#A3.SS3)gives retrieval / router baselines and task\-difficulty controls\.

We evaluate 15 LLMs: GPT\-4o\-mini\[openai2024gpt4omini\], GPT\-5\-mini\[openai2025gpt5\], GPT\-5\.4\-mini\[openai2026gpt54mini\], GPT\-5\.4\[openai2026gpt54\], Claude Sonnet 4\.6\[anthropic2026sonnet\], Claude Opus 4\.6\[anthropic2026api\], Gemini 3\.1 Pro, Gemini 3\.1 Flash Lite\[gemini2025gemini3\], GLM\-5\[zai2026glm\], GLM\-4\.7\[zai2026glm47\], Kimi K2\.5\[moonshot2026k25\], Kimi K2\.6\[moonshot2026k26\], Doubao Seed 2\.0 Pro\[bytedance2026seed20\], DeepSeek\-V4 Pro\[deepseek2025v4\], and Qwen3\-235B\[qwen2025qwen3235b\]\. Routing uses plain\-text single\-skill selection unless stated otherwise, so hallucinations remain measurable\. Constrained routing is used only for execution\-side isolation and conditions where valid in\-library selection must be enforced; it is not pooled into the plain\-text hallucination or hijack analyses\. Prompts are in Appendix[B](https://arxiv.org/html/2605.16508#A2)\. Optimization experiments use the same held\-out routing protocol as the diagnostic studies\.

This section analyzes the routing law before execution: the model observes a task and skill descriptions, choosess^\\hat\{s\}, and has no execution artifactyky\_\{k\}in context\. The central effect is not just that larger libraries contain more candidates; they also create denser neighborhoods of plausible alternatives, so scale changes both the rate and the geometry of routing errors\.

![Refer to caption](https://arxiv.org/html/2605.16508v1/x3.png)Figure 2:Library scale induces logarithmic single\-step decay, super\-independent pipeline loss, and a mid\-chain routing trough\.We first ask whether increasingNNonly adds independent choices or changes the structure of the routing problem\. For eachNN, every trial exposes the gold skill plus sampled distractors from the same domain mixture; for route\-only pipelines, theKKgold skills are fixed and only the exposed distractor set changes\. First, single\-step routing accuracy decreases almost linearly withln⁡N\\ln N\(Fig\.[2](https://arxiv.org/html/2605.16508#S3.F2)\(a\)\)\. Second, three\-step routing plans fall below the accuracy predicted by independently repeating the single\-step selector \(Fig\.[2](https://arxiv.org/html/2605.16508#S3.F2)\(b\)\)\. Library scale therefore weakens individual decisions and also makes planned sequences more error\-prone\.

Together, these results give the first part of the routing law\. The logarithmic decay suggests a finite discrimination budget: asNNgrows, the target skill faces more nearby competitors \(Sec\.[5](https://arxiv.org/html/2605.16508#S5)\)\. The compounding result explains why this single\-step loss becomes worse in planned sequences \(Fig\.[2](https://arxiv.org/html/2605.16508#S3.F2)\(c\)\)\. A wrong early route moves the plan into the wrong semantic neighborhood, making later routes more likely to fail\. The U\-shape in Fig\.[2](https://arxiv.org/html/2605.16508#S3.F2)\(d\) then locates the fragile point: middle steps inherit most plausible continuations, while terminal steps partially recover when the final goal narrows the choice set\. Append\.[A](https://arxiv.org/html/2605.16508#A1)&[B\.7](https://arxiv.org/html/2605.16508#A2.SS7)report mathematical analysis and supplemental cascade diagnostics\.

Routing Scaling law\.Single\-step routing followsA​c​c​\(N\)=a−b​ln⁡NAcc\(N\)=a\-b\\ln NwithR2\>0\.97R^\{2\}\{\>\}0\.97; each doubling costs≈3\\approx 3percentage points\. In planned route\-only pipelines, the loss compounds asA​c​c​\(N,K\)≈\(a−b​ln⁡N\)γ​KAcc\(N,K\)\\approx\(a\-b\\ln N\)^\{\\gamma K\}with empirical exponentγ=6\.7​b\+1\.09\\gamma\{=\}6\.7b\+1\.09\. Per\-step accuracy is U\-shaped: middle steps are more error\-prone than the first or last\.

Having established the decay law, we next ask what drives its slopebb\. Our hypothesis is simple: before execution state is available, routing depends on how clearly the target skill is separated from similar but distinct skills\. We test this by varying description quality while holding the task, gold skill, distractor set, and model fixed\. More distinguishable descriptions improve accuracy and reduce decay, showing that skill boundaries matter \(Fig\.[3](https://arxiv.org/html/2605.16508#S3.F3)\(a\)\)\.

Boundary quality, however, does not explain all errors\. We therefore analyze where the remaining mistakes occur\. Fig\.[3](https://arxiv.org/html/2605.16508#S3.F3)\(b, c\) shows that errors concentrate around intermediate\-similarity skills: alternatives that are close enough to be plausible, but not close enough to trigger obvious disambiguation\. Exposing more candidates can therefore hurt when it adds these near\-miss alternatives\.

Together, these results isolate two sources of routing difficulty: description quality defines the target skill, while local competition reflects nearby alternatives\. Hence, global library size is only a coarse proxy: crowded neighborhoods remain difficult despite better descriptions, andC​ICIpredicts per\-skill failures better thanNNalone \(Fig\.[3](https://arxiv.org/html/2605.16508#S3.F3)\(d\)\)\. The L4→\\toL5 paradox follows: in small libraries, counterexamples sharpen boundaries; at scale, they may instead foreground plausible confusers and redirect attention to the alternatives they aim to exclude \(Append\.[A](https://arxiv.org/html/2605.16508#A1)&[C\.2](https://arxiv.org/html/2605.16508#A3.SS2)\)\. Appendix[C\.4](https://arxiv.org/html/2605.16508#A3.SS4)further tests the mechanism by directly manipulating skill\-boundary distances\.

Semantic competition mechanism\.Description quality changes the effective slope:P​\(N,ℓ\)=aℓ−bℓ​ln⁡NP\(N,\\ell\)=a\_\{\\ell\}\-b\_\{\\ell\}\\ln N, with L1 name\-only descriptions at1111–72%72\\%and L4 constraint/example descriptions at7171–90%90\\%\(bL1=0\.32b\_\{\\mathrm\{L1\}\}\{=\}0\.32vs\.bL4=0\.08b\_\{\\mathrm\{L4\}\}\{=\}0\.08\)\. Remaining errors are local: 94% stay inside the correct cluster, and the danger zone is intermediate similarity\[0\.55,0\.75\)\[0\.55,0\.75\)\. In this band,A​c​c=A/\(A\+C​I\)Acc=A/\(A\+CI\), andC​ICIpredicts errors better thanNNalone \(RCI2=0\.55R^\{2\}\_\{\\mathrm\{CI\}\}\{=\}0\.55vs\.RN2=0\.26R^\{2\}\_\{N\}\{=\}0\.26; see Append\.[C\.4](https://arxiv.org/html/2605.16508#A3.SS4)for the definitions ofC​ICI,AA, andβ\\beta\)\.

![Refer to caption](https://arxiv.org/html/2605.16508v1/x4.png)Figure 3:Local Competition Organizes Error\.\(a\)Accuracy decays withNNin all description regimes, but better descriptions reduce the decay rate\.\(b\)Top\-50 introduces more errors than Top\-20/10\.\(c\)Danger band\[0\.55,0\.75\)\[0\.55,0\.75\)shows strongest negativeρ\\rhowith accuracy\.\(d\)The Boltzmann fit between the competition index and accuracy within the danger zone, whereRCI2=0\.55R^\{2\}\_\{\\mathrm\{CI\}\}\{=\}0\.55, outperforms the fit withNNalone, whereRN2=0\.26R^\{2\}\_\{N\}\{=\}0\.26\.After identifying what controls the slope, we examine where lost probability mass is redistributed\. We construct paired conditions by preserving the underlying task intent while removing concrete nouns, file names, tool\-specific verbs, or schema anchors from the query; skill\-anchor ablations similarly remove boundary clauses from candidate descriptions while preserving names and interfaces\. The pattern is ordered: strong task\-query anchors induce local substitution, weak anchors induce in\-library drift, and weak anchors combined with vague skills induce “black\-hole skill” capture\.

In\-library drift emerges as task anchors weaken \(Fig\.[4](https://arxiv.org/html/2605.16508#S3.F4)\(a\)\)\. Concrete prompts with strong anchors remain highly accurate atN=100N\{=\}100\(89\.7%89\.7\\%–98\.3%98\.3\\%\)\. The drift is structured: errors concentrate within the target skill’s functional family and increase with library size as anchors weaken \(Fig\.[4](https://arxiv.org/html/2605.16508#S3.F4)\(b, c\)\)\. This suggests that the model preserves coarse task information but fails to reliably select the correct skill within the same functional cluster\. The final stage is black\-hole capture, where a few skills become attractors with much higher Gini coefficients \(Fig\.[4](https://arxiv.org/html/2605.16508#S3.F4)\(d\)\)\. As the library grows, broad high\-abstraction skills absorb disproportionate routing mass \(Fig\.[4](https://arxiv.org/html/2605.16508#S3.F4)\(e\)\)\. To further characterize this pattern, we analyze routing\-mass distributions across skills\. Capture occurs only when both skill\-anchor removal and vague queries are present \(Fig\.[4](https://arxiv.org/html/2605.16508#S3.F4)\(f\)\)\.

Drift and attractor mechanism\.With strong anchors, errors are geometrically local substitutions within the same functional family\. Weak anchors break this locality: accuracy collapses, but the model still prefers existing skills over hallucinated names\. Black\-hole capture is conjunctive, not additive: neither weak task anchors nor vague skills are sufficient alone, but together they induce attractor routing\.

![Refer to caption](https://arxiv.org/html/2605.16508v1/x5.png)Figure 4:Weak task anchors and vague skill descriptions convert local skill\-cluster drift into black\-hole skill capture\.

## 4Execution Law: State Realization

The execution law begins where the routing law ends: a selected skill may produce state\. We distinguish three cases\. First, without state, multi\-step skill use reduces to composed routing decisions\. Second, after correct execution, the artifact can inform the next decision\. Third, if the artifact is incorrect or mismatched, the same state channel may propagate errors or congest context\. Thus, the key question is not whether execution helps, but when state alters downstream routing\.

### 4\.1No State Realization: Multiplicative Baseline

We first establish a baseline before any execution artifact is produced\. The question is whether routing steps within a pipeline interact merely because they are planned step\-by\-step\. We form ordered two\-skill pairs from annotated pipelines, expose the same library to the single\-step and paired prompts, and suppress execution artifacts in the paired prompt\. If the two routes do not interact, pipeline success should factor asP​\(A∩B\)=P​\(A\)​P​\(B\)P\(A\\cap B\)=P\(A\)P\(B\)\(for convenience, we usePPto denote the probability of successA​c​cAcc\); any systematic deviationΔ\\Deltawould indicate interaction before state realization\. Across 1,690 skill pairs,Δ\\Deltais near zero \(mean < 0\.01\) across all models \(Fig\.[5](https://arxiv.org/html/2605.16508#S4.F5)\(a\)\)\.

This shows that pipeline prompting alone creates neither reliable positive interaction nor systematic degradation\. We attribute this to the fact that the router is modeled as a conditional distribution over skills given the prompt, and the no\-state isolation setup removes dependence between the two steps before any execution artifact is observed \(Appendix[A](https://arxiv.org/html/2605.16508#A1)\)\.

No\-state multiplicative baseline\.Before execution state exists, two\-step routing is approximately multiplicative:P​\(A∩B\)≈P​\(A\)​P​\(B\),Δ≡P​\(A∩B\)−P​\(A\)​P​\(B\)≈0\.P\(A\\cap B\)\\approx P\(A\)P\(B\),\\qquad\\Delta\\equiv P\(A\\cap B\)\-P\(A\)P\(B\)\\approx 0\.

### 4\.2Correct State Realization: Downstream Rescue

Correct execution changes downstream routing by turning the upstream artifact into concrete evidence for the next skill\. In the state\-realization condition, we execute the upstream skill, insert its artifact verbatim into the downstream routing context, and keep the downstream gold label fixed relative to the no\-state condition \(Fig\.[5](https://arxiv.org/html/2605.16508#S4.F5)\(b, c\)\)\. Rescue should therefore concentrate where upstream execution is correct and pre\-state downstream confidence is low\.

As shown in Fig\.[6](https://arxiv.org/html/2605.16508#S4.F6)\(a\), regressingΔ​P​\(B\|A\)\\Delta P\(B\|A\)on\(1−P​\(B\)\)​P​\(A\)\(1\-P\(B\)\)P\(A\)yields a slope of2​α≈0\.762\\alpha\\approx 0\.76across 1,690 pairs\. The fit is strongest in the hardest quartile \(R2=0\.81R^\{2\}\{=\}0\.81vs\.0\.540\.54overall\), and the effect size follows the same pattern: hard downstream decisions improve about four times more than median\-difficulty ones\. This rescue disappears in the no\-state condition, showing that the gain is not due to merely pairing two skills\. Instead, correct execution turns an underspecified downstream route into a grounded selection problem\. We attribute this effect to increased downstream context concreteness, bounded by upstream success and downstream headroom \(Appendices[A](https://arxiv.org/html/2605.16508#A1)and[D\.1](https://arxiv.org/html/2605.16508#A4.SS1)\)\.

Correct\-state rescue law\.Correct upstream execution rescues downstream routing in proportion to upstream success and downstream headroom:Δ​P​\(B∣A\)=2​α​\(1−P​\(B\)\)​P​\(A\),2​α≈0\.76\.\\Delta P\(B\\mid A\)=2\\alpha\(1\-P\(B\)\)P\(A\),\\qquad 2\\alpha\\approx 0\.76\.

![Refer to caption](https://arxiv.org/html/2605.16508v1/x6.png)Figure 5:Before state realization, paired routing is approximately multiplicative; after correct execution, realized state rescues difficult downstream routes\.
### 4\.3Incorrect State Realization: Propagation and Tie\-Dependent Synergy

![Refer to caption](https://arxiv.org/html/2605.16508v1/x7.png)Figure 6:Incorrect state propagates through tight dependencies, while joint execution synergy changes sign with dependency structure and capability gapGG\.Wrong upstream output has two different effects\. We label pair dependency strengthκ\\kappafrom the task graph and verify it by whether the downstream checker requires the upstream artifact\. If the downstream skill needs that output, the error is carried forward \(Fig\.[6](https://arxiv.org/html/2605.16508#S4.F6)\(b\)\): tight pairs lose over 15% because the required input is missing or incorrect\. If the downstream skill does not really need it, the model can ignore the bad output and solve from the downstream task itself: loose pairs gain 2\.8%\. The no\-dependency baseline stays near zero, and ignored\-upstream behavior rises by 10–15%, so the gain comes from ignoring the wrong upstream result, not from fixing it\.

The same logic explains the capability\-gap result\. The organizing variable is the capability gapGG, not ordering alone\. WhenG<G∗≈0\.25G<G^\{\*\}\{\\approx\}0\.25, the pair is a weak tie: neither step provides a strong enough anchor for the other, and joint execution shows a shallow drag that increases toward zero as the gap grows\. WhenG≥G∗G\\geq G^\{\*\}, the pair becomes a strong tie: the stronger step provides a usable scaffold for the weaker one, producing a positive gain that rises quickly and then saturates \(Fig\.[6](https://arxiv.org/html/2605.16508#S4.F6)\(c\)\)\. Thus the effect is not a simple strong\-first vs\. weak\-first ordering result; it is a thresholded capability\-gap law, with weak\-tie drag belowG∗G^\{\*\}and strong\-tie promotion aboveG∗G^\{\*\}\.

Wrong\-state propagation and tie\-dependent synergy\.Wrong upstream state propagates in proportion to dependency strength: tight dependencies carry wrong state forward, while loose dependencies can ignore it and even show a small gain\. Joint\-execution synergy then changes sign with capability gapGG:S​\(G\)≈\{−0\.0775\+0\.31​GG<G∗≈0\.25​\(Weak\-Tie\)\+0\.265​\(1−e−\(G−G∗\)/0\.12\)G≥G∗​\(Strong\-Tie\)S\(G\)\\approx\\begin\{cases\}\-0\.0775\+0\.31\\,G&G<G^\{\*\}\\approx 0\.25\\qquad\\text\{\(Weak\-Tie\)\}\\\\ \+0\.265\\,\(1\-e^\{\-\(G\-G^\{\*\}\)/0\.12\}\)&G\\geq G^\{\*\}\\qquad\\text\{\(Strong\-Tie\)\}\\end\{cases\}\(4\)

## 5A Unified Law Structure for Skill Libraries

![Refer to caption](https://arxiv.org/html/2605.16508v1/x8.png)Figure 7:Cross\-law coupling: routing slope predicts rescue gain\.The previous two sections establish the routing and execution laws separately\. The remaining question is whether the two laws share a state variable\. They do: the routing slopebbis not only the rate at which a model loses accuracy as the library grows; it also determines how often correct upstream state is available for execution\-side rescue\. Concretely, take a model whose routing accuracy at exposed library sizeNNisA​c​c​\(A\|N\)=a−b​ln⁡NAcc\(A\|N\)=a\-b\\ln N\. This probability also gates whether the downstream step receives useful realized state\. SubstitutingA​c​c​\(A\|N\)Acc\(A\|N\)into the independently measured rescue equation from Sec\.[4](https://arxiv.org/html/2605.16508#S4)givesA​c​cres​\(B\|N\)=A​c​c​\(B\|N\)\+2​α​\(1−A​c​c​\(B\|N\)\)​\(a−b​ln⁡N\),Acc\_\{\\text\{res\}\}\(B\|N\)=Acc\(B\|N\)\+2\\alpha\\,\(1\-Acc\(B\|N\)\)\\,\(a\-b\\ln N\),wherea,ba,bcome from routing experiments, and2​α≈0\.762\\alpha\\approx 0\.76comes from execution experiments\. Yet the prediction tracks independently measured rescue gains across 15 models \(ρ=0\.74\\rho\{=\}0\.74,p<0\.001p\{<\}0\.001; Fig\.[7](https://arxiv.org/html/2605.16508#S5.F7)\)\. This is the unifying law\-level result:bbacts as an empirical state variable for skill\-library scaling\. Reducing it improves immediate routing accuracy and preserves the correct state needed for downstream rescue\.

This link also explains why the design optimization in Sec\.[6](https://arxiv.org/html/2605.16508#S6)targets library structure rather than only prompt formatting\. Boundary rewriting, nearest\-neighbor auditing, and abstract\-skill removal all reduce probability mass lost to local competition or attractor capture\. In this unified law view, those changes are not separate heuristics: they lowerbb, delaying the routing cascade and increasing the probability that execution state can help later steps\.

## 6Law\-Guided Auto Skill Manager

The laws make a falsifiable design prediction: if failures are governed by library geometry rather than only by model capability, then editing that geometry should improve a fixed router on held\-out tasks\. Our law\-guided auto skill manager implements this prediction by auditing the exposed library, estimating where routing probability mass is being lost, and editing the library while holding the router fixed\. Local competition triggers nearest\-neighbor audit and boundary rewrite; cross\-cluster drift triggers prompt anchoring; black\-hole capture triggers abstract\-skill removal or narrowing; and the execution law constrains edits to preserve correct upstream state for downstream rescue\. We evaluate prospectively atN=150N\{=\}150, near the law\-predicted transition point for median\-bbagents, with held\-out tasks, gold labels, distractors, model, prompt template, and parser fixed before optimization\. Under this matched protocol, the gain is therefore attributable to the library surface and manager edits rather than model retraining or selecting an easier evaluation set\.

![Refer to caption](https://arxiv.org/html/2605.16508v1/x9.png)Figure 8:The performance of the law\-guided automatic skill manager\.The prediction holds on both the in\-house held\-out benchmark and downstream agent benchmarks\. On 1,600 held\-out tasks, the manager raises accuracy from 71\.3% to 91\.7% and reduces hijack from 22\.4% to 4\.1% \(Fig\.[8](https://arxiv.org/html/2605.16508#S6.F8)\(a, b\)\)\. The optimized library transfers to downstream tasks: under the downstream setting, mean pass rate improves from 28\.4% to 34\.5% onClawMarkand from 49\.3% to 61\.6% onClawBench\(Fig\.[8](https://arxiv.org/html/2605.16508#S6.F8)\(c, d\); Append\.[F](https://arxiv.org/html/2605.16508#A6)\)\. Thus the manager is not just a diagnostic cleanup pass, which can also improve routing and positive downstream transfer\. Append\.[E\.1](https://arxiv.org/html/2605.16508#A5.SS1)–[E\.5](https://arxiv.org/html/2605.16508#A5.SS5)provide more analysis and discussion\.

## 7Discussion

##### Boundaries and improvements\.

The results should be read as empirical laws for flat natural\-language skill libraries, not as universal laws of every possible agent architecture\. They also assume availability\-preserving evaluation: the required skill is present in the exposed library, so the central error is in\-library misselection rather than missing capability\. Within this setting, the laws identify concrete improvement levers: report in\-library hijack separately from hallucination, sweep library sizeNN, include weak\-anchor prompt conditions, and restructure libraries before deployment\.

##### Broader impacts\.

The paper turns skill\-library scale into a measurable experimental axis, supporting more reproducible studies of routing, execution, and library structure\. For deployed agents, the positive impact is safer and more auditable skill exposure; the risk is that the same diagnostics could make harmful automation more reliable, so deployments need access controls, audit logs, and domain\-specific safety policies\.

##### Limitations and future work\.

The exact slopes may change with learned routers, fine\-tuning, retrieval architectures, or hierarchical libraries, although the qualitative decay replicates beyond the curated library \(Appendix[C\.5](https://arxiv.org/html/2605.16508#A3.SS5)\)\. Future work should repeat the intervention across domains, separate the effects of each design choice, and model when realized state rescues downstream decisions versus when wrong state propagates\.

## 8Conclusion

This paper identifies empirical scaling laws of skill libraries in settings where the needed skill is available but may be misselected\. As reusable skills scale, behavior is shaped not only by model capability but also by library structure\. Before execution, routing accuracy follows a logarithmic law; after correct execution, realized state can rescue difficult downstream decisions\. A single parameter, the routing decay slopebb, links these regimes by predicting both routing collapse and execution\-side rescue\. We instantiate this coupling in a Law\-Guided Auto Skill Manager, showing that the laws can drive practical library optimization with held\-out and downstream validation\. Large skill libraries should therefore be designed as structured systems, where naming, granularity, exposure, and execution state determine whether scale expands capability or amplifies failure\.

## References

Appendix

This appendix is organized as a reader’s map from theory to implementation evidence\. It first states the conditional derivations behind the routing and execution laws \(Appendix[A](https://arxiv.org/html/2605.16508#A1)\), then gives the experimental protocol needed to interpret the measurements \(Appendix[B](https://arxiv.org/html/2605.16508#A2)\)\. The routing\-law section reports the fitted decay parameters, the fine\-grained law summary, mechanism diagnostics, retriever/router baselines, task\-difficulty controls, boundary manipulations, and external validity checks \(Appendices[C\.1](https://arxiv.org/html/2605.16508#A3.SS1)–[C\.5](https://arxiv.org/html/2605.16508#A3.SS5)\)\. The execution\-law section reports cross\-model rescue robustness \(Appendix[D\.1](https://arxiv.org/html/2605.16508#A4.SS1)\)\. The final two blocks turn these measurements into system evidence: Appendix[E](https://arxiv.org/html/2605.16508#A5)explains the automatic skill manager and its component checks, while Appendix[F](https://arxiv.org/html/2605.16508#A6)tests whether the law\-guided library changes transfer to downstream skill\-agent benchmarks\.

## Appendix AMathematical Analysis for the Scaling Laws of Skill Libraries

This section gives the formal backbone behind the empirical laws\. The results are conditional theorems: under explicit assumptions about finite\-capacity selection, library\-competition growth, and state realization, the observed laws follow\. The empirical sections then test whether those assumptions are a good description of the measured skill libraries\. This separates two claims: the proofs show what the theory implies; the experiments show that the theory’s assumptions hold well enough in the studied regime\.

We useNNfor library size,KKfor pipeline length,A​c​c​\(N\)Acc\(N\)for routing accuracy,s⋆s^\{\\star\}for the target skill, ands^\\hat\{s\}for the selected skill\. The marginΔ​μ\\Delta\\mumeasures how clearly the target skill is separated from its nearest competitors; largerΔ​μ\\Delta\\mumeans easier routing\. The competition indexCI\\mathrm\{CI\}measures the total pressure from nearby distractor skills\. For execution,AAis the upstream step,BBis the downstream step, andΔ​A​c​c​\(B∣A\)\\Delta Acc\(B\\mid A\)is the downstream gain after correct upstream execution\. The common mechanism is simple: larger candidate sets and smaller margins lower routing confidence, while correct execution state can restore useful context\. The shared empirical state variable is the routing decay slopebb\.

##### Assumptions\.

We use the following assumptions throughout the formal statements\.

1. 1\.Finite\-capacity margin model\.For taskqq, the router assigns each skill a latent scoreZi=mi\+εiZ\_\{i\}=m\_\{i\}\+\\varepsilon\_\{i\}, wherem⋆−mj=Δjm\_\{\\star\}\-m\_\{j\}=\\Delta\_\{j\}is the semantic margin of the gold skill against distractorjj, andεi\\varepsilon\_\{i\}is zero\-mean sub\-Gaussian noise with scaleσ\\sigma\.
2. 2\.Rank\-regular clustered library\.Within a functional cluster, distractor skills can be ordered by semantic rankr=1,…,N−1r=1,\\ldots,N\{\-\}1around the target, and their effective overtake weights satisfywr=κ/r\+O​\(r−1−ξ\)w\_\{r\}=\\kappa/r\+O\(r^\{\-1\-\\xi\}\)for someκ,ξ\>0\\kappa,\\xi\>0over the measured range\. This is the scale\-free local\-crowding condition tested by the CI and semantic\-gap diagnostics\.
3. 3\.Logarithmic effective competition\.The total effective pressure from plausible distractors isC​\(N\)=∑j≠⋆wj​\(N\)=C0\+C1​ln⁡N\+o​\(ln⁡N\)C\(N\)=\\sum\_\{j\\neq\\star\}w\_\{j\}\(N\)=C\_\{0\}\+C\_\{1\}\\ln N\+o\(\\ln N\)over the exposed\-library range\. Irrelevant distractors have negligiblewjw\_\{j\}; local near\-misses dominateC​\(N\)C\(N\)\.
4. 4\.Small\-error linearization regime\.Over the measured operating range, the router is not saturated at 0 or 1, so first\-order Taylor expansions of the error odds are valid\.
5. 5\.State\-gated rescue\.Correct upstream execution produces a concrete artifact with rescue coefficientα∈\[0,1\]\\alpha\\in\[0,1\]; rescue can only occur when upstream routing/execution is correct and only to the extent that the downstream route has remaining headroom\.
6. 6\.No pre\-state leakage\.In the no\-state condition, paired routing prompts do not contain an execution artifact, so any interaction before execution is bounded by a protocol termϵproto\\epsilon\_\{\\mathrm\{proto\}\}\.

##### Lemma 1 \(Clustered libraries imply logarithmic effective competition\)\.

Under Assumption 2, Assumption 3 follows withC1=κC\_\{1\}=\\kappa\.

##### Proof\.

By Assumption 2,

C​\(N\)=∑r=1N−1wr=κ​∑r=1N−11r\+∑r=1N−1O​\(r−1−ξ\)\.C\(N\)=\\sum\_\{r=1\}^\{N\-1\}w\_\{r\}=\\kappa\\sum\_\{r=1\}^\{N\-1\}\\frac\{1\}\{r\}\+\\sum\_\{r=1\}^\{N\-1\}O\(r^\{\-1\-\\xi\}\)\.\(5\)The harmonic sum satisfies∑r=1N−11/r=ln⁡N\+γE\+o​\(1\)\\sum\_\{r=1\}^\{N\-1\}1/r=\\ln N\+\\gamma\_\{E\}\+o\(1\), whereγE\\gamma\_\{E\}is the Euler constant\. The residual series∑rO​\(r−1−ξ\)\\sum\_\{r\}O\(r^\{\-1\-\\xi\}\)converges becauseξ\>0\\xi\>0, so it contributes a constant pluso​\(1\)o\(1\)\. Therefore

C​\(N\)=C0\+κ​ln⁡N\+o​\(ln⁡N\),C\(N\)=C\_\{0\}\+\\kappa\\ln N\+o\(\\ln N\),\(6\)which is Assumption 3\.□\\square

Table 1:Fine\-grained appendix laws underlying the grouped routing\-law and execution\-law summaries in the main text\.
##### Proposition 1 \(Routing law from finite\-capacity competition\)\.

Under Assumptions 1–4, there exist constantsaaandb\>0b\>0such that

A​c​c​\(N\)=a−b​ln⁡N\+o​\(ln⁡N\)Acc\(N\)=a\-b\\ln N\+o\(\\ln N\)\(7\)over the measured library range\. This is a finite\-range local approximation, not a universal asymptotic claim\. Moreover, increasing semantic margins decreasesbb\.

##### Proof\.

The gold skill is selected whenZ⋆\>ZjZ\_\{\\star\}\>Z\_\{j\}for all distractors\. For each distractor, define its pairwise overtake probability

rj=Pr⁡\[Zj≥Z⋆\]=Pr⁡\[εj−ε⋆≥Δj\]\.r\_\{j\}=\\Pr\[Z\_\{j\}\\geq Z\_\{\\star\}\]=\\Pr\[\\varepsilon\_\{j\}\-\\varepsilon\_\{\\star\}\\geq\\Delta\_\{j\}\]\.\(8\)Sub\-Gaussian concentration givesrj≤exp⁡\(−Δj2/\(4​σ2\)\)r\_\{j\}\\leq\\exp\(\-\\Delta\_\{j\}^\{2\}/\(4\\sigma^\{2\}\)\)up to a constant factor\. In the measured operating range, we assume the effective competition weights are comparable to these pairwise overtake probabilities, so that the same local crowding index controls both the upper bound and the observed error pressure\. Write this effective pressure aswjw\_\{j\}\. By the union bound and the usual inclusion–exclusion expansion,

Pr⁡\[∃j:Zj≥Z⋆\]=∑j≠⋆rj\+O​\(\(∑j≠⋆rj\)2\)\.\\Pr\[\\exists j:Z\_\{j\}\\geq Z\_\{\\star\}\]=\\sum\_\{j\\neq\\star\}r\_\{j\}\+O\\\!\\left\(\(\\sum\_\{j\\neq\\star\}r\_\{j\}\)^\{2\}\\right\)\.\(9\)Assumption 3 and the comparability condition give∑jrj=λ0\+λ1​ln⁡N\+o​\(ln⁡N\)\\sum\_\{j\}r\_\{j\}=\\lambda\_\{0\}\+\\lambda\_\{1\}\\ln N\+o\(\\ln N\)after absorbing constant factors intoλ0,λ1\\lambda\_\{0\},\\lambda\_\{1\}\. Assumption 4 makes the second\-order term bounded and locally linearizable in the measured range, so

A​c​c​\(N\)=1−Pr⁡\[∃j:Zj≥Z⋆\]=a−b​ln⁡N\+o​\(ln⁡N\)\.Acc\(N\)=1\-\\Pr\[\\exists j:Z\_\{j\}\\geq Z\_\{\\star\}\]=a\-b\\ln N\+o\(\\ln N\)\.\(10\)If descriptions or skill boundaries increase marginsΔj\\Delta\_\{j\}, the effective overtake pressures decrease under the same comparability condition, so the log\-growth coefficientλ1\\lambda\_\{1\}and hencebbdecrease\. This proves the local logarithmic form and the design prediction that sharpening boundaries reduces the slope in the measured regime\.□\\square

##### Lemma 2 \(Boundary interventions identify semantic competition\)\.

Consider two candidate mechanisms for the decay slope:

b=bctx​\(LN\)\+bsem​\(\{Δj\}\),b=b\_\{\\mathrm\{ctx\}\}\(L\_\{N\}\)\+b\_\{\\mathrm\{sem\}\}\(\\\{\\Delta\_\{j\}\\\}\),\(11\)wherebctxb\_\{\\mathrm\{ctx\}\}depends only on prompt length or number of exposed tokensLNL\_\{N\}, andbsemb\_\{\\mathrm\{sem\}\}depends on semantic margins\. A boundary rewrite that preserves token length and candidate set but increases marginsΔj\\Delta\_\{j\}can reducebbonly throughbsemb\_\{\\mathrm\{sem\}\}\. Therefore, a statistically reliable decrease inbbunder length\-matched boundary rewrites rules out a pure context\-length explanationb=bctx​\(LN\)b=b\_\{\\mathrm\{ctx\}\}\(L\_\{N\}\)\.

##### Proof\.

In the intervention,LNL\_\{N\}and the exposed candidate set are fixed by construction, sobctx​\(LN\)b\_\{\\mathrm\{ctx\}\}\(L\_\{N\}\)is invariant\. The only changed argument in the decomposition is the margin set\{Δj\}\\\{\\Delta\_\{j\}\\\}\. By Proposition[A](https://arxiv.org/html/2605.16508#A1.SS0.SSS0.Px4), increasing margins decreases the effective overtake pressures under the finite\-range comparability condition, and hence decreasesbsemb\_\{\\mathrm\{sem\}\}\. Thus any observed slope change under a length\-matched boundary rewrite is identified as semantic\-competition movement within this additive model\. Ifbbwere purely a function of context length, the treatment effect would be exactly zero\.□\\square

##### Proposition 2 \(Pipeline compounding from context compression\)\.

LetpN=a−b​ln⁡Np\_\{N\}=a\-b\\ln Nbe the isolated single\-step routing probability\. In a route\-only pipeline, suppose each downstream step after the first pays a compression penalty0≤ηN<pN0\\leq\\eta\_\{N\}<p\_\{N\}because the prompt contains an intermediate plan state rather than the full original task anchor\. Then strict all\-correct pipeline success is

A​c​c​\(N,K\)=pN​\(pN−ηN\)K−1\.Acc\(N,K\)=p\_\{N\}\(p\_\{N\}\-\\eta\_\{N\}\)^\{K\-1\}\.\(12\)IfηN\>0\\eta\_\{N\}\>0, thenA​c​c​\(N,K\)<pNKAcc\(N,K\)<p\_\{N\}^\{K\}, so pipeline success falls below independent repetition\. IfηN/pN=O​\(b\)\\eta\_\{N\}/p\_\{N\}=O\(b\), then

A​c​c​\(N,K\)=pNK​exp⁡\[−\(K−1\)​ηN/pN\+O​\(K​\(ηN/pN\)2\)\],Acc\(N,K\)=p\_\{N\}^\{K\}\\exp\\\!\\left\[\-\(K\-1\)\\eta\_\{N\}/p\_\{N\}\+O\(K\(\\eta\_\{N\}/p\_\{N\}\)^\{2\}\)\\right\],\(13\)which can be reparameterized as the empirical exponent formA​c​c​\(N,K\)≈pNγ​KAcc\(N,K\)\\approx p\_\{N\}^\{\\gamma K\}withγ\>1\\gamma\>1\. The fittedγ\\gammaincreases with routing fragility when the relative compression penaltyηN/pN\\eta\_\{N\}/p\_\{N\}increases sufficiently withbb\.

##### Proof\.

Letδk=1\\delta\_\{k\}=1denote a correct route\. The first step sees the original task anchor, soPr⁡\(δ1=1\)=pN\\Pr\(\\delta\_\{1\}=1\)=p\_\{N\}\. Each later step is routed from a compressed intermediate context, so

Pr⁡\(δk=1∣δ1=⋯=δk−1=1\)=pN−ηN,k≥2\.\\Pr\(\\delta\_\{k\}=1\\mid\\delta\_\{1\}=\\cdots=\\delta\_\{k\-1\}=1\)=p\_\{N\}\-\\eta\_\{N\},\\qquad k\\geq 2\.\(14\)Multiplying conditional probabilities givespN​\(pN−ηN\)K−1p\_\{N\}\(p\_\{N\}\-\\eta\_\{N\}\)^\{K\-1\}\. SincepN−ηN<pNp\_\{N\}\-\\eta\_\{N\}<p\_\{N\}whenηN\>0\\eta\_\{N\}\>0, the product is strictly belowpNKp\_\{N\}^\{K\}\. For the exponential form,

pN​\(pN−ηN\)K−1=pNK​\(1−ηN/pN\)K−1\.p\_\{N\}\(p\_\{N\}\-\\eta\_\{N\}\)^\{K\-1\}=p\_\{N\}^\{K\}\(1\-\\eta\_\{N\}/p\_\{N\}\)^\{K\-1\}\.\(15\)Usingln⁡\(1−x\)=−x\+O​\(x2\)\\ln\(1\-x\)=\-x\+O\(x^\{2\}\)gives the displayed expansion\. Finally, becausepNγ​K=pNK​exp⁡\(\(γ−1\)​K​ln⁡pN\)p\_\{N\}^\{\\gamma K\}=p\_\{N\}^\{K\}\\exp\(\(\\gamma\-1\)K\\ln p\_\{N\}\)andln⁡pN<0\\ln p\_\{N\}<0, the additional exponential loss corresponds to someγ\>1\\gamma\>1\. Cross\-model monotonicity ofγ\\gammainbbis therefore an empirical regularity unless one additionally assumes that the growth ofηN/pN\\eta\_\{N\}/p\_\{N\}dominates the change inln⁡pN\\ln p\_\{N\}\.□\\square

##### Proposition 3 \(Execution rescue\)\.

Under Assumption 5, the downstream improvement from correct upstream state has the form

Δ​A​c​c​\(B∣A\)=2​α​A​c​c​\(A\)​\(1−A​c​c​\(B\)\)\.\\Delta Acc\(B\\mid A\)=2\\alpha\\,Acc\(A\)\\,\(1\-Acc\(B\)\)\.\(16\)

##### Proof\.

Rescue requires two events: correct upstream state exists, and downstream routing has remaining headroom\. The first event has probabilityA​c​c​\(A\)Acc\(A\)\. Conditional on useful state, the largest possible downstream improvement is bounded by1−A​c​c​\(B\)1\-Acc\(B\), because routes already correct before state cannot improve\. Letα\\alphabe the fraction of this available headroom converted into correct downstream decisions by the artifact\. Multiplying the gateA​c​c​\(A\)Acc\(A\), the available headroom1−A​c​c​\(B\)1\-Acc\(B\), and the conversion coefficientα\\alphayields the claim\.□\\square

##### Theorem 1 \(Cross\-law coupling through the routing slope\)\.

Under Assumptions 1–5 and Propositions[A](https://arxiv.org/html/2605.16508#A1.SS0.SSS0.Px4)–[A](https://arxiv.org/html/2605.16508#A1.SS0.SSS0.Px10), the execution\-side rescued downstream accuracy satisfies

A​c​cres​\(B\)=A​c​c​\(B\)\+2​α​\(1−A​c​c​\(B\)\)​\(a−b​ln⁡N\)\+o​\(ln⁡N\)\.Acc\_\{\\mathrm\{res\}\}\(B\)=Acc\(B\)\+2\\alpha\(1\-Acc\(B\)\)\(a\-b\\ln N\)\+o\(\\ln N\)\.\(17\)Thus, holdinga,N,α,a,N,\\alpha,andA​c​c​\(B\)Acc\(B\)fixed, larger routing decay slopebbstrictly decreases the expected execution rescue\.

##### Coupling diagnostic details\.

The coupling check deliberately uses two measurements that are estimated from different experimental regimes\. For each model, the routing\-side quantity is the slopebbfrom the single\-step library\-size sweep in Appendix[C\.1](https://arxiv.org/html/2605.16508#A3.SS1)\. The execution\-side quantity is the rescue coefficientα\\alphafrom the correct\-state execution probes, estimated by regressing downstream rescue on upstream correctness and downstream headroom\. The same ordered skill pairs used for rescue estimation are not used to refit the routing slope\.

After these two quantities are fixed for all 15 models, we run a cross\-model diagnostic regression ofα\\alphaonbband obtainα=0\.50−3\.4​b\\alpha=0\.50\-3\.4b\. The purpose is not to add a new free parameter to the main law, but to test whether the independently measured routing fragility of a model predicts how much correct execution state can rescue later decisions\. We therefore interpret the relation as a no\-refit consistency check linking the routing and execution experiments\. The derivative in the theorem is a partial derivative withα\\alphaheld fixed; if one instead treats the empirical diagnosticα=α​\(b\)\\alpha=\\alpha\(b\)as a structural relation, the total derivative contains the additional termα′​\(b\)​\(a−b​ln⁡N\)\\alpha^\{\\prime\}\(b\)\(a\-b\\ln N\)\.

##### Proof\.

By Proposition[A](https://arxiv.org/html/2605.16508#A1.SS0.SSS0.Px4), the probability that the upstream route supplies the correct state isA​c​c​\(A\)=a−b​ln⁡N\+o​\(ln⁡N\)Acc\(A\)=a\-b\\ln N\+o\(\\ln N\)\. Substitute this into Proposition[A](https://arxiv.org/html/2605.16508#A1.SS0.SSS0.Px10):

Δ​A​c​c​\(B∣A\)=2​α​\(1−A​c​c​\(B\)\)​\(a−b​ln⁡N\)\+o​\(ln⁡N\)\.\\Delta Acc\(B\\mid A\)=2\\alpha\(1\-Acc\(B\)\)\(a\-b\\ln N\)\+o\(\\ln N\)\.\(18\)Adding this improvement to the pre\-state downstream accuracyA​c​c​\(B\)Acc\(B\)gives the stated equation\. Differentiating with respect tobbgives

∂A​c​cres​\(B\)∂b=−2​α​\(1−A​c​c​\(B\)\)​ln⁡N<0\\frac\{\\partial Acc\_\{\\mathrm\{res\}\}\(B\)\}\{\\partial b\}=\-2\\alpha\(1\-Acc\(B\)\)\\ln N<0\(19\)forα\>0\\alpha\>0,A​c​c​\(B\)<1Acc\(B\)<1, andN\>1N\>1\. Hence the same slope that governs routing collapse also controls the expected gate through which correct upstream state can rescue downstream routing\.□\\square

##### L1: logarithmic decay from capacity\-limited selection\.

L1 is the direct consequence of Proposition[A](https://arxiv.org/html/2605.16508#A1.SS0.SSS0.Px4)\. A complementary finite\-range view comes from an extreme\-value approximation\. Let the target skill score bez⋆=⟨𝐮,𝐯~⋆⟩z^\{\\star\}=\\langle\\mathbf\{u\},\\tilde\{\\mathbf\{v\}\}^\{\\star\}\\rangleand each competing score bezj=⟨𝐮,𝐯~j⟩z\_\{j\}=\\langle\\mathbf\{u\},\\tilde\{\\mathbf\{v\}\}\_\{j\}\\rangle, where𝐯~i=𝐯i\+ϵi\\tilde\{\\mathbf\{v\}\}\_\{i\}=\\mathbf\{v\}\_\{i\}\+\\boldsymbol\{\\epsilon\}\_\{i\}is the noisy representation available to a finite\-capacity router\. If the nearest semantic margin isΔ​μ\\Delta\\muand the effective noise variance isσ02​f​\(N\)\\sigma\_\{0\}^\{2\}f\(N\), then

A​c​c​\(N\)=Pr⁡\[z⋆\>maxj≠⋆⁡zj\]≈Φ​\(Δ​μ−σ0​f​\(N\)​2​ln⁡Nσ0​f​\(N\)\)\.Acc\(N\)=\\Pr\[z^\{\\star\}\>\\max\_\{j\\neq\\star\}z\_\{j\}\]\\approx\\Phi\\\!\\left\(\\frac\{\\Delta\\mu\-\\sigma\_\{0\}\\sqrt\{f\(N\)\}\\sqrt\{2\\ln N\}\}\{\\sigma\_\{0\}\\sqrt\{f\(N\)\}\}\\right\)\.\(20\)This expression is not used as a global asymptotic equality\. In the finite rangeN∈\{10,…,500\}N\\in\\\{10,\\ldots,500\\\}, definex=ln⁡Nx=\\ln Nand write the right\-hand side asF​\(x\)F\(x\)\. Taylor expansion around the center of the sweepx0x\_\{0\}gives

F​\(x\)=F​\(x0\)\+F′​\(x0\)​\(x−x0\)\+O​\(\(x−x0\)2\)=a−b​ln⁡N\+O​\(\(ln⁡N−ln⁡N0\)2\),F\(x\)=F\(x\_\{0\}\)\+F^\{\\prime\}\(x\_\{0\}\)\(x\-x\_\{0\}\)\+O\(\(x\-x\_\{0\}\)^\{2\}\)=a\-b\\ln N\+O\(\(\\ln N\-\\ln N\_\{0\}\)^\{2\}\),\(21\)whereb=−F′​\(x0\)\>0b=\-F^\{\\prime\}\(x\_\{0\}\)\>0in the measured decreasing regime\. The derivativeF′​\(x0\)F^\{\\prime\}\(x\_\{0\}\)still depends on the local value off​\(N\)f\(N\)and on the expansion point; we use this approximation only to justify a local slope\. The monotone margin prediction comes from Proposition[A](https://arxiv.org/html/2605.16508#A1.SS0.SSS0.Px4): larger semantic separation lowers effective overtake pressure and therefore lowers the fitted log\-slope in the measured regime\. Thus the proof claim is local: finite\-capacity extreme competition plus observed log\-scale crowding yields the measureda−b​ln⁡Na\-b\\ln Nform\.

Assumption notes\.The scalingf​\(N\)∝ln⁡Nf\(N\)\\propto\\ln Nis an empirical approximation, motivated by the sub\-linear growth of CI\(NN\) in our 14\-cluster library and supported by the AIC comparison \(Δ​AIC\>8\\Delta\\mathrm\{AIC\}\{\>\}8across all 15 models\)\. The Gaussian approximation treats noise termsϵi\\epsilon\_\{i\}as independent; this is imperfect for semantically similar skills, but the resulting prediction is supported by the per\-skill CI regression \(R2=0\.55R^\{2\}\{=\}0\.55, Sec\.[3](https://arxiv.org/html/2605.16508#S3.SS0.SSS0.Px2)\) and by the cross\-model log fits \(R2\>0\.97R^\{2\}\{\>\}0\.97for all models\)\. If added skills were mostly irrelevant, CI would not grow withNNand the log slope would collapse toward zero; if the effect were pure context length, description rewrites would not selectively reducebbfor crowded neighborhoods\. Both alternatives are contradicted by the semantic\-gap regression and the boundary manipulation in Appendix[C\.4](https://arxiv.org/html/2605.16508#A3.SS4)\.

##### L2: pipeline compounding and cascade amplification\.

L2 follows from Proposition[A](https://arxiv.org/html/2605.16508#A1.SS0.SSS0.Px8)\. Letδk∈\{0,1\}\\delta\_\{k\}\\in\\\{0,1\\\}denote whether stepkkis routed correctly, and letpN=A​c​c​\(N\)p\_\{N\}=Acc\(N\)\. The independence baseline is

Pind​\(N,K\)=∏k=1KPr⁡\(δk=1\)=pNK\.P\_\{\\mathrm\{ind\}\}\(N,K\)=\\prod\_\{k=1\}^\{K\}\\Pr\(\\delta\_\{k\}=1\)=p\_\{N\}^\{K\}\.\(22\)In a route\-only plan, later prompts are conditioned on compressed planner state\. Model that loss by

Pr⁡\(δk=1∣δ1=⋯=δk−1=1\)=pN−ηN,k≥2,\\Pr\(\\delta\_\{k\}=1\\mid\\delta\_\{1\}=\\cdots=\\delta\_\{k\-1\}=1\)=p\_\{N\}\-\\eta\_\{N\},\\qquad k\\geq 2,\(23\)with0≤ηN<pN0\\leq\\eta\_\{N\}<p\_\{N\}\. Multiplying the chain\-rule factors gives

A​c​c​\(N,K\)=pN​\(pN−ηN\)K−1,pN=A​c​c​\(N\),0≤ηN<pN,Acc\(N,K\)=p\_\{N\}\(p\_\{N\}\-\\eta\_\{N\}\)^\{K\-1\},\\qquad p\_\{N\}=Acc\(N\),\\quad 0\\leq\\eta\_\{N\}<p\_\{N\},\(24\)and hence

A​c​c​\(N,K\)Pind​\(N,K\)=\(1−ηNpN\)K−1<1\\frac\{Acc\(N,K\)\}\{P\_\{\\mathrm\{ind\}\}\(N,K\)\}=\\left\(1\-\\frac\{\\eta\_\{N\}\}\{p\_\{N\}\}\\right\)^\{K\-1\}<1\(25\)wheneverηN\>0\\eta\_\{N\}\>0\. Taking logs,

ln⁡A​c​c​\(N,K\)=K​ln⁡pN\+\(K−1\)​ln⁡\(1−ηN/pN\)=K​ln⁡pN−\(K−1\)​ηN/pN\+O​\(K​ηN2/pN2\)\.\\ln Acc\(N,K\)=K\\ln p\_\{N\}\+\(K\-1\)\\ln\(1\-\\eta\_\{N\}/p\_\{N\}\)=K\\ln p\_\{N\}\-\(K\-1\)\\eta\_\{N\}/p\_\{N\}\+O\(K\\eta\_\{N\}^\{2\}/p\_\{N\}^\{2\}\)\.\(26\)Equivalently, define

γ=1\+K−1K​ln⁡\(1−ηN/pN\)ln⁡pN,\\gamma=1\+\\frac\{K\-1\}\{K\}\\frac\{\\ln\(1\-\\eta\_\{N\}/p\_\{N\}\)\}\{\\ln p\_\{N\}\},\(27\)which is larger than one because both logarithms are negative\. ThenA​c​c​\(N,K\)=pNγ​KAcc\(N,K\)=p\_\{N\}^\{\\gamma K\}exactly for fixedN,K,ηNN,K,\\eta\_\{N\}\. The empirical scaling law uses this as a low\-dimensional summary across the measuredNNrange\. The derivation is what establishes compounding below the independence baseline\.

##### L3: mid\-chain fragility from information compression\.

L3 follows by adding terminal recovery to the same compression model\. LetIkI\_\{k\}be the mutual information between the original user intent and the context at stepkk\. Use

Ik=I0−c0​\(k−1\)​ln⁡N\+rk,I\_\{k\}=I\_\{0\}\-c\_\{0\}\(k\-1\)\\ln N\+r\_\{k\},\(28\)wherec0​ln⁡Nc\_\{0\}\\ln Nis per\-step identification loss andrkr\_\{k\}is a terminal\-constraint recovery term\. Assumerkr\_\{k\}is negligible before the final segment and increases near the end\. For the middle stepm=⌊K/2⌋m=\\lfloor K/2\\rfloor,

I1−Im=c0​\(m−1\)​ln⁡N−\(rm−r1\)≈c0​\(m−1\)​ln⁡N\.I\_\{1\}\-I\_\{m\}=c\_\{0\}\(m\-1\)\\ln N\-\(r\_\{m\}\-r\_\{1\}\)\\approx c\_\{0\}\(m\-1\)\\ln N\.\(29\)For a late stepKK, the terminal constraint contributesrK\>rmr\_\{K\}\>r\_\{m\}, so

IK−Im=c0​\(m−K\)​ln⁡N\+\(rK−rm\)\.I\_\{K\}\-I\_\{m\}=c\_\{0\}\(m\-K\)\\ln N\+\(r\_\{K\}\-r\_\{m\}\)\.\(30\)A rebound occurs whenrK−rm\>c0​\(K−m\)​ln⁡Nr\_\{K\}\-r\_\{m\}\>c\_\{0\}\(K\-m\)\\ln N; its depth is the recovered accuracy gap between the middle and late steps\. In the finite range, write the relative terminal recovery asrK−rm=r0\+r1​ln⁡Nr\_\{K\}\-r\_\{m\}=r\_\{0\}\+r\_\{1\}\\ln N, wherer1r\_\{1\}captures the fact that final\-step constraints become more valuable when the intermediate library ambiguity is larger\. If local routing accuracy satisfiesA​c​ck≃β0\+β1​IkAcc\_\{k\}\\simeq\\beta\_\{0\}\+\\beta\_\{1\}I\_\{k\}, then the rebound depth is

δ​\(N\)=A​c​cK−A​c​cm≃β1​r0\+β1​\{r1−c0​\(K−m\)\}​ln⁡N\.\\delta\(N\)=Acc\_\{K\}\-Acc\_\{m\}\\simeq\\beta\_\{1\}r\_\{0\}\+\\beta\_\{1\}\\\{r\_\{1\}\-c\_\{0\}\(K\-m\)\\\}\\ln N\.\(31\)Thusδ​\(N\)=δ0\+cδ​ln⁡N\\delta\(N\)=\\delta\_\{0\}\+c\_\{\\delta\}\\ln Nwithcδ\>0c\_\{\\delta\}\>0wheneverr1\>c0​\(K−m\)r\_\{1\}\>c\_\{0\}\(K\-m\)\. The proof is conditional on the explicit recovery term; monotonicity alone would not imply the rebound\.

##### L4: description quality as effective semantic margin\.

L4 follows from the margin dependence in Proposition[A](https://arxiv.org/html/2605.16508#A1.SS0.SSS0.Px4)\. Model the description\-quality effect as a saturating margin gain:

Δ​μ​\(ℓ\)=Δ​μ0​ℓℓ\+c,\\Delta\\mu\(\\ell\)=\\Delta\\mu\_\{0\}\\frac\{\\ell\}\{\\ell\+c\},\(32\)whereℓ\\ellis description quality and the denominator says that each extra detail helps less after the main boundary is already clear\. For a distractor with marginΔj​\(ℓ\)\\Delta\_\{j\}\(\\ell\), the sub\-Gaussian bound gives

rj​\(ℓ\)≤exp⁡\{−Δj​\(ℓ\)2/\(4​σ2\)\}\.r\_\{j\}\(\\ell\)\\leq\\exp\\\{\-\\Delta\_\{j\}\(\\ell\)^\{2\}/\(4\\sigma^\{2\}\)\\\}\.\(33\)An upper bound alone does not identify the derivative ofrjr\_\{j\}\. We therefore use the same finite\-range comparability condition as Proposition[A](https://arxiv.org/html/2605.16508#A1.SS0.SSS0.Px4): in the measured regime, the effective overtake pressure is

rj​\(ℓ\)=θj​\(ℓ\)​exp⁡\{−Δj​\(ℓ\)2/\(4​σ2\)\},r\_\{j\}\(\\ell\)=\\theta\_\{j\}\(\\ell\)\\exp\\\{\-\\Delta\_\{j\}\(\\ell\)^\{2\}/\(4\\sigma^\{2\}\)\\\},\(34\)whereθj​\(ℓ\)\\theta\_\{j\}\(\\ell\)is bounded and does not increase fast enough to offset margin gain\. Then

∂log⁡rj∂ℓ=∂log⁡θj∂ℓ−Δj​\(ℓ\)​Δj′​\(ℓ\)2​σ2<0\\frac\{\\partial\\log r\_\{j\}\}\{\\partial\\ell\}=\\frac\{\\partial\\log\\theta\_\{j\}\}\{\\partial\\ell\}\-\\frac\{\\Delta\_\{j\}\(\\ell\)\\Delta\_\{j\}^\{\\prime\}\(\\ell\)\}\{2\\sigma^\{2\}\}<0\(35\)whenever the margin term dominates\. Since the routing slopeb​\(ℓ\)b\(\\ell\)is the local log\-growth coefficient of∑jrj​\(ℓ\)\\sum\_\{j\}r\_\{j\}\(\\ell\)in Proposition[A](https://arxiv.org/html/2605.16508#A1.SS0.SSS0.Px4), this givesb′​\(ℓ\)<0b^\{\\prime\}\(\\ell\)<0in that regime\. The induced routing curve is

A​c​c​\(N,ℓ\)≈a​\(ℓ\)−b​\(ℓ\)​ln⁡N,b′​\(ℓ\)<0,Acc\(N,\\ell\)\\approx a\(\\ell\)\-b\(\\ell\)\\ln N,\\qquad b^\{\\prime\}\(\\ell\)<0,\(36\)witha​\(ℓ\)a\(\\ell\)allowed to move slightly because clearer descriptions can also improve small\-library routing\. Thus the improvement is derived through lower overtake pressure, not by multiplying the whole accuracy curve by a description\-quality factor\.

##### L5: danger zone and non\-monotonic competition\.

L5 can be derived by separating semantic similarity from explicit disambiguation\. Letd=Δ​μi​jd=\\Delta\\mu\_\{ij\}be the distance between two candidate descriptions\. Write confusion pressure as

Pr⁡\(i→j\)∝g​\(d\)​exp⁡\(−d2/2​σ2\),\\Pr\(i\\to j\)\\propto g\(d\)\\exp\\\!\\left\(\-d^\{2\}/2\\sigma^\{2\}\\right\),\(37\)where the Gaussian term is semantic substitutability andg​\(d\)g\(d\)is the probability that the candidate survives relevance and duplicate checks\. Assumeg​\(0\)=0g\(0\)=0because exact or near duplicates trigger explicit boundary checking,g′​\(d\)\>0g^\{\\prime\}\(d\)\>0for smalldd, andg​\(d\)g\(d\)is positive and differentiable on\(0,∞\)\(0,\\infty\), bounded, and not exponentially increasing\. We also assume the duplicate\-check release is steep enough near zero thatg′​\(d\)/g​\(d\)\>d/σ2g^\{\\prime\}\(d\)/g\(d\)\>d/\\sigma^\{2\}for sufficiently small positivedd\. The derivative of log confusion pressure is

dd​d​log⁡Pr⁡\(i→j\)=g′​\(d\)g​\(d\)−dσ2\.\\frac\{d\}\{dd\}\\log\\Pr\(i\\to j\)=\\frac\{g^\{\\prime\}\(d\)\}\{g\(d\)\}\-\\frac\{d\}\{\\sigma^\{2\}\}\.\(38\)For smalld\>0d\>0, the release condition makes confusion rise\. For largedd, the boundedness condition makes the Gaussian tail dominate, so confusion tends to zero\. By continuity, the maximum is attained at an interior pointd⋆d^\{\\star\}; any differentiable interior maximizer satisfies the first\-order conditiong′​\(d⋆\)/g​\(d⋆\)=d⋆/σ2g^\{\\prime\}\(d^\{\\star\}\)/g\(d^\{\\star\}\)=d^\{\\star\}/\\sigma^\{2\}\. This gives the non\-monotonic danger zone under the duplicate\-check model: plausible near\-misses are worse than both irrelevant skills and obvious duplicates\.

##### L6: descriptor geometry and asymmetric confusion\.

L6 follows from a set\-overlap model of descriptor scope\. Treat descriptiondid\_\{i\}as defining a task regionCiC\_\{i\}\. The overlap term is

J​\(Ci,Cj\)=\|Ci∩Cj\|\|Ci∪Cj\|,J\(C\_\{i\},C\_\{j\}\)=\\frac\{\|C\_\{i\}\\cap C\_\{j\}\|\}\{\|C\_\{i\}\\cup C\_\{j\}\|\},\(39\)and the directional asymmetry term is

A​\(di,dj\)=\|Ci∖Cj\|−\|Cj∖Ci\|\|Ci∪Cj\|A\(d\_\{i\},d\_\{j\}\)=\\frac\{\|C\_\{i\}\\setminus C\_\{j\}\|\-\|C\_\{j\}\\setminus C\_\{i\}\|\}\{\|C\_\{i\}\\cup C\_\{j\}\|\}\(40\)with\|A\|≤1\|A\|\\leq 1\. This is a signed coverage\-imbalance term, not an overlap measure\. Define mutual\-confusion risk as

R​i​s​k​\(i,j\)∝J​\(Ci,Cj\)​\(1−\|A​\(di,dj\)\|\)\.Risk\(i,j\)\\propto J\(C\_\{i\},C\_\{j\}\)\\bigl\(1\-\|A\(d\_\{i\},d\_\{j\}\)\|\\bigr\)\.\(41\)Then∂R​i​s​k/∂J\>0\\partial Risk/\\partial J\>0when\|A\|<1\|A\|<1, and∂R​i​s​k/∂\|A\|=−J<0\\partial Risk/\\partial\|A\|=\-J<0\. Thus high overlap increases confusion, while directional ownership decreases it\. Boundary rewrites reduce risk either by loweringJ​\(Ci,Cj\)J\(C\_\{i\},C\_\{j\}\)or by increasing\|A\|\|A\|through clearer scope boundaries\.

##### L7–L8: anchor removal and black\-hole capture\.

L7–L8 explain why vague prompts and broad skills are dangerous mainly together\. A concrete prompt points toward a specific skill, so the correct skill keeps a large margin\. A vague prompt points toward the center of a functional cluster instead\. If the library contains a broad abstract skill near that center, the broad skill can become the easiest explanation of the prompt:

score​\(sabs\)≈1M​∑i=1M⟨𝐮vague,𝐯i⟩\+ϵ,\\mathrm\{score\}\(s\_\{\\mathrm\{abs\}\}\)\\approx\\frac\{1\}\{M\}\\sum\_\{i=1\}^\{M\}\\langle\\mathbf\{u\}\_\{\\mathrm\{vague\}\},\\mathbf\{v\}\_\{i\}\\rangle\+\\epsilon,\(42\)whereMMis the number of concrete skills whose intent the abstract skill subsumes\. Vague prompts alone need not cause capture, and abstract skills alone need not cause capture\. The failure appears when both push probability mass toward the same broad skill\.

##### Anchor\-loss and black\-hole experiment details\.

The anchor\-loss experiment starts from matched task intents and progressively removes information that normally identifies the target skill\. Query\-anchor removal deletes or generalizes concrete nouns, file names, API names, schema fields, and domain\-specific verbs while preserving the intended operation\. Skill\-anchor removal weakens the candidate descriptions by removing boundary clauses or replacing specific operational constraints with broader functional language\. Because the task intent and gold skill are retained, a drop in accuracy measures loss of routing evidence rather than a change in what the task requires\.

For every in\-library error, we record both the gold functional category and the chosen wrong category\. This lets us distinguish three regimes: local substitution within the same cluster, cross\-cluster drift, and capture by a broad abstract skill\. The semantic\-anchor removal sweep crosses library size with removal level and measures hijack rate, keeping hallucinated skill names separate from in\-library errors\. The black\-hole analysis then retains a broad catch\-all skill in the exposed pool and measures top\-1 absorption, routing\-mass Gini, and hijack rate as the library grows\. Finally, the activation test crosses two factors, skill\-anchor removal and vague query construction\. We treat capture as a dual\-trigger effect only if the combined condition exceeds both single\-factor controls; this is the empirical counterpart of Proposition 4\.

##### Proposition 4 \(Dual\-trigger capture\)\.

Let the gold\-skill score margin over an abstract skill be

M=M0−Δq−Δs,M=M\_\{0\}\-\\Delta\_\{q\}\-\\Delta\_\{s\},\(43\)whereM0\>0M\_\{0\}\>0is the concrete\-query/concrete\-skill margin,Δq≥0\\Delta\_\{q\}\\geq 0is the margin loss from query\-anchor removal, andΔs≥0\\Delta\_\{s\}\\geq 0is the margin loss from broad abstract skill descriptions\. If capture occurs whenM<0M<0, then there exist regimes where neither trigger alone causes capture but both together do:

M0−Δq\>0,M0−Δs\>0,M0−Δq−Δs<0\.M\_\{0\}\-\\Delta\_\{q\}\>0,\\qquad M\_\{0\}\-\\Delta\_\{s\}\>0,\\qquad M\_\{0\}\-\\Delta\_\{q\}\-\\Delta\_\{s\}<0\.\(44\)

##### Proof\.

The three inequalities are jointly feasible whenevermax⁡\(Δq,Δs\)<M0<Δq\+Δs\\max\(\\Delta\_\{q\},\\Delta\_\{s\}\)<M\_\{0\}<\\Delta\_\{q\}\+\\Delta\_\{s\}\. In that interval, each individual manipulation leaves the gold skill ahead of the abstract skill, but their combined margin loss reverses the ordering\. Thus capture is an interaction term in margin space rather than a necessary consequence of either vague prompts or abstract skills alone\.□\\square

##### L9: pre\-state routing independence\.

L9 is the clean baseline for execution: before anything runs, there is no artifact from stepAAthat can help stepBB\. LetAAandBBbe the events that the upstream and downstream routes are correct\. Once we condition on the two task prompts and the exposed library, the downstream route has no extra state from the upstream route\. The no\-state baseline is therefore

Pr⁡\(A∩B∣qA,qB,𝒮N\)=Pr⁡\(A∣qA,𝒮N\)​Pr⁡\(B∣qB,𝒮N\)\+ϵproto\.\\Pr\(A\\cap B\\mid q\_\{A\},q\_\{B\},\\mathcal\{S\}\_\{N\}\)=\\Pr\(A\\mid q\_\{A\},\\mathcal\{S\}\_\{N\}\)\\Pr\(B\\mid q\_\{B\},\\mathcal\{S\}\_\{N\}\)\+\\epsilon\_\{\\mathrm\{proto\}\}\.\(45\)Hereϵproto\\epsilon\_\{\\mathrm\{proto\}\}captures residual prompt\-format correlations, shared task difficulty, or cluster\-level biases that are not real execution effects\. The no\-state isolation setup estimates this term and finds it small in the measured regime, so multiplicativity is an empirical baseline rather than a theorem from the mere absence of an artifact\.

##### L10: execution rescue from concrete state\.

L10 says that execution helps only after it produces useful concrete state\. LetoAo\_\{A\}be the artifact from the upstream step\. IfoAo\_\{A\}tells the router something about the correct downstream skillsB⋆s\_\{B\}^\{\\star\}, then the downstream prompt becomes less ambiguous:

C​\(qB,oA\)=C​\(qB\)\+I​\(sB⋆;oA∣qB\),C\(q\_\{B\},o\_\{A\}\)=C\(q\_\{B\}\)\+I\(s\_\{B\}^\{\\star\};o\_\{A\}\\mid q\_\{B\}\),\(46\)whereC​\(⋅\)C\(\\cdot\)is concreteness and the mutual\-information term is the new evidence supplied by the artifact\. Closing this evidence model with the state\-gated headroom model in Proposition[A](https://arxiv.org/html/2605.16508#A1.SS0.SSS0.Px10)givesΔ​A​c​c​\(B∣A\)=2​α​A​c​c​\(A\)​\(1−A​c​c​\(B\)\)\\Delta Acc\(B\\mid A\)=2\\alpha Acc\(A\)\(1\-Acc\(B\)\)\.A​c​c​\(A\)Acc\(A\)appears because rescue requires correct upstream state;\(1−A​c​c​\(B\)\)\(1\-Acc\(B\)\)appears because easy downstream routes have little headroom\.

##### L11: dependency\-weighted propagation\.

L11 describes what happens when the upstream state is wrong\. The key quantity is dependency strength: if downstream step truly needs the upstream artifact, wrong state should hurt; if dependency is loose, LLM may ignore the bad artifact and use the original task signal\. Letκ∈\[0,1\]\\kappa\\in\[0,1\]measure how much downstream evidence must come from the upstream artifact\. Then the quality change decomposes into propagated loss and task\-context recovery:

Δ​QB​\(κ\)=−λ​κ\+r​\(1−κ\)\.\\Delta Q\_\{B\}\(\\kappa\)=\-\\lambda\\,\\kappa\+r\(1\-\\kappa\)\.\(47\)Estimatingλ\\lambdaandrrfrom tight and loose dependency groups yields the reported propagation relation\. The no\-dependency baseline constrainsrr: recovery requires the downstream task to remain understandable without the upstream artifact, not arbitrary unrelated state\. Wrong state hurts when downstream step needs it, but can be ignored when downstream task remains identifiable without it\.

##### Proposition 5 \(Dependency\-weighted wrong\-state propagation\)\.

Suppose a wrong upstream artifact is used by the downstream step with dependency weightκ∈\[0,1\]\\kappa\\in\[0,1\]\. Letλ\>0\\lambda\>0be the loss when required wrong state is used, and letr≥0r\\geq 0be the recovery gain from ignoring irrelevant wrong state and relying on the downstream task context\. Then

Δ​QB​\(κ\)=−λ​κ\+r​\(1−κ\)\.\\Delta Q\_\{B\}\(\\kappa\)=\-\\lambda\\kappa\+r\(1\-\\kappa\)\.\(48\)The effect is negative forκ\>r/\(λ\+r\)\\kappa\>r/\(\\lambda\+r\)and positive forκ<r/\(λ\+r\)\\kappa<r/\(\\lambda\+r\)\.

##### Proof\.

Decompose the downstream decision into two mutually exclusive channels: with weightκ\\kappa, the checker\-relevant evidence must come from the upstream artifact; with weight1−κ1\-\\kappa, the downstream task remains identifiable without that artifact\. Wrong required state contributes expected change−λ\-\\lambdaon the first channel\. Ignoring irrelevant wrong state contributes expected recoveryrron the second channel\. Linearity of expectation gives the stated affine form\. Solving−λ​κ\+r​\(1−κ\)=0\-\\lambda\\kappa\+r\(1\-\\kappa\)=0gives the sign thresholdκ=r/\(λ\+r\)\\kappa=r/\(\\lambda\+r\)\.□\\square

##### L12: strong\-tie promotion and weak\-tie drag\.

L12 explains why putting two steps together can either help or hurt depending on the capability gapG=\|A​c​c​\(A\)−A​c​c​\(B\)\|G=\|Acc\(A\)\-Acc\(B\)\|\. WhenG<G∗G<G^\{\*\}, the pair is effectively weak\-tie: neither step gives the other a strong enough anchor, so joint execution carries a small drag that shrinks as the gap grows\. WhenG≥G∗G\\geq G^\{\*\}, the pair becomes strong\-tie: the stronger step can promote the weaker one, and the gain saturates once the useful scaffold has been provided\. The empirical fit is

S​\(G\)≈\{−0\.0775\+0\.31​GG<G∗,\+0\.265​\(1−e−\(G−G∗\)/0\.12\)G≥G∗,G∗≈0\.25\.S\(G\)\\approx\\begin\{cases\}\-0\.0775\+0\.31\\,G&G<G^\{\*\},\\\\ \+0\.265\\,\(1\-e^\{\-\(G\-G^\{\*\}\)/0\.12\}\)&G\\geq G^\{\*\},\\end\{cases\}\\qquad G^\{\*\}\\approx 0\.25\.\(49\)Thus Law 12 is not a symmetric ordering effect\. The negative weak\-tie regime is shallow, while the positive strong\-tie regime rises quickly and saturates, matching the main\-text observation that promotion by a sufficiently stronger step dominates weak\-tie drag\.

##### Proposition 6 \(Strong\-tie promotion threshold\)\.

Let joint execution have crowding costc​\(G\)c\(G\)that decreases approximately linearly with capability gap in the weak\-tie regime, and scaffold benefith​\(G\)h\(G\)that is zero below a thresholdG∗G^\{\*\}and saturates above it:

c​\(G\)=\(c0−c1​G\)\+,h​\(G\)=hmax​\(1−e−\(G−G∗\)/τ\)​𝟏​\{G≥G∗\}\.c\(G\)=\(c\_\{0\}\-c\_\{1\}G\)\_\{\+\},\\qquad h\(G\)=h\_\{\\max\}\(1\-e^\{\-\(G\-G^\{\*\}\)/\\tau\}\)\\mathbf\{1\}\\\{G\\geq G^\{\*\}\\\}\.\(50\)Then the net synergyS​\(G\)=h​\(G\)−c​\(G\)S\(G\)=h\(G\)\-c\(G\)is negative\-but\-increasing belowG∗G^\{\*\}and becomes positive\-saturating once the scaffold benefit exceeds the residual cost, matching the empirical form in Law 12 in main text\.

##### Proof\.

ForG<G∗G<G^\{\*\},h​\(G\)=0h\(G\)=0, soS​\(G\)=−c0\+c1​GS\(G\)=\-c\_\{0\}\+c\_\{1\}Gas long as the positive part is active, a shallow negative line whenever0<c1​G<c00<c\_\{1\}G<c\_\{0\}\. ForG≥G∗G\\geq G^\{\*\}, the scaffold term becomeshmax​\(1−e−\(G−G∗\)/τ\)h\_\{\\max\}\(1\-e^\{\-\(G\-G^\{\*\}\)/\\tau\}\), which is increasing and concave with asymptotehmaxh\_\{\\max\}\. Oncec​\(G\)c\(G\)has been driven to zero, the net effect is positive and saturating; before that point, subtracting the residual cost only delays the crossing\. This yields the observed asymmetric piecewise structure: weak\-tie drag is limited, while strong\-tie promotion rises quickly and then saturates\.□\\square

##### Theorem 2 \(Intervention closure\)\.

Under Lemma[A](https://arxiv.org/html/2605.16508#A1.SS0.SSS0.Px6)and Theorem[A](https://arxiv.org/html/2605.16508#A1.SS0.SSS0.Px12), any intervention that length\-matches prompts, preserves the task distribution, and increases semantic margins is predicted by the local model to weakly improve both single\-step routing and expected downstream rescue, provided it does not reduceaa,α\\alpha, orA​c​c​\(B\)Acc\(B\)and higher\-order terms do not dominate:

Δ​A​c​c​\(N\)≥0,Δ​A​c​cres​\(B\)≥0,\\Delta Acc\(N\)\\geq 0,\\qquad\\Delta Acc\_\{\\mathrm\{res\}\}\(B\)\\geq 0,\(51\)with strict improvement whenever the intervention strictly reducesbbandα​\(1−A​c​c​\(B\)\)​ln⁡N\>0\\alpha\(1\-Acc\(B\)\)\\ln N\>0\.

##### Proof\.

By Lemma[A](https://arxiv.org/html/2605.16508#A1.SS0.SSS0.Px6), a length\-matched boundary intervention that increases semantic margins can only move the semantic component of the slope, and Proposition[A](https://arxiv.org/html/2605.16508#A1.SS0.SSS0.Px4)givesΔ​b≤0\\Delta b\\leq 0\. SinceA​c​c​\(N\)=a−b​ln⁡N\+o​\(ln⁡N\)Acc\(N\)=a\-b\\ln N\+o\(\\ln N\), decreasingbbweakly increases single\-step routing accuracy forN\>1N\>1\. By Theorem[A](https://arxiv.org/html/2605.16508#A1.SS0.SSS0.Px12),

∂A​c​cres​\(B\)∂b=−α​\(1−A​c​c​\(B\)\)​ln⁡N\.\\frac\{\\partial Acc\_\{\\mathrm\{res\}\}\(B\)\}\{\\partial b\}=\-\\alpha\(1\-Acc\(B\)\)\\ln N\.\(52\)Whenα​\(1−A​c​c​\(B\)\)​ln⁡N\>0\\alpha\(1\-Acc\(B\)\)\\ln N\>0, a strict decrease inbbstrictly increases the local model’s expected rescue term\. Therefore, under the fixed\-headroom and negligible higher\-order conditions stated above, the same library\-side intervention that improves routing is predicted to improve the expected availability of correct state for downstream execution\.□\\square

## Appendix BExperimental Details

### B\.1Library construction and sampling\.

Each routing trial exposes exactly one gold skill andN−1N\{\-\}1distractors\. Distractors are sampled without replacement from the same 14\-domain library mixture, with the target domain kept in proportion to the full library unless a local\-competition experiment intentionally changes the neighbor set\. For multi\-step route\-only pipelines, all gold skills are fixed by the annotated task graph; only the non\-gold exposed skills are resampled\. We use fixed sampler seeds for paired comparisons so that baseline and intervention conditions see the same task and distractor instances\.

### B\.2Task construction and annotation\.

Most evaluation tasks are benchmark\-derived or adapted from real software\-agent task settings\. They keep the original task intent and receive additional gold\-skill annotations for our library\. We use synthetic drafting only for controlled routing cases where existing benchmarks do not require enough distinct skills to support the planned library\-size and multi\-skill sweeps\. These synthetic cases are written from predefined skill combinations, then independently checked against the skill library\. A task is retained only when annotators agree on the gold skill or gold skill sequence; disagreements are adjudicated by removing the case rather than relabeling it into the majority class\. Synthetic drafting assistance by LLMs \(GPT\-5\.4\) is used only before annotation, not for scoring, rewriting, manager optimization, or downstream transfer evaluation\.

##### Human annotation guideline for skills and tasks\.

Annotators were given the following written guideline\.

High\-Quality Task Annotation GuidelineDecide whether the task is a valid evaluation item\. A valid task must be realistic, executable, and specific enough that another annotator can identify the operation, object, expected artifact, and success condition without seeing model outputs\.Inputs\.You will receive a task card with:•user\-visible task instruction;•benchmark source or synthetic\-control flag, when available;•required output artifact, file, answer, patch, report, or state change;•pipeline position or candidate composition, when this is a multi\-step case;•any provided files, schema, command context, or environment notes\.You may also inspect the frozen skill\-library snapshot to judge whether the task is in scope, but do not choose labels during this pass\.Acceptance criteria\.Keep a task only if all criteria below are satisfied\.1\.Clear intent: the instruction states a concrete user goal, not merely a topic\.2\.Concrete object: the task identifies or clearly implies the file, repository, API, dataset, table, document, command, state, or other object to operate on\.3\.Explicit operation: the requested action is identifiable, e\.g\., analyze, edit, extract, validate, transform, run, compare, summarize, repair, or generate\.4\.Observable output: the final answer, file, patch, report, state change, or execution artifact can be checked after completion\.5\.Sufficient context: a competent software agent would not need to invent missing requirements, hidden files, private credentials, unstated schemas, or unprovided external facts\.6\.Library relevance: at least one available skill is plausibly needed, even if the exact gold skill set is decided later\.7\.No label leakage: the task should not trivially reveal the answer by copying a skill name or internal label, unless that wording is naturally present in the source benchmark or real user request\.8\.Single coherent request: the task should not bundle unrelated goals that would naturally be separate tasks\.Permitted light edits\.You may make only minimal edits that preserve task intent:•normalize spelling or formatting;•expand an abbreviation already clear from context;•add an explicit expected artifact when it is directly implied by the source;•split a bundled task only if the source explicitly contains separable subtasks and each subtask can stand alone\.Rejection labels\.UseAMBIGUOUSwhen multiple incompatible interpretations are equally reasonable\. UseUNDERSPECIFIEDwhen key inputs, objects, constraints, or success conditions are missing\. UseOUT\_OF\_SCOPEwhen the task is not an executable software\-agent task or no skill\-library capability is plausibly relevant\.Reject the task if:•the requested operation is unclear;•the expected output cannot be checked;•key inputs are missing;•the task requires private credentials, hidden files, or unstated external state;•it can only be solved by assuming capabilities not present in the task card or library;•it is primarily open\-ended conversation, preference elicitation, or general advice rather than an executable task\.Quality\-control rule\.Do not inspect model outputs\. If annotators disagree on whether a task isACCEPTED,AMBIGUOUS,UNDERSPECIFIED, orOUT\_OF\_SCOPEafter applying the criteria above, exclude the task rather than forcing agreement by majority vote\.

Skill and Pipeline Label Annotation GuidelineLabel the minimal sufficient gold skill set or ordered gold\-skill sequence using the frozen skill library\. The label should contain the skills required to complete the task, not every skill that might be useful\.Inputs\.You will receive:•the accepted task card and expected artifact;•the frozen skill library, including each skill’s name, description, declared inputs, declared outputs, domain tag, examples, and boundary notes when available;•pipeline metadata when the task is part of a multi\-step case\.Core principle: minimal sufficient gold set\.A gold skill set is valid only if:1\.Sufficiency: together, the selected skills can complete the task under their stated interfaces\.2\.Necessity: removing any selected skill would leave a required operation, artifact, or dependency uncovered\.3\.Interface faithfulness: the label must rely on declared skill behavior, not on unstated behavior inferred from a broad name\.Single\-step tasks\.Assign a gold skill setGG\.•Use one skill if a single skill fully covers the task\.•Use multiple skills only when the task genuinely requires multiple capabilities, artifacts, or interfaces and no single available skill covers them\.•Do not add formatting, checking, retrieval, or helper skills unless they are required by the task’s success condition\.•MarkAMBIGUOUSif two or more distinct gold sets are equally valid\.•MarkUNDERSPECIFIEDif the task lacks information needed to decide the gold set\.Choosing between similar skills\.When multiple skills look plausible:1\.Prefer the narrower skill whose description names the concrete object, operation, domain, input, or output in the task\.2\.Prefer a skill with matching declared inputs and outputs over a skill that only matches by general wording\.3\.Reject broad catch\-all skills unless no narrower exposed skill can perform the task\.4\.Do not select a skill when the task asks for an excluded behavior, a different artifact type, or a different execution environment\.5\.If the difference remains unresolved after checking descriptions, examples, and boundary notes, markAMBIGUOUS\.Pipeline tasks\.Assign an ordered sequence of steps:Step 1:​G1,Step 2:​G2,…,Step K:​GK\.\\text\{Step 1: \}G\_\{1\},\\quad\\text\{Step 2: \}G\_\{2\},\\quad\\ldots,\\quad\\text\{Step K: \}G\_\{K\}\.Each step\-level gold set must either:•produce the final requested artifact;•produce an intermediate artifact required by a later step; or•perform a required validation, transformation, or state update named by the task\.Do not add optional helper steps\. Do not reorder steps unless the task logic requires that order\. If two skills must be used jointly at the same stage, place them in the same step\-level gold set rather than creating an artificial sequence\.Dependency labels for adjacent pipeline steps\.For each adjacent pair\(Gi,Gi\+1\)\(G\_\{i\},G\_\{i\+1\}\), assign one label:tightthe downstream step cannot be completed without the upstream artifact or state\.loosethe upstream artifact may help, but the downstream step can still be completed from the original task or other provided context\.nonethe steps are independent controls; the upstream artifact is not needed by the downstream step\.Closure check\.For every downstream step, list the required input artifact or state and verify that it is produced by an earlier step or present in the original task card\. If any required input has no source, mark the caseUNDERSPECIFIED\.Submission fields\.For each accepted case, submit:•task id;•ACCEPTEDtask\-quality status;•gold skill set for single\-step tasks, or ordered step\-level gold sets for pipeline tasks;•dependency labels for adjacent pipeline steps;•one\-sentence rationale citing the decisive interface or boundary evidence;•AMBIGUOUSorUNDERSPECIFIEDflag if no reliable label can be assigned\.Agreement policy\.Annotate independently and do not inspect model outputs\. A case is kept only when annotators agree on the gold skill set or full ordered sequence and dependency labels\. If disagreement remains after reviewing interface match, boundary match, negative evidence, minimality, and pipeline closure, exclude the case rather than resolving by majority vote\.

### B\.3Routing protocol and parsing\.

Most routing experiments use the following plain\-text prompt:

`We parse the first exact skill\-name span after normalizing whitespace and case\. If no exposed skill name is returned, the response is counted as hallucination or abstention, not mapped to the nearest valid skill\. This is why the paper can distinguish ordinary out\-of\-library hallucination from in\-library hijack\. Unless a provider disables temperature control, routing uses deterministic decoding; repeated runs come from independent task/distractor samples or provider\-side nondeterminism, not from best\-of\-kk selection\.`

`B\.4 Description\-quality and anchor manipulations\. Description\-quality sweeps hold the task, gold skill, candidate set, and model fixed while changing only the skill\-description field\. L1 uses names only; higher levels add purpose, inputs/outputs, boundary conditions, and examples\. Anchor\-loss experiments hold the task intent fixed while removing concrete query anchors such as file names, APIs, schema fields, or domain\-specific verbs\. Black\-hole experiments cross this query manipulation with skill\-side abstraction, so capture is measured as an interaction rather than inferred from one degraded condition\. B\.5 Execution\-state protocol\. No\-state execution probes present the two steps jointly but withhold any upstream artifact, thereby estimating interaction before state realization\. Correct\-state probes execute the upstream skill first and insert the resulting artifact into the downstream routing context\. Wrong\-state probes condition on incorrect upstream artifacts and stratify pairs by dependency strength κ\\kappa, where tight dependencies require the upstream artifact for the downstream checker and loose dependencies do not\. Artifact correctness is scored by task\-specific checkers or human verification when a checker is unavailable\. B\.6 Fitting and uncertainty\. Logarithmic routing laws are fit by least squares over N∈\{10,…,500\}N\\in\\\{10,\.\.\.,500\\\}\. Binomial rates use Wilson 95% intervals\. Cross\-model associations use Spearman correlation with percentile bootstrap confidence intervals\. Optimization comparisons use paired task sets whenever possible; the headline prospective optimization reports the pre\-specified held\-out set rather than selecting the best run\. B\.7 Routing Cascade Checks This diagnostic uses route\-only multi\-step tasks to measure whether pipeline failure is only the product of single\-step routing errors or whether later routes become harder after earlier routing decisions have compressed the task state\. Figure 9: Cascade Penalty Decomposition\. Pipeline depth amplifies the gap between observed end\-to\-end accuracy and the independence baseline\. Route\-only cascade protocol\. Each case is an annotated skill sequence \(s1⋆,…,sK⋆\)\(s\_\{1\}^\{\\star\},\\ldots,s\_\{K\}^\{\\star\}\) with the same underlying task graph used across library sizes\. At step kk, the router sees the current subtask description, the exposed library of size NN, and the previous routed skill names, but it does not receive execution artifacts or checker feedback\. This isolates planning state from execution state: any downstream degradation comes from routing over a compressed intermediate plan, not from a wrong file, table, API result, or other realized artifact\. For every NN, the KK gold skills are fixed and only the non\-gold distractors are resampled under the same domain as the single\-step routing sweep \(Fig\. 9\)\. Figure 10: State\-Transition Audit\. Downstream routing accuracy depends on whether the preceding step remains correct, linking transition state to cascade behavior \(annotated by human annotators\)\. Matched product baseline\. For each pipeline position kk, we run the same subtask as an isolated single\-step routing query with the same gold skill and matched distractor sampling\. Let A​c​ck​\(N\)=Pr⁡\[s^k=sk⋆\]Acc\_\{k\}\(N\)=\\Pr\[\\hat\{s\}\_\{k\}=s\_\{k\}^\{\\star\}\] be this isolated accuracy\. The no\-cascade product baseline is A​c​cind​\(N,K\)=∏k=1KA​c​ck​\(N\)\.Acc\_\{\\mathrm\{ind\}\}\(N,K\)=\\prod\_\{k=1\}^\{K\}Acc\_\{k\}\(N\)\. \(53\) We then run the full route\-only pipeline on the same task set and record strict success A​c​c​\(N,K\)=Pr⁡\[s^1=s1⋆,…,s^K=sK⋆\]Acc\(N,K\)=\\Pr\[\\hat\{s\}\_\{1\}=s\_\{1\}^\{\\star\},\\ldots,\\hat\{s\}\_\{K\}=s\_\{K\}^\{\\star\}\]\. The extra depth loss is D​\(N,K\)=log⁡A​c​cind​\(N,K\)−log⁡A​c​c​\(N,K\)\.D\(N,K\)=\\log Acc\_\{\\mathrm\{ind\}\}\(N,K\)\-\\log Acc\(N,K\)\. \(54\) Using log probabilities makes the excess penalty additive across depth and comparable between models with different absolute single\-step accuracies\. Transition audit\. To check whether the excess loss is consistent with local cascade behavior, we estimate adjacent correctness transitions from the same route\-only runs\. For every adjacent pair \(k,k\+1\)\(k,k\+1\), define ck=𝟏​\[s^k=sk⋆\]c\_\{k\}=\\mathbf\{1\}\[\\hat\{s\}\_\{k\}=s\_\{k\}^\{\\star\}\] and estimate ρc=A​c​c​\(ck\+1∣ck\)−A​c​c​\(ck\+1∣¬ck\)\\rho\_\{c\}=Acc\(c\_\{k\+1\}\\mid c\_\{k\}\)\-Acc\(c\_\{k\+1\}\\mid\\neg c\_\{k\}\) \(55\) after pooling adjacent pairs within the same model, library size, and depth condition\. A positive ρc\\rho\_\{c\} means the next route is more likely to be correct when the previous route was correct\. We compare this transition estimate with the fitted depth exponent γ\\gamma from the scaling law as a diagnostic, not as an additional fitted result: if both move together, the observed pipeline penalty is attributable to local routing\-state compression rather than an unmatched prompt or task\-difficulty artifact \(Fig\. 10\)\. Appendix C Routing Law C\.1 Empirical Decay Parameters Table 2 reports the fitted intercept aa, decay slope bb, and 70% threshold N∗N^\{\*\} for each evaluated model\. Stronger models exhibit smaller bb, pushing the operational threshold to larger libraries, but none remove the logarithmic form itself\. Routing\-scale experiment details\. Each routing condition fixes the evaluated task set and changes only the number of exposed candidate skills\. A trial contains the kk gold skill and N−kN\{\-\}k randomly selected distractors sampled without replacement from the domain\-stratified library pool\. The target distribution is therefore held fixed as NN changes: increasing NN adds distractors around the same gold tasks rather than introducing harder targets\. For paired or repeated settings, the task identifier and candidate\-set seed define the unit of aggregation\. Repeated calls sharing that unit are averaged first, and task\-level means are then averaged across the condition, so tasks with more repeats do not receive extra weight\. Single\-step routing accuracy is estimated for each model and each N∈\{10,20,50,100,200,500\}N\\in\\\{10,20,50,100,200,500\\\} and fit by ordinary least squares as a−b​ln⁡Na\-b\\ln N\. Pipeline experiments use route\-only annotated skill sequences: the gold sequence is known, every step is routed, but no execution artifact from an earlier step is inserted into the next step\. This isolates planning and routing from state realization\. The independent baseline for a length\-KK pipeline is computed from the corresponding single\-step fit as \(a−b​ln⁡N\)K\(a\-b\\ln N\)^\{K\}\. The observed route\-only pipeline accuracy is then compared with this baseline to estimate a model\-specific compounding exponent γ\\gamma\. Per\-step analyses keep the pipeline length fixed while computing accuracy at each step, then use the normalized position k/Kk/K only when pooling curves across different lengths\. The fitted intercept aa is not used as a probability estimate\. It is the intercept at ln⁡N=0\\ln N=0, outside the evaluated range, which is why it can slightly exceed one for the strongest models in Table 2\. All claims use the measured sweep N∈\{10,20,50,100,200,500\}N\\in\\\{10,20,50,100,200,500\\\} and the local slope bb over that range; the linear\-log law is not extrapolated beyond the observed support\. Table 2: Fitted parameters for A​c​c​\(N\)=a−b​ln⁡NAcc\(N\)=a\-b\\ln N across all 15 models\. The intercept aa can slightly exceed 1 for the strongest models; the law is used over N≥10N\\geq 10\. C\.2 Decay Slope vs\. Semantic Gap Mechanism This diagnostic connects the fitted routing law to the paper’s main mechanism\. If the logarithmic slope bb were only a generic model\-capacity or prompt\-length effect, then it would not depend strongly on where a skill sits inside the library\. The local\-competition account makes a sharper prediction: skills whose descriptions sit close to a neighbor should lose accuracy faster as more candidates are exposed, because additional skills add plausible near\-misses around the same intent\. We therefore test whether per\-skill decay is largest exactly where the library geometry is most crowded\. The visual evidence is Fig\. 3: panel \(a\) shows that sharper descriptions flatten the decay slope, panels \(b,c\) show where local near\-miss errors concentrate, and panel \(d\) summarizes the same effect through the competition\-index fit\. This appendix paragraph gives the per\-skill regression behind that visual mechanism\. How the diagnostic is run\. For each skill, we embed the same description text that appears in the routing prompt and compute the cosine distance to its nearest neighboring skill, denoted Δ​μ\\Delta\\mu\. This step uses only the library text and is completed before looking at model outputs\. We then estimate a per\-skill decay slope using only trials where that skill is the gold target across the same library\-size sweep as the main routing experiment\. Appearances of the skill as a distractor for other targets are used only to define local competition, not to estimate that skill’s own slope\. We correlate the per\-skill slope with 1/Δ​μ1/\\Delta\\mu, because a smaller nearest\-neighbor gap corresponds to a larger inverse\-gap value and hence a predicted larger decay slope\. This keeps the diagnostic aligned with the design claim: boundary rewrites should help most when they increase separation between locally confusable skills\. In the figure, this is the move from the crowded danger\-band regime toward wider local margins; in the regression, it appears as a positive association between inverse gap and decay slope\. The relationship is strong: Spearman ρ=0\.71\\rho\{=\}0\.71 \(p<0\.001p\{<\}0\.001, n=452n\{=\}452 skills\)\. A linear regression b=β0\+β1/Δ​μb=\\beta\_\{0\}\+\\beta\_\{1\}/\\Delta\\mu gives β0=0\.008\\beta\_\{0\}\{=\}0\.008 \(95% CI: \[0\.003,0\.013\]\[0\.003,0\.013\]\), β1=0\.031\\beta\_\{1\}\{=\}0\.031 \(\[0\.026,0\.036\]\[0\.026,0\.036\]\), and R2=0\.49R^\{2\}\{=\}0\.49\. The positive intercept means that even isolated skills retain a small baseline decay from finite context and selection noise, but nearly half of the per\-skill variation in slope is explained by local semantic crowding\. This is why the later optimization targets skill boundaries and nearest\-neighbor audits rather than only changing the global prompt\. Table 3: Component attribution for the two highest\-leverage library\-side optimization actions at N=150N\{=\}150 \(100\-task held\-out factorial ablation; full details in Appendix E\.4\)\. C\.3 Routing Law Controls: Baselines and Task Difficulty The routing law should not depend on a single implementation of the router, nor should it be an artifact of harder tasks appearing at larger NN\. This section therefore collects two controls: retrieval baselines under the same scaling sweep, and task\-difficulty checks that hold task hardness separate from library size\. C\.3\.1 Retriever and Router Baselines Table 4 positions zero\-shot LLM routing against sparse and dense retrieval baselines under the same scaling sweep\. The purpose is to show that decline with library scale is not unique to one routing implementation\. Note on sample sizes\. The baseline table uses n=50n\{=\}50 tasks per condition, which is intentionally smaller than the n=500n\{=\}500 used in the main scaling experiments\. The baselines are not the primary contribution of the paper; the goal is to check whether sparse retrieval, dense retrieval, and LLM routing all show degradation with larger candidate sets\. We report means across runs where repeated runs are available rather than best\-of\-run values\. The low R2R^\{2\} values for some rows reflect sampling variance at this scale, not absence of the decay trend: at n=500n\{=\}500, GPT\-series achieves R2\>0\.97R^\{2\}\{\>\}0\.97 in the main scaling experiment\. BM25 is a lexical control, not the main skill\-router regime\. The main analysis concerns LLM semantic routing: the model reads natural\-language skill descriptions, infers task intent, and can therefore be pulled toward broad semantic attractors\. BM25 is included only as a sparse lexical retrieval control\. It matches surface terms between the query and skill descriptions, but it does not perform the same semantic abstraction, state\-aware skill selection, or execution\-conditioned reasoning studied in the paper\. This difference is why the large\-NN reversal is informative\. At N=200N\{=\}200, BM25 \(78\.0%\) outperforms LLM routing \(GPT\-5\.4\-mini, 60\.7%\): BM25 is less exposed to black\-hole capture precisely because it lacks the semantic generalization that makes an abstract catch\-all skill attractive to an LLM router\. The result is therefore not an endorsement of BM25 as a deployment choice; LLM routing is substantially better at small NN, handles paraphrase better, and is the relevant regime for skill\-based agents\. Rather, the reversal is a negative\-control signal: the large\-library degradation we analyze is not just generic task difficulty or prompt length, but a semantic in\-library hijack mechanism specific to LLM\-style skill routing\. Table 4: Routing accuracy across methods and library sizes \(n=50n\{=\}50 tasks per condition; means across runs where available\)\. All methods show the same qualitative decline as NN grows, but this table is an auxiliary implementation check rather than a headline quantitative fit\. C\.3\.2 Task\-Difficulty Confounds The difficulty concern is that larger libraries might accidentally contain harder tasks, so the observed decay could reflect task selection rather than library size\. Our routing sweep is constructed to avoid this: the gold task pool is held fixed\. Concretely, every size\-NN condition draws from the same domain\-stratified task pool \(n=500n\{=\}500 per condition in the main sweep\); each trial exposes the gold skill plus N−1N\{\-\}1 distractors sampled from the same library mixture\. Thus larger NN changes the number of alternatives around the same targets, not the target distribution itself\. The control is visible in the fitted scaling curves\. Under this fixed\-target, distractor\-only sweep, all 15 models still follow A​c​c​\(N\)=a−b​ln⁡NAcc\(N\)=a\-b\\ln N over N∈\{10,20,50,100,200,500\}N\\in\\\{10,20,50,100,200,500\\\}, with R2=0\.968R^\{2\}\{=\}0\.968–0\.9810\.981 and positive slopes b=0\.031b\{=\}0\.031–0\.0650\.065 \(Table 2\)\. The strongest model has the shallowest decay \(b=0\.031b\{=\}0\.031\), while GPT\-4o\-mini has the steepest \(b=0\.065b\{=\}0\.065\); the sign and log\-linear form are unchanged across the model range\. Because the task pool does not get harder as NN grows, these slopes measure sensitivity to additional distractors rather than a between\-condition shift in intrinsic task hardness\. We use the same logic for route\-only pipeline controls: the annotated gold skill sequence is fixed by the task graph, and only non\-gold exposed skills are resampled\. The observed pipeline degradation therefore cannot be explained by longer or harder target tasks being introduced at larger NN; it occurs when the same required skills are routed among more candidate distractors\. Finally, per\-domain stratification prevents a domain\-composition artifact: each size condition preserves the same domain mixture, so the decay is not driven by difficulty becoming overrepresented at large library sizes\. Token\-budget boundary\. The library\-size sweep increases both distractor count and prompt length\. Our controls do not make a pure token\-budget estimate\. They show that the decay is not only generic long\-context degradation: the task pool is fixed, length\-matched boundary rewrites still move accuracy, and the semantic competition index predicts failures better than NN alone\. The measured slope therefore applies to the flat exposed\-library prompt format studied here, not to pagination, hierarchy, or retrieval\-gated top\-MM exposure\. We also ran a small GPT\-5\.4\-mini context\-growth check that keeps the required skill and task pool fixed while increasing only the exposed skill context\. The added context contains non\-gold skills drawn by the same domain\-stratified sampler, so the required skill remains available in every condition and the target tasks do not change\. The check is intended as a token\-growth stress test, not a replacement for the full 15\-model scaling sweep: it asks whether the GPT\-5\.4\-mini decline appears when task hardness is fixed and only the exposed candidate context grows\. The observed pattern matches the main sweep direction, supporting the interpretation that scale\-induced context growth is part of the flat\-library routing problem rather than a separate task\-difficulty artifact\. We additionally use a context\-matched skill\-count control to separate exposed skill count from approximate prompt length\. The control uses the same tasks and GPT\-5\.4\-mini router in all conditions\. For each task, we first sample the N=150N\{=\}150 candidate set and use its description\-only candidate list to define a fixed token budget\. We then vary the exposed skill count from N=10N\{=\}10 to 150150 while rendering truncated evenly across skills, which utilize GPT\-5\.4 to expand, to match the same candidate\-token budget\. Thus the number of selectable in\-library alternatives changes while the exposed candidate\-list token count remains approximately fixed\. Table 5: Context\-matched skill\-count control\. The same task set and GPT\-5\.4\-mini router are evaluated under approximately matched candidate\-list token budgets while changing the number of exposed skills\. Candidate budgets are set by the description\-only N=150N\{=\}150 condition, while each evaluated condition renders truncated GPT\-5\.4\-expanded descriptions to match that budget\. Table 6: Context\-scale accounting for the downstream library construction\. This is not a pure token\-only ablation; it records the scale difference between full exposed context and the gated manager context used in transfer checks\. Context construction Raw skills Global cap Per\-task cap Per\-domain cap Raw collected library 1412 – – – Deduplicated diagnostic library 1141 – – – Manager\-gated downstream library 1412 250 80 24 Table 6 makes the context\-length boundary explicit\. The routing law is estimated on the 1,141\-skill diagnostic library after near\-duplicate removal, where increasing NN also increases the candidate text shown to the model\. The downstream manager starts from the broader 1,412\-skill raw transfer library and does not claim to hold prompt length fixed; instead, it changes the exposed surface by selecting a smaller domain\- and task\-conditioned context from that raw library\. Therefore the downstream gains should be read as evidence that law\-guided gating and editing help under a matched transfer protocol, not as an isolated estimate of the causal effect of tokens\. What each control rules out\. The controls separate several possible explanations but do not collapse them into a single causal estimate\. The fixed\-target sweep rules out task\-set hardening across NN\. Domain stratification rules out a domain\-composition shift\. Length\-matched boundary rewrites rule out a purely token\-count account for the boundary intervention, because the candidate list length is matched while local accuracy changes\. The per\-skill inverse\-gap regression and CI fit rule out a pure candidate\-count account, because skills with more crowded neighborhoods lose accuracy faster than isolated skills under the same global library size\. Finally, the sparse\-retrieval control is a negative control for semantic abstraction: BM25 degrades with candidate growth but is less vulnerable to abstract black\-hole capture than LLM routing\. Together these checks support semantic competition as the dominant measured mechanism in the flat exposed\-library protocol, while leaving open how much a hierarchical or retrieval\-gated interface would reduce the slope\. C\.4 Mechanism Probe: Manipulating Skill Boundaries The routing law says that larger libraries hurt because they create denser neighborhoods of plausible alternatives\. To probe this mechanism directly, we run a description intervention: we manipulate the semantic similarity between pairs of skills by rewriting their descriptions to be more or less similar, then test whether routing accuracy changes as predicted by the capacity model\. Local\-competition experiment details\. The description\-quality sweep is paired at the trial level\. We hold fixed the task, gold skill, exposed distractor set, model, prompt template, decoding setting, parser, and scoring rule\. Only the description field changes\. The levels progress from name\-only text to brief summaries, target objects and actions, constraints and examples, and finally bounded counterexamples\. This design tests whether sharpening the skill boundary changes routing while keeping the underlying task and candidate set unchanged\. Local competition is measured before model inference\. For each exposed library, we compute similarity between the gold skill and each exposed non\-gold skill, rank the nearest distractors, and count exposure to predefined similarity bands\. Error\-rate summaries are then grouped by these precomputed ranks and bands\. The danger band is selected as the band with the most negative Spearman association between exposure and accuracy: it is the region where adding candidates most reliably hurts\. Finally, we compute a competition index C​I​\(s⋆,𝒮N\)=∑sj∈𝒮N∖\{s⋆\}exp⁡\(β​TFIDFSim​\(s⋆,sj\)\),CI\(s^\{\\star\},\\mathcal\{S\}\_\{N\}\)=\\sum\_\{s\_\{j\}\\in\\mathcal\{S\}\_\{N\}\\setminus\\\{s^\{\\star\}\\\}\}\\exp\\\!\\left\(\\beta\\,\\mathrm\{TFIDFSim\}\(s^\{\\star\},s\_\{j\}\)\\right\), \(56\) over exposed non\-gold skills and fit the Boltzmann form A​c​c​\(s^=s⋆\)=AA\+C​I​\(s⋆,𝒮N\)\.Acc\(\\hat\{s\}=s^\{\\star\}\)=\\frac\{A\}\{A\+CI\(s^\{\\star\},\\mathcal\{S\}\_\{N\}\)\}\. \(57\) Here C​ICI is a scalar summary of distractor pressure around the gold skill\. The coefficient β\\beta is a fitted inverse\-temperature parameter: when β\\beta is larger, small increases in description similarity create much larger competitive weight\. If β=0\\beta=0, every exposed distractor contributes equally and CI collapses to a count; positive β\\beta makes near neighbors dominate the sum\. The parameter A\>0A\>0 is the fitted gold\-side baseline strength, absorbing the target skill’s average salience, description quality, and any model\-level preference for the correct class that is not explained by exposed distractors\. Thus the fitted probability compares one target mass AA against the total distractor mass C​ICI\. The gold skill is excluded from CI so that the index measures distractor pressure, not target descriptiveness\. Boundary intervention\. We select 60 skill pairs from the danger zone \(cos∈\[0\.55,0\.75\)\\cos\\in\[0\.55,0\.75\)\) and 60 pairs from the safe zone \(cos<0\.55\\cos<0\.55\)\. For each pair, we produce three description variants: original, pushed apart \(targeting cos<0\.45\\cos<0\.45\), and pulled together \(targeting cos\>0\.80\\cos\>0\.80\)\. We verify cosine shifts using BGE embeddings before running routing experiments \(n=100n\{=\}100 tasks per pair per variant\)\. All variants are length\-matched to within ±15\\pm 15 tokens and written at L4 quality; functional equivalence is verified by two annotators \(κ=0\.88\\kappa\{=\}0\.88\)\. The manipulation therefore changes the local semantic geometry while holding the skill function fixed\. Mechanism check\. • Pushed apart: accuracy increases by \+18\.4%\+18\.4\\% for danger\-zone pairs \(p<0\.001p\{<\}0\.001, n=60n\{=\}60\) and \+9\.2%\+9\.2\\% for safe\-zone pairs \(p=0\.003p\{=\}0\.003\)\. • Pulled together \(danger zone\): accuracy decreases by −11\.3%\-11\.3\\% \(p<0\.001p\{<\}0\.001\)\. • Pulled together \(safe zone\): accuracy increases by \+3\.1%\+3\.1\\% \(p=0\.041p\{=\}0\.041\), consistent with the near\-duplicate disambiguation effect\. All four directional predictions match the capacity model without refitting\. This supports the mechanism behind the routing law: description similarity is not merely correlated with routing error, but can causally move probability mass among local competitors\. C\.5 External Validity To validate the routing law beyond the main skill\-routing experiments, we test its qualitative logarithmic on ToolBench \[qin2023toolllm\], not as a refit of the main paper’s quantitative slopes \(Fig\. 11\)\. Figure 11: ToolBench Validity\. ToolBench routing accuracy and hallucination rates follow the same qualitative library\-size pattern on an external tool corpus\. Table 7: ToolBench routing accuracy and hallucination rate by library size\. 30 queries per condition, gold API \+ uniform distractors\. External routing setting\. We sample 140 answer traces from the ToolBench G1 split and extract 633 unique API functions with their natural\-language descriptions\. For each of 30 sampled queries per library size N∈\{5,10,20,50,100,200\}N\\in\\\{5,10,20,50,100,200\\\}, we construct a library containing the gold API plus N−1N\{\-\}1 distractors drawn uniformly from the full API pool\. Both GPT\-4o\-mini and Claude Sonnet 4\.6 route each query to a single API name using the same zero\-shot plain\-text protocol as the main experiments\. The random seed is fixed at 42\. ToolBench measurement details\. For each model and library size, each query is scored as correct if the parsed API name matches the gold API from the original ToolBench trace\. A response that does not match any exposed API name is counted as hallucination; an exposed but non\-gold API is counted as an in\-library routing error\. Accuracy and hallucination rate are computed over the 30 sampled queries at each NN\. The log fit is estimated separately for each model from those condition means, using the same a−b​ln⁡Na\-b\\ln N form as the main routing experiment\. Routing\-law replication\. Table 7 and Fig\. 11 show the accuracy and hallucination rates for both models\. GPT\-4o\-mini accuracy declines from 1\.000 at N=5N\{=\}5 to 0\.700 at N=200N\{=\}200; Claude Sonnet 4\.6 declines from 1\.000 to 0\.800\. Log fits A​c​c​\(N\)=a−b​ln⁡NAcc\(N\)=a\-b\\ln N yield: GPT\-4o\-mini: a=1\.176a\{=\}1\.176, b=0\.089b\{=\}0\.089, R2=0\.83R^\{2\}\{=\}0\.83; Claude Sonnet 4\.6: a=1\.116a\{=\}1\.116, b=0\.051b\{=\}0\.051, R2=0\.71R^\{2\}\{=\}0\.71\. Both slopes are positive and the qualitative decay pattern replicates across model families\. Hallucination rate stays low \(≤13%\{\\leq\}13\\%\) across all NN for both models, replicating the main routing result that in\-library routing errors dominate over hallucination at scale\. Appendix D Execution Law D\.1 Cross\-Model Rescue Robustness The execution law does not imply that every model receives the same rescue gain\. Rescue is largest when the upstream step is likely to be correct and the downstream route has headroom\. The cross\-model diagnostic therefore serves a narrower role: it checks that the state\-rescue pattern is systematic across model families while leaving the precise coefficient fit as diagnostic support rather than a separate headline law\. Execution\-state experiment details\. The execution\-state experiments use ordered two\-skill pairs from annotated pipelines\. For each pair, we first run matched single\-step routing trials for the upstream skill AA and the downstream skill BB under the same exposed\-library regime\. These trials estimate A​c​c​\(A\)Acc\(A\) and A​c​c​\(B\)Acc\(B\) without any execution artifact\. The no\-state paired condition then asks for the two routes jointly but still withholds upstream output; its observed joint success A​c​c​\(A,B\)Acc\(A,B\) is compared with A​c​c​\(A\)​A​c​c​\(B\)Acc\(A\)Acc\(B\) through Δ=A​c​c​\(A,B\)−A​c​c​\(A\)​A​c​c​\(B\)\\Delta=Acc\(A,B\)\-Acc\(A\)Acc\(B\)\. This is the protocol\-leakage control: if pairing alone changes routing, Δ\\Delta should move away from zero before any state is realized\. How to read the multiplicativity control\. The no\-state result is a leakage diagnostic, not a theorem of pairwise independence\. Small pair\-level residuals can occur because the two prompts may share wording or domain context\. The key comparison is scale: these no\-state residuals are small relative to the downstream changes observed only after a verified upstream artifact is inserted\. For correct\-state trials, the upstream skill is actually executed\. Only artifacts that pass the upstream checker, or human verification when no checker exists, enter the correct\-state condition\. The artifact is inserted verbatim into the downstream routing context, while the downstream gold skill and candidate library are kept matched to the no\-state condition\. Rescue boost is measured as the downstream success gain relative to the matched no\-state downstream route, and rescue ratio is measured as the realized joint success divided by the product baseline\. The rescue\-law regression uses boost rate as the response and rescue potential \(1−A​c​c​\(B\)\)​A​c​c​\(A\)\(1\-Acc\(B\)\)Acc\(A\) as the predictor\. Wrong\-state and capability\-gap robustness\. The wrong\-state results are also heterogeneous in a structured way\. In the quality propagation audit, 11 models over 68 ordered pairs produce 23,739 downstream\-scored rows\. Tight dependencies lose quality when the upstream artifact is wrong rather than perfect \(\-7\.2%\), while loose dependencies show a small positive difference \(\+2\.8%\) because the downstream step can often ignore the bad upstream artifact\. Independent pairs stay near zero \(\-0\.8%\)\. The ignored\-upstream rate rises in all three groups \(about \+10\.5% to \+14\.5%\), so the loose\-pair gain should be read as bad\-state rejection or fallback, not as true repair of the wrong artifact\. The capability\-gap analysis shows the same kind of structured heterogeneity\. Across 11 models and 253 model\-pair summaries, large\-gap pairs have positive product synergy \(\+25\.2% on average, CI half\-width 11\.6%\), whereas small\-gap pairs are near zero \(\+1\.5%, CI half\-width 3\.4%\)\. The sign is model\-stable in the large\-gap regime \(10 positive models, none negative\)\. Thus the thresholded GG result is not used as a universal closed\-form deployment rule; it summarizes where positive joint execution is most consistently observed\. The pooled rescue coefficient is reported for the same reason: it tests the state\-gated form of the execution law rather than estimating a deployment constant\. Different models, dependency types, and domains can change the local magnitude of α\\alpha, but the predicted structure remains the same: rescue requires correct upstream state and downstream headroom, whereas wrong\-state effects depend on whether the downstream checker actually needs the upstream artifact\. For wrong\-state trials, we deliberately condition on upstream artifacts that fail the upstream checker or receive degraded rubric scores\. Pairs are stratified by dependency type from the task graph and by whether the downstream checker requires the upstream artifact\. Tight pairs require the upstream output for downstream success; loose pairs keep enough downstream task signal that the artifact can be ignored\. Capability\-gap trials estimate G=A​c​c​\(A\)−A​c​c​\(B\)G=Acc\(A\)\-Acc\(B\) from matched single\-step success before joint execution is evaluated\. The fitted transition around G∗≈0\.25G^\{\*\}\\approx 0\.25 is therefore based on a pre\-execution capability measure rather than on post\-hoc joint\-task outcomes\. Appendix E Design Principles for the Automatic Skill Manager This section explains how the empirical laws are converted into the automatic skill manager evaluated in Sec\. 6\. It has three roles\. First, it fixes the design vocabulary by mapping each observed failure regime to a named library\-maintenance action\. Second, it specifies the manager implementation: scorecards, planning, edit actions, runtime gating, and closure checks \(Appendix E\.1\)\. Third, it separates the evidence for the manager into focused checks: boundary\-rewrite stability \(Appendix E\.3\), a stage\-level factorial ablation \(Appendix E\.4\), and rewrite\-style selection \(Appendix E\.5\)\. The central constraint is that the manager is not treated as a free\-form prompt\-engineering bundle: each edit is tied to a measured law variable, while the router, task set, candidate construction, prompt template, and parser are held fixed in the held\-out routing evaluation\. E\.1 Manager Pipeline Table 8 gives the rulebook used by the manager\. Each row starts from a failure regime measured earlier in the paper, turns it into an optimization rule, and names the mechanism that justifies the rule\. The table should be read as the design contract for the manager: edits are allowed only when they target a measured source of routing or execution failure\. Table 8: Optimization rules derived from the observed routing and execution regimes\. The action names are the terms used consistently in the manager description and ablations\. The automatic skill manager is an analyzer\-first library maintenance loop\. It does not change the base model or train a new router\. It takes a structured skill library as input, computes law\-aligned risks, proposes human\-reviewable edits, applies approved changes, and then re\-audits the before/after library\. The implementation used in the experiments follows six stages: schema normalization, scorecard construction, recommendation planning, edit application, runtime gating, and before/after audit\. Stage 1: schema normalization\. Each skill record contains an identifier, name, description, examples, family label, tags, input/output metadata, and explicit anchors: verbs, objects, and constraints\. Optional pipeline edges record upstream skill, downstream skill, dependency type \(tight, loose, or independent\), and edge weight\. The manager normalizes YAML/JSON/metadata\-derived skills into this schema before scoring\. Stage 2: law\-aligned scorecards\. The manager computes three scorecard levels\. A pair scorecard measures lexical or embedding overlap, shared anchors, same\-family membership, competition risk, merge candidate score, and weak\-drag risk\. A skill scorecard aggregates each skill’s top\-neighbor similarity, family conflict, anchor strength, abstraction score, black\-hole risk, routing fragility, and rewrite priority\. A library scorecard aggregates competition density, danger\-zone mass, anchor\-weakness mass, black\-hole exposure, family\-interference index, pipeline\-fragility index, and predicted routing stability\. These quantities correspond directly to the law variables and action names in Table 8: local competition drives nearest\-neighbor audit and boundary rewrite, anchor weakness drives prompt anchoring, black\-hole exposure drives abstract\-skill removal or narrowing, and pipeline fragility drives runtime context gating and closure checks\. Stage 3: recommendation planning\. The planner converts scorecards into pending actions rather than silently modifying the library\. High local\-competition risk triggers rewrite or review\-overlap actions for boundary rewrite\. High abstraction or black\-hole risk triggers remove, narrow, or rewrite actions for abstract\-skill removal or narrowing\. Weak anchors trigger prompt\-anchoring edits that add concrete verbs, objects, and constraints\. Candidate\-skill simulation compares a proposed skill to the existing library and returns reject, add\-with\-review, or approve\-candidate based on nearest overlap, same\-family hits, anchor strength, abstraction score, and predicted routing stability delta\. Stage 4: library edits\. Approved actions are applied as explicit library edits\. A boundary rewrite replaces the skill description and anchor fields with narrower verbs, objects, constraints, and reciprocal exclusions\. A merge action keeps a target skill, absorbs examples/tags/anchors from dropped skills, and removes redundant entries\. A remove or narrow action handles broad catch\-all skills that create abstract\-attractor risk\. After applying a plan, the manager recomputes all scorecards and emits a before/after diff with metric deltas for competition density, danger\-zone mass, anchor weakness, black\-hole exposure, and predicted routing stability\. Stage 5: runtime context and closure checks\. For downstream agent runs, the manager also supports runtime context selection\. It scores skills against the task instruction using matches in names, tags, anchors, descriptions, families, and domain profiles, then exposes a domain\-gated context rather than the full flat library\. Local artifact tasks receive smaller context limits to reduce irrelevant tool/vendor distraction\. A closure checker infers required output artifacts from the task or from explicit task IDs, then prevents completion when required files are missing or empty\. This implements the execution\-law constraint: correct state must be present before downstream decisions or final completion are trusted\. Stage 6: before/after audit\. The complete loop is: load the library; score skill, pair, and library risks; plan rewrite/merge/remove actions; apply approved edits; diff before/after scorecards; and evaluate held\-out routing plus downstream execution\. In the experiments, this loop produced the optimized library evaluated in Sec\. 6\. The implementation is deliberately conservative: every edit is grounded in an observed law variable, and the router is held fixed so gains can be attributed to library geometry rather than model retraining\. E\.2 Evidence Map for the Manager The auto\-skill\-manager has more than two optimization stages: it audits neighbors, rewrites boundaries, strengthens anchors, merges or reviews overlapping skills, narrows or removes abstract skills, gates runtime context, and checks execution closure\. The appendix evidence does not claim to decompose every component independently\. Instead, it uses three focused checks that cover the main claims needed for Sec\. 6\. Table 9 summarizes the role of each evidence block\. Runtime context gating and closure checks are part of the downstream transfer setup; they are not treated as separate routing\-law ablation factors\. This separation is deliberate\. The held\-out routing ablation isolates the two largest library\-surface actions under a fixed router, prompt template, parser, and task set\. The downstream transfer uses the auto\-skill\-manager because completed benchmark tasks also require runtime context selection and closure checks\. We therefore report component evidence for the main routing\-law actions and treat runtime execution controls as part of the downstream system configuration, not as additional proof that each manager component has an independent causal effect\. Table 9: How the appendix evidence supports the automatic skill manager\. Each check tests one narrow claim rather than decomposing the entire manager\. E\.3 Boundary\-Rewrite Stability Details Table 10 reports the model\-level and pair\-level stability checks for the 15\-pair boundary\-rewrite probe\. Each probe pair contains two nearby skills from the danger zone: the gold skill and its most plausible local competitor\. The rewrite is bilateral: we add reciprocal boundary clauses to both descriptions, so each skill states not only what it does, but also how it differs from the paired neighbor\. For example, if two skills both mention repository analysis, the rewritten descriptions explicitly separate the trigger conditions, inputs, and outputs that should send a task to one skill rather than the other\. We track three quantities\. Accuracy gain is the ordinary change in selecting the gold skill\. Outside\-miss change counts errors that leave the intended two\-skill neighborhood entirely: the router selects some third skill, not the gold skill or its paired local competitor\. Local\-support change is the complementary mass assigned to the intended neighborhood, i\.e\., probability that the router selects either the gold skill or the paired competitor\. A positive local\-support change does not by itself mean the router is correct; it means the rewrite has moved attention from diffuse unrelated alternatives back to the relevant local decision\. The stable effect across models is therefore localization\. Boundary text first pulls diffuse outside\-pair errors back into the intended two\-skill neighborhood\. Accuracy then improves only when the localized mass lands on the correct member of the pair rather than the competitor\. This is why the table reports both outside\-miss reduction and accuracy gain: the first measures whether the rewrite restored the right neighborhood, and the second measures whether it also resolved the within\-pair boundary\. Table 10: Stability of the bilateral boundary rewrite over 15 prospectively specified pairs\. Positive accuracy counts report pairs with boundary accuracy above the original condition; outside\-miss and local\-support counts report pairs moving in the desired direction\. E\.4 Design Evidence: Factorial Ablation of Bundled Optimization The prospective evaluation \(Sec\. 6\) reports a bundled 20\.4% gain from the optimized library\. The ablation below is a stage\-level mechanism probe, not a complete decomposition of every manager component\. It toggles one routing\-law stage and one attractor\-law stage\. Boundary rewrite is the ablated form of the nearest\-neighbor\-audit/boundary\-rewrite action in Table 8: crowded pairs are identified first, and rewriting then adds boundary clauses, concrete anchors, and scope exclusions\. Abstract\-skill removal represents the anchor\-loss/black\-hole action: broad catch\-all skills are removed from the flat routing pool or narrowed so that they no longer absorb vague prompts\. We run the 2×\\times2 factorial ablation on a 100\-task held\-out set at N=150N\{=\}150, keeping the router, task set, distractor construction, prompt template, and parser fixed\. Table 11: Stage\-level 2×\\times2 ablation at N=150N\{=\}150 on a 100\-task held\-out set\. “Boundary Rewrite” probes the local\-competition stage after nearest\-neighbor audit; “Abstract\-Skill Removal” probes the anchor\-loss/black\-hole stage\. The auto\-skill\-manager also includes prompt anchoring, overlap review, runtime context gating, and closure checks\. Boundary rewrite alone accounts for 12\.8% of the accuracy gain \(84\.1−71\.384\.1\-71\.3\) and 12\.6% of the hijack reduction\. Abstract\-skill removal alone contributes 4\.9% accuracy \(76\.2−71\.376\.2\-71\.3\) and 5\.1% hijack reduction\. The two effects sum to 17\.7%; the remaining 2\.7% \(91\.7−71\.3−12\.8−4\.991\.7\-71\.3\-12\.8\-4\.9\) is the interaction, consistent with the dual\-trigger mechanism: removing abstract skills is most effective when descriptions are already concrete enough to prevent vague\-prompt drift\. Thus the ablation validates two representative law channels used by the manager: local pairwise confusion and abstract\-attractor capture\. It should be read as a mechanism probe for two stages of the optimization pipeline, not as an exhaustive list of all manager actions\. E\.5 Design Evidence: Rewrite Style Selection The boundary\-rewrite stage in the ablation still leaves an implementation choice: how should rewritten skill descriptions be expressed? This check is an implementation choice inside the boundary\-rewrite stage, not a separate causal claim\. Table 12 compares five rewrite styles by the same library\-geometry quantities used in the routing law: stability, anchor weakness, danger\-zone mass, and black\-hole exposure\. Longer structured cards can improve a manager\-native routing check while adding shared boilerplate that leaves competition density or danger\-zone mass less improved\. The final label\-free compact card keeps the useful identity, action, and boundary information while minimizing reusable template language\. Table 12: Rewrite\-style selection using library\-geometry diagnostics\. Stability is better when higher; anchor weakness, danger\-zone mass, and black\-hole exposure are better when lower\. Manager\-native routing accuracy is used only to select the rewrite style\. This analysis only selects the rewrite style used inside the boundary\-rewrite stage of the held\-out optimization\. The causal claim remains the factorial result in Appendix E\.4 and the prospective held\-out evaluation in Sec\. 6\. Appendix F Downstream Transfer: ClawBench & ClawMark This section reports the downstream skill\-based agent checks referenced in Sec\. 6\. These runs test whether the law\-guided library changes transfer beyond diagnostic routing tasks\. They are not used to establish the routing or execution laws, which are measured in controlled probes\. Table 13: Task\-domain coverage of the downstream transfer data\. The downstream suites are intentionally broader than the controlled routing probes: ClawBench covers 242 task entries across 18 tool\-oriented domains, while ClawMark covers 100 held\-out tasks across 13 role\-oriented domains \(Table 13\)\. This coverage table describes the transfer data only; the routing laws are fitted on the separate controlled routing sweeps where task identity and domain mixture are held fixed across library sizes\. Table 14: Domain\-level downstream transfer on ClawMark\. Entries are pass@4 rates; the Avg\. row reports the domain\-macro average\. Table 15: Domain\-level downstream transfer on ClawBench\. Entries are pass@4 rates; the Avg\. row reports the domain\-macro average\. Setup\. Using gpt\-5\.4\-mini as the base model, we compare raw and optimized skill\-library configurations under matched downstream execution settings\. The auto\-skill\-manager uses the same law\-guided changes as the prospective routing optimization: nearest\-neighbor audit, boundary rewrite, abstract\-skill removal or narrowing, and prompt anchoring, etc\. The downstream comparison holds the base model, execution prompt family, task split, and scoring rule fixed between raw and optimized libraries\. Mean pass rate is computed as the domain\-macro average from the benchmark checkers within each downstream suite and is reported separately for ClawBench and ClawMark\. Transfer measurement details\. Held\-out routing transfer is measured on the pre\-specified 1,600\-task set at N=150N\{=\}150\. The raw\-library and optimized\-library conditions use the same model, prompt template, parser, task list, candidate\-set construction, and scoring rule\. The optimized condition changes only the library surface produced by the law\-guided manager: boundary rewrites, nearest\-neighbor audit, abstract\-skill removal or narrowing, and prompt anchoring\. We report two routing outcomes\. Accuracy is the fraction of tasks routed to the gold skill\. Hijack rate is the fraction routed to an exposed but non\-gold skill, so hallucinations are not mixed into the in\-library failure rate\. Downstream transfer uses matched raw\-library and auto\-skill\-manager\-library runs under the same execution setting\. This separation matters because downstream success depends both on the library surface and on the execution policy that preserves or loses intermediate state\. We therefore treat the downstream result as a transfer check for the optimized library, not as evidence used to fit the routing or execution laws\. The comparison is therefore deliberately narrower than a full agent\-system ablation: it asks whether the same library\-side changes that improve controlled routing remain useful when benchmark checkers score completed tasks\. It does not isolate every runtime component, and it should not be read as evidence that library editing alone solves execution\-state propagation\. Result and interpretation\. The optimized library improves downstream mean pass rate from 49\.3% to 61\.6% on ClawBench and from 28\.4% to 34\.5% on ClawMark\. This pattern is useful but bounded: the library changes improve downstream transfer, while downstream success still depends on execution\-state management\. This is consistent with the paper’s two\-law picture: library structure controls routing\-side probability mass, and execution\-state management controls whether downstream state is usable\. Author Contributions Authors are listed in alphabetical order\. Core Contributors\. Charles Chen, Qiming Yu Contributors\. Yuhang Gu, Zhuoye Huang, Hanjing Li, Hongyu Liu, Jinhao Liu, Simin Liu, Dengyun Peng, Jiangyi Wang, Zheng Yan Supervisors\. Carl Che, Mengkang Hu, Fanqing Meng, Ethan Qin`

Similar Articles