AGENT SKILL

Claude Code 界面自动化

claude-code-computer-use

使用 Claude Code 运行计算机使用(computer-use)风格的 UI 自动化循环,包含截图 → 决策 → 执行(screenshot → decide → act)的循环、安全护栏和有限步数执行。当用户要求让智能体执行 Claude 计算机使用行为、桌面/浏览器 UI 控制、点击/输入/滚动自动化,或在 Claude Code 中执行迭代式可视化任务时触发。

License 许可
MIT
最近更新
2026-11-14
Stars
★ 6
Forks
0

01 前言 Front Matter

name
claude-code-computer-use
description
Use Claude Code to run computer-use style UI automation loops with screenshot → decide → act cycles, safety guardrails, and step-bounded execution. Trigger when the user asks to make agents do Claude computer-use behavior, desktop/browser UI control, click/type/scroll automation, or iterative visual task execution in Claude Code.

03 SKILL.md 正文

Claude Code Computer Use

Run Claude Code as a bounded UI-control agent that observes screenshots, takes one action, re-checks state, and repeats until success or stop conditions.

Required loop

  1. Restate the user goal in one sentence.
  2. Define a max step budget (default 20).
  3. For each step, do exactly one UI action.
  4. After each action, capture a fresh screenshot.
  5. Verify expected change before continuing.
  6. Stop on success, ambiguity, or budget exhaustion.

Tool contract to enforce

Require these tool primitives (or closest equivalents):

  • screenshot()
  • click(x,y) / double_click(x,y)
  • type(text) / key(combo)
  • scroll(delta)
  • Optional: ocr(region) / accessibility_tree()

Never take multiple UI actions in a single reasoning step.

Safety policy

  • Allowlist app/site scope before starting.
  • Ask before destructive actions (delete, send, purchase, publish, submit).
  • If target is unclear for 2 consecutive steps, pause and ask human.
  • Log every step with: intention, action, result.

Claude Code invocation pattern

Use non-interactive Claude Code mode for deterministic logs:

claude --print --permission-mode bypassPermissions "<task prompt>"

Task prompt template:

You are controlling a UI via tools.
Goal: <goal>
Allowed scope: <apps/sites>
Max steps: <N>
Rules:
- One action per step.
- After each action, screenshot and verify.
- If uncertain for 2 steps, stop and ask.
- Ask before destructive actions.
Return a step log and final status: success | blocked | needs-human.

Antigravity/Desktop reliability notes

When automating Antigravity on macOS with Peekaboo:

  1. Prefer peekaboo see --app Antigravity --annotate first and target element IDs from the snapshot.
  2. Use explicit element targeting (--on elem_x) over raw coordinates whenever possible.
  3. If multiple Antigravity windows exist, confirm the active manager window by checking window_title in see output.
  4. For chat input, verify a textField is present before paste/send.
  5. Re-capture state after send and confirm the prompt appears as a new conversation item.

OAuth vs key clarification

  • Hermes agent auth should remain OAuth-based.
  • If visual analysis fails with OPENAI_API_KEY not found, that is specific to optional Peekaboo --analyze image analysis backend, not the Hermes agent auth path.

Completion criteria

Declare completion only when:

  • Goal state is visible in screenshot evidence, or
  • You are blocked and provide the exact blocker + required human input.

Always return concise evidence:

  • Final status
  • Last 3 step logs
  • Screenshot/file references (if available)

04 同仓库更多 Skills

jleechanorg
jleechanorg/jleechan-skills

disk-reclaim-playbook

Use Disk Magician to diagnose disk growth or qualify cleanup on macOS or Linux.

★ 6
jleechanorg
jleechanorg/jleechan-skills

claudea-bench

Compare `claudea` and normal `claude` on a fair split of comparable work by default; use `--strict` for duplicate runs of the exact same task.

★ 6
jleechanorg
jleechanorg/jleechan-skills

pr

Alias for the canonical pr-lifecycle PR workflow skill (/pr-workflow, /prw).

★ 6
jleechanorg
jleechanorg/jleechan-skills

whisper

OpenAI's general-purpose speech recognition model. Supports 99 languages, transcription, translation to English, and language identification. Six model sizes from tiny (39M params) to large (1550M params). Use for speech-to-text, podcast transcription, or multilingual audio processing. Best for robust, multilingual ASR.

★ 6
jleechanorg
jleechanorg/jleechan-skills

webapp-testing

Toolkit for interacting with and testing local web applications using Playwright. Supports verifying frontend functionality, debugging UI behavior, capturing browser screenshots, and viewing browser logs.

★ 6
jleechanorg
jleechanorg/jleechan-skills

pr-report

This skill should be used when the user asks for a PR report, PR audit, PR delta analysis, /pr-report, or wants per-PR summary with delta files/lines. Generates a structured report for one or more open PRs covering purpose, files changed, +/− line counts, /code-standards + /thermo review findings, /ponytail simplification opportunities, file-overlap combination candidates, and /green status per pr-green-definition. Output: machine-readable JSONL + human-readable markdown. Read-only by default; can apply simplifications if user opts in.

★ 6