Self-host llama-swap
v270Run and hot-swap multiple local AI models locally
docker run -it --rm --runtime nvidia -p 9292:8080 -v /path/to/models:/models -v /path/to/custom/config.yaml:/etc/llama-swap/config/config.yaml ghcr.io/mostlygeek/llama-swap:unified-cuda13- Stars
- 6 205
- Port
- 8080 (Main HTTP listening port)
ghcr.io/mostlygeek/llama-swapWhat is llama-swap?
A lightweight Go binary that manages multiple AI inference servers and switches between them based on incoming API requests. Users can run various backends like llama.cpp, vllm, stable-diffusion.cpp, audio.cpp, and ComfyUI simultaneously. The software provides a web interface for testing models, viewing token usage metrics, inspecting requests and responses, managing model loading/unloading, and monitoring logs in real-time. Configuration is done via a single YAML file that specifies commands for each model backend.
Should you self-host llama-swap?
llama-swap scores 73/100 on selfhost.directory (how scoring works) and ranks #2 of 7 in AI Workflows. It has 6 205 GitHub stars, +384 in the last 30 days.
It shipped 53 stable releases in the past year. The latest, v270, came out on 5 November 2026. New versions land roughly every 3 days.
Setup is moderate: expect some configuration beyond a single command. An official Docker image is available. It is MIT-licensed and written mostly in Go.
Its closest alternative on selfhost.directory is dify (90/100, 160 634 stars). It scores higher overall, so compare the two before you pick. See llama-swap vs dify side by side.
llama-swap README
Run multiple generative AI models on your machine and hot-swap between them on demand. llama-swap works with any OpenAI and Anthropic API compatible server and is used by thousands of people to power their local AI workflows.
Built in Go for performance and simplicity, llama-swap has zero dependencies and is incredibly easy to set up. Get started in minutes - just one binary and one configuration file.
Tip
Got questions about configuring llama-swap? Try out the Chat agent on llama-swap.ai. It runs entirely in your browser and is powered by LFM3-1.7B fine tuned on the docs.
Models for llama-swap
Open-weight models you can plug into llama-swap, most popular first.
More in AI Workflows
LoomFlowSelf-hosted AI workflow builder: write a prompt, get a runnable flow on a canvas, expose it as an API. Single Docker command to deploy.
Manor AISelf-hosted AI workspace for small teams to run governed agents with bring-your-own keys, workflows, tools, and human approvals.
markusSelf-hosted open-source AI workforce platform running autonomous agent teams locally with your own API keys.
self-hosted-ai-starter-kitThis open-source Docker Compose template spins up a self-hosted AI stack with n8n, Ollama, Qdrant and PostgreSQL, auto-pulling Llama3.2 for local workflows.
SimOpen-source, self-hosted AI workspace for teams designing, launching and observing agent workflows, with 1,000+ app connectors, tables, knowledge bases and run logs.
1flowbaseAn open-source AI Gateway and app runtime you host yourself, unifying model access with PostgreSQL storage, workflows, APIs, and React apps via MCP.
AgentaOpen-source, self-hosted workspace where teams build AI agents by chatting, run them in Slack, Telegram or WhatsApp, and schedule automations on any LLM.
bifrostOpen-source, high-performance AI gateway that works as your LLM gateway, MCP gateway and agent gateway. One OpenAI-compatible API for 10,000+ models, with failover, load balancing, semantic caching, virtual keys, budgets and MCP Code Mode. Works with any SDK or agent and adds under 200µs of overhead at 5k RPS.
bishengAn Apache-2.0, self-hosted LLM devops platform for enterprise AI: GenAI workflows, RAG knowledge bases, agents, model management, evaluation, SFT and OCR.
DEEIX ChatDEEIX Chat is a self-hosted, open-source AI workspace unifying model routing, multimodal chat, RAG, MCP tools, billing, and identity into one deployable platform.
deer-flowAn open-source long-horizon SuperAgent harness that researches, codes, and creates. With the help of sandboxes, memories, tools, skill, subagents and message gateway, it handles different levels of tasks that could take minutes to hours.
difyDify is a self-hosted, open-source LLM app platform with visual workflows, RAG pipelines, agents, and model management for taking AI apps from prototype to production.

0 comments