Skip to content

Brain/OKF: conformance check + okf_version + tolerance #70

Description

@parag

Part of the Brain ⇄ OKF compatibility effort (plan: docs/brain-okf-compat.md).

Why

OKF §9 defines conformance (parseable frontmatter, non-empty type, reserved files follow §6/§7) and a consumer-tolerance contract (tolerate missing optional fields, unknown type, unknown keys, broken links, missing index.md). §11 declares okf_version. Formalizing this turns "convention" into a checkable contract and lets us assert the tree is a conformant OKF bundle.

Scope

  • A conformance pass folded into brain.curate (or a brain.okf_check tool): flag every non-reserved .md lacking parseable frontmatter or a non-empty type; verify reserved files (index.md/log.md) match OKF shape.
  • Auto-fix: back-fill a folder-derived type for legacy/unconformant files (additive, safe) — this is the migration path for pre-OKF trees.
  • Declare okf_version: "0.1" at each scope-root index.
  • Document the consumer-tolerance rules in the brain SKILL + brain-implementation.md.

Acceptance criteria

  • brain.curate reports non-conformant files and auto-fills a folder-derived type.
  • A seeded file with no/empty type is flagged then back-filled; re-run is clean.
  • okf_version present at the scope root.
  • Tolerance rules documented; unit + integration + live tests; no regressions.

Files (likely)

packages/@boringos/brain/src/curate.ts (+ optional okf.ts), packages/@boringos/core/src/modules/brain.ts, docs.

Metadata

Metadata

Assignees

No one assigned

    Labels

    brainBoringOS Brain / foundation memoryenhancementNew feature or requestokfOKF (Open Knowledge Format) compatibility

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions