- Inicio
- Plugins
- Herramientas y funciones
- dsh-browser
dsh-browser
lum1104/dsh-browser
Extensión de barra lateral para Chrome que permite a DSH operar tu navegador directamente, sin necesitar capacidades de visión.
Instalar
dsh plugin --profile web add github:lum1104/dsh-browserREADME
dsh Browser Control
English | 中文
Connect DeepSeek Harness to the Chrome tab you are already using. The model can read page content, click controls, fill forms, scroll, and navigate while preserving your login state, session, and cookies. A side panel provides the conversation UI.
dsh is DeepSeek AI's open-source, plugin-based agent harness. This repository provides a companion browser bridge plugin and Chrome MV3 extension as one standalone pnpm workspace.
The integration is text-only: pages become structured text with a numbered inventory of interactive elements, and the model addresses those elements by number. Screenshots never enter the model-facing pipeline.
Quick install
The standard dsh plugin command alone cannot install this project. The integration contains both a dsh bridge plugin and a Chrome MV3 extension, and the extension must also be built and installed in Chrome. Use the repository's one-line installer to set up both parts:
curl -fsSL https://raw.githubusercontent.com/Lum1104/dsh-browser/refs/heads/main/scripts/install.sh | bash
When the installer opens chrome://extensions, follow its instructions to load or reload dsh Browser Assistant. If dsh is already running, restart it after installation. See Detailed installation and usage for prerequisites, startup commands, updates, and developer installation.
[!IMPORTANT] The unscoped
dsh-browserpackage on npm belongs to a different project and is not affiliated with this repository. This project is not currently published as an npm package; use the installer above.
Performance
In a paired 60-run end-to-end benchmark on August 18, 2026, both backends completed all 30 assigned runs successfully, while dsh Browser Control required fewer model/tool round trips and finished faster:
| Backend | Success | Mean end-to-end latency | Mean browser tool calls |
|---|---|---|---|
| dsh Browser Control | 30/30 | 5.32 s | 3.4 |
| Matched Playwright baseline | 30/30 | 6.67 s | 4.7 |
The paired Playwright / extension duration ratio was 1.24 (95% CI 1.16–1.34): Playwright took about 24% longer, or equivalently, dsh Browser Control reduced latency by about 20% and saved 1.35 seconds per task on average. The suite used six browser tasks, five deterministic seeds, the same DSH profile and model (deepseek-v4-flash), and independently validated page state. See the benchmark methodology and reproduction guide.
Core capabilities
| Capability | Tool | Notes |
|---|---|---|
| Read page | browser_snapshot | Structured text snapshot: title, URL, main text, numbered controls, and masked form fields; delta: true returns only changes |
| Click element | browser_click | Click links, buttons, checkboxes, and other controls by inventory number |
| Fill forms | browser_type | React/Vue-compatible input; replace clears the field first |
| Press keys | browser_press | Keyboard events such as Enter, Tab, Escape, and arrow keys |
| Scroll | browser_scroll | Viewport scrolling: up, down, top, and bottom |
| Navigate | browser_navigate / browser_back / browser_forward / browser_reload | Navigation inside the controlled tab, with login state preserved |
| Read region | browser_get_text | Lazy-loaded or partial page text |
| Wait for stability | browser_wait | Page-load and render-settle detection |
Repository layout
packages/browser/bridge-browser/
cordis.patch.yml
extensions/dsh-browser/
scripts/install.sh
Why this design
- Your real browser, not a headless copy: the model works in the page you already have open, retaining logins, sessions, and cookies.
- A text-first model interface: numbered controls, stable IDs across snapshots, delta updates, and masked sensitive values make pages operable without vision.
- A narrow privacy boundary: passwords and payment-card values are always rendered as
••••and never leave the page. - A guarded bridge: authenticated handshakes protect remote connections, privileged gateway methods reject non-loopback callers, and the extension binds tools to one user-controlled tab.
Detailed installation and usage
Requirements: Node.js ^22.19 or >=24, Corepack/pnpm, and Google Chrome.
Install or update
For a managed installation, run:
curl -fsSL https://raw.githubusercontent.com/Lum1104/dsh-browser/refs/heads/main/scripts/install.sh | bash
The installer downloads main, builds and registers the bridge plugin, builds the Chrome extension into ~/.dsh/browser-extension, and opens chrome://extensions. On the first install, load that directory as an unpacked extension; on updates, click Reload. Restart dsh if it is already running.
To install the current branch from a source checkout instead:
git clone https://github.com/Lum1104/dsh-browser.git
cd dsh-browser
./scripts/install.sh
After pulling or switching revisions, rerun ./scripts/install.sh and reload the extension.
Start and use
Start the managed installation with:
cd ~/.dsh/dsh-browser && pnpm start
From a source checkout, run pnpm start in the repository root. To use the latest public dsh release instead:
npx @deepseek-ai/dsh web
Local use requires no configuration. Open an http:// or https:// page, click the DeepSeek whale icon, and wait for Connected. Existing tabs are instrumented on the first action; protected pages such as chrome:// and the Chrome Web Store are not supported.
Troubleshooting
Side panel stays "Not connected"
- Make sure dsh web is running locally (default
http://127.0.0.1:3080). - Verify the bridge is loaded: open
http://127.0.0.1:3080/ext/bridge-config. It should return JSON such as{"wsUrl":"ws://127.0.0.1:3080/ext/bridge"}. If it returns a web page instead of JSON, the running dsh predates the bridge registration — restart dsh and refresh the page; the extension reconnects on its own. - The extension probes ports 3080, 3081, and 3090 automatically. If dsh runs on another port — or you use a remote
--host 0.0.0.0deployment — set the address (and bridge token) in the side panel settings.
Development
The bridge plugin and Chrome extension are both members of this repository's workspace. Run all commands from the repository root. For the first development installation, run pnpm install.
pnpm run build
pnpm run typecheck
pnpm run test
pnpm --filter @yuxianglin/dsh-bridge-browser run build
pnpm --filter @yuxianglin/dsh-bridge-browser run typecheck
pnpm --filter @yuxianglin/dsh-bridge-browser run test
pnpm --filter dsh-browser-extension run build
pnpm --filter dsh-browser-extension run test
Notes:
- The bridge plugin must have a built
lib/before startup because the loader consumes it; bothscripts/install.shand the rootpnpm run buildbuild the plugin before the extension. - The dependencies of
@deepseek-ai/dshand the bridge plugin are pinned to the same tested public release line. An upgrade must update the manifests and lockfile together and rerun the root checks.
Security
- The bridge path sits outside the
/apitrust boundary and performs its own bearer-token authentication. - Privileged gateway methods such as
settings.*,credentials.*, andhost.open*reject non-loopback sources. - The model-facing pipeline is text-only; passwords and payment-card values never leave the page.
- When work begins, the assistant binds to the active tab (at prompt submission, or at the first direct browser-tool call). If you switch tabs manually, later browser actions pause and the side panel asks whether the assistant should continue on the original tab or follow the new one. Choosing the original tab permits background operation; the extension never silently retargets or changes your visible tab. Closing the controlled tab also pauses tools until you explicitly select the current page.
- Page-authored text is wrapped as untrusted input. The default
automode reads only the controlled tab without an extra prompt; privacy-sensitive users can selectaskfor per-read confirmation oroffto block reads entirely. Inaskmode, the read dialog can allow one read or persistently switch back toauto; this can be reversed in Settings. Read page text is sent to the selected model. - Click, type, keypress, navigation, history, and reload calls fail closed until the user approves them. An origin may be trusted for the current side-panel session (cleared when the last panel closes or the service worker restarts), while permanent trust is managed explicitly in Settings. Explicit cross-origin
browser_navigatecalls and unknown history destinations always prompt again.