From 95b736cdf8e67d12ffa3d7ffca9bb560894c3af8 Mon Sep 17 00:00:00 2001 From: "M. Pabiszczak" <2+mpabi@noreply.zsl-gitea.mpabi.pl> Date: Mon, 20 Jul 2026 08:36:20 +0200 Subject: [PATCH] meta: add interactive draft URL --- json/card_source.json | 224 ++++++++++++++++++++++++++++++++++++------ 1 file changed, 195 insertions(+), 29 deletions(-) diff --git a/json/card_source.json b/json/card_source.json index d6281c7..7937b22 100644 --- a/json/card_source.json +++ b/json/card_source.json @@ -20,7 +20,13 @@ "author": "M. Pabiszczak", "year": "2026" }, - "generated": {"tex": "doc/generated/main.tex", "html": "web/index.html", "html_css": "web/style.css", "html_tree_inspector": false, "react_app": true}, + "generated": { + "tex": "doc/generated/main.tex", + "html": "web/index.html", + "html_css": "web/style.css", + "html_tree_inspector": false, + "react_app": true + }, "template": "templates/karta-klasyczna.json", "title_block": { "category": "KARTA PRACY · INFORMATYKA", @@ -37,7 +43,8 @@ "show_repository_qr": false, "height_cm": 2.6, "repeat_on_every_page": true, - "replace_front_matter": true + "replace_front_matter": true, + "url": "https://dce7fb9d-7b2f-5d49-96a2-3a30d3070b84.mpabi.pl/1af48a2e-8564-4e18-8115-b2c0208169d6" }, "front_page_scope": { "title": "Cel karty", @@ -45,33 +52,108 @@ "scope_title": "Zakres karty", "scope_content_tex": "Resource ma context i dwa function pointers, bez vtable. Arena jest monotoniczna i resetowana zbiorczo; karta nie deklaruje zgodności z hosted STL ani automatycznego czasu życia obiektów." }, - "side_margin_tree_layout": {"columns": [ - {"id": "zawodowe", "label": "TECH", "side": "left", "tree": "WE -> EK -> KW", "description": "Adresy, ABI, alignment i failure."}, - {"id": "ogolne", "label": "OG", "side": "right", "tree": "WE -> EN -> KW", "description": "Kontrakty ownership i release policy."} - ]}, + "side_margin_tree_layout": { + "columns": [ + { + "id": "zawodowe", + "label": "TECH", + "side": "left", + "tree": "WE -> EK -> KW", + "description": "Adresy, ABI, alignment i failure." + }, + { + "id": "ogolne", + "label": "OG", + "side": "right", + "tree": "WE -> EN -> KW", + "description": "Kontrakty ownership i release policy." + } + ] + }, "learning_effects": { - "K06.EN01": {"bloom_level": "Analiza", "label": "Kontrakt zasobu", "text": "Uczeń wyjaśnia non-owning context, dispatch przez function pointers oraz różnicę heap free i arena reset.", "assessment_criteria": ["K06.KW01"]}, - "K06.EK01": {"bloom_level": "Zastosowanie", "label": "Bezpieczna alokacja typowana", "text": "Uczeń implementuje guard count*sizeof(T), sprawdza alignment i dowodzi niezmienności po failure.", "assessment_criteria": ["K06.KW01"]} + "K06.EN01": { + "bloom_level": "Analiza", + "label": "Kontrakt zasobu", + "text": "Uczeń wyjaśnia non-owning context, dispatch przez function pointers oraz różnicę heap free i arena reset.", + "assessment_criteria": [ + "K06.KW01" + ] + }, + "K06.EK01": { + "bloom_level": "Zastosowanie", + "label": "Bezpieczna alokacja typowana", + "text": "Uczeń implementuje guard count*sizeof(T), sprawdza alignment i dowodzi niezmienności po failure.", + "assessment_criteria": [ + "K06.KW01" + ] + } }, "assessment_criteria": { - "K06.KW01": {"text": "Program kończy się PASS; resource ma trzy wskaźniki i brak vtable; adresy należą do ucHeap/.bss; overflow nie wywołuje providera; capacity failure nie zmienia storage; heap wraca do baseline, arena dopiero po reset.", "learning_effects": ["K06.EN01", "K06.EK01"]} + "K06.KW01": { + "text": "Program kończy się PASS; resource ma trzy wskaźniki i brak vtable; adresy należą do ucHeap/.bss; overflow nie wywołuje providera; capacity failure nie zmienia storage; heap wraca do baseline, arena dopiero po reset.", + "learning_effects": [ + "K06.EN01", + "K06.EK01" + ] + } }, "educational_requirements": { "K06.WE01": { "text": "Zaprojektowanie jawnego, fallible i runtime-selected źródła pamięci dla typów.", "label": "Resource i typed allocator", - "learning_effects": ["K06.EN01", "K06.EK01"], + "learning_effects": [ + "K06.EN01", + "K06.EK01" + ], "learning_tree": { "schema": "we-learning-tree.v1", "policy": "Każda alokacja ma jawny provider, alignment i wynik; reset wymaga granicy czasu życia.", - "ogolne": [{ - "effect_ref": "K06.EN01", "display": "EN LOCAL MEM.RESOURCE.01", "source": "LOCAL", "official": "MEM.RESOURCE", "local": "01", "kind": "EN", "tree_id": "K06.WE01.OG.LOCAL.MEM.RESOURCE.01", "text": "Analizuje ownership resource view i politykę release/reset.", - "kw": [{"criterion_ref": "K06.KW01", "display": "KW LOCAL MEM.RESOURCE.01", "source": "LOCAL", "kind": "KW", "official": "MEM.RESOURCE", "local": "01", "text": "Uzasadnia provider lifetime, arena no-op deallocate i zbiorczy reset."}] - }], - "zawodowe": [{ - "effect_ref": "K06.EK01", "display": "EK LOCAL MEM.ALLOC.01", "source": "LOCAL", "official": "MEM.ALLOC", "local": "01", "kind": "EK", "tree_id": "K06.WE01.TECH.LOCAL.MEM.ALLOC.01", "text": "Bada typed allocation, adresy, alignment i failure state.", - "kw": [{"criterion_ref": "K06.KW01", "display": "KW LOCAL MEM.ALLOC.01", "source": "LOCAL", "kind": "KW", "official": "MEM.ALLOC", "local": "01", "text": "Pokazuje dwa storage domains, guard przed mnożeniem i niezmienione available/used."}] - }] + "ogolne": [ + { + "effect_ref": "K06.EN01", + "display": "EN LOCAL MEM.RESOURCE.01", + "source": "LOCAL", + "official": "MEM.RESOURCE", + "local": "01", + "kind": "EN", + "tree_id": "K06.WE01.OG.LOCAL.MEM.RESOURCE.01", + "text": "Analizuje ownership resource view i politykę release/reset.", + "kw": [ + { + "criterion_ref": "K06.KW01", + "display": "KW LOCAL MEM.RESOURCE.01", + "source": "LOCAL", + "kind": "KW", + "official": "MEM.RESOURCE", + "local": "01", + "text": "Uzasadnia provider lifetime, arena no-op deallocate i zbiorczy reset." + } + ] + } + ], + "zawodowe": [ + { + "effect_ref": "K06.EK01", + "display": "EK LOCAL MEM.ALLOC.01", + "source": "LOCAL", + "official": "MEM.ALLOC", + "local": "01", + "kind": "EK", + "tree_id": "K06.WE01.TECH.LOCAL.MEM.ALLOC.01", + "text": "Bada typed allocation, adresy, alignment i failure state.", + "kw": [ + { + "criterion_ref": "K06.KW01", + "display": "KW LOCAL MEM.ALLOC.01", + "source": "LOCAL", + "kind": "KW", + "official": "MEM.ALLOC", + "local": "01", + "text": "Pokazuje dwa storage domains, guard przed mnożeniem i niezmienione available/used." + } + ] + } + ] } } }, @@ -80,30 +162,101 @@ "title": "Resource bez wirtualności", "content_kind": "prose", "content_tex": "Narysuj context oraz allocate/deallocate function pointers. Provider posiada stan, a MemoryResource jest nieposiadającym widokiem.", - "educational_requirement_refs": ["K06.WE01"], "learning_effect_refs": ["K06.EN01"], "assessment_criterion_refs": ["K06.KW01"], "area_tree_refs": ["K06.WE01.OG.LOCAL.MEM.RESOURCE.01"], + "educational_requirement_refs": [ + "K06.WE01" + ], + "learning_effect_refs": [ + "K06.EN01" + ], + "assessment_criterion_refs": [ + "K06.KW01" + ], + "area_tree_refs": [ + "K06.WE01.OG.LOCAL.MEM.RESOURCE.01" + ], "steps": [ - {"id": "S01", "title": "Zapisz context i dwa różne adresy funkcji allocate.", "tree_refs": ["K06.WE01.OG.LOCAL.MEM.RESOURCE.01"]}, - {"id": "S02", "title": "Potwierdź brak vtable/typeinfo w ELF.", "tree_refs": ["K06.WE01.OG.LOCAL.MEM.RESOURCE.01"]} + { + "id": "S01", + "title": "Zapisz context i dwa różne adresy funkcji allocate.", + "tree_refs": [ + "K06.WE01.OG.LOCAL.MEM.RESOURCE.01" + ] + }, + { + "id": "S02", + "title": "Potwierdź brak vtable/typeinfo w ELF.", + "tree_refs": [ + "K06.WE01.OG.LOCAL.MEM.RESOURCE.01" + ] + } ] }, { "title": "Overflow-safe FreeRtosAllocator", "content_kind": "prose", "content_tex": "Sprawdź count > SIZE_MAX/sizeof(T) przed mnożeniem, potem przekaż bytes i alignof(T) do resource.", - "educational_requirement_refs": ["K06.WE01"], "learning_effect_refs": ["K06.EK01"], "assessment_criterion_refs": ["K06.KW01"], "area_tree_refs": ["K06.WE01.TECH.LOCAL.MEM.ALLOC.01"], + "educational_requirement_refs": [ + "K06.WE01" + ], + "learning_effect_refs": [ + "K06.EK01" + ], + "assessment_criterion_refs": [ + "K06.KW01" + ], + "area_tree_refs": [ + "K06.WE01.TECH.LOCAL.MEM.ALLOC.01" + ], "steps": [ - {"id": "S03", "title": "Uzupełnij guard i udowodnij brak wywołania providera przy overflow.", "tree_refs": ["K06.WE01.TECH.LOCAL.MEM.ALLOC.01"]}, - {"id": "S04", "title": "Sprawdź niezmienione available/used po capacity failure.", "tree_refs": ["K06.WE01.TECH.LOCAL.MEM.ALLOC.01"]} + { + "id": "S03", + "title": "Uzupełnij guard i udowodnij brak wywołania providera przy overflow.", + "tree_refs": [ + "K06.WE01.TECH.LOCAL.MEM.ALLOC.01" + ] + }, + { + "id": "S04", + "title": "Sprawdź niezmienione available/used po capacity failure.", + "tree_refs": [ + "K06.WE01.TECH.LOCAL.MEM.ALLOC.01" + ] + } ] }, { "title": "Heap kontra arena", "content_kind": "prose", "content_tex": "Przydziel po 16 uint32_t, sprawdź zakresy i alignment, a następnie porównaj natychmiastowy heap free z arena deallocate i reset.", - "educational_requirement_refs": ["K06.WE01"], "learning_effect_refs": ["K06.EN01", "K06.EK01"], "assessment_criterion_refs": ["K06.KW01"], "area_tree_refs": ["K06.WE01.TECH.LOCAL.MEM.ALLOC.01", "K06.WE01.OG.LOCAL.MEM.RESOURCE.01"], + "educational_requirement_refs": [ + "K06.WE01" + ], + "learning_effect_refs": [ + "K06.EN01", + "K06.EK01" + ], + "assessment_criterion_refs": [ + "K06.KW01" + ], + "area_tree_refs": [ + "K06.WE01.TECH.LOCAL.MEM.ALLOC.01", + "K06.WE01.OG.LOCAL.MEM.RESOURCE.01" + ], "steps": [ - {"id": "S05", "title": "Pokaż heap address w ucHeap i arena address w .bss.", "tree_refs": ["K06.WE01.TECH.LOCAL.MEM.ALLOC.01"]}, - {"id": "S06", "title": "Pokaż arena used 64, 64, 0 po allocate/deallocate/reset.", "tree_refs": ["K06.WE01.OG.LOCAL.MEM.RESOURCE.01"]} + { + "id": "S05", + "title": "Pokaż heap address w ucHeap i arena address w .bss.", + "tree_refs": [ + "K06.WE01.TECH.LOCAL.MEM.ALLOC.01" + ] + }, + { + "id": "S06", + "title": "Pokaż arena used 64, 64, 0 po allocate/deallocate/reset.", + "tree_refs": [ + "K06.WE01.OG.LOCAL.MEM.RESOURCE.01" + ] + } ] } ], @@ -113,8 +266,21 @@ "uuid": "1af48a2e-8564-4e18-8115-b2c0208169d6", "prompt_tex": "Uzupełnij guard overflow, uruchom identyczne alokacje z heapu i areny, a następnie udowodnij adresy, failure invariants oraz odmienne release policies.", "criterion": "Brak vtable; dwa aligned storage domains; overflow przed providerem; capacity failure bez zmiany storage; heap baseline; arena used 64/64/0; pass=1.", - "educational_requirement_refs": ["K06.WE01"], "learning_effect_refs": ["K06.EN01", "K06.EK01"], "assessment_criterion_ref": "K06.KW01", "links": {"equations": [], "figures": []} + "educational_requirement_refs": [ + "K06.WE01" + ], + "learning_effect_refs": [ + "K06.EN01", + "K06.EK01" + ], + "assessment_criterion_ref": "K06.KW01", + "links": { + "equations": [], + "figures": [] + } } }, - "tasks_order": ["task01"] + "tasks_order": [ + "task01" + ] }