# LiteLLM

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

> LiteLLM 是开源 AI 开发框架，2023 年推出，面向开发者、企业。

用统一的 OpenAI 兼容格式调用上百种大模型 API 的代理服务和 Python SDK。

主打：多模型统一接入、大模型 API。开源，可以免费使用。使用方式：自部署、API、命令行。

## 速览

- **类别:** [框架](https://godooo.ai/zh/browse#framework)
- **推出于:** 2023
- **所属星系:** [模型与 API](https://godooo.ai/zh/galaxy/builders)
- **是否开源:** 是
- **源代码:** [github.com/BerriAI/litellm](https://github.com/BerriAI/litellm)
- **GitHub 星标:** 59,540
- **使用方式:** 可自部署 · API · 命令行
- **适合谁:** 开发者 · 企业
- **支持的协议:** [Model Context Protocol](https://godooo.ai/zh/protocol/mcp), [OpenAI-compatible API](https://godooo.ai/zh/protocol/openai-compatible-api)
- **官网:** [docs.litellm.ai](https://docs.litellm.ai/docs)
- **别名:** LiteLLM Proxy · LiteLLM AI Gateway

## 能做什么

- **[多模型统一接入](https://godooo.ai/zh/capability/model-gateway)** — 主打, _由机器提出，尚待校准_. “LiteLLM is an open source AI Gateway that gives you a single, unified interface to call 100+ LLM providers” (摘自 [github.com](https://github.com/BerriAI/litellm)，2026-09-24)
- **[大模型 API](https://godooo.ai/zh/capability/llm-api)** — 主打, _由机器提出，尚待校准_. “Call any LLM in OpenAI format.” (摘自 [github.com](https://github.com/BerriAI/litellm)，2026-09-24)

## 平替与同类

- **[OpenRouter](https://godooo.ai/zh/product/openrouter)** (免费版 + 付费升级): 同样能做：多模型统一接入、大模型 API
- **[AI SDK](https://godooo.ai/zh/framework/ai-sdk)** (开源免费): 同样能做：多模型统一接入、大模型 API
- **[One API](https://godooo.ai/zh/product/one-api)** (开源免费): 同样能做：多模型统一接入、大模型 API
- **[LLM](https://godooo.ai/zh/cli/llm)** (开源免费): 同样能做：大模型 API、多模型统一接入；可离线本地运行
- **[Together AI](https://godooo.ai/zh/product/together)** (付费): 同样能做：大模型 API、多模型统一接入
- **[Claude](https://godooo.ai/zh/model/claude)**: 同样能做：大模型 API；不用写代码
- **[Gemini](https://godooo.ai/zh/model/gemini)**: 同样能做：大模型 API；不用写代码
- **[GPT](https://godooo.ai/zh/model/gpt)**: 同样能做：大模型 API；不用写代码
- **[GPT-3](https://godooo.ai/zh/model/gpt-3)**: 同样能做：大模型 API
- **[GPT-4](https://godooo.ai/zh/model/gpt-4)**: 同样能做：大模型 API；不用写代码
- **[Hugging Face](https://godooo.ai/zh/product/huggingface)** (免费版 + 付费升级): 同样能做：多模型统一接入、大模型 API；可离线本地运行
- **[Llama](https://godooo.ai/zh/model/llama)** (开源免费): 同样能做：大模型 API；可离线本地运行

## 常见问题

### LiteLLM 是什么？

LiteLLM 是开源 AI 开发框架，2023 年推出，面向开发者、企业。用统一的 OpenAI 兼容格式调用上百种大模型 API 的代理服务和 Python SDK。

### LiteLLM 免费吗？

免费。LiteLLM 是开源软件。

### LiteLLM 开源吗？

开源。源代码在 https://github.com/BerriAI/litellm。

### LiteLLM 能本地运行吗？

可以部署在自己的服务器上。

### LiteLLM 能做什么？

主打：多模型统一接入、大模型 API。

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

开源的有：AI SDK、One API、LLM、Llama。其他：OpenRouter、Together AI、Claude、Gemini、GPT、GPT-3。

## 来源

- [github.com](https://github.com/BerriAI/litellm) — 核实于 2026-09-24
- [docs.litellm.ai](https://docs.litellm.ai/docs)

---

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