Intro0:00
Hello there, my name is Raymond Weitekamp, and today I'm going to talk about recursive coding agents, which is this idea of applying the lessons of recursive language models, RLMs, to coding agents. This is some work that I have done both in my independent research, um, raw works, and also more recently in my role at OpenProse.
So, to motivate this a little bit: we all want outcomes, we all want agents that are working on our behalf, we want reliable coworkers that are getting things done while we're doing something fun, while we're out on a hike, while we're cold chilling, while we're doing the do.
And my argument, and my experience, is that the bottleneck to this is not intelligence. The models are intelligent enough; they know all kinds of things, they know the entire internet, but they can't reliably deliver outcomes, and so I can't trust them.
So, as a very simple example, you know, one day I get almost a fully working SAS app from a single prompt, granted a long prompt. The next day—and I swear this actually happened—Claude Code empties the entire contents of my Solana wallet.
Oops. Okay. So that doesn't really instill trust. So, at the bottom here we've got this pro- this progression, okay, and we all want to move towards the one on theright, where we're just sort of sitting there meditating and things are manifesting.
And so where does that come from? This is from the AI Engineer code.
It's actually from the back of the T-shirt. AI Engineer code, November 2025, man. I hope—I hope you were there. If you weren't, watch it on YouTube. It was—it was amazing. So here's the thesis. The thesis is: today's agents are mismanaged geniuses.
The intelligence is there, and the missing layer is how do we specify and manage and reuse and verify the work. So this framing, this phrase, the mismanaged genius, comes from Alex Zhang, Zed Li, and Omar Kattab at MIT.
And Alex and Omar are part of the authors of the original Recursive Language Models paper. I've also talked a little bit about this recently on Turning Post. I forgot to mention that these slides are actually a website, recursivecodingagents.com, so you can click on them by going to this website.
RLMs2:40
So everything I'm going to show in here is interactive. Okay. What are recursive language models? So I like to say that in an RLM, the context itself is the object of computation. And this is essentially a marriage of tool calling and reasoning.
We're going to talk a lot more about that in the next slide. But the idea is that the full prompt is not a simple user query. The full prompt is a variable. The full prompt could be a file, or many files.
And we have this read-evaluate-print-loop repel that the agent is interacting with. In the original paper, that's Python. And the RLM is instructed to operate symbolically on that prompt. So don't just read the whole thing into your context window.
Explore it symbolically. And even more, you don't even directly explore it symbolically, or maybe you do a little bit of poking around, but have other LLMs, and I guess other RLMs if you allow the recursion depth to be greater than 1, have these other recursive sub-agents.
And again, we'll get a little bit into the weeds of the lingo. Sub-RLMs, sub-LLMs, do this symbolic manipulation to pick apart the answer and then work our way back up to a final answer. So it looks something like this in this tree below.
So my take here is that RLMs are the new reasoning models. And I see this as the next paradigm of test-time compute, inference-time compute, whatever you want to call it. And why does it seem obvious, or maybe like, hey, why is this even a thing?
I think it's very elegant. Because it's a very elegant marriage of two things: reasoning and code execution. So the code execution is reasoning. And so instead of we had long, we had chain-of-thought as a prompting strategy that evolved into reasoning models that explicitly express the chain-of-thought as their reasoning tokens, we already had function calling, tool calling, parallel tool calling.
And RLMs really put that together in a way that gets amazing results. So three very simple examples. One from the original paper, Oolong: the RLMs can process information that is many orders of magnitude larger than their context window, tens of millions of tokens.
What I showed in my own independent work was that the default RLM harness is itself a really powerful memory system. So RLM with no modifications is essentially like a top-10 memory system. Like, you know, up there with all the people custom-making memory systems, and there's probably billions of dollars going into that.
And with a little bit of modification, you can get really amazing results using it as memory. I was also able to show state-of-the-art results where the RLM framework, and specifically the DSPY implementation of it, was able to get state-of-the-art results on long reasoning tasks.
Now, there's this new benchmark, LongCOT. I won't go into the details in depth, but the idea of this benchmark was that the problems are hard specifically because they require so many steps of reasoning in the, like, analysis sequence or the chain-of-thought, that most reasoning models, including the top ones, can't hold the thread for long enough.
If you allow the RLM to solve the problem using a combination of code and recursive calls to sub-agents, then a very small model, Qwen 3.5 9B, you could run this on a laptop, can actually beat. So Qwen 3.5 9B as an RLM can beat Opus
and GPT-5.4, all the top frontier models, as LLMs on these long reasoning tasks. So they're extremely, extremely powerful. So powerful that they are arguably too hot to benchmark. So two examples here. On the left, a very high-profile case where the Symbolika team has this RLM agent harness called Agentica, within hours of ARC AGI-3 being released, where the top scores of all the frontier models were around 2 or 3 percent.
The Symbolika team showed 30-something percent. This is crazy. They blew it out of the water within hours using RLMs as a framework. So much so that it very much upset the ARC Prize team, and so they gave them what I'm interpreting as a consolation tweet, which, as far as I'm reading the situation, was essentially saying, you know, la-di-da, congratulations, but you didn't solve the problem theright way, and we don't like RLM harnesses, and so you can have this nice tweet, but we refuse to actually do the full private part of the ARC AGI evaluation, which to me is just insane.
In my own work and on the LongCOT benchmark, my results, as well as Alex from MIT, the RLM first author, encouraged, let's say, the leaderboard maintainers to actually make, like, a separate open harness leaderboard so that the results of the RLMs could be showcased without contaminating the original intent of the leaderboard, which was basically no tool calling is allowed.
So my take on this is I don't care. I don't care whether it's latent space or reasoning tokens or code execution. I want results. And I want AI programs that get those results. Okay. So this can feel close to a lot of other things, and I built a little rubric.
RLM Rubric9:14
There's a companion GitHub repo for this that you can go through if you want to see. And so what do we need to be an RLM? We have an executable environment. The prompt is externalized. There's code that's actually the thing calling the model.
The model is able to pick the decomposition of the problem into the sub-calls or sub-agents. And the state itself is staying symbolic,right? So obviously plain LLMs and RAG and things like that don't meet those. Coding agents and sub-agents and loops, they get close, but they're not quite there.
And again, this rubric here is not to, like, start fights or nitpick. It's just trying to explain, like, what's the essence of RLM and recursive coding agents. Another example that's close but no cigar would be hard-coded map resumes.
And I would put this project called Lambda RLM in that category, which is essentially a way of saying, okay, I'm going to decompose the problem using Lambda calculus into a map reduce, and then there are, like, LLM calls in that executing the map reduce.
But the LLM is not deciding, or the RLM is not deciding, how to decompose the problem. And that I see as, like, a key element of this that makes it very agent-native, you might say. Okay. So now RLMs, what about recursive coding agents?
Recursive Coders10:36
Okay. It looks the same to me. We just swap RLMs and LLMs for agents and sub-agents, and don't we have the same thing? And yeah, you do. And I think that you could take this perspective of, ha-ha, trick question, like, RLM is a coding agent and it's already recursive, so wah-di-da.
And that's fine, and I don't think that argument is wrong, but it doesn't really move anything forward. And so what I'm interested in is this question of how can we apply the principles of RLMs to coding agents and make them actually useful for coding agents.
And I've been very obsessed with this problem since the October RLM blog post came out in 2025. Okay. So I'll show some of my experiments on recursive coding agents. The first one was simply wrapping Alex's RLM package as a CLI.
So the idea was, I just want to give my coding agent an RLM as a tool call. So let's say we need to go sift through 100 million token corpus. Well, now it just uses that tool, and then the RLM does the RLM thing.
So that's interesting, and it can be very useful. And a few other people have built things like that. But then I thought, well, what would it really mean? What would be possible, or how could it be possible, to make the coding agent fully recursive?
So the coding agent harness, like, calls itself, like, the exact version of itself. And how might you implement that? And that is what I called YPI. Y stands for the Lambda calculus Y combinator. And Pi, in case you haven't heard of it, is a really awesome coding agent.
Implementations12:12
It's incredibly minimal, and it's specifically designed to be extensible. So Mario wants you to write extensions for Pi for new features that you would like, rather than trying to stuff your ideas into the main agent. So it's meant to mean a very minimal core that you extend however you like.
And when I originally had the recursive coding agent idea and wanted to do it with Pi, I was not able to use Pi extensions to achieve this goal.
And so I had to fork it instead. I'm very excited to report that in anticipation of this talk, I revisited this, and now Pi has evolved, and the Pi extensions have evolved such that you can make it fully recursive with a pure extension.
So I have both the pure recursive extension, Pi recursive package, as well as the YPI wrapper that is like a convenience wrapper for this. So this is very, quite literally, a recursive coding agent in the sense that Pi calls Pi, calls Pi, calls Pi.
You can set the depth however you want.
And now I want to show a few other notable projects in this space. So obviously there's the original implementation from Alex RLM. DSPY.RLM is my go-to when I'm especially doing benchmarking. That's how I got all these amazing results on some of these benchmarks.
AX, I think, is a very interesting one because it's incredibly agent-native. So the AX started out as a TypeScript variation on DSPY. When RLMs came out, they obviously implemented it. But they did it in this way that enables an AX agent to, like, write a whole TypeScript interface to another AX agent and go all the way down the recursive rabbit hole, which I think is really cool and very interesting.
Just to showcase that this, like, repl could be anything. There's an example from Dan at OpenProse who made the Unix RLM. This is pure bash, and the environment is just the Linux file system. So that's a whole nother angle of thinking about what's possible with RLM.
And then lastly, and we'll talk more about OpenProse, but OpenProse as a language actually enables you to convert any coding agent into an RLM. And I'll talk a little bit more about how to do that towards the end of the talk.
And then the OpenProse repo also contains a harness that executes. It's a coding agent harness that will let you use Codex SDK or Claude Code underneath and do an RLM-style execution of these PROS programs. So is Claude Code an RLM?
Claude Code RLM?15:32
This is, like, the question that keeps getting asked. And the original answer on the release day of the blog post was, no, no, no, it's not. But it was literally the first question that was asked, or, like, asked on the very same day to the launch tweet.
It's basically saying, hey, this is Claude Code sub-agents,right? Go back to my rubric if you want to, like, dig into some of the nitty-gritty details. But arguably, now it is. So over here on theright, we can see Omar saying, hey, congratulations, Anthropic.
Claude Code is finally an RLM now that you have Dynamic Workflows. So what changed? And I think this is an interesting way of explaining what's powerful about recursive coding agents and what RLMs even are by using this example.
So Dynamic Workflows were released just a few weeks ago, and they make Claude Code recursive, or capable of doing these recursive workflows. I would highly encourage you to read this blog post called "A Harness for Every Task." It shows six different workflow patterns that are very powerful.
Obviously, there's many more that you can achieve. And just to show it, I wrote two workflows for Claude Code, one that is explicitly not an RLM, so that's, like, a hard-coded map reduce workflow, and one that I'm arguing is, that is, you could kind of think of it as, like, deep research over a file system.
So, you know, pick a handle, assign that to an agent, have it go do some analysis, bring back what it finds, et cetera. Again, these are in the companion repo.
And then now to OpenProse. So Dynamic Workflows are cool. They're only in Claude Code. They're also not the only way to do this. So what if you don't like Claude Code? Or what if you do like Claude Code, but you don't want to use Dynamic Workflows?
OpenProse17:30
You want something else. So this is what OpenProse is all about. So OpenProse is technically a programming language, but it is not compiled by your computer. It's compiled by your coding agent. And it's a markdown spec. It's logical English.
You don't need to learn any kind of crazy syntax. And there's actually a command, PROSEWRITE, that will get Claude Code or Codex or your favorite or Pi or your favorite coding agent to write a .PROSE.md file for you.
So in that way, it's similar to the Claude Code Ultra Code command where, like, decide and write the workflows for you. And
the PROSE has the ability to turn any agent that's got a file system and sub-agents into an RLM. So this is an open-source repo. You can check it out. And I've also written a little bit more in-depth about this for Turing Post in this article.
And the key thing that I want to bring up with regards to the RLMs is that OpenProse can explicitly declare the sub-agent work. So again, I've made two kind of demo PROSE.md files that are in this companion repo if you want to dig into the code.
I'm not going to do that here in the slides. Where you can break a problem up into smaller pieces that are assigned to sub-agents, verify the work of those sub-agents in the parent agent session. And what's even cooler is you can actually, in OpenProse, two of the features that I added to the language are that you can add skills and tools as explicit dependencies.
So you can imagine a workflow where a certain sub-agent needs a very specific skill to do its role in the workflow, or must have access to a certain CLI tool, for example, or it can't run and do its job.
And so there's a way in PROSE to actually wire those in as dependencies to ensure that not only that the way the work is done is what you want, but actually that the sub-agents are specifically configured with the tools and skills that they need to successfully do the work that you are declaring in the PROSE contract.
Okay. Super cool. What can you actually do? So I've got two examples from Claude Dynamic Workflows, two examples from OpenProse, repo scale migrations. This was kind of the launch post example. Refactor, like, a huge thing, all with a big swarm in parallel, and then merge the whole thing together.
Use Cases19:56
That's super cool. This idea of, like, go after a directory and then deep research or deep analyze or deep process in some way recursively inside that is another example I have here. You can do audits, bug sweeps. You can do adversarial things such as having a skeptical agent or, you know, a red team
set of agents that are going to try to improve the system adversarially or in parallel. And then one really cool thing that you can do with OpenProse that I just added recently is kind of goes back to my very first slide,right?
So, like, one day I get this amazing result. The next day, like, they trade away all my cryptocurrency, which is very small, thankfully. But, like, how do we get these things to be more reliable? And how do we get them, you know, we have, like, a golden session, or we have a great day, and now we want to capture that and reuse it over and over again.
So I built a system where you can take a golden session for Claude Code, Codex, Pi, whatever you want. And it's a PROSE program that will actually have the agent deconstruct that session and turn it into a reusable PROSE workflow that, again, can involve this idea of recursive coding agents to get you to a reliable way of getting to that golden state of performance over and over and over again.
Recursive coding agents for the win. I really think this is very powerful. RLMs just kind of blew my mind when they first came out. And again, as you can probably see through this talk, I've been absolutely obsessed with applying the ideas of RLMs to coding agents.
Conclusion21:51
The three things that I hope you'll take away from this is, one, like, trust is reliability. Like, how can we trust something that isn't reliable? And again, my argument and this idea of the mismanaged genius is that the next step is not more raw intelligence.
It's actually behavioral. It's actually orchestration. I personally believe that RLMs represent this new paradigm of test-time compute, inference-time compute, where tool calling and reasoning are unified. And we reason through tool calling, and we can recursively iterate. And one of those tools is to call another agent to go do it on some other specific task or subset of the problem.
And then also, I hope we settle a little bit of this drama around, like, wait, like, are RLMs actually new? Aren't they just coding agents? Yes, coding agents can be RLMs. They aren't automatically RLMs. And so I've showed a couple of different Claude Code Dynamic Workflows that can turn Claude Code into an RLM, as well as some ways of doing this with OpenProse that you can use with any coding agent.
So I see this as an incredibly powerful way of working with coding agents. I hope you will dig in more to recursivecodingagents.com. But with great power comes great responsibility. So until next time, please recurse responsibly. Thank you very much.





