Used for storing API keys and configuration settings for the MCP server
Enables the creation of multi-tool AI assistants using LangChain MCP Adapters to connect tools and services
Integrates with the system to create conversational AI agents that can interact with multiple MCP tools
🧠 MCP Server with LangChain and AI Tools
This project demonstrates how to build a multi-tool AI assistant using the Model Context Protocol (MCP), LangChain, and Groq’s Qwen model. It includes:
- 📐 A local Math MCP Server
- 🌤️ A simulated Weather MCP Server
- 🤖 A conversational AI agent (MCP client) that talks to both
🧰 Features
- Uses LangChain MCP Adapters to connect tools
- Powered by Groq's Qwen LLM
- Handles local and remote tool servers via MCP
- Interactive CLI chat with tool usage detection
🏁 Prerequisites
- Python >= 3.11
uv
for project/environment management (https://github.com/astral-sh/uv)- Internet connection for loading LLM (Groq)
⚙️ Setup Instructions
1. Create Project
Set Python version in .python-version and pyproject.toml to >=3.11
2. Create Virtual Environment
3. Add Dependencies
Install them
Project Structure
mcp_project/ │ ├── math_server.py # MCP server for math tools ├── weather_server.py # MCP server for weather API simulation ├── client.py # MCP client with AI agent ├── requirements.txt ├── .python-version └── .env # For storing Groq API key (GROQ_API_KEY)
How to Run
1. Run the Weather Server
2. Run the Client (Automatically runs math server as sub process)
Example Conversation
Note
The weather server is simulated. Replace it with real API logic if needed.
You can add more MCP servers for documents, search, DBs, etc.
Use .env to store your GROQ_API_KEY.
This server cannot be installed
A multi-tool AI assistant system that uses Model Context Protocol to connect language models with various tools, including math calculations and weather information.
Related MCP Servers
- -securityFlicense-qualityA versatile Model Context Protocol server that enables AI assistants to manage calendars, track tasks, handle emails, search the web, and control smart home devices.Last updated -2Python
- -security-license-qualityA Model Context Protocol server implementation that enables AI assistants to interact with Linear project management systems, allowing them to create, retrieve, and modify data related to issues, projects, teams, and users.Last updated -202TypeScript
- -securityFlicense-qualityA comprehensive Model Context Protocol server implementation that enables AI assistants to interact with file systems, databases, GitHub repositories, web resources, and system tools while maintaining security and control.Last updated -16TypeScript
- -securityAlicense-qualityA customizable Model Context Protocol server implementation that enables AI models to interact with external tools including weather queries, Google search, and camera control functionality.Last updated -8PythonApache 2.0