Skip to content

Deploy DeepSeek-R1-0528: Open Source Reasoning Model Guide

Deploy the open source reasoning model DeepSeek-R1-0528 locally with Ollama. Real VRAM numbers, install commands, and fixes for the tool-calling trap.

7 min readIntermediate

Here’s the thing nobody mentions upfront: the model you download when you type ollama run deepseek-r1:32b isn’t actually DeepSeek-R1. It’s a Qwen2.5 model fine-tuned on large-scale reasoning traces generated BY R1. The distill family is six dense models trained on R1 outputs, using base models from Alibaba’s Qwen 2.5 (four variants) and Meta’s Llama 3 (two variants). Ollama’s tag naming hides this completely.

This guide covers deploying the open source reasoning model DeepSeek-R1 – both the right distill for your hardware and the full R1-0528 if you have serious GPUs. We skip the marketing and get to commands, VRAM numbers, and the gotchas that break agent frameworks.

Which version are you actually deploying?

Three things get called “DeepSeek-R1” and confusing them wastes hours.

  • DeepSeek-R1 (original): released January 20, 2025, 671B total parameters with 37B activated per forward pass, MoE architecture built on DeepSeek-V3-Base, 128K context window, MIT license – commercial use permitted.
  • DeepSeek-R1-0528 (current): released May 28, 2025 on Hugging Face, 685B parameters. Described as a “minor” update, but the official API changelog shows AIME 2025 Pass@1 jumping from 70.0 to 87.5 and substantially lower hallucination rates on complex tasks.
  • DeepSeek-R1-Distill-*: six smaller dense models (1.5B, 7B, 8B, 14B, 32B, 70B) that you can actually run on one GPU. These are what Ollama serves by default.

If you’re deploying locally on consumer hardware, you’re deploying a distill. Period. The full model needs roughly 1.2 TB of RAM to run without quantization (per a community benchmark post from Manu Borrero) – that’s a small server rack, not a workstation.

System requirements (pick your VRAM tier)

Distill choice is a VRAM equation, not a preference. Here’s what fits where, all at Q4_K_M quantization (the practical default) based on mid-2025 testing from llmhardware.io:

Model Approx VRAM (Q4) File size Example GPU
deepseek-r1:1.5b ~2 GB ~1.1 GB Any modern iGPU or CPU
deepseek-r1:7b ~5.5 GB ~4.7 GB RTX 4060 8GB
deepseek-r1:14b ~8.5 GB ~9 GB RTX 4070 12GB
deepseek-r1:32b ~17.5 GB ~18-20 GB RTX 4090 24GB
deepseek-r1:70b ~36.5 GB ~40 GB Mac Studio M4 Max 64GB or 2× 3090

The 32B at Q4_K_M is a tight fit on 24 GB once KV cache lands on top. For long reasoning chains – 8K+ output tokens – that headroom matters. The 7B fits on cards most people already own; the 14B is the practical middle ground for a dedicated AI workstation.

What’s still an open question: how much reasoning quality degrades as you compress from 32B to 14B on tasks outside math and code. The AIME benchmarks favor the 32B clearly, but for code review or document summarization, the gap is less documented. Worth testing against your actual workload before committing to the larger VRAM spend.

OS requirements: Linux (Ubuntu 20.04+), macOS 12+, or Windows 10/11. Disk: 5-40 GB depending on model. RAM: at least 16 GB system RAM even with GPU offload enabled.

Install via Ollama

On Linux, one line:

curl -fsSL https://ollama.com/install.sh | sh

On macOS, use Homebrew (brew install ollama) or the official installer from ollama.com/download. Windows: grab the installer from the same page.

Start the server and pull your chosen distill:

# start Ollama in the background
ollama serve &

# pull the 14B distill (adjust to your VRAM tier)
ollama pull deepseek-r1:14b

# run it
ollama run deepseek-r1:14b

First pull takes a while – the 14B model is roughly 9 GB. You’ll drop into a chat prompt when it finishes.

First-time configuration (the part most guides skip)

Ollama defaults to temperature 0.8. The official DeepSeek README recommends 0.5-0.7 (0.6 ideal). Run at 0.8 and R1 produces endless repetitions or incoherent output – the docs say so explicitly, and Ollama won’t apply the correction unless you push it via Modelfile or the API.

There’s a second setting that contradicts standard Ollama patterns: the official recommendation says to avoid system prompts entirely and put all instructions inside the user prompt. LangChain users especially hit this – their standard chain template splits context into a system message, which R1 will either ignore or hallucinate around.

Create a Modelfile to bake these settings in:

# Save as: Modelfile
FROM deepseek-r1:14b
PARAMETER temperature 0.6
PARAMETER top_p 0.95
PARAMETER num_ctx 16384

Then register your custom model:

ollama create r1-tuned -f Modelfile
ollama run r1-tuned

Pro tip: For math problems, append "put your final answer within boxed{}" to your prompt – directly from the official DeepSeek usage guide. It fixes the common miss where R1 gets the right number but buries it mid-sentence inside the chain-of-thought.

Verify the install

ollama --version
ollama list # should show deepseek-r1:14b
curl http://localhost:11434/api/generate -d '{
 "model": "deepseek-r1:14b",
 "prompt": "What is 25 * 47? Think step by step.",
 "stream": false,
 "options": {"temperature": 0.6}
}'

The response contains <think>...</think> blocks before the final answer. That’s the visible chain-of-thought – strip these tags in your application layer if you only want the conclusion.

Common errors and real fixes

1. “connectex: No connection could be made” on Windows. Reported in Ollama GitHub issue #8565 – pulling fails with dial tcp 127.0.0.1:11434: connectex: No connection could be made because the target machine actively refused it. The Ollama service isn’t running. On Windows, open the Ollama app from the Start menu (it lives in the system tray), or run ollama serve in a separate terminal before pulling.

2. “does not support tools (status 400)” with LangChain or agent frameworks. The catch: the distilled DeepSeek-R1 models on Ollama return does not support tools when any tool-calling schema is passed – this breaks browser-use, LangChain’s OpenAI tool-calling adapter, and most agent frameworks (confirmed in GitHub issues ollama/ollama#8517 and browser-use#486). No fix at the Ollama level exists yet. Workaround: prompt R1 to produce JSON directly and parse it yourself, or route tool calls through a Qwen2.5-Instruct proxy and use R1 only for the reasoning step.

3. Random gibberish or endless repetition. Almost always the temperature problem covered above – Ollama’s default 0.8 pushes R1 past its stable output range. Set temperature to 0.6 via Modelfile (instructions above). If repetition persists after correcting temperature, check that you’re pulling the plain deepseek-r1 tag rather than any -zero variant.

Upgrade and uninstall

No formal migration path – just pull the new tag:

# check current models
ollama list

# pull a newer distill when Ollama publishes it
ollama pull deepseek-r1:14b

# remove an old model to reclaim disk
ollama rm deepseek-r1:7b

Full uninstall on Linux: sudo rm -rf /usr/local/bin/ollama ~/.ollama. On macOS: delete the app and remove ~/.ollama. Model weights live in that directory and can easily exceed 50 GB if you’ve been experimenting.

The research context (worth 5 minutes)

R1’s contribution isn’t matching o1’s benchmark scores – it’s showing how. The arXiv paper (2501.12948), later published in Nature, makes a specific claim: reasoning behavior can be incentivized in LLMs purely through reinforcement learning using Group Relative Policy Optimization (GRPO), with no supervised reasoning trajectories at all. That’s the interesting part – not the leaderboard position, but that the reasoning capability wasn’t hand-engineered.

The six distills inherit that reasoning capability at a fraction of the compute. The 32B Qwen-based distill reached 72.6% on AIME 2024, compared to OpenAI o1-mini’s 63.6%, and fits on a single RTX 4090. For most local deployments, that’s the target: reasoning quality jumps over o1-mini at consumer GPU price.

FAQ

Can I run the full 671B DeepSeek-R1 locally?

No, not on a single machine. The full model needs roughly 1.2 TB of RAM unquantized. Multi-node GPU clusters or the DeepSeek API are your options.

Which distill should I pick if I have an RTX 4090?

Start with deepseek-r1:32b – it fits at Q4 with about 6.5 GB headroom for KV cache (24 GB minus the ~17.5 GB model footprint). Reasoning quality on math and code is close to the full R1. One scenario where you’d drop to the 14B: running long reasoning chains where output tokens exceed 8K. That KV cache headroom fills up fast during extended chain-of-thought generation, and OOM crashes mid-reasoning are unpleasant to debug. For short to medium tasks, stick with 32B.

Why does the model produce visible <think> blocks?

Common misconception: it’s not a formatting bug. That’s the chain-of-thought – the model reasoning before committing to an answer, which is the point of a reasoning model. Strip <think>...</think> with a regex in your app layer if you only want the final output.

Next action: check your GPU’s VRAM with nvidia-smi (or About This Mac on Apple Silicon), pick the matching row from the table above, and run the pull command. You’ll have R1 answering questions in under 15 minutes.