PatternBloom: Empowering Agentic RAG with Externalized RL-Distilled Graph Patterns

Yi Ge, Heng Huang

TL;DR

PatternBloom is a novel agentic Retrieval-Augmented Generation (RAG) framework that shifts the focus from retrieving content (facts) to retrieving logic (reasoning structures). By externalizing reasoning patterns into a "Graph Pattern Memory" distilled via reinforcement learning, it achieves a massive +15.0 point gain in out-of-distribution accuracy, allowing a 7B model to outperform 72B giants.

What Problem Does This Paper Address?

Current agentic RAG systems—where an AI agent decides what to search for and when—primarily focus on content retrieval. They fetch passages or knowledge graph fragments, but the actual "reasoning route" (the logic of how to connect these facts) remains hidden within the model's internal weights.

This creates a major bottleneck: for every new query, the model has to re-derive the reasoning logic from scratch. For example, if a model knows how to find the "birth country of a film director" for one movie, it doesn't explicitly "remember" that logical sequence for the next movie; it just re-executes it. As questions get more complex and require more "hops" of reasoning, performance plateaus because the model struggles to maintain these long, implicit logical chains.

Figure 1: Content Retrieval paradigm versus Logic Retrieval paradigm. Left: prior paradigms retrieve content units (passages, knowledge-graph fragments, or hyperedges), leaving the reasoning route implicit in policy weights. Right: PatternBloom retrieves a typed reasoning skeleton from an externalized Graph Pattern Memory and traverses it as an explicit logic path.

Methods

PatternBloom introduces a two-stage Reinforcement Learning (RL) pipeline to externalize and reuse reasoning logic:

  1. Stage I: Evidence Construction with IDR: The agent is trained to build an evidence graph. Instead of just rewarding the final answer, the authors introduce the Information-Density Reward (IDR). This information-theoretic reward scores the constructed graph based on how much it increases a frozen "oracle" model's confidence in the correct answer, normalized by the graph's size. This forces the agent to find the "minimum sufficient" evidence.
  2. Pattern Distillation: High-reward reasoning trajectories from Stage I are distilled into a Graph Pattern Memory (GPM). These are "type-abstracted" skeletons—for example, instead of remembering a specific director, it remembers the path: FILM -> directed_by -> PERSON -> born_in -> COUNTRY.
  3. Stage II: Policy Refinement with PAR: The agent is re-trained using the Pattern-Augmented Reward (PAR). This reward incentivizes the agent to follow the explicit logical paths stored in the GPM. This turns reasoning from a "black-box" behavior into a retrievable, learnable structural prior.
Figure 2: PatternBloom pipeline. Top: training with intermediate pattern distillation between Stage I (IDR) and Stage II (PAR). Bottom: deployment uses only trained policy and frozen pattern memory.

Datasets

The authors evaluated PatternBloom against 27 baselines across seven multi-hop and single-hop QA benchmarks:

  • In-Distribution (IID): HotpotQA and 2WikiMultiHopQA (used for training).
  • Out-of-Distribution (OOD): MuSiQue, Natural Questions (NQ), TriviaQA, PopQA, and Bamboogle.

The OOD datasets are particularly challenging as they test the model's ability to generalize its learned reasoning patterns to entirely new topics and more complex (up to 4+ hop) questions.

Key Insights and Ideas

  • Logic as a Retrieval Unit: The core "aha" moment is that reasoning logic is procedural knowledge that recurs across many queries. By making this logic a first-class object that can be retrieved, the model doesn't have to waste "mental effort" re-deriving it.
  • Information-Density as a Reward: Moving away from simple "is the answer right?" rewards to information-theoretic ones (IDR) provides a much cleaner signal for training agents to build high-quality, concise evidence chains.
  • A New Scaling Axis: Traditionally, we scale RAG by using bigger models or more documents. PatternBloom suggests a third axis: procedural-knowledge accumulation. The same frozen "logic memory" can be transferred across different model sizes (from 1.5B to 32B) and even different model families.
  • Compounding Gains with Depth: Unlike content-only methods that fail as reasoning depth increases, PatternBloom’s performance gap widens on deeper queries because the reused logical skeletons provide a stable "map" for the agent to follow.

Key Results

  • State-of-the-Art Performance: A 7B PatternBloom model achieved a +15.0 point lead in Average OOD Exact Match (EM) over leading RL-based RAG agents like R1-Searcher.
  • Efficiency: The 7B model outperformed a 72B prompt-engineered RAG system by 17.1 points while using 1/10th the parameters.
  • Robustness to Depth: On the MuSiQue dataset, PatternBloom showed the flattest performance decay as the number of reasoning hops increased, outperforming baselines by a factor of 4.5x on the hardest 5+ hop questions.
  • Human Preference: In a blind human study, PatternBloom's reasoning trajectories were rated significantly higher for logical coherence and reusability compared to other state-of-the-art systems.

Limitations and Future Work

  • Domain Specificity: Currently, the system is built on a Wikipedia-based hypergraph. The authors note that testing cross-domain transfer to specialized fields like medicine, law, or finance is a natural next step.
  • Memory Quality: A poorly curated pattern memory could potentially mislead the agent. The authors suggest that production systems might benefit from an "LLM-judge" or human audit of the distilled patterns before they are frozen for deployment.
  • Static Memory: While the memory is distilled from the agent's own experience, it is currently frozen after training. Future work could explore "lifelong learning" where the pattern library continues to grow and refine itself during deployment.

Summary updated

Abstract

Reinforcement-learning-trained agents for retrieval-augmented generation retrieve content (passages, knowledge-graph fragments, or hyperedges) and supervise training with outcome rewards on the final answer. Across these paradigms the reasoning route through retrieved content never leaves the language model's hidden state, conflating declarative knowledge with the procedural knowledge that recurs across queries of the same logical type; content-only methods consequently plateau as reasoning depth grows. We introduce PatternBloom, an agentic RAG framework that shifts the unit of retrieval from content (what to read) to logic (how to reason). A first RL stage scores the agent's constructed evidence graph by a frozen oracle's information gain through the Information-Density Reward (IDR), a size-normalized mutual-information surrogate. High-reward trajectories are distilled into a Graph Pattern Memory (GPM) of type-abstracted reasoning skeletons, and a second RL stage uses the Pattern-Augmented Reward (PAR) to couple policy to memory, turning procedural reasoning into a learnable, externalized structural prior. A 7B PatternBloom outperforms $27$ baselines by $+15.0$ Avg-OOD EM, with the gain compounding with reasoning depth precisely because procedural knowledge, once distilled, is reused rather than re-derived at every query. We release our code at https://github.com/EllenYiGe/PatternBloom.
BibTeX
@inproceedings{ge2026patternbloom,
  author = {Yi Ge and Heng Huang},
  title = {{PatternBloom: Empowering Agentic RAG with Externalized RL-Distilled Graph Patterns}},
  booktitle = {Advances in Neural Information Processing Systems},
  year = {2026},
  url = {https://openreview.net/forum?id=SDljMGVCMp},
}
Figure