[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"similar-oobabooga--text-generation-webui":3,"tool-oobabooga--text-generation-webui":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":76,"owner_company":76,"owner_location":76,"owner_email":78,"owner_twitter":76,"owner_website":76,"owner_url":79,"languages":80,"stars":109,"forks":110,"last_commit_at":111,"license":112,"difficulty_score":23,"env_os":113,"env_gpu":114,"env_ram":115,"env_deps":116,"category_tags":128,"github_topics":76,"view_count":129,"oss_zip_url":76,"oss_zip_packed_at":76,"status":16,"created_at":130,"updated_at":131,"faqs":132,"releases":161},2693,"oobabooga\u002Ftext-generation-webui","text-generation-webui","The original local LLM interface. Text, vision, tool-calling, training, and more. 100% offline.","text-generation-webui 是一款功能强大的本地大语言模型（LLM）交互界面，旨在让用户在完全离线且隐私安全的环境下运行各类开源 AI 模型。它解决了用户依赖云端服务可能导致的数据泄露风险，以及高昂的 API 调用成本问题，让所有计算都在本地完成。\n\n这款工具非常适合希望私有化部署 AI 的开发者、需要微调模型的研究人员，以及注重数据隐私的普通极客用户。其核心亮点在于极高的灵活性与兼容性：支持 llama.cpp、Transformers、ExLlamaV3 等多种后端，用户无需重启即可切换模型；提供与 OpenAI 和 Anthropic 兼容的本地 API，方便直接替换现有应用的后端。此外，它还具备多模态视觉理解、自定义工具调用（如联网搜索、数学计算）、文档内容问答以及本地 LoRA 微调等高级功能。界面基于 Gradio 构建，操作直观，既支持类似 ChatGPT 的对话模式，也提供自由创作的笔记本模式。无论是想要一键解压即用的新手，还是追求极致控制的专业用户，text-generation-webui 都能提供零遥测、纯本地的完美体验。","\u003Cdiv align=\"center\" markdown=\"1\">\n   \u003Csup>Special thanks to:\u003C\u002Fsup>\n   \u003Cbr>\n   \u003Cbr>\n   \u003Ca href=\"https:\u002F\u002Fgo.warp.dev\u002Ftext-generation-webui\">\n      \u003Cimg alt=\"Warp sponsorship\" width=\"400\" src=\"https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Foobabooga_text-generation-webui_readme_7f26e93a2b2c.png\">\n   \u003C\u002Fa>\n\n### [Warp, built for coding with multiple AI agents](https:\u002F\u002Fgo.warp.dev\u002Ftext-generation-webui)\n[Available for macOS, Linux, & Windows](https:\u002F\u002Fgo.warp.dev\u002Ftext-generation-webui)\u003Cbr>\n\u003C\u002Fdiv>\n\u003Chr>\n\n# Text Generation Web UI\n\nA Gradio web UI for running Large Language Models locally. 100% private and offline. Supports text generation, vision, tool-calling, training, image generation, and more.\n\n[Try the Deep Reason extension](https:\u002F\u002Foobabooga.gumroad.com\u002Fl\u002Fdeep_reason)\n\n|![Image1](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Foobabooga_text-generation-webui_readme_8fd8317211fb.png) | ![Image2](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Foobabooga_text-generation-webui_readme_b3045e962f07.png) |\n|:---:|:---:|\n|![Image1](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Foobabooga_text-generation-webui_readme_3d57a82deb15.png) | ![Image2](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Foobabooga_text-generation-webui_readme_ec69549cd9e8.png) |\n\n## Features\n\n- **Easy setup**: [Portable builds](https:\u002F\u002Fgithub.com\u002Foobabooga\u002Ftext-generation-webui\u002Freleases) (zero setup, just unzip and run) for GGUF models on Windows\u002FLinux\u002FmacOS, or a one-click installer for the full feature set.\n- **Multiple backends**: [llama.cpp](https:\u002F\u002Fgithub.com\u002Fggerganov\u002Fllama.cpp), [Transformers](https:\u002F\u002Fgithub.com\u002Fhuggingface\u002Ftransformers), [ExLlamaV3](https:\u002F\u002Fgithub.com\u002Fturboderp-org\u002Fexllamav3), and [TensorRT-LLM](https:\u002F\u002Fgithub.com\u002FNVIDIA\u002FTensorRT-LLM). Switch between backends and models without restarting.\n- **OpenAI\u002FAnthropic-compatible API**: Chat, Completions, and Messages endpoints with tool-calling support. Use as a local drop-in replacement for the OpenAI\u002FAnthropic APIs ([examples](https:\u002F\u002Fgithub.com\u002Foobabooga\u002Ftext-generation-webui\u002Fwiki\u002F12-%E2%80%90-OpenAI-API#examples)).\n- **Tool-calling**: Models can call custom functions during chat — web search, page fetching, math, and more. Each tool is a single `.py` file, easy to create and extend ([tutorial](https:\u002F\u002Fgithub.com\u002Foobabooga\u002Ftext-generation-webui\u002Fwiki\u002FTool-Calling-Tutorial)).\n- **Vision (multimodal)**: Attach images to messages for visual understanding ([tutorial](https:\u002F\u002Fgithub.com\u002Foobabooga\u002Ftext-generation-webui\u002Fwiki\u002FMultimodal-Tutorial)).\n- **File attachments**: Upload text files, PDF documents, and .docx documents to talk about their contents.\n- **Training**: Fine-tune LoRAs on multi-turn chat or raw text datasets. Supports resuming interrupted runs ([tutorial](https:\u002F\u002Fgithub.com\u002Foobabooga\u002Ftext-generation-webui\u002Fwiki\u002F05-%E2%80%90-Training-Tab)).\n- **Image generation**: A dedicated tab for `diffusers` models like **Z-Image-Turbo**. Features 4-bit\u002F8-bit quantization and a persistent gallery with metadata ([tutorial](https:\u002F\u002Fgithub.com\u002Foobabooga\u002Ftext-generation-webui\u002Fwiki\u002FImage-Generation-Tutorial)).\n- 100% offline and private, with zero telemetry, external resources, or remote update requests.\n- `instruct` mode for instruction-following (like ChatGPT), and `chat-instruct`\u002F`chat` modes for talking to custom characters. Prompts are automatically formatted with Jinja2 templates.\n- Edit messages, navigate between message versions, and branch conversations at any point.\n- Free-form text generation in the Notebook tab without being limited to chat turns.\n- Multiple sampling parameters and generation options for sophisticated text generation control.\n- Dark\u002Flight themes, syntax highlighting for code blocks, and LaTeX rendering for mathematical expressions.\n- Extension support, with numerous built-in and user-contributed extensions available. See the [wiki](https:\u002F\u002Fgithub.com\u002Foobabooga\u002Ftext-generation-webui\u002Fwiki\u002F07-%E2%80%90-Extensions) and [extensions directory](https:\u002F\u002Fgithub.com\u002Foobabooga\u002Ftext-generation-webui-extensions) for details.\n\n## How to install\n\n#### ✅ Option 1: Portable builds (get started in 1 minute)\n\nNo installation needed – just download, unzip and run. All dependencies included.\n\nDownload from here: **https:\u002F\u002Fgithub.com\u002Foobabooga\u002Ftext-generation-webui\u002Freleases**\n\n- Builds are provided for Linux, Windows, and macOS, with options for CUDA, Vulkan, ROCm, and CPU-only.\n- Compatible with GGUF (llama.cpp) models.\n\n#### Option 2: Manual portable install with venv\n\nVery fast setup that should work on any Python 3.9+:\n\n```bash\n# Clone repository\ngit clone https:\u002F\u002Fgithub.com\u002Foobabooga\u002Ftext-generation-webui\ncd text-generation-webui\n\n# Create virtual environment\npython -m venv venv\n\n# Activate virtual environment\n# On Windows:\nvenv\\Scripts\\activate\n# On macOS\u002FLinux:\nsource venv\u002Fbin\u002Factivate\n\n# Install dependencies (choose appropriate file under requirements\u002Fportable for your hardware)\npip install -r requirements\u002Fportable\u002Frequirements.txt --upgrade\n\n# Launch server (basic command)\npython server.py --portable --api --auto-launch\n\n# When done working, deactivate\ndeactivate\n```\n\n#### Option 3: One-click installer\n\nFor users who need additional backends (ExLlamaV3, Transformers), training, image generation, or extensions (TTS, voice input, translation, etc). Requires ~10GB disk space and downloads PyTorch.\n\n1. Clone the repository, or [download its source code](https:\u002F\u002Fgithub.com\u002Foobabooga\u002Ftext-generation-webui\u002Farchive\u002Frefs\u002Fheads\u002Fmain.zip) and extract it.\n2. Run the startup script for your OS: `start_windows.bat`, `start_linux.sh`, or `start_macos.sh`.\n3. When prompted, select your GPU vendor.\n4. After installation, open `http:\u002F\u002F127.0.0.1:7860` in your browser.\n\nTo restart the web UI later, run the same `start_` script.\n\nYou can pass command-line flags directly (e.g., `.\u002Fstart_linux.sh --help`), or add them to `user_data\u002FCMD_FLAGS.txt` (e.g., `--api` to enable the API).\n\nTo update, run the update script for your OS: `update_wizard_windows.bat`, `update_wizard_linux.sh`, or `update_wizard_macos.sh`.\n\nTo reinstall with a fresh Python environment, delete the `installer_files` folder and run the `start_` script again.\n\n\u003Cdetails>\n\u003Csummary>\nOne-click installer details\n\u003C\u002Fsummary>\n\n### One-click-installer\n\nThe script uses Miniforge to set up a Conda environment in the `installer_files` folder.\n\nIf you ever need to install something manually in the `installer_files` environment, you can launch an interactive shell using the cmd script: `cmd_linux.sh`, `cmd_windows.bat`, or `cmd_macos.sh`.\n\n* There is no need to run any of those scripts (`start_`, `update_wizard_`, or `cmd_`) as admin\u002Froot.\n* To install requirements for extensions, it is recommended to use the update wizard script with the \"Install\u002Fupdate extensions requirements\" option. At the end, this script will install the main requirements for the project to make sure that they take precedence in case of version conflicts.\n* For automated installation, you can use the `GPU_CHOICE`, `LAUNCH_AFTER_INSTALL`, and `INSTALL_EXTENSIONS` environment variables. For instance: `GPU_CHOICE=A LAUNCH_AFTER_INSTALL=FALSE INSTALL_EXTENSIONS=TRUE .\u002Fstart_linux.sh`.\n\n\u003C\u002Fdetails>\n\n\u003Cdetails>\n\u003Csummary>\nManual full installation with conda or docker\n\u003C\u002Fsummary>\n\n### Full installation with Conda\n\n#### 0. Install Conda\n\nhttps:\u002F\u002Fgithub.com\u002Fconda-forge\u002Fminiforge\n\nOn Linux or WSL, Miniforge can be automatically installed with these two commands:\n\n```\ncurl -sL \"https:\u002F\u002Fgithub.com\u002Fconda-forge\u002Fminiforge\u002Freleases\u002Flatest\u002Fdownload\u002FMiniforge3-Linux-x86_64.sh\" > \"Miniforge3.sh\"\nbash Miniforge3.sh\n```\n\nFor other platforms, download from: https:\u002F\u002Fgithub.com\u002Fconda-forge\u002Fminiforge\u002Freleases\u002Flatest\n\n#### 1. Create a new conda environment\n\n```\nconda create -n textgen python=3.13\nconda activate textgen\n```\n\n#### 2. Install Pytorch\n\n| System | GPU | Command |\n|--------|---------|---------|\n| Linux\u002FWSL | NVIDIA | `pip3 install torch==2.9.1 --index-url https:\u002F\u002Fdownload.pytorch.org\u002Fwhl\u002Fcu128` |\n| Linux\u002FWSL | CPU only | `pip3 install torch==2.9.1 --index-url https:\u002F\u002Fdownload.pytorch.org\u002Fwhl\u002Fcpu` |\n| Linux | AMD | `pip3 install https:\u002F\u002Frepo.radeon.com\u002Frocm\u002Fmanylinux\u002Frocm-rel-7.2\u002Ftorch-2.9.1%2Brocm7.2.0.lw.git7e1940d4-cp313-cp313-linux_x86_64.whl` |\n| MacOS + MPS | Any | `pip3 install torch==2.9.1` |\n| Windows | NVIDIA | `pip3 install torch==2.9.1 --index-url https:\u002F\u002Fdownload.pytorch.org\u002Fwhl\u002Fcu128` |\n| Windows | CPU only | `pip3 install torch==2.9.1` |\n\nThe up-to-date commands can be found here: https:\u002F\u002Fpytorch.org\u002Fget-started\u002Flocally\u002F.\n\nIf you need `nvcc` to compile some library manually, you will additionally need to install this:\n\n```\nconda install -y -c \"nvidia\u002Flabel\u002Fcuda-12.8.1\" cuda\n```\n\n#### 3. Install the web UI\n\n```\ngit clone https:\u002F\u002Fgithub.com\u002Foobabooga\u002Ftext-generation-webui\ncd text-generation-webui\npip install -r requirements\u002Ffull\u002F\u003Crequirements file according to table below>\n```\n\nRequirements file to use:\n\n| GPU | requirements file to use |\n|--------|---------|\n| NVIDIA | `requirements.txt` |\n| AMD | `requirements_amd.txt` |\n| CPU only | `requirements_cpu_only.txt` |\n| Apple Intel | `requirements_apple_intel.txt` |\n| Apple Silicon | `requirements_apple_silicon.txt` |\n\n### Start the web UI\n\n```\nconda activate textgen\ncd text-generation-webui\npython server.py\n```\n\nThen browse to\n\n`http:\u002F\u002F127.0.0.1:7860`\n\n#### Manual install\n\nThe `requirements*.txt` above contain various wheels precompiled through GitHub Actions. If you wish to compile things manually, or if you need to because no suitable wheels are available for your hardware, you can use `requirements_nowheels.txt` and then install your desired loaders manually.\n\n### Alternative: Docker\n\n```\nFor NVIDIA GPU:\nln -s docker\u002F{nvidia\u002FDockerfile,nvidia\u002Fdocker-compose.yml,.dockerignore} .\nFor AMD GPU:\nln -s docker\u002F{amd\u002FDockerfile,amd\u002Fdocker-compose.yml,.dockerignore} .\nFor Intel GPU:\nln -s docker\u002F{intel\u002FDockerfile,intel\u002Fdocker-compose.yml,.dockerignore} .\nFor CPU only\nln -s docker\u002F{cpu\u002FDockerfile,cpu\u002Fdocker-compose.yml,.dockerignore} .\ncp docker\u002F.env.example .env\n#Create logs\u002Fcache dir :\nmkdir -p user_data\u002Flogs user_data\u002Fcache\n# Edit .env and set:\n#   TORCH_CUDA_ARCH_LIST based on your GPU model\n#   APP_RUNTIME_GID      your host user's group id (run `id -g` in a terminal)\n#   BUILD_EXTENIONS      optionally add comma separated list of extensions to build\n# Edit user_data\u002FCMD_FLAGS.txt and add in it the options you want to execute (like --listen --cpu)\n#\ndocker compose up --build\n```\n\n* You need to have Docker Compose v2.17 or higher installed. See [this guide](https:\u002F\u002Fgithub.com\u002Foobabooga\u002Ftext-generation-webui\u002Fwiki\u002F09-%E2%80%90-Docker) for instructions.\n* For additional docker files, check out [this repository](https:\u002F\u002Fgithub.com\u002FAtinoda\u002Ftext-generation-webui-docker).\n\n### Updating the requirements\n\nFrom time to time, the `requirements*.txt` change. To update, use these commands:\n\n```\nconda activate textgen\ncd text-generation-webui\npip install -r \u003Crequirements file that you have used> --upgrade\n```\n\u003C\u002Fdetails>\n\n\u003Cdetails>\n\u003Csummary>\nList of command-line flags\n\u003C\u002Fsummary>\n\n```txt\nusage: server.py [-h] [--user-data-dir USER_DATA_DIR] [--multi-user] [--model MODEL] [--lora LORA [LORA ...]] [--model-dir MODEL_DIR] [--lora-dir LORA_DIR] [--model-menu] [--settings SETTINGS]\n                 [--extensions EXTENSIONS [EXTENSIONS ...]] [--verbose] [--idle-timeout IDLE_TIMEOUT] [--image-model IMAGE_MODEL] [--image-model-dir IMAGE_MODEL_DIR] [--image-dtype {bfloat16,float16}]\n                 [--image-attn-backend {flash_attention_2,sdpa}] [--image-cpu-offload] [--image-compile] [--image-quant {none,bnb-8bit,bnb-4bit,torchao-int8wo,torchao-fp4,torchao-float8wo}]\n                 [--loader LOADER] [--ctx-size N] [--cache-type N] [--model-draft MODEL_DRAFT] [--draft-max DRAFT_MAX] [--gpu-layers-draft GPU_LAYERS_DRAFT] [--device-draft DEVICE_DRAFT]\n                 [--ctx-size-draft CTX_SIZE_DRAFT] [--spec-type {none,ngram-mod,ngram-simple,ngram-map-k,ngram-map-k4v,ngram-cache}] [--spec-ngram-size-n SPEC_NGRAM_SIZE_N]\n                 [--spec-ngram-size-m SPEC_NGRAM_SIZE_M] [--spec-ngram-min-hits SPEC_NGRAM_MIN_HITS] [--gpu-layers N] [--cpu-moe] [--mmproj MMPROJ] [--streaming-llm] [--tensor-split TENSOR_SPLIT]\n                 [--row-split] [--no-mmap] [--mlock] [--no-kv-offload] [--batch-size BATCH_SIZE] [--ubatch-size UBATCH_SIZE] [--threads THREADS] [--threads-batch THREADS_BATCH] [--numa]\n                 [--parallel PARALLEL] [--fit-target FIT_TARGET] [--extra-flags EXTRA_FLAGS] [--cpu] [--cpu-memory CPU_MEMORY] [--disk] [--disk-cache-dir DISK_CACHE_DIR] [--load-in-8bit] [--bf16]\n                 [--no-cache] [--trust-remote-code] [--force-safetensors] [--no_use_fast] [--attn-implementation IMPLEMENTATION] [--load-in-4bit] [--use_double_quant] [--compute_dtype COMPUTE_DTYPE]\n                 [--quant_type QUANT_TYPE] [--gpu-split GPU_SPLIT] [--enable-tp] [--tp-backend TP_BACKEND] [--cfg-cache] [--listen] [--listen-port LISTEN_PORT] [--listen-host LISTEN_HOST] [--share]\n                 [--auto-launch] [--gradio-auth GRADIO_AUTH] [--gradio-auth-path GRADIO_AUTH_PATH] [--ssl-keyfile SSL_KEYFILE] [--ssl-certfile SSL_CERTFILE] [--subpath SUBPATH] [--old-colors]\n                 [--portable] [--api] [--public-api] [--public-api-id PUBLIC_API_ID] [--api-port API_PORT] [--api-key API_KEY] [--admin-key ADMIN_KEY] [--api-enable-ipv6] [--api-disable-ipv4]\n                 [--nowebui] [--temperature N] [--dynatemp-low N] [--dynatemp-high N] [--dynatemp-exponent N] [--smoothing-factor N] [--smoothing-curve N] [--min-p N] [--top-p N] [--top-k N]\n                 [--typical-p N] [--xtc-threshold N] [--xtc-probability N] [--epsilon-cutoff N] [--eta-cutoff N] [--tfs N] [--top-a N] [--top-n-sigma N] [--adaptive-target N] [--adaptive-decay N]\n                 [--dry-multiplier N] [--dry-allowed-length N] [--dry-base N] [--repetition-penalty N] [--frequency-penalty N] [--presence-penalty N] [--encoder-repetition-penalty N]\n                 [--no-repeat-ngram-size N] [--repetition-penalty-range N] [--penalty-alpha N] [--guidance-scale N] [--mirostat-mode N] [--mirostat-tau N] [--mirostat-eta N]\n                 [--do-sample | --no-do-sample] [--dynamic-temperature | --no-dynamic-temperature] [--temperature-last | --no-temperature-last] [--sampler-priority N] [--dry-sequence-breakers N]\n                 [--enable-thinking | --no-enable-thinking] [--reasoning-effort N] [--chat-template-file CHAT_TEMPLATE_FILE]\n\nText Generation Web UI\n\noptions:\n  -h, --help                                           show this help message and exit\n\nBasic settings:\n  --user-data-dir USER_DATA_DIR                        Path to the user data directory. Default: auto-detected.\n  --multi-user                                         Multi-user mode. Chat histories are not saved or automatically loaded. Best suited for small trusted teams.\n  --model MODEL                                        Name of the model to load by default.\n  --lora LORA [LORA ...]                               The list of LoRAs to load. If you want to load more than one LoRA, write the names separated by spaces.\n  --model-dir MODEL_DIR                                Path to directory with all the models.\n  --lora-dir LORA_DIR                                  Path to directory with all the loras.\n  --model-menu                                         Show a model menu in the terminal when the web UI is first launched.\n  --settings SETTINGS                                  Load the default interface settings from this yaml file. See user_data\u002Fsettings-template.yaml for an example. If you create a file called\n                                                       user_data\u002Fsettings.yaml, this file will be loaded by default without the need to use the --settings flag.\n  --extensions EXTENSIONS [EXTENSIONS ...]             The list of extensions to load. If you want to load more than one extension, write the names separated by spaces.\n  --verbose                                            Print the prompts to the terminal.\n  --idle-timeout IDLE_TIMEOUT                          Unload model after this many minutes of inactivity. It will be automatically reloaded when you try to use it again.\n\nImage model:\n  --image-model IMAGE_MODEL                            Name of the image model to select on startup (overrides saved setting).\n  --image-model-dir IMAGE_MODEL_DIR                    Path to directory with all the image models.\n  --image-dtype {bfloat16,float16}                     Data type for image model.\n  --image-attn-backend {flash_attention_2,sdpa}        Attention backend for image model.\n  --image-cpu-offload                                  Enable CPU offloading for image model.\n  --image-compile                                      Compile the image model for faster inference.\n  --image-quant {none,bnb-8bit,bnb-4bit,torchao-int8wo,torchao-fp4,torchao-float8wo}\n                                                       Quantization method for image model.\n\nModel loader:\n  --loader LOADER                                      Choose the model loader manually, otherwise, it will get autodetected. Valid options: Transformers, llama.cpp, ExLlamav3_HF, ExLlamav3, TensorRT-\n                                                       LLM.\n\nContext and cache:\n  --ctx-size, --n_ctx, --max_seq_len N                 Context size in tokens. 0 = auto for llama.cpp (requires gpu-layers=-1), 8192 for other loaders.\n  --cache-type, --cache_type N                         KV cache type; valid options: llama.cpp - fp16, q8_0, q4_0; ExLlamaV3 - fp16, q2 to q8 (can specify k_bits and v_bits separately, e.g. q4_q8).\n\nSpeculative decoding:\n  --model-draft MODEL_DRAFT                            Path to the draft model for speculative decoding.\n  --draft-max DRAFT_MAX                                Number of tokens to draft for speculative decoding.\n  --gpu-layers-draft GPU_LAYERS_DRAFT                  Number of layers to offload to the GPU for the draft model.\n  --device-draft DEVICE_DRAFT                          Comma-separated list of devices to use for offloading the draft model. Example: CUDA0,CUDA1\n  --ctx-size-draft CTX_SIZE_DRAFT                      Size of the prompt context for the draft model. If 0, uses the same as the main model.\n  --spec-type {none,ngram-mod,ngram-simple,ngram-map-k,ngram-map-k4v,ngram-cache}\n                                                       Draftless speculative decoding type. Recommended: ngram-mod.\n  --spec-ngram-size-n SPEC_NGRAM_SIZE_N                N-gram lookup size for ngram speculative decoding.\n  --spec-ngram-size-m SPEC_NGRAM_SIZE_M                Draft n-gram size for ngram speculative decoding.\n  --spec-ngram-min-hits SPEC_NGRAM_MIN_HITS            Minimum n-gram hits for ngram-map speculative decoding.\n\nllama.cpp:\n  --gpu-layers, --n-gpu-layers N                       Number of layers to offload to the GPU. -1 = auto.\n  --cpu-moe                                            Move the experts to the CPU (for MoE models).\n  --mmproj MMPROJ                                      Path to the mmproj file for vision models.\n  --streaming-llm                                      Activate StreamingLLM to avoid re-evaluating the entire prompt when old messages are removed.\n  --tensor-split TENSOR_SPLIT                          Split the model across multiple GPUs. Comma-separated list of proportions. Example: 60,40.\n  --row-split                                          Split the model by rows across GPUs. This may improve multi-gpu performance.\n  --no-mmap                                            Prevent mmap from being used.\n  --mlock                                              Force the system to keep the model in RAM.\n  --no-kv-offload                                      Do not offload the K, Q, V to the GPU. This saves VRAM but reduces performance.\n  --batch-size BATCH_SIZE                              Maximum number of prompt tokens to batch together when calling llama-server. This is the application level batch size.\n  --ubatch-size UBATCH_SIZE                            Maximum number of prompt tokens to batch together when calling llama-server. This is the max physical batch size for computation (device level).\n  --threads THREADS                                    Number of threads to use.\n  --threads-batch THREADS_BATCH                        Number of threads to use for batches\u002Fprompt processing.\n  --numa                                               Activate NUMA task allocation for llama.cpp.\n  --parallel PARALLEL                                  Number of parallel request slots. The context size is divided equally among slots. For example, to have 4 slots with 8192 context each, set\n                                                       ctx_size to 32768.\n  --fit-target FIT_TARGET                              Target VRAM margin per device for auto GPU layers, comma-separated list of values in MiB. A single value is broadcast across all devices.\n                                                       Default: 1024.\n  --extra-flags EXTRA_FLAGS                            Extra flags to pass to llama-server. Format: \"flag1=value1,flag2,flag3=value3\". Example: \"override-tensor=exps=CPU\"\n\nTransformers\u002FAccelerate:\n  --cpu                                                Use the CPU to generate text. Warning: Training on CPU is extremely slow.\n  --cpu-memory CPU_MEMORY                              Maximum CPU memory in GiB. Use this for CPU offloading.\n  --disk                                               If the model is too large for your GPU(s) and CPU combined, send the remaining layers to the disk.\n  --disk-cache-dir DISK_CACHE_DIR                      Directory to save the disk cache to.\n  --load-in-8bit                                       Load the model with 8-bit precision (using bitsandbytes).\n  --bf16                                               Load the model with bfloat16 precision. Requires NVIDIA Ampere GPU.\n  --no-cache                                           Set use_cache to False while generating text. This reduces VRAM usage slightly, but it comes at a performance cost.\n  --trust-remote-code                                  Set trust_remote_code=True while loading the model. Necessary for some models.\n  --force-safetensors                                  Set use_safetensors=True while loading the model. This prevents arbitrary code execution.\n  --no_use_fast                                        Set use_fast=False while loading the tokenizer (it's True by default). Use this if you have any problems related to use_fast.\n  --attn-implementation IMPLEMENTATION                 Attention implementation. Valid options: sdpa, eager, flash_attention_2.\n\nbitsandbytes 4-bit:\n  --load-in-4bit                                       Load the model with 4-bit precision (using bitsandbytes).\n  --use_double_quant                                   use_double_quant for 4-bit.\n  --compute_dtype COMPUTE_DTYPE                        compute dtype for 4-bit. Valid options: bfloat16, float16, float32.\n  --quant_type QUANT_TYPE                              quant_type for 4-bit. Valid options: nf4, fp4.\n\nExLlamaV3:\n  --gpu-split GPU_SPLIT                                Comma-separated list of VRAM (in GB) to use per GPU device for model layers. Example: 20,7,7.\n  --enable-tp, --enable_tp                             Enable Tensor Parallelism (TP) to split the model across GPUs.\n  --tp-backend TP_BACKEND                              The backend for tensor parallelism. Valid options: native, nccl. Default: native.\n  --cfg-cache                                          Create an additional cache for CFG negative prompts. Necessary to use CFG with that loader.\n\nGradio:\n  --listen                                             Make the web UI reachable from your local network.\n  --listen-port LISTEN_PORT                            The listening port that the server will use.\n  --listen-host LISTEN_HOST                            The hostname that the server will use.\n  --share                                              Create a public URL. This is useful for running the web UI on Google Colab or similar.\n  --auto-launch                                        Open the web UI in the default browser upon launch.\n  --gradio-auth GRADIO_AUTH                            Set Gradio authentication password in the format \"username:password\". Multiple credentials can also be supplied with \"u1:p1,u2:p2,u3:p3\".\n  --gradio-auth-path GRADIO_AUTH_PATH                  Set the Gradio authentication file path. The file should contain one or more user:password pairs in the same format as above.\n  --ssl-keyfile SSL_KEYFILE                            The path to the SSL certificate key file.\n  --ssl-certfile SSL_CERTFILE                          The path to the SSL certificate cert file.\n  --subpath SUBPATH                                    Customize the subpath for gradio, use with reverse proxy\n  --old-colors                                         Use the legacy Gradio colors, before the December\u002F2024 update.\n  --portable                                           Hide features not available in portable mode like training.\n\nAPI:\n  --api                                                Enable the API extension.\n  --public-api                                         Create a public URL for the API using Cloudflare.\n  --public-api-id PUBLIC_API_ID                        Tunnel ID for named Cloudflare Tunnel. Use together with public-api option.\n  --api-port API_PORT                                  The listening port for the API.\n  --api-key API_KEY                                    API authentication key.\n  --admin-key ADMIN_KEY                                API authentication key for admin tasks like loading and unloading models. If not set, will be the same as --api-key.\n  --api-enable-ipv6                                    Enable IPv6 for the API\n  --api-disable-ipv4                                   Disable IPv4 for the API\n  --nowebui                                            Do not launch the Gradio UI. Useful for launching the API in standalone mode.\n\nAPI generation defaults:\n  --temperature N                                      Temperature\n  --dynatemp-low N                                     Dynamic temperature low\n  --dynatemp-high N                                    Dynamic temperature high\n  --dynatemp-exponent N                                Dynamic temperature exponent\n  --smoothing-factor N                                 Smoothing factor\n  --smoothing-curve N                                  Smoothing curve\n  --min-p N                                            Min P\n  --top-p N                                            Top P\n  --top-k N                                            Top K\n  --typical-p N                                        Typical P\n  --xtc-threshold N                                    XTC threshold\n  --xtc-probability N                                  XTC probability\n  --epsilon-cutoff N                                   Epsilon cutoff\n  --eta-cutoff N                                       Eta cutoff\n  --tfs N                                              TFS\n  --top-a N                                            Top A\n  --top-n-sigma N                                      Top N Sigma\n  --adaptive-target N                                  Adaptive target\n  --adaptive-decay N                                   Adaptive decay\n  --dry-multiplier N                                   DRY multiplier\n  --dry-allowed-length N                               DRY allowed length\n  --dry-base N                                         DRY base\n  --repetition-penalty N                               Repetition penalty\n  --frequency-penalty N                                Frequency penalty\n  --presence-penalty N                                 Presence penalty\n  --encoder-repetition-penalty N                       Encoder repetition penalty\n  --no-repeat-ngram-size N                             No repeat ngram size\n  --repetition-penalty-range N                         Repetition penalty range\n  --penalty-alpha N                                    Penalty alpha\n  --guidance-scale N                                   Guidance scale\n  --mirostat-mode N                                    Mirostat mode\n  --mirostat-tau N                                     Mirostat tau\n  --mirostat-eta N                                     Mirostat eta\n  --do-sample, --no-do-sample                          Do sample\n  --dynamic-temperature, --no-dynamic-temperature      Dynamic temperature\n  --temperature-last, --no-temperature-last            Temperature last\n  --sampler-priority N                                 Sampler priority\n  --dry-sequence-breakers N                            DRY sequence breakers\n  --enable-thinking, --no-enable-thinking              Enable thinking\n  --reasoning-effort N                                 Reasoning effort\n  --chat-template-file CHAT_TEMPLATE_FILE              Path to a chat template file (.jinja, .jinja2, or .yaml) to use as the default instruction template for API requests. Overrides the model's\n                                                       built-in template.\n```\n\n\u003C\u002Fdetails>\n\n## Downloading models\n\n1. Download a GGUF model file from [Hugging Face](https:\u002F\u002Fhuggingface.co\u002Fmodels?pipeline_tag=text-generation&sort=downloads&search=gguf).\n2. Place it in the `user_data\u002Fmodels` folder.\n\nThat's it. The UI will detect it automatically.\n\nTo estimate how much memory a model will use, you can use the [GGUF Memory Calculator](https:\u002F\u002Fhuggingface.co\u002Fspaces\u002Foobabooga\u002Faccurate-gguf-vram-calculator).\n\n\u003Cdetails>\n\u003Csummary>Other model types (Transformers, EXL3)\u003C\u002Fsummary>\n\nModels that consist of multiple files (like 16-bit Transformers models and EXL3 models) should be placed in a subfolder inside `user_data\u002Fmodels`:\n\n```\ntext-generation-webui\n└── user_data\n    └── models\n        └── Qwen_Qwen3-8B\n            ├── config.json\n            ├── generation_config.json\n            ├── model-00001-of-00004.safetensors\n            ├── ...\n            ├── tokenizer_config.json\n            └── tokenizer.json\n```\n\nThese formats require the one-click installer (not the portable build).\n\u003C\u002Fdetails>\n\n## Documentation\n\nhttps:\u002F\u002Fgithub.com\u002Foobabooga\u002Ftext-generation-webui\u002Fwiki\n\n## Community\n\nhttps:\u002F\u002Fwww.reddit.com\u002Fr\u002FOobabooga\u002F\n\n## Acknowledgments\n\n- In August 2023, [Andreessen Horowitz](https:\u002F\u002Fa16z.com\u002F) (a16z) provided a generous grant to encourage and support my independent work on this project. I am **extremely** grateful for their trust and recognition.\n- This project was inspired by [AUTOMATIC1111\u002Fstable-diffusion-webui](https:\u002F\u002Fgithub.com\u002FAUTOMATIC1111\u002Fstable-diffusion-webui) and wouldn't exist without it.\n","\u003Cdiv align=\"center\" markdown=\"1\">\n   \u003Csup>特别感谢：\u003C\u002Fsup>\n   \u003Cbr>\n   \u003Cbr>\n   \u003Ca href=\"https:\u002F\u002Fgo.warp.dev\u002Ftext-generation-webui\">\n      \u003Cimg alt=\"Warp赞助\" width=\"400\" src=\"https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Foobabooga_text-generation-webui_readme_7f26e93a2b2c.png\">\n   \u003C\u002Fa>\n\n### [Warp，专为多AI代理编码而打造](https:\u002F\u002Fgo.warp.dev\u002Ftext-generation-webui)\n[适用于macOS、Linux和Windows](https:\u002F\u002Fgo.warp.dev\u002Ftext-generation-webui)\u003Cbr>\n\u003C\u002Fdiv>\n\u003Chr>\n\n# 文本生成Web界面\n\n一个用于在本地运行大型语言模型的Gradio Web界面。100%私密且离线。支持文本生成、视觉理解、工具调用、训练、图像生成等功能。\n\n[试用Deep Reason扩展](https:\u002F\u002Foobabooga.gumroad.com\u002Fl\u002Fdeep_reason)\n\n|![Image1](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Foobabooga_text-generation-webui_readme_8fd8317211fb.png) | ![Image2](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Foobabooga_text-generation-webui_readme_b3045e962f07.png) |\n|:---:|:---:|\n|![Image1](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Foobabooga_text-generation-webui_readme_3d57a82deb15.png) | ![Image2](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Foobabooga_text-generation-webui_readme_ec69549cd9e8.png) |\n\n## 功能特性\n\n- **轻松部署**：适用于Windows\u002FLinux\u002FmacOS的GGUF模型的[便携式版本](https:\u002F\u002Fgithub.com\u002Foobabooga\u002Ftext-generation-webui\u002Freleases)（无需任何设置，解压即用），或一键安装完整功能集。\n- **多后端支持**：支持[llama.cpp](https:\u002F\u002Fgithub.com\u002Fggerganov\u002Fllama.cpp)、[Transformers](https:\u002F\u002Fgithub.com\u002Fhuggingface\u002Ftransformers)、[ExLlamaV3](https:\u002F\u002Fgithub.com\u002Fturboderp-org\u002Fexllamav3)以及[TensorRT-LLM](https:\u002F\u002Fgithub.com\u002FNVIDIA\u002FTensorRT-LLM)。可在不同后端和模型之间无缝切换，无需重启。\n- **兼容OpenAI\u002FAnthropic API**：提供聊天、补全和消息端点，并支持工具调用功能。可用作OpenAI\u002FAnthropic API的本地替代方案（[示例](https:\u002F\u002Fgithub.com\u002Foobabooga\u002Ftext-generation-webui\u002Fwiki\u002F12-%E2%80%90-OpenAI-API#examples)）。\n- **工具调用**：模型可以在对话过程中调用自定义函数——如网络搜索、网页抓取、数学计算等。每个工具只需一个`.py`文件即可实现，易于创建和扩展（[教程](https:\u002F\u002Fgithub.com\u002Foobabooga\u002Ftext-generation-webui\u002Fwiki\u002FTool-Calling-Tutorial)）。\n- **视觉理解（多模态）**：可将图片附加到消息中，以实现视觉内容的理解（[教程](https:\u002F\u002Fgithub.com\u002Foobabooga\u002Ftext-generation-webui\u002Fwiki\u002FMultimodal-Tutorial)）。\n- **文件附件**：支持上传文本文件、PDF文档和.docx文档，以便围绕其内容进行对话。\n- **模型训练**：可在多轮对话或原始文本数据集上微调LoRA模型。支持中断后继续训练（[教程](https:\u002F\u002Fgithub.com\u002Foobabooga\u002Ftext-generation-webui\u002Fwiki\u002F05-%E2%80%90-Training-Tab)）。\n- **图像生成**：专门设有针对`diffusers`模型（如Z-Image-Turbo）的标签页。支持4位\u002F8位量化，并配备带有元数据的持久化图库（[教程](https:\u002F\u002Fgithub.com\u002Foobabooga\u002Ftext-generation-webui\u002Fwiki\u002FImage-Generation-Tutorial)）。\n- 100%离线与私密，无任何遥测、外部资源或远程更新请求。\n- 提供`instruct`模式用于指令遵循任务（类似ChatGPT），以及`chat-instruct`和`chat`模式用于与自定义角色对话。提示会自动使用Jinja2模板格式化。\n- 可编辑消息、在不同版本间切换，也可在任意时间点对对话进行分支。\n- 在“Notebook”标签页中可自由进行文本生成，不受限于对话轮次。\n- 多种采样参数和生成选项，便于精细控制文本生成过程。\n- 支持深色\u002F浅色主题、代码块语法高亮显示，以及数学表达式的LaTeX渲染。\n- 扩展支持，内置及用户贡献的扩展众多。详情请参阅[wiki](https:\u002F\u002Fgithub.com\u002Foobabooga\u002Ftext-generation-webui\u002Fwiki\u002F07-%E2%80%90-Extensions)和[扩展目录](https:\u002F\u002Fgithub.com\u002Foobabooga\u002Ftext-generation-webui-extensions)。\n\n## 安装方法\n\n#### ✅ 方法一：便携式版本（1分钟快速上手）\n\n无需安装，直接下载、解压并运行即可。所有依赖项均已包含在内。\n\n下载地址：**https:\u002F\u002Fgithub.com\u002Foobabooga\u002Ftext-generation-webui\u002Freleases**\n\n- 提供适用于Linux、Windows和macOS的版本，分别支持CUDA、Vulkan、ROCm及纯CPU运行。\n- 兼容GGUF（llama.cpp）模型。\n\n#### 方法二：手动便携式安装（使用虚拟环境）\n\n非常快速的安装方式，适用于任何Python 3.9及以上版本：\n\n```bash\n# 克隆仓库\ngit clone https:\u002F\u002Fgithub.com\u002Foobabooga\u002Ftext-generation-webui\ncd text-generation-webui\n\n# 创建虚拟环境\npython -m venv venv\n\n# 激活虚拟环境\n# Windows:\nvenv\\Scripts\\activate\n# macOS\u002FLinux:\nsource venv\u002Fbin\u002Factivate\n\n# 安装依赖（根据硬件选择合适的requirements\u002Fportable文件）\npip install -r requirements\u002Fportable\u002Frequirements.txt --upgrade\n\n# 启动服务器（基本命令）\npython server.py --portable --api --auto-launch\n\n# 工作结束后，退出虚拟环境\ndeactivate\n```\n\n#### 方法三：一键安装程序\n\n适用于需要额外后端（ExLlamaV3、Transformers）、训练、图像生成或扩展功能（TTS、语音输入、翻译等）的用户。需约10GB磁盘空间，并会下载PyTorch。\n\n1. 克隆仓库，或[下载源代码](https:\u002F\u002Fgithub.com\u002Foobabooga\u002Ftext-generation-webui\u002Farchive\u002Frefs\u002Fheads\u002Fmain.zip)并解压。\n2. 根据操作系统运行相应的启动脚本：`start_windows.bat`、`start_linux.sh`或`start_macos.sh`。\n3. 按照提示选择您的GPU供应商。\n4. 安装完成后，在浏览器中打开`http:\u002F\u002F127.0.0.1:7860`。\n\n后续若需重启Web界面，再次运行相同的`start_`脚本即可。\n\n您也可以直接通过命令行传递参数（如`.\u002Fstart_linux.sh --help`），或将参数添加到`user_data\u002FCMD_FLAGS.txt`文件中（如`--api`以启用API）。\n\n要更新软件，请运行对应操作系统的更新脚本：`update_wizard_windows.bat`、`update_wizard_linux.sh`或`update_wizard_macos.sh`。\n\n若需重新安装并创建全新的Python环境，删除`installer_files`文件夹后，再次运行`start_`脚本即可。\n\n\u003Cdetails>\n\u003Csummary>\n一键安装程序详细说明\n\u003C\u002Fsummary>\n\n### 一键安装程序\n\n该脚本使用 Miniforge 在 `installer_files` 文件夹中设置 Conda 环境。\n\n如果您需要在 `installer_files` 环境中手动安装某些内容，可以使用命令行脚本启动交互式 shell：`cmd_linux.sh`、`cmd_windows.bat` 或 `cmd_macos.sh`。\n\n* 无需以管理员或 root 权限运行这些脚本（`start_`、`update_wizard_` 或 `cmd_`）。\n* 要安装扩展的依赖项，建议使用更新向导脚本中的“安装\u002F更新扩展依赖项”选项。该脚本最后会安装项目的主要依赖项，以确保在版本冲突时优先使用这些依赖项。\n* 对于自动化安装，可以使用 `GPU_CHOICE`、`LAUNCH_AFTER_INSTALL` 和 `INSTALL_EXTENSIONS` 环境变量。例如：`GPU_CHOICE=A LAUNCH_AFTER_INSTALL=FALSE INSTALL_EXTENSIONS=TRUE .\u002Fstart_linux.sh`。\n\n\u003C\u002Fdetails>\n\n\u003Cdetails>\n\u003Csummary>\n使用 Conda 或 Docker 的手动完整安装\n\u003C\u002Fsummary>\n\n### 使用 Conda 的完整安装\n\n#### 0. 安装 Conda\n\nhttps:\u002F\u002Fgithub.com\u002Fconda-forge\u002Fminiforge\n\n在 Linux 或 WSL 上，可以通过以下两条命令自动安装 Miniforge：\n\n```\ncurl -sL \"https:\u002F\u002Fgithub.com\u002Fconda-forge\u002Fminiforge\u002Freleases\u002Flatest\u002Fdownload\u002FMiniforge3-Linux-x86_64.sh\" > \"Miniforge3.sh\"\nbash Miniforge3.sh\n```\n\n对于其他平台，请从以下链接下载：https:\u002F\u002Fgithub.com\u002Fconda-forge\u002Fminiforge\u002Freleases\u002Flatest\n\n#### 1. 创建一个新的 Conda 环境\n\n```\nconda create -n textgen python=3.13\nconda activate textgen\n```\n\n#### 2. 安装 PyTorch\n\n| 系统 | GPU | 命令 |\n|--------|---------|---------|\n| Linux\u002FWSL | NVIDIA | `pip3 install torch==2.9.1 --index-url https:\u002F\u002Fdownload.pytorch.org\u002Fwhl\u002Fcu128` |\n| Linux\u002FWSL | 仅 CPU | `pip3 install torch==2.9.1 --index-url https:\u002F\u002Fdownload.pytorch.org\u002Fwhl\u002Fcpu` |\n| Linux | AMD | `pip3 install https:\u002F\u002Frepo.radeon.com\u002Frocm\u002Fmanylinux\u002Frocm-rel-7.2\u002Ftorch-2.9.1%2Brocm7.2.0.lw.git7e1940d4-cp313-cp313-linux_x86_64.whl` |\n| MacOS + MPS | 任何 | `pip3 install torch==2.9.1` |\n| Windows | NVIDIA | `pip3 install torch==2.9.1 --index-url https:\u002F\u002Fdownload.pytorch.org\u002Fwhl\u002Fcu128` |\n| Windows | 仅 CPU | `pip3 install torch==2.9.1` |\n\n最新命令可在以下页面找到：https:\u002F\u002Fpytorch.org\u002Fget-started\u002Flocally\u002F。\n\n如果您需要 `nvcc` 手动编译某些库，则还需额外安装：\n\n```\nconda install -y -c \"nvidia\u002Flabel\u002Fcuda-12.8.1\" cuda\n```\n\n#### 3. 安装 Web UI\n\n```\ngit clone https:\u002F\u002Fgithub.com\u002Foobabooga\u002Ftext-generation-webui\ncd text-generation-webui\npip install -r requirements\u002Ffull\u002F\u003C根据下表选择的依赖文件>\n```\n\n应使用的依赖文件：\n\n| GPU | 应使用的依赖文件 |\n|--------|---------|\n| NVIDIA | `requirements.txt` |\n| AMD | `requirements_amd.txt` |\n| 仅 CPU | `requirements_cpu_only.txt` |\n| Apple Intel | `requirements_apple_intel.txt` |\n| Apple Silicon | `requirements_apple_silicon.txt` |\n\n### 启动 Web UI\n\n```\nconda activate textgen\ncd text-generation-webui\npython server.py\n```\n\n然后访问：\n\n`http:\u002F\u002F127.0.0.1:7860`\n\n#### 手动安装\n\n上述 `requirements*.txt` 文件包含通过 GitHub Actions 预编译的各种轮子包。如果您希望手动编译某些内容，或者因为您的硬件没有合适的轮子包而必须手动编译，可以使用 `requirements_nowheels.txt`，然后手动安装您所需的加载器。\n\n### 替代方案：Docker\n\n```\n对于 NVIDIA GPU：\nln -s docker\u002F{nvidia\u002FDockerfile,nvidia\u002Fdocker-compose.yml,.dockerignore} .\n对于 AMD GPU：\nln -s docker\u002F{amd\u002FDockerfile,amd\u002Fdocker-compose.yml,.dockerignore} .\n对于 Intel GPU：\nln -s docker\u002F{intel\u002FDockerfile,intel\u002Fdocker-compose.yml,.dockerignore} .\n对于仅 CPU：\nln -s docker\u002F{cpu\u002FDockerfile,cpu\u002Fdocker-compose.yml,.dockerignore} .\ncp docker\u002F.env.example .env\n# 创建日志\u002F缓存目录：\nmkdir -p user_data\u002Flogs user_data\u002Fcache\n# 编辑 .env 并设置：\n#   TORCH_CUDA_ARCH_LIST 根据您的 GPU 型号\n#   APP_RUNTIME_GID      您主机用户的组 ID（在终端中运行 `id -g`）\n#   BUILD_EXTENIONS      可选地添加要构建的扩展列表，用逗号分隔\n# 编辑 user_data\u002FCMD_FLAGS.txt，并添加您想要执行的选项（如 --listen --cpu）\n#\ndocker compose up --build\n```\n\n* 您需要安装 Docker Compose v2.17 或更高版本。有关说明，请参阅[此指南](https:\u002F\u002Fgithub.com\u002Foobabooga\u002Ftext-generation-webui\u002Fwiki\u002F09-%E2%80%90-Docker)。\n* 如需更多 Docker 文件，请查看[此仓库](https:\u002F\u002Fgithub.com\u002FAtinoda\u002Ftext-generation-webui-docker)。\n\n### 更新依赖项\n\n`requirements*.txt` 文件会不时更新。要更新，请使用以下命令：\n\n```\nconda activate textgen\ncd text-generation-webui\npip install -r \u003C您之前使用的依赖文件> --upgrade\n```\n\u003C\u002Fdetails>\n\n\u003Cdetails>\n\u003Csummary>\n命令行标志列表\n\u003C\u002Fsummary>\n\n```txt\n用法：server.py [-h] [--user-data-dir USER_DATA_DIR] [--multi-user] [--model MODEL] [--lora LORA [LORA ...]] [--model-dir MODEL_DIR] [--lora-dir LORA_DIR] [--model-menu] [--settings SETTINGS]\n                 [--extensions EXTENSIONS [EXTENSIONS ...]] [--verbose] [--idle-timeout IDLE_TIMEOUT] [--image-model IMAGE_MODEL] [--image-model-dir IMAGE_MODEL_DIR] [--image-dtype {bfloat16,float16}]\n                 [--image-attn-backend {flash_attention_2,sdpa}] [--image-cpu-offload] [--image-compile] [--image-quant {none,bnb-8bit,bnb-4bit,torchao-int8wo,torchao-fp4,torchao-float8wo}]\n                 [--loader LOADER] [--ctx-size N] [--cache-type N] [--model-draft MODEL_DRAFT] [--draft-max DRAFT_MAX] [--gpu-layers-draft GPU_LAYERS_DRAFT] [--device-draft DEVICE_DRAFT]\n                 [--ctx-size-draft CTX_SIZE_DRAFT] [--spec-type {none,ngram-mod,ngram-simple,ngram-map-k,ngram-map-k4v,ngram-cache}] [--spec-ngram-size-n SPEC_NGRAM_SIZE_N]\n                 [--spec-ngram-size-m SPEC_NGRAM_SIZE_M] [--spec-ngram-min-hits SPEC_NGRAM_MIN_HITS] [--gpu-layers N] [--cpu-moe] [--mmproj MMPROJ] [--streaming-llm] [--tensor-split TENSOR_SPLIT]\n                 [--row-split] [--no-mmap] [--mlock] [--no-kv-offload] [--batch-size BATCH_SIZE] [--ubatch-size UBATCH_SIZE] [--threads THREADS] [--threads-batch THREADS_BATCH] [--numa]\n                 [--parallel PARALLEL] [--fit-target FIT_TARGET] [--extra-flags EXTRA_FLAGS] [--cpu] [--cpu-memory CPU_MEMORY] [--disk] [--disk-cache-dir DISK_CACHE_DIR] [--load-in-8bit] [--bf16]\n                 [--no-cache] [--trust-remote-code] [--force-safetensors] [--no_use_fast] [--attn-implementation IMPLEMENTATION] [--load-in-4bit] [--use_double_quant] [--compute_dtype COMPUTE_DTYPE]\n                 [--quant_type QUANT_TYPE] [--gpu-split GPU_SPLIT] [--enable-tp] [--tp-backend TP_BACKEND] [--cfg-cache] [--listen] [--listen-port LISTEN_PORT] [--listen-host LISTEN_HOST] [--share]\n                 [--auto-launch] [--gradio-auth GRADIO_AUTH] [--gradio-auth-path GRADIO_AUTH_PATH] [--ssl-keyfile SSL_KEYFILE] [--ssl-certfile SSL_CERTFILE] [--subpath SUBPATH] [--old-colors]\n                 [--portable] [--api] [--public-api] [--public-api-id PUBLIC_API_ID] [--api-port API_PORT] [--api-key API_KEY] [--admin-key ADMIN_KEY] [--api-enable-ipv6] [--api-disable-ipv4]\n                 [--nowebui] [--temperature N] [--dynatemp-low N] [--dynatemp-high N] [--dynatemp-exponent N] [--smoothing-factor N] [--smoothing-curve N] [--min-p N] [--top-p N] [--top-k N]\n                 [--typical-p N] [--xtc-threshold N] [--xtc-probability N] [--epsilon-cutoff N] [--eta-cutoff N] [--tfs N] [--top-a N] [--top-n-sigma N] [--adaptive-target N] [--adaptive-decay N]\n                 [--dry-multiplier N] [--dry-allowed-length N] [--dry-base N] [--repetition-penalty N] [--frequency-penalty N] [--presence-penalty N] [--encoder-repetition-penalty N]\n                 [--no-repeat-ngram-size N] [--repetition-penalty-range N] [--penalty-alpha N] [--guidance-scale N] [--mirostat-mode N] [--mirostat-tau N] [--mirostat-eta N]\n                 [--do-sample | --no-do-sample] [--dynamic-temperature | --no-dynamic-temperature] [--temperature-last | --no-temperature-last] [--sampler-priority N] [--dry-sequence-breakers N]\n                 [--enable-thinking | --no-enable-thinking] [--reasoning-effort N] [--chat-template-file CHAT_TEMPLATE_FILE]\n\n文本生成 Web UI\n\n选项：\n  -h, --help                                           显示此帮助信息并退出\n\n基本设置：\n  --user-data-dir USER_DATA_DIR                        用户数据目录路径。默认：自动检测。\n  --multi-user                                         多用户模式。聊天记录不会保存或自动加载。最适合小型可信团队使用。\n  --model MODEL                                        默认加载的模型名称。\n  --lora LORA [LORA ...]                               要加载的 LoRA 列表。如果要加载多个 LoRA，请用空格分隔名称。\n  --model-dir MODEL_DIR                                包含所有模型的目录路径。\n  --lora-dir LORA_DIR                                  包含所有 LoRA 的目录路径。\n  --model-menu                                         在首次启动 Web UI 时，在终端中显示模型菜单。\n  --settings SETTINGS                                  从该 YAML 文件加载默认界面设置。示例请参见 user_data\u002Fsettings-template.yaml。如果您创建名为\n                                                       user_data\u002Fsettings.yaml 的文件，系统将默认加载该文件，无需使用 --settings 标志。\n  --extensions EXTENSIONS [EXTENSIONS ...]             要加载的扩展列表。如果要加载多个扩展，请用空格分隔名称。\n  --verbose                                            将提示信息打印到终端。\n  --idle-timeout IDLE_TIMEOUT                          在不活动达到此时间（分钟）后卸载模型。再次尝试使用时会自动重新加载。\n\n图像模型：\n  --image-model IMAGE_MODEL                            启动时选择的图像模型名称（覆盖已保存的设置）。\n  --image-model-dir IMAGE_MODEL_DIR                    包含所有图像模型的目录路径。\n  --image-dtype {bfloat16,float16}                     图像模型的数据类型。\n  --image-attn-backend {flash_attention_2,sdpa}        图像模型的注意力机制后端。\n  --image-cpu-offload                                  启用图像模型的 CPU 卸载。\n  --image-compile                                      编译图像模型以加快推理速度。\n  --image-quant {none,bnb-8bit,bnb-4bit,torchao-int8wo,torchao-fp4,torchao-float8wo}\n                                                       图像模型的量化方法。\n\n模型加载器：\n  --loader LOADER                                      手动选择模型加载器，否则将自动检测。有效选项：Transformers、llama.cpp、ExLlamav3_HF、ExLlamav3、TensorRT-\n                                                       LLM。\n\n上下文与缓存：\n  --ctx-size, --n_ctx, --max_seq_len N                 上下文大小（以 token 为单位）。0 表示 llama.cpp 自动调整（需要 gpu-layers=-1），其他加载器则为 8192。\n  --cache-type, --cache_type N                         KV 缓存类型；有效选项：llama.cpp - fp16、q8_0、q4_0；ExLlamaV3 - fp16、q2 至 q8（可分别指定 k_bits 和 v_bits，例如 q4_q8）。\n\n推测解码：\n  --model-draft MODEL_DRAFT                            推测解码用草稿模型的路径。\n  --draft-max DRAFT_MAX                                推测解码时要草拟的标记数。\n  --gpu-layers-draft GPU_LAYERS_DRAFT                  草稿模型中卸载到GPU的层数。\n  --device-draft DEVICE_DRAFT                          用于卸载草稿模型的设备列表，以逗号分隔。例如：CUDA0,CUDA1\n  --ctx-size-draft CTX_SIZE_DRAFT                      草稿模型的提示上下文大小。若为0，则与主模型相同。\n  --spec-type {none,ngram-mod,ngram-simple,ngram-map-k,ngram-map-k4v,ngram-cache}\n                                                       无草稿推测解码类型。推荐：ngram-mod。\n  --spec-ngram-size-n SPEC_NGRAM_SIZE_N                ngram推测解码的n-gram查找大小。\n  --spec-ngram-size-m SPEC_NGRAM_SIZE_M                ngram推测解码的草稿n-gram大小。\n  --spec-ngram-min-hits SPEC_NGRAM_MIN_HITS            ngram-map推测解码所需的最小n-gram命中次数。\n\nllama.cpp：\n  --gpu-layers, --n-gpu-layers N                       卸载到GPU的层数。-1 = 自动。\n  --cpu-moe                                            将专家层移动到CPU（适用于MoE模型）。\n  --mmproj MMPROJ                                      视觉模型mmproj文件的路径。\n  --streaming-llm                                      启用StreamingLLM，以避免在移除旧消息时重新评估整个提示。\n  --tensor-split TENSOR_SPLIT                          将模型拆分到多个GPU上。以逗号分隔的比例列表。例如：60,40。\n  --row-split                                          按行将模型拆分到不同GPU上。这可能会提升多GPU性能。\n  --no-mmap                                            禁止使用mmap。\n  --mlock                                              强制系统将模型保留在RAM中。\n  --no-kv-offload                                      不将K、Q、V卸载到GPU。这可以节省显存，但会降低性能。\n  --batch-size BATCH_SIZE                              调用llama-server时，最多可将多少个提示标记合并为一批。这是应用层的批处理大小。\n  --ubatch-size UBATCH_SIZE                            调用llama-server时，最多可将多少个提示标记合并为一批。这是计算的最大物理批处理大小（设备级）。\n  --threads THREADS                                    使用的线程数。\n  --threads-batch THREADS_BATCH                        用于批处理\u002F提示处理的线程数。\n  --numa                                               为llama.cpp启用NUMA任务分配。\n  --parallel PARALLEL                                  并发请求槽位的数量。上下文大小会平均分配到各个槽位。例如，若要设置4个槽位，每个槽位8192个上下文，则将ctx_size设为32768。\n  --fit-target FIT_TARGET                              自动GPU层分配时，每个设备的目标显存余量，以MiB为单位的逗号分隔列表。单个值会广播到所有设备。\n                                                       默认：1024。\n  --extra-flags EXTRA_FLAGS                            传递给llama-server的额外参数。格式：“flag1=value1,flag2,flag3=value3”。例如：“override-tensor=exps=CPU”。\n\nTransformers\u002FAccelerate：\n  --cpu                                                使用CPU生成文本。警告：在CPU上训练极其缓慢。\n  --cpu-memory CPU_MEMORY                              最大CPU内存，单位为GiB。用于CPU卸载。\n  --disk                                               如果模型体积过大，超出GPU和CPU的总容量，则将剩余层发送到磁盘。\n  --disk-cache-dir DISK_CACHE_DIR                      保存磁盘缓存的目录。\n  --load-in-8bit                                       使用8位精度加载模型（使用bitsandbytes）。\n  --bf16                                               使用bfloat16精度加载模型。需要NVIDIA Ampere GPU。\n  --no-cache                                           在生成文本时将use_cache设为False。这会略微减少显存占用，但会牺牲性能。\n  --trust-remote-code                                  加载模型时将trust_remote_code设为True。对某些模型是必要的。\n  --force-safetensors                                  加载模型时将use_safetensors设为True。这可以防止任意代码执行。\n  --no_use_fast                                        加载分词器时将use_fast设为False（默认为True）。如果遇到与use_fast相关的问题，请使用此选项。\n  --attn-implementation IMPLEMENTATION                 注意力实现方式。有效选项：sdpa、eager、flash_attention_2。\n\nbitsandbytes 4位：\n  --load-in-4bit                                       使用4位精度加载模型（使用bitsandbytes）。\n  --use_double_quant                                   对4位使用双量化。\n  --compute_dtype COMPUTE_DTYPE                        4位计算的数据类型。有效选项：bfloat16、float16、float32。\n  --quant_type QUANT_TYPE                              4位量化类型。有效选项：nf4、fp4。\n\nExLlamaV3：\n  --gpu-split GPU_SPLIT                                每个GPU设备用于模型层的显存（单位：GB），以逗号分隔。例如：20,7,7。\n  --enable-tp, --enable_tp                             启用张量并行（TP）以将模型拆分到多个GPU上。\n  --tp-backend TP_BACKEND                              张量并行的后端。有效选项：native、nccl。默认：native。\n  --cfg-cache                                          为CFG负向提示创建额外缓存。使用该加载器时必须启用CFG。\n\nGradio：\n  --listen                                             使 Web UI 可通过本地网络访问。\n  --listen-port LISTEN_PORT                            服务器将使用的监听端口。\n  --listen-host LISTEN_HOST                            服务器将使用的主机名。\n  --share                                              创建一个公共 URL。这在 Google Colab 或类似平台上运行 Web UI 时非常有用。\n  --auto-launch                                        启动时在默认浏览器中打开 Web UI。\n  --gradio-auth GRADIO_AUTH                            设置 Gradio 身份验证密码，格式为“用户名:密码”。也可以使用“u1:p1,u2:p2,u3:p3”格式提供多个凭据。\n  --gradio-auth-path GRADIO_AUTH_PATH                  设置 Gradio 身份验证文件路径。该文件应包含一个或多个用户:密码对，格式与上述相同。\n  --ssl-keyfile SSL_KEYFILE                            SSL 证书密钥文件的路径。\n  --ssl-certfile SSL_CERTFILE                          SSL 证书证书文件的路径。\n  --subpath SUBPATH                                    自定义 Gradio 的子路径，用于反向代理。\n  --old-colors                                         使用 2024 年 12 月更新之前的旧版 Gradio 颜色。\n  --portable                                           隐藏便携模式下不可用的功能，例如训练。\n\nAPI：\n  --api                                                启用 API 扩展。\n  --public-api                                         使用 Cloudflare 为 API 创建公共 URL。\n  --public-api-id PUBLIC_API_ID                        命名式 Cloudflare 隧道的隧道 ID。需与 public-api 选项一起使用。\n  --api-port API_PORT                                  API 的监听端口。\n  --api-key API_KEY                                    API 身份验证密钥。\n  --admin-key ADMIN_KEY                                用于加载和卸载模型等管理任务的 API 身份验证密钥。若未设置，则与 --api-key 相同。\n  --api-enable-ipv6                                    为 API 启用 IPv6。\n  --api-disable-ipv4                                   禁用 API 的 IPv4。\n  --nowebui                                            不启动 Gradio UI。适用于以独立模式启动 API。\n\nAPI 生成默认参数：\n  --temperature N                                      温度\n  --dynatemp-low N                                     动态温度下限\n  --dynatemp-high N                                    动态温度上限\n  --dynatemp-exponent N                                动态温度指数\n  --smoothing-factor N                                 平滑因子\n  --smoothing-curve N                                  平滑曲线\n  --min-p N                                            Min P\n  --top-p N                                            Top P\n  --top-k N                                            Top K\n  --typical-p N                                        Typical P\n  --xtc-threshold N                                    XTC 阈值\n  --xtc-probability N                                  XTC 概率\n  --epsilon-cutoff N                                   Epsilon 截断\n  --eta-cutoff N                                       Eta 截断\n  --tfs N                                              TFS\n  --top-a N                                            Top A\n  --top-n-sigma N                                      Top N Sigma\n  --adaptive-target N                                  自适应目标\n  --adaptive-decay N                                   自适应衰减\n  --dry-multiplier N                                   DRY 乘数\n  --dry-allowed-length N                               DRY 允许长度\n  --dry-base N                                         DRY 基础\n  --repetition-penalty N                               重复惩罚\n  --frequency-penalty N                                频率惩罚\n  --presence-penalty N                                 存在惩罚\n  --encoder-repetition-penalty N                       编码器重复惩罚\n  --no-repeat-ngram-size N                             不重复 n-gram 大小\n  --repetition-penalty-range N                         重复惩罚范围\n  --penalty-alpha N                                    惩罚 alpha\n  --guidance-scale N                                   引导尺度\n  --mirostat-mode N                                    米罗斯特模式\n  --mirostat-tau N                                     米罗斯特 tau\n  --mirostat-eta N                                     米罗斯特 eta\n  --do-sample, --no-do-sample                          是否采样\n  --dynamic-temperature, --no-dynamic-temperature      是否启用动态温度\n  --temperature-last, --no-temperature-last            是否使用最后的温度\n  --sampler-priority N                                 采样器优先级\n  --dry-sequence-breakers N                            DRY 序列中断符\n  --enable-thinking, --no-enable-thinking              是否启用思考\n  --reasoning-effort N                                 思考力度\n  --chat-template-file CHAT_TEMPLATE_FILE              用于作为 API 请求默认指令模板的聊天模板文件路径（.jinja、.jinja2 或 .yaml）。会覆盖模型自带的模板。\n```\n\n\u003C\u002Fdetails>\n\n\n\n## 下载模型\n\n1. 从 [Hugging Face](https:\u002F\u002Fhuggingface.co\u002Fmodels?pipeline_tag=text-generation&sort=downloads&search=gguf) 下载 GGUF 格式的模型文件。\n2. 将其放入 `user_data\u002Fmodels` 文件夹中。\n\n这样就完成了。UI 会自动检测到该模型。\n\n要估算模型将占用多少内存，可以使用 [GGUF 内存计算器](https:\u002F\u002Fhuggingface.co\u002Fspaces\u002Foobabooga\u002Faccurate-gguf-vram-calculator)。\n\n\u003Cdetails>\n\u003Csummary>其他模型类型（Transformers、EXL3）\u003C\u002Fsummary>\n\n由多个文件组成的模型（如 16 位 Transformers 模型和 EXL3 模型）应放置在 `user_data\u002Fmodels` 文件夹内的子文件夹中：\n\n```\ntext-generation-webui\n└── user_data\n    └── models\n        └── Qwen_Qwen3-8B\n            ├── config.json\n            ├── generation_config.json\n            ├── model-00001-of-00004.safetensors\n            ├── ...\n            ├── tokenizer_config.json\n            └── tokenizer.json\n```\n\n这些格式需要使用一键安装程序（而非便携版）。\n\u003C\u002Fdetails>\n\n## 文档\n\nhttps:\u002F\u002Fgithub.com\u002Foobabooga\u002Ftext-generation-webui\u002Fwiki\n\n## 社区\n\nhttps:\u002F\u002Fwww.reddit.com\u002Fr\u002FOobabooga\u002F\n\n## 致谢\n\n- 2023年8月，[Andreessen Horowitz](https:\u002F\u002Fa16z.com\u002F)（a16z）慷慨地提供了资助，以鼓励和支持我在该项目上的独立工作。我对其信任与认可深表**感激**。\n- 本项目受到[AUTOMATIC1111\u002Fstable-diffusion-webui](https:\u002F\u002Fgithub.com\u002FAUTOMATIC1111\u002Fstable-diffusion-webui)的启发，若没有它，本项目将无从谈起。","# Text Generation Web UI 快速上手指南\n\nText Generation Web UI 是一个功能强大的本地大语言模型（LLM）运行界面。它支持 100% 离线隐私运行，兼容多种后端（llama.cpp, Transformers, ExLlamaV3 等），并提供聊天、文本生成、视觉理解、工具调用及模型微调等功能。\n\n## 环境准备\n\n### 系统要求\n- **操作系统**: Windows, Linux, macOS\n- **Python 版本**: Python 3.9+ (手动安装时推荐 3.10-3.12)\n- **硬件建议**:\n  - **GPU**: NVIDIA (CUDA), AMD (ROCm), Apple Silicon (MPS) 或 Intel GPU。显存越大可运行的模型参数量越大。\n  - **CPU**: 仅使用 CPU 也可运行（速度较慢），推荐使用 GGUF 格式模型。\n- **磁盘空间**: 完整安装需预留约 10GB+ 空间（不含模型文件）。\n\n### 前置依赖\n- **Git**: 用于克隆仓库。\n- **网络环境**: 首次安装需下载依赖库。国内用户建议配置 pip 镜像源以加速下载。\n  ```bash\n  # 临时使用清华源示例\n  export PIP_INDEX_URL=https:\u002F\u002Fpypi.tuna.tsinghua.edu.cn\u002Fsimple\n  ```\n\n## 安装步骤\n\n根据需求选择以下任一方案：\n\n### 方案一：便携版构建（推荐新手，最快上手）\n无需安装 Python 环境，解压即用，专为运行 GGUF 模型优化。\n\n1. 访问 [Releases 页面](https:\u002F\u002Fgithub.com\u002Foobabooga\u002Ftext-generation-webui\u002Freleases) 下载对应系统的压缩包（Windows\u002FLinux\u002FmacOS）。\n2. 解压文件夹。\n3. 运行启动脚本：\n   - Windows: `start_windows.bat` (便携版通常包含在 release 包中，具体文件名视版本而定，或直接运行目录下的启动程序)\n   - Linux\u002FmacOS: 终端进入目录运行对应的启动脚本。\n   > *注：便携版已预装所有依赖，适合只想快速体验 GGUF 模型的用户。*\n\n### 方案二：一键安装脚本（功能最全）\n适合需要完整功能（如训练、图像生成、多后端切换）的用户。\n\n1. 克隆仓库或下载源码并解压：\n   ```bash\n   git clone https:\u002F\u002Fgithub.com\u002Foobabooga\u002Ftext-generation-webui\n   cd text-generation-webui\n   ```\n\n2. 运行对应系统的启动脚本：\n   ```bash\n   # Windows\n   start_windows.bat\n   \n   # Linux\n   .\u002Fstart_linux.sh\n   \n   # macOS\n   .\u002Fstart_macos.sh\n   ```\n\n3. 按提示选择 GPU 厂商（如 NVIDIA, AMD, CPU 等）。\n4. 等待安装完成（自动创建 Conda 环境并下载 PyTorch 等依赖）。\n5. 浏览器访问 `http:\u002F\u002F127.0.0.1:7860` 即可使用。\n\n> **国内加速提示**：若脚本下载缓慢，可手动编辑脚本或使用环境变量指定镜像源，或在安装完成后手动替换 `installer_files` 环境中的 pip 源。\n\n### 方案三：手动安装 (Conda)\n适合高级用户或需要自定义环境的开发者。\n\n1. **安装 Miniforge\u002FConda** (推荐 Miniforge):\n   ```bash\n   curl -sL \"https:\u002F\u002Fgithub.com\u002Fconda-forge\u002Fminiforge\u002Freleases\u002Flatest\u002Fdownload\u002FMiniforge3-Linux-x86_64.sh\" > \"Miniforge3.sh\"\n   bash Miniforge3.sh\n   # 其他系统请前往官网下载\n   ```\n\n2. **创建环境并安装 PyTorch** (以 Linux + NVIDIA 为例):\n   ```bash\n   conda create -n textgen python=3.10\n   conda activate textgen\n   pip3 install torch==2.9.1 --index-url https:\u002F\u002Fdownload.pytorch.org\u002Fwhl\u002Fcu128\n   ```\n\n3. **安装项目依赖**:\n   ```bash\n   git clone https:\u002F\u002Fgithub.com\u002Foobabooga\u002Ftext-generation-webui\n   cd text-generation-webui\n   pip install -r requirements\u002Ffull\u002Frequirements.txt\n   ```\n\n4. **启动服务**:\n   ```bash\n   python server.py\n   ```\n\n## 基本使用\n\n1. **启动服务**\n   运行安装步骤中的启动脚本后，终端会显示类似信息：\n   ```text\n   Running on local URL: http:\u002F\u002F127.0.0.1:7860\n   ```\n   在浏览器打开该地址。\n\n2. **加载模型**\n   - 将下载的模型文件（如 `.gguf`, `.safetensors` 等）放入项目根目录下的 `models` 文件夹。\n   - 在网页界面左上角 \"Model\" 下拉菜单中选择已放入的模型。\n   - 点击 \"Load\" 按钮加载模型。\n\n3. **开始对话**\n   - 切换到 **Chat** 标签页。\n   - 在底部输入框输入内容，点击 \"Generate\" 或与模型进行多轮对话。\n   - 可在右侧 \"Parameters\" 调整温度 (Temperature)、最大令牌数 (Max new tokens) 等参数以控制生成效果。\n\n4. **进阶功能**\n   - **Notebook**: 适合自由文本生成，非对话模式。\n   - **Training**: 上传数据集对模型进行 LoRA 微调。\n   - **Extensions**: 在 \"Session\" -> \"Extensions\" 中启用插件（如语音输入、搜索工具等）。\n\n5. **API 调用**\n   启动时添加 `--api` 参数即可开启兼容 OpenAI 格式的 API 接口：\n   ```bash\n   python server.py --api\n   ```\n   端点地址：`http:\u002F\u002F127.0.0.1:5000\u002Fv1`","某独立开发者需要在无网络环境的保密项目中，利用本地大模型辅助编写代码并分析内部技术文档。\n\n### 没有 text-generation-webui 时\n- 必须将敏感代码或文档上传至云端 API，存在严重的数据泄露风险，且无法在断网环境下工作。\n- 切换不同量化版本或架构的模型（如从 GGUF 切换到 ExLlamaV3）需要重启服务甚至重新配置环境，效率极低。\n- 无法让模型直接读取本地的 PDF 需求文档或调用自定义的 Python 脚本工具，只能手动复制粘贴内容，交互割裂。\n- 缺乏对生成参数的精细控制，难以针对特定编程任务调整采样策略，导致代码生成质量不稳定。\n\n### 使用 text-generation-webui 后\n- 实现 100% 离线运行，所有代码推理与文档分析均在本地完成，彻底杜绝数据外传，完美适配保密开发场景。\n- 支持多后端无缝切换，开发者可在不重启界面的情况下即时对比不同模型在代码补全任务上的表现。\n- 直接上传内部技术 PDF 进行对话，并通过简单的 `.py` 文件挂载自定义工具，让模型能自动执行项目特定的检查脚本。\n- 提供丰富的采样参数调节面板和 Notebook 模式，可精准控制代码生成的逻辑性与创造性，显著提升产出可用性。\n\ntext-generation-webui 通过全本地化、多功能集成及高度可定制的特性，为隐私敏感型开发提供了安全且高效的私有智能助手方案。","https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Foobabooga_text-generation-webui_8fd83172.png","oobabooga",null,"https:\u002F\u002Foss.gittoolsai.com\u002Favatars\u002Foobabooga_cefad751.jpg","oobabooga4@gmail.com","https:\u002F\u002Fgithub.com\u002Foobabooga",[81,85,89,93,97,101,105],{"name":82,"color":83,"percentage":84},"Python","#3572A5",87.5,{"name":86,"color":87,"percentage":88},"JavaScript","#f1e05a",5.7,{"name":90,"color":91,"percentage":92},"CSS","#663399",4.9,{"name":94,"color":95,"percentage":96},"Shell","#89e051",0.7,{"name":98,"color":99,"percentage":100},"Batchfile","#C1F12E",0.5,{"name":102,"color":103,"percentage":104},"Dockerfile","#384d54",0.4,{"name":106,"color":107,"percentage":108},"Jupyter Notebook","#DA5B0B",0.3,46388,5903,"2026-04-03T08:16:49","AGPL-3.0","Linux, macOS, Windows","非必需（支持 CPU 模式）。若使用 GPU 加速，支持 NVIDIA (CUDA 12.8), AMD (ROCm 7.2), Intel, 或 Apple Silicon (MPS)。具体显存需求取决于模型大小和后端（如 ExLlamaV3, Transformers），README 未指定统一最低显存要求。","未说明（取决于模型大小，一键安装器需约 10GB 磁盘空间）",{"notes":117,"python":118,"dependencies":119},"提供多种安装方式：无需安装的便携版（仅支持 GGUF 模型）、一键安装器（支持所有功能，需约 10GB 磁盘空间）或手动 Conda\u002FDocker 安装。支持多种后端（llama.cpp, Transformers, ExLlamaV3, TensorRT-LLM）且无需重启即可切换。完全离线运行，无遥测。若需编译特定库，可能需要额外安装 nvcc (CUDA Toolkit)。Docker 用户需 Docker Compose v2.17+。","3.9+ (便携版\u002F手动 venv), 3.13 (Conda 完整安装示例)",[120,121,122,123,124,125,126,127],"torch (版本依硬件而定，如 2.9.1)","transformers","llama.cpp","ExLlamaV3","TensorRT-LLM","diffusers","Gradio","Miniforge (一键安装器用)",[26,14,13,15,54],12,"2026-03-27T02:49:30.150509","2026-04-06T07:11:47.233351",[133,138,143,148,152,157],{"id":134,"question_zh":135,"answer_zh":136,"source_url":137},12487,"AMD 显卡用户如何设置和运行 text-generation-webui？","目前 text-generation-webui 在 AMD 显卡上不再使用 ROCm，而是改用 Vulkan compute 后端。这意味着之前的许多针对 ROCm 的讨论可能不再适用。使用 Vulkan 后，即使在集成显卡（如 Framework 笔记本上的 780M）上也能运行，但建议使用较小的模型以获得更好性能。例如，运行 22B 参数模型（IQ3 量化）时速度约为 1.5 tokens\u002F秒。如果显存不足导致分页，性能会下降。","https:\u002F\u002Fgithub.com\u002Foobabooga\u002Ftext-generation-webui\u002Fissues\u002F3759",{"id":139,"question_zh":140,"answer_zh":141,"source_url":142},12488,"加载 LLaMA 模型时出现 'Tokenizer class LLaMATokenizer does not exist' 错误怎么办？","该错误通常是因为 transformers 库版本过旧或未正确导入 LLaMA 相关的 tokenizer 类。请确保安装了最新版本的 transformers 库。如果问题依旧，可能需要手动更新或重新安装包含 LLaMA 支持的 transformers 版本。此外，确认模型文件完整且位于正确的 models 目录下。","https:\u002F\u002Fgithub.com\u002Foobabooga\u002Ftext-generation-webui\u002Fissues\u002F147",{"id":144,"question_zh":145,"answer_zh":146,"source_url":147},12489,"LLaMA 模型支持哪些量化方法？GPTQ 量化效果如何？","支持 GPTQ 量化，这是目前 LLM 最先进的单次量化方法，可实现 3-bit 和 4-bit 权重量化。测试表明，4-bit GPTQ 量化的 LLaMA-7B 在 Wikitext2、PTB 和 C4 数据集上的表现接近 FP16 原版，远优于 RTN 量化。3-bit GPTQ 虽然精度有所下降，但仍显著优于 3-bit RTN。代码实现可参考 GPTQ-for-LLaMa 项目。","https:\u002F\u002Fgithub.com\u002Foobabooga\u002Ftext-generation-webui\u002Fissues\u002F177",{"id":149,"question_zh":150,"answer_zh":151,"source_url":147},12490,"不同显卡运行量化模型的性价比和性能对比如何？","根据社区数据：P40 ($200, 24GB) 约 8 tokens\u002Fs；RTX 3090 ($600, 24GB) 约 10 tokens\u002Fs；RTX 4090 ($1400, 24GB) 约 12-18 tokens\u002Fs（受 CPU 单核性能限制）。值得注意的是，exllama 分支可在 4090 上带来 150-200% 的速度提升，30B 模型全上下文下可达 45 tokens\u002Fs。对于预算有限的用户，二手 P40 或 3090 具有较高性价比；追求极致性能则推荐 4090 配合 exllama。",{"id":153,"question_zh":154,"answer_zh":155,"source_url":156},12491,"遇到 CUDA 版本不匹配错误（如检测到 12.1 但 PyTorch 编译于 11.7）如何解决？","可以通过降级 CUDA 版本来解决。方法一：修改 ~\u002F.bashrc 文件，添加以下行并执行 source ~\u002F.bashrc：\nexport CUDA_HOME=\"\u002Fusr\u002Flocal\u002Fcuda-11.7\"\nexport LD_LIBRARY_PATH=\"\u002Fusr\u002Flocal\u002Fcuda-11.7\u002Flib64:$LD_LIBRARY_PATH\"\nexport PATH=\"\u002Fusr\u002Flocal\u002Fcuda-11.7\u002Fbin:$PATH\"\n方法二：使用 conda 安装指定版本的 CUDA toolkit：\nconda install -c \"nvidia\u002Flabel\u002Fcuda-11.7.0\" cuda-toolkit\n确保系统与 PyTorch 使用的 CUDA 版本一致。","https:\u002F\u002Fgithub.com\u002Foobabooga\u002Ftext-generation-webui\u002Fissues\u002F1456",{"id":158,"question_zh":159,"answer_zh":160,"source_url":147},12492,"为什么生成文本时 CPU 单个核心占用率达到 100%？","这是因为当前 Python 实现中，文本生成过程是单线程的，无论使用多少核心的 CPU（如 Ryzen 或多核 Xeon），都只会占用一个核心至 100%。这是架构限制，并非异常。部分旧模型（如 RWKV）在加载时会利用多核，但生成阶段仍为单线程。若需提升速度，应考虑升级单核性能更强的 CPU 或使用更高效的推理后端（如 exllama）。",[162,167,172,177,182,187,192,197,202,207,212,217,222,227,232,237,242,247,252,257],{"id":163,"version":164,"summary_zh":165,"released_at":166},62820,"v4.3.1","## 变更\n\n- **Gemma 4 支持**，在 API 和 UI 中实现完整的工具调用功能。🆕\n- **ik_llama.cpp 支持**：通过新的 `textgen-portable-ik` 便携式构建以及全量安装的新 `--ik` 标志，新增 [ik_llama.cpp](https:\u002F\u002Fgithub.com\u002Fikawrakow\u002Fik_llama.cpp) 作为后端。ik_llama.cpp 是 imatrix 量化作者的分支，包含对新量化类型的支持、显著更精确的 KV 缓存量化（通过哈达玛 KV 缓存旋转，默认启用），以及针对 MoE 模型和 CPU 推理的优化。\n- API：为 `\u002Fv1\u002Fcompletions` 添加回显 + 对数概率功能。补全端点现在支持 `echo` 和 `logprobs` 参数，返回提示词和生成文本的 token 级别对数概率。输出中还通过新的 `top_logprobs_ids` 字段包含 token ID。\n- 进一步优化我的自定义 Gradio 分支，每次 UI 事件（按钮点击等）可节省高达 50 毫秒。\n- Transformers：从模型配置中自动检测 `torch_dtype`，不再强制使用 bfloat16 或 float16。`--bf16` 标志仍可用作覆盖选项。\n- 移除已废弃的 `models\u002Fconfig.yaml` 文件。指令模板现在从模型元数据中检测，而非依赖文件名模式。\n- 将终端日志消息中的“截断长度”更名为“上下文长度”。\n\n## 安全性\n\n- Gradio 分支：修复 Windows\u002FmacOS 上因不区分大小写的路径匹配而导致的 ACL 绕过漏洞。\n- Gradio 分支：为 Dropdown、Radio 和 CheckboxGroup 添加服务器端验证。\n- 修复 superbooga 扩展中的 SSRF 漏洞：superbooga\u002Fsuperboogav2 获取的 URL 现在会经过验证，以阻止对私有\u002F内部网络的请求。\n\n## 错误修复\n\n- 修复 `--idle-timeout` 在编码\u002F解码请求中失效，且无法正确跟踪并行生成的问题。\n- 修复 chromadb\u002Fcontext-1 的停止字符串检测问题（`\u003C|return|>` 与 `\u003C|result|>`）。\n- 修复 Qwen3.5 MoE 通过 ExLlamav3_HF 加载失败的问题。\n- 修复 `ban_eos_token` 对 ExLlamav3 无效的问题。EOS 现在会在 logits 层面被抑制。\n\n## 依赖更新\n\n- 将 llama.cpp 更新至 https:\u002F\u002Fgithub.com\u002Fggml-org\u002Fllama.cpp\u002Ftree\u002Fa1cfb645307edc61a89e41557f290f441043d3c2。\n  - **新增 Gemma-4 支持**\n  - **基于 TurboQuant https:\u002F\u002Fgithub.com\u002Fggml-org\u002Fllama.cpp\u002Fpull\u002F21038，新增通过激活旋转实现的改进 KV 缓存量化**\n- 将 ExLlamaV3 更新至 0.0.28。\n- 将 transformers 更新至 5.5。\n\n-----\n\n## 便携式构建\n\n以下为您提供可独立运行的软件包，支持 GGUF 模型（llama.cpp），并且**无需安装**！只需下载适合您系统的版本，解压后即可运行。\n\n#### 应下载哪个版本：\n\n- Windows\u002FLinux：\n  - NVIDIA 显卡\n    - 较旧驱动：使用 **`cuda12.4`**。\n    - 较新驱动（nvidia-smi 报告 CUDA 版本 ≥ 13.1）：使用 `cuda13.1`。\n  - AMD\u002FIntel 显卡：使用 `vulkan`。\n  - AMD 显卡（ROCm）：使用 `rocm`。\n  - 仅 CPU：使用 `cpu`。\n- Mac：\n  - Apple Silicon：使用 `macos-arm64`。\n  - Intel：使用 `macos-x86_64`。\n\n**`textgen-portable-ik` 适用于 [ik-llama.cpp](https:\u002F\u002Fgithub.com\u002Fikawrakow\u002Fi**","2026-04-03T03:54:31",{"id":168,"version":169,"summary_zh":170,"released_at":171},62821,"v4.3","已更新至 v4.3.1！\n\nhttps:\u002F\u002Fgithub.com\u002Foobabooga\u002Ftext-generation-webui\u002Freleases\u002Ftag\u002Fv4.3.1","2026-04-03T01:22:35",{"id":173,"version":174,"summary_zh":175,"released_at":176},62822,"v4.2","| 之前 | 之后 |\r\n|------|----------|\r\n| \u003Cimg width=\"888\" height=\"674\" alt=\"before\" src=\"https:\u002F\u002Fgithub.com\u002Fuser-attachments\u002Fassets\u002Fe68422a4-6e40-4377-80c2-8dfd4cbbef39\" \u002F>  | \u003Cimg width=\"888\" height=\"674\" alt=\"after\" src=\"https:\u002F\u002Fgithub.com\u002Fuser-attachments\u002Fassets\u002Ff9cfb462-b91d-4638-bd56-db8e0302d3cf\" \u002F> |\r\n\r\n## 变更内容\r\n\r\n- **Anthropic 兼容 API**：新增 `\u002Fv1\u002Fmessages` 端点，允许您连接 Claude Code、Cursor 以及其他 Anthropic API 客户端。支持系统消息、内容块、工具使用、工具结果、图像输入和思考块。与 Claude Code 搭配使用时，请设置：`ANTHROPIC_BASE_URL=http:\u002F\u002F127.0.0.1:5000 claude`。\r\n- **更新的 UI 主题**：在浅色和深色模式下，采用了全新的颜色、边框和按钮样式。\r\n- **`--extra-flags` 现在支持字面量标志**：现在可以直接传递标志，例如 `--extra-flags \"--rpc 192.168.1.100:50052 --jinja\"`。旧的 `key=value` 格式仍被接受，以保持向后兼容性。\r\n- 训练\r\n  - 默认启用 `gradient_checkpointing`，以降低训练过程中的显存占用。\r\n  - 移除任意的 `higher_rank_limit` 参数。\r\n  - 重新组织了训练界面。\r\n- 在解析工具调用之前移除思考块，以防止因 `\u003Cthink>` 内容而导致的误检工具调用。\r\n- 将 OpenAI 兼容 API 从 `extensions\u002Fopenai` 迁移到 `modules\u002Fapi`。旧的 `--extensions openai` 标志仍然作为 `--api` 的别名被接受。\r\n- 将 `top_p=0.95` 设置为 API 请求的默认采样参数。\r\n- 移除 52 个过时的 2023 年指令模板（Airoboros、Baichuan、Guanaco、Koala、Vicuna v0、MOSS 等）。\r\n- 通过使用精简版 Python 发行包，减小便携式构建的体积。\r\n\r\n## 错误修复\r\n\r\n- 修复在上下文截断的情况下继续聊天时提示词损坏的问题（#7439）。感谢 @Phrosty1。\r\n- 修复 Kimi 模型多轮思考块损坏的问题。\r\n- 修复 AMD 安装程序无法解析 ROCm triton 依赖的问题。\r\n- 修复 Gradio 分支中的 `--share` 功能。\r\n- 修复 `--extra-flags` 导致仅限长格式的短标志（如 `--rpc`）失效的问题。\r\n- 修复指令模板删除对话框不显示的问题。\r\n- 修复模型元数据加载中的文件句柄泄漏和冗余重读问题（#7422）。感谢 @alvinttang。\r\n- 修复 superboogav2 删除端点失效的问题（#6010）。感谢 @Raunak-Kumar7。\r\n- 修复 API 响应中推理后 `content` 的首部空格问题。\r\n- 修复 Cloudflare 隧道重试逻辑在首次失败后就停止，而非尝试所有重试机会的问题。\r\n- 修复 `OPENEDAI_DEBUG=0` 被视为真值的问题。\r\n- 修复 LogitsBiasProcessor 中可变默认参数的问题（#7426）。感谢 @Jah-yee。\r\n\r\n## 依赖项更新\r\n\r\n- 更新 llama.cpp 至 https:\u002F\u002Fgithub.com\u002Fggml-org\u002Fllama.cpp\u002Ftree\u002F3fc6f1aed172602790e9088b57786109438c2466\r\n- 更新 ExLlamaV3 至 0.0.26\r\n\r\n-----\r\n\r\n## 便携式构建\r\n\r\n以下为您提供自包含的软件包，它们支持 GGUF 模型（llama.cpp），并且**无需安装**！只需下载适合您系统的版本，解压并运行即可。\r\n\r\n#### 应该下载哪个版本？","2026-03-24T19:39:58",{"id":178,"version":179,"summary_zh":180,"released_at":181},62823,"v4.1.1","\u003Cimg width=\"600\" alt=\"print\" src=\"https:\u002F\u002Fgithub.com\u002Fuser-attachments\u002Fassets\u002F73a5be81-05d9-4d75-b13e-f73c8cf4bab1\" \u002F>\r\n\r\n\r\n## 变更说明\r\n\r\n- **UI 中的工具调用！**: 模型现在可以在聊天过程中调用自定义函数。每个工具都是 `user_data\u002Ftools` 目录下的一个单独 `.py` 文件，我们提供了五个示例：`web_search`、`fetch_webpage`、`calculate`、`get_datetime` 和 `roll_dice`。在流式响应中，每次工具调用都会以可折叠的 accordion 风格呈现，类似于现有的思考块，显示被调用的函数、LLM 选择的参数以及输出结果。[[教程]](https:\u002F\u002Fgithub.com\u002Foobabooga\u002Ftext-generation-webui\u002Fwiki\u002FTool-Calling-Tutorial)\r\n- 使用 `trafilatura` 替代 `html2text` 来从网页中提取文本，大幅减少了导航栏等冗余内容，从而在代理式的工具调用循环中节省了 token 数量。\r\n- **OpenAI API 改进**:\r\n  - 重写 `logprobs` 支持，确保在 llama.cpp、ExLlamaV3 和 Transformers 后端上完全符合规范。无论是流式还是非流式响应，现在都会返回逐 token 的 logprobs。\r\n  - 在流式和非流式聊天完成中为思考块添加 `reasoning_content` 字段。现在思考块将专门放在该字段中，而 `content` 字段仅显示经过思考后的回复内容，即使存在工具调用也是如此。\r\n  - 添加 `tool_choice` 支持，并修复了 `tool_calls` 响应格式，以严格遵守规范。\r\n  - 将对话中间的系统消息放置到提示词中的正确位置，而不是将所有系统消息都合并到顶部。\r\n  - 添加对 `developer` 角色的支持，并将其映射为 `system` 角色。\r\n  - 添加 `max_completion_tokens` 作为 `max_tokens` 的别名。\r\n  - 在终端打印的 API URL 中加入 `\u002Fv1`，因为大多数客户端都期望使用这种格式。\r\n  - 使 `\u002Fv1\u002Fmodels` 端点仅显示当前加载的模型。\r\n  - 为流式响应添加 `stream_options` 支持，并包含 `include_usage` 选项。\r\n  - 当检测到工具调用时，返回 `finish_reason: tool_calls`。\r\n  - 经过仔细审计后，还进行了其他多项规范合规性改进。\r\n- llama.cpp\r\n  - 默认将 `ctx-size` 设置为 `0`（自动）。注意：这仅在同时将 `--gpu-layers` 设置为 `-1` 时才有效，而 `-1` 是默认值。当使用其他加载器时，`0` 会映射为 `8192`。\r\n  - 将 `--fit-target` 的默认值从 1024 MiB 降低至 512 MiB。\r\n  - 使用 `--fit-ctx 8192` 将 `--fit on` 的最小可接受上下文大小设置为 8192（llama.cpp 默认为 4096）。\r\n  - 使 `logit_bias` 和 `logprobs` 在 API 调用中可用。\r\n  - 在 UI 中添加缺失的 `custom_token_bans` 参数。\r\n- ExLlamaV3\r\n  - 原生支持 `logit_bias` 和 `logprobs`。\r\n  - 在加载主模型之前先加载视觉模型和草稿模型，以便内存自动分割能够考虑到它们的影响。\r\n- 新的默认预设：“Top-P”（`top_p: 0.95`），遵循多个 SOTA 开源权重模型的推荐设置。旧的“Qwen3 - 思考”、“Qwen3 - 不思考”、“min_p”和“Instruct”预设已被移除。\r\n- 重构推理\u002F思考部分","2026-03-18T05:33:05",{"id":183,"version":184,"summary_zh":185,"released_at":186},62824,"v4.1","已更新至 v4.1.1！\n\nhttps:\u002F\u002Fgithub.com\u002Foobabooga\u002Ftext-generation-webui\u002Freleases\u002Ftag\u002Fv4.1.1","2026-03-16T15:53:03",{"id":188,"version":189,"summary_zh":190,"released_at":191},62825,"v4.0","## 变更说明\r\n\r\n- **自定义 Gradio 分支**：Gradio 已被替换为位于 [oobabooga\u002Fgradio](https:\u002F\u002Fgithub.com\u002Foobabooga\u002Fgradio) 的自定义分支，其中进行了多项重大性能优化。UI 现在每次更新时会减少大量冗余工作，启动速度更快，SSE 消息传递改为即时推送而非每 50 毫秒轮询一次，并且新增的零渲染 `gr.Headless` 组件可降低聊天流式传输过程中的开销。此外，还从安装包中移除了分析工具、未使用的依赖项和资源文件。\r\n- **工具调用全面改进**：现在 Qwen 3.5、Devstral 2、GPT-OSS、DeepSeek V3.2、GLM 5、MiniMax M2.5、Kimi K2\u002FK2.5 以及 Llama 4 等模型的工具调用功能已正式生效。同时，针对严格遵循 OpenAI 格式的要求也做了多项优化。经过大量测试，确保所支持的模型都能完美实现工具调用功能。[[文档]](https:\u002F\u002Fgithub.com\u002Foobabooga\u002Ftext-generation-webui\u002Fwiki\u002F12-%E2%80%90-OpenAI-API#toolfunction-calling)\r\n- **并行 API 请求**：对于 llama.cpp、ExLlamaV3 和 TensorRT-LLM 加载器，现在可以并发发起 API 请求以获得最大吞吐量。使用 llama.cpp 时，需配合 `--parallel N` 参数，并将上下文长度乘以 `N`。[[文档]](https:\u002F\u002Fgithub.com\u002Foobabooga\u002Ftext-generation-webui\u002Fwiki\u002F12-%E2%80%90-OpenAI-API#python-parallel-requests-example)\r\n- **训练模块全面重构**（[文档](https:\u002F\u002Fgithub.com\u002Foobabooga\u002Ftext-generation-webui\u002Fwiki\u002F05-%E2%80%90-Training-Tab)）：训练代码已被完全重写，现与 [axolotl](https:\u002F\u002Fgithub.com\u002Faxolotl-ai-cloud\u002Faxolotl) 完全一致，适用于原始文本训练和对话训练两种场景。\r\n  - 对话训练方面，现已支持 OpenAI `messages` 格式或 ShareGPT `conversations` 格式的数据集。多轮对话得到完整支持，并会对用户输入进行正确掩码处理，从而仅对助手消息进行训练。示例文件请参见 `user_data\u002Ftraining\u002Fexample_messages.json` 和 `user_data\u002Ftraining\u002Fexample_sharegpt.json`。\r\n  - 原始文本训练则采用 JSONL 文件格式，为每个子文档正确添加 BOS 和 EOS 标记。示例输入文件请参见 `user_data\u002Ftraining\u002Fexample_text.json`。\r\n  - 对话训练现使用 jinja2 模板来格式化提示词。用户可以选择模型自带的模板（如有），也可提供自定义模板。\r\n  - 新增“应用到所有线性层”复选框，可将 LoRA 应用于除 `lm_head` 外的每一个 `nn.Linear` 层，该功能适用于任何模型架构。\r\n  - 检查点恢复：系统会自动检测 HF Trainer 的检查点目录，并在保留优化器和调度器完整状态的情况下继续训练。\r\n  - 所有训练参数均已设置经过审核的良好默认值。\r\n  - 超过截断长度的对话现会被直接丢弃，而非静默截断（可配置）。\r\n  - 动态填充（对话数据集）：批次现仅按本批次中最长序列进行填充，不再一律填充至 `cutoff_len`，从而减少不必要的计算开销。","2026-03-07T14:34:59",{"id":193,"version":194,"summary_zh":195,"released_at":196},62826,"v3.23","## 变更\n\n- 改进聊天消息中表格和水平分隔线的样式\n\n## 错误修复\n\n- 修复加载禁用了 EOS 令牌的模型的问题 (#7363)。感谢 @jin-eld。\n- 修复在更新非便携式安装时，llama-cpp-binaries 中的符号链接问题。\n\n## 后端更新\n\n* 将 llama.cpp 更新至 https:\u002F\u002Fgithub.com\u002Fggml-org\u002Fllama.cpp\u002Ftree\u002F55abc393552f3f2097f168cb6db4dc495a514d56\n* 将 bitsandbytes 更新至 0.49\n\n-----\n\n## 便携式版本\n\n以下是可独立运行、支持 GGUF 模型（llama.cpp）且**无需安装**的软件包！只需下载适合您系统的版本，解压后即可运行。\n\n#### 应下载哪个版本：\n\n- Windows\u002FLinux：\n  - NVIDIA 显卡：使用 `cuda12.4` 版本。\n  - AMD\u002FIntel 显卡：使用 `vulkan` 版本。\n  - 仅 CPU：使用 `cpu` 版本。\n\n- Mac：\n  - Apple Silicon：使用 `macos-arm64` 版本。\n\n#### 如何更新便携式安装：\n\n1. 下载并解压最新版本。\n2. 将 `user_data` 文件夹替换为您现有安装中的文件夹。您的所有设置和模型都将被保留。","2026-01-08T20:54:35",{"id":198,"version":199,"summary_zh":200,"released_at":201},62827,"v3.22","## 后端更新\r\n\r\n* 将 llama.cpp 更新至 https:\u002F\u002Fgithub.com\u002Fggml-org\u002Fllama.cpp\u002Ftree\u002Fce734a8a2f9fb6eb4f0383ab1370a1b0014ab787\r\n\r\n-----\r\n\r\n## 可移植版本\r\n\r\n以下提供了可独立运行的软件包，支持 GGUF 模型（llama.cpp），并且**无需安装**！只需下载适合您系统的版本，解压后即可运行。\n\n#### 应下载哪个版本：\n\n- Windows\u002FLinux：\n  - NVIDIA 显卡：使用 `cuda12.4` 版本。\n  - AMD 或 Intel 显卡：使用 `vulkan` 版本。\n  - 仅 CPU：使用 `cpu` 版本。\n\n- Mac：\n  - Apple Silicon 芯片：使用 `macos-arm64` 版本。\n\n#### 如何更新可移植安装：\n\n1. 下载并解压最新版本。\n2. 将 `user_data` 文件夹替换为您现有安装中的 `user_data` 文件夹。您的所有设置和模型都将被保留。","2025-12-20T05:19:46",{"id":203,"version":204,"summary_zh":205,"released_at":206},62828,"v3.21","## 变更\n\n- 减小所有 Linux\u002FmacOS 便携版的体积，方法是移除 llama.cpp 的符号链接（由于 Python whl 的限制已解析为实际文件），并在首次启动时重新创建这些链接。\n\n## 后端更新\n\n* 将 llama.cpp 更新至 https:\u002F\u002Fgithub.com\u002Fggml-org\u002Fllama.cpp\u002Ftree\u002F5c8a717128cc98aa9e5b1c44652f5cf458fd426e\n* 将 ExLlamaV3 更新至 0.0.18\n* 将 safetensors 更新至 0.7\n* 将 triton-windows 更新至 3.5.1.post22\n\n-----\n\n## 便携版构建\n\n以下是可独立运行的软件包，支持 GGUF 模型（llama.cpp），且**无需安装**！只需下载适合您系统的版本，解压后即可运行。\n\n#### 应下载哪个版本：\n\n- Windows\u002FLinux：\n  - NVIDIA 显卡：使用 `cuda12.4` 版本。\n  - AMD\u002FIntel 显卡：使用 `vulkan` 版本。\n  - 仅 CPU：使用 `cpu` 版本。\n\n- Mac：\n  - Apple Silicon：使用 `macos-arm64` 版本。\n\n#### 如何更新便携版安装：\n\n1. 下载并解压最新版本。\n2. 将 `user_data` 文件夹替换为您现有安装中的 `user_data` 文件夹。您的所有设置和模型都将被保留。","2025-12-15T01:59:41",{"id":208,"version":209,"summary_zh":210,"released_at":211},62829,"v3.20","# 图像生成支持！\n\n\u003Cimg width=\"1920\" height=\"1080\" alt=\"523303375-5108de50-658b-4e93-b2ae-4656d076bc9d\" src=\"https:\u002F\u002Fgithub.com\u002Fuser-attachments\u002Fassets\u002Ffe245937-c77d-49ac-adf6-bd2007e9b7ee\" \u002F>\n\n## 更改内容\n\n- **图像生成支持**：在新的“图像 AI”选项卡中，使用如 [Z-Image-Turbo](https:\u002F\u002Fhuggingface.co\u002FTongyi-MAI\u002FZ-Image-Turbo) 等 `diffusers` 模型生成图像。功能包括：\n  - 4位\u002F8位量化\n  - `torch.compile` 支持\n  - LLM 生成的提示词变体\n  - PNG 元数据用于记录生成设置\n  - 历史生成作品图库\n  - 进度条\n  - OpenAI 兼容的图像生成 API 端点\n\n有关分步教程，请参阅：[**图像生成教程**](https:\u002F\u002Fgithub.com\u002Foobabooga\u002Ftext-generation-webui\u002Fwiki\u002FImage-Generation-Tutorial)\n\n- 将 `bos_token` 和 `eos_token` 传递给 jinja2 模板，从而可以将该模板用于 `Seed-OSS-36B-Instruct` 及其他模型。\n- 默认为 Transformers 模型启用 `flash_attention_2`。\n\n## 错误修复\n\n- 修复 API 请求始终返回相同 `created` 时间的问题。\n\n## 后端更新\n\n- 将 llama.cpp 更新至 https:\u002F\u002Fgithub.com\u002Fggml-org\u002Fllama.cpp\u002Ftree\u002F0a540f9abd98915edb99fed47d80078ed8d2f343\n- 将 ExLlamaV3 更新至 0.0.17\n\n-----\n\n## 便携式版本\n\n以下提供了可独立运行的软件包，支持 GGUF 模型（llama.cpp），并且**无需安装**！只需下载适合您系统的版本，解压并运行即可。\n\n#### 应下载哪个版本：\n\n- Windows\u002FLinux：\n  - NVIDIA 显卡：使用 `cuda12.4` 版本。\n  - AMD\u002FIntel 显卡：使用 `vulkan` 版本。\n  - 仅 CPU：使用 `cpu` 版本。\n\n- Mac：\n  - Apple Silicon：使用 `macos-arm64` 版本。\n\n#### 更新便携式安装：\n\n1. 下载并解压最新版本。\n2. 将现有安装中的 `user_data` 文件夹替换为新版本中的文件夹。您的所有设置和模型都将被迁移。","2025-12-07T20:58:45",{"id":213,"version":214,"summary_zh":215,"released_at":216},62830,"v3.19","# Qwen3-Next llama.cpp support!\r\n\r\n## Changes\r\n\r\n- Add slider for --ubatch-size for llama.cpp loader, change defaults for better MoE performance (#7316). Thanks, @GodEmperor785.\r\n  - This significantly improves prompt processing speeds for MoE models in both full-GPU and GPU+CPU configurations.\r\n\r\n## Bug fixes\r\n\r\n- fix(deps): upgrade coqui-tts to >=0.27.0 for transformers 4.55 compatibility (#7329). Thanks, @aidevtime. \r\n\r\n## Backend updates\r\n\r\n* Update llama.cpp to https:\u002F\u002Fgithub.com\u002Fggml-org\u002Fllama.cpp\u002Ftree\u002Fff55414c42522adbeaa1bd9c52c0e9db16942484, adding Qwen3-Next support\r\n* Update ExLlamaV3 to 0.0.16\r\n\r\n-----\r\n\r\n## Portable builds\r\n\r\nBelow you can find self-contained packages that work with GGUF models (llama.cpp) and **require no installation**! Just download the right version for your system, unzip, and run.\r\n\r\n#### Which version to download:\r\n\r\n- Windows\u002FLinux:\r\n  - NVIDIA GPU: Use `cuda12.4`.\r\n  - AMD\u002FIntel GPU: Use `vulkan` builds.\r\n  - CPU only: Use `cpu` builds.\r\n\r\n- Mac:\r\n  - Apple Silicon: Use `macos-arm64`.\r\n\r\n#### Updating a portable install:\r\n\r\n1. Download and unzip the latest version.\r\n2. Replace the `user_data` folder with the one in your existing install. All your settings and models will be moved.\r\n","2025-11-29T02:00:44",{"id":218,"version":219,"summary_zh":220,"released_at":221},62831,"v3.18","## Changes\r\n\r\n- Add `--cpu-moe` flag for llama.cpp to move MoE model experts to CPU, reducing VRAM usage.\r\n- Add ROCm portable builds for AMD GPUs on Linux. This was made possible by PR https:\u002F\u002Fgithub.com\u002Foobabooga\u002Fllama-cpp-binaries\u002Fpull\u002F7 by @ShortTimeNoSee. Thanks, @ShortTimeNoSee.\r\n- Remove deprecated macOS 13 wheels (no longer supported by GitHub Actions).\r\n\r\n## Backend updates\r\n\r\n* Update llama.cpp to https:\u002F\u002Fgithub.com\u002Fggml-org\u002Fllama.cpp\u002Ftree\u002F10e9780154365b191fb43ca4830659ef12def80f\r\n* Update ExLlamaV3 to 0.0.15\r\n* Update peft to 0.18.*\r\n* Update triton-windows to 3.5.1.post21\r\n\r\n-----\r\n\r\n## Portable builds\r\n\r\nBelow you can find self-contained packages that work with GGUF models (llama.cpp) and **require no installation**! Just download the right version for your system, unzip, and run.\r\n\r\n#### Which version to download:\r\n\r\n- Windows\u002FLinux:\r\n  - NVIDIA GPU: Use `cuda12.4`.\r\n  - AMD\u002FIntel GPU: Use `vulkan` builds.\r\n  - CPU only: Use `cpu` builds.\r\n\r\n- Mac:\r\n  - Apple Silicon: Use `macos-arm64`.\r\n\r\n#### Updating a portable install:\r\n\r\n1. Download and unzip the latest version.\r\n2. Replace the `user_data` folder with the one in your existing install. All your settings and models will be moved.\r\n","2025-11-19T14:04:23",{"id":223,"version":224,"summary_zh":225,"released_at":226},62832,"v3.17","## Changes\r\n\r\n- Add `weights_only=True` to `torch.load` in Training_PRO for better security.\r\n\r\n## Bug fixes\r\n\r\n- Pin huggingface-hub to 0.36.0 to fix manual venv installs.\r\n- fix: Rename 'evaluation_strategy' to 'eval_strategy' in training. Thanks, @inyourface34456.\r\n\r\n## Backend updates\r\n\r\n* Update llama.cpp to https:\u002F\u002Fgithub.com\u002Fggml-org\u002Fllama.cpp\u002Ftree\u002F230d1169e5bfe04a013b2e20f4662ee56c2454b0 (adds **Qwen3-VL** support)\r\n* Update exllamav3 to 0.0.12\r\n\r\n-----\r\n\r\n## Portable builds\r\n\r\nBelow you can find self-contained packages that work with GGUF models (llama.cpp) and **require no installation**! Just download the right version for your system, unzip, and run.\r\n\r\n#### Which version to download:\r\n\r\n- Windows\u002FLinux:\r\n  - NVIDIA GPU: Use `cuda12.4`.\r\n  - AMD\u002FIntel GPU: Use `vulkan` builds.\r\n  - CPU only: Use `cpu` builds.\r\n\r\n- Mac:\r\n  - Apple Silicon: Use `macos-arm64`.\r\n  - Intel CPU: Use `macos-x86_64`.\r\n\r\n#### Updating a portable install:\r\n\r\n1. Download and unzip the latest version.\r\n2. Replace the `user_data` folder with the one in your existing install. All your settings and models will be moved.\r\n","2025-11-06T03:39:00",{"id":228,"version":229,"summary_zh":230,"released_at":231},62833,"v3.16","## Changes\r\n\r\n* Make it possible to run a portable Web UI build via a symlink (#7277). Thanks, @reksar.\r\n\r\n## Bug fixes\r\n\r\n* Fixed python requirements for apple devices with macos tahoe (#7273). Thanks, @drieschel.\r\n\r\n## Backend updates\r\n\r\n* Update llama.cpp to https:\u002F\u002Fgithub.com\u002Fggml-org\u002Fllama.cpp\u002Ftree\u002Fd0660f237a5c31771a3d6d1030ebe3e0c409ba92 (adds Ling-mini-2.0, Ring-mini-2.0 support)\r\n* Update exllamav3 to 0.0.11\r\n* Update triton-windows to 3.5.0.post21\r\n\r\n-----\r\n\r\n## Portable builds\r\n\r\nBelow you can find self-contained packages that work with GGUF models (llama.cpp) and **require no installation**! Just download the right version for your system, unzip, and run.\r\n\r\n#### Which version to download:\r\n\r\n- Windows\u002FLinux:\r\n  - NVIDIA GPU: Use `cuda12.4` for newer GPUs or `cuda11.7` for older GPUs and systems with older drivers.\r\n  - AMD\u002FIntel GPU: Use `vulkan` builds.\r\n  - CPU only: Use `cpu` builds.\r\n\r\n- Mac:\r\n  - Apple Silicon: Use `macos-arm64`.\r\n  - Intel CPU: Use `macos-x86_64`.\r\n\r\n#### Updating a portable install:\r\n\r\n1. Download and unzip the latest version.\r\n2. Replace the `user_data` folder with the one in your existing install. All your settings and models will be moved.\r\n","2025-10-23T15:50:37",{"id":233,"version":234,"summary_zh":235,"released_at":236},62834,"v3.15","## Changes\r\n\r\n* log error when llama-server request exceeds context size (#7263). Thanks, @mamei16.\r\n* Make --trust-remote-code immutable from the UI\u002FAPI for better security.\r\n\r\n## Bug fixes\r\n\r\n* Fix metadata leaking into branched chats.\r\n* Fix \"continue\" missing an initial space in chat-instruct\u002Fchat modes.\r\n* Fix resuming incomplete downloads after HF moved to Xet.\r\n* Revert exllamav3_hf changes in v3.14 that made it output gibberish.\r\n\r\n## Backend updates\r\n\r\n* Update llama.cpp to https:\u002F\u002Fgithub.com\u002Fggml-org\u002Fllama.cpp\u002Ftree\u002Ff9fb33f2630b4b4ba9081ce9c0c921f8cd8ba4eb.\r\n* Update exllamav3 0.0.10.\r\n\r\n-----\r\n\r\n## Portable builds\r\n\r\nBelow you can find self-contained packages that work with GGUF models (llama.cpp) and **require no installation**! Just download the right version for your system, unzip, and run.\r\n\r\n#### Which version to download:\r\n\r\n- Windows\u002FLinux:\r\n  - NVIDIA GPU: Use `cuda12.4` for newer GPUs or `cuda11.7` for older GPUs and systems with older drivers.\r\n  - AMD\u002FIntel GPU: Use `vulkan` builds.\r\n  - CPU only: Use `cpu` builds.\r\n\r\n- Mac:\r\n  - Apple Silicon: Use `macos-arm64`.\r\n  - Intel CPU: Use `macos-x86_64`.\r\n\r\n#### Updating a portable install:\r\n\r\n1. Download and unzip the latest version.\r\n2. Replace the `user_data` folder with the one in your existing install. All your settings and models will be moved.\r\n","2025-10-15T20:15:51",{"id":238,"version":239,"summary_zh":240,"released_at":241},62835,"v3.14","## Changes\r\n\r\n* Better handle multi-GPU setups when using Transformers with bitsandbytes (`load-in-8bit` and `load-in-4bit`).\r\n* Implement the `\u002Fv1\u002Finternal\u002Flogits` endpoint for the `exllamav3` and `exllamav3_hf` loaders.\r\n* Make profile picture uploading safer.\r\n* Add `fla` to the requirements for Exllamav3 to support `qwen3-next` models.\r\n\r\n## Bug fixes\r\n\r\n* Fix an issue with loading certain chat histories in Instruct mode. Thanks, @Remowylliams.\r\n* Fix portable builds for macOS x86 missing llama.cpp binaries (#7238). Thanks, @IonoclastBrigham.\r\n\r\n## Backend updates\r\n\r\n* Update llama.cpp to https:\u002F\u002Fgithub.com\u002Fggml-org\u002Fllama.cpp\u002Ftree\u002Fd00cbea63c671cd85a57adaa50abf60b3b87d86f.\r\n* Update transformers to 4.57.\r\n* Update exllamav3 0.0.7.\r\n* Update bitsandbytes to 0.48.\r\n\r\n-----\r\n\r\n## Portable builds\r\n\r\nBelow you can find self-contained packages that work with GGUF models (llama.cpp) and **require no installation**! Just download the right version for your system, unzip, and run.\r\n\r\n#### Which version to download:\r\n\r\n- Windows\u002FLinux:\r\n  - NVIDIA GPU: Use `cuda12.4` for newer GPUs or `cuda11.7` for older GPUs and systems with older drivers.\r\n  - AMD\u002FIntel GPU: Use `vulkan` builds.\r\n  - CPU only: Use `cpu` builds.\r\n\r\n- Mac:\r\n  - Apple Silicon: Use `macos-arm64`.\r\n  - Intel CPU: Use `macos-x86_64`.\r\n\r\n#### Updating a portable install:\r\n\r\n1. Download and unzip the latest version.\r\n2. Replace the `user_data` folder with the one in your existing install. All your settings and models will be moved.\r\n","2025-10-10T13:47:17",{"id":243,"version":244,"summary_zh":245,"released_at":246},62836,"v3.13","## Bug fixes\r\n\r\n- Don't use `$ $` for LaTeX, only `$$ $$`, to avoid broken rendering of text like `apples cost $1, oranges cost $2`\r\n- Fix exllamav3 ignoring the stop button\r\n- Fix a transformers issue when using --bf16 and Flash Attention 2 (#7217). Thanks, @stevenxdavis.\r\n- Fix x86_64 macos portable builds containing arm64 files\r\n\r\n## Backend updates\r\n\r\n- Update llama.cpp to https:\u002F\u002Fgithub.com\u002Fggml-org\u002Fllama.cpp\u002Ftree\u002F7f766929ca8e8e01dcceb1c526ee584f7e5e1408\r\n- Update transformers to 4.56\r\n\r\n-----\r\n\r\n## Portable builds\r\n\r\nBelow you can find self-contained packages that work with GGUF models (llama.cpp) and **require no installation**! Just download the right version for your system, unzip, and run.\r\n\r\n#### Which version to download:\r\n\r\n- Windows\u002FLinux:\r\n  - NVIDIA GPU: Use `cuda12.4` for newer GPUs or `cuda11.7` for older GPUs and systems with older drivers.\r\n  - AMD\u002FIntel GPU: Use `vulkan` builds.\r\n  - CPU only: Use `cpu` builds.\r\n\r\n- Mac:\r\n  - Apple Silicon: Use `macos-arm64`.\r\n  - Intel CPU: Use `macos-x86_64`.\r\n\r\n#### Updating a portable install:\r\n\r\n1. Download and unzip the latest version.\r\n2. Replace the `user_data` folder with the one in your existing install. All your settings and models will be moved.\r\n","2025-09-21T04:19:44",{"id":248,"version":249,"summary_zh":250,"released_at":251},62837,"v3.12","\r\n## Changes\r\n\r\n- **Characters can now think in `chat-instruct` mode!** This was possible thanks to many simplifications and improvements to jinja2 template handling:\r\n\r\n\u003Cimg width=\"600\" src=\"https:\u002F\u002Fgithub.com\u002Fuser-attachments\u002Fassets\u002F2a7c45bd-b17b-4763-81be-5883cdd47df2\" \u002F>\r\n\r\n- Add support for the **Seed-OSS-36B-Instruct** template.\r\n- Better handle the growth of the chat input textarea:\r\n\r\n| Before | After |\r\n|------|----------|\r\n| \u003Cimg width=\"888\" height=\"674\" alt=\"before\" src=\"https:\u002F\u002Fgithub.com\u002Fuser-attachments\u002Fassets\u002F6ddde225-6bc3-448c-b221-3a2648441129\" \u002F>  | \u003Cimg width=\"888\" height=\"674\" alt=\"after\" src=\"https:\u002F\u002Fgithub.com\u002Fuser-attachments\u002Fassets\u002F682d975e-7dbd-42e7-af2b-2f255ec94d3d\" \u002F> |\r\n\r\n- Make the `--model` flag work with absolute paths for gguf models, like `--model \u002Ftmp\u002Fgemma-3-270m-it-IQ4_NL.gguf`\r\n- Make venv portable installs work with Python 3.13\r\n- Optimize LaTeX rendering during streaming for long replies\r\n- Give streaming instruct messages more vertical space\r\n- Preload the instruct and chat fonts for smoother startup\r\n- Improve right sidebar borders in light mode\r\n- Remove the `--flash-attn` flag (it's always on now in llama.cpp)\r\n- Suppress \"Attempted to select a non-interactive or hidden tab\" console warnings, reducing the UI CPU usage during streaming\r\n- Statically link MSVC runtime to remove the Visual C++ Redistributable dependency on Windows for the llama.cpp binaries\r\n- Make the llama.cpp terminal output with `--verbose` less verbose\r\n\r\n## Bug fixes\r\n\r\n- llama.cpp: Fix stderr deadlock while loading some models\r\n- llama.cpp: Fix obtaining the maximum sequence length for GPT-OSS\r\n- Fix the UI failing to launch if the Notebook prompt is too long\r\n- Fix LaTeX rendering for equations with asterisks\r\n- Fix italic and quote colors in headings\r\n\r\n## Backend updates\r\n\r\n- Update llama.cpp to https:\u002F\u002Fgithub.com\u002Fggml-org\u002Fllama.cpp\u002Ftree\u002F9961d244f2df6baf40af2f1ddc0927f8d91578c8\r\n\r\n-----\r\n\r\n## Portable builds\r\n\r\nBelow you can find self-contained packages that work with GGUF models (llama.cpp) and **require no installation**! Just download the right version for your system, unzip, and run.\r\n\r\n#### Which version to download:\r\n\r\n- Windows\u002FLinux:\r\n  - NVIDIA GPU: Use `cuda12.4` for newer GPUs or `cuda11.7` for older GPUs and systems with older drivers.\r\n  - AMD\u002FIntel GPU: Use `vulkan` builds.\r\n  - CPU only: Use `cpu` builds.\r\n\r\n- Mac:\r\n  - Apple Silicon: Use `macos-arm64`.\r\n  - Intel CPU: Use `macos-x86_64`.\r\n\r\n#### Updating a portable install:\r\n\r\n1. Download and unzip the latest version.\r\n2. Replace the `user_data` folder with the one in your existing install. All your settings and models will be moved.\r\n","2025-09-02T19:55:29",{"id":253,"version":254,"summary_zh":255,"released_at":256},62838,"v3.11","## Changes\r\n\r\n- Add the Tensor Parallelism option to the ExLlamav3\u002FExLlamav3_HF loaders through the `--enable-tp` and `--tp-backend` options.\r\n- Set multimodal status during Model Loading instead of checking every generation (#7199). Thanks, @altoiddealer.\r\n- Improve the [multimodal API examples](https:\u002F\u002Fgithub.com\u002Foobabooga\u002Ftext-generation-webui\u002Fwiki\u002F12-%E2%80%90-OpenAI-API#multimodalvision-llamacpp-and-exllamav3) slightly.\r\n\r\n## Bug fixes\r\n\r\n- Make web search functional again\r\n- mtmd: Fix a bug when \"include past attachments\" is unchecked\r\n- Fix code blocks having an extra empty line in the UI\r\n\r\n## Backend updates\r\n\r\n- Update llama.cpp to https:\u002F\u002Fgithub.com\u002Fggml-org\u002Fllama.cpp\u002Fcommit\u002F6d7f1117e3e3285d0c5c11b5ebb0439e27920082\r\n- Update ExLlamaV3 to 0.0.6\r\n- Update flash-attention to 2.8.3\r\n\r\n-----\r\n\r\n## Portable builds\r\n\r\nBelow you can find self-contained packages that work with GGUF models (llama.cpp) and **require no installation**! Just download the right version for your system, unzip, and run.\r\n\r\n#### Which version to download:\r\n\r\n- Windows\u002FLinux:\r\n  - NVIDIA GPU: Use `cuda12.4` for newer GPUs or `cuda11.7` for older GPUs and systems with older drivers.\r\n  - AMD\u002FIntel GPU: Use `vulkan` builds.\r\n  - CPU only: Use `cpu` builds.\r\n\r\n- Mac:\r\n  - Apple Silicon: Use `macos-arm64`.\r\n  - Intel CPU: Use `macos-x86_64`.\r\n\r\n#### Updating a portable install:\r\n\r\n1. Download and unzip the latest version.\r\n2. Replace the `user_data` folder with the one in your existing install. All your settings and models will be moved.\r\n","2025-08-19T14:52:49",{"id":258,"version":259,"summary_zh":260,"released_at":261},62839,"v3.10","See the [**Multimodal Tutorial**](https:\u002F\u002Fgithub.com\u002Foobabooga\u002Ftext-generation-webui\u002Fwiki\u002FMultimodal-Tutorial)\r\n\r\n\u003Cimg width=\"600\" alt=\"print6\" src=\"https:\u002F\u002Fgithub.com\u002Fuser-attachments\u002Fassets\u002F839818bc-04bd-417a-b6a0-a17c55b099af\" \u002F>\r\n\r\n## Changes\r\n\r\n- Add multimodal support to the UI and API\r\n  - With the llama.cpp loader (#7027). This was possible thanks to PR https:\u002F\u002Fgithub.com\u002Fggml-org\u002Fllama.cpp\u002Fpull\u002F15108 to llama.cpp. Thanks @65a.\r\n  - With ExLlamaV3 through a new ExLlamaV3 loader (#7174). Thanks @Katehuuh.\r\n- Add speculative decoding to the new ExLlamaV3 loader.\r\n- Use ExLlamav3 instead of ExLlamav3_HF by default for EXL3 models, since it supports multimodal and speculative decoding.\r\n- Support loading chat templates from `chat_template.json` files (EXL3\u002FEXL2\u002FTransformers models)\r\n- Default max_tokens to 512 in the API instead of 16\r\n- Better organize the right sidebar in the UI\r\n- llama.cpp: Pass `--swa-full` to llama-server when `streaming-llm` is checked to make it work for models with SWA.\r\n\r\n## Bug fixes\r\n\r\n- Fix getting the ctx-size for newer EXL3\u002FEXL2\u002FTransformers models\r\n- Fix the exllamav2 loader ignoring add_bos_token\r\n- Fix the color of italic text in chat messages\r\n- Fix edit window and buttons in Messenger theme (#7100). Thanks @mykeehu.\r\n\r\n## Backend updates\r\n\r\n- Bump llama.cpp to https:\u002F\u002Fgithub.com\u002Fggml-org\u002Fllama.cpp\u002Fcommit\u002Ff4586ee5986d6f965becb37876d6f3666478a961\r\n\r\n-----\r\n\r\n## Portable builds\r\n\r\nBelow you can find self-contained packages that work with GGUF models (llama.cpp) and **require no installation**! Just download the right version for your system, unzip, and run.\r\n\r\n#### Which version to download:\r\n\r\n- Windows\u002FLinux:\r\n  - NVIDIA GPU: Use `cuda12.4` for newer GPUs or `cuda11.7` for older GPUs and systems with older drivers.\r\n  - AMD\u002FIntel GPU: Use `vulkan` builds.\r\n  - CPU only: Use `cpu` builds.\r\n\r\n- Mac:\r\n  - Apple Silicon: Use `macos-arm64`.\r\n  - Intel CPU: Use `macos-x86_64`.\r\n\r\n#### Updating a portable install:\r\n\r\n1. Download and unzip the latest version.\r\n2. Replace the `user_data` folder with the one in your existing install. All your settings and models will be moved.\r\n","2025-08-12T21:18:29"]