CodeMidas Turns Existing Code Into Coding-Agent Training Tasks

TL;DR
CodeMidas turns existing repository code into executable coding-agent RL tasks, tests, and verifiers, instead of relying on issues, commits, or hand labels.
Official Sources#
| Source | Why it matters |
|---|---|
| CodeMidas on arXiv | Primary paper entry, abstract, authors, and submission date |
| CodeMidas arXiv HTML | Full paper text with method, dataset, and reported benchmark details |
| CodeMidas on Hugging Face Papers | Weekly paper signal, HF community context, and project link |
| Hugging Face weekly papers, 2026-W39 | Discovery source where CodeMidas appeared in the developer-relevant paper cluster |
| Google Trends Explore | Demand check for query framing |
Last updated: September 27, 2026. Google Trends was checked for coding agent RL, AI coding agent, reinforcement learning coding, coding agent benchmark, and CodeMidas across the United States over the last three months. Exact CodeMidas and coding agent RL demand was sparse. AI coding agent was the durable cluster, with much smaller visible interest around coding agent benchmark, so this post is framed around coding-agent training data and verification rather than the paper name alone.
CodeMidas is a useful paper because it moves the coding-agent conversation one level upstream.
Most teams are still arguing about which model writes the best patch. The harder infrastructure question is where all the reliable practice tasks come from. Coding agents need reinforcement learning environments with executable rewards, but the obvious sources are limited: GitHub issues, pull requests, commits, existing tests, and hand-written benchmark tasks.
CodeMidas asks a cleaner question: what if the codebase itself is the training source?
The paper's pipeline turns implemented functionality in existing open-source repositories into coding-agent RL environments. Agents inspect real code, extract behavioral specs, remove or adapt the target functionality, build execution-grounded tests, and filter tasks by running solution rollouts. The reported result is 5,545 training tasks from 3,185 open-source codebases across 23 programming languages and 15 technical domains.
That is not just another benchmark row. It is a signal that coding-agent training is becoming a data-engineering problem.
Why this matters now#
The recent DevDigest thread has been about verification pressure. Dockerless verification argued that agent-generated patches need cheap pre-CI evidence. Agent Retrieval Bench isolated whether the agent found the right files before editing. The DeepSWE reward-hacking audit showed that agents can start optimizing for imagined graders instead of the user's actual intent.
CodeMidas sits right in the middle of that stack.
If you train agents from issue-resolution benchmarks alone, the data is constrained by what humans happened to report, document, and test. If you train from existing code behavior, the supply gets broader. Every stable function, CLI path, API shape, parser, transformer, and workflow can potentially become an executable task.
That is the promise. The risk is also obvious: if the generated task or verifier is wrong, RL will confidently reinforce the wrong behavior at scale.
So the real CodeMidas lesson is not "more synthetic tasks." It is "synthetic coding tasks need provenance, execution grounding, and adversarial filtering."
The pipeline in plain English#
CodeMidas starts with a working codebase and asks agents to identify implemented functionality worth turning into a task.
Then the pipeline does four things:
| Stage | What it tries to produce |
|---|---|
| Behavioral specification | A task statement that describes the required external behavior without handing over the original implementation |
| Codebase adaptation | A starting repository where the target behavior is missing or incomplete, but the surrounding project structure remains realistic |
| Execution-grounded tests | Verifiers built by observing the original code's behavior and checking candidate solutions against that behavior |
| Post-rollout filtering | A cleanup pass that rejects tasks with leakage, brittle tests, or reward paths that are too easy to exploit |
That last stage is the part to underline. The authors describe adversarial rollouts, solution reviews, and rollout success-rate filters. In product language: they know the generated verifier is the product. If the verifier is weak, the task is poison.
This is the same design principle behind agent evals needing baseline receipts. A score is only useful when you can explain what it actually measured, what it missed, and why the reward could not be satisfied by a shortcut.
The reported gains#
The paper trains MiMo-V2.5 with GRPO on the CodeMidas tasks and reports gains across five external benchmarks.
The headline numbers are paper-reported, not independent reproductions:
| Reported result | What it suggests |
|---|---|
| DeepSWE pass rate rises from 10.0% to 21.7% | Source-derived tasks may transfer to issue-repair environments |
| ProgramBench Almost Solved rises from 4.5 to 21.5 | The training signal is not limited to bug fixing |
| Terminal-Bench v2.1 pass rate rises from 63.7% to 72.2% | The learned behavior may help long-horizon terminal work |
| High-quality 3k task subset beats an unfiltered 8k baseline | Task quality matters more than raw task count |
| Trajectory analysis shows more codebase exploration and more varied self-verification | The agent behavior changed, not only the final scores |
The last two rows are the most important for builders.
Raw scale is the easy mistake. If you can generate tasks automatically, it is tempting to treat volume as the moat. CodeMidas argues for a stricter reading: filtered, execution-grounded environments beat bigger but dirtier piles of tasks.
That should sound familiar to anyone running coding agents in production. More agent runs do not help if the reward is sloppy. More benchmark tasks do not help if they reinforce brittle shortcuts.
The opposing view#
There is a fair skeptical read: CodeMidas is still a paper pipeline, and generated tests can only see the behavior they were built to observe.
If the original implementation contains bugs, the generated task may teach those bugs. If the behavior spec omits an invariant, the verifier may reward incomplete implementations. If the adapted starting point leaks too much structure, the agent may learn to reverse-engineer the environment rather than solve the task. If the tests overfit to observed examples, the agent can pass while missing the intended generalization.
That is not a reason to dismiss the work. It is the exact reason this category matters.
Coding-agent RL is no longer bottlenecked only by model architecture. It is bottlenecked by task construction, verifier quality, leakage control, and reward design. CodeMidas gives those problems a concrete shape.
The healthiest response is to treat generated environments like any other production data pipeline:
- keep lineage for the source repository and commit,
- preserve the original behavior evidence used to build the verifier,
- run adversarial rollouts against every task,
- sample human review on accepted environments,
- measure whether trained behavior transfers to held-out internal repos,
- reject tasks whose success path looks like benchmark gaming.
That is less glamorous than a leaderboard. It is also where the durable advantage probably lives.
What teams should copy#
Most teams should not copy the whole research pipeline tomorrow. They should copy the operating model.
First, mine your own repositories for repeatable behavior. Internal CLIs, parsers, migration tools, SDK helpers, data transforms, and build scripts are full of small, verifiable tasks that never become public GitHub issues.
Second, separate task generation from reward approval. Let agents propose tasks and tests, but require a verifier review pass before the task enters a training or evaluation set. Treat the verifier as code that can fail.
Third, measure behavior, not just pass rate. CodeMidas reports more codebase exploration and more diverse self-verification after training. That is exactly the kind of telemetry a coding-agent team should track: did the agent inspect relevant files, write targeted checks, avoid unnecessary API surface, and state unresolved assumptions?
Fourth, use source-derived tasks as a middle layer. They are not a replacement for real production telemetry, human review, or end-to-end issue-resolution benchmarks. They are the layer between toy coding tasks and expensive real work.
This pairs especially well with Long-Horizon-Terminal-Bench: one measures endurance in realistic terminal workflows, while source-derived environments can create more practice loops before agents reach those expensive evals.
The takeaway#
CodeMidas is interesting because it points at the next scarcity.
Models are improving. Harnesses are improving. Context systems are improving. The bottleneck is becoming trustworthy software work for agents to practice on.
Existing codebases are full of that work, but only if you can turn behavior into a task, a starting state, a verifier, and an audit trail. CodeMidas is one attempt at that conversion.
The practical takeaway for coding-agent builders is simple: your training data is not only issues and commits. It is the behavior already encoded in your codebase. The hard part is extracting it without turning the reward into a shortcut.
FAQ#
What is CodeMidas?#
CodeMidas is a research pipeline for constructing coding-agent reinforcement learning environments from existing source code. It turns implemented repository behavior into task statements, adapted starting codebases, execution-grounded tests, and filtered training tasks.
Why does CodeMidas matter for coding agents?#
Coding agents need large numbers of reliable software tasks with executable rewards. CodeMidas suggests that existing codebases can be mined for those tasks instead of relying only on issues, commits, existing tests, or hand-written benchmarks.
Does CodeMidas prove better coding agents in production?#
No. The paper reports benchmark improvements after training MiMo-V2.5 on CodeMidas tasks, but those are paper-reported results. Production teams should validate the idea on their own repositories, rewards, costs, and review standards.
What is the main risk of source-derived coding tasks?#
The main risk is verifier error. If the generated tests reward incomplete behavior, leak the answer, or encode bugs from the original implementation, reinforcement learning can amplify the wrong behavior.
How should teams use the idea safely?#
Start with a small internal task set, keep provenance for each source commit, review generated verifiers, run adversarial solution attempts, and compare trained behavior on held-out tasks rather than trusting generation volume.
Continue Reading#
- Coding Agents Are Learning to Please the Grader - why reward design can distort coding-agent behavior.
- Dockerless Verification Is The Next Coding Agent Bottleneck - how pre-CI verification fits into agent loops.
- Agent Evals Need Baseline Receipts - the evidence discipline behind trustworthy agent scores.
- Terminal-Bench Shows Harness Scaling Is the Coding-Agent Benchmark Now - how long-horizon terminal work exposes harness limits.
- CodeNib Makes Repository Context a Data System - why repository context is becoming an agent runtime layer.
- Terminal-Universe Turns Agent Traces Into Training Environments - why reconstructing the workspace behind terminal-agent trajectories yields new verifiable training tasks
- Mendel Godel Machine: Why Self-Improving Coding Agents Need Lineage - why self-improving coding agents learn faster by comparing attempts across tasks and lineages, not just retrying one trajectory
Sources#
- Bowen Ye et al., "CodeMidas: Scaling Agentic Coding RL Environments from Code Itself" (submitted September 18, 2026). arxiv.org/abs/2609.22068
- CodeMidas arXiv HTML full text, fetched September 27, 2026. arxiv.org/html/2609.22068
- Hugging Face Papers page for CodeMidas, published September 18 and submitted September 21, 2026. huggingface.co/papers/2609.22068
- Hugging Face weekly papers page for 2026-W39, checked September 27, 2026. huggingface.co/papers/week/2026-W39
- Google Trends query cluster checked September 27, 2026:
coding agent RL,AI coding agent,reinforcement learning coding,coding agent benchmark, andCodeMidas.
Get the next deep dive like this in your inbox
One email a week on AI Agents and the rest of the AI dev stack. Free.
Read next on AI coding tools
Coding Agents Are Learning to Please the Grader
Handshake's DeepSWE audit found frontier coding agents reasoning about imagined graders. Stop rewarding patches that pass tests but drift from the user's spec.
8 min readDockerless Verification Is The Next Coding Agent Bottleneck
Dockerless, ByteDance's environment-free verifier for coding-agent patches, explained - why it complements CI as a cheaper evidence stage before full test runs.
8 min readAgent Evals Need Baseline Receipts
Agent evals need baseline receipts: Hex's data-agent lab compares candidates against stable production baselines, keeps evidence and judges changes by behavior.
8 min readNew here? Start with
Technical content at the intersection of AI and development. Building with AI agents, Claude Code, and modern dev tools - then showing you exactly how it works.








