Litelm Released: A Lightweight Library Extracting Only LiteLLM's Routing and Translation Features
Key point
The open-source library Litelm has been released, stripping away unnecessary features from LiteLLM to achieve a lightweight footprint of 2,900 lines.
Details
The lightweight library Litelm has been released, extracting only the core model routing and message translation features from the massive codebase (100k+ LOC) of the existing LiteLLM. By removing auxiliary features such as proxy servers, caching, and cost tracking, it has been reduced to approximately 2,900 LOC, with only two dependencies: openai and httpx.
Key Features and Compatibility
- API Compatibility: Supports the same function names, arguments, and response types as LiteLLM, allowing migration by simply changing the
importstatement. - Supported Features: Supports model routing, message translation (Anthropic, Bedrock, etc.), streaming, Tool use, Embeddings, and the OpenAI Responses API.
- Excluded Features: Load balancing, Fallbacks, Proxy server, Caching, Token counting, Image gen/Audio/OCR, etc., are excluded.
- Providers: Supports a total of 19 providers, and OpenAI-compatible endpoints can be connected via
api_base.
Verification Status and Testing
Currently in the Alpha stage, compatibility has been secured by auditing LiteLLM's latest changes (commit 649eb2d ~ 9a715df2). All 262 local tests, 45 live provider tests, and 10 DSPy integration tests have passed. It is released under the MIT license, and the AI-assisted development process is transparently disclosed.
This summary was generated automatically by AI. Check the original for the author's claims and context. Copyright belongs to the original author.
Our guide explains how the AI works. Report summary errors, attribution issues, or removal requests via Contact.