[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"similar-openai--human-eval":3,"tool-openai--human-eval":65},[4,17,27,35,43,56],{"id":5,"name":6,"github_repo":7,"description_zh":8,"stars":9,"difficulty_score":10,"last_commit_at":11,"category_tags":12,"status":16},1381,"everything-claude-code","affaan-m\u002Feverything-claude-code","everything-claude-code 是一套专为 AI 编程助手（如 Claude Code、Codex、Cursor 等）打造的高性能优化系统。它不仅仅是一组配置文件，而是一个经过长期实战打磨的完整框架，旨在解决 AI 代理在实际开发中面临的效率低下、记忆丢失、安全隐患及缺乏持续学习能力等核心痛点。\n\n通过引入技能模块化、直觉增强、记忆持久化机制以及内置的安全扫描功能，everything-claude-code 能显著提升 AI 在复杂任务中的表现，帮助开发者构建更稳定、更智能的生产级 AI 代理。其独特的“研究优先”开发理念和针对 Token 消耗的优化策略，使得模型响应更快、成本更低，同时有效防御潜在的攻击向量。\n\n这套工具特别适合软件开发者、AI 研究人员以及希望深度定制 AI 工作流的技术团队使用。无论您是在构建大型代码库，还是需要 AI 协助进行安全审计与自动化测试，everything-claude-code 都能提供强大的底层支持。作为一个曾荣获 Anthropic 黑客大奖的开源项目，它融合了多语言支持与丰富的实战钩子（hooks），让 AI 真正成长为懂上",160784,2,"2026-04-19T11:32:54",[13,14,15],"开发框架","Agent","语言模型","ready",{"id":18,"name":19,"github_repo":20,"description_zh":21,"stars":22,"difficulty_score":23,"last_commit_at":24,"category_tags":25,"status":16},4487,"LLMs-from-scratch","rasbt\u002FLLMs-from-scratch","LLMs-from-scratch 是一个基于 PyTorch 的开源教育项目，旨在引导用户从零开始一步步构建一个类似 ChatGPT 的大型语言模型（LLM）。它不仅是同名技术著作的官方代码库，更提供了一套完整的实践方案，涵盖模型开发、预训练及微调的全过程。\n\n该项目主要解决了大模型领域“黑盒化”的学习痛点。许多开发者虽能调用现成模型，却难以深入理解其内部架构与训练机制。通过亲手编写每一行核心代码，用户能够透彻掌握 Transformer 架构、注意力机制等关键原理，从而真正理解大模型是如何“思考”的。此外，项目还包含了加载大型预训练权重进行微调的代码，帮助用户将理论知识延伸至实际应用。\n\nLLMs-from-scratch 特别适合希望深入底层原理的 AI 开发者、研究人员以及计算机专业的学生。对于不满足于仅使用 API，而是渴望探究模型构建细节的技术人员而言，这是极佳的学习资源。其独特的技术亮点在于“循序渐进”的教学设计：将复杂的系统工程拆解为清晰的步骤，配合详细的图表与示例，让构建一个虽小但功能完备的大模型变得触手可及。无论你是想夯实理论基础，还是为未来研发更大规模的模型做准备",90106,3,"2026-04-06T11:19:32",[15,26,14,13],"图像",{"id":28,"name":29,"github_repo":30,"description_zh":31,"stars":32,"difficulty_score":10,"last_commit_at":33,"category_tags":34,"status":16},8553,"spec-kit","github\u002Fspec-kit","Spec Kit 是一款专为提升软件开发效率而设计的开源工具包，旨在帮助团队快速落地“规格驱动开发”（Spec-Driven Development）模式。传统开发中，需求文档往往与代码实现脱节，导致沟通成本高且结果不可控；而 Spec Kit 通过将规格说明书转化为可执行的指令，让 AI 直接依据明确的业务场景生成高质量代码，从而减少从零开始的随意编码，确保产出结果的可预测性。\n\n该工具特别适合希望利用 AI 辅助编程的开发者、技术负责人及初创团队。无论是启动全新项目还是在现有工程中引入规范化流程，用户只需通过简单的命令行操作，即可初始化项目并集成主流的 AI 编程助手。其核心技术亮点在于“规格即代码”的理念，支持社区扩展与预设模板，允许用户根据特定技术栈定制开发流程。此外，Spec Kit 强调官方维护的安全性，提供稳定的版本管理，帮助开发者在享受 AI 红利的同时，依然牢牢掌握架构设计的主动权，真正实现从“凭感觉写代码”到“按规格建系统”的转变。",88749,"2026-04-17T09:48:14",[15,26,14,13],{"id":36,"name":37,"github_repo":38,"description_zh":39,"stars":40,"difficulty_score":10,"last_commit_at":41,"category_tags":42,"status":16},3704,"NextChat","ChatGPTNextWeb\u002FNextChat","NextChat 是一款轻量且极速的 AI 助手，旨在为用户提供流畅、跨平台的大模型交互体验。它完美解决了用户在多设备间切换时难以保持对话连续性，以及面对众多 AI 模型不知如何统一管理的痛点。无论是日常办公、学习辅助还是创意激发，NextChat 都能让用户随时随地通过网页、iOS、Android、Windows、MacOS 或 Linux 端无缝接入智能服务。\n\n这款工具非常适合普通用户、学生、职场人士以及需要私有化部署的企业团队使用。对于开发者而言，它也提供了便捷的自托管方案，支持一键部署到 Vercel 或 Zeabur 等平台。\n\nNextChat 的核心亮点在于其广泛的模型兼容性，原生支持 Claude、DeepSeek、GPT-4 及 Gemini Pro 等主流大模型，让用户在一个界面即可自由切换不同 AI 能力。此外，它还率先支持 MCP（Model Context Protocol）协议，增强了上下文处理能力。针对企业用户，NextChat 提供专业版解决方案，具备品牌定制、细粒度权限控制、内部知识库整合及安全审计等功能，满足公司对数据隐私和个性化管理的高标准要求。",87618,"2026-04-05T07:20:52",[13,15],{"id":44,"name":45,"github_repo":46,"description_zh":47,"stars":48,"difficulty_score":10,"last_commit_at":49,"category_tags":50,"status":16},2268,"ML-For-Beginners","microsoft\u002FML-For-Beginners","ML-For-Beginners 是由微软推出的一套系统化机器学习入门课程，旨在帮助零基础用户轻松掌握经典机器学习知识。这套课程将学习路径规划为 12 周，包含 26 节精炼课程和 52 道配套测验，内容涵盖从基础概念到实际应用的完整流程，有效解决了初学者面对庞大知识体系时无从下手、缺乏结构化指导的痛点。\n\n无论是希望转型的开发者、需要补充算法背景的研究人员，还是对人工智能充满好奇的普通爱好者，都能从中受益。课程不仅提供了清晰的理论讲解，还强调动手实践，让用户在循序渐进中建立扎实的技能基础。其独特的亮点在于强大的多语言支持，通过自动化机制提供了包括简体中文在内的 50 多种语言版本，极大地降低了全球不同背景用户的学习门槛。此外，项目采用开源协作模式，社区活跃且内容持续更新，确保学习者能获取前沿且准确的技术资讯。如果你正寻找一条清晰、友好且专业的机器学习入门之路，ML-For-Beginners 将是理想的起点。",85267,"2026-04-18T11:00:28",[26,51,52,53,14,54,15,13,55],"数据工具","视频","插件","其他","音频",{"id":57,"name":58,"github_repo":59,"description_zh":60,"stars":61,"difficulty_score":62,"last_commit_at":63,"category_tags":64,"status":16},5784,"funNLP","fighting41love\u002FfunNLP","funNLP 是一个专为中文自然语言处理（NLP）打造的超级资源库，被誉为\"NLP 民工的乐园”。它并非单一的软件工具，而是一个汇集了海量开源项目、数据集、预训练模型和实用代码的综合性平台。\n\n面对中文 NLP 领域资源分散、入门门槛高以及特定场景数据匮乏的痛点，funNLP 提供了“一站式”解决方案。这里不仅涵盖了分词、命名实体识别、情感分析、文本摘要等基础任务的标准工具，还独特地收录了丰富的垂直领域资源，如法律、医疗、金融行业的专用词库与数据集，甚至包含古诗词生成、歌词创作等趣味应用。其核心亮点在于极高的全面性与实用性，从基础的字典词典到前沿的 BERT、GPT-2 模型代码，再到高质量的标注数据和竞赛方案，应有尽有。\n\n无论是刚刚踏入 NLP 领域的学生、需要快速验证想法的算法工程师，还是从事人工智能研究的学者，都能在这里找到急需的“武器弹药”。对于开发者而言，它能大幅减少寻找数据和复现模型的时间；对于研究者，它提供了丰富的基准测试资源和前沿技术参考。funNLP 以开放共享的精神，极大地降低了中文自然语言处理的开发与研究成本，是中文 AI 社区不可或缺的宝藏仓库。",79857,1,"2026-04-08T20:11:31",[15,51,54],{"id":66,"github_repo":67,"name":68,"description_en":69,"description_zh":70,"ai_summary_zh":70,"readme_en":71,"readme_zh":72,"quickstart_zh":73,"use_case_zh":74,"hero_image_url":75,"owner_login":76,"owner_name":77,"owner_avatar_url":78,"owner_bio":79,"owner_company":80,"owner_location":80,"owner_email":80,"owner_twitter":80,"owner_website":81,"owner_url":82,"languages":83,"stars":88,"forks":89,"last_commit_at":90,"license":91,"difficulty_score":10,"env_os":92,"env_gpu":92,"env_ram":93,"env_deps":94,"category_tags":98,"github_topics":80,"view_count":10,"oss_zip_url":80,"oss_zip_packed_at":80,"status":16,"created_at":99,"updated_at":100,"faqs":101,"releases":131},9746,"openai\u002Fhuman-eval","human-eval","Code for the paper \"Evaluating Large Language Models Trained on Code\"","HumanEval 是一套专为评估大语言模型代码生成能力而设计的开源测试框架，源自 OpenAI 关于代码训练模型评估的著名论文。它核心解决了一个关键问题：如何客观、量化地判断 AI 写的代码是否真正“能跑通”且逻辑正确，而不仅仅是看起来像代码。\n\n这套工具提供了一个包含 164 个手工编写编程问题的数据集，每个问题都配有完善的单元测试。用户只需让模型针对这些问题生成代码补全，HumanEval 即可在安全沙箱中自动执行这些代码并运行测试，最终输出 pass@k 等指标（如 pass@1、pass@10），直观反映模型在不同采样次数下的成功率。其独特的技术亮点在于严谨的功能性正确性验证机制，以及对执行安全的高度重视，默认禁用危险执行操作以提醒用户构建隔离环境。\n\nHumanEval 非常适合 AI 研究人员、大模型开发者以及需要基准测试来对比不同代码模型性能的技术团队使用。对于希望深入理解或复现代码大模型评估流程的从业者来说，它是目前业界公认的标准工具之一，能帮助开发者从“写得像”迈向“写得对”的实质性评估阶段。","# HumanEval: Hand-Written Evaluation Set \n\nThis is an evaluation harness for the HumanEval problem solving dataset\ndescribed in the paper \"[Evaluating Large Language Models Trained on\nCode](https:\u002F\u002Farxiv.org\u002Fabs\u002F2107.03374)\".\n\n## Installation\n\nMake sure to use python 3.7 or later:\n```\n$ conda create -n codex python=3.7\n$ conda activate codex\n```\n\nCheck out and install this repository:\n```\n$ git clone https:\u002F\u002Fgithub.com\u002Fopenai\u002Fhuman-eval\n$ pip install -e human-eval\n```\n\n## Usage\n\n**This program exists to run untrusted model-generated code. Users are strongly\nencouraged not to do so outside of a robust security sandbox. The [execution\ncall](https:\u002F\u002Fgithub.com\u002Fopenai\u002Fhuman-eval\u002Fblob\u002Fmaster\u002Fhuman_eval\u002Fexecution.py#L48-L58)\nin `execution.py` is deliberately commented out to ensure users read this\ndisclaimer before running code in a potentially unsafe manner. See the comment in\n`execution.py` for more information and instructions.**\n\nAfter following the above instructions to enable execution, generate samples\nand save them in the following JSON Lines (jsonl) format, where each sample is\nformatted into a single line like so:\n```\n{\"task_id\": \"Corresponding HumanEval task ID\", \"completion\": \"Completion only without the prompt\"}\n```\nWe provide `example_problem.jsonl` and `example_solutions.jsonl` under `data`\nto illustrate the format and help with debugging.\n\nHere is nearly functional example code (you just have to provide\n`generate_one_completion` to make it work) that saves generated completions to\n`samples.jsonl`.\n```\nfrom human_eval.data import write_jsonl, read_problems\n\nproblems = read_problems()\n\nnum_samples_per_task = 200\nsamples = [\n    dict(task_id=task_id, completion=generate_one_completion(problems[task_id][\"prompt\"]))\n    for task_id in problems\n    for _ in range(num_samples_per_task)\n]\nwrite_jsonl(\"samples.jsonl\", samples)\n```\n\nTo evaluate the samples, run\n```\n$ evaluate_functional_correctness samples.jsonl\nReading samples...\n32800it [00:01, 23787.50it\u002Fs]\nRunning test suites...\n100%|...| 32800\u002F32800 [16:11\u003C00:00, 33.76it\u002Fs]\nWriting results to samples.jsonl_results.jsonl...\n100%|...| 32800\u002F32800 [00:00\u003C00:00, 42876.84it\u002Fs]\n{'pass@1': ..., 'pass@10': ..., 'pass@100': ...}\n```\nThis script provides more fine-grained information in a new file ending in\n`\u003Cinput_path>_results.jsonl`. Each row now contains whether the completion\n`passed` along with the execution `result` which is one of \"passed\", \"timed\nout\", or \"failed\".\n\nAs a quick sanity-check, the example samples should yield 0.5 pass@1.\n```\n$ evaluate_functional_correctness data\u002Fexample_samples.jsonl --problem_file=data\u002Fexample_problem.jsonl\nReading samples...\n6it [00:00, 3397.11it\u002Fs]\nRunning example suites...\n100%|...| 6\u002F6 [00:03\u003C00:00,  1.96it\u002Fs]\nWriting results to data\u002Fexample_samples.jsonl_results.jsonl...\n100%|...| 6\u002F6 [00:00\u003C00:00, 6148.50it\u002Fs]\n{'pass@1': 0.4999999999999999}\n```\n\nBecause there is no unbiased way of estimating pass@k when there are fewer\nsamples than k, the script does not evaluate pass@k for these cases. To\nevaluate with other k values, pass `--k=\u003Ccomma-separated-values-here>`. For\nother options, see\n```\n$ evaluate_functional_correctness --help\n```\nHowever, we recommend that you use the default values for the rest.\n\n## Known Issues\n\nWhile evaluation uses very little memory, you might see the following error\nmessage when the system is running out of RAM. Since this may cause some\ncorrect programs to fail, we recommend that you free some memory and try again.\n```\nmalloc: can't allocate region\n```\n\n## Citation\n\nPlease cite using the following bibtex entry:\n\n```\n@article{chen2021codex,\n  title={Evaluating Large Language Models Trained on Code},\n  author={Mark Chen and Jerry Tworek and Heewoo Jun and Qiming Yuan and Henrique Ponde de Oliveira Pinto and Jared Kaplan and Harri Edwards and Yuri Burda and Nicholas Joseph and Greg Brockman and Alex Ray and Raul Puri and Gretchen Krueger and Michael Petrov and Heidy Khlaaf and Girish Sastry and Pamela Mishkin and Brooke Chan and Scott Gray and Nick Ryder and Mikhail Pavlov and Alethea Power and Lukasz Kaiser and Mohammad Bavarian and Clemens Winter and Philippe Tillet and Felipe Petroski Such and Dave Cummings and Matthias Plappert and Fotios Chantzis and Elizabeth Barnes and Ariel Herbert-Voss and William Hebgen Guss and Alex Nichol and Alex Paino and Nikolas Tezak and Jie Tang and Igor Babuschkin and Suchir Balaji and Shantanu Jain and William Saunders and Christopher Hesse and Andrew N. Carr and Jan Leike and Josh Achiam and Vedant Misra and Evan Morikawa and Alec Radford and Matthew Knight and Miles Brundage and Mira Murati and Katie Mayer and Peter Welinder and Bob McGrew and Dario Amodei and Sam McCandlish and Ilya Sutskever and Wojciech Zaremba},\n  year={2021},\n  eprint={2107.03374},\n  archivePrefix={arXiv},\n  primaryClass={cs.LG}\n}\n```\n","# HumanEval：人工编写的评估集\n\n这是用于评估论文《[评估基于代码训练的大语言模型](https:\u002F\u002Farxiv.org\u002Fabs\u002F2107.03374)》中描述的 HumanEval 问题求解数据集的评估工具。\n\n## 安装\n\n请确保使用 Python 3.7 或更高版本：\n```\n$ conda create -n codex python=3.7\n$ conda activate codex\n```\n\n克隆并安装此仓库：\n```\n$ git clone https:\u002F\u002Fgithub.com\u002Fopenai\u002Fhuman-eval\n$ pip install -e human-eval\n```\n\n## 使用说明\n\n**本程序旨在运行不受信任的模型生成代码。强烈建议用户仅在强大的安全沙箱环境中执行此类操作。`execution.py` 中的 [执行调用](https:\u002F\u002Fgithub.com\u002Fopenai\u002Fhuman-eval\u002Fblob\u002Fmaster\u002Fhuman_eval\u002Fexecution.py#L48-L58) 已被故意注释掉，以确保用户在可能不安全的情况下运行代码之前阅读此免责声明。更多信息和操作指南请参阅 `execution.py` 中的注释。**\n\n按照上述说明启用执行功能后，生成样本并将其保存为以下 JSON Lines (jsonl) 格式，其中每个样本都格式化为一行，如下所示：\n```\n{\"task_id\": \"对应的 HumanEval 任务 ID\", \"completion\": \"仅完成部分，不含提示\"}\n```\n我们在 `data` 目录下提供了 `example_problem.jsonl` 和 `example_solutions.jsonl`，以展示格式并帮助调试。\n\n以下是一个几乎可用的示例代码（只需提供 `generate_one_completion` 函数即可运行），它会将生成的完成内容保存到 `samples.jsonl` 文件中。\n```\nfrom human_eval.data import write_jsonl, read_problems\n\nproblems = read_problems()\n\nnum_samples_per_task = 200\nsamples = [\n    dict(task_id=task_id, completion=generate_one_completion(problems[task_id][\"prompt\"]))\n    for task_id in problems\n    for _ in range(num_samples_per_task)\n]\nwrite_jsonl(\"samples.jsonl\", samples)\n```\n\n要评估这些样本，请运行：\n```\n$ evaluate_functional_correctness samples.jsonl\n读取样本...\n32800it [00:01, 23787.50it\u002Fs]\n运行测试套件...\n100%|...| 32800\u002F32800 [16:11\u003C00:00, 33.76it\u002Fs]\n将结果写入 samples.jsonl_results.jsonl...\n100%|...| 32800\u002F32800 [00:00\u003C00:00, 42876.84it\u002Fs]\n{'pass@1': ..., 'pass@10': ..., 'pass@100': ...}\n```\n\n该脚本会在以 `\u003Cinput_path>_results.jsonl` 结尾的新文件中提供更细粒度的信息。每行现在包含完成是否“通过”以及执行结果，执行结果可能是“通过”、“超时”或“失败”。\n\n作为快速验证，示例样本应得到 0.5 的 pass@1 值。\n```\n$ evaluate_functional_correctness data\u002Fexample_samples.jsonl --problem_file=data\u002Fexample_problem.jsonl\n读取样本...\n6it [00:00, 3397.11it\u002Fs]\n运行示例套件...\n100%|...| 6\u002F6 [00:03\u003C00:00,  1.96it\u002Fs]\n将结果写入 data\u002Fexample_samples.jsonl_results.jsonl...\n100%|...| 6\u002F6 [00:00\u003C00:00, 6148.50it\u002Fs]\n{'pass@1': 0.4999999999999999}\n```\n\n由于当样本数量少于 k 时，无法无偏估计 pass@k，因此脚本不会对这些情况计算 pass@k。若要使用其他 k 值进行评估，可传递 `--k=\u003C逗号分隔的值>` 参数。有关其他选项，请参阅：\n```\n$ evaluate_functional_correctness --help\n```\n\n不过，我们仍建议您使用默认值。\n\n## 已知问题\n\n尽管评估过程占用内存极少，但在系统内存不足时，您可能会看到以下错误信息。由于这可能导致一些正确的程序失败，我们建议您释放一些内存后再重试。\n```\nmalloc: can't allocate region\n```\n\n## 引用\n\n请使用以下 BibTeX 条目进行引用：\n\n```\n@article{chen2021codex,\n  title={Evaluating Large Language Models Trained on Code},\n  author={Mark Chen and Jerry Tworek and Heewoo Jun and Qiming Yuan and Henrique Ponde de Oliveira Pinto and Jared Kaplan and Harri Edwards and Yuri Burda and Nicholas Joseph and Greg Brockman and Alex Ray and Raul Puri and Gretchen Krueger and Michael Petrov and Heidy Khlaaf and Girish Sastry and Pamela Mishkin and Brooke Chan and Scott Gray and Nick Ryder and Mikhail Pavlov and Alethea Power and Lukasz Kaiser and Mohammad Bavarian and Clemens Winter and Philippe Tillet and Felipe Petroski Such and Dave Cummings and Matthias Plappert and Fotios Chantzis and Elizabeth Barnes and Ariel Herbert-Voss and William Hebgen Guss and Alex Nichol and Alex Paino and Nikolas Tezak and Jie Tang and Igor Babuschkin and Suchir Balaji and Shantanu Jain and William Saunders and Christopher Hesse and Andrew N. Carr and Jan Leike and Josh Achiam and Vedant Misra and Evan Morikawa and Alec Radford and Matthew Knight and Miles Brundage and Mira Murati and Katie Mayer and Peter Welinder and Bob McGrew and Dario Amodei and Sam McCandlish and Ilya Sutskever and Wojciech Zaremba},\n  year={2021},\n  eprint={2107.03374},\n  archivePrefix={arXiv},\n  primaryClass={cs.LG}\n}\n```","# HumanEval 快速上手指南\n\nHumanEval 是用于评估大语言模型代码生成能力的基准测试工具集，源自论文《Evaluating Large Language Models Trained on Code》。本指南帮助开发者快速搭建环境并运行评估。\n\n## 环境准备\n\n- **操作系统**：Linux \u002F macOS \u002F Windows (WSL 推荐)\n- **Python 版本**：3.7 或更高\n- **依赖管理**：推荐使用 `conda` 或 `pip`\n- **网络要求**：需访问 GitHub 和 PyPI（国内用户可配置镜像源加速）\n\n> 💡 国内加速建议：\n> - Conda: 使用清华源 `https:\u002F\u002Fmirrors.tuna.tsinghua.edu.cn\u002Fanaconda\u002Fpkgs\u002Fmain\u002F`\n> - Pip: 使用阿里云源 `https:\u002F\u002Fmirrors.aliyun.com\u002Fpypi\u002Fsimple\u002F`\n\n## 安装步骤\n\n1. 创建并激活 Python 虚拟环境（以 conda 为例）：\n```bash\n$ conda create -n codex python=3.7\n$ conda activate codex\n```\n\n2. 克隆仓库并安装工具包：\n```bash\n$ git clone https:\u002F\u002Fgithub.com\u002Fopenai\u002Fhuman-eval\n$ pip install -e human-eval\n```\n> 国内用户可使用镜像加速克隆：\n> ```bash\n> $ git clone https:\u002F\u002Fgitee.com\u002Fmirror\u002Fhuman-eval.git  # 示例镜像，实际请替换为可用源\n> ```\n\n## 基本使用\n\n### 1. 生成模型输出样本\n\n将你的模型生成的代码补全结果保存为 JSON Lines 格式（`.jsonl`），每行一个样本：\n\n```json\n{\"task_id\": \"HumanEval\u002F0\", \"completion\": \"def add(a, b):\\n    return a + b\"}\n```\n\n参考示例文件位于 `data\u002Fexample_problem.jsonl` 和 `data\u002Fexample_solutions.jsonl`。\n\n以下是一个生成样本的示例脚本（需实现 `generate_one_completion` 函数）：\n\n```python\nfrom human_eval.data import write_jsonl, read_problems\n\nproblems = read_problems()\n\nnum_samples_per_task = 200\nsamples = [\n    dict(task_id=task_id, completion=generate_one_completion(problems[task_id][\"prompt\"]))\n    for task_id in problems\n    for _ in range(num_samples_per_task)\n]\nwrite_jsonl(\"samples.jsonl\", samples)\n```\n\n### 2. 执行功能正确性评估\n\n运行评估命令：\n\n```bash\n$ evaluate_functional_correctness samples.jsonl\n```\n\n输出示例：\n```\nReading samples...\n32800it [00:01, 23787.50it\u002Fs]\nRunning test suites...\n100%|...| 32800\u002F32800 [16:11\u003C00:00, 33.76it\u002Fs]\nWriting results to samples.jsonl_results.jsonl...\n{'pass@1': 0.35, 'pass@10': 0.62, 'pass@100': 0.89}\n```\n\n评估结果将保存至 `samples.jsonl_results.jsonl`，包含每个样本的执行状态（passed \u002F failed \u002F timed out）。\n\n### 3. 快速验证（可选）\n\n使用内置示例数据进行 sanity check：\n\n```bash\n$ evaluate_functional_correctness data\u002Fexample_samples.jsonl --problem_file=data\u002Fexample_problem.jsonl\n```\n\n预期输出 `pass@1` 接近 `0.5`。\n\n> ⚠️ 安全提示：本工具会执行模型生成的代码，请务必在隔离沙箱环境中运行，避免安全风险。默认情况下执行代码已被注释，请仔细阅读 `human_eval\u002Fexecution.py` 中的说明后再启用。","某 AI 初创团队正在研发一款专用于生成 Python 算法代码的大模型，急需在发布前量化评估其代码生成的功能正确性。\n\n### 没有 human-eval 时\n- **缺乏统一标尺**：团队只能自行拼凑少量测试题，评估标准不一，无法与业界顶尖模型（如 Codex）进行公平对比。\n- **人工验证低效**：依靠工程师肉眼阅读生成的代码或手动运行脚本，面对数千个生成样本时耗时极长且容易出错。\n- **指标维度单一**：仅能统计“代码是否跑通”，难以科学计算 pass@k（如 pass@10, pass@100）等反映模型采样多样性的关键指标。\n- **执行风险不可控**：直接在本地运行模型生成的未知代码，缺乏沙箱隔离机制，极易导致宿主机环境被恶意代码破坏。\n\n### 使用 human-eval 后\n- **对标行业标准**：直接复用包含 164 道手写难题的 HumanEval 数据集，确保评估结果具有权威性和可复现性，便于横向竞品分析。\n- **自动化批量评测**：通过 `evaluate_functional_correctness` 命令一键运行数万条测试用例，分钟级输出详细的通过率报告，效率提升百倍。\n- **多维深度洞察**：自动计算并输出 pass@1、pass@10 等多粒度指标，精准定位模型在不同采样策略下的真实性能边界。\n- **安全沙箱执行**：内置受控的代码执行机制（需配置沙箱），在保障系统安全的前提下自动判断代码是“通过”、“超时”还是“失败”。\n\nhuman-eval 将原本模糊主观的代码能力评估，转化为了一套安全、高效且国际通用的量化基准体系。","https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fopenai_human-eval_ec43d7a3.png","openai","OpenAI","https:\u002F\u002Foss.gittoolsai.com\u002Favatars\u002Fopenai_1960bbf4.png","",null,"https:\u002F\u002Fopenai.com\u002F","https:\u002F\u002Fgithub.com\u002Fopenai",[84],{"name":85,"color":86,"percentage":87},"Python","#3572A5",100,3205,441,"2026-04-18T14:29:12","MIT","未说明","未说明（已知问题中提到若系统内存不足可能导致评估失败，建议释放内存后重试）",{"notes":95,"python":96,"dependencies":97},"该工具用于运行模型生成的不可信代码，强烈建议在健壮的安全沙箱环境中运行。默认情况下执行代码的功能被注释掉，用户需手动启用并阅读相关安全免责声明。评估过程本身内存占用很低，但若系统 RAM 耗尽可能会导致正确程序运行失败。","3.7+",[92],[15,54],"2026-03-27T02:49:30.150509","2026-04-20T04:06:06.279212",[102,107,112,117,122,126],{"id":103,"question_zh":104,"answer_zh":105,"source_url":106},43768,"安装 human-eval 包时出现 'Invalid script entry point' 错误怎么办？","这是一个已知的 setup.py 配置问题。解决方法是手动修改项目根目录下的 `setup.py` 文件，找到 `entry_points` 部分，将 `evaluate_functional_correctness` 的入口点从 `None` 改为 `main`。\n\n修改前的代码：\n`\"evaluate_functional_correctness = human_eval.evaluate_functional_correctness:None\"`\n\n修改后的代码：\n```python\nentry_points={\n    \"console_scripts\": [\n        \"evaluate_functional_correctness = human_eval.evaluate_functional_correctness:main\",\n    ]\n}\n```\n修改后重新运行 `pip install -e .` 即可解决。","https:\u002F\u002Fgithub.com\u002Fopenai\u002Fhuman-eval\u002Fissues\u002F58",{"id":108,"question_zh":109,"answer_zh":110,"source_url":111},43769,"在 Windows 系统上运行 evaluate_functional_correctness 报错或卡住如何解决？","Windows 用户需要执行以下步骤：\n1. 重新安装 `multiprocess` 库：`pip install multiprocess`。\n2. 打开 `human_eval\u002Fexecution.py` 文件，将所有的 `import multiprocessing` 替换为 `import multiprocess as multiprocessing`。\n3. 确保调用脚本的主入口包含 `if __name__ == \"__main__\":` 保护。\n4. 如果需要处理超时逻辑，由于 Windows 不支持 `signal.alarm`，需将 `time_limit` 函数修改为使用 `threading.Timer` 实现：\n```python\nimport threading\nimport contextlib\n\nclass TimeoutException(Exception):\n    pass\n\n@contextlib.contextmanager\ndef time_limit(seconds: float):\n    timer = threading.Timer(seconds, lambda: (_ for _ in ()).throw(TimeoutException(\"Timed out!\")))\n    timer.start()\n    try:\n        yield\n    finally:\n        timer.cancel()\n```","https:\u002F\u002Fgithub.com\u002Fopenai\u002Fhuman-eval\u002Fissues\u002F18",{"id":113,"question_zh":114,"answer_zh":115,"source_url":116},43770,"HumanEval 评估中使用的具体 Prompt 格式是什么？","作者构建了一个新的 Prompt，并未直接完全沿用 APPS 基准测试的原始 Prompt。具体的 Prompt 模板如下：\n\n```text\n# Language: Python 3\n# Task: Synthesize program\n\n\"\"\"\nContains programming exercises for single functions specified by their\ndoc-strings and with solutions in simple code and with a lot of comments\nthat explain what is done and why and how it is related to the specification.\n\"\"\"\n\n# Example 1.\n\n\"\"\"\nGiven an array of integers, find if the array contains any duplicates.\n\nYour function should return true if any value appears at least twice in the array, and\n it should return false if every element is distinct.\n\n-----Input-----\n\nThe first line contains a list of integers.\n\n\n-----Output-----\n\nOutput true if there are duplicates and false otherwise.\n\n-----Examples-----\nInput\n[1,2,3,1]\n\nOutput\ntrue\n\nInput\n[1,2,3,4]\n\nOutput\nfalse\n\nInput\n[1,1,1,3,3,4,3,2,4,2]\n\nOutput\ntrue\n\n\"\"\"\n\n# So\n```\n该模板包含语言声明、任务描述、通用说明以及一个带有输入输出示例的具体案例，用于引导模型生成代码。","https:\u002F\u002Fgithub.com\u002Fopenai\u002Fhuman-eval\u002Fissues\u002F11",{"id":118,"question_zh":119,"answer_zh":120,"source_url":121},43771,"为什么我在 macOS 或新环境中安装时仍然遇到 entry point 错误？","这是因为官方仓库的 `setup.py` 文件在某些版本中未正确指定入口函数。即使是在 macOS 或全新的虚拟环境中，如果直接克隆仓库运行 `pip install -e .`，仍可能报错 `invalid console script`。\n\n解决方案与 Windows\u002FLinux 相同：必须手动编辑 `setup.py`，明确指定入口点为 `main` 函数：\n```python\nentry_points={\n    \"console_scripts\": [\n        \"evaluate_functional_correctness = human_eval.evaluate_functional_correctness:main\",\n    ]\n}\n```\n保存后重新安装即可。","https:\u002F\u002Fgithub.com\u002Fopenai\u002Fhuman-eval\u002Fissues\u002F12",{"id":123,"question_zh":124,"answer_zh":125,"source_url":111},43772,"如何在 Linux 机器上正确实现代码执行的超时限制（time_limit）？","在 Linux 机器上，推荐使用 `signal` 模块来实现精确的超时控制。请在 `human_eval\u002Fexecution.py` 或相关文件中将 `time_limit` 上下文管理器实现为：\n\n```python\nimport signal\nimport contextlib\n\nclass TimeoutException(Exception):\n    pass\n\n@contextlib.contextmanager\ndef time_limit(seconds: float):\n    def signal_handler(signum, frame):\n        raise TimeoutException(\"Timed out!\")\n    \n    signal.setitimer(signal.ITIMER_REAL, seconds)\n    signal.signal(signal.SIGALRM, signal_handler)\n    try:\n        yield\n    finally:\n        signal.setitimer(signal.ITIMER_REAL, 0)\n```\n注意：此方法仅适用于类 Unix 系统（Linux\u002FmacOS），Windows 用户请使用 threading 方案。",{"id":127,"question_zh":128,"answer_zh":129,"source_url":130},43773,"复现 GPT-Neo 在 HumanEval 上的结果远低于论文报告值，有什么技巧吗？","根据社区讨论，原始 GPT-Neo 模型（125M 和 1.3B）在 HumanEval 数据集上的表现确实可能显著低于 Codex 论文中报告的结果。这通常是因为 Codex 经过了专门的代码数据微调和提示工程优化，而原始 GPT-Neo 没有。\n\n目前 Issue 中尚未给出官方的具体复现技巧或修正后的基准数据。建议检查以下几点：\n1. 确保使用的 Prompt 格式与 HumanEval 官方推荐的一致（参考相关问答）。\n2. 确认采样参数（如 temperature, top_p）是否与实验设置一致。\n3. 注意是否需要对模型进行特定的代码领域微调才能达到论文效果。","https:\u002F\u002Fgithub.com\u002Fopenai\u002Fhuman-eval\u002Fissues\u002F8",[]]