Run a local AI companion on Windows with Ollama
Install Ollama, download a model, and wrap it in a Modelfile with a character system prompt, temperature and context size. Based on the author's RTX 4070 Super setup.
Verification
- Test environment
- Unknown
- Tested on
- Unknown
- Last updated
- 2026-11-20
With a reasonably capable gaming PC (a desktop, or a well-equipped laptop) you can run an AI companion entirely on your own machine. This guide follows the author's setup: an RTX 4070 Super with 12 GB of VRAM and 32 GB of RAM. On that hardware the largest practical model was deepseek-r1:32b (32B = 32 billion parameters); smaller models, such as a 14B Qwen model, also work for character chat. Output on that machine was slow, roughly 1–3 Chinese characters per second, with heavy memory use. Your speed will differ, and larger models or longer contexts need more memory.
1. Install Ollama and download a model
Install the Windows version of Ollama and keep several dozen gigabytes free for model files. Open Command Prompt or PowerShell and run:
ollama run deepseek-r1:32b
Ollama downloads the model and drops you into a plain chat. Leave it with /bye (or Ctrl+D).
2. Write a Modelfile with your character
Create a plain-text file named prompts (make sure your editor doesn't add .txt) containing:
FROM deepseek-r1:32b
SYSTEM """
You are a cheerful catgirl character. Stay in character during role-play.
End every reply with "meow~".
"""
PARAMETER temperature 0.7
PARAMETER num_ctx 8192
FROMis the model you downloaded; change it if you use another.SYSTEMis the character's system prompt: personality, speaking style and rules.temperaturearound 0.7–0.8 works well: lower is more predictable, higher more creative, and above 1 the model tends to ramble.num_ctxis the context size. 8192 tokens keeps VRAM use manageable; a long character prompt eats into it, so a small model can afford a larger value.
3. Build and run your companion
In the folder containing prompts, run:
ollama create nya-r1 -f prompts
ollama run nya-r1
nya-r1 is just a name; pick any. The model now answers in character every time.
Trade-offs
Running locally keeps your conversations on your own machine and gives you full control of the configuration, with no hosted platform involved. The costs are slow output on consumer hardware and smaller models that are noticeably less capable than hosted frontier services.
Adapted from the XMLans blog: Run a Local AI Companion on Windows with Ollama (Chinese original: 超简单教你自己部署本地AI女友).
Sources
- 超简单教你自己部署本地AI女友(星梦博客)www
.xmlans .com (opens in a new tab) · checked 2026-11-20 - Run a Local AI Companion on Windows with Ollama (XMLans blog)en
.xmlans .com (opens in a new tab) · checked 2026-11-20 - Ollama Modelfile referencedocs
.ollama .com (opens in a new tab) · checked 2026-11-20