You’ve set up OpenCode with Ollama on your laptop. Now the real question: which model should you run?
Most “best model” lists are tested on desktops with big graphics cards. So I tested the two models most people with an ordinary laptop will try first, qwen3.5:4b and qwen3.5:9b, on my own 16 GB laptop, on a real project, with the same question.
The short version: the 9b read the project and gave an accurate, complete answer. The 4b answered faster, but it never opened a single file. It guessed.
New to the pieces? What is OpenCode explains the agent, and OpenCode vs Ollama explains how the two fit together.
The short answer
| Your laptop | Run | Why |
|---|---|---|
| 16 GB memory | qwen3.5:9b |
Reads your files before answering, and its answers were accurate. Slow on a laptop without a graphics card, but right. |
| 8 GB memory | qwen3.5:4b |
The one that fits. In my tests it didn’t read files even when told to, so use it for questions about code you show it, and check every answer. |
My setup
| Laptop | HP Pavilion Aero 13, AMD Ryzen 7 7735U |
| Memory | 16 GB (15.2 GB usable) |
| Graphics | Integrated AMD Radeon only, so Ollama ran on the CPU |
| OS | Windows, PowerShell |
| Ollama | 0.40.19 |
| OpenCode | 1.19.6 |
| Context length | 32,768 tokens |
| Models | qwen3.5:4b (3.3 GB download), qwen3.5:9b (6.6 GB download) |
No graphics card is the important line. Most people’s laptops look like this, and everything below runs on the processor alone. A laptop with a graphics card, or an Apple silicon Mac, will be several times faster.
First, the error you’ll probably hit
The first time I asked OpenCode a question, it failed straight away with:
The prompt is longer than the context length available
Here’s why. OpenCode sends about 12,000 tokens before you even type: its own instructions plus the list of tools the model can use. My 4b session below used 12,195 tokens without reading a single file. But on a laptop without a graphics card, Ollama sets the context length to just 4,096 tokens by default. The startup log even says so: vram-based default context total_vram="0 B" default_num_ctx=4096. The prompt simply doesn’t fit.
The fix: stop every Ollama process (including the tray app), then start the server yourself with a bigger context. In PowerShell, Terminal 1:
Get-Process ollama* -ErrorAction SilentlyContinue | Stop-Process -Force
$env:OLLAMA_CONTEXT_LENGTH="32768"
ollama serve
Leave that window open. In the server config line near the top of the log, check that it says OLLAMA_CONTEXT_LENGTH:32768. Then in Terminal 2:
cd mcp-studio
ollama launch opencode
On Command Prompt, use set OLLAMA_CONTEXT_LENGTH=32768 instead of the $env: line. On macOS or Linux, quit the Ollama app and run OLLAMA_CONTEXT_LENGTH=32768 ollama serve. The laptop guide has the full setup, and how to make the setting permanent.
ollama launch opencode shows a model picker. Choose your local model there, not one of the :cloud ones at the top, which run on Ollama’s servers.

Test 1: raw speed
Before OpenCode, I timed each model on a plain chat question with thinking switched off:
ollama run qwen3.5:4b --verbose --think=false "Explain what a Java interface is in 3 sentences."
ollama run qwen3.5:9b --verbose --think=false "Explain what a Java interface is in 3 sentences."
The number that matters is eval rate: how many tokens per second the model writes.
qwen3.5:4b |
qwen3.5:9b |
|
|---|---|---|
| Writing speed (eval rate) | 9.5 tokens/s | 5.8 tokens/s |
| Time to load into memory (first run) | already loaded | 19.8 s |


The 4b writes about 1.6 times faster. A comfortable reading speed is around 5 to 10 tokens per second, so both are usable for chat. A coding agent is a different story, as the next test shows.
Test 2: the real job in OpenCode
I opened my open-source project, MCP Studio, in OpenCode and asked both models the same question, each in a fresh session:
explain about this mcp-studio project, and list the features it does have.
To answer this well, the model has to look: list the folders, read the README and package.json, and only then explain.
qwen3.5:9b: it read the project
The 9b did exactly what a good teammate would do. It listed the top-level folders, read README.md and package.json, listed the apps folder, and only then wrote its answer.

The answer was accurate and complete: it explained that MCP Studio teaches you to build an MCP server, client and host in the browser, named the three course chapters, the MCP methods the core package implements, the four blueprints (Hello World, Database, File Server, GitHub), the coach, and the dev setup (Vitest, TypeScript, Node 20+, deploys to Vercel). Everything it said was true.

The catch is time: 14 minutes 58 seconds. With 15,000 tokens of context to work through, its writing speed dropped from 5.8 tokens/s in plain chat to about 3 tokens/s. The final answer alone (922 tokens) took about 5 minutes.
qwen3.5:4b: it guessed
The 4b thought for 7 seconds and answered. It didn’t list a folder or read a single file. Look at its wording: the project “appears to be”, it “likely serves as”, key features “typically include”. It was guessing from the folder name.

The features it listed (server management, a configuration UI, debugging tools) sound reasonable, but they aren’t what MCP Studio does. And it still took 5 minutes 41 seconds, because even with no files read, it had to work through OpenCode’s 12,000-token starting prompt on the CPU.
Side by side
qwen3.5:4b |
qwen3.5:9b |
|
|---|---|---|
| Opened files with tools? | No | Yes: listed folders, read README.md and package.json |
| Answer | Generic guesses, mostly wrong | Accurate and complete |
| Total time | 5 min 41 s | 14 min 58 s |
| Context used | 12,195 tokens (37% of 32K) | 15,686 tokens (48% of 32K) |
Test 3: telling them exactly which files to read
Maybe the 4b just needed clearer instructions? I started a fresh session for each model and gave them both the same, more direct prompt:
Read README.md and package.json, then explain..
qwen3.5:4b: it said it would read them, then didn’t
The 4b replied “I’ll read both files to help you understand the project structure.” and stopped. There’s no Read line under it: it described the tool call instead of making it. When I typed explain, it answered “Based on these files, this is an MCP Studio project…”, but it had never opened them.
The context counter gives it away: 12,099 tokens, the same as OpenCode’s starting prompt on its own. If a README had been read, that number would have gone up.

This is the most common way small models fail as agents: they talk about using a tool instead of using it.
qwen3.5:9b: it read both files and got it right
Same prompt, the 9b went straight to work: Read README.md, Read package.json, then an answer that was accurate down to the details: the live site, the MCP spec version it implements, the MIT license, the server, client and host it teaches, the folder structure, and the commands to run it locally. Its context grew to 14,687 tokens, because the two files were really read.

| Same direct prompt | qwen3.5:4b |
qwen3.5:9b |
|---|---|---|
| Read the files? | No, only said it would | Yes, both |
| Context afterwards | 12,099 tokens (unchanged) | 14,687 tokens |
| Answer | Vague, and claims to be “based on these files” | Accurate and detailed |
Why it sits silent for minutes before thinking
On both models, every first prompt in a session sat for minutes before “Thinking…” even appeared. The 4b’s first reply above took 5 minutes 4 seconds, but only 3.8 seconds of that was thinking.
The rest was the model reading the prompt. Before it can write a single word, it has to process everything OpenCode sends: about 12,000 tokens of instructions and tool descriptions. On my CPU the 9b reads roughly 22 to 30 tokens a second, so that’s several minutes of silence before anything happens.
Now look at the second prompt in the same session: 15.1 seconds. Ollama keeps what it has already read (the KV cache), so the second time it only had to read the one new word, explain.
| Time | Thinking | |
|---|---|---|
| First prompt in the session | 5 min 4 s | 3.8 s |
| Second prompt, same session | 15.1 s | 3.4 s |
Three things make you pay that first-prompt cost again:
- Starting a new session (
/new). Everything is read from scratch. Keep related questions in one session. - The model unloading. Ollama unloads a model after 5 idle minutes by default. Start the server with
$env:OLLAMA_KEEP_ALIVE="-1"(next to the context setting) to keep it loaded until you stop the server. - Restarting Ollama. The cache lives in memory, so it’s gone after a restart.
What this means for you
On 16 GB, use the 9b. A wrong answer in 6 minutes is worse than a right one in 15, because you’d have to check everything the 4b says yourself. Start the task, go make a cup of tea, and come back to an answer you can trust.
On 8 GB, the 4b is the one that fits, but go in with low expectations. The 9b’s 6.6 GB download plus a 32K context and Windows itself is too much for 8 GB. The 4b, at 3.3 GB, leaves room. But in my tests it didn’t read files on its own, and it didn’t read them when I named them either. Use it as a helper for code it can see: questions about a file you have open, explaining an error you paste in, writing a small function. For anything that needs the agent to explore your project, you need the 9b or bigger, or a cloud model.
Watch for the warning signs of guessing. If an answer has no tool calls above it (no Read, no listed folders) and is full of “appears to”, “likely” and “typically”, the model didn’t look. Another quick check: the context number in OpenCode’s side panel. If it didn’t grow, nothing was read.
Want it faster? A machine with a graphics card or an Apple silicon Mac makes a big difference. On my laptop, the Ollama log also said it had skipped the integrated Radeon graphics (dropping integrated GPU; to enable, set OLLAMA_IGPU_ENABLE=1). I haven’t tested that setting yet; it’s next on my list.
Common questions
Why does OpenCode need such a big context when my question is short? Because your question is the smallest part. OpenCode adds its instructions and its tool list (about 12,000 tokens) to every request, then every file the model reads, then the conversation so far. My 9b session reached 15,686 tokens from one question.
Is 32,768 tokens enough? For one question like this, yes: the 9b used under half of it. For longer sessions with several files, Ollama recommends 64,000 or more if your memory allows. On 16 GB without a graphics card, 32K is a sensible start.
Why didn’t the 4b use the tools? Small models are weaker at using tools. It had the same tools as the 9b, but it answered from what it already “knew”, and even when I named the files, it only said it would read them. That’s the main reason to pick the 9b if you have 16 GB.
Why is the first prompt so slow, and the next one fast?
The first prompt has to read OpenCode’s whole 12,000-token setup; later prompts in the same session reuse it. In my test: 5 minutes for the first reply, 15 seconds for the next. Stay in one session, and set OLLAMA_KEEP_ALIVE=-1 so the model doesn’t unload.
Should I try other models?
Yes, if you have the memory. On 16 GB, gemma4:12b (shown as about 11 GB in the picker) is worth a try next. Check for the tools badge on ollama.com first: without it, OpenCode can’t use the model.
Key takeaways
- Raise the context first. OpenCode needs about 12,000 tokens before you type, and Ollama gives a laptop without a graphics card only 4,096. Start
ollama servewithOLLAMA_CONTEXT_LENGTH=32768. - 16 GB:
qwen3.5:9b. It read the project and was right. On CPU, expect minutes, not seconds. - 8 GB:
qwen3.5:4b. It fits, but it didn’t read files even when told to. Use it for code it can see, and check its answers. - The first prompt is the slow one. 5 minutes, then 15 seconds for the next one in the same session. Don’t
/newfor every question. - Check for tool calls. No
Readin the transcript means the answer is a guess.
Next: the full setup, step by step, in OpenCode + Ollama on your own laptop, or learn the agent itself in the OpenCode beginner’s tutorial.
Comments