Skip to main content
ClaudeWave
Slash Command1.1k repo starsupdated 3d ago

hep-browser

Use the Agentlas browser hardpoint for browser-required work.

Install in Claude Code
Copy
mkdir -p ~/.claude/commands && curl -fsSL https://raw.githubusercontent.com/agentlas-ai/Agentlas-OS/HEAD/.claude/commands/hep-browser.md -o ~/.claude/commands/hep-browser.md
Then start a new Claude Code session; the slash command loads automatically.

hep-browser.md

Update fallback: 자동 업데이트가 안 되면 `hephaestus update`를 한 번 실행하세요. 업데이트하지 않아도 현재 버전 명령은 그대로 동작합니다.

# /hep-browser

Use this when the task needs a real browser, page rendering, login-visible state,
click/form behavior, or JS-heavy evidence. Prefer the Agentlas browser hardpoint
first; do not route browser work through generic research commands unless this
command reports that the hardpoint is unavailable.

Behavior:
- `/hep-browser <url>` reads a rendered browser snapshot.
- `/hep-browser <url> "<instruction>"` or `/hep-browser <url> --act "<instruction>"`
  performs browser automation through `browser.agent_cli`, then captures a
  snapshot.
- If the Agentlas Browser CDP port is already live, the command attaches to it
  by default so logged-in Desktop/browser state is reused.
- Prefer the human-facing URL a person would type over app-shell automation
  URLs. For example, use `https://mail.google.com/` instead of
  `https://mail.google.com/mail/u/0/#inbox` unless that exact deep route is
  required. Add `--raw-url` to preserve the exact URL.
- `/hep-browser <url> --click @e1` clicks an explicit snapshot ref.
- `/hep-browser <url> --click-text "Compose"` clicks visible text without an
  LLM provider.
- Add `--wait-ms 2000` when a dynamic app opens dialogs after a short delay.
- Add `--read` to force snapshot-only mode when extra text is context rather
  than an action.
- Pass `--cdp`, `--profile`, `--auto-connect`, or `--headed` only when the user
  needs an existing Desktop/browser session or a specific browser launch mode.

Raw arguments: `$ARGUMENTS`

## Run

```bash
RUNNER=""
for candidate in \
  "$HOME/.agentlas/runtime/current/bin/hephaestus" \
  "${CLAUDE_PLUGIN_ROOT:+$CLAUDE_PLUGIN_ROOT/bin/hephaestus}" \
  "${PLUGIN_ROOT:+$PLUGIN_ROOT/bin/hephaestus}" \
  "${GEMINI_EXTENSION_ROOT:+$GEMINI_EXTENSION_ROOT/bin/hephaestus}" \
  "./bin/hephaestus"
do
  if [ -n "$candidate" ] && [ -x "$candidate" ]; then RUNNER="$candidate"; break; fi
done
[ -n "$RUNNER" ] || { echo "Hephaestus runtime not found. Run the installer first." >&2; exit 1; }
"$RUNNER" hep-browser "$ARGUMENTS"
```

## Answer Shape

1. Report whether `browser.agent_cli` was mounted or needs setup.
2. If setup is needed, show `hep-browser --setup` and `hep-browser --check`.
3. Include the receipt id and the browser module chain.

## Examples

```text
/hep-browser https://example.com
/hep-browser https://example.com "click the Docs link and report what changed"
/hep-browser https://example.com --act "open the pricing section" --cdp 9222 --keep-open
/hep-browser https://mail.google.com/ --click-text "Compose" --wait-ms 2000 --keep-open
/hep-browser https://example.com "summarize this page" --read
/hep-browser login page render check
/hep-browser --setup
/hep-browser --check
```

## Rules carried from the other runtime copies

These lines existed in one runtime's hand-maintained copy and not in the
longest one. They are kept verbatim rather than dropped — a rule that only
one runtime enforced was still a rule someone wrote on purpose.

- `$ARGUMENTS` Codex plugins cannot register slash commands, so this custom prompt is the explicit entrypoint:
- Prefer the Agentlas browser hardpoint first.
- - `/prompts:hep-browser <url>` reads a rendered browser snapshot.
- - `/prompts:hep-browser <url> "<instruction>"` or `/prompts:hep-browser <url> --act "<instruction>"` performs browser automation through `browser.agent_cli`, then captures a snapshot.
- - Use `--click @e1` or `--click-text "Compose"` for LLM-free browser primitives after the host has selected a ref/text target.
- ```bash RUNNER="" for c in "$HOME/.agentlas/runtime/current/bin/hephaestus" ./bin/hephaestus; do [ -x "$c" ] && RUNNER="$c" && break done [ -n "$RUNNER" ] || { echo "Hephaestus runtime not found.
- Run the installer first." >&2; exit 1; } "$RUNNER" hep-browser "$ARGUMENTS" ``` Report whether `browser.agent_cli` mounted, whether setup is needed, and the receipt id.
- For automation, also report the action, whether CDP/profile flags were used, and the final snapshot status.
- # Hephaestus Browser Use this for browser-required work:
- rendered pages, JS-heavy sites, click/form flows, or login-visible evidence.
- With a URL plus an explicit instruction, `hep-browser` runs browser automation through `browser.agent_cli` before taking the final snapshot.
- Use `--read` to force snapshot-only mode.
- Resolve the runner (`~/.agentlas/runtime/current/bin/hephaestus`, then `./bin/hephaestus`) and run:
- `"$RUNNER" hep-browser "<url-or-query>"` Report whether `browser.agent_cli` mounted, whether setup is needed, and the receipt id.
- For automation, also report the action and final snapshot status.
- `$ARGUMENTS` ```bash RUNNER="" for c in "$HOME/.agentlas/runtime/current/bin/hephaestus" ./bin/hephaestus; do [ -x "$c" ] && RUNNER="$c" && break done [ -n "$RUNNER" ] || { echo "Hephaestus runtime not found.
- Run the installer first." >&2; exit 1; } "$RUNNER" hep-browser "$ARGUMENTS" ``` Use this for rendered/browser-required work and report the `browser.agent_cli` status plus receipt id.
- With a URL and an explicit instruction, this performs browser automation before taking the final snapshot:
- ```text /hep-browser https://example.com "click the Docs link and report what changed" /hep-browser https://example.com --act "open pricing" --cdp 9222 --keep-open /hep-browser https://example.com "extra context only" --read ``` If setup is needed, show `hep-browser --setup` and `hep-browser --check`.
- # /hep-browser Use this for rendered pages, JS-heavy sites, click/form flows, login-visible state, or browser evidence.
- The request is the exact text the user typed after `/hep-browser`.
- ## How to run Run the shell block below verbatim, replacing only the `REQUEST` value.
- ```bash REQUEST="<replace with the exact text the user typed after /hep-browser>" case "$REQUEST" in "<replace"*) echo "REQUEST placeholder not filled -- substitute the user's request first." >&2; exit 2 ;; esac RUNNE