ChatGPTClaudeGrok / X / CursorGemini

dsh-plugin-opencode-local: Use Your Local OpenCode Models Inside DeepSeek Harness

mateenahmed737/dsh-plugin-opencode-local

Models & ReasoningVerified
Listed on 2026-11-03
Page last updated 2026-11-12

A DSH plugin that adds an OpenCode (local) model provider, exposing every model from your own OpenCode CLI while keeping credentials and traffic on your machine.

dsh-plugin-opencode-local is a DSH plugin that adds an OpenCode (local) model provider to DeepSeek Harness. Every request is served by the OpenCode process already installed on your machine, so all models from the providers you signed in to in OpenCode appear in the model picker while credentials stay with OpenCode itself. On the first request it starts a local server and health-checks it, restarts it after a crash, and routes restricted tools such as shell and file edits through DSH's approval prompt, which suits developers who want one place to reach their local model sources.

How to Install

install
npmdsh plugin --profile <your-profile> add dsh-plugin-opencode-local

Replace --profile with the profile name you actually run (see ls ~/.dsh/profiles/): usually web in the browser UI, desktop or desktop-NNN in the desktop app.

Category
Models & Reasoning
Platform
DSH Plugin
Author
mateenahmed737
Distribution
Plugin

dsh-plugin-opencode-local Key Features

All local OpenCode modelsReuses your own loginNo credential forwardingApproval for restricted toolsAttach to existing server
Listed on dsh-plugin.org

dsh-plugin-opencode-local Repo Summary

What Does It Do?

It is a DSH plugin for DeepSeek Harness that adds an "OpenCode (local)" model provider, serving every request through the OpenCode CLI installed on your own machine. It solves the problem of wanting your existing OpenCode models inside DSH when no plugin offered that path: the plugin never reads, copies, or forwards credentials, and makes no calls to opencode.ai or any other host. Its core capabilities are starting a local OpenCode server automatically, listing every model from every provider you are signed in to, and routing restricted tool calls through DSH's approval prompt.

Core Features

  • Full local model access: exposes every model of every provider you are signed in to in OpenCode, plus OpenCode's own free models, using provider/model ids in the model picker.
  • Zero credential handling: the plugin never reads or forwards auth.json or any credential; OpenCode keeps using its own login.
  • Shared local server: on the first request it starts one opencode serve instance on 127.0.0.1, waits for the listening line, runs a health check, and restarts the server if it crashes.
  • Controlled tool use: restricted tools such as shell, file edits, and web fetch go through DSH's approval prompt, and can be configured to run without asking or to be rejected.
  • Configurable settings: binary path, attaching to an already running server with its password, session working directory, per-turn timeout, model list refresh interval, and whether tool activity is shown.
  • Clear compatibility: works with DSH 0.2.x on desktop and CLI/headless profiles, requires OpenCode 1.14.19 or newer including 2.x, tested end to end on Windows and via CI on Linux.

How to Use This Plugin?

Install OpenCode on your machine and confirm it runs; paid providers need a login while free models do not. Then add the plugin through the DSH desktop plugin manager or your CLI profile, restart DSH, open the model picker, and choose a model under "OpenCode (local)". To adjust behavior, edit the provider under Settings → Models or change the matching fields in your profile config, for example pointing binaryPath at your opencode executable, attaching to a server you already run, or setting the session working directory and turn timeout. If opencode cannot be found, the first request explains how to install it or where to point the binary path.

How to Troubleshoot This Plugin?

  • The plugin reports that opencode cannot be found: the executable is not on PATH; install OpenCode as prompted or set binaryPath to the actual executable.
  • The model list is empty or stale: make sure you are signed in to the relevant providers in OpenCode, and lower modelRefreshSeconds to re-read the list sooner.
  • Restricted tools are rejected: check askForApproval and allowRestrictedTools; when approval is off, restricted tools are rejected outright.
  • Attaching to an existing server fails: confirm serverUrl and the password variable for your OpenCode version, since 1.x and 2.x use different environment variable names.

This page is an independent rewrite of the plugin's official README — for authoritative documentation and the latest changes, refer to the source: mateenahmed737/dsh-plugin-opencode-local. The plugin is third-party code that runs on your machine once installed; inclusion does not imply endorsement — please review the source before installing.

Install, update, and uninstall this plugin in the Plugin Market of DeepSeek Harness's DSH Plugin Hub
ChatGPTClaudeGrok / X / CursorGemini

DSH Plugin FAQ