llms  by ServiceStack

Unified LLM client, server, and UI

Created 2 months ago
400 stars

Top 72.2% on SourcePulse

GitHubView on GitHub
1 Expert Loves This Project
Project Summary

<2-3 sentences summarising what the project addresses and solves, the target audience, and the benefit.> ServiceStack/llms offers a unified, lightweight, and privacy-focused client for diverse Large Language Models (LLMs). It simplifies managing multiple LLM APIs and local models via a single, offline-capable interface with an OpenAI-compatible API and UI. This empowers users to seamlessly switch providers, optimize costs, and maintain data privacy by abstracting individual LLM complexities.

How It Works

Built around a single Python file (llms.py) using aiohttp, it acts as a client, OpenAI-compatible server, and web UI. Requests are intelligently routed to configured providers (local Ollama, remote APIs like OpenAI, Anthropic, Groq, Google) based on model availability and user-defined priorities (cost, speed). Features like automatic retries and provider health checks ensure robust, cost-effective LLM access.

Quick Start & Requirements

Install via pip install llms-py or Docker. Requires API keys for providers (e.g., OPENAI_API_KEY, GROQ_API_KEY) set as environment variables or in llms.json. Ollama must run locally for local model integration. Docker Compose is recommended for streamlined deployment. Links to Docker Compose files and setup guides are available.

Highlighted Details

  • Unified Interface: Access over 160 LLMs via a ChatGPT-like UI and an OpenAI-compatible API endpoint.
  • Intelligent Model Routing: Automatically directs requests to the first available provider supporting the model, with configurable fallback logic for cost savings.
  • Multi-modal Support: Processes image (vision), audio, and file (PDF) inputs.
  • Offline & Private: Designed for offline operation, storing data locally in browser storage for privacy.
  • Provider Management: Easy enabling/disabling of providers/models via CLI/UI, with analytics for cost and token usage.

Maintenance & Community

Active development is indicated by recent changelog entries (e.g., Nov 2025). Contributions are welcomed via pull requests; specific community channels are not detailed.

Licensing & Compatibility

The project's specific open-source license is not explicitly stated in the provided README content, posing a potential adoption risk. Its OpenAI-compatible API and Docker support enhance integration with existing ecosystems and deployment workflows.

Limitations & Caveats

Users must manage API keys for external providers. The llms.json configuration can become extensive. Functionality depends on the availability and reliability of underlying third-party LLM services. The unspecified license is a significant caveat.

Health Check
Last Commit

3 days ago

Responsiveness

Inactive

Pull Requests (30d)
0
Issues (30d)
6
Star History
322 stars in the last 30 days

Explore Similar Projects

Feedback? Help us improve.