Borrowing it
Nothing to install: this file belongs to web-casa/DeepSeek-Harness-Desktop. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.
curl -O https://raw.githubusercontent.com/web-casa/DeepSeek-Harness-Desktop/main/AGENTS.mdgit clone --depth 1 https://github.com/web-casa/DeepSeek-Harness-DesktopWrote 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.
[](https://agentmods.dev/instructions/web-casa/deepseek-harness-desktop/agents-md)<a href="https://agentmods.dev/instructions/web-casa/deepseek-harness-desktop/agents-md"><img src="https://agentmods.dev/badge/instructions/web-casa/deepseek-harness-desktop/agents-md.svg" alt="Measured on agentmods" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.02781 | $0.02781 |
| Opus 5 | $0.01391 | $0.01391 |
| Sonnet 5 | $0.00556 | $0.00556 |
| Haiku 4.5 | $0.00278 | $0.00278 |
Grade A, and why
DeepSeek-Harness-Desktop AGENTS.md scanned grade A with 1 finding 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.
Runs shell commandslowCapability
Expected in a hook, worth knowing in a rule or an instructions file.
--profile、参数原样转发 pnpm、`spawnSync("pnpm", {shell: win32, How it starts
The opening of the file, as written. The whole thing — 156 lines — stays where its author put it; the contents beside it link to each section on GitHub.
AGENTS.md — DSH Desktop
面向 AI 编码代理(codex/claude 等)的项目上下文基线。先读本文,再读 README.md。
项目本质
Tauri 2 壳 + Rust dsh-sidecar 监督器 + 内置 Node 24 运行官方 DeepSeek
Harness(@deepseek-ai/dsh,不 fork,pin 版本)。桌面层只做生命周期:
Tauri 管窗口/托盘,sidecar 管 Harness 进程树,Harness Web UI 原样加载。
不可违背的安全不变量
- harness 窗口 capability 为空集;远程 webview 零 IPC 面,且导航只允许
就绪时捕获的 origin(
same_origin,见harness/mod.rs)。 - 桌面命令经 app ACL(
src-tauri/build.rsAppManifest)只授权 bootstrap。 - 外部 deep link(
dsharness://plugin/install)只产生「待确认安装请求」, 绝不静默安装;协议/包名/来源在 Rust 侧全量重校验后才可进入 UI。 DSH_HOME0700、拒绝符号链接;withGlobalTauri: false+ CSP。- 进程树保证:unix 进程组 + sigaction;Windows Job Object + 隐藏控制台
CTRL_C 优雅关闭(
platform.rs)。任何改动不得弱化。 - 零符号链接不变量限定范围:
src-tauri/resources/runtime/harness与安装包内runtime/harness子树必须完全物化(materialize.ts+check-runtime-links.ts断言)。macOS .app 框架自身的系统级链接不在其列。 - NDJSON 协议契约与 golden 测试(
ndjson_golden_events)同改:改事件结构 必须同时更新 sidecar、Tauriapply_state_event、verify-runtime.ts三端。
版本单一事实源(改动版本时必须同时改全部)
| 文件 | 内容 |
|---|---|
runtime/runtime-manifest.json |
desktop/harness/node/sidecar 版本 + nodeSha256(6 平台) |
package.json(根) |
desktop 版本 |
src-tauri/Cargo.toml / tauri.conf.json |
desktop 版本 + dsh-sidecar 依赖的 version pin(与 crates/dsh-sidecar 同步;cargo-deny wildcards=deny 要求非空版本) |
crates/dsh-sidecar/Cargo.toml |
sidecar 版本 |
runtime/package.json + package-lock.json |
harness pin(npm install 刷新锁) |
.nvmrc |
CI 脚本 Node(== manifest.nodeVersion) |
snap/snapcraft.yaml |
Snap Store 包版本(== desktopVersion) |
scripts/lib/node-distribution.ts 是由 manifest 生成的下载路径白名单,不是第二
个版本事实源;Node bump 时执行 pnpm runtime:node:generate 并提交结果。
release:preflight 会拒绝未同步的生成文件。
Snap 包只能由同一原生 job 从当前 checkout 生成的、已过
verify-bundle --bundle deb 的本地 DEB 输入;不得下载/重包装 GitHub Release
资产。snap/bin/launch-dsh-desktop 必须无条件将 DSH_HOME 与 XDG 数据目录
固定到 $SNAP_USER_COMMON,并清除 DSH_RUNTIME_DIR;不得为方便调试放开
classic、devmode、home 或 removable-media。
Snap 的 part source 必须是当前 checkout 内的本地输入;不得重新引入会在构建期拉取
可变 Git 分支的 extensions: [gnome]。GNOME/WebKit/GPU 运行期集成使用经过定义
复核的本地 command-chain relay 与 Store 签名的 gnome-46-2404 / mesa-2404 content
provider;变更它们须同时更新 scripts/lib/snap.ts、定义测试与最终包 verifier。
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.
- 7d ago First seen · 156 lines · 2,781 tokens per session scan A 49738a517fcb
DeepSeek-Harness-Desktop AGENTS.md is an instructions file published in the GitHub repository web-casa/DeepSeek-Harness-Desktop (117 stars, last pushed 2d ago), licensed MIT. It adds 2,781 tokens to every session, about $0.0139 per session on Opus 5. A static security scan graded it A with 1 finding (runs shell commands). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other instructions, from other repositories
next.js AGENTS.md
AGENTS.md instructions for vercel/next.js, covering next.js development guide, codebase structure, monorepo overview, core package: packages/next and other important packages.
codex AGENTS.md
AGENTS.md instructions for openai/codex, covering rust/codex-rs, the codex-core crate, code review rules, crate api surface and model visible context.
vscode buildNext.instructions.md
Working notes and architecture documentation for the new esbuild-based build system in build/next. Use when making changes to the new build pipeline (transpile/bundle commands, NLS plugin, source-map handling, resource copying, or self-hosting watch tasks).
vscode oss-third-party-notices.instructions.md
Instructions for microsoft/vscode, covering vs code oss third-party-notices pipeline, architecture, pipeline flow in ci, applying the notice (cutover) and fallback chain (never fail the build).
langchain AGENTS.md
AGENTS.md instructions for langchain-ai/langchain, covering global development guidelines for the langchain monorepo, corridor security analysis, project architecture and context, monorepo structure and development tools & commands.
spec-kit AGENTS.md
AGENTS.md instructions for github/spec-kit, covering agents.md, about spec kit and specify, quickstart — add a new integration in 5 steps, integration architecture and integrationmanifest — file tracking.