# WebLLM

框架 · https://godooo.ai/zh/framework/webllm

> WebLLM 是开源 AI 开发框架，2023 年推出，面向开发者。

借助 WebGPU 在浏览器里直接运行大模型的 JavaScript 引擎。

主打：大模型 API、本地运行模型。开源，可以免费使用。使用方式：网页版、本地离线运行。

## 速览

- **类别:** [框架](https://godooo.ai/zh/browse#framework)
- **推出于:** 2023
- **所属星系:** [模型与 API](https://godooo.ai/zh/galaxy/builders)
- **是否开源:** 是 · Apache-2.0
- **源代码:** [github.com/mlc-ai/web-llm](https://github.com/mlc-ai/web-llm)
- **GitHub 星标:** 19,183
- **使用方式:** 网页 · 可离线本地运行
- **适合谁:** 开发者
- **支持的协议:** [OpenAI-compatible API](https://godooo.ai/zh/protocol/openai-compatible-api)
- **官网:** [webllm.mlc.ai](https://webllm.mlc.ai)
- **别名:** Web LLM

## 能做什么

- **[大模型 API](https://godooo.ai/zh/capability/llm-api)** — 主打, _由机器提出，尚待校准_. “WebLLM is fully compatible with OpenAI API.” (摘自 [github.com](https://github.com/mlc-ai/web-llm)，2026-09-24)
- **[本地运行模型](https://godooo.ai/zh/capability/local-inference)** — 主打, _由机器提出，尚待校准_. “WebLLM is a high-performance in-browser LLM inference engine that brings language model inference directly onto web browsers with hardware acceleration.” (摘自 [github.com](https://github.com/mlc-ai/web-llm)，2026-09-24)
- **[对话问答](https://godooo.ai/zh/capability/chat)** — 支持, _由机器提出，尚待校准_. “Supports streaming chat completions, allowing real-time output generation which enhances interactive applications like chatbots and virtual assistants.” (摘自 [webllm.mlc.ai](https://webllm.mlc.ai/)，2026-09-24)

## 平替与同类

- **[Llama](https://godooo.ai/zh/model/llama)** (开源免费): 同样能做：大模型 API、对话问答、本地运行模型
- **[Qwen](https://godooo.ai/zh/model/qwen)** (开源免费): 同样能做：大模型 API、对话问答、本地运行模型；不用写代码
- **[GLM](https://godooo.ai/zh/model/glm)** (开源免费): 同样能做：大模型 API、对话问答、本地运行模型
- **[Jan](https://godooo.ai/zh/product/jan)** (开源免费): 同样能做：对话问答、本地运行模型、大模型 API；不用写代码
- **[LocalAI](https://godooo.ai/zh/framework/localai)** (开源免费): 同样能做：大模型 API、本地运行模型
- **[Mixtral](https://godooo.ai/zh/model/mixtral)** (开源免费): 同样能做：大模型 API、对话问答、本地运行模型
- **[Phi](https://godooo.ai/zh/model/phi)** (开源免费): 同样能做：对话问答、本地运行模型、大模型 API
- **[TextGen](https://godooo.ai/zh/product/textgen)** (开源免费): 同样能做：对话问答、本地运行模型、大模型 API；不用写代码
- **[gpt-oss](https://godooo.ai/zh/model/gpt-oss)** (开源免费): 同样能做：本地运行模型、大模型 API、对话问答
- **[Kimi K2](https://godooo.ai/zh/model/kimi-k2)** (开源免费): 同样能做：大模型 API、对话问答、本地运行模型
- **[LLM](https://godooo.ai/zh/cli/llm)** (开源免费): 同样能做：大模型 API、对话问答、本地运行模型
- **[LM Studio](https://godooo.ai/zh/product/lm-studio)** (免费): 同样能做：本地运行模型、大模型 API、对话问答；不用写代码

## 关系

- **基于…构建:** [MLC LLM](https://godooo.ai/zh/framework/mlc-llm)

## 常见问题

### WebLLM 是什么？

WebLLM 是开源 AI 开发框架，2023 年推出，面向开发者。借助 WebGPU 在浏览器里直接运行大模型的 JavaScript 引擎。

### WebLLM 免费吗？

免费。WebLLM 是开源软件（Apache-2.0）。

### WebLLM 开源吗？

开源，许可证是 Apache-2.0。源代码在 https://github.com/mlc-ai/web-llm。

### WebLLM 能本地运行吗？

能，可以在自己的电脑上离线运行。

### WebLLM 能做什么？

主打：大模型 API、本地运行模型。也能做：对话问答。

### WebLLM 有哪些开源替代品？

开源的有：Llama、Qwen、GLM、Jan、LocalAI、Mixtral、Phi、TextGen。其他：LM Studio。

## 来源

- [github.com](https://github.com/mlc-ai/web-llm) — 核实于 2026-09-24
- [webllm.mlc.ai](https://webllm.mlc.ai/) — 核实于 2026-09-24

---

最后更新 2026-09-24 · 来源核实于 2026-09-24 · 这是 https://godooo.ai/zh/framework/webllm 的 Markdown 版本。本站每个页面都有：在地址后面加 .md。
