dsh-project-agent-instructions: Injecting project-level AGENTS.md into DSH agent system prompts

Introduction

When running agents in DSH, system prompts are often written in global configurations or individual sessions. If team norms, directory conventions, and prohibitions are scattered across documents or verbal agreements, they must be repeatedly pasted for every new session. This is not only prone to omissions but also difficult to align with repository versions. Common practices include manually pasting instructions into the prompt or maintaining a “notes for AI” file in each project without a unified loading mechanism.

Below is an introduction to the community plugin dsh-project-agent-instructions (npm package name @shihaoshen/dsh-project-agent-instructions). It locates .dsh/AGENTS.md in the project directory (and optional additional paths) and injects the content as a separate section into the system prompt of every agent. It also provides a settings page in the DSH Web UI. The maintainer is ShihaoShenCreator, and it is categorized as “Workflow” in the SkillHub directory.

What is this

This plugin is a Cordis plugin for DeepSeek Harness (DSH): starting from the session’s working directory, it traverses upwards through ancestor directories to find the nearest .dsh/AGENTS.md. It then reads other paths relative to the project root according to the configuration. Finally, it writes the merged instruction text into the agent’s system prompt. This takes effect for agents launched with the project root or any subdirectory as the working directory.

Core Features

Based on the repository README and package.json (current version 1.2.0), the verified capabilities are as follows:

  1. Default loading of .dsh/AGENTS.md: Searches upwards from the working directory, supporting files in the project root and parent directories.
  2. Additional read paths: Configurable via the settings page as comma-separated paths relative to the project root; these are checked after the default file. .dsh/AGENTS.md is always included in the list and cannot be removed from the read list.
  3. Size limit: If the content exceeds the limit, it is truncated in a UTF-8 safe manner before injection. The default limit is 32,768 bytes.
  4. File watching: Changes to instruction files take effect automatically without needing to restart DSH.
  5. Web settings page: Located at Plugins → This plugin; modifications are applied immediately.

The license is MIT.

Installation and Activation

Open Plugins → Add plugin in the DSH Web UI and install:

@shihaoshen/dsh-project-agent-instructions

You can also install it for your profile via the CLI’s plugin manager. After installation, restart DSH is required for the client module to load.

Typical Usage

Create .dsh/AGENTS.md in the project root:

my-project/
└── .dsh/
    └── AGENTS.md

When an agent is launched with that project as the working directory (or any of its subdirectories), the content of this file is automatically added to the system prompt. You can write team conventions such as coding standards, test commands, and directory structure descriptions in AGENTS.md.

If other instructions need to be loaded besides the default file (e.g., docs/AGENT-RULES.md), fill in the paths relative to the project root in the Additional read paths field on the settings page, separating multiple paths with commas. If a single file is too large, you can adjust Maximum bytes (default 32768).

Use Cases and Notes

Suitable for: DSH users who need to solidify “project instructions for agents” within the repository, wish for sessions in subdirectories to inherit the same set of rules, and want changes to files to take effect immediately without repeatedly pasting prompts manually.

Notes:

  • The plugin reads local files under the permissions of the DSH process; before installation, it is recommended to review the GitHub Source Code and the MIT license to ensure the behavior meets expectations.
  • The injected content enters the system prompt of every agent, and overly long files will be truncated; important constraints should be written at the front or the total size should be controlled.
  • SkillHub (https://www.skillhub.cn/plugins/ShihaoShenCreator/dsh-project-agent-instructions) is a community plugin directory with no official affiliation with DeepSeek or High-Flyer; the DSH ecosystem follows the “everything is a plugin” extension approach.

Conclusion

dsh-project-agent-instructions uniformly injects project-level .dsh/AGENTS.md and optional additional paths into DSH agent system prompts. It supports file watching and Web configuration, reducing the issues of repeated pasting and unsynchronized standards.

  • Directory Page: https://www.skillhub.cn/plugins/ShihaoShenCreator/dsh-project-agent-instructions
  • GitHub: https://github.com/ShihaoShenCreator/dsh-project-agent-instructions
羽毛球分组比赛记分
小程序二维码

欢迎使用《羽毛球分组比赛记分》微信小程序

Xiaoye