College AI Assistant

College AI Assistant

Provides MCP tools for searching student profiles, viewing marks/attendance, and finding low-attendance students. Enables AI assistants like Gemini to interact with college student data through natural language.

Category
Visit Server

README

College AI Assistant

An interactive assistant for managing and querying college student information (profiles, marks, attendance) using an MCP-based tool server and Google Gemini.

Overview

College AI Assistant demonstrates a small local system with:

  • an MCP tool server (server.py) exposing student data and helper tools
  • a CLI assistant (ai_agent.py) that uses Gemini plus MCP tools
  • a FastAPI wrapper (api.py) for the browser UI
  • a simple static frontend in web/
  • a local SQLite database managed by database.py

Features

  • Search student profiles by name
  • Retrieve detailed student information by ID
  • View subject-wise marks, average marks, and academic performance
  • View subject-wise attendance and attendance analysis
  • Find students with attendance below a threshold
  • Run the assistant from CLI, HTTP API, or web UI

Repository Structure

  • ai_agent.py — CLI client that starts an interactive assistant session
  • api.py — FastAPI app exposing /chat and health endpoints
  • server.py — MCP tool server with student data tools and prompts
  • database.py — SQLite helpers, schema creation, and sample data seeding
  • config/settings.py — Gemini and MCP server configuration
  • agent/ — shared adapter code for integrating Gemini and MCP tools
  • web/ — static frontend: index.html, script.js, style.css
  • requirements.txt — Python dependencies

Requirements

  • Python 3.9+
  • A valid Gemini API key

Install dependencies with:

pip install -r requirements.txt

Configuration

Create a .env file in the project root with:

GEMINI_API_KEY=your_gemini_api_key_here

Default Gemini model and MCP settings are configured in config/settings.py:

  • GEMINI_MODEL = "gemini-2.5-flash"
  • MCP_SERVER_COMMAND = "python"
  • MCP_SERVER_FILE = "server.py"

Setup & Run

  1. Initialize the database and seed sample data:
python database.py
  1. Start the MCP tool server:
python server.py

3a. Run the CLI assistant:

python ai_agent.py

3b. Or start the HTTP API for the web UI:

uvicorn api:app --reload --host 127.0.0.1 --port 8000
  1. Open web/index.html in your browser. The UI sends chat requests to http://127.0.0.1:8000/chat by default.

API Endpoints

  • GET / — basic health check
  • GET /health — service status
  • POST /chat — chat endpoint

Request body:

{ "message": "Hello", "session_id": "optional-session-id" }

Response body:

{ "session_id": "...", "response": "..." }

Notes

  • The local SQLite database file is college.db.
  • The web UI is a static front end and requires the FastAPI server to be running.
  • database.py can be re-run to recreate tables and insert sample rows.

Troubleshooting

  • If the web UI cannot connect, verify the API is running at 127.0.0.1:8000.
  • If Gemini fails due to quota or authentication, check GEMINI_API_KEY and your Gemini account settings.

Optional Improvements

  • Add docker-compose.yml for streamlined startup
  • Add a Makefile or PowerShell script for common commands
  • Add tests for the API and MCP tools

Recommended Servers

playwright-mcp

playwright-mcp

A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.

Official
Featured
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.

Official
Featured
Local
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.

Official
Featured
Local
TypeScript
VeyraX MCP

VeyraX MCP

Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.

Official
Featured
Local
graphlit-mcp-server

graphlit-mcp-server

The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.

Official
Featured
TypeScript
Kagi MCP Server

Kagi MCP Server

An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.

Official
Featured
Python
Neon Database

Neon Database

MCP server for interacting with Neon Management API and databases

Official
Featured
E2B

E2B

Using MCP to run code via e2b.

Official
Featured
Exa Search

Exa Search

A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.

Official
Featured
Qdrant Server

Qdrant Server

This repository is an example of how to create a MCP server for Qdrant, a vector search engine.

Official
Featured