Librarian Agents: Training LLMs to Curate Long-Context Workspaces that Anticipate Future Queries

Reasoning over long document contexts remains a challenge for large language models (LLMs). Standard retrieval methods are inherently reactive, bottlenecking agents with complex, cross-document reasoning at inference time, while precomputed structures like knowledge graphs often fall short because they rely on rigid heuristics. Instead, can we allow agents to perform anticipatory directed curation: learning to proactively reorganize unstructured corpora prior to inference to efficiently serve diverse future queries. We build on a key asymmetry in modern agentic harnesses (e.g., Claude Code): while LLM agents are adept at navigating existing filesystems to solve an immediate task, they are rarely trained to construct reusable workspaces for future use. To instantiate this capability, we introduce Librarian Agents, a framework in which a builder agent transforms raw documents into a hierarchical filesystem of synthetic files and reference links, which forms a workspace tailored for a downstream answering agent. We formulate workspace construction as a Markov decision process and optimize the builder policy via reinforcement learning to directly maximize downstream answering accuracy. Empirically, Librarian Agents outperforms the strongest retrieval and precomputation baselines by 33 percentage points on BrowseComp-Plus, amortizes upfront construction costs across repeated queries, and generalizes zero-shot to unseen domains on BRIGHT with a 31-point average accuracy improvement.

Link
https://www.semanticscholar.org/paper/43ebaa755cba7b28aca01ccea156ded21eff183b
Found by
Semantic Scholar
Authors
Anikait Singh, Teresa Zhang, Yoonho Lee, Roshen Sanjay Nair, Aviral Kumar, Chelsea Finn
Categories
dataset
Published
2026-10-15
Last seen by the radar
2026-10-17
Citations
0
Influential citations
0
Radar score
26.75 / 100 (how it is scored)
Why it scored so
Matched: corpora$; Primary record: Semantic Scholar
Related links
https://arxiv.org/abs/2610.22273
Is this record right? If you made this work and something here is wrong or missing, tell us what to fix.

More records found by Semantic Scholar