{"id":"becb4d36-4694-4b38-b349-d9d62195f582","entityType":"agent","slug":"crewai-rabiul9137-leo-multi-agent-ai-tutor","name":"leo-multi-agent-ai-tutor","canonicalUrl":"https://www.xpersona.co/agent/crewai-rabiul9137-leo-multi-agent-ai-tutor","canonicalPath":"/agent/crewai-rabiul9137-leo-multi-agent-ai-tutor","generatedAt":"2026-10-09T22:35:49.442Z","source":"GITHUB_REPOS","claimStatus":"UNCLAIMED","verificationTier":"NONE","summary":{"evidence":{"source":"editorial-content","verified":true,"confidence":"high","updatedAt":"2026-10-09T11:47:36.420Z","emptyReason":null},"description":"A multi-agent AI tutor built with CrewAI, Groq, Pydantic, and Streamlit. \\# 🦁 Leo — Multi-Agent AI Tutor \\*\\*An AI-powered multi-agent study assistant that coordinates learning, explains concepts, generates quizzes, evaluates student answers, remembers learning progress, and re-teaches weak concepts.\\*\\* Leo is a multi-agent AI tutor built with \\*\\*CrewAI, Groq, Streamlit, Python, and Pydantic\\*\\*. Instead of relying on a single AI prompt, Leo divides the tutoring workflow into specializ","descriptionLabel":"Technical summary","evidenceSummary":"Capability contract not published. No trust telemetry is available yet. Last updated 10/9/2026.","installCommand":null,"sourceUrl":"https://github.com/rabiul9137/leo-multi-agent-ai-tutor","homepage":null,"primaryLinks":[{"label":"View Source","url":"https://github.com/rabiul9137/leo-multi-agent-ai-tutor","kind":"source"}],"safetyScore":66,"overallRank":35,"popularityScore":0,"trustScore":null,"claimedByName":null,"isOwner":false,"seoDescription":"A multi-agent AI tutor built with CrewAI, Groq, Pydantic, and Streamlit. \\# 🦁 Leo — Multi-Agent AI Tutor \\*\\*An AI-powered multi-agent study assistant that coo"},"coverage":{"evidence":{"source":"public-profile","verified":false,"confidence":"medium","updatedAt":"2026-10-09T11:47:36.420Z","emptyReason":null},"protocols":[{"protocol":"OPENCLEW","label":"OpenClaw","status":"self-declared","notes":"Declared in the public agent profile."}],"capabilities":[{"label":"crewai","status":"self-declared"},{"label":"multi-agent","status":"self-declared"}],"verifiedCount":0,"selfDeclaredCount":3,"capabilityMatrix":{"rows":[{"key":"OPENCLEW","type":"protocol","support":"unknown","confidenceSource":"profile","notes":"Listed on profile"},{"key":"crewai","type":"capability","support":"supported","confidenceSource":"profile","notes":"Declared in agent profile metadata"},{"key":"multi-agent","type":"capability","support":"supported","confidenceSource":"profile","notes":"Declared in agent profile metadata"}],"flattenedTokens":"protocol:OPENCLEW|unknown|profile capability:crewai|supported|profile capability:multi-agent|supported|profile"}},"adoption":{"evidence":{"source":"no-adoption-signals","verified":false,"confidence":"low","updatedAt":"2026-10-09T11:47:36.420Z","emptyReason":"No source adoption metrics were available."},"stars":0,"forks":0,"downloads":null,"packageName":null,"latestVersion":null,"tractionLabel":null},"release":{"evidence":{"source":"agent-index","verified":false,"confidence":"medium","updatedAt":"2026-10-09T11:47:36.414Z","emptyReason":null},"lastUpdatedAt":"2026-10-09T11:47:36.420Z","lastCrawledAt":"2026-10-09T11:47:36.414Z","lastIndexedAt":null,"nextCrawlAt":"2026-10-16T11:47:36.414Z","lastVerifiedAt":null,"highlights":[]},"execution":{"evidence":{"source":"GITHUB REPOS","verified":false,"confidence":"low","updatedAt":null,"emptyReason":"No published capability contract is available yet."},"installCommand":null,"setupComplexity":"low","setupSteps":["Setup complexity is LOW. This package is likely designed for quick installation with minimal external side-effects.","Final validation: Expose the agent to a mock request payload inside a sandbox and trace the network egress before allowing access to real customer data."],"contract":{"contractStatus":"missing","authModes":[],"requires":[],"forbidden":[],"supportsMcp":false,"supportsA2a":false,"supportsStreaming":false,"inputSchemaRef":null,"outputSchemaRef":null,"dataRegion":null,"contractUpdatedAt":null,"sourceUpdatedAt":null,"freshnessSeconds":null},"invocationGuide":{"preferredApi":{"snapshotUrl":"https://www.xpersona.co/api/v1/agents/crewai-rabiul9137-leo-multi-agent-ai-tutor/snapshot","contractUrl":"https://www.xpersona.co/api/v1/agents/crewai-rabiul9137-leo-multi-agent-ai-tutor/contract","trustUrl":"https://www.xpersona.co/api/v1/agents/crewai-rabiul9137-leo-multi-agent-ai-tutor/trust"},"curlExamples":["curl -s \"https://www.xpersona.co/api/v1/agents/crewai-rabiul9137-leo-multi-agent-ai-tutor/snapshot\"","curl -s \"https://www.xpersona.co/api/v1/agents/crewai-rabiul9137-leo-multi-agent-ai-tutor/contract\"","curl -s \"https://www.xpersona.co/api/v1/agents/crewai-rabiul9137-leo-multi-agent-ai-tutor/trust\""],"jsonRequestTemplate":{"query":"summarize this repo","constraints":{"maxLatencyMs":2000,"protocolPreference":["OPENCLEW"]}},"jsonResponseTemplate":{"ok":true,"result":{"summary":"...","confidence":0.9},"meta":{"source":"GITHUB_REPOS","generatedAt":"2026-10-09T22:35:49.442Z"}},"retryPolicy":{"maxAttempts":3,"backoffMs":[500,1500,3500],"retryableConditions":["HTTP_429","HTTP_503","NETWORK_TIMEOUT"]}},"endpoints":{"dossierUrl":"https://www.xpersona.co/api/v1/agents/crewai-rabiul9137-leo-multi-agent-ai-tutor/dossier","snapshotUrl":"https://www.xpersona.co/api/v1/agents/crewai-rabiul9137-leo-multi-agent-ai-tutor/snapshot","contractUrl":"https://www.xpersona.co/api/v1/agents/crewai-rabiul9137-leo-multi-agent-ai-tutor/contract","trustUrl":"https://www.xpersona.co/api/v1/agents/crewai-rabiul9137-leo-multi-agent-ai-tutor/trust"}},"reliability":{"evidence":{"source":"runtime-metrics","verified":false,"confidence":"low","updatedAt":null,"emptyReason":"No trust, reliability, or runtime telemetry is available."},"trust":{"status":"unavailable","handshakeStatus":"UNKNOWN","verificationFreshnessHours":null,"reputationScore":null,"p95LatencyMs":null,"successRate30d":null,"fallbackRate":null,"attempts30d":null,"trustUpdatedAt":null,"trustConfidence":"unknown","sourceUpdatedAt":null,"freshnessSeconds":null},"decisionGuardrails":{"doNotUseIf":["Contract metadata is missing or unavailable for deterministic execution."],"safeUseWhen":[],"riskFlags":["missing_or_unavailable_contract","trust_data_unavailable","schema_references_missing"],"operationalConfidence":"low"},"executionMetrics":{"observedLatencyMsP50":null,"observedLatencyMsP95":null,"estimatedCostUsd":null,"uptime30d":null,"rateLimitRpm":null,"rateLimitBurst":null,"lastVerifiedAt":null,"verificationSource":null},"runtimeMetrics":{"successRate":null,"avgLatencyMs":null,"avgCostUsd":null,"hallucinationRate":null,"retryRate":null,"disputeRate":null,"p50Latency":null,"p95Latency":null,"lastUpdated":null}},"benchmarks":{"evidence":{"source":"no-benchmark-data","verified":false,"confidence":"low","updatedAt":null,"emptyReason":"No benchmark suites or observed failure patterns are available."},"suites":[],"failurePatterns":[]},"artifacts":{"evidence":{"source":"GITHUB REPOS","verified":false,"confidence":"high","updatedAt":"2026-10-09T11:47:36.420Z","emptyReason":null},"readme":"\\# 🦁 Leo — Multi-Agent AI Tutor\n\n\n\n> \\*\\*An AI-powered multi-agent study assistant that coordinates learning, explains concepts, generates quizzes, evaluates student answers, remembers learning progress, and re-teaches weak concepts.\\*\\*\n\n\n\nLeo is a multi-agent AI tutor built with \\*\\*CrewAI, Groq, Streamlit, Python, and Pydantic\\*\\*.\n\n\n\nInstead of relying on a single AI prompt, Leo divides the tutoring workflow into specialized agents. Each agent has a specific responsibility and passes its work to the next stage of the learning process.\n\n\n\n\\---\n\n\n\n\\## 🎯 Project Overview\n\n\n\nLeo is designed to simulate a structured tutoring session:\n\n\n\n```text\n\n&#x20;                   ┌─────────────────┐\n\n&#x20;                   │     Student     │\n\n&#x20;                   │ Topic + Level   │\n\n&#x20;                   └────────┬────────┘\n\n&#x20;                            │\n\n&#x20;                            ▼\n\n&#x20;                 ┌───────────────────┐\n\n&#x20;                 │   Coordinator     │\n\n&#x20;                 │ Learning Planner  │\n\n&#x20;                 └─────────┬─────────┘\n\n&#x20;                           │\n\n&#x20;                    Learning Plan\n\n&#x20;                           │\n\n&#x20;                           ▼\n\n&#x20;                 ┌───────────────────┐\n\n&#x20;                 │     Explainer     │\n\n&#x20;                 │   Concept Teacher │\n\n&#x20;                 └─────────┬─────────┘\n\n&#x20;                           │\n\n&#x20;                      Lesson Content\n\n&#x20;                           │\n\n&#x20;                           ▼\n\n&#x20;                 ┌───────────────────┐\n\n&#x20;                 │    Quiz Master    │\n\n&#x20;                 │  Quiz Generator   │\n\n&#x20;                 └─────────┬─────────┘\n\n&#x20;                           │\n\n&#x20;                      Quiz Questions\n\n&#x20;                           │\n\n&#x20;                           ▼\n\n&#x20;                   ┌───────────────┐\n\n&#x20;                   │    Student    │\n\n&#x20;                   │ Answers Quiz  │\n\n&#x20;                   └───────┬───────┘\n\n&#x20;                           │\n\n&#x20;                           ▼\n\n&#x20;                 ┌───────────────────┐\n\n&#x20;                 │     Evaluator     │\n\n&#x20;                 │ Answer Assessment │\n\n&#x20;                 └─────────┬─────────┘\n\n&#x20;                           │\n\n&#x20;                      Evaluation\n\n&#x20;                           │\n\n&#x20;                           ▼\n\n&#x20;                ┌─────────────────────┐\n\n&#x20;                │   Feedback Loop     │\n\n&#x20;                │ Weak Concept Check  │\n\n&#x20;                └──────────┬──────────┘\n\n&#x20;                           │\n\n&#x20;                    Weak concepts?\n\n&#x20;                      /           \\\\\n\n&#x20;                    Yes            No\n\n&#x20;                     │              │\n\n&#x20;                     ▼              ▼\n\n&#x20;             ┌──────────────┐    Finish\n\n&#x20;             │  Explainer   │\n\n&#x20;             │ Re-teaching  │\n\n&#x20;             └──────────────┘\n\n```\n\n\n\n\\---\n\n\n\n\\# ✨ Key Features\n\n\n\n\\- 🤖 \\*\\*4 specialized AI agents\\*\\*\n\n\\- 🧭 Coordinator-based learning planning\n\n\\- 📚 Adaptive concept explanation\n\n\\- 📝 Automatically generated 3-question quizzes\n\n\\- 📊 Structured answer evaluation\n\n\\- 🧠 Persistent student memory\n\n\\- 🔄 Automatic feedback loop\n\n\\- 🔁 Re-teaching of weak concepts\n\n\\- 🖥️ Streamlit interactive interface\n\n\\- 🧩 Sequential multi-agent orchestration with CrewAI\n\n\\- ✅ Pydantic validation for quiz and evaluation outputs\n\n\\- 🔐 Environment-variable based API key management\n\n\\- 🛡️ Error handling for rate limits, authentication errors, and timeouts\n\n\n\n\\---\n\n\n\n\\# 🤖 Multi-Agent Architecture\n\n\n\nLeo contains four specialized agents.\n\n\n\n\\## 1. 🧭 Coordinator\n\n\n\n\\*\\*Role:\\*\\* Learning Coordinator\n\n\n\n\\### Responsibilities\n\n\n\nThe Coordinator:\n\n\n\n\\- Understands the student's topic\n\n\\- Considers the student's learning level\n\n\\- Creates a short learning plan\n\n\\- Determines the teaching sequence\n\n\\- Identifies the concepts that should receive quiz focus\n\n\n\nThe Coordinator \\*\\*does not teach the topic directly\\*\\*.\n\n\n\n\\### Example\n\n\n\n```text\n\nStudent:\n\n\"I want to learn Python OOP.\"\n\n\n\nLevel:\n\nBeginner\n\n\n\nCoordinator:\n\n\\- Classes and objects\n\n\\- Encapsulation\n\n\\- Inheritance\n\n\\- Polymorphism\n\n\\- Quiz focus on fundamental concepts\n\n```\n\n\n\n\\---\n\n\n\n\\## 2. 📚 Explainer\n\n\n\n\\*\\*Role:\\*\\* Concept Explainer\n\n\n\n\\### Responsibilities\n\n\n\nThe Explainer:\n\n\n\n\\- Receives the Coordinator's learning plan\n\n\\- Teaches the requested topic\n\n\\- Adapts explanations to the student's level\n\n\\- Uses simple explanations\n\n\\- Provides examples\n\n\\- Prepares the student for the quiz\n\n\n\nThe Explainer receives the Coordinator's output as task context.\n\n\n\n```text\n\nCoordinator\n\n&#x20;    │\n\n&#x20;    │ Learning Plan\n\n&#x20;    ▼\n\nExplainer\n\n&#x20;    │\n\n&#x20;    │ Lesson\n\n&#x20;    ▼\n\nQuiz Master\n\n```\n\n\n\n\\---\n\n\n\n\\## 3. 📝 Quiz Master\n\n\n\n\\*\\*Role:\\*\\* Quiz Master\n\n\n\n\\### Responsibilities\n\n\n\nThe Quiz Master:\n\n\n\n\\- Receives the Explainer's lesson\n\n\\- Creates a quiz based on the taught concepts\n\n\\- Generates exactly 3 questions\n\n\\- Provides 4 options per question\n\n\\- Provides the correct answer\n\n\\- Provides an explanation\n\n\\- Assigns difficulty\n\n\n\nThe quiz output is validated using \\*\\*Pydantic\\*\\*.\n\n\n\n\\### Quiz structure\n\n\n\n```json\n\n{\n\n&#x20; \"topic\": \"Python OOP\",\n\n&#x20; \"questions\": \\[\n\n&#x20;   {\n\n&#x20;     \"question\": \"Question text\",\n\n&#x20;     \"options\": \\[\n\n&#x20;       \"Option 1\",\n\n&#x20;       \"Option 2\",\n\n&#x20;       \"Option 3\",\n\n&#x20;       \"Option 4\"\n\n&#x20;     ],\n\n&#x20;     \"correct\\_answer\": \"Option 1\",\n\n&#x20;     \"explanation\": \"Short explanation\",\n\n&#x20;     \"difficulty\": \"Easy\"\n\n&#x20;   }\n\n&#x20; ]\n\n}\n\n```\n\n\n\nThe project validates that:\n\n\n\n\\- There are exactly 3 questions\n\n\\- Each question has exactly 4 options\n\n\\- `correct\\_answer` exactly matches one of the options\n\n\n\n\\---\n\n\n\n\\## 4. 📊 Evaluator\n\n\n\n\\*\\*Role:\\*\\* Student Evaluator\n\n\n\n\\### Responsibilities\n\n\n\nThe Evaluator:\n\n\n\n\\- Receives the generated quiz\n\n\\- Receives the student's answers\n\n\\- Compares answers with the correct answers\n\n\\- Calculates the score\n\n\\- Calculates the percentage\n\n\\- Identifies weak concepts\n\n\\- Provides question-level feedback\n\n\\- Provides overall feedback\n\n\n\nThe evaluation output is also validated using \\*\\*Pydantic\\*\\*.\n\n\n\nExample:\n\n\n\n```text\n\nScore: 1/3\n\n\n\nPercentage: 33.33%\n\n\n\nWeak Concepts:\n\n\\- Class definition\n\n\\- Polymorphism\n\n\n\nFeedback:\n\nFocus on understanding class structures\n\nand polymorphism.\n\n```\n\n\n\n\\---\n\n\n\n\\# 🔄 Agent Handoff\n\n\n\nOne of the main goals of this project is to demonstrate that the agents are not isolated AI prompts.\n\n\n\nThe workflow passes information between agents.\n\n\n\n\\### Phase 1\n\n\n\n```text\n\nCoordinator\n\n&#x20;   │\n\n&#x20;   │ coordinator\\_task output\n\n&#x20;   ▼\n\nExplainer\n\n&#x20;   │\n\n&#x20;   │ explanation\\_task output\n\n&#x20;   ▼\n\nQuiz Master\n\n&#x20;   │\n\n&#x20;   │ quiz output\n\n&#x20;   ▼\n\nStudent\n\n```\n\n\n\n\\### Phase 2\n\n\n\n```text\n\nStudent Answers\n\n&#x20;      │\n\n&#x20;      ▼\n\nEvaluator\n\n```\n\n\n\n\\### Phase 3 — Feedback Loop\n\n\n\n```text\n\nEvaluator\n\n&#x20;   │\n\n&#x20;   │ weak concepts\n\n&#x20;   ▼\n\nFeedback Loop\n\n&#x20;   │\n\n&#x20;   ▼\n\nExplainer\n\n&#x20;   │\n\n&#x20;   │ re-teaching lesson\n\n&#x20;   ▼\n\nStudent\n\n```\n\n\n\nThis creates a complete learning cycle rather than independent agent responses.\n\n\n\n\\---\n\n\n\n\\# 🔁 Feedback Loop\n\n\n\nLeo includes a feedback loop for students who struggle with the quiz.\n\n\n\nAfter evaluation, Leo checks:\n\n\n\n```text\n\nAre there weak concepts?\n\n&#x20;       │\n\n&#x20;      Yes\n\n&#x20;       │\n\n&#x20;       ▼\n\nCreate re-teaching prompt\n\n&#x20;       │\n\n&#x20;       ▼\n\nExplainer re-teaches weak concepts\n\n&#x20;       │\n\n&#x20;       ▼\n\nStudent receives targeted practice\n\n```\n\n\n\nThe feedback system considers both:\n\n\n\n\\- Weak concepts\n\n\\- Quiz percentage\n\n\n\nThe current implementation triggers additional practice when weak concepts are detected or the score percentage is below the defined threshold.\n\n\n\n\\---\n\n\n\n\\# 🧠 Student Memory\n\n\n\nLeo maintains persistent student learning information in:\n\n\n\n```text\n\ndata/student\\_memory.json\n\n```\n\n\n\nThe memory system can store:\n\n\n\n```json\n\n{\n\n&#x20;   \"student\\_name\": \"\",\n\n&#x20;   \"student\\_level\": \"Beginner\",\n\n&#x20;   \"topics\": \\[],\n\n&#x20;   \"quiz\\_scores\": \\[],\n\n&#x20;   \"weak\\_concepts\": \\[]\n\n}\n\n```\n\n\n\nLeo can remember:\n\n\n\n\\- Student name\n\n\\- Learning level\n\n\\- Previously studied topics\n\n\\- Quiz scores\n\n\\- Weak concepts\n\n\n\nThe local memory file is intentionally excluded from Git because it contains user/session data.\n\n\n\n\\---\n\n\n\n\\# 🖥️ User Interface\n\n\n\nLeo uses \\*\\*Streamlit\\*\\* for the interactive interface.\n\n\n\nThe application provides a complete learning session:\n\n\n\n\\### Phase 1 — Start Learning\n\n\n\nThe student provides:\n\n\n\n\\- Name\n\n\\- Learning level\n\n\\- Topic\n\n\n\nExample:\n\n\n\n```text\n\nStudent Name: Rabiul\n\n\n\nLearning Level: Beginner\n\n\n\nTopic: Python OOP\n\n```\n\n\n\n\\---\n\n\n\n\\### Phase 2 — Quiz\n\n\n\nLeo displays the generated questions and answer options.\n\n\n\n```text\n\nQuestion 1:\n\nWhat is a class in Object-Oriented Programming?\n\n\n\n○ Blueprint for objects\n\n○ Instance of an object\n\n○ Method to hide data\n\n○ Interface for abstraction\n\n```\n\n\n\n\\---\n\n\n\n\\### Phase 3 — Evaluation\n\n\n\nThe student submits answers and Leo displays:\n\n\n\n\\- Score\n\n\\- Percentage\n\n\\- Status\n\n\\- Overall feedback\n\n\\- Question-level results\n\n\\- Weak concepts\n\n\n\n\\---\n\n\n\n\\### Phase 4 — Feedback Loop\n\n\n\nIf the student needs additional practice, Leo generates a focused re-teaching lesson.\n\n\n\n\\---\n\n\n\n\\# 🛠️ Technology Stack\n\n\n\n| Technology | Purpose |\n\n|---|---|\n\n| Python | Core programming language |\n\n| CrewAI | Multi-agent orchestration |\n\n| Groq | LLM inference |\n\n| OpenAI-compatible GPT-OSS model | Language model |\n\n| Streamlit | Web interface |\n\n| Pydantic | Structured output validation |\n\n| python-dotenv | Environment configuration |\n\n| JSON | Local student memory |\n\n| Git | Version control |\n\n\n\n\\---\n\n\n\n\\# 🏗️ Project Structure\n\n\n\n```text\n\nleo-multi-agent-ai-tutor/\n\n│\n\n├── app.py\n\n├── requirements.txt\n\n├── .env.example\n\n├── .gitignore\n\n│\n\n├── data/\n\n│   └── student\\_memory.json\n\n│\n\n├── src/\n\n│   │\n\n│   ├── agents/\n\n│   │   ├── coordinator.py\n\n│   │   ├── explainer.py\n\n│   │   ├── quiz\\_master.py\n\n│   │   └── evaluator.py\n\n│   │\n\n│   ├── crew/\n\n│   │   ├── tutor\\_crew.py\n\n│   │   └── feedback\\_loop.py\n\n│   │\n\n│   ├── tasks/\n\n│   │   ├── coordinator\\_task.py\n\n│   │   ├── explanation\\_task.py\n\n│   │   ├── quiz\\_task.py\n\n│   │   ├── quiz\\_schema.py\n\n│   │   ├── evaluation\\_task.py\n\n│   │   ├── evaluation\\_schema.py\n\n│   │   └── reteaching\\_task.py\n\n│   │\n\n│   ├── memory/\n\n│   │   └── student\\_memory.py\n\n│   │\n\n│   ├── llm.py\n\n│   ├── error\\_handler.py\n\n│   └── feedback\\_loop.py\n\n│\n\n├── test\\_crew.py\n\n├── test\\_error\\_handler.py\n\n├── test\\_evaluation\\_schema.py\n\n├── test\\_feedback\\_loop.py\n\n├── test\\_llm.py\n\n├── test\\_memory.py\n\n└── test\\_quiz\\_schema.py\n\n```\n\n\n\n\\---\n\n\n\n\\# 🔧 Orchestration Pattern\n\n\n\nLeo uses \\*\\*sequential orchestration\\*\\* with CrewAI.\n\n\n\nThe first learning crew follows:\n\n\n\n```text\n\nCoordinator Task\n\n&#x20;      ↓\n\nExplanation Task\n\n&#x20;      ↓\n\nQuiz Task\n\n```\n\n\n\nThe explanation task receives the Coordinator task as context:\n\n\n\n```text\n\nCoordinator → Explainer\n\n```\n\n\n\nThe quiz task receives the Explanation task as context:\n\n\n\n```text\n\nExplainer → Quiz Master\n\n```\n\n\n\nEvaluation is handled as a second stage:\n\n\n\n```text\n\nQuiz\n\n&#x20;↓\n\nStudent Answers\n\n&#x20;↓\n\nEvaluator\n\n```\n\n\n\nRe-teaching is handled as a third stage:\n\n\n\n```text\n\nEvaluation\n\n&#x20;↓\n\nWeak Concepts\n\n&#x20;↓\n\nExplainer\n\n```\n\n\n\nThis design keeps each stage focused on a specific responsibility.\n\n\n\n\\---\n\n\n\n\\# ⚙️ Installation\n\n\n\n\\## 1. Clone the repository\n\n\n\n```bash\n\ngit clone <YOUR\\_GITHUB\\_REPOSITORY\\_URL>\n\ncd leo-multi-agent-ai-tutor\n\n```\n\n\n\n\\---\n\n\n\n\\## 2. Create a virtual environment\n\n\n\n```bash\n\npython -m venv venv\n\n```\n\n\n\nActivate it on Windows:\n\n\n\n```cmd\n\nvenv\\\\Scripts\\\\activate\n\n```\n\n\n\n\\---\n\n\n\n\\## 3. Install dependencies\n\n\n\n```bash\n\npip install -r requirements.txt\n\n```\n\n\n\n\\---\n\n\n\n\\# 🔑 Environment Configuration\n\n\n\nCreate a `.env` file in the project root.\n\n\n\n```text\n\nGROQ\\_API\\_KEY=your\\_groq\\_api\\_key\\_here\n\n```\n\n\n\nA safe example is already provided:\n\n\n\n```text\n\n.env.example\n\n```\n\n\n\n\\### Important\n\n\n\nNever commit the real `.env` file.\n\n\n\nThe repository's `.gitignore` excludes:\n\n\n\n```text\n\n.env\n\nvenv/\n\ndata/student\\_memory.json\n\n```\n\n\n\n\\---\n\n\n\n\\# ▶️ Run Leo\n\n\n\nStart the Streamlit application:\n\n\n\n```bash\n\nstreamlit run app.py\n\n```\n\n\n\nStreamlit will provide a local URL, usually:\n\n\n\n```text\n\nhttp://localhost:8501\n\n```\n\n\n\nOpen the URL in your browser.\n\n\n\n\\---\n\n\n\n\\# 🧪 Testing\n\n\n\nThe project includes tests for important components.\n\n\n\nRun the test files individually, for example:\n\n\n\n```bash\n\npython test\\_memory.py\n\n```\n\n\n\n```bash\n\npython test\\_quiz\\_schema.py\n\n```\n\n\n\n```bash\n\npython test\\_evaluation\\_schema.py\n\n```\n\n\n\n```bash\n\npython test\\_feedback\\_loop.py\n\n```\n\n\n\n```bash\n\npython test\\_error\\_handler.py\n\n```\n\n\n\nThe project also includes:\n\n\n\n```text\n\ntest\\_crew.py\n\ntest\\_llm.py\n\n```\n\n\n\nfor checking the CrewAI workflow and LLM configuration.\n\n\n\n\\---\n\n\n\n\\# 🛡️ Error Handling\n\n\n\nLeo includes basic error handling for common AI-service failures.\n\n\n\nThe application provides user-friendly messages for:\n\n\n\n\\### Rate limits\n\n\n\n```text\n\nLeo is temporarily busy because the AI service\n\nhas reached its request limit.\n\n```\n\n\n\n\\### Authentication/API key problems\n\n\n\n```text\n\nLeo could not connect to the AI service.\n\nPlease check the API configuration.\n\n```\n\n\n\n\\### Timeout problems\n\n\n\n```text\n\nLeo's AI service took too long to respond.\n\nPlease try again.\n\n```\n\n\n\n\\### Other temporary failures\n\n\n\n```text\n\nLeo encountered a temporary problem while\n\nprocessing your request.\n\n```\n\n\n\nThis prevents raw technical errors from being the only feedback shown to users.\n\n\n\n\\---\n\n\n\n\\# 📋 Example Learning Session\n\n\n\n\\### Student Input\n\n\n\n```text\n\nName: Rabiul\n\nLevel: Beginner\n\nTopic: Python OOP\n\n```\n\n\n\n\\### Coordinator\n\n\n\n```text\n\nLearning Plan:\n\n1\\. Classes and objects\n\n2\\. Encapsulation\n\n3\\. Inheritance\n\n4\\. Polymorphism\n\n```\n\n\n\n\\### Explainer\n\n\n\nLeo teaches the selected concepts using simple explanations and examples.\n\n\n\n\\### Quiz Master\n\n\n\nLeo creates:\n\n\n\n```text\n\n3 Questions\n\n4 Options Each\n\nEasy → Medium → Hard\n\n```\n\n\n\n\\### Student\n\n\n\nSubmits answers.\n\n\n\n\\### Evaluator\n\n\n\nExample result:\n\n\n\n```text\n\nScore: 1/3\n\nPercentage: 33.33%\n\n\n\nWeak Concepts:\n\n\\- Class definition\n\n\\- Polymorphism\n\n```\n\n\n\n\\### Feedback Loop\n\n\n\nLeo generates a focused lesson:\n\n\n\n```text\n\nRe-teaching:\n\n\\- Class Definition\n\n\\- Polymorphism\n\n\n\nIncludes:\n\n\\- Simple explanations\n\n\\- Examples\n\n\\- Common mistakes\n\n\\- Practice exercise\n\n```\n\n\n\n\\---\n\n\n\n\\# 🎓 Learning Design\n\n\n\nLeo follows a simple instructional cycle:\n\n\n\n```text\n\nPlan\n\n&#x20;↓\n\nTeach\n\n&#x20;↓\n\nPractice\n\n&#x20;↓\n\nEvaluate\n\n&#x20;↓\n\nIdentify Weakness\n\n&#x20;↓\n\nRe-teach\n\n```\n\n\n\nThis allows the system to move beyond simple question-answering and provide a structured learning experience.\n\n\n\n\\---\n\n\n\n\\# 🔐 Security\n\n\n\nAPI credentials are loaded from environment variables.\n\n\n\nThe actual API key should be stored in:\n\n\n\n```text\n\n.env\n\n```\n\n\n\nand never directly inside Python source code.\n\n\n\nThe repository provides:\n\n\n\n```text\n\n.env.example\n\n```\n\n\n\nfor configuration guidance.\n\n\n\n\\### Never commit:\n\n\n\n```text\n\n.env\n\n```\n\n\n\nor any file containing your real API key.\n\n\n\n\\---\n\n\n\n\\# 🚀 Future Improvements\n\n\n\nPotential future improvements include:\n\n\n\n\\- More adaptive learning plans\n\n\\- Larger quiz generation\n\n\\- Automatic second quiz after re-teaching\n\n\\- More persistent student profiles\n\n\\- Vector database-based learning memory\n\n\\- Retrieval-Augmented Generation (RAG)\n\n\\- Subject-specific knowledge bases\n\n\\- More advanced progress analytics\n\n\\- Human-in-the-loop tutoring\n\n\\- Voice-based interaction\n\n\\- Multiple LLM/provider support\n\n\\- Improved agent observability\n\n\\- Deployment to a cloud platform\n\n\n\n\\---\n\n\n\n\\# 📹 Demo Video Flow\n\n\n\nA recommended demonstration sequence for the project:\n\n\n\n\\### 1. Introduction\n\n\n\nShow:\n\n\n\n```text\n\nLeo — Multi-Agent AI Tutor\n\n```\n\n\n\nBriefly explain that Leo uses multiple specialized AI agents.\n\n\n\n\\### 2. Student Input\n\n\n\nEnter:\n\n\n\n```text\n\nName: Rabiul\n\nLevel: Beginner\n\nTopic: Python OOP\n\n```\n\n\n\n\\### 3. Coordinator\n\n\n\nShow the learning plan.\n\n\n\n\\### 4. Explainer\n\n\n\nShow the concept explanation.\n\n\n\n\\### 5. Quiz Master\n\n\n\nShow the generated 3-question quiz.\n\n\n\n\\### 6. Student Answers\n\n\n\nSubmit a mixture of correct and incorrect answers.\n\n\n\n\\### 7. Evaluator\n\n\n\nShow:\n\n\n\n```text\n\nScore\n\nPercentage\n\nQuestion Results\n\nWeak Concepts\n\nFeedback\n\n```\n\n\n\n\\### 8. Feedback Loop\n\n\n\nShow Leo detecting weak concepts and generating targeted re-teaching.\n\n\n\n\\### 9. Memory\n\n\n\nShow that the student's learning information can be persisted locally.\n\n\n\n\\---\n\n\n\n\\# 📌 Assignment Requirements Coverage\n\n\n\n| Requirement | Implementation |\n\n|---|---|\n\n| Multi-agent system | ✅ 4 specialized agents |\n\n| Coordinator | ✅ Learning Coordinator |\n\n| Explainer | ✅ Concept Explainer |\n\n| Quiz Master | ✅ Quiz Master |\n\n| Evaluator | ✅ Student Evaluator |\n\n| Agent handoffs | ✅ Task context passing |\n\n| Orchestration | ✅ CrewAI Sequential Process |\n\n| Structured output | ✅ Pydantic validation |\n\n| Memory | ✅ JSON student memory |\n\n| Error handling | ✅ Request validation + error formatting |\n\n| Interface | ✅ Streamlit |\n\n| Feedback loop | ✅ Weak concept re-teaching |\n\n| Environment security | ✅ `.env` + `.env.example` |\n\n| Tests | ✅ Component test files |\n\n| Documentation | ✅ This README |\n\n\n\n\\---\n\n\n\n\\# 🧩 Design Principles\n\n\n\nLeo follows several core design principles:\n\n\n\n\\### Single Responsibility\n\n\n\nEach agent has a specific role.\n\n\n\n```text\n\nCoordinator → Plan\n\nExplainer   → Teach\n\nQuiz Master → Assess\n\nEvaluator   → Evaluate\n\n```\n\n\n\n\\### Context Passing\n\n\n\nAgents receive relevant outputs from previous stages rather than independently generating unrelated responses.\n\n\n\n\\### Structured Data\n\n\n\nQuiz and evaluation results are validated using Pydantic models.\n\n\n\n\\### Feedback-Driven Learning\n\n\n\nThe system identifies weak concepts and can send the student back to a targeted teaching stage.\n\n\n\n\\### Secure Configuration\n\n\n\nSensitive credentials are separated from source code.\n\n\n\n\\---\n\n\n\n\\# 👨‍💻 Author\n\n\n\n\\*\\*Rabiul Islam\\*\\*\n\n\n\nAI/ML Developer focused on:\n\n\n\n\\- Artificial Intelligence\n\n\\- Machine Learning\n\n\\- Generative AI\n\n\\- Computer Vision\n\n\\- AI Agents\n\n\\- Intelligent Automation\n\n\n\nGitHub:\n\n\n\n```text\n\nhttps://github.com/rabiul9137\n\n```\n\n\n\n\\---\n\n\n\n\\# 📄 License\n\n\n\nThis project is created for educational, portfolio, and demonstration purposes.\n\n\n\nAdd an appropriate open-source license before distributing the project publicly if required.\n\n\n\n\\---\n\n\n\n\\## ⭐ Project Summary\n\n\n\n\\*\\*Leo is a multi-agent AI tutor that demonstrates how specialized AI agents can collaborate to create a complete learning workflow.\\*\\*\n\n\n\nInstead of using one general-purpose agent, Leo separates tutoring into:\n\n\n\n```text\n\n🧭 Coordinate\n\n&#x20;    ↓\n\n📚 Explain\n\n&#x20;    ↓\n\n📝 Quiz\n\n&#x20;    ↓\n\n📊 Evaluate\n\n&#x20;    ↓\n\n🔄 Re-teach\n\n```\n\n\n\nThe project demonstrates practical concepts in:\n\n\n\n\\*\\*Multi-Agent AI + LLM Orchestration + Structured Outputs + Memory + Feedback Loops + Streamlit\\*\\*\n\n\n\n\\---\n\n\n\n\\*\\*Built with Python, CrewAI, Groq, Pydantic, and Streamlit.\\*\\*\n\n","readmeExcerpt":"\\# 🦁 Leo — Multi-Agent AI Tutor \\*\\*An AI-powered multi-agent study assistant that coordinates learning, explains concepts, generates quizzes, evaluates student answers, remembers learning progress, and re-teaches weak concepts.\\*\\* Leo is a multi-agent AI tutor built with \\*\\*CrewAI, Groq, Streamlit, Python, and Pydantic\\*\\*. Instead of relying on a single AI prompt, Leo divides the tutoring workflow into specializ","codeSnippets":[],"executableExamples":[{"language":"text","snippet":"&#x20;                   ┌─────────────────┐\n\n&#x20;                   │     Student     │\n\n&#x20;                   │ Topic + Level   │\n\n&#x20;                   └────────┬────────┘\n\n&#x20;                            │\n\n&#x20;                            ▼\n\n&#x20;                 ┌───────────────────┐\n\n&#x20;                 │   Coordinator     │\n\n&#x20;                 │ Learning Planner  │\n\n&#x20;                 └─────────┬─────────┘\n\n&#x20;                           │\n\n&#x20;                    Learning Plan\n\n&#x20;                           │\n\n&#x20;                           ▼\n\n&#x20;                 ┌───────────────────┐\n\n&#x20;                 │     Explainer     │\n\n&#x20;                 │   Concept Teacher │\n\n&#x20;                 └─────────┬─────────┘\n\n&#x20;                           │\n\n&#x20;                      Lesson Content\n\n&#x20;                           │\n\n&#x20;                           ▼\n\n&#x20;                 ┌───────────────────┐\n\n&#x20;                 │    Quiz Master    │\n\n&#x20;                 │  Quiz Generator   │\n\n&#x20;                 └─────────┬─────────┘\n\n&#x20;                           │\n\n&#x20;                      Quiz Questions\n\n&#x20;                           │\n\n&#x20;                           ▼\n\n&#x20;                   ┌───────────────┐\n\n&#x20;                   │    Student    │\n\n&#x20;                   │ Answers Quiz  │\n\n&#x20;                   └───────┬───────┘\n\n&#x20;                           │\n\n&#x20;                           ▼\n\n&#x20;                 ┌───────────────────┐\n\n&#x20;                 │     Evaluator     │\n\n&#x20;                 │ Answer Assessment │\n\n&#x20;                 └─────────┬─────────┘\n\n&#x20;                           │\n\n&#x20;                      Evaluation\n\n&#x20;                           │\n\n&#x20;                           ▼\n\n&#x20;                ┌─────────────────────┐\n\n&#x20;                │   Feedback Loop     │\n\n&#x20;                │ Weak Concept Check  │\n\n&#x20;          "},{"language":"text","snippet":"Student:\n\n\"I want to learn Python OOP.\"\n\n\n\nLevel:\n\nBeginner\n\n\n\nCoordinator:\n\n\\- Classes and objects\n\n\\- Encapsulation\n\n\\- Inheritance\n\n\\- Polymorphism\n\n\\- Quiz focus on fundamental concepts"},{"language":"text","snippet":"Coordinator\n\n&#x20;    │\n\n&#x20;    │ Learning Plan\n\n&#x20;    ▼\n\nExplainer\n\n&#x20;    │\n\n&#x20;    │ Lesson\n\n&#x20;    ▼\n\nQuiz Master"},{"language":"json","snippet":"{\n\n&#x20; \"topic\": \"Python OOP\",\n\n&#x20; \"questions\": \\[\n\n&#x20;   {\n\n&#x20;     \"question\": \"Question text\",\n\n&#x20;     \"options\": \\[\n\n&#x20;       \"Option 1\",\n\n&#x20;       \"Option 2\",\n\n&#x20;       \"Option 3\",\n\n&#x20;       \"Option 4\"\n\n&#x20;     ],\n\n&#x20;     \"correct\\_answer\": \"Option 1\",\n\n&#x20;     \"explanation\": \"Short explanation\",\n\n&#x20;     \"difficulty\": \"Easy\"\n\n&#x20;   }\n\n&#x20; ]\n\n}"},{"language":"text","snippet":"Score: 1/3\n\n\n\nPercentage: 33.33%\n\n\n\nWeak Concepts:\n\n\\- Class definition\n\n\\- Polymorphism\n\n\n\nFeedback:\n\nFocus on understanding class structures\n\nand polymorphism."},{"language":"text","snippet":"Coordinator\n\n&#x20;   │\n\n&#x20;   │ coordinator\\_task output\n\n&#x20;   ▼\n\nExplainer\n\n&#x20;   │\n\n&#x20;   │ explanation\\_task output\n\n&#x20;   ▼\n\nQuiz Master\n\n&#x20;   │\n\n&#x20;   │ quiz output\n\n&#x20;   ▼\n\nStudent"}],"parameters":null,"dependencies":[],"permissions":[],"extractedFiles":[],"languages":["python"],"docsSourceLabel":"GITHUB REPOS","editorialOverview":"A multi-agent AI tutor built with CrewAI, Groq, Pydantic, and Streamlit. \\# 🦁 Leo — Multi-Agent AI Tutor \\*\\*An AI-powered multi-agent study assistant that coordinates learning, explains concepts, generates quizzes, evaluates student answers, remembers learning progress, and re-teaches weak concepts.\\*\\* Leo is a multi-agent AI tutor built with \\*\\*CrewAI, Groq, Streamlit, Python, and Pydantic\\*\\*. Instead of relying on a single AI prompt, Leo divides the tutoring workflow into specializ","editorialQuality":{"score":100,"threshold":65,"status":"ready","wordCount":405,"uniquenessScore":61,"reasons":[]}},"media":{"evidence":{"source":"no-media","verified":false,"confidence":"low","updatedAt":"2026-10-09T11:47:36.420Z","emptyReason":"No screenshots, media assets, or demo links are available."},"primaryImageUrl":null,"mediaAssetCount":0,"assets":[],"demoUrl":null},"ownerResources":{"evidence":{"source":"unclaimed","verified":false,"confidence":"low","updatedAt":"2026-10-09T11:47:36.420Z","emptyReason":"This page has not been claimed by the agent owner."},"hasCustomPage":false,"customPageUpdatedAt":null,"customLinks":[],"structuredLinks":{"docsUrl":null,"demoUrl":null,"supportUrl":null,"pricingUrl":null,"statusUrl":null},"customPage":null},"relatedAgents":{"evidence":{"source":"protocol-neighbors","verified":false,"confidence":"medium","updatedAt":"2026-10-09T22:35:49.442Z","emptyReason":null},"items":[{"id":"8ebccd8e-3863-4187-8355-c3f14e1f9edf","entityType":"agent","canonicalPath":"/agent/iofficeai-aionui","slug":"iofficeai-aionui","name":"AionUi","description":"Free, local, open-source 24/7 Cowork app and OpenClaw for Gemini CLI, Claude Code, Codex, OpenCode, Qwen Code, Goose CLI, Auggie, and more | 🌟 Star if you like it!","url":"https://github.com/iOfficeAI/AionUi","homepage":"https://www.aionui.com","source":"GITHUB_REPOS","protocols":["MCP","OPENCLAW"],"capabilities":[],"safetyScore":100,"overallRank":70,"updatedAt":"2026-10-09T19:11:12.944Z","createdAt":"2026-02-25T03:38:16.584Z","downloads":null},{"id":"b917f68a-ebff-438e-84f8-3f4b2494c0bc","entityType":"agent","canonicalPath":"/agent/activepieces-activepieces","slug":"activepieces-activepieces","name":"activepieces","description":"AI Agents & MCPs & AI Workflow Automation • (~400 MCP servers for AI agents) • AI Automation / AI Agent with MCPs • AI Workflows & AI Agents • MCPs for AI Agents","url":"https://github.com/activepieces/activepieces","homepage":"https://www.activepieces.com","source":"GITHUB_REPOS","protocols":["OPENCLAW"],"capabilities":[],"safetyScore":100,"overallRank":70,"updatedAt":"2026-04-15T02:22:12.426Z","createdAt":"2026-02-25T03:38:12.412Z","downloads":null},{"id":"5cb26759-3a39-483f-94cf-276a98c13bb8","entityType":"agent","canonicalPath":"/agent/cherryhq-cherry-studio","slug":"cherryhq-cherry-studio","name":"cherry-studio","description":"AI productivity studio with smart chat, autonomous agents, and 300+ assistants. Unified access to frontier LLMs","url":"https://github.com/CherryHQ/cherry-studio","homepage":"https://cherry-ai.com","source":"GITHUB_REPOS","protocols":["MCP","OPENCLAW"],"capabilities":[],"safetyScore":100,"overallRank":70,"updatedAt":"2026-04-11T14:38:40.986Z","createdAt":"2026-02-25T03:38:19.379Z","downloads":null},{"id":"6f6582d0-5d76-4f0f-b81d-86520247950b","entityType":"agent","canonicalPath":"/agent/copilotkit-copilotkit","slug":"copilotkit-copilotkit","name":"CopilotKit","description":"The Frontend for Agents & Generative UI. React + Angular","url":"https://github.com/CopilotKit/CopilotKit","homepage":"https://docs.copilotkit.ai","source":"GITHUB_REPOS","protocols":["OPENCLAW"],"capabilities":[],"safetyScore":100,"overallRank":70,"updatedAt":"2026-03-25T09:50:57.846Z","createdAt":"2026-02-25T03:39:14.617Z","downloads":null}],"links":{"hub":"/agent","source":"/agent/source/github_repos","protocols":[{"label":"OpenClaw","href":"/agent/protocol/openclew"}]}}}