@@ -2470,3 +2470,332 @@ InsightLearn is planning a major business model transition from **pay-per-course
24702470- ** URL** : https://github.com/marypas74/InsightLearn_WASM
24712471- ** Issues** : https://github.com/marypas74/InsightLearn_WASM/issues
24722472- ** Maintainer** : [email protected] 2473+
2474+ ---
2475+
2476+ # # Student Learning Space (v2.1.0 - In Development)
2477+
2478+ ** Status** : Planning Complete, Development Starting
2479+ ** Target Version** : v2.1.0
2480+ ** Implementation Timeline** : 10-12 weeks
2481+ ** Architecture Review** : 10/10 (Backend Architect + UI/UX Designer)
2482+ ** Task Breakdown** : [/tmp/STUDENT-LEARNING-SPACE-TASK-BREAKDOWN.md](/tmp/STUDENT-LEARNING-SPACE-TASK-BREAKDOWN.md)
2483+
2484+ # ## Overview
2485+
2486+ Professional student learning interface matching LinkedIn Learning quality standards, with integrated AI assistant for enhanced learning experience.
2487+
2488+ # ## Key Features
2489+
2490+ ** Video Learning Experience** :
2491+ - Professional 3-column responsive layout (sidebar-content-AI assistant)
2492+ - Enhanced video player with advanced controls
2493+ - Video bookmarks with custom labels
2494+ - Resume from last position across devices
2495+ - Picture-in-picture support
2496+
2497+ ** AI-Powered Features** :
2498+ - ** Video Transcripts** : Auto-generated using Azure Speech Services or Whisper API
2499+ - Searchable with timestamp navigation
2500+ - Full-text search with highlighting
2501+ - Download as text/SRT format
2502+ - ** AI Key Takeaways** : Automatically extracted main concepts, best practices, examples
2503+ - Relevance scoring
2504+ - Category classification (CoreConcept, BestPractice, Example, Warning, Summary)
2505+ - Thumbs up/down feedback
2506+ - ** Contextual AI Chatbot** : Enhanced Ollama integration with context awareness
2507+ - Knows current video timestamp, transcript, and student notes
2508+ - Conversation history per lesson
2509+ - Real-time streaming responses via SignalR
2510+
2511+ ** Student Tools** :
2512+ - ** Notebook** : Take timestamped notes during video playback
2513+ - Markdown support with preview
2514+ - Bookmark important notes
2515+ - Share notes with community (optional)
2516+ - Real-time sync across devices (SignalR)
2517+ - ** Progress Tracking** : Granular 5-second interval tracking
2518+ - Multi-device sync via Redis
2519+ - Resume position API
2520+ - Visual progress indicators
2521+
2522+ # ## Architecture
2523+
2524+ ** Database Schema** :
2525+ - ** 5 new SQL Server tables** :
2526+ - ` StudentNotes` - User notes with timestamps
2527+ - ` VideoBookmarks` - Bookmarked video positions
2528+ - ` VideoTranscriptMetadata` - Metadata for MongoDB transcripts
2529+ - ` AIKeyTakeawaysMetadata` - Metadata for AI analysis
2530+ - ` AIConversations` - Chat session management
2531+ - ** 3 new MongoDB collections** :
2532+ - ` VideoTranscripts` - Full transcript data with text search indexes
2533+ - ` VideoKeyTakeaways` - AI-extracted key concepts
2534+ - ` AIConversationHistory` - Complete chat history
2535+
2536+ ** Backend Services** (6 new):
2537+ - ` IVideoTranscriptService` - ASR integration, transcript generation
2538+ - ` IAIAnalysisService` - Ollama-powered takeaway extraction, contextual chat
2539+ - ` IStudentNoteService` - Note CRUD, sharing, bookmarking
2540+ - ` IVideoBookmarkService` - Bookmark management
2541+ - ` IVideoProgressService` (enhanced) - Granular tracking, multi-device sync
2542+ - Background Jobs (Hangfire/Quartz.NET):
2543+ - ` TranscriptGenerationJob` - Queue video → ASR → MongoDB
2544+ - ` AITakeawayExtractionJob` - Transcript → Ollama analysis
2545+ - ` OldConversationCleanupJob` - Cleanup 90-day old chats
2546+
2547+ ** New API Endpoints** (28 total):
2548+
2549+ # #### Transcript Endpoints (5)
2550+ - ` GET /api/transcripts/{lessonId}` - Get complete transcript
2551+ - ` GET /api/transcripts/{lessonId}/search? query={text}` - Search transcript
2552+ - ` POST /api/transcripts/{lessonId}/generate` - Queue generation (Admin/Instructor)
2553+ - ` GET /api/transcripts/{lessonId}/status` - Check processing status
2554+ - ` DELETE /api/transcripts/{lessonId}` - Delete transcript (Admin)
2555+
2556+ # #### AI Takeaways Endpoints (3)
2557+ - ` GET /api/takeaways/{lessonId}` - Get key takeaways
2558+ - ` POST /api/takeaways/{lessonId}/generate` - Queue generation (Admin/Instructor)
2559+ - ` POST /api/takeaways/{takeawayId}/feedback` - Thumbs up/down
2560+
2561+ # #### Student Notes Endpoints (6)
2562+ - ` GET /api/notes? lessonId={id}` - Get user notes for lesson
2563+ - ` POST /api/notes` - Create note
2564+ - ` PUT /api/notes/{id}` - Update note
2565+ - ` DELETE /api/notes/{id}` - Delete note
2566+ - ` GET /api/notes/shared? lessonId={id}` - Get community shared notes
2567+ - ` POST /api/notes/{id}/toggle-bookmark` - Bookmark note
2568+
2569+ # #### AI Chat Endpoints (4)
2570+ - ` POST /api/ai-chat/message` - Send message with context
2571+ - ` GET /api/ai-chat/history? sessionId={id}` - Get chat history
2572+ - ` POST /api/ai-chat/sessions/{sessionId}/end` - End session
2573+ - ` GET /api/ai-chat/sessions? lessonId={id}` - List sessions for lesson
2574+
2575+ # #### Video Bookmarks Endpoints (4)
2576+ - ` GET /api/bookmarks? lessonId={id}` - Get bookmarks
2577+ - ` POST /api/bookmarks` - Create bookmark
2578+ - ` PUT /api/bookmarks/{id}` - Update bookmark
2579+ - ` DELETE /api/bookmarks/{id}` - Delete bookmark
2580+
2581+ # #### Video Progress Enhancement (2)
2582+ - ` POST /api/progress/sync` - Sync progress (multi-device)
2583+ - ` GET /api/progress/resume? lessonId={id}` - Get resume position
2584+
2585+ ** Frontend Components** (10+ new Blazor components):
2586+
2587+ ** Main Layout** :
2588+ - ` StudentLearningSpace.razor` - Main 3-column layout with responsive breakpoints
2589+ - ` CourseContentSidebar.razor` - Left sidebar with collapsible chapters
2590+ - ` VideoPlayerArea.razor` - Center area with video + tabs
2591+ - ` AIAssistantSidebar.razor` - Right sidebar with AI features
2592+
2593+ ** Video & Content** :
2594+ - ` VideoPlayer.razor` (enhanced) - Advanced controls, keyboard shortcuts, PiP
2595+ - ` TabNavigation.razor` - Overview, Notebook, Transcript, Q& A tabs
2596+ - ` OverviewTab.razor` - Course description, instructor info
2597+ - ` NotebookTab.razor` - Student notes interface with Markdown editor
2598+ - ` TranscriptTab.razor` - Searchable transcript with auto-scroll
2599+ - ` QATab.razor` - Placeholder for future Q& A feature
2600+
2601+ ** AI Assistant** :
2602+ - ` KeyTakeawaysCard.razor` - Display AI-extracted key concepts
2603+ - ` AIQuestionInput.razor` - Chat input with context indicators
2604+ - ` AIResponseDisplay.razor` - Chat messages with typing indicator
2605+ - ` RelatedTopicsCard.razor` - Placeholder for future feature
2606+
2607+ ** Supporting Components** :
2608+ - ` VideoBookmarkIndicator.razor` - Bookmark markers on timeline
2609+ - ` ProgressIndicator.razor` - Enhanced progress visualization
2610+ - ` ChapterListItem.razor` - Sidebar chapter item
2611+ - ` VideoListItem.razor` - Sidebar video item
2612+
2613+ # ## Design System
2614+
2615+ ** CSS Variables** (defined in ` learning-space.css` ):
2616+ ` ` ` css
2617+ :root {
2618+ /* Brand Colors * /
2619+ --il-primary: # 0073b1; /* LinkedIn blue */
2620+ --il-primary-dark: # 005582;
2621+ --il-sidebar-bg: # 2d2d2d; /* Dark sidebar */
2622+ --il-bg-primary: # ffffff;
2623+ --il-bg-secondary: # f3f6f8;
2624+
2625+ /* Typography * /
2626+ --il-font-family: ' Inter' , -apple-system, sans-serif;
2627+ --il-font-base: 16px;
2628+
2629+ /* Spacing (8px grid) * /
2630+ --il-space-sm: 0.5rem; /* 8px * /
2631+ --il-space-md: 1rem; /* 16px * /
2632+ --il-space-lg: 1.5rem; /* 24px * /
2633+ --il-space-xl: 2rem; /* 32px * /
2634+ }
2635+ ` ` `
2636+
2637+ ** Responsive Breakpoints** :
2638+ - Desktop: 1024px+ (3-column layout)
2639+ - Tablet: 768px-1023px (content + toggleable sidebars)
2640+ - Mobile: < 768px (single column + bottom nav)
2641+
2642+ ** Accessibility** : WCAG 2.1 AA compliant
2643+ - Keyboard navigation (tab order, skip links, shortcuts)
2644+ - Screen reader support (ARIA labels, semantic HTML)
2645+ - Color contrast 4.5:1 minimum
2646+ - Captions & transcripts for all videos
2647+ - Tested with axe DevTools, NVDA, VoiceOver
2648+
2649+ # ## Implementation Phases
2650+
2651+ ** Phase 1: Database Schema & Foundation (Week 1-2)**
2652+ - 5 SQL Server tables + 3 MongoDB collections
2653+ - Entity models & DTOs
2654+ - Repository pattern implementation
2655+
2656+ ** Phase 2: Backend Services & Business Logic (Week 3-5)**
2657+ - Video transcript service (ASR integration)
2658+ - AI analysis service (Ollama prompts)
2659+ - Student note service
2660+ - Video bookmark service
2661+ - Background job processing (Hangfire)
2662+
2663+ ** Phase 3: API Endpoints (Week 6-7)**
2664+ - 28 new REST endpoints
2665+ - Swagger documentation
2666+ - Integration tests
2667+
2668+ ** Phase 4: Frontend Components (Week 8-10)**
2669+ - Design system CSS
2670+ - Main layout + 10+ Blazor components
2671+ - Responsive design (desktop/tablet/mobile)
2672+ - Accessibility implementation
2673+
2674+ ** Phase 5: Integration & Optimization (Week 11)**
2675+ - SignalR real-time features
2676+ - Performance optimization (Redis caching, lazy loading)
2677+ - Error handling & logging
2678+
2679+ ** Phase 6: Testing & QA (Week 12)**
2680+ - Unit tests (80%+ coverage)
2681+ - Integration tests (user journeys)
2682+ - Load testing (K6)
2683+ - Security audit
2684+
2685+ ** Phase 7: Deployment & Documentation (Week 12)**
2686+ - Kubernetes deployment updates
2687+ - API documentation (Swagger)
2688+ - User guide
2689+ - Monitoring & alerting (Grafana dashboards)
2690+
2691+ # ## Development Status
2692+
2693+ ** Current Phase** : Planning Complete ✅
2694+ ** Next Phase** : Phase 1 (Database Schema) - Ready to Start
2695+ ** Estimated Completion** : 10-12 weeks from kickoff
2696+
2697+ ** Task Tracking** :
2698+ - Complete task breakdown: [/tmp/STUDENT-LEARNING-SPACE-TASK-BREAKDOWN.md](/tmp/STUDENT-LEARNING-SPACE-TASK-BREAKDOWN.md)
2699+ - TODO list registered in Claude Code
2700+ - Development assignments pending team availability
2701+
2702+ # ## Dependencies
2703+
2704+ ** External Services** :
2705+ - ** Azure Speech Services** or ** Whisper API** - Video transcription (ASR)
2706+ - API key required in environment variables
2707+ - Fallback: Manual transcript upload
2708+ - ** Ollama** - AI analysis (already deployed: qwen2:0.5b)
2709+ - ** MongoDB** - Transcript & AI data storage (already configured)
2710+ - ** Redis** - Caching & multi-device sync (already configured)
2711+ - ** SignalR** - Real-time features (WebSocket support required)
2712+
2713+ ** NuGet Packages** (new):
2714+ - ` Hangfire` or ` Quartz.NET` - Background job processing
2715+ - ` Azure.AI.TextAnalytics` (optional) - Advanced AI features
2716+ - ` MarkdownSharp` or ` Markdig` - Markdown rendering
2717+
2718+ ** NPM Packages** (new):
2719+ - ` marked` - Markdown editor component
2720+ - (Optional) ` video.js` - Enhanced video player (if replacing HTML5 default)
2721+
2722+ # ## Known Limitations
2723+
2724+ 1. ** Transcript Generation Cost** : Azure Speech Services charges per minute
2725+ - Estimated cost: $1 per hour of video
2726+ - Mitigation: Cache transcripts, manual upload option
2727+ 2. ** Ollama Performance** : AI takeaway extraction ~ 10-15 seconds per video
2728+ - Background job processing prevents blocking
2729+ 3. ** MongoDB Storage** : Large transcripts (~500KB per hour of video)
2730+ - 1000 hours of video = ~ 500MB MongoDB storage
2731+ 4. ** Mobile Data Usage** : Streaming video + transcripts data-intensive
2732+ - Mitigation: Download for offline, quality selector
2733+
2734+ # ## Future Enhancements (Post-v2.1.0)
2735+
2736+ - ** Interactive Quizzes** : In-video quiz questions at key moments
2737+ - ** Study Groups** : Real-time collaborative note-taking sessions
2738+ - ** Flashcard Generation** : Auto-generate flashcards from key takeaways
2739+ - ** Certificate of Completion** : PDF certificate with learning metrics
2740+ - ** Learning Analytics Dashboard** : Time spent, topics mastered, quiz scores
2741+ - ** Multi-language Transcripts** : Auto-translate transcripts (Azure Translator)
2742+ - ** Instructor Live Sessions** : Live video streaming with Q& A chat
2743+ - ** Peer Review** : Students can review/rate shared notes
2744+
2745+ # ## Success Metrics (Post-Launch)
2746+
2747+ ** Technical KPIs** :
2748+ - All 28 API endpoints operational (100%)
2749+ - API response time < 200ms (p95)
2750+ - Transcript generation success rate > 95%
2751+ - AI chat response < 3 seconds
2752+ - WCAG 2.1 AA compliance verified
2753+
2754+ ** User Experience KPIs** :
2755+ - Video playback starts < 2 seconds
2756+ - Note auto-save < 1 second
2757+ - Mobile interface fully functional
2758+ - Accessibility score > 90 (Lighthouse)
2759+
2760+ ** Business KPIs** :
2761+ - Student engagement time +30% vs current interface
2762+ - Note-taking feature adoption > 60%
2763+ - AI assistant usage > 40% of students
2764+ - Course completion rate +15%
2765+ - Mobile usage > 35%
2766+
2767+ # ## Testing Strategy
2768+
2769+ ** Unit Tests** : 80%+ coverage (services, repositories)
2770+ ** Integration Tests** : User journeys (watch video → take notes → ask AI → complete)
2771+ ** Load Tests** : 100 concurrent users, 500 AI messages/min
2772+ ** Security Tests** : Authorization, SQL injection, XSS, rate limiting
2773+ ** Accessibility Tests** : axe DevTools, NVDA, VoiceOver, Lighthouse
2774+
2775+ # ## Monitoring & Alerting
2776+
2777+ ** New Metrics** (Prometheus):
2778+ - ` transcript_generation_duration_seconds` - ASR processing time
2779+ - ` ai_takeaway_extraction_duration_seconds` - Ollama analysis time
2780+ - ` student_note_creation_total` - Note creation count
2781+ - ` ai_chat_response_duration_seconds` - Chat response latency
2782+ - ` video_playback_error_total` - Playback failures
2783+
2784+ ** New Alerts** (Grafana):
2785+ - Transcript job failures > 5% in 1 hour
2786+ - AI chat response time > 5 seconds (p95)
2787+ - Video playback error rate > 2%
2788+ - MongoDB query latency > 500ms
2789+
2790+ # ## Documentation
2791+
2792+ - ** API Documentation** : Swagger UI at ` /swagger` (28 new endpoints)
2793+ - ** User Guide** : " How to Use Student Learning Space" (in-app help)
2794+ - ** Developer Documentation** : Architecture, database schema, troubleshooting
2795+ - ** Task Breakdown** : [/tmp/STUDENT-LEARNING-SPACE-TASK-BREAKDOWN.md](/tmp/STUDENT-LEARNING-SPACE-TASK-BREAKDOWN.md)
2796+
2797+ ---
2798+
2799+ ** Last Updated** : 2025-11-18
2800+ ** Document Version** : 1.0
2801+ ** Status** : ✅ Ready for Development Kickoff
0 commit comments