DeepTutor: Agent-Native Intelligent Learning Companion

repository·main·Indexed 12 days ago

https://github.com/hkuds/deeptutor

An agent-native system for lifelong personalized tutoring featuring multi-agent collaboration and RAG. It provides a unified runtime for capabilities such as deep research, problem solving, and mastery-based learning paths. Includes a CLI for managing knowledge bases, sessions, and provider authentication, as well as a backend API service. Supports multiple RAG libraries including LlamaIndex, GraphRAG, and LightRAG.

Tokens
67K
Snippets
149
Records
267
Agent score
93%

What's inside DeepTutor

  1. Overview of DeepTutor Features

    main

    DeepTutor is an agent-native learning workspace designed for lifelong personalized tutoring. It integrates tutoring, problem solving, quiz generation, research, visualization, and mastery practice into a single extensible system.

    Core Capabilities

    • Unified Runtime: Modes like Chat, Quiz, Research, Visualize, Solve, and Mastery Path all run on a single agent loop, allowing you to change objectives without losing learner context.
    • Connected Learning Context: Knowledge bases, books, Co-Writer drafts, notebooks, question banks, personas, and Memory are shared across all workflows.
    • Sub-Agents and Partners: Supports live coding CLIs (e.g., Claude Code, Codex, Gemini, Kimi, opencode, or MiMo) and persistent IM companions.
    • Multi-Engine Knowledge: Supports versioned RAG libraries using LlamaIndex, PageIndex, GraphRAG, LightRAG, or linked Obsidian vaults, along with pluggable document parsing.
    • Extensible Tools and Skills: Includes built-in tools, MCP servers, CLI apps, generative models (image/video/voice), and community skills installable via EduHub.
    • Inspectable Memory: Provides visibility into L1 traces, L2 surface summaries, and L3 synthesis personalization via a Memory Graph that traces claims to evidence.
  2. Overview of DeepTutor key features

    main

    DeepTutor is an agent-native learning workspace designed for lifelong personalized tutoring. It integrates multiple learning modes into a single extensible system, ensuring that context (knowledge bases, books, drafts, notebooks, etc.) remains consistent across different workflows.

    Key capabilities include:

    • Unified Runtime: Modes like Chat, Quiz, Research, Visualize, Solve, and Mastery Path all operate on the same agent loop, allowing seamless switching of objectives without losing context.
    • Connected Context: Maintains access to knowledge bases, Co-Writer drafts, notebooks, question banks, personas, and Memory across all workflows.
    • Subagents and Partners: Supports consulting live coding CLIs (e.g., Claude Code, Codex, Gemini, Kimi, opencode, MiMo) or importing past conversations from Partners.
    • Multi-engine Knowledge: Supports versioned RAG libraries including LlamaIndex, PageIndex, GraphRAG, LightRAG, or linked Obsidian vaults, with pluggable document parsing.
    • Extensible Ecosystem: Integrates built-in tools, MCP servers, CLI apps, generative models (image/video/voice), and community skills from EduHub.
    • Inspectable Memory: Provides visibility into personalization through L1 traces, L2 surface summaries, and L3 synthesis, supported by a Memory Graph that traces claims to evidence.
  3. Overview of DeepTutor core capabilities

    main

    DeepTutor is an agentic learning runtime that integrates tutoring, problem-solving, quiz generation, research, visualization, and mastery practice into a single extensible system.

    Key architectural features include:

    • Unified Runtime: Modes like Chat, Quiz, Research, Visualize, Solve, and Mastery Path share a single agent loop, allowing context to persist across different learning goals.
    • Linked Learning Context: Knowledge bases, books, Co-Writer drafts, notebooks, question banks, personas, and Memory are accessible across all workflows.
    • Sub-agents and Partners: Supports integration with CLI coding tools (e.g., Claude Code, Codex, Gemini, Kimi, opencode, or MiMo) and persistent IM companions.
    • Multi-engine Knowledge: Supports versioned RAG libraries including LlamaIndex, PageIndex, GraphRAG, LightRAG, or Obsidian storage.
    • Extensible Tools: Supports built-in tools, MCP servers, CLI applications, generative models (image/video/voice), and community skills from EduHub.
    • Verifiable Memory: Uses a multi-layer memory system (L1 traces, L2 surface summaries, L3 synthesis) and a Memory Graph to trace claims back to their sources.
  4. Overview of DeepTutor

    main

    DeepTutor is an agent-native learning workspace designed for lifelong personalized tutoring. It integrates tutoring, problem-solving, quiz generation, research, visualization, and mastery practice into a single extensible system.

    Key features include:

    • Unified Runtime: All modes (Chat, Quiz, Research, Visualize, Solve, Mastery Path) run on the same agent loop, allowing context to move with the learner.
    • Connected Learning Context: Knowledge bases, books, drafts, notebooks, problem banks, personas, and Memory are accessible across all workflows.
    • Sub-agents and Partners: Ability to consult live coding CLIs (e.g., Claude Code, Codex, Gemini, Kimi, opencode, MiMo) or Partners within the same agent loop.
    • Multi-engine Knowledge: Supports RAG libraries across LlamaIndex, PageIndex, GraphRAG, LightRAG, or linked Obsidian vaults.
    • Extensible Tools and Skills: Supports built-in tools, MCP servers, CLI apps, generative models, and community skills from EduHub.
    • Inspectable Memory: Personalization is visible and editable through L1 traces, L2 surface summaries, and L3 synthesis, with a Memory Graph for evidence tracking.
  5. Overview of DeepTutor core features

    main

    DeepTutor is an agent-native learning workspace designed for personalized tutoring. Its core architecture includes:

    • Unified Agent Runtime: All modes (Chat, Quiz, Research, Visualize, Solve, and Mastery Path) run on the same agent loop, ensuring context follows the user.
    • Connected Learning Context: Knowledge bases, books, Co-Writer drafts, notebooks, question banks, personas, and Memory are shared across all workflows.
    • Sub-agents and Partners: Ability to consult live programming CLIs (e.g., Claude Code, Codex, Gemini, Kimi, opencode, or MiMo) or persistent IM companions.
    • Multi-engine Knowledge: Supports various RAG libraries including LlamaIndex, PageIndex, GraphRAG, LightRAG, or linked Obsidian vaults.
    • Extensible Tools: Integrates with MCP servers, CLI applications, and community skills from the EduHub.
    • Inspectable Memory: Uses a tiered memory system (L1 tracking, L2 surface summaries, L3 synthesis) with a Memory Graph to track claims to evidence.
  6. DeepTutor Overview

    main

    DeepTutor is an agent-native learning environment designed for lifelong personalized tutoring. It integrates tutoring, problem-solving, quiz generation, research, visualization, and mastery exercises into a single extensible system.

    Key features include:

    • Unified Environment: Modes like Chat, Quiz, Research, Visualize, Solve, and Mastery Path share the same agent loop, ensuring context follows the learner.
    • Connected Learning Context: Knowledge bases, books, Co-Writer sketches, notebooks, question banks, personas, and Memory are accessible across all workflows.
    • Sub-agents and Partners: Supports integration with coding CLIs (e.g., Claude Code, Codex, Gemini, Kimi, opencode, MiMo) and persistent learning companions.
    • Multi-engine Knowledge: Supports versioned RAG libraries including LlamaIndex, PageIndex, GraphRAG, LightRAG, or connected Obsidian vaults.
    • Extensible Tools: Includes built-in tools, MCP servers, CLI apps, generative models (image/video/voice), and community skills via EduHub.
    • Inspectable Memory: Uses a multi-layer memory structure (L1 traces, L2 surface summaries, L3 synthesis) and a Memory Graph to track claims back to evidence.
  7. DeepTutor Overview and Core Features

    main

    DeepTutor is an agent-native learning workspace designed for lifelong personalized tutoring. It integrates tutoring, problem-solving, quiz generation, research, visualization, and mastery practice into a single extensible system.

    Key Capabilities:

    • Unified Runtime: Chat, Quiz, Research, Visualize, Solve, and Mastery Path all operate on the same agent loop, ensuring context flows seamlessly with the learner.
    • Interconnected Learning Context: Knowledge bases, books, Co-Writer drafts, notebooks, question banks, personality presets, and Memory are available across all workflows.
    • Sub-agents and Partners: Ability to call real-time programming CLIs (e.g., Claude Code, Codex, Gemini, Kimi, opencode, or MiMo) or import Partner conversation histories.
    • Multi-engine Knowledge Base: Supports versioned RAG (Retrieval-Augmented Generation) across LlamaIndex, PageIndex, GraphRAG, LightRAG, or linked Obsidian vaults with pluggable document parsing.
    • Extensible Tools and Skills: Includes built-in tools, MCP servers, CLI applications, generative models (image/video/speech), and community skills from EduHub.
    • Auditable Memory: Features L1 tracking, L2 surface summaries, and L3 synthesis, with a Memory Graph that traces conclusions back to original evidence.
  8. What is a DeepTutor skill?

    main

    A skill is a self-contained capability package designed to teach the model procedural knowledge, such as specific workflows, domain expertise, or format conventions.

    Technically, a skill consists of a required SKILL.md playbook and optional files located in a references/ directory. The system prompt only contains the skill's name and description. The model uses the read_skill tool to fetch the full content of the skill only when a task matches the provided description.

    Note: Behavior or voice presets (like tone or teaching style) are considered personas and are managed separately from skills.

  9. How Chat, Partners, and My Agents work in DeepTutor

    main

    DeepTutor uses different interaction models depending on the use case:

    • Chat: The default starting point. It uses an agent loop where the model thinks, calls tools, observes results, and eventually responds. It supports Sticky Session Context (sub-agents, knowledge bases, personas, models) which persists across turns, and One-time References (files, chat history, books) added via the + menu for single turns.
    • Partners: Persistent companions with their own "soul" (model strategy, knowledge base, memory, and channels). They act like a chat with a personality and a phone number. Each Partner has a dedicated workspace in data/partners/<id>/workspace/ and can be connected to IM platforms like Telegram, Slack, or Discord.
    • My Agents: Allows you to call other agents within a chat. You can Connect Real-time Agents (like Claude Code, Gemini, or a Partner) using the consult_subagent tool, or Import Historical Dialogues (from Claude Code or Codex) to use them as searchable, resumable context.
  10. Integrate DeepTutor with other agents via JSON/NDJSON

    main

    DeepTutor is designed to be controlled by other LLM agents. By adding the --format json flag to any run command, the CLI outputs NDJSON (Newline Delimited JSON).

    Each line represents a single event (e.g., content, tool_call, tool_result, done) and includes a session_id. This allows agents to track state across multiple turns.

    Key features for automation:

    • Stateful Sessions: Capture the session_id from a done event to reuse it in subsequent commands using the --session <ID> flag.
    • Non-interactive Safety: In environments without a TTY, ask_user pauses will automatically resolve with an empty response instead of hanging the process.
    • Agent Handoff: You can provide the SKILL.md file from the repository to an LLM (like Claude Code or Codex) to give it full context of the DeepTutor surface area in one go.
    # Single machine-readable request
    deeptutor run deep_solve "Find d/dx[sin(x^2)]" --tool reason --format json
    
    # Chaining turns in a single session using the session_id
    SID=$(deeptutor run deep_research "Survey 2026 papers on RAG" \
      --config mode=report --config depth=standard --format json \
      | jq -r 'select(.type=="done").session_id')
    
    deeptutor run deep_question "Quiz me on that survey" --session "$SID" --format json
  11. How Memory works (3-Layer System)

    main

    DeepTutor uses a file-backed, three-layer system for inspectable personalization. It is not a hidden vector store, but a traceable graph:

    • L1 (Event Trace): Append-only traces of events stored in trace/<surface>/<date>.jsonl.
    • L2 (Curated Facts): Surface-specific curated facts stored in L2/<surface>.md. L2 cites L1.
    • L3 (Cross-Surface Synthesis): Synthesized profiles, recent context, scope, and preferences stored in L3/<profile|recent|scope|preferences>.md. L3 cites L2.

    This structure allows you to use the Memory Graph to trace any synthesized claim back to the exact raw event in L1. Memory is tracked across chat, notebook, quiz, kb, book, partner, and cowriter surfaces.