[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M71M83X27AC8A0F8GSMKS1YT":3,"skill-same:01M71M83X27AC8A0F8GSMKS1YT":79},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":39,"linkOnly":40,"markdownContent":41,"markdownBody":42,"frontMatter":43,"refName":48,"commitSha":49,"skillDirectory":50,"forksCount":14,"repositoryHtmlUrl":51,"repositoryHomepageUrl":52,"ownerHtmlUrl":53,"ownerBlogUrl":6,"ownerDescription":6,"updatedAt":54,"install":55,"resources":68},"01M71M83X27AC8A0F8GSMKS1YT","agentic-browser-testing",null,"Goal-driven E2E testing where a browser agent (Playwright MCP \u002F computer-use) reads a natural-language goal and explores the app via the accessibility tree to assert outcomes — no pre-written script. Covers when intent-driven beats scripted, making agent runs deterministic (pinned model, temperature 0, seeded data, bounded steps, explicit success assertion, snapshot-not-pixel), cost\u002Flatency control, the accessibility-tree-first interaction model, CI gating, and graduating a stable run into a scripted Playwright test. Use when: \"agentic browser test,\" \"goal-driven browser test,\" \"let an agent explore the app,\" \"natural-language E2E,\" \"browser agent smoke test,\" \"Playwright MCP test.\" Not for: Writing\u002Fmaintaining deterministic scripted Playwright tests — that is playwright-automation. Testing your product's OWN LLM features — that is ai-system-testing. Related: playwright-automation, ai-system-testing, exploratory-testing, test-reliability, qa-project-context.","pattanation\u002FNorvik","pattanation","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F235419268?v=4","01M71M5THHYYB15ME8R2E4FCZG","Patta","01M71M5TJM1NDM992M8PDKYR2K",0,"MIT","https:\u002F\u002Fgithub.com\u002Fpattanation\u002FNorvik\u002Fblob\u002Fclaude\u002Finstall-gsd-build-foQdV\u002F.agents\u002Fskills\u002Fagentic-browser-testing\u002FSKILL.md",[],[19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38],"testing","agentic","browser","agentic browser","agentic browser testing","browser testing","natural-language","when","gating","writing","MCP","qa","pixel","ci","explore","project","model","browser test","reliability","app","2026-11-10 10:56:23",false,"---\nname: agentic-browser-testing\ndescription: >-\n  Goal-driven E2E testing where a browser agent (Playwright MCP \u002F computer-use) reads a\n  natural-language goal and explores the app via the accessibility tree to assert outcomes —\n  no pre-written script. Covers when intent-driven beats scripted, making agent runs\n  deterministic (pinned model, temperature 0, seeded data, bounded steps, explicit success\n  assertion, snapshot-not-pixel), cost\u002Flatency control, the accessibility-tree-first\n  interaction model, CI gating, and graduating a stable run into a scripted Playwright test.\n  Use when: \"agentic browser test,\" \"goal-driven browser test,\" \"let an agent explore the app,\"\n  \"natural-language E2E,\" \"browser agent smoke test,\" \"Playwright MCP test.\"\n  Not for: Writing\u002Fmaintaining deterministic scripted Playwright tests — that is\n  playwright-automation. Testing your product's OWN LLM features — that is ai-system-testing.\n  Related: playwright-automation, ai-system-testing, exploratory-testing, test-reliability, qa-project-context.\nlicense: MIT\nmetadata:\n  author: kindlmann\n  version: \"1.0\"\n  category: ai-qa\n---\n\n\u003Cobjective>\nA scripted Playwright test breaks the moment a button moves or a class renames; writing one\nfor a dashboard that changes weekly is a maintenance treadmill. This skill stands up a\ngoal-driven browser agent instead: it reads a natural-language goal, explores the app via the\naccessibility tree (Playwright MCP `browser_snapshot`), and asserts the outcome against an\nexplicit oracle. The failure mode it prevents is the one that makes teams distrust agents — an\nagent that reports \"success\" while stuck on the login page because nothing forced it to prove\nwhere it landed. You leave with a deterministic, CI-gated agent run and a graduation path to a\ndurable scripted test once the flow stabilizes.\n\u003C\u002Fobjective>\n\n## Quick Route\n\n| Situation | Go to |\n|-----------|-------|\n| Stand up a goal-driven run from scratch | Discovery + `references\u002Fsetup.md` |\n| Decide agentic vs scripted for a given flow | Fit: Intent-Driven vs Scripted |\n| Agent passes one run, fails the next | Determinism |\n| \"How does it click without screenshots?\" | Interaction Model |\n| Runs are slow \u002F burning tokens | Cost and Latency |\n| Agent reports false success | Success Assertion (the Oracle) |\n| Flow is stable — make it permanent | Graduation → `references\u002Fgraduation-and-ci.md` |\n| Block a merge on the goal | CI Gating → `references\u002Fgraduation-and-ci.md` |\n| Canvas \u002F no accessibility tree | Canvas Fallback → `references\u002Fgraduation-and-ci.md` |\n\n## Discovery Questions\n\nFirst, check `.agents\u002Fqa-project-context.md` in the project root and skip anything it already\nanswers (stack, environments, seed\u002Freset tooling, model access).\n\n1. **Which flow, and how often does its UI change?** Fast-changing\u002Fexperimental UI favors\n   intent-driven; a stable critical path (login) favors scripted. This decides the whole approach.\n2. **Is there a seeded fixture and a way to reset state?** Determinism is impossible without\n   seeded data and a per-run reset. If neither exists, that is step zero.\n3. **Can you deep-link past auth to a seeded entry point?** Re-driving login every run is the\n   biggest avoidable cost; a seeded entry URL scopes the goal and cuts steps.\n4. **What is the unambiguous success oracle?** Specific account text, a `\u002Fdashboard` URL, an\n   order number — plus a forbidden state. \"No error\" is not an oracle.\n5. **Does the target render to canvas \u002F WebGL?** No accessibility tree means snapshot-first\n   won't work; plan the vision fallback or instrument the canvas with ARIA.\n6. **Which model and budget?** Pin a model id and a step budget up front; tier cheap steps to\n   Haiku 4.5 \u002F Sonnet 4.6 and reserve Opus 4.8 for genuinely ambiguous flows.\n\n---\n\n## Core Principles\n\n1. **Intent, not instructions — but only where churn earns it.** The agent reads a goal and\n   finds its own path through the accessibility tree, so it survives a moved button or renamed\n   class that would break a selector. That resilience costs 2-5x the time and money of a\n   scripted run, so spend it on fast-changing UI and hard-to-locate flows, not on stable\n   critical paths.\n\n2. **An agent run is untrustworthy until it is deterministic.** Same goal, same seeded app\n   must produce the same verdict. That requires temperature 0, a pinned model id, seeded data\n   with a reset, a bounded step budget, and an explicit pass\u002Ffail assertion. Without these you\n   have a coin flip, not a test.\n\n3. **The oracle lives outside the agent.** Never let the LLM self-grade \"looks good.\" Success\n   is a checkable assertion against the final `browser_snapshot` — specific expected text, a\n   URL, AND a forbidden-state negative check — evaluated by your harness, not the model.\n\n4. **Accessibility tree first, pixels last.** `browser_snapshot` returns roles, refs, and\n   accessible names (~200-400 tokens) and is deterministic and cheap. Screenshots, pixel\n   coordinates, vision, and OCR are a scoped last resort for canvas only, never the default.\n\n5. **Graduation is the goal, not perpetual agent runs.** Once a flow is stable, promote the\n   run to a durable scripted `tests\u002F*.spec.ts` with role-based locators. An agent that has\n   been green for two weeks should become a fast, free regression test — keep the agent for\n   exploration, not for guarding a settled path.\n\n---\n\n## Fit: Intent-Driven vs Scripted\n\nThe decision is per-flow, not per-project. Run `risk-based-testing` first if you need the\nrisk map; this table is the routing rule once you have it.\n\n| Flow characteristic | Use | Why |\n|---------------------|-----|-----|\n| Stable, high-frequency critical path (login, payment) | **Scripted + pinned** (`playwright-automation`) | Runs every PR; must be fast, free, and deterministic. No upside to re-exploring it. |\n| Fast-changing \u002F experimental UI (a dashboard that churns weekly, a redesign in flight) | **Agentic \u002F intent-driven** | Selectors would break constantly; a goal survives layout churn. |\n| Hard-to-locate flow you can't reliably select | **Agentic** | The agent finds the control by role\u002Fname instead of you reverse-engineering a selector. |\n| Exploratory smoke \u002F \"does the happy path still work at all\" | **Agentic** | One NL goal covers a lot of ground without a maintained script. |\n| Anything in CI that must never falsely pass | Scripted, OR agentic **with a hard oracle** | Non-determinism is a false-pass risk you must actively cap. |\n\n**The rule, stated plainly:** keep stable critical paths scripted and pinned; point\nintent-driven agents at fast-changing UI and exploratory smoke. Do not move everything to the\nagent — it is slower, costlier, and non-deterministic, and not every test should be agentic.\n\n---\n\n## The Interaction Model (accessibility-tree-first)\n\nPlaywright MCP is **not** computer-use with screenshots and pixel coordinates. It is\naccessibility-tree-first:\n\n1. `browser_navigate` to the seeded entry URL.\n2. `browser_snapshot` returns the **accessibility tree** — each interactive element as a\n   `role`, a stable `ref`, and its `accessible name` (from ARIA\u002Flabels). ~200-400 tokens.\n3. The agent picks an element by `ref` and calls `browser_click` or `browser_type`.\n4. `browser_wait_for` waits on text appearing\u002Fdisappearing — never a fixed sleep.\n5. Re-`browser_snapshot` after the DOM changes; assert against that tree.\n\nWhy not screenshots: the snapshot is **token-efficient** (thousands of tokens cheaper than an\nimage), **deterministic** (text refs, not fuzzy pixel matching), and needs no vision model or\nOCR. Feeding screenshots as the primary input makes the run slower, pricier, and flakier.\n`browser_take_screenshot` is for human evidence only, never as the assertion input.\n\nSee `references\u002Fsetup.md` for the MCP registration, the full tool table, and the goal prompt.\n\n---\n\n## Determinism: making a run trustworthy in CI\n\nA run that passes once and fails the next with no app change is not yet a test. The fix is\nnever \"just retry\" or bumping temperature for \"smarter\" exploration — that adds variance. Pin\nthe variables instead:\n\n| Lever | Setting |\n|-------|---------|\n| Model | **Pinned model id** (e.g. `claude-haiku-4-5-20251001`), never `latest` |\n| Sampling | **temperature 0** — no creative wandering in CI |\n| Data | **Seeded fixture + reset\u002Fseed the database** before every run |\n| Scope | **Bounded step budget** (`maxSteps`), e.g. 18 — exceeding it FAILS, never auto-retries |\n| Oracle | **Explicit pass\u002Ffail verdict** asserted against the snapshot |\n| Evidence | Assert on the **accessibility tree**, never a screenshot diff |\n\nAvoid: `temperature: 0.7` or `1` for exploration, retry-until-pass loops,\n`waitForTimeout` sleeps, and screenshot-based assertions. Each one hides flakiness rather than\nremoving it. Full harness config in `references\u002Fsetup.md`.\n\n---\n\n## Success Assertion: the Oracle (where agents fail silently)\n\nThis is the sharpest failure mode: the agent reports success while stuck on the login page,\nbecause \"page loaded \u002F no error \u002F looks good\" was accepted as success and the LLM was allowed\nto self-grade. Force an explicit oracle the harness checks — never the agent.\n\nFor the goal *\"sign in as an existing user and confirm the dashboard shows the right account name\"*:\n\n```text\nSUCCESS (all must hold — assert against the final browser_snapshot):\n  - URL matches \u002Fdashboard\n  - Snapshot contains the specific expected account name text, e.g. \"Acme Corp — Jane R.\"\nNEGATIVE \u002F forbidden state (fail fast if any is true):\n  - Still on a URL matching \u002Flogin  → FAIL\n  - Snapshot contains role=\"alert\" with \"invalid credentials\"  → FAIL\nVERDICT: harness emits {\"passed\": true|false}; the LLM does not decide.\n```\n\nThe positive checks (specific account name + `\u002Fdashboard` URL) prove where it landed; the\n**negative check** (must NOT be on the login page) is what kills the false pass. \"No error,\"\n\"didn't crash,\" \"screenshot looks correct,\" and \"trust the agent\" are not success criteria.\n\n---\n\n## Cost and Latency\n\nAgent runs are 2-5x slower and pricier than scripted tests — a step is an LLM round-trip, the\ndominant cost. Cut spend without losing coverage by going *smaller*, not *bigger*:\n\n- **Step budget** — keep `maxSteps` low and enforced; fewer round-trips, less drift.\n- **Model tiering** — Haiku 4.5 \u002F Sonnet 4.6 for cheap navigation steps; reserve Opus 4.8 for\n  genuinely ambiguous exploration. Don't run the biggest model on every step.\n- **Prompt caching** — cache the static system prompt, tool schemas, and goal; they repeat\n  every run.\n- **Scope via a seeded entry point** — one narrow goal per run, deep-linked past login instead\n  of re-driving it each time.\n- **Snapshot over screenshots** — the a11y snapshot is ~200-400 tokens; a full-page screenshot\n  is thousands. Default to snapshot.\n\nBackwards moves to reject: \"use a bigger model \u002F Opus 4.8 for every step,\" \"raise the step\nlimit,\" \"screenshot every step,\" and running with no budget at all. See `references\u002Fsetup.md`.\n\n---\n\n## Graduation and CI Gating\n\nPromote a stabilized goal into a durable scripted test, and gate merges on the verdict. Both\nare detailed in `references\u002Fgraduation-and-ci.md`; the essentials:\n\n- **Graduate** with **Playwright Test Agents** (planner \u002F generator \u002F healer, shipped in\n  Playwright **v1.56.0**). `npx playwright init-agents --loop=claude`. The **planner** writes a\n  Markdown test plan to `specs\u002F\u003Cflow>.md`; the **generator** turns it into `tests\u002F\u003Cflow>.spec.ts`\n  with **role-based locators** (`getByRole`, `getByLabel`, `getByText`) verified against the live\n  DOM; the **healer** repairs broken locators. This is the promotion path — not \"keep running it\n  as an agent,\" not recorded clicks, not `page.locator('xpath=...')`, not data-testid-only.\n- **Gate CI** so a failed goal exits **non-zero** and emits a **machine-readable** verdict\n  (`{\"passed\": true|false}` in `result.json`); the GitHub Actions job parses the boolean and\n  `exit 1`s on false. State is seeded\u002Fephemeral and reset per run, with a step budget and a\n  timeout cap. Never `continue-on-error: true`, never \"always exit 0,\" never a prose verdict a\n  human reads.\n- **Canvas with no accessibility tree:** prefer instrumenting the canvas with ARIA; as a scoped\n  last resort enable `--caps=vision` to unlock `browser_mouse_click_xy` for that flow only.\n  `browser_snapshot` will not work on a raw canvas, but don't make coordinates the default and\n  don't abandon agentic testing.\n\n---\n\n## Migrating a brittle script to a goal (honest tradeoffs)\n\nConverting an 80-line script that re-types login and walks 6 hardcoded steps into a single NL\n**goal** with an **explicit success assertion** is a real win for a churning flow — but state\nthe downsides honestly:\n\n- **Non-determinism \u002F false-pass risk** — the run could pass falsely; that's why the hard\n  oracle and the negative check are non-negotiable.\n- **Cost\u002Flatency** — 2-5x slower; bound it with a **step budget** and a seeded entry point.\n- **Not every test should be agentic** — keep stable paths scripted, and plan to **graduate**\n  this one back to a scripted test once it stabilizes.\n\nReject the over-promise: it is **not** \"strictly better with no downsides,\" do **not** \"migrate\neverything,\" and never drop the assertions to make it pass.\n\n---\n\n## Anti-Patterns\n\n### 1. Reflexively writing a scripted Playwright test\n\"Browser test\" pattern-matches to codegen, so the default is `page.goto` \u002F `page.locator` \u002F\n`await expect(page...)` \u002F hunting `data-testid`. That misses the entire point. A goal-driven\nagent reads NL intent and explores via `browser_snapshot` — no pre-written selectors.\n\n### 2. \"Use the agent for everything\"\nOver-selling the new toy. The agent is 2-5x slower and non-deterministic. Stable critical paths\n(login) stay scripted and pinned; intent-driven wins on fast-changing UI. Never \"always use the\nagent\" or \"agents replace all scripted tests.\"\n\n### 3. Fixing flakiness with retries or higher temperature\n\"Just retry\" and bumping temperature for \"smarter\" exploration both add variance. The real\nlevers are temperature 0, a pinned model, seeded data, a bounded step budget, and an explicit\nverdict.\n\n### 4. Assuming computer-use = screenshots + pixel coordinates\nPlaywright MCP is accessibility-tree-first. Defaulting to vision, screenshots, OCR, or\n`mouse_click_xy` is slower, costlier, and flakier. Pixels are a canvas-only last resort.\n\n### 5. \"No error = success\" (the false pass)\nAccepting \"page loaded \u002F didn't crash \u002F looks good\" and letting the LLM self-grade is exactly\nwhy the agent reports success while stuck on login. Require specific expected text, a URL, and\na forbidden-state negative check, evaluated by the harness.\n\n### 6. Bigger model \u002F more steps to go faster\nBackwards. Opus 4.8 on every step and raising `maxSteps` raise cost and latency without buying\nreliability. Smaller models, tighter budgets, caching, and tighter scope are the fix.\n\n### 7. Running an agent forever instead of graduating\nA goal green for two weeks on a now-stable flow should become a scripted `tests\u002F*.spec.ts` via\nPlaywright Test Agents. \"Keep running it as an agent,\" recording clicks, and xpath locators are\nall wrong promotions.\n\n### 8. Prose verdict in CI\nReturning a paragraph for a human to read, or `continue-on-error: true`, lets a failed goal\nmerge. The run must exit non-zero on failure with a machine-readable boolean.\n\n---\n\n## Done When\n\n- Goal prompt exists as natural-language intent (no `page.locator` \u002F `page.goto` \u002F\n  `data-testid` in the goal) with a START seeded entry URL.\n- An explicit success oracle is defined: specific expected text AND a URL check AND a\n  forbidden-state negative check, asserted against `browser_snapshot` — not a screenshot.\n- Run config pins a model id, sets `temperature: 0`, a `maxSteps` budget, and a seed; no\n  `waitForTimeout`, no retry-until-pass.\n- Interaction is snapshot-first: `browser_navigate` \u002F `browser_snapshot` \u002F\n  `browser_click` \u002F `browser_type` \u002F `browser_wait_for`; screenshots used only for evidence.\n- The runner emits `result.json` with `{\"passed\": true|false}` and `exit 1`s on false; the CI\n  job gates the merge on the boolean (no `continue-on-error`, no `always exit 0`).\n- CI seeds\u002Fresets ephemeral state per run and enforces a step budget and a timeout cap.\n- A graduation trigger is recorded (e.g. \"green for 2 weeks → run `init-agents`, generate\n  `tests\u002F\u003Cflow>.spec.ts` with `getByRole` locators\").\n- If any target is canvas\u002FWebGL, the vision fallback (`--caps=vision` +\n  `browser_mouse_click_xy`) is scoped to that flow only, or the canvas is instrumented with ARIA.\n\n---\n\n## Related Skills\n\n- **playwright-automation** — Writing and maintaining deterministic scripted Playwright tests\n  and Page Objects. Go there to author the durable test; this skill graduates an agent run into one.\n- **ai-system-testing** — Testing your product's OWN LLM\u002FAI features (prompt regression, model\n  output quality). This skill tests any app *using* an agent; it does not test your AI feature.\n- **exploratory-testing** — Human SBTM exploration and bug hunting. The agentic smoke goal is\n  the automated cousin; use exploratory-testing for charter-driven manual sessions.\n- **test-reliability** — Self-healing locators and quarantine for *scripted* flaky tests at\n  runtime. Complements the determinism levers here once a test has graduated.\n- **qa-project-context** — The universal dependency; supplies stack, environments, seed\u002Freset\n  tooling, and model access that every question above depends on.\n\n## Reference Files (in `references\u002F`)\n\n- **setup.md** — Playwright MCP registration (`.mcp.json`), the snapshot tool table, the\n  natural-language goal prompt with success\u002Fnegative assertions, the determinism harness\n  config (pinned model, temperature 0, maxSteps, seed, prompt cache), and cost\u002Flatency levers.\n- **graduation-and-ci.md** — Playwright Test Agents promotion pipeline (planner → `specs\u002F*.md`,\n  generator → `tests\u002F*.spec.ts` with role-based locators, healer), the GitHub Actions gating\n  workflow with a machine-readable boolean verdict, and the canvas `--caps=vision` fallback.\n","\u003Cobjective>\nA scripted Playwright test breaks the moment a button moves or a class renames; writing one\nfor a dashboard that changes weekly is a maintenance treadmill. This skill stands up a\ngoal-driven browser agent instead: it reads a natural-language goal, explores the app via the\naccessibility tree (Playwright MCP `browser_snapshot`), and asserts the outcome against an\nexplicit oracle. The failure mode it prevents is the one that makes teams distrust agents — an\nagent that reports \"success\" while stuck on the login page because nothing forced it to prove\nwhere it landed. You leave with a deterministic, CI-gated agent run and a graduation path to a\ndurable scripted test once the flow stabilizes.\n\u003C\u002Fobjective>\n\n## Quick Route\n\n| Situation | Go to |\n|-----------|-------|\n| Stand up a goal-driven run from scratch | Discovery + `references\u002Fsetup.md` |\n| Decide agentic vs scripted for a given flow | Fit: Intent-Driven vs Scripted |\n| Agent passes one run, fails the next | Determinism |\n| \"How does it click without screenshots?\" | Interaction Model |\n| Runs are slow \u002F burning tokens | Cost and Latency |\n| Agent reports false success | Success Assertion (the Oracle) |\n| Flow is stable — make it permanent | Graduation → `references\u002Fgraduation-and-ci.md` |\n| Block a merge on the goal | CI Gating → `references\u002Fgraduation-and-ci.md` |\n| Canvas \u002F no accessibility tree | Canvas Fallback → `references\u002Fgraduation-and-ci.md` |\n\n## Discovery Questions\n\nFirst, check `.agents\u002Fqa-project-context.md` in the project root and skip anything it already\nanswers (stack, environments, seed\u002Freset tooling, model access).\n\n1. **Which flow, and how often does its UI change?** Fast-changing\u002Fexperimental UI favors\n   intent-driven; a stable critical path (login) favors scripted. This decides the whole approach.\n2. **Is there a seeded fixture and a way to reset state?** Determinism is impossible without\n   seeded data and a per-run reset. If neither exists, that is step zero.\n3. **Can you deep-link past auth to a seeded entry point?** Re-driving login every run is the\n   biggest avoidable cost; a seeded entry URL scopes the goal and cuts steps.\n4. **What is the unambiguous success oracle?** Specific account text, a `\u002Fdashboard` URL, an\n   order number — plus a forbidden state. \"No error\" is not an oracle.\n5. **Does the target render to canvas \u002F WebGL?** No accessibility tree means snapshot-first\n   won't work; plan the vision fallback or instrument the canvas with ARIA.\n6. **Which model and budget?** Pin a model id and a step budget up front; tier cheap steps to\n   Haiku 4.5 \u002F Sonnet 4.6 and reserve Opus 4.8 for genuinely ambiguous flows.\n\n---\n\n## Core Principles\n\n1. **Intent, not instructions — but only where churn earns it.** The agent reads a goal and\n   finds its own path through the accessibility tree, so it survives a moved button or renamed\n   class that would break a selector. That resilience costs 2-5x the time and money of a\n   scripted run, so spend it on fast-changing UI and hard-to-locate flows, not on stable\n   critical paths.\n\n2. **An agent run is untrustworthy until it is deterministic.** Same goal, same seeded app\n   must produce the same verdict. That requires temperature 0, a pinned model id, seeded data\n   with a reset, a bounded step budget, and an explicit pass\u002Ffail assertion. Without these you\n   have a coin flip, not a test.\n\n3. **The oracle lives outside the agent.** Never let the LLM self-grade \"looks good.\" Success\n   is a checkable assertion against the final `browser_snapshot` — specific expected text, a\n   URL, AND a forbidden-state negative check — evaluated by your harness, not the model.\n\n4. **Accessibility tree first, pixels last.** `browser_snapshot` returns roles, refs, and\n   accessible names (~200-400 tokens) and is deterministic and cheap. Screenshots, pixel\n   coordinates, vision, and OCR are a scoped last resort for canvas only, never the default.\n\n5. **Graduation is the goal, not perpetual agent runs.** Once a flow is stable, promote the\n   run to a durable scripted `tests\u002F*.spec.ts` with role-based locators. An agent that has\n   been green for two weeks should become a fast, free regression test — keep the agent for\n   exploration, not for guarding a settled path.\n\n---\n\n## Fit: Intent-Driven vs Scripted\n\nThe decision is per-flow, not per-project. Run `risk-based-testing` first if you need the\nrisk map; this table is the routing rule once you have it.\n\n| Flow characteristic | Use | Why |\n|---------------------|-----|-----|\n| Stable, high-frequency critical path (login, payment) | **Scripted + pinned** (`playwright-automation`) | Runs every PR; must be fast, free, and deterministic. No upside to re-exploring it. |\n| Fast-changing \u002F experimental UI (a dashboard that churns weekly, a redesign in flight) | **Agentic \u002F intent-driven** | Selectors would break constantly; a goal survives layout churn. |\n| Hard-to-locate flow you can't reliably select | **Agentic** | The agent finds the control by role\u002Fname instead of you reverse-engineering a selector. |\n| Exploratory smoke \u002F \"does the happy path still work at all\" | **Agentic** | One NL goal covers a lot of ground without a maintained script. |\n| Anything in CI that must never falsely pass | Scripted, OR agentic **with a hard oracle** | Non-determinism is a false-pass risk you must actively cap. |\n\n**The rule, stated plainly:** keep stable critical paths scripted and pinned; point\nintent-driven agents at fast-changing UI and exploratory smoke. Do not move everything to the\nagent — it is slower, costlier, and non-deterministic, and not every test should be agentic.\n\n---\n\n## The Interaction Model (accessibility-tree-first)\n\nPlaywright MCP is **not** computer-use with screenshots and pixel coordinates. It is\naccessibility-tree-first:\n\n1. `browser_navigate` to the seeded entry URL.\n2. `browser_snapshot` returns the **accessibility tree** — each interactive element as a\n   `role`, a stable `ref`, and its `accessible name` (from ARIA\u002Flabels). ~200-400 tokens.\n3. The agent picks an element by `ref` and calls `browser_click` or `browser_type`.\n4. `browser_wait_for` waits on text appearing\u002Fdisappearing — never a fixed sleep.\n5. Re-`browser_snapshot` after the DOM changes; assert against that tree.\n\nWhy not screenshots: the snapshot is **token-efficient** (thousands of tokens cheaper than an\nimage), **deterministic** (text refs, not fuzzy pixel matching), and needs no vision model or\nOCR. Feeding screenshots as the primary input makes the run slower, pricier, and flakier.\n`browser_take_screenshot` is for human evidence only, never as the assertion input.\n\nSee `references\u002Fsetup.md` for the MCP registration, the full tool table, and the goal prompt.\n\n---\n\n## Determinism: making a run trustworthy in CI\n\nA run that passes once and fails the next with no app change is not yet a test. The fix is\nnever \"just retry\" or bumping temperature for \"smarter\" exploration — that adds variance. Pin\nthe variables instead:\n\n| Lever | Setting |\n|-------|---------|\n| Model | **Pinned model id** (e.g. `claude-haiku-4-5-20251001`), never `latest` |\n| Sampling | **temperature 0** — no creative wandering in CI |\n| Data | **Seeded fixture + reset\u002Fseed the database** before every run |\n| Scope | **Bounded step budget** (`maxSteps`), e.g. 18 — exceeding it FAILS, never auto-retries |\n| Oracle | **Explicit pass\u002Ffail verdict** asserted against the snapshot |\n| Evidence | Assert on the **accessibility tree**, never a screenshot diff |\n\nAvoid: `temperature: 0.7` or `1` for exploration, retry-until-pass loops,\n`waitForTimeout` sleeps, and screenshot-based assertions. Each one hides flakiness rather than\nremoving it. Full harness config in `references\u002Fsetup.md`.\n\n---\n\n## Success Assertion: the Oracle (where agents fail silently)\n\nThis is the sharpest failure mode: the agent reports success while stuck on the login page,\nbecause \"page loaded \u002F no error \u002F looks good\" was accepted as success and the LLM was allowed\nto self-grade. Force an explicit oracle the harness checks — never the agent.\n\nFor the goal *\"sign in as an existing user and confirm the dashboard shows the right account name\"*:\n\n```text\nSUCCESS (all must hold — assert against the final browser_snapshot):\n  - URL matches \u002Fdashboard\n  - Snapshot contains the specific expected account name text, e.g. \"Acme Corp — Jane R.\"\nNEGATIVE \u002F forbidden state (fail fast if any is true):\n  - Still on a URL matching \u002Flogin  → FAIL\n  - Snapshot contains role=\"alert\" with \"invalid credentials\"  → FAIL\nVERDICT: harness emits {\"passed\": true|false}; the LLM does not decide.\n```\n\nThe positive checks (specific account name + `\u002Fdashboard` URL) prove where it landed; the\n**negative check** (must NOT be on the login page) is what kills the false pass. \"No error,\"\n\"didn't crash,\" \"screenshot looks correct,\" and \"trust the agent\" are not success criteria.\n\n---\n\n## Cost and Latency\n\nAgent runs are 2-5x slower and pricier than scripted tests — a step is an LLM round-trip, the\ndominant cost. Cut spend without losing coverage by going *smaller*, not *bigger*:\n\n- **Step budget** — keep `maxSteps` low and enforced; fewer round-trips, less drift.\n- **Model tiering** — Haiku 4.5 \u002F Sonnet 4.6 for cheap navigation steps; reserve Opus 4.8 for\n  genuinely ambiguous exploration. Don't run the biggest model on every step.\n- **Prompt caching** — cache the static system prompt, tool schemas, and goal; they repeat\n  every run.\n- **Scope via a seeded entry point** — one narrow goal per run, deep-linked past login instead\n  of re-driving it each time.\n- **Snapshot over screenshots** — the a11y snapshot is ~200-400 tokens; a full-page screenshot\n  is thousands. Default to snapshot.\n\nBackwards moves to reject: \"use a bigger model \u002F Opus 4.8 for every step,\" \"raise the step\nlimit,\" \"screenshot every step,\" and running with no budget at all. See `references\u002Fsetup.md`.\n\n---\n\n## Graduation and CI Gating\n\nPromote a stabilized goal into a durable scripted test, and gate merges on the verdict. Both\nare detailed in `references\u002Fgraduation-and-ci.md`; the essentials:\n\n- **Graduate** with **Playwright Test Agents** (planner \u002F generator \u002F healer, shipped in\n  Playwright **v1.56.0**). `npx playwright init-agents --loop=claude`. The **planner** writes a\n  Markdown test plan to `specs\u002F\u003Cflow>.md`; the **generator** turns it into `tests\u002F\u003Cflow>.spec.ts`\n  with **role-based locators** (`getByRole`, `getByLabel`, `getByText`) verified against the live\n  DOM; the **healer** repairs broken locators. This is the promotion path — not \"keep running it\n  as an agent,\" not recorded clicks, not `page.locator('xpath=...')`, not data-testid-only.\n- **Gate CI** so a failed goal exits **non-zero** and emits a **machine-readable** verdict\n  (`{\"passed\": true|false}` in `result.json`); the GitHub Actions job parses the boolean and\n  `exit 1`s on false. State is seeded\u002Fephemeral and reset per run, with a step budget and a\n  timeout cap. Never `continue-on-error: true`, never \"always exit 0,\" never a prose verdict a\n  human reads.\n- **Canvas with no accessibility tree:** prefer instrumenting the canvas with ARIA; as a scoped\n  last resort enable `--caps=vision` to unlock `browser_mouse_click_xy` for that flow only.\n  `browser_snapshot` will not work on a raw canvas, but don't make coordinates the default and\n  don't abandon agentic testing.\n\n---\n\n## Migrating a brittle script to a goal (honest tradeoffs)\n\nConverting an 80-line script that re-types login and walks 6 hardcoded steps into a single NL\n**goal** with an **explicit success assertion** is a real win for a churning flow — but state\nthe downsides honestly:\n\n- **Non-determinism \u002F false-pass risk** — the run could pass falsely; that's why the hard\n  oracle and the negative check are non-negotiable.\n- **Cost\u002Flatency** — 2-5x slower; bound it with a **step budget** and a seeded entry point.\n- **Not every test should be agentic** — keep stable paths scripted, and plan to **graduate**\n  this one back to a scripted test once it stabilizes.\n\nReject the over-promise: it is **not** \"strictly better with no downsides,\" do **not** \"migrate\neverything,\" and never drop the assertions to make it pass.\n\n---\n\n## Anti-Patterns\n\n### 1. Reflexively writing a scripted Playwright test\n\"Browser test\" pattern-matches to codegen, so the default is `page.goto` \u002F `page.locator` \u002F\n`await expect(page...)` \u002F hunting `data-testid`. That misses the entire point. A goal-driven\nagent reads NL intent and explores via `browser_snapshot` — no pre-written selectors.\n\n### 2. \"Use the agent for everything\"\nOver-selling the new toy. The agent is 2-5x slower and non-deterministic. Stable critical paths\n(login) stay scripted and pinned; intent-driven wins on fast-changing UI. Never \"always use the\nagent\" or \"agents replace all scripted tests.\"\n\n### 3. Fixing flakiness with retries or higher temperature\n\"Just retry\" and bumping temperature for \"smarter\" exploration both add variance. The real\nlevers are temperature 0, a pinned model, seeded data, a bounded step budget, and an explicit\nverdict.\n\n### 4. Assuming computer-use = screenshots + pixel coordinates\nPlaywright MCP is accessibility-tree-first. Defaulting to vision, screenshots, OCR, or\n`mouse_click_xy` is slower, costlier, and flakier. Pixels are a canvas-only last resort.\n\n### 5. \"No error = success\" (the false pass)\nAccepting \"page loaded \u002F didn't crash \u002F looks good\" and letting the LLM self-grade is exactly\nwhy the agent reports success while stuck on login. Require specific expected text, a URL, and\na forbidden-state negative check, evaluated by the harness.\n\n### 6. Bigger model \u002F more steps to go faster\nBackwards. Opus 4.8 on every step and raising `maxSteps` raise cost and latency without buying\nreliability. Smaller models, tighter budgets, caching, and tighter scope are the fix.\n\n### 7. Running an agent forever instead of graduating\nA goal green for two weeks on a now-stable flow should become a scripted `tests\u002F*.spec.ts` via\nPlaywright Test Agents. \"Keep running it as an agent,\" recording clicks, and xpath locators are\nall wrong promotions.\n\n### 8. Prose verdict in CI\nReturning a paragraph for a human to read, or `continue-on-error: true`, lets a failed goal\nmerge. The run must exit non-zero on failure with a machine-readable boolean.\n\n---\n\n## Done When\n\n- Goal prompt exists as natural-language intent (no `page.locator` \u002F `page.goto` \u002F\n  `data-testid` in the goal) with a START seeded entry URL.\n- An explicit success oracle is defined: specific expected text AND a URL check AND a\n  forbidden-state negative check, asserted against `browser_snapshot` — not a screenshot.\n- Run config pins a model id, sets `temperature: 0`, a `maxSteps` budget, and a seed; no\n  `waitForTimeout`, no retry-until-pass.\n- Interaction is snapshot-first: `browser_navigate` \u002F `browser_snapshot` \u002F\n  `browser_click` \u002F `browser_type` \u002F `browser_wait_for`; screenshots used only for evidence.\n- The runner emits `result.json` with `{\"passed\": true|false}` and `exit 1`s on false; the CI\n  job gates the merge on the boolean (no `continue-on-error`, no `always exit 0`).\n- CI seeds\u002Fresets ephemeral state per run and enforces a step budget and a timeout cap.\n- A graduation trigger is recorded (e.g. \"green for 2 weeks → run `init-agents`, generate\n  `tests\u002F\u003Cflow>.spec.ts` with `getByRole` locators\").\n- If any target is canvas\u002FWebGL, the vision fallback (`--caps=vision` +\n  `browser_mouse_click_xy`) is scoped to that flow only, or the canvas is instrumented with ARIA.\n\n---\n\n## Related Skills\n\n- **playwright-automation** — Writing and maintaining deterministic scripted Playwright tests\n  and Page Objects. Go there to author the durable test; this skill graduates an agent run into one.\n- **ai-system-testing** — Testing your product's OWN LLM\u002FAI features (prompt regression, model\n  output quality). This skill tests any app *using* an agent; it does not test your AI feature.\n- **exploratory-testing** — Human SBTM exploration and bug hunting. The agentic smoke goal is\n  the automated cousin; use exploratory-testing for charter-driven manual sessions.\n- **test-reliability** — Self-healing locators and quarantine for *scripted* flaky tests at\n  runtime. Complements the determinism levers here once a test has graduated.\n- **qa-project-context** — The universal dependency; supplies stack, environments, seed\u002Freset\n  tooling, and model access that every question above depends on.\n\n## Reference Files (in `references\u002F`)\n\n- **setup.md** — Playwright MCP registration (`.mcp.json`), the snapshot tool table, the\n  natural-language goal prompt with success\u002Fnegative assertions, the determinism harness\n  config (pinned model, temperature 0, maxSteps, seed, prompt cache), and cost\u002Flatency levers.\n- **graduation-and-ci.md** — Playwright Test Agents promotion pipeline (planner → `specs\u002F*.md`,\n  generator → `tests\u002F*.spec.ts` with role-based locators, healer), the GitHub Actions gating\n  workflow with a machine-readable boolean verdict, and the canvas `--caps=vision` fallback.\n",{"name":5,"license":15,"metadata":44,"description":7},{"author":45,"version":46,"category":47},"kindlmann","1.0","ai-qa","claude\u002Finstall-gsd-build-foQdV","d86cd127f527124b5fd0fd0bc679a4d79b7d01d7",".agents\u002Fskills\u002Fagentic-browser-testing","https:\u002F\u002Fgithub.com\u002Fpattanation\u002FNorvik","https:\u002F\u002Fnorvik-orpin.vercel.app","https:\u002F\u002Fgithub.com\u002Fpattanation","2026-07-17 11:17:04",{"source":8,"skillName":5,"commands":56,"prompt":66,"zipAvailable":67},[57,60,63],{"tool":58,"command":59},"npx","npx skills add pattanation\u002FNorvik --skill agentic-browser-testing",{"tool":61,"command":62},"bunx","bunx skills add pattanation\u002FNorvik --skill agentic-browser-testing",{"tool":64,"command":65},"pnpm","pnpm dlx skills add pattanation\u002FNorvik --skill agentic-browser-testing","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fpattanation\u002FNorvik\u002Fblob\u002Fclaude\u002Finstall-gsd-build-foQdV\u002F.agents\u002Fskills\u002Fagentic-browser-testing\u002FSKILL.md",true,[69,75],{"path":70,"resourceType":71,"resourceTypeDesc":72,"sizeBytes":73,"sourceHtmlUrl":74},"references\u002Fgraduation-and-ci.md","REFERENCE","参考文档",5137,"https:\u002F\u002Fgithub.com\u002Fpattanation\u002FNorvik\u002Fblob\u002Fclaude\u002Finstall-gsd-build-foQdV\u002F.agents\u002Fskills\u002Fagentic-browser-testing\u002Freferences\u002Fgraduation-and-ci.md",{"path":76,"resourceType":71,"resourceTypeDesc":72,"sizeBytes":77,"sourceHtmlUrl":78},"references\u002Fsetup.md",4770,"https:\u002F\u002Fgithub.com\u002Fpattanation\u002FNorvik\u002Fblob\u002Fclaude\u002Finstall-gsd-build-foQdV\u002F.agents\u002Fskills\u002Fagentic-browser-testing\u002Freferences\u002Fsetup.md",[80,89,96,103,127,152],{"skillNo":81,"name":82,"nameZh":6,"description":83,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":84,"licenseFileUrl":6,"sourceHtmlUrl":85,"categories":86,"keywords":87,"publishedAt":88},"01M73Z1NPMJ667E0DSPBS9FH0B","jetson-set-target","Switch the active Jetson target-platform pointer to an existing profile YAML. Use before customize\u002Fbuild\u002Fflash to change target; not for authoring profiles — use jetson-init-target instead.","Apache-2.0","https:\u002F\u002Fgithub.com\u002Fpattanation\u002FNorvik\u002Fblob\u002Fclaude\u002Finstall-gsd-build-foQdV\u002F.agents\u002Fskills\u002Fjetson-set-target\u002FSKILL.md",[],[],"2026-11-11 15:11:14",{"skillNo":90,"name":91,"nameZh":6,"description":92,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":84,"licenseFileUrl":6,"sourceHtmlUrl":93,"categories":94,"keywords":95,"publishedAt":88},"01M73YC29YWGCW521P7B0NM3HQ","earth2studio-data-fetch","Fetch weather\u002Fclimate data via Earth2Studio data sources for specific variables and times. Do NOT use for inference pipelines, model discovery, or installation.","https:\u002F\u002Fgithub.com\u002Fpattanation\u002FNorvik\u002Fblob\u002Fclaude\u002Finstall-gsd-build-foQdV\u002F.agents\u002Fskills\u002Fearth2studio-data-fetch\u002FSKILL.md",[],[],{"skillNo":97,"name":98,"nameZh":6,"description":99,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":84,"licenseFileUrl":6,"sourceHtmlUrl":100,"categories":101,"keywords":102,"publishedAt":88},"01M73YBNHMHFDFP83MAVGQQ92N","earth2studio-create-datasource","Create and validate Earth2Studio data source wrappers (DataSource, ForecastSource, DataFrameSource, ForecastFrameSource) from remote stores. Do NOT use for fetching data with existing sources, model inference, or installation tasks.","https:\u002F\u002Fgithub.com\u002Fpattanation\u002FNorvik\u002Fblob\u002Fclaude\u002Finstall-gsd-build-foQdV\u002F.agents\u002Fskills\u002Fearth2studio-create-datasource\u002FSKILL.md",[],[],{"skillNo":104,"name":105,"nameZh":6,"description":106,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":84,"licenseFileUrl":107,"sourceHtmlUrl":108,"categories":109,"keywords":110,"publishedAt":126},"01M71QDV4DM8T19HEHWATEF1K4","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.","https:\u002F\u002Fgithub.com\u002Fpattanation\u002FNorvik\u002Fblob\u002Fclaude\u002Finstall-gsd-build-foQdV\u002F.agents\u002Fskills\u002Fwebapp-testing\u002FLICENSE.txt","https:\u002F\u002Fgithub.com\u002Fpattanation\u002FNorvik\u002Fblob\u002Fclaude\u002Finstall-gsd-build-foQdV\u002F.agents\u002Fskills\u002Fwebapp-testing\u002FSKILL.md",[],[111,19,112,113,114,115,116,21,117,118,119,120,121,122,123,124,125],"webapp","webapp testing","local","screenshots","for","applications","ui","behavior","web","playwright","with","frontend","debugging","toolkit","logs","2026-11-10 13:02:02",{"skillNo":128,"name":129,"nameZh":6,"description":130,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":84,"licenseFileUrl":131,"sourceHtmlUrl":132,"categories":133,"keywords":134,"publishedAt":126},"01M71QDH2GGMXGA9105C9W1N7B","web-artifacts-builder","Suite of tools for creating elaborate, multi-component claude.ai HTML artifacts using modern frontend web technologies (React, Tailwind CSS, shadcn\u002Fui). Use for complex artifacts requiring state management, routing, or shadcn\u002Fui components - not for simple single-file HTML\u002FJSX artifacts.","https:\u002F\u002Fgithub.com\u002Fpattanation\u002FNorvik\u002Fblob\u002Fclaude\u002Finstall-gsd-build-foQdV\u002F.agents\u002Fskills\u002Fweb-artifacts-builder\u002FLICENSE.txt","https:\u002F\u002Fgithub.com\u002Fpattanation\u002FNorvik\u002Fblob\u002Fclaude\u002Finstall-gsd-build-foQdV\u002F.agents\u002Fskills\u002Fweb-artifacts-builder\u002FSKILL.md",[],[135,119,136,137,138,139,140,141,142,143,144,145,115,146,147,122,148,149,150,151],"web artifacts builder","artifacts","artifacts builder","builder","multi","state","routing","state management","react","single-file","css","Tailwind","ui components","single","use","file","components",{"skillNo":153,"name":154,"nameZh":6,"description":155,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":156,"sourceHtmlUrl":157,"categories":158,"keywords":159,"publishedAt":126},"01M71QD9T2XC3EWMQNN9ACNWQ1","vueuse-functions","Apply VueUse composables where appropriate to build concise, maintainable Vue.js \u002F Nuxt features.","https:\u002F\u002Fgithub.com\u002Fpattanation\u002FNorvik\u002Fblob\u002Fclaude\u002Finstall-gsd-build-foQdV\u002F.agents\u002Fskills\u002Fvueuse-functions\u002FLICENSE.md","https:\u002F\u002Fgithub.com\u002Fpattanation\u002FNorvik\u002Fblob\u002Fclaude\u002Finstall-gsd-build-foQdV\u002F.agents\u002Fskills\u002Fvueuse-functions\u002FSKILL.md",[],[160,161,162,163,34,164,165,166,167,168,169,170,171,172],"vueuse","vueuse functions","functions","composables","nuxt","apply","github","concise","build","https","features","vue","js"]