Why K2F
From docs/spec/k2f-v0.1.md (public contract, not a paraphrase).
K2F format specification v0.1
Version: 0.1 (tracks k2f_core crate 0.1.0 at release)
K2F (Key-to-Flow) is a ZIP archive containing a semantic document tree, theme, embedded fonts, optional assets, and a compiled geometry lock. Agents and tools write meaning; the reference engine owns layout and pixels.
Contents
For agents
The semantic tree is JSON with stable dotted ids and roles. Patch a clause or total by id. Do not draw a PDF. Do not hand-place coordinates.
For humans
The compiled lock paints the same pages on every official reader. Opening a file is not compiling. The banner reports whether the lock still matches the tree, theme, fonts, and engine.
What it is not
- No PDF import (`PDF_IS_NOT_A_SOURCE`).
- No reflow of body text in the official viewer.
- No drag-layout editing. Changes go through node ids.
- Not a shipped MCP server. Not a packaged desktop installer.