list_modelsLABSCO SUMMARY
Two models on one machine, without restarting the conversation.
The trick is a clean split of duties: the service manager owns the weights, the client owns the history. That is what lets you plan with a reasoning model and then implement with a coding model in the same thread. Set health_timeout above its default of 30 seconds if your models are large — a swap that times out is almost always weights still loading.
What it is
A model switcher for a local llama-server. It starts and stops model services through launchctl on macOS or systemd on Linux, so the weights behind the endpoint change while the client keeps the full message history it re-sends every turn.
What you get
list_modelslists every configured model with its load status and the current modeget_current_modelreturns the alias of the model loaded right nowswap_modelunloads the current model, loads the one you name, and waits for the health check to passcreate_model_configwrites a new launchd plist or systemd unit for a model you describe in the chat- Two resources,
llama-swap://configandllama-swap://status, plus aswap-workflowprompt for the plan-then-implement pattern
Requirements
The PyPI package mcp-llama-swap, version 1.0.0, run as uvx mcp-llama-swap. Python 3.10+, llama-server on the machine, and launchctl or systemd. Point LLAMA_SWAP_CONFIG at an absolute path to your config.json, which maps aliases to service filenames. Claude Code has to be pointed at a LiteLLM proxy for the swap to be invisible to it.
Setup effort
One command — uvx mcp-llama-swap
USE CASES
Planning with one model and building with another
Load the reasoning model, agree the architecture, then swap to the coding model and implement it with the plan still in context.
Checking what is actually loaded
Ask which model is answering before you trust a result — the alias comes back directly.
Adding a new model without editing plists by hand
Describe the GGUF path and context size in the chat and the service file is written into your services directory.
4 tools
Listed in project docs. Your client may show a different list.
get_current_modelswap_modelcreate_model_configBEFORE YOU INSTALL
What to know first
Tools you get
4 tools named in the project's documentation.
Requires
- uvx on PATH
- Python 3.10+
Where it runs
The documented client runs the server on your machine.
INSTALLATION
Connect your client
Server setup
uvx mcp-llama-swapMCP Clients
Claude Code
{
"mcpServers": {
"llama-swap": {
"command": "uvx",
"args": [
"mcp-llama-swap"
],
"env": {
"LLAMA_SWAP_CONFIG": "<YOUR_LLAMA_SWAP_CONFIG>"
}
}
}
}