This is a paper from December 2025 that recently had a resurgence due to the improvement of LLMs and the proven successful implementation of sub-agents with Claude Code.

RLM are an agent architecture that overcome LLM context and reasoning limits by giving agents programmatic control over their own context via a REPL.
RLM works over a mutable context and can recursively spawn sub-agents to work on sub-tasks.
An RLM agent has:
- A context object: a mutable structure that can scale to very large contexts
- A recursive agent function: rlm_agent(query, context) → response, which can spawn child agents
- A Python execution environment: enabling search, filtering, and computation over context
The agent alternates between writing code, inspecting results, and delegating work recursively.
RLM with Google's Agent Development Kit (ADK)
ADK adapts RLMs for production by providing low-level control over execution, memory, and orchestration via BaseAgent. Key features:
- Lazy context loading from files instead of massive in-memory prompts
- Parallel recursive delegation for scalable reasoning
- Tool-first reasoning over code before language
- Built-in observability for debugging recursive behavior
ADK preserves the core RLM idea—recursive, compute-over-context agents—while making it practical to deploy at scale.
Sources: Zhang Tweet, RLM with ADK Tweet, paper
Stay Updated
Get the latest AI insights delivered to your inbox. No spam, unsubscribe anytime.
Comments
Sign in as a member to join the conversation.
Loading comments…