LeafSkill: Efficient Leaf-Level Action Grounding for Recursive LLM Agents
Organizations: North China Institute of Computer System Engineering, Beijing, China · Beijing University of Aeronautics and Astronautics, Beijing, China · University of Science and Technology of China, Hefei, China · China Information Security Research Institute Co., Ltd., Beijing, China
Abstract
Recursive large language model (LLM) agents solve long-horizon tasks through decomposition, execution, and environmental feedback. Yet after producing an atomic subtask, they often invoke the same large model again to translate a familiar instruction into an executable action. We observe that high-level planning is task-specific, whereas leaf-level action grounding recurs across tasks and can be checked against environment-admitted actions. We introduce LeafSkill, an external reuse layer that retrieves semantically related grounding experience, binds action templates to current objects and admissible actions, and uses a lightweight 1.7B selector to choose a bound action or defer the unchanged subtask to the original agent. Skills remain outside the model parameters, allowing a frozen selector to use post-training additions. Under lexical and syntactic paraphrases, exact matching retrieves none of the reference actions, while semantic retrieval preserves 96.0% and 97.0% candidate coverage; the frozen selector adopts 97.34% of unseen skill types. On an independent confirmation set of 200 Robotouille tasks, LeafSkill completes 137 tasks versus 121 for ReCAP (68.5% vs. 60.5%, exact McNemar p=.0259). On the 106 tasks completed by both, it reduces Qwen3.5-27B tokens by 14.42% and calls by 14.08%. A separate held-out repeat yields a consistent 9.0-point success gain and 18.98% token reduction. Reusable leaf grounding can thus improve task completion while reducing host-model inference without replacing high-level planning.
Figures & tables
| System | Reused unit | Delegated decision |
|---|---|---|
| ExpRAG | Retrieved trajectories | Policy conditions action generation on retrieved experience |
| GoS | Skill documents and graph neighbors | Host interprets a dependency-aware skill bundle |
| GraSP | Typed skill DAG | Graph executor composes and repairs multiple nodes |
| LeafSkill | State-bound action candidates | Local selector chooses an admissible action or abstains |
| Environment | Adapter boundary | Binding example |
|---|---|---|
| Robotouille | Native atomic-leaf flag | pick up [food] from [board] pick up onion1 from board1 |
| ALFWorld | Non-root downward phase; exclude root, upward return, and revisit | check fridge 1 go to fridge 1 |
| Stage | Guard | Outcome |
|---|---|---|
| Retrieval | No result above | Return |
| Binding | Missing entity, malformed command, or | Remove candidate; return if empty |
| Select/resolve | Abstention, unknown ID, or stale mapping | Return |
| Final check | Resolved action not in | Return |
| Environment | Split | Size | Role |
|---|---|---|---|
| Robotouille | A | 200 | Library and selector construction |
| B | 200 | Repeats, ablations, and growth source | |
| C | 200 | Independent evaluation | |
| ALFWorld | valid_seen | 140 | Library and optional adaptation |
| valid_unseen | 134 | Final evaluation |
| Metric | Reduction | 95% CI | |
|---|---|---|---|
| Tokens | 106 | 14.4% | |
| Calls | 106 | 14.1% |
| Evaluation | Run | ReCAP | LeafSkill | ||
|---|---|---|---|---|---|
| Robotouille B | R1 | 55.5 | 61.5 | .126 | +6.0 |
| R2 | 56.5 | 65.5 | .025 | +9.0 | |
| R3 | 53.0 | 59.5 | .079 | +6.5 | |
| Mean | – | – | – | +7.2 | |
| Robotouille C | R1 | 60.5 | 68.5 | .0259 | +8.0 |
| ALFWorld unseen | R1 | 90.3 | 90.3 | 1.00 | 0.0 |
| Evaluation | Ep. | Calls | Ctrl. tok. | Tok./ep. |
|---|---|---|---|---|
| Robotouille B R1 | 200 | 1,485 | – | – |
| Robotouille B R2–R3 | 400 | 3,849 | 3.98M | 9,952 |
| Robotouille C | 200 | 1,355 | 1.38M | 6,900 |
| ALFWorld unseen R1–R3 | 402 | 4,636 | 3.31M | 8,236 |
| Reuse path | R/B/S | Success ( ) | Tok. red. |
|---|---|---|---|
| ReCAP R2 | –/–/Host | 113/200 (–) | – |
| RawPair-Exact | Ex./Raw/Dir. | 121/200 (.3581) | 0.20 |
| RawPair-BGE | Sem./Raw/Dir. | 127/200 (.0541) | 8.08 |
| Canonical-Exact | Ex./St./SFT | 134/200 (.0075) | 29.60 |
| BGE Top-1 | Sem./St./Dir. | 124/200 (.2000) | 13.08 |
| BGE Top-5 + Base | Sem./St./Base | 113/200 (1.000) | 27.01 |
| Diagnostic | Comparison | Result (%) | |
|---|---|---|---|
| Lexical rewrite coverage | 200 | Exact / Top-1 / Top-5 | 0.0 / 79.5 / 96.0 |
| Syntactic rewrite coverage | 200 | Exact / Top-1 / Top-5 | 0.0 / 70.5 / 97.0 |
| Mixed-rank selection | 193 | Base / SFT | 81.9 / 93.3 |
| All-negative fallback | 200 | SFT | 7.5 |
| Input-scope mixed-rank | 193 | Local / + planner | 93.3 / 90.7 |
| Library | Keys | Skills | Success | Tok. red. | Call red. |
|---|---|---|---|---|---|
| A | 413 | 446 | 137/200 | 18.35% | 17.70% |
| A+B | 527 | 588 | 131/200 | 25.64% | 24.22% |
| Controller | Training route | Succ. (%) | Use (%) |
|---|---|---|---|
| ReCAP | no controller | 89.80 | – |
| Bare 1.7B | none | 84.33 | 79.41 |
| Robot.-only | Robot. SFT | 91.29 | 70.99 |
| ALF-only | ALF seen SFT | 86.07 | 98.02 |
| Sequential | Robot. ALF seen | 91.79 | 98.81 |
LLM Agent Skill Retrieval
Large language model agent skill retrieval finds and selects reusable procedures to help agents complete tasks.
See all 102 papers