diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..d645695673349e3947e8e5ae42332d0ac3164cd7 --- /dev/null +++ b/LICENSE @@ -0,0 +1,202 @@ + + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright [yyyy] [name of copyright owner] + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. diff --git a/LICENSE-mimoagent.md b/LICENSE-mimoagent.md new file mode 100644 index 0000000000000000000000000000000000000000..339328d620d779723500f4ad18dccf0293b91d93 --- /dev/null +++ b/LICENSE-mimoagent.md @@ -0,0 +1,22 @@ +MIT License + +Copyright (c) 2026 Xiaomi Corporation +Copyright (c) 2025 Kilian A. Lieret and Carlos E. Jimenez (mini-swe-agent) + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/NOTICE b/NOTICE new file mode 100644 index 0000000000000000000000000000000000000000..3d5a24149c3b352768918ae361d87d8b6747d97d --- /dev/null +++ b/NOTICE @@ -0,0 +1,31 @@ +MiMo-V2.6-RL in Harbor format +Converted by Hugging Face and the FineEnvs team. Not affiliated with or endorsed by Xiaomi. + +This work is derived from, and redistributes material of: + + MiMo-V2.6-RL-oss (https://huggingface.co/datasets/XiaomiMiMo/MiMo-V2.6-RL-oss, revision 639865fd3374018d6cb29b9fb82dd531406fcf5f) + Copyright Xiaomi Corporation. Licensed under the Apache License, Version 2.0 (LICENSE). + The task prompts, test patches, test commands, Terminal-Bench test files, General-domain verifier files, + and the Docker images referenced by digest (docker.io/xiaomimimo/mimo-v2.6-rl-oss) are Xiaomi's. + + XiaomiMiMo/verl (https://github.com/XiaomiMiMo/verl, commit a2ad9f6), Apache License 2.0 (LICENSE): + tests/music_scorer/ (recipes/design/music/scorer), tests/webdev/shot.py, tests/webdev/eval_rubric.py, + tests/webdev/verdict.py (parse_verdict from eval_mode.py), the Webdev agent prompt, and the step limits. + + XiaomiMiMo/mimoagent (https://github.com/XiaomiMiMo/mimoagent, commit 467f0a1), MIT License + (LICENSE-mimoagent.md; Copyright (c) 2026 Xiaomi Corporation, Copyright (c) 2025 Kilian A. Lieret and + Carlos E. Jimenez (mini-swe-agent)): tests/server_arvo.py, and the Code-domain residue scrub, cache scrub, + git-clean keep list, test-file reset and ARVO description parsing, ported into the setup and test scripts. + +Vendored files are unmodified. Changes made in this conversion (Apache-2.0 section 4(b)): + - Each environment is repackaged as a Harbor task: task.toml, instruction.md, environment/, tests/. + - Setup that Xiaomi's harness runs before the agent is written as environment/setup/setup.sh and run from + the task's healthcheck. In the Code residue scrub, /logs is emptied rather than deleted (Harbor owns it). + - Grading entry points (tests/test.sh, grade.py, verify.py) wrap the original graders. Cyber re-runs the + last submitted PoC with server_arvo.py's own logic; General redacts judge-key echoes from its output. + - Music: "Write your complete reply to /app/answer.md." is appended to each prompt, because a Harbor task + is an agent session rather than a single completion. + - Images are referenced by digest instead of by tag; the MCP sidecar pins mcp==1.26.0. + - agents/mimo_opencode.py extends Harbor's OpenCode agent (Apache-2.0, harbor-framework/harbor). + +Harbor (https://github.com/harbor-framework/harbor) is the task format and runner; it is not redistributed here. diff --git a/README.md b/README.md new file mode 100644 index 0000000000000000000000000000000000000000..f01b5be1876a4df20738c34c0516b9d5f765bd23 --- /dev/null +++ b/README.md @@ -0,0 +1,121 @@ +--- +license: apache-2.0 +language: +- en +- zh +task_categories: +- other +tags: +- rl-environment +- reinforcement-learning +- harbor +- agent +- mimo +- mimo-v2.6-rl +- terminal +- terminal +- terminal-bench +- cli +size_categories: +- n<1K +viewer: false +--- + +[![View tasks in Harbor Visualiser](https://img.shields.io/badge/%F0%9F%A4%97%20Harbor%20Visualiser-View%20tasks-FFD21F?style=for-the-badge)](https://huggingface.co/spaces/HuggingFaceH4/harbor-visualiser?dataset=FineEnvs/MiMo-V2.6-RL-harbor-terminal) +[![MiMo RL Environment Explorer](https://img.shields.io/badge/%F0%9F%A4%97%20Explorer-Run%20a%20rollout-FFD21F?style=for-the-badge)](https://huggingface.co/spaces/FineEnvs/MiMo-RL-Envs-Explorer) + +# MiMo-V2.6-RL Terminal (Harbor) + +**Terminal-Bench style tasks.** 64 Harbor tasks from the Terminal domain of Xiaomi's +[MiMo-V2.6-RL-oss](https://huggingface.co/datasets/XiaomiMiMo/MiMo-V2.6-RL-oss), the RL environments MiMo-V2.6 was trained +on, converted so every one runs as a standard Harbor task. + +Self-contained command-line tasks in the Terminal-Bench format, graded by each task's own pytest suite and anti-hack guard. + +| | | +|---|---| +| Tasks | 64 | +| Graded by | pytest + anti-hack guard (deterministic) | +| Reference step limit | 500 | +| Source | [`XiaomiMiMo/MiMo-V2.6-RL-oss`](https://huggingface.co/datasets/XiaomiMiMo/MiMo-V2.6-RL-oss) at `639865fd3374` | +| Reference harness | XiaomiMiMo/verl `a2ad9f6` + XiaomiMiMo/mimoagent `467f0a1` | + +Part of a set of six: [code](https://huggingface.co/datasets/FineEnvs/MiMo-V2.6-RL-harbor-code), [cyber](https://huggingface.co/datasets/FineEnvs/MiMo-V2.6-RL-harbor-cyber), [general](https://huggingface.co/datasets/FineEnvs/MiMo-V2.6-RL-harbor-general), [terminal](https://huggingface.co/datasets/FineEnvs/MiMo-V2.6-RL-harbor-terminal), [webdev](https://huggingface.co/datasets/FineEnvs/MiMo-V2.6-RL-harbor-webdev), [music](https://huggingface.co/datasets/FineEnvs/MiMo-V2.6-RL-harbor-music). + +## Layout + +```text +tasks// +├── task.toml # image pinned by digest, one-time setup (healthcheck), judge settings, provenance +├── instruction.md # the prompt the agent sees, word for word what Xiaomi's harness gives it +├── environment/ # Dockerfile (FROM the same digest) and setup/, a readable copy of the setup +└── tests/ # test.sh and everything grading needs; uploaded only after the agent finishes +registry.json # Harbor registry entry +data/tasks.jsonl # one metadata row per task, for filtering without walking the tree +manifest.json # sha256 of every task directory +jobs/terminal.yaml # the reference agent settings +agents/mimo_opencode.py +``` + +Example: [task.toml](https://huggingface.co/datasets/FineEnvs/MiMo-V2.6-RL-harbor-terminal/blob/main/tasks/candidate-0036-software-data-engineering/task.toml) · +[instruction](https://huggingface.co/datasets/FineEnvs/MiMo-V2.6-RL-harbor-terminal/blob/main/tasks/candidate-0036-software-data-engineering/instruction.md) · +[verifier](https://huggingface.co/datasets/FineEnvs/MiMo-V2.6-RL-harbor-terminal/blob/main/tasks/candidate-0036-software-data-engineering/tests/test.sh). + +## Run + +```bash +hf download FineEnvs/MiMo-V2.6-RL-harbor-terminal --repo-type dataset --local-dir mimo-terminal +cd mimo-terminal +PYTHONPATH=agents HF_TOKEN=hf_... harbor run -y -c jobs/terminal.yaml +``` + +The job runs `agents/mimo_opencode.py` (OpenCode 1.18.32) on HF Sandbox with the reference settings: the step +limit above, replies of up to 65,536 tokens, thinking low, no web fetch or search. +Change `model_name` and the provider block for another model. Any Harbor agent can run these tasks; this one +also applies two steps of Xiaomi's harness a task file can't express: the answer-leak blocklist after install, +and the unprivileged `agent` user on sandboxes that run everything as root. + +Serving them to a trainer works like any Harbor dataset, for example with OpenEnv: + +```bash +openenv harbor serve --dataset FineEnvs/MiMo-V2.6-RL-harbor-terminal --llm-url http://127.0.0.1:8000/v1 --model +``` + +## How it was converted + +With the [mimo_harbor adapter](https://github.com/adithya-s-k/FineEnvs/tree/mimo-explorer-rollouts/mimo-explorer/mimo_harbor). It reads the source at one pinned revision and every image through +a digest lock, so a rerun produces byte-identical tasks (`manifest.json`). Setup and grading follow Xiaomi's +harness step by step, as the explorer's runner does, using the same vendored graders: + +- Nothing that grades a task (hidden tests, rubrics, verifier scripts) is reachable while the agent works. +- A testbed failure (a patch that won't apply, a system that died, a judge that never answered) writes no reward, + so Harbor records an error rather than a 0. +- Images are pinned by digest; HF Sandbox and other prebuilt-image backends run them without a build step. + +Deviations from the reference, and why, are listed in the adapter's README. + +## Validation + +- All 7,780 tasks across the six datasets load with Harbor's task loader and pass the adapter's static checks + (digest-pinned images, setup payload equal to its readable copy, rubrics only under `tests/`). +- With Harbor's no-op agent every dataset scores 0 and every verifier runs to completion: no free rewards. +- One task per dataset was run end to end with GLM-5.3 both in Harbor and in the + [explorer](https://huggingface.co/spaces/FineEnvs/MiMo-RL-Envs-Explorer), which runs Xiaomi's harness; the results match (see the adapter's `parity.md`). + A full parity study over repeated runs has not been done yet. + +## Credits + +The environments, their prompts, tests, verifiers, images and graders are the work of the +[Xiaomi MiMo](https://huggingface.co/XiaomiMiMo) team, released as +[XiaomiMiMo/MiMo-V2.6-RL-oss](https://huggingface.co/datasets/XiaomiMiMo/MiMo-V2.6-RL-oss) together with their training code +[XiaomiMiMo/verl](https://github.com/XiaomiMiMo/verl) and agent harness +[XiaomiMiMo/mimoagent](https://github.com/XiaomiMiMo/mimoagent). mimoagent builds on +[mini-swe-agent](https://github.com/SWE-agent/mini-swe-agent) (Kilian A. Lieret and Carlos E. Jimenez). +The task format and runner are [Harbor](https://github.com/harbor-framework/harbor). +This conversion is by Hugging Face and the FineEnvs team, and is not affiliated with or endorsed by Xiaomi. + +## License + +Apache-2.0, as the source dataset (`LICENSE`). Files vendored from XiaomiMiMo/mimoagent (`tests/server_arvo.py` +in Cyber tasks, and the ported setup commands) are MIT (`LICENSE-mimoagent.md`). `NOTICE` lists every source, +its license, and the changes this conversion made. Vendored grader files are unmodified. diff --git a/agents/mimo_opencode.py b/agents/mimo_opencode.py new file mode 100644 index 0000000000000000000000000000000000000000..2502c7443d3951c22ccce450b32b888a819a0a6b --- /dev/null +++ b/agents/mimo_opencode.py @@ -0,0 +1,71 @@ +"""OpenCode for MiMo tasks: Harbor's OpenCode agent plus two steps of Xiaomi's harness that a task can't express. + +1. The answer-leak blocklist. mimoagent appends it to /etc/hosts after the agent is installed (the install itself + needs github.com). Task setup leaves the list in /var/lib/mimo/blocklist; this agent applies it right after + install and fails closed, as mimoagent does. +2. The unprivileged agent user. Cyber and General run the agent as `agent`, so the verify server and the systems' + data stay out of its reach. Tasks say so in [agent].user; on environments that cannot switch users (HF Sandbox + runs everything as root), this agent drops to that user itself with runuser. + +3. The output ceiling. OpenCode caps a reply at 32,000 tokens unless OPENCODE_EXPERIMENTAL_OUTPUT_TOKEN_MAX says + otherwise; it is set here from the configured model limit (65,536, mimoagent's opencode.yaml) rather than in the + job's env, because Harbor treats any env var named *TOKEN* as a secret and blanks its value in every output. + +Use it with `import_path: mimo_opencode:MimoOpenCode` (see jobs/*.yaml). +""" + +from __future__ import annotations + +import shlex +from typing import Any + +from harbor.agents.installed.opencode import OpenCode +from harbor.environments.base import BaseEnvironment + +MIMO = "/var/lib/mimo" + + +class MimoOpenCode(OpenCode): + @staticmethod + def name() -> str: + return "mimo-opencode" + + def __init__(self, *args, **kwargs): + super().__init__(*args, **kwargs) + self._drop_to: str | None | bool = False # False: not checked yet + limits = [m.get("limit", {}).get("output") for p in (self._opencode_config.get("provider") or {}).values() + for m in (p.get("models") or {}).values()] + top = max([x for x in limits if isinstance(x, int)] or [0]) + self._mimo_env = {"OPENCODE_EXPERIMENTAL_OUTPUT_TOKEN_MAX": str(top)} if top > 32000 else {} + + async def _target_user(self, environment: BaseEnvironment) -> str | None: + """The user the task wants the agent to run as, if the environment would otherwise run it as root.""" + if self._drop_to is False: + want = await environment.exec(f"cat {MIMO}/agent_user 2>/dev/null", user="root") + user = (want.stdout or "").strip() or None + if user: + who = await super().exec_as_agent(environment, "id -un") + user = user if (who.stdout or "").strip() == "root" else None + self._drop_to = user + return self._drop_to + + async def exec_as_agent(self, environment: BaseEnvironment, command: str, env: dict[str, str] | None = None, + cwd: str | None = None, timeout_sec: int | None = None) -> Any: + env = {**(env or {}), **self._mimo_env} + user = await self._target_user(environment) + if user: + home = f"/home/{user}" + exports = " ".join(f"{k}={shlex.quote(v)}" for k, v in (env or {}).items()) + command = (f"runuser -u {user} -- env HOME={home} USER={user} {exports} " + f"bash -c {shlex.quote(('cd ' + shlex.quote(cwd) + ' && ' if cwd else '') + command)}") + return await super().exec_as_agent(environment, command, env=env, cwd=cwd, timeout_sec=timeout_sec) + + async def install(self, environment: BaseEnvironment) -> None: + await super().install(environment) + res = await environment.exec( + f"if [ -f {MIMO}/blocklist ]; then cat {MIMO}/blocklist >> /etc/hosts && grep -c '^0.0.0.0' /etc/hosts; " + f"else echo none; fi", user="root") + if res.return_code != 0: + raise RuntimeError("could not install the answer-leak blocklist in /etc/hosts: " + (res.stderr or res.stdout or "")[-300:]) + out = (res.stdout or "").strip() + self.logger.info("answer-leak blocklist: " + ("none for this task" if out == "none" else f"{out} hosts blocked in /etc/hosts")) diff --git a/data/tasks.jsonl b/data/tasks.jsonl new file mode 100644 index 0000000000000000000000000000000000000000..0de376b918212d4ab84e7b7d645e725a43919df7 --- /dev/null +++ b/data/tasks.jsonl @@ -0,0 +1,64 @@ +{"task_id": "candidate-0036-software-data-engineering", "source_id": "candidate-0036-software-data-engineering", "domain": "terminal", "task_path": "tasks/candidate-0036-software-data-engineering", "docker_image": "docker.io/xiaomimimo/mimo-v2.6-rl-oss@sha256:3db4bdcb19504df7b6a9ad1de3ed33b7ec32340dcb4ff108b6b947af39cd5bee", "step_limit": 500, "agent_timeout_sec": 900.0, "verifier_timeout_sec": 240.0, "instruction": "You are an agent, your current working directory is /app.\n\nYou can use the tools available to you to interact with the computer to assist the user in completing tasks.\n\n# Repair wildcard output flags in the workflow engine\n\nYou are given a frozen, pre-fix Snakemake source tree at\n`/app/vendor/snakemake`. A data workflow declares several output patterns with\nwildcard constraints. Some outputs are marked `touch`, `temp`, `protected`,\n`pipe`, or `service`. After a rule is expanded for a concrete wildcard value,\nthe resulting job must retain the flags attached to that concrete output.\n\nDiagnose the interaction between output declaration in\n`src/snakemake/rules.py` and concrete job construction in\n`src/snakemake/jobs.py`. Repair the existing production modules so flag\nclassification is based on the expanded output object and remains correct for\nall of the flags above. Do not special-case the sample names, remove wildcard\nconstraints, or add shell commands that manufacture marker files.\n\nRun the three-stage offline integration replay:\n\n```sh\ncd /app\npython3 workflow_probe.py\n```\n\nIt must write `/app/output.json` with schema version `workflow-repair-1`, two\nconcrete wildcard jobs, one touch output per job, preserved temp/protected and\npipe/service categories, and a completed downstream aggregate. The replay is\nonly valid when both existing source modules have been repaired.\n"} +{"task_id": "candidate-0109-science-robotics", "source_id": "candidate-0109-science-robotics", "domain": "terminal", "task_path": "tasks/candidate-0109-science-robotics", "docker_image": "docker.io/xiaomimimo/mimo-v2.6-rl-oss@sha256:92e1760ed72a11016f8792e3f7c8ec97943ad4f16c591164e8d5d4e0b81c9ab5", "step_limit": 500, "agent_timeout_sec": 900.0, "verifier_timeout_sec": 240.0, "instruction": "You are an agent, your current working directory is /app.\n\nYou can use the tools available to you to interact with the computer to assist the user in completing tasks.\n\n# Repair numerical IK restart validation\n\nWork in the frozen source tree at `/app/vendor/robotics-toolbox-python`.\n\nThe numerical inverse-kinematics solvers use random restarts when no explicit initial\nconfiguration is available. That restart operation exists in both the Python solver\nhelper and the compiled ETS fast path. Models containing non-finite joint-limit\nmetadata currently reach those samplers and fail inconsistently or contaminate the\nrestart state.\n\nRepair the existing implementation with these requirements:\n\n1. Modify both `src/roboticstoolbox/robot/IK.py` and\n `src/roboticstoolbox/ets/cpp-extensions/ik.cpp`; a one-backend repair is incomplete.\n2. Reject `NaN`, positive infinity, or negative infinity in any lower or upper joint\n limit before consuming random-number state or producing a restart sample.\n3. Expose `ValueError` to Python callers. The diagnostic must identify joint-limit\n validation and the offending joint index and values sufficiently to locate bad\n robot metadata.\n4. Preserve existing valid behavior: seeded sampling remains deterministic, scalar\n and batched requests retain shape `(count, joint_count)`, and every sample remains\n inside its closed finite interval. Zero-width finite intervals remain valid.\n5. Do not clamp, replace, or invent finite limits, and do not bypass the native path,\n replace the library with a standalone implementation, or modify tests to hide the\n defect.\n\nAfter repairing the source, run the offline integration check:\n\n```sh\ncd /app/vendor/robotics-toolbox-python\npython3 /app/tools/run_validation.py > /app/output.json\n```\n\nThe command must succeed and produce `/app/output.json` with schema version\n`robotics.ik_restart_validation.v1`. Network access and package installation are not\navailable.\n"} +{"task_id": "candidate-0260-security-appsec", "source_id": "candidate-0260-security-appsec", "domain": "terminal", "task_path": "tasks/candidate-0260-security-appsec", "docker_image": "docker.io/xiaomimimo/mimo-v2.6-rl-oss@sha256:22f5efb3150202c6e0894f9838c064c2a88e758bd9d4e62d795ad95d9986913a", "step_limit": 500, "agent_timeout_sec": 900.0, "verifier_timeout_sec": 240.0, "instruction": "You are an agent, your current working directory is /app.\n\nYou can use the tools available to you to interact with the computer to assist the user in completing tasks.\n\n# Repair the offline security scan pipeline\n\nYou are given a vendored Bandit source tree under `/app/vendor/pycqa-bandit` and\nan offline fixture set under `/app/workload/fixtures`. Repair the existing source\nso the normal file-level Trojan Source check can be used by an integration\ncaller, then produce `/app/output.json` by running the supplied scan entrypoint.\nDo not replace the scanner with a new standalone evaluator.\n\nThe producer must preserve the scanner's security semantics:\n\n- bidirectional Unicode controls are reported as B613 with HIGH severity and\n MEDIUM confidence;\n- the finding location is 1-based and points to the physical source line and\n character column containing the control character;\n- file-level plugins may provide their own non-empty `linerange`; generic tester\n enrichment must not erase it, while issues without a custom range still get\n the framework context range;\n- filename and original file bytes remain attached to each issue, and the\n non-UTF-8 fixture must be decoded according to its Python encoding declaration;\n- clean files must remain clean.\n\nUse the existing modules and integration path. The output contract is documented\nin `/app/CONTRACT.md`; its schema version must be exactly\n`bandit_trojan_repair.v1`. Include every `*.py` fixture in lexical filename order,\nincluding clean files, and use the supplied `/app/run_scan.py` after repairing\nthe source. Keep the workspace offline and do not add dependencies.\n"} +{"task_id": "candidate-0308-security-forensics", "source_id": "candidate-0308-security-forensics", "domain": "terminal", "task_path": "tasks/candidate-0308-security-forensics", "docker_image": "docker.io/xiaomimimo/mimo-v2.6-rl-oss@sha256:c1b2d7e5807fef4065b79fe92e1dfef047503159349ced9b19941b48f684c4e6", "step_limit": 500, "agent_timeout_sec": 900.0, "verifier_timeout_sec": 240.0, "instruction": "You are an agent, your current working directory is /app.\n\nYou can use the tools available to you to interact with the computer to assist the user in completing tasks.\n\n# Repair the Windows forensic plugin integration\n\nThe vendored Volatility3 tree contains a partially completed API migration in\nthe Windows forensic plugins. The shared `Handles` plugin now exposes its\nhandle-table helpers as context-explicit classmethods and has a newer plugin\nversion. Several consumers still use the old contract.\n\nWork in `/app/vendor/volatility3`. Repair the integration in all four existing\nconsumer modules: `callbacks.py`, `dumpfiles.py`, `poolscanner.py`, and\n`psxview.py`. Preserve the upstream filtering and invalid-memory behavior.\n\nRequirements:\n\n1. Every consumer must declare the current `Handles` requirement version.\n2. Calls to `get_type_map`, `find_cookie`, and `handles` must use the\n context-explicit classmethod interface, passing the active kernel module\n name and handle table where applicable.\n3. Do not replace the forensic traversal with constants, a new evaluator, or\n a separate script. Keep the existing plugin dependency graph intact.\n4. Run a compile smoke check that does not leave generated bytecode in the\n source tree, then write `/app/output.json` with exactly\n this schema:\n\n```json\n{\"schema_version\":\"volatility-repair-report.v1\",\"modules\":[\"callbacks\",\"dumpfiles\",\"poolscanner\",\"psxview\"],\"checks\":{\"requirements\":4,\"context_calls\":true,\"compile\":true}}\n```\n\nThe report is a summary of the repaired source tree, not a substitute for the\nsource repair. Runtime is offline and no packages or files may be downloaded.\n"} +{"task_id": "candidate-0390-security-appsec", "source_id": "candidate-0390-security-appsec", "domain": "terminal", "task_path": "tasks/candidate-0390-security-appsec", "docker_image": "docker.io/xiaomimimo/mimo-v2.6-rl-oss@sha256:2e60ef07848d3fdb80ec45dd1afa9651a2d66629e2acbbba401104287d43f507", "step_limit": 500, "agent_timeout_sec": 900.0, "verifier_timeout_sec": 240.0, "instruction": "You are an agent, your current working directory is /app.\n\nYou can use the tools available to you to interact with the computer to assist the user in completing tasks.\n\n# Repair the static-analysis pipeline\n\nThe workspace contains a frozen, offline Bandit source tree under `/app/vendor/bandit` and two representative inputs under `/app/inputs`. A regression affects the line-oriented bidirectional-control-character check when its finding passes through the shared tester.\n\nRepair the existing source modules so that:\n\n- Running `python3 -m bandit -q -f json -o /app/output.json /app/inputs/suspicious.py /app/inputs/latin1.py` completes and writes valid JSON.\n- The suspicious input produces exactly one B613 finding, with high severity, medium confidence, CWE 838, and the finding's manually identified line and column preserved in the serialized result.\n- The Latin-1 input completes without an analyzer traceback and produces no B613 finding.\n- The shared tester still supplies context-derived location data for findings that do not provide their own line range, while never replacing a non-empty plugin-provided range.\n- Existing source, formatter, manager, and functional-test modules remain usable; do not replace the analyzer with a new standalone evaluator or disable checks.\n\nYou may inspect and modify the existing Bandit modules. Keep the solution offline and CPU-only. Your final deliverable is `/app/output.json`; do not include explanations in that file.\n"} +{"task_id": "candidate-0461-ml-evaluation", "source_id": "candidate-0461-ml-evaluation", "domain": "terminal", "task_path": "tasks/candidate-0461-ml-evaluation", "docker_image": "docker.io/xiaomimimo/mimo-v2.6-rl-oss@sha256:80a528e6d2c5a0c311dd24246c9db89f2f5eaa175390aa00dd0a5252e60d518d", "step_limit": 500, "agent_timeout_sec": 900.0, "verifier_timeout_sec": 240.0, "instruction": "You are an agent, your current working directory is /app.\n\nYou can use the tools available to you to interact with the computer to assist the user in completing tasks.\n\n# Repair the fairness feature path\n\nYou are working in an offline checkout of a Fairlearn development package. A downstream evaluation pipeline uses `MetricFrame` to compute selection rates and accuracy by sensitive and control groups.\n\nThe current feature-processing path has an unsafe edge case: a missing sensitive or control value can be treated as an ordinary subgroup instead of being rejected. This can silently change fairness conclusions. Repair the existing package rather than replacing it with a new evaluator.\n\n## Required workflow\n\n1. Inspect the `MetricFrame` feature-processing path and the `GroupFeature` representation. Reproduce the failure using `environment/cases/metricframe_cases.json` and `environment/run_case.py`.\n2. Modify the existing production modules so missing values in every supported feature container (Python scalar lists, NumPy arrays, pandas Series/DataFrames, and control features) raise a clear `ValueError` before grouping.\n3. Preserve valid behavior: length checks, feature names, multi-column grouping, aggregate metrics, and sample weights must remain unchanged.\n4. Run the focused upstream feature-processing test and the supplied integration runner. Write `/app/repair_report.json` with the exact schema below.\n\nThe report must contain `output_schema_version: \"fairlearn-repair-report.v1\"`, `valid_metrics` for the valid fixture, `rejected_cases` naming all invalid cases, and `focused_tests_passed` as a boolean. Do not hard-code a report without repairing and exercising the package.\n\nThe workspace must remain offline and CPU-only. Do not install packages, download data, modify tests to bypass the repair, or delete the existing source tree.\n\n"} +{"task_id": "candidate-0534-ml-training", "source_id": "candidate-0534-ml-training", "domain": "terminal", "task_path": "tasks/candidate-0534-ml-training", "docker_image": "docker.io/xiaomimimo/mimo-v2.6-rl-oss@sha256:9b39c1530ad2f0d047b802b1ad0de1f483131d448efb2a8b2f224c6832b086b9", "step_limit": 500, "agent_timeout_sec": 900.0, "verifier_timeout_sec": 240.0, "instruction": "You are an agent, your current working directory is /app.\n\nYou can use the tools available to you to interact with the computer to assist the user in completing tasks.\n\n# Repair incremental training after model persistence\n\nThe frozen scikit-learn source slice under `/app/vendor/scikit-learn` has a regression in a stateful CPU training workflow. The public harness trains an `MLPRegressor`, serializes and reloads it, then changes the target and performs repeated `partial_fit` calls with both Adam and momentum SGD.\n\nRun:\n\n```bash\npython3 /app/run_regression.py\n```\n\nThe current implementation advances optimizer bookkeeping but leaves the reloaded estimator's live weights and predictions unchanged. Diagnose the parameter ownership across the MLP fit loop and stochastic optimizers, then repair these existing production modules:\n\n- `/app/vendor/scikit-learn/sklearn/neural_network/_multilayer_perceptron.py`\n- `/app/vendor/scikit-learn/sklearn/neural_network/_stochastic_optimizers.py`\n\nAcceptance requirements:\n\n1. The optimizer update contract must apply gradients to the estimator's current coefficient and intercept arrays, including after serialization.\n2. Existing Adam moments/step count and SGD momentum state must continue across reload and fine-tuning; do not recreate the optimizer on each incremental call.\n3. Both public Adam and SGD cases must move materially closer to the changed target while preserving the fitted layer shapes and finite numeric state.\n4. `python3 /app/run_regression.py` must complete and write `/app/results/finetune_report.json` with `output_schema_version` equal to `tbench.mlp_continuation.v1`.\n\nDo not replace or edit `run_regression.py`, `runtime_loader.py`, `cases.json`, immutable vendored modules, or the license. Do not hard-code predictions, bypass serialization, change the workload, disable a solver, or install/download anything. The repair must be in both listed source modules and must remain compatible with both stochastic optimizers.\n"} +{"task_id": "candidate-0628-media-music", "source_id": "candidate-0628-media-music", "domain": "terminal", "task_path": "tasks/candidate-0628-media-music", "docker_image": "docker.io/xiaomimimo/mimo-v2.6-rl-oss@sha256:c41c260588f06ccd0e4b0f8c8ba6b29ef497cc0c180ddf891a4e5d214f7c68aa", "step_limit": 500, "agent_timeout_sec": 900.0, "verifier_timeout_sec": 240.0, "instruction": "You are an agent, your current working directory is /app.\n\nYou can use the tools available to you to interact with the computer to assist the user in completing tasks.\n\n# Task\n\nRepair the frozen Partitura source tree in `/app/vendor/partitura` and produce `/app/output.mid` by running `/app/run_boundary_workflow.py`.\n\nThe current tree fails at several connected boundaries in its real MusicXML-to-MIDI workflow. Implement the repair in the existing production modules `partitura/io/importmusicxml.py` and `partitura/io/exportmidi.py`.\n\n## Required behavior\n\n1. A MusicXML note marked as a chord member normally inherits the preceding note's onset and duration. If such a marker appears before any anchor note in its measure, loading must emit a warning and keep that note as a standalone event instead of raising an assertion or silently dropping it.\n2. Valid chord members must still share the anchor note's onset and duration; the malformed-input fallback must not disable normal chord semantics.\n3. MIDI export must accept `Score`, `Part`, `PartGroup`, ordinary iterables, and one-shot iterators of parts without consuming an iterator during preliminary inspection.\n4. Exporting a score with no parts must raise a clear domain-level `ValueError` indicating that the score has no parts, before NumPy concatenation or MIDI serialization fails.\n5. Compute PPQ from the score's actual quarter-duration values. Preserve an exact computed PPQ when it is within the Standard MIDI File range; do not substitute a conventional constant.\n6. Standard MIDI File ticks-per-beat is limited to 32767. If the computed PPQ is larger, emit a `RuntimeWarning` explaining that timing is rounded, cap PPQ at 32767, and still serialize a readable MIDI file with integer event ticks.\n7. Run `python3 /app/run_boundary_workflow.py` after the repair. The resulting `/app/output.mid` must be a readable MIDI file generated through the repaired public import/export APIs.\n\nKeep the solution offline and modify the existing implementation rather than replacing the package, altering fixtures, or adding a parallel exporter.\n"} +{"task_id": "candidate-0674-ml-evaluation", "source_id": "candidate-0674-ml-evaluation", "domain": "terminal", "task_path": "tasks/candidate-0674-ml-evaluation", "docker_image": "docker.io/xiaomimimo/mimo-v2.6-rl-oss@sha256:5ca4cd941a5a7509de9686894e4c8cb5f3c9519e5de687b4b6592903951329e7", "step_limit": 500, "agent_timeout_sec": 900.0, "verifier_timeout_sec": 240.0, "instruction": "You are an agent, your current working directory is /app.\n\nYou can use the tools available to you to interact with the computer to assist the user in completing tasks.\n\n# Task\n\nRepair the frozen TorchMetrics retrieval source tree under `/app/vendor/torchmetrics` so all four public evaluation paths enforce one consistent `top_k` contract:\n\n- `retrieval_average_precision`\n- `retrieval_reciprocal_rank`\n- `RetrievalMAP`\n- `RetrievalMRR`\n\n## Required behavior\n\n1. `top_k=None` evaluates the complete ranking for each query.\n2. A positive integer evaluates only the highest-scored `k` documents **within each query**.\n3. Zero, negative integers, non-integral numbers, and other non-integer values must raise `ValueError` at the public API boundary.\n4. Ranking remains descending by prediction score, preserving each score's relevance label.\n5. Stateful metrics must group by query index before truncation and preserve `empty_target_action` plus `mean`, `median`, `min`, and `max` aggregation behavior.\n6. Functional and stateful APIs must agree on valid inputs.\n\nModify the existing production modules rather than adding a replacement evaluator. The intended repair spans the two functional retrieval modules and the two stateful retrieval modules. Do not delete or rewrite the supplied source tree, public cases, or workflow helper.\n\nAfter repairing the modules, run:\n\n```bash\npython3 /app/tools/run_retrieval_workflow.py\n```\n\nThe command must finish successfully and write `/app/evaluation_report.json` with schema version `retrieval_topk_eval.v1`. Runtime networking and package installation are not allowed.\n"} +{"task_id": "candidate-0688-hardware-rtl", "source_id": "candidate-0688-hardware-rtl", "domain": "terminal", "task_path": "tasks/candidate-0688-hardware-rtl", "docker_image": "docker.io/xiaomimimo/mimo-v2.6-rl-oss@sha256:396bc53d212898043d303c8b275d4b16d51a73f37024f7377d9b240fb435e981", "step_limit": 500, "agent_timeout_sec": 900.0, "verifier_timeout_sec": 240.0, "instruction": "You are an agent, your current working directory is /app.\n\nYou can use the tools available to you to interact with the computer to assist the user in completing tasks.\n\nRepair the vendored Ibex RTL so an in-flight multi-cycle RV32Zcmp compressed expansion is discarded when the IF stage redirects to an exception handler. Preserve normal Zcmp expansion and the parameterized decoder interface.\n\nWork in `/app/vendor/project`. The source tree is intentionally pre-fix. Add the necessary decoder flush input, connect it from the IF-stage exception redirect, and give the flush priority over the state-machine transition. Then run:\n\n python3 /app/vendor/project/rtl_regression.py --output /app/output.json\n\nThe command must exit successfully and produce `/app/output.json` matching the public schema in `/app/vendor/project/output_contract.json`. Do not add a replacement evaluator or bypass the existing RTL modules.\n"} +{"task_id": "candidate-0758-ml-inference", "source_id": "candidate-0758-ml-inference", "domain": "terminal", "task_path": "tasks/candidate-0758-ml-inference", "docker_image": "docker.io/xiaomimimo/mimo-v2.6-rl-oss@sha256:93f1160b8e5c20c4d0071744d49d53f64386c57b402db3404fc26590a58df47e", "step_limit": 500, "agent_timeout_sec": 900.0, "verifier_timeout_sec": 240.0, "instruction": "You are an agent, your current working directory is /app.\n\nYou can use the tools available to you to interact with the computer to assist the user in completing tasks.\n\nThe workspace under `/app/vendor/onnx` is a frozen slice of a tensor operator used for bounded\nattention KV-cache updates. Diagnose and repair the circular-mode indexing bug in the existing\nproduction files:\n\n- `vendor/onnx/onnx/reference/ops/op_tensor_scatter.py`\n- `vendor/onnx/onnx/defs/tensor/defs.cc`\n\nKeep the operator's public contract intact. For each batch/prefix coordinate, `write_indices[b]`\nselects the sequence start. In `circular` mode, wrap only the selected sequence coordinate modulo\nthe cache length. Never modulo batch/head prefix coordinates. Preserve untouched cache values,\nupdate ordering, axis normalization, and the existing shape and mode errors. The same sequence-only\nrule must be visible in the C++ operator pseudocode.\n\nRun the real source through the supplied workflow:\n\n```sh\ncd /app\npython3 run_kv_inference.py --input fixtures/kv_cases.json --output /app/output.json\n```\n\nThe output must be deterministic JSON with `output_schema_version` equal to\n`tensor_scatter_inference.v1` and one result for each input case. Do not modify the fixture, runner,\nor supporting source files to bypass the repair.\n"} +{"task_id": "candidate-0803-ml-training", "source_id": "candidate-0803-ml-training", "domain": "terminal", "task_path": "tasks/candidate-0803-ml-training", "docker_image": "docker.io/xiaomimimo/mimo-v2.6-rl-oss@sha256:07630d0920ee4055051a97efb49b681e1dc83b0fe24c10ce2fd2d312ba620741", "step_limit": 500, "agent_timeout_sec": 900.0, "verifier_timeout_sec": 240.0, "instruction": "You are an agent, your current working directory is /app.\n\nYou can use the tools available to you to interact with the computer to assist the user in completing tasks.\n\n# Repair effective-batch normalization\n\nA deterministic language-model training reproduction in `/app/vendor/transformers/tools/effective_batch_case.py` exposes a regression in the existing Trainer label-smoothing path. With gradient accumulation, microbatches can contain different numbers of non-ignored target tokens. Repair the existing framework modules; do not rewrite or bypass the reproduction harness or its local tensor runtime.\n\nRequirements:\n\n1. Trace the call from `Trainer.compute_loss` into `LabelSmoother` and make the effective active-item count available to the smoothing calculation.\n2. Preserve the standalone fallback: when no effective count is supplied, normalization must still use the active non-`-100` labels in that call.\n3. Preserve causal-LM shifting: logits and labels must remain aligned after shifting, while the supplied count is forwarded.\n4. Keep ignored labels out of both NLL and smoothing mass. Do not alter the reproduction inputs or its expected semantics.\n5. Run the existing CPU/offline harness and write its JSON result to `/app/output.json`. The JSON must retain `output_schema_version` equal to `effective_batch.v1` and contain the computed loss, finite-difference gradient, and parameter-update fields produced by the harness.\n\nThe repair is expected to involve the existing `trainer.py` and `trainer_pt_utils.py` modules. The task intentionally uses a small vendored tensor runtime because the execution image has no external ML framework installed. Do not add dependencies, use the network, modify the harness/runtime/tests, or solve by hard-coding the report.\n"} +{"task_id": "candidate-0847-software-languages", "source_id": "candidate-0847-software-languages", "domain": "terminal", "task_path": "tasks/candidate-0847-software-languages", "docker_image": "docker.io/xiaomimimo/mimo-v2.6-rl-oss@sha256:f09a84c006a3e88d6e559f2b6cd46a902bbe1fc5f60ae50b515543ec3c6f2937", "step_limit": 500, "agent_timeout_sec": 900.0, "verifier_timeout_sec": 240.0, "instruction": "You are an agent, your current working directory is /app.\n\nYou can use the tools available to you to interact with the computer to assist the user in completing tasks.\n\n# Repair independent LALR interactive-parser clones\n\nThe frozen Lark tree in `/app/vendor/lark` has a clone-ownership regression. Copying an `InteractiveParser` after partially consuming a source stream creates multiple lexer objects whose references do not agree. A clone may therefore consume the original parser's remaining input, or a superficially independent implementation may leave `parser_state.lexer` disconnected from `lexer_thread`.\n\nRepair the existing implementation in both files:\n\n- `/app/vendor/lark/lark/parsers/lalr_parser_state.py`\n- `/app/vendor/lark/lark/parsers/lalr_interactive_parser.py`\n\n## Required behavior\n\n1. `ParserState.copy(deepcopy_values=...)` must create an independent lexer thread and independent parser stack while preserving its current shallow-versus-deep value-stack policy.\n2. `InteractiveParser.copy(deepcopy_values=...)` must use one coherent cloned lexer thread: the clone's `parser_state.lexer` must be the clone's `lexer_thread`, and neither may be the original parser's lexer thread.\n3. After partially consuming input, clone and original must both be resumable to the same complete parse tree in either execution order. Advancing either continuation must not change the other's cursor.\n4. Existing manual `feed_token`, `exhaust_lexer`, EOF, and ordinary LALR parsing behavior must remain compatible.\n\nDo not replace the parser with a task-specific implementation, hard-code the sample streams, disable tests, or edit the supplied upstream test asset.\n\n## Validation and artifact\n\nFrom `/app/vendor/lark`, run:\n\n```bash\npython3 -m compileall -q lark\npython3 tests/test_parser.py TestLalrBasic.test_parser_interactive_parser -q\n```\n\nThen generate the required artifact:\n\n```bash\ncd /app\npython3 tools/run_clone_matrix.py --output /app/repair_report.json\n```\n\nThe artifact must use `output_schema_version` **`lark-clone-repair-v1`** and the driver must report `summary.all_cases_pass: true` after the source repair.\n\n"} +{"task_id": "candidate-0867-software-frontend", "source_id": "candidate-0867-software-frontend", "domain": "terminal", "task_path": "tasks/candidate-0867-software-frontend", "docker_image": "docker.io/xiaomimimo/mimo-v2.6-rl-oss@sha256:71f6e6d61f5ec8b0134e51456e24d5b32e70f6c7ae567c738c54722b24408cfc", "step_limit": 500, "agent_timeout_sec": 900.0, "verifier_timeout_sec": 240.0, "instruction": "You are an agent, your current working directory is /app.\n\nYou can use the tools available to you to interact with the computer to assist the user in completing tasks.\n\n# Restore reliable file selection\n\nYou are repairing the existing React dropzone source under\n`/app/vendor/project`; do not replace it with a new script or bypass its\nruntime path.\n\nWhen `useFsAccessApi` is enabled, opening the dropzone first uses the browser\nFile System Access picker. Some browsers reject that picker with a\n`DOMException` named `NotAllowedError` even though the API was detected and the\nuser did not cancel. Treat that outcome as an unavailable capability:\n\n1. Extend the shared exception helpers in `src/utils/index.ts` with a precise\n predicate for this failure.\n2. Update the existing picker branch in `src/index.tsx` so this failure is\n handled like the existing security fallback: disable the FS Access path for\n future opens, reset the native input, and click it only after the rejected\n promise. Keep `AbortError` as cancellation and preserve the existing error\n path for unrelated exceptions.\n3. Do not fabricate files. The native input change event must continue through\n the existing extraction, accept/type, size, and `maxFiles` validation and\n callback pipeline.\n\nCheck both files and the surrounding tests before editing. Run the focused\noffline regression contract after the repair:\n\n```sh\ncd /app/vendor/project\npython3 integration/run_regression.py --output /app/output.json\n```\n\nThe command must exit successfully and create `/app/output.json` with the\ncontract's schema and all checks true. Do not install packages or use network\naccess.\n"} +{"task_id": "candidate-0938-science-chemistry", "source_id": "candidate-0938-science-chemistry", "domain": "terminal", "task_path": "tasks/candidate-0938-science-chemistry", "docker_image": "docker.io/xiaomimimo/mimo-v2.6-rl-oss@sha256:1d41382d0752848d54ff88e2cbbf0f7336d041c6001ddee2ae69face1a1d800c", "step_limit": 500, "agent_timeout_sec": 900.0, "verifier_timeout_sec": 240.0, "instruction": "You are an agent, your current working directory is /app.\n\nYou can use the tools available to you to interact with the computer to assist the user in completing tasks.\n\n# Repair the orbital-analysis integration\n\nYou are working in `/app/vendor/project`, a small frozen slice of a computational-chemistry library. The included `data/casebook.json` contains six `ccData` scenarios covering restricted, open-shell, unrestricted, and incomplete molecular-orbital data.\n\nThe integration command is:\n\n```sh\npython3 /app/tools/orbital_check.py --input /app/data/casebook.json --output /app/output.json\n```\n\nRepair the existing library modules under `vendor/project/src/cclib` so this command completes and writes the declared JSON artifact. Preserve the public APIs and use the real `ccData` and `Orbitals` classes.\n\nRequirements:\n- Orbital analysis must reject incomplete data before analysis, identifying each missing required attribute. `mocoeffs`, `moenergies`, and `homos` are all required for `Orbitals`.\n- The closed-shell convenience property must instantiate the public `Orbitals` class and return its computed boolean result.\n- Preserve the scientific behavior: a single MO set with differing HOMO indices is open-shell; two MO sets are closed-shell only when their energy arrays agree within numerical tolerance.\n- Exercise all six cases, inspect the generated JSON, and ensure the schema version is `orbital-report.v1` with one record per input case.\n\nDo not edit the casebook or integration script to hard-code expected answers. Do not add network dependencies or bypass the library source.\n"} +{"task_id": "candidate-0993-software-systems", "source_id": "candidate-0993-software-systems", "domain": "terminal", "task_path": "tasks/candidate-0993-software-systems", "docker_image": "docker.io/xiaomimimo/mimo-v2.6-rl-oss@sha256:7dbdb84be548a95ca247523d3e4cbe7d07294491ed3d33f6c3d30030cae76dc1", "step_limit": 500, "agent_timeout_sec": 900.0, "verifier_timeout_sec": 240.0, "instruction": "You are an agent, your current working directory is /app.\n\nYou can use the tools available to you to interact with the computer to assist the user in completing tasks.\n\n# Repair wheel tag validation\n\nYou are working in a frozen checkout of the Python `packaging` library under\n`/app/vendor/packaging`. A compatibility regression is present at the boundary\nbetween compressed wheel-tag parsing and wheel filename parsing.\n\nRepair the existing production code, rather than adding a parallel evaluator.\nThe public APIs involved are `packaging.tags.parse_tag` and\n`packaging.utils.parse_wheel_filename`.\n\nRequirements:\n\n1. A compressed tag has interpreter, ABI, and platform components. Every\n member of every compressed component must be validated before expansion.\n2. Interpreter members must be valid Python identifiers. Reject a numeric\n dotted value such as `2.7.6` as one malformed interpreter member; do not\n expand it into `2`, `7`, and `6`.\n3. Preserve valid compressed tags such as `py3.py2-none-any`, and preserve\n custom identifier forms such as `graalpy311` and `_custom`.\n4. Direct parsing must expose the existing `InvalidTag` API. Wheel filename\n parsing must translate malformed tag validation into its existing\n `InvalidWheelFilename` API without changing valid filename normalization,\n versions, build tags, or tag sets.\n5. Keep the existing source tree and tests intact. Update the two production\n modules that own this behavior: `src/packaging/tags.py` and\n `src/packaging/utils.py`.\n6. Run the focused regression tests in the repository, compile the package,\n and create `/app/output.json` using the repaired public APIs.\n\nThe output must be JSON with this exact top-level contract:\n\n```json\n{\n \"output_schema_version\": \"packaging-tag-audit.v1\",\n \"cases\": [\n {\n \"name\": \"valid-compressed\",\n \"direct\": {\"status\": \"ok\", \"tag_count\": 2, \"interpreters\": [\"py2\", \"py3\"]},\n \"wheel\": {\"status\": \"ok\", \"name\": \"demo\", \"version\": \"1.0\", \"build\": [], \"tag_count\": 2, \"interpreters\": [\"py2\", \"py3\"]}\n },\n {\n \"name\": \"custom-identifiers\",\n \"direct\": {\"status\": \"ok\", \"tag_count\": 2, \"interpreters\": [\"_custom\", \"graalpy311\"]},\n \"wheel\": {\"status\": \"ok\", \"name\": \"demo\", \"version\": \"1.0\", \"build\": [], \"tag_count\": 2, \"interpreters\": [\"_custom\", \"graalpy311\"]}\n },\n {\n \"name\": \"malformed-interpreter\",\n \"direct\": {\"status\": \"invalid-tag\", \"tag_count\": 0, \"interpreters\": []},\n \"wheel\": {\"status\": \"invalid-wheel\", \"tag_count\": 0, \"interpreters\": []}\n }\n ]\n}\n```\n\nFor the malformed wheel case, use a filename whose tag is\n`2.7.6-none-any`; do not hard-code an answer without exercising both public\nentry points. JSON arrays must be deterministically sorted as shown.\n"} +{"task_id": "candidate-1001-security-forensics", "source_id": "candidate-1001-security-forensics", "domain": "terminal", "task_path": "tasks/candidate-1001-security-forensics", "docker_image": "docker.io/xiaomimimo/mimo-v2.6-rl-oss@sha256:549cd81822ede4b3cfdbd34e5e06f9e34cbc36aed6ee245e2370c8a9064639d9", "step_limit": 500, "agent_timeout_sec": 900.0, "verifier_timeout_sec": 240.0, "instruction": "You are an agent, your current working directory is /app.\n\nYou can use the tools available to you to interact with the computer to assist the user in completing tasks.\n\n# Repair the Windows Registry forensic workflow\n\nThe vendored project under `/app/vendor/plaso` is a pre-fix slice of a Windows Registry forensic parser. A recent input can contain one registry value whose typed decoder raises `dfwinreg.errors.WinRegistryValueError`. Repair the real plugin code, not the runner, so extraction remains useful and the caller integration remains consistent.\n\nRequirements:\n\n1. Update the shared Windows Registry value-formatting helper to receive the parser mediator and handle only the decoder failure represented by `WinRegistryValueError`. The affected value must remain in the formatted event as `[TYPE] (N bytes)`, where `N` is the raw payload length.\n2. Emit exactly one extraction warning for that recovery. The warning must include the value type, value name, registry key path, and decoder error text.\n3. Preserve existing formatting for strings, integers, multi-strings, binary values, and empty values, including their type labels and byte/empty representations.\n4. Update the Services plugin caller to pass the mediator into the shared helper while keeping its skip list. The service event must still be produced with its typed `Start` and `Type` fields and remaining values.\n5. Keep the existing source modules and runner intact. Run the offline integration command:\n\n```sh\ncd /app/vendor/plaso\nPYTHONPATH=/app/vendor/plaso python3 tools/run_case.py /app/output.json\n```\n\nThe output file must be JSON with `output_schema_version` equivalent to `schema_version` `registry-forensics.v1`, two events, one warning, a recovered byte-count value, and the service event fields. Do not use network access or add dependencies.\n"} +{"task_id": "candidate-1005-software-systems", "source_id": "candidate-1005-software-systems", "domain": "terminal", "task_path": "tasks/candidate-1005-software-systems", "docker_image": "docker.io/xiaomimimo/mimo-v2.6-rl-oss@sha256:56b2cf332e1f88c7d2e85b3efa7bcc132fec61717fe8876d693e4d72f11069b0", "step_limit": 500, "agent_timeout_sec": 900.0, "verifier_timeout_sec": 240.0, "instruction": "You are an agent, your current working directory is /app.\n\nYou can use the tools available to you to interact with the computer to assist the user in completing tasks.\n\nA frozen Requests source tree is available at `/app/vendor/requests`.\n\nSome file-like wrappers expose `read` only through `__getattr__`. Runtime protocol checks do not reliably recognize that delegated capability, so request preparation uses inconsistent rules in different branches.\n\nRepair the existing implementation. Your submission must satisfy all of the following:\n\n1. Add one reusable internal predicate in `/app/vendor/requests/src/requests/_types.py` that recognizes an object as readable only when resolving its `read` attribute yields a callable.\n2. Use that predicate consistently in `/app/vendor/requests/src/requests/models.py` for parameter encoding, multipart file-content reading, and the decision not to synthesize `application/x-www-form-urlencoded`.\n3. A wrapper that hides `__iter__` but delegates `read` must remain a raw request body, and request preparation must not add a form content type.\n4. The same delegated wrapper must be read correctly when supplied as a multipart file, for both byte and text streams.\n5. Preserve existing behavior for strings, bytes, `None`, mappings, ordered form pairs, and objects whose `read` attribute exists but is not callable. In particular, mappings must still be form-encoded with their normal content type.\n6. Modify both existing modules named above. Do not replace the Requests package, delete neighboring source/tests, disable checks, or add network/package-install steps.\n7. Compile the two repaired modules and run:\n\n```bash\nPYTHONPATH=/app/vendor/requests/src python3 /app/tools/run_regression.py --output /app/repair_report.json\n```\n\nThe required artifact is `/app/repair_report.json` with `output_schema_version` equal to `requests.stream_proxy.repair.v1` and `passed` equal to `true`. The verifier also imports and exercises the repaired source independently; a forged report is insufficient.\n"} +{"task_id": "candidate-1048-operations-virtualization", "source_id": "candidate-1048-operations-virtualization", "domain": "terminal", "task_path": "tasks/candidate-1048-operations-virtualization", "docker_image": "docker.io/xiaomimimo/mimo-v2.6-rl-oss@sha256:529269bf9f03ab9cf9c1ceeb75fb243f8ba906c6854ea19fdae42ec0ddc47a59", "step_limit": 500, "agent_timeout_sec": 900.0, "verifier_timeout_sec": 240.0, "instruction": "You are an agent, your current working directory is /app.\n\nYou can use the tools available to you to interact with the computer to assist the user in completing tasks.\n\nThe vendored Vagrant VirtualBox provider has a regression in private-network\nconfiguration. Repair the existing provider source, preserving its public\nAPIs and version-specific VBoxManage parsing.\n\nA private network's `name` may be either the stable host-only interface name or\nthe display name reported by VBoxManage. Make the common network action resolve\nthe display form to the canonical interface name before adapter setup. Ensure\nthe legacy driver parsers and the VirtualBox 7 host-only-network adapter expose\nthe same normalized `display_name` field while retaining their native address,\nmask, IPv6, and status behavior. The generic action must use the portable\nhost-only interface inventory; the host-only-network inventory is only a\nDarwin/VirtualBox-7 implementation detail. Keep the shared driver facade's\ndelegation surface synchronized with the versioned inventory APIs.\n\nCanonical interface names must continue to resolve unchanged. An unknown name\nmust remain unknown rather than selecting the first available interface.\n\nWork directly in the existing files under `vendor/vagrant`. Do not add a\nreplacement evaluator or hard-code the fixture's interface name. The vendored\nupstream tests are available for code-reading context, but do not install gems\nor attempt the full upstream suite. Finish by running:\n\n```sh\npython3 /app/contract_runner.py > /app/contract_result.json\n```\n\nThe command must succeed offline and leave the declared artifact at that exact\npath. The JSON artifact must declare\n`output_schema_version = \"vagrant.virtualbox.network-contract.v1\"` and report the\ncross-version inventories, the three name-resolution outcomes, portable API\ncall counts, Meta delegation status, and the sorted result-key list produced by\nthe supplied runner.\n"} +{"task_id": "candidate-1155-software-systems", "source_id": "candidate-1155-software-systems", "domain": "terminal", "task_path": "tasks/candidate-1155-software-systems", "docker_image": "docker.io/xiaomimimo/mimo-v2.6-rl-oss@sha256:b69825011aa7bc37ee9e9564fa42a581f5f4621aff19455b6a3b7286ad12ced9", "step_limit": 500, "agent_timeout_sec": 900.0, "verifier_timeout_sec": 240.0, "instruction": "You are an agent, your current working directory is /app.\n\nYou can use the tools available to you to interact with the computer to assist the user in completing tasks.\n\n# Repair configurable routing behavior\n\nThe workspace contains a frozen source tree for a Python URL-routing library and `routing_workflow.py`. Diagnose and repair the routing implementation in the vendored source tree, then run:\n\n```sh\npython3 /app/routing_workflow.py\n```\n\nThe runner must create `/app/output.json` with `output_schema_version` set to `werkzeug-routing-repair-v1`.\n\nThe public `Map.merge_slashes` setting controls whether repeated separators in a request are canonicalized to a redirect. It must work both when supplied at construction and when changed on an existing map. A rule-level opt-out must continue to reject the normalized spelling while accepting its literal spelling. Preserve strict-trailing-slash redirects, integer conversion, path converters (including repeated separators inside a variable), host binding, and URL building.\n\nWork only in the vendored library source. Do not replace the runner or hard-code its JSON, remove tests or source modules, install packages, access the network, or rely on external services.\n"} +{"task_id": "candidate-1165-ml-evaluation", "source_id": "candidate-1165-ml-evaluation", "domain": "terminal", "task_path": "tasks/candidate-1165-ml-evaluation", "docker_image": "docker.io/xiaomimimo/mimo-v2.6-rl-oss@sha256:5bdaefdf97293fca3f552b581ee9ce96c42c0d1d3a3c54a88748fe285c43a08e", "step_limit": 500, "agent_timeout_sec": 900.0, "verifier_timeout_sec": 240.0, "instruction": "You are an agent, your current working directory is /app.\n\nYou can use the tools available to you to interact with the computer to assist the user in completing tasks.\n\n# Repair the evaluation metric boundary\n\nThe workspace contains a frozen slice of a Hugging Face Evaluate repository\nunder `/app/vendor/project`. Its precision, recall, and F1 metric scripts call\nscikit-learn and then normalize the returned score for downstream JSON\nserialization. With current scikit-learn, binary averages can return a native\nPython scalar while per-label (`average=None`) calls return an array. The\nexisting normalization assumes every result has the same array API.\n\nRepair the existing metric modules so the integration runner works for every\ncase in `/app/cases.json` and for unseen case manifests supplied by the\nverifier. Keep sklearn's metric values and options intact: binary and other\naggregate averages must serialize as a Python `float`, while `average=None`\nmust remain an ordered per-label array. Apply the compatibility boundary\nconsistently to `metrics/f1/f1.py`, `metrics/precision/precision.py`, and\n`metrics/recall/recall.py`.\n\nRun the integration command:\n\n```sh\npython3 /app/run_metrics.py --input /app/cases.json --output /app/output.json\n```\n\nThe output must be exactly one JSON object with `schema_version`\n`ml-eval-output.v1` and a `results` array in input order. Each row contains its\ncase `id` and `f1`, `precision`, and `recall` values (a number or an array).\nDo not add dependencies, access the network, or replace the vendored metric\nimplementations with a new evaluator.\n"} +{"task_id": "candidate-1216-software-frontend", "source_id": "candidate-1216-software-frontend", "domain": "terminal", "task_path": "tasks/candidate-1216-software-frontend", "docker_image": "docker.io/xiaomimimo/mimo-v2.6-rl-oss@sha256:d2c208c7f2b8c183b142ee8e900d10baf2fa7c778a785c227eeaf818fde5a176", "step_limit": 500, "agent_timeout_sec": 900.0, "verifier_timeout_sec": 240.0, "instruction": "You are an agent, your current working directory is /app.\n\nYou can use the tools available to you to interact with the computer to assist the user in completing tasks.\n\n# Repair bundled development runtime ordering\n\nWork in `/app/vendor/vite`. The frozen source implements an experimental bundled\ndevelopment mode, but its client runtime is currently attached at the wrong layer.\n\nRepair the existing production source so all of these behaviors hold:\n\n1. Define one exported canonical filename for the bundled development client in the\n shared node constants module, and use it consistently for both the built client entry\n path and the in-memory server filename.\n2. During `serve` for a bundled **client** environment, generated HTML must contain a\n `