sde-bench
收藏资源简介:
sde-bench 是一个用于评估记忆系统对编码代理帮助的基准数据集。该数据集包含61个基于真实代码库(boltons 库)的 bug 修复任务,每个任务都依赖于一个非可猜测的、项目特定的决策:明显的修复虽然能通过可见的复现测试,但会在隐藏测试中失败,因为项目先前已决定该明显修复违反了规则。该决策存在于仓库的 git 历史(28个任务)、过去的开发者对话(27个任务)或对话的后续修订(6个任务,跨对话合并测试)中。数据集通过机器验证确保每个任务具有区分性:当前版本(HEAD)同时失败复现测试和隐藏测试,正确修复通过所有测试,而两种合理的朴素修复均通过复现测试但失败隐藏测试——因此无法通过猜测通过,只能通过知识通过。数据集包含两个配置:tasks(每个任务一行,包含身份、来源、层级、类别、面向代理的 bug 报告、决策材料(对话或决策主题/理由)、评分测试(回归测试、隐藏测试及通过/失败文件列表)以及实例化字段)和decoys(140个逼真的、无策略的开发者对话,用作每个任务记忆语料库中的检索噪声)。注意:隐藏测试仅用于评分,绝不能提供给代理或其记忆系统。数据集采用 MIT 许可证。
sde-bench is a benchmark dataset for evaluating the assistance of memory systems to coding agents. This dataset contains 61 bug-fixing tasks based on the real-world codebase (boltons library). Each task relies on a non-guessable, project-specific decision: the obvious fix can pass visible reproduction tests but fails hidden tests, as the project had previously ruled that this obvious fix violates its rules. This decision is sourced from the repository's git history (28 tasks), past developer conversations (27 tasks), or subsequent revisions of conversations (6 tasks, cross-dialog merge tests). The dataset is machine-verified to ensure each task is discriminatory: the current HEAD revision fails both reproduction tests and hidden tests, the correct fix passes all tests, while two plausible naive fixes both pass reproduction tests but fail hidden tests — thus the task cannot be solved by guessing but only by leveraging domain knowledge. The dataset includes two configurations: "tasks" (one task per line, containing identity, source, level, category, agent-facing bug reports, decision materials (conversations or decision topics/reasons), scoring tests (regression tests, hidden tests, and lists of passing/failing files), and instantiation fields) and "decoys" (140 realistic, unstrategic developer conversations that serve as retrieval noise in the memory corpus for each task). Note: Hidden tests are only used for scoring and must never be provided to the agent or its memory system. The dataset is licensed under the MIT License.
数据集概述:sde-bench
sde-bench 是一个用于评估编码智能体(coding agent)在借助记忆系统时能否解决真实代码库中 bug 修复任务的基准测试集。该数据集包含 61 个 bug 修复任务,每个任务都围绕一个不可猜测、项目特定的决策展开:表面明显的修复能通过可见的复现测试,但会因违反项目历史决策而无法通过隐藏测试。正确答案的信息存储在仓库的 git 历史(28 个任务)、过去的开发者对话(27 个任务)或后续修订的对话(6 个任务,属于跨聊天整合测试)中。该基准用于衡量记忆系统能否可靠地提取并利用这些关键决策信息。
数据文件与配置
该数据集包含两个配置:
tasks(默认配置,文件tasks.jsonl):每个任务一行,包含任务标识与维度(source、tier、category)、面向智能体的bug_report、决策材料(conversations或decision_subject/decision_rationale)、评估测试(regression_test、hidden_test及通过/失败文件列表),以及物化字段(host_repo/host_ref、head_module_source)。decoys(文件decoys.jsonl):包含 140 条现实的、无特定策略的开发者对话,用作每个任务记忆语料库中的检索噪声。
重要提示:hidden_test 仅供评分使用,绝不能提供给智能体或其记忆系统。
任务设计与验证
每个任务均经过机器验证,具备判别性:
- HEAD 版本同时失败于复现测试和隐藏测试;
- 正确修复能通过所有测试;
- 两个合理的朴素修复能通过复现测试但失败于隐藏测试。
因此,猜测无法通过,只有真正知晓项目决策才能通过。
快速开始
使用 Hugging Face datasets 库加载:
python from datasets import load_dataset tasks = load_dataset("vectorize-io/sde-bench", "tasks", split="train") decoys = load_dataset("vectorize-io/sde-bench", "decoys", split="train")
若要实际运行基准测试(构建任务仓库、驱动智能体、在 Docker 中评分、统计修正次数),请使用配套运行器 agent-memory-benchmark:
bash uv run amb run --dataset sdebench --split boltons --mode coding --memory vanilla uv run amb run --dataset sdebench --split boltons --mode coding --memory hindsight-coding
相关资源
- 规范仓库(可执行任务、生成器、验证器):https://github.com/vectorize-io/sde-bench
- 运行器 / 测试框架 / 智能体 / 评分:https://github.com/vectorize-io/agent-memory-benchmark
- 宿主支架:boltons @
979fa9b(来自 mahmoud/boltons 的分支,BSD 许可,未修改使用)
许可证
MIT 许可证(覆盖 sde-bench 内容——陷阱、植入模块、测试、对话、诱饵及本卡片)。宿主支架 boltons 版权归 Mahmoud Hashemi 所有,采用 BSD-3-Clause 许可,未被修改使用。



