potentialpaper

Self-Programmed Execution for Language-Model Agents

Luke Jen O'Connor

NeurIPS 2026

Edit this page

Or clone it with git

Run in a terminal:

Needs Git LFS. To push, use an API key from your profile as the password.

Or let your agent set it up

It checks and sets up everything: signing in, git, the clone, credentials and an SSH key.

TL;DR. An LM can act as an agent with no external agent loop by writing a program which the harness simply evaluates.

Abstract. At the heart of a language model agent is an orchestrator program which is responsible for the state transition between consecutive turns. In existing systems, this program is implemented in the harness. This paper introduces self-programmed execution (SPE), in which the model completion is itself the orchestrator program, and the harness evaluates this program but does not impose any fixed orchestration policy. Formally, an SPE state of an agentic machine is one from which a model completion can load any successor state up to an embedding, and an instance of an SPE state is one which executes the model completion as a program. In practice, the program requires a language with unusual features, as its source code doubles as the content of the model's context window. I therefore introduce Spell, a Lisp dialect in which programs can edit and re-evaluate themselves, and effectful expressions like model invocations are structured such that re-evaluating an edited program does not replay its side effects. Experiments with existing models, not trained for SPE or Spell, show that frontier models can learn Spell in-context and accomplish challenging agentic tasks. These results demonstrate how an LM can act as an agent without any fixed orchestration policy, and they raise the question of what self-orchestration strategies might be learned by a model trained for self-programmed execution. Code is available at https://github.com/lukejoconnor/spell.

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 paper
How does this paper connect to your work? Write how you built on it, compared with it or reproduced it, or add a summary, a critique or errata.
Or make it interactive:
Start writing

edit · history

DateVersionSubmitted toPDFEvidence
4 May 2026NeurIPS 2026submittedNeurIPS 2026Accept (oral)reviews ↓[1]—[1]
Missing a version?

NeurIPS 2026

Accept (oral) · 3 reviews · OpenReview

Updated 25 Nov 2026, 03:42 UTC.

Program Chairs · DecisionOpenReview ↗
Decision
Accept (oral)
Read decision
Meta-review

This work proposes self-programmed execution (SPE), a novel agent architecture that abandons the fixed orchestrator program adopted by conventional language model agents, enabling the language model’s own completion to serve as the orchestrator for state transition and task execution.

All reviewers have provided positive scores of 5 for this paper, fully recognizing the originality, technical rationality and experimental value of this work. The authors are suggested to fully integrate the key discussions and revised contents in the rebuttal stage into the final camera-ready version to further polish and improve the paper’s completeness and presentation quality.

Overall, this paper delivers a innovative and solid contribution to language model agent architecture research. I recommend accepting this paper for oral presentation.

Final justification

The paper receives positive scores (5, 5, 5) from all reviewers. Through rebuttal and post-discussion clarification, the concerns are fully resolved. The work is technically solid, conceptually novel, and brings valuable new insights to LM agent research. I endorse the acceptance of this paper for oral presentation, with all rebuttal revisions to be incorporated into the camera-ready version.

Area Chair Bvtp · Meta-reviewOpenReview ↗
Read meta-review
Meta-review

This work proposes self-programmed execution (SPE), a novel agent architecture that abandons the fixed orchestrator program adopted by conventional language model agents, enabling the language model’s own completion to serve as the orchestrator for state transition and task execution.

All reviewers have provided positive scores of 5 for this paper, fully recognizing the originality, technical rationality and experimental value of this work. The authors are suggested to fully integrate the key discussions and revised contents in the rebuttal stage into the final camera-ready version to further polish and improve the paper’s completeness and presentation quality.

Overall, this paper delivers a innovative and solid contribution to language model agent architecture research. I recommend accepting this paper for oral presentation.

Final justification

The paper receives positive scores (5, 5, 5) from all reviewers. Through rebuttal and post-discussion clarification, the concerns are fully resolved. The work is technically solid, conceptually novel, and brings valuable new insights to LM agent research. I endorse the acceptance of this paper for oral presentation, with all rebuttal revisions to be incorporated into the camera-ready version.

1 comment
Authors · CommentOpenReview ↗

Thank you very much to the AC and reviewers for the positive assessment. I was especially gratified by the reviewers' assessment of the paper's novelty and significance. I have addressed the reviewers' questions and concerns below.

Reviewer x1PhOpenReview ↗
Rating
5/6
Confidence
3/5
Quality
3/4
Clarity
3/4
Significance
4/4
Originality
4/4
Contribution type
general
Ethical concerns
NO or VERY MINOR ethics concerns only
Read review
Summary

The paper observes that LM agents increasingly depend on engineered harnesses for context management, tool use, and turn-to-turn orchestration. It proposes self-programmed execution (SPE), in which the model’s own completion is executed as the orchestration program, rather than relying on a fixed agent loop. To make this feasible, the paper introduces Spell, a Lisp-like harness language designed for self-editing programs. Spell uses self-reference, quoted trailing expressions, and fresh local environments to let agents preserve/edit context, avoid replaying old effects, and safely make recursive self-calls. Experiments show that strong models, especially GPT-5.4, can use Spell correctly with few fatal language errors. Spell shows cost-effectiveness on Terminal Bench v1.1 and SWE-lite, but cannot best Codex CLI. However, Spell also shows ineffectiveness on LongBench and AppWorld benchmarks.

Strengths and weaknesses

Strengths

  1. The paper proposes an interesting shift from fixed harness orchestration to model-written orchestration via self-programmed execution. The formalization of SPE and the design of Spell make the idea concrete rather than just conceptual.
  2. The motivation and main design challenges are explained clearly. The discussion of why self-reference, replay-safe effects, and fresh local environments are needed is especially helpful. The appendices provide substantial implementation and experimental detail.

Weaknesses

  1. The evaluation is mainly based on existing coding/agent benchmarks. Since the paper’s key claim concerns orchestration, stronger evidence on subagent calling, async/concurrent execution, and nontrivial self-orchestration would better support the contribution.
  2. Figures 2 and 4 do not show error bars or confidence intervals. Figure 2 is based on only 32-task subsets, so uncertainty is important. Figure 4 reports significance markers, but the plots still do not communicate variance or confidence intervals.
  3. The comparison with Codex CLI is useful, but potentially confounded by differences in prompting, harness maturity, and model post-training alignment. Spell appears more cost-efficient in several settings, but it does not clearly outperform Codex CLI in coding accuracy.
Questions
  1. How were the 32 Terminal-Bench and SWE-bench Lite tasks in Figure 2 selected? Were they random, stratified, or chosen by some other criterion?
  2. In Figure 4, are all tasks from each benchmark evaluated? For LongBench v2, how was the 200-item subset chosen?
  3. What is the performance of an open-source or simpler traditional harness using GPT-5.4 under the same model and budget settings?
  4. Can Spell be mixed with a traditional harness, e.g., using Spell only for context management or tool batching while retaining an outer agent loop? Or is SPE intended to be an exclusive replacement for fixed harness orchestration?
  5. How much of Spell’s performance comes from the language design itself versus the large system prompt and coding reminder?
Limitations

Yes

Final justification

The work examines the new design choices for the harness and shows that SPELL can be a cost-effective solution. The proposed SPELL may affect future LLM training paradigms. Although the author shares their identity in the checklist, this will not change my assessment. I will keep my score of 5.

Formatting concerns
  1. The paper's outlook does not look like a formal NeurIPS paper.
  2. The author shares their identity in the checklist Open access to data and code with the GitHub link. This may break the anonymity rules.
3 comments
Authors · RebuttalOpenReview ↗
Rebuttal

Thank you to the reviewer for the positive assessment and detailed comments. I respond below and would sincerely appreciate further comment on whether the reviewer's concerns are mitigated.

W1: The evaluation is mainly based on existing coding/agent benchmarks. Since the paper’s key claim concerns orchestration, stronger evidence on subagent calling, asynchronous/concurrent execution, and nontrivial self-orchestration would better support the contribution.

I agree that this is a weakness. The submitted manuscript presents different types of evidence for the three items listed:

  • Subagent calling: Observation 3 ("orchestration games") shows that this is within model capabilities, but Observation 2 (feature utilization) shows that it is not within their normal behavioral range.
  • Asynchronous subagent execution: this was a gap (see below)
  • Nontrivial self-orchestration: for the way that the manuscript defines orchestration ("multi-turn, not only multi-agent"), this is used frequently (Observation 2 and Appendix C.7).

To address the gap related to asynchronous execution, I added a variation on the orchestration games of Observation 3 in which the model delegates subagents asynchronously. GPT-5.4 performed poorly on this variant, completing valid asynchronous orchestration in only 9/24 trials. However, GPT-5.6 Sol (medium effort) completed valid orchestration in 22/24 trials. These results expand the set of Spell features and orchestration policies that are currently within model capabilities, yet outside of their normal behavioral range. In my revision, I add these results to Observation 3 and to Appendix C.2.1.

W2: Figures 2 and 4 do not show error bars or confidence intervals. Figure 2 is based on only 32-task subsets, so uncertainty is important. Figure 4 reports significance markers, but the plots still do not communicate variance or confidence intervals.

In the revision, I add confidence intervals to Figures 2 and 4.

W3: The comparison with Codex CLI is useful, but potentially confounded by differences in prompting, harness maturity, and model post-training alignment. Spell appears more cost-efficient in several settings, but it does not clearly outperform Codex CLI in coding accuracy.

The way I would describe this limitation is that the experiments address a question about current performance but not a question about future performance.

The factors listed, particularly harness maturity and post-training alignment, favor Codex rather than Spell (regarding prompting, see Q5 below). However, these biases do reflect reality, particularly the way frontier models are actually trained, and the considerable engineering effort that has been devoted to traditional harnesses. There is no ideal world in which these factors are equitable.

More generally, this comment gestures in the same direction as comments W1/Q1 from Reviewer yEyV and W1 from Reviewer iZzx, both of whom wondered about the future potential of SPE and Spell. Indeed, the benchmarks presented do not show how SPE agents will perform in the future, particularly after post-training. I give extended thoughts on this question and quote a new Discussion paragraph in my responses to those comments.

In my revision, I edit the text describing these results to acknowledge the factors highlighted:

A limitation of these comparisons is that the comparators differ along axes besides the use of SPE or the core semantics of Spell: Codex CLI is a mature harness likely aligned with GPT-5.4's post-training, whereas Spell is a new implementation of an unfamiliar architecture. Prompts also differ (Appendix B.12.1). Because of these differences, these results do not necessarily predict the future performance of agents using Spell (Section 6).

Q1: How were the 32 Terminal-Bench and SWE-bench Lite tasks in Figure 2 selected? Were they random, stratified, or chosen by some other criterion?

In the submitted manuscript, these were the first 32 tasks after sorting by task identifier. This was undesirable for SWE-bench Lite because repository name is part of the identifier, so the subset included just 2/11 repositories. In the revision, I re-ran this analysis with a random subset. Other changes: I added GPT-5.6 Sol, which is used in the orchestration games above; I replaced Qwen-3.6-Plus with Qwen-3.7-Plus for availability reasons; and I added Fable 5 to the Appendix but excluded it from the main figure due to cyber refusals. Updated results were qualitatively similar to the submitted results, except that Qwen-3.7-Plus performed substantially better than Qwen-3.6-Plus:

Model Terminal-Bench resolved, original → rerun SWE-bench Lite resolved, original → rerun
GPT-5.4 16 → 17 23 → 16
Opus 4.6 15 → 12 15 → 16
GLM-5.1 10 → 12 14 → 12
Kimi-K2.6 12 → 12 14 → 12
Qwen-3.6/7-Plus 4 → 13 0 → 5
GPT-5.6 Sol — → 17 — → 17
Fable 5* — → 13 — → 18

Q2: In Figure 4, are all tasks from each benchmark evaluated? For LongBench v2, how was the 200-item subset chosen?

Figure 4 uses all 80 Terminal-Bench 1.1 core tasks, all 300 SWE-bench Lite tasks, and all 57 tasks in the AppWorld development split. LongBench v2 contains 503 items; I evaluated the first 200 records in the benchmark dataset's published order. No items were excluded based on errors or outcomes. In my revision, I state how subsets are chosen in Appendix C.3.

Q3: What is the performance of an open-source or simpler traditional harness using GPT-5.4 under the same model and budget settings?

I evaluated mini-swe-agent [Yang et al., 2024], a strong academic open-source harness, with GPT-5.4 at medium effort on Terminal-Bench and SWE-bench Lite. (Codex CLI itself is also open source.) Compared with Codex CLI, the most important difference is that this harness has only one tool, bash. Its task template prescribes a workflow that could be viewed as benchmark-driven (“Create a script to reproduce the issue...”). Versus Spell, this harness had higher performance on Terminal-Bench at slightly higher cost and slightly lower performance on SWE-bench Lite at slightly lower cost:

Benchmark Spell mini-swe-agent Codex CLI Paired p, mini vs. Spell
Terminal-Bench 1.1 36/80 (45.0%); $25.72 44/80 (55.0%); $30.71 39/80 (48.8%); $46.96 0.0215
SWE-bench Lite 171/300 (57.0%); $102.12 168/300 (56.0%); $86.57 172/300 (57.3%); $161.82 0.711

This result follows the same pattern as the Codex CLI comparison: at matched effort, Spell trades some Terminal-Bench accuracy for lower cost, while performing on par on SWE-bench Lite. In my revision, I add the following sentences to the Observation 4 text:

I additionally evaluated mini-swe-agent, a strong academic open-source harness, with GPT-5.4 at medium effort (Appendix C.5.3). On Terminal-Bench, mini-swe-agent had significantly higher performance than Spell at slightly higher cost (44/80 versus 36/80; $30.71 versus $25.72). On SWE-bench Lite, it had slightly lower performance at slightly lower cost (168/300 versus 171/300; $86.57 versus $102.12).

Q4: Can Spell be mixed with a traditional harness, e.g. using Spell only for context management or tool batching while retaining an outer agent loop? Or is SPE intended to be an exclusive replacement for fixed harness orchestration?

Yes: a Spell run is initialized by running an initial program, and normally, this program includes just a prompt and a self-call. However, this could be any user-specified Spell program, even an implementation of the traditional agent loop. In my revision, I highlight this functionality more prominently:

First, the LM's first turn is produced by evaluating an initial program, which defaults to a prompt and a self-call. By customizing this program, a user may embed a Spell agent within a user-specified orchestrator program; for example, this program could compose an ordinary self-call with deterministic logic that runs tests or invokes a review agent, or even implement a traditional agent loop.

Q5: How much of Spell’s performance comes from the language design itself versus the large system prompt and coding reminder?

The optional coding-reminder prompt was not injected in the main experiments (Figures 2--4). It was available for the model to read, but inspection of traces shows that the model never did so; my revision states this in Appendix B.11.2.

More generally, for the Spell system prompt, the experiments are not able to separately evaluate language semantics versus a prompting effect. The challenge is that this prompt teaches the model to use Spell; for this reason, the manuscript describes it as "an important part of the language". Appendix B.11 describes these prompts in detail, and Appendix B.12.1 compares them with the prompts of Codex CLI and Claude Code. One aspect of the system prompt which was under-emphasized is that it strongly encourages the use of Spell's context management features. In my revision, I add the following sentence within Observation 2:

This behavior was explicitly encouraged by the Spell system prompt, which describes not only how to invoke context-management features but when to use them; prior work on context management found that a prescriptive prompt outperformed a descriptive one [Li et al., 2025].

Formatting: “The paper's outlook does not look like a formal NeurIPS paper.”

Thank you; my submission unintentionally overwrote the template's Times typeface. My revision corrects this, and doing so does not increase the page count.

Anonymity: “The author shares their identity in the checklist Open access to data and code with the GitHub link. This may break the anonymity rules.”

I apologize for this error and will remove the GitHub link in my revision.

Reviewer x1Ph · CommentOpenReview ↗

Response to rebuttal

Thanks for your hard work on the rebuttal. It is surprising that GPT-5.6-sol performs well in asynchronous execution. Overall, it is a good paper. I will keep my score of 5.

Authors · CommentOpenReview ↗

Thank you for your time and your positive assessment!

Reviewer iZzxOpenReview ↗
Rating
5/6
Confidence
4/5
Quality
3/4
Clarity
4/4
Significance
4/4
Originality
4/4
Contribution type
general
Ethical concerns
NO or VERY MINOR ethics concerns only
Read review
Summary

This original paper proposes to orchestrate agents in an harness-free setting: instead of having a pre-defined state machine that decides what the next step is, allow the model to freely code its own harness. This goes against current (short-term?) tendency which create all kind of discussions on harness vs model capabilities, and where gains in one or the other are often hidden or co-founded with changes in the other.

The paper introduces a formal notation for this, and proposes an implementation that can be instantiated with various models.

Perhaps surprisingly for a first attempt, the results are extremely promising. Evaluations on agentic code-benchmarks point to competitive results. But more interesting, it allows for insights like the (in)capacity of spawning sub-agents or different context management strategies.

Strengths and weaknesses

As said before, there is much to like in this paper due to the originality and potential impact it has.

Feasibility-wise - as is often for new ideas - there are obviously questions if this automatic harness creation is indeed more powerful than human-inspired ones. In particular, the lack of sub-agent spawning seems intriguing and raises the question of what it would require.

[Update July 30th]: as pointed out by the PCs, my contribution type assessment (Concept & Feasibility) differed from the one proposed by the authors (General). The requirements for General are higher wrt relationship to previous work and citations - something that is present in this paper, but relegated to the Appendix. As I still believe that this is rather a Concept paper, I consider a related work section in the Appendix as fine. From an experimental point-of-view, the paper seems to clear the bar for a General submission, although in that case it is not necessarily a strong point. It remains high in Significance

Questions

Some harnesses are "better" than others, because they leverage more inference-time compute by - for instance making - the model more stubborn. Are there specific strategies which emerge here, and how do they differ across models?

Limitations

yes

Final justification

I am confident that this paper has the potential of adding to a change on how the discussion models-vs-harness is framed, and that it points to a future were models create their own harness on-the-fly

Formatting concerns

na

1 comment
Authors · RebuttalOpenReview ↗
Rebuttal

Thank you very much to the reviewer for the very thoughtful summary and positive comments. I would welcome further feedback, especially about the inclusion of forward-looking speculation.

W1: Feasibility-wise—as is often true for new ideas—there are questions about whether automatic harness creation is indeed more powerful than human-inspired harnesses. In particular, the lack of subagent spawning is intriguing and raises the question of what would be required for it to emerge.

I agree with the reviewer that this is an important limitation. A similar concern was raised by Reviewer yEyV (W1/Q1). I'll offer some predictions and articulate some reasons for optimism. I would appreciate further feedback on what the reviewer finds convincing or at least appealing.

One prediction is that a SPE-native model should have better token and cost efficiency on long-horizon tasks, where context tends to accumulate and become stale. Already, Spell agents expend far fewer input tokens than Codex CLI by pruning context across turns (Appendix C.7), at some cost in accuracy. A model post-trained for SPE should improve this tradeoff by learning to decide what context is stale.

What further strategies might be learned? First, the model might learn to manipulate its chain of thought, which is normally append-only. It might reset recent reasoning branches to avoid anchoring while brainstorming, compact a completed reasoning branch into its conclusion, or edit out an earlier reasoning error. Second, because context eviction makes exploration cheap, it might learn to read broadly—beyond what is clearly needed—and retain only what proves relevant. Third, it might learn to decompose tasks and context in a fine-grained, hierarchical manner, delegating subtasks to subagents so that context length scales with subtask size rather than with the full trajectory.

This is speculation, but three pieces of evidence make me generally optimistic:

  1. The amount of human activity suggests that domain-specific harness engineering (similarly "context engineering" and "loop engineering") does affect performance in ways that practitioners care about. A few examples are PR-triggered code review, goal-oriented loops, and research-plan-implement pipelines. These workflows mostly remix a handful of building blocks in a manner that seems amenable to reinforcement-learned heuristics.
  2. Precedent exists that models can be post-trained for self-orchestration, leading to improvements in benchmark performance (ll. 387–392). This applies to both subagent orchestration and context management. Kimi-K2.6 was trained to use parallel subagents via an RL approach that seems generalizable: initially, spike the reward signal with a term which encourages the use of subagent features; gradually, downweight this term such that the model learns to employ these features only when beneficial.
  3. When given a task that requires multi-agent self-orchestration, GPT-5.4 is capable of implementing such programs, indicating that the gap is one of behavior rather than capability (Observation 3). In my revision, I extend this analysis to include asynchronous multi-agent orchestration (see below). In general, post-training is expected to be effective at eliciting behaviors that are already within the capabilities of a base model.

In the submitted manuscript, these arguments were scattered about. In the revision, I expand the final Discussion paragraph to bring them together:

The tendency of current agents to implement mostly simple Spell programs could change if an LM were trained to use Spell natively. Production systems increasingly rely on domain-specific harnesses that manage context and trigger certain orchestration motifs deterministically [Horthy, 2025]; practitioners describe this work as “context engineering” and “harness engineering” [Anthropic Applied AI Team, 2025, Lopopolo, 2026]. For frontier models, it is already within their capability to implement common self-orchestration motifs in Spell (Observation 3), and post-training may elicit such behaviors more reliably. Prior work provides supportive precedent, reporting gains from systems specialized for subagent orchestration, including Conductor and Kimi K2.6 [Nielsen et al., 2026, Kimi Team (Moonshot AI), 2026], and from post-training for context management, as in FoldGRPO [Sun et al., 2025]. It remains unclear how far this would scale: would long-running tasks accumulate increasing benefit over time? Would a strong Spell-native model actually discover optimal strategies during training? Would this end-to-end approach outperform self-evolving agent architectures? Despite these uncertainties, there is precedent for end-to-end learning to outscale human effort [Sutton, 2019]; Spell-native training may provide the means by which to scale orchestration with computation.

Regarding subagent spawning in particular, I performed a relevant analysis in response to Reviewer x1Ph's W1. I repeated the "orchestration games" of Observation 3 in a variant where the agent uses asynchronous agent spawning instead of synchronous self-calling; GPT-5.4 completed valid asynchronous orchestration in only 9/24 trials, but GPT-5.6 Sol did so in 22/24 trials. This analysis expands the set of Spell orchestration strategies which are observed to be within model capabilities yet outside their normal behavioral range.

Q1: Some harnesses are “better” than others because they leverage more inference-time compute by, for instance, making the model more stubborn. Are there specific strategies which emerge here, and how do they differ across models?

Spell agents do use specific strategies that affect token and cost efficiency, to an extent that varies strongly with reasoning effort. The first is context pruning: this is used frequently enough to have a substantial effect on input token count (Observation 2 and Appendix C.7). The second is programmatic tool calling, which reduces turn count (Observation 2 and Appendix C.8). Something I didn't remark upon originally is that this behavior scales with reasoning effort: at high effort, GPT-5.4 uses more output reasoning tokens but also many fewer input tokens, such that total token count actually decreases (by 34% on SWE-bench Lite and 36% on Terminal-Bench, high vs. low effort). The same is not observed with Codex CLI, whose total token count increases with effort (+65% on SWE-bench Lite, +137% on Terminal-Bench). In my revision, I add reasoning-token statistics to Appendix C.7 and state in Observation 2 the effort-scaling of these strategies:

These behaviors intensified with reasoning effort: at high versus low effort, the model used more output tokens but also much fewer input tokens, such that total token count actually decreased by about one third (total cost still increased); the same was not observed for Codex CLI (Appendix C.7).

Regarding differences between models, GPT-5.4 and Opus 4.6 did differ, including in behavior that could be called "stubbornness". Opus 4.6 used much more turns per task compared with GPT-5.4, and the difference was mostly driven by failures. On SWE-bench Lite, successful GPT-5.4 runs (medium effort) averaged 7.1 turns and failed runs 10.4 turns, whereas successful Opus 4.6 runs (medium effort) averaged 10.1 turns and failed runs 26.9 turns. On Terminal-Bench, the corresponding averages were 7.1 and 7.9 turns for GPT-5.4, 8.6 and 15.3 turns for Opus 4.6. In my revision, I add this observation to the Appendix (C.4, "Comparison between models").

I did try two interventions which affected compute utilization. First, in Appendix C.5, I report a coding-prompt intervention that prescribed an iterative research/plan/implement/verify workflow. At medium effort, this improved accuracy from 36/80 to 40/80 while increasing total tokens from 6.96M to 10.21M; at high effort, it improved accuracy from 40/80 to 43/80 with unchanged token use (6.52M versus 6.48M). However, at low effort it increased tokens from 10.11M to 22.51M without improving accuracy (35/80 in both conditions). Second, in preliminary experiments, I implemented various orchestration patterns which can be invoked in the initial program, like an iterative worker-checker loop. This type of intervention runs somewhat against the premise of SPE, but the idea was to illustrate strategies that a model could theoretically implement itself. These caused higher compute utilization and some seemed to improve accuracy, but statistical power was an issue, and pilots were not promising enough to justify expensive runs.

Reviewer yEyVOpenReview ↗
Rating
5/6
Confidence
3/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

This paper proposes self-programmed execution (SPE), a new agent architecture in which the language model's output serves as the orchestrator itself, eliminating the need for a fixed external control policy. To enable this paradigm, the author introduces Spell, a Lisp-based self-modifying language that supports safe re-evaluation without replaying side effects. Experiments show that existing SOTA LLMs can successfully operate under this execution model on challenging agentic tasks, suggesting a potentially promising direction for learned self-orchestration.

Strengths and weaknesses

Strengths:

  • The paper is generally well-written and easy to follow (Some exceptions in Section 2)
  • Overall, the idea of LLMs having maximum flexibility to program the agentic execution sounds promising. For instance, the ability for a model to choose the prefix used for subsequent steps can result in more natural management of the context window
  • The paper describes existing works on agents' architecture in detail and clearly positions the proposed idea with respect to those works
  • The Spell language designed for SPE is a reasonable approach for concretely implementing the proposed idea and handling the challenges mentioned, such as context persistence and replaying effects

Weaknesses:

  • One of the major weaknesses of the paper is the lack of evidence showing the potential of SPE. I sympathize with the author about the fact that the true potential of the method can only be seen through a model that is explicitly trained with a matching harness. However, I still fail to understand exactly what benefit I would expect to clearly see if such a model exists

Minor:

  • Some of the terms might be better defined in the paper rather than directly using them given that this is a ML conference readers. For example, CEK (line 68), quine (line 151)
Questions

Questions:

  • If we were to have a strong model of the same capability post-trained with SPE-based architecture, what benefits would I likely see compared to ReAct and RLM due to its better expressivity? Should we expect the model to learn more efficient ways to solve the problems in general benchmarks during the RL?
  • A reader would appreciate some more motivation of the formalization in Section 2. Lines 67 to 70 attempt to express this motivation, but it uses terms that are not defined before and is still unclear to me. Can you elaborate on the motivation for the formalization in simple terms?
  • “An SPE state of X is a state x0 such that (X, x0) completion-generates X” — what does this mean? (Line 91)
  • What is divergence state, Def 2.2?
Limitations

Discussed in Section 6

Final justification

Author has sufficiently answered my questions and resolved some of my concerns in the updated revision.

Formatting concerns

None

3 comments
Authors · RebuttalOpenReview ↗
Rebuttal

Thank you to the reviewer for the positive comments and thoughtful review; I respond to each point below.

Future potential of SPE

W1: The major weakness is the lack of evidence showing the potential of SPE. I sympathize with the fact that the true potential may only become visible with a model explicitly trained using a matching harness, but I still do not understand what benefit such a model should clearly exhibit.

Q1: If a model of the same capability were post-trained with an SPE-based architecture, what benefits would likely appear relative to ReAct and RLM because of SPE’s greater expressivity? Should the model learn more efficient problem-solving strategies during reinforcement learning?

I agree with the reviewer that the unknown future potential of SPE is an important limitation. A similar concern was raised by Reviewer iZzx (W1). I'll offer some predictions and articulate some reasons for optimism.

One prediction is that a SPE-native model should have better token and cost efficiency on long-horizon tasks. Already, Spell agents expend far fewer input tokens than Codex CLI by pruning context across turns (Appendix C.7), at some cost in accuracy; a model post-trained for SPE should improve this tradeoff. Over long-horizon tasks in particular, input tokens accumulate and become stale with an append-only orchestration policy. Long-horizon tasks are also currently the major focus of task-specific harness engineering effort, and a suitably trained model might automate this kind of work.

What further strategies might be learned? First, the model might learn to manipulate its chain of thought, which is append-only under ReAct-style orchestration (the RLM shares this limitation). It might reset recent reasoning branches to avoid anchoring while brainstorming, compact a completed reasoning branch into its conclusion, or edit out an earlier reasoning error that would otherwise cause anchoring or cost attention to ignore. Second, because context eviction makes exploration cheap, it might learn to read broadly—beyond what is clearly needed—and retain only what proves relevant. Third, it might learn to decompose tasks and context in a fine-grained, hierarchical manner, delegating subtasks to subagents so that context length and quadratic attention cost scale with subtask size rather than with the full trajectory.

This is speculation, but three pieces of evidence make me generally optimistic:

  1. An ongoing trend in production systems is toward feature-rich, custom harnesses that manage LM context and trigger certain actions deterministically (l. 24-30). A few examples are PR-triggered code review, goal-oriented loops, and research-plan-implement pipelines. The amount of human activity suggests that this harness engineering (similarly "context engineering" and "loop engineering") does affect performance in ways that practitioners care about.
  2. Precedent exists that models can be post-trained for self-orchestration, leading to improvements in benchmark performance (ll. 387–392). This applies both to subagent orchestration and context management. Kimi-K2.6 was trained to use parallel subagents via an RL approach that seems generalizable: initially, spike the reward signal with a term which encourages the use of subagent features; gradually, downweight this term such that the model learns to employ these features only when beneficial.
  3. For frontier models, the gap is one of behavior rather than capability. When given a task that requires multi-agent self-orchestration, GPT-5.4 is capable of implementing such programs (Observation 3). In my revision, I extend this analysis to include asynchronous multi-agent orchestration (see my response to Reviewer x1Ph's W1). In general, post-training is expected to be effective at eliciting behaviors that are already within the capabilities of a base model.

In the submitted manuscript, these arguments were scattered about. In the revision, I expand the final Discussion paragraph to bring them together:

The tendency of current agents to implement mostly simple Spell programs could change if an LM were trained to use Spell natively. Production systems increasingly rely on feature-rich harnesses that manage context and trigger certain actions deterministically [Horthy, 2025]; practitioners describe this work as “context engineering” and “harness engineering” [Anthropic Applied AI Team, 2025, Lopopolo, 2026]. At least for GPT-5.4, common self-orchestration motifs are already within the model's capabilities: when given artificial tasks that require self-orchestration, it writes nontrivial Spell programs, including worker–checker loops (Observation 3). Post-training may be able to elicit such behaviors more reliably. Prior work provides supportive precedent, reporting gains from systems specialized for subagent orchestration, including Conductor and Kimi K2.6 [Nielsen et al., 2026, Kimi Team (Moonshot AI), 2026], and from post-training for context management, as in FoldGRPO [Sun et al., 2025]. It remains unclear how far this would scale: would long-running tasks accumulate increasing benefit over time? Would a strong Spell-native model actually discover optimal strategies during training? Would this end-to-end approach outperform self-evolving agent architectures? Despite these uncertainties, there is precedent for end-to-end learning to outscale human effort [Sutton, 2019]; Spell-native training may provide the means by which to scale orchestration with computation.

I would welcome further feedback on this paragraph.

Motivation and clarity of Section 2

Q2 A reader would appreciate more motivation for the formalization in Section 2. Lines 67–70 attempt to give this motivation, but use undefined terminology and remain unclear. Can the motivation be explained in simple terms?

Thank you for the comment; this section was overly compressed and has been revised.

The purpose of this section is to address two questions:

  1. What is a "fixed orchestration policy" and why is SPE, or its implementation in Spell, not an example of such a policy?
  2. Why does the motivation for SPE - "let's ablate the fixed orchestration policy" - lead to the procedure which is proposed, "evaluate the model completion as a program"?

Question (1) is addressed by defining "orchestration policy" as the transition function exposed at a particular machine state (ll. 104–111); the policy is "fixed" if some successor states are inaccessible. An SPE state (Definition 2.3) is one whose orchestration policy is not fixed, meaning that the model chooses its successor state freely. Then, question (2) is addressed by Theorem 2.5, which shows that the procedure I propose does indeed produce an SPE state.

In my revision, I expanded the first paragraph of the section as follows:

What is meant by “fixed orchestration policy,” what does it mean to ablate it, and why does doing so lead to the specific procedure—“evaluate the model completion as a program”—which is termed SPE? This section addresses these questions formally. First, it defines an agentic machine and its orchestration policy, the transition function that maps a model completion to the successor machine state. Second, it defines an SPE state as one in which, roughly, the model freely chooses its successor state; in contrast, orchestration policy is fixed when the menu of reachable successor states is limited. Third, it defines a machine state that realizes the procedure in Equation (1), and Theorem 2.5 shows that this state is an SPE state. Thus, the formalization both defines what it means to remove fixed orchestration policy and verifies that the proposed procedure has this property. Proofs and additional results are provided in Appendix A.

Q3 What does “An SPE state of X is a state x0 such that (X, x0) completion-generates X” mean?

Informally, if we gloss over the "embedding" construction, this defines an SPE state of an agentic machine X as one such that the model can reach any successor state by emitting a certain completion. Perhaps what is confusing here is that "completion-generates" is defined generally for two different machines X and X', while the definition of an SPE state applies it to the case X'=X. In my revision, I have attempted to make this more clear:

Completion-generation is defined for a possibly different target machine X′ because this more general relation is used again in Corollary 2.6. An SPE state is the special case X′ = X: the machine completion-generates itself. Equivalently, imagine an equivalent copy of the agentic machine embedded inside X. Starting from x₀, for every state y in that copy, there is some completion that makes y the next state. The completion can therefore load an arbitrary future orchestration state rather than merely select from a harness-prescribed menu of actions.

Q4 What is a divergence state in Definition 2.2?

A divergence state is one which never reaches a successor state. This possibility is important to handle because it is impossible to have a general computer such that every program is guaranteed to halt (cf. the halting problem). In my revision, I define this term upon first use:

The harness function maps a state/completion pair either to the next model-call state, to a distinguished halting state 1, or to a divergence state ↑ indicating that the intervening deterministic computation never halts or reaches another model call.

Minor clarity issue: terms such as “CEK” and “quine” should be defined for an ML-conference audience rather than introduced without explanation.

I add definitions for these and other such terms (e.g., REPL, boundary state) in my revision.

Thank you again to the reviewer for their comments. I would welcome further feedback, or, if concerns are mitigated, I would appreciate this being reflected in the reviewer's assessment.

Reviewer yEyV · CommentOpenReview ↗

Thanks for answering my questions. The updated manuscript addresses my concerns. I am raising my score accordingly.

Authors · CommentOpenReview ↗

Thank you for your time and your positive assessment!

From OpenReview, CC BY 4.0. Authors as signed there; shown unedited.

Missing a submission?

Loading the discussion…