Files
card-layouts/schemas/card-source.schema.json
T
mpabi 8bf8e22448
Check card layouts / check (push) Has been cancelled
feat: publish A1-A8 card viewer and FreeRTOS C generator
2026-07-19 16:43:35 +02:00

1454 lines
42 KiB
JSON

{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"title": "Źródło karty pracy",
"description": "Schemat wspólnego źródła treści generowanego do TeX i HTML.",
"type": "object",
"required": [
"schema",
"card",
"generated",
"template",
"learning_effects",
"assessment_criteria",
"educational_requirements",
"sections",
"tasks",
"tasks_order"
],
"properties": {
"$schema": {
"type": "string"
},
"schema": {
"const": "esc-card-source.v1"
},
"card": {
"$ref": "#/$defs/card"
},
"generated": {
"$ref": "#/$defs/generated"
},
"debug_checkpoints": {
"$ref": "#/$defs/debugCheckpoints"
},
"viewpoints": {
"type": "array",
"minItems": 1,
"maxItems": 8,
"items": {
"$ref": "#/$defs/viewpoint"
}
},
"debug_strategies": {
"type": "object",
"propertyNames": {
"pattern": "^[A-Za-z0-9][A-Za-z0-9._-]*$"
},
"additionalProperties": {
"$ref": "#/$defs/debugStrategy"
}
},
"render_dictionary": {
"type": "boolean",
"description": "Czy React/HTML ma dodać końcową stronę słownika WE/EN/EK/KW."
},
"template": {
"type": "string",
"minLength": 1
},
"title_block": {
"$ref": "#/$defs/titleBlock"
},
"front_page_scope": {
"$ref": "#/$defs/frontPageScope"
},
"dictionary_refs": {
"type": "object",
"properties": {
"pp_json_root": {
"type": "string"
}
},
"additionalProperties": true
},
"side_margin_tree_layout": {
"$ref": "#/$defs/sideMarginLayout"
},
"reference_registries": {
"type": "array",
"items": {
"type": "object",
"required": ["uuid", "source"],
"properties": {
"uuid": {
"$ref": "#/$defs/uuid"
},
"source": {
"type": "string",
"minLength": 1
}
},
"additionalProperties": false
}
},
"learning_effects": {
"type": "object",
"minProperties": 1,
"additionalProperties": {
"$ref": "#/$defs/learningEffect"
}
},
"assessment_criteria": {
"type": "object",
"minProperties": 1,
"additionalProperties": {
"$ref": "#/$defs/assessmentCriterion"
}
},
"educational_requirements": {
"type": "object",
"minProperties": 1,
"additionalProperties": {
"$ref": "#/$defs/educationalRequirement"
}
},
"sections": {
"type": "array",
"items": {
"$ref": "#/$defs/section"
}
},
"tasks": {
"type": "object",
"additionalProperties": {
"$ref": "#/$defs/task"
}
},
"tasks_order": {
"type": "array",
"uniqueItems": true,
"items": {
"type": "string"
}
},
"model_block": {
"type": "object",
"properties": {
"steps": {
"$ref": "#/$defs/stringList"
}
},
"additionalProperties": true
},
"code_block": {
"type": "object",
"properties": {
"blocks": {
"type": "array",
"items": {
"type": "object",
"properties": {
"title": {
"type": "string"
},
"slug": {
"type": "string"
},
"goal": {
"type": "string"
},
"web_steps": {
"$ref": "#/$defs/stringList"
},
"web_commands": {
"type": "array",
"items": {
"type": "object",
"required": ["label", "command"],
"properties": {
"label": {
"type": "string"
},
"command": {
"type": "string"
}
},
"additionalProperties": true
}
}
},
"additionalProperties": true
}
}
},
"additionalProperties": true
},
"hardware_procedure": {
"type": "array",
"items": {
"$ref": "#/$defs/procedureStep"
}
}
},
"$defs": {
"uuid": {
"type": "string",
"pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$"
},
"externalReference": {
"type": "object",
"required": ["kind", "registry_uuid", "uuid"],
"properties": {
"kind": {
"enum": ["strategy", "card", "content", "formula"]
},
"registry_uuid": {
"$ref": "#/$defs/uuid"
},
"uuid": {
"$ref": "#/$defs/uuid"
}
},
"additionalProperties": false
},
"stringList": {
"type": "array",
"items": {
"type": "string"
}
},
"card": {
"type": "object",
"required": [
"id",
"series",
"number",
"count",
"slug",
"title",
"version",
"uuid"
],
"properties": {
"id": {
"type": "string",
"minLength": 1
},
"series": {
"type": "string",
"minLength": 1
},
"series_title": {
"type": "string",
"minLength": 1
},
"number": {
"type": "string",
"minLength": 1
},
"count": {
"type": "string",
"minLength": 1
},
"slug": {
"type": "string",
"pattern": "^[a-z0-9][a-z0-9-]*$"
},
"title": {
"type": "string",
"minLength": 1
},
"version": {
"type": "string",
"minLength": 1
},
"uuid": {
"type": "string",
"minLength": 1
}
},
"additionalProperties": true
},
"generated": {
"type": "object",
"required": ["tex", "html"],
"properties": {
"tex": {
"type": "string",
"minLength": 1
},
"html": {
"type": "string",
"minLength": 1
},
"html_css": {
"type": "string"
},
"html_tree_inspector": {
"type": "boolean"
},
"react_app": {
"type": "boolean",
"description": "Generuje komponentowy podgląd React oraz jawny view-model card-data.json."
},
"bibliography": {
"type": "string"
},
"report_tasks_json": {
"type": "string"
},
"report_tasks_tex": {
"type": "string"
}
},
"additionalProperties": false
},
"titleBlock": {
"type": "object",
"description": "Tekstowa tabliczka w nagłówku: metadane dokumentu oraz opcjonalny adres kodowany w QR.",
"properties": {
"category": { "type": "string" },
"standard": { "type": "string" },
"prepared_by": { "type": "string" },
"prepared_on": { "type": "string" },
"checked_by": { "type": "string" },
"approved_by": { "type": "string" },
"title": { "type": "string" },
"url": {
"type": "string",
"pattern": "^https?://"
},
"repository_url": {
"type": "string",
"pattern": "^https?://"
},
"url_host_uuid": {
"type": "string",
"pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$"
},
"url_domain": {
"type": "string",
"pattern": "^[A-Za-z0-9.-]+$",
"description": "Opcjonalna domena dopinana do subdomeny UUID, np. mpabi.pl."
},
"url_port": { "type": ["string", "integer"] },
"doc_uuid": {
"type": "string",
"pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$"
},
"revision": { "type": "string" },
"issued_on": { "type": "string" },
"series": { "type": "string" },
"document_type": { "type": "string" },
"tool": { "type": "string" },
"sheet": {
"type": "string",
"description": "Legacy static sheet label. Repeated page headers compute page/total dynamically."
},
"show_qr": { "type": "boolean" },
"show_repository_qr": { "type": "boolean" },
"height_cm": { "enum": [2.6, 3] },
"repeat_on_every_page": { "const": true },
"replace_front_matter": { "const": true }
},
"allOf": [
{
"if": {
"required": ["show_qr"],
"properties": {
"show_qr": { "const": true }
}
},
"then": {
"anyOf": [
{ "required": ["url"] },
{ "required": ["url_host_uuid", "doc_uuid"] }
]
}
},
{
"if": {
"required": ["show_repository_qr"],
"properties": {
"show_repository_qr": { "const": true }
}
},
"then": {
"required": ["repository_url"]
}
}
],
"additionalProperties": false
},
"frontPageScope": {
"type": "object",
"required": ["title", "content_tex"],
"properties": {
"title": { "type": "string", "minLength": 1 },
"content_tex": { "type": "string" },
"scope_title": { "type": "string", "minLength": 1 },
"scope_content_tex": { "type": "string" },
"scope_footer_tex": { "type": "string" },
"scope_table": { "$ref": "#/$defs/scopeTable" }
},
"additionalProperties": false
},
"scopeTable": {
"type": "object",
"required": ["rows"],
"properties": {
"headers": {
"type": "array",
"items": { "type": "string", "minLength": 1 }
},
"rows": {
"type": "array",
"items": { "$ref": "#/$defs/scopeTaskRow" }
}
},
"additionalProperties": false
},
"scopeTaskRow": {
"type": "object",
"required": ["chapter", "idea_tex", "priority"],
"properties": {
"chapter": { "type": "string", "minLength": 1 },
"task": { "type": "string" },
"idea_tex": { "type": "string" },
"priority": { "type": "string" },
"status": {
"enum": ["not-started", "draft", "in-progress", "review", "ready", "blocked"]
},
"version": {
"type": "string",
"pattern": "^v[0-9]{2}\\.[0-9]{2}$"
},
"key": { "type": "boolean" }
},
"additionalProperties": false
},
"sideMarginLayout": {
"type": "object",
"required": ["columns"],
"properties": {
"columns": {
"type": "array",
"minItems": 2,
"items": {
"type": "object",
"required": ["id", "label", "side", "tree"],
"properties": {
"id": {
"enum": ["ogolne", "zawodowe"]
},
"label": {
"type": "string"
},
"side": {
"enum": ["left", "right"]
},
"tree": {
"type": "string"
},
"description": {
"type": "string"
}
},
"additionalProperties": true
}
}
},
"additionalProperties": true
},
"learningEffect": {
"type": "object",
"required": ["text"],
"properties": {
"text": {
"type": "string",
"minLength": 1
},
"label": {
"type": "string"
},
"bloom_level": {
"type": "string"
},
"assessment_criteria": {
"$ref": "#/$defs/stringList"
}
},
"additionalProperties": true
},
"assessmentCriterion": {
"type": "object",
"required": ["text", "learning_effects"],
"properties": {
"text": {
"type": "string",
"minLength": 1
},
"learning_effects": {
"$ref": "#/$defs/stringList"
}
},
"additionalProperties": true
},
"educationalRequirement": {
"type": "object",
"required": ["text", "learning_effects", "learning_tree"],
"properties": {
"text": {
"type": "string",
"minLength": 1
},
"label": {
"type": "string"
},
"learning_effects": {
"$ref": "#/$defs/stringList"
},
"learning_tree": {
"type": "object",
"required": ["ogolne", "zawodowe"],
"properties": {
"schema": {
"type": "string"
},
"policy": {
"type": "string"
},
"ogolne": {
"type": "array",
"items": {
"$ref": "#/$defs/treeItem"
}
},
"zawodowe": {
"type": "array",
"items": {
"$ref": "#/$defs/treeItem"
}
}
},
"additionalProperties": true
}
},
"additionalProperties": true
},
"treeItem": {
"type": "object",
"required": ["tree_id", "effect_ref", "display", "text", "kw"],
"properties": {
"tree_id": {
"type": "string",
"minLength": 1
},
"effect_ref": {
"type": "string",
"minLength": 1
},
"display": {
"type": "string",
"minLength": 1
},
"text": {
"type": "string",
"minLength": 1
},
"source": {
"type": "string"
},
"official": {
"type": "string"
},
"local": {
"type": "string"
},
"kind": {
"type": "string"
},
"kw": {
"type": "array",
"minItems": 1,
"items": {
"$ref": "#/$defs/treeCriterion"
}
}
},
"additionalProperties": true
},
"treeCriterion": {
"type": "object",
"required": ["criterion_ref", "display", "text"],
"properties": {
"criterion_ref": {
"type": "string",
"minLength": 1
},
"display": {
"type": "string",
"minLength": 1
},
"text": {
"type": "string",
"minLength": 1
},
"source": {
"type": "string"
},
"official": {
"type": "string"
},
"local": {
"type": "string"
},
"kind": {
"type": "string"
}
},
"additionalProperties": true
},
"section": {
"type": "object",
"required": ["title"],
"properties": {
"title": {
"type": "string",
"minLength": 1
},
"content_kind": {
"type": "string"
},
"content_tex": {
"type": "string"
},
"asset_page_mode": {
"enum": ["flow", "one-per-page"],
"description": "Sposób paginacji assetów. one-per-page wymusza osobną kartkę A4 w HTML i PDF."
},
"page_orientation": {
"enum": ["portrait", "landscape"],
"default": "portrait",
"description": "Orientacja fizycznych stron tej sekcji w HTML i TeX. Dobierana do geometrii diagramu, niezależnie od page_grid."
},
"spread_group": {
"type": "string",
"pattern": "^[A-Za-z0-9][A-Za-z0-9._-]*$",
"description": "Łączy kolejne strony assetów w opcjonalny ekranowy spread; druk nadal zachowuje osobne kartki A4."
},
"spread_label": {
"type": "string",
"minLength": 1,
"description": "Krótka nazwa logicznego diagramu pokazywana przy przełączniku spreadu."
},
"spread_columns": {
"type": "integer",
"minimum": 1,
"maximum": 12,
"description": "Liczba fizycznych stron A4 w jednym wierszu logicznego spreadu."
},
"area_tree_refs": {
"$ref": "#/$defs/stringList"
},
"educational_requirement_refs": {
"$ref": "#/$defs/stringList"
},
"learning_effect_refs": {
"$ref": "#/$defs/stringList"
},
"assessment_criterion_refs": {
"$ref": "#/$defs/stringList"
},
"steps": {
"type": "array",
"items": {
"$ref": "#/$defs/sectionStep"
}
},
"assets": {
"type": "array",
"items": {
"$ref": "#/$defs/sectionAsset"
}
}
},
"additionalProperties": true
},
"sectionAsset": {
"type": "object",
"required": ["path", "caption", "label"],
"properties": {
"path": {
"type": "string",
"minLength": 1
},
"html_path": {
"type": "string",
"minLength": 1,
"description": "Opcjonalny wariant zasobu dla HTML, np. SVG zamiast PNG używanego w TeX."
},
"source_path": {
"type": "string",
"minLength": 1,
"description": "Opcjonalne edytowalne źródło rysunku, np. plik PlantUML."
},
"caption": {
"type": "string",
"minLength": 1
},
"label": {
"type": "string",
"pattern": "^[A-Za-z0-9][A-Za-z0-9:.-]*$"
},
"alt": {
"type": "string"
},
"kind": {
"enum": ["screenshot", "figure", "diagram"]
},
"width": {
"type": "number",
"minimum": 0.1,
"maximum": 1.0
},
"full_size_link": {
"type": "boolean"
},
"interactive": {
"$ref": "#/$defs/interactiveAsset"
},
"page_grid": {
"$ref": "#/$defs/diagramPageGrid"
}
},
"additionalProperties": false
},
"diagramPageGrid": {
"type": "object",
"required": ["columns", "rows"],
"properties": {
"columns": {
"type": "integer",
"minimum": 1,
"maximum": 12
},
"rows": {
"type": "integer",
"minimum": 1,
"maximum": 12
},
"page_width": {
"type": "number",
"exclusiveMinimum": 0,
"default": 660,
"description": "Referencyjna szerokość bezpiecznego pola diagramu A4 w jednostkach PlantUML."
},
"page_height": {
"type": "number",
"exclusiveMinimum": 0,
"default": 760,
"description": "Referencyjna wysokość bezpiecznego pola diagramu A4 w jednostkach PlantUML."
},
"step_tiles": {
"type": "object",
"propertyNames": {
"pattern": "^[A-Za-z0-9][A-Za-z0-9._-]*$"
},
"additionalProperties": {
"type": "integer",
"minimum": 1
},
"description": "Jawne przypisanie id kroku do numeru kafla w porządku wierszowym, liczonego od 1."
},
"cuts_x": {
"type": "array",
"items": {
"type": "number",
"exclusiveMinimum": 0
},
"uniqueItems": true,
"description": "Semantyczne pionowe linie cięcia w układzie współrzędnych SVG; nie mogą przecinać bloków ani etykiet."
},
"cuts_y": {
"type": "array",
"items": {
"type": "number",
"exclusiveMinimum": 0
},
"uniqueItems": true,
"description": "Semantyczne poziome linie cięcia w układzie współrzędnych SVG; nie mogą przecinać bloków ani etykiet."
},
"overview": {
"type": "boolean",
"default": true,
"description": "W HTML udostępnia pomniejszony podgląd całej logicznej planszy obok widoku kafli 1:1."
}
},
"additionalProperties": false
},
"umlSnapshotRegister": {
"type": "object",
"required": ["name", "value"],
"properties": {
"name": { "type": "string", "minLength": 1 },
"value": { "type": "string", "minLength": 1 },
"note": { "type": "string" }
},
"additionalProperties": false
},
"umlSnapshotFrameField": {
"type": "object",
"required": ["name", "address", "value", "state"],
"properties": {
"name": { "type": "string", "minLength": 1 },
"address": { "type": "string", "minLength": 1 },
"value": { "type": "string", "minLength": 1 },
"size_bytes": { "type": "integer", "minimum": 1 },
"state": { "enum": ["initialised", "uninitialised", "saved"] },
"note": { "type": "string" }
},
"additionalProperties": false
},
"umlSnapshotFrame": {
"type": "object",
"required": ["name", "sp", "fp", "size_bytes", "fields"],
"properties": {
"name": { "type": "string", "minLength": 1 },
"sp": { "type": "string", "minLength": 1 },
"fp": { "type": "string", "minLength": 1 },
"stack_top": { "type": "string", "minLength": 1 },
"size_bytes": { "type": "integer", "minimum": 0 },
"fields": {
"type": "array",
"items": { "$ref": "#/$defs/umlSnapshotFrameField" }
}
},
"additionalProperties": false
},
"umlSnapshotMemoryItem": {
"type": "object",
"required": ["name", "address", "value"],
"properties": {
"name": { "type": "string", "minLength": 1 },
"address": { "type": "string", "minLength": 1 },
"value": { "type": "string", "minLength": 1 },
"note": { "type": "string" }
},
"additionalProperties": false
},
"umlSnapshotArena": {
"type": "object",
"required": ["base", "size_bytes", "cursor", "offset", "bytes"],
"properties": {
"base": { "type": "string", "minLength": 1 },
"size_bytes": { "type": "integer", "minimum": 1 },
"cursor": { "type": "string", "minLength": 1 },
"offset": {
"oneOf": [
{ "type": "integer", "minimum": 0 },
{ "type": "null" }
]
},
"bytes": { "type": "string", "minLength": 1 }
},
"additionalProperties": false
},
"umlSnapshot": {
"type": "object",
"required": ["pc", "registers", "frame", "memory", "description"],
"properties": {
"target": { "type": "string", "minLength": 1 },
"captured_at": { "type": "string", "minLength": 1 },
"captured_with": { "type": "string", "minLength": 1 },
"elf": { "type": "string", "minLength": 1 },
"pc": { "type": "string", "minLength": 1 },
"registers": {
"type": "array",
"minItems": 1,
"items": { "$ref": "#/$defs/umlSnapshotRegister" }
},
"frame": { "$ref": "#/$defs/umlSnapshotFrame" },
"memory": {
"type": "object",
"required": ["items"],
"properties": {
"items": {
"type": "array",
"items": { "$ref": "#/$defs/umlSnapshotMemoryItem" }
},
"arena": { "$ref": "#/$defs/umlSnapshotArena" }
},
"additionalProperties": false
},
"code": {
"type": "object",
"required": ["source", "assembly"],
"properties": {
"source": { "type": "string", "minLength": 1 },
"source_ref": { "type": "string" },
"assembly": { "type": "string", "minLength": 1 },
"note": { "type": "string" }
},
"additionalProperties": false
},
"description": { "type": "string", "minLength": 1 }
},
"additionalProperties": false
},
"umlSnapshotContext": {
"type": "object",
"required": ["target", "captured_at"],
"properties": {
"target": { "type": "string", "minLength": 1 },
"captured_at": { "type": "string", "minLength": 1 },
"captured_with": { "type": "string", "minLength": 1 },
"elf": { "type": "string", "minLength": 1 },
"stack_top": { "type": "string", "minLength": 1 }
},
"additionalProperties": false
},
"nvimAnnotationAnchor": {
"type": "object",
"required": ["kind"],
"properties": {
"kind": { "enum": ["screen-text", "grid-range"] },
"text": { "type": "string", "minLength": 1 },
"occurrence": { "type": "integer", "minimum": 1 },
"row": { "type": "integer", "minimum": 0 },
"column": { "type": "integer", "minimum": 0 },
"rows": { "type": "integer", "minimum": 1 },
"columns": { "type": "integer", "minimum": 1 },
"padding_cells": { "type": "integer", "minimum": 0, "maximum": 8 }
},
"allOf": [
{
"if": { "properties": { "kind": { "const": "screen-text" } } },
"then": { "required": ["text"] }
},
{
"if": { "properties": { "kind": { "const": "grid-range" } } },
"then": { "required": ["row", "column", "rows", "columns"] }
}
],
"additionalProperties": false
},
"nvimAnnotation": {
"type": "object",
"required": ["id", "anchor"],
"properties": {
"id": { "type": "string", "minLength": 1 },
"anchor_ref": {
"type": "string",
"minLength": 1,
"description": "Semantyczna kotwica rozwiązywana przez adapter Neovima; anchor jest fallbackiem dla nagranego gridu."
},
"label": { "type": "string", "minLength": 1 },
"tone": { "enum": ["danger", "info", "success", "warning"] },
"shape": { "enum": ["outline", "underline"] },
"anchor": { "$ref": "#/$defs/nvimAnnotationAnchor" }
},
"additionalProperties": false
},
"nvimStepView": {
"type": "object",
"properties": {
"connection_ref": {
"type": "string",
"minLength": 1,
"description": "Logiczny profil/adapter celu, nigdy ID procesu, bufora ani kontenera."
},
"layout": { "type": "string", "minLength": 1 },
"recorded_grid_ref": {
"type": "string",
"minLength": 1,
"description": "Wersjonowany fallback ekranu używany, gdy kontener jest offline."
},
"reveal": {
"type": "object",
"properties": {
"anchor_ref": { "type": "string", "minLength": 1 },
"align": { "enum": ["top", "center", "bottom"] }
},
"additionalProperties": false
},
"annotations": {
"type": "array",
"items": { "$ref": "#/$defs/nvimAnnotation" }
}
},
"additionalProperties": false
},
"debugCheckpointExpression": {
"type": "object",
"required": ["expr", "equals"],
"properties": {
"expr": { "type": "string", "minLength": 1 },
"equals": { "type": "integer" }
},
"additionalProperties": false
},
"debugCheckpointRecipe": {
"type": "object",
"required": ["stop"],
"properties": {
"event_id": {
"type": "string",
"pattern": "^E[0-9]{2}$",
"description": "Semantic event shared by comparable cards; the snapshot id remains card-local."
},
"stop": {
"type": "object",
"required": ["symbol", "offset"],
"properties": {
"symbol": { "type": "string", "pattern": "^[A-Za-z_][A-Za-z0-9_]*$" },
"offset": { "type": "integer", "minimum": 0 },
"condition": { "type": "string", "minLength": 1 }
},
"additionalProperties": false
},
"verify": {
"type": "object",
"properties": {
"expressions": {
"type": "array",
"maxItems": 16,
"items": { "$ref": "#/$defs/debugCheckpointExpression" }
}
},
"additionalProperties": false
}
},
"additionalProperties": false
},
"debugCheckpoints": {
"type": "object",
"required": ["schema", "semantics", "artifact", "targets", "items"],
"properties": {
"schema": { "const": "stem-debug-checkpoints.v1" },
"semantics": { "const": "deterministic-replay" },
"recorded_grid_pattern": {
"type": "string",
"pattern": "^[A-Za-z0-9._/-]*\\{snapshot_ref\\}[A-Za-z0-9._/-]*$"
},
"artifact": {
"type": "object",
"required": ["source", "elf"],
"properties": {
"source": { "type": "string", "minLength": 1 },
"source_git_blob": { "type": "string", "pattern": "^[0-9a-f]{40}$" },
"repository_revision": { "type": "string", "pattern": "^[0-9a-f]{40}$" },
"elf": { "type": "string", "minLength": 1 },
"hazard3_elf_sha256": { "type": "string", "pattern": "^[0-9a-f]{64}$" },
"hazard3_image": { "type": "string", "minLength": 1 },
"hazard3_image_sha256": { "type": "string", "pattern": "^[0-9a-f]{64}$" }
},
"dependentRequired": {
"hazard3_image": ["hazard3_image_sha256"],
"hazard3_image_sha256": ["hazard3_image"]
},
"additionalProperties": false
},
"targets": {
"type": "object",
"minProperties": 1,
"additionalProperties": {
"type": "object",
"required": ["adapter", "baseline"],
"properties": {
"adapter": { "type": "string", "minLength": 1 },
"baseline": { "type": "string", "minLength": 1 },
"clean_ram": { "type": "boolean" },
"requires_probe_lease": { "type": "boolean" },
"persistent_flash": { "type": "boolean" }
},
"additionalProperties": false
}
},
"items": {
"type": "object",
"minProperties": 1,
"propertyNames": { "pattern": "^[A-Za-z0-9][A-Za-z0-9._-]*$" },
"additionalProperties": { "$ref": "#/$defs/debugCheckpointRecipe" }
}
},
"additionalProperties": false
},
"umlSequenceStep": {
"type": "object",
"required": ["id", "number", "label", "description"],
"properties": {
"id": { "type": "string", "minLength": 1 },
"number": { "type": "integer", "minimum": 1 },
"label": { "type": "string", "minLength": 1 },
"mode": {
"enum": ["CODE", "RUN"],
"description": "CODE opens source only; RUN opens source and may replay snapshot_ref. When omitted, steps with snapshot_ref infer RUN and code-only steps infer CODE."
},
"event_id": {
"type": "string",
"pattern": "^E[0-9]{2}$"
},
"strategy_ref": {
"type": "string",
"minLength": 1,
"description": "Reference to a structured entry in debug_strategies."
},
"description": { "type": "string", "minLength": 1 },
"evidence": {
"type": "string",
"minLength": 1,
"description": "Expected source, ELF, disassembly, or runtime proof for the teaching step."
},
"code_ref": { "type": "string" },
"progress_id": { "type": "string", "minLength": 1 },
"snapshot_ref": {
"type": "string",
"minLength": 1,
"description": "Kanoniczny stan wykonania; wiele kroków dydaktycznych może współdzielić jeden snapshot."
},
"view": { "$ref": "#/$defs/nvimStepView" },
"svg_label": {
"type": "string",
"minLength": 1,
"description": "Dokładny numer lub etykieta wiadomości PlantUML wybieranej w inline SVG."
},
"svg_target": {
"type": "string",
"minLength": 1,
"description": "Stable PlantUML SVG element id. If absent, the renderer focuses the svg_label row."
},
"snapshot": { "$ref": "#/$defs/umlSnapshot" }
},
"allOf": [
{
"if": {
"properties": { "mode": { "const": "CODE" } },
"required": ["mode"]
},
"then": { "not": { "required": ["snapshot_ref"] } }
}
],
"additionalProperties": false
},
"viewpoint": {
"type": "object",
"required": ["id", "label", "status"],
"properties": {
"id": {
"enum": ["A1", "A2", "A3", "A4", "A5", "A6", "A7", "A8"]
},
"label": { "type": "string", "minLength": 1 },
"subtitle": { "type": "string" },
"status": { "enum": ["enabled", "unavailable"] },
"target_label": {
"type": "string",
"pattern": "^[A-Za-z0-9][A-Za-z0-9:.-]*$"
},
"reason": { "type": "string", "minLength": 1 }
},
"allOf": [
{
"if": { "properties": { "status": { "const": "enabled" } }, "required": ["status"] },
"then": { "required": ["target_label"] }
},
{
"if": { "properties": { "status": { "const": "unavailable" } }, "required": ["status"] },
"then": { "required": ["reason"] }
}
],
"additionalProperties": false
},
"debugStrategy": {
"type": "object",
"required": ["id", "kind", "action", "expected_observations", "assertions", "evidence_fields"],
"properties": {
"id": { "type": "string", "minLength": 1 },
"kind": { "enum": ["code", "run"] },
"prerequisites": { "$ref": "#/$defs/stringList" },
"code_ref": { "type": "string", "minLength": 1 },
"action": { "enum": ["open", "replay"] },
"layout": { "$ref": "#/$defs/stringList" },
"commands": { "$ref": "#/$defs/stringList" },
"expected_observations": { "$ref": "#/$defs/stringList" },
"assertions": { "$ref": "#/$defs/stringList" },
"evidence_fields": { "$ref": "#/$defs/stringList" }
},
"additionalProperties": false
},
"umlSequencePhase": {
"type": "object",
"required": ["id", "label", "steps"],
"properties": {
"id": { "type": "string", "minLength": 1 },
"label": { "type": "string", "minLength": 1 },
"description": { "type": "string" },
"svg_label": { "type": "string", "minLength": 1 },
"steps": {
"type": "array",
"minItems": 1,
"items": { "$ref": "#/$defs/umlSequenceStep" }
}
},
"additionalProperties": false
},
"interactiveAsset": {
"type": "object",
"required": ["kind"],
"properties": {
"kind": {
"enum": ["allocator-memory-flow", "uml-sequence", "uml-class"]
},
"storage_key": {
"type": "string",
"minLength": 1
},
"title": {
"type": "string",
"minLength": 1
},
"task": {
"type": "object",
"required": ["id", "label"],
"properties": {
"id": { "type": "string", "minLength": 1 },
"label": { "type": "string", "minLength": 1 }
},
"additionalProperties": false
},
"block": {
"type": "object",
"required": ["id", "label"],
"properties": {
"id": { "type": "string", "minLength": 1 },
"label": { "type": "string", "minLength": 1 },
"description": { "type": "string" }
},
"additionalProperties": false
},
"snapshot_context": { "$ref": "#/$defs/umlSnapshotContext" },
"terminal_view": {
"type": "object",
"required": ["path", "alt"],
"properties": {
"path": { "type": "string", "minLength": 1 },
"title": { "type": "string", "minLength": 1 },
"alt": { "type": "string", "minLength": 1 },
"caption": { "type": "string" }
},
"additionalProperties": false
},
"arena_size": {
"type": "integer",
"minimum": 1
},
"allocations": {
"type": "array",
"items": {
"type": "integer",
"minimum": 1
}
},
"symbols": {
"type": "array",
"items": {
"type": "object",
"required": ["id", "area", "declaration", "description"],
"properties": {
"id": { "type": "string", "minLength": 1 },
"area": { "enum": ["compile", "bss", "stack", "registers", "text"] },
"declaration": { "type": "string", "minLength": 1 },
"description": { "type": "string", "minLength": 1 }
},
"additionalProperties": false
}
},
"stages": {
"type": "array",
"minItems": 1,
"items": {
"type": "object",
"required": ["id", "label", "description"],
"properties": {
"id": { "type": "string", "minLength": 1 },
"label": { "type": "string", "minLength": 1 },
"description": { "type": "string", "minLength": 1 },
"code_ref": { "type": "string" },
"progress_id": {
"type": "string",
"minLength": 1,
"description": "Identyfikator zatwierdzenia etapu zapisywany w JSON-ie przebiegu zajęć."
},
"svg_label": {
"type": "string",
"minLength": 1,
"description": "Początek etykiety grupy PlantUML zaznaczanej w inline SVG."
}
},
"additionalProperties": false
}
},
"phases": {
"type": "array",
"minItems": 1,
"items": { "$ref": "#/$defs/umlSequencePhase" }
}
},
"additionalProperties": false
},
"sectionStep": {
"type": "object",
"required": ["id", "title", "tree_refs"],
"properties": {
"id": {
"type": "string",
"minLength": 1
},
"title": {
"type": "string",
"minLength": 1
},
"tree_refs": {
"type": "array",
"minItems": 1,
"items": {
"type": "string"
}
},
"educational_requirement_refs": {
"$ref": "#/$defs/stringList"
},
"learning_effect_refs": {
"$ref": "#/$defs/stringList"
},
"assessment_criterion_refs": {
"$ref": "#/$defs/stringList"
},
"equation_refs": {
"$ref": "#/$defs/stringList"
},
"figure_refs": {
"$ref": "#/$defs/stringList"
},
"references": {
"type": "array",
"items": {
"$ref": "#/$defs/externalReference"
}
}
},
"additionalProperties": true
},
"task": {
"type": "object",
"required": ["prompt_tex", "criterion"],
"properties": {
"prompt_tex": {
"type": "string"
},
"criterion": {
"type": "string"
},
"conclusion_tex": {
"type": "string",
"description": "Końcowy wniosek renderowany po zasobach sekcji."
},
"title": {
"type": "string",
"minLength": 1
},
"uuid": {
"type": "string",
"minLength": 1
},
"flow": {
"type": "array",
"minItems": 1,
"items": {
"$ref": "#/$defs/taskFlowItem"
}
},
"assessment_criterion_ref": {
"type": "string"
},
"educational_requirement_refs": {
"$ref": "#/$defs/stringList"
},
"learning_effect_refs": {
"$ref": "#/$defs/stringList"
}
},
"additionalProperties": true
},
"taskFlowItem": {
"oneOf": [
{ "$ref": "#/$defs/taskBlock" },
{ "$ref": "#/$defs/taskExercise" }
]
},
"taskBlock": {
"type": "object",
"required": ["kind", "id", "title"],
"properties": {
"kind": { "const": "block" },
"id": { "type": "string", "minLength": 1 },
"title": { "type": "string", "minLength": 1 },
"content_tex": { "type": "string" },
"steps": {
"type": "array",
"items": { "$ref": "#/$defs/taskBlockStep" }
}
},
"additionalProperties": false
},
"taskBlockStep": {
"type": "object",
"required": ["id", "title"],
"properties": {
"id": { "type": "string", "minLength": 1 },
"title": { "type": "string", "minLength": 1 },
"content_tex": { "type": "string" },
"tree_refs": { "$ref": "#/$defs/stringList" },
"references": {
"type": "array",
"items": { "$ref": "#/$defs/externalReference" }
}
},
"additionalProperties": false
},
"taskExercise": {
"type": "object",
"required": ["kind", "id", "title", "prompt_tex", "criterion"],
"properties": {
"kind": { "const": "exercise" },
"id": { "type": "string", "minLength": 1 },
"title": { "type": "string", "minLength": 1 },
"prompt_tex": { "type": "string", "minLength": 1 },
"evidence_tex": { "type": "string" },
"criterion": { "type": "string", "minLength": 1 },
"based_on": { "$ref": "#/$defs/stringList" }
},
"additionalProperties": false
},
"procedureStep": {
"type": "object",
"required": ["step", "action", "condition"],
"properties": {
"step": {
"type": "string"
},
"action": {
"type": "string",
"minLength": 1
},
"condition": {
"type": "string",
"minLength": 1
}
},
"additionalProperties": false
}
},
"additionalProperties": true
}