browser-drivers
Select, configure, and troubleshoot LaVague Selenium and Playwright browser drivers safely.
- License 许可
- Apache-2.0
- 最近更新
- 2026-10-08
- Stars
- ★ 11
- Forks
- 3
01 前言 Front Matter
- name
- browser-drivers
- license
- Apache 2.0
- metadata
- { "disco-role": "operating" }
- description
- Select, configure, and troubleshoot LaVague Selenium and Playwright browser drivers safely.
- disable-model-invocation
- true
02 资源文件 3
- 参考文档references/browser-workflows.md8.7 KB
- 参考文档references/driver-reference.md7.8 KB
- 参考文档references/troubleshooting.md8.1 KB
03 SKILL.md 正文
LaVague browser drivers
Use this sub-skill when the task is to choose or configure a LaVague browser driver, verify browser runtime availability, connect an existing browser/session, or diagnose Selenium/Playwright browser failures.
Route here for
- Choosing
SeleniumDriverversusPlaywrightDriverfor a LaVagueActionEngineorWebAgent. - Configuring
headless, viewport size,user_data_dir, custom Selenium options, driver injection, or Playwright page factories. - Diagnosing missing Chrome/Chromedriver, missing Playwright browser binaries, GUI/headless mismatches, tabs, iframes, scrolling, screenshots, or Browserbase remote Selenium setup.
Route elsewhere
WorldModel,ActionEngine,WebAgent, agent logging, token counting, and normalagent.run()patterns: route to../core-web-agent/.- Provider contexts, OpenAI/Gemini/Anthropic/Fireworks credentials, embeddings, and retrievers: route to
../contexts-and-retrievers/. - Gradio,
agent.demo(), Chrome extension server, websocket driver server, orlavague-serve: route to../server-extension-gradio/. - QA generation or benchmark runner CLI behavior: route to
../qa-and-test-runner/.
Start points
- Read references/driver-reference.md for constructor signatures, driver capabilities, and feature support boundaries.
- Use references/browser-workflows.md for copyable Selenium/Playwright setup patterns, existing-session recipes, iframe/tab/scan behavior, and Browserbase notes.
- Use references/troubleshooting.md when browser construction fails, Playwright binaries are missing, headless/headed behavior is wrong, or a page with CAPTCHAs/pop-ups/iframes/tabs stalls.
- Run the safe probe before spending browser/API time:
python sub-skills/browser-drivers/scripts/lavague_driver_probe.py
The probe checks imports and local browser binary hints by default. It does not launch a browser unless --construct is provided.
Driver choice in one minute
- Prefer
SeleniumDriverfor the widest LaVague feature coverage: default install path, iframes, multiple tabs, element highlighting, scrolling, dropdowns, custom Selenium options, and Browserbase remote connection. - Use
PlaywrightDriveronly when the caller specifically wants Playwright or already has a Playwright page/context. Treat it as a smaller feature surface: do not promise Selenium feature parity, remote Browserbase support, or complete tab/headless-agent behavior without a local verification run. - Both driver constructors create a browser/page immediately. If the task only asks whether the environment is ready, run the bundled probe without
--constructfirst.
Minimal usage patterns
Selenium default:
from lavague.core import ActionEngine, WorldModel
from lavague.core.agents import WebAgent
from lavague.drivers.selenium import SeleniumDriver
driver = SeleniumDriver(headless=True)
action_engine = ActionEngine(driver)
agent = WebAgent(WorldModel(), action_engine)
# agent.get(url); agent.run(objective) belongs to the core-web-agent workflow.
Playwright selection:
from lavague.core import ActionEngine
from lavague.drivers.playwright import PlaywrightDriver
driver = PlaywrightDriver(headless=True)
action_engine = ActionEngine(driver)
Existing Chrome session for CAPTCHA/login-heavy sites:
from lavague.drivers.selenium import SeleniumDriver
driver = SeleniumDriver(headless=False, user_data_dir="/path/to/chrome-profile")
Do not hard-code profile paths or credentials in reusable scripts. Ask the caller for an explicit path at runtime.
Safety defaults
- Default probes and recipes here avoid model provider calls, downloads, public-site navigation, persistent servers, and browser launch.
--constructin the bundled probe is the explicit opt-in for browser launch. Passing--urlmay navigate to that URL; omit it for a blank-page construction check.- Browser examples can still require GUI support, browser binaries, matching drivers, provider credentials, and network access when escalated into full agent execution.
04 同仓库更多 Skills
obsidian-clipper-template-creator
Guide for creating templates for the Obsidian Web Clipper. Use when you want to create a new clipping template, understand available variables, or format clipped content.
obsidian-clipper-template-creator
Guide for creating templates for the Obsidian Web Clipper. Use when you want to create a new clipping template, understand available variables, or format clipped content.
python-api
Programmatic Object-Detection-Metrics API guidance for BoundingBox, BoundingBoxes, Evaluator, enums, coordinate conversion, AP/mAP semantics, and source-style import diagnostics.
file-evaluation
Folder-based PASCAL VOC AP/mAP evaluation from ground-truth and detection text files.
object-detection-metrics
Guides legacy Object-Detection-Metrics PASCAL VOC AP/mAP evaluation from detection text folders and direct Python API classes.
nx-workspace-patterns
Configure and optimize Nx monorepo workspaces. Use when setting up Nx, configuring project boundaries, optimizing build caching, or implementing affected commands.