Introduction¶
DeepSeek Harness (DSH) uses a plugin-based architecture and aims to inject various capabilities into the agent runtime. For developers who need to manage self-hosted code repositories, direct access to Gitea or Forgejo instances usually requires additional REST API wrappers. The maxmilian/dsh-forge plugin was created to solve this problem. It provides DSH with a toolset for interacting with Gitea/Forgejo REST APIs, enabling agents to directly read repository, Issue, Pull Request, and Actions context.
This plugin is maintained by the user maxmilian and uses the MIT license.
Core Features¶
The plugin extends DSH capabilities through the REST API, specifically including:
- Instance Information: Check the version of the configured Gitea or Forgejo instance.
- Repositories and Search: List repositories owned by the currently authenticated user; search Issues and Pull Requests across visible repositories.
- Issues and PRs: Read a single Issue or PR by repository and index; read PR diffs and changed file metadata.
- Actions Integration: List repository Actions runs and jobs, and read plain-text job logs.
- Localization: Runtime tool metadata localization is supported in English, Traditional Chinese, Simplified Chinese, and Japanese.
- Security and Limits: Forward cancellation requests, and enforce request timeouts and response size limits.
- Parallel Safety: v0.3 tools are designed to be read-only and to execute safely in parallel.
Installation and Activation¶
Installation via the npm package is recommended. The command is as follows:
dsh plugin --profile web add @maxhsu/dsh-forge
If you need to install from a local checkout, you can use:
dsh plugin --profile web add .
Install from a prebuilt release package:
dsh plugin --profile web add https://github.com/maxmilian/dsh-forge/releases/latest/download/dsh-forge.tgz
After installation, access credentials must be configured in the configuration file. It is recommended to use environment variables rather than writing the token directly into the configuration file.
Typical Usage¶
Before calling the tools provided by the plugin, you need to configure the environment variables DSH_FORGE_URL and DSH_FORGE_TOKEN.
export DSH_FORGE_URL='https://code.example.com'
export DSH_FORGE_TOKEN='replace-with-a-read-only-token'
dsh --profile web
The DSH_FORGE_URL can include a subpath (for example, https://example.com/git), and the plugin automatically appends /api/v1 to the end. If the URL is not configured, calling a tool returns an actionable configuration error, while not preventing DSH from starting.
Use Cases and Notes¶
- Compatibility: DeepSeek Harness is in developer preview. The plugin has been tested and is compatible with
@deepseek-ai/dsh-tools 0.1.7-rc.2. - Operation Mode: All tools in the current version (v0.3) are read-only operations and will not create, update, merge, rerun, or delete remote resources.
- Data Limits: List-type endpoints cap the
limitparameter at 50 to keep the model context size manageable. - Log Format: Diff and log responses remain in plain-text format to avoid the complexity caused by JSON escaping.
Summary¶
maxmilian/dsh-forge provides DeepSeek Harness with a standardized toolchain for managing self-hosted Gitea and Forgejo instances. It uses the REST API to create a complete closed loop from version checking to Actions log reading, making it suitable for agent scenarios that require code review or automated operations on local code repositories.