AI Tutor Home (Student/B2C)¶
/learn is the post-login landing for both B2B student and B2C b2c_user roles: one page, two audiences. It leads with a time-of-day greeting and a four-tile intent grid, so a learner sees in one glance what the tutor can do for them.
How it works¶
The page renders inside ChatEngine via the B2C emptyStateSlot. It shows a time-of-day greeting with the learner's first name ("Good evening, Rahul. What shall we work on?") and four IntentTiles under an "Or start something new" divider:
- Get help with a problem →
/learn/get_help - Understand a topic →
/learn/understand - Practice for a test →
/learn/practice(opensTestPrepWizardon first visit) - Revise weak topics →
/learn/revise
Practice carries an "Updated" badge so first-time learners notice the Test Prep Wizard exists. The badge is an optional badge?: ReactNode prop on IntentTile; falsy means no badge.
Below the grid, ChatView still renders the composer and dynamic suggestion chips. The home does not duplicate the composer.
Flow when a learner taps Practice: IntentTile navigates to /learn/practice, ChatEngine sees intent=practice and mounts TestPrepWizard, gated first-time by kwilo.testPrepWalkthroughSeen. The wizard runs overview → subject → materials → generating → done. On re-entry with the walkthrough already seen, it skips straight to test generation.
Edge cases:
- No first name (rare): greeting falls back to "What shall we work on?".
- The institutional learner (B2B
student) empty state is unchanged. The B2CChatPageat/new-chatis a separate surface and keeps its own empty state.
Intent tones¶
Each intent maps 1:1 to a TIntentTileTone already defined in packages/ui/src/surfaces/IntentTile.tsx:
| Intent | Tone |
|---|---|
get_help |
accent |
understand |
primary |
practice |
secondary |
revise |
accent |
Card copy reuses student.intents.{intent}.title and .description from student.json.
Where it lives¶
- Route:
/learn(ROUTES.studentHome), guarded forstudent+b2c_userinStudentRoutes.tsx apps/web/src/pages/student/StudentHomePage/index.tsx