Pick any line to see why it is the way it is: the commit, the pull request and issue it came from, and what the agent was thinking.
| The docs service answers every artifacts call: docs can be made, listed, shared, moved, trashed, restored, searched, versioned and edited live in their own rooms, agents read, write and recall them only where their person and everyone in the conversation can, and folio events go out on the bus, while Docs' pages keep working as before. | 1 | /** |
| 2 | * The kinds the room knows, one line each (docs/ARTIFACTS_MODE.md, | |
| 3 | * section 3). A kind without a line here can't be made yet: the service | |
| 4 | * says it is coming. Append only; never reformat (parallel phases each | |
| 5 | * add their line). | |
| 6 | */ | |
| 7 | import type { FolioKind } from "@g1t/contracts"; | |
| 8 | ||
| 9 | import { doc } from "./doc/index.ts"; | |
| 10 | import type { KindModel } from "./types.ts"; | |
| 11 | ||
| 12 | export const KINDS: Partial<Record<FolioKind, KindModel>> = { | |
| 13 | doc, | |
| 14 | }; | |
| 15 | ||
| 16 | /** The kind's model, or null when it isn't built yet. */ | |
| 17 | export function kindModel(kind: string | null | undefined): KindModel | null { | |
| 18 | return (KINDS as Record<string, KindModel | undefined>)[String(kind ?? "")] ?? null; | |
| 19 | } |