DeepSeek Harness, dsh for short, is DeepSeek’s open-source agent: it reads and edits files, runs commands and keeps a plan, from a desktop app or a web interface. It is built to use DeepSeek’s own API, but it can also talk to any OpenAI-compatible server, which includes Ollama, LM Studio and llama.cpp running on your own machine.
DeepSeek’s documentation never names those local servers, so this guide fills the gap from the parts it does document: how to install Harness, how to point it at a local model, the context setting that matters most, and the permission and telemetry defaults worth knowing before you let an agent loose. BFWR has not run Harness; everything here comes from DeepSeek’s repository, documentation and terms, and the example configuration is assembled by us from documented fields.
Quick answer
- What it is: an MIT-licensed agent harness from DeepSeek, at about 260,000 GitHub stars on 24 October. It is a developer preview: every release so far is alpha or release-candidate.
- Install: desktop apps for Apple-silicon Macs and 64-bit Windows, or
npx @deepseek-ai/dsh webon any system with Node.js 24.9 or newer. - Local models: add a “Custom model API” in Settings → Models, pointed at
http://localhost:11434/v1for Ollama. No API key is needed. - The setting to change: Harness assumes a 1,000,000-token context for any model it does not know, so set the real context window for your local model.
- Defaults: file writes are limited to the workspace and risky actions ask first. Pressing feedback sends the whole session to DeepSeek unless you turn telemetry off.
What DeepSeek Harness is
The README describes it as “an open-source agent harness developed by DeepSeek AI”, built on an “everything-is-a-plugin” architecture. In a session, according to the user guide, “The agent can read and edit workspace files, run commands, delegate work, and maintain a plan.” The repository is deepseek-ai/deepseek-harness, created in August 2026, and its README warns in capitals: “THERE WILL BE COMPATIBILITY-BREAKING CHANGES.”
Search results often describe Harness as a version of the pi coding agent. It is not. It uses pi’s model library, pi-ai, as the adapter for every provider other than DeepSeek’s own, which is why its custom-provider settings look like pi’s. The agent itself is DeepSeek’s.
Several unofficial apps also carry the name, such as “DSH Desktop” and “DeepSeekGUI”. They are community projects, not DeepSeek’s. The official desktop builds come from download.deepseek.com, linked from DeepSeek’s Harness page.
Installing it
Desktop: DeepSeek’s Harness page offers a macOS (Apple silicon) DMG of about 265 MB and a Windows (64-bit) installer of about 289 MB. The desktop app bundles its own runtime, so you do not need Node.js. There is no Linux desktop build.
npm, for any system including Linux:
npx @deepseek-ai/dsh web
The README says this “starts the Web UI at http://127.0.0.1:3080 by default”. You need Node.js 24.9 or newer: DeepSeek’s upgrade guide says “DSH requires Node.js 24.9 or newer.” The npm package does not declare that requirement, so an older Node will not warn you before something fails. On 24 October the latest tag was 0.2.1-rc.2 (17 October) and next was 0.2.1-rc.3.
The web interface listens only on your own machine by default and refuses to bind to all network interfaces.
Connecting a local model
DeepSeek’s providers guide says to switch the provider card to “Custom model API” for “a relay, a company gateway, a self-hosted server, or any provider absent from the installed catalog.” The steps:
- Start your local server and load a model with tool calling (see the model table below).
- In Harness, open Settings → Models and choose Custom model API.
- Enter a lowercase provider ID such as
ollama. Choose it carefully: the docs note that “The Provider ID is permanent”. - Enter the base URL with its scheme:
http://localhost:11434/v1for Ollama,http://localhost:1234/v1for LM Studio. For llama.cpp’sllama-server, check the port it prints: current builds default to 9931 rather than the long-standing 8080. - Choose the OpenAI Chat Completions protocol.
- Leave the API key blank. A blank key saves the provider without a credential. If you instead name an environment variable that is not set, every request fails with a missing-credential error.
- Use Fetch available models, which calls the server’s
/modelsendpoint, or type the model tag exactly asollama listshows it.
The settings are saved in ~/.dsh/profiles/web/cordis.patch.yml for the web version. The equivalent entry, assembled by BFWR from the fields DeepSeek documents rather than copied from its docs, looks like this:
- id: llm-pi-ai
config:
providers:
ollama:
api: openai-completions
baseURL: http://localhost:11434/v1
models:
- id: qwen3-coder:30b
contextWindow: 65536
maxTokens: 8192
If the server rejects every request even though the address is right, DeepSeek’s troubleshooting advice for gateways is to add compat: {supportsDeveloperRole: false, maxTokensField: max_tokens} to the provider. We could not confirm whether Ollama, LM Studio or llama.cpp need it.
The context setting that matters
For any model it has no information about, Harness falls back to a default context window of 1,000,000 tokens. DeepSeek’s upgrade notes for 0.2.1-rc.2 say this “can delay automatic compaction”, and advise you to “Check the actual limits of custom endpoints.”
For a local model, that default is far too high. Ollama picks a context length from your GPU’s memory, and below 24 GiB of VRAM it is 4,096 tokens. If Harness believes it has a million tokens, it will keep growing the conversation long after the server has started cutting it off. So set two things:
- On the server: a real context length, for example
OLLAMA_CONTEXT_LENGTH=65536before starting Ollama. Ollama’s context-length page says tasks like “agents, and coding tools should be set to at least 64000 tokens.” - In Harness: the same number as
contextWindowon the model, as in the example above.
Which local models to use
DeepSeek recommends no local models for Harness. Two documented details narrow the choice: the agent works through tool calls, and the adapter fails a tool call whose arguments are malformed without retrying it by default. Small models produce malformed tool calls far more often than larger ones, so a model with reliable tool calling matters more than raw benchmark scores.
The memory needed at a 64K context, computed with our VRAM calculator‘s formula (4-bit weights, 16-bit cache, plus runtime overhead):
| Model | Memory at 64K context | Fits |
|---|---|---|
| Gemma 4 12B | 10.3 GB | 12GB cards |
| gpt-oss-20b | 17.1 GB | 24GB cards |
| Gemma 4 26B-A4B | 19.2 GB | 24GB cards |
| Qwen3.8 27B | 22.5 GB | 24GB cards, just |
| Qwen3.6 35B-A3B | 24.7 GB | 32GB cards, or Macs with 36GB+ |
| Qwen3-Coder 30B-A3B | 26.1 GB (23.1 GB with an 8-bit cache) | 32GB cards, or 24GB with an 8-bit cache |
Our guide to local LLMs for coding compares these models in more depth, and our OpenCode guide shows how to set the context length in Ollama, LM Studio and llama.cpp.
Permissions and safety
DeepSeek’s shipped configuration starts every session in workspace-write mode with ask approval: the agent may write files inside your workspace, and actions that need approval prompt you first. You can change it with the Permissions selector or the DSH_PERMISSION_MODE variable, which takes read-only, workspace-write or danger-full-access.
Two details are easy to miss. The sandbox covers files only: DeepSeek’s sandbox notes say “Network and process visibility are outside this vocabulary.” And in danger-full-access mode the approval policy switches to never, so there is no confinement and no prompt at all.
DeepSeek’s own safety notice is direct about the rest: “It has not undergone a security audit and must not be treated as secure or production-ready.” It recommends that you “Prefer a disposable virtual machine, container, or dedicated environment.” A local model does not change that advice, because the risk comes from what the agent can run, not where the model lives. Our guide to securing a local LLM covers why.
What leaves your machine
Running a local model keeps prompts on your machine during normal use, but two things in Harness can still send data out:
- Feedback uploads the session. Session telemetry is off until you submit feedback, and then, in the words of its README, it is sent “for all users and providers”, local models included. The upload covers the whole session so far, not just the feedback. Setting
DSH_TELEMETRY_DISABLEDto any value turns it off completely. - The desktop app sends product analytics. Its README says the desktop “reports selected interactions through the existing OTel product exporter by default, without a user-facing control.” It excludes prompts, responses and API keys, but includes device details. The web version never sends these events.
DeepSeek’s privacy policy for custom models says Harness “does not store or process your Input and Output on the server side”. That fits normal use. It does not fit the feedback upload, which the code describes as covering every provider. If your data must stay local, set the telemetry variable and do not press feedback.
Licence and terms
The code is MIT-licensed. Using your own model needs no DeepSeek account: the Terms of Use say “You may use the custom model services without registering or logging in to an account”. They also describe Harness as “a purely neutral calling tool”, which puts responsibility for the model, and what it does, on you.
Local model or DeepSeek’s API?
Harness is tuned for DeepSeek’s own model. DeepSeek says its new V4.1-Flash-1017 was optimised specifically for Harness, and it costs $0.30 per million input tokens at peak through the API. A 30B local model will be slower at long agent tasks and make more tool-call mistakes. The local route is worth it when code or documents cannot leave your machine, or you want to work offline; for everything else, our DeepSeek API pricing guide shows how cheap the API has become.
FAQ
Does DeepSeek Harness work with Ollama?
Yes, through its Custom model API setting, which accepts any OpenAI-compatible server. DeepSeek does not document Ollama by name, so the settings above follow the generic route: base URL http://localhost:11434/v1, Chat Completions protocol, no key.
Do I need a DeepSeek account?
Not for custom models. The desktop app’s welcome screen asks for a DeepSeek API key, but you can choose to set it up later and add your own model in Settings.
Is DeepSeek Harness free?
Yes, the software is free and MIT-licensed. You pay only for the model: nothing for a local one, or DeepSeek’s API prices for its own.
Is it the same as the pi coding agent?
No. Harness uses pi’s model library to talk to non-DeepSeek providers, but the agent is DeepSeek’s own and is built on a different framework.
Related guides and tools
- Claude Code with a local model on Ollama
- OpenClaw vs Hermes Agent, two personal agents on local models
- OpenCode with a local LLM
- Running Ollama as a server
- Model recommender
Sources
- deepseek-ai/deepseek-harness on GitHub: README, SAFETY.md, the providers guide, the 0.2.1-rc.2 upgrade guides, the sandbox notes, and the telemetry and product-analytics READMEs
- Harness documentation: providers
- DeepSeek Harness page, Terms of Use and Privacy Policy
- npm registry: @deepseek-ai/dsh
- Ollama: context length and llama.cpp server README (default port)
Updated 24 October 2026. Versions, defaults and terms were read from DeepSeek’s repository and site on that date. Harness is a developer preview and changes quickly.
Work out what your hardware can actually run
Free calculators and directories, sized from real model weights — before you download gigabytes or order a card:


Leave a Reply