deepseek-harness

deepseek-harness is a skill for Claude Code, Codex from D-Robotics/moss. It costs 22 tokens per session (564 once invoked), scanned A, original, MIT.

A set of rules for building and debugging clients that call DeepSeek V4 models through an OpenAI-compatible API. An API is a defined way for software to communicate with another service.

In plain words
What is it for?
Implementing or troubleshooting DeepSeek V4-Pro, V4-Flash, deepseek-chat, or deepseek-reasoner integrations.
Why use it?
It helps prevent protocol errors when handling reasoning output, streamed responses, parallel tool calls, usage data, and request limits.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Implementing or troubleshooting DeepSeek V4-Pro, V4-Flash, deepseek-chat, or deepseek-reasoner integrations.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/d-robotics/moss/deepseek-harness
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add D-Robotics/moss --skill deepseek-harness
Clone the repo
git clone --depth 1 https://github.com/D-Robotics/moss

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for deepseek-harness

README.md
[![agentmods](https://agentmods.dev/badge/skills/d-robotics/moss/deepseek-harness.svg)](https://agentmods.dev/skills/d-robotics/moss/deepseek-harness)
Your own site
<a href="https://agentmods.dev/skills/d-robotics/moss/deepseek-harness"><img src="https://agentmods.dev/badge/skills/d-robotics/moss/deepseek-harness.svg" alt="Measured on agentmods" height="20"></a>
Per session 22 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 564 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00022 $0.00564
Opus 5 $0.00011 $0.00282
Sonnet 5 $0.00004 $0.00113
Haiku 4.5 $0.00002 $0.00056

Measured 7d ago against content hash f809c8556e24, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-07, from the pricing page.

Security

Grade A, and why

deepseek-harness scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 7d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

packages/moss-agent/assets/plugins/deepseek-harness/skills/deepseek-harness/SKILL.md · 46 lines

What it actually says

DeepSeek V4 Harness

Use these rules when code calls DeepSeek V4-Pro, V4-Flash, deepseek-chat, or deepseek-reasoner through an OpenAI-compatible API. This Moss edition is adapted from HenryZ838978/deepseek-harness at commit d1dd82381604aeb3586edb242e67a62003b77d71.

  1. Disable thinking for work that does not benefit from reasoning. In Python, send extra_body={"thinking":{"type":"disabled"}}; for OpenAI's TypeScript SDK, confirm how the installed SDK forwards provider extensions.
  2. When thinking is enabled and an assistant message contains tool calls, preserve its original reasoning_content while completing that tool loop. Dropping it can make the next request fail.
  3. Always set a finite max_tokens output cap. Treat the model and gateway limits as runtime configuration, not as timeless constants.
  4. Aggregate streamed parallel tool-call deltas by the protocol's call index. Do not assume chunks arrive in call-list order.
  5. Buffer text and reasoning chunks in arrays and join them once; repeated string concatenation can become quadratic for long reasoning streams.
  6. Accept stream chunks whose choices array is empty. They can still carry usage information.
  7. Keep input plus requested output within the model's advertised context window. Probe or configure the current limit rather than relying on an old catalog value.
  8. Keep the stable prompt prefix free of volatile timestamps and request-specific state when prefix caching matters. Read both DeepSeek-native and OpenAI-shaped cached-token usage fields.
  9. Use the normal DeepSeek endpoint for tool-using flows unless current official documentation explicitly requires a beta endpoint.
  10. Validate tool arguments after JSON parsing even when strict function schemas are enabled.

For a real client implementation, prefer the maintained upstream packages and MCP server instead of copying an old snapshot blindly:

  • Python: deepseek-harness
  • CLI: deepseek-harness-cli
  • MCP: @deepseek-harness/mcp

Before recommending install commands or model limits, verify the current upstream README and official DeepSeek API documentation. Never put API keys in source, plugin configuration output, logs, or chat.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 7d ago First seen · 46 lines · 22 tokens per session scan A f809c8556e24

Subscribe to this mod's changes

deepseek-harness is a skill published in the GitHub repository D-Robotics/moss (142 stars, last pushed 11d ago), licensed MIT. It adds 22 tokens to every session and 564 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

gemini-api-agent-platform

Guides the usage of the Gemini API on Agent Platform with the Google Gen AI SDK for enterprise AI applications. Covers SDK usage (Python, JS/TS, Go, Java, C#), capabilities like Live API, tools, multimedia generation, caching, and batch prediction.

davila7/claude-code-templates · 61 tokens

open-source

Documentation reference for writing Python code using the browser-use open-source library. Use this skill whenever the user needs help with Agent, Browser, or Tools configuration, is writing code that imports from browseruse, asks about @sandbox deployment, supported LLM models, Actor API, custom tools, lifecycle…

browser-use/browser-use · 137 tokens

gemini-api-dev

Use this skill when writing code that calls the Gemini API for text generation, multi-turn chat, multimodal understanding, image generation, video generation, streaming responses, background research tasks, function calling, structured output, or migrating from the old generateContent API. Covers SDK usage and best…

google-gemini/gemini-skills · 73 tokens

deepstream-sop

Use this skill when building, deploying, evaluating, debugging, or measuring latency for the DeepStream SOP Inference Microservice — a GPU-accelerated FastAPI service that detects whether operators perform assembly-line steps in order via event boundary detection (GEBD) plus VLM classification. Trigger even if the…

NVIDIA/skills · 219 tokens

azure-search-documents-dotnet

Azure AI Search SDK for .NET (Azure.Search.Documents). Use for building search applications with full-text, vector, semantic, and hybrid search. Covers SearchClient (queries, document CRUD), SearchIndexClient (index management), and SearchIndexerClient (indexers, skillsets). Triggers: "Azure Search .NET"…

microsoft/skills · 102 tokens

azure-search-documents-ts

Build search applications using Azure AI Search SDK for JavaScript (@azure/search-documents). Use when creating/managing indexes, implementing vector/hybrid search, semantic ranking, or building agentic retrieval with knowledge bases.

microsoft/skills · 48 tokens