Commit Graph

3 Commits

Author SHA1 Message Date
f39680d714 feat: AI-powered quiz generation with caching
- Add Quiz model to store generated questions in DB
- Integrate OpenRouter API to generate quiz from lesson content
- Cache quiz results to avoid regenerating on every request
- Extract text from TipTap JSON and send to AI
- Fallback to default questions if AI fails or no API key

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-06 10:58:15 +00:00
2ed65f5678 feat: add course catalog, enrollment, progress tracking, quizzes, and reviews
Backend changes:
- Add Enrollment and LessonProgress models to track user progress
- Add UserRole enum (USER, MODERATOR, ADMIN)
- Add course verification and moderation fields
- New CatalogModule: public course browsing, publishing, verification
- New EnrollmentModule: enroll, progress tracking, quiz submission, reviews
- Add quiz generation endpoint to LessonsController

Frontend changes:
- Redesign course viewer: proper course UI with lesson navigation, progress bar
- Add beautiful typography styles for course content (prose-course)
- Fix first-login bug with token exchange retry logic
- New pages: /catalog (public courses), /catalog/[id] (course details), /learning (enrollments)
- Add LessonQuiz component with scoring and results
- Update sidebar navigation: add Catalog and My Learning links
- Add publish/verify buttons in course editor
- Integrate enrollment progress tracking with backend

All courses now support: sequential progression, quiz tests, reviews, ratings,
author verification badges, and full marketplace publishing workflow.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-06 10:44:05 +00:00
b9d9b9ed17 project init 2026-02-06 02:17:59 +03:00