Skip to content

Add Spaced Repetition System (SRS) and Adaptive Learning #7

@dbsectrainer

Description

@dbsectrainer

🧠 Feature Request: Spaced Repetition System & Adaptive Learning

Problem Statement

Mandarin Pathways currently lacks adaptive learning capabilities and spaced repetition, which are core features of effective language learning platforms like Ninchanese, Skritter, and LingoDeer. Without these systems, learners may not effectively retain vocabulary and characters long-term.

Proposed Features

Spaced Repetition System (SRS)

  • Intelligent Review Scheduling

    • Algorithm-based review intervals (1 day, 3 days, 1 week, 2 weeks, 1 month, etc.)
    • Performance-based interval adjustment (correct answers increase intervals, mistakes reset them)
    • Forgetting curve integration to optimize retention
  • Content Review System

    • Vocabulary Reviews: Chinese characters, pinyin, and meanings
    • Character Writing Reviews: Stroke order and character recognition
    • Pronunciation Reviews: Audio-based repetition with speech recognition integration
    • Grammar Pattern Reviews: Sentence structures and common patterns

Adaptive Learning Engine

  • Personalized Learning Paths

    • AI-driven lesson recommendations based on performance data
    • Difficulty adjustment based on user success rates
    • Weak area identification and targeted practice suggestions
    • Skip ahead options for advanced learners
  • Smart Content Prioritization

    • Focus on frequently missed items
    • Prioritize high-frequency vocabulary and characters
    • Balance new content introduction with review content
    • HSK-level appropriate progression

Technical Implementation

SRS Algorithm Implementation

// Simplified SRS algorithm structure
class SRSCard {
  constructor(content, type) {
    this.content = content; // Character, vocabulary, etc.
    this.type = type; // 'character', 'vocabulary', 'grammar'
    this.level = 1; // SRS level (1-8)
    this.interval = 1; // Days until next review
    this.lastReviewed = new Date();
    this.correctCount = 0;
    this.incorrectCount = 0;
    this.easeFactor = 2.5; // Difficulty multiplier
  }
  
  updateOnReview(correct) {
    this.lastReviewed = new Date();
    if (correct) {
      this.correctCount++;
      this.level = Math.min(this.level + 1, 8);
      this.interval *= this.easeFactor;
    } else {
      this.incorrectCount++;
      this.level = Math.max(1, this.level - 1);
      this.interval = Math.max(1, Math.floor(this.interval * 0.6));
    }
  }
  
  isDueForReview() {
    const daysSinceReview = (new Date() - this.lastReviewed) / (1000 * 60 * 60 * 24);
    return daysSinceReview >= this.interval;
  }
}

Adaptive Learning Logic

class AdaptiveLearning {
  constructor(userProgress) {
    this.userProgress = userProgress;
    this.weakAreas = this.identifyWeakAreas();
  }
  
  getNextLessonRecommendation() {
    const reviewsDue = this.getItemsDueForReview();
    const newContent = this.getRecommendedNewContent();
    
    // Balance 70% reviews, 30% new content
    return {
      reviews: reviewsDue.slice(0, Math.ceil(reviewsDue.length * 0.7)),
      newContent: newContent.slice(0, 5), // Limit new items per session
      focusAreas: this.weakAreas
    };
  }
  
  identifyWeakAreas() {
    // Analyze user performance to identify problem areas
    const performanceData = this.userProgress.getPerformanceByCategory();
    return Object.keys(performanceData)
      .filter(area => performanceData[area].accuracy < 0.7)
      .sort((a, b) => performanceData[a].accuracy - performanceData[b].accuracy);
  }
}

Data Structure & Storage

// localStorage schema for SRS data
{
  srs: {
    cards: {
      "char_你": {
        content: "你",
        type: "character",
        level: 3,
        interval: 7,
        lastReviewed: "2025-01-01T10:00:00Z",
        correctCount: 5,
        incorrectCount: 1,
        easeFactor: 2.6
      }
    },
    reviewQueue: ["char_你", "vocab_hello", "grammar_past_tense"],
    userStats: {
      totalCards: 150,
      masteredCards: 45,
      reviewAccuracy: 0.82,
      averageInterval: 4.2
    }
  }
}

User Interface Components

Review Interface

  • Review Session Dashboard

    • Daily review counter and progress bar
    • Review queue with estimated completion time
    • Performance statistics and streak tracking
  • Card-Based Review System

    • Front: Chinese character/vocabulary
    • Back: Pinyin, definition, example sentence
    • Self-assessment buttons (Again, Hard, Good, Easy)
    • Audio playback for pronunciation practice

Progress Visualization

  • Learning Analytics
    • Retention rate graphs
    • Learning velocity charts
    • Weak area identification dashboard
    • Long-term progress trends

Smart Study Recommendations

  • Daily Study Plan
    • Optimal study time suggestions based on review load
    • Break recommendations for effective learning
    • Difficulty balancing (mix of easy and challenging content)

Integration with Existing Features

Lesson Integration

  • Automatic SRS card creation from completed lessons
  • Character writing practice integrated with SRS reviews
  • Reading comprehension vocabulary added to SRS system

Gamification Integration

  • XP bonuses for maintaining review streaks
  • Achievements for SRS milestones (100 cards mastered, etc.)
  • Level progression tied to SRS performance

Algorithm Customization

  • Multiple SRS Algorithms

    • SM-2 (SuperMemo 2) - classic algorithm
    • Anki-style algorithm with customizable parameters
    • Custom algorithm optimized for Chinese learning
  • User Preferences

    • Adjustable review load (light, normal, intensive)
    • Custom interval multipliers
    • Review session length preferences

Acceptance Criteria

  • Basic SRS algorithm implementation (SM-2 based)
  • Automatic card creation from lesson content
  • Daily review queue system
  • Performance-based interval adjustment
  • Review interface with self-assessment
  • Progress tracking and statistics
  • Integration with character writing practice
  • Vocabulary review system
  • Mobile-responsive review interface
  • Data persistence across browser sessions
  • Export/import functionality for backup

Future Enhancements

  • Machine learning-based personalization
  • Collaborative filtering for content recommendations
  • Cross-device synchronization
  • Advanced analytics and learning insights
  • Integration with HSK preparation goals
  • Community-driven card sharing

Research References

  • Ebbinghaus Forgetting Curve: Optimal review timing research
  • SuperMemo Algorithm: Proven spaced repetition methodology
  • Chinese Learning Studies: Research on character retention and vocabulary acquisition

Priority

High - Spaced repetition is fundamental for long-term language retention and is expected by experienced language learners.


Labels: enhancement, frontend, adaptive-learning, high-priority

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions