[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M7ECSTYEFDST9CXV7T6Q8NJE":3,"skill-same:01M7ECSTYEFDST9CXV7T6Q8NJE":49},{"skillNo":4,"name":5,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":7,"ownerLogin":8,"ownerAvatarUrl":9,"ownerAccountNo":10,"ownerDisplayName":11,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":15,"categories":16,"keywords":17,"publishedAt":18,"linkOnly":19,"markdownContent":20,"markdownBody":20,"frontMatter":21,"refName":22,"commitSha":23,"skillDirectory":24,"forksCount":13,"repositoryHtmlUrl":25,"repositoryHomepageUrl":6,"ownerHtmlUrl":26,"ownerBlogUrl":6,"ownerDescription":27,"updatedAt":28,"install":29,"resources":42},"01M7ECSTYEFDST9CXV7T6Q8NJE","hermes-desktop-plugins",null,"jonahthan433\u002FCortexOS","jonahthan433","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F211465495?v=4","01M7ECH9HPHGA89DCXHHJBTS3C","jonah.ai","01M7ECH9JCEM45DZMWPT7148S1",0,"Apache-2.0","https:\u002F\u002Fgithub.com\u002Fjonahthan433\u002FCortexOS\u002Fblob\u002Fmain\u002Fskills\u002Fimported\u002Fhermes-desktop-plugins\u002Fhermes-desktop-plugins\u002FSKILL.md",[],[],"2026-11-15 14:19:17",false,"# hermes-desktop-plugins\n\n# Hermes Desktop Plugins Skill\n\nWrite plugins for the Hermes desktop app: statusbar items, layout panes,\ncommand-palette commands, keybinds, routes, and themes. A plugin is a single\nplain-JavaScript ESM file the app loads at runtime — no build step, no repo\nchanges. A plugin can also talk to its own Python backend namespace\n(`ctx.rest`\u002F`ctx.socket` → `\u002Fapi\u002Fplugins\u002F\u003Cid>`); the general Python plugin\nsystem (`~\u002F.hermes\u002Fplugins\u002F`) is otherwise documented separately.\n\nFull human reference (every export, area payloads, backend, security):\n`website\u002Fdocs\u002Fdeveloper-guide\u002Fdesktop-plugin-sdk.md`.\n\n## When to Use\n\n- The user asks for a new desktop UI element (a pane, a statusbar widget, a\n  dashboard, a command) without modifying the app itself.\n- You want to surface data you compute (via gateway RPC) inside the app.\n\n## Prerequisites\n\n- The Hermes desktop app (it loads plugins; the CLI\u002Fgateway alone does not).\n- Write access to `$HERMES_HOME\u002Fdesktop-plugins\u002F` (usually\n  `~\u002F.hermes\u002Fdesktop-plugins\u002F`).\n\n## How to Run\n\n1. Create `$HERMES_HOME\u002Fdesktop-plugins\u002F\u003Cname>\u002Fplugin.js` from\n   `templates\u002Fplugin.js` (relative to this skill directory) — that's\n   `~\u002F.hermes\u002F...` by default, or `~\u002F.hermes\u002Fprofiles\u002F\u003Cprofile>\u002F...` under a\n   named profile. Keep `\u003Cname>` equal to the plugin `id`.\n2. The desktop app watches that directory: the plugin loads within a few\n   seconds of the file landing, and every later save hot-reloads it in\n   place. No reload step. (Fallback if it doesn't appear: ⌘K →\n   **Reload desktop plugins**.)\n3. If loading fails the app shows a toast naming the error — fix the file\n   and save again.\n\n## Quick Reference\n\nThe ONLY import surface is `@hermes\u002Fplugin-sdk` (plus `react` \u002F\n`react\u002Fjsx-runtime`, which resolve to the app's own React — write UI with\n`jsx()` calls, not JSX syntax; the file is not compiled).\n\n- `host.state.*` — readonly reactive atoms: `activeSessionId`, `cwd`,\n  `gateway`, `model`, `profile`, `viewport`. Read with `.get()` in handlers,\n  `useValue(atom)` in components.\n- `host.request(method, params)` — gateway JSON-RPC (sessions, config,\n  skills, cron — everything the app uses).\n- `host.onEvent(type, fn)` — live gateway events (`'*'` for all). Returns a\n  disposer.\n- `host.notify({ kind, message })`, `host.navigate(path)`, `host.logs(...)`,\n  `host.status()`, `haptic('tap')`.\n- `ctx.register({ id, area, order?, render?, data? })` — contribute UI.\n  Key areas: `'statusBar.right'`\u002F`'statusBar.left'` (chips),\n  `'panes'` (layout zones — set `title` and\n  `data: { placement, dock?, width?, height? }`; the pane auto-joins a\n  matching zone), `PALETTE_AREA` (⌘K commands), `KEYBINDS_AREA` (rebindable\n  actions).\n- Pane placement: `placement: 'left'|'right'|'bottom'|'main'` is the\n  semantic role — the pane stacks (tabs) with existing panes of that role.\n  To land on a specific EDGE instead, add `dock: { pane, pos }` — the same\n  gesture as dragging onto a pane's drop chip. `pane` is any pane id\n  (`workspace` is the main thread; also `sessions`, `terminal`, `files`,\n  `review`, `logs`), `pos` is `'top'|'bottom'|'left'|'right'|'center'`.\n  E.g. \"below the conversation\" = `dock: { pane: 'workspace', pos: 'bottom' }`\n  — declare a `height` (e.g. `'200px'`) so it doesn't take half the zone.\n- Full PAGES: register `area: ROUTES_AREA` with `data: { path: '\u002Fmy-page' }`\n  and a `render` — the page mounts in the workspace (main) pane like any\n  built-in view. Make it reachable with a sidebar nav row:\n  `ctx.register({ id: 'nav', area: SIDEBAR_NAV_AREA, data: { path: '\u002Fmy-page', label: 'My Page', codicon: 'project' } })`\n  (renders below Artifacts, lights up at the route) — and\u002For a\n  `PALETTE_AREA` command calling `host.navigate('\u002Fmy-page')`.\n- `ctx.storage.get\u002Fset\u002Fremove` — persistence namespaced to your plugin.\n- `ctx.i18n.register({ en, ja, ... })` — ship your OWN locale bundles, scoped\n  to your plugin (never edit core `en.ts`). Values are literal strings or\n  interpolator functions; nested trees are addressed by dot-path. Read them\n  reactively in components with `usePluginI18n(id)` returning `t('key', ...args)`\n  (re-renders on a locale switch), or via `ctx.i18n.t` in handlers\u002Fstores.\n  Resolution follows the app's active locale, then your `en`, then the raw key.\n- Data: `useQuery`\u002F`useMutation`\u002F`useQueryClient`\u002F`queryClient` (the app's ONE\n  React Query client — cache, dedupe, `refetchInterval`, invalidate like core;\n  never hand-roll a poll loop), plus `atom`\u002F`computed` for plugin-local state.\n- Backend: if the plugin ships a Python `plugin_api.py` (under\n  `~\u002F.hermes\u002Fplugins\u002F\u003Cid>\u002Fdashboard\u002F`, manifest `\"api\": \"plugin_api.py\"`), reach\n  it with `ctx.rest('\u002Fpath', { method?, body?, timeoutMs? })` and its live twin\n  `ctx.socket('\u002Fevents', onMessage)` — both scoped to `\u002Fapi\u002Fplugins\u002F\u003Cid>` by\n  construction (traversal rejected). `ctx.socket` is a **no-op on OAuth\n  remotes**, so always keep a polling fallback. The Python backend is imported\n  only when the plugin is in `plugins.enabled` in `config.yaml` (separate from\n  the in-app enable toggle). For gateway-wide data use `host.request` \u002F\n  `host.onEvent` instead.\n- `Contribute` (mount-scoped): render `jsx(Contribute, { area, id, children })`\n  inside a component so page-owned chrome (e.g. a titlebar control in\n  `TITLEBAR_AREAS.center`) leaves when the page unmounts — `ctx.register` is for\n  permanent contributions.\n- `defaultEnabled: false` on the default export ships an opt-in plugin: it\n  inventories in Settings → Plugins, off until the user flips it on.\n- Users manage plugins in Settings → Plugins (enable\u002Fdisable live, reveal\n  folder). A disabled plugin stays disabled across restarts — don't fight\n  it; the user turned you off.\n- UI: the app's design language, importable directly — `Button`, `Input`,\n  `Textarea`, `Select*`, `Switch`, `Checkbox`, `SegmentedControl`, `Tabs*`,\n  `Dialog*`, `ConfirmDialog`, `DropdownMenu*`, `ContextMenu*`, `Popover*`,\n  `Tip`\u002F`Tooltip*`, `Badge`, `Kbd`\u002F`KbdGroup`, `SearchField`, `ScrollArea`,\n  `Separator`, `Skeleton`, `GlyphSpinner`, `EmptyState`, `ErrorState`,\n  `CopyButton`, `StatusDot`, `LogView`, `Codicon`, `DecodeText`, plus `cn`\n  and `icons.*`. Prefer these over hand-rolled elements so the plugin looks\n  native; style with theme vars, never hardcoded colors.\n\n## Procedure\n\n1. Pick a short kebab-case `id`; the folder name must match.\n2. Start from `templates\u002Fplugin.js`; keep the default export shape\n   (`{ id, name, register(ctx) }`).\n3. For a pane, register `area: 'panes'` with a `placement` hint and a\n   `render` returning your component — the app places it into a sensible\n   zone automatically; the user can drag it anywhere afterwards.\n4. Fetch data with `host.request` and\u002For subscribe with `host.onEvent`;\n   never poll faster than a few seconds.\n5. Write the file with your file tools, then ask the user to run\n   **Reload desktop plugins** from ⌘K.\n\n## Pitfalls\n\n- NEVER hardcode colors or backgrounds (`#000`, `black`, `rgb(...)`). Panes\n  already sit on the app's editor background — leave the background alone\n  and use theme variables for everything else: `var(--ui-text-secondary)`,\n  `var(--ui-text-quaternary)`, `var(--ui-stroke-secondary)`,\n  `var(--ui-accent)`. For canvas drawing, resolve them once with\n  `getComputedStyle(canvas).getPropertyValue('--ui-accent')`.\n- Reference only what you imported — a component you forgot to import\n  (e.g. `StatusDot`) is a ReferenceError at render. Double-check every\n  identifier in your `jsx()` calls appears in the import line.\n- Canvas panes MUST track their container with a `ResizeObserver` and\n  re-size the canvas (width\u002Fheight attributes, not just CSS) — panes resize\n  constantly (sash drags, layout switches); a mount-time-only size leaves\n  blank space or blurry scaling.\n- JSX syntax will not parse — the file loads uncompiled. Use\n  `jsx('div', { children: ... })` from `react\u002Fjsx-runtime`.\n- Do not import anything except `@hermes\u002Fplugin-sdk`, `react`, and\n  `react\u002Fjsx-runtime`; other specifiers fail to resolve.\n- Handlers must read state imperatively (`$atom.get()`), never from render\n  closures — rapid events will otherwise see stale values.\n- Keep components small; subscribe (`useValue`) only in the leaf that\n  renders the value.\n\n## Verification\n\n- The plugin's UI appears after **Reload desktop plugins**.\n- No error toast (\"Plugin \u003Cname> failed to load\") appears; if it does, the\n  message names the failure — fix and reload.\n- For panes: the new zone is visible and draggable like any core pane.\n",{},"main","38b32c99e7ed0b8e215d638e92cfa452c1ec3079","skills\u002Fimported\u002Fhermes-desktop-plugins\u002Fhermes-desktop-plugins","https:\u002F\u002Fgithub.com\u002Fjonahthan433\u002FCortexOS","https:\u002F\u002Fgithub.com\u002Fjonahthan433","AI Consultant","2026-10-24 05:13:39",{"source":7,"skillName":5,"commands":30,"prompt":40,"zipAvailable":41},[31,34,37],{"tool":32,"command":33},"npx","npx skills add jonahthan433\u002FCortexOS --skill hermes-desktop-plugins",{"tool":35,"command":36},"bunx","bunx skills add jonahthan433\u002FCortexOS --skill hermes-desktop-plugins",{"tool":38,"command":39},"pnpm","pnpm dlx skills add jonahthan433\u002FCortexOS --skill hermes-desktop-plugins","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fjonahthan433\u002FCortexOS\u002Fblob\u002Fmain\u002Fskills\u002Fimported\u002Fhermes-desktop-plugins\u002Fhermes-desktop-plugins\u002FSKILL.md",true,[43],{"path":44,"resourceType":45,"resourceTypeDesc":46,"sizeBytes":47,"sourceHtmlUrl":48},"skill.json","REFERENCE","参考文档",378,"https:\u002F\u002Fgithub.com\u002Fjonahthan433\u002FCortexOS\u002Fblob\u002Fmain\u002Fskills\u002Fimported\u002Fhermes-desktop-plugins\u002Fhermes-desktop-plugins\u002Fskill.json",[50,56,62,68,74,80],{"skillNo":51,"name":52,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":7,"ownerLogin":8,"ownerAvatarUrl":9,"ownerAccountNo":10,"ownerDisplayName":11,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":53,"categories":54,"keywords":55,"publishedAt":18},"01M7EDQZDQX3Q8Y7GCQX6KN9V7","opportunity-brief","https:\u002F\u002Fgithub.com\u002Fjonahthan433\u002FCortexOS\u002Fblob\u002Fmain\u002Fskills\u002Fsales\u002Fopportunity-brief\u002FSKILL.md",[],[],{"skillNo":57,"name":58,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":7,"ownerLogin":8,"ownerAvatarUrl":9,"ownerAccountNo":10,"ownerDisplayName":11,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":59,"categories":60,"keywords":61,"publishedAt":18},"01M7EDQYA0V9Y99VKBREJJ3MRT","morning-intel","https:\u002F\u002Fgithub.com\u002Fjonahthan433\u002FCortexOS\u002Fblob\u002Fmain\u002Fskills\u002Fresearch\u002Fmorning-intel\u002FSKILL.md",[],[],{"skillNo":63,"name":64,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":7,"ownerLogin":8,"ownerAvatarUrl":9,"ownerAccountNo":10,"ownerDisplayName":11,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":65,"categories":66,"keywords":67,"publishedAt":18},"01M7EDQVX1JVY0B6PDHKKGM19G","decision-brief","https:\u002F\u002Fgithub.com\u002Fjonahthan433\u002FCortexOS\u002Fblob\u002Fmain\u002Fskills\u002Fresearch\u002Fdecision-brief\u002FSKILL.md",[],[],{"skillNo":69,"name":70,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":7,"ownerLogin":8,"ownerAvatarUrl":9,"ownerAccountNo":10,"ownerDisplayName":11,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":71,"categories":72,"keywords":73,"publishedAt":18},"01M7EDQV1GENZAC2SZSD8KZ3GM","weekly-review","https:\u002F\u002Fgithub.com\u002Fjonahthan433\u002FCortexOS\u002Fblob\u002Fmain\u002Fskills\u002Fproductivity\u002Fweekly-review\u002FSKILL.md",[],[],{"skillNo":75,"name":76,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":7,"ownerLogin":8,"ownerAvatarUrl":9,"ownerAccountNo":10,"ownerDisplayName":11,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":77,"categories":78,"keywords":79,"publishedAt":18},"01M7EDQT2KETJ1Y3CGVN9EKW2J","system-health","https:\u002F\u002Fgithub.com\u002Fjonahthan433\u002FCortexOS\u002Fblob\u002Fmain\u002Fskills\u002Fops\u002Fsystem-health\u002FSKILL.md",[],[],{"skillNo":81,"name":82,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":7,"ownerLogin":8,"ownerAvatarUrl":9,"ownerAccountNo":10,"ownerDisplayName":11,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":83,"categories":84,"keywords":85,"publishedAt":18},"01M7EDQQN2JK3XPWMS1M4T0F3K","backup-restore","https:\u002F\u002Fgithub.com\u002Fjonahthan433\u002FCortexOS\u002Fblob\u002Fmain\u002Fskills\u002Fops\u002Fbackup-restore\u002FSKILL.md",[],[]]