Introduction

DeepSeek Harness (DSH) uses a plugin architecture, allowing developers to extend agent capabilities through plugins. During local development or debugging, common needs include frequently querying GitHub repositories, creating issues, or cloning repositories into the workspace. The tkwkeven/dsh-tool-github plugin provides GitHub REST API support for DSH, registers a github_* toolset, and enables the agent to bind an account, query data, create issues/PRs, and clone repositories. It also provides a browser-side GitHub panel.

Core Features

The plugin mainly provides the following capabilities:

  • Account Binding: Uses github_bind to validate and store a personal access token (PAT); subsequent tools automatically use this identity.
  • GitHub API: Supports repository metadata queries (github_repo), search (github_search), issue/PR management (github_issues, github_prs, github_create_issue, github_create_pr), and file content reading (github_content).
  • Workspace Management: Supports cloning repositories locally (github_workspace_add) and registering them as DSH workspaces, making them appear in the workspace selector.
  • Web GUI Panel: Provides a GitHub panel in the DSH web interface sidebar for viewing status, binding an account, adding workspaces, and more.

Installation and Enabling

Run the following command in the plugin directory to install it:

dsh plugin --profile web add .

After installation, you need to restart the Web GUI (dsh web) to load the new client components. The GUI client plugin discovery mechanism runs only when the process starts.

Usage

The agent can directly call the following tools or interact through natural language:

  • github_bind: Bind a GitHub account (a PAT is required).
  • github_whoami: View the currently logged-in account.
  • github_workspace_add <owner> <repo> [branch]: Clone a repository and add it as a workspace.
  • github_workspace_list: List the cloned workspaces.
  • github_repo <owner>/<repo>: Get repository information (such as star count).
  • github_search <query>: Search repositories or code.

Workspace and Credential Mechanism

  • Cloning Method: github_workspace_add prefers git clone, falling back to a codeload tarball download when Git TLS is unavailable.
  • Credential Resolution: The token source priority is: credential store -> plugin configuration -> environment variable (GITHUB_TOKEN). github_bind stores the token in DSH’s credential seam (ctx.credentials), so changing credentials does not require restarting the process.

Web GUI Panel

After installing and restarting dsh web, a GitHub icon appears in the sidebar. Clicking features in the panel (such as “Bind Account” or “Add Workspace”) communicates with the host via /github-* commands. This means the panel does not directly hold the token or access the GitHub API, which is more secure.

Configuration

The plugin supports adjusting parameters through configuration files (such as ~/.dsh/cordis.patch.yml or profiles/<name>/cordis.patch.yml):

- id: tool-github
  config:
    maxResults: 20
    workspaceRoot: D:\github-workspaces

Summary

This plugin integrates GitHub into DSH workflows through standardized API tools and a web panel, making it suitable for developers who frequently interact with GitHub.