Back to Portfolio

AI Study Buddy

$ cat README.md
An AI-powered study companion that helps students learn more effectively through personalized quizzes, flashcards, and study schedules. Features include real-time progress tracking and adaptive learning paths.

Project at a Glance

StudyBuddy is an interactive educational robot that combines AI with physical hardware to create a more engaging learning experience for children. Using ESP32 microcontrollers, OLED displays, and machine learning, it provides personalized learning through speech recognition and adaptive feedback.

Adaptive Learning Speech Recognition Physical Interaction Real-time Feedback Multi-sensory Experience
StudyBuddy Prototype
README.md
source/
assets/
tests/
demo.mp4

StudyBuddy: An Adaptive Educational Robot

Video demonstration showcasing the StudyBuddy's interactive capabilities

Speech Recognition

Understands natural language questions and commands using Vosk for offline processing

Adaptive Learning

Personalizes content based on student performance using Bayesian skill estimation

Physical Interaction

Responds with facial expressions, sounds, and servo-driven movements

Knowledge Base

Accesses facts and educational content through Wikipedia API integration

Project Overview

StudyBuddy uses AI and hardware (ESP32, OLED displays, servos) to create an adaptive educational robot that supports interactive learning for children. It provides real-time feedback through a combination of visual, auditory, and physical responses.

StudyBuddy Prototype Side View

Project Goals:

  • Design an interactive robot that uses AI to personalize lessons in real-time
  • Enhance engagement through speech recognition, motion, and dynamic feedback
  • Bridge the gap between digital and hands-on learning experiences

System Design

StudyBuddy combines hardware components with AI software to create an interactive learning companion:

Hardware Components

  • ESP32: Core microcontroller managing interactions
  • Dual OLED Displays: For facial expressions and text content
  • Servo Motors: Enable physical movements and gestures
  • Speaker: Provides audio feedback and responses
StudyBuddy Internal Components

The software pipeline consists of several key components:

  • Speech Recognition: Vosk for offline speech-to-text processing
  • Natural Language Processing: TinyLlama from Hugging Face Transformers
  • Knowledge Base: Wikipedia API integration for factual information
  • Adaptive Learning: Lightweight Bayesian skill estimation algorithm

Key System Classes:

class ESP32Communicator:
    # Handles communication with ESP32 hardware
    # Controls displays, servos, and audio

class StudyBuddyAI:
    # Main AI companion managing the learning experience
    # Handles speech recognition, response generation

The system tracks student performance and adjusts its approach using a lightweight Bayesian skill estimation method.

# Key adaptive learning algorithm (simplified)
def update_subject_skill(self, subject, topic, correct):
    # Current estimates
    current_skill = self.profile['skills'][subject][topic]
    
    # Bayesian update weights
    surprise_factor = 1.5 if (correct and current_skill < 0.5) or \
                              (not correct and current_skill > 0.5) else 1.0
        
    # Update skill estimate
    if correct:
        new_skill = current_skill + (1 - current_skill) * 0.2 * surprise_factor
    else:
        new_skill = current_skill * (1 - 0.2 * surprise_factor)
        
    # Store updated skill
    self.profile['skills'][subject][topic] = new_skill

This approach enables:

  • Personalized difficulty scaling based on demonstrated skills
  • Targeted practice recommendations focusing on weak areas
  • Learning style adaptation (visual, auditory, kinesthetic)

User Experience

Interaction Flow

  1. Startup: Friendly greeting with animation and sound
  2. Main Menu: Voice command access to learning modes
  3. Learning Activities: Q&A, vocabulary, math, science
  4. Feedback: Multi-sensory responses with expressions, sound, and movement
StudyBuddy Display Interaction
Science Quiz Example:
StudyBuddy: "Let's learn about photosynthesis! This is the process plants use 
to make food using sunlight. Would you like to take a mini-quiz?"

User: "Yes"

StudyBuddy: [Displays a thinking expression]
"Great! Here's your first question: What do plants need for photosynthesis? 
Is it: A) Just water, B) Sunlight, water, and carbon dioxide, or C) Soil only?"

User: "B"

StudyBuddy: [Displays happy expression, servo nods] 
"Correct! Plants need sunlight, water, and carbon dioxide to make their own food 
through photosynthesis. They release oxygen as a byproduct, which we breathe."
Adaptive Math Example:
StudyBuddy: "Based on your previous answers, I'll give you a slightly more 
challenging subtraction problem. What is 43 - 18?"

User: "25"

StudyBuddy: [Displays thinking face]
"Let's check that... I got a different answer. Let me help you work through this.
First, we can subtract 3 - 8, but since 8 is larger than 3, we need to borrow.
40 + 3 becomes 30 + 13. Now 13 - 8 = 5, and 30 - 10 = 20.
So 43 - 18 = 25. You were right! Great job!"

[System updates user's math subtraction skill from 0.65 to 0.71]

User Testing

Testing revealed several key insights:

  • Performance: 88% speech recognition accuracy in quiet environments
  • Engagement: Physical interaction significantly increased student engagement
  • User Feedback: Students requested clearer instructions and more mechanical movements
StudyBuddy User Testing Session

Outcomes & Future Direction

Key Findings:

  • AI-driven personalization significantly enhances student engagement
  • Physical interaction through gestures and expressions improves focus
  • Multimodal feedback makes learning more inclusive and accessible
  1. Hardware Upgrades:
    • Integration of Raspberry Pi 5 for improved local processing
    • More mechanical body design with expanded movement capabilities
    • ESP32 camera module for visual recognition and interaction
  2. Software Enhancements:
    • Emotion recognition through facial and tonal analysis
    • More diverse lesson plans and adaptive content delivery
    • Cloud-AI hybrid approach for balancing performance and privacy
  3. Expanded Capabilities:
    • Multi-language support for diverse educational settings
    • Interactive games and narrative-based learning activities
    • Field testing in classroom environments with diverse learners

Technology Stack

ESP32 OLED Displays Servo Motors Python Vosk TinyLlama Hugging Face Wikipedia API Bayesian Learning 3D Printing