RDF/XML serialization is deferred.
{
"@context": {
"schema": "https://schema.org/",
"wiki": "https://wazootech.github.io/wiki/",
"foaf": "http://xmlns.com/foaf/0.1/",
"rdf": "http://www.w3.org/1999/02/22-rdf-syntax-ns#",
"rdfs": "http://www.w3.org/2000/01/rdf-schema#",
"xsd": "http://www.w3.org/2001/XMLSchema#",
"owl": "http://www.w3.org/2002/07/owl#",
"dc": "http://purl.org/dc/elements/1.1/",
"dcterms": "http://purl.org/dc/terms/",
"sh": "http://www.w3.org/ns/shacl#",
"wazoo": "https://schema.wazoo.dev/"
},
"@id": "wiki:wiki_check",
"@type": "schema:TechArticle",
"schema:articleBody": "# `wiki check`\n\nRun **integrity** checks on the wiki: strict **SHACL** validation, **JSON Schema** frontmatter validation, route safety, output collisions, and layout frontmatter contracts.\n\nExits **0 silently** on success unless `-v` is set. See [Design Philosophies](Design_Philosophies.md).\n\n## Usage\n\n```bash\nwiki check\nwiki check wiki/Some_Page.md\nwiki check wiki/A.md wiki/B.md\nwiki check -v\nwiki check --strict\nwiki check -f json wiki/Some_Page.md\n```\n\n## Options\n\n| Flag | Description |\n| ----------------- | ------------------------------------------------------------------------------------- |\n| `FILE...` | Optional documents; otherwise entire wiki (scoped mode: SHACL + JSON Schema per file) |\n| `-v`, `--verbose` | Print warnings |\n| `--strict` | Treat warnings as errors (exit 1) |\n| `-f`, `--format` | `text` (default) or `json`; see [JSON output](#json-output) |\n| `--json` | Shorthand for `--format json` |\n\n## What is checked\n\n### Full wiki (default)\n\n`wiki check` with no `FILE` argument runs every check below.\n\n### Always errors (not configurable)\n\n- **SHACL** — shapes from wiki frontmatter (`sh:NodeShape`, etc.) on the full RDF graph\n- **Route safety** — unsafe path segments (spaces, reserved characters, and similar)\n- **Output collisions** — two wiki sources mapping to the same built URL (against default `_site` layout)\n\n### Configurable (`check.*` in `wiki.yaml`)\n\n| Rule key | What it audits |\n| --------------------- | ------------------------------------------------------------------- |\n| `missing_layout_file` | `wazoo:layout` paths that do not resolve to a readable `.html` file |\n| `frontmatter_schema` | Frontmatter that fails JSON Schema validation |\n| `missing_schema_ref` | `wazoo:jsonSchema` paths or URLs that cannot be loaded |\n| `shape_definition` | Ill-formed SHACL shape pages (see [below](#shape-definitions)) |\n| `shape_unused` | Node shape pages that validate nothing |\n| `remote_schema_refs` | Policy for remote schema URLs: `allow`, `deny`, or `allowlist` |\n| `remote_schema_hosts` | Hostnames allowed when `remote_schema_refs` is `allowlist` |\n\nDefault: `missing_layout_file`, `frontmatter_schema`, `missing_schema_ref`, and `shape_definition` are `error`. `shape_unused` is `warning`. `remote_schema_refs` defaults to `allow`.\n\n### Shape definitions\n\nA shape page is ordinary frontmatter, so a misspelled `sh:` key compiles to an inert triple and the constraint it meant to declare never fires. `shape_definition` runs before SHACL and fails the check when a page, or a shape nested in it, breaks a SHACL Core rule: an unknown `sh:` term, a property shape without `sh:path`, a malformed path, or a non-IRI value for an IRI-valued parameter. While any remain as errors, SHACL validation is skipped and a `shacl_skipped` warning says so, because a broken shape makes the SHACL verdict meaningless. A node shape that applies to nothing is reported separately, under `shape_unused`, as a warning by default. Each finding names the route and the key path, for example `In Purchase_Shape: sh:property[0].sh:minCont: …`. Shapes written in RDF (fenced `turtle` blocks and `.ttl` and other RDF files) get the same checks, and their findings name the source and the shape. Findings appear in `wiki check -f json` under the code `shape_definition`. See [SHACL](SHACL.md#shape-page-checks) for the rules.\n\n### JSON Schema frontmatter\n\nBind schemas on `sh:NodeShape` documents with `wazoo:jsonSchema` and `sh:targetClass`. Type-level schemas apply to every matching page; pages may append extra schemas with their own `wazoo:jsonSchema` (string or list). Local refs resolve under the wiki config root; remote `http(s)` URLs are fetched at check time unless `check.remote_schema_refs` is `deny` or the host is outside `check.remote_schema_hosts` when using `allowlist`. Shape binding documents are excluded from instance validation. See [SHACL](SHACL.md) and [Style Guide](Style_Guide.md#shacl-shapes).\n\nBroken links, filename pattern, and heading style are **not** part of `wiki check` — use [wiki lint](wiki_lint.md).\n\n### Scoped mode (one or more FILE args)\n\n`wiki check path/to/Page.md` (or multiple paths) runs **SHACL and JSON Schema** per file. Route safety, output collisions, and layout frontmatter rules are **full-wiki only**. Cross-document SHACL interactions may only appear in a full-wiki check. Broken links on those pages require `wiki lint` with the same paths.\n\n`--strict` applies only when warnings exist; scoped mode does not emit warnings today.\n\n## JSON output\n\n`wiki check -f json` writes a structured report to **stdout** so editors and CI can tell which document, which frontmatter field, which shape, and which constraint failed without parsing the text report. The text report still goes to stderr, and the exit code is unchanged (1 when the check fails, 0 otherwise).\n\n```json\n{\n \"version\": 1,\n \"ok\": false,\n \"documents\": [\n {\n \"path\": \"wiki/CSS.md\",\n \"route\": \"CSS\",\n \"focusNode\": \"https://wiki.example.org/CSS\",\n \"conforms\": false,\n \"results\": [\n {\n \"code\": \"shacl_violation\",\n \"severity\": \"error\",\n \"check\": \"shacl\",\n \"message\": \"Article must have a description.\",\n \"resultPath\": \"https://schema.org/description\",\n \"frontmatterKeys\": [\"description\", \"schema:description\"],\n \"shaclSeverity\": \"http://www.w3.org/ns/shacl#Violation\",\n \"sourceConstraintComponent\": \"http://www.w3.org/ns/shacl#MinCountConstraintComponent\",\n \"sourceShapes\": [\n {\n \"iri\": \"https://wiki.example.org/Article_Shape\",\n \"route\": \"Article_Shape\",\n \"path\": \"wiki/Article_Shape.md\",\n \"targetClass\": [\"https://schema.org/Article\"],\n \"label\": \"Article Shape\"\n }\n ],\n \"value\": null,\n \"schema\": null,\n \"instancePath\": null,\n \"keyword\": null\n }\n ]\n }\n ],\n \"issues\": [\n {\n \"code\": \"shacl_violation\",\n \"severity\": \"error\",\n \"message\": \"SHACL Validation Violation in CSS.md: ...\",\n \"path\": \"wiki/CSS.md\",\n \"route\": \"CSS\"\n }\n ]\n}\n```\n\n- **`version`** is the envelope's format version, currently `1`. New fields can appear without a bump; renaming, removing, or changing the meaning of a field bumps it.\n- **`issues`** lists every issue the text report shows, with the same `code`, `severity`, and `message`. Warnings are always included, with or without `-v`.\n- **`documents`** groups the document-level issues by page. Each SHACL result and JSON Schema failure gets its own entry in `results`. In scoped mode every `FILE` gets an entry, even when it conforms. In full-wiki mode, only documents with findings are listed.\n- **`frontmatterKeys`** are the frontmatter spellings of `resultPath`, resolved through the wiki context. A key the page already uses is listed alone. For a missing field, the list holds the spellings that would satisfy it.\n- **`sourceShapes`** names the shape page that declared the failing constraint (SHACL's `sh:sourceShape`), with its `sh:targetClass` and `rdfs:label`. A named `sh:PropertyShape` page is named itself, even when a node shape lists it under `sh:property`. An inline property shape is named by the node shape page that holds it. Blank nodes are never serialized because their labels change between runs. A constraint that has no named shape gives an empty list.\n- JSON Schema results (`check: \"jsonSchema\"`) carry `schema`, `instancePath`, and `keyword`. SHACL results (`check: \"shacl\"`) carry `resultPath`, `sourceConstraintComponent`, and `value`. A result whose focus node matches no document is listed under a document with `path: null`. It is never dropped.\n\n### Related CI commands\n\n| Command | Purpose |\n| --------------------- | ---------------------------------------------------- |\n| `wiki lint --strict` | Broken links, filename pattern, headings, link style |\n| `wiki fmt --check` | Deno Markdown formatter consistency |\n| `wiki render --check` | Stale inline SPARQL result blocks |\n| `wiki link --check` | Remaining missing-wikilink opportunities |\n\n`wiki build` runs `wiki lint` then `wiki check` before writing output unless `--no-check`.\n\n## Related\n\n- [Wiki Configuration](Wiki_Configuration.md) — `check.*` severities\n- [SHACL](SHACL.md) — shape and JSON Schema binding\n- [wiki lint](wiki_lint.md) — convention lane\n- [Style Guide](Style_Guide.md)",
"schema:dateCreated": {
"@type": "xsd:dateTime",
"@value": "2026-10-31T23:19:03Z"
},
"schema:dateModified": {
"@type": "xsd:dateTime",
"@value": "2026-10-31T23:19:03Z"
},
"schema:description": "Integrity checks — SHACL validation, JSON Schema frontmatter, route safety, and layout frontmatter.",
"schema:headline": "wiki check"
}
@prefix schema: <https://schema.org/>.
@prefix wiki: <https://wazootech.github.io/wiki/>.
@prefix foaf: <http://xmlns.com/foaf/0.1/>.
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>.
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#>.
@prefix xsd: <http://www.w3.org/2001/XMLSchema#>.
@prefix owl: <http://www.w3.org/2002/07/owl#>.
@prefix dc: <http://purl.org/dc/elements/1.1/>.
@prefix dcterms: <http://purl.org/dc/terms/>.
@prefix sh: <http://www.w3.org/ns/shacl#>.
@prefix wazoo: <https://schema.wazoo.dev/>.
wiki:wiki_check a schema:TechArticle;
schema:description "Integrity checks — SHACL validation, JSON Schema frontmatter, route safety, and layout frontmatter.";
schema:articleBody "# `wiki check`\n\nRun **integrity** checks on the wiki: strict **SHACL** validation, **JSON Schema** frontmatter validation, route safety, output collisions, and layout frontmatter contracts.\n\nExits **0 silently** on success unless `-v` is set. See [Design Philosophies](Design_Philosophies.md).\n\n## Usage\n\n```bash\nwiki check\nwiki check wiki/Some_Page.md\nwiki check wiki/A.md wiki/B.md\nwiki check -v\nwiki check --strict\nwiki check -f json wiki/Some_Page.md\n```\n\n## Options\n\n| Flag | Description |\n| ----------------- | ------------------------------------------------------------------------------------- |\n| `FILE...` | Optional documents; otherwise entire wiki (scoped mode: SHACL + JSON Schema per file) |\n| `-v`, `--verbose` | Print warnings |\n| `--strict` | Treat warnings as errors (exit 1) |\n| `-f`, `--format` | `text` (default) or `json`; see [JSON output](#json-output) |\n| `--json` | Shorthand for `--format json` |\n\n## What is checked\n\n### Full wiki (default)\n\n`wiki check` with no `FILE` argument runs every check below.\n\n### Always errors (not configurable)\n\n- **SHACL** — shapes from wiki frontmatter (`sh:NodeShape`, etc.) on the full RDF graph\n- **Route safety** — unsafe path segments (spaces, reserved characters, and similar)\n- **Output collisions** — two wiki sources mapping to the same built URL (against default `_site` layout)\n\n### Configurable (`check.*` in `wiki.yaml`)\n\n| Rule key | What it audits |\n| --------------------- | ------------------------------------------------------------------- |\n| `missing_layout_file` | `wazoo:layout` paths that do not resolve to a readable `.html` file |\n| `frontmatter_schema` | Frontmatter that fails JSON Schema validation |\n| `missing_schema_ref` | `wazoo:jsonSchema` paths or URLs that cannot be loaded |\n| `shape_definition` | Ill-formed SHACL shape pages (see [below](#shape-definitions)) |\n| `shape_unused` | Node shape pages that validate nothing |\n| `remote_schema_refs` | Policy for remote schema URLs: `allow`, `deny`, or `allowlist` |\n| `remote_schema_hosts` | Hostnames allowed when `remote_schema_refs` is `allowlist` |\n\nDefault: `missing_layout_file`, `frontmatter_schema`, `missing_schema_ref`, and `shape_definition` are `error`. `shape_unused` is `warning`. `remote_schema_refs` defaults to `allow`.\n\n### Shape definitions\n\nA shape page is ordinary frontmatter, so a misspelled `sh:` key compiles to an inert triple and the constraint it meant to declare never fires. `shape_definition` runs before SHACL and fails the check when a page, or a shape nested in it, breaks a SHACL Core rule: an unknown `sh:` term, a property shape without `sh:path`, a malformed path, or a non-IRI value for an IRI-valued parameter. While any remain as errors, SHACL validation is skipped and a `shacl_skipped` warning says so, because a broken shape makes the SHACL verdict meaningless. A node shape that applies to nothing is reported separately, under `shape_unused`, as a warning by default. Each finding names the route and the key path, for example `In Purchase_Shape: sh:property[0].sh:minCont: …`. Shapes written in RDF (fenced `turtle` blocks and `.ttl` and other RDF files) get the same checks, and their findings name the source and the shape. Findings appear in `wiki check -f json` under the code `shape_definition`. See [SHACL](SHACL.md#shape-page-checks) for the rules.\n\n### JSON Schema frontmatter\n\nBind schemas on `sh:NodeShape` documents with `wazoo:jsonSchema` and `sh:targetClass`. Type-level schemas apply to every matching page; pages may append extra schemas with their own `wazoo:jsonSchema` (string or list). Local refs resolve under the wiki config root; remote `http(s)` URLs are fetched at check time unless `check.remote_schema_refs` is `deny` or the host is outside `check.remote_schema_hosts` when using `allowlist`. Shape binding documents are excluded from instance validation. See [SHACL](SHACL.md) and [Style Guide](Style_Guide.md#shacl-shapes).\n\nBroken links, filename pattern, and heading style are **not** part of `wiki check` — use [wiki lint](wiki_lint.md).\n\n### Scoped mode (one or more FILE args)\n\n`wiki check path/to/Page.md` (or multiple paths) runs **SHACL and JSON Schema** per file. Route safety, output collisions, and layout frontmatter rules are **full-wiki only**. Cross-document SHACL interactions may only appear in a full-wiki check. Broken links on those pages require `wiki lint` with the same paths.\n\n`--strict` applies only when warnings exist; scoped mode does not emit warnings today.\n\n## JSON output\n\n`wiki check -f json` writes a structured report to **stdout** so editors and CI can tell which document, which frontmatter field, which shape, and which constraint failed without parsing the text report. The text report still goes to stderr, and the exit code is unchanged (1 when the check fails, 0 otherwise).\n\n```json\n{\n \"version\": 1,\n \"ok\": false,\n \"documents\": [\n {\n \"path\": \"wiki/CSS.md\",\n \"route\": \"CSS\",\n \"focusNode\": \"https://wiki.example.org/CSS\",\n \"conforms\": false,\n \"results\": [\n {\n \"code\": \"shacl_violation\",\n \"severity\": \"error\",\n \"check\": \"shacl\",\n \"message\": \"Article must have a description.\",\n \"resultPath\": \"https://schema.org/description\",\n \"frontmatterKeys\": [\"description\", \"schema:description\"],\n \"shaclSeverity\": \"http://www.w3.org/ns/shacl#Violation\",\n \"sourceConstraintComponent\": \"http://www.w3.org/ns/shacl#MinCountConstraintComponent\",\n \"sourceShapes\": [\n {\n \"iri\": \"https://wiki.example.org/Article_Shape\",\n \"route\": \"Article_Shape\",\n \"path\": \"wiki/Article_Shape.md\",\n \"targetClass\": [\"https://schema.org/Article\"],\n \"label\": \"Article Shape\"\n }\n ],\n \"value\": null,\n \"schema\": null,\n \"instancePath\": null,\n \"keyword\": null\n }\n ]\n }\n ],\n \"issues\": [\n {\n \"code\": \"shacl_violation\",\n \"severity\": \"error\",\n \"message\": \"SHACL Validation Violation in CSS.md: ...\",\n \"path\": \"wiki/CSS.md\",\n \"route\": \"CSS\"\n }\n ]\n}\n```\n\n- **`version`** is the envelope's format version, currently `1`. New fields can appear without a bump; renaming, removing, or changing the meaning of a field bumps it.\n- **`issues`** lists every issue the text report shows, with the same `code`, `severity`, and `message`. Warnings are always included, with or without `-v`.\n- **`documents`** groups the document-level issues by page. Each SHACL result and JSON Schema failure gets its own entry in `results`. In scoped mode every `FILE` gets an entry, even when it conforms. In full-wiki mode, only documents with findings are listed.\n- **`frontmatterKeys`** are the frontmatter spellings of `resultPath`, resolved through the wiki context. A key the page already uses is listed alone. For a missing field, the list holds the spellings that would satisfy it.\n- **`sourceShapes`** names the shape page that declared the failing constraint (SHACL's `sh:sourceShape`), with its `sh:targetClass` and `rdfs:label`. A named `sh:PropertyShape` page is named itself, even when a node shape lists it under `sh:property`. An inline property shape is named by the node shape page that holds it. Blank nodes are never serialized because their labels change between runs. A constraint that has no named shape gives an empty list.\n- JSON Schema results (`check: \"jsonSchema\"`) carry `schema`, `instancePath`, and `keyword`. SHACL results (`check: \"shacl\"`) carry `resultPath`, `sourceConstraintComponent`, and `value`. A result whose focus node matches no document is listed under a document with `path: null`. It is never dropped.\n\n### Related CI commands\n\n| Command | Purpose |\n| --------------------- | ---------------------------------------------------- |\n| `wiki lint --strict` | Broken links, filename pattern, headings, link style |\n| `wiki fmt --check` | Deno Markdown formatter consistency |\n| `wiki render --check` | Stale inline SPARQL result blocks |\n| `wiki link --check` | Remaining missing-wikilink opportunities |\n\n`wiki build` runs `wiki lint` then `wiki check` before writing output unless `--no-check`.\n\n## Related\n\n- [Wiki Configuration](Wiki_Configuration.md) — `check.*` severities\n- [SHACL](SHACL.md) — shape and JSON Schema binding\n- [wiki lint](wiki_lint.md) — convention lane\n- [Style Guide](Style_Guide.md)";
schema:headline "wiki check";
schema:dateCreated "2026-10-31T23:19:03Z"^^xsd:dateTime;
schema:dateModified "2026-10-31T23:19:03Z"^^xsd:dateTime.
@prefix schema: <https://schema.org/>.
@prefix wiki: <https://wazootech.github.io/wiki/>.
@prefix foaf: <http://xmlns.com/foaf/0.1/>.
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>.
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#>.
@prefix xsd: <http://www.w3.org/2001/XMLSchema#>.
@prefix owl: <http://www.w3.org/2002/07/owl#>.
@prefix dc: <http://purl.org/dc/elements/1.1/>.
@prefix dcterms: <http://purl.org/dc/terms/>.
@prefix sh: <http://www.w3.org/ns/shacl#>.
@prefix wazoo: <https://schema.wazoo.dev/>.
wiki:wiki_check a schema:TechArticle;
schema:description "Integrity checks — SHACL validation, JSON Schema frontmatter, route safety, and layout frontmatter.";
schema:articleBody "# `wiki check`\n\nRun **integrity** checks on the wiki: strict **SHACL** validation, **JSON Schema** frontmatter validation, route safety, output collisions, and layout frontmatter contracts.\n\nExits **0 silently** on success unless `-v` is set. See [Design Philosophies](Design_Philosophies.md).\n\n## Usage\n\n```bash\nwiki check\nwiki check wiki/Some_Page.md\nwiki check wiki/A.md wiki/B.md\nwiki check -v\nwiki check --strict\nwiki check -f json wiki/Some_Page.md\n```\n\n## Options\n\n| Flag | Description |\n| ----------------- | ------------------------------------------------------------------------------------- |\n| `FILE...` | Optional documents; otherwise entire wiki (scoped mode: SHACL + JSON Schema per file) |\n| `-v`, `--verbose` | Print warnings |\n| `--strict` | Treat warnings as errors (exit 1) |\n| `-f`, `--format` | `text` (default) or `json`; see [JSON output](#json-output) |\n| `--json` | Shorthand for `--format json` |\n\n## What is checked\n\n### Full wiki (default)\n\n`wiki check` with no `FILE` argument runs every check below.\n\n### Always errors (not configurable)\n\n- **SHACL** — shapes from wiki frontmatter (`sh:NodeShape`, etc.) on the full RDF graph\n- **Route safety** — unsafe path segments (spaces, reserved characters, and similar)\n- **Output collisions** — two wiki sources mapping to the same built URL (against default `_site` layout)\n\n### Configurable (`check.*` in `wiki.yaml`)\n\n| Rule key | What it audits |\n| --------------------- | ------------------------------------------------------------------- |\n| `missing_layout_file` | `wazoo:layout` paths that do not resolve to a readable `.html` file |\n| `frontmatter_schema` | Frontmatter that fails JSON Schema validation |\n| `missing_schema_ref` | `wazoo:jsonSchema` paths or URLs that cannot be loaded |\n| `shape_definition` | Ill-formed SHACL shape pages (see [below](#shape-definitions)) |\n| `shape_unused` | Node shape pages that validate nothing |\n| `remote_schema_refs` | Policy for remote schema URLs: `allow`, `deny`, or `allowlist` |\n| `remote_schema_hosts` | Hostnames allowed when `remote_schema_refs` is `allowlist` |\n\nDefault: `missing_layout_file`, `frontmatter_schema`, `missing_schema_ref`, and `shape_definition` are `error`. `shape_unused` is `warning`. `remote_schema_refs` defaults to `allow`.\n\n### Shape definitions\n\nA shape page is ordinary frontmatter, so a misspelled `sh:` key compiles to an inert triple and the constraint it meant to declare never fires. `shape_definition` runs before SHACL and fails the check when a page, or a shape nested in it, breaks a SHACL Core rule: an unknown `sh:` term, a property shape without `sh:path`, a malformed path, or a non-IRI value for an IRI-valued parameter. While any remain as errors, SHACL validation is skipped and a `shacl_skipped` warning says so, because a broken shape makes the SHACL verdict meaningless. A node shape that applies to nothing is reported separately, under `shape_unused`, as a warning by default. Each finding names the route and the key path, for example `In Purchase_Shape: sh:property[0].sh:minCont: …`. Shapes written in RDF (fenced `turtle` blocks and `.ttl` and other RDF files) get the same checks, and their findings name the source and the shape. Findings appear in `wiki check -f json` under the code `shape_definition`. See [SHACL](SHACL.md#shape-page-checks) for the rules.\n\n### JSON Schema frontmatter\n\nBind schemas on `sh:NodeShape` documents with `wazoo:jsonSchema` and `sh:targetClass`. Type-level schemas apply to every matching page; pages may append extra schemas with their own `wazoo:jsonSchema` (string or list). Local refs resolve under the wiki config root; remote `http(s)` URLs are fetched at check time unless `check.remote_schema_refs` is `deny` or the host is outside `check.remote_schema_hosts` when using `allowlist`. Shape binding documents are excluded from instance validation. See [SHACL](SHACL.md) and [Style Guide](Style_Guide.md#shacl-shapes).\n\nBroken links, filename pattern, and heading style are **not** part of `wiki check` — use [wiki lint](wiki_lint.md).\n\n### Scoped mode (one or more FILE args)\n\n`wiki check path/to/Page.md` (or multiple paths) runs **SHACL and JSON Schema** per file. Route safety, output collisions, and layout frontmatter rules are **full-wiki only**. Cross-document SHACL interactions may only appear in a full-wiki check. Broken links on those pages require `wiki lint` with the same paths.\n\n`--strict` applies only when warnings exist; scoped mode does not emit warnings today.\n\n## JSON output\n\n`wiki check -f json` writes a structured report to **stdout** so editors and CI can tell which document, which frontmatter field, which shape, and which constraint failed without parsing the text report. The text report still goes to stderr, and the exit code is unchanged (1 when the check fails, 0 otherwise).\n\n```json\n{\n \"version\": 1,\n \"ok\": false,\n \"documents\": [\n {\n \"path\": \"wiki/CSS.md\",\n \"route\": \"CSS\",\n \"focusNode\": \"https://wiki.example.org/CSS\",\n \"conforms\": false,\n \"results\": [\n {\n \"code\": \"shacl_violation\",\n \"severity\": \"error\",\n \"check\": \"shacl\",\n \"message\": \"Article must have a description.\",\n \"resultPath\": \"https://schema.org/description\",\n \"frontmatterKeys\": [\"description\", \"schema:description\"],\n \"shaclSeverity\": \"http://www.w3.org/ns/shacl#Violation\",\n \"sourceConstraintComponent\": \"http://www.w3.org/ns/shacl#MinCountConstraintComponent\",\n \"sourceShapes\": [\n {\n \"iri\": \"https://wiki.example.org/Article_Shape\",\n \"route\": \"Article_Shape\",\n \"path\": \"wiki/Article_Shape.md\",\n \"targetClass\": [\"https://schema.org/Article\"],\n \"label\": \"Article Shape\"\n }\n ],\n \"value\": null,\n \"schema\": null,\n \"instancePath\": null,\n \"keyword\": null\n }\n ]\n }\n ],\n \"issues\": [\n {\n \"code\": \"shacl_violation\",\n \"severity\": \"error\",\n \"message\": \"SHACL Validation Violation in CSS.md: ...\",\n \"path\": \"wiki/CSS.md\",\n \"route\": \"CSS\"\n }\n ]\n}\n```\n\n- **`version`** is the envelope's format version, currently `1`. New fields can appear without a bump; renaming, removing, or changing the meaning of a field bumps it.\n- **`issues`** lists every issue the text report shows, with the same `code`, `severity`, and `message`. Warnings are always included, with or without `-v`.\n- **`documents`** groups the document-level issues by page. Each SHACL result and JSON Schema failure gets its own entry in `results`. In scoped mode every `FILE` gets an entry, even when it conforms. In full-wiki mode, only documents with findings are listed.\n- **`frontmatterKeys`** are the frontmatter spellings of `resultPath`, resolved through the wiki context. A key the page already uses is listed alone. For a missing field, the list holds the spellings that would satisfy it.\n- **`sourceShapes`** names the shape page that declared the failing constraint (SHACL's `sh:sourceShape`), with its `sh:targetClass` and `rdfs:label`. A named `sh:PropertyShape` page is named itself, even when a node shape lists it under `sh:property`. An inline property shape is named by the node shape page that holds it. Blank nodes are never serialized because their labels change between runs. A constraint that has no named shape gives an empty list.\n- JSON Schema results (`check: \"jsonSchema\"`) carry `schema`, `instancePath`, and `keyword`. SHACL results (`check: \"shacl\"`) carry `resultPath`, `sourceConstraintComponent`, and `value`. A result whose focus node matches no document is listed under a document with `path: null`. It is never dropped.\n\n### Related CI commands\n\n| Command | Purpose |\n| --------------------- | ---------------------------------------------------- |\n| `wiki lint --strict` | Broken links, filename pattern, headings, link style |\n| `wiki fmt --check` | Deno Markdown formatter consistency |\n| `wiki render --check` | Stale inline SPARQL result blocks |\n| `wiki link --check` | Remaining missing-wikilink opportunities |\n\n`wiki build` runs `wiki lint` then `wiki check` before writing output unless `--no-check`.\n\n## Related\n\n- [Wiki Configuration](Wiki_Configuration.md) — `check.*` severities\n- [SHACL](SHACL.md) — shape and JSON Schema binding\n- [wiki lint](wiki_lint.md) — convention lane\n- [Style Guide](Style_Guide.md)";
schema:headline "wiki check";
schema:dateCreated "2026-10-31T23:19:03Z"^^xsd:dateTime;
schema:dateModified "2026-10-31T23:19:03Z"^^xsd:dateTime.
<https://wazootech.github.io/wiki/wiki_check> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <https://schema.org/TechArticle> .
<https://wazootech.github.io/wiki/wiki_check> <https://schema.org/description> "Integrity checks — SHACL validation, JSON Schema frontmatter, route safety, and layout frontmatter." .
<https://wazootech.github.io/wiki/wiki_check> <https://schema.org/articleBody> "# `wiki check`\n\nRun **integrity** checks on the wiki: strict **SHACL** validation, **JSON Schema** frontmatter validation, route safety, output collisions, and layout frontmatter contracts.\n\nExits **0 silently** on success unless `-v` is set. See [Design Philosophies](Design_Philosophies.md).\n\n## Usage\n\n```bash\nwiki check\nwiki check wiki/Some_Page.md\nwiki check wiki/A.md wiki/B.md\nwiki check -v\nwiki check --strict\nwiki check -f json wiki/Some_Page.md\n```\n\n## Options\n\n| Flag | Description |\n| ----------------- | ------------------------------------------------------------------------------------- |\n| `FILE...` | Optional documents; otherwise entire wiki (scoped mode: SHACL + JSON Schema per file) |\n| `-v`, `--verbose` | Print warnings |\n| `--strict` | Treat warnings as errors (exit 1) |\n| `-f`, `--format` | `text` (default) or `json`; see [JSON output](#json-output) |\n| `--json` | Shorthand for `--format json` |\n\n## What is checked\n\n### Full wiki (default)\n\n`wiki check` with no `FILE` argument runs every check below.\n\n### Always errors (not configurable)\n\n- **SHACL** — shapes from wiki frontmatter (`sh:NodeShape`, etc.) on the full RDF graph\n- **Route safety** — unsafe path segments (spaces, reserved characters, and similar)\n- **Output collisions** — two wiki sources mapping to the same built URL (against default `_site` layout)\n\n### Configurable (`check.*` in `wiki.yaml`)\n\n| Rule key | What it audits |\n| --------------------- | ------------------------------------------------------------------- |\n| `missing_layout_file` | `wazoo:layout` paths that do not resolve to a readable `.html` file |\n| `frontmatter_schema` | Frontmatter that fails JSON Schema validation |\n| `missing_schema_ref` | `wazoo:jsonSchema` paths or URLs that cannot be loaded |\n| `shape_definition` | Ill-formed SHACL shape pages (see [below](#shape-definitions)) |\n| `shape_unused` | Node shape pages that validate nothing |\n| `remote_schema_refs` | Policy for remote schema URLs: `allow`, `deny`, or `allowlist` |\n| `remote_schema_hosts` | Hostnames allowed when `remote_schema_refs` is `allowlist` |\n\nDefault: `missing_layout_file`, `frontmatter_schema`, `missing_schema_ref`, and `shape_definition` are `error`. `shape_unused` is `warning`. `remote_schema_refs` defaults to `allow`.\n\n### Shape definitions\n\nA shape page is ordinary frontmatter, so a misspelled `sh:` key compiles to an inert triple and the constraint it meant to declare never fires. `shape_definition` runs before SHACL and fails the check when a page, or a shape nested in it, breaks a SHACL Core rule: an unknown `sh:` term, a property shape without `sh:path`, a malformed path, or a non-IRI value for an IRI-valued parameter. While any remain as errors, SHACL validation is skipped and a `shacl_skipped` warning says so, because a broken shape makes the SHACL verdict meaningless. A node shape that applies to nothing is reported separately, under `shape_unused`, as a warning by default. Each finding names the route and the key path, for example `In Purchase_Shape: sh:property[0].sh:minCont: …`. Shapes written in RDF (fenced `turtle` blocks and `.ttl` and other RDF files) get the same checks, and their findings name the source and the shape. Findings appear in `wiki check -f json` under the code `shape_definition`. See [SHACL](SHACL.md#shape-page-checks) for the rules.\n\n### JSON Schema frontmatter\n\nBind schemas on `sh:NodeShape` documents with `wazoo:jsonSchema` and `sh:targetClass`. Type-level schemas apply to every matching page; pages may append extra schemas with their own `wazoo:jsonSchema` (string or list). Local refs resolve under the wiki config root; remote `http(s)` URLs are fetched at check time unless `check.remote_schema_refs` is `deny` or the host is outside `check.remote_schema_hosts` when using `allowlist`. Shape binding documents are excluded from instance validation. See [SHACL](SHACL.md) and [Style Guide](Style_Guide.md#shacl-shapes).\n\nBroken links, filename pattern, and heading style are **not** part of `wiki check` — use [wiki lint](wiki_lint.md).\n\n### Scoped mode (one or more FILE args)\n\n`wiki check path/to/Page.md` (or multiple paths) runs **SHACL and JSON Schema** per file. Route safety, output collisions, and layout frontmatter rules are **full-wiki only**. Cross-document SHACL interactions may only appear in a full-wiki check. Broken links on those pages require `wiki lint` with the same paths.\n\n`--strict` applies only when warnings exist; scoped mode does not emit warnings today.\n\n## JSON output\n\n`wiki check -f json` writes a structured report to **stdout** so editors and CI can tell which document, which frontmatter field, which shape, and which constraint failed without parsing the text report. The text report still goes to stderr, and the exit code is unchanged (1 when the check fails, 0 otherwise).\n\n```json\n{\n \"version\": 1,\n \"ok\": false,\n \"documents\": [\n {\n \"path\": \"wiki/CSS.md\",\n \"route\": \"CSS\",\n \"focusNode\": \"https://wiki.example.org/CSS\",\n \"conforms\": false,\n \"results\": [\n {\n \"code\": \"shacl_violation\",\n \"severity\": \"error\",\n \"check\": \"shacl\",\n \"message\": \"Article must have a description.\",\n \"resultPath\": \"https://schema.org/description\",\n \"frontmatterKeys\": [\"description\", \"schema:description\"],\n \"shaclSeverity\": \"http://www.w3.org/ns/shacl#Violation\",\n \"sourceConstraintComponent\": \"http://www.w3.org/ns/shacl#MinCountConstraintComponent\",\n \"sourceShapes\": [\n {\n \"iri\": \"https://wiki.example.org/Article_Shape\",\n \"route\": \"Article_Shape\",\n \"path\": \"wiki/Article_Shape.md\",\n \"targetClass\": [\"https://schema.org/Article\"],\n \"label\": \"Article Shape\"\n }\n ],\n \"value\": null,\n \"schema\": null,\n \"instancePath\": null,\n \"keyword\": null\n }\n ]\n }\n ],\n \"issues\": [\n {\n \"code\": \"shacl_violation\",\n \"severity\": \"error\",\n \"message\": \"SHACL Validation Violation in CSS.md: ...\",\n \"path\": \"wiki/CSS.md\",\n \"route\": \"CSS\"\n }\n ]\n}\n```\n\n- **`version`** is the envelope's format version, currently `1`. New fields can appear without a bump; renaming, removing, or changing the meaning of a field bumps it.\n- **`issues`** lists every issue the text report shows, with the same `code`, `severity`, and `message`. Warnings are always included, with or without `-v`.\n- **`documents`** groups the document-level issues by page. Each SHACL result and JSON Schema failure gets its own entry in `results`. In scoped mode every `FILE` gets an entry, even when it conforms. In full-wiki mode, only documents with findings are listed.\n- **`frontmatterKeys`** are the frontmatter spellings of `resultPath`, resolved through the wiki context. A key the page already uses is listed alone. For a missing field, the list holds the spellings that would satisfy it.\n- **`sourceShapes`** names the shape page that declared the failing constraint (SHACL's `sh:sourceShape`), with its `sh:targetClass` and `rdfs:label`. A named `sh:PropertyShape` page is named itself, even when a node shape lists it under `sh:property`. An inline property shape is named by the node shape page that holds it. Blank nodes are never serialized because their labels change between runs. A constraint that has no named shape gives an empty list.\n- JSON Schema results (`check: \"jsonSchema\"`) carry `schema`, `instancePath`, and `keyword`. SHACL results (`check: \"shacl\"`) carry `resultPath`, `sourceConstraintComponent`, and `value`. A result whose focus node matches no document is listed under a document with `path: null`. It is never dropped.\n\n### Related CI commands\n\n| Command | Purpose |\n| --------------------- | ---------------------------------------------------- |\n| `wiki lint --strict` | Broken links, filename pattern, headings, link style |\n| `wiki fmt --check` | Deno Markdown formatter consistency |\n| `wiki render --check` | Stale inline SPARQL result blocks |\n| `wiki link --check` | Remaining missing-wikilink opportunities |\n\n`wiki build` runs `wiki lint` then `wiki check` before writing output unless `--no-check`.\n\n## Related\n\n- [Wiki Configuration](Wiki_Configuration.md) — `check.*` severities\n- [SHACL](SHACL.md) — shape and JSON Schema binding\n- [wiki lint](wiki_lint.md) — convention lane\n- [Style Guide](Style_Guide.md)" .
<https://wazootech.github.io/wiki/wiki_check> <https://schema.org/headline> "wiki check" .
<https://wazootech.github.io/wiki/wiki_check> <https://schema.org/dateCreated> "2026-10-31T23:19:03Z"^^<http://www.w3.org/2001/XMLSchema#dateTime> .
<https://wazootech.github.io/wiki/wiki_check> <https://schema.org/dateModified> "2026-10-31T23:19:03Z"^^<http://www.w3.org/2001/XMLSchema#dateTime> .
@prefix schema: <https://schema.org/>.
@prefix wiki: <https://wazootech.github.io/wiki/>.
@prefix foaf: <http://xmlns.com/foaf/0.1/>.
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>.
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#>.
@prefix xsd: <http://www.w3.org/2001/XMLSchema#>.
@prefix owl: <http://www.w3.org/2002/07/owl#>.
@prefix dc: <http://purl.org/dc/elements/1.1/>.
@prefix dcterms: <http://purl.org/dc/terms/>.
@prefix sh: <http://www.w3.org/ns/shacl#>.
@prefix wazoo: <https://schema.wazoo.dev/>.
wiki:wiki_check a schema:TechArticle;
schema:description "Integrity checks — SHACL validation, JSON Schema frontmatter, route safety, and layout frontmatter.";
schema:articleBody "# `wiki check`\n\nRun **integrity** checks on the wiki: strict **SHACL** validation, **JSON Schema** frontmatter validation, route safety, output collisions, and layout frontmatter contracts.\n\nExits **0 silently** on success unless `-v` is set. See [Design Philosophies](Design_Philosophies.md).\n\n## Usage\n\n```bash\nwiki check\nwiki check wiki/Some_Page.md\nwiki check wiki/A.md wiki/B.md\nwiki check -v\nwiki check --strict\nwiki check -f json wiki/Some_Page.md\n```\n\n## Options\n\n| Flag | Description |\n| ----------------- | ------------------------------------------------------------------------------------- |\n| `FILE...` | Optional documents; otherwise entire wiki (scoped mode: SHACL + JSON Schema per file) |\n| `-v`, `--verbose` | Print warnings |\n| `--strict` | Treat warnings as errors (exit 1) |\n| `-f`, `--format` | `text` (default) or `json`; see [JSON output](#json-output) |\n| `--json` | Shorthand for `--format json` |\n\n## What is checked\n\n### Full wiki (default)\n\n`wiki check` with no `FILE` argument runs every check below.\n\n### Always errors (not configurable)\n\n- **SHACL** — shapes from wiki frontmatter (`sh:NodeShape`, etc.) on the full RDF graph\n- **Route safety** — unsafe path segments (spaces, reserved characters, and similar)\n- **Output collisions** — two wiki sources mapping to the same built URL (against default `_site` layout)\n\n### Configurable (`check.*` in `wiki.yaml`)\n\n| Rule key | What it audits |\n| --------------------- | ------------------------------------------------------------------- |\n| `missing_layout_file` | `wazoo:layout` paths that do not resolve to a readable `.html` file |\n| `frontmatter_schema` | Frontmatter that fails JSON Schema validation |\n| `missing_schema_ref` | `wazoo:jsonSchema` paths or URLs that cannot be loaded |\n| `shape_definition` | Ill-formed SHACL shape pages (see [below](#shape-definitions)) |\n| `shape_unused` | Node shape pages that validate nothing |\n| `remote_schema_refs` | Policy for remote schema URLs: `allow`, `deny`, or `allowlist` |\n| `remote_schema_hosts` | Hostnames allowed when `remote_schema_refs` is `allowlist` |\n\nDefault: `missing_layout_file`, `frontmatter_schema`, `missing_schema_ref`, and `shape_definition` are `error`. `shape_unused` is `warning`. `remote_schema_refs` defaults to `allow`.\n\n### Shape definitions\n\nA shape page is ordinary frontmatter, so a misspelled `sh:` key compiles to an inert triple and the constraint it meant to declare never fires. `shape_definition` runs before SHACL and fails the check when a page, or a shape nested in it, breaks a SHACL Core rule: an unknown `sh:` term, a property shape without `sh:path`, a malformed path, or a non-IRI value for an IRI-valued parameter. While any remain as errors, SHACL validation is skipped and a `shacl_skipped` warning says so, because a broken shape makes the SHACL verdict meaningless. A node shape that applies to nothing is reported separately, under `shape_unused`, as a warning by default. Each finding names the route and the key path, for example `In Purchase_Shape: sh:property[0].sh:minCont: …`. Shapes written in RDF (fenced `turtle` blocks and `.ttl` and other RDF files) get the same checks, and their findings name the source and the shape. Findings appear in `wiki check -f json` under the code `shape_definition`. See [SHACL](SHACL.md#shape-page-checks) for the rules.\n\n### JSON Schema frontmatter\n\nBind schemas on `sh:NodeShape` documents with `wazoo:jsonSchema` and `sh:targetClass`. Type-level schemas apply to every matching page; pages may append extra schemas with their own `wazoo:jsonSchema` (string or list). Local refs resolve under the wiki config root; remote `http(s)` URLs are fetched at check time unless `check.remote_schema_refs` is `deny` or the host is outside `check.remote_schema_hosts` when using `allowlist`. Shape binding documents are excluded from instance validation. See [SHACL](SHACL.md) and [Style Guide](Style_Guide.md#shacl-shapes).\n\nBroken links, filename pattern, and heading style are **not** part of `wiki check` — use [wiki lint](wiki_lint.md).\n\n### Scoped mode (one or more FILE args)\n\n`wiki check path/to/Page.md` (or multiple paths) runs **SHACL and JSON Schema** per file. Route safety, output collisions, and layout frontmatter rules are **full-wiki only**. Cross-document SHACL interactions may only appear in a full-wiki check. Broken links on those pages require `wiki lint` with the same paths.\n\n`--strict` applies only when warnings exist; scoped mode does not emit warnings today.\n\n## JSON output\n\n`wiki check -f json` writes a structured report to **stdout** so editors and CI can tell which document, which frontmatter field, which shape, and which constraint failed without parsing the text report. The text report still goes to stderr, and the exit code is unchanged (1 when the check fails, 0 otherwise).\n\n```json\n{\n \"version\": 1,\n \"ok\": false,\n \"documents\": [\n {\n \"path\": \"wiki/CSS.md\",\n \"route\": \"CSS\",\n \"focusNode\": \"https://wiki.example.org/CSS\",\n \"conforms\": false,\n \"results\": [\n {\n \"code\": \"shacl_violation\",\n \"severity\": \"error\",\n \"check\": \"shacl\",\n \"message\": \"Article must have a description.\",\n \"resultPath\": \"https://schema.org/description\",\n \"frontmatterKeys\": [\"description\", \"schema:description\"],\n \"shaclSeverity\": \"http://www.w3.org/ns/shacl#Violation\",\n \"sourceConstraintComponent\": \"http://www.w3.org/ns/shacl#MinCountConstraintComponent\",\n \"sourceShapes\": [\n {\n \"iri\": \"https://wiki.example.org/Article_Shape\",\n \"route\": \"Article_Shape\",\n \"path\": \"wiki/Article_Shape.md\",\n \"targetClass\": [\"https://schema.org/Article\"],\n \"label\": \"Article Shape\"\n }\n ],\n \"value\": null,\n \"schema\": null,\n \"instancePath\": null,\n \"keyword\": null\n }\n ]\n }\n ],\n \"issues\": [\n {\n \"code\": \"shacl_violation\",\n \"severity\": \"error\",\n \"message\": \"SHACL Validation Violation in CSS.md: ...\",\n \"path\": \"wiki/CSS.md\",\n \"route\": \"CSS\"\n }\n ]\n}\n```\n\n- **`version`** is the envelope's format version, currently `1`. New fields can appear without a bump; renaming, removing, or changing the meaning of a field bumps it.\n- **`issues`** lists every issue the text report shows, with the same `code`, `severity`, and `message`. Warnings are always included, with or without `-v`.\n- **`documents`** groups the document-level issues by page. Each SHACL result and JSON Schema failure gets its own entry in `results`. In scoped mode every `FILE` gets an entry, even when it conforms. In full-wiki mode, only documents with findings are listed.\n- **`frontmatterKeys`** are the frontmatter spellings of `resultPath`, resolved through the wiki context. A key the page already uses is listed alone. For a missing field, the list holds the spellings that would satisfy it.\n- **`sourceShapes`** names the shape page that declared the failing constraint (SHACL's `sh:sourceShape`), with its `sh:targetClass` and `rdfs:label`. A named `sh:PropertyShape` page is named itself, even when a node shape lists it under `sh:property`. An inline property shape is named by the node shape page that holds it. Blank nodes are never serialized because their labels change between runs. A constraint that has no named shape gives an empty list.\n- JSON Schema results (`check: \"jsonSchema\"`) carry `schema`, `instancePath`, and `keyword`. SHACL results (`check: \"shacl\"`) carry `resultPath`, `sourceConstraintComponent`, and `value`. A result whose focus node matches no document is listed under a document with `path: null`. It is never dropped.\n\n### Related CI commands\n\n| Command | Purpose |\n| --------------------- | ---------------------------------------------------- |\n| `wiki lint --strict` | Broken links, filename pattern, headings, link style |\n| `wiki fmt --check` | Deno Markdown formatter consistency |\n| `wiki render --check` | Stale inline SPARQL result blocks |\n| `wiki link --check` | Remaining missing-wikilink opportunities |\n\n`wiki build` runs `wiki lint` then `wiki check` before writing output unless `--no-check`.\n\n## Related\n\n- [Wiki Configuration](Wiki_Configuration.md) — `check.*` severities\n- [SHACL](SHACL.md) — shape and JSON Schema binding\n- [wiki lint](wiki_lint.md) — convention lane\n- [Style Guide](Style_Guide.md)";
schema:headline "wiki check";
schema:dateCreated "2026-10-31T23:19:03Z"^^xsd:dateTime;
schema:dateModified "2026-10-31T23:19:03Z"^^xsd:dateTime.
<https://wazootech.github.io/wiki/wiki_check> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <https://schema.org/TechArticle> .
<https://wazootech.github.io/wiki/wiki_check> <https://schema.org/description> "Integrity checks — SHACL validation, JSON Schema frontmatter, route safety, and layout frontmatter." .
<https://wazootech.github.io/wiki/wiki_check> <https://schema.org/articleBody> """# `wiki check`
Run **integrity** checks on the wiki: strict **SHACL** validation, **JSON Schema** frontmatter validation, route safety, output collisions, and layout frontmatter contracts.
Exits **0 silently** on success unless `-v` is set. See [Design Philosophies](Design_Philosophies.md).
## Usage
```bash
wiki check
wiki check wiki/Some_Page.md
wiki check wiki/A.md wiki/B.md
wiki check -v
wiki check --strict
wiki check -f json wiki/Some_Page.md
```
## Options
| Flag | Description |
| ----------------- | ------------------------------------------------------------------------------------- |
| `FILE...` | Optional documents; otherwise entire wiki (scoped mode: SHACL + JSON Schema per file) |
| `-v`, `--verbose` | Print warnings |
| `--strict` | Treat warnings as errors (exit 1) |
| `-f`, `--format` | `text` (default) or `json`; see [JSON output](#json-output) |
| `--json` | Shorthand for `--format json` |
## What is checked
### Full wiki (default)
`wiki check` with no `FILE` argument runs every check below.
### Always errors (not configurable)
- **SHACL** — shapes from wiki frontmatter (`sh:NodeShape`, etc.) on the full RDF graph
- **Route safety** — unsafe path segments (spaces, reserved characters, and similar)
- **Output collisions** — two wiki sources mapping to the same built URL (against default `_site` layout)
### Configurable (`check.*` in `wiki.yaml`)
| Rule key | What it audits |
| --------------------- | ------------------------------------------------------------------- |
| `missing_layout_file` | `wazoo:layout` paths that do not resolve to a readable `.html` file |
| `frontmatter_schema` | Frontmatter that fails JSON Schema validation |
| `missing_schema_ref` | `wazoo:jsonSchema` paths or URLs that cannot be loaded |
| `shape_definition` | Ill-formed SHACL shape pages (see [below](#shape-definitions)) |
| `shape_unused` | Node shape pages that validate nothing |
| `remote_schema_refs` | Policy for remote schema URLs: `allow`, `deny`, or `allowlist` |
| `remote_schema_hosts` | Hostnames allowed when `remote_schema_refs` is `allowlist` |
Default: `missing_layout_file`, `frontmatter_schema`, `missing_schema_ref`, and `shape_definition` are `error`. `shape_unused` is `warning`. `remote_schema_refs` defaults to `allow`.
### Shape definitions
A shape page is ordinary frontmatter, so a misspelled `sh:` key compiles to an inert triple and the constraint it meant to declare never fires. `shape_definition` runs before SHACL and fails the check when a page, or a shape nested in it, breaks a SHACL Core rule: an unknown `sh:` term, a property shape without `sh:path`, a malformed path, or a non-IRI value for an IRI-valued parameter. While any remain as errors, SHACL validation is skipped and a `shacl_skipped` warning says so, because a broken shape makes the SHACL verdict meaningless. A node shape that applies to nothing is reported separately, under `shape_unused`, as a warning by default. Each finding names the route and the key path, for example `In Purchase_Shape: sh:property[0].sh:minCont: …`. Shapes written in RDF (fenced `turtle` blocks and `.ttl` and other RDF files) get the same checks, and their findings name the source and the shape. Findings appear in `wiki check -f json` under the code `shape_definition`. See [SHACL](SHACL.md#shape-page-checks) for the rules.
### JSON Schema frontmatter
Bind schemas on `sh:NodeShape` documents with `wazoo:jsonSchema` and `sh:targetClass`. Type-level schemas apply to every matching page; pages may append extra schemas with their own `wazoo:jsonSchema` (string or list). Local refs resolve under the wiki config root; remote `http(s)` URLs are fetched at check time unless `check.remote_schema_refs` is `deny` or the host is outside `check.remote_schema_hosts` when using `allowlist`. Shape binding documents are excluded from instance validation. See [SHACL](SHACL.md) and [Style Guide](Style_Guide.md#shacl-shapes).
Broken links, filename pattern, and heading style are **not** part of `wiki check` — use [wiki lint](wiki_lint.md).
### Scoped mode (one or more FILE args)
`wiki check path/to/Page.md` (or multiple paths) runs **SHACL and JSON Schema** per file. Route safety, output collisions, and layout frontmatter rules are **full-wiki only**. Cross-document SHACL interactions may only appear in a full-wiki check. Broken links on those pages require `wiki lint` with the same paths.
`--strict` applies only when warnings exist; scoped mode does not emit warnings today.
## JSON output
`wiki check -f json` writes a structured report to **stdout** so editors and CI can tell which document, which frontmatter field, which shape, and which constraint failed without parsing the text report. The text report still goes to stderr, and the exit code is unchanged (1 when the check fails, 0 otherwise).
```json
{
"version": 1,
"ok": false,
"documents": [
{
"path": "wiki/CSS.md",
"route": "CSS",
"focusNode": "https://wiki.example.org/CSS",
"conforms": false,
"results": [
{
"code": "shacl_violation",
"severity": "error",
"check": "shacl",
"message": "Article must have a description.",
"resultPath": "https://schema.org/description",
"frontmatterKeys": ["description", "schema:description"],
"shaclSeverity": "http://www.w3.org/ns/shacl#Violation",
"sourceConstraintComponent": "http://www.w3.org/ns/shacl#MinCountConstraintComponent",
"sourceShapes": [
{
"iri": "https://wiki.example.org/Article_Shape",
"route": "Article_Shape",
"path": "wiki/Article_Shape.md",
"targetClass": ["https://schema.org/Article"],
"label": "Article Shape"
}
],
"value": null,
"schema": null,
"instancePath": null,
"keyword": null
}
]
}
],
"issues": [
{
"code": "shacl_violation",
"severity": "error",
"message": "SHACL Validation Violation in CSS.md: ...",
"path": "wiki/CSS.md",
"route": "CSS"
}
]
}
```
- **`version`** is the envelope's format version, currently `1`. New fields can appear without a bump; renaming, removing, or changing the meaning of a field bumps it.
- **`issues`** lists every issue the text report shows, with the same `code`, `severity`, and `message`. Warnings are always included, with or without `-v`.
- **`documents`** groups the document-level issues by page. Each SHACL result and JSON Schema failure gets its own entry in `results`. In scoped mode every `FILE` gets an entry, even when it conforms. In full-wiki mode, only documents with findings are listed.
- **`frontmatterKeys`** are the frontmatter spellings of `resultPath`, resolved through the wiki context. A key the page already uses is listed alone. For a missing field, the list holds the spellings that would satisfy it.
- **`sourceShapes`** names the shape page that declared the failing constraint (SHACL's `sh:sourceShape`), with its `sh:targetClass` and `rdfs:label`. A named `sh:PropertyShape` page is named itself, even when a node shape lists it under `sh:property`. An inline property shape is named by the node shape page that holds it. Blank nodes are never serialized because their labels change between runs. A constraint that has no named shape gives an empty list.
- JSON Schema results (`check: "jsonSchema"`) carry `schema`, `instancePath`, and `keyword`. SHACL results (`check: "shacl"`) carry `resultPath`, `sourceConstraintComponent`, and `value`. A result whose focus node matches no document is listed under a document with `path: null`. It is never dropped.
### Related CI commands
| Command | Purpose |
| --------------------- | ---------------------------------------------------- |
| `wiki lint --strict` | Broken links, filename pattern, headings, link style |
| `wiki fmt --check` | Deno Markdown formatter consistency |
| `wiki render --check` | Stale inline SPARQL result blocks |
| `wiki link --check` | Remaining missing-wikilink opportunities |
`wiki build` runs `wiki lint` then `wiki check` before writing output unless `--no-check`.
## Related
- [Wiki Configuration](Wiki_Configuration.md) — `check.*` severities
- [SHACL](SHACL.md) — shape and JSON Schema binding
- [wiki lint](wiki_lint.md) — convention lane
- [Style Guide](Style_Guide.md)""" .
<https://wazootech.github.io/wiki/wiki_check> <https://schema.org/headline> "wiki check" .
<https://wazootech.github.io/wiki/wiki_check> <https://schema.org/dateCreated> "2026-10-31T23:19:03Z"^^<http://www.w3.org/2001/XMLSchema#dateTime> .
<https://wazootech.github.io/wiki/wiki_check> <https://schema.org/dateModified> "2026-10-31T23:19:03Z"^^<http://www.w3.org/2001/XMLSchema#dateTime> .