DeepSeek Harness Plugin Hub

发布与管理完整 Harness Profiles,发现适合你的插件。

探索

插件目录环境预设文档中心动态

社区

发布插件联系我们报告问题

相关链接

Plugin Hub GitHubDeepSeek Harness 官方项目系统状态隐私说明
© 2026 DeepSeek Harness Plugin HubPowered byPaxTech

独立、非官方社区项目,与 DeepSeek 官方无隶属、授权或背书关系。

DeepSeek Harness Plugin Hub
ProfilesPlugins分类动态文档登录管理 Profiles
ProfilesPlugins分类动态文档登录
← Plugins

dsh-pathfix

Pathfix

用于在宿主层规范化工具路径和模式参数中的空白字符及末尾换行符的 DeepSeek Harness 插件。

插件会安装到这里;不确定时保持 web。

npx -y @deepseek-ai/dsh plugin --profile web add dsh-pathfix@0.1.0
README兼容性版本

兼容性与来源证明

Pathfix 以 dsh-pathfix 发布,当前版本为 0.1.0。Plugin Hub 会校验它的 manifest,并保存精确安装来源,便于复现安装结果。

DSH 兼容范围
*
运行环境
any
发布来源
npm
Registry 更新时间
2026/11/5

版本

0.1.0stable
2026/9/13

相关插件

正在加载相关插件…

最新版
0.1.0
DSH
*
HMR
重启进程
Tree shaking
未声明可安全裁剪
解包体积
22.9 kB
文件数
9
Surface
any
许可证
MIT
发布源
npm
GitHub
★ 0
周下载
7
最近提交
2026/9/18
查看源码 ↗项目主页 ↗
README Badge

点击下方 Badge 复制 Markdown,粘贴到 README 即可。

这是你的 Plugin?认领权益 · 优先安全扫描

验证 package.json 声明的 GitHub 仓库,即可管理这个公开页面。认领后,Hub 会优先安排当前版本的安全扫描,并在通过后公开展示结果。

认领这个 Plugin →
报告问题

相关插件

继续浏览 developer-tools 分类下经过校验的插件。

Client Ui Git Graph@linxin666/dsh-client-ui-git-graph外部 dsh Web GUI 插件:空会话 Git 分支选择器和 Git 图,包含实际的主机端 Git 操作与防护,作为 dsh 配置文件包Ssh@linxin666/dsh-sshdsh Web GUI 的远程 SSH 操作:主机配置存储(~/.dsh/dsh-ssh.json,可从 ~/.ssh/config 导入)、支持跳板主机的持久化 ssh2 连接池、exec / PTY Web 终端 / SFTP 传输 / 本地端口转发隧道 / 集群执行Opsdsh-ops适用于 Windows x64、Linux x64 和 macOS arm64/x64 的原生文件和 PTC 工具;仅限 Windows 的可选 Bash 负载和主机 PowerShell 集成Update@linxin666/dsh-update用于 dsh Web GUI 的自更新插件:探测 npm 上是否有更新的系列版本,并在原地运行所属配置的 pnpm 更新;可通过设置图标旁侧边栏中的触发器启动,并显示发布说明面板

README

🧹 dsh-pathfix

Host-layer DeepSeek Harness (DSH) plugin that automatically detects and repairs whitespace and trailing newlines in tool path and pattern parameters before dispatch.

📋 Table of Contents
  • What It Fixes
  • Guarantees
  • Installation
  • Configuration
  • Observability & Telemetry
  • Verification & Testing
  • Contributing
  • Links
  • License

What It Fixes

Due to model tokenization and sampling variance, LLMs occasionally emit tool parameters with unexpected trailing newlines or edge whitespace (e.g. "file_path": "C:\\images\\_shot.png\n"). Because standard filesystem tools take parameters verbatim, this causes recurring, misleading tool failures:

ToolError when a trailing \n is in the parameterWhat dsh-pathfix does
writeEINVAL: invalid argument, mkdir '...<filename>\n.<id>.tmpdir'Trims whitespace; directory and file creation succeed.
globIO error / The filename, directory name, or volume label syntax is incorrect (os error 123)Trims path whitespace; search succeeds.
greprg: the literal "\n" is not allowed in a regexStrips \r/\n while preserving regex edge spaces.
read_imageMisleading read_image only accepts PNG/JPEG/WebP/GIF pathsTrims path; image extension check passes.
readMisleading not found (file exists)Trims path; file resolves and reads normally.

dsh-pathfix operates transparently at the host layer before tool dispatch. The model does not need to learn any replacement tool, and tool result prose is never modified.

Guarantees

  • No-Op Guarantee: Clean arguments pass through completely untouched (fix(clean) === clean). If no repair is required, the original argument object reference is returned and no telemetry is emitted.
  • Idempotency Guarantee: fix(fix(x)) === fix(x). Applying normalization multiple times yields the exact same state.
  • Preserves Regex Edge Spaces: In pattern arguments (for grep and glob), only \r and \n characters are stripped. Spaces and tabs at pattern boundaries are preserved because they can be semantically significant in regular expressions.
  • Zero Runtime Dependencies: Relies solely on host peer dependencies (@deepseek-ai/dsh-tools, @deepseek-ai/schemastery).

Installation

Install into your target DSH profile (e.g. web):

dsh plugin --profile web add file:/absolute/path/to/plugins/dsh-pathfix

Verify that the bundle is mounted in your profile:

dsh web --dump-config | Select-String -Pattern "pathfix" -Context 1,2

Expected output includes the patch layer:

# == dsh-pathfix
- id: pathfix
  name: dsh-pathfix

Configuration

dsh-pathfix is configurable via your profile's cordis.patch.yml or cordis configuration:

- id: pathfix
  name: dsh-pathfix
  config:
    enabled: true           # Enable or disable parameter normalization (default: true)
    tools:                  # List of tool names to inspect (default: fs tools)
      - read
      - read_image
      - write
      - edit
      - glob
      - grep
    stripLeading: true      # Strip leading whitespace in paths (default: true)
    logFixes: true          # Log repairs to session/console (default: true)

Observability & Telemetry

When a parameter is repaired, dsh-pathfix records the event in an internal telemetry tracker and emits an informational log message (if logFixes: true):

[dsh-pathfix] Repaired parameter "file_path" on tool "read_image": stripped trailing "\n" (value: "C:\\images\\_shot.png\n" -> "C:\\images\\_shot.png")

The repair event is also emitted as pathfix/repair on the Cordis context and tracked in ctx.pathfix.telemetry.

Verification & Testing

Verification (Check if Plugin is Mounted in Profile)

In Windows CMD (Command Prompt):

dsh web --dump-config | findstr /i "pathfix"

In PowerShell:

dsh web --dump-config | Select-String -Pattern "pathfix" -Context 1,2

Expected output:

# == dsh-pathfix
- id: pathfix
  name: dsh-pathfix

Acceptance Mount Check

Verify that the profile dependencies, bundle patch, and live Cordis normalization hook are fully active:

node acceptance/mount_check.mjs C:\Users\marti\.dsh\profiles\web

Or via npm:

npm run mount-check C:\Users\marti\.dsh\profiles\web

Automated Test Suite

Run unit and E2E tests using Node.js built-in test runner:

# Run all tests (unit + E2E)
npm test

# Run unit tests covering the 5 real-world error fixtures
npm run test:unit

# Run E2E test with real @deepseek-ai/dsh-tool-fs suite
npm run test:e2e

Or directly with Node:

node --test test/unit.test.mjs test/e2e.test.mjs

🤝 Contributing

We welcome contributions! Please see our Contributing Guidelines for details on code invariants, test fixtures, and commit standards.

🔗 Links

  • 📚 DeepSeek Harness
  • 🐛 Issues
  • 📦 NPM Package

License

MIT © loonylabs-dev


Maintained by loonylabs-dev