Maestro — Intelligent Tutoring System
Maestro is an Intelligent Tutoring System (ITS) built to bridge the gap between simulation-level Reinforcement Learning (RL) and real-world production deployment. It combines cognitive load theories with a non-linear Q-POMDP approximation algorithm to sequence learning topics dynamically while offering natural language conversational hints and Socratic tutoring.
Pedagogical Reinforcement Learning Engine
At the core of Maestro lies a Q-learning policy engine structured around a centralized adaptive score. The score scales dynamically based on the student's progress and content mastery, controlling adaptive parameter scheduling for the exploration rate, discount factor, and learning rate. The reward function balances learning state affect, action suitability, step-wise progress transitions, and response diversity to prevent policy collapse. Updates utilize a dual-update approach, updating specific state-action values and the aggregate topic mastery simultaneously, protected by exponential soft clamping.
Production Optimization & Tech Stack
The client is built using Flutter SDK 3.41.7 and Dart 3.11.5, utilizing Riverpod 2.6.1 for declarative state management and GoRouter 17.2.3 for hash-less URL routing. Content is rendered via Markdown and LaTeX math widgets, and progress is visualized via FL Chart. Backend systems run on Firebase, utilizing Cloud Firestore for real-time NoSQL Q-value matrix persistence.
To minimize LLM costs and latency, Maestro employs five critical optimizations: Context Partitioning (Subject Shield) to isolate chat histories and Q-matrices between subjects; a Semantic Cache & Heuristic Filter (LRU local cache with 4h TTL) to bypass LLM inference for short greetings; a LaTeX Integrity Guard to auto-correct broken formatting strings via regex; Adaptive Context Pruning for token limit compliance; and Safari iOS OOM Prevention, which clamps image caching to 50MB to avoid crashes on iOS devices.
Architecture
The platform uses Flutter for a cross-platform mobile and web frontend, with Firebase as the backend for authentication, real-time database, and cloud functions. The RL policy runs as a cloud function, triggered by user interactions and updating the Q-table incrementally. The LLM agent (accessed via API) provides conversational tutoring support, with carefully designed prompt templates to ensure pedagogical consistency.
Key architectural decisions include: offline-first data synchronization for unreliable network conditions, incremental policy updates to avoid cold-start problems, and a feedback loop that collects user responses to continuously refine the RL reward function.
Impact
Maestro has been registered as a software copyright (HAKI) in Indonesia. A paper describing the hybrid Q-Learning + LLM architecture has been submitted to IEEE ISemantic 2026. The project demonstrated that bridging the simulation-to-production gap requires not just algorithmic improvements, but a holistic approach to system architecture — handling state persistence, network resilience, and user experience design alongside the core AI policy.