Search-R1: Training LLMs to Reason and Leverage Search Engines with Reinforcement Learning

Bowen Jin, Hansi Zeng, Zhenrui Yue, Jinsung Yoon, Sercan Arik +3 more
3/12/2025
1,816 citations
cs.CLcs.AIcs.IR
rlrag

Official code: PeterGriffinJin/Search-R1 (5,553 stars, Python, Apache-2.0, last commit 2025-11-13).

Abstract

Efficiently acquiring external knowledge and up-to-date information is essential for effective reasoning and text generation in large language models (LLMs). Prompting advanced LLMs with reasoning capabilities to use search engines during inference is often suboptimal, as the LLM might not fully possess the capability on how to interact optimally with the search engine.

Show full abstract

This paper introduces Search-R1, an extension of reinforcement learning (RL) for reasoning frameworks where the LLM learns to autonomously generate (multiple) search queries during step-by-step reasoning with real-time retrieval. Search-R1 optimizes LLM reasoning trajectories with multi-turn search interactions, leveraging retrieved token masking for stable RL training and a simple outcome-based reward function. Experiments on seven question-answering datasets show that Search-R1 improves performance by 41% (Qwen2.5-7B) and 20% (Qwen2.5-3B) over various RAG baselines under the same setting. This paper further provides empirical insights into RL optimization methods, LLM choices, and response length dynamics in retrieval-augmented reasoning. The code and model checkpoints are available at https://github.com/PeterGriffinJin/Search-R1.

View on arXivView PDF

Code Implementations(1)

Apache-2.0

Search-R1: An Efficient, Scalable RL Training Framework for Reasoning & Search Engine Calling interleaved LLM based on veRL

5,553500Python, ShellFeb 28, 20251 years agoApache-2.0

Similar Papers

Cite this paper

@article{jin2025searchr,
  title  = {Search-R1: Training LLMs to Reason and Leverage Search Engines with Reinforcement Learning},
  author = {Bowen Jin and Hansi Zeng and Zhenrui Yue and Jinsung Yoon and Sercan Arik and Dong Wang and Hamed Zamani and Jiawei Han},
  year   = {2025},
  eprint = {2503.09516},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2503.09516v5}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2503.09516.svg)](https://codeofpaper.com/paper/2503.09516)

Discussion