Skip to content
Back to search

cgpa-mcp-server

MCP server exposing CGPA/GPA calculation tools (built with FastMCP) for the PUCIT CGPA Guider agent.

Safety scan

A static text scan, not a guarantee. Select the badge to see what was scanned and every finding.

Checked today
Badge for your README
findsafeskills safety rating

Markdown

[![findsafeskills safety rating](/api/listings/nabiha-tanveer--cgpa-mcp-server/badge.svg)](/listings/nabiha-tanveer--cgpa-mcp-server)

HTML

<a href="/listings/nabiha-tanveer--cgpa-mcp-server"><img src="/api/listings/nabiha-tanveer--cgpa-mcp-server/badge.svg" alt="findsafeskills safety rating" /></a>

Install

i

What was scanned

The files the safety scan read, as written by the repository's author and shown as plain text. Lines with a finding are marked.

README.md · README · 36 lines
  1. # CGPA Guider: MCP + Memory + Streaming
  2. PUCIT BS Computer Science CGPA assistant. The agent's tools live on a separate MCP server hosted on the internet, and the agent has persistent memory and streaming output.
  3. ## MCP Server
  4. - Hosted on: FastMCP Horizon
  5. - Server URL: https://cgpa-guider.fastmcp.app/mcp
  6. - Authentication: required (Bearer API key)
  7. - API key: <YAHAN APNI HORIZON KEY PASTE KARO>
  8. - Server code (GitHub): https://github.com/nabiha-tanveer/cgpa-mcp-server
  9. ## Project structure
  10. - `server/`: FastMCP server exposing 7 tools: `marks_to_grade_points`, `calculate_semester_gpa`, `calculate_new_cgpa`, `required_gpa_for_target`, `get_semester_courses`, `get_remaining_credit_hours`, `save_report`
  11. - `agent/`: async LangChain agent (`create_agent`) that loads its tools from the MCP server
  12. ## How to run the agent
  13. 1. `cd agent`
  14. 2. Install dependencies:
  15. ```
  16. pip install -U "langchain[mcp]" langgraph langchain-groq langgraph-checkpoint-sqlite aiosqlite python-dotenv
  17. ```
  18. 3. Create a `.env` file in `agent/`:
  19. ```
  20. GROQ_API_KEY=<your Groq key>
  21. MCP_URL=https://cgpa-guider.fastmcp.app/mcp
  22. FASTMCP_KEY=<Horizon API key from above>
  23. ```
  24. 4. Run `python agent.py`
  25. Commands inside the chat: `/switch`, `/history`, `/forget`, `exit`.
  26. ## Features
  27. - **MCP (Task 1, 2, 5):** tools moved from `tools.py` to a FastMCP server and deployed on Horizon. The agent only needs `MCP_URL` and the key in `.env`.
  28. - **Memory (Task 3):** `AsyncSqliteSaver` (`memory.db`), `thread_id` is the person's name, so chats survive restarts.
  29. - **Streaming (Task 4):** `astream` with `stream_mode=["updates", "messages"]`. Tokens print live and tool calls are shown as `[tool: name]`.
  30. - **Server down (Task 6):** a failed tool call is turned into an error `ToolMessage`, so the model tells the user the service is down. `repair_history` adds an error `ToolMessage` for any old tool call left without an answer, so the chat is never stuck.

Ratings and comments

Sign in to rate this skill.

Sign in

Free to use. If it’s helped, pass it on.