Google OKF (Open Knowledge Format)
What is OKF?
Section titled โWhat is OKF?โOKF (Open Knowledge Format) is a specification from GoogleCloudPlatform/knowledge-catalog for machine-readable frontmatter on knowledge pages. It enables:
- Trust tier display โ human-reviewed vs agent-authored content
- Automated staleness detection โ
stale_afterdates trigger annual review - Provenance tracking โ
generated.at,verified.at,generated.by,verified.by - Cross-repo bundle exchange โ OKF-conformant bundles can be shared between repositories
Colibri adopted OKF v0.2 in commit 0c964cd (2026-07-26).
Frontmatter Schema (v0.2)
Section titled โFrontmatter Schema (v0.2)โEvery docs/wiki/*.md page now carries this frontmatter:
---type: "Agent Harness Reference" # Type taxonomy (see below)title: "Agent Harness Reference" # Human-readable titledescription: "The zot (agent) + Colibri (control plane) split..."tags: [architecture, cost, skill, task, agent, harness, hive, deploy, jail, mother, vault, terminal, tmux, ssh, benchmark, pricing, tokenomics, naming, quality, contract, store, pull, daemon, factory, rust, bare, llama, glm, deepseek, a2a, model, doctor, headroom, dashboard, operator, routing, pane, external]status: "stable" # stable | draft | deprecatedstale_after: "2026-12-31" # ISO date โ triggers annual reviewgenerated: by: "human:sam" # human:sam | agent:zot/v1.2.3 at: "2026-06-15T10:00:00Z" # ISO 8601 timestampverified: - by: "human:sam" at: "2026-06-20T09:00:00Z"---Type Taxonomy
Section titled โType Taxonomyโ| Type | Pages |
|---|---|
| Agent Harness Reference | agent-harness, agent-events-reference, glasspane, hive-pane, hive-routing, runtime-inventory |
| Cost Model | cost-model, deepseek-pricing, glm-pricing, tokenomics |
| Skill Catalog Entry | skills-catalog, layered-soul |
| Task Board Design | task-board, task-dispatch-flow |
| Operational Procedure | deployment, doctor, jail-confinement, mother-hive, updating-a-node, vault-provision, terminal, tmux-safety |
| Glossary | abbreviations |
| Reference | contracts, store-schema, pull-requests, naming-decisions, quality-gates, factory-model, rust-glossary, bare-metal-freebsd, llama-cpp, llama-cpp-benchmarks, glm-pricing, deepseek-pricing, a2a-complexity-audit, model-selection-and-eval, doctor, headroom-sidecar, ssh-bridge, cost-dashboard, operator-attention, operator-cli, external-mcp |
| Architecture Decision | (reserved for ADRs) |
Trust Tiers
Section titled โTrust Tiersโ| Tier | generated.by | verified.by | Display |
|---|---|---|---|
| Human-reviewed | human:sam | human:sam | โ Green badge |
| Agent-authored, human-verified | agent:zot/v1.2.3 | human:sam | ๐ก Yellow badge |
| Agent-authored, unverified | agent:zot/v1.2.3 | โ | ๐ด Red badge |
The operator-attention predicate uses these tiers to surface pages needing review.
Automation: wiki-to-okf.sh
Section titled โAutomation: wiki-to-okf.shโThe script at scripts/wiki-to-okf.sh adds frontmatter to all wiki pages:
# Dry run โ show what would change./scripts/wiki-to-okf.sh --dry-run
# Apply frontmatter to all pages./scripts/wiki-to-okf.sh
# Apply and run wiki-lint --strict./scripts/wiki-to-okf.sh --verifyWhat it does
Section titled โWhat it doesโ- Skips
index.md(getsokf_version: "0.2"only) andlog.md - Extracts title from first
#heading - Extracts description from first paragraph after title
- Infers type from filename keywords
- Generates tags from filename keywords
- Sets
stale_after: "2026-12-31"(annual review cycle) - Sets
generated.by: "human:sam"andverified.by: "human:sam"(all current pages are human-reviewed)
Type Inference Logic
Section titled โType Inference Logicโcase "$filename" in *pricing*|*cost*|*tokenomics*) type="Cost Model" ;; *skill*|*catalog*|*layered-soul*) type="Skill Catalog Entry" ;; *task*|*board*|*scheduler*|*dispatch*) type="Task Board Design" ;; *agent*|*harness*|*event*|*hive*|*runtime*|*glasspane*) type="Agent Harness Reference" ;; *deploy*|*jail*|*mother*|*updating*|*vault*|*terminal*|*tmux*) type="Operational Procedure" ;; *abbrev*) type="Glossary" ;; *naming*|*quality*|*contract*|*store*|*pull*|*daemon*|*factory*|*rust*|*bare*|*llama*|*bench*|*glm*|*deepseek*|*a2a*|*model*|*doctor*|*headroom*|*ssh*|*cost-dash*|*operator*|*hive-pane*|*hive-rout*|*external*) type="Reference" ;; *) type="Architecture Decision" ;;esacCI Integration
Section titled โCI IntegrationโThe OKF frontmatter is validated at three points:
-
wiki-lint --strict(in CI build)
Checks all wiki pages for:- dangling references (broken links) โ links pointing to non-existent pages
- resurrected names โ old terms that reappeared after being renamed
- orphan pages โ pages that exist but nothing links to them
-
ci-checks.sh --strict(in CI build)
Runs the full test suite includingwiki-lintโ part of the pre-merge gate that runs before pushing to Git repository -
Pre-push hook (before
git push, local)
Blocksgit pushifwiki-lintfails โ same as clippy warnings blocking push
Example: Abbreviations Page Frontmatter
Section titled โExample: Abbreviations Page Frontmatterโ---type: "Glossary"title: "Abbreviations"description: "Expansions for acronyms and technical terms used across Colibri wikis. When a new term enters a wiki page, add it here so the next reader doesn't have to search."tags: [abbreviations, glossary]status: "stable"stale_after: "2026-12-31"generated: by: "human:sam" at: "2026-06-15T10:00:00Z"verified: - by: "human:sam" at: "2026-06-20T09:00:00Z"---Benefits for Colibri
Section titled โBenefits for Colibriโ| Feature | How it helps |
|---|---|
| Staleness alerts | stale_after: 2026-12-31 โ annual review reminder in TUI/CLI |
| Trust transparency | Operator sees which pages are human-verified vs agent-generated |
| Audit trail | generated.at / verified.at timestamps for compliance |
| Cross-repo sync | OKF bundles can be exchanged with other GoogleCloudPlatform/knowledge-catalog consumers |
| Agent authorship | Future agent-authored pages get generated.by: agent:zot/vX.Y.Z for traceability |
The Three Cost Parallels (Visual)
Section titled โThe Three Cost Parallels (Visual)โThe โthree cost parallelsโ from tokenomics.md โ three strategies to reduce LLM API costs:
Price โ โ โโโโโโโโโโโ โโโโโโโโโโโ โ โ PEAK โ โ PEAK โ โ daytime / high demand โ โโโโโโฌโโโโโ โโโโโโฌโโโโโ โ โ โ โ โโโโโโดโโโโโ โโโโโโดโโโโโ โ โ VALLEY โ โ VALLEY โ โ night / low demand โ โโโโโโโโโโโ โโโโโโโโโโโ โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ Time Day 1 Day 2| Lever | What it means | How it saves money |
|---|---|---|
| (valley) | Timing โ run workloads during off-peak hours when providers charge less | DeepSeek has โpeak-valley pricingโ: ~50% cheaper at night (UTC 16:00โ08:00) / Ljubljana night |
| predpomnilnik (prefix) | Caching โ reuse the prompt prefix so you donโt pay for re-processing the same context | Byte-stable prefixes = cache hits = pay only for new tokens |
| proraฤun (cost modes) | Budget mode โ choose cheaper models / smaller contexts / fewer tokens for non-critical tasks | e.g. use GLM-5-Turbo instead of GLM-5.2, or 8B instead of 14B |
Why โvalleyโ? It comes from DeepSeekโs pricing model (and AWS spot instances): the โvalleyโ is the cheap time window. Schedule heavy workloads (evals, batch jobs, indexing) into the valley to cut costs ~50%.
Future Work
Section titled โFuture Workโ- TUI/CLI trust-tier display (operator-attention predicate)
- Automated staleness detection via
stale_afterdate - Agent-authored page auditing (
generated.by = agent/version) - Cross-repo bundle exchange (OKF conformant)
- Integration with
colibri doctorfor wiki health checks
References
Section titled โReferencesโ- GoogleCloudPlatform/knowledge-catalog SPEC.md
- Colibri commit 0c964cd โ initial OKF adoption
- Colibri commit 5d3925f โ prettier formatting
scripts/wiki-to-okf.shโ automation scriptscripts/wiki-lintโ validation script