Skip to main content

Module schema_export

Module schema_export 

Source
Expand description

Generates docs/schemas/ (LAB-1829) from this repo’s real schemas: the hand-written project-config schema (mecha10_core::schema_validation::get_project_schema, with its behaviors property overridden by the real schemars-derived BehaviorsConfig schema – see [project_schema_with_introspected_behaviors]) and the schemars-derived per-node-type/model-catalog schemas (mecha10_schema_registry). See docs/validate-configs.md for how these schemas are used to validate configs; this module is purely about rendering them as reference docs — it adds no new schema content and hand-writes no field descriptions (those come from the schemas themselves, which pull node-config field docs from packages/nodes/*/src/config.rs’s doc comments via schemars).

Every file this writes is generated output: the raw schema JSON (one file per schema) plus a single Markdown field reference. scripts/ci/schema-docs-check.sh re-runs this and diffs against what’s committed, so docs/schemas/ can never silently drift from the schemas it documents.

Structs§

SchemaExportService
Generates docs/schemas/-style reference docs (raw JSON Schema files plus a Markdown field reference) from every schema this CLI knows about. See the module-level docs for what “knows about” means and why nothing here hand-writes schema content.