Skip to content
| Marketplace
Sign in
Visual Studio>Tools>DeepSeek Harness for Visual Studio
DeepSeek Harness for Visual Studio

DeepSeek Harness for Visual Studio

Preview

VSworder

|
5 installs
| (0) | Free
Community-built and unofficial: not affiliated with DeepSeek. Review DeepSeek Harness file edits in Visual Studio's native diff window before they touch disk. DeepSeek Harness (dsh) is a terminal agent. This extension gives it the one thing a terminal cannot: a real diff. Whe...
Download

Review every file the agent wants to change, in Visual Studio's own diff window, before it touches disk.

DeepSeek Harness is a terminal coding agent. What a terminal cannot give you is a real diff — you see a wall of text scroll past and hope. This extension gives it one: when the agent proposes a change, the comparison opens in Visual Studio's native diff window, left against right, with Accept and Reject. Nothing is written until you accept, and a rejection carries your reason back to the model.

What you get

A diff gate. Every write, edit and str_replace_editor call is intercepted before it runs and turned into a proposal. Accept writes it. Reject fails the call, with whatever you typed attached — so the agent learns why, instead of retrying the same thing.

Nothing is written on rejection. Not the file, not a zero-byte placeholder, not the parent directories.

Reads are not gated. Only changes are.

Visual Studio tools for the agent. Three read-only MCP tools report IDE state, so the model stops guessing about your workspace:

Tool Reads
get_environment Solution path, workspace folders, process id
get_open_files Files in the editor, and which one is active
get_current_selection The selected text, its file and line range

The last one works while you are typing in the terminal, because it asks the text manager for the last active view rather than the focused one.

Install

  1. Download the VSIX and close Visual Studio
  2. Double-click the file
  3. Restart Visual Studio

Then open a solution and pick Tools → DeepSeek Harness → Start session. A terminal tab opens running DeepSeek Harness with the gate attached.

The menu also has Status (reports whether the gate is ready, and what is missing if not), Open log, and an optional Clean up installed files for removing what the extension wrote.

Nothing is installed into your DeepSeek Harness profile

The gate is a plugin this project owns. It lives under the extension's own directory and is mounted from there through a generated patch. Your profile's dependencies, approval policy and sandbox policy are untouched — uninstalling the extension removes every capability, because without Visual Studio there is no bridge and no diff window.

Requirements

  • Visual Studio 2022 17.14 or newer (developed against Visual Studio 2026 18.10)
  • .NET Framework 4.8
  • DeepSeek Harness: npm install -g @deepseek-ai/dsh

Source and security

MIT licensed, source at github.com/VSworder/deepseek-harness-visual-studio.

The extension listens on a loopback port only (127.0.0.1), requires a per-instance token compared in constant time, and never executes a shell command. What the bridge exposes, what the token is worth, and what is deliberately not defended is written up in SECURITY.md.

Unofficial

Community-built. Not affiliated with, endorsed by, or supported by DeepSeek. DeepSeek Harness is their product; this extension only adds an IDE surface to it.


中文

agent 想改的每个文件,都会先在 Visual Studio 自己的 diff 窗口里给你过一遍,你点接受才落盘。

DeepSeek Harness 是个终端里的编码 agent。终端给不了你的东西,是一个真正的 diff —— 你只能看着一屏文字刷过去,然后祈祷。这个扩展补上这一块:agent 提出改动时,比较窗口会用 Visual Studio 原生的 diff 窗口打开,左对右,配 Accept 和 Reject。你不点接受,就什么都不写;点拒绝时你写的原因会回到模型那里。

你会得到什么

一道 diff 闸门。 每次 write、edit 和 str_replace_editor 调用都会在运行前被拦截,变成一个待审的提议。接受就写入;拒绝则让这次调用失败,并附上你输入的原因 —— 于是 agent 知道为什么,而不是把同一件事重试一遍。

拒绝时什么都不写。 不建文件、不留 0 字节占位、不建父目录。

读取不经过闸门,只有改动才拦。

给 agent 用的 Visual Studio 工具。 三个只读的 MCP 工具汇报 IDE 状态,模型不必再猜你的工作区:

工具 读到什么
get_environment 解决方案路径、工作区文件夹、进程 id
get_open_files 编辑器里的文件,以及哪个是活动的
get_current_selection 选中的文本,及其所在文件和行范围

最后那个在你于终端里打字时也能用 —— 它问的是文本管理器"最后活动的视图",而不是"当前有焦点的视图"。

安装

  1. 下载 VSIX,关闭 Visual Studio
  2. 双击该文件
  3. 重启 Visual Studio

然后打开解决方案,选 工具 → DeepSeek Harness → Start session。会开一个终端标签页,里面跑着挂了闸门的 DeepSeek Harness。

菜单里还有 Status(报告闸门是否就绪,没就绪时缺什么)、Open log,以及一个可选的 Clean up installed files(删除扩展写入的文件)。

不会往你的 DeepSeek Harness profile 里装任何东西

闸门是本项目自己维护的插件,待在扩展自己的目录下,通过生成的 patch 从那里挂载。你的 profile 依赖、审批策略、沙箱策略一概不动 —— 卸载扩展就移除了全部能力,因为没有 Visual Studio 就没有 bridge、也没有 diff 窗口。

前置条件

  • Visual Studio 2022 17.14 或更新(开发环境是 Visual Studio 2026 18.10)
  • .NET Framework 4.8
  • DeepSeek Harness:npm install -g @deepseek-ai/dsh

源码与安全

MIT 许可,源码在 github.com/VSworder/deepseek-harness-visual-studio。

扩展只监听环回端口(127.0.0.1),每个实例一个 token 且用常数时间比较,从不执行 shell 命令。bridge 暴露了什么、token 值多少、以及哪些是刻意不防的,都写在 SECURITY.md 里。

非官方

社区作品。与 DeepSeek 没有隶属关系,未获其背书或支持。DeepSeek Harness 是他们的产品;这个扩展只是给它加了一层 IDE 界面。

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
  • Your Privacy Choices
  • Consumer Health Privacy
© 2026 Microsoft