[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"similar-online-ml--river":3,"tool-online-ml--river":64},[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},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,3,"2026-04-05T11:01:52",[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},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 真正成长为懂上",138956,2,"2026-04-05T11:33:21",[13,15,26],"语言模型",{"id":28,"name":29,"github_repo":30,"description_zh":31,"stars":32,"difficulty_score":23,"last_commit_at":33,"category_tags":34,"status":16},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 都能提供强大的支持。其独特的模块化架构允许社区不断扩展新功能，使其成为当前最灵活、生态最丰富的开源扩散模型工具之一，帮助用户将创意高效转化为现实。",107662,"2026-04-03T11:11:01",[13,14,15],{"id":36,"name":37,"github_repo":38,"description_zh":39,"stars":40,"difficulty_score":23,"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,26],{"id":44,"name":45,"github_repo":46,"description_zh":47,"stars":48,"difficulty_score":23,"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 将是理想的起点。",84991,"2026-04-05T10:45:23",[14,51,52,53,15,54,26,13,55],"数据工具","视频","插件","其他","音频",{"id":57,"name":58,"github_repo":59,"description_zh":60,"stars":61,"difficulty_score":10,"last_commit_at":62,"category_tags":63,"status":16},3128,"ragflow","infiniflow\u002Fragflow","RAGFlow 是一款领先的开源检索增强生成（RAG）引擎，旨在为大语言模型构建更精准、可靠的上下文层。它巧妙地将前沿的 RAG 技术与智能体（Agent）能力相结合，不仅支持从各类文档中高效提取知识，还能让模型基于这些知识进行逻辑推理和任务执行。\n\n在大模型应用中，幻觉问题和知识滞后是常见痛点。RAGFlow 通过深度解析复杂文档结构（如表格、图表及混合排版），显著提升了信息检索的准确度，从而有效减少模型“胡编乱造”的现象，确保回答既有据可依又具备时效性。其内置的智能体机制更进一步，使系统不仅能回答问题，还能自主规划步骤解决复杂问题。\n\n这款工具特别适合开发者、企业技术团队以及 AI 研究人员使用。无论是希望快速搭建私有知识库问答系统，还是致力于探索大模型在垂直领域落地的创新者，都能从中受益。RAGFlow 提供了可视化的工作流编排界面和灵活的 API 接口，既降低了非算法背景用户的上手门槛，也满足了专业开发者对系统深度定制的需求。作为基于 Apache 2.0 协议开源的项目，它正成为连接通用大模型与行业专有知识之间的重要桥梁。",77062,"2026-04-04T04:44:48",[15,14,13,26,54],{"id":65,"github_repo":66,"name":67,"description_en":68,"description_zh":69,"ai_summary_zh":69,"readme_en":70,"readme_zh":71,"quickstart_zh":72,"use_case_zh":73,"hero_image_url":74,"owner_login":75,"owner_name":76,"owner_avatar_url":77,"owner_bio":78,"owner_company":79,"owner_location":79,"owner_email":79,"owner_twitter":79,"owner_website":80,"owner_url":81,"languages":82,"stars":102,"forks":103,"last_commit_at":104,"license":105,"difficulty_score":106,"env_os":107,"env_gpu":108,"env_ram":108,"env_deps":109,"category_tags":113,"github_topics":114,"view_count":23,"oss_zip_url":79,"oss_zip_packed_at":79,"status":16,"created_at":127,"updated_at":128,"faqs":129,"releases":159},3785,"online-ml\u002Friver","river","🌊 Online machine learning in Python","River 是一个专为 Python 打造的在线机器学习库，旨在让流式数据处理变得简单高效。与传统机器学习需要一次性加载全部数据不同，River 能够逐条接收并实时学习新数据，边预测边更新模型。这一特性完美解决了数据源源不断产生、内存受限或需要即时响应的场景难题，例如金融欺诈检测、物联网传感器分析或实时推荐系统。\n\nRiver 非常适合开发者、数据科学家及研究人员使用，特别是那些希望在不依赖庞大算力的情况下构建敏捷智能应用的团队。它的独特亮点在于由两个知名项目 creme 和 scikit-multiflow 合并而成，集成了丰富的线性模型、决策树及集成算法，并针对流式计算进行了深度优化。此外，River 拥有类似 Scikit-learn 的友好接口，上手门槛低，同时底层结合 Cython 和 Rust 技术以确保高性能运行。无论是快速原型验证还是生产环境部署，River 都能提供稳定且灵活的支持，帮助用户轻松驾驭动态数据流。","\u003Cp align=\"center\">\n  \u003Cimg height=\"220px\" src=\"https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fonline-ml_river_readme_6c1050196199.png\" alt=\"river_logo\">\n\u003C\u002Fp>\n\n\u003Cp align=\"center\">\n  \u003C!-- Code quality -->\n  \u003Ca href=\"https:\u002F\u002Fgithub.com\u002Fonline-ml\u002Friver\u002Factions\u002Fworkflows\u002Fcode-quality.yml\">\n    \u003Cimg src=\"https:\u002F\u002Fgithub.com\u002Fonline-ml\u002Friver\u002Factions\u002Fworkflows\u002Fcode-quality.yml\u002Fbadge.svg\" alt=\"code-quality\">\n  \u003C\u002Fa>\n  \u003C!-- Documentation -->\n  \u003Ca href=\"https:\u002F\u002Friverml.xyz\">\n    \u003Cimg src=\"https:\u002F\u002Fimg.shields.io\u002Fwebsite?label=docs&style=flat-square&url=https%3A%2F%2Friverml.xyz%2F\" alt=\"documentation\">\n  \u003C\u002Fa>\n  \u003C!-- PyPI -->\n  \u003Ca href=\"https:\u002F\u002Fpypi.org\u002Fproject\u002Friver\">\n    \u003Cimg src=\"https:\u002F\u002Fimg.shields.io\u002Fpypi\u002Fv\u002Friver.svg?label=release&color=blue&style=flat-square\" alt=\"pypi\">\n  \u003C\u002Fa>\n  \u003C!-- PePy -->\n  \u003Ca href=\"https:\u002F\u002Fpepy.tech\u002Fproject\u002Friver\">\n    \u003Cimg src=\"https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fonline-ml_river_readme_150dfe653354.png\" alt=\"pepy\">\n  \u003C\u002Fa>\n  \u003C!-- Mypy -->\n  \u003Ca href=\"http:\u002F\u002Fmypy-lang.org\u002F\">\n    \u003Cimg src=\"http:\u002F\u002Fwww.mypy-lang.org\u002Fstatic\u002Fmypy_badge.svg\" alt=\"mypy\">\n  \u003C\u002Fa>\n  \u003C!-- License -->\n  \u003Ca href=\"https:\u002F\u002Fopensource.org\u002Flicenses\u002FBSD-3-Clause\">\n    \u003Cimg src=\"https:\u002F\u002Fimg.shields.io\u002Fbadge\u002FLicense-BSD%203--Clause-blue.svg?style=flat-square\" alt=\"bsd_3_license\">\n  \u003C\u002Fa>\n\u003C\u002Fp>\n\n\u003C\u002Fbr>\n\n\u003Cp align=\"center\">\n  River is a Python library for \u003Ca href=\"https:\u002F\u002Fwww.wikiwand.com\u002Fen\u002FOnline_machine_learning\">online machine learning\u003C\u002Fa>. It aims to be the most user-friendly library for doing machine learning on streaming data. River is the result of a merger between \u003Ca href=\"https:\u002F\u002Fgithub.com\u002FMaxHalford\u002Fcreme\">creme\u003C\u002Fa> and \u003Ca href=\"https:\u002F\u002Fgithub.com\u002Fscikit-multiflow\u002Fscikit-multiflow\">scikit-multiflow\u003C\u002Fa>.\n\u003C\u002Fp>\n\n## ⚡️ Quickstart\n\nAs a quick example, we'll train a logistic regression to classify the [website phishing dataset](http:\u002F\u002Farchive.ics.uci.edu\u002Fml\u002Fdatasets\u002FWebsite+Phishing). Here's a look at the first observation in the dataset.\n\n```python\n>>> from pprint import pprint\n>>> from river import datasets\n\n>>> dataset = datasets.Phishing()\n\n>>> for x, y in dataset:\n...     pprint(x)\n...     print(y)\n...     break\n{'age_of_domain': 1,\n 'anchor_from_other_domain': 0.0,\n 'empty_server_form_handler': 0.0,\n 'https': 0.0,\n 'ip_in_url': 1,\n 'is_popular': 0.5,\n 'long_url': 1.0,\n 'popup_window': 0.0,\n 'request_from_other_domain': 0.0}\nTrue\n\n```\n\nNow let's run the model on the dataset in a streaming fashion. We sequentially interleave predictions and model updates. Meanwhile, we update a performance metric to see how well the model is doing.\n\n```python\n>>> from river import compose\n>>> from river import linear_model\n>>> from river import metrics\n>>> from river import preprocessing\n\n>>> model = compose.Pipeline(\n...     preprocessing.StandardScaler(),\n...     linear_model.LogisticRegression()\n... )\n\n>>> metric = metrics.Accuracy()\n\n>>> for x, y in dataset:\n...     y_pred = model.predict_one(x)      # make a prediction\n...     metric.update(y, y_pred)           # update the metric\n...     model.learn_one(x, y)              # make the model learn\n\n>>> metric\nAccuracy: 89.28%\n\n```\n\nOf course, this is just a contrived example. We welcome you to check the [introduction](https:\u002F\u002Friverml.xyz\u002Fdev\u002Fintroduction\u002Finstallation\u002F) section of the documentation for a more thorough tutorial.\n\n## 🛠 Installation\n\nRiver is intended to work with **Python 3.10 and above**. Installation can be done with `pip`:\n\n```sh\npip install river\n```\n\nThere are [wheels available](https:\u002F\u002Fpypi.org\u002Fproject\u002Friver\u002F#files) for Linux, MacOS, and Windows. This means you most probably won't have to build River from source.\n\nYou can install the latest development version from GitHub as so:\n\n```sh\npip install git+https:\u002F\u002Fgithub.com\u002Fonline-ml\u002Friver --upgrade\npip install git+ssh:\u002F\u002Fgit@github.com\u002Fonline-ml\u002Friver.git --upgrade  # using SSH\n```\n\nThis method requires having Cython and Rust installed on your machine.\n\n## 🔮 Features\n\nRiver provides online implementations of the following family of algorithms:\n\n- Linear models, with a wide array of optimizers\n- Decision trees and random forests\n- (Approximate) nearest neighbors\n- Anomaly detection\n- Drift detection\n- Recommender systems\n- Time series forecasting\n- Bandits\n- Factorization machines\n- Imbalanced learning\n- Clustering\n- Bagging\u002Fboosting\u002Fstacking\n- Active learning\n\nRiver also provides other online utilities:\n\n- Feature extraction and selection\n- Online statistics and metrics\n- Preprocessing\n- Built-in datasets\n- Progressive model validation\n- Model pipelines\n\nCheck out [the API](https:\u002F\u002Friverml.xyz\u002Flatest\u002Fapi\u002Foverview\u002F) for a comprehensive overview\n\n## 🤔 Should I be using River?\n\nYou should ask yourself if you need online machine learning. The answer is likely no. Most of the time batch learning does the job just fine. An online approach might fit the bill if:\n\n- You want a model that can learn from new data without having to revisit past data.\n- You want a model which is robust to [concept drift](https:\u002F\u002Fwww.wikiwand.com\u002Fen\u002FConcept_drift).\n- You want to develop your model in a way that is closer to what occurs in a production context, which is usually event-based.\n\nSome specificities of River are that:\n\n- It focuses on clarity and user experience, more so than performance.\n- It's very fast at processing one sample at a time. Try it, you'll see.\n- It plays nicely with the rest of Python's ecosystem.\n\n## 🔗 Useful links\n\n- [Documentation](https:\u002F\u002Friverml.xyz)\n- [Package releases](https:\u002F\u002Fpypi.org\u002Fproject\u002Friver\u002F#history)\n- [awesome-online-machine-learning](https:\u002F\u002Fgithub.com\u002Fonline-ml\u002Fawesome-online-machine-learning)\n- [2022 presentation at GAIA](https:\u002F\u002Fwww.youtube.com\u002Fwatch?v=nzFTmJnIakk&list=PLIU25-FciwNaz5PqWPiHmPCMOFYoEsJ8c&index=5)\n- [Online Clustering: Algorithms, Evaluation, Metrics, Applications and Benchmarking](https:\u002F\u002Fdl.acm.org\u002Fdoi\u002F10.1145\u002F3534678.3542600) from [KDD'22](https:\u002F\u002Fkdd.org\u002Fkdd2022\u002F).\n\n## 👐 Contributing\n\nFeel free to contribute in any way you like, we're always open to new ideas and approaches.\n\n- [Open a discussion](https:\u002F\u002Fgithub.com\u002Fonline-ml\u002Friver\u002Fdiscussions\u002Fnew) if you have any question or enquiry whatsoever. It's more useful to ask your question in public rather than sending us a private email. It's also encouraged to open a discussion before contributing, so that everyone is aligned and unnecessary work is avoided.\n- Feel welcome to [open an issue](https:\u002F\u002Fgithub.com\u002Fonline-ml\u002Friver\u002Fissues\u002Fnew\u002Fchoose) if you think you've spotted a bug or a performance issue.\n- Our [roadmap](https:\u002F\u002Fgithub.com\u002Forgs\u002Fonline-ml\u002Fprojects\u002F3?query=is%3Aopen+sort%3Aupdated-desc) is public. Feel free to work on anything that catches your eye, or to make suggestions.\n\nPlease check out the [contribution guidelines](https:\u002F\u002Fgithub.com\u002Fonline-ml\u002Friver\u002Fblob\u002Fmain\u002FCONTRIBUTING.md) if you want to bring modifications to the code base.\n\n## 🤝 Affiliations\n\n\u003Cp align=\"center\">\n  \u003Cimg width=\"70%\" src=\"https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fonline-ml_river_readme_824054caf584.png\" alt=\"affiliations\">\n\u003C\u002Fp>\n\n## 💬 Citation\n\nIf River has been useful to you, and you would like to cite it in a scientific publication, please refer to the [paper](https:\u002F\u002Fwww.jmlr.org\u002Fpapers\u002Fvolume22\u002F20-1380\u002F20-1380.pdf) published at JMLR:\n\n```bibtex\n@article{montiel2021river,\n  title={River: machine learning for streaming data in Python},\n  author={Montiel, Jacob and Halford, Max and Mastelini, Saulo Martiello\n          and Bolmier, Geoffrey and Sourty, Raphael and Vaysse, Robin and Zouitine, Adil\n          and Gomes, Heitor Murilo and Read, Jesse and Abdessalem, Talel and others},\n  year={2021}\n}\n```\n\n## 📝 License\n\nRiver is free and open-source software licensed under the [3-clause BSD license](https:\u002F\u002Fgithub.com\u002Fonline-ml\u002Friver\u002Fblob\u002Fmain\u002FLICENSE).\n","\u003Cp align=\"center\">\n  \u003Cimg height=\"220px\" src=\"https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fonline-ml_river_readme_6c1050196199.png\" alt=\"river_logo\">\n\u003C\u002Fp>\n\n\u003Cp align=\"center\">\n  \u003C!-- 代码质量 -->\n  \u003Ca href=\"https:\u002F\u002Fgithub.com\u002Fonline-ml\u002Friver\u002Factions\u002Fworkflows\u002Fcode-quality.yml\">\n    \u003Cimg src=\"https:\u002F\u002Fgithub.com\u002Fonline-ml\u002Friver\u002Factions\u002Fworkflows\u002Fcode-quality.yml\u002Fbadge.svg\" alt=\"code-quality\">\n  \u003C\u002Fa>\n  \u003C!-- 文档 -->\n  \u003Ca href=\"https:\u002F\u002Friverml.xyz\">\n    \u003Cimg src=\"https:\u002F\u002Fimg.shields.io\u002Fwebsite?label=docs&style=flat-square&url=https%3A%2F%2Friverml.xyz%2F\" alt=\"documentation\">\n  \u003C\u002Fa>\n  \u003C!-- PyPI -->\n  \u003Ca href=\"https:\u002F\u002Fpypi.org\u002Fproject\u002Friver\">\n    \u003Cimg src=\"https:\u002F\u002Fimg.shields.io\u002Fpypi\u002Fv\u002Friver.svg?label=release&color=blue&style=flat-square\" alt=\"pypi\">\n  \u003C\u002Fa>\n  \u003C!-- PePy -->\n  \u003Ca href=\"https:\u002F\u002Fpepy.tech\u002Fproject\u002Friver\">\n    \u003Cimg src=\"https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fonline-ml_river_readme_150dfe653354.png\" alt=\"pepy\">\n  \u003C\u002Fa>\n  \u003C!-- Mypy -->\n  \u003Ca href=\"http:\u002F\u002Fmypy-lang.org\u002F\">\n    \u003Cimg src=\"http:\u002F\u002Fwww.mypy-lang.org\u002Fstatic\u002Fmypy_badge.svg\" alt=\"mypy\">\n  \u003C\u002Fa>\n  \u003C!-- 许可证 -->\n  \u003Ca href=\"https:\u002F\u002Fopensource.org\u002Flicenses\u002FBSD-3-Clause\">\n    \u003Cimg src=\"https:\u002F\u002Fimg.shields.io\u002Fbadge\u002FLicense-BSD%203--Clause-blue.svg?style=flat-square\" alt=\"bsd_3_license\">\n  \u003C\u002Fa>\n\u003C\u002Fp>\n\n\u003C\u002Fbr>\n\n\u003Cp align=\"center\">\n  River 是一个用于 \u003Ca href=\"https:\u002F\u002Fwww.wikiwand.com\u002Fen\u002FOnline_machine_learning\">在线机器学习\u003C\u002Fa> 的 Python 库。它的目标是成为处理流式数据时最易用的机器学习库。River 是 \u003Ca href=\"https:\u002F\u002Fgithub.com\u002FMaxHalford\u002Fcreme\">creme\u003C\u002Fa> 和 \u003Ca href=\"https:\u002F\u002Fgithub.com\u002Fscikit-multiflow\u002Fscikit-multiflow\">scikit-multiflow\u003C\u002Fa> 合并后的产物。\n\u003C\u002Fp>\n\n## ⚡️ 快速入门\n\n作为一个简单的示例，我们将训练一个逻辑回归模型来分类 [网站钓鱼数据集](http:\u002F\u002Farchive.ics.uci.edu\u002Fml\u002Fdatasets\u002FWebsite+Phishing)。以下是该数据集中第一条记录的内容。\n\n```python\n>>> from pprint import pprint\n>>> from river import datasets\n\n>>> dataset = datasets.Phishing()\n\n>>> for x, y in dataset:\n...     pprint(x)\n...     print(y)\n...     break\n{'age_of_domain': 1,\n 'anchor_from_other_domain': 0.0,\n 'empty_server_form_handler': 0.0,\n 'https': 0.0,\n 'ip_in_url': 1,\n 'is_popular': 0.5,\n 'long_url': 1.0,\n 'popup_window': 0.0,\n 'request_from_other_domain': 0.0}\nTrue\n\n```\n\n现在让我们以流式方式在数据集上运行模型。我们交替进行预测和模型更新，同时更新性能指标以观察模型的表现。\n\n```python\n>>> from river import compose\n>>> from river import linear_model\n>>> from river import metrics\n>>> from river import preprocessing\n\n>>> model = compose.Pipeline(\n...     preprocessing.StandardScaler(),\n...     linear_model.LogisticRegression()\n... )\n\n>>> metric = metrics.Accuracy()\n\n>>> for x, y in dataset:\n...     y_pred = model.predict_one(x)      # 进行预测\n...     metric.update(y, y_pred)           # 更新指标\n...     model.learn_one(x, y)              # 更新模型\n\n>>> metric\nAccuracy: 89.28%\n\n```\n\n当然，这只是一个示例。欢迎查看文档中的 [简介](https:\u002F\u002Friverml.xyz\u002Fdev\u002Fintroduction\u002Finstallation\u002F) 部分，以获取更详细的教程。\n\n## 🛠 安装\n\nRiver 旨在与 **Python 3.10 及以上版本** 兼容。可以通过 `pip` 进行安装：\n\n```sh\npip install river\n```\n\nLinux、MacOS 和 Windows 平台都有 [预编译的二进制包](https:\u002F\u002Fpypi.org\u002Fproject\u002Friver\u002F#files) 可用，因此你很可能无需从源码构建 River。\n\n你也可以从 GitHub 安装最新的开发版本：\n\n```sh\npip install git+https:\u002F\u002Fgithub.com\u002Fonline-ml\u002Friver --upgrade\npip install git+ssh:\u002F\u002Fgit@github.com\u002Fonline-ml\u002Friver.git --upgrade  # 使用 SSH\n```\n\n这种方法需要你的机器上已安装 Cython 和 Rust。\n\n## 🔮 功能\n\nRiver 提供以下算法族的在线实现：\n\n- 线性模型，配备多种优化器\n- 决策树和随机森林\n- （近似）最近邻\n- 异常检测\n- 概念漂移检测\n- 推荐系统\n- 时间序列预测\n- 多臂老虎机\n- 因子分解机\n- 不平衡学习\n- 聚类\n- 装袋\u002F提升\u002F堆叠\n- 主动学习\n\n此外，River 还提供其他在线工具：\n\n- 特征提取和选择\n- 在线统计与度量\n- 数据预处理\n- 内置数据集\n- 渐进式模型验证\n- 模型流水线\n\n请参阅 [API 文档](https:\u002F\u002Friverml.xyz\u002Flatest\u002Fapi\u002Foverview\u002F) 获取全面概述。\n\n## 🤔 我应该使用 River 吗？\n\n你需要问自己是否需要在线机器学习。答案很可能是否定的。大多数情况下，批量学习已经足够。如果你遇到以下情况，可能更适合使用在线方法：\n\n- 你希望模型能够从新数据中学习，而无需重新处理历史数据。\n- 你希望模型对 [概念漂移](https:\u002F\u002Fwww.wikiwand.com\u002Fen\u002FConcept_drift) 具有鲁棒性。\n- 你想以更接近生产环境的方式开发模型，而生产环境通常是基于事件驱动的。\n\nRiver 的一些特点包括：\n\n- 它更注重清晰性和用户体验，而非性能。\n- 它处理单个样本的速度非常快。你可以亲自试一试。\n- 它能很好地与 Python 生态系统中的其他工具协同工作。\n\n## 🔗 有用链接\n\n- [文档](https:\u002F\u002Friverml.xyz)\n- [软件包发布记录](https:\u002F\u002Fpypi.org\u002Fproject\u002Friver\u002F#history)\n- [awesome-online-machine-learning](https:\u002F\u002Fgithub.com\u002Fonline-ml\u002Fawesome-online-machine-learning)\n- [2022 年 GAIA 大会上的演讲](https:\u002F\u002Fwww.youtube.com\u002Fwatch?v=nzFTmJnIakk&list=PLIU25-FciwNaz5PqWPiHmPCMOFYoEsJ8c&index=5)\n- [在线聚类：算法、评估、度量、应用及基准测试](https:\u002F\u002Fdl.acm.org\u002Fdoi\u002F10.1145\u002F3534678.3542600)，发表于 [KDD'22](https:\u002F\u002Fkdd.org\u002Fkdd2022\u002F)。\n\n## 👐 贡献\n\n欢迎以任何方式参与贡献，我们始终欢迎新的想法和方法。\n\n- 如果有任何问题或咨询，请[开启讨论](https:\u002F\u002Fgithub.com\u002Fonline-ml\u002Friver\u002Fdiscussions\u002Fnew)。公开提问比发送私人邮件更有帮助。也鼓励在贡献之前先发起讨论，以便大家达成一致，避免重复劳动。\n- 如果你认为发现了 bug 或性能问题，请随时[提交 issue](https:\u002F\u002Fgithub.com\u002Fonline-ml\u002Friver\u002Fissues\u002Fnew\u002Fchoose)。\n- 我们的 [路线图](https:\u002F\u002Fgithub.com\u002Forgs\u002Fonline-ml\u002Fprojects\u002F3?query=is%3Aopen+sort%3Aupdated-desc) 是公开的。你可以自由选择感兴趣的任务进行开发，或者提出建议。\n\n如果你想对代码库进行修改，请务必阅读 [贡献指南](https:\u002F\u002Fgithub.com\u002Fonline-ml\u002Friver\u002Fblob\u002Fmain\u002FCONTRIBUTING.md)。\n\n## 🤝 合作伙伴\n\n\u003Cp align=\"center\">\n  \u003Cimg width=\"70%\" src=\"https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fonline-ml_river_readme_824054caf584.png\" alt=\"affiliations\">\n\u003C\u002Fp>\n\n## 💬 引用\n\n如果 River 对您有所帮助，并且您希望在科学出版物中引用它，请参考发表在 JMLR 上的论文：\n\n```bibtex\n@article{montiel2021river,\n  title={River: machine learning for streaming data in Python},\n  author={Montiel, Jacob and Halford, Max and Mastelini, Saulo Martiello\n          and Bolmier, Geoffrey and Sourty, Raphael and Vaysse, Robin and Zouitine, Adil\n          and Gomes, Heitor Murilo and Read, Jesse and Abdessalem, Talel and others},\n  year={2021}\n}\n```\n\n## 📝 许可证\n\nRiver 是一款免费的开源软件，采用 [3 条款 BSD 许可证](https:\u002F\u002Fgithub.com\u002Fonline-ml\u002Friver\u002Fblob\u002Fmain\u002FLICENSE)授权。","# River 快速上手指南\n\nRiver 是一个专注于**在线机器学习**（Online Machine Learning）的 Python 库，旨在为流式数据提供最友好的机器学习体验。它由 `creme` 和 `scikit-multiflow` 合并而来，支持单样本逐条学习与预测。\n\n## 环境准备\n\n- **操作系统**：Linux、macOS 或 Windows\n- **Python 版本**：3.10 及以上\n- **前置依赖**：\n  - 标准安装无需额外依赖（官方提供预编译 Wheel 包）\n  - 若从源码安装开发版，需预先安装 `Cython` 和 `Rust`\n\n## 安装步骤\n\n### 方式一：通过 PyPI 安装（推荐）\n\n使用 pip 直接安装稳定版：\n\n```sh\npip install river\n```\n\n> 💡 国内用户可指定清华或阿里镜像加速安装：\n> ```sh\n> pip install river -i https:\u002F\u002Fpypi.tuna.tsinghua.edu.cn\u002Fsimple\n> ```\n\n### 方式二：安装最新开发版（可选）\n\n如需体验最新功能，可从 GitHub 安装（需安装 Cython 和 Rust）：\n\n```sh\npip install git+https:\u002F\u002Fgithub.com\u002Fonline-ml\u002Friver --upgrade\n```\n\n或使用 SSH 方式：\n\n```sh\npip install git+ssh:\u002F\u002Fgit@github.com\u002Fonline-ml\u002Friver.git --upgrade\n```\n\n## 基本使用\n\n以下示例演示如何使用 River 对流式数据进行在线分类：加载钓鱼网站数据集，构建一个包含标准化预处理和逻辑回归的管道，并逐条更新模型与评估准确率。\n\n```python\nfrom river import compose, linear_model, metrics, preprocessing, datasets\n\n# 加载内置数据集\ndataset = datasets.Phishing()\n\n# 构建模型管道：标准化 + 逻辑回归\nmodel = compose.Pipeline(\n    preprocessing.StandardScaler(),\n    linear_model.LogisticRegression()\n)\n\n# 初始化评估指标\nmetric = metrics.Accuracy()\n\n# 流式训练：逐条预测 → 更新指标 → 学习样本\nfor x, y in dataset:\n    y_pred = model.predict_one(x)      # 预测\n    metric.update(y, y_pred)           # 更新指标\n    model.learn_one(x, y)              # 在线学习\n\n# 输出最终准确率\nprint(metric)\n# 输出示例：Accuracy: 89.28%\n```\n\n该模式适用于所有支持 `predict_one` 和 `learn_one` 接口的 River 模型，是实现在线学习的核心范式。","某金融科技公司风控团队需要实时检测每秒涌入的数千笔交易欺诈行为，数据流持续不断且特征分布随时间动态变化。\n\n### 没有 river 时\n- 必须积攒大量历史数据后批量重新训练模型，导致新出现的欺诈模式无法被即时识别，存在数小时的风险敞口。\n- 随着数据量无限增长，内存迅速爆满，开发人员需自行编写复杂的滑动窗口逻辑来丢弃旧数据，代码维护成本极高。\n- 面对用户行为随季节或活动发生的“概念漂移”，静态模型准确率急剧下降，却难以在不中断服务的情况下进行增量更新。\n- 传统批处理框架延迟高，无法满足毫秒级反欺诈决策的 SLA 要求，往往只能事后诸葛亮式地分析报表。\n\n### 使用 river 后\n- 利用在线学习机制，每笔交易到来时先预测再立即更新模型，新欺诈手段在出现后的几秒钟内即可被模型捕捉并拦截。\n- 原生支持流式数据处理，算法仅保留必要的统计状态而非原始数据，内存占用恒定，轻松应对无限数据流。\n- 模型具备自适应能力，能随着数据分布的自然演变自动调整权重，无需人工干预重训即可长期保持高准确率。\n- 极简的 `learn_one` 和 `predict_one` 接口让实时管道构建如同搭积木，显著降低了流式机器学习系统的开发门槛。\n\nriver 将滞后的批量风控升级为实时的自适应防御，让模型在数据流动中持续进化，彻底消除了时间延迟带来的安全隐患。","https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fonline-ml_river_93c8327e.png","online-ml","The Fellowship of Online Machine Learning","https:\u002F\u002Foss.gittoolsai.com\u002Favatars\u002Fonline-ml_247cb21b.png","",null,"https:\u002F\u002Fmaxhalford.notion.site\u002FFriends-of-Online-Machine-Learning-8a264829ccf345a4b2627de38139ec8b","https:\u002F\u002Fgithub.com\u002Fonline-ml",[83,87,90,94,98],{"name":84,"color":85,"percentage":86},"Python","#3572A5",97.1,{"name":88,"color":89,"percentage":23},"Cython","#fedf5b",{"name":91,"color":92,"percentage":93},"C++","#f34b7d",0.5,{"name":95,"color":96,"percentage":97},"Rust","#dea584",0.4,{"name":99,"color":100,"percentage":101},"Makefile","#427819",0.1,5778,614,"2026-04-04T08:50:13","BSD-3-Clause",1,"Linux, macOS, Windows","未说明",{"notes":110,"python":111,"dependencies":112},"从 GitHub 安装最新开发版本时，需要预先安装 Cython 和 Rust。该库专注于流式数据（在线机器学习），擅长单样本快速处理，而非大规模批量训练。","3.10+",[],[13,51,54],[115,116,117,118,119,120,121,122,123,124,125,126],"incremental-learning","machine-learning","python","online-learning","online-statistics","data-science","streaming","online-machine-learning","streaming-data","concept-drift","real-time-processing","stream-processing","2026-03-27T02:49:30.150509","2026-04-06T05:35:34.867449",[130,135,140,145,150,155],{"id":131,"question_zh":132,"answer_zh":133,"source_url":134},17338,"如何在 River (Creme) 中使用非 scikit-learn 格式的数据集（例如字典）？","可以使用 `iter_pandas` 方法将数据转换为流式格式。虽然用户提到了字典，但官方推荐通常是将数据加载到 pandas DataFrame 中，然后使用 `river.stream.iter_pandas()` 进行迭代处理。对于特征 X 和目标变量 y，可以通过选择特定的列来处理。","https:\u002F\u002Fgithub.com\u002Fonline-ml\u002Friver\u002Fissues\u002F170",{"id":136,"question_zh":137,"answer_zh":138,"source_url":139},17339,"导入 River 时出现 'numpy.ufunc size changed' 错误或二进制不兼容错误怎么办？","这通常是由于 NumPy 版本不兼容导致的。请确保安装 `numpy>=1.22` 版本。如果遇到此错误，建议升级 NumPy：`pip install --upgrade numpy`。维护者已在 setup.py 中添加了版本限制以解决此问题。","https:\u002F\u002Fgithub.com\u002Fonline-ml\u002Friver\u002Fissues\u002F875",{"id":141,"question_zh":142,"answer_zh":143,"source_url":144},17340,"使用 OneHotEncoder 处理具有大量类别的特征时导致内存消耗过大，如何解决？","在使用 `preprocessing.OneHotEncoder` 时，可以启用 `sparse=True` 参数来使用稀疏矩阵表示，从而显著减少内存消耗。此外，对于分类特征，可以使用 `drop_first=True` 参数来避免多重共线性并减少一个特征列。注意：如果在管道组合使用时遇到 KeyError，可能是内部列引用问题，需确保管道连接正确或升级到修复后的版本。","https:\u002F\u002Fgithub.com\u002Fonline-ml\u002Friver\u002Fissues\u002F1253",{"id":146,"question_zh":147,"answer_zh":148,"source_url":149},17341,"River 是否支持多臂老虎机（Multi-Armed Bandits）算法？如何使用？","是的，River 已经实现了多臂老虎机算法的基础功能（如 Epsilon Greedy, UCB 等），用于在线模型选择和超参数调整。这些算法实现了 `fit_one`\u002F`predict_one` 接口，可以像其他模型一样使用。具体的实现位于 `model_selection` 模块中（例如 `SuccessiveHalvingClassifier`），可用于在渐进式验证中高效地选择最佳模型。","https:\u002F\u002Fgithub.com\u002Fonline-ml\u002Friver\u002Fissues\u002F270",{"id":151,"question_zh":152,"answer_zh":153,"source_url":154},17342,"使用 OutputCodeClassifier 时，当 code-size 较大（如大于 20 或 40）时报错 'OverflowError: Python int too large to convert to C ssize_t' 怎么办？","这是一个已知的限制，当代码大小（code-size）过大导致生成的整数超出 C 语言 `ssize_t` 的范围时会发生溢出错误。目前建议尝试使用较小的 code-size，或者检查是否有更新的版本修复了此问题。如果必须处理大量类别，可能需要寻找替代的分类策略或等待库的优化更新。","https:\u002F\u002Fgithub.com\u002Fonline-ml\u002Friver\u002Fissues\u002F1116",{"id":156,"question_zh":157,"answer_zh":158,"source_url":144},17343,"如何在 River 中结合使用多项式特征（PolynomialFeatures）和在线学习模型？","可以通过构建管道（Pipeline）来实现。首先使用 `Select` 选择特征，然后分别对分类特征应用 `OneHotEncoder`，对数值特征应用 `StandardScaler`。接着使用 `+` 操作符组合特征组，并利用 `*` 操作符创建交互项（类似于多项式特征）。最后将组合后的特征连接到模型（如 `SGDRegressor`）。示例代码结构：`model = (group1 + group1 * group2) | model_instance`。",[160,165,170,175,180,185,190,195,200,205,210,215,220,225,230,235,240,245],{"id":161,"version":162,"summary_zh":163,"released_at":164},99590,"0.23.0","- https:\u002F\u002Friverml.xyz\u002F0.23.0\u002Freleases\u002F0.23.0\u002F\n- https:\u002F\u002Fpypi.org\u002Fproject\u002Friver\u002F0.23.0\u002F","2025-11-13T19:29:35",{"id":166,"version":167,"summary_zh":168,"released_at":169},99591,"0.22.0","- https:\u002F\u002Friverml.xyz\u002F0.22.0\u002Freleases\u002F0.22.0\u002F\n- https:\u002F\u002Fpypi.org\u002Fproject\u002Friver\u002F0.22.0\u002F","2024-11-25T23:59:25",{"id":171,"version":172,"summary_zh":173,"released_at":174},99592,"0.21.2","- https:\u002F\u002Friverml.xyz\u002F0.21.2\u002Freleases\u002F0.21.2\u002F\n- https:\u002F\u002Fpypi.org\u002Fproject\u002Friver\u002F0.21.2\u002F","2024-07-09T02:21:03",{"id":176,"version":177,"summary_zh":178,"released_at":179},99593,"0.21.1","- https:\u002F\u002Friverml.xyz\u002F0.21.1\u002Freleases\u002F0.21.1\u002F\n- https:\u002F\u002Fpypi.org\u002Fproject\u002Friver\u002F0.21.1\u002F","2024-04-23T13:20:18",{"id":181,"version":182,"summary_zh":183,"released_at":184},99594,"0.21.0","- https:\u002F\u002Friverml.xyz\u002F0.21.0\u002Freleases\u002F0.21.0\u002F\n- https:\u002F\u002Fpypi.org\u002Fproject\u002Friver\u002F0.21.0\u002F","2023-12-05T09:29:54",{"id":186,"version":187,"summary_zh":188,"released_at":189},99595,"0.20.0","- https:\u002F\u002Friverml.xyz\u002F0.20.0\u002Freleases\u002F0.20.0\u002F\n- https:\u002F\u002Fpypi.org\u002Fproject\u002Friver\u002F0.20.0\u002F","2023-11-09T14:20:01",{"id":191,"version":192,"summary_zh":193,"released_at":194},99596,"0.19.0","- https:\u002F\u002Friverml.xyz\u002F0.19.0\u002Freleases\u002F0.19.0\u002F\n- https:\u002F\u002Fpypi.org\u002Fproject\u002Friver\u002F0.19.0\u002F","2023-09-03T17:17:56",{"id":196,"version":197,"summary_zh":198,"released_at":199},99597,"0.18.0","- https:\u002F\u002Friverml.xyz\u002F0.18.0\u002Freleases\u002F0.18.0\u002F\n- https:\u002F\u002Fpypi.org\u002Fproject\u002Friver\u002F0.18.0\u002F","2023-06-27T09:20:33",{"id":201,"version":202,"summary_zh":203,"released_at":204},99598,"0.17.0","- https:\u002F\u002Friverml.xyz\u002F0.17.0\u002Freleases\u002F0.17.0\u002F\n- https:\u002F\u002Fpypi.org\u002Fproject\u002Friver\u002F0.17.0\u002F","2023-05-27T14:06:20",{"id":206,"version":207,"summary_zh":208,"released_at":209},99599,"0.16.0","- https:\u002F\u002Friverml.xyz\u002F0.16.0\u002Freleases\u002F0.16.0\u002F\n- https:\u002F\u002Fpypi.org\u002Fproject\u002Friver\u002F0.16.0\u002F","2023-05-10T13:12:23",{"id":211,"version":212,"summary_zh":213,"released_at":214},99600,"0.15.0","- https:\u002F\u002Friverml.xyz\u002F0.15.0\u002Freleases\u002F0.15.0\u002F\n- https:\u002F\u002Fpypi.org\u002Fproject\u002Friver\u002F0.15.0\u002F","2023-01-30T07:27:43",{"id":216,"version":217,"summary_zh":218,"released_at":219},99601,"0.14.0","- https:\u002F\u002Friverml.xyz\u002F0.14.0\u002Freleases\u002F0.14.0\u002F\n- https:\u002F\u002Fpypi.org\u002Fproject\u002Friver\u002F0.14.0\u002F","2022-10-27T14:26:01",{"id":221,"version":222,"summary_zh":223,"released_at":224},99602,"0.13.0","- https:\u002F\u002Friverml.xyz\u002F0.13.0\u002Freleases\u002F0.13.0\u002F\r\n- https:\u002F\u002Fpypi.org\u002Fproject\u002Friver\u002F0.13.0\u002F","2022-09-19T18:08:51",{"id":226,"version":227,"summary_zh":228,"released_at":229},99603,"0.12.1","- https:\u002F\u002Friverml.xyz\u002F0.12.1\u002Freleases\u002F0.12.1\u002F and https:\u002F\u002Friverml.xyz\u002F0.12.1\u002Freleases\u002F0.12.0\u002F\r\n- https:\u002F\u002Fpypi.org\u002Fproject\u002Friver\u002F0.12.1\u002F","2022-09-02T20:37:47",{"id":231,"version":232,"summary_zh":233,"released_at":234},99604,"0.11.1","- https:\u002F\u002Friverml.xyz\u002F0.11.1\u002Freleases\u002F0.11.1\u002F\r\n- https:\u002F\u002Fpypi.org\u002Fproject\u002Friver\u002F0.11.1\u002F","2022-06-06T21:34:22",{"id":236,"version":237,"summary_zh":238,"released_at":239},99605,"0.11.0","- https:\u002F\u002Friverml.xyz\u002F0.11.0\u002Freleases\u002F0.11.0\u002F\r\n- https:\u002F\u002Fpypi.org\u002Fproject\u002Friver\u002F0.11.0\u002F","2022-05-28T19:28:00",{"id":241,"version":242,"summary_zh":243,"released_at":244},99606,"0.10.0","- https:\u002F\u002Friverml.xyz\u002Flatest\u002Freleases\u002F0.10.0\u002F\r\n- https:\u002F\u002Fpypi.org\u002Fmanage\u002Fproject\u002Friver\u002Frelease\u002F0.10.0\u002F","2022-02-04T15:14:56",{"id":246,"version":247,"summary_zh":248,"released_at":249},99607,"0.9.0","- https:\u002F\u002Friverml.xyz\u002Flatest\u002Freleases\u002F0.9.0\u002F\r\n- https:\u002F\u002Fpypi.org\u002Fmanage\u002Fproject\u002Friver\u002Frelease\u002F0.9.0\u002F","2021-12-01T16:11:26"]