Inspiration

I've always noticed a massive flaw in how we learn today, especially with the rise of AI and EdTech: The Illusion of Competence. We watch a 15-minute 4K animated video on YouTube or read a perfectly formatted ChatGPT summary, and we feel like geniuses. But the moment someone asks us to explain what we just learned, we go completely blank.

Learning has become entirely passive. I realized that true understanding only happens when you are forced to retrieve that information from your own brain. I was inspired by the Feynman Technique—the idea that you don't truly understand something unless you can teach it to someone else in simple terms. I wanted to build an AI that doesn't just give you answers, but acts as a strict mentor that forces you to do the talking.

What it does

Samjho is a voice-first AI tutor built around the "Teach-Back" loop. Instead of just giving you a wall of text to read, the flow goes like this:

  1. You pick a topic (e.g., "Newton's Third Law") and an interest (e.g., "Cricket").
  2. The AI gives you a targeted analogy based on your interest.
  3. The Core Loop: You hit the mic and try to teach the concept back to the AI in your own words.
  4. The Evaluation: The AI evaluates your transcript. If you leave out a crucial detail, it catches the gap, tells you what you missed, and generates a fresh analogy to fix that specific misunderstanding. It will not let you move on until you genuinely understand it.

It also supports native scripts for Hindi, Marathi, Bengali, and Tamil, because elite pedagogy shouldn't just be for English speakers.

How we built it

This was a solo build focused entirely on proving the core loop.

  • Frontend: Built purely with HTML, Vanilla JavaScript, and CSS. No heavy React frameworks. I used GSAP for some animations and Three.js to render the floating interactive orb to give it a futuristic vibe. I hooked into the browser's native Web Speech API for the STT (Speech-to-Text) and TTS (Text-to-Speech).
  • Backend: Vercel Serverless Functions (/api/explain and /api/evaluate) acting as a secure bridge.
  • AI Engine: Powered by Groq's llama-3.3-70b-versatile. I specifically chose Groq because the teach-back loop requires ultra-low latency; if the AI takes 10 seconds to evaluate your voice, the conversational magic dies.
  • Prompt Engineering: I spent hours tuning the prompts so the LLM outputs strict JSON for gap detection, forcing it to look for missing concepts rather than just matching keywords.

Challenges we ran into

To be completely honest with the judges: this is a hackathon prototype, and it's rough around the edges.

  • Browser APIs are finicky: The Web Speech STT API only works reliably on Chrome/Edge. On Firefox or Safari, it outright fails. I had to build a fallback text-input UI just so the app wouldn't completely break for non-Chrome users.
  • Voice Localization: Getting the Text-to-Speech to sound naturally Indian ("desi") was a nightmare. The browser kept defaulting to generic robotic US/UK accents. I had to write custom logic to aggressively hunt through the user's OS for voices with "India" or "IN" tags to make it sound right.
  • Hallucinating Scripts: When I tried to output Marathi or Bengali, the LLM kept trying to write it in Romanized English (Hinglish style). Forcing the model to strictly adhere to Devanagari and native scripts took a lot of prompt tweaking.

Accomplishments that we're proud of

I am incredibly proud that the Gap Detection actually works. It’s so easy to build an AI app that just says "Good job!" to whatever the user says. But when you deliberately give Samjho an incomplete answer, it genuinely catches you. It identifies exactly what part of the concept you missed. Building an evaluating machine is infinitely harder than building an answering machine, and seeing that loop successfully execute in milliseconds is an amazing feeling.

What we learned

I learned that the UI and the polish don't matter if the core pedagogical loop is broken. I spent a lot of time initially worrying about 3D animations and gradients, but I realized none of that mattered if the AI couldn't accurately detect a student's misunderstanding. The hardest part of EdTech isn't the "Tech"; it's the "Ed".

What's next for Samjho: The Feynman AI Tutor

This hackathon submission is just a proof of concept. The product isn't perfectly smooth yet, but the idea is what will change things. The immediate next steps are:

  1. Moving away from browser-dependent Web Speech APIs and integrating a robust cloud STT/TTS (like Whisper or ElevenLabs) so it works flawlessly on any device, especially low-end mobile phones.
  2. Adding a proper database (like Supabase) to track a student's "Knowledge Graph" over time.
  3. Expanding to WhatsApp. The mass audience in India doesn't use web apps; they use WhatsApp. Samjho needs to become an audio-based bot that students can just send voice notes to.

Built With

Share this project:

Updates

Submission history