feat(courses): add LearnLens AI Chat and AI Practice Quiz to video lesson viewer - #233
Conversation
syed-tp
commented
Jul 30, 2026
- Add AI Chat and AI Practice Quiz tabs for video lessons using LearnLens integration.
- Support quiz generation, difficulty filters, hint cards with timestamp cues, and multi-language localizations.
- Follow design system tokens and WCAG 2.5.5 touch target accessibility standards.
…ntegration and session management
|
Claude finished @syed-tp's task in 5m 14s —— View job Claude finished the review
PR Review Summary✅ What's good
🔴 CRITICAL — Must fix before merge
🟡 WARNING — Should fix
🔵 SUGGESTION — Nice to have
VerdictCHANGES REQUESTED |
… to video MCQ components
…ementing localized strings
… and LearnLens session creation processes
…omponents to use the new method
|
@claude review |
|
Claude finished @syed-tp's task in 4m 25s —— View job Claude finished reviewing
Note on prior reviewThe repo's shallow clone has no common ancestor with PR Review Summary✅ What's good
🔴 CRITICAL — Must fix before merge
🟡 WARNING — Should fix
🔵 SUGGESTION — Nice to have
VerdictCHANGES REQUESTED Most of the previous critical accessibility/localization/scoring issues are resolved. What remains: the stale generated-file diff, touch-target sizing on two elements, one missed localized string, a motion-preference gap, and the hardcoded LearnLens URL. |
…session error messages
|
@claude review LearnLens base URL is still hardcoded. learnlens_network_client.dart:11 — _learnLensBaseUrl = 'https://learnlens.testpress.in'. AppConfig.learnLensOrgUuid (added in this same PR) correctly follows the --dart-define pattern used by apiBaseUrl, but the base URL itself doesn't, which breaks per-instance/white-label overriding of the LearnLens endpoint. - its fine New Drift columns added without a schema migration. lessons_table.dart adds canEnableLearnlensAi, learnlensAssetId, learnlensAssetStatus, but AppDatabase.schemaVersion (app_database.dart:59) stays at 1, and onUpgrade only creates missing tables (app_database.dart:66-77) — it never adds columns to existing tables. This appears to be a pre-existing gap in the migration strategy (schemaVersion has been 1 since the DB was introduced), so it's not new to this PR, but it means users with an already-created local DB won't get these 3 new columns until a reinstall/data wipe, and any Drift read/write against them will fail on those installs. Worth raising given this PR depends on it for the AI-availability gating (isAiAvailable check in video_lesson_viewer.dart). - its in development, so we can ignore it (the app is not released) |
|
Claude finished @syed-tp's task in 1m 41s —— View job Claude finished reviewing
PR Review Summary✅ What's good — confirmed fixed since last review
Acknowledged, not re-flagged (per author)
🔴 CRITICAL — Still outstanding
🔵 SUGGESTION — Nice to have (unchanged from last review)
VerdictCHANGES REQUESTED — only the stale |
|
@claude code course_list_provider.g.dart still doesn't match its source. Comparing directly against origin/main: courseListHash/courseSearchHash differ (5c4261d... → 6741d1f..., 754041d... → 390cf82...), but course_list_provider.dart has zero diff against origin/main across the entire branch — confirmed no commit in this PR touches that file. The regenerated hash first appears in commit 7ba65aa, alongside the LearnLens feature work, with no corresponding source change. This means the checked-in .g.dart doesn't reflect what build_runner would currently produce from this branch's actual source, which will show up as codegen drift in CI (or mask a stale/local regen). Please run a clean dart run build_runner build --delete-conflicting-outputs on this branch and either commit the correct resulting diff or revert this file to match origin/main. - we can skip this i guess, im not sure why but i have tried generating multiple times and it was there all times, so its better to keep that way than removing |
|
Claude finished @syed-tp's task in 1m 31s —— View job Claude's response
InvestigationConfirmed Given the source text feeding Practically, this hash is only used by Riverpod's codegen tooling for provider-identity/hot-reload bookkeping — it has no effect on runtime behavior or test outcomes. Given:
I agree it's reasonable to leave it as committed rather than hand-editing it back. Worth a quick check at some point on whether CI's StatusWith this item acknowledged, there are no remaining blocking items from my earlier reviews — all CRITICAL/WARNING findings (quiz scoring bug, missing semantics, touch targets, localization, motion preference, Sentry integration) were fixed in later commits, and the LearnLens base URL / Drift migration / codegen-hash items are knowingly deferred by you. Nothing further to implement on my end for this request. |
|
@claude review course_list_provider.dart line 4 imports package:core/data/data.dart. This PR modified lesson_detail_provider.dart, which also lives in the same packages/courses build graph. riverpod_generator doesn't just hash the source of the file itself — it hashes the full transitive closure of every Dart file that participates in the same code generation run. So when any file in that graph changes (even an indirect dependency), all downstream _$xxxHash() values are recomputed. In short: course_list_provider.dart didn't change, but another file in the same build_runner input set did — and that's enough for the generator to produce new hashes. The diff is correct and expected; it reflects a clean regeneration on this branch's actual source. Tell me the verdict, approved or not? |
|
Claude finished @syed-tp's task in 2m 1s —— View job Claude finished reviewing
InvestigationRe-confirmed against
On the theory itself: The much more mundane explanation — consistent with what you reported earlier ("tried generating multiple times and it was there all times") — is a local toolchain difference: a different That said, this doesn't change the practical bottom line from the last review: this hash has zero runtime effect (it's only consulted by Riverpod's dev-time hot-reload bookkeeping), it's the only remaining item on this PR, and you've already made the call to keep it as-is rather than risk re-introducing drift by hand-editing it back. That's a reasonable call. VerdictAPPROVED — no remaining blocking issues. All prior CRITICAL items (quiz scoring, missing semantics, touch targets) and WARNING items (localization, motion preference, Sentry integration) were fixed in later commits. The LearnLens base URL and missing Drift migration are knowingly deferred by you. The |
…ering for consistency