Pondr
adaptive learning platform with ML-based knowledge decay prediction
Project metadata
Overview
An adaptive learning platform that models a user's knowledge as a live graph and uses an XGBoost retention model over Ebbinghaus forgetting curves to predict when each concept will decay, recommending targeted micro-reviews before knowledge fades.
Problem
Spaced repetition tools schedule reviews on fixed intervals that ignore individual learning behavior. Pondr personalizes the forgetting curve per user per concept from behavioral signals.
What it does
Knowledge graph canvas
A React Flow canvas where each concept is a node with a color-coded state:
Nodes are draggable and positions persist across sessions. A timeline scrubber replays learning history.
Hub-based learning
Searching a topic creates a Hub with its own knowledge subgraph, generated by Gemini plus live web research. Prior learning history and past hubs set per-concept difficulty (easy/intermediate/hard), with beginner concepts positioned left and advanced right.
Learning modes
Voice input
ElevenLabs STT (POST /api/speech/transcribe) on onboarding and canvas search. Text-to-speech via POST /api/speech/tts.
Google Calendar integration
Full OAuth 2.0 read/write. Gemini generates weekly study schedules from hubs, availability, and decay state, pushed as [Pondr] Study: <concept> events. Falls back to default free slots (8–10am, 2–4pm, 7–9pm) when unconnected.
Web search and scraping
Tavily for real-time search when generating hub graphs. Firecrawl for resource extraction.
Gamification
XP awards (video snippet +40, quick quiz +80, Feynman +120, Socratic round +150, full Socratic 3+ rounds +450, daily login +25, streak bonus +10 × streak_days). Six level tiers: Novice (0–1,000), Explorer (1,001–3,000), Pathfinder (3,001–8,000), Scholar (8,001–18,000), Master (18,001–35,000), Sage (35,001+). Eight achievements across Common, Rare, Epic, and Legendary rarities.
Architecture
Data flow: register/login issues a JWT → onboarding saves prior learning history → topic search creates a Hub and generates its graph via Gemini plus web research → node interactions log learning events and award XP → the decay engine scores each node via XGBoost and updates node state → Gemini recommendations surface targeted YouTube clips and practice scenarios → Gemini generates a study schedule, optionally synced to Google Calendar.
ML model
Predicts retention R(t) for each user-concept pair: the probability the concept is still remembered at time t, range 0.0 to 1.0. Personalizes the Ebbinghaus stability parameter S from 10 behavioral features.
Feature importances
Performance
Training data
1,000 synthetic learner records generated with realistic behavioral distributions by backend/ml/generate_dataset.py. Trained by backend/ml/train_model.py, serialized to backend/ml/decay_model.joblib.
Edge cases
- days_since_review = 0 → return retention 1.0, skip model
- last_reviewed null → set days_since_review = 99, return retention 0.0
- review_count = 0 → skip model, return state red
- All predictions clipped to [0.0, 1.0]
- Model file missing → log warning, return 0.5 default
API
Nine routers. All endpoints except Auth and Health require Authorization: Bearer <token>.
Database models
MongoDB with Beanie ODM (async Pydantic documents).
- User: auth, profile (goal, background, prior_history, learner_type, has_onboarded), Google OAuth fields (google_id, access/refresh tokens, token expiry, calendar_connected), gamification (xp, level, level_title, streak_days, last_active_date, daily_xp, daily_xp_goal, achievements, skill_points)
- Hub: user_id, topic, title, created_at, last_accessed_at
- ConceptNode: user_id, hub_id, concept, domain, complexity_tier, dependency_depth, state, mode, mastery_score, stability_s, retention_rt, last_reviewed, review_count, canvas_x, canvas_y, difficulty_label
- LearningEvent: every interaction: view, rewatch, practice, feynman, snapshot, quiz
- Recommendation: Gemini recommendation for a node, with YouTube video ID and exact timestamp window
- KnowledgeEdge: directed edge between ConceptNodes, type prerequisite or related, scoped to a hub
- StudyPlan: weekly schedule with embedded StudySession objects and optional Google Calendar event IDs
- Achievement: unlock conditions and XP rewards
- GeminiRateLimit: per user per node, max 1 call per node per 6 hours
Auth flow
Google OAuth exchanges the auth code for Google tokens, links by google_id or email, stores the refresh token for Calendar access, and returns a Pondr JWT.
Full stack
React 18 · Vite · React Flow · Zustand · Tailwind · Framer Motion · Recharts · FastAPI · Uvicorn · MongoDB · Motor · Beanie · XGBoost · scikit-learn · NetworkX · Gemini 2.5 Flash · LangChain · LangGraph · ElevenLabs · Tavily · Firecrawl · Google Calendar API · YouTube Data API v3
Results
Placement | 1st place, HackAI 2026 | |
Participants | 350+ | |
Model RMSE / MAE / lift | 0.0524 / 0.0410 / 67.03% | |
Precision / Recall @ 0.7 | 97.2% / 96.7% | |
Training data | 1,000 synthetic learner records | |
API surface | ~40 endpoints across 9 routers | |
Learning modes | 6 | |
Gemini rate limit | 1 call per node per 6 hours |
