JeremyWangCY/dsh-pc-pilot ↗★ 1

dsh-pc-pilot

PC-Pilot - lightweight Windows + Chromium computer-use runtime, CLI, and DeepSeek Harness host plugin. 适合需要让Agent控制Windows系统、获取窗口状态及操作浏览器的任务。

Package
dsh-pc-pilot
Compatibility
Unverified
Version
0.4.10
License
MIT
Last updated
Sep 16, 2026

Install

$npx -p @deepseek-ai/dsh dsh plugin --profile web add github:JeremyWangCY/dsh-pc-pilot

Usage

The plugin registers one global tool, computer. Typical flow:

  1. computer { action: "list_apps" } — running apps with pids, exact app_identity / identity_key, window titles, hwnds and rects.
  2. computer { action: "get_window_state", window: { id, app }, include_screenshot: true, include_text: true } — indexed accessibility tree with stable element_id, revision/delta metadata, a window screenshot and snapshot_id.
  3. Act on the state — element actions include the snapshot_id from the same observation. Browser results return a reusable browser: { endpoint, tab_id } target that can be passed back unchanged; element actions can use either the raw browser_element token or the short @eN ref returned by browser_state / browser_observe.
  4. Observe again only when state is stale/unknown, the target changed, or the next decision needs information you do not already have. Desktop element_index values remain bound to the get_window_state that produced them.

Action reference (57 actions)

ActionPurpose
list_apps / list_windows / list_displaysEnumerate apps with exact identity / per-app windows / display topology
get_app_identityResolve a process/window to stable Win32 path or packaged AUMID identity; lazily return product/version/company and optionally verified Authenticode signer evidence
get_window_stateIndexed UIA tree + stable element ids + revision/delta metadata + per-window PNG screenshot + document text
clickCoordinate click or snapshot-bound element_index click
set_value / type_text / perform_secondary_action / select_textElement-level write, text entry, named UIA pattern, text-range selection
press_key / hold_keyKey chords and timed holds
scrollStandard scroll_x/scroll_y (including target-window horizontal UIA scrolling), or legacy amount plus direction
move / mouse_move / mouse_down / mouse_upStandard move plus raw mouse primitives
dragStandard path of {x, y} points or legacy endpoints; element move (background) or real SendInput drag (foreground)
screenshot / zoomFull-display or region capture; crop screenshot_path from a prior capture (path remains accepted by the runtime for compatibility)
switch_display / cursor_positionDefault capture display; real cursor location
launch_app / waitLaunch an app behind the active work without activating it; the window stays normally renderable for WGC/UIA instead of remaining minimized. Registered Windows activation protocols such as ms-settings:display are supported. Delegated app launches return a target only when exactly one new window is safely identifiable; pause between actions
activate_window / minimize_window / close_window / get_windowBring window to foreground / minimize it directly with Win32 (no title-bar coordinates) / request a graceful WM_CLOSE and verify disappearance (otherwise returns window_close_unconfirmed) / query fresh window geometry & metadata
read_clipboard / write_clipboardClipboard round-trip
browser_tabs / browser_state / browser_observe / browser_history / browser_back / browser_forward / browser_waitManage exact tabs; browser_observe gives compact ref-only semantic state while browser_state keeps raw tokens for compatibility; navigate history and wait on page readiness/URL/text without synthetic sleeps
browser_events / browser_downloadsCursor-based console/network/lifecycle evidence; Chromium download progress and completed AI-profile files
browser_shutdownClose the entire browser only when this PC-Pilot tool instance launched it
browser_click / browser_type / browser_replace / browser_keyOperate a raw token or compact @eN ref from the latest state/observe result; stale or changed targets are rejected
browser_click_pointClick browser-viewport coordinates only when bound to an exact screenshot_id; both explicit observations and post-action screenshots remain chainable for 30 seconds while the tab/document/URL identity is unchanged
browser_uploadSelect 1–20 explicit absolute local files on an already-observed `` and verify the browser received them; does not submit the surrounding form

Key parameters

ParameterDefaultNotes
dispatchbackgroundUIA patterns + window messages; never steals focus. foreground uses real SendInput — pick it per task only when the user asked for real control or the essential action has no background path.
activatefalselaunch_app only: normal foreground launch. The default keeps the new window renderable but non-activated and places it behind the active work; use true only when the user explicitly wants it brought forward.
overlaytrueShow the click-through cursor at each action point; it auto-hides 3 s after the last action.
include_screenshottrueCapture a per-window PNG in get_window_state.
include_textfalseInclude the indexed accessibility tree and document text when an element action is needed. On a window-targeted wait, include it in the post-wait observation to check application readiness without a second round-trip.
wait_for—On a window-targeted wait, wait for accessibility_present (any UIA descendant) or accessibility_available (a complete UIA tree). A timeout is an explicit, retry-safe wait_condition_timeout.
app—pid number, process name, or window-title substring; same-titled duplicate windows are rejected unless window_index or hwnd identifies one, while differently titled windows of one app auto-resolve and return chosen_hwnd.
identity_key—Exact application identity returned by discovery. Packaged apps use aumid:; Win32 apps use win32:. Prefer it for continuation targeting once an app is known.
verify_signaturetrueget_app_identity only: verify Authenticode signer/publisher and cache the result by executable path.
snapshot_id—Required for desktop element actions; use the id from the latest get_window_state { include_text: true }.
element_id—Stable UIA identity returned by get_window_state; optional for normal actions, required for safe element remapping during foreground_once recovery.
expect—Optional postcondition: verify window state, accessibility change, element value, text, browser URL/text/readiness, or completed download after the action.
when—Optional precondition using the same condition vocabulary as expect; checked before dispatch, with default timeout_ms: 0. If unmet the action is not_executed. Useful as a lightweight gate inside short actions batches.
recoverynoneforeground_once retries only a conclusively non-executed background_unavailable action. Unknown outcomes are never replayed.
browser / browser_endpoint / tab_id / browser_element / event_cursor—Prefer the reusable browser: { endpoint, tab_id } target returned by PC-Pilot; the separate endpoint/tab fields remain compatible. browser_element accepts a raw semantic token or compact @eN ref.
x / y—Window-local pixels with app/hwnd, matching the Computer Use coordinate model; screen coordinates without a target. Set coordinate_space: "screen" only for an explicit absolute click.
button / click_count / keysleft / 1 / —Mouse button and legacy click repetitions; keys supplies standard keypress chords and mouse modifiers. Foreground mouse actions and validated native-window background clicks preserve the modifier state; unsupported background paths report background_unavailable.
actions—Ordered batch of action objects (maximum 20). Steps may use when before dispatch and expect after dispatch; the batch stops at the first unmet/failed/uncertain step. Intended for short predictable sequences, not scripted branching.
displayprimary1-based display index for screenshot / switch_display.