Blueprint

Architecture

The layers, five rules, one engine everywhere, and each kit saving its own file.

Updated

Kition is a desktop app with an AI agent and 16 kits: a Tauri shell around a Rust runtime. The same kits are delivered to other products as Kition Kits, and to teams in Kition One.

Layers

Kition’s layers, top to bottom
LayerWhat it does
ClientsPeople (the kit’s own editor), your product (the editor embedded in a page), scripts (the object model) and AI agents (MCP tools that follow KHP). All four go through the same entry point
SessionTurns commands into transactions; provides the object model; pushes events and presence; undoes per author
KitOne engine per kind of file: domain rules, validation, layout, rendering, and reading and writing files
DataThe Kit Data Model (KDM): one data model shared by the kits, where every change merges and has history
Storage and syncYour folder when you work alone; Kition Server, or Kition Cloud, when you co-edit

Five rules

  1. One authority per document. When collaborating, the KDM replica is the source of truth; the engine’s model is a view of it. Never sync by replacing the whole document.
  2. Every change is a transaction. Typing, dragging, menus, scripts, extensions, imports and AI all go through the same entry point, with no back doors. Each transaction records who made it: a person, an agent, a script, an import or the system.
  3. Files are for saving and sharing, not state. Each kit saves its own file (Doc saves .docx, CAD saves .dxf, Board saves .kboard). Opening reads it into the model; saving writes it back. Your files stay your files.
  4. Private state is not replicated. Selection, cursor, zoom and render output are not synced as document data; cursors and selections travel separately as presence.
  5. One contract everywhere. The web, the desktop and the server run the same engine behind the same interface.

One engine everywhere

Most kit engines are written in Rust. They compile to WebAssembly to run on the web and the desktop, and to native executables (kition-<kit>, such as kition-slide) to run headless on servers. In testing, the Rust and TypeScript replicas came out byte-for-byte identical.

That gives you three things:

  • What AI changes is what people see: a file AI edits headless on a server is exactly what a person sees when they open it in the editor.
  • Embedding needs no rewrite: putting the editor in another product uses the same kit package.
  • No second implementation on the server: previews, exports, validation and server-side agents all use the same engine.

How files are stored

  • Your document is a file in your own folder, in the kit’s format; Kition keeps its working data (history, assets) in a .kition folder in the workspace.
  • If the file changes outside Kition, the new content comes in as an import rather than being overwritten.
  • Content a kit doesn’t recognize (say, a rare feature of a format) is kept as a read-only “preserved as is” object and written back on save.

The protocol itself, the Kit Harness Protocol (KHP), lives at kitharness.org.

Ready when you are.

Kition is a desktop AI workspace for connected documents, structured tables, editable designs, whiteboards, visual workflows, and reviewable AI agents.