agentleFS
Codename-11Codename-11/SubFrame/.agents/skills/sub-ipc/SKILL.md

sub-ipc

Skill9 starsChanged 8 months agoMITView on GitHub

Regenerate the IPC channel reference documentation from ipcChannels.ts type maps.

The file

We split this skill into the rules it gives an agent

5 rules. About 0 are common, 0 are distinctive, and 5 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈0

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 5

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Read src/shared/ipcChannels.ts completely.

    line 21
  2. Very specific:

    If it appears in IPCHandleMap → handle

    line 31
  3. Very specific:

    If it appears in both IPCSendMap and IPCEventMap → send + event (bidirectional)

    line 34
  4. Very specific:

    If it appears in NONE of the maps → ⚠ (untyped/legacy)

    line 35
  5. Very specific:

    Write .subframe/docs-internal/refs/ipc-channels.md with this structure:

    line 39

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

SubFrame IPC Reference Regeneration

Regenerate .subframe/docs-internal/refs/ipc-channels.md from the source of truth: src/shared/ipcChannels.ts.

Dynamic Context

Current channel count: !node -e "const src=require('fs').readFileSync('src/shared/ipcChannels.ts','utf8'); const m=src.match(/^\s+\w+:\s*'/gm); console.log(m ? m.length + ' channels in IPC constant' : 'Could not count')"

Instructions

Step 1: Read Source

Read src/shared/ipcChannels.ts completely. Extract:

  1. IPC constant — all channel name constants, grouped by their comment headers (e.g., // Terminal, // Workspace)
  2. IPCHandleMap — channels using the handle pattern (request/response)
  3. IPCSendMap — channels using the send pattern (fire-and-forget)
  4. IPCEventMap — channels using the event pattern (main→renderer push)

Step 2: Classify Each Channel

For every channel in the IPC constant, determine its pattern:

  • If it appears in IPCHandleMap → handle
  • If it appears in IPCSendMap → send
  • If it appears in IPCEventMap → event
  • If it appears in both IPCSendMap and IPCEventMap → send + event (bidirectional)
  • If it appears in NONE of the maps → ⚠ (untyped/legacy)

Step 3: Write Reference Doc

Write .subframe/docs-internal/refs/ipc-channels.md with this structure:

# IPC Channel Reference

**Source of truth:** `src/shared/ipcChannels.ts`

All channels are typed. Three communication patterns are used:

| Pattern | Direction | Usage |
|---------|-----------|-------|
| `ipcMain.handle` / `ipcRenderer.invoke` | Renderer → Main (request/response) | Data fetching, mutations |
| `ipcRenderer.send` / `ipcMain.on` | Renderer → Main (fire-and-forget) | Commands, notifications |
| `webContents.send` / `ipcRenderer.on` | Main → Renderer (push events) | Data updates, state changes |

Channels marked ⚠ are defined in the `IPC` constant but not yet in `IPCHandleMap`, `IPCSendMap`, or `IPCEventMap` type maps.

---

## Channels by Domain

### {Domain} ({N} channels)
| Channel | Pattern | Purpose |
|---------|---------|---------|
| `CHANNEL_NAME` | pattern | Brief purpose |

...

---

**Total: {N} channels** ({H} handle, {S} send, {E} event, {U} untyped/legacy)

*Regenerated from `ipcChannels.ts` — keep this reference in sync when adding/removing channels.*

Rules

  • Group channels by the // comment headers in the IPC constant
  • Purpose descriptions should be concise (3-8 words)
  • Count channels that appear in multiple maps only once for the total
  • Flag channels not in any type map with ⚠
  • Include a note for legacy channels that have been superseded by handle patterns

Step 4: Verify

Count the total channels and verify it matches the number of entries in the IPC constant.

Download now (ZIP)

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
What did you use it for? e.g. Reviewing pull requests in a Rails app

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.