Skip to main content
Glama

Educhain based MCP Server (via Google Gemini)

This project devises an MCP server that handles various functions like: generating MCQs, flashcards, lesson-plans etc.,

Structure

Claude Desktop(Front end) <-> MCP Server <-> LLM (google Gemini)

Related MCP server: EduChain MCP Server

Installation and Initialization

Packages Manager: uv (Recommended) or pip

Step 0: Clone this repository

git clone Anudeep-CodeSpace/educhain_mcp_server.git
cd educhain_mcp_server

Step 1: Install uv

pip install uv # universal
brew install uv # mac os only

Step 2: Initialize project

uv init # initialize an already existing project

Step 3: Add required packages

# They contain all the required sub -packages in them
uv add "educhain" "mcp[cli]"

Step 4: Add your Google gemini api key

# inside .env file
GOOGLE_API_KEY=<Your Google api key without quotes>

Step 5: Debug your MCP server

uv run mcp dev main.py

It produces a tokenised proxy server at

http://localhost:6274/?PROXY_API_TOKEN=<proxy token>

Paste it and navigate to the link in a browser. Click "Connect" and you can debug your tools, resources and prompts in that site.

Step 6: Install Claude Desktop app

Install Claude Desktop app and login with your account(can be new).

Step 7: Add MCP server to Claude Desktop app

In the git repo folder run

# Adds the MCP Server to Claude Desktop client
uv run mcp install main.py

After that your claude_desktop_config.json should look like this:

{
  "mcpServers": {
    "Educhain - MCP server": {
      "command": "absolute/path/to/uv",
      "args": [
        "run",
        "--with",
        "mcp[cli]",
        "mcp",
        "run",
        "absolute/path/to/main/main.py"
      ]
    }
  }
}

Final step: Check for any discrepancies in the logs

All the logs are located at:

%APPDATA%\\Claude\\logs\\mcp.log # in windows
~/Library/Logs/Claude/mcp.log # in macOS

Metadata

get_info(about://info) resource lists out all the tools and resources provided by this server

Key Characteristics of this project

Modularity: Separating the server initialization (server.py), route handling (handlers.py), and the main entry point (main.py) makes the codebase clean, scalable, and easy to maintain.

Clear Schema Definitions: Use of Pydantic models in the schema directory. It ensures strong data validation, clear API contracts, and self-documenting code for requests and responses.

Dependency Injection: Passing the mcp server instance to handler functions (handle_resources(mcp)) is a good practice. It avoids circular dependencies and global state issues.

Use of Decorators: The @mcp.resource and @mcp.tool decorators provide a clean and declarative way to define the server's capabilities.

Known Issues

Claude Desktop client cannot direclty access Resource Templates (Beta stage)

For Example Claude Desktop client cannot access the generate_lessonplan resource(uri = lessonplan://{topic}) cannot be used directly as it is in beta stage and doesn't support dynamic resource uri's!!!

So Generate a lesson plan to teach algebra cannot invoke the generate_lessonplan tools!

Needs external LLM to generate content

Claude being a powerful llm cannot direclty generate content according to our tools and resources! (Hence I am using Gemini)

Key Contributors

Myself(Anudeep-CodeSpace), Chatgpt, Perplexity AI, Gemini(Free LLM)

Note

Node js(LTS) version is required for debugging pyenv is not recommended(That wasted a lot of time for me 😭)

Available Tools

2 tools
generate_flashcardC

Tool to generate Flash cards about a given topic.

Inputs: request (required). Returns: title, flashcards

generate_mcqB

Tool to generate Multiple Choice Questions(mcqs) about a given topic.

Inputs: request (required). Returns: questions

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    B3/5.0

    Scored across 2 tools

    Disambiguation5/5

    The two tools have clearly distinct purposes: one generates flash cards and the other generates multiple-choice questions, both focused on educational content creation but for different formats. There is no overlap in functionality, making it easy for an agent to choose the right tool based on the desired output type.

    Naming Consistency5/5

    Both tools follow a consistent 'verb_noun' naming pattern (generate_flashcard, generate_mcq), using the same verb 'generate' and descriptive nouns that clearly indicate the output. This uniformity enhances readability and predictability across the tool set.

    Tool Count2/5

    With only 2 tools, the server feels thin for an educational domain like 'Educhain', which might imply broader functionality such as managing content, quizzes, or user interactions. The limited scope may hinder agents from performing comprehensive tasks, suggesting an underdeveloped tool surface.

    Completeness2/5

    The server is severely incomplete for an educational domain; it only offers content generation tools without any CRUD operations (e.g., create, read, update, delete for flashcards or MCQs) or lifecycle management. This creates significant gaps, as agents cannot retrieve, modify, or organize generated content, leading to potential dead ends in workflows.

    Related MCP Connectors

    Related MCP Servers

    • F
      license
      Not graded
      quality
      D
      maintenance
      An MCP-compatible Flask server that integrates with the educhain Python library to dynamically generate educational content for Claude Desktop, including multiple-choice questions, lesson plans, and flashcards.
      1
      -
    • F
      license
      Not graded
      quality
      D
      maintenance
      Integrates the EduChain library with Claude Desktop to generate educational content such as multiple-choice questions, lesson plans, and flashcards. It utilizes Gemini LLMs through LangChain to provide local and secure content generation tools.
      -
    • F
      license
      Not graded
      quality
      D
      maintenance
      An MCP server that enables users to interact with local documents for educational purposes through tools for listing and reading files. It features an integrated agent capable of automatically generating document summaries and study flashcards.
      -
    • A
      license
      A
      quality
      D
      maintenance
      An MCP server that brings Google Gemini's image generation and editing capabilities to Claude Desktop, Claude Code, and Cursor. It supports 2K image creation, natural language image transformations, and session consistency to maintain styles across generations.
      7
      719 npm
      MIT