Translation Providers
Choose between local models (Ollama, LM Studio) and cloud APIs, and tune how translation works.
1. Available Providers
XianScan works with any OpenAI-compatible API. These providers are built in; the default is Ollama with qwen3.5:9b.
To change provider: Settings -> AI Translation Providers -> Switch Provider, enter the API Key (cloud only) and Model, click Test Connection, then Save & Set Active. Local providers (Ollama, LM Studio, or any localhost address) need no key.
When you change a cloud provider's Endpoint Base URL, enter the API key again in the same save. A saved key is never sent to a new address.
DeepSeek
Google AI Studio
Groq
Ollama
DEFAULTLM Studio
OpenAI
OpenRouter
Custom
2. Setting Up Ollama
- Install Ollama. On Windows and macOS it runs in the background after installing; on a Linux server, start it with
ollama serve. - Download a model that fits your GPU:
ollama pull qwen3.5:4b # 4 to 6 GB of GPU memory, or CPU
ollama pull qwen3.5:9b # 8 to 12 GB (XianScan's default)
ollama pull qwen3.5:27b # 16 GB or more
- In XianScan, open Settings -> AI Translation Providers, choose Ollama (Local), and set the Model to the one you downloaded. The Endpoint Base URL is
http://localhost:11434/v1. - Click Test Connection.
No strong GPU? Ollama can also run models in Ollama's cloud with a free account. Run ollama signin, then ollama pull gemma4:cloud, and set the model to gemma4:cloud. Your pages are still processed locally; only the text is sent to Ollama's servers.
3. Dialogue Context
To keep names, pronouns and the flow of conversation consistent, XianScan sends the recent dialogue from previous pages along with each page. Empty pages are skipped, and at the start of a chapter it looks back into the previous chapter.
Set how many pages it looks back with Sliding Dialogue Context in Settings -> AI Translation Providers -> Inference & Sampling: Off, 1 to 6 pages, or Custom. The default is 4. More context helps consistency but makes each request longer and slower.
4. Reasoning, Output Length and Sampling
Also in Inference & Sampling:
- Reasoning effort: for models that can "think" first (DeepSeek-R1, OpenAI o-series, Qwen with thinking). Choose None, Minimal, Low, Medium, High, Max or Auto, or type a custom value. For Ollama it simply turns thinking on or off. The model's thinking never ends up in the speech bubbles.
- Max output tokens: default 4,096. XianScan raises it automatically for pages with a lot of text, and doubles it when it retries a page.
- Temperature (default 0.2), Top-P, frequency and presence penalty: lower temperature gives more literal, consistent translations. Each can be switched off to use the provider's own default.