[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"similar-tensorflow--decision-forests":3,"tool-tensorflow--decision-forests":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 真正成长为懂上",155373,2,"2026-04-14T11:34:08",[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 都能提供强大的支持。其独特的模块化架构允许社区不断扩展新功能，使其成为当前最灵活、生态最丰富的开源扩散模型工具之一，帮助用户将创意高效转化为现实。",108322,"2026-04-10T11:39:34",[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},6121,"gemini-cli","google-gemini\u002Fgemini-cli","gemini-cli 是一款由谷歌推出的开源 AI 命令行工具，它将强大的 Gemini 大模型能力直接集成到用户的终端环境中。对于习惯在命令行工作的开发者而言，它提供了一条从输入提示词到获取模型响应的最短路径，无需切换窗口即可享受智能辅助。\n\n这款工具主要解决了开发过程中频繁上下文切换的痛点，让用户能在熟悉的终端界面内直接完成代码理解、生成、调试以及自动化运维任务。无论是查询大型代码库、根据草图生成应用，还是执行复杂的 Git 操作，gemini-cli 都能通过自然语言指令高效处理。\n\n它特别适合广大软件工程师、DevOps 人员及技术研究人员使用。其核心亮点包括支持高达 100 万 token 的超长上下文窗口，具备出色的逻辑推理能力；内置 Google 搜索、文件操作及 Shell 命令执行等实用工具；更独特的是，它支持 MCP（模型上下文协议），允许用户灵活扩展自定义集成，连接如图像生成等外部能力。此外，个人谷歌账号即可享受免费的额度支持，且项目基于 Apache 2.0 协议完全开源，是提升终端工作效率的理想助手。",100752,"2026-04-10T01:20:03",[52,13,15,14],"插件",{"id":54,"name":55,"github_repo":56,"description_zh":57,"stars":58,"difficulty_score":32,"last_commit_at":59,"category_tags":60,"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":62,"github_repo":63,"name":64,"description_en":65,"description_zh":66,"ai_summary_zh":67,"readme_en":68,"readme_zh":69,"quickstart_zh":70,"use_case_zh":71,"hero_image_url":72,"owner_login":73,"owner_name":73,"owner_avatar_url":74,"owner_bio":75,"owner_company":76,"owner_location":76,"owner_email":77,"owner_twitter":76,"owner_website":78,"owner_url":79,"languages":80,"stars":109,"forks":110,"last_commit_at":111,"license":112,"difficulty_score":113,"env_os":114,"env_gpu":115,"env_ram":115,"env_deps":116,"category_tags":121,"github_topics":122,"view_count":32,"oss_zip_url":76,"oss_zip_packed_at":76,"status":17,"created_at":132,"updated_at":133,"faqs":134,"releases":164},7541,"tensorflow\u002Fdecision-forests","decision-forests","A collection of state-of-the-art algorithms for the training, serving and interpretation of Decision Forest models in Keras.","TensorFlow Decision Forests 是一个专为 TensorFlow 生态打造的开源库，旨在帮助开发者轻松训练、部署和解读决策森林模型（如随机森林和梯度提升树）。它有效解决了传统机器学习框架中集成学习算法实现复杂、与深度学习工作流割裂的痛点，让用户能在熟悉的 Keras 接口下，一站式完成从数据加载、模型训练到评估导出全流程。\n\n该工具特别适合需要在 TensorFlow 环境中应用高效表格数据模型的机器学习工程师、数据科学家及研究人员。无论是处理分类、回归还是排序任务，它都能提供State-of-the-Art的性能表现。其核心技术亮点在于底层由高性能的 C++ 引擎 Yggdrasil Decision Forests (YDF) 驱动，不仅训练速度快、功能丰富，还支持与 YDF 原生模型双向兼容。此外，它提供了直观的模型解释功能，帮助用户深入理解预测逻辑。虽然官方建议新用户直接迁移至功能更强大的 YDF，但 TensorFlow Decision Forests 依然是连接经典机器学习算法与现代深度学习平台的桥梁，支持 Linux 和 macOS 系统，让复杂","TensorFlow Decision Forests 是一个专为 TensorFlow 生态打造的开源库，旨在帮助开发者轻松训练、部署和解读决策森林模型（如随机森林和梯度提升树）。它有效解决了传统机器学习框架中集成学习算法实现复杂、与深度学习工作流割裂的痛点，让用户能在熟悉的 Keras 接口下，一站式完成从数据加载、模型训练到评估导出全流程。\n\n该工具特别适合需要在 TensorFlow 环境中应用高效表格数据模型的机器学习工程师、数据科学家及研究人员。无论是处理分类、回归还是排序任务，它都能提供State-of-the-Art的性能表现。其核心技术亮点在于底层由高性能的 C++ 引擎 Yggdrasil Decision Forests (YDF) 驱动，不仅训练速度快、功能丰富，还支持与 YDF 原生模型双向兼容。此外，它提供了直观的模型解释功能，帮助用户深入理解预测逻辑。虽然官方建议新用户直接迁移至功能更强大的 YDF，但 TensorFlow Decision Forests 依然是连接经典机器学习算法与现代深度学习平台的桥梁，支持 Linux 和 macOS 系统，让复杂的集成学习变得像调用普通神经网络一样简单流畅。","\u003Cp align=\"center\">\n\u003Cimg src=\"https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Ftensorflow_decision-forests_readme_33c7cca13d21.png\"  \u002F>\n\u003C\u002Fp>\n\n> **Note:** We recommend users to migrate to **Yggdrasil Decision Forests**\n> (**YDF**). YDF trains the same models as TF-DF, but is faster and has more\n> functionality. See the\n> [migration guide](https:\u002F\u002Fydf.readthedocs.io\u002Fen\u002Flatest\u002Ftutorial\u002Fmigrating_to_ydf\u002F)\n> for more information.\n\n**TensorFlow Decision Forests** (**TF-DF**) is a library to train, run and\ninterpret [decision forest](https:\u002F\u002Fydf.readthedocs.io\u002Fen\u002Flatest\u002Fintro_df.html)\nmodels (e.g., Random Forests, Gradient Boosted Trees) in TensorFlow. TF-DF\nsupports classification, regression and ranking.\n\n**TF-DF** is powered by\n[Yggdrasil Decision Forest](https:\u002F\u002Fgithub.com\u002Fgoogle\u002Fyggdrasil-decision-forests)\n(**YDF**, a library to train and use decision forests in C++, JavaScript, CLI,\nand Go. TF-DF models are\n[compatible](https:\u002F\u002Fydf.readthedocs.io\u002Fen\u002Flatest\u002Fconvert_model.html#convert-a-a-tensorflow-decision-forests-model-to-a-yggdrasil-model)\nwith YDF' models, and vice versa.\n\nTensorflow Decision Forests is available on Linux and Mac. Windows users can use\nthe library through WSL+Linux.\n\n## Usage example\n\nA minimal end-to-end run looks as follows:\n\n```python\nimport tensorflow_decision_forests as tfdf\nimport pandas as pd\n\n# Load the dataset in a Pandas dataframe.\ntrain_df = pd.read_csv(\"project\u002Ftrain.csv\")\ntest_df = pd.read_csv(\"project\u002Ftest.csv\")\n\n# Convert the dataset into a TensorFlow dataset.\ntrain_ds = tfdf.keras.pd_dataframe_to_tf_dataset(train_df, label=\"my_label\")\ntest_ds = tfdf.keras.pd_dataframe_to_tf_dataset(test_df, label=\"my_label\")\n\n# Train the model\nmodel = tfdf.keras.RandomForestModel()\nmodel.fit(train_ds)\n\n# Look at the model.\nmodel.summary()\n\n# Evaluate the model.\nmodel.evaluate(test_ds)\n\n# Export to a TensorFlow SavedModel.\n# Note: the model is compatible with Yggdrasil Decision Forests.\nmodel.save(\"project\u002Fmodel\")\n```\n\n## Google I\u002FO Presentation\n\n\u003Cdiv align=\"center\">\n    \u003Ca href=\"https:\u002F\u002Fyoutu.be\u002F5qgk9QJ4rdQ\">\n        \u003Cimg src=\"https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Ftensorflow_decision-forests_readme_34d656e50e4c.jpg\">\u003C\u002Fimg>\n    \u003C\u002Fa>\n\u003C\u002Fdiv>\n\n## Documentation & Resources\n\nThe following resources are available:\n\n-   [TF-DF on TensorFlow.org](https:\u002F\u002Ftensorflow.org\u002Fdecision_forests) (API\n    Reference, Guides and Tutorials)\n-   [Tutorials](https:\u002F\u002Fwww.tensorflow.org\u002Fdecision_forests\u002Ftutorials) (on\n    tensorflow.org)\n-   [YDF documentation](https:\u002F\u002Fydf.readthedocs.io) (also applicable to TF-DF)\n-   [Issue tracker](https:\u002F\u002Fgithub.com\u002Ftensorflow\u002Fdecision-forests\u002Fissues)\n-   [Known issues](documentation\u002Fknown_issues.md)\n-   [Changelog](CHANGELOG.md)\n-   [More examples](documentation\u002Fmore_examples.md)\n\n## Installation\n\nTo install TensorFlow Decision Forests, run:\n\n```shell\npip3 install tensorflow_decision_forests --upgrade\n```\n\nSee the [installation](documentation\u002Finstallation.md) page for more details,\ntroubleshooting and alternative installation solutions.\n\n## Contributing\n\nContributions to TensorFlow Decision Forests and Yggdrasil Decision Forests are\nwelcome. If you want to contribute, make sure to review the\n[developer manual](documentation\u002Fdeveloper_manual.md) and\n[contribution guidelines](CONTRIBUTING.md).\n\n## Citation\n\nIf you us Tensorflow Decision Forests in a scientific publication, please cite\nthe following paper:\n[Yggdrasil Decision Forests: A Fast and Extensible Decision Forests Library](https:\u002F\u002Fdoi.org\u002F10.1145\u002F3580305.3599933).\n\n**Bibtex**\n\n```\n@inproceedings{GBBSP23,\n  author       = {Mathieu Guillame{-}Bert and\n                  Sebastian Bruch and\n                  Richard Stotz and\n                  Jan Pfeifer},\n  title        = {Yggdrasil Decision Forests: {A} Fast and Extensible Decision Forests\n                  Library},\n  booktitle    = {Proceedings of the 29th {ACM} {SIGKDD} Conference on Knowledge Discovery\n                  and Data Mining, {KDD} 2023, Long Beach, CA, USA, August 6-10, 2023},\n  pages        = {4068--4077},\n  year         = {2023},\n  url          = {https:\u002F\u002Fdoi.org\u002F10.1145\u002F3580305.3599933},\n  doi          = {10.1145\u002F3580305.3599933},\n}\n```\n\n**Raw**\n\nYggdrasil Decision Forests: A Fast and Extensible Decision Forests Library,\nGuillame-Bert et al., KDD 2023: 4068-4077. doi:10.1145\u002F3580305.3599933\n\n## Contact\n\nYou can contact the core development team at\n[decision-forests-contact@google.com](mailto:decision-forests-contact@google.com).\n\n## Credits\n\nTensorFlow Decision Forests was developed by:\n\n-   Mathieu Guillame-Bert (gbm AT google DOT com)\n-   Jan Pfeifer (janpf AT google DOT com)\n-   Richard Stotz (richardstotz AT google DOT com)\n-   Sebastian Bruch (sebastian AT bruch DOT io)\n-   Arvind Srinivasan (arvnd AT google DOT com)\n\n## License\n\n[Apache License 2.0](LICENSE)\n","\u003Cp align=\"center\">\n\u003Cimg src=\"https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Ftensorflow_decision-forests_readme_33c7cca13d21.png\"  \u002F>\n\u003C\u002Fp>\n\n> **注意:** 我们建议用户迁移到 **Yggdrasil Decision Forests**\n> (**YDF**)。YDF 训练的模型与 TF-DF 相同，但速度更快且功能更丰富。更多信息请参阅\n> [迁移指南](https:\u002F\u002Fydf.readthedocs.io\u002Fen\u002Flatest\u002Ftutorial\u002Fmigrating_to_ydf\u002F)。\n\n**TensorFlow 决策森林** (**TF-DF**) 是一个用于在 TensorFlow 中训练、运行和解释\n[决策森林](https:\u002F\u002Fydf.readthedocs.io\u002Fen\u002Flatest\u002Fintro_df.html) 模型（例如随机森林、梯度提升树）的库。TF-DF 支持分类、回归和排序任务。\n\n**TF-DF** 基于\n[Yggdrasil Decision Forest](https:\u002F\u002Fgithub.com\u002Fgoogle\u002Fyggdrasil-decision-forests)\n(**YDF**，一个用 C++、JavaScript、CLI 和 Go 编写的用于训练和使用决策森林的库）。TF-DF 模型与 YDF 的模型\n[兼容](https:\u002F\u002Fydf.readthedocs.io\u002Fen\u002Flatest\u002Fconvert_model.html#convert-a-a-tensorflow-decision-forests-model-to-a-yggdrasil-model),\n反之亦然。\n\nTensorFlow 决策森林适用于 Linux 和 Mac 系统。Windows 用户可以通过 WSL + Linux 使用该库。\n\n## 使用示例\n\n一个最简化的端到端流程如下：\n\n```python\nimport tensorflow_decision_forests as tfdf\nimport pandas as pd\n\n# 将数据集加载到 Pandas 数据框中。\ntrain_df = pd.read_csv(\"project\u002Ftrain.csv\")\ntest_df = pd.read_csv(\"project\u002Ftest.csv\")\n\n# 将数据集转换为 TensorFlow 数据集。\ntrain_ds = tfdf.keras.pd_dataframe_to_tf_dataset(train_df, label=\"my_label\")\ntest_ds = tfdf.keras.pd_dataframe_to_tf_dataset(test_df, label=\"my_label\")\n\n# 训练模型\nmodel = tfdf.keras.RandomForestModel()\nmodel.fit(train_ds)\n\n# 查看模型。\nmodel.summary()\n\n# 评估模型。\nmodel.evaluate(test_ds)\n\n# 导出为 TensorFlow SavedModel。\n# 注意：该模型与 Yggdrasil 决策森林兼容。\nmodel.save(\"project\u002Fmodel\")\n```\n\n## Google I\u002FO 演示\n\n\u003Cdiv align=\"center\">\n    \u003Ca href=\"https:\u002F\u002Fyoutu.be\u002F5qgk9QJ4rdQ\">\n        \u003Cimg src=\"https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Ftensorflow_decision-forests_readme_34d656e50e4c.jpg\">\u003C\u002Fimg>\n    \u003C\u002Fa>\n\u003C\u002Fdiv>\n\n## 文档与资源\n\n以下资源可供使用：\n\n-   [TF-DF 在 TensorFlow.org 上](https:\u002F\u002Ftensorflow.org\u002Fdecision_forests)（API 参考、指南和教程）\n-   [教程](https:\u002F\u002Fwww.tensorflow.org\u002Fdecision_forests\u002Ftutorials)（在 tensorflow.org 上）\n-   [YDF 文档](https:\u002F\u002Fydf.readthedocs.io)（同样适用于 TF-DF）\n-   [问题追踪器](https:\u002F\u002Fgithub.com\u002Ftensorflow\u002Fdecision-forests\u002Fissues)\n-   [已知问题](documentation\u002Fknown_issues.md)\n-   [变更日志](CHANGELOG.md)\n-   [更多示例](documentation\u002Fmore_examples.md)\n\n## 安装\n\n要安装 TensorFlow 决策森林，请运行：\n\n```shell\npip3 install tensorflow_decision_forests --upgrade\n```\n\n更多详细信息、故障排除及替代安装方案，请参阅 [安装页面](documentation\u002Finstallation.md)。\n\n## 贡献\n\n欢迎为 TensorFlow 决策森林和 Yggdrasil 决策森林做出贡献。如果您希望参与贡献，请务必阅读\n[开发者手册](documentation\u002Fdeveloper_manual.md) 和\n[贡献指南](CONTRIBUTING.md)。\n\n## 引用\n\n如果您在科学出版物中使用了 TensorFlow 决策森林，请引用以下论文：\n[Yggdrasil 决策森林：一个快速且可扩展的决策森林库](https:\u002F\u002Fdoi.org\u002F10.1145\u002F3580305.3599933)。\n\n**Bibtex**\n\n```\n@inproceedings{GBBSP23,\n  author       = {Mathieu Guillame{-}Bert and\n                  Sebastian Bruch and\n                  Richard Stotz and\n                  Jan Pfeifer},\n  title        = {Yggdrasil Decision Forests: {A} Fast and Extensible Decision Forests\n                  Library},\n  booktitle    = {Proceedings of the 29th {ACM} {SIGKDD} Conference on Knowledge Discovery\n                  and Data Mining, {KDD} 2023, Long Beach, CA, USA, August 6-10, 2023},\n  pages        = {4068--4077},\n  year         = {2023},\n  url          = {https:\u002F\u002Fdoi.org\u002F10.1145\u002F3580305.3599933},\n  doi          = {10.1145\u002F3580305.3599933},\n}\n```\n\n**原文**\n\nYggdrasil 决策森林：一个快速且可扩展的决策森林库，Guillame-Bert 等人，KDD 2023：4068–4077。doi：10.1145\u002F3580305.3599933\n\n## 联系方式\n\n您可以通过电子邮件 [decision-forests-contact@google.com](mailto:decision-forests-contact@google.com) 联系核心开发团队。\n\n## 致谢\n\nTensorFlow 决策森林由以下人员开发：\n\n-   Mathieu Guillame-Bert (gbm AT google DOT com)\n-   Jan Pfeifer (janpf AT google DOT com)\n-   Richard Stotz (richardstotz AT google DOT com)\n-   Sebastian Bruch (sebastian AT bruch DOT io)\n-   Arvind Srinivasan (arvnd AT google DOT com)\n\n## 许可证\n\n[Apache License 2.0](LICENSE)","# TensorFlow Decision Forests 快速上手指南\n\n> **重要提示**：官方建议新用户迁移至 **Yggdrasil Decision Forests (YDF)**。YDF 能训练与 TF-DF 相同的模型，但速度更快且功能更丰富。如需了解迁移细节，请参考官方迁移指南。\n\nTensorFlow Decision Forests (TF-DF) 是一个用于在 TensorFlow 中训练、运行和解释决策森林模型（如随机森林、梯度提升树）的库。它支持分类、回归和排序任务，底层由 C++ 编写的 Yggdrasil Decision Forests 驱动。\n\n## 环境准备\n\n*   **操作系统**：\n    *   Linux\n    *   macOS\n    *   Windows：需通过 **WSL (Windows Subsystem for Linux)** 使用。\n*   **前置依赖**：\n    *   Python 3.x\n    *   TensorFlow\n    *   Pandas (用于数据处理示例)\n\n## 安装步骤\n\n使用 pip 进行安装。国内开发者如遇下载缓慢，可指定清华或阿里镜像源加速安装。\n\n**标准安装命令：**\n```shell\npip3 install tensorflow_decision_forests --upgrade\n```\n\n**使用国内镜像源加速（推荐）：**\n```shell\npip3 install tensorflow_decision_forests --upgrade -i https:\u002F\u002Fpypi.tuna.tsinghua.edu.cn\u002Fsimple\n```\n\n*注：更多安装细节及故障排查请参阅官方安装文档。*\n\n## 基本使用\n\n以下是一个完整的端到端最小化示例，展示如何加载数据、训练随机森林模型并进行评估。\n\n```python\nimport tensorflow_decision_forests as tfdf\nimport pandas as pd\n\n# 1. 使用 Pandas 加载数据集\ntrain_df = pd.read_csv(\"project\u002Ftrain.csv\")\ntest_df = pd.read_csv(\"project\u002Ftest.csv\")\n\n# 2. 将数据集转换为 TensorFlow 数据集\n# label 参数指定目标列名\ntrain_ds = tfdf.keras.pd_dataframe_to_tf_dataset(train_df, label=\"my_label\")\ntest_ds = tfdf.keras.pd_dataframe_to_tf_dataset(test_df, label=\"my_label\")\n\n# 3. 创建并训练模型 (此处以随机森林为例)\nmodel = tfdf.keras.RandomForestModel()\nmodel.fit(train_ds)\n\n# 4. 查看模型结构\nmodel.summary()\n\n# 5. 评估模型性能\nmodel.evaluate(test_ds)\n\n# 6. 导出为 TensorFlow SavedModel\n# 注意：导出的模型与 Yggdrasil Decision Forests 兼容\nmodel.save(\"project\u002Fmodel\")\n```\n\n### 后续资源\n*   **官方教程**：[TensorFlow.org 教程页面](https:\u002F\u002Fwww.tensorflow.org\u002Fdecision_forests\u002Ftutorials)\n*   **API 文档**：[TF-DF on TensorFlow.org](https:\u002F\u002Ftensorflow.org\u002Fdecision_forests)\n*   **底层引擎文档**：[YDF Documentation](https:\u002F\u002Fydf.readthedocs.io)","某电商数据团队需要基于用户行为日志构建高准确率的购买转化预测模型，以优化广告投放策略。\n\n### 没有 decision-forests 时\n- **框架割裂严重**：团队习惯使用 TensorFlow 构建深度学习流水线，但处理表格数据时不得不引入 Scikit-learn 训练随机森林，导致数据预处理和模型服务需维护两套独立代码库。\n- **调参门槛极高**：传统梯度提升树（如 XGBoost）对超参数敏感，数据科学家需花费数天手动调整树深、学习率等参数，且难以在 Keras 统一接口下自动化实验。\n- **模型解释性差**：业务方要求清晰了解“哪些特征驱动了预测”，但原有方案缺乏原生集成化的特征重要性可视化工具，需额外编写复杂脚本提取逻辑。\n- **部署兼容性问题**：将非 TensorFlow 训练的模型嵌入现有的 TF Serving 生产环境时，常遇到格式转换错误和推理延迟波动，增加了运维风险。\n\n### 使用 decision-forests 后\n- **原生无缝集成**：直接在 Keras 中调用 `RandomForestModel`，无需切换框架即可将表格数据训练纳入统一的 TensorFlow 数据管道（tf.data），代码量减少 40%。\n- **开箱即用的性能**：内置先进的 Yggdrasil 算法引擎，默认参数下即可达到业界 SOTA 水平，自动处理缺失值和类别特征，大幅缩短模型迭代周期。\n- **内置可解释性分析**：通过 `model.summary()` 和内置绘图功能，一键生成特征重要性排名和部分依赖图，轻松向非技术 stakeholders 展示决策逻辑。\n- **平滑生产部署**：训练出的模型可直接保存为 SavedModel 格式，完美兼容现有 TF Serving 基础设施，实现了从训练到推理的零摩擦上线。\n\ndecision-forests 让表格数据建模拥有了与深度学习同等的工程体验，显著提升了算法团队的研发效率与模型落地速度。","https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Ftensorflow_decision-forests_33c7cca1.png","tensorflow","https:\u002F\u002Foss.gittoolsai.com\u002Favatars\u002Ftensorflow_07ed5093.png","",null,"github-admin@tensorflow.org","http:\u002F\u002Fwww.tensorflow.org","https:\u002F\u002Fgithub.com\u002Ftensorflow",[81,85,89,93,97,101,105],{"name":82,"color":83,"percentage":84},"Python","#3572A5",72.3,{"name":86,"color":87,"percentage":88},"C++","#f34b7d",19.6,{"name":90,"color":91,"percentage":92},"Starlark","#76d275",4.4,{"name":94,"color":95,"percentage":96},"Shell","#89e051",1.9,{"name":98,"color":99,"percentage":100},"JavaScript","#f1e05a",1.1,{"name":102,"color":103,"percentage":104},"PureBasic","#5a6986",0.5,{"name":106,"color":107,"percentage":108},"Batchfile","#C1F12E",0.2,694,116,"2026-04-08T08:38:14","Apache-2.0",1,"Linux, macOS","未说明",{"notes":117,"python":115,"dependencies":118},"Windows 用户需通过 WSL+Linux 使用该库。官方建议用户迁移至 Yggdrasil Decision Forests (YDF) 以获得更快的速度和更多功能。模型与 YDF 兼容。",[119,120,73],"tensorflow_decision_forests","pandas",[14],[123,124,125,73,126,127,128,129,130,131],"python","machine-learning","random-forest","ml","decision-trees","gradient-boosting","interpretability","decision-forest","keras","2026-03-27T02:49:30.150509","2026-04-15T06:50:17.420219",[135,140,145,150,155,160],{"id":136,"question_zh":137,"answer_zh":138,"source_url":139},33809,"在 Mac 或其他系统上运行 pip install tensorflow_decision_forests 时提示找不到版本怎么办？","请确保使用正确的包名，PyPI 上的包名包含连字符而非下划线。应运行命令：`pip3 install tensorflow-decision-forests --upgrade`。如果问题仍然存在（如在 Fedora 或 Mac M2 上），可能是特定平台的兼容性问题，建议检查是否已正确安装对应版本的 TensorFlow（如 tensorflow-macos 和 tensorflow-metal），并将详细错误信息提交为新 Issue 以便进一步调查。","https:\u002F\u002Fgithub.com\u002Ftensorflow\u002Fdecision-forests\u002Fissues\u002F16",{"id":141,"question_zh":142,"answer_zh":143,"source_url":144},33810,"训练模型时出现 'AbstractFeatureResourceE does not exist' 或类似 NotFoundError 错误如何解决？","该问题已在 0.1.5 版本中修复。请升级库到最新版本：`pip install --upgrade tensorflow-decision-forests`。此外，确保不要将回归任务的数据误用于分类模型，否则会导致模型异常庞大且报错。新版已增加对此类情况的警告或错误提示。","https:\u002F\u002Fgithub.com\u002Ftensorflow\u002Fdecision-forests\u002Fissues\u002F4",{"id":146,"question_zh":147,"answer_zh":148,"source_url":149},33811,"调用 GradientBoostedTreesModel 进行预测时出现 AssertionError: len(self._semantics) == 1 错误怎么办？","此错误通常发生在直接传入原始张量而非符合模型输入语义格式的数据时。请确保输入数据通过 `tfdf.keras.pd_dataframe_to_tf_dataset` 转换，或按照官方示例代码构建输入。参考社区提供的可用示例代码可解决该问题，避免直接传递 numpy 数组给模型调用。","https:\u002F\u002Fgithub.com\u002Ftensorflow\u002Fdecision-forests\u002Fissues\u002F95",{"id":151,"question_zh":152,"answer_zh":153,"source_url":154},33812,"决策树中分类节点和数值节点的分裂路径方向为何不同？是预期行为吗？","是的，这是预期行为。对于分类节点，满足阈值条件时路径向左；对于数值节点，满足条件时路径向右。如需可视化验证决策路径，可使用 dtreeviz 工具，官方教程参见：https:\u002F\u002Fwww.tensorflow.org\u002Fdecision_forests\u002Ftutorials\u002Fdtreeviz_colab","https:\u002F\u002Fgithub.com\u002Ftensorflow\u002Fdecision-forests\u002Fissues\u002F111",{"id":156,"question_zh":157,"answer_zh":158,"source_url":159},33813,"使用预编译的 tensorflow_model_server 部署模型时出现 GLIBC 版本不匹配错误如何解决？","该错误源于预编译二进制文件所依赖的 GLIBC 版本高于当前容器或系统版本。解决方案包括：1) 使用与预编译包匹配的更高版本基础镜像（如更新 Ubuntu 版本）；2) 自行从源码编译 tensorflow_model_server 以适配当前环境；3) 尝试其他兼容的 tf-serving 镜像版本。目前尚无官方提供完全兼容低版本 GLIBC 的预编译包。","https:\u002F\u002Fgithub.com\u002Ftensorflow\u002Fdecision-forests\u002Fissues\u002F124",{"id":161,"question_zh":162,"answer_zh":163,"source_url":139},33814,"Mac M2 芯片上导入 tensorflow_decision_forests 导致 VSCode\u002FJupyter 内核崩溃怎么办？","在 Mac M2 上需确保安装专为 Apple Silicon 优化的 TensorFlow 组件：`tensorflow-macos` 和 `tensorflow-metal`，并搭配兼容版本的 `tensorflow-decision-forests`（如 1.1.0）。若仍崩溃，请尝试重建虚拟环境、升级所有相关包至最新稳定版，并检查是否有原生扩展冲突。如问题持续，建议提交包含完整堆栈跟踪的新 Issue。",[165,170,175,180,185,190,195,200,205,210,215,220,225,230,235,240,245,250,255,260],{"id":166,"version":167,"summary_zh":168,"released_at":169},263661,"v1.10.1","# 1.10.1 - 2025-03-27\n\n## 修复\n\n-   修复与 TensorFlow 2.17.1 的兼容性。","2025-03-28T19:28:13",{"id":171,"version":172,"summary_zh":173,"released_at":174},263662,"v1.12.0","# 1.12.0 - 2025-03-13\n\n## 功能\n\n-   新增对 Python 3.12 的支持。\n-   新增用于配置稀疏斜分割的超参数：\n    `sparse_oblique_max_num_features`、`sparse_oblique_weights_integer_maximum`、`sparse_oblique_weights_integer_minimum`、\n    `sparse_oblique_weights_power_of_two_max_exponent`、`sparse_oblique_weights_power_of_two_min_exponent`。\n\n## 修复\n\n-   修复与 TF 2.19.0 的兼容性问题。\n-   修复对包含非 Unicode 值的分类变量的处理。\n-   修复与新 YDF 模型的兼容性。\n-   多处文档改进。","2025-03-13T12:58:46",{"id":176,"version":177,"summary_zh":178,"released_at":179},263663,"v1.11.0","## 1.11.0 - 2024-10-28\n\n### 功能\n\n-   将 LAMBDA_MART_NDCG5 损失函数重命名为 LAMBDA_MART_NDCG。旧的损失函数仍然可用。现在可以通过超参数来修改 NDCG 的截断值。\n-   在启动时向用户提示有关 ydf 的信息。可通过设置环境变量 TFDF_DISABLE_WELCOME_MESSAGE 来禁用该提示。\n\n### 修复\n\n-   部分错误现在会抛出 InvalidArgumentError，而不是 UnknownError。\n-   修复了与 TensorFlow 2.18.0 的兼容性问题。","2024-10-28T13:49:33",{"id":181,"version":182,"summary_zh":183,"released_at":184},263664,"v1.10.0","## 1.10.0 - 2024-08-21\n\n### 修复\n\n-   修复与 TensorFlow 2.17.0 的兼容性。\n-   修复 macOS 构建问题。","2024-08-21T19:49:44",{"id":186,"version":187,"summary_zh":188,"released_at":189},263665,"v1.9.2","# 1.9.2 - 2024-07-04\n\n## 修复\n\n-   修复与 TF 2.16.2 的兼容性。\n-   修复构建问题。\n\n## 已知问题\n\n-   由于依赖项存在问题，目前无法提供 macOS 版本的构建。","2024-07-09T08:49:36",{"id":191,"version":192,"summary_zh":193,"released_at":194},263666,"v1.9.1","### 修复\n\n-   解决 PYDF 和 TF-DF 之间 YDF Proto 的依赖冲突。","2024-05-08T13:54:29",{"id":196,"version":197,"summary_zh":198,"released_at":199},263667,"v1.9.0","# 1.9.0 - 2024-03-12\n\n## 修复\n\n-   修复了 `max_depth` 和早停参数的文档。\n-   修复了绘图中包含条件的问题。\n\n## 功能\n\n-   兼容 TensorFlow 2.16.0。\n-   暴露了新的参数 `sparse_oblique_max_num_projections`。\n-   在示例和文档中使用 `tf_keras` 替代 `tf.keras`。\n-   支持快速引擎中的 `NAConditions`。\n-   加快了具有大量特征和密集斜向条件的模型加载速度。\n\n## 文档\n\n-   清晰化了斜向分裂相关参数的文档说明。","2024-03-14T10:30:16",{"id":201,"version":202,"summary_zh":203,"released_at":204},263668,"v.1.9.0rc0","## 1.9.0rc0 - 2024-02-26\n\n### 修复\n\n- 修复 `max_depth` 和提前停止参数的文档。\n- 修复绘图中包含条件的问题。\n\n### 功能\n\n- 兼容 TensorFlow 2.16.0rc0。\n- 兼容 YDF 1.9.0。\n- 在示例和文档中使用 `tf_keras` 替代 `tf.keras`。\n- 支持快速引擎中的 `NAConditions`。","2024-03-06T08:56:06",{"id":206,"version":207,"summary_zh":208,"released_at":209},263669,"v.1.8.1","## 1.8.1 - 2023-11-17\n\n### 修复\n\n-   均方误差损失和平均绝对误差损失在回归任务中错误地对梯度进行了截断，导致预测结果不正确。","2023-11-17T17:03:16",{"id":211,"version":212,"summary_zh":213,"released_at":214},263670,"1.8.0","## 1.8.0 - 2023-11-15\n\n### 功能\n\n-   兼容 TensorFlow 2.15.0。\n-   Inspector 支持升级功能。\n\n### 修复\n\n-   加载模型时发出的警告减少。","2023-11-17T14:54:52",{"id":216,"version":217,"summary_zh":218,"released_at":219},263671,"v1.6.0","## 1.6.0 2023-09-27\r\n\r\n### Breaking Changes\r\n\r\n-   TF-DF no longer supports Python 3.8 since Tensorflow dropped its support.\r\n\r\n### Features\r\n\r\n-   Compatibility with Tensorflow 2.14.0\r\n-   Contrib: Training preprocessing jointly on the input features, labels and \r\n    weights\r\n\r\n### Fix\r\n\r\n-   Incorrect model predictions for models without features\r\n-   Data race for model resources","2023-09-28T14:21:12",{"id":221,"version":222,"summary_zh":223,"released_at":224},263672,"1.5.0","## 1.5.0 - 2023-07-06\r\n\r\n### Features\r\n\r\n-   Compatibility with Tensorflow 2.13.0","2023-07-24T05:56:14",{"id":226,"version":227,"summary_zh":228,"released_at":229},263673,"1.4.0","### Features\r\n\r\n-   Support for multi-task learning.\r\n-   New tutorial for TF-DF \u003C--> TF.js\r\n-   Support for uplift modeling in the model inspector.\r\n-   New tutorial for Uplift modeling.\r\n-   Bump Bazel version to 6.1.0.\r\n\r\n### Fix\r\n\r\n-   Regex to generate Bazel workspace.\r\n-   Remove warning when converting Keras -> YDF.\r\n-   Fixed default hyperparameter issue Github #172.\r\n-   Various documentation issues fixed.","2023-07-04T11:11:15",{"id":231,"version":232,"summary_zh":233,"released_at":234},263674,"1.3.0","### Features\r\n\r\n-   Check learner parameters during the model construction.\r\n-   Fix discretized numerical features for regression task.\r\n-   Allow for float32 values to be fed as categorical features.\r\n-   Add new \u002F improved tutorials for ranking and visualization.\r\n-   Compatibility with Tensorflow 2.12.0. Unfortunately, this means dropping\r\n    support for Python 3.7.\r\n\r\n### Fix\r\n\r\n-   Fix crashes when using ranking with very large groups.\r\n-   Add option to set the port used by YDF in TF-DF distributed training.\r\n-   Improve logging robustness.","2023-03-24T13:14:43",{"id":236,"version":237,"summary_zh":238,"released_at":239},263675,"1.2.0","### Features\r\n\r\n-   Add support for distributed training and distributed hyper-parameter tuning\r\n    in the OSS build. See\r\n    https:\u002F\u002Fwww.tensorflow.org\u002Fdecision_forests\u002Fdistributed_training\r\n-   Setting \"subsample\" is enough enable random subsampling (to need to also set\r\n    \"sampling_method=RANDOM\").\r\n-   Add \"min_vocab_frequency\" argument in \"FeatureUsage\" to control the minimum\r\n    frequency of categorical items.\r\n-   Add \"override_global_imputation_value\" argument in \"FeatureUsage\" to\r\n    override the value used for global imputation of missing value by the\r\n    global-imputation algorithm.\r\n-   The Tuner argument \"use_predefined_hps\" automatically configures the set of\r\n    hyper-parameters to explore during automatic hyper-parameter tuning.\r\n-   Replaces the MEAN_MIN_DEPTH variable importance with INV_MEAN_MIN_DEPTH.\r\n-   Add option to forbid model inference with the slow inference engine.\r\n\r\n### Fix\r\n\r\n-   Automatic documentation generation for RandomForestModel and other classes.","2023-01-25T12:47:14",{"id":241,"version":242,"summary_zh":243,"released_at":244},263676,"1.1.0","## 1.1.0 - 2022-11-18\r\n\r\n### Features\r\n\r\n-   Native support for TensorFlow Decision Forests in TensorFlow Serving.\r\n-   Add support for zipped Yggdrasil Decision Forests model for\r\n    `yggdrasil_model_to_keras_model`.\r\n-   Added model prediction tutorial.\r\n-   Prevent premature stopping of GBT training through new parameter\r\n    `early_stopping_initial_iteration`.\r\n\r\n### Fix\r\n\r\n-   Using loaded datasets with TF-DF no longer fails (Github #131).\r\n-   Automatically infer the semantic of int8 values as numerical (was\r\n    categorical before).\r\n-   Build script fixed\r\n-   Model saving no longer fails when using invalid feature names.\r\n-   Added keyword to pandas dataset drop (Github #135).","2022-11-18T18:34:15",{"id":246,"version":247,"summary_zh":248,"released_at":249},263677,"1.1.0rc2","# Features\r\n- Support for Tensorflow Serving APIs.\r\n- Add support for zipped Yggdrasil Decision Forests model for yggdrasil_model_to_keras_model.\r\n- Added model prediction tutorial.\r\n- Prevent premature stopping of GBT training through new parameter early_stopping_initial_iteration.\r\n# Fix\r\n- Using loaded datasets with TF-DF no longer fails (Github #131).\r\n- Automatically infer the semantic of int8 values as numerical (was categorical before).\r\n- Build script fixed\r\n- Model saving no longer fails when using invalid feature names.\r\n- Added keyword to pandas dataset drop (Github #135).\r\n","2022-11-10T07:50:15",{"id":251,"version":252,"summary_zh":253,"released_at":254},263678,"serving-1.0.1","Nightly build of TensorFlow Serving 2.11.\r\nTensorFlow Serving >=2.11 supports natively TensorFlow Decision Forests models.\r\n\r\nBuild instructions:\r\n\r\n```shell\r\ngit clone https:\u002F\u002Fgithub.com\u002Ftensorflow\u002Fserving.git\r\ndocker run -it -v ${PWD}\u002F..:\u002Fworking_dir -w \u002Fworking_dir\u002Fserving tensorflow\u002Fserving:nightly-devel bash\r\nbazel build \u002F\u002Ftensorflow_serving\u002Fmodel_servers:tensorflow_model_server\r\n```","2022-09-20T09:13:19",{"id":256,"version":257,"summary_zh":258,"released_at":259},263679,"macos-1.0.1","## Experimental TF-DF Release for MacOS\r\n\r\nThis pre-release is designed to help testing a release for TF-DF 1.0.1 with different MacOS versions. \r\n\r\nMake sure you pick a version corresponding to your MacOS version and Python version.","2022-09-16T15:01:09",{"id":261,"version":262,"summary_zh":263,"released_at":264},263680,"1.0.1","# TensorFlow Decision Forests 1.0.1\r\n\r\nWith this release, TensorFlow Decision Forests finally reaches its first major release 🥳 \r\n\r\nWith this milestone we want to communicate more broadly that TensorFlow Decision Forests has become a more stable and mature library. In particular, we established more comprehensive testing to make sure that TF-DF is ready for professional environments.\r\n\r\n### Features\r\n\r\n-   Add customization of the number of IO threads when using `fit_on_dataset_path`.\r\n\r\n### Fix\r\n\r\n-   Improved documentation\r\n-   Improved testing and stability\r\n-   Issue in the application of auditwheel\r\n","2022-09-07T16:22:53"]