Contributing playwright-axi to the AXI catalog
September 17, 2026 · View on GitHub
This document captures everything needed to list playwright-axi in the
community catalog at axi.md, following
kunchenguid/axi's CONTRIBUTING.md.
catalog.yaml entry
Append to the community: list in
catalog.yaml
(keep entries alphabetical-ish by insertion convention — check neighboring
entries and place accordingly):
- name: playwright-axi
url: https://github.com/brycehamrick/playwright-axi
author: brycehamrick
domain: Browser automation
description: "Navigate, click, fill, and extract with combined operations, inline filtered snapshots, and TOON output. Wraps the `playwright` npm package's agent CLI."
Workflow (per CONTRIBUTING.md)
Human-authored pull requests targeting main must go through
no-mistakes (v1.30.1+ for
fork-based contributions):
- Fork
kunchenguid/axi, then clone the parent repo or resetorigintogit@github.com:kunchenguid/axi.git. - Create a branch (suggested:
catalog/playwright-axi). no-mistakes init --fork-url git@github.com:<you>/axi.git- Add the entry above to
catalog.yamlundercommunity:. pnpm install --frozen-lockfile && pnpm run docs:gen— regeneratesREADME.mdanddocs/index.htmlfrom the catalog. Do not hand-edit the generated table regions.- Commit
catalog.yaml,README.md, anddocs/index.htmltogether. git push no-mistakes, then runno-mistakesto attach to the review pipeline. It opens the PR againstkunchenguid/axiafter checks pass.- A
Require no-mistakesGitHub check validates the PR body signature.
Review readiness (the 10 principles)
The catalog performs independent source review before admission. How this implementation satisfies each principle, with pointers for reviewers:
| # | Principle | Where |
|---|---|---|
| 1 | Token-efficient output (TOON) | src/render.ts — TOON-style text by default; structured objects serialized by axi-sdk-js's TOON encoder; --json escape hatch |
| 2 | Minimal default schemas | sessions[n]{name,status,browser,headed}, tabs[n]{index,current,title,url}, requests[n]{index,request} — 3–4 fields per row |
| 3 | Content truncation | 120-line snapshot cap, 2000-char text cap, size hints naming --full/--query (src/render.ts) |
| 4 | Pre-computed aggregates | console totals: {messages, errors, warnings}, matches: N of M lines, count on every listing |
| 5 | Definitive empty states | sessions: 0, requests: 0 + note, matches: 0, items: 0, snapshot: (no lines match "x") |
| 6 | Structured errors & exit codes | AxiError via axi-sdk-js; VALIDATION_ERROR → exit 2, runtime (NO_SESSION, STALE_REF, ENGINE_ERROR, ENGINE_TIMEOUT, MISSING_DEPENDENCY) → exit 1; errors on stdout; no prompts; unknown flags fail loud with valid-flag lists; delete-data is --confirm-gated and idempotent |
| 7 | Ambient context | setup hooks → installSessionStartHooks (Claude Code, Codex, OpenCode); installable Agent Skill ships at skills/playwright-axi/SKILL.md |
| 8 | Content first | bare playwright-axi renders the live session dashboard (src/home.ts) with bin path + description header injected by the SDK |
| 9 | Contextual disclosure | help[] next-step lines after page actions, listings, and errors |
| 10 | Consistent help | --help top level + per command, generated from the registry so it cannot drift from dispatch |
Notes for reviewers
- The engine is spawned as
node <playwright>/cli.js cli ... --json; the wrapper adds onlyNO_UPDATE_NOTIFIER=1to the environment and never reads or prints credentials. - The
attachcommand's--sessionflag belongs to the engine (it names the bound browser's session) and is forwarded rather than consumed — seesrc/registry.ts. - Unit tests mock the spawner (
setEngineSpawner) and run without a browser; fixtures intest/*.test.tsare captured verbatim fromplaywright@1.63.