LHKong7/dsh-browser-runtime ↗★ 1

dsh-browser-runtime

Stateful, provider-neutral browser environments for DeepSeek Harness agents 适合需要让 Agent 执行网页浏览、信息提取及截图等自动化任务的用户。

패키지
dsh-browser-runtime
호환성
미검증
Harness peer 범위
0.1.1-rc.2
Cordis peer 범위
^4.0.1
버전
0.1.2
라이선스
MIT
최근 업데이트
2026. 8. 27.

설치

$npx -p @deepseek-ai/dsh dsh plugin --profile web add github:LHKong7/dsh-browser-runtime

Configuration

The bundle's cordis.patch.yml selects Playwright, uses ephemeral Agent environments, blocks private networks, and registers the complete browser tool suite. A user profile can replace any row by id; DSH patches replace the complete config, so restate every field for that row.

Runtime row:

- id: browser-runtime
  config:
    provider: playwright
    maxTextChars: 60000
    maxTransitionsInMemory: 500
    cleanupTimeoutMs: 10000
    checkpointTtlMs: 0
    maxCheckpoints: 100

Playwright row:

- id: browser-playwright
  config:
    headless: true
    navigationTimeoutMs: 30000
    actionTimeoutMs: 10000
    maxElements: 100
    maxScreenshotPixels: 16000000
    maxScreenshotBytes: 16777216
    network:
      mode: strict # strict | allowlist | unrestricted
      allowHosts: []
      allowCidrs: []
      denyCidrs: []
    # checkpointRoot: /private/absolute/path

Tool row:

- id: tool-browser
  config:
    provider: playwright
    persistence: ephemeral # or resume
    timeoutMs: 30000
    observeMode: summary # or interactive, document
    maxTextChars: 12000
    maxElements: 100
    # credentials:
    #   requireApproval: true
    #   refs:
    #     ci-token: DSH_BROWSER_CI_TOKEN

observeMode sets the default for calls that name no mode, and maxTextChars/maxElements cap what any single response may carry. The runtime row's maxTextChars is the separate ceiling on what one observation retains from the page.

Runtime checkpoint retention is bounded by checkpointTtlMs (0 retains indefinitely) and maxCheckpoints. Pruning runs when the durable index loads; ctx.browserRuntime.pruneCheckpoints() and listCheckpoints() expose it, and dsh-browser-runtime checkpoints [--clear] lists or deletes the Provider-private payloads. A record keeps the Provider build that wrote it, and a restore refuses a payload from a different build.

With persistence: resume, checkpoints restore inside the same process from the runtime's in-memory index. Cross-process restore additionally requires DSH's ctx.storageDomain; the Web profile already mounts it. Checkpoint metadata goes to the browser_runtime domain, while Playwright stores the sensitive storage-state payload under $DSH_HOME/browser-runtime/providers/playwright/v1/checkpoints with owner-only permissions.