electron
Skill4 starsChanged 4 months agoMITView on GitHub
Automate Electron apps (Slack, VS Code, Discord, etc.) whose UI is Chromium web content exposed through the Accessibility API
12 other projects use a version of this.
Adopted by
Most recently taken up by
- Quad4-Software/skillstheir own version, first seen Oct 3, 2026
- BytePioneer-AI/codex-hosttheir own version, first seen Oct 2, 2026
- skillpie/ZCodeOnlinetheir own version, first seen Sep 29, 2026
- ccbud/CCBuddytheir own version, first seen Sep 24, 2026
- ZCodium-project/ZCodiumtheir own version, first seen Sep 20, 2026
- vercel-labs/agent-browsertheir own version, first seen Sep 16, 2026
Used with
Projects with it also use architecture-governance, dep-refs and 3 more.
Other files people use alongside this one.
Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
ZCodium-projectSkillarchitecture-governance
Apply the repository's architecture policy to code changes by generating a bounded context package, checking module and layer boundaries, and reporting baseline-aware violations. Use for any code change; skip for documentation-only work.
Also in 4 projects that use this
ZCodium-projectSkilldep-refs
Use when needs to inspect TypeScript export references in the z-code workspace, list exports from a file, verify whether an export is unused before deletion, investigate who imports a symbol during refactors, or combine pnpm knip unused-export results with pnpm dep:refs symbol-level reference tracing.
Also in 4 projects that use this
VercelSkillai-elements
Build AI chat interfaces using ai-elements components — conversations, messages, tool displays, prompt inputs, and more. Use when the user wants to build a chatbot, AI assistant UI, or any AI-powered chat interface.
Also in 4 projects that use this
VercelSkillvercel-react-best-practices
React and Next.js performance optimization guidelines from Vercel Engineering. This skill should be used when writing, reviewing, or refactoring React/Next.js code to ensure optimal performance patterns. Triggers on tasks involving React components, Next.js pages, data fetching, bundle optimization, or performance improvements.
Also in 3 projects that use this
- +1 more from ZCodium-project
Other versions12 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 12
- vercel-labs/agent-browser★ 44ksame name
- BytePioneer-AI/codex-host★ 2.7ksame name
- opral/flashtype★ 294same name
- ZCodium-project/ZCodium★ 215same name
- ccbud/CCBuddy★ 8same name
- flpbalada/fb-skills★ 8same name
- JayAI623/claude-code-config★ 2same name
- skillpie/ZCodeOnline★ 2same name
- LDKTC/Agent-P-FullStack★ 1same name
- Quad4-Software/skills★ 1same name
2 more not listed
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
The file
We split this skill into the rules it gives an agent
3 rules. 0 are common, 1 is distinctive, and 2 are very specific to this project.
0
Common
Most of the 12 edited versions we read keep these.
1
Distinctive
This author's own choices. Worth a look.
2
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 31
After connecting, Chromium needs a short, non-deterministic moment (usually <1s) to construct the tree.
- Very specific: line 42
Always run query_tree after connecting, before building locators — Electron trees vary a lot between apps and change as the app renders.
- Very specific: line 100
If it remains degraded, follow the returned screenshot/OCR/menu/keyboard fallback.
“Common” is measured: kept by at least 6 in 10 of the 12 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Electron App Automation
Electron apps (Slack, VS Code, Discord, Notion, Figma desktop, …) render their UI as Chromium web content. macbeth automates them the same way it does native apps, with a few Electron-specific things to know.
Connect
Connect by name or PID as usual:
connect_app({ "name": "Slack" })On connect, macbeth enables Chromium's accessibility tree (AXManualAccessibility) and
waits for the web content to expose descendants. Branded Electron distributions are
recognised via ElectronAsarIntegrity, ChromiumBaseVersion, or a renamed
*Framework.framework + Helper (Renderer) layout. list_apps reports these apps
with runtime: electron and includes declared aliases and bundle IDs.
Reconnecting the same app refreshes readiness without waiting again unless you pass
readyTimeoutMs explicitly — useful after a first connect reported empty_web_area.
Expect a readiness delay
After connecting, Chromium needs a short, non-deterministic moment (usually <1s) to
construct the tree. connect_app already polls for this, but if the very first
query_tree looks empty (just a window shell), wait briefly and query again — the web
content is still materializing. For slow apps, connect with a longer wait:
connect_app({ "name": "Slack", "readyTimeoutMs": 5000 })Discover the tree first
Always run query_tree after connecting, before building locators — Electron trees vary
a lot between apps and change as the app renders. Web content lives under a web_area
node:
[window "Slack"] h:h_0
[web_area] h:h_5
[button "Send"] h:h_31
[text_field] h:h_28
[heading "Threads"] h:h_12
...Scope queries to the web_area and target elements directly — recursive descent means you
don't need to name every intermediate container:
{ "query": [{ "role": "window" }, { "role": "web_area" }, { "role": "button", "title": "Send" }] }Common web-content roles: web_area, heading, link, button, text_field,
text_area, checkbox, radio, list, table, text. Note Chromium sometimes exposes
a contenteditable message box as text_area rather than text_field — check the tree.
Fill and click: use strategy overrides when auto fails
Both fill and click default to strategy: "auto", which handles web content well. Reach
for an override when auto doesn't do what you expect:
fill — "auto" | "ax" | "keyboard"
auto(default): on Electron it types the value as real keystrokes so the app's framework (React, etc.) registers the input. This is almost always what you want.keyboard: force keystroke synthesis (e.g. if you scriptedaxand state went stale).ax: force a direct AX value write. Fast, but the app may not "see" the change — only use when you've confirmed it works for that field.
fill({ "app": "Slack", "query": [{ "role": "web_area" }, { "role": "text_area" }], "value": "hello team", "strategy": "keyboard" })click — "auto" | "ax" | "mouse"
auto(default): triesAXPresson the element and its neighbours, then a synthetic mouse click at the element center.mouse: force a coordinate click — best for canvas-heavy UIs (Figma, drawing surfaces) that expose geometry but no press action. Macbeth briefly activates only the owning window, then restores the previous app, focused window, and cursor. AddwaitForIdleMswhen avoiding a mid-keystroke focus steal matters.ax: forceAXPressonly.
click({ "app": "Figma", "query": [{ "role": "web_area" }, { "role": "button", "title": "Frame" }], "strategy": "mouse" })Gotchas
- Empty first tree — if
query_treereturns just the window with noweb_area, or adegraded_accessibilitywarning says the web area has no descendants, the tree may still be building. Wait ~500ms and retry, or reconnect with a largerreadyTimeoutMs. If it remains degraded, follow the returned screenshot/OCR/menu/keyboard fallback. - Stale handles — Electron re-renders can invalidate element handles quickly. Prefer
query-based locators (they re-resolve automatically) over holding raw
h_Nhandles fromquery_tree. If an action fails with a "stale-element" error, re-runquery_tree. - AX tree ≠ DOM — you get roles, titles, values, and geometry, not DOM attributes or
CSS. For that, launch the app with
--remote-debugging-portand use the Chrome DevTools Protocol (out of scope for macbeth). filllooks like it worked but the app ignores it — you probably usedstrategy: "ax". Switch toautoorkeyboard.
Workflows
Send a message in a chat app
connect_app({ name: "Slack" })query_treeto find the message box (text_areaortext_fieldunderweb_area)fillthe message box (auto strategy synthesizes keystrokes)press_key({ app: "Slack", key: "return" })orclickthe Send button
Click a toolbar/canvas control
query_treeto find the control underweb_areaclickwithstrategy: "auto"; if nothing happens, retry withstrategy: "mouse"
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

