Expand description
Metadata: the kind schema (kinds.yaml) and one JSON Schema per kind, both read at run
time from the tool distribution’s share directory and, when a repository adds its own,
from .ai/repo/knowledge/; and the YAML helpers shared by every reader. The contract
is documented in docs/CAPABILITIES.md and in share/kinds.yaml itself.
Modules§
- frontmatter
- Front matter: the metadata block at the top of a document of the layer.
- yaml
- The layer’s YAML subset, as
docs/SCHEMAS.mdand the shell tool’smj_yaml_flattendefine it:key: value, nested maps by two-space indent, block lists (- item), lists of maps (- key: valueplus indented keys), inline lists[a, b], single or double quotes, comments. Tabs, odd indentation, anchors, multi-line scalars and flow maps are refused with the line named (the shell parser reads an anchor or alias as text; this one refuses it, which is the stricter reading of the same contract). A scalar is a string unless it is an unquoted integer ortrue/false; nothing else is interpreted.
Structs§
- Kind
Schema - The kind schema with every JSON Schema it names compiled.
- Kind
Spec - One entry of
kinds.yaml. - Schema
- One JSON Schema, compiled, with where it came from.
- Schema
Set - Schemas gathered from the distribution and the repository, each name once.
- Schema
Version - A field whose value must be one of the listed ones: an integer (
version: 1) or a string (schema: context/v1). - Violation
- One failed constraint of a validation.
Enums§
- Format
- How a file of a kind is read.
- Front
Matter Rule - Whether a Markdown kind must, may, or does not carry front matter.
Constants§
- KINDS_
SCHEMA - The one schema version this executable reads.
- REPO_
KINDS_ FILE - The file, under the manifest’s
knowledgesection, in which a repository adds kinds. - REPO_
SCHEMAS_ DIR - The directory, under the manifest’s
knowledgesection, in which a repository adds schemas.