Documentation
Docs
Everything you need to run AI on your own computer with Loculus Core: install it, choose a model, ask your first question, make pictures and videos, and connect the apps and coding agents you already use. No experience needed: every step has a command to copy.
Quickstart
From nothing to your first answer in five steps. You’ll type a few commands, but each one is here to copy, with what you should see after it. Most of the time goes on downloading the AI model; the rest takes a few minutes.
#Before you start
A computer
Linux on a 64-bit PC (the first release). Windows comes next.
Graphics
An AMD, NVIDIA or Intel graphics card or chip from the last few years. Which ones?
Memory
8 GB of graphics memory runs small models well; more runs bigger ones. What fits?
Disk space
From 6 GB to over 80 GB for a model, depending on its size.
Time
About ten minutes, plus the model download.
You’ll use a terminalA window where you type commands. On Linux it’s called Terminal; on Windows, PowerShell. : a window where you type commands. Every command on this page has a copy button: click it, paste into the terminal (Ctrl + Shift + Vright-click, or Ctrl + V) and press Enter.
#Install Loculus Core
-
Download Loculus Core for your system from your account on loculuscore.com. It’s one file:
loculus-core-linux-x86_64.tar.gzloculus-core-windows-x86_64.zip -
Unpack it into your home folder, and go into the folder it makes:
TerminalLinux PowerShellWindowstar -xzf ~/Downloads/loculus-core-linux-x86_64.tar.gz -C ~ cd ~/loculus-coreExpand-Archive $HOME\Downloads\loculus-core-windows-x86_64.zip -DestinationPath $HOME cd $HOME\loculus-coreOr right-click the file in your Downloads folder, choose Extract Here, and move the
loculus-corefolder to your home folder. To open a terminal there later: open the folder, right-click an empty space, and choose Open in Terminal.Or right-click the file in Downloads, choose Extract All, and extract to your user folder. To open PowerShell there later: open the folder, click the address bar, type
powershelland press Enter. -
Have an up-to-date graphics driver.
AMD and Intel: Mesa 23 or newer, which Ubuntu 24.04 and other current systems already have. NVIDIA: driver 535 or newer (on Ubuntu: Software & Updates → Additional Drivers). The check-up in the next step tells you if anything is missing.
-
For video only: install ffmpeg, the free tool Loculus Core uses to write MP4 files.
TerminalLinux PowerShellWindowssudo apt install ffmpeg # Ubuntu, Debian sudo dnf install ffmpeg # Fedora (with RPM Fusion enabled) sudo pacman -S ffmpeg # Archwinget install Gyan.FFmpeg # then open a new PowerShell window
#Check your computer
Ask Loculus Core to look over your machine. In the Loculus Core folder:
./loculus doctor .\loculus.exe doctor It takes about a minute. Look for two things: your graphics card’s line ending runs Loculus Core, and 36 of 36 checks passed. Here is a healthy report from our mini PC:
Loculus Core 568af8e, doctor: this machine, its GPUs and a short check (nothing of your prompts or files)
This machine
Ubuntu 24.04.4 LTS, kernel 7.0.0-42-generic
AMD RYZEN AI MAX+ 395 w/ Radeon 8060S (32 threads; avx2, avx512bw, avx512vnni, f16c), CPU kernels: avx512-vnni
memory 92.9 GiB, 85.1 GiB available
Vulkan devices
0: AMD Radeon Graphics (RADV GFX1151) (integrated GPU, 1002:1586), radv, Mesa 25.2.8-0ubuntu0.24.04.2, Vulkan 1.4.318, 62.6 GiB: runs Loculus Core
2: llvmpipe (LLVM 20.1.2, 256 bits) (software (CPU), 10005:0000), llvmpipe, Mesa 25.2.8-0ubuntu0.24.04.2 (LLVM 20.1.2), Vulkan 1.4.318, 92.9 GiB: a software renderer on the CPU, not a GPU. Or run on the CPU: leave out --gpu.
The GPU Loculus Core uses: AMD Radeon Graphics (RADV GFX1151) (1002:1586 driver 0x6402008 api 0x40413e)
matrix units: yes; packed dot products: yes; 32-64 lanes a subgroup; 64 KiB of shared memory a workgroup
Selftest (its kernels against references on the CPU), in a process of its own
... 36 checks, one line each
36 of 36 checks passed in 66.8 s
Speed
matrix units: 53.8 TFLOP/s f16, 54.3 TOP/s int8 (from registers: the ceiling)
reading its memory: 235 GB/s (decode speed follows this) Something else? The report says what, and Troubleshooting says what to do.
#Download a model
A modelThe AI itself: one large file (sometimes a few) of learned numbers that reads text and writes a reply. You download it once and it runs on your computer. is the AI itself: a large file you download once. Open models are shared on Hugging Face as GGUFThe file format most open models are shared in. Loculus Core reads everything it needs to run a model from the file. files, in several sizes (quantizationsA smaller, slightly simplified copy of a model. Versions marked Q4 or Q5 keep nearly all the quality at about a third of the full size. ). Pick one for your computer, and the commands below download it, with its vision file for pictures:
mkdir -p ~/models/qwen3.8-27b && cd ~/models/qwen3.8-27b
curl -LO https://huggingface.co/unsloth/Qwen3.8-27B-GGUF/resolve/main/Qwen3.8-27B-UD-Q4_K_M.gguf
curl -LO https://huggingface.co/unsloth/Qwen3.8-27B-GGUF/resolve/main/mmproj-F16.gguf
cd ~/loculus-core New-Item -ItemType Directory -Force $HOME\models\qwen3.8-27b | Out-Null; cd $HOME\models\qwen3.8-27b
curl.exe -LO https://huggingface.co/unsloth/Qwen3.8-27B-GGUF/resolve/main/Qwen3.8-27B-UD-Q4_K_M.gguf
curl.exe -LO https://huggingface.co/unsloth/Qwen3.8-27B-GGUF/resolve/main/mmproj-F16.gguf
cd $HOME\loculus-core mkdir -p ~/models/gemma-4-e4b && cd ~/models/gemma-4-e4b
curl -LO https://huggingface.co/unsloth/gemma-4-E4B-it-GGUF/resolve/main/gemma-4-E4B-it-Q4_K_M.gguf
curl -LO https://huggingface.co/unsloth/gemma-4-E4B-it-GGUF/resolve/main/mmproj-F16.gguf
curl -LO https://huggingface.co/unsloth/gemma-4-E4B-it-GGUF/resolve/main/mtp-gemma-4-E4B-it.gguf
cd ~/loculus-core New-Item -ItemType Directory -Force $HOME\models\gemma-4-e4b | Out-Null; cd $HOME\models\gemma-4-e4b
curl.exe -LO https://huggingface.co/unsloth/gemma-4-E4B-it-GGUF/resolve/main/gemma-4-E4B-it-Q4_K_M.gguf
curl.exe -LO https://huggingface.co/unsloth/gemma-4-E4B-it-GGUF/resolve/main/mmproj-F16.gguf
curl.exe -LO https://huggingface.co/unsloth/gemma-4-E4B-it-GGUF/resolve/main/mtp-gemma-4-E4B-it.gguf
cd $HOME\loculus-core mkdir -p ~/models/qwen3.8-flash-next && cd ~/models/qwen3.8-flash-next
R=https://huggingface.co/unsloth/Qwen3.8-Flash-Next-GGUF/resolve/main
for f in UD-Q2_K_XL/Qwen3.8-Flash-Next-UD-Q2_K_XL-0000{1,2,3,4}-of-00004.gguf mmproj-F16.gguf MTP/mtp-Qwen3.8-Flash-Next-shared-Q4_K_M.gguf; do
curl -L --create-dirs -o "$f" "$R/$f"
done
cd ~/loculus-core New-Item -ItemType Directory -Force $HOME\models\qwen3.8-flash-next | Out-Null; cd $HOME\models\qwen3.8-flash-next
$R = 'https://huggingface.co/unsloth/Qwen3.8-Flash-Next-GGUF/resolve/main'
$files = (1..4 | ForEach-Object { "UD-Q2_K_XL/Qwen3.8-Flash-Next-UD-Q2_K_XL-0000$_-of-00004.gguf" }) + 'mmproj-F16.gguf', 'MTP/mtp-Qwen3.8-Flash-Next-shared-Q4_K_M.gguf'
foreach ($f in $files) { curl.exe -L --create-dirs -o $f "$R/$f" }
cd $HOME\loculus-core Downloads run in the terminal and show their progress; a big one can take a while. You can also download the files in your browser and put them in the same folders. More models, and what fits your machine: What fits your memory.
#Start Loculus Core
Start Loculus Core with your model, on your graphics card (--gpu), with the name loculus that every example on this page uses:
./loculus serve ~/models/qwen3.8-27b/Qwen3.8-27B-UD-Q4_K_M.gguf --gpu --alias loculus .\loculus.exe serve $HOME\models\qwen3.8-27b\Qwen3.8-27B-UD-Q4_K_M.gguf --gpu --alias loculus ./loculus serve ~/models/gemma-4-e4b/gemma-4-E4B-it-Q4_K_M.gguf --gpu --alias loculus .\loculus.exe serve $HOME\models\gemma-4-e4b\gemma-4-E4B-it-Q4_K_M.gguf --gpu --alias loculus ./loculus serve ~/models/qwen3.8-flash-next/UD-Q2_K_XL/Qwen3.8-Flash-Next-UD-Q2_K_XL-00001-of-00004.gguf --gpu --alias loculus .\loculus.exe serve $HOME\models\qwen3.8-flash-next\UD-Q2_K_XL\Qwen3.8-Flash-Next-UD-Q2_K_XL-00001-of-00004.gguf --gpu --alias loculus It reads the model, measures what it needs, and says when it’s ready. Here it is with Qwen3.8 27B on our mini PC:
serving loculus on http://127.0.0.1:8090: ready. That’s its address on your computer.ctx 262144: how much text the model can keep in view (its contextHow much the model keeps in view at once (your conversation, files and instructions), counted in tokens. ), in tokensA piece of a word. Speeds are counted in tokens a second; 100 tokens is about 75 English words. .on AMD Radeon Graphics: the graphics it runs on (yours will show your own).pictures: the vision tower in …: it found the vision file, so it can read pictures.- The very first time, it also says
first start: measuring this GPU for this model. That takes about half a minute, once.
#Ask your first question
Open a second terminal window and ask your first question:
This uses curl and jq; if your system says either is missing, install them first: sudo apt install curl jq (Fedora: sudo dnf install curl jq).
curl -s http://127.0.0.1:8090/v1/chat/completions \
-H "Content-Type: application/json" \
-d '{"model": "loculus", "messages": [{"role": "user", "content": "Explain what a GPU does, in one sentence."}]}' \
| jq -r '.choices[0].message.content' $body = @{ model = 'loculus'; messages = @(@{ role = 'user'; content = 'Explain what a GPU does, in one sentence.' }) } | ConvertTo-Json -Depth 5
(Invoke-RestMethod http://127.0.0.1:8090/v1/chat/completions -Method Post -ContentType 'application/json' -Body $body).choices[0].message.content The answer appears a moment later, written by the AI on your own computer. Nothing was sent anywhere.
What next
How-to examples
Recipes you can copy, from a one-line question to pictures, video and a server for your whole home network. Each command shows for the system you picked at the top of the page. All of them talk to Loculus Core running as in the Quickstart: on this computer, port 8090, with the model named loculus.
- Ask in one line
- Watch the answer arrive
- Chat in your terminal
- Summarise a file
- Reasoning models
- Answers as JSON
- Let the model use tools
- Ask about a picture
- Make a picture
- Make a video
- Server options
- Use it from another computer
- Keep it running
- Measure your speed
#Ask in one line
The quickest test there is: ask a question and get the answer back in your terminalA window where you type commands. On Linux it’s called Terminal; on Windows, PowerShell. .
These recipes use curl to send the question and jq to pick the answer out of the reply. Most systems have curl; install both if they’re missing:
sudo apt install curl jq # Ubuntu, Debian, Mint, Pop!_OS
sudo dnf install curl jq # Fedora curl -s http://127.0.0.1:8090/v1/chat/completions \
-H "Content-Type: application/json" \
-d '{"model": "loculus", "messages": [{"role": "user", "content": "Explain what a GPU does, in one sentence."}]}' \
| jq -r '.choices[0].message.content' $body = @{ model = 'loculus'; messages = @(@{ role = 'user'; content = 'Explain what a GPU does, in one sentence.' }) } | ConvertTo-Json -Depth 5
(Invoke-RestMethod http://127.0.0.1:8090/v1/chat/completions -Method Post -ContentType 'application/json' -Body $body).choices[0].message.content Make it a command of its own
Add a small ask command once, and from then on any question is one short line away:
Open your PowerShell profile (this creates it the first time):
if (!(Test-Path $PROFILE)) { New-Item -Path $PROFILE -ItemType File -Force }
notepad $PROFILE # Paste at the end of ~/.bashrc (nano ~/.bashrc), save, then open a new terminal.
ask() {
jq -n --arg q "$*" '{model: "loculus", messages: [{role: "user", content: $q}]}' |
curl -s http://127.0.0.1:8090/v1/chat/completions -H "Content-Type: application/json" -d @- |
jq -r '.choices[0].message.content'
} # Paste into your PowerShell profile (notepad $PROFILE), save, then open a new PowerShell window.
function ask {
$body = @{ model = 'loculus'; messages = @(@{ role = 'user'; content = "$args" }) } | ConvertTo-Json -Depth 5
$reply = Invoke-RestMethod http://127.0.0.1:8090/v1/chat/completions -Method Post -ContentType 'application/json; charset=utf-8' -Body ([Text.Encoding]::UTF8.GetBytes($body))
$reply.choices[0].message.content
} Then, any time Loculus Core is running:
ask "Write a haiku about the sea" ask "Write a haiku about the sea" #Watch the answer arrive
Long answers are nicer to watch as they’re written, word by word. Ask for a streamThe answer arrives word by word as it is written, instead of all at once at the end. and print each piece as it arrives:
curl -sN http://127.0.0.1:8090/v1/chat/completions \
-H "Content-Type: application/json" \
-d '{"model": "loculus", "stream": true, "messages": [{"role": "user", "content": "Tell me a short story about a lighthouse keeper."}]}' \
| sed -un 's/^data: //p' | grep --line-buffered -v '^\[DONE\]' \
| jq -j --unbuffered '.choices[0].delta.content // empty'; echo The same in Python, which works the same way on every system. It uses the official OpenAI library: Loculus Core speaks the same APIThe standard way programs talk to an AI model. Loculus Core speaks the same APIs as OpenAI and Anthropic, so apps made for them work with it. , so the library only needs its address.
Set up Python onceA private Python with the OpenAI and Anthropic libraries
sudo apt install python3-venv # Ubuntu and Debian (Fedora has it already)
python3 -m venv ~/loculus-py # a private Python for your scripts
source ~/loculus-py/bin/activate # run this in each new terminal before your scripts
pip install openai anthropic winget install Python.Python.3.12 # then open a new PowerShell window
py -m venv $HOME\loculus-py # a private Python for your scripts
& $HOME\loculus-py\Scripts\Activate.ps1 # run this in each new window before your scripts
pip install openai anthropic If PowerShell refuses to run Activate.ps1, allow your own scripts with Set-ExecutionPolicy -Scope CurrentUser RemoteSigned and try again.
from openai import OpenAI
client = OpenAI(base_url="http://127.0.0.1:8090/v1", api_key="local")
stream = client.chat.completions.create(
model="loculus",
messages=[{"role": "user", "content": "Tell me a short story about a lighthouse keeper."}],
stream=True,
)
for chunk in stream:
if chunk.choices and chunk.choices[0].delta.content:
print(chunk.choices[0].delta.content, end="", flush=True)
print() Save it as stream.py and run it:
python stream.py python stream.py #Chat in your terminal
A conversation that remembers what was said, in twenty lines of Python. Each turn sends the whole conversation back, and Loculus Core only works on what’s new: everything it has already read is kept, so follow-up questions start answering almost at once.
from openai import OpenAI
client = OpenAI(base_url="http://127.0.0.1:8090/v1", api_key="local")
messages = [{"role": "system", "content": "You are a friendly, helpful assistant."}]
print("Chat with your local AI. Press Ctrl+C to leave.")
while True:
try:
question = input("\nYou: ")
except (KeyboardInterrupt, EOFError):
break
messages.append({"role": "user", "content": question})
print("AI: ", end="", flush=True)
answer = ""
for chunk in client.chat.completions.create(model="loculus", messages=messages, stream=True):
if chunk.choices and chunk.choices[0].delta.content:
answer += chunk.choices[0].delta.content
print(chunk.choices[0].delta.content, end="", flush=True)
print()
messages.append({"role": "assistant", "content": answer}) Run it with python chat.py (with Python set up as above), type a question and press Enter. Press Ctrl + C to leave.
#Summarise a file
Send a whole document and ask for a summary. Swap report.txt for your own file, and the request for anything you like: translate it into Spanish, list the action points, check the spelling.
jq -Rs '{model: "loculus", messages: [{role: "user", content: ("Summarise this in five bullet points:\n\n" + .)}]}' report.txt \
| curl -s http://127.0.0.1:8090/v1/chat/completions -H "Content-Type: application/json" -d @- \
| jq -r '.choices[0].message.content' $text = Get-Content report.txt -Raw
$body = @{ model = 'loculus'; messages = @(@{ role = 'user'; content = "Summarise this in five bullet points:`n`n$text" }) } | ConvertTo-Json -Depth 5
(Invoke-RestMethod http://127.0.0.1:8090/v1/chat/completions -Method Post -ContentType 'application/json; charset=utf-8' -Body ([Text.Encoding]::UTF8.GetBytes($body))).choices[0].message.content #Reasoning models
Reasoning modelsA model that thinks step by step before it answers. You can turn the thinking up, down or off. such as Qwen3.8, DeepSeek V4.1, GLM-5.3 and gpt-oss think a problem through before they answer. You choose how hard they think with an effort: none (answer at once), low, medium, high, and on some models xhigh or max. Loculus Core reads which levels a model has from the model itself, and uses the nearest one to what you ask for.
Think hard, and see the thinking
curl -s http://127.0.0.1:8090/v1/chat/completions \
-H "Content-Type: application/json" \
-d '{"model": "loculus", "reasoning_effort": "high", "messages": [{"role": "user", "content": "A bat and a ball cost 1.10 in total. The bat costs 1.00 more than the ball. How much does the ball cost?"}]}' \
| jq -r '.choices[0].message | "THINKING:\n\(.reasoning_content // "(none)")\n\nANSWER:\n\(.content)"' $body = @{ model = 'loculus'; reasoning_effort = 'high'; messages = @(@{ role = 'user'; content = 'A bat and a ball cost 1.10 in total. The bat costs 1.00 more than the ball. How much does the ball cost?' }) } | ConvertTo-Json -Depth 5
$m = (Invoke-RestMethod http://127.0.0.1:8090/v1/chat/completions -Method Post -ContentType 'application/json' -Body $body).choices[0].message
"THINKING:`n$($m.reasoning_content)`n`nANSWER:`n$($m.content)" Answer at once
curl -s http://127.0.0.1:8090/v1/chat/completions \
-H "Content-Type: application/json" \
-d '{"model": "loculus", "reasoning_effort": "none", "messages": [{"role": "user", "content": "Give me three names for a black cat."}]}' \
| jq -r '.choices[0].message.content' $body = @{ model = 'loculus'; reasoning_effort = 'none'; messages = @(@{ role = 'user'; content = 'Give me three names for a black cat.' }) } | ConvertTo-Json -Depth 5
(Invoke-RestMethod http://127.0.0.1:8090/v1/chat/completions -Method Post -ContentType 'application/json' -Body $body).choices[0].message.content Which levels does my model have?
The start-up line reasoning: lists them, and so does the model list:
curl -s http://127.0.0.1:8090/v1/models | jq '.data[0].reasoning' (Invoke-RestMethod http://127.0.0.1:8090/v1/models).data[0].reasoning | ConvertTo-Json -Depth 5 From Python
With the OpenAI library the thinking comes back as reasoning_content beside the answer; with the Anthropic library, as thinking blocks before the text.
from openai import OpenAI
client = OpenAI(base_url="http://127.0.0.1:8090/v1", api_key="local")
reply = client.chat.completions.create(
model="loculus",
reasoning_effort="high", # or "low", "medium", ... "none" for no thinking
messages=[{"role": "user", "content": "Is 1,001 a prime number? Explain briefly."}],
)
message = reply.choices[0].message
print("THINKING:", getattr(message, "reasoning_content", None))
print("ANSWER:", message.content) import anthropic
client = anthropic.Anthropic(base_url="http://127.0.0.1:8090", api_key="local")
reply = client.messages.create(
model="loculus",
max_tokens=16000,
thinking={"type": "enabled", "budget_tokens": 8000}, # {"type": "disabled"} answers at once
messages=[{"role": "user", "content": "Plan a three-day trip to Rome for someone who loves history."}],
)
for block in reply.content:
if block.type == "thinking":
print("THINKING:\n" + block.thinking + "\n")
elif block.type == "text":
print("ANSWER:\n" + block.text) #Answers as JSON
For apps and automations: give a schema (the fields you want and their types) and the answer is guaranteed to match it. Loculus Core masks every word the schema doesn’t allow, so there is nothing to clean up afterwards.
curl -s http://127.0.0.1:8090/v1/chat/completions \
-H "Content-Type: application/json" \
-d '{
"model": "loculus",
"messages": [{"role": "user", "content": "Extract the contact: call Maria Lopez at Northwind Ltd on 020 7946 0018."}],
"response_format": {
"type": "json_schema",
"json_schema": {
"name": "contact",
"schema": {
"type": "object",
"properties": {
"name": {"type": "string"},
"company": {"type": "string"},
"phone": {"type": "string"}
},
"required": ["name", "company", "phone"]
}
}
}
}' | jq -r '.choices[0].message.content' import json
from openai import OpenAI
client = OpenAI(base_url="http://127.0.0.1:8090/v1", api_key="local")
schema = {
"type": "object",
"properties": {
"name": {"type": "string"},
"company": {"type": "string"},
"phone": {"type": "string"},
},
"required": ["name", "company", "phone"],
}
reply = client.chat.completions.create(
model="loculus",
messages=[{"role": "user", "content": "Extract the contact: call Maria Lopez at Northwind Ltd on 020 7946 0018."}],
response_format={"type": "json_schema", "json_schema": {"name": "contact", "schema": schema}},
)
contact = json.loads(reply.choices[0].message.content)
print(contact["name"], "|", contact["company"], "|", contact["phone"]) On Windows, use the Python version: it runs the same everywhere.
#Let the model use tools
Tools let the model ask your code to do something (look up the weather, search your files, switch on a light) and then use the result in its answer. You describe each tool; the model decides when to call it, and Loculus Core makes sure each call names one of your tools with every argument it needs.
curl -s http://127.0.0.1:8090/v1/chat/completions \
-H "Content-Type: application/json" \
-d '{
"model": "loculus",
"messages": [{"role": "user", "content": "Should I pack an umbrella for Lisbon tomorrow?"}],
"tools": [{
"type": "function",
"function": {
"name": "get_weather",
"description": "Get the weather forecast for a city",
"parameters": {
"type": "object",
"properties": {"city": {"type": "string"}},
"required": ["city"]
}
}
}]
}' | jq '.choices[0].message.tool_calls' import json
from openai import OpenAI
client = OpenAI(base_url="http://127.0.0.1:8090/v1", api_key="local")
def get_weather(city):
# Your own code goes here: a weather service, a database, your smart-home hub...
return {"city": city, "forecast": "light rain", "high_c": 17}
tools = [{
"type": "function",
"function": {
"name": "get_weather",
"description": "Get the weather forecast for a city",
"parameters": {
"type": "object",
"properties": {"city": {"type": "string"}},
"required": ["city"],
},
},
}]
messages = [{"role": "user", "content": "Should I pack an umbrella for Lisbon tomorrow?"}]
reply = client.chat.completions.create(model="loculus", messages=messages, tools=tools)
message = reply.choices[0].message
while message.tool_calls: # the model asked to use a tool
messages.append(message)
for call in message.tool_calls:
result = get_weather(**json.loads(call.function.arguments))
messages.append({"role": "tool", "tool_call_id": call.id, "content": json.dumps(result)})
reply = client.chat.completions.create(model="loculus", messages=messages, tools=tools)
message = reply.choices[0].message
print(message.content) The curl version shows the call the model asks for; the Python version runs it and hands the result back, until the model has its answer.
#Ask about a picture
Models that read pictures (Qwen3.8 27B and Flash-Next, Gemma 4, GLM-5.3 Flash and DeepSeek V4.1 Flash) take a photo with your question. They need their vision file, mmproj-F16.gguf from the same download page as the model, placed beside the model: Loculus Core finds it there and says so when it starts (pictures: the vision tower in …). The Quickstart’s downloads include it.
base64 -w0 photo.jpg | jq -Rs '{
model: "loculus",
messages: [{role: "user", content: [
{type: "text", text: "What is in this picture?"},
{type: "image_url", image_url: {url: ("data:image/jpeg;base64," + .)}}
]}]
}' | curl -s http://127.0.0.1:8090/v1/chat/completions -H "Content-Type: application/json" -d @- \
| jq -r '.choices[0].message.content' $img = [Convert]::ToBase64String([IO.File]::ReadAllBytes("$PWD\photo.jpg"))
$body = @{ model = 'loculus'; messages = @(@{ role = 'user'; content = @(
@{ type = 'text'; text = 'What is in this picture?' },
@{ type = 'image_url'; image_url = @{ url = "data:image/jpeg;base64,$img" } }
) }) } | ConvertTo-Json -Depth 8
(Invoke-RestMethod http://127.0.0.1:8090/v1/chat/completions -Method Post -ContentType 'application/json' -Body $body).choices[0].message.content import base64
from openai import OpenAI
client = OpenAI(base_url="http://127.0.0.1:8090/v1", api_key="local")
with open("photo.jpg", "rb") as f:
picture = base64.b64encode(f.read()).decode()
reply = client.chat.completions.create(
model="loculus",
messages=[{
"role": "user",
"content": [
{"type": "text", "text": "What is in this picture? Then suggest a caption."},
{"type": "image_url", "image_url": {"url": f"data:image/jpeg;base64,{picture}"}},
],
}],
)
print(reply.choices[0].message.content) Pictures go in as PNG or JPEG. Send the picture itself, as above: Loculus Core doesn’t fetch pictures from web addresses. Download only the F16 vision file: if several sit beside the model, Loculus Core takes the largest.
#Make a picture
Loculus Core makes pictures from a description with two picture models: Z-Image-Turbo (fast: 8 steps) and FLUX.3 [klein] (finer detail: 16 steps, up to native 4K on a 16 GB graphics card and 8K on a 96 GB machine). Both are diffusionHow picture and video models work: they start from random noise and refine it, step by step, into the picture you described. models: they start from noise and refine it, step by step, into your picture.
Get the model files
Each picture model comes in three parts: the model itself, a text encoder that reads your prompt, and a decoder that paints the pixels. Keep each model’s parts in a folder of its own.
Z-Image-TurboAbout 11 GB · Apache 2.0 licence
mkdir -p ~/models/z-image-turbo && cd ~/models/z-image-turbo
curl -LO https://huggingface.co/leejet/Z-Image-Turbo-GGUF/resolve/main/z_image_turbo-Q8_0.gguf
curl -LO https://huggingface.co/Qwen/Qwen3-4B-GGUF/resolve/main/Qwen3-4B-Q8_0.gguf
curl -LO https://huggingface.co/second-state/FLUX.1-schnell-GGUF/resolve/main/ae.safetensors
cd ~/loculus-core New-Item -ItemType Directory -Force $HOME\models\z-image-turbo | Out-Null; cd $HOME\models\z-image-turbo
curl.exe -LO https://huggingface.co/leejet/Z-Image-Turbo-GGUF/resolve/main/z_image_turbo-Q8_0.gguf
curl.exe -LO https://huggingface.co/Qwen/Qwen3-4B-GGUF/resolve/main/Qwen3-4B-Q8_0.gguf
curl.exe -LO https://huggingface.co/second-state/FLUX.1-schnell-GGUF/resolve/main/ae.safetensors
cd $HOME\loculus-core FLUX.3 [klein]About 16 GB · FLUX Kommunity Licence
Black Forest Labs asks you to accept its licence before downloading. Once, in your browser:
- Sign in at huggingface.co (an account is free), open FLUX.3 [klein]’s page and accept the licence.
- Make an access token: Settings → Access Tokens → Create new token, type Read. Copy it.
- Put your token in the first line below, and run it:
export HF_TOKEN=hf_your_token_here # your Hugging Face access token
mkdir -p ~/models/flux3-klein && cd ~/models/flux3-klein
curl -LO -H "Authorization: Bearer $HF_TOKEN" https://huggingface.co/black-forest-labs/flux-3-image-klein-comfy/resolve/main/diffusion_models/flux3-image-klein-bf16.safetensors
curl -LO -H "Authorization: Bearer $HF_TOKEN" https://huggingface.co/black-forest-labs/flux-3-image-klein-comfy/resolve/main/vae/flux2-vae.safetensors
curl -LO https://huggingface.co/Qwen/Qwen3-VL-4B-Instruct-GGUF/resolve/main/Qwen3VL-4B-Instruct-Q8_0.gguf
cd ~/loculus-core $env:HF_TOKEN = 'hf_your_token_here' # your Hugging Face access token
New-Item -ItemType Directory -Force $HOME\models\flux3-klein | Out-Null; cd $HOME\models\flux3-klein
curl.exe -LO -H "Authorization: Bearer $env:HF_TOKEN" https://huggingface.co/black-forest-labs/flux-3-image-klein-comfy/resolve/main/diffusion_models/flux3-image-klein-bf16.safetensors
curl.exe -LO -H "Authorization: Bearer $env:HF_TOKEN" https://huggingface.co/black-forest-labs/flux-3-image-klein-comfy/resolve/main/vae/flux2-vae.safetensors
curl.exe -LO https://huggingface.co/Qwen/Qwen3-VL-4B-Instruct-GGUF/resolve/main/Qwen3VL-4B-Instruct-Q8_0.gguf
cd $HOME\loculus-core FLUX.3 [klein]’s licence allows non-commercial use, and commercial use of its pictures for businesses under US$5 million a year in revenue; other uses need a licence from Black Forest Labs.
From the command line
# Z-Image-Turbo: fast, 8 steps
./loculus image ~/models/z-image-turbo/z_image_turbo-Q8_0.gguf \
--llm ~/models/z-image-turbo/Qwen3-4B-Q8_0.gguf --vae ~/models/z-image-turbo/ae.safetensors \
-p "A lighthouse on a cliff at sunset, oil painting" -W 1280 -H 720 --seed 7 -o lighthouse.png
# FLUX.3 [klein]: finer detail, 16 steps; here at 4K
./loculus image ~/models/flux3-klein/flux3-image-klein-bf16.safetensors \
--llm ~/models/flux3-klein/Qwen3VL-4B-Instruct-Q8_0.gguf --vae ~/models/flux3-klein/flux2-vae.safetensors \
-p "An orchid of glass and copper circuits, a neon city behind it, museum lighting" -W 3840 -H 2160 -o orchid.png # Z-Image-Turbo: fast, 8 steps
.\loculus.exe image $HOME\models\z-image-turbo\z_image_turbo-Q8_0.gguf `
--llm $HOME\models\z-image-turbo\Qwen3-4B-Q8_0.gguf --vae $HOME\models\z-image-turbo\ae.safetensors `
-p "A lighthouse on a cliff at sunset, oil painting" -W 1280 -H 720 --seed 7 -o lighthouse.png
# FLUX.3 [klein]: finer detail, 16 steps; here at 4K
.\loculus.exe image $HOME\models\flux3-klein\flux3-image-klein-bf16.safetensors `
--llm $HOME\models\flux3-klein\Qwen3VL-4B-Instruct-Q8_0.gguf --vae $HOME\models\flux3-klein\flux2-vae.safetensors `
-p "An orchid of glass and copper circuits, a neon city behind it, museum lighting" -W 3840 -H 2160 -o orchid.png
The --llm and --vae options name the text encoder and decoder, so Loculus Core uses exactly those files. Left out, it looks for them beside the model, and if other models’ files are near, it can pick the wrong one.
| Option | What it does |
|---|---|
-p "…" | What to paint. Describe the subject, the setting, the light and the style. |
-W 1280 -H 720 | Width and height in pixels, each a multiple of 16 (1920 × 1080 is -W 1920 -H 1088). Default 1024 × 1024. |
--seed 7 | The same seed, prompt and size give the same picture again; change it for a new variation. |
--steps 12 | More steps, more refinement (slower). Defaults: 8 for Z-Image-Turbo, 16 for FLUX.3 [klein]. |
-o picture.png | Where to save it (PNG). Default out.png. |
-r photo.jpg | FLUX.3 [klein]: a reference picture whose content the new picture keeps (a product, a face, an object), placed as your prompt describes. Give it more than once for several. |
If a size is too big for your graphics memory, Loculus Core says so before it starts, with the largest size of that shape that fits.
From your apps, through the API
Serve a picture model beside your chat model with --image, and apps can ask for pictures through the standard OpenAI Images API:
./loculus serve ~/models/qwen3.8-27b/Qwen3.8-27B-UD-Q4_K_M.gguf --gpu --alias loculus \
--image ~/models/z-image-turbo/z_image_turbo-Q8_0.gguf \
--image-encoder ~/models/z-image-turbo/Qwen3-4B-Q8_0.gguf \
--image-vae ~/models/z-image-turbo/ae.safetensors .\loculus.exe serve $HOME\models\qwen3.8-27b\Qwen3.8-27B-UD-Q4_K_M.gguf --gpu --alias loculus `
--image $HOME\models\z-image-turbo\z_image_turbo-Q8_0.gguf `
--image-encoder $HOME\models\z-image-turbo\Qwen3-4B-Q8_0.gguf `
--image-vae $HOME\models\z-image-turbo\ae.safetensors curl -s http://127.0.0.1:8090/v1/images/generations \
-H "Content-Type: application/json" \
-d '{"prompt": "A lighthouse on a cliff at sunset, oil painting", "size": "1280x720", "seed": 7}' \
| jq -r '.data[0].b64_json' | base64 -d > lighthouse.png $body = @{ prompt = 'A lighthouse on a cliff at sunset, oil painting'; size = '1280x720'; seed = 7 } | ConvertTo-Json
$r = Invoke-RestMethod http://127.0.0.1:8090/v1/images/generations -Method Post -ContentType 'application/json' -Body $body
[IO.File]::WriteAllBytes("$PWD\lighthouse.png", [Convert]::FromBase64String($r.data[0].b64_json)) import base64
from openai import OpenAI
client = OpenAI(base_url="http://127.0.0.1:8090/v1", api_key="local")
result = client.images.generate(
prompt="A lighthouse on a cliff at sunset, oil painting",
size="1280x720",
n=2, # up to 4 at a time
extra_body={"seed": 7, "steps": 8}, # the same seed gives the same picture again
)
for i, picture in enumerate(result.data):
with open(f"lighthouse-{i + 1}.png", "wb") as f:
f.write(base64.b64decode(picture.b64_json)) Sizes go from 256 to 7680 pixels a side (multiples of 16), or by name: 720p, 1080p, 4k. The picture model loads for the first picture and lets its memory go after two minutes without one; while a picture is being made, your chat model keeps answering.
#Make a video
Video comes from LTX-2.5 by Lightricks, which makes the picture and its sound together, in one pass: rain you can hear on the glass, footsteps in time with the walk, a voice with moving lips. Describe a scene, or give it a picture to bring to life. Ask for a size and a length in seconds, and Loculus Core plans the rest.
Get the model files
LTX-2.5About 52 GB · video with sound, from text or a picture
mkdir -p ~/models/ltx-2.5 && cd ~/models/ltx-2.5
R=https://huggingface.co/unsloth/LTX-2.5-GGUF/resolve/main
for f in distilled/ltx-2.5-22b-distilled-Q8_0.gguf \
text_encoders/gemma4-12b-with-proj-ltx-2.5-bf16.safetensors \
vae/ltx-2.5-video-vae-conv-bf16.safetensors \
vae/ltx-2.5-audio-vae-bf16.safetensors \
latent_upscale_models/ltx-2.5-latent-spatial-upscaler-x2-bf16-1.0.safetensors; do
curl -L --create-dirs -o "$f" "$R/$f"
done
cd ~/loculus-core New-Item -ItemType Directory -Force $HOME\models\ltx-2.5 | Out-Null; cd $HOME\models\ltx-2.5
$R = 'https://huggingface.co/unsloth/LTX-2.5-GGUF/resolve/main'
$files = 'distilled/ltx-2.5-22b-distilled-Q8_0.gguf',
'text_encoders/gemma4-12b-with-proj-ltx-2.5-bf16.safetensors',
'vae/ltx-2.5-video-vae-conv-bf16.safetensors',
'vae/ltx-2.5-audio-vae-bf16.safetensors',
'latent_upscale_models/ltx-2.5-latent-spatial-upscaler-x2-bf16-1.0.safetensors'
foreach ($f in $files) { curl.exe -L --create-dirs -o $f "$R/$f" }
cd $HOME\loculus-core The model, its text encoder, its video and sound decoders, and its upscaler, in the folders they come in. Leave them there: Loculus Core finds each part from the model’s folder. The first time, it also prepares its text encoder from the download, which takes a few minutes, once, and adds 13 GB beside it, so allow about 65 GB in all.
It runs best with a 16 GB graphics card and 64 GB of system memory, or 64 GB or more of unified memory, on a GPU whose check-up says matrix units: yes.
LTX-2.5 is released by Lightricks under its LTX-2.x Community License: free for individuals and for companies under US$10 million a year in revenue; larger companies need a commercial licence from Lightricks. Its terms ask that what you make is disclosed as made by AI.
From the command line
# From a description: the video and its sound
./loculus video ~/models/ltx-2.5/distilled/ltx-2.5-22b-distilled-Q8_0.gguf \
-p "Rain streams down a window at night as thunder rolls in the distance; inside, a candle flickers and a clock ticks softly" \
--size 720p --seconds 5 -o rain.mp4
# From a picture: it becomes the first frame
./loculus video ~/models/ltx-2.5/distilled/ltx-2.5-22b-distilled-Q8_0.gguf -i lighthouse.png \
-p "Waves crash against the rocks and the wind howls as the lighthouse beam sweeps the sea" \
--size 720p --seconds 5 -o lighthouse.mp4 # From a description: the video and its sound
.\loculus.exe video $HOME\models\ltx-2.5\distilled\ltx-2.5-22b-distilled-Q8_0.gguf `
-p "Rain streams down a window at night as thunder rolls in the distance; inside, a candle flickers and a clock ticks softly" `
--size 720p --seconds 5 -o rain.mp4
# From a picture: it becomes the first frame
.\loculus.exe video $HOME\models\ltx-2.5\distilled\ltx-2.5-22b-distilled-Q8_0.gguf -i lighthouse.png `
-p "Waves crash against the rocks and the wind howls as the lighthouse beam sweeps the sea" `
--size 720p --seconds 5 -o lighthouse.mp4 Sizes: 480p, 720p, 1080p, 1440p, 4k or exact pixels such as 1280x704; with a picture, a named size follows the picture’s shape. Videos are saved as MP4, sound included, through ffmpeg. If a size won’t fit your graphics memory, Loculus Core steps down a size and says why.
From your apps, through the API
Serve a video model with --video. A video takes minutes, so the API answers at once with a job: ask how far it’s got, then download the MP4.
./loculus serve ~/models/qwen3.8-27b/Qwen3.8-27B-UD-Q4_K_M.gguf --gpu --alias loculus \
--video ~/models/ltx-2.5/distilled/ltx-2.5-22b-distilled-Q8_0.gguf .\loculus.exe serve $HOME\models\qwen3.8-27b\Qwen3.8-27B-UD-Q4_K_M.gguf --gpu --alias loculus `
--video $HOME\models\ltx-2.5\distilled\ltx-2.5-22b-distilled-Q8_0.gguf # 1. Ask for the video. The answer comes at once: a job, with its id.
ID=$(curl -s http://127.0.0.1:8090/v1/videos \
-H "Content-Type: application/json" \
-d '{"prompt": "A paper boat drifting down a rain-soaked street at dusk, raindrops pattering, distant traffic", "size": "720p", "seconds": 5}' \
| jq -r .id)
# 2. Wait while it's made: status and progress every 10 seconds.
while :; do
STATUS=$(curl -s http://127.0.0.1:8090/v1/videos/$ID | jq -r '.status + " " + (.progress | tostring) + "%"')
echo "$STATUS"
case "$STATUS" in completed*|failed*) break ;; esac
sleep 10
done
# 3. Download the MP4.
curl -s -o boat.mp4 http://127.0.0.1:8090/v1/videos/$ID/content # 1. Ask for the video. The answer comes at once: a job, with its id.
$body = @{ prompt = 'A paper boat drifting down a rain-soaked street at dusk, raindrops pattering, distant traffic'; size = '720p'; seconds = 5 } | ConvertTo-Json
$job = Invoke-RestMethod http://127.0.0.1:8090/v1/videos -Method Post -ContentType 'application/json' -Body $body
# 2. Wait while it's made: status and progress every 10 seconds.
do {
Start-Sleep -Seconds 10
$job = Invoke-RestMethod "http://127.0.0.1:8090/v1/videos/$($job.id)"
"$($job.status) $($job.progress)%"
} while ($job.status -notin 'completed', 'failed')
# 3. Download the MP4.
Invoke-WebRequest "http://127.0.0.1:8090/v1/videos/$($job.id)/content" -OutFile boat.mp4 To start from a picture, send it along as input_reference:
curl -s http://127.0.0.1:8090/v1/videos \
-F prompt="The boat sails slowly into the mist" \
-F input_reference=@boat.png \
-F size=720p \
-F seconds=5 | jq . $img = [Convert]::ToBase64String([IO.File]::ReadAllBytes("$PWD\boat.png"))
$body = @{ prompt = 'The boat sails slowly into the mist'; size = '720p'; seconds = 5; input_reference = "data:image/png;base64,$img" } | ConvertTo-Json
Invoke-RestMethod http://127.0.0.1:8090/v1/videos -Method Post -ContentType 'application/json' -Body $body import json
import time
import urllib.request
SERVER = "http://127.0.0.1:8090/v1"
def call(path, body=None):
data = json.dumps(body).encode() if body is not None else None
req = urllib.request.Request(SERVER + path, data=data, headers={"Content-Type": "application/json"})
with urllib.request.urlopen(req) as r:
return r.read() if path.endswith("/content") else json.load(r)
job = call("/videos", {"prompt": "A hot-air balloon rising over misty hills at sunrise", "size": "720p", "seconds": 5})
while job["status"] not in ("completed", "failed"):
time.sleep(10)
job = call(f"/videos/{job['id']}")
print(job["status"], job.get("progress", 0), "%")
if job["status"] == "completed":
with open("balloon.mp4", "wb") as f:
f.write(call(f"/videos/{job['id']}/content"))
print("Saved balloon.mp4")
else:
print("It failed:", job.get("error")) Lengths go up to 600 seconds. The server keeps the last 16 finished videos for download.
A smaller graphics card? Wan 2.2About 13 GB · Apache 2.0 licence · video without sound, on 8 GB graphics cards
Wan 2.2 TI2V-5B, from Alibaba’s Wan team, makes video from a description or a picture, without sound, and fits graphics cards with 8 GB. Get its three parts (the model, its caption encoder and its video decoder, kept together in one folder):
mkdir -p ~/models/wan2.2 && cd ~/models/wan2.2
curl -LO https://huggingface.co/QuantStack/Wan2.2-TI2V-5B-GGUF/resolve/main/Wan2.2-TI2V-5B-Q8_0.gguf
curl -LO https://huggingface.co/city96/umt5-xxl-encoder-gguf/resolve/main/umt5-xxl-encoder-Q8_0.gguf
curl -LO https://huggingface.co/Comfy-Org/Wan-2.2/resolve/main/split_files/vae/wan2.2_vae.safetensors
cd ~/loculus-core New-Item -ItemType Directory -Force $HOME\models\wan2.2 | Out-Null; cd $HOME\models\wan2.2
curl.exe -LO https://huggingface.co/QuantStack/Wan2.2-TI2V-5B-GGUF/resolve/main/Wan2.2-TI2V-5B-Q8_0.gguf
curl.exe -LO https://huggingface.co/city96/umt5-xxl-encoder-gguf/resolve/main/umt5-xxl-encoder-Q8_0.gguf
curl.exe -LO https://huggingface.co/Comfy-Org/Wan-2.2/resolve/main/split_files/vae/wan2.2_vae.safetensors
cd $HOME\loculus-core # From a description
./loculus video ~/models/wan2.2/Wan2.2-TI2V-5B-Q8_0.gguf \
-p "A paper boat drifting down a rain-soaked street at dusk, cinematic" --size 720p --seconds 5 -o boat.mp4
# From a picture: it becomes the first frame
./loculus video ~/models/wan2.2/Wan2.2-TI2V-5B-Q8_0.gguf -i lighthouse.png \
-p "Waves crash against the rocks as the lighthouse beam sweeps the sea" --size 720p --seconds 5 -o lighthouse.mp4 # From a description
.\loculus.exe video $HOME\models\wan2.2\Wan2.2-TI2V-5B-Q8_0.gguf `
-p "A paper boat drifting down a rain-soaked street at dusk, cinematic" --size 720p --seconds 5 -o boat.mp4
# From a picture: it becomes the first frame
.\loculus.exe video $HOME\models\wan2.2\Wan2.2-TI2V-5B-Q8_0.gguf -i lighthouse.png `
-p "Waves crash against the rocks as the lighthouse beam sweeps the sea" --size 720p --seconds 5 -o lighthouse.mp4 Serve it for apps the same way: --video ~/models/wan2.2/Wan2.2-TI2V-5B-Q8_0.gguf.
#Server options
Everything about how fast Loculus Core runs is measured and tuned by itself; there’s nothing to adjust. These options are about how you want to use it:
| Option | What it does | Without it |
|---|---|---|
--gpu | Runs the model on your graphics card or chip. | Runs on the processor (slower; some models need the GPU) |
--port 9000 | Listens on another portThe number that, with your computer’s address, says where Loculus Core listens for requests: 8090 unless you choose another. , for example when 8090 is taken. | 8090 |
--host 0.0.0.0 | Lets other computers on your network use it (see below). | This computer only (127.0.0.1) |
--alias loculus | The model name apps see. | The model’s own name |
--ctx 65536 | How much text the model keeps in view, in tokens. | The largest that fits, up to the model’s own maximum |
--parallel 8 | Answers up to this many requests side by side (up to 16), for several agents or people at once. | 4, where the model allows |
--idle-unload 600 | Gives the graphics memory back after 600 seconds without a request, for games or other apps; the next request loads the model again. | Stays loaded |
--image FILE | Also serves a picture model. | No pictures out |
--video FILE | Also serves a video model. | No video |
--no-mmproj | Leaves out the vision file, if you don’t send pictures. | Found beside the model |
--no-spec | Turns off drafting (it writes ahead and checks itself; on by default because it’s faster). | On |
For example, a server for a team of coding agents on another port, with room for long files:
./loculus serve ~/models/qwen3.8-27b/Qwen3.8-27B-UD-Q4_K_M.gguf --gpu --alias loculus \
--port 9000 --ctx 65536 --parallel 8 .\loculus.exe serve $HOME\models\qwen3.8-27b\Qwen3.8-27B-UD-Q4_K_M.gguf --gpu --alias loculus `
--port 9000 --ctx 65536 --parallel 8 #Use it from another computer
Run Loculus Core on your most powerful computer and use it from your laptop, another PC or a tablet on the same network. By default it only answers the computer it runs on (localhostYour own computer’s address for itself (127.0.0.1). Only programs on the same computer can reach it. ); --host 0.0.0.0 opens it to your network.
Start it on the powerful computer, open to the network:
TerminalLinux PowerShellWindows./loculus serve ~/models/qwen3.8-27b/Qwen3.8-27B-UD-Q4_K_M.gguf --gpu --alias loculus --host 0.0.0.0.\loculus.exe serve $HOME\models\qwen3.8-27b\Qwen3.8-27B-UD-Q4_K_M.gguf --gpu --alias loculus --host 0.0.0.0Find that computer’s address on your network (it looks like
192.168.1.50):TerminalLinux PowerShellWindowshostname -IGet-NetIPAddress -AddressFamily IPv4 | Where-Object { $_.PrefixOrigin -in 'Dhcp', 'Manual' -and $_.IPAddress -notlike '169.254*' } | Select-Object InterfaceAlias, IPAddressIf its firewall is on, let port 8090 through:
TerminalLinux PowerShellWindowssudo ufw allow 8090/tcp # Ubuntu, Mint, Pop!_OS sudo firewall-cmd --add-port=8090/tcp --permanent && sudo firewall-cmd --reload # Fedora# In PowerShell opened as Administrator (right-click PowerShell: Run as administrator) New-NetFirewallRule -DisplayName 'Loculus Core' -Direction Inbound -Protocol TCP -LocalPort 8090 -Action Allow -Profile PrivateWindows may also ask the first time whether Loculus Core may use private networks: choose Allow.
From the other computer, check it answers, then use that address wherever these docs say
127.0.0.1:TerminalLinux PowerShellWindowscurl http://192.168.1.50:8090/healthInvoke-RestMethod http://192.168.1.50:8090/health
Reach it securely over SSHFrom anywhere you can SSH in, with Loculus Core left on localhost
On the computer you’re using (Linux, macOS or Windows all have ssh), forward its port 8090 to the Loculus Core computer’s own:
ssh -N -L 8090:127.0.0.1:8090 you@192.168.1.50 While that runs, http://127.0.0.1:8090 on your computer is Loculus Core on the other one, so every recipe and app set-up here works unchanged.
#Keep it running
To keep Loculus Core running without a terminal window, and start it with the computer:
Make it a user service. Create its file:
[Unit]
Description=Loculus Core
After=network-online.target
[Service]
ExecStart=%h/loculus-core/loculus serve %h/models/qwen3.8-27b/Qwen3.8-27B-UD-Q4_K_M.gguf --gpu --alias loculus
Restart=on-failure
[Install]
WantedBy=default.target Then switch it on, and read its messages whenever you like:
systemctl --user daemon-reload
systemctl --user enable --now loculus # start it now, and at every sign-in
journalctl --user -u loculus -f # its messages as they come (Ctrl+C stops watching)
loginctl enable-linger $USER # optional: keep it running when you're signed out Put a shortcut in your Startup folder, and Windows starts it, minimised, each time you sign in:
$link = (New-Object -ComObject WScript.Shell).CreateShortcut("$env:APPDATA\Microsoft\Windows\Start Menu\Programs\Startup\Loculus Core.lnk")
$link.TargetPath = "$HOME\loculus-core\loculus.exe"
$link.Arguments = "serve `"$HOME\models\qwen3.8-27b\Qwen3.8-27B-UD-Q4_K_M.gguf`" --gpu --alias loculus"
$link.WorkingDirectory = "$HOME\loculus-core"
$link.WindowStyle = 7 # starts minimised: its window waits on the taskbar
$link.Save() Its window waits on the taskbar with Loculus Core’s messages; close it to stop Loculus Core. To stop it starting with Windows, delete the shortcut: press Win + R, type shell:startup, and delete Loculus Core.
Add --idle-unload 600 to the command so that, left alone, it gives the graphics memory back to your other apps after ten minutes, and loads the model again on the next request.
#Measure your speed
To see how fast a model runs on your machine:
./loculus bench ~/models/qwen3.8-27b/Qwen3.8-27B-UD-Q4_K_M.gguf -p 512 -n 128 --gpu .\loculus.exe bench $HOME\models\qwen3.8-27b\Qwen3.8-27B-UD-Q4_K_M.gguf -p 512 -n 128 --gpu It prints two lines. pp512 is how fast it reads: tokens a second through a 512-token prompt. tg128 is how fast it writes: tokens a second over a 128-token answer. Add -d 16384 to measure deep into a long conversation. Our own measurements, machine by machine, are on the Performance page.
API integration
Loculus Core speaks the same APIsThe standard way programs talk to an AI model. Loculus Core speaks the same APIs as OpenAI and Anthropic, so apps made for them work with it. as OpenAI and Anthropic, all on one port. So the coding agents, editors, chat apps and libraries you already use work with your own AI: point them at Loculus Core’s address and give the model name. Nothing else changes.
#Addresses and endpoints
Every app asks for one of two addresses, depending on which API it speaks:
OpenAI-style apps
http://127.0.0.1:8090/v1 Anthropic-style apps
http://127.0.0.1:8090 From another computer, use the address of the one running Loculus Core instead of 127.0.0.1 (see Use it from another computer); with --port, your port instead of 8090.
| Endpoint | What it’s for |
|---|---|
POST/v1/messages | Anthropic Messages: Claude Code, the Anthropic libraries |
POST/v1/messages/count_tokens | Anthropic: how many tokens a request is |
POST/v1/responses | OpenAI Responses: Codex, the OpenAI libraries |
POST/v1/chat/completions | OpenAI Chat Completions: most apps and libraries |
POST/v1/completions | OpenAI Completions: plain text in, text out |
GET/v1/models | The model’s name, and its reasoning levels |
GET/health | {"status":"ok"} while it’s running |
POST/v1/images/generations | OpenAI Images: pictures (served with --image) |
POST/v1/videos | OpenAI Videos: start a video (served with --video) |
GET/v1/videos/{id} | A video’s progress |
GET/v1/videos/{id}/content | The finished MP4 |
GET/v1/videos | Videos made, newest first |
DELETE/v1/videos/{id} | Delete a finished video |
POST/unload · /load | Give the graphics memory back now, or load the model again |
Every endpoint streams with "stream": true where its API allows, and /v1 is optional on all of them.
#Keys and model names
- API key: none needed. Apps that insist on one can have any text: these docs use
local. - Model name: whatever you give
--aliaswhen you start Loculus Core; these docs useloculus. Apps can read it from/v1/models. One model is served at a time, so the name in a request doesn’t change which model answers. - Context size: coding agents send long prompts. Start Loculus Core with room for them,
--ctx 65536or more if your memory allows, and tell the agent the same number: the set-ups below use 65536. Claude Code is the exception: its own window stays larger (see Long conversations). - Tool calls: agents act through tools, so choose a model that calls them: Qwen3.8, DeepSeek V4.1, GLM-5.3, gpt-oss and Nemotron do; the start-up line
tool calls: …saysnonefor a model that doesn’t.
Check your settings from the terminal; this lists the model by the name apps should use:
curl -s http://127.0.0.1:8090/v1/models | jq -r '.data[0].id' (Invoke-RestMethod http://127.0.0.1:8090/v1/models).data[0].id #From your own code
The official OpenAI and Anthropic libraries, and the frameworks built on them, need only the base URL and a model name. Pick yours:
OpenAI Python SDK OpenAI Responses
base_url and api_key on OpenAI(), or the OPENAI_BASE_URL and OPENAI_API_KEY environment variables
from openai import OpenAI
client = OpenAI(base_url="http://127.0.0.1:8090/v1", api_key="local")
response = client.responses.create(model="loculus", input="Hello")
print(response.output_text) - Pass a non-empty key: the SDK expects one even though Loculus Core ignores it.
- Or set OPENAI_BASE_URL=http://127.0.0.1:8090/v1 and OPENAI_API_KEY=local and call OpenAI() with no arguments.
- Chat Completions works too: client.chat.completions.create.
OpenAI Python SDK’s own documentation Set-up checked against it on 21 Nov 2026.
OpenAI Node / TypeScript SDK OpenAI Responses
baseURL and apiKey on new OpenAI(), or the OPENAI_BASE_URL and OPENAI_API_KEY environment variables
import OpenAI from 'openai';
const client = new OpenAI({ baseURL: 'http://127.0.0.1:8090/v1', apiKey: 'local' });
const response = await client.responses.create({ model: 'loculus', input: 'Hello' });
console.log(response.output_text); - Pass the dummy key: without one the constructor throws “Missing credentials”.
- baseURL and apiKey default to the OPENAI_BASE_URL and OPENAI_API_KEY environment variables.
- Chat Completions works too: client.chat.completions.create.
OpenAI Node / TypeScript SDK’s own documentation Set-up checked against it on 21 Nov 2026.
Anthropic Python SDK Anthropic Messages
base_url and api_key on Anthropic(), or the ANTHROPIC_BASE_URL and ANTHROPIC_API_KEY environment variables
from anthropic import Anthropic
client = Anthropic(base_url="http://127.0.0.1:8090", api_key="local")
message = client.messages.create(
model="loculus",
max_tokens=1024,
messages=[{"role": "user", "content": "Hello"}],
)
for block in message.content:
if block.type == "text":
print(block.text) - No /v1 in base_url: the SDK adds /v1/messages itself.
- Pass one credential, api_key or auth_token, not both: version 2 raises a ValueError.
- count_tokens and stream=True work against the same base URL.
Anthropic Python SDK’s own documentation Set-up checked against it on 21 Nov 2026.
Anthropic TypeScript SDK Anthropic Messages
baseURL and apiKey on new Anthropic(), or the ANTHROPIC_BASE_URL and ANTHROPIC_API_KEY environment variables
import Anthropic from '@anthropic-ai/sdk';
const client = new Anthropic({ baseURL: 'http://127.0.0.1:8090', apiKey: 'local' });
const message = await client.messages.create({
model: 'loculus',
max_tokens: 1024,
messages: [{ role: 'user', content: 'Hello' }],
});
console.log(message.content); - No /v1 in baseURL: the SDK adds /v1/messages itself.
- Pass exactly one credential: with none the first request fails, and two throw a TypeError.
- It needs Node.js 20 LTS or later. In a browser, add dangerouslyAllowBrowser: true.
Anthropic TypeScript SDK’s own documentation Set-up checked against it on 21 Nov 2026.
LangChain OpenAI Chat Completions
base_url and api_key on ChatOpenAI or ChatAnthropic
# pip install -U langchain-openai
from langchain_openai import ChatOpenAI
llm = ChatOpenAI(
model="loculus",
base_url="http://127.0.0.1:8090/v1",
api_key="local",
) # pip install -U langchain-anthropic
from langchain_anthropic import ChatAnthropic
llm = ChatAnthropic(
model="loculus",
base_url="http://127.0.0.1:8090",
api_key="local",
max_tokens=4096,
) - ChatOpenAI uses Chat Completions (use_responses_api=True switches it to Responses). ChatAnthropic uses the Messages API, with no /v1 in base_url.
- api_key must not be empty: the OpenAI SDK refuses to start without one.
- Set max_tokens on ChatAnthropic: for an unknown model such as loculus it falls back to 4096.
LangChain’s own documentation Set-up checked against it on 21 Nov 2026.
Vercel AI SDK OpenAI Chat Completions
baseURL and apiKey on createOpenAICompatible (or createOpenAI, createAnthropic)
// npm i ai @ai-sdk/openai-compatible
import { createOpenAICompatible } from '@ai-sdk/openai-compatible';
import { generateText } from 'ai';
const loculus = createOpenAICompatible({
name: 'loculus',
baseURL: 'http://127.0.0.1:8090/v1',
apiKey: 'local',
supportsStructuredOutputs: true,
});
const { text } = await generateText({ model: loculus('loculus'), prompt: 'Hello' }); // npm i ai @ai-sdk/openai
import { createOpenAI } from '@ai-sdk/openai';
const openai = createOpenAI({ baseURL: 'http://127.0.0.1:8090/v1', apiKey: 'local' });
// openai('loculus') -> Responses API (/v1/responses)
// openai.chat('loculus') -> Chat Completions // npm i ai @ai-sdk/anthropic
import { createAnthropic } from '@ai-sdk/anthropic';
const anthropic = createAnthropic({ baseURL: 'http://127.0.0.1:8090/v1', apiKey: 'local' });
// anthropic('loculus') -> Messages API (/v1/messages) - @ai-sdk/anthropic needs /v1 in baseURL, unlike the official Anthropic SDKs and Claude Code.
- supportsStructuredOutputs: true lets object generation send the JSON schema, which Loculus Core supports.
- Always pass the placeholder apiKey: otherwise @ai-sdk/openai and @ai-sdk/anthropic send your real OPENAI_API_KEY or ANTHROPIC_API_KEY to the local server.
Vercel AI SDK’s own documentation Set-up checked against it on 21 Nov 2026.
LiteLLM OpenAI Chat Completions
api_base on each call, or the proxy’s config.yaml
# pip install litellm
import litellm
resp = litellm.completion(
model="openai/loculus",
api_base="http://127.0.0.1:8090/v1",
api_key="local",
messages=[{"role": "user", "content": "Hello"}],
) model_list:
- model_name: loculus
litellm_params:
model: openai/loculus
api_base: http://127.0.0.1:8090/v1
api_key: local - For openai/, api_base must end in /v1 with nothing after it.
- openai/ needs a non-empty api_key: the placeholder is simplest.
- Run the proxy with litellm --config config.yaml; it serves on port 4000.
LiteLLM’s own documentation Set-up checked against it on 21 Nov 2026.
OpenAI Agents SDK OpenAI Responses
An AsyncOpenAI client with base_url, passed to the model (or set as the default with set_default_openai_client)
from openai import AsyncOpenAI
from agents import Agent, OpenAIResponsesModel, Runner, set_tracing_disabled
set_tracing_disabled(True)
client = AsyncOpenAI(base_url="http://127.0.0.1:8090/v1", api_key="local")
agent = Agent(
name="Assistant",
instructions="You are a helpful assistant.",
model=OpenAIResponsesModel(model="loculus", openai_client=client),
)
print(Runner.run_sync(agent, "Hello").final_output) import OpenAI from 'openai';
import { Agent, run, setDefaultOpenAIClient, setTracingDisabled } from '@openai/agents';
setDefaultOpenAIClient(new OpenAI({ baseURL: 'http://127.0.0.1:8090/v1', apiKey: 'local' }));
setTracingDisabled(true);
const agent = new Agent({ name: 'Assistant', instructions: 'You are a helpful assistant.', model: 'loculus' });
const result = await run(agent, 'Hello');
console.log(result.finalOutput); - Turn tracing off as shown: traces upload to OpenAI with the client’s key, and the dummy key fails with a 401.
- Use your own function tools: hosted tools such as WebSearchTool run on OpenAI’s platform, not on Loculus Core.
- In JavaScript, a client you pass in must be openai 7.2 or later.
OpenAI Agents SDK’s own documentation Set-up checked against it on 21 Nov 2026. Part of it isn’t confirmed in its documentation yet: tell us if it works for you.
Claude Agent SDK Anthropic Messages
The env option, with the same variables as Claude Code
import asyncio
from claude_agent_sdk import ClaudeAgentOptions, query
options = ClaudeAgentOptions(
model="loculus",
env={
"ANTHROPIC_BASE_URL": "http://127.0.0.1:8090",
"ANTHROPIC_AUTH_TOKEN": "local",
"ANTHROPIC_DEFAULT_OPUS_MODEL": "loculus",
"ANTHROPIC_DEFAULT_SONNET_MODEL": "loculus",
"ANTHROPIC_DEFAULT_HAIKU_MODEL": "loculus",
"ANTHROPIC_DEFAULT_FABLE_MODEL": "loculus",
"CLAUDE_CODE_MAX_CONTEXT_TOKENS": "262144",
"CLAUDE_CODE_AUTO_COMPACT_WINDOW": "262144",
"CLAUDE_CODE_MAX_OUTPUT_TOKENS": "128000",
},
)
async def main():
async for message in query(prompt="Hello", options=options):
print(message)
asyncio.run(main()) import { query } from '@anthropic-ai/claude-agent-sdk';
for await (const message of query({
prompt: 'Hello',
options: {
model: 'loculus',
env: {
...process.env,
ANTHROPIC_BASE_URL: 'http://127.0.0.1:8090',
ANTHROPIC_AUTH_TOKEN: 'local',
ANTHROPIC_DEFAULT_OPUS_MODEL: 'loculus',
ANTHROPIC_DEFAULT_SONNET_MODEL: 'loculus',
ANTHROPIC_DEFAULT_HAIKU_MODEL: 'loculus',
ANTHROPIC_DEFAULT_FABLE_MODEL: 'loculus',
CLAUDE_CODE_MAX_CONTEXT_TOKENS: '262144',
CLAUDE_CODE_AUTO_COMPACT_WINDOW: '262144',
CLAUDE_CODE_MAX_OUTPUT_TOKENS: '128000',
},
},
})) {
console.log(message);
} - Start Loculus Core with --ctx 65536, or more if your memory allows. As in Claude Code, its own window stays at 262,144 on purpose (see Long conversations).
- In TypeScript, env replaces the whole environment, so keep ...process.env; in Python, env adds to it.
- The SDK also loads the env block from ~/.claude/settings.json. setting_sources=[] (settingSources: [] in TypeScript) turns that off.
Claude Agent SDK’s own documentation Set-up checked against it on 21 Nov 2026.
LlamaIndex OpenAI Chat Completions
api_base and api_key on OpenAILike
# pip install llama-index-llms-openai-like
from llama_index.llms.openai_like import OpenAILike
llm = OpenAILike(
model="loculus",
api_base="http://127.0.0.1:8090/v1",
api_key="local",
context_window=65536,
is_chat_model=True,
is_function_calling_model=True,
) - Keep is_chat_model=True (otherwise it calls the old /v1/completions endpoint) and is_function_calling_model=True for agents.
- context_window defaults to 3900: start Loculus Core with --ctx 65536 (or more) to match the value set here.
- For the Responses API, use OpenAILikeResponses from the same package.
LlamaIndex’s own documentation Set-up checked against it on 21 Nov 2026.
Pydantic AI OpenAI Chat Completions
base_url and api_key on OpenAICompatibleProvider
# pip install "pydantic-ai-slim[openai]"
from pydantic_ai import Agent
from pydantic_ai.models.openai import OpenAIChatModel
from pydantic_ai.providers.openai_compatible import OpenAICompatibleProvider
model = OpenAIChatModel(
'loculus',
provider=OpenAICompatibleProvider(
'loculus',
base_url='http://127.0.0.1:8090/v1',
api_key='local',
),
)
agent = Agent(model) # pip install "pydantic-ai-slim[anthropic]"
from pydantic_ai.models.anthropic import AnthropicModel
from pydantic_ai.providers.anthropic import AnthropicProvider
model = AnthropicModel(
'loculus',
provider=AnthropicProvider(base_url='http://127.0.0.1:8090', api_key='local'),
) - The provider’s first argument names the service: keep it the same between runs.
- For the Responses API, use OpenAIResponsesModel instead of OpenAIChatModel.
- api_key is optional on OpenAICompatibleProvider; the placeholder is harmless.
Pydantic AI’s own documentation Set-up checked against it on 21 Nov 2026.
DSPy OpenAI Chat Completions
api_base and api_key on dspy.LM
# pip install -U dspy
import dspy
lm = dspy.LM(
"openai/loculus",
api_base="http://127.0.0.1:8090/v1",
api_key="local",
model_type="chat",
)
dspy.configure(lm=lm) - A placeholder key is required.
- DSPy caches answers by default: pass cache=False when testing or benchmarking.
- model_type="responses" switches to the Responses API, which Loculus Core supports.
DSPy’s own documentation Set-up checked against it on 21 Nov 2026.
Nothing matches. Most tools that let you set an “OpenAI-compatible” address work with Loculus Core: use the address and model name from Addresses and endpoints.
#Coding agents
Coding agents read your code, run commands and make changes, all by calling tools. Each set-up below points one at Loculus Core. For the best results use a model that calls tools well, such as Qwen3.8 27B or Flash-Next, and give it a large context.
Claude Code Anthropic Messages
Linux & macOS: ~/.claude/settings.json · Windows: %USERPROFILE%\.claude\settings.json · One project only: .claude/settings.local.json
{
"env": {
"ANTHROPIC_BASE_URL": "http://127.0.0.1:8090",
"ANTHROPIC_AUTH_TOKEN": "local",
"ANTHROPIC_MODEL": "loculus",
"ANTHROPIC_DEFAULT_OPUS_MODEL": "loculus",
"ANTHROPIC_DEFAULT_SONNET_MODEL": "loculus",
"ANTHROPIC_DEFAULT_HAIKU_MODEL": "loculus",
"ANTHROPIC_DEFAULT_FABLE_MODEL": "loculus",
"CLAUDE_CODE_MAX_CONTEXT_TOKENS": "262144",
"CLAUDE_CODE_AUTO_COMPACT_WINDOW": "262144",
"CLAUDE_CODE_MAX_OUTPUT_TOKENS": "128000",
"CLAUDE_CODE_DISABLE_NONESSENTIAL_TRAFFIC": "1"
}
} - Start Loculus Core with --ctx 65536, or more if your memory allows. Claude Code’s own window stays at 262,144 on purpose: when a session outgrows the model’s context, Loculus Core keeps it going (see Long conversations).
- For the VS Code extension, also add ANTHROPIC_BASE_URL and ANTHROPIC_AUTH_TOKEN under claudeCode.environmentVariables in VS Code’s own settings.json. The Claude desktop app ignores these settings.
- Anthropic doesn’t support Claude Code with non-Claude models: it works because Loculus Core speaks the Messages API, but it’s outside Anthropic’s support.
Claude Code’s own documentation Set-up checked against it on 21 Nov 2026.
OpenAI Codex CLI OpenAI Responses
Linux & macOS: ~/.codex/config.toml · Windows: %USERPROFILE%\.codex\config.toml
model = "loculus"
model_provider = "loculus"
model_context_window = 65536
[model_providers.loculus]
name = "Loculus Core"
base_url = "http://127.0.0.1:8090/v1"
wire_api = "responses" - Start Loculus Core with --ctx 65536 (or more) to match.
- Codex turns on OpenAI’s web search by default. If Loculus Core rejects it, add web_search = "disabled" at the top of the file.
- No key is needed, so the provider has no env_key line.
OpenAI Codex CLI’s own documentation Set-up checked against it on 21 Nov 2026.
OpenCode OpenAI Chat Completions
All projects: ~/.config/opencode/opencode.json (the docs give no Windows path) · One project: opencode.json in its root folder, on any system
{
"$schema": "https://opencode.ai/config.json",
"providers": {
"loculus": {
"name": "Loculus Core",
"package": "@opencode/ai/providers/openai-compatible",
"settings": {
"baseURL": "http://127.0.0.1:8090/v1",
"apiKey": "local"
},
"models": {
"loculus": {
"name": "Loculus",
"limit": { "context": 65536, "output": 8192 }
}
}
}
},
"model": "loculus/loculus"
} {
"$schema": "https://opencode.ai/config.json",
"provider": {
"loculus": {
"npm": "@ai-sdk/openai-compatible",
"name": "Loculus Core",
"options": {
"baseURL": "http://127.0.0.1:8090/v1",
"apiKey": "local"
},
"models": {
"loculus": {
"name": "Loculus",
"limit": { "context": 65536, "output": 8192 }
}
}
}
},
"model": "loculus/loculus"
} - Keep the limit line: OpenCode can’t detect the real window and otherwise assumes 200,000 tokens. Start Loculus Core with --ctx 65536 (or more) to match.
- Use the OpenCode 2 file on version 2 and the 1.x file on older versions. OpenCode 2 still reads the 1.x layout.
- The model is written provider/model, which is why it reads loculus/loculus.
OpenCode’s own documentation Set-up checked against it on 21 Nov 2026.
Gemini CLI Can’t use a local server
No setting for an OpenAI- or Anthropic-style server
- Gemini CLI speaks only Google’s Gemini API, which Loculus Core doesn’t serve.
- Workaround: use Qwen Code, a Gemini CLI fork that speaks the OpenAI API, or put LiteLLM’s proxy in between as LiteLLM’s Gemini CLI tutorial shows (untested with Loculus Core).
Gemini CLI’s own documentation Set-up checked against it on 21 Nov 2026.
GitHub Copilot CLI OpenAI Chat Completions
~/.copilot/providers.json (the docs give no Windows path)
{
"providers": [
{
"name": "loculus",
"type": "openai",
"baseUrl": "http://127.0.0.1:8090/v1",
"apiKey": "local"
}
],
"models": [
{
"id": "loculus",
"provider": "loculus",
"maxPromptTokens": 57344,
"maxOutputTokens": 8192
}
]
} COPILOT_OFFLINE=true copilot --model loculus/loculus - maxPromptTokens and maxOutputTokens together must fit Loculus Core’s context (these add up to 65,536: start it with --ctx 65536). Unknown models may otherwise get 128,000 prompt tokens.
- No GitHub sign-in is needed with your own provider. COPILOT_OFFLINE=true stops all contact with GitHub, telemetry included.
- GitHub recommends a 128k context for best results.
GitHub Copilot CLI’s own documentation Set-up checked against it on 21 Nov 2026.
Cursor CLI Can’t use a local server
No setting for your own server
- The Cursor CLI has no option for your own key or a custom base URL.
- There’s no workaround: use Claude Code, Codex or OpenCode with Loculus Core instead.
Cursor CLI’s own documentation Set-up checked against it on 21 Nov 2026.
Aider OpenAI Chat Completions
Environment variables, or .aider.conf.yml and .aider.model.metadata.json in your home folder, the repository’s root or the current folder
export OPENAI_API_BASE=http://127.0.0.1:8090/v1
export OPENAI_API_KEY=local
aider --model openai/loculus setx OPENAI_API_BASE http://127.0.0.1:8090/v1
setx OPENAI_API_KEY local
aider --model openai/loculus model: openai/loculus
openai-api-base: http://127.0.0.1:8090/v1
openai-api-key: local {
"openai/loculus": {
"max_tokens": 8192,
"max_input_tokens": 65536,
"max_output_tokens": 8192,
"litellm_provider": "openai",
"mode": "chat"
}
} - Add .aider.model.metadata.json: without it Aider treats the window as unlimited and won’t trim the chat to fit. Start Loculus Core with --ctx 65536 (or more) to match.
- On Windows, setx only reaches new windows: open a new one before running aider.
- Use either the environment variables or .aider.conf.yml, and keep the openai/ prefix on the model name.
Aider’s own documentation Set-up checked against it on 21 Nov 2026.
Qwen Code OpenAI Chat Completions
All projects: ~/.qwen/settings.json (on Windows %USERPROFILE%\.qwen\settings.json, not confirmed in the docs) · One project: .qwen/settings.json
{
"modelProviders": {
"openai": [
{
"id": "loculus",
"name": "Loculus Core",
"baseUrl": "http://127.0.0.1:8090/v1",
"envKey": "LOCULUS_API_KEY",
"generationConfig": { "contextWindowSize": 65536 }
}
]
},
"env": { "LOCULUS_API_KEY": "local" },
"security": { "auth": { "selectedType": "openai" } },
"model": { "name": "loculus" }
} - Start Loculus Core with --ctx 65536 (or more) to match.
- Loculus Core needs no key, but Qwen Code wants one through envKey: any placeholder works.
- For image input, add "modalities": { "image": true } to generationConfig.
Qwen Code’s own documentation Set-up checked against it on 21 Nov 2026.
Cline CLI OpenAI Chat Completions
~/.cline/data/settings/providers.json, written by cline auth
cline auth # interactive: choose OpenAI Compatible; base URL http://127.0.0.1:8090/v1, key local, model loculus
# non-interactive (provider id UNCONFIRMED, see below):
cline auth -p openai -k local -m loculus -b http://127.0.0.1:8090/v1 - The provider id openai (Cline’s internal id for OpenAI Compatible) isn’t confirmed in the CLI docs. If it fails, run cline auth on its own and choose OpenAI Compatible.
- Install it with npm i -g cline.
Cline CLI’s own documentation Set-up checked against it on 21 Nov 2026. Part of it isn’t confirmed in its documentation yet: tell us if it works for you.
Kilo CLI OpenAI Chat Completions
Linux & macOS: ~/.config/kilo/kilo.jsonc · Windows: C:\Users\<username>\.config\kilo\kilo.jsonc · One project: kilo.jsonc or .kilo/kilo.jsonc
{
"$schema": "https://app.kilo.ai/config.json",
"model": "openai-compatible/loculus",
"provider": {
"openai-compatible": {
"options": {
"apiKey": "local",
"baseURL": "http://127.0.0.1:8090/v1"
},
"models": {
"loculus": {
"name": "Loculus",
"tool_call": true,
"limit": { "context": 65536, "output": 8192 }
}
}
}
}
} - Start Loculus Core with --ctx 65536 (or more) to match.
- Pick the model with kilo -m openai-compatible/loculus or the model picker.
- The Kilo CLI and its VS Code and JetBrains extensions share this file.
Kilo CLI’s own documentation Set-up checked against it on 21 Nov 2026.
Goose OpenAI Chat Completions
Linux & macOS: ~/.config/goose/custom_providers/custom_loculus.json · Windows: %APPDATA%\Block\goose\config\custom_providers\custom_loculus.json · Goose Desktop: Settings → Models → Configure providers → Add Custom Provider
{
"name": "custom_loculus",
"engine": "openai",
"display_name": "Loculus Core",
"api_key_env": "",
"base_url": "http://127.0.0.1:8090/v1",
"models": [{ "name": "loculus", "context_limit": 65536 }],
"supports_streaming": true,
"requires_auth": false
} GOOSE_PROVIDER=custom_loculus GOOSE_MODEL=loculus goose session - Start Loculus Core with --ctx 65536 (or more) to match.
- GOOSE_PROVIDER and GOOSE_MODEL apply to that run only. To make the choice permanent, pick the provider in goose configure.
- Running without a key ("requires_auth": false) comes from Goose’s source code; the docs show no example of it.
Goose’s own documentation Set-up checked against it on 21 Nov 2026. Part of it isn’t confirmed in its documentation yet: tell us if it works for you.
Warp Can’t use a local server
Settings → search “inference endpoint” (public URLs only)
- Warp’s custom endpoint must be reachable at a public URL, and requests pass through Warp’s servers, so it can’t reach Loculus Core on your computer.
- The only workaround is a public URL for Loculus Core, which isn’t recommended: it has no password, and your prompts and key would pass through Warp’s servers.
Warp’s own documentation Set-up checked against it on 21 Nov 2026.
Amp Can’t use a local server
Settings → Model Routing → Add Provider → Custom URL (public URLs only)
- Amp sends model requests from its own servers, so a 127.0.0.1 address points at Amp’s servers, not your computer.
- The only workaround is a public URL for Loculus Core, which isn’t recommended for a local engine: your prompts would pass through Amp’s servers and Loculus Core would be open to the internet.
Amp’s own documentation Set-up checked against it on 21 Nov 2026.
OpenHands OpenAI Chat Completions
Settings → LLM → Advanced (Agent Canvas or the Docker app) · Legacy CLI: environment variables or ~/.openhands/agent_settings.json
Custom Model: openai/loculus
Base URL: http://127.0.0.1:8090/v1 (Agent Canvas via npx/npm on the same machine)
http://host.docker.internal:8090/v1 (OpenHands running in Docker)
API Key: local export LLM_MODEL="openai/loculus"
export LLM_BASE_URL="http://127.0.0.1:8090/v1"
export LLM_API_KEY="local"
openhands --override-with-envs - In Docker, 127.0.0.1 is the container itself: use http://host.docker.internal:8090/v1, and on Linux start Loculus Core with --host 0.0.0.0 so the container can reach it.
- OpenHands needs a large context (its docs: at least 22,000 tokens, 32,768 recommended), so start Loculus Core with --ctx 32768 or more.
- The OpenHands CLI is no longer maintained. The maintained local app is Agent Canvas (npx @openhands/agent-canvas).
OpenHands’s own documentation Set-up checked against it on 21 Nov 2026.
Crush OpenAI Chat Completions
Linux & macOS: ~/.config/crush/crushrc · Windows: %USERPROFILE%\.config\crush\crushrc · One project: .crushrc or crushrc in its folder
provider add loculus --name "Loculus Core" --type completions \
--base-url "http://127.0.0.1:8090/v1" \
--api-key "local"
model add loculus/loculus --name "Loculus" \
--context-window 65536 \
--default-max-tokens 8192
model large loculus/loculus
model small loculus/loculus - Start Loculus Core with --ctx 65536 (or more) to match.
- crushrc replaces crush.json: on an old Crush, upgrade rather than copy old JSON examples.
- For image input, add --supports-images true to model add.
Crush’s own documentation Set-up checked against it on 21 Nov 2026.
Factory Droid OpenAI Chat Completions
~/.factory/settings.json, key customModels (the docs give no Windows path; %USERPROFILE%\.factory\settings.json is the likely equivalent)
{
"customModels": [
{
"model": "loculus",
"displayName": "Loculus Core",
"baseUrl": "http://127.0.0.1:8090/v1",
"apiKey": "local",
"provider": "generic-chat-completion-api",
"maxContextLimit": 65536,
"maxOutputTokens": 8192,
"noImageSupport": false
}
]
} - Start Loculus Core with --ctx 65536 (or more) to match.
- Then choose it in /model → Custom Models → Loculus Core.
- "noImageSupport": false turns on image input. Leave that line out if the model can’t take images.
Factory Droid’s own documentation Set-up checked against it on 21 Nov 2026.
Pi coding agent OpenAI Chat Completions
~/.pi/agent/models.json (the docs give no Windows path; %USERPROFILE%\.pi\agent\models.json is the likely equivalent)
{
"$schema": "https://pi.dev/schemas/models.schema.json",
"providers": {
"loculus": {
"baseUrl": "http://127.0.0.1:8090/v1",
"api": "openai-completions",
"apiKey": "local",
"models": [
{ "id": "loculus", "contextWindow": 65536, "maxTokens": 8192 }
]
}
}
} pi --model loculus/loculus - Set both limits: Pi otherwise assumes a 128,000-token window and 16,384-token answers. Start Loculus Core with --ctx 65536 (or more) to match.
- Keep the placeholder apiKey: Pi hides custom models until it has a key for them.
- For image input, add "input": ["text", "image"] to the model.
Pi coding agent’s own documentation Set-up checked against it on 21 Nov 2026.
Kimi Code CLI OpenAI Chat Completions
~/.kimi-code/config.toml (the docs give no Windows path)
default_model = "loculus"
[providers.loculus]
type = "openai"
base_url = "http://127.0.0.1:8090/v1"
api_key = "local"
[models.loculus]
provider = "loculus"
model = "loculus"
max_context_size = 65536
capabilities = ["tool_use"] - Start Loculus Core with --ctx 65536 (or more) to match.
- Keep api_key: Kimi Code won’t start without one, and any value works.
- Declare what the model can do under capabilities: add "image_in" for pictures.
Kimi Code CLI’s own documentation Set-up checked against it on 21 Nov 2026.
Mistral Vibe OpenAI Chat Completions
~/.vibe/config.toml (the docs give no Windows path)
active_model = "loculus"
[[providers]]
name = "loculus"
api_base = "http://127.0.0.1:8090/v1"
api_style = "openai"
backend = "generic"
[[models]]
name = "loculus"
provider = "loculus"
alias = "loculus"
max_context_length = 65536 - max_context_length drives automatic compaction: start Loculus Core with --ctx 65536 (or more) to match.
- No key is needed: leave api_key_env_var unset.
- For offline use, also set enable_telemetry = false and enable_update_checks = false.
Mistral Vibe’s own documentation Set-up checked against it on 21 Nov 2026.
Open Interpreter OpenAI Responses
~/.openinterpreter/config.toml (the only path the docs give, for every system) · One project: .openinterpreter/config.toml in a trusted project
model_provider = "loculus"
model = "loculus"
[model_providers.loculus]
name = "Loculus Core"
base_url = "http://127.0.0.1:8090/v1"
wire_api = "responses" - This is the new Rust Open Interpreter, built on Codex. The old Python release’s --api_base flags don’t apply.
- For Chat Completions instead, set wire_api = "chat" or run interpreter --chat-completions once.
- Running without a key is assumed from Codex. If it asks for one, add env_key = "LOCULUS_API_KEY" to the provider and set LOCULUS_API_KEY=local.
Open Interpreter’s own documentation Set-up checked against it on 21 Nov 2026. Part of it isn’t confirmed in its documentation yet: tell us if it works for you.
Nothing matches. Most tools that let you set an “OpenAI-compatible” address work with Loculus Core: use the address and model name from Addresses and endpoints.
#Long conversations
Every model has a contextHow much the model keeps in view at once (your conversation, files and instructions), counted in tokens. : the amount of conversation it can hold at once. A long coding session outgrows it. Loculus Core then keeps the session going by itself. It keeps your task and the latest steps exactly as they are, shortens the older steps, and files the oldest behind a one-line note of what they did. The model can ask for what was set aside, and a single message too large for the context (a very long file, say) is kept as its beginning and end with a map of the rest, from which the model asks for the parts it needs. The session carries on, and there’s nothing to switch on.
One piece of advice for Claude Code: keep its own context window large, as its set-up above does (262,144). If you set it to the model’s smaller context, Claude Code starts summarising the session itself, and the work goes worse.
#Editors and IDEs
Editor extensions and IDEs with their own AI features:
Continue OpenAI Chat Completions No longer maintained (final release 2.0.0)
Linux & macOS: ~/.continue/config.yaml · Windows: %USERPROFILE%\.continue\config.yaml (one file for the VS Code and JetBrains extensions)
name: Local Config
version: 1.0.0
schema: v1
models:
- name: Loculus
provider: openai
model: loculus
apiBase: http://127.0.0.1:8090/v1
apiKey: local
capabilities:
- tool_use
defaultCompletionOptions:
contextLength: 65536 - Keep capabilities: tool_use. Continue can’t tell what loculus supports, and without it Agent mode is off. Add image_input if the model takes pictures.
- Start Loculus Core with --ctx 65536 (or more) to match.
- Continue is no longer maintained: 2.0.0 was its final release, and its repository is read-only.
Continue’s own documentation Set-up checked against it on 21 Nov 2026.
Cline OpenAI Chat Completions
Cline panel → Settings (the gear)
API Provider: OpenAI Compatible
Base URL: http://127.0.0.1:8090/v1
API Key: local
Model ID: loculus
Model Configuration
Context Window Size: 65536
Max Output Tokens: 8192
Image Support: on only if the loaded model accepts images - Start Loculus Core with --ctx 65536 (or more) to match.
- Turn on Use Compact Prompt (Settings → Features), as Cline’s docs recommend for local models.
- Include /v1 in the Base URL: current versions use it exactly as entered.
Cline’s own documentation Set-up checked against it on 21 Nov 2026.
Zed OpenAI Chat Completions
Linux & macOS: ~/.config/zed/settings.json · Windows: %APPDATA%\Zed\settings.json · Or Agent Settings → LLM Providers → Add Provider
{
"language_models": {
"openai_compatible": {
"loculus": {
"api_url": "http://127.0.0.1:8090/v1",
"available_models": [
{
"name": "loculus",
"display_name": "Loculus",
"max_tokens": 65536
}
]
}
}
}
} {
"language_models": {
"anthropic_compatible": {
"Loculus": {
"api_url": "http://127.0.0.1:8090",
"available_models": [
{ "name": "loculus", "display_name": "Loculus", "max_tokens": 65536 }
]
}
}
}
} - Zed needs a key: enter local under Settings → AI → LLM Providers (it’s kept in the system keychain), or set LOCULUS_API_KEY=local in Zed’s environment.
- max_tokens is the context window: start Loculus Core with --ctx 65536 (or more) to match.
- Pick loculus once in the Agent Panel’s model selector; Zed saves it as the default.
Zed’s own documentation Set-up checked against it on 21 Nov 2026.
VS Code Copilot Chat OpenAI Chat Completions
Command Palette → Chat: Manage Language Models, which writes chatLanguageModels.json
- Open the Command Palette and run Chat: Manage Language Models.
- Choose Add Models → Custom Endpoint.
- Enter a group name, a display name and the API key local, then choose Chat Completions.
- VS Code opens chatLanguageModels.json: edit the model entry to match this one and save.
[
{
"name": "Loculus",
"vendor": "customendpoint",
"apiKey": "${input:loculusApiKey}",
"apiType": "chat-completions",
"models": [
{
"id": "loculus",
"name": "Loculus",
"url": "http://127.0.0.1:8090/v1/chat/completions",
"toolCalling": true,
"vision": false,
"contextWindow": 65536,
"maxOutputTokens": 8192
}
]
}
] - Start Loculus Core with --ctx 65536 (or more) to match.
- Keep the apiKey line VS Code wrote when you typed the key: it keeps the key in secret storage.
- Without a GitHub sign-in it works only in Local sessions, which VS Code will remove by February 2027. Inline suggestions always need GitHub Copilot.
VS Code Copilot Chat’s own documentation Set-up checked against it on 21 Nov 2026.
Cursor Can’t use a local server
Cursor Settings → Models → API Keys (public URLs only)
openssl rand -hex 32 # YOUR_TOKEN
ngrok config add-authtoken YOUR_NGROK_TOKEN
ngrok http 8090 --traffic-policy-file policy.yaml # policy.yaml: reject any request without the token
on_http_request:
- expressions:
- "!hasReqHeader('Authorization') || getReqHeader('Authorization')[0] != 'Bearer YOUR_TOKEN'"
actions:
- type: deny
config:
status_code: 401 Cursor Settings > Models > API Keys
OpenAI API Key: on, value YOUR_TOKEN
Override OpenAI Base URL: on, https://<your-name>.ngrok-free.dev/v1
Add model: loculus
-> Verify - Cursor sends every request through its own servers, which can’t reach Loculus Core on your computer or home network.
- Workaround: put Loculus Core behind a public ngrok tunnel that checks a token, and set the tunnel’s address as Cursor’s Override OpenAI Base URL.
- Keep the token check: Loculus Core has no password of its own. Your prompts and code still pass through Cursor’s servers.
Cursor’s own documentation Set-up checked against it on 21 Nov 2026. Part of it isn’t confirmed in its documentation yet: tell us if it works for you.
JetBrains AI Assistant OpenAI Chat Completions
Settings → Tools → AI Assistant → Providers & API keys (on macOS, Settings is under the IDE menu)
Settings | Tools | AI Assistant | Providers & API keys
Third-party AI providers
Provider: OpenAI-compatible
URL: http://127.0.0.1:8090/v1
API Key: local
Tool calling: on
-> Test Connection -> Apply
Model Assignment
Core features: loculus
Instant helpers: loculus
Context window: 65536 - Assign loculus under Model Assignment, or it appears only in AI Chat. Start Loculus Core with --ctx 65536 (or more) to match the Context window.
- JetBrains’ agents can’t use local models, and code completion has its own AI Completion settings.
- If Test Connection fails, try the URL without /v1: http://127.0.0.1:8090.
JetBrains AI Assistant’s own documentation Set-up checked against it on 21 Nov 2026. Part of it isn’t confirmed in its documentation yet: tell us if it works for you.
Kilo Code OpenAI Chat Completions
Settings → Providers → Custom provider, then kilo.jsonc (Linux & macOS: ~/.config/kilo/kilo.jsonc · Windows: C:\Users\<username>\.config\kilo\kilo.jsonc)
- Open Settings (the gear), go to the Providers tab and choose Custom provider.
- Set Provider ID loculus, Display name Loculus, Provider API OpenAI Compatible, Base URL http://127.0.0.1:8090/v1 and API key local.
- Under Models, pick loculus from the list Kilo fetches from Loculus Core, then click Submit.
- Add the limits to kilo.jsonc as shown.
{
"$schema": "https://app.kilo.ai/config.json",
"model": "loculus/loculus",
"provider": {
"loculus": {
"npm": "@ai-sdk/openai-compatible",
"options": {
"baseURL": "http://127.0.0.1:8090/v1",
"apiKey": "local"
},
"models": {
"loculus": {
"name": "Loculus",
"tool_call": true,
"limit": { "context": 65536, "output": 8192 }
}
}
}
}
} - Always set limit.context and limit.output: if they’re missing, both count as 0 and automatic compaction is off. Start Loculus Core with --ctx 65536 (or more) to match.
- tool_call: true gives the agent its tools. For pictures, also add "attachment": true and image input under "modalities".
- The Kilo CLI and the VS Code and JetBrains extensions all read this file.
Kilo Code’s own documentation Set-up checked against it on 21 Nov 2026.
Windsurf (now Devin Desktop) Can’t use a local server
Devin User Settings → Agents tab (third-party agents only)
Agent's own config (e.g. ~/.claude/settings.json "env", ~/.codex/config.toml, opencode.json) -> points it at the server
Extra env vars for the agent: "..." button in the Agents tab, or settings.json key devin.acp.agentEnv.<agentName> - Its own agents (Cascade, Devin Local) offer only Cognition-hosted models, with no option for your own key or a custom URL.
- Workaround: run Claude Code, Codex or OpenCode inside it as an ACP agent, set up as in their own sections; they run on your computer, so they can reach Loculus Core.
Windsurf (now Devin Desktop)’s own documentation Set-up checked against it on 21 Nov 2026. Part of it isn’t confirmed in its documentation yet: tell us if it works for you.
Roo Code OpenAI Chat Completions Discontinued 15 May 2026
Roo Code panel → Settings
API Provider: OpenAI Compatible
Base URL: http://127.0.0.1:8090/v1
API Key: local
Model: loculus
Model Configuration
Context Window: 65536
Max Output Tokens: 8192 - Roo Code was shut down on 15 May 2026 and is no longer maintained: this is only for copies already installed.
- Start Loculus Core with --ctx 65536 (or more) to match.
- The model must support tool calling: Roo Code has no fallback without it.
Roo Code’s own documentation Set-up checked against it on 21 Nov 2026.
Void OpenAI Chat Completions Archived 2 June 2026
Void Settings → providers
Provider: OpenAI-Compatible
baseURL: http://127.0.0.1:8090/v1 (do not include /chat/completions)
API Key: local
Model: loculus (add it as a model for the OpenAI-Compatible provider) - Void is no longer maintained (its repository was archived on 2 June 2026): this is only for existing users.
- Add loculus as a model for the OpenAI-Compatible provider; Void has no docs saying exactly where.
Void’s own documentation Set-up checked against it on 21 Nov 2026. Part of it isn’t confirmed in its documentation yet: tell us if it works for you.
Nothing matches. Most tools that let you set an “OpenAI-compatible” address work with Loculus Core: use the address and model name from Addresses and endpoints.
#Chat apps
Chat apps give you a chat window for your local AI, with conversations saved, documents and more. In each, add an “OpenAI-compatible” connection:
Open WebUI OpenAI Chat Completions
Admin Panel → Settings → Connections → OpenAI → Add Connection, or environment variables at first start
URL: http://127.0.0.1:8090/v1 (Open WebUI in Docker: http://host.docker.internal:8090/v1)
Auth: Bearer, key: local (or Auth: None; the server needs no key)
API Type: Chat Completions (default)
Model IDs: leave empty (models come from GET /v1/models) docker run -d -p 3000:8080 \
--add-host=host.docker.internal:host-gateway \
-e OPENAI_API_BASE_URL=http://host.docker.internal:8090/v1 \
-e OPENAI_API_KEY=local \
-e WEBUI_SECRET_KEY=your-secret-key \
-v open-webui:/app/backend/data \
--name open-webui --restart always \
ghcr.io/open-webui/open-webui:main - In Docker, use http://host.docker.internal:8090/v1, and on Linux start Loculus Core with --host 0.0.0.0 so the container can reach it.
- The environment variables apply only at first launch. After that, change the address in the Admin settings.
- Saving doesn’t test the connection: click Verify Connection next to the URL.
Open WebUI’s own documentation Set-up checked against it on 21 Nov 2026.
AnythingLLM OpenAI Chat Completions
Settings → AI Providers → LLM → Generic OpenAI, or the server’s .env (self-hosted and Docker)
Base URL: http://127.0.0.1:8090/v1 (Docker: http://host.docker.internal:8090/v1)
API Key: local (optional field)
Selected Model: loculus
Model context window: 65536
Max Tokens: 4096 (default 1024) LLM_PROVIDER='generic-openai'
GENERIC_OPEN_AI_BASE_PATH='http://host.docker.internal:8090/v1'
GENERIC_OPEN_AI_MODEL_PREF='loculus'
GENERIC_OPEN_AI_MODEL_TOKEN_LIMIT=65536
GENERIC_OPEN_AI_API_KEY='local'
GENERIC_OPEN_AI_MAX_TOKENS=4096 - In Docker, use http://host.docker.internal:8090/v1; on Linux, add --add-host=host.docker.internal:host-gateway to docker run and start Loculus Core with --host 0.0.0.0. The Desktop app can use 127.0.0.1.
- Max Tokens caps every answer and defaults to 1024: raise it, or long answers get cut off.
- Set Model context window to Loculus Core’s real context: start it with --ctx 65536 (or more) to match.
AnythingLLM’s own documentation Set-up checked against it on 21 Nov 2026. Part of it isn’t confirmed in its documentation yet: tell us if it works for you.
LibreChat OpenAI Chat Completions
librechat.yaml in the LibreChat folder, next to .env, on every system (with Docker, also enable its mount in docker-compose.override.yml)
version: 1.3.19
endpoints:
custom:
- name: "Loculus"
apiKey: "local"
baseURL: "http://host.docker.internal:8090/v1" # LibreChat not in Docker: http://127.0.0.1:8090/v1
models:
default: ["loculus"]
fetch: true
titleConvo: true
titleModel: "current_model" - In Docker, host.docker.internal reaches your computer. On Linux, start Loculus Core with --host 0.0.0.0 so the container can reach it.
- Keep apiKey: LibreChat drops a custom endpoint that has none, and any placeholder works.
- Apply changes with docker compose down && docker compose up -d.
LibreChat’s own documentation Set-up checked against it on 21 Nov 2026.
Jan OpenAI Chat Completions
Settings → Model Providers → Add Provider (Jan Desktop, every system)
- Open Settings → Model Providers and click Add Provider.
- Fill in the Add Custom Provider dialog as shown and click Create.
- In the provider’s Models list, click the pencil next to loculus and turn on Tools under Capabilities.
- If loculus isn’t listed, add it with + using the exact ID loculus.
API format: OpenAI-compatible
Provider name: Loculus
Base URL: http://127.0.0.1:8090/v1
API key: local - Turn on Tools (and vision, if wanted) by hand: Jan can’t tell what a model supports.
- A 404 on every request means the base URL is missing /v1.
- The API key field is required: any placeholder works.
Jan’s own documentation Set-up checked against it on 21 Nov 2026.
Chatbox OpenAI Chat Completions
Settings → Model Provider → Add (desktop, web and mobile)
- Open Settings → Model Provider and click Add at the bottom of the list.
- Fill in the fields as shown, including the model’s capabilities and context window.
- Save, then click Check.
Name: Loculus
API mode: OpenAI API Compatible
API Host: http://127.0.0.1:8090
API Path: /v1/chat/completions (the default; usually leave as is)
API Key: local
Models: add "loculus"; in its capabilities tick tool use (and vision); context window 65536 - Host and path together must make http://127.0.0.1:8090/v1/chat/completions: don’t put /v1 in both.
- Set tool use, vision and the context window on the model, or Chatbox treats it as plain text. Start Loculus Core with --ctx 65536 (or more) to match.
- From a phone or another computer, use this computer’s network address and start Loculus Core with --host 0.0.0.0.
Chatbox’s own documentation Set-up checked against it on 21 Nov 2026. Part of it isn’t confirmed in its documentation yet: tell us if it works for you.
Page Assist OpenAI Chat Completions
Toolbar icon → Settings → OpenAI Compatible API → Add Provider
- Click the Page Assist toolbar icon, then Settings → OpenAI Compatible API → Add Provider.
- Choose Custom, fill in the fields as shown and save.
- Make sure loculus is listed for this provider, and add it by hand if it isn’t.
Provider: Custom
Name: Loculus
Base URL: http://127.0.0.1:8090/v1
API Key: leave empty (or "local") - Use Custom, not the “Anthropic (Claude)” preset, which points at Anthropic’s servers.
- No origin settings are needed: Loculus Core already accepts requests from the browser.
Page Assist’s own documentation Set-up checked against it on 21 Nov 2026. Part of it isn’t confirmed in its documentation yet: tell us if it works for you.
Msty Studio OpenAI Chat Completions
Settings → Model Providers → Add Provider (Msty Studio 3.x, every system)
- Open Settings → Model Providers → Add Provider and choose an OpenAI-compatible provider.
- Enter the endpoint, then Fetch Models and pick loculus (or Add Custom Model → loculus).
- Optionally name the connection, then Save.
Endpoint (base URL): http://127.0.0.1:8090/v1
API key: local (only if the form asks; the server ignores it)
Models: Fetch Models → loculus (or Add Custom Model → loculus) - For Loculus Core on another computer, use its network address and start it with --host 0.0.0.0.
- Some provider types need Msty’s paid Aurum tier; the docs don’t say whether this one does.
- Msty Studio Web works too: Loculus Core already accepts requests from the browser.
Msty Studio’s own documentation Set-up checked against it on 21 Nov 2026. Part of it isn’t confirmed in its documentation yet: tell us if it works for you.
Nothing matches. Most tools that let you set an “OpenAI-compatible” address work with Loculus Core: use the address and model name from Addresses and endpoints.
#What the API supports
| Chat Completions | Responses | Anthropic Messages | |
|---|---|---|---|
| Streaming | yes | yes | yes |
| Tool calls | yes | yes, function and custom tools | yes |
| Answers matching a JSON schema | response_format | text.format | output_format |
| Reasoning effort | reasoning_effort | reasoning.effort | thinking, output_config.effort |
| Pictures in | image_url (data URLs) | input_image | image blocks (base64) |
- Conversations pick up where they left off. Each request only works on what’s new since the last: an agent’s next turn costs only its new tokens. Long prompts are also kept on disk, so after a restart a long conversation resumes in a moment.
- Several at once. On models that allow it, up to 4 requests run side by side by default (
--parallel, up to 16), so several agents, or several people, can share one Loculus Core. - Tool calls stay valid. A call always names one of the tools you offered, with every required argument, of the right types.
- The model’s own chat format. Prompts are written with the model’s own template, and its tool calls and reasoning are read in its own format, so every model answers as its makers intended.
Troubleshooting
When something goes wrong, Loculus Core says what and why, in plain words, and usually what to do about it. Find the message below, or start with a check-up of your machine.
#Start with a check-up
doctor looks over your machine the way Loculus Core sees it: your system and memory, every graphics device and whether it can run Loculus Core (and if not, what it lacks), a self-test of its GPU code, and a short speed measurement. It takes about a minute, and reads nothing of your prompts or files.
./loculus doctor .\loculus.exe doctor A healthy report shows your graphics card’s line ending runs Loculus Core and every check passed: see the example in the Quickstart. Any line that says can’t run Loculus Core names what’s missing; the messages below explain each one.
#Messages and fixes
Graphics and drivers
“Vulkan isn’t installed” vulkan loader libvulkan linux install driver
Vulkan isn't installed: Loculus Core runs on the GPU through Vulkan, and this machine has no Vulkan loader (libvulkan.so.1). Loculus Core reaches your graphics through Vulkan, which comes with your graphics driver. On Linux, install Vulkan and your GPU’s Vulkan driver, then start Loculus Core again. The last line lists your GPUs as Vulkan sees them:
sudo apt install libvulkan1 mesa-vulkan-drivers vulkan-tools # Ubuntu, Debian (AMD, Intel)
sudo dnf install vulkan-loader mesa-vulkan-drivers vulkan-tools # Fedora
sudo pacman -S vulkan-icd-loader vulkan-radeon vulkan-tools # Arch (or vulkan-intel, nvidia-utils)
vulkaninfo --summary # lists the GPUs Vulkan can see No suitable GPU? Leave out --gpu and small models run on the processor.
“No Vulkan driver for a GPU was found” driver nvidia amd intel mesa update old
No Vulkan driver for a GPU was found: Loculus Core runs on the GPU through Vulkan.
Install your GPU's Vulkan driver (NVIDIA: the NVIDIA driver, 535 or newer; AMD and Intel: Mesa's Vulkan drivers, 23 or newer, e.g. the mesa-vulkan-drivers package), then start Loculus Core again.
Or run on the CPU: leave out --gpu. Your graphics driver is missing or too old. Install the current one:
- NVIDIA: driver 535 or newer. Linux: your distribution’s NVIDIA driver (Ubuntu: Software & Updates → Additional Drivers). Windows: the GeForce Game Ready or Studio driver from nvidia.com.
- AMD: Linux: Mesa 23 or newer (Ubuntu 24.04 and later have it). Windows: AMD Software: Adrenalin Edition from amd.com.
- Intel: Linux: Mesa 23 or newer. Windows: the Intel Arc and Iris Xe graphics driver from intel.com.
NVIDIA on Linux: “its Vulkan driver didn’t start” nvidia glvnd minimal server install linux
The NVIDIA driver is installed, but its Vulkan driver didn't start: on Linux it needs the GLVND libraries, which a minimal or server install may not have. Minimal and server installs of Linux can leave out the GLVND libraries that NVIDIA’s Vulkan driver needs. Install them, then start Loculus Core again:
sudo apt install libglvnd0 libglx0 libegl1 # Ubuntu, Debian
sudo dnf install libglvnd-glx libglvnd-egl # Fedora
sudo pacman -S libglvnd # Arch “No GPU on this machine can run Loculus Core” old gpu unsupported lacks vulkan 1.3 turing rdna
No GPU on this machine can run Loculus Core. The message goes on to list each graphics device and what it lacks. Usually the driver is too old (update it as above). Some graphics are too old for Loculus Core: NVIDIA before the GeForce RTX 20 series, AMD before the Radeon RX 5000 series, and older Intel integrated graphics. See Graphics cards and drivers. Small models still run on the processor without --gpu.
“Resizable BAR is off” resizable bar rebar smart access memory bios slow loading staging
AMD Radeon RX 7800 XT: Resizable BAR is off (256 MiB of its 16 GiB in the CPU's reach): weights upload through a staging buffer (slower loading). Turning it on in the BIOS/UEFI ("Re-Size BAR Support"; AMD: "Smart Access Memory") loads faster. Your graphics card can only be reached through a small window, so models load more slowly (they run at full speed once loaded). Turn on Above 4G Decoding and Re-Size BAR Support (on AMD systems: Smart Access Memory) in your computer’s BIOS/UEFI settings. On a few cards with a very small window, Loculus Core needs this turned on before it can use the card, and says so.
Memory and context
“this needs … GiB of GPU memory, but the GPU has … free” memory vram not enough out of memory gib quantization context fit too big
this needs 18.2 GiB of GPU memory, but the GPU has 15.1 GiB free (of 16.0 GiB; 0.9 GiB in use by other programs or kept clear). Try a smaller context (--ctx), a smaller quantization of the model, or closing programs that use the GPU The model, at the context Loculus Core would give it, doesn’t fit in your graphics memory. In order of what helps most:
- Close programs that use the GPU: games, video editors, a browser with many tabs.
- Use a smaller quantization of the same model (Q4 instead of Q8, for example): see What fits your memory.
- Ask for a smaller context:
--ctx 16384. - Pick a smaller model.
Big mixture-of-experts models are the exception: when they don’t fit, Loculus Core streams their experts from your SSD and says so with a line starting experts:.
“prompt is too long” context too long tokens maximum conversation
prompt is too long: 41210 tokens > 32768 maximum What Loculus Core always keeps (the instructions and tools, everything you typed, and the latest step) is larger than the model’s context. A single long message or tool result is shortened by itself to its two ends and a map, except in requests for structured output; a raw prompt to /v1/completions is used as it is. Start Loculus Core with a larger context (--ctx 65536, if your memory allows), send less text at once, or start a new conversation.
Model files
“… can’t run: N of its files are missing” missing file encoder decoder autoencoder vae companion beside folder
FLUX.3 [klein] can't run: 1 of its files is missing.
1. Its decoder, FLUX.2's autoencoder (ae.safetensors, or flux2-vae.safetensors): put it in one of the folders below, or name it with --vae FILE. Picture and video models come in several parts, and some chat models have extras (a vision file, a drafting file). The message lists every missing part, what it is, and where it goes: download each from the model’s page and put it in the same folder as the model, or name it with the option the message gives.
“the model is split into … files” split parts 00001 gguf shards
the model is split into 3 files, and 1 is not beside the first: model-00003-of-00003.gguf (every part goes in the same folder) Large models come in numbered parts (…-00001-of-00003.gguf). Download every part into the same folder and start Loculus Core with the first.
Pictures are ignored: “pictures go in as text” vision picture image mmproj projector
pictures: this model reads pictures through its vision projector, a file of its own (a GGUF of type mmproj, such as mmproj-F16.gguf from the repository the model came from), and none projecting to its width (2048) is in ~/models or ~; put it beside the model, or name it with --mmproj FILE. Until then pictures go in as text. The model reads pictures through its vision file. Download the mmproj file from the same page as the model and put it beside the model.
“not supported yet” architecture unsupported tensor type format tokenizer load
architecture mamba not supported yet The model’s family or format isn’t one Loculus Core runs yet: see Compatibility for the list. To check any file without loading it fully:
./loculus check-load ~/models/your-model.gguf .\loculus.exe check-load $HOME\models\your-model.gguf It prints loads, or cannot load: and the reason.
Starting and connecting
The first start takes longer slow first start measuring tuning half a minute
first start: measuring this GPU for this model (about half a minute, once; later starts read it back) That’s normal. The first time it runs a model on your machine, Loculus Core measures your hardware to pick its fastest settings, and keeps the result. It measures again after a driver or system update.
“Address already in use” port in use 8090 address already 10048 98 another program
Address already in use (os error 98) Only one usage of each socket address (protocol/network address/port) is normally permitted. (os error 10048) Another program, often a Loculus Core you started earlier, is using port 8090. Stop it (Ctrl + C in its window), or start this one on another port: --port 8091. To see what holds the port:
sudo ss -ltnp 'sport = :8090' Get-Process -Id (Get-NetTCPConnection -LocalPort 8090 -State Listen).OwningProcess An app can’t connect connect refused app harness base url v1 docker host
no route for POST /v1/v1/messages Check, in order:
- Loculus Core is running and has printed
serving … on http://…. Check it answers:TerminalLinux PowerShellWindowscurl http://127.0.0.1:8090/healthInvoke-RestMethod http://127.0.0.1:8090/health - The address: OpenAI-style apps use
http://127.0.0.1:8090/v1; Anthropic-style apps (Claude Code) usehttp://127.0.0.1:8090with no/v1, which is the message above. - From another computer, Loculus Core must be started with
--host 0.0.0.0and the firewall must let port 8090 in: see Use it from another computer. - An app inside Docker reaches your computer as
http://host.docker.internal:8090, not 127.0.0.1.
Speed
Answers are slow slow speed tokens per second cpu gpu laptop battery
- Check the start-up line ends with
onand your GPU’s name. If it doesn’t, add--gpu. - A model bigger than your graphics memory runs partly from system memory, which is slower: a smaller quantization that fits is much faster. Start-up lines beginning
weights:orexperts:say when this happens. - Laptops: plug in the charger, and choose the high-performance power mode.
- Reasoning models think before they answer: lower the effort (see Reasoning models).
- Measure it: Measure your speed.
Pictures and video
A video came out as a folder of pictures ffmpeg mp4 png frames video install
ffmpeg not found (No such file or directory (os error 2)): PNG frames instead Videos are written as MP4 through ffmpeg, a free video tool. Install it, then make the video again. Through the API, the job fails with ffmpeg isn't installed here until it’s installed.
sudo apt install ffmpeg # Ubuntu, Debian
sudo dnf install ffmpeg # Fedora (with RPM Fusion enabled)
sudo pacman -S ffmpeg # Arch winget install Gyan.FFmpeg # then open a new PowerShell window “the largest picture of this shape that fits is …” picture too large size memory image 4k 8k
a 7680 x 4320 picture needs 21.4 GiB of GPU memory and the GPU has 14.2 GiB free: the largest picture of this shape that fits is 5120 x 2880 The size you asked for needs more graphics memory than is free. Use the size the message suggests, or close other programs that use the GPU. Videos step down a size by themselves and say why, with a line like 1920 x 1088: … trying 1280 x 704.
No message matches. Try another word, or ask us.
#Getting help
Still stuck? Make a report and send it to us with your question. It holds your machine’s details and the check-up’s results, nothing of your prompts or files:
./loculus doctor --json loculus-report.json .\loculus.exe doctor --json loculus-report.json Email support@loculuscore.com with the report attached, and tell us:
- the command you ran, and the model’s file name;
- what Loculus Core printed (copy it from the terminal);
- your Loculus Core version:
loculus version.
Hardware & compatibility
What Loculus Core runs on, what each part does for it, and which models suit your machine. If you’re not sure about yours, run the check-up: it tells you.
#Operating systems
One engine for every system it ships on. Linux is first; the same purchase covers each system as it arrives, on every device you sign in on.
- Linux First release
- Windows Coming next
- Android Planned
- macOS Planned
- iOS Planned
Today Loculus Core runs on 64-bit x86 PCs. The instructions on this page follow your system choice at the top, and each new system will get its own as it’s released.
#Graphics cards and drivers
Loculus Core runs AI models on your graphics card (or the graphics in your processor) through VulkanThe open graphics standard Loculus Core uses to run on AMD, NVIDIA and Intel graphics. It comes with your graphics driver. , the open graphics standard every current AMD, NVIDIA and Intel driver includes. It needs a GPU with Vulkan 1.3.
-
AMD
Radeon RX 5000 series and newer, and Ryzen processors’ Radeon graphics (Ryzen AI Max, 700M and 800M series).
Linux: Mesa 23 or newer. Windows: AMD Software: Adrenalin Edition.
Not yet: Radeon cards before the RX 5000 series, and Instinct accelerators.
-
NVIDIA
The Turing generation and newer: GeForce RTX 20 series onwards (and GTX 16), and RTX workstation cards of the same generations.
Driver 535 or newer, on Linux and Windows.
Not: cards before Turing (GeForce GTX 10 series and older).
-
Intel
Arc graphics cards and recent integrated graphics (Core Ultra).
Linux: Mesa 23 or newer. Windows: Intel’s Arc and Iris Xe graphics driver.
Older integrated graphics may lack what Loculus Core needs: the check-up says.
- Graphics card or built-in graphics? Both work. A graphics card has its own fast memory (VRAMYour graphics card’s own memory. A model runs fastest when it fits there. ); machines with unified memoryOn some computers, such as those with AMD’s Ryzen AI Max, the processor and graphics share one large pool of memory, so much bigger models fit. , like the Ryzen AI Max+ 395, share one large pool with the processor, so much bigger models fit.
- More than one GPU? Loculus Core uses the best one: a graphics card before built-in graphics, then the one with the most memory.
- Graphics cards: turn on Resizable BAR (Smart Access Memory on AMD systems) in your BIOS/UEFI settings. Models load faster with it, and a few cards need it.
- No suitable GPU? Leave out
--gpuand Loculus Core runs on the processor: fine for small models, slower for big ones. Pictures and video need a GPU.
#What fits your memory
The model has to fit in memory, with room for the conversation. As a rule of thumb, a model needs about its download size in memory, plus 10 to 20% for a long conversation:
| Your machine | Comfortably runs | For example |
|---|---|---|
| 8 GB graphics card | Models up to about 8 billion parameters on the card; bigger ones partly from system memory, more slowly | Gemma 4 E4B · Qwen3 30B-A3B · Mistral 7B |
| 16 GB graphics card | Models up to about 20 billion parameters on the card; up to 177 billion with system memory beside it | gpt-oss 20B · Gemma 4 26B-A4B · Qwen3.8 27B |
| 96–128 GB unified memory | The biggest open models: mixtures of experts with 100 to 750 billion parameters | Qwen3.8 Flash-Next · GLM 5.3 Flash · DeepSeek V4.1 Flash |
Here is how fast each model ran on the machines we test on:
Writing speed, tokens a second · GeForce RTX 3060 Ti 8 GB, 32 GB RAM, Linux
- LFM2.5 1.2BQ4_K_M 311 LFM2.5 1.2B Q4_K_M Writing 311 tokens/s · reading 3877 tokens/s First token 70 ms Memory: 0.9 GB on the card
- Llama 3.2 1BQ4_K_M 356 Llama 3.2 1B Q4_K_M Writing 356 tokens/s · reading 3669 tokens/s First token 61 ms Memory: 1.0 GB on the card
- Llama 3.2 3BQ4_K_M 148 Llama 3.2 3B Q4_K_M Writing 148 tokens/s · reading 1551 tokens/s First token 141 ms Memory: 2.4 GB on the card
- Phi-4 miniQ4_K_M 118 Phi-4 mini Q4_K_M Writing 118 tokens/s · reading 1443 tokens/s First token 143 ms Memory: 3.0 GB on the card
- Mistral 7B v0.3Q4_K_M 77.8 Mistral 7B v0.3 Q4_K_M Writing 77.8 tokens/s · reading 981 tokens/s First token 287 ms Memory: 4.4 GB on the card
- Gemma 4 E4BQ4_K_M 88.5 Gemma 4 E4B Q4_K_M Writing 88.5 tokens/s · reading 1409 tokens/s First token 199 ms Memory: 3.2 GB on the card
- GLM-4 9BQ4_K_M 55.1 GLM-4 9B Q4_K_M Writing 55.1 tokens/s · reading 965 tokens/s First token 335 ms Memory: 5.8 GB on the card
- Gemma 4 12BQ4_K_M 29.4 Gemma 4 12B Q4_K_M Writing 29.4 tokens/s · reading 588 tokens/s First token 540 ms Memory: 6.6 GB on the card + 2.2 GB system
- gpt-oss 20BMXFP4 24.4 gpt-oss 20B MXFP4 Writing 24.4 tokens/s · reading 173 tokens/s First token 2.3 s Memory: 6.2 GB on the card
- Gemma 4 26B-A4BUD-Q4_K_M 19.3 Gemma 4 26B-A4B UD-Q4_K_M Writing 19.3 tokens/s · reading 199 tokens/s First token 2.6 s Memory: 6.4 GB on the card
- Qwen3 30B-A3BUD-IQ1_S 57.1 Qwen3 30B-A3B UD-IQ1_S Writing 57.1 tokens/s · reading 293 tokens/s First token 902 ms Memory: 6.3 GB on the card
Fits on the card Part of it in system memory (slower)
Writing speed, tokens a second · Radeon RX 9070 XT 16 GB, 64 GB RAM, Windows 11
- LFM2.5 1.2BQ4_K_M 652 LFM2.5 1.2B Q4_K_M Writing 652 tokens/s · reading 18958 tokens/s First token 31 ms Memory: 0.9 GB on the card
- Llama 3.2 1BQ4_K_M 620 Llama 3.2 1B Q4_K_M Writing 620 tokens/s · reading 18155 tokens/s First token 33 ms Memory: 1.0 GB on the card
- Llama 3.2 3BQ4_K_M 254 Llama 3.2 3B Q4_K_M Writing 254 tokens/s · reading 7163 tokens/s First token 60 ms Memory: 2.3 GB on the card
- Phi-4 miniQ4_K_M 206 Phi-4 mini Q4_K_M Writing 206 tokens/s · reading 5905 tokens/s First token 58 ms Memory: 3.0 GB on the card
- Mistral 7B v0.3Q4_K_M 136 Mistral 7B v0.3 Q4_K_M Writing 136 tokens/s · reading 4341 tokens/s First token 93 ms Memory: 4.7 GB on the card
- Gemma 4 E4BQ4_K_M 153 Gemma 4 E4B Q4_K_M Writing 153 tokens/s · reading 6528 tokens/s First token 81 ms Memory: 3.2 GB on the card
- GLM-4 9BQ4_K_M 92.9 GLM-4 9B Q4_K_M Writing 92.9 tokens/s · reading 3842 tokens/s First token 126 ms Memory: 5.8 GB on the card
- Gemma 4 12BQ4_K_M 145 Gemma 4 12B Q4_K_M Writing 145 tokens/s · reading 2685 tokens/s First token 156 ms Memory: 7.9 GB on the card
- gpt-oss 20BMXFP4 197 gpt-oss 20B MXFP4 Writing 197 tokens/s · reading 5446 tokens/s First token 105 ms Memory: 11.1 GB on the card
- Gemma 4 26B-A4BUD-Q4_K_M 93.2 Gemma 4 26B-A4B UD-Q4_K_M Writing 93.2 tokens/s · reading 272 tokens/s First token 1.4 s Memory: 11.6 GB on the card + 5.3 GB system
- Qwen3.8 27BUD-Q4_K_M 20.4 Qwen3.8 27B UD-Q4_K_M Writing 20.4 tokens/s · reading 765 tokens/s First token 662 ms Memory: 12.1 GB on the card + 10.0 GB system
- Qwen3 30B-A3BUD-IQ1_S 221 Qwen3 30B-A3B UD-IQ1_S Writing 221 tokens/s · reading 4002 tokens/s First token 98 ms Memory: 9.0 GB on the card
- gpt-oss 120BMXFP4 20.9 gpt-oss 120B MXFP4 Writing 20.9 tokens/s · reading 66.9 tokens/s First token 7.7 s Memory: 11.5 GB on the card + 45.2 GB system
- Qwen3.8 Flash-Next 177B-A3BUD-Q2_K_XL 29.8 Qwen3.8 Flash-Next 177B-A3B UD-Q2_K_XL Writing 29.8 tokens/s · reading 390 tokens/s First token 4.1 s Memory: 11.8 GB on the card + 20.2 GB system
Fits on the card Part of it in system memory (slower)
Writing speed, tokens a second · Ryzen AI Max+ 395, 96 GB unified memory, Linux
- LFM2.5 1.2BQ4_K_M 283 LFM2.5 1.2B Q4_K_M Writing 283 tokens/s · reading 9206 tokens/s First token 41 ms Memory: 1.1 GB
- Llama 3.2 1BQ4_K_M 276 Llama 3.2 1B Q4_K_M Writing 276 tokens/s · reading 8667 tokens/s First token 42 ms Memory: 1.0 GB
- Llama 3.2 3BQ4_K_M 101 Llama 3.2 3B Q4_K_M Writing 101 tokens/s · reading 3043 tokens/s First token 117 ms Memory: 2.4 GB
- Phi-4 miniQ4_K_M 85.0 Phi-4 mini Q4_K_M Writing 85.0 tokens/s · reading 2652 tokens/s First token 110 ms Memory: 2.7 GB
- Mistral 7B v0.3Q4_K_M 55.1 Mistral 7B v0.3 Q4_K_M Writing 55.1 tokens/s · reading 1539 tokens/s First token 218 ms Memory: 4.7 GB
- Gemma 4 E4BQ4_K_M 70.3 Gemma 4 E4B Q4_K_M Writing 70.3 tokens/s · reading 2497 tokens/s First token 150 ms Memory: 3.2 GB
- GLM-4 9BQ4_K_M 37.7 GLM-4 9B Q4_K_M Writing 37.7 tokens/s · reading 1464 tokens/s First token 289 ms Memory: 5.6 GB
- Gemma 4 12BQ4_K_M 71.3 Gemma 4 12B Q4_K_M Writing 71.3 tokens/s · reading 996 tokens/s First token 397 ms Memory: 7.7 GB
- gpt-oss 20BMXFP4 79.4 gpt-oss 20B MXFP4 Writing 79.4 tokens/s · reading 2324 tokens/s First token 205 ms Memory: 11.1 GB
- Gemma 4 26B-A4BUD-Q4_K_M 97.4 Gemma 4 26B-A4B UD-Q4_K_M Writing 97.4 tokens/s · reading 1685 tokens/s First token 247 ms Memory: 16.5 GB
- Qwen3.8 27BUD-Q4_K_M 27.5 Qwen3.8 27B UD-Q4_K_M Writing 27.5 tokens/s · reading 435 tokens/s First token 1.0 s Memory: 16.3 GB
- Nemotron 3.5 Lightning 30B-A3BUD-Q4_K_M 79.9 Nemotron 3.5 Lightning 30B-A3B UD-Q4_K_M Writing 79.9 tokens/s · reading 2156 tokens/s First token 291 ms Memory: 24.3 GB
- Qwen3 30B-A3BUD-IQ1_S 110 Qwen3 30B-A3B UD-IQ1_S Writing 110 tokens/s · reading 1783 tokens/s First token 185 ms Memory: 8.8 GB
- gpt-oss 120BMXFP4 56.5 gpt-oss 120B MXFP4 Writing 56.5 tokens/s · reading 1041 tokens/s First token 459 ms Memory: 59.2 GB
- Qwen3.8 Flash-Next 177B-A3BUD-Q2_K_XL 61.9 Qwen3.8 Flash-Next 177B-A3B UD-Q2_K_XL Writing 61.9 tokens/s · reading 763 tokens/s First token 629 ms Memory: 52.0 GB
- GLM 5.3 FlashUD-IQ1_S 15.8 GLM 5.3 Flash UD-IQ1_S Writing 15.8 tokens/s · reading 211 tokens/s First token 8.6 s Memory: 74.2 GB
- DeepSeek V4.1 FlashUD-IQ1_S 17.6 DeepSeek V4.1 Flash UD-IQ1_S Writing 17.6 tokens/s · reading 130 tokens/s First token 11.4 s Memory: 74.9 GB
Show as a table
| Model | Writing (tokens/s) | Reading (tokens/s) | Memory |
|---|---|---|---|
LFM2.5 1.2B Q4_K_M | 311 | 3877 | 0.9 GB on the card |
Llama 3.2 1B Q4_K_M | 356 | 3669 | 1.0 GB on the card |
Llama 3.2 3B Q4_K_M | 148 | 1551 | 2.4 GB on the card |
Phi-4 mini Q4_K_M | 118 | 1443 | 3.0 GB on the card |
Mistral 7B v0.3 Q4_K_M | 77.8 | 981 | 4.4 GB on the card |
Gemma 4 E4B Q4_K_M | 88.5 | 1409 | 3.2 GB on the card |
GLM-4 9B Q4_K_M | 55.1 | 965 | 5.8 GB on the card |
Gemma 4 12B Q4_K_M | 29.4 | 588 | 6.6 GB on the card + 2.2 GB system |
gpt-oss 20B MXFP4 | 24.4 | 173 | 6.2 GB on the card |
Gemma 4 26B-A4B UD-Q4_K_M | 19.3 | 199 | 6.4 GB on the card |
Qwen3 30B-A3B UD-IQ1_S | 57.1 | 293 | 6.3 GB on the card |
| Model | Writing (tokens/s) | Reading (tokens/s) | Memory |
|---|---|---|---|
LFM2.5 1.2B Q4_K_M | 652 | 18958 | 0.9 GB on the card |
Llama 3.2 1B Q4_K_M | 620 | 18155 | 1.0 GB on the card |
Llama 3.2 3B Q4_K_M | 254 | 7163 | 2.3 GB on the card |
Phi-4 mini Q4_K_M | 206 | 5905 | 3.0 GB on the card |
Mistral 7B v0.3 Q4_K_M | 136 | 4341 | 4.7 GB on the card |
Gemma 4 E4B Q4_K_M | 153 | 6528 | 3.2 GB on the card |
GLM-4 9B Q4_K_M | 92.9 | 3842 | 5.8 GB on the card |
Gemma 4 12B Q4_K_M | 145 | 2685 | 7.9 GB on the card |
gpt-oss 20B MXFP4 | 197 | 5446 | 11.1 GB on the card |
Gemma 4 26B-A4B UD-Q4_K_M | 93.2 | 272 | 11.6 GB on the card + 5.3 GB system |
Qwen3.8 27B UD-Q4_K_M | 20.4 | 765 | 12.1 GB on the card + 10.0 GB system |
Qwen3 30B-A3B UD-IQ1_S | 221 | 4002 | 9.0 GB on the card |
gpt-oss 120B MXFP4 | 20.9 | 66.9 | 11.5 GB on the card + 45.2 GB system |
Qwen3.8 Flash-Next 177B-A3B UD-Q2_K_XL | 29.8 | 390 | 11.8 GB on the card + 20.2 GB system |
| Model | Writing (tokens/s) | Reading (tokens/s) | Memory |
|---|---|---|---|
LFM2.5 1.2B Q4_K_M | 283 | 9206 | 1.1 GB |
Llama 3.2 1B Q4_K_M | 276 | 8667 | 1.0 GB |
Llama 3.2 3B Q4_K_M | 101 | 3043 | 2.4 GB |
Phi-4 mini Q4_K_M | 85.0 | 2652 | 2.7 GB |
Mistral 7B v0.3 Q4_K_M | 55.1 | 1539 | 4.7 GB |
Gemma 4 E4B Q4_K_M | 70.3 | 2497 | 3.2 GB |
GLM-4 9B Q4_K_M | 37.7 | 1464 | 5.6 GB |
Gemma 4 12B Q4_K_M | 71.3 | 996 | 7.7 GB |
gpt-oss 20B MXFP4 | 79.4 | 2324 | 11.1 GB |
Gemma 4 26B-A4B UD-Q4_K_M | 97.4 | 1685 | 16.5 GB |
Qwen3.8 27B UD-Q4_K_M | 27.5 | 435 | 16.3 GB |
Nemotron 3.5 Lightning 30B-A3B UD-Q4_K_M | 79.9 | 2156 | 24.3 GB |
Qwen3 30B-A3B UD-IQ1_S | 110 | 1783 | 8.8 GB |
gpt-oss 120B MXFP4 | 56.5 | 1041 | 59.2 GB |
Qwen3.8 Flash-Next 177B-A3B UD-Q2_K_XL | 61.9 | 763 | 52.0 GB |
GLM 5.3 Flash UD-IQ1_S | 15.8 | 211 | 74.2 GB |
DeepSeek V4.1 Flash UD-IQ1_S | 17.6 | 130 | 74.9 GB |
#Machines we test on
Releases are measured on these machines before they ship, and each figure on the Performance page comes from one of them.
-
AMD Strix Halo
- System
- Linux (Ubuntu 24.04)
- Processor
- AMD Ryzen AI Max+ 395
- Graphics
- Radeon 8060S (integrated)
- Memory
- 96 GB unified, shared by CPU and GPU
-
AMD Radeon RX 9070 XT
- System
- Windows 11
- Processor
- AMD Ryzen Threadripper 3960X
- Graphics
- AMD Radeon RX 9070 XT, 16 GB
- Memory
- 64 GB system memory
-
NVIDIA GeForce RTX 3060 Ti
- System
- Windows 11
- Processor
- AMD Ryzen 5 5600X
- Graphics
- NVIDIA GeForce RTX 3060 Ti, 8 GB
- Memory
- 32 GB system memory
-
NVIDIA GeForce RTX 3060 Ti
- System
- Linux (Ubuntu 24.04)
- Processor
- AMD Ryzen 5 5600X
- Graphics
- NVIDIA GeForce RTX 3060 Ti, 8 GB
- Memory
- 32 GB system memory
Making hardware we should test? See Hardware partners.
#Models and formats
Loculus Core runs open models from their GGUF files, and reads everything it needs from the file, so new models of a supported family work as they’re published.
- Qwen3.8 (27B, Flash-Next)
- DeepSeek V4.1
- GLM-4 and 5.3
- gpt-oss
- Gemma 2, 3 and 4
- Llama
- Mistral
- Nemotron 3.5
- Phi-3 and 4
- Qwen2 and 3
- Granite
- SmolLM3
- OLMo 2
- LFM2 and 2.5
Pictures: Z-Image-Turbo and FLUX.3 [klein]. Video: LTX-2.5, with its sound, and Wan 2.2. Quantizations from 1 to 16 bits (Q2_K to Q8_0, the IQ formats, MXFP4, F16, BF16 and more), single files or split. The full lists, model by model: Compatibility.