Using RECURSIVE LANGUAGE MODELS (RLMs) to extend LLMs context window #4911
reyxv16
started this conversation in
1. Feature requests
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Adding RLM functionality to expand the LLM context window to much higher levels and prevent context degradation with each summary.
I learned about this idea from a video explaining the details of a paper. I think implementing this type of strategy is relatively easy through extensions.
Here's the link to the paper's PDF: https://arxiv.org/pdf/2512.24601
And the summary at the beginning of the paper:
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 strategy 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 successfully handle inputs up to two orders of magnitude beyond model context windows and, even for shorter prompts, dramatically outperform the quality of base LLMs and common long-context scaffolds across four diverse longcontext tasks, while having comparable (or cheaper) cost per query.
Would it be possible to add this type of functionality that allows managing a code variable as a context store, thus maintaining a much larger context without saturating the model's context?
2512.24601v1.pdf
Beta Was this translation helpful? Give feedback.
All reactions