ServeLLM
Expose a local LLM runtime (Ollama, vLLM, or llama.cpp) as a reliable, OpenAI-compatible HTTP/WebSocket API.
Install
pip install servellm
Quickstart
servellm init # writes servellm.yaml with a generated API key
servellm start # starts the server in the background
servellm models # list available models
Usage
OpenAI-compatible endpoint, so existing OpenAI clients work by changing base_url:
curl http://localhost:8000/v1/chat/completions \
-H "Authorization: Bearer <your-api-key>" \
-H "Content-Type: application/json" \
-d '{"model": "fast", "messages": [{"role": "user", "content": "hello"}]}'
Also available: GET /v1/models, GET /health, GET /metrics, WS /ws/chat, and the simpler
POST /chat endpoint.
Configuration
Edit servellm.yaml (created by servellm init) to point at your runtime, set API keys,
concurrency limits, and model aliases. No Python code required. See the project repository
for the full configuration reference.
CLI
servellm init create servellm.yaml in the current directory
servellm start start the server
servellm stop gracefully stop the server
servellm status check whether the server is running and healthy
servellm models list configured/discovered models
License
MIT
Metadata
Release files for servellm 1.0.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| servellm-1.0.0.tar.gz | 16.8 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| servellm-1.0.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 37.4 kB
Release files / servellm-1.0.0.tar.gz
| Download URL | servellm-1.0.0.tar.gz |
|---|---|
| Size | 16.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
6c1a11cbbd87bbfda21a9a889d69b74c7025e46633afaccd7a80d37ac51c8abc
|
|
BLAKE2b-256 checksum How to use checksums |
71ee77f7bbe2943980a0cafdb42ef8e53dbbc4cdb0a7debe7923251f99a6a214
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.4
|
Release files / servellm-1.0.0-py3-none-any.whl
| Download URL | servellm-1.0.0-py3-none-any.whl |
|---|---|
| Size | 20.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
411335917af0e89dd6a10a08b4996c893137375e646f843433b336612468290a
|
|
BLAKE2b-256 checksum How to use checksums |
f5e8d654d7a859c9e1c0353a0cfd8b4e548e662d6a97ef369250e2c84fa410d7
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.4
|