Wikidata Search Traces: A Dataset for Training Knowledge Graph Search Agents
cs.CL
Submitted: 2026-10-05
Updated: 2026-10-09
Comments: Technical Report
Code: https://github.com/PrimeIntellect-ai/nano-rlm
License: http://creativecommons.org/licenses/by/4.0/
The gist: Wikidata is one of the largest open knowledge bases, yet answering a complex question over it still requires a SPARQL query that names the right entities and properties and chains their relations.
Terminology
Abstract
Wikidata is one of the largest open knowledge bases, yet answering a complex question over it still requires a SPARQL query that names the right entities and properties and chains their relations. Language models offer a natural-language alternative but answer largely from memory, which is least reliable for less prominent entities. We study agents that instead answer by exploring the graph, and argue that two obstacles limit them: the lack of training data recording how a solver explores, and interfaces that add large graph results directly to the model's context. We test three hypotheses: that the difficulty of graph search can be controlled through the structure of a question rather than only through obscure entities or wording; that much of the failure on long-horizon search comes from how retrieved evidence is managed rather than from the model itself; and that, in a suitable environment, open-weight models can match commercial closed ones. We construct multi-hop questions on a frozen Wikidata snapshot by replacing named entities with nested conditions, checking after each expansion that the target remains unique and that every new condition is necessary. We release 10,235 solving traces over single-entity and multi-hop questions, together with the recursive language model (RLM) harness that produced them, in which models batch graph calls, keep results in persistent Python state and interpret selected evidence through sub-calls. On 100 questions, the harness improves both models we ran under both interfaces compared with direct tool calling over the same functions: gpt-6-luna rises from 49 to 61 correct answers, doubling its multi-hop accuracy, and Qwen3.8-27B, an open-weight model served on a single GPU, from 60 to 74.
Sources
- When Not to Trust Language Models: Investigating Effectiveness of Parametric and Non-Parametric Memories
- KQA Pro: A Dataset with Explicit Compositional Programs for Complex Question Answering over Knowledge Base
- The Wikidata Query Logs Dataset
- ReAct: Synergizing Reasoning and Acting in Language Models
- RULER: What's the Real Context Size of Your Long-Context Language Models?
- Recursive Language Models
- Beyond I.I.D.: Three Levels of Generalization for Question Answering on Knowledge Bases
- Diagnosing and Addressing Pitfalls in KG-RAG Datasets: Toward More Reliable Benchmarking
- DeepDive: Advancing Deep Search Agents with Knowledge Graphs and Multi-Turn RL
- WebSailor: Navigating Super-human Reasoning for Web Agent
- REDSearcher: A Scalable and Cost-Efficient Framework for Long-Horizon Search Agents
- SearchArt: Training Long-Horizon Search Agent with Scalable Synthetic and Verified Task
- Open Data Synthesis For Deep Research
- WebShaper: Agentically Data Synthesizing via Information-Seeking Formalization
- LoHoSearch: Benchmarking Long-Horizon Search Agents Beyond the Human Difficulty Ceiling
- Think-on-Graph: Deep and Responsible Reasoning of Large Language Model on Knowledge Graph
- KG-Agent: An Efficient Autonomous Agent Framework for Complex Reasoning over Knowledge Graph
- Executable Code Actions Elicit Better LLM Agents
Related papers
- Exploring Solution Divergence and Its Effect on Large Language Model Problem Solving
- Ishigaki-IDS-Bench: A Benchmark for Generating Information Delivery Specification from BIM Information Requirements
- Subliminal Steering: Stronger Encoding of Hidden Signals
- MedStruct-S: A Benchmark for Key Discovery, Key-Conditioned QA and Semi-Structured Extraction from OCR Clinical Reports
- The End of Transformers? On Challenging Attention and the Rise of Sub-Quadratic Architectures
- Untangling the Mechanisms of Misleading Context in Medical Question Answering