Recursive Language Models
Alex L Zhang, Tim Kraska, Omar Khattab
NeurIPS 2026
TL;DR. We introduce Recursive Language Models (RLMs), a general-purpose inference paradigm for dramatically scaling the effective input and output lengths of LLMs through symbolic recursion.
Abstract. We study allowing large language models (LLMs) to process arbitrarily long prompts through the lens of inference-time scaling. We propose Recursive Language Models (RLMs), a general inference paradigm that treats long prompts as part of an external environment and allows the LLM to programmatically examine, decompose, and recursively call itself over snippets of the prompt. We find that RLMs can successfully process inputs more than an order of magnitude beyond model context window limits and, even for shorter prompts, dramatically outperform the quality of vanilla frontier LLMs and common long-context scaffolds (e.g., on GPT-5 by a median across the evaluated benchmarks of 26% against compaction, 130% against CodeAct with sub-calls, and 13% against Claude Code) across four diverse long-context tasks while having comparable cost. At a small scale, we post-train the first model around the RLM. Our model, RLM-Qwen3-8B, outperforms the underlying Qwen3-8B model by a median of 28% and even approaches the quality of vanilla GPT-5 on three long-context tasks.
Are you an author? Claim this paper to see who's reading it, with views and other statistics, and to write about it here.
Claim this paperedit · history
NeurIPS 2026
Accept (poster) · 3 reviews · OpenReview
Updated 25 Nov 2026, 03:43 UTC.
- Decision
- Accept (poster)
Read decision
Meta-review
This paper introduces Recursive Language Models, which processes long inputs by invoking language models recursively on selected portions and aggregating intermediate results. The reviewers found the idea simple and the empirical results promising.
The current reviewer consensus is borderline reject and the main issue is whether the improvements can be attributed specifically to the adaptive RLM mechanism. In particular, the paper does not appear to isolate RLM from simpler alternatives that also externalize the full prompt and use repeated model calls, such as fixed chunking followed by sub-LM calls and deterministic aggregation, or recursive self-delegation through subagents. As a result, it is currently hard to determine whether the gains come from adaptive programmatic decomposition and recursion, from prompt offloading, from allocating additional inference compute, or from the combination of these. This also affects the strength of the paper's framing as a new general inference paradigm.
The author response should therefore focus on the below points, of which the first two are most consequential:
- Clarifying the precise conceptual and practical distinction between RLM and self-delegation or fixed-decomposition alternatives.
- Disentangling the contribution of adaptive RLM from prompt offloading, repeated subcalls, and additional inference compute.
- Clarifying the observed dependence on the underlying model, particularly the large performance differences between GPT-5 and Qwen3-Coder under RLM despite similar base model performance.
====Post Rebuttal==== My main concern in the initial metareview was whether the gains could be attributed to the RLM design. The rebuttal made many clarifications that many requested ablations are already included, and two reviewers gave a 4 now. Overall, I think the core idea is interesting and the results are strong, so I will change my initial recommendation and recommend acceptance if space permits.
Final justification
see above under "Post Rebuttal"
- Final justification
- see above under "Post Rebuttal"
Read meta-review
Meta-review
This paper introduces Recursive Language Models, which processes long inputs by invoking language models recursively on selected portions and aggregating intermediate results. The reviewers found the idea simple and the empirical results promising.
The current reviewer consensus is borderline reject and the main issue is whether the improvements can be attributed specifically to the adaptive RLM mechanism. In particular, the paper does not appear to isolate RLM from simpler alternatives that also externalize the full prompt and use repeated model calls, such as fixed chunking followed by sub-LM calls and deterministic aggregation, or recursive self-delegation through subagents. As a result, it is currently hard to determine whether the gains come from adaptive programmatic decomposition and recursion, from prompt offloading, from allocating additional inference compute, or from the combination of these. This also affects the strength of the paper's framing as a new general inference paradigm.
The author response should therefore focus on the below points, of which the first two are most consequential:
- Clarifying the precise conceptual and practical distinction between RLM and self-delegation or fixed-decomposition alternatives.
- Disentangling the contribution of adaptive RLM from prompt offloading, repeated subcalls, and additional inference compute.
- Clarifying the observed dependence on the underlying model, particularly the large performance differences between GPT-5 and Qwen3-Coder under RLM despite similar base model performance.
====Post Rebuttal==== My main concern in the initial metareview was whether the gains could be attributed to the RLM design. The rebuttal made many clarifications that many requested ablations are already included, and two reviewers gave a 4 now. Overall, I think the core idea is interesting and the results are strong, so I will change my initial recommendation and recommend acceptance if space permits.
- Rating
- 4/6
- Confidence
- 4/5
- Quality
- 3/4
- Clarity
- 3/4
- Significance
- 3/4
- Originality
- 2/4
- Contribution type
- general
- Ethical concerns
- NO or VERY MINOR ethics concerns only
Read review
Summary
The paper introduces Recursive Language Models (RLMs), which are a general inference paradigm that treats an arbitrarily long input prompt as an external environment rather than feeding it directly into the model's context window. The prompt is stored as a variant in a REPL environment; write code that peeks into, decomposes, and recursively invokes the underlying model over programmatic snippets of the variable, addressing three flaws in base models: lack of symbolic handle, direct generation of the output, and lack of symbolic recursion. RLMs are evaluated with GPT-5 and Qwen3-Coder-480B and show a median 28% performance improvement across four tasks compared with the base model, CodeAct, Compaction agent, and OpenCode.
Strengths and weaknesses
Strengths
- The central idea is clean and well-motivated: The adopted symbolic approach to programmatically handle long context is interesting and reasonable for handling long context tasks. The results shown in Figure 1 about performance over input context length provide clear motivations for recursive language models.
- Ablation on recursion depth with API cost is interesting: results report on recursion depth along with API cost provide a more complete story on the design of RLM from the perspectives of model design and efficiency.
- Good experiment results on given models and tasks: Out of all benchmarks and baselines, RLM is almost always the best performing approach.
- Promising training direction: The insight regarding an effective sub-call model, which resembles general reasoning, makes small-scale training tractable and is promising.
Weaknesses
- Unsure about where the gain comes from: no baseline combines full-rpompt offloading with programmatic sub-call dispatch, so the RLM's advantage could come from the conjunction, from offloading alone, or from better allocation of compute budget. No abolition studies have been conducted to disentangle the performance gain.
- Somewhat overclaim of new paradigm: the mechanism is an elegant composition of existing pieces to tackle real-world applications. The claim of proposing a new paradigm is still somewhat overstated.
- Inference latency is not reported: The paper didn't include the results on inference latency of RLM compared with baselines. How does latency scale with context length and task complexity?
- API cost scalability: The API cost doubled frequently with increasing recursion depth. How costly is the framework with increasing recursion depth and context length?
- RLM varied performance across two base models. The base model performance in Table 1 for GPT-5 and Qwen3-Coder-480B-A35B is similar, while RLM performance on the two models shows a large gap. For example, on OOLONG-Pairs, both GPT-5 and Qwen3-Coder-480B-A35B have 0.1 for Base Model, while GPT-5 + RLM has 76.0, versus Qwen3-Coder-480B-A35B + RLM has 23.1. Similar to BrowseComp+ and OOLONG. Any intuition behind why the performance of RLM differs this much? Since RLM performance varies dramatically across the two base models, a third base model should be considered to show model-agnostic
Questions
Refer to weaknesses
Limitations
yes
Final justification
My concerns during rebuttal, including ablation control, conceptual novelty, and cost scaling, are mostly addressed. One remaining concern is the ablation of additional model families, as task performance varies across existing model families and is particularly strong for GPT-5. I lean towards acceptance, giving the remaining concern.
Formatting concerns
no
3 comments
CodeAct ablations You frame "CodeAct" and "CodeAct + sub-agents" as ablations of the RLM, but they read more like a different approach in the table. Do they share the RLM's exact pipeline (same root model, sub-call model, recursion budget, iteration limits, scoring), with the only differences being prompt offloading and programmatic sub-calling? If the loop structure or action interface also differs, the Table 1 gap can't be cleanly attributed to those two features. A precise account of what's held fixed vs. what changes would make the ablation convincing.
Novelty of the composition I'm sympathetic to the view that many strong methods are elegant compositions. To weigh the contribution, I'd like to hear what's novel beyond combining the three ingredients — e.g., a non-obvious design insight that makes the composition work where prior combinations wouldn't, a capability unachievable by any piece in isolation.
Cost growth rate In Figure 16, RLM cost per query grows noticeably faster with context length than the base model, especially on OOLONG-Pairs. My concern is generalization to longer contexts: even if absolute costs stay within an order of magnitude in the tested range, this steeper growth rate suggests the cost advantage could erode or reverse as contexts scale beyond what's evaluated here. Could you comment on how RLM cost is expected to behave at those longer lengths?
We thank you for your response, and we also hope our rebuttal was sufficient to answer your earlier questions and concerns as well. We answer your new questions below, and are happy to answer any additional concerns you may have:
CodeAct ablations. You frame "CodeAct" and "CodeAct + sub-agents" as ablations of the RLM, but they read more like a different approach in the table…
We will update the writing to make this clearer for the reader, but we note that in Section 3.2 when we first introduce CodeAct and CodeAct + sub-agents as a baseline and ablation of the RLM, we explicitly state: “Unlike an RLM, CodeAct does not offload the user prompt to the code environment, and instead provides it directly to the LM. We consider two variants… (2) a version with a sub-call tool inside of the REPL. Compared to RLMs, this method loads the context directly into the model.”
In the implementation of CodeAct and CodeAct with sub-agents, we use the RLM implementation with extra ablated flags to either include sub-agents as functions, or include context directly. The rest of the arguments are identical. They are direct ablations of the RLM, both in theory and in practice in Table 1.
Novelty of the composition. To weigh the contribution, I'd like to hear what's novel beyond combining the three ingredients…
We first note that the widely accepted design of harnesses involves 1) a growing context containing a history of observations that a main LM directly interfaces with; 2) API-based tool calls that are invoked by the model; 3) provide answers from the model output. These are explicit design choices that define the current paradigm of harnesses. RLMs deviate from all three at once.
The non-obvious design insight is that the behavior of the LM inside an RLM harness is very different than that of a standard harness, despite each individual component not greatly affecting the behavior of the original harness on its own. To be more specific, the non-obvious unique behavior that emerges from RLM harnesses is the ability to observe different tasks as similar and act over them with LM programs, by keeping the long context as a variable in memory rather than in the language model’s context. Furthermore, the RLM can act such that it handles tasks with arbitrarily long input, output, and horizon. Effectively, an RLM can generate agent scaffolds over its context on the fly, which requires all three of the stated components. With only prompt offloading, the LM must still eventually read and find a way to read all of the relevant information from the context, which is difficult without a symbolic handle to it or the ability to programmatically access it. With the CodeAct design of using only a REPL, the LM is forced to take actions based on a large context, rather than abstract away and answer based on a short context window.
The empirical value of this paradigm and the major behavioral change described above is clear from Table 1: each ablation of these components performs considerably worse than the RLM on at least one of the long tasks, and in many cases all of them. Only the RLM harness itself performs well across all tasks compared to any of its ablations, and the behavior is well understood and studied in Sections 4 and 5. The decompositional actions that an RLM makes on all of the benchmarks are either not possible or very difficult for any ablation of the RLM features.
Cost growth rate. In Figure 16, RLM cost per query grows noticeably faster with context length than the base model, especially on OOLONG-Pairs… Could you comment on how RLM cost is expected to behave at those longer lengths?
We first note that the cost of RLMs is a direct consequence of the behavior of the underlying LM, which currently is not trained to act as an RLM. The optimal behavior on OOLONG-Pairs is to chunk, run a sub-call over each input, then programmatically construct the output, allowing the RLM cost to scale linearly if it learns the correct decomposition. However, the fixed LM does not exactly perform this decomposition in some cases, leading to tail-end costs that are expensive. Over time, as LMs are trained as RLMs, their costs will likely scale better with more cost-efficient behavior. We observe this effect in Table 3 in our training experiments, where the untrained Qwen3-8B model uses redundant steps as an RLM, but the trained version is much faster and cheaper.
We also note that other harnesses and models cannot solve OOLONG-Pairs at any cost. Training models to solve dense tasks is extremely expensive, and likely would also allow the RLM itself to take a cheaper strategy of simply invoking the model. Furthermore, tasks like BrowseComp-Plus show significantly flatter cost scaling curves despite being orders of magnitude longer. RLM cost scales as a function of both length and task complexity, which is not exclusive to RLMs, and would occur for any other harness as well.
- Rating
- 4/6
- Confidence
- 4/5
- Quality
- 3/4
- Clarity
- 3/4
- Significance
- 3/4
- Originality
- 3/4
- Contribution type
- general
- Ethical concerns
- NO or VERY MINOR ethics concerns only
Read review
Summary
Recursive language models (RLMs) describe a harness for LLMs intended to process long-context inputs using a REPL environment. To interact with this context, the LLM generates a Python program to decompose the input into smaller sub-parts and queries these smaller components with an LLM before providing a final output. Importantly, these sub-queries can themselves be RLMs enabling recursive processing of the input.
Strengths and weaknesses
Strengths:
- The general idea is novel and valuable; treating text as the object of manipulation in a REPL environment where an LLM can write code to process its context by recursively calling itself opens up interesting new research directions.
- The experiment section is fairly convincing and the analysis and ablations are generally comprehensive. The structure of the results section in terms of enumerating key observations helped with clarity. I especially appreciated the authors listing negative results in the appendix, I think this practice needs to be encouraged a lot more in research so I applaud the authors for describing their failed attempts.
Weaknesses:
- One point I am stuck on philosophically is why we should expect RLMs to be better than self-delegation approaches where an LLM can recursively call itself using a sub-agent tool rather than in code. The authors note that these approaches "are handicapped by the underlying LLM’s limited output lengths because they are designed to verbalize sub-calls autoregressively rather than producing them programmatically." but I don't quite understand this point. Can the authors please provide more details on the differences here and why one is better than the other, also ideally a direct empirical comparison would help convince me of RLM benefits.
- The authors focus their motivation on processing long-form inputs where the base prompt is very large. However, long context need not just stem from long-form inputs, it can also arise from having many intermediate steps in long-horizon tasks even when the base prompt is itself short (e.g., coding a complicated website). Conceptually, the RLM framework should still be applicable in this setting but it's unclear whether additional scaffolding is needed. Can the authors comment on the framework's generality and whether it is limited, it its current version, to long-form inputs or can it also be applied out-of-the-box to long-horizon tasks, and what (if any) modifications need to be made.
- The authors initially describe compaction methods as summarization once context exceeds a certain threshold. However, the LLM can also have a summarization tool and the model can itself decide when is an opportune time to summarize its context. The authors do mention this in the Related Works, but it's unclear whether their Compaction Agent baseline uses thresholding or tool calling. In many modern harnesses, a combination of the two is used. Can the authors please clarify what they used.
Questions
- When a recursive RLM query is initiated within the REPL, is the current (parent) REPL state shared with that of its spawned child, or is a new isolated REPL environment created?
- See also questions listed in the weaknesses above.
Should the authors adequately address all these points, I will consider further increasing my score to recommend acceptance.
Limitations
Yes
Final justification
I appreciate the authors' response and having addressed most of my concerns. In terms of self-delegation approaches with sub-agent tool calling (e.g., OpenCode, Claude Code), although I do conceptually agree with the points the authors raise this does not seem to translate to empirical improvements in Table 1 except for OOLONG-Pairs which is a somewhat contrived dataset in my view. However, I do still see value in this work and so will increase my score to a 4.
Formatting concerns
N/A
1 comment
Rebuttal
We thank the reviewer for taking the time to review our work and provide valuable feedback. We also thank the reviewer for recognizing the novelty of the work, and the completeness of the experiments and analysis.
The reviewer’s comments have been valuable for knowing what areas need extra clarification in the paper. We answer your questions below, namely clarifying how the paper addresses:
- where RLMs differ from self-delegation approaches both conceptually and empirically.
- a long-horizon benchmark was evaluated and discussed in Table 2 and Observation 5.
- details of the compaction agent, described in Appendix C.2.
One point I am stuck on philosophically is why we should expect RLMs to be better than self-delegation approaches where an LLM can recursively call itself using a sub-agent tool rather than in code…
Conventionally, before RLMs, sub-agents were invoked using a standard tool-calling interface, e.g. a JSON-based API, in which the main agent has to verbalize a concrete string prompt for each sub-agent and read its concrete output in the main context window.
The two main limitations of that approach, presented in Flaw #3 of Algorithm 2, lie in the flexibility of what you can orchestrate with tool calls, and where all this intermediate context lives:
-
Orchestration. To fan out N sub-agents in a pattern, the LLM has to specify and emit N different tool calls. If the LLM accidentally only invokes it N-2 times during autoregressive generation, and your answer relies on all sub-calls being launched correctly, it will get the answer wrong. An RLM instead expresses this orchestration process compactly via code, which naturally supports looping, conditional, and even data-dependent tool calling.
-
Context. LLM’s have a limited context window. If sub-calls are treated like tools, the inputs and outputs of these sub-calls have to consume a very sizable fraction of the main LLM’s context window. Consider OOLONG-Pairs as an example. From a list of 1000 entries, you may need to generate up to 1M pairs in the output answer by first examining the list with sub-calls, then generating pairs from that augmented list. The RLM is able to store the augmented list in memory, and act over it with more sub-calls to produce the final answer; it can describe this whole process in code. A conventional sub-agent tool construction is forced to iteratively form the augmented list, then iteratively produce all pairs it needs to answer the question, which is exhaustively large and prone to error.
As for empirical evidence provided in the paper, Claude Code and OpenCode with context offloading serve as the direct comparison in Table 1 of a strong harness that uses a sub-agent tool rather than code. The poor performance (<7% F1) of all of these methods on OOLONG-Pairs is a consequence of the limitation highlighted above, despite Claude Code even having a model that was trained around its harness. This is also discussed in Observation 2 (page 6) of the results, and provides direct empirical evidence for the limitations described above.
Can the authors comment on the framework's generality and whether it is limited, in its current version, to long-form inputs or can it also be applied out-of-the-box to long-horizon tasks, and what (if any) modifications need to be made. We agree that a discussion and empirical result on long-horizon and other non long-input tasks would strengthen the argument around the applicability of the RLM harness.
The LongCoT-mini benchmark included in Table 2, which we also discussed in Observation 5, is a short-form long-horizon benchmark that the reviewer is describing; we evaluated on this benchmark and showed large performance improvements without any adjustments to the harness. This benchmark explicitly provides a short prompt, requiring the model to answer difficult sub-questions within a larger reasoning graph to ultimately find the correct answer.
As the reviewer noted, a long-horizon task can often be reduced to a long-context task, which an RLM is suitable to answer without modification. The results in Table 2 show that the RLM significantly increases the performance of the base model on this difficult long-horizon reasoning task. Lastly, we also point out that OOLONG-Pairs is not a long-form input task: it has an input context of 32k tokens (well within the context window of any modern LM), but serves as a task where the model must process and yield a long output answer.
In general, RLMs are not exclusively applied to long-context or even long tasks; they can be applied to general tasks as other harnesses do, without modification. Features like programmatic tool / sub-calling are beneficial beyond just long context, as evidenced by their inclusion in Anthropic’s Dynamic Workflows feature [1] for coding tasks.
The authors initially describe compaction methods as summarization once context exceeds a certain threshold. However, the LLM can also have a summarization tool and the model can itself decide when is an opportune time to summarize its context. The authors do mention this in the Related Works, but it's unclear whether their Compaction Agent baseline uses thresholding or tool calling. In many modern harnesses, a combination of the two is used. Can the authors please clarify what they used.
We included implementation details on the compaction agent in Appendix C.2, which only uses a thresholding compaction rule with a rule about chunking overflowed context. It follows a baseline used in several other context folding papers [2,3,4]. To make it easier to find, we will explicitly reference this Appendix section in Section 3.2, and rename it to “Compaction agent implementation details”.
Lastly, we point out that Claude Code and OpenCode are also included as baselines in these experiments, both of which have and use a compaction tool and thresholding that they can use as a comparison for the harness design the reviewer described.
When a recursive RLM query is initiated within the REPL, is the current (parent) REPL state shared with that of its spawned child, or is a new isolated REPL environment created?
The REPL environment of a recursively called RLM is completely new and isolated. The parent RLM can choose what information to transfer over to the REPL of the sub-RLM call. We will make this detail clearer in the revision.
We thank the reviewer for their time in reading our work. We are happy to answer and incorporate any related or follow-up questions, or additional concerns the reviewer may have.
References
[1] Anthropic, "Introducing Dynamic Workflows in Claude Code," Claude Blog, Jun 2026.
[2] Sun et al., "Scaling Long-Horizon LLM Agent via Context-Folding," arXiv:2510.11967, Oct 2025.
[3] Wu et al., "ReSum: Unlocking Long-Horizon Search Intelligence via Context Summarization," arXiv:2509.13313, Sep 2025.
[4] Yu et al., "MemAgent: Reshaping Long-Context LLM with Multi-Conv RL-based Memory Agent," ICLR 2026, Jul 2025.
- Rating
- 3/6
- Confidence
- 3/5
- Quality
- 3/4
- Clarity
- 2/4
- Significance
- 2/4
- Originality
- 2/4
- Contribution type
- general
- Ethical concerns
- NO or VERY MINOR ethics concerns only
Read review
Summary
This paper proposes Recursive Language Models (RLMs), an inference-time framework for handling long-context inputs by placing the prompt and states in an external REPL environment rather than directly feeding it into the model context. The root model can programmatically inspect and decompose the input, invoke sub-LMs or sub-RLMs on selected snippets, and aggregate intermediate results through external state. Overall, the paper presents a unified framework for combining code execution, recursive model calls, and long-context task decomposition.
Strengths and weaknesses
Strengths
-
The paper addresses an important and well-motivated problem. Instead of focusing only on nominal context length, it highlights how the effective context window can degrade as task complexity increases. This setting reflects a real limitation of current long-context models, especially on information-dense tasks.
-
The framework is conceptually appealing in its simplicity. It lets the model decide how to inspect, decompose, and process long inputs through explicit stateful interaction with external context, offering a more scalable and controllable alternative to context stuffing or repeated compaction.
-
The paper also provides useful trajectory-level analyses that make the behavior of RLMs more transparent. By examining decomposition patterns, sub-call behavior, and failure cases, the paper offers valuable qualitative insight beyond aggregate benchmark scores.
Weakness
-
The applicability of depth=0 may be limited. Since it mainly relies on code-based retrieval and aggregation, it may struggle with natural language understanding problems involving pronoun resolution, entity coreference, or cross-segment dependencies. The experiments do not seem to sufficiently cover such scenarios.
-
The paper lacks key ablations to demonstrate the necessity of the dynamic RLM decision-making mechanism. Many evaluated tasks may already benefit from a simpler fixed pipeline, such as fixed chunking, repeated sub-LM calls, and deterministic Python aggregation. A fixed chunking + sub-LM + deterministic aggregation baseline would make the contribution of adaptive RLM control clearer.
-
The source of improvement after training the open-source model is not sufficiently disentangled. The performance gain of Qwen3-8B may come from better protocol following, chunking behavior, and tool-use formatting, rather than from a genuine improvement in deciding when to retrieve, when to call subagents, when to stop, and how to aggregate intermediate results.
Questions
Please refer to my weakness
Limitations
yes
Formatting concerns
N/A
1 comment
Rebuttal
We thank the reviewer for taking the time to read and provide valuable feedback on our work. We also appreciate the acknowledgement of the conceptually simple but well-motivated design of RLMs, as well as the qualitative insights we provide in the paper. We address your questions below, which have been valuable for understanding what needs clarification in the main paper and will update the writing accordingly to make it clearer how each concern is currently addressed.
The applicability of depth=0 may be limited. Since it mainly relies on code-based retrieval and aggregation, it may struggle with natural language understanding problems involving pronoun resolution, entity coreference, or cross-segment dependencies. The experiments do not seem to sufficiently cover such scenarios.
We point out that depth=0 exists as an ablation to highlight why programmatic sub-agent calling at depth>=1 of recursion is useful or even sometimes necessary. While the tasks the reviewer describes may further highlight the limitations of depth=0, we point out that the existing benchmarks already show this:
- On OOLONG, the RLM(GPT-5, depth>0) methods perform 33-60% better than depth=0 across both models. OOLONG is hard for depth=0 because it requires semantically mapping each entry to some label. The depth=0 model develops a heuristic for estimating this, yielding non-zero but weaker performance.
- On OOLONG-Pairs, RLM(GPT-5, depth>0) yields a noticeably large improvement (near double) over depth=0 across both models.
- On BrowseComp-Plus, RLM(Qwen3-480B) struggles to retrieve the right documents with depth=0, but with depth>=1 it uses a more direct divide-and-conquer approach to yield better performance at a higher token cost.
The paper lacks key ablations to demonstrate the necessity of the dynamic RLM decision-making mechanism. Many evaluated tasks may already benefit from a simpler fixed pipeline, such as fixed chunking, repeated sub-LM calls, and deterministic Python aggregation. A fixed chunking + sub-LM + deterministic aggregation baseline would make the contribution of adaptive RLM control clearer.
The necessity of the dynamic RLM decision-making mechanism lies in the fact that it works out of the box across several different task environments in Table 1.
We fully agree that if we extract the strategy that the RLM creates for each task and freeze it, then that fixed pipeline will always be competitive on an individual benchmark. However, it would be of much less practical value because it presupposes we know in advance about one narrow domain. Our goal is to develop a general-purpose inference strategy, on par with the baselines we do compare against like reasoning models, coding agents, and compaction agents. The goal is not to compete with a human-designed per-task system.
In other words, each environment (and sometimes unique tasks within an environment) presents a unique chunking and aggregation scheme. For example, an explicit decomposition describing a fixed chunking scheme and a set of deterministic aggregation operators on OOLONG does not work for OOLONG-Pairs, BrowseComp-Plus, or LongBenchv2. This observation holds across all benchmarks in the paper, especially LongCoT-mini, which carries a completely different type of decomposition compared to any of the other benchmarks; chunking and aggregation does not work for this benchmark.
Lastly, we point out that we also included many ablations in Table 1 that ablate how different features of the RLM (namely prompt offloading and programmatic sub-calling) contribute to its overall lift in performance on long tasks. Indeed, we included a compaction agent as one relatively fixed chunking and aggregation scheme in Table 1, and it performs quite poorly.
The source of improvement after training the open-source model is not sufficiently disentangled. The performance gain of Qwen3-8B may come from better protocol following, chunking behavior, and tool-use formatting, rather than from a genuine improvement in deciding when to retrieve, when to call subagents, when to stop, and how to aggregate intermediate results.
Our analyses in the paper show that the performance gains come from both better protocol following and also a genuine change in the behavior of the trained model. For example, we cite evidence in Figure 6 in Appendix A, referenced in Observation 6, in which a very noticeable change in behavior is evident in the number of turns, sub-calls, and overall runtime of RLM(Qwen3-8B) after post-training.
For Figure 3(a), where we train a Qwen3-8B model on distilled traces from LongBenchPro, we examined the overall runtime of the trained Qwen3-8B-RLM vs. the base model as an RLM in Figure 6, and we find that the number of turns and the overall latency decrease by an order of magnitude. This suggests more concise decision making and a change in the behavior of the model itself as an RLM, even for tasks it was not trained on.
For Figure 3(b), we show that RL training a Qwen3-8B model on the short tasks in MRCRv2 perfectly generalizes from 0% to 100% reward on the very long version of the task. Merely producing a well-formed, protocol-following trajectory is not sufficient to perfectly generalize to the longer variant of the task. Instead, the plot and the trajectories themselves suggest that the model learned a length-generalizing strategy using the RLM harness.
In other words, our results show a genuine change in the behavior of the model as an RLM on our tasks, beyond just following the format of the harness. We are happy to include additional figures and trajectory-specific analysis such as errors rates to supplement these findings.
We appreciate the reviewer’s time and feedback, and are happy to answer any additional questions or concerns.
Comments on the paper
1 comment
Gentle reminder
Dear reviewers, we appreciate you taking the time to read and review our work. With a little over a day and a half left in the discussion period, we wanted to gently seek your comments on our responses. We put care into addressing each point and hope the clarifications are helpful. We would be very happy to answer any remaining questions. Thank you!
From OpenReview, CC BY 4.0. Authors as signed there; shown unedited.
Loading the discussion…
Rebuttal
We thank the reviewer for taking the time to read our paper and provide feedback, and appreciate you commending the RLM idea as elegant and well-motivated with strong experiments and ablations. We answer your questions below, which will help us improve the clarity of our discussion of RLMs.
We agree that ablating RLM components is important for disentangling performance gain. Table 1 contains several baselines that explicitly ablate full prompt offloading and programmatic sub-calling:
All three baselines show clear gaps in performance and explain how these features help the RLM. CodeAct + subagents struggle on BrowseComp-Plus and OOLONG because of the sparsity of the huge amount of context, but perform well on OOLONG-Pairs compared to methods that do not have sub-agents or use sub-agent tools. Meanwhile, OpenCode / Claude Code with offloading perform well on search, but perform poorly on OOLONG-Pairs, because of their inability to use programmatic sub-agent calling to act over their sub-call outputs as variables. We do not enforce a compute budget, but show in Table 1 the cost of each method on each environment.
We are happy to use some alternative terminology, e.g. to “a new inference strategy”, if the reviewer deems this important for this paper.
We nonetheless appreciate the reviewer’s take on RLMs as an “elegant composition of existing pieces to tackle real-world applications”. We believe that the best ideas in machine learning (from ResNets or the Transformer to CoT reasoning models and ReAct agents) are elegant compositions of existing pieces that advance real-world capabilities, and we aspire to that same standard. Our goal is to show that, with the right novel inference-time scaling axis, even existing models can dramatically improve their ability to process much longer user prompts than originally assumed.
We discuss inference latency results in Observation 4 (page 7) in the main paper, which references the plots in Appendix F. Figures 12 and 13 showed the runtime quartiles (i.e., inference latency) of several baselines and the RLM across the tasks in Table 1. We are happy to move much of this analysis and include more fine-grained inference latency plots to the main paper, if our work is accepted.
We also note in the paper that, because we do not optimize for latency and keep sub-calls sequential, the API cost of the model is generally proportional to the runtime. Figures 14, 15, and 16 reflect how token cost as a proxy for latency scales with context length and task complexity. However, we also note the addition of the
llm_batch()module used in the LongCoT-mini experiments, which parallelizes sub-calls and reduces the overall latency in a way that we expect can be applied in RLMs going forward.When studying Table 1, we cannot see that a pattern that the average API cost doubles when increasing recursion depth. For example, on OOLONG-Pairs RLM(GPT-5) goes from 0.69 USD at depth=0, to ~0.33 USD at depth=1-3. There are a few isolated cases where the cost increases by a sizable amount, but on the whole, depth=3 for example is roughly the same cost or even cheaper than depth=2 on average in our experiments. Even between depth=0 and depth=1, the difference is highly variable.
This is because the RLM dynamically chooses strategies for the task, making it difficult to estimate the effect of increased recursion depth. We include in Figure 16 how the cost of the RLM changes with respect to context length (from Figure 1), and it is roughly a function of both context length and task complexity (e.g. S-NIAH stays roughly constant, OOLONG is linear, and OOLONG-Pairs is quadratic).
This is a great point to help us explain in future revisions that, experimentally, there is no direct connection between a model’s inability to solve a task with its ability to use a harness to solve that task. A model that is stronger at, say, writing code or writing recursive prompts will be a stronger RLM even if its long-context performance is bounded. We view this as a great power of RLMs, which means that making progress on the ability of models to reason and generate recursive code can largely achieve big improvements in long-context processing (via the RLM inference strategy).
To provide intuition and analysis on why GPT-5 performs better as an RLM, we refer to Figure 4(b) and Section 5 as a whole. To summarize, we find that the Qwen3-Coder model makes significantly more mistakes in following the RLM harness constraints, and also often making formatting or syntax errors when using the persistent REPL environment across turns. We also include traces in Appendix F.1 to support and compare how these models solve problems.
We thank the reviewer for taking the time to provide feedback, and we are happy to answer any follow-up or additional questions.
References
[1] Yao et al., "ReAct: Synergizing Reasoning and Acting in Language Models," ICLR 2023, Oct 2022.
[2] Wang et al., "Executable Code Actions Elicit Better LLM Agents", ICML 2024, Feb 2024.