Architecture
Genbeya is decomposed by volatility, following the iDesign Method: each layer hides one thing that is likely to change, and calls only go down.
| Layer | Folder | Hides | May use |
|---|---|---|---|
| Contracts | src/contracts/ | Nothing: the types every layer agrees on, the RPC envelope and the shell bridges | — |
| Utilities | src/utilities/ | Path rules, hashing, queues, tree building, version numbers | contracts |
| Engines | src/engines/ | The rules for tasks and their comments and activity, wiki pages, settings, link rewriting, search results, interactive rebases and the AI agent files, and the sample repository’s content. Pure functions, no I/O | contracts, utilities |
| Resource access | src/access/ | Where repositories live (local, WSL, SSH), how Git is called, how files and preferences are stored | contracts, utilities, the Machine port |
| Managers | src/managers/ | The use cases: open a repository, save a page, commit. One per area of change | engines, access |
| Platforms | src/platforms/ | The machine itself: Node’s fs, child_process and node-pty, or Tauri’s Rust commands | contracts |
| Shells | src/shells/ | The runtime: window, IPC, menus, packaging; or VS Code’s views and editors | everything below |
| Client | src/client/ | The user interface | contracts only; reaches the managers through its platform connector |
ESLint enforces the table: a layer that imports from a layer it may not use fails the lint, and node:* modules are only allowed in platforms and shells.
Within the client, features use the core services and the generic building blocks in ui/ (dialogs, trees, menus, the guided tour); only core/ talks to the platform connector.
The VS Code extension is a shell without the client: native views and two small webviews (a preview and the board) call the managers directly, and render Markdown with the client’s pipeline. The Kit is that renderer and the editor as one bundle for other apps’ web views, such as the mobile app: the same renderer (src/shells/webview/), with the host behind messages.
The Demo that runs in a browser has no shell and no machine: its connector runs managers of its own (src/managers/demo/) in the page, on Git repositories simulated in memory (src/access/memory/), with the same engines.
Pages shown outside Genbeya, such as the wiki on genbeya.fyi, draw their plan blocks with src/shells/docs/plans.ts: plan() of the client’s Markdown pipeline on a repository’s task files and .genbeya.yml.
| Page | Covers |
|---|---|
| Managers | What the backend can do, call by call: snapshots, operations that stop, comments, search, moving pages, writes |
| Hosts | Repositories on this computer, on WSL and over SSH, and their terminals |
| Content branch | Keeping the wiki, the tasks or the settings on a shared branch |
| Runtimes | Electron, Tauri and Deno Desktop compared, with measurements |
| Demo | Genbeya in a browser tab, on repositories in memory: how it works, what it simulates, and why |
| VS Code | The VS Code extension: managers in the extension host, native views, a preview and a board |
| Kit | The renderer and the editor for other apps’ web views: the bundle, the message protocol, tests and releases |
| Security | How the app protects itself from the repositories it shows |