This skill should be used when the user asks to "build a computer-use agent", "automate a GUI with an AI agent", "when to use computer use vs an API", "make browser automation reliable", or "design screenshot-driven agent actions".
The Computer Use Automation skill helps you design AI agents that operate a graphical interface the way a person does — take a screenshot, reason about what is on screen, then click, type, scroll, or navigate, and repeat. It covers the core perception→reason→action loop, the decision of when computer-use is the right tool versus a structured API/MCP tool (prefer a real API whenever one exists; reach for computer-use only for GUIs with no programmatic surface), reliability patterns (grounding every action in the current screenshot, verifying after each step, recovering from misclicks), safety guardrails (confirmation gates for destructive actions, sandboxing, avoiding blocking dialogs), and how to evaluate a computer-use agent. It is model-agnostic — the patterns apply to any computer-use-capable model and any GUI tool surface.
Clarify First
Before designing or auditing a computer-use agent, confirm these inputs. If any is unknown or vague, ASK — do not assume:
Does a real API/MCP tool exist? — whether the target exposes an API, SDK, CLI, or MCP server, or is GUI-only (the single biggest factor; if a real API exists, prefer it and skip computer-use)
Task & risk — what the agent must accomplish and whether any step is destructive or irreversible (delete, send, pay, submit), which sets the confirmation gates and sandboxing
Which tool — advise on tool choice for a target, or lint a planned action sequence for safety (selects tool_choice_advisor.py vs action_safety_linter.py)
Stop rule: ask only the 2-3 that most change the output. If the user says "just draft it," proceed and list your assumptions at the top of the artifact.
Quick Start
# Decide computer-use vs API/MCP for a target
python scripts/tool_choice_advisor.py --api-exists no --gui-stability high --volume low --json
# Lint a planned action sequence for safety/reliability gaps
python scripts/action_safety_linter.py --file planned_actions.json
# Read actions from stdin and emit a markdown risk report
echo '[{"type":"click","target":"Delete"},{"type":"submit","target":"Confirm"}]' \
| python scripts/action_safety_linter.py --format markdown
Tools Overview
Tool
Purpose
Key Flags
tool_choice_advisor.py
Recommend computer-use vs structured API/MCP for a target, with rationale
Scan a planned action list for destructive verbs, missing verification, missing confirmation gates, and dialog-triggering patterns
--file, --format, --json
All scripts: Python 3 standard library only, argparse CLI, --json and human-readable output. Run --help for full usage.
Workflows
Decide and Design a Computer-Use Agent
Run tool_choice_advisor.py with the target's API/MCP availability, GUI stability, and volume — if it says "use API/MCP," stop and build against the real interface instead.
If computer-use is justified, draft the action plan as the screenshot→reason→action loop: each step re-grounds on a fresh screenshot before acting.
Add a verification observation after every state-changing action (read back the resulting screen, not the intent).
Insert confirmation gates before any destructive/irreversible step and choose a sandbox (throwaway profile, test account, isolated VM/container).
Audit a Planned Action Sequence
Express the plan as a JSON/text list of actions (type, target, optional verified/confirmed).
Run action_safety_linter.py --file plan.json to flag risky verbs, unverified state changes, ungated destructive actions, and dialog-triggering patterns.
Re-run until clean, then dry-run in the sandbox before any real target.
Reference Documentation
Computer Use Patterns - The action loop; computer-use vs structured-tool decision matrix; reliability patterns (grounding, verification, recovery); safety guardrails (confirmation gates, sandboxing, blocking dialogs); evaluation approach; and common failure modes.
Common Patterns
Ground Every Action in the Current Screenshot
Never act on a stale screenshot or a remembered layout — re-capture before each action.
Reference elements by what is visible now (label, position) rather than a cached coordinate from a prior turn.
After acting, take a fresh screenshot and confirm the expected change actually happened before continuing.
Gate Destructive Actions and Sandbox by Default
Require an explicit confirmation step before delete, send, pay, submit, or any irreversible action.
Run in a sandbox first: throwaway browser profile, test account, or isolated VM/container.
Avoid flows that spawn blocking modal/native dialogs (file pickers, OS print dialogs) that the agent cannot see or dismiss; prefer paths that keep state on the page.
Prefer the Real Interface When It Exists
A documented API, SDK, CLI, or MCP tool is more reliable, cheaper, and more verifiable than pixels — use it.
Reserve computer-use for genuinely GUI-only targets, one-off tasks, or bridging gaps an API does not cover.
For high-volume or business-critical flows, the cost of computer-use flakiness usually justifies building or requesting an API.
1---2name: computer-use-automation3description: This skill should be used when the user asks to "build a computer-use agent", "automate a GUI with an AI agent", "when to use computer use vs an API", "make browser automation reliable", or "design screenshot-driven agent actions".4license: MIT + Commons Clause5---67# Computer Use Automation
89> **Category:** Engineering
10> **Domain:** AI Agents
1112## Overview
1314The **Computer Use Automation** skill helps you design AI agents that operate a graphical interface the way a person does — take a screenshot, reason about what is on screen, then click, type, scroll, or navigate, and repeat. It covers the core perception→reason→action loop, the decision of when computer-use is the right tool versus a structured API/MCP tool (prefer a real API whenever one exists; reach for computer-use only for GUIs with no programmatic surface), reliability patterns (grounding every action in the *current* screenshot, verifying after each step, recovering from misclicks), safety guardrails (confirmation gates for destructive actions, sandboxing, avoiding blocking dialogs), and how to evaluate a computer-use agent. It is model-agnostic — the patterns apply to any computer-use-capable model and any GUI tool surface.
1516## Clarify First
1718Before designing or auditing a computer-use agent, confirm these inputs. If any is unknown or vague, ASK — do not assume:
1920- [ ] **Does a real API/MCP tool exist?** — whether the target exposes an API, SDK, CLI, or MCP server, or is GUI-only (the single biggest factor; if a real API exists, prefer it and skip computer-use)
21- [ ] **Task & risk** — what the agent must accomplish and whether any step is destructive or irreversible (delete, send, pay, submit), which sets the confirmation gates and sandboxing
22- [ ] **Which tool** — advise on tool choice for a target, or lint a planned action sequence for safety (selects `tool_choice_advisor.py` vs `action_safety_linter.py`)
2324Stop rule: ask only the 2-3 that most change the output. If the user says "just draft it," proceed and list your assumptions at the top of the artifact.
2526## Quick Start
2728```bash
29# Decide computer-use vs API/MCP for a target
30python scripts/tool_choice_advisor.py --api-exists no --gui-stability high --volume low --json
3132# Lint a planned action sequence for safety/reliability gaps
33python scripts/action_safety_linter.py --file planned_actions.json
3435# Read actions from stdin and emit a markdown risk report
36echo '[{"type":"click","target":"Delete"},{"type":"submit","target":"Confirm"}]' \
37 | python scripts/action_safety_linter.py --format markdown
38```
3940## Tools Overview
4142| Tool | Purpose | Key Flags |
43|------|---------|-----------|
44| `tool_choice_advisor.py` | Recommend computer-use vs structured API/MCP for a target, with rationale | `--api-exists`, `--gui-stability`, `--volume`, `--reversible`, `--json` |
45| `action_safety_linter.py` | Scan a planned action list for destructive verbs, missing verification, missing confirmation gates, and dialog-triggering patterns | `--file`, `--format`, `--json` |
4647All scripts: Python 3 standard library only, argparse CLI, `--json` and human-readable output. Run `--help` for full usage.
4849## Workflows
5051### Decide and Design a Computer-Use Agent
521. Run `tool_choice_advisor.py` with the target's API/MCP availability, GUI stability, and volume — if it says "use API/MCP," stop and build against the real interface instead.
532. If computer-use is justified, draft the action plan as the screenshot→reason→action loop: each step re-grounds on a fresh screenshot before acting.
543. Add a verification observation after every state-changing action (read back the resulting screen, not the intent).
554. Insert confirmation gates before any destructive/irreversible step and choose a sandbox (throwaway profile, test account, isolated VM/container).
5657### Audit a Planned Action Sequence
581. Express the plan as a JSON/text list of actions (`type`, `target`, optional `verified`/`confirmed`).
592. Run `action_safety_linter.py --file plan.json` to flag risky verbs, unverified state changes, ungated destructive actions, and dialog-triggering patterns.
603. Resolve each finding — add verification steps, add confirmation gates, replace blocking-dialog flows.
614. Re-run until clean, then dry-run in the sandbox before any real target.
6263## Reference Documentation
6465- [Computer Use Patterns](references/computer-use-patterns.md) - The action loop; computer-use vs structured-tool decision matrix; reliability patterns (grounding, verification, recovery); safety guardrails (confirmation gates, sandboxing, blocking dialogs); evaluation approach; and common failure modes.
6667## Common Patterns
6869### Ground Every Action in the Current Screenshot
70- Never act on a stale screenshot or a remembered layout — re-capture before each action.
71- Reference elements by what is visible now (label, position) rather than a cached coordinate from a prior turn.
72- After acting, take a fresh screenshot and confirm the expected change actually happened before continuing.
7374### Gate Destructive Actions and Sandbox by Default
75- Require an explicit confirmation step before delete, send, pay, submit, or any irreversible action.
76- Run in a sandbox first: throwaway browser profile, test account, or isolated VM/container.
77- Avoid flows that spawn blocking modal/native dialogs (file pickers, OS print dialogs) that the agent cannot see or dismiss; prefer paths that keep state on the page.
7879### Prefer the Real Interface When It Exists
80- A documented API, SDK, CLI, or MCP tool is more reliable, cheaper, and more verifiable than pixels — use it.
81- Reserve computer-use for genuinely GUI-only targets, one-off tasks, or bridging gaps an API does not cover.
82- For high-volume or business-critical flows, the cost of computer-use flakiness usually justifies building or requesting an API.
Run npx skillmds@latest add borghei/computer-use-automation in your terminal (requires Node.js), paste this page's agent-chat prompt into Claude, Cursor, or any MCP-connected agent, or download the SKILL.md file and copy it into your agent's skills directory.
This skill should be used when the user asks to "build a computer-use agent", "automate a GUI with an AI agent", "when to use computer use vs an API", "make browser automation reliable", or "design screenshot-driven agent actions". It is listed under AI & ML on SkillMD.
This skill has not completed SkillMD's automated safety review yet. Capability flags: executes scripts. SkillMD never runs a skill's scripts for you; review the SKILL.md before installing.
This skill is tagged as working with Claude Code, Claude.ai, OpenAI Codex. SKILL.md is an open format, so most agents that read a skills directory can load it too.
Yes. Installing skills from SkillMD is free. This skill is licensed under MIT + Commons Clause.
borghei (@borghei) published this skill. Their other Agent Skills are listed on their SkillMD profile.