[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"similar-declare-lab--instruct-eval":3,"tool-declare-lab--instruct-eval":61},[4,18,26,36,44,53],{"id":5,"name":6,"github_repo":7,"description_zh":8,"stars":9,"difficulty_score":10,"last_commit_at":11,"category_tags":12,"status":17},4358,"openclaw","openclaw\u002Fopenclaw","OpenClaw 是一款专为个人打造的本地化 AI 助手，旨在让你在自己的设备上拥有完全可控的智能伙伴。它打破了传统 AI 助手局限于特定网页或应用的束缚，能够直接接入你日常使用的各类通讯渠道，包括微信、WhatsApp、Telegram、Discord、iMessage 等数十种平台。无论你在哪个聊天软件中发送消息，OpenClaw 都能即时响应，甚至支持在 macOS、iOS 和 Android 设备上进行语音交互，并提供实时的画布渲染功能供你操控。\n\n这款工具主要解决了用户对数据隐私、响应速度以及“始终在线”体验的需求。通过将 AI 部署在本地，用户无需依赖云端服务即可享受快速、私密的智能辅助，真正实现了“你的数据，你做主”。其独特的技术亮点在于强大的网关架构，将控制平面与核心助手分离，确保跨平台通信的流畅性与扩展性。\n\nOpenClaw 非常适合希望构建个性化工作流的技术爱好者、开发者，以及注重隐私保护且不愿被单一生态绑定的普通用户。只要具备基础的终端操作能力（支持 macOS、Linux 及 Windows WSL2），即可通过简单的命令行引导完成部署。如果你渴望拥有一个懂你",349277,3,"2026-04-06T06:32:30",[13,14,15,16],"Agent","开发框架","图像","数据工具","ready",{"id":19,"name":20,"github_repo":21,"description_zh":22,"stars":23,"difficulty_score":10,"last_commit_at":24,"category_tags":25,"status":17},3808,"stable-diffusion-webui","AUTOMATIC1111\u002Fstable-diffusion-webui","stable-diffusion-webui 是一个基于 Gradio 构建的网页版操作界面，旨在让用户能够轻松地在本地运行和使用强大的 Stable Diffusion 图像生成模型。它解决了原始模型依赖命令行、操作门槛高且功能分散的痛点，将复杂的 AI 绘图流程整合进一个直观易用的图形化平台。\n\n无论是希望快速上手的普通创作者、需要精细控制画面细节的设计师，还是想要深入探索模型潜力的开发者与研究人员，都能从中获益。其核心亮点在于极高的功能丰富度：不仅支持文生图、图生图、局部重绘（Inpainting）和外绘（Outpainting）等基础模式，还独创了注意力机制调整、提示词矩阵、负向提示词以及“高清修复”等高级功能。此外，它内置了 GFPGAN 和 CodeFormer 等人脸修复工具，支持多种神经网络放大算法，并允许用户通过插件系统无限扩展能力。即使是显存有限的设备，stable-diffusion-webui 也提供了相应的优化选项，让高质量的 AI 艺术创作变得触手可及。",162132,"2026-04-05T11:01:52",[14,15,13],{"id":27,"name":28,"github_repo":29,"description_zh":30,"stars":31,"difficulty_score":32,"last_commit_at":33,"category_tags":34,"status":17},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 真正成长为懂上",146793,2,"2026-04-08T23:32:35",[14,13,35],"语言模型",{"id":37,"name":38,"github_repo":39,"description_zh":40,"stars":41,"difficulty_score":32,"last_commit_at":42,"category_tags":43,"status":17},2271,"ComfyUI","Comfy-Org\u002FComfyUI","ComfyUI 是一款功能强大且高度模块化的视觉 AI 引擎，专为设计和执行复杂的 Stable Diffusion 图像生成流程而打造。它摒弃了传统的代码编写模式，采用直观的节点式流程图界面，让用户通过连接不同的功能模块即可构建个性化的生成管线。\n\n这一设计巧妙解决了高级 AI 绘图工作流配置复杂、灵活性不足的痛点。用户无需具备编程背景，也能自由组合模型、调整参数并实时预览效果，轻松实现从基础文生图到多步骤高清修复等各类复杂任务。ComfyUI 拥有极佳的兼容性，不仅支持 Windows、macOS 和 Linux 全平台，还广泛适配 NVIDIA、AMD、Intel 及苹果 Silicon 等多种硬件架构，并率先支持 SDXL、Flux、SD3 等前沿模型。\n\n无论是希望深入探索算法潜力的研究人员和开发者，还是追求极致创作自由度的设计师与资深 AI 绘画爱好者，ComfyUI 都能提供强大的支持。其独特的模块化架构允许社区不断扩展新功能，使其成为当前最灵活、生态最丰富的开源扩散模型工具之一，帮助用户将创意高效转化为现实。",108111,"2026-04-08T11:23:26",[14,15,13],{"id":45,"name":46,"github_repo":47,"description_zh":48,"stars":49,"difficulty_score":32,"last_commit_at":50,"category_tags":51,"status":17},4721,"markitdown","microsoft\u002Fmarkitdown","MarkItDown 是一款由微软 AutoGen 团队打造的轻量级 Python 工具，专为将各类文件高效转换为 Markdown 格式而设计。它支持 PDF、Word、Excel、PPT、图片（含 OCR）、音频（含语音转录）、HTML 乃至 YouTube 链接等多种格式的解析，能够精准提取文档中的标题、列表、表格和链接等关键结构信息。\n\n在人工智能应用日益普及的今天，大语言模型（LLM）虽擅长处理文本，却难以直接读取复杂的二进制办公文档。MarkItDown 恰好解决了这一痛点，它将非结构化或半结构化的文件转化为模型“原生理解”且 Token 效率极高的 Markdown 格式，成为连接本地文件与 AI 分析 pipeline 的理想桥梁。此外，它还提供了 MCP（模型上下文协议）服务器，可无缝集成到 Claude Desktop 等 LLM 应用中。\n\n这款工具特别适合开发者、数据科学家及 AI 研究人员使用，尤其是那些需要构建文档检索增强生成（RAG）系统、进行批量文本分析或希望让 AI 助手直接“阅读”本地文件的用户。虽然生成的内容也具备一定可读性，但其核心优势在于为机器",93400,"2026-04-06T19:52:38",[52,14],"插件",{"id":54,"name":55,"github_repo":56,"description_zh":57,"stars":58,"difficulty_score":10,"last_commit_at":59,"category_tags":60,"status":17},4487,"LLMs-from-scratch","rasbt\u002FLLMs-from-scratch","LLMs-from-scratch 是一个基于 PyTorch 的开源教育项目，旨在引导用户从零开始一步步构建一个类似 ChatGPT 的大型语言模型（LLM）。它不仅是同名技术著作的官方代码库，更提供了一套完整的实践方案，涵盖模型开发、预训练及微调的全过程。\n\n该项目主要解决了大模型领域“黑盒化”的学习痛点。许多开发者虽能调用现成模型，却难以深入理解其内部架构与训练机制。通过亲手编写每一行核心代码，用户能够透彻掌握 Transformer 架构、注意力机制等关键原理，从而真正理解大模型是如何“思考”的。此外，项目还包含了加载大型预训练权重进行微调的代码，帮助用户将理论知识延伸至实际应用。\n\nLLMs-from-scratch 特别适合希望深入底层原理的 AI 开发者、研究人员以及计算机专业的学生。对于不满足于仅使用 API，而是渴望探究模型构建细节的技术人员而言，这是极佳的学习资源。其独特的技术亮点在于“循序渐进”的教学设计：将复杂的系统工程拆解为清晰的步骤，配合详细的图表与示例，让构建一个虽小但功能完备的大模型变得触手可及。无论你是想夯实理论基础，还是为未来研发更大规模的模型做准备",90106,"2026-04-06T11:19:32",[35,15,13,14],{"id":62,"github_repo":63,"name":64,"description_en":65,"description_zh":66,"ai_summary_zh":66,"readme_en":67,"readme_zh":68,"quickstart_zh":69,"use_case_zh":70,"hero_image_url":71,"owner_login":72,"owner_name":73,"owner_avatar_url":74,"owner_bio":75,"owner_company":76,"owner_location":76,"owner_email":76,"owner_twitter":76,"owner_website":77,"owner_url":78,"languages":79,"stars":84,"forks":85,"last_commit_at":86,"license":87,"difficulty_score":10,"env_os":88,"env_gpu":89,"env_ram":90,"env_deps":91,"category_tags":97,"github_topics":98,"view_count":32,"oss_zip_url":76,"oss_zip_packed_at":76,"status":17,"created_at":101,"updated_at":102,"faqs":103,"releases":139},5775,"declare-lab\u002Finstruct-eval","instruct-eval","This repository contains code to quantitatively evaluate instruction-tuned models such as Alpaca and Flan-T5 on held-out tasks. ","instruct-eval 是一个专为评估指令微调大语言模型（如 Alpaca、Flan-T5 等）而设计的开源评测框架。它旨在解决当前业界难以对各类指令模型进行统一、定量比较的痛点，帮助开发者在未见过的复杂任务中准确衡量模型的泛化能力。\n\n相较于现有的评测库，instruct-eval 的最大亮点在于其便捷性与广泛的兼容性。它支持直接调用 Hugging Face Transformers 中的多种主流架构（包括因果语言模型和序列到序列模型），让用户能够轻松地在多个学术基准（如 MMLU、BBH）上运行测试。此外，该项目不仅提供了详细的排行榜和论文支持，还不断扩展评估维度，近期更引入了针对模型安全性的\"Red-Eval\"基准以及考察写作能力的\"IMPACT\"数据集，实现了从性能到安全的全方位 holistic 评估。\n\n这款工具非常适合 AI 研究人员、大模型开发者以及需要验证模型效果的技术团队使用。如果你正在寻找一种简单高效的方法来对比不同指令微调模型的表现，或者希望深入探索模型在特定领域的边界能力，instruct-eval 将是一个专业且实用的选择。","## :camel: 🍮 📚 InstructEval: Towards Holistic Evaluation of Instruction-Tuned Large Language Models\n\n[Paper](https:\u002F\u002Farxiv.org\u002Fabs\u002F2306.04757) | [Model](https:\u002F\u002Fhuggingface.co\u002Fdeclare-lab\u002Fflan-alpaca-gpt4-xl) | [Leaderboard](https:\u002F\u002Fdeclare-lab.github.io\u002Finstruct-eval\u002F)\n\n\u003Cp align=\"center\">\n  \u003Cimg src=\"https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fdeclare-lab_instruct-eval_readme_93f0b6ded071.png\" alt=\"\" width=\"300\" height=\"300\">\n\u003C\u002Fp>\n\n> 🔥 If you are interested in IQ testing LLMs, check out our new work: [AlgoPuzzleVQA](https:\u002F\u002Fgithub.com\u002Fdeclare-lab\u002Fpuzzle-reasoning)\n\n> 📣 Introducing Resta: **Safety Re-alignment of Language Models**. [**Paper**](https:\u002F\u002Farxiv.org\u002Fabs\u002F2402.11746) [**Github**](https:\u002F\u002Fgithub.com\u002Fdeclare-lab\u002Fresta)\n\n> 📣 **Red-Eval**, the benchmark for **Safety** Evaluation of LLMs has been added: [Red-Eval](https:\u002F\u002Fgithub.com\u002Fdeclare-lab\u002Finstruct-eval\u002Ftree\u002Fmain\u002Fred-eval)\n\n> 📣 Introducing **Red-Eval** to evaluate the safety of the LLMs using several jailbreaking prompts. With **Red-Eval** one could jailbreak\u002Fred-team GPT-4 with a 65.1% attack success rate and ChatGPT could be jailbroken 73% of the time as measured on DangerousQA and HarmfulQA benchmarks. More details are here: [Code](https:\u002F\u002Fgithub.com\u002Fdeclare-lab\u002Fred-instruct) and [Paper](https:\u002F\u002Farxiv.org\u002Fabs\u002F2308.09662).\n\n> 📣 We developed Flacuna by fine-tuning Vicuna-13B on the Flan collection. Flacuna is better than Vicuna at problem-solving. Access the model here [https:\u002F\u002Fhuggingface.co\u002Fdeclare-lab\u002Fflacuna-13b-v1.0](https:\u002F\u002Fhuggingface.co\u002Fdeclare-lab\u002Fflacuna-13b-v1.0).\n\n> 📣 The [**InstructEval**](https:\u002F\u002Fdeclare-lab.net\u002Finstruct-eval\u002F) benchmark and leaderboard have been released. \n\n> 📣 The paper reporting Instruction Tuned LLMs on the **InstructEval** benchmark suite has been released on Arxiv. Read it here: [https:\u002F\u002Farxiv.org\u002Fpdf\u002F2306.04757.pdf](https:\u002F\u002Farxiv.org\u002Fpdf\u002F2306.04757.pdf)\n\n> 📣 We are releasing **IMPACT**, a dataset for evaluating the writing capability of LLMs in four aspects: Informative, Professional, Argumentative, and Creative. Download it from Huggingface: [https:\u002F\u002Fhuggingface.co\u002Fdatasets\u002Fdeclare-lab\u002FInstructEvalImpact](https:\u002F\u002Fhuggingface.co\u002Fdatasets\u002Fdeclare-lab\u002FInstructEvalImpact). \n\n> 📣 **FLAN-T5** is also useful in text-to-audio generation. Find our work\nat [https:\u002F\u002Fgithub.com\u002Fdeclare-lab\u002Ftango](https:\u002F\u002Fgithub.com\u002Fdeclare-lab\u002Ftango) if you are interested.\n\nThis repository contains code to evaluate instruction-tuned models such as Alpaca and Flan-T5 on held-out\ntasks.\nWe aim to facilitate simple and convenient benchmarking across multiple tasks and models.\n\n### Why?\n\nInstruction-tuned models such as [Flan-T5](https:\u002F\u002Farxiv.org\u002Fabs\u002F2210.11416)\nand [Alpaca](https:\u002F\u002Fcrfm.stanford.edu\u002F2023\u002F03\u002F13\u002Falpaca.html) represent an exciting direction to approximate the\nperformance of large language models (LLMs) like ChatGPT at lower cost.\nHowever, it is challenging to compare the performance of different models qualitatively.\nTo evaluate how well the models generalize across a wide range of unseen and challenging tasks, we can use academic\nbenchmarks such as [MMLU](https:\u002F\u002Farxiv.org\u002Fabs\u002F2009.03300) and [BBH](https:\u002F\u002Farxiv.org\u002Fabs\u002F2210.09261).\nCompared to existing libraries such as [evaluation-harness](https:\u002F\u002Fgithub.com\u002FEleutherAI\u002Flm-evaluation-harness)\nand [HELM](https:\u002F\u002Fgithub.com\u002Fstanford-crfm\u002Fhelm), this repo enables simple and convenient evaluation for multiple\nmodels.\nNotably, we support most models from HuggingFace Transformers 🤗 (check [here](.\u002Fdocs\u002Fmodels.md) for a list of models we support):\n\n- [AutoModelForCausalLM](https:\u002F\u002Fhuggingface.co\u002Fdocs\u002Ftransformers\u002Fmodel_doc\u002Fauto#transformers.AutoModelForCausalLM) (\n  eg [GPT-2](https:\u002F\u002Fhuggingface.co\u002Fgpt2-xl), [GPT-J](https:\u002F\u002Fhuggingface.co\u002FEleutherAI\u002Fgpt-j-6b)\n  , [OPT-IML](https:\u002F\u002Fhuggingface.co\u002Ffacebook\u002Fopt-iml-max-1.3b), [BLOOMZ](https:\u002F\u002Fhuggingface.co\u002Fbigscience\u002Fbloomz-7b1))\n- [AutoModelForSeq2SeqLM](https:\u002F\u002Fhuggingface.co\u002Fdocs\u002Ftransformers\u002Fmodel_doc\u002Fauto#transformers.AutoModelForSeq2SeqLM) (\n  eg [Flan-T5](https:\u002F\u002Fhuggingface.co\u002Fgoogle\u002Fflan-t5-xl), [Flan-UL2](https:\u002F\u002Fhuggingface.co\u002Fgoogle\u002Fflan-ul2)\n  , [TK-Instruct](https:\u002F\u002Fhuggingface.co\u002Fallenai\u002Ftk-instruct-3b-def))\n- [LlamaForCausalLM](https:\u002F\u002Fhuggingface.co\u002Fdocs\u002Ftransformers\u002Fmain\u002Fmodel_doc\u002Fllama#transformers.LlamaForCausalLM) (\n  eg [LLaMA](https:\u002F\u002Fhuggingface.co\u002Fdecapoda-research\u002Fllama-7b-hf)\n  , [Alpaca](https:\u002F\u002Fhuggingface.co\u002Fchavinlo\u002Falpaca-native), [Vicuna](https:\u002F\u002Fhuggingface.co\u002Fchavinlo\u002Fvicuna))\n- [ChatGLM](https:\u002F\u002Fhuggingface.co\u002FTHUDM\u002Fchatglm-6b)\n\n### Results\n\nFor detailed results, please go to our [leaderboard](https:\u002F\u002Fdeclare-lab.net\u002Finstruct-eval\u002F)\n\n| Model Name | Model Path                                                                                                              | Paper                                                                                                         | Size | MMLU | BBH  | DROP | HumanEval |\n|------------|-------------------------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------|------|------|------|------|-----------|\n|            | [GPT-4](https:\u002F\u002Fopenai.com\u002Fproduct\u002Fgpt-4)                                                                               | [Link](https:\u002F\u002Farxiv.org\u002Fabs\u002F2303.08774)                                                                      | ?    | 86.4 |      | 80.9 | 67.0      |\n|            | [ChatGPT](https:\u002F\u002Fopenai.com\u002Fblog\u002Fchatgpt)                                                                              | [Link](https:\u002F\u002Farxiv.org\u002Fabs\u002F2303.08774)                                                                      | ?    | 70.0 |      | 64.1 | 48.1      |\n| seq_to_seq | [google\u002Fflan-t5-xxl](https:\u002F\u002Fhuggingface.co\u002Fgoogle\u002Fflan-t5-xxl)                                                         | [Link](https:\u002F\u002Farxiv.org\u002Fabs\u002F2210.11416)                                                                      | 11B  | 54.5 | 43.9 |      |           |\n| seq_to_seq | [google\u002Fflan-t5-xl](https:\u002F\u002Fhuggingface.co\u002Fgoogle\u002Fflan-t5-xl)                                                           | [Link](https:\u002F\u002Farxiv.org\u002Fabs\u002F2210.11416)                                                                      | 3B   | 49.2 | 40.2 | 56.3 |           |\n| llama      | [eachadea\u002Fvicuna-13b](https:\u002F\u002Fhuggingface.co\u002Feachadea\u002Fvicuna-13b)                                                       | [Link](https:\u002F\u002Fvicuna.lmsys.org\u002F)                                                                             | 13B  | 49.7 | 37.1 | 32.9 | 15.2      |\n| llama      | [decapoda-research\u002Fllama-13b-hf](https:\u002F\u002Fhuggingface.co\u002Fdecapoda-research\u002Fllama-13b-hf)                                 | [Link](https:\u002F\u002Farxiv.org\u002Fabs\u002F2302.13971)                                                                      | 13B  | 46.2 | 37.1 | 35.3 | 13.4      |\n| seq_to_seq | [declare-lab\u002Fflan-alpaca-gpt4-xl](https:\u002F\u002Fhuggingface.co\u002Fdeclare-lab\u002Fflan-alpaca-gpt4-xl)                               | [Link](https:\u002F\u002Fgithub.com\u002Fdeclare-lab\u002Fflan-alpaca)                                                            | 3B   | 45.6 | 34.8 |      |           |\n| llama      | [TheBloke\u002Fkoala-13B-HF](https:\u002F\u002Fhuggingface.co\u002FTheBloke\u002Fkoala-13B-HF)                                                   | [Link](https:\u002F\u002Fbair.berkeley.edu\u002Fblog\u002F2023\u002F04\u002F03\u002Fkoala\u002F)                                                      | 13B  | 44.6 | 34.6 | 28.3 | 11.0      |\n| llama      | [chavinlo\u002Falpaca-native](https:\u002F\u002Fhuggingface.co\u002Fchavinlo\u002Falpaca-native)                                                 | [Link](https:\u002F\u002Fcrfm.stanford.edu\u002F2023\u002F03\u002F13\u002Falpaca.html)                                                      | 7B   | 41.6 | 33.3 | 26.3 | 10.3      |\n| llama      | [TheBloke\u002FwizardLM-7B-HF](https:\u002F\u002Fhuggingface.co\u002FTheBloke\u002FwizardLM-7B-HF)                                               | [Link](https:\u002F\u002Farxiv.org\u002Fabs\u002F2304.12244)                                                                      | 7B   | 36.4 | 32.9 |      | 15.2      |\n| chatglm    | [THUDM\u002Fchatglm-6b](https:\u002F\u002Fhuggingface.co\u002FTHUDM\u002Fchatglm-6b)                                                             | [Link](https:\u002F\u002Farxiv.org\u002Fabs\u002F2210.02414)                                                                      | 6B   | 36.1 | 31.3 | 44.2 | 3.1       |\n| llama      | [decapoda-research\u002Fllama-7b-hf](https:\u002F\u002Fhuggingface.co\u002Fdecapoda-research\u002Fllama-7b-hf)                                   | [Link](https:\u002F\u002Farxiv.org\u002Fabs\u002F2302.13971)                                                                      | 7B   | 35.2 | 30.9 | 27.6 | 10.3      |\n| llama      | [wombat-7b-gpt4-delta](https:\u002F\u002Fhuggingface.co\u002FGanjinZero\u002Fwombat-7b-gpt4-delta)                                          | [Link](https:\u002F\u002Farxiv.org\u002Fabs\u002F2304.05302)                                                                      | 7B   | 33.0 | 32.4 |      | 7.9       |\n| seq_to_seq | [bigscience\u002Fmt0-xl](https:\u002F\u002Fhuggingface.co\u002Fbigscience\u002Fmt0-xl)                                                           | [Link](https:\u002F\u002Farxiv.org\u002Fabs\u002F2210.11416)                                                                      | 3B   | 30.4 |      |      |           |\n| causal     | [facebook\u002Fopt-iml-max-1.3b](https:\u002F\u002Fhuggingface.co\u002Ffacebook\u002Fopt-iml-max-1.3b)                                           | [Link](https:\u002F\u002Farxiv.org\u002Fabs\u002F2212.12017)                                                                      | 1B   | 27.5 |      |      | 1.8       |\n| causal     | [OpenAssistant\u002Foasst-sft-4-pythia-12b-epoch-3.5](https:\u002F\u002Fhuggingface.co\u002FOpenAssistant\u002Foasst-sft-4-pythia-12b-epoch-3.5) | [Link](https:\u002F\u002Fgithub.com\u002FLAION-AI\u002FOpen-Assistant)                                                            | 12B  | 27.0 | 30.0 |      | 9.1       |\n| causal     | [stabilityai\u002Fstablelm-base-alpha-7b](https:\u002F\u002Fhuggingface.co\u002Fstabilityai\u002Fstablelm-base-alpha-7b)                         | [Link](https:\u002F\u002Fgithub.com\u002FStability-AI\u002FStableLM)                                                              | 7B   | 26.2 |      |      | 1.8       |\n| causal     | [databricks\u002Fdolly-v2-12b](https:\u002F\u002Fhuggingface.co\u002Fdatabricks\u002Fdolly-v2-12b)                                               | [Link](https:\u002F\u002Fwww.databricks.com\u002Fblog\u002F2023\u002F04\u002F12\u002Fdolly-first-open-commercially-viable-instruction-tuned-llm) | 12B  | 25.7 |      |      | 7.9       |\n| causal     | [Salesforce\u002Fcodegen-6B-mono](https:\u002F\u002Fhuggingface.co\u002FSalesforce\u002Fcodegen-6B-mono)                                         | [Link](https:\u002F\u002Farxiv.org\u002Fabs\u002F2203.13474)                                                                      | 6B   |      |      |      | 27.4      |\n  | causal     | [togethercomputer\u002FRedPajama-INCITE-Instruct-7B-v0.1](https:\u002F\u002Fhuggingface.co\u002Ftogethercomputer\u002FRedPajama-INCITE-Instruct-7B-v0.1) | [Link](https:\u002F\u002Fgithub.com\u002Ftogethercomputer\u002FRedPajama-Data)                                                             | 7B   | 38.1 | 31.3 | 24.7 | 5.5      |\n\n### Example Usage\n\nEvaluate on [Massive Multitask Language Understanding](https:\u002F\u002Fhuggingface.co\u002Fdatasets\u002Flukaemon\u002Fmmlu) (MMLU) which\nincludes exam questions from 57 tasks such as mathematics, history, law, and medicine.\nWe use 5-shot direct prompting and measure the exact-match score.\n\n```\npython main.py mmlu --model_name llama --model_path chavinlo\u002Falpaca-native\n# 0.4163936761145136\n\npython main.py mmlu --model_name seq_to_seq --model_path google\u002Fflan-t5-xl \n# 0.49252243270189433\n```\n\nEvaluate on [Big Bench Hard](https:\u002F\u002Fhuggingface.co\u002Fdatasets\u002Flukaemon\u002Fbbh) (BBH) which includes 23 challenging tasks for\nwhich PaLM (540B) performs below an average human rater.\nWe use 3-shot direct prompting and measure the exact-match score.\n\n```\npython main.py bbh --model_name llama --model_path TheBloke\u002Fkoala-13B-HF --load_8bit\n# 0.3468942926723247\n```\n\nEvaluate on [DROP](https:\u002F\u002Fhuggingface.co\u002Fdatasets\u002Fdrop) which is a math question answering benchmark.\nWe use 3-shot direct prompting and measure the exact-match score.\n\n```\npython main.py drop --model_name seq_to_seq --model_path google\u002Fflan-t5-xl \n# 0.5632458233890215\n```\n\nEvaluate on [HumanEval](https:\u002F\u002Fhuggingface.co\u002Fdatasets\u002Fopenai_humaneval) which includes 164 coding questions in python.\nWe use 0-shot direct prompting and measure the pass@1 score.\n\n```\npython main.py humaneval  --model_name llama --model_path eachadea\u002Fvicuna-13b --n_sample 1 --load_8bit\n# {'pass@1': 0.1524390243902439}\n```\n\n### Setup\n\nInstall dependencies and download data.\n\n```\nconda create -n instruct-eval python=3.8 -y\nconda activate instruct-eval\npip install -r requirements.txt\nmkdir -p data\nwget https:\u002F\u002Fpeople.eecs.berkeley.edu\u002F~hendrycks\u002Fdata.tar -O data\u002Fmmlu.tar\ntar -xf data\u002Fmmlu.tar -C data && mv data\u002Fdata data\u002Fmmlu\n```\n\n","## :camel: 🍮 📚 InstructEval：迈向指令微调大型语言模型的全面评估\n\n[论文](https:\u002F\u002Farxiv.org\u002Fabs\u002F2306.04757) | [模型](https:\u002F\u002Fhuggingface.co\u002Fdeclare-lab\u002Fflan-alpaca-gpt4-xl) | [排行榜](https:\u002F\u002Fdeclare-lab.github.io\u002Finstruct-eval\u002F)\n\n\u003Cp align=\"center\">\n  \u003Cimg src=\"https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fdeclare-lab_instruct-eval_readme_93f0b6ded071.png\" alt=\"\" width=\"300\" height=\"300\">\n\u003C\u002Fp>\n\n> 🔥 如果你对LLM的智商测试感兴趣，可以查看我们的新工作：[AlgoPuzzleVQA](https:\u002F\u002Fgithub.com\u002Fdeclare-lab\u002Fpuzzle-reasoning)\n\n> 📣 重磅推出Resta：**语言模型的安全性再对齐**。[**论文**](https:\u002F\u002Farxiv.org\u002Fabs\u002F2402.11746) [**Github**](https:\u002F\u002Fgithub.com\u002Fdeclare-lab\u002Fresta)\n\n> 📣 **Red-Eval**，用于评估LLM安全性的基准测试已加入：[Red-Eval](https:\u002F\u002Fgithub.com\u002Fdeclare-lab\u002Finstruct-eval\u002Ftree\u002Fmain\u002Fred-eval)\n\n> 📣 重磅推出**Red-Eval**，通过多种越狱提示来评估LLM的安全性。使用**Red-Eval**，可以在DangerousQA和HarmfulQA基准上以65.1%的成功率对GPT-4进行越狱\u002F红队攻击，而ChatGPT则有73%的时间可以被成功越狱。更多详情请见：[代码](https:\u002F\u002Fgithub.com\u002Fdeclare-lab\u002Fred-instruct)和[论文](https:\u002F\u002Farxiv.org\u002Fabs\u002F2308.09662)。\n\n> 📣 我们基于Flan数据集对Vicuna-13B进行了微调，开发了Flacuna模型。Flacuna在解决问题方面优于Vicuna。你可以通过以下链接访问该模型：[https:\u002F\u002Fhuggingface.co\u002Fdeclare-lab\u002Fflacuna-13b-v1.0](https:\u002F\u002Fhuggingface.co\u002Fdeclare-lab\u002Fflacuna-13b-v1.0)。\n\n> 📣 [**InstructEval**](https:\u002F\u002Fdeclare-lab.net\u002Finstruct-eval\u002F) 基准测试及排行榜现已发布。\n\n> 📣 报告指令微调LLM在**InstructEval**基准套件上表现的论文已在Arxiv上发表。点击此处阅读：[https:\u002F\u002Farxiv.org\u002Fpdf\u002F2306.04757.pdf](https:\u002F\u002Farxiv.org\u002Fpdf\u002F2306.04757.pdf)。\n\n> 📣 我们发布了**IMPACT**数据集，用于从信息性、专业性、论证性和创造性四个方面评估LLM的写作能力。你可以从Huggingface下载：[https:\u002F\u002Fhuggingface.co\u002Fdatasets\u002Fdeclare-lab\u002FInstructEvalImpact](https:\u002F\u002Fhuggingface.co\u002Fdatasets\u002Fdeclare-lab\u002FInstructEvalImpact)。\n\n> 📣 **FLAN-T5** 在文本转音频生成方面也非常有用。如果你感兴趣，可以查看我们的相关工作：[https:\u002F\u002Fgithub.com\u002Fdeclare-lab\u002Ftango](https:\u002F\u002Fgithub.com\u002Fdeclare-lab\u002Ftango)。\n\n本仓库包含用于在未见过的任务上评估指令微调模型（如Alpaca和Flan-T5）的代码。\n我们的目标是促进跨多个任务和模型的简单便捷基准测试。\n\n### 为什么？\n\n像[Flan-T5](https:\u002F\u002Farxiv.org\u002Fabs\u002F2210.11416)和[Alpaca](https:\u002F\u002Fcrfm.stanford.edu\u002F2023\u002F03\u002F13\u002Falpaca.html)这样的指令微调模型，代表了一种令人振奋的方向，能够在较低成本下逼近大型语言模型（LLMs，如ChatGPT）的性能。\n然而，要定性地比较不同模型的性能却颇具挑战性。\n为了评估这些模型在广泛且具有挑战性的未见任务上的泛化能力，我们可以使用诸如[MMLU](https:\u002F\u002Farxiv.org\u002Fabs\u002F2009.03300)和[BBH](https:\u002F\u002Farxiv.org\u002Fabs\u002F2210.09261)之类的学术基准。\n与现有的库（如[evaluation-harness](https:\u002F\u002Fgithub.com\u002FEleutherAI\u002Flm-evaluation-harness)和[HELM](https:\u002F\u002Fgithub.com\u002Fstanford-crfm\u002Fhelm)）相比，本仓库能够为多个模型提供简单便捷的评估方式。\n值得注意的是，我们支持HuggingFace Transformers中的大多数模型（具体支持的模型列表请参阅[这里](.\u002Fdocs\u002Fmodels.md)）：\n\n- [AutoModelForCausalLM](https:\u002F\u002Fhuggingface.co\u002Fdocs\u002Ftransformers\u002Fmodel_doc\u002Fauto#transformers.AutoModelForCausalLM)（例如[GPT-2](https:\u002F\u002Fhuggingface.co\u002Fgpt2-xl)、[GPT-J](https:\u002F\u002Fhuggingface.co\u002FEleutherAI\u002Fgpt-j-6b)、[OPT-IML](https:\u002F\u002Fhuggingface.co\u002Ffacebook\u002Fopt-iml-max-1.3b)、[BLOOMZ](https:\u002F\u002Fhuggingface.co\u002Fbigscience\u002Fbloomz-7b1)）\n- [AutoModelForSeq2SeqLM](https:\u002F\u002Fhuggingface.co\u002Fdocs\u002Ftransformers\u002Fmodel_doc\u002Fauto#transformers.AutoModelForSeq2SeqLM)（例如[Flan-T5](https:\u002F\u002Fhuggingface.co\u002Fgoogle\u002Fflan-t5-xl)、[Flan-UL2](https:\u002F\u002Fhuggingface.co\u002Fgoogle\u002Fflan-ul2)、[TK-Instruct](https:\u002F\u002Fhuggingface.co\u002Fallenai\u002Ftk-instruct-3b-def)）\n- [LlamaForCausalLM](https:\u002F\u002Fhuggingface.co\u002Fdocs\u002Ftransformers\u002Fmain\u002Fmodel_doc\u002Fllama#transformers.LlamaForCausalLM)（例如[LLaMA](https:\u002F\u002Fhuggingface.co\u002Fdecapoda-research\u002Fllama-7b-hf)、[Alpaca](https:\u002F\u002Fhuggingface.co\u002Fchavinlo\u002Falpaca-native)、[Vicuna](https:\u002F\u002Fhuggingface.co\u002Fchavinlo\u002Fvicuna)）\n- [ChatGLM](https:\u002F\u002Fhuggingface.co\u002FTHUDM\u002Fchatglm-6b)\n\n### 结果\n\n有关详细结果，请访问我们的[排行榜](https:\u002F\u002Fdeclare-lab.net\u002Finstruct-eval\u002F)\n\n| 模型名称 | 模型路径                                                                                                              | 论文                                                                                                         | 参数量 | MMLU | BBH  | DROP | HumanEval |\n|------------|-------------------------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------|------|------|------|------|-----------|\n|            | [GPT-4](https:\u002F\u002Fopenai.com\u002Fproduct\u002Fgpt-4)                                                                               | [链接](https:\u002F\u002Farxiv.org\u002Fabs\u002F2303.08774)                                                                      | ?    | 86.4 |      | 80.9 | 67.0      |\n|            | [ChatGPT](https:\u002F\u002Fopenai.com\u002Fblog\u002Fchatgpt)                                                                              | [链接](https:\u002F\u002Farxiv.org\u002Fabs\u002F2303.08774)                                                                      | ?    | 70.0 |      | 64.1 | 48.1      |\n| seq_to_seq | [google\u002Fflan-t5-xxl](https:\u002F\u002Fhuggingface.co\u002Fgoogle\u002Fflan-t5-xxl)                                                         | [链接](https:\u002F\u002Farxiv.org\u002Fabs\u002F2210.11416)                                                                      | 11B  | 54.5 | 43.9 |      |           |\n| seq_to_seq | [google\u002Fflan-t5-xl](https:\u002F\u002Fhuggingface.co\u002Fgoogle\u002Fflan-t5-xl)                                                           | [链接](https:\u002F\u002Farxiv.org\u002Fabs\u002F2210.11416)                                                                      | 3B   | 49.2 | 40.2 | 56.3 |           |\n| llama      | [eachadea\u002Fvicuna-13b](https:\u002F\u002Fhuggingface.co\u002Feachadea\u002Fvicuna-13b)                                                       | [链接](https:\u002F\u002Fvicuna.lmsys.org\u002F)                                                                             | 13B  | 49.7 | 37.1 | 32.9 | 15.2      |\n| llama      | [decapoda-research\u002Fllama-13b-hf](https:\u002F\u002Fhuggingface.co\u002Fdecapoda-research\u002Fllama-13b-hf)                                 | [链接](https:\u002F\u002Farxiv.org\u002Fabs\u002F2302.13971)                                                                      | 13B  | 46.2 | 37.1 | 35.3 | 13.4      |\n| seq_to_seq | [declare-lab\u002Fflan-alpaca-gpt4-xl](https:\u002F\u002Fhuggingface.co\u002Fdeclare-lab\u002Fflan-alpaca-gpt4-xl)                               | [链接](https:\u002F\u002Fgithub.com\u002Fdeclare-lab\u002Fflan-alpaca)                                                            | 3B   | 45.6 | 34.8 |      |           |\n| llama      | [TheBloke\u002Fkoala-13B-HF](https:\u002F\u002Fhuggingface.co\u002FTheBloke\u002Fkoala-13B-HF)                                                   | [链接](https:\u002F\u002Fbair.berkeley.edu\u002Fblog\u002F2023\u002F04\u002F03\u002Fkoala\u002F)                                                      | 13B  | 44.6 | 34.6 | 28.3 | 11.0      |\n| llama      | [chavinlo\u002Falpaca-native](https:\u002F\u002Fhuggingface.co\u002Fchavinlo\u002Falpaca-native)                                                 | [链接](https:\u002F\u002Fcrfm.stanford.edu\u002F2023\u002F03\u002F13\u002Falpaca.html)                                                      | 7B   | 41.6 | 33.3 | 26.3 | 10.3      |\n| llama      | [TheBloke\u002FwizardLM-7B-HF](https:\u002F\u002Fhuggingface.co\u002FTheBloke\u002FwizardLM-7B-HF)                                               | [链接](https:\u002F\u002Farxiv.org\u002Fabs\u002F2304.12244)                                                                      | 7B   | 36.4 | 32.9 |      | 15.2      |\n| chatglm    | [THUDM\u002Fchatglm-6b](https:\u002F\u002Fhuggingface.co\u002FTHUDM\u002Fchatglm-6b)                                                             | [链接](https:\u002F\u002Farxiv.org\u002Fabs\u002F2210.02414)                                                                      | 6B   | 36.1 | 31.3 | 44.2 | 3.1       |\n| llama      | [decapoda-research\u002Fllama-7b-hf](https:\u002F\u002Fhuggingface.co\u002Fdecapoda-research\u002Fllama-7b-hf)                                   | [链接](https:\u002F\u002Farxiv.org\u002Fabs\u002F2302.13971)                                                                      | 7B   | 35.2 | 30.9 | 27.6 | 10.3      |\n| llama      | [wombat-7b-gpt4-delta](https:\u002F\u002Fhuggingface.co\u002FGanjinZero\u002Fwombat-7b-gpt4-delta)                                          | [链接](https:\u002F\u002Farxiv.org\u002Fabs\u002F2304.05302)                                                                      | 7B   | 33.0 | 32.4 |      | 7.9       |\n| seq_to_seq | [bigscience\u002Fmt0-xl](https:\u002F\u002Fhuggingface.co\u002Fbigscience\u002Fmt0-xl)                                                           | [链接](https:\u002F\u002Farxiv.org\u002Fabs\u002F2210.11416)                                                                      | 3B   | 30.4 |      |      |           |\n| causal     | [facebook\u002Fopt-iml-max-1.3b](https:\u002F\u002Fhuggingface.co\u002Ffacebook\u002Fopt-iml-max-1.3b)                                           | [链接](https:\u002F\u002Farxiv.org\u002Fabs\u002F2212.12017)                                                                      | 1B   | 27.5 |      |      | 1.8       |\n| causal     | [OpenAssistant\u002Foasst-sft-4-pythia-12b-epoch-3.5](https:\u002F\u002Fhuggingface.co\u002FOpenAssistant\u002Foasst-sft-4-pythia-12b-epoch-3.5) | [链接](https:\u002F\u002Fgithub.com\u002FLAION-AI\u002FOpen-Assistant)                                                            | 12B  | 27.0 | 30.0 |      | 9.1       |\n| causal     | [stabilityai\u002Fstablelm-base-alpha-7b](https:\u002F\u002Fhuggingface.co\u002Fstabilityai\u002Fstablelm-base-alpha-7b)                         | [链接](https:\u002F\u002Fgithub.com\u002FStability-AI\u002FStableLM)                                                              | 7B   | 26.2 |      |      | 1.8       |\n| causal     | [databricks\u002Fdolly-v2-12b](https:\u002F\u002Fhuggingface.co\u002Fdatabricks\u002Fdolly-v2-12b)                                               | [链接](https:\u002F\u002Fwww.databricks.com\u002Fblog\u002F2023\u002F04\u002F12\u002Fdolly-first-open-commercially-viable-instruction-tuned-llm) | 12B  | 25.7 |      |      | 7.9       |\n| causal     | [Salesforce\u002Fcodegen-6B-mono](https:\u002F\u002Fhuggingface.co\u002FSalesforce\u002Fcodegen-6B-mono)                                         | [链接](https:\u002F\u002Farxiv.org\u002Fabs\u002F2203.13474)                                                                      | 6B   |      |      |      | 27.4      |\n| causal     | [togethercomputer\u002FRedPajama-INCITE-Instruct-7B-v0.1](https:\u002F\u002Fhuggingface.co\u002Ftogethercomputer\u002FRedPajama-INCITE-Instruct-7B-v0.1) | [链接](https:\u002F\u002Fgithub.com\u002Ftogethercomputer\u002FRedPajama-Data)                                                     | 7B   | 38.1 | 31.3 | 24.7 | 5.5      |\n\n### 示例用法\n\n在[大规模多任务语言理解](https:\u002F\u002Fhuggingface.co\u002Fdatasets\u002Flukaemon\u002Fmmlu)（MMLU）上进行评估，该数据集包含来自数学、历史、法律和医学等57个任务的考试题目。\n我们采用5-shot直接提示方法，并以完全匹配准确率作为衡量标准。\n\n```\npython main.py mmlu --model_name llama --model_path chavinlo\u002Falpaca-native\n# 0.4163936761145136\n\npython main.py mmlu --model_name seq_to_seq --model_path google\u002Fflan-t5-xl\n\n# 0.49252243270189433\n```\n\n在 [Big Bench Hard](https:\u002F\u002Fhuggingface.co\u002Fdatasets\u002Flukaemon\u002Fbbh) (BBH) 上进行评估，该数据集包含 23 个具有挑战性的任务，而 PaLM (540B) 在这些任务上的表现低于平均人类评分者。我们采用 3 次示例的直接提示方法，并测量完全匹配得分。\n\n```\npython main.py bbh --model_name llama --model_path TheBloke\u002Fkoala-13B-HF --load_8bit\n# 0.3468942926723247\n```\n\n在 [DROP](https:\u002F\u002Fhuggingface.co\u002Fdatasets\u002Fdrop) 上进行评估，这是一个数学问题解答基准测试。我们同样采用 3 次示例的直接提示方法，并测量完全匹配得分。\n\n```\npython main.py drop --model_name seq_to_seq --model_path google\u002Fflan-t5-xl \n# 0.5632458233890215\n```\n\n在 [HumanEval](https:\u002F\u002Fhuggingface.co\u002Fdatasets\u002Fopenai_humaneval) 上进行评估，该数据集包含 164 道 Python 编程题目。我们采用 0 次示例的直接提示方法，并测量 pass@1 得分。\n\n```\npython main.py humaneval  --model_name llama --model_path eachadea\u002Fvicuna-13b --n_sample 1 --load_8bit\n# {'pass@1': 0.1524390243902439}\n```\n\n### 设置\n\n安装依赖并下载数据。\n\n```\nconda create -n instruct-eval python=3.8 -y\nconda activate instruct-eval\npip install -r requirements.txt\nmkdir -p data\nwget https:\u002F\u002Fpeople.eecs.berkeley.edu\u002F~hendrycks\u002Fdata.tar -O data\u002Fmmlu.tar\ntar -xf data\u002Fmmlu.tar -C data && mv data\u002Fdata data\u002Fmmlu\n```","# InstructEval 快速上手指南\n\nInstructEval 是一个用于全面评估指令微调大语言模型（Instruction-Tuned LLMs）的开源工具。它支持在 MMLU、BBH、DROP、HumanEval 等多个学术基准上对模型进行简便、统一的评测，兼容 HuggingFace Transformers 中的多种模型架构（如 LLaMA、Flan-T5、ChatGLM 等）。\n\n## 环境准备\n\n*   **操作系统**: Linux 或 macOS (Windows 需使用 WSL)\n*   **Python**: 3.8 或更高版本\n*   **硬件**: 推荐配备 NVIDIA GPU (显存大小取决于所评测模型的参数量)。若评测大模型，建议使用支持 `bitsandbytes` 的环境以开启 8-bit 量化加载。\n*   **前置依赖**:\n    *   PyTorch\n    *   HuggingFace Transformers\n    *   Datasets\n    *   Accelerate\n\n> **国内加速建议**：\n> 1. 配置 HuggingFace 镜像源：\n>    ```bash\n>    export HF_ENDPOINT=https:\u002F\u002Fhf-mirror.com\n>    ```\n> 2. 使用 pip 国内源安装依赖（如阿里云或清华源）：\n>    ```bash\n>    pip install -r requirements.txt -i https:\u002F\u002Fpypi.tuna.tsinghua.edu.cn\u002Fsimple\n>    ```\n\n## 安装步骤\n\n1.  **克隆仓库**\n    ```bash\n    git clone https:\u002F\u002Fgithub.com\u002Fdeclare-lab\u002Finstruct-eval.git\n    cd instruct-eval\n    ```\n\n2.  **安装依赖**\n    确保已安装 PyTorch（根据你的 CUDA 版本选择对应的安装命令），然后安装项目所需库：\n    ```bash\n    pip install -r requirements.txt\n    ```\n    *(注：如果原文未提供 requirements.txt，请手动安装核心库：`pip install transformers datasets accelerate sentencepiece protobuf`)*\n\n3.  **验证安装**\n    运行帮助命令确认脚本可用：\n    ```bash\n    python main.py --help\n    ```\n\n## 基本使用\n\nInstructEval 通过 `main.py` 脚本调用，指定评测数据集、模型类型及模型路径即可。\n\n### 1. 评测 MMLU 基准\nMMLU 包含数学、历史、法律等 57 个领域的考试题目。以下示例使用 5-shot 直接提示并计算精确匹配分数。\n\n**评测 Alpaca (LLaMA 架构):**\n```bash\npython main.py mmlu --model_name llama --model_path chavinlo\u002Falpaca-native\n```\n\n**评测 Flan-T5 (Seq2Seq 架构):**\n```bash\npython main.py mmlu --model_name seq_to_seq --model_path google\u002Fflan-t5-xl\n```\n\n### 2. 评测 BBH 基准\nBBH 包含 23 个高难度任务。以下示例展示如何加载 8-bit 量化模型以节省显存（适用于大模型如 Koala-13B）。\n\n```bash\npython main.py bbh --model_name llama --model_path TheBloke\u002Fkoala-13B-HF --load_8bit\n```\n\n### 3. 评测 DROP 基准\nDROP 是数学问答基准，通常使用 3-shot 直接提示。\n\n```bash\npython main.py drop --model_name llama --model_path decapoda-research\u002Fllama-7b-hf\n```\n\n### 参数说明\n*   `--model_name`: 模型架构类型，支持 `llama`, `seq_to_seq`, `causal`, `chatglm` 等。\n*   `--model_path`: HuggingFace 模型 ID 或本地模型路径。\n*   `--load_8bit`: (可选) 启用 8-bit 量化加载，降低显存需求。\n*   数据集名称：支持 `mmlu`, `bbh`, `drop`, `human_eval` 等。\n\n更多支持的模型列表及详细评测结果，请参考官方 [Leaderboard](https:\u002F\u002Fdeclare-lab.github.io\u002Finstruct-eval\u002F)。","某 AI 初创团队在研发垂直领域客服模型时，需要从 Alpaca、Flan-T5 等多个开源指令微调模型中筛选出泛化能力最强的基座，以应对用户千变万化的提问。\n\n### 没有 instruct-eval 时\n- **评估标准混乱**：团队只能依赖人工抽检或单一数据集测试，难以量化模型在未见过的复杂任务上的真实表现，导致选型靠“感觉”。\n- **对比成本高昂**：不同模型需要编写独立的测试脚本，缺乏统一框架，复现论文结果和横向对比耗费大量工程时间。\n- **盲区风险大**：仅关注常规问答，忽略了模型在逻辑推理、安全防御（如越狱攻击）等关键维度的潜在缺陷，上线后易出现严重事故。\n- **迭代方向模糊**：由于缺乏多维度的量化反馈（如 IMPACT 写作能力评估），开发人员无法精准定位模型短板，优化工作如同“盲人摸象”。\n\n### 使用 instruct-eval 后\n- **全景量化评估**：利用内置的 MMLU、BBH 等学术基准及 Red-Eval 安全测试，一键生成涵盖通用能力、逻辑推理及安全性的多维度评分报告。\n- **高效横向比对**：通过统一接口快速加载 HuggingFace 上的各类模型，自动在保留任务上运行测试，将原本数天的对比工作缩短至几小时。\n- **风险提前暴露**：借助 Red-Eval 中的越狱提示词库，提前发现模型在面对恶意诱导时的脆弱性，确保上线模型具备基本的安全防线。\n- **精准优化指导**：基于 IMPACT 数据集的细粒度反馈（信息量、专业性等），团队能清晰看到模型在特定写作风格上的不足，从而针对性调整微调策略。\n\ninstruct-eval 将模糊的模型体感转化为可信的量化数据，帮助团队以最低成本锁定最适合业务场景的高性能模型。","https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fdeclare-lab_instruct-eval_16b3091c.png","declare-lab","Deep Cognition and Language Research (DeCLaRe) Lab","https:\u002F\u002Foss.gittoolsai.com\u002Favatars\u002Fdeclare-lab_27a2ce73.png","",null,"https:\u002F\u002Fdeclare-lab.github.io","https:\u002F\u002Fgithub.com\u002Fdeclare-lab",[80],{"name":81,"color":82,"percentage":83},"Python","#3572A5",100,552,45,"2026-02-19T10:25:39","Apache-2.0","未说明","必需（用于运行大模型），具体型号和显存取决于所选模型大小。示例中使用了 --load_8bit 参数，表明支持量化加载以降低显存需求。支持 CUDA 的 NVIDIA GPU 通常为首选。","未说明（建议根据模型参数量配置，运行 7B-13B 模型通常推荐 16GB-32GB+）",{"notes":92,"python":88,"dependencies":93},"该工具主要用于评估指令微调的大语言模型（如 Alpaca, Flan-T5, LLaMA, ChatGLM 等）。代码依赖 HuggingFace Transformers 库加载模型。示例命令中包含 '--load_8bit' 参数，表明集成了 bitsandbytes 以支持 8 位量化推理，从而在显存有限的设备上运行较大模型。具体的硬件需求高度依赖于用户选择评估的模型大小（从 1B 到数十亿参数不等）。",[94,95,96],"transformers","torch","accelerate",[35,14],[99,100],"instruct-tuning","llm","2026-03-27T02:49:30.150509","2026-04-09T12:33:45.982566",[104,109,114,119,124,129,134],{"id":105,"question_zh":106,"answer_zh":107,"source_url":108},26186,"执行过程中遇到报错（如空值相关错误），该如何修复？","这类错误通常是由于数据中存在空值导致的。需要在代码中增加非空判断（null check）逻辑来避免程序崩溃。","https:\u002F\u002Fgithub.com\u002Fdeclare-lab\u002Finstruct-eval\u002Fissues\u002F9",{"id":110,"question_zh":111,"answer_zh":112,"source_url":113},26180,"如何为类 Alpaca 模型（如 LLaMa）设置正确的提示词格式？","当前代码支持 Alpaca 指令模板。在运行评估脚本时，请添加 `--use_template` 标志即可启用该格式。不过根据初始测试，对于少样本提示（few-shot prompting），使用该模板差异不大，甚至不使用模板的结果略好。","https:\u002F\u002Fgithub.com\u002Fdeclare-lab\u002Finstruct-eval\u002Fissues\u002F2",{"id":115,"question_zh":116,"answer_zh":117,"source_url":118},26181,"在 human_eval 任务中运行时报错 'generate() got multiple values for keyword argument do_sample' 如何解决？","这是一个已知的代码冲突问题，维护者已经推送了修复补丁。请拉取最新的代码更新（git pull）即可解决该错误。","https:\u002F\u002Fgithub.com\u002Fdeclare-lab\u002Finstruct-eval\u002Fissues\u002F22",{"id":120,"question_zh":121,"answer_zh":122,"source_url":123},26182,"HHH 基准评估中为什么要使用 base_prompt 以及 (A - A_base) > (B - B_base) 的计算逻辑？","这是为了消除选项位置对预测结果（logits）的影响，确保评估的公平性。研究发现，仅仅改变候选答案在上下文中的出现顺序就能轻易操纵排名（参考论文：Large Language Models are not Fair Evaluators）。通过计算相对差值，可以抵消位置偏差，使大语言模型给出更鲁棒和公平的答案。","https:\u002F\u002Fgithub.com\u002Fdeclare-lab\u002Finstruct-eval\u002Fissues\u002F20",{"id":125,"question_zh":126,"answer_zh":127,"source_url":128},26183,"项目是否计划支持大于 1 的 batch_size 以提高运行速度？","目前暂无此计划。为了保持代码库的简洁性，项目暂时假设 batch_size 必须为 1，不支持更大的批次大小。","https:\u002F\u002Fgithub.com\u002Fdeclare-lab\u002Finstruct-eval\u002Fissues\u002F18",{"id":130,"question_zh":131,"answer_zh":132,"source_url":133},26184,"本项目未来的发展方向是什么？是否计划支持基于模型微调格式的零样本评估？","项目鼓励社区贡献新的基准测试结果并推送到仓库。维护团队维护着一个排行榜（https:\u002F\u002Fdeclare-lab.net\u002Finstruct-eval\u002F），可以将新的基准测试（如 OpenAI evals, EvalPlus 等）纳入其中。关于具体的零样本评估格式，欢迎提交 PR 共同完善。","https:\u002F\u002Fgithub.com\u002Fdeclare-lab\u002Finstruct-eval\u002Fissues\u002F11",{"id":135,"question_zh":136,"answer_zh":137,"source_url":138},26185,"面对 MMLU 等数据集中存在的标签噪声或错误题目，应该如何处理？","虽然减少评估数据集中的噪声很重要，但目前的策略是不过度纠结于现有数据集的噪声，而是致力于构建更具挑战性和干净的新基准（如 BBH, human-eval 等）。此外，探索测试大模型安全性（如红队测试）也是重要的研究方向。","https:\u002F\u002Fgithub.com\u002Fdeclare-lab\u002Finstruct-eval\u002Fissues\u002F21",[]]