Inspiration

We live in an era of infinite educational content. From YouTube to Medium articles and online courses, there is an overwhelming sea of knowledge available. Yet, this abundance has created a severe modern crisis in self-directed learning: people no longer know where to start or what path to follow.

Learners get trapped in "Tutorial Hell", endlessly jumping from one disconnected video to another without ever completing a coherent curriculum. Imagine a beginner chess player attempting to improve; without a structured roadmap, they jump from watching a video on the Sicilian Defense to learning complex endgame theory simply because they heard someone mention it. They absorb scattered fragments of information, lose focus, and fail to build foundational mastery. And foundation is key to success in learning.

On the flip side, when learners attempt to commit to formal online courses, they are confronted with 40-hour video playlists without an engaging means of testing how much they learned. The result is a staggering dropout rate across traditional EdTech.

We built Sabi to solve this exact dual dilemma. We wanted to create an adaptive learning engine capable of generating custom curricula that a learner can easily start without confusion, and reliably complete without burnout.

What it does

Sabi is a deterministic, AI-driven adaptive learning engine. It abandons the linear playlist paradigm but focused more on optimizing learning.

When a user requests a topic, Sabi generates a strict Directed Acyclic Graph (DAG) curriculum just-in-time. Instead of hitting the user with a 50-question diagnostic wall, Sabi injects a capped assessment of 5 to 8 diagnostic questions biased specifically toward the foundational root nodes, assigning "Neutral Priors" to unassessed topics.

While learning, users are supervised by the Sabi Socratic AI Tutor. We eliminated multiple-choice quizzes, which reward guessing. Instead, the AI asks probing questions and evaluates free-text replies for semantic mastery.

Behind the scenes, Sabi operates a headless Operations Research (OR) routing engine that evaluates four concurrent variables to pick your next study module:

  1. Prerequisite Eligibility (raw mastery >= 0.70)
  2. Spaced Repetition Priority
  3. Time Fitting (matching your available minutes, e.g., 15 minutes)
  4. Goal Relevance

Finally, Sabi completely decouples course completion from memory retention using a dual-track cognitive architecture. Completion is a discrete milestone, while memory is a continuous vector tracked via the Free Spaced Repetition Scheduler (FSRS) math: [ M(t) = M_0 \times e^{-\lambda t} ] Where lambda is your personalized daily decay rate.

Hence Completing a course does not equal mastery. Mastery is maintained by pratice and repitition

How we built it

We built the core infrastructure using Next.js 15 (App Router, Server Components) and TypeScript for strict type safety across our complex math engine.

For the backend database and authentication, we utilized Supabase PostgreSQL with strict Row Level Security.

The generative AI layer is powered by the Google Gemini API. We used Gemini for high-speed deterministic JSON generation (to build the DAGs), semantic grading, and Socratic tutoring.

The most critical component of the application, the Operations Research routing engine, was built entirely from scratch in pure TypeScript, using the FSRS - a reactive, mathematical algorithm that perfectly feeds into our deterministic Operations Research engine to route your exact path in real-time rather than Ebbinghaus is just a generalized observation about human memory. It executes zero-latency edge computations to traverse the dependency graphs and calculate the multi-dimensional scoring algorithms without blocking the UI.

For the user interface, we utilized Tailwind CSS to build a premium, glassmorphic design system that feels immersive and responsive.

Challenges we ran into

The greatest technical challenge was bridging the probabilistic nature of Generative AI with the strict deterministic requirements of our Operations Research engine. If the AI generated a cyclical loop in the prerequisite graph, the routing algorithm would crash. We had to enforce strict JSON schema validation and acyclic dependency checks to guarantee mathematical safety during curriculum generation.

Being a zero budget project, finding free tools that can do what we want was a challenge, while trying to deal with harsh rate limit and 429 errors. Switched from googlethis to Serpapi due to blocked IP, supabase currently have an email rate of 2 request per hour. Had to use, multiple models of gemini to reduce request on a single model.

Another significant challenge was designing the UX for Spaced Repetition (FSRS). Raw decimals (like a 0.35 mastery score) are unintuitive for users. We had to translate complex forgetting curves into empowering, gamified metrics—presenting memory decay as a clear daily percentage (e.g., 15% / day) and rewarding users with flattened decay curves when they successfully review material after multi-day gaps.

Accomplishments that we're proud of

We are incredibly proud of successfully decoupling discrete course progress from continuous cognitive retention. In traditional platforms, learners get stuck at 99% due to minor mistakes or lose their "completed" badges months later when memory decays. By splitting these into two distinct vectors, we achieved a UX that respects a learner's immediate progress while accurately reflecting the reality of human memory.

We are also proud of our 1-Click Anonymous Demo environment, which allows judges and users to instantly experience the adaptive engine inside isolated PostgreSQL sandboxes without needing to hand over an email address.

We also implemented caching and rate limiting, to quickly find resources and reduce load on our api and models

What we learned

We learned that Generative AI is exponentially more powerful when it is constrained by a deterministic mathematical framework. Sabi is not just an LLM wrapper; the AI serves strictly as a data generator and semantic grader, while traditional computer science (graph traversal and operations research) handles the actual routing decisions.

We also learned a profound lesson in cognitive science: multiple-choice questions give the illusion of learning, but true mastery is only proven when a learner can explain a concept in their own words to a Socratic evaluator.

What's next for Sabi

To support continuous lifelong learning, our next major milestone is scaling our "Automated Follow-Up Curriculum" generation. We want Sabi to completely eliminate educational dead ends. When a user masters a journey, Sabi will synthesize their newly acquired mastery vectors across all domains and automatically calculate the next optimal curriculum to hop onto, turning single courses into an infinite, personalized trajectory.

Built With

Share this project:

Updates

Submission history