

Also from Kynth Studios


Also from Kynth Studios


Also from Kynth Studios
1# CLAUDE.md - Course Creator Platform Documentation23This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.45**Version**: 3.3.1 - Login Redirect Fixes & Authentication Enhancement6**Last Updated**: 2025-10-0878---910## 🚀 MANDATORY SESSION START PROTOCOL1112**AT THE START OF EVERY SESSION, CLAUDE CODE MUST:**1314### Step 1: Load Core Methodology (30 seconds)15```bash16# Check user preferences (CRITICAL - DO THIS FIRST)17python3 .claude/query_memory.py search "Agile"18python3 .claude/query_memory.py search "TDD"19python3 .claude/query_memory.py search "parallel"2021# Review recent context22python3 .claude/query_memory.py list 2023```2425### Step 2: Internalize Methodology (No user reminder needed)26- ✅ User ALWAYS wants Agile + Kanban boards (automatic)27- ✅ User ALWAYS wants TDD - tests BEFORE code (automatic)28- ✅ User ALWAYS wants TodoWrite tracking (automatic)29- ✅ User NEVER wants to be reminded of these preferences30- ✅ For complex tasks: Use Parallel Agent Development System (PADS)3132### Step 3: Reference Self-Improvement Framework33- **Read**: `.claude/CLAUDE_SELF_IMPROVEMENT_PLAN.md` for behavioral guidelines34- **Read**: `.claude/PARALLEL_AGENT_DEVELOPMENT_SYSTEM.md` for parallel workflows35- **Templates**: `.claude/templates/` for TDD, Kanban, session checklists3637### Step 4: Confirm Readiness38Silently confirm understanding of:39- Memory-first workflow40- TDD approach (Red-Green-Refactor)41- Parallel agent development for efficiency42- TodoWrite for task tracking43- Tentative language (no false claims)4445**THESE ARE NOW DEFAULT BEHAVIOR - NOT OPTIONAL**4647---4849## 📁 Documentation Structure5051This documentation is organized into logical sections within the `claude.md/` subdirectory:5253### Core Requirements & Standards54- **[Critical Requirements](claude.md/01-critical-requirements.md)** - Absolute imports, exception handling, file editing efficiency55- **[Documentation Standards](claude.md/02-documentation-standards.md)** - Comprehensive code documentation requirements56- **[Memory System](claude.md/03-memory-system.md)** - Mandatory persistent memory system usage5758### Version History & Features59- **[Version History](claude.md/04-version-history.md)** - Platform evolution and feature updates60- **[Architecture Overview](claude.md/05-architecture.md)** - Microservices structure and dependencies61- **[Key Systems](claude.md/06-key-systems.md)** - Quiz management, feedback, RBAC, RAG, lab containers6263### Development & Operations64- **[Development Commands](claude.md/07-development-commands.md)** - Platform management, testing, database operations65- **[Testing Strategy](claude.md/08-testing-strategy.md)** - Comprehensive testing framework and requirements66- **[Quality Assurance](claude.md/09-quality-assurance.md)** - Code validation, CI/CD pipeline, compliance verification67- **[Troubleshooting](claude.md/10-troubleshooting.md)** - Common issues, debugging, problem-solving methodology6869## 🚨 CRITICAL BEHAVIORAL REQUIREMENTS FOR CLAUDE CODE7071### 1. MANDATORY COMPREHENSIVE E2E SELENIUM TESTING - ALL ROLES (v3.2.2)72**HIGHEST PRIORITY - APPLIES TO ALL CODE CHANGES**7374- **MANDATORY**: Subagents MUST perform Selenium E2E tests on **EVERY feature and pathway for ALL user roles**75- **NO EXCEPTIONS**: All user journeys for ALL 4 roles must have complete E2E test coverage76- **TARGET**: 90%+ E2E coverage across 14 major feature areas and ALL roles (currently ~45-60%)77- **CRITICAL REQUIREMENT**: Test ALL roles, not just students!7879**User Roles Requiring Complete Coverage (4 authenticated + 1 unauthenticated):**801. **Site Admin** - Platform administration, all organizations, system configuration812. **Organization Admin** - Member management, organization settings, tracks, compliance823. **Instructor** - Course creation, content generation, student management, analytics834. **Student** - Learning workflows, assessments, labs, progress tracking845. **Anonymous/Guest** - Public pages, registration, course browsing (unauthenticated)8586**Comprehensive Test Plan:** `/home/bbrelin/course-creator/tests/COMPREHENSIVE_E2E_TEST_PLAN.md`8788**Priority 0 Tests (Must Implement First) - ALL ROLES:**891. Complete Student Learning Journey (Login → Learn → Quiz → Lab → Certificate)902. Complete Instructor Workflow (Create Course → Generate Content → Manage Students → Analytics)913. Complete Organization Admin Workflow (Manage Members → Configure Org → Tracks → Reports)924. Complete Site Admin Workflow (Platform Admin → Monitor System → Manage All Orgs)935. Anonymous/Guest Workflows (Browse → Register → Password Reset)946. RAG AI Assistant Workflow (ALL roles can interact with AI)957. Content Generation Pipeline (Instructor role)9697**Quick Test Command:**98```bash99# Run Priority 0 tests for ALL roles100pytest tests/e2e/critical_user_journeys/ -v101102# Run specific role tests103pytest tests/e2e/critical_user_journeys/test_student_complete_journey.py -v104pytest tests/e2e/critical_user_journeys/test_instructor_complete_journey.py -v105pytest tests/e2e/critical_user_journeys/test_org_admin_complete_journey.py -v106pytest tests/e2e/critical_user_journeys/test_site_admin_complete_journey.py -v107pytest tests/e2e/critical_user_journeys/test_guest_complete_journey.py -v108```109110### 2. MANDATORY DOCKER INFRASTRUCTURE TESTING (v3.2.2)111**SECOND HIGHEST PRIORITY - APPLIES TO ALL CODE CHANGES**112113- **BEFORE** any PR or commit: ALL Docker containers MUST be healthy114- **MANDATORY** GitHub Actions workflow: `docker-infrastructure-test` must pass115- **NO EXCEPTIONS**: Every code change requires Docker health verification116- **ALL 16 SERVICES** must pass health checks with HTTPS enabled117- **VERIFICATION REQUIRED**: Run `./scripts/app-control.sh status` and confirm all green checkmarks118119**Quick Verification Command:**120```bash121# THIS MUST PASS BEFORE ANY PR122./scripts/app-control.sh status 2>&1 | grep "✅"123# Expected: 16 services showing "✅ Healthy"124```125126### 3. NO FALSE SUCCESS CLAIMS127- **NEVER** claim a task is "completed" or "successful" unless you have PROVEN it works through actual testing128- **NEVER** say "✅" or mark anything as working without concrete evidence129- **NEVER** use phrases like "successfully completed", "working correctly", "fixed", "healthy" without verification130131### 4. MANDATORY VERIFICATION REQUIREMENTS132- Before claiming ANY task completion, you MUST provide concrete evidence:133 - Service responding to HTTP requests with 200 status134 - Actual command output showing success135 - Container running with "Up (healthy)" status136 - Real test results, not assumptions137 - **Docker infrastructure tests passing** (see requirement #1)138139### 5. MANDATORY MEMORY TOOL USAGE - ALWAYS FIRST, EVERY TASK140141**CRITICAL RULE: MEMORY SEARCH IS THE FIRST ACTION FOR EVERY TASK**142143Before doing ANYTHING - before reading files, before writing code, before running commands - you MUST:1441451. **Search memory for task-relevant facts** (keywords: technology, feature, component)1462. **Search memory for constraints** (keywords: HTTPS, requirements, architecture)1473. **Review recent context** (`list 20`)148149**Memory Tool Commands:**150```bash151# ALWAYS START WITH THESE - NO EXCEPTIONS152python3 .claude/query_memory.py search "relevant_keyword"153python3 .claude/query_memory.py search "constraints"154python3 .claude/query_memory.py list 20155156# Add new facts AFTER discoveries157python3 .claude/query_memory.py add "<fact_content>" "<category>" "<importance>"158```159160**Why This Matters:**161- Prevents repeating mistakes (like using HTTP instead of HTTPS)162- Ensures critical requirements aren't forgotten163- Maintains consistency with user preferences164- Avoids redundant work165166**Mandatory Memory Workflow:**1671. **BEFORE** making any technical decision → Search memory for relevant facts1682. **DURING** investigation → Document findings as you discover them1693. **AFTER** fixing bugs → Add facts about root cause and solution1704. **NEVER** assume you know something → Verify it exists in memory first171172**Example Workflow:**173```bash174# User says: "The platform uses HTTPS only"175# Step 1: Search memory to verify176python3 .claude/query_memory.py search "HTTPS"177# Found: ID 300 confirms HTTPS-only requirement178179# Step 2: Work on the task using this fact180181# Step 3: Add new discovery182python3 .claude/query_memory.py add "Service endpoint discovered: /users/me (not /api/v1/users/me)" "api-endpoints" "critical"183```184185### 4. MEMORY AND STATE TRACKING186- **ALWAYS** maintain accurate state of what has been attempted vs. what actually works187- If something failed before, acknowledge it failed and explain what's different this time188- Keep track of which services/components are genuinely working vs. still broken189190### 5. TRUTHFUL STATUS REPORTING191When reporting status, use only these categories:192- **WORKING**: Verified with evidence (show the evidence)193- **ATTEMPTED**: Tried but not verified to work194- **BROKEN**: Confirmed not working195- **UNKNOWN**: Not yet tested196197### 6. PROBLEM ACKNOWLEDGMENT198- If you encounter the same error repeatedly, STOP and acknowledge the pattern199- Don't keep trying the same approach that already failed200- Ask for guidance when stuck in loops201202### 7. NO ASSUMPTION-BASED CLAIMS203- Don't claim something works because "the code looks right"204- Don't assume Docker containers work because they built successfully205- Verify actual functionality, not just absence of build errors206207### 8. SYSTEMATIC VERIFICATION PROTOCOL208**Before claiming ANY fix works, you MUST:**209- **Test the exact failing case** - Copy/paste the exact error scenario and reproduce it210- **Test in the actual environment** - Not just isolated unit tests, but in the real deployment context211- **Provide evidence** - Show the before/after comparison with actual output212- **Wait for user confirmation** - Never declare success, only "attempted fix - please verify"213214### 9. LANGUAGE RESTRICTIONS215**FORBIDDEN phrases (never use these without concrete proof):**216- ✅ "PROVEN: [anything] is working"217- ✅ "The error should now be resolved"218- ✅ "Pattern/code compiles successfully!"219- ✅ "Both fixes are working"220- ✅ "Successfully completed"221- ✅ "Working correctly"222223**REQUIRED language (always use these instead):**224- 🔄 "I've made a change that might fix this. Please test it."225- 🔄 "Here's what I changed and why. Can you verify if it works?"226- 🔄 "The pattern works in my test, but please confirm in your browser."227- 🔄 "Attempted fix deployed - needs user verification"228229### 10. ROOT CAUSE ANALYSIS REQUIREMENT230**When debugging, you MUST:**231- **Understand the problem** (not just pattern-match visual symptoms)232- **Research the root cause** (don't guess based on superficial similarities)233- **Test exact scenario** (reproduce the exact failure first)234- **Make minimal changes** (one thing at a time)235- **Document uncertainty** (what you're not sure about)236237### 11. ANTI-PATTERN RECOGNITION238**Recognize and STOP these harmful patterns:**239- Visual pattern recognition → quick fix instinct → biased testing240- "This looks wrong" → make change → assume it's fixed241- Deployment success → claim functional success242- Isolated test passes → claim real-world functionality243- Speed/confidence prioritized over accuracy/verification244245### 12. EPISTEMOLOGICAL HUMILITY246**Acknowledge the limits of what you can know:**247- You cannot directly interact with user browsers248- You cannot see actual user experience249- Your tests are simulations, not reality250- Deployment ≠ functionality251- Code compilation ≠ runtime success252253## 🚨 Critical Code Directives (Always Apply)254255### 1. Python Import Requirements256**ABSOLUTE IMPORTS ONLY** - Never use relative imports (`from ..`, `from .`) in Python files.257258**SERVICE-SPECIFIC NAMESPACES** - All services use service-specific namespaces to prevent collision:259260**9 Services with Clean Architecture (domain/application/infrastructure layers):**261- `analytics` → imports from `analytics.domain.*`, `analytics.application.*`, `analytics.infrastructure.*`262- `content-management` → imports from `content_management.domain.*`, `content_management.application.*`, `content_management.infrastructure.*`263- `course-generator` → imports from `course_generator.domain.*`, `course_generator.application.*`, `course_generator.infrastructure.*`264- `course-management` → imports from `course_management.domain.*`, `course_management.application.*`, `course_management.infrastructure.*`265- `knowledge-graph-service` → imports from `knowledge_graph_service.domain.*`, `knowledge_graph_service.application.*`, `knowledge_graph_service.infrastructure.*`266- `metadata-service` → imports from `metadata_service.domain.*`, `metadata_service.application.*`, `metadata_service.infrastructure.*`267- `nlp-preprocessing` → imports from `nlp_preprocessing.domain.*`, `nlp_preprocessing.application.*`, `nlp_preprocessing.infrastructure.*`268- `organization-management` → imports from `organization_management.domain.*`, `organization_management.application.*`, `organization_management.infrastructure.*`269- `user-management` → imports from `user_management.domain.*`, `user_management.application.*`, `user_management.infrastructure.*`270271**Directory Structure:**272```273services/SERVICE-NAME/274├── service_name_package/ # ← New namespace directory (underscored)275│ ├── __init__.py276│ ├── domain/ # ← Domain layer under service namespace277│ │ └── entities/278│ ├── application/ # ← Application layer under service namespace279│ │ └── services/280│ └── infrastructure/ # ← Infrastructure layer under service namespace281│ └── repositories/282├── data_access/ # ← Shared DAOs (not in namespace)283├── api/ # ← API endpoints (not in namespace)284└── main.py # ← Service entry point285```286287**Import Examples:**288```python289# OLD (namespace collision - DO NOT USE):290from domain.entities.course import Course291from application.services.course_service import CourseService292293# NEW (service-specific namespace - USE THIS):294from course_management.domain.entities.course import Course295from course_management.application.services.course_service import CourseService296```297298**Note**: Service directory names use hyphens (`content-management`), but Python package names use underscores (`content_management`).299300### 2. Exception Handling301**CUSTOM EXCEPTIONS MANDATORY** - Never use generic `except Exception as e` handlers. Use structured custom exceptions with f-strings.302303### 3. Documentation Requirements304**COMPREHENSIVE DOCUMENTATION** - All code must include multiline string documentation explaining business context and technical rationale.305306### 4. Memory System Usage307**MANDATORY MEMORY SYSTEM** - Must use the persistent memory system for context continuity across conversations.308309### 5. File Type-Specific Comment Syntax310- Python: `"""multiline strings"""`311- JavaScript: `//` or `/* */`312- CSS: `/* */`313- HTML: `<!-- -->`314- YAML: `#`315- SQL: `--` or `/* */`316- Bash: `#`317318## 🏗️ Platform Overview319320The Course Creator Platform is a comprehensive educational technology system with:321322- **9 Microservices** (ports 8000-8010) providing authentication, content generation, lab management, analytics, RBAC, and demo functionality323- **Multi-IDE Lab Environment** with individual Docker containers for students324- **Enhanced RBAC System** with multi-tenant organization management and Guest role325- **RAG-Enhanced AI** for progressive learning and content generation326- **Demo Service** with realistic data generation for platform demonstration (port 8010)327- **Guest Session Privacy Compliance** with GDPR/CCPA/PIPEDA-compliant PostgreSQL storage and privacy APIs328- **Enhanced AI Chatbot** with NLP, RAG, knowledge graph integration, and personalized onboarding329- **Comprehensive Testing** with 102 RBAC tests achieving 100% success rate plus 101+ demo service tests330- **Advanced Password Management** with secure admin account creation and self-service password changes331- **Enhanced UI/UX** with keyboard navigation, accessibility features, and responsive design332333## 📖 How to Read This Documentation334335When Claude Code needs to reference this documentation:3363371. **Start here** - Read this root file for overview and critical directives3382. **Navigate to specific sections** - Use the links above to access detailed information3393. **Follow cross-references** - Related sections reference each other for comprehensive understanding340341## 🔄 Quick Navigation342343For immediate needs:344- **Development Setup**: See [Development Commands](claude.md/07-development-commands.md)345- **Troubleshooting**: See [Troubleshooting](claude.md/10-troubleshooting.md)346- **Architecture Questions**: See [Architecture Overview](claude.md/05-architecture.md)347- **Testing Issues**: See [Testing Strategy](claude.md/08-testing-strategy.md)348- **Privacy Compliance**: See [Guest Session Privacy Compliance](docs/GUEST_SESSION_PRIVACY_COMPLIANCE.md)349- **Privacy API**: See [Privacy API Documentation](docs/PRIVACY_API_DOCUMENTATION.md)350351---352353**COMPLIANCE REQUIREMENT**: All code must adhere to the critical directives listed above and the detailed requirements in the subdirectory files.
Same format, overlapping stack, ranked by quality.
| Repository | Format | Stack | Covers | Score | Changed |
|---|---|---|---|---|---|
| nimbalyst/nimbalystpackages/android/CLAUDE.md · 1.5k | CLAUDE.md | setupbuildstylearch+2 | 100/100 | 14 days ago | |
| dotCMS/corecore-web/CLAUDE.md · 949 | CLAUDE.md | teststylearchtesting-strategy+3 | 100/100 | 14 days ago | |
| tphakala/birdnet-goCLAUDE.md · 1.6k | CLAUDE.md | buildtestlint-formatstyle+8 | 100/100 | today | |
| tyrchen/geektime-bootcamp-aiw7/genslides/backend/CLAUDE.md · 230 | CLAUDE.md | testlint-formatstylearch+6 | 100/100 | 9 days ago | |
| Adit-Jain-srm/NightmareNetCLAUDE.md · 46 | CLAUDE.md | buildtestlint-formatstyle+6 | 100/100 | 14 days ago | |
| livewire/livewireCLAUDE.md · 24k | CLAUDE.md | setupbuildteststyle+4 | 100/100 | 14 days ago | |
| dotCMS/coreCLAUDE.md · 949 | CLAUDE.md | setupbuildteststyle+7 | 99/100 | today | |
| dotCMS/corecore-web/libs/sdk/client/CLAUDE.md · 949 | CLAUDE.md | setupbuildtestlint-format+9 | 97/100 | 14 days ago |
A badge carrying the measured quality of the strongest agent config file in this repository, out of 100. It reads from this index every time somebody loads your page, so it changes when the measurement changes and there is nothing to keep up to date. Free, no account, and the value is not something you or we can set by hand.
[](https://rulestack.kynth.studio/configs/redmage123-course-creator-claude)Would rather not hotlink us? Every badge is also served in shields.io’s endpoint schema, so shields renders the image and your readers never talk to our domain:
Published by Toolproof, the masthead over this index and eight others. The method behind the number is at toolproof.kynth.studio/methodology, and the whole thing is readable as JSON with no key at /api.