ctxbrew-manifest schema (v1.3)
The ctxbrew-manifest file is validated by the normative JSON Schema published at its canonical URL:
- $id: https://contextbrew.dev/schemas/ctxbrew-manifest/v1.3/schema.json
- Format version:
1.3.0 - Schema dialect: draft-07
- Validate with:
ctx schema ctxbrew-manifestor any JSON Schema validator (ajv, VS Code, …)
Root object: CtxbrewManifest
Section titled “Root object: CtxbrewManifest”.ctxbrew manifest.json schema v1
| Property | Type | Required | Description |
|---|---|---|---|
version | "1.3.0" | yes | Format version (semver-like, major.minor.patch). 1.3.0 — evaluation suites (T1335, 2026-09-30): ModelIndex/CTXBREW_FILES/CtxbrewModels gained evals (models/evals.json). Older archives unpack unchanged: readers ignore unknown manifest fields and unlisted ZIP entries. 1.2.0 — authored documents (2026-09-26): the manifest gained an optional documents index and archives may carry documents/<slug>.mdx raw MDX entries (see CtxbrewDocument). 1.1.0 — additive widening (audit W6.3, 2026-09-19): ModelIndex/ CTXBREW_FILES/CtxbrewModels gained cbrl/c4/absl/context-map/esdm/ decision. 1.0.0 archives (five model kinds only) unpack unchanged. |
createdAt | string | yes | ISO 8601 timestamp when the file was created |
projectId | string | yes | Unique project identifier (UUID or slug) |
projectName | string | yes | Human-readable project name |
models | ModelIndex | yes | Map of model type to filename within models/ |
history | string | no | Optional history snapshot log filename |
documents | DocumentIndexEntry[] | no | Authored project documents carried in this archive (1.2.0). Each entry corresponds to a raw documents/<slug>.mdx ZIP entry; the index holds the metadata + integrity digest while the MDX text stays verbatim (plain, git-diffable, no JSON wrapping). |
encryption | EncryptionMetadata | no | Optional encryption metadata (reserved for future use) |
Definitions
Section titled “Definitions”CommentThreadPayload
Section titled “CommentThreadPayload”One review-comment thread attached to an anchored span in the MDX.
| Property | Type | Required | Description |
|---|---|---|---|
author | string | yes | |
text | string | yes | |
createdAt | string | yes | ISO 8601 creation timestamp. |
resolved | boolean | no | Resolved threads stay visible (greyed) until deleted. |
DocumentFrontmatter
Section titled “DocumentFrontmatter”| Property | Type | Required | Description |
|---|---|---|---|
title | string | no | |
subtitle | string | no | |
author | string | no | |
date | string | no | |
logoUrl | string | no | |
accentColor | string | no | |
vocabVersion | number | no | |
commentThreads | Record<string, CommentThreadPayload> | no | Threaded review comments (WS5): keyed by threadId; the MDX carries only <span data-thread-id="…"> anchors. Written through the server-side merge route (POST /api/documents/:id/comment-threads) — never via a wholesale frontmatter PUT, which would clobber sibling keys like frozenEmbeds. |
contextbrewFirstUsefulExperience | Record<string, unknown> | no | First Useful Experience first-task marker (apps/web lib/server/first-task-document.ts is the owner). Bounded ids/enums only; opaque to the document editor and carried verbatim on frontmatter round-trips. Grants no authority. |
DocumentIndexEntry
Section titled “DocumentIndexEntry”Metadata for one authored document in the manifest’s documents index. The MDX content itself lives in the ZIP entry documents/<slug>.mdx.
| Property | Type | Required | Description |
|---|---|---|---|
slug | string | yes | URL-safe document slug (unique within the archive; no path separators). |
title | string | yes | |
section | DocumentSection | yes | |
contentVersion | number | yes | |
frontmatter | DocumentFrontmatter | no | |
sha256 | string | yes | Hex sha256 of the raw .mdx bytes — verified on unpack. |
DocumentSection
Section titled “DocumentSection”Document Facet — domain types for project documents.
Type: "input" | "work" | "archived"
EncryptionMetadata
Section titled “EncryptionMetadata”Encryption metadata (reserved for v2+). In v1, files are stored as plaintext JSON+gzip.
| Property | Type | Required | Description |
|---|---|---|---|
algorithm | string | yes | Encryption algorithm identifier (e.g., "aes-256-gcm") |
kdf | string | yes | Key derivation function identifier (e.g., "argon2id") |
salt | string | yes | Salt used for key derivation (base64url) |
nonce | string | yes | Nonce/IV for the encryption (base64url) |
ModelIndex
Section titled “ModelIndex”Index of available models in the archive. Each value is the relative path to the model JSON within the ZIP.
| Property | Type | Required | Description |
|---|---|---|---|
ddd | string | no | |
usm | string | no | |
scm | string | no | |
dsm | string | no | |
sim | string | no | |
cbrl | string | no | Audit W6.3: requirements/spec exports (previously silently dropped). |
c4 | string | no | |
absl | string | no | |
context-map | string | no | |
esdm | string | no | |
decision | string | no | |
evals | string | no | T1335 (1.3.0): evaluation suites — the tiered verification artifact. |
See the schemas overview for the versioning policy and how these files are generated and kept in sync.
