# Browser Intent > Ejecuta una intención en lenguaje natural en el navegador vía page-agent (browser_act) cuando el objetivo es más fácil de describir que de seleccionar; se degrada con elegancia si falta configuración. Fuente: https://skillsagentes.com/skills/ruvnet/ruflo/browser-intent Markdown: https://skillsagentes.com/skills/ruvnet/ruflo/browser-intent.md Repositorio: https://github.com/ruvnet/ruflo Autor: ruvnet Licencia: MIT Actualizado: el mes pasado Coste de contexto: 54 tok instalada, 1.2k tok al activarse, 1.2k tok con todos los archivos del bundle Bundle: 1 archivo, 5 KB Permisos que pide: mcp__plugin_ruflo-core_ruflo__browser_act mcp__plugin_ruflo-core_ruflo__browser_open mcp__plugin_ruflo-core_ruflo__browser_snapshot mcp__plugin_ruflo-core_ruflo__browser_close mcp__plugin_ruflo-core_ruflo__aidefence_has_pii mcp__plugin_ruflo-core_ruflo__aidefence_is_safe bash read ## Instalación Un skill son archivos markdown: los mismos archivos valen para cualquier agente y lo único que cambia es el directorio de destino, es decir la bandera `--agent`. Añade `-g` para instalarlo en todos los proyectos de la máquina. ```bash # Claude Code npx -y skills add ruvnet/ruflo --skill browser-intent --agent claude-code # Cursor npx -y skills add ruvnet/ruflo --skill browser-intent --agent cursor # Codex npx -y skills add ruvnet/ruflo --skill browser-intent --agent codex # Gemini CLI npx -y skills add ruvnet/ruflo --skill browser-intent --agent gemini # Windsurf npx -y skills add ruvnet/ruflo --skill browser-intent --agent windsurf # Cline npx -y skills add ruvnet/ruflo --skill browser-intent --agent cline ``` ## Qué hace - Ejecuta una intención en lenguaje natural sobre el navegador (por ejemplo, 'haz clic en el botón de login') delegando en page-agent en vez de usar selectores explícitos. - Devuelve el resultado ya filtrado por AIDefence, con la traza completa de pasos (reflexión + acción + resultado de herramienta). - Se degrada con elegancia (degraded: true) si page-agent o un proveedor LLM compatible con OpenAI no está configurado, sin tratarlo como error a reintentar. ## Cuándo usarla - El elemento objetivo es más fácil de describir en palabras que de seleccionar de forma fiable (clases dinámicas, estructura ambigua). - Es una interacción puntual donde no vale la pena escribir una cadena de selectores. ## Cuándo no - Cuando ya se conoce el selector o ref exacto, porque browser_act añade latencia y coste de LLM que un selector directo no tiene. ## Qué la activa - "Haz clic en el botón de login usando lenguaje natural" - "Rellena el buscador con 'gatos' y envíalo" ## Antes de instalar - Requiere page-agent instalado (dependencia opcional) y una clave de proveedor LLM compatible con OpenAI (OPENROUTER_API_KEY, OLLAMA_API_KEY o una URL base propia). - makes network requests ## Archivos - SKILL.md — 5 KB ## SKILL.md Reproducido tal cual desde ruvnet/ruflo bajo MIT. Esta sección es el documento original y está en inglés. # Browser Intent Natural-language layer on top of the low-level `browser_*` selector tools. Where `browser-extract` and `browser-form-fill` compose selector-based primitives (`browser_click`, `browser_fill`, `browser_snapshot`), `browser-intent` lets the caller say what they want ("Click the login button", "Fill the search box with cats and submit") and delegates execution to [page-agent](https://github.com/alibaba/page-agent) — in-page injected JS that turns the DOM into text and drives an LLM tool-call loop against it. ## When to use - The target element is easier to describe in words than to select reliably (dynamic class names, ambiguous structure, A/B-tested markup). - A one-shot interaction where writing out a selector chain isn't worth it. - Prefer `browser_click` / `browser_fill` / `browser_snapshot` directly when you already know the exact selector or ref (`@e1`) — `browser_act` adds LLM latency + cost that a direct selector call doesn't. ## Steps 1. **Call `browser_act`** with a `task` string, and optionally `url` (navigates first) and `session` (default `"default"`): ``` mcp__plugin_ruflo-core_ruflo__browser_act({ task: "Click the login button", url: "https://example.com/account", session: "my-session" }) ``` 2. **Read the response contract**: - `{ success: true, result, steps, history, contentFlagged, llmSource }` — the intent executed. `result` is the AIDefence-gated final text page-agent produced; `history` is the full step trace (reflection + action + tool result per step); `steps` is `history.length`. - `{ success: true, degraded: true, reason, hint }` — page-agent isn't installed, or no OpenAI-compatible LLM provider is configured. **Never treat `degraded: true` as an error to retry** — surface the `hint` and fall back to selector-based `browser_*` tools instead. - `{ success: false, error, ... }` — a real failure (browser open failed, injection failed, execution timed out, or page-agent's own `execute()` reported `success:false`). 3. **On `contentFlagged: true`**, the returned `result` has already been redacted by AIDefence (PII or a prompt-injection/threat pattern was detected in the page-agent output) — do not attempt to recover the original text. 4. **Prefer a recorded session** (`browser-record`) when the interaction matters enough to replay later; `browser_act` itself does not open an RVF container — it operates on whatever session id you pass (or `"default"`). ## Provider requirements (why this degrades so often) `page-agent` calls its LLM directly from the browser page context via a plain OpenAI-compatible `POST {baseURL}/chat/completions`. That means: - A bare `ANTHROPIC_API_KEY` is **not sufficient** — Anthropic's native API is a different shape (`/v1/messages`). - Configure one of: `OPENROUTER_API_KEY` (OpenRouter, OpenAI-compatible), `OLLAMA_API_KEY` (Ollama Cloud, OpenAI-compatible), or `CLAUDE_FLOW_PAGE_AGENT_BASE_URL` + `CLAUDE_FLOW_PAGE_AGENT_API_KEY` for a custom OpenAI-compatible endpoint. - The real provider key **never** enters the page: `browser_act` starts a short-lived loopback HTTP proxy that holds the key server-side and injects the real `Authorization` header itself. The page only ever sees a `127.0.0.1` URL and a placeholder key string. ## Caveats - `page-agent` is an `optionalDependencies` entry (`npm i page-agent` if the doctor/degraded hint asks for it) — this plugin stays fully operational without it; you simply lose the natural-language layer and fall back to selector-based tools. - The npm bundle's demo auto-init tail (which would otherwise construct a second `PageAgent` instance against Alibaba's public test endpoint) is stripped before injection — you should never see traffic to a `page-ag-testing-*` host from this tool. - Every successful `browser_act` call best-effort records the intent + resulting trajectory into the `browser` memory namespace (ADR-174 distillation loop). This is fire-and-forget — a memory-store failure never fails the tool call. - `timeoutMs` (default 120000) bounds how long `browser_act` polls for `execute()` to settle; a slow multi-step intent may need a higher value. ## Dónde encaja - Categoría: [Automatización](https://skillsagentes.com/categorias/automatizacion.md) — Flujos de varios pasos que se ejecutan sin supervisión. - Creador: [ruvnet](https://skillsagentes.com/creators/ruvnet.md) — 275 skills en el directorio - [Todas las skills](https://skillsagentes.com/skills.md) - [Ranking de instalaciones](https://skillsagentes.com/ranking.md) ## Otras skills del mismo repositorio - [Harness Gepa](https://skillsagentes.com/skills/ruvnet/ruflo/harness-gepa.md): Inspecciona y audita genomas GEPA: carga y valida un genoma, renderiza el system prompt que compila, o clasifica los modos de fallo de una transcripción de ejecución. - [Deepseek Reason](https://skillsagentes.com/skills/ruvnet/ruflo/deepseek-reason.md): Completion en modo razonamiento contra deepseek-reasoner (R1) de DeepSeek. Devuelve el chain-of-thought por separado de la respuesta final. Lee DEEPSEEK_API_KEY y degrada si falta o la API no responde. - [Deepseek Chat](https://skillsagentes.com/skills/ruvnet/ruflo/deepseek-chat.md): Completion de un solo turno contra el modelo deepseek-chat de DeepSeek vía /v1/chat/completions. Lee DEEPSEEK_API_KEY y degrada con status:degraded si falta o la API no responde. Para tareas sin razonamiento. - [Adr Index](https://skillsagentes.com/skills/ruvnet/ruflo/adr-index.md): Construye o reconstruye el índice de ADRs y su grafo de dependencias ejecutando scripts/import.mjs, en vez de cientos de llamadas MCP. - [Agntcy Status](https://skillsagentes.com/skills/ruvnet/ruflo/agntcy-status.md): Muestra el estado de la integración AGNTCY/SLIM/CASA: si los paquetes están instalados, qué transporte está activo y si el enforcement de CASA está habilitado. --- Skills Agentes · [Índice de páginas en markdown](https://skillsagentes.com/sitemap.md) · [Inicio](https://skillsagentes.com/index.md)