ISMG-2050 Template System Build Completed
Context: Decoupled Content Workflow
The ISMG-2050 course page generation workflow has been rearchitected from a fragile regex/sed approach to a structured YAML + Jinja2 template system. The goal was to replace ad-hoc text transformations with a maintainable content pipeline.
Three-Artifact Architecture
- Template (assignment_template.html): Shared HTML skeleton in
/home/franklin/.openclaw/workspace-web/templates/. Uses dynamicdata-titleanddata-moduleattributes on the header div, with/js/header.jsmounting content at runtime. No static masthead — self-contained pages matching existing ISMG-2050 page patterns. - Manifest (curriculum.yaml): Structured entries for Weeks 1-4 in
/home/franklin/.openclaw/workspace-web/. Each assignment has: slug, output_path, title, type, due_date, description, requirements array, starter_file, and expected_submission. - Compiler (bin/build.py): Reads the manifest, renders pages via Jinja2, runs quality gates (no static <h1> outside teal banner, required course-header div present, minimum 500 bytes output), then deploys via rsync.
Design Decisions
- No nav/footer includes: Template pages are self-contained. This matches the existing ISMG-2050 pattern of standalone homework pages with teal banners only.
- Inline max-width on main: Only allowed inline style is
style="max-width: 960px"on <main> — consistent with the site-wide CSS framework. - Quality gate for <h1>: Rejects any static <h1> outside the teal banner. This prevents template drift from reintroducing hardcoded page titles that conflict with dynamic rendering.
- | safe filter discipline: The Jinja2 safe filter on loop content allows inline code/kbd/strong from YAML but requires strict input validation — any YAML error becomes a DOM risk.
Web Root Conflict Identified
Two conflicting web roots exist on chonk:
- Source of truth (workspace-web):
/home/franklin/.openclaw/workspace-web/— contains curriculum.yaml, templates/, scripts/, and the published teaching pages. - Live site mirror:
/home/franklin/.openclaw/workspace/website/static/www/teaching/ISMG-2050/— the wonderland-synced copy that actually serves the pages.
The build pipeline correctly targets workspace-web as source and deploys to the live path via rsync. However, manual edits on either root without syncing will cause divergence. Franklin confirmed workspace-web is authoritative.
Build Results (October 1, ~07:33 MDT)
- 12 assignments compiled from the curriculum.yaml manifest (5 in weeks 1-2, 7 in weeks 3-4).
- All pages pushed to wonderland via rsync — verified checksum parity.
- Page sizes: 2.3–2.6 KB each (lean, structure-only output from template rendering).
Open Items
- Browser verification: Generated pages need manual review for correct header.js dynamic mounting and CSS styling.
- Git commit: curriculum.yaml, build.py, and assignment_template.html need to be committed to the repo (not done this session).
- Week seeding: Additional week entries should be added to curriculum.yaml as new assignments are created.