Repository Public
1# CLAUDE.md — ATLAS IA: The Open MOOC Platform23> **Mission:** Design, implement, test, deploy, and maintain a truly exceptional, French-language, free and accountless MOOC experience at **https://atlas.spboucher.ai**.4>5> **Instructor:** **Simon-Pierre Boucher**, professeur, Département des sciences administratives, **Université du Québec en Outaouais (UQO)**.6>7> **Public access promise:** No login, registration, email, payment, subscription, paywall, tracking consent wall, or account is required to access any published educational material.89## 0. Operating mandate — build, don't just describe1011You are Claude Code acting as principal product designer, full-stack engineer, video learning systems engineer, accessibility lead, DevOps engineer, QA lead, and educational experience designer. Deliver a functioning, deployed, polished production system, not a mockup or implementation plan. Follow the existing repository's conventions where appropriate. Verify claims and test each feature. When external credentials or approvals are missing, implement the integration boundary, document the blocker, and do not fabricate success.1213**First inspect the existing course platform used for IMM1003 and IMM1033**: locate its actual source repository, deployment, design, content organization, video player, administration, storage, and authentication model using available authorized local files, repositories, and deployment information. Reuse proven patterns where licensing and access allow. Do not guess its stack or copy protected assets. If it cannot be located, record that fact and continue with a self-contained, modern implementation. Audit any existing atlas.spboucher.ai deployment before touching it. Preserve data and use reversible deployment steps.1415Read the companion ATLAS AI MOOC curriculum repository and its CLAUDE.md, when accessible. The site must map to the actual course content and should not invent published lessons, video files, or download links. If materials are absent, clearly label them as 'À venir' and use a configurable preview mode rather than fake completed content.1617## 1. Non-negotiable product principles18191. Entire learner-facing experience is in high-quality **Canadian French (fr-CA)**, including UI, accessibility labels, error messages, SEO, transcripts, lessons, captions, quizzes, emails if any, downloadable descriptions, and legal information. Preserve code/API identifiers in English where helpful.202. All **published** content is free to view and, where licensing permits, download, without creating an account. No hidden registration for quizzes, progress, search, video playback, or resources.213. The platform is publicly accessible; **only the instructor/editor administration is private**. Never expose editing privileges or secrets publicly.224. Instructor credit: **Simon-Pierre Boucher — Professeur, Département des sciences administratives, Université du Québec en Outaouais (UQO)**. Display on course home, instructor page, and appropriate session pages. Do not imply official university accreditation, endorsement, branding authorization, or UQO-issued certification without explicit approval. Use university logo only if authorized.235. Extraordinary but restrained original design: visually memorable, readable, performant, accessible, not a generic LMS template. No unlicensed copied artwork or proprietary UI assets.246. All public features must work without third-party AI API keys. AI-assisted extras must be optional, explicitly labeled, rate-limited, and cost-controlled; core education must never depend on them.257. Privacy first: avoid behavioral advertising, invasive analytics, and unnecessary personal data. Respect applicable Canadian/Quebec privacy requirements; get legal review for any compliance claims.268. Mobile-first, keyboard accessible, responsive, fast, resilient on slow connections, compatible with modern Safari, Chrome, Firefox, iOS, iPadOS, and macOS.279. Provide working tests, deployment automation, backup/restore, monitoring, and operational documentation.2829## 2. Brand and design direction3031Name: **ATLAS IA**. Site: **atlas.spboucher.ai**.32Proposed headline: **« Comprendre l’IA. Construire avec l’IA. »**33Proposed subtitle: **« Un cours ouvert et gratuit sur les modèles de langage, les agents IA, Claude Code, Codex et les systèmes agentiques. »**34Instructor: **Simon-Pierre Boucher**, professeur à l'UQO.3536Develop a distinctive design system: deep midnight/navy foundation, crisp off-white text, carefully controlled cyan/azure/violet accents, custom diagrams, sophisticated grid, subtle depth and motion, excellent typography and generous spacing. Offer dark and light modes; respect system preference. Provide reduced-motion alternatives. Make every visual element serve learning. Avoid overdecorated dashboards, tiny fonts, inaccessible contrast, stock-image overload, and generic AI-glow clichés.3738Create a proper brand kit: wordmark and original ATLAS icon (vector), favicons, OG image, tokens, iconography, component library, design documentation, screenshots, and responsive states. Any custom diagrams must be original, code-based SVG/Canvas/CSS or exported from the course's own TikZ/PGFPlots source. Respect original educational figure provenance.3940## 3. Information architecture4142Public routes (adapt names to the selected router while keeping semantic French URLs):4344- `/` — extraordinary course landing page.45- `/programme` — complete curriculum, 24 sessions grouped by 6 parts, searchable/filterable.46- `/seances/[slug]` — lesson detail and learning hub.47- `/seances/[slug]/regarder` — immersive learning/video view.48- `/ressources` — unified library of slides, PDF, source code, exercises, datasets, transcripts.49- `/laboratoires` — practical labs and guided challenges.50- `/parcours` — recommended learning paths for beginner, professional, developer, researcher.51- `/glossaire` — searchable definitions with cross-links and diagrams.52- `/recherche` — full-text search over published materials and transcripts.53- `/a-propos` — course, instructor, methodology, affiliation disclaimer, licensing.54- `/accessibilite`, `/confidentialite`, `/conditions` — accurate, concise informational pages.55- `/admin` — private authoring studio, never public editing access.5657Build meaningful empty, loading, error, offline, and not-yet-published states. Provide graceful 404 and 500 pages. Support permanent redirects when slugs change.5859## 4. The 24-session MOOC structure6061Do not hardcode fictional lesson details as published. Import actual titles and metadata from the course repo, with an editable canonical manifest. If unavailable, provision this *draft* structure, visibly labeled as planned:6263**Part I — Foundations**6401. Qu'est-ce qu'un LLM ?6502. Transformers, tokens, embeddings et inférence6603. Fenêtre de contexte et gestion du contexte6704. Mémoire, RAG et recherche sémantique6869**Part II — Agent systems**7005. Chatbot, assistant et agent autonome7106. Terminal, shell, fichiers et permissions7207. Sous-agents, délégation et orchestration7308. Tool calling, API et MCP7475**Part III — Coding agents**7609. Claude Code : premiers projets7710. OpenAI Codex : premiers projets7811. Git, tests et développement agentique7912. CLAUDE.md, AGENTS.md et règles de projet8081**Part IV — Engineering practice**8213. Recherche documentaire et citations8314. Python, données et automatisation8415. Sécurité, sandboxing et contrôle humain8516. Débogage, évaluation et fiabilité des agents8687**Part V — Advanced architecture**8817. Architectures multi-agents avancées8918. Gestion de la mémoire persistante9019. Agents de longue durée et workflows9120. Modèles locaux, coûts et infrastructure9293**Part VI — Applied projects**9421. Construire une application avec l'IA9522. Applications en recherche, science et éducation9623. Applications en finance, immobilier et organisations9724. Projet intégrateur, validation et perspectives9899The curriculum repository is the authority when its final plan differs from these placeholders. Support additional sessions and changes without code modifications.100101## 5. Landing page — world-class learning experience102103The first screen should instantly answer: what is ATLAS IA, who teaches it, why it is useful, what is free, and where to begin. Prominent **« Commencer gratuitement »** CTA; never require signup. Include a short course preview/video when genuinely available, instructor identity, 6-part curriculum map, selected lesson cards, practical outcomes, transparent prerequisites, equipment/software guidance, FAQs, and resource availability. Show real published content counts, not invented metrics. Build a compelling curriculum visualization that is accessible and works without animations.104105No intrusive newsletter popups, fake testimonials, false student counts, fake endorsements, or manufactured ratings. Any testimonials require consent and provenance.106107## 6. Best-in-class video learning player108109Implement a production-ready player with:110111- Native HTML5 playback and adaptive HLS where supported, with robust Safari compatibility; fallback MP4 as configured.112- Multiple resolutions where encoded, bandwidth-adaptive playback, poster, preload control, buffering indicators.113- Play/pause, ±10 s skip, volume/mute, playback speed (e.g. 0.75x–2x), full-screen, picture-in-picture when available, keyboard shortcuts with a visible help overlay.114- French subtitles (WebVTT), optionally other languages, with accurate caption timing and controls.115- Searchable, timestamped transcript; clicking a segment seeks video; highlight current segment where feasible; accessible transcript export.116- Chapter navigation, timestamps, bookmarks stored **locally in the browser**, and deep links to moments.117- Resumable position and progress stored locally, no account or server identity needed; a clear **« Effacer mes données locales »** control.118- Video and slide synchronization only when accurate slide timing metadata exists; otherwise offer side-by-side independent PDF view.119- Focus mode / theater mode, distraction-free layout, notes area stored locally with explicit export/import (JSON or Markdown), no forced cloud sync.120- Next/previous lesson navigation, estimated duration, prerequisite links, session resource tabs.121- Clear error handling for unavailable media and helpful retry behavior.122- Download only when the instructor has enabled and licensed it.123124Do not bypass DRM, access restrictions, or provider terms. Do not promise offline video playback unless it is actually implemented and rights permit it.125126## 7. Lesson page: one authoritative learning hub per session127128Every lesson has: title, part, number, description, learning outcomes, level, estimated duration, prerequisites, publication state, video list, chapters, original diagrams, slides PDF, LaTeX sources when released, exercise instructions, datasets, code examples, solutions with configurable delayed release, quiz, bibliography, glossary links, revision history, and instructor notes (private when appropriate).129130A lesson may have several short capsules, not one giant video. Make video ordering, optional vs mandatory material, and lesson completion rules explicit. Offer compact content outline, progress marker, shareable canonical URL, print-friendly summary, and accessibility-first navigation. Never render empty resources as working downloads.131132## 8. Interactive exercises without accounts133134Build accessible, responsive self-check activities: single/multiple-choice, true/false, ordering, matching, short numerical answer with tolerance, fill-in-the-blank, debugging scenarios, and conceptual reasoning. Give explanations, not just right/wrong badges. Allow repeat attempts. Store attempts only locally by default; offer manual export/import. Avoid client-side answer leakage for graded high-stakes assessments; since this is a free anonymous MOOC, clearly label quizzes as formative, not secure proctored exams.135136For programming exercises, provide downloadable starter files, expected outputs, automated local tests, and optional browser-based sandbox only if properly isolated and resource-limited. Never execute arbitrary learner code on the production server without a hardened isolated execution environment.137138## 9. Original interactive educational visuals139140Create a reusable library of first-class diagrams and explorable explanations, all home-made:1411421. Tokenization visualizer with examples and token counts clearly marked as tokenizer-specific.1432. Transformer attention schematic with precise, simplified educational labels.1443. Context-window budget visualization.1454. Memory vs context vs retrieval flow.1465. RAG retrieval pipeline with citations and failure modes.1476. Agent observe–plan–act–verify loop.1487. Tool invocation and permission boundary.1498. Terminal/shell process and filesystem model.1509. Multi-agent delegation graph with parallel/sequential paths.15110. MCP client/server/tool/resource conceptual map.15211. Git branches, commits and review flow.15312. Agent evaluation, test coverage and failure recovery.15413. Model hosting and local vs API trade-offs.15514. Prompt-injection and trust-boundary illustration.15615. End-to-end coding agent lifecycle.157158Implement as original SVG/React/CSS or import/export from authored TikZ figures; accessible text equivalents and keyboard interaction are mandatory. The platform should feel like a living textbook, not merely a video hosting site. Every interaction must accurately model the concept; no misleading animated decoration.159160## 10. Search and knowledge navigation161162Index titles, descriptions, chapter names, transcript segments, glossary entries, and published resources. Support French accents, typo tolerance when feasible, highlighted matches, faceted filters by part/session/type/level, and timestamped video search results. Keep private/draft/solution content out of public search and metadata. Prefer an efficient local or server-side search index, not a required third-party paid service. Make the content graph navigable via cross-links and 'concepts associés'.163164## 11. Anonymous progress and privacy165166No learner accounts, cookies for identity, mandatory tracking, login gates, email capture, or paywall. Use localStorage/IndexedDB only for optional local progress, bookmarks, preferences, and notes; explain what is stored and how to clear it. Export/import local learning state without a server account. Avoid analytics by default; if privacy-preserving aggregate analytics are added, document exact collection, retention, consent/legal basis, and opt-out where required. Do not silently transmit transcripts of user notes or quiz answers to an AI provider.167168A public anonymous experience cannot promise cross-device progress synchronization; describe manual import/export as the supported alternative. Do not issue official certificates tied to identity without a separate identity-verification workflow and authorization. Optional downloadable self-assessment completion summary is not a university credential.169170## 12. Instructor studio — private, powerful, elegant171172Build a separate, strongly authenticated admin interface for the instructor and explicitly authorized editors. Prefer secure passkeys/WebAuthn or a robust supported identity provider; enforce server-side authorization, rate limits, secure sessions, CSRF protection where applicable, audit logging for changes, and least privilege. Never use client-only admin guards, hidden URLs as security, or hardcoded credentials. Admin login is allowed; **learner login is not**.173174Studio capabilities:175176- Dashboard: draft/published sessions, media processing, broken resources, publication schedule, storage use, build health.177- Create/edit/reorder/archive sessions, parts, capsules, chapters, outcomes, prerequisites, glossary, bibliography, and metadata.178- Rich Markdown/MDX editor with live preview, image/diagram embed, syntax-highlighted code, LaTeX math, accessible tables.179- Drag-and-drop video uploads with chunked/resumable transfer, progress, checksum, retry, duplicate detection, and storage quota warnings.180- Video processing jobs: validate input, transcode to configured HLS renditions and MP4 fallback, extract poster, waveforms if useful, generate thumbnails, create chapter metadata, attach subtitles and transcripts. Use queue/worker infrastructure for long jobs.181- Upload slides PDF, source LaTeX, ZIP labs, datasets, transcripts, captions, thumbnails, and licensed assets.182- Resource visibility, download permissions, version history, replacement without broken links, integrity checks.183- Draft → preview → scheduled/published → archived workflow; preview access must be private and secure.184- Bulk import from the ATLAS course repository, manifest diff preview, conflict handling, and explicit publish confirmation.185- Quiz editor with answer explanations, randomized options, and preview.186- Search-index rebuild, link checker, subtitle validation, caption timing preview.187- Backup/restore interface or documented operator commands; export all course content and metadata.188- Audit log, undo/rollback where feasible, destructive-action confirmation.189190Do not expose draft videos or answer keys via public storage URLs. Secure signed URLs where needed, while keeping published materials accessible anonymously.191192## 13. Repository and content integration193194Establish a canonical machine-readable `course.manifest.json` or YAML schema. Each session folder in the ATLAS curriculum repository should support, where present:195196```197sessions/198 01-introduction-llm/199 metadata.yaml200 slides/main.tex201 slides/figures/202 slides/main.pdf203 videos/manifest.yaml204 transcripts/205 captions/206 labs/207 exercises/208 solutions/209 datasets/210 references.bib211```212213The actual course repo may have different paths: write an adapter rather than imposing a destructive restructure. Validate schema, required fields, referenced files, media URLs, licensing, publication state, captions, and transcript timestamps. Support incremental sync, content hashes, idempotent imports, and clear conflict policy. Never auto-publish unreviewed course content.214215Treat course repo code and LaTeX as **content**, not trusted commands to execute in the web server. If PDFs are built automatically, isolate compilation and impose resource/time limits. Prevent path traversal, malicious archives, and unsafe uploads.216217## 14. Recommended architecture (validate against existing infrastructure)218219Default candidate: TypeScript monorepo, Next.js (or existing compatible framework), React, strict TypeScript, Tailwind/design tokens, accessible headless UI primitives, PostgreSQL for authoring metadata, object storage compatible with S3 for media, FFmpeg workers, search index appropriate to corpus size, reverse proxy/Caddy, and containerized deployment. Prefer the existing proven stack when warranted. Avoid complexity for its own sake.220221Suggested structure:222223```224atlas-platform/225 CLAUDE.md226 README.md227 apps/web/228 apps/worker/229 packages/ui/230 packages/content-schema/231 packages/learning-engine/232 packages/diagram-library/233 packages/search/234 packages/config/235 infra/236 scripts/237 tests/238 docs/239 .github/workflows/240```241242Support clean environments: local development, staging, production. Secrets exclusively in environment/secret manager; commit `.env.example` but never real credentials. No destructive migration or DNS change without backup and approval. Confirm actual deployment host, domain routing, TLS and storage from authorized access before deployment. Provide a deterministic build and version pinning.243244## 15. Performance, accessibility and SEO245246Aim for WCAG 2.2 AA, with manual keyboard/screen-reader checks in addition to automated audits. Captions and accurate transcripts for all published instructional videos; accessible PDFs or equivalent HTML alternatives when feasible. Logical heading hierarchy, visible focus, skip links, proper form labels, semantic landmarks, high contrast, no color-only information, reduced motion.247248Use SSR/SSG/ISR appropriately for public lessons. Optimize images and fonts, defer heavy visualizations, lazy-load media, preconnect only to necessary origins, support caching and CDN. Set measurable Core Web Vitals budgets and test on constrained mobile devices. Generate sitemap, canonical URLs, robots, structured Course/VideoObject metadata only for genuine published content, social cards, French locale metadata, and accessible share links. Never index admin or drafts.249250## 16. Security and threat model251252Threat-model admin auth, public content, upload processing, media storage, API abuse, SSRF, XSS/Markdown injection, CSRF, SQL injection, path traversal, prompt injection in imported materials, malicious ZIP/PDF/LaTeX, denial of service, secrets leakage, and unsafe code execution. Validate content type and size, scan uploads where practical, isolate FFmpeg/LaTeX workers, enforce time/memory/disk quotas, set CSP/security headers, restrict CORS, use secure cookies and server-side auth. Separate public read permissions from private write permissions. Run dependency audits, static checks and integration tests. Never log secrets or unnecessary personal information.253254## 17. Operational reliability and content durability255256Implement health endpoints, structured logs with sensitive data redaction, error monitoring, media processing observability, uptime checks, storage alerts, database migrations, regular backups, restoration drills, and incident runbooks. Preserve original master videos, transcoded derivatives, caption files, PDFs, source content, and manifest metadata. Define retention, lifecycle, and rollback policy. Document storage/bandwidth/transcoding cost estimates and how to operate within a realistic budget; public content is free to learners, not cost-free to host.257258## 18. Quality assurance and acceptance criteria259260Before claiming completion, run and report:261262- `typecheck`, lint, formatting and production build.263- Unit tests for manifests, search, progress, quiz logic, publication permissions, and URL generation.264- Integration tests for imports, admin publication, media attachment, search indexing, and access control.265- E2E tests for anonymous visitor: open home → browse curriculum → open published session → play video → use captions/transcript → take quiz → download a resource → refresh and resume locally; **never prompted for an account**.266- E2E tests for private admin authentication, upload, processing, preview, publication, edit and rollback.267- Accessibility tests and manual keyboard/screen reader audits.268- Responsive screenshots and visual regression at mobile/tablet/desktop; dark/light mode.269- Performance checks with a representative course catalog and realistic video assets.270- Security checks: unpublished materials inaccessible, admin APIs protected, upload validation, no secrets in bundle.271- Production smoke tests only after authorized deployment, including HTTPS/TLS, DNS, media playback on Safari/iPhone, resource downloads, and graceful errors.272273Record actual test commands, results, failures, screenshots, and fixes. Do not report a feature as complete merely because UI scaffolding exists.274275## 19. Implementation phases — keep moving, validate each phase276277**Phase 0 — Reconnaissance:** Inspect IMM1003/IMM1033 platform and ATLAS course repository; audit existing domain/deployment; document findings, constraints, and chosen architecture. Do not invent infrastructure.278279**Phase 1 — Foundations:** Initialize repo, design system, brand, route structure, manifest schema, sample *draft* content, database/storage configuration, CI, security baseline, test harness.280281**Phase 2 — Public flagship:** Build exceptional homepage, curriculum, session pages, instructor/about, resources, glossary, search, mobile navigation, SEO and accessibility.282283**Phase 3 — Learning engine:** Build professional video player, chapters, captions, transcript search, progress, notes, quizzes, labs, diagram library, local export/import.284285**Phase 4 — Publishing studio:** Implement secure admin, content editor, uploads, transcode queue, previews, scheduled publishing, versioning, audit trail, import/sync from course repo.286287**Phase 5 — Production hardening:** Security review, load tests, backups, monitoring, cost optimization, full E2E, cross-browser verification, staging deployment.288289**Phase 6 — Launch:** Deploy to atlas.spboucher.ai only with verified infrastructure and authorization. Validate DNS, TLS, media, admin, backups, anonymous access, mobile Safari. Publish only approved material. Provide launch checklist and operational handover.290291Continue through phases autonomously within available permissions and time; maintain a durable `IMPLEMENTATION_STATUS.md` showing done/in progress/blocked, real evidence and next actions. Never silently skip a hard feature or replace it with a mock.292293## 20. Documentation deliverables294295Produce `README.md` (French overview, quick start), `docs/ARCHITECTURE.md`, `docs/DESIGN_SYSTEM.md`, `docs/CONTENT_MANIFEST.md`, `docs/INSTRUCTOR_STUDIO.md`, `docs/VIDEO_PIPELINE.md`, `docs/ACCESSIBILITY.md`, `docs/SECURITY.md`, `docs/PRIVACY.md`, `docs/DEPLOYMENT.md`, `docs/BACKUP_RESTORE.md`, `docs/TESTING.md`, `docs/OPERATIONS.md`, and `IMPLEMENTATION_STATUS.md`. Include `.env.example`, migration scripts, example course manifest, and automated checks.296297Document who can publish, how to add a new session, how to upload a 4K master and create adaptive streams, how to attach captions, how to sync LaTeX slides from the MOOC repository, how to roll back a publication, how to restore backups, and how to operate without a paid AI API.298299## 21. Visual quality bar and anti-patterns300301The finished product must feel like a premium original educational publication with exceptional editorial typography, intentional motion, precise diagrams, clear hierarchy, and fluid mobile UX. Treat every major screen as a crafted product: home, catalog, session, player, glossary, lab, admin. Use real content when available and honest empty states otherwise.302303**Never** deliver: a generic LMS template, placeholder video buttons, broken downloads, faux progress syncing, fabricated instructor endorsements, unverified university certification, public admin endpoints, mandatory learner accounts, hidden paywalls, generic AI stock imagery as the primary teaching medium, inaccessible interactive diagrams, or nonfunctional controls.304305## 22. Final instructions to Claude Code306307Start by auditing the actual course repositories, IMM1003/IMM1033 platform and available deployment environment. Summarize verified findings briefly, then implement. Create the full working repository and commit in logical increments. Produce original, extraordinary visual quality, a real media pipeline, and frictionless anonymous learning. Test relentlessly. Preserve French as the public language and Simon-Pierre Boucher's correct instructor credit. The goal is **the most polished free French-language agentic AI MOOC platform we can responsibly build**.308309**Launch principle:** Anyone should be able to open `https://atlas.spboucher.ai`, click **« Commencer gratuitement »**, and begin learning immediately—without entering a name, email address, password, or payment information.310