{"id":28419882,"url":"https://github.com/zayedrais/ai_agent_with_mcp","last_synced_at":"2025-08-29T09:08:30.458Z","repository":{"id":295131855,"uuid":"989262762","full_name":"zayedrais/AI_Agent_with_MCP","owner":"zayedrais","description":"MCP server built with Google’s Agent Development(ADK) Kit featuring multiple specialised agents that collaborate through intelligent routing. The system provides RESTful API endpoints for various capabilities including web searches, data analysis, and code generation while maintaining extensibility through a modular architecture","archived":false,"fork":false,"pushed_at":"2025-05-28T07:41:08.000Z","size":21637,"stargazers_count":3,"open_issues_count":0,"forks_count":2,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-06-05T01:11:34.986Z","etag":null,"topics":["agent","agentic-ai","agents","ai","ai-agents","ai-tools","airtificialintelligence","fastmcp","google-adk","groq-api","litellm","llm","llmagents","mcp","mcp-client","mcp-server","model-context-protocol","openrouter-api","python","tools"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/zayedrais.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2025-05-23T19:08:01.000Z","updated_at":"2025-06-04T16:47:09.000Z","dependencies_parsed_at":"2025-05-23T20:36:14.735Z","dependency_job_id":null,"html_url":"https://github.com/zayedrais/AI_Agent_with_MCP","commit_stats":null,"previous_names":["zayedrais/ai_agent_with_mcp"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/zayedrais/AI_Agent_with_MCP","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zayedrais%2FAI_Agent_with_MCP","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zayedrais%2FAI_Agent_with_MCP/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zayedrais%2FAI_Agent_with_MCP/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zayedrais%2FAI_Agent_with_MCP/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/zayedrais","download_url":"https://codeload.github.com/zayedrais/AI_Agent_with_MCP/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zayedrais%2FAI_Agent_with_MCP/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":262444709,"owners_count":23312211,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["agent","agentic-ai","agents","ai","ai-agents","ai-tools","airtificialintelligence","fastmcp","google-adk","groq-api","litellm","llm","llmagents","mcp","mcp-client","mcp-server","model-context-protocol","openrouter-api","python","tools"],"created_at":"2025-06-04T21:46:23.610Z","updated_at":"2025-08-29T09:08:30.446Z","avatar_url":"https://github.com/zayedrais.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# MCP Server with Google ADK Project\n\nThis project implements a Model Context Protocol (MCP) server using Google's Agent Development Kit (ADK) for building intelligent agents and tools. The system features multiple specialized agents that collaborate through a coordinator agent to handle different types of requests.\n\n[Details in Medium Post](https://zayedrais.medium.com/building-a-mcp-server-with-ai-tools-and-agents-a4cd71b05a36)\n\n\n## Project Structure\n\n```\n├── agents/                    # Contains agent implementations\n│   ├── coordinator_agent.py   # LLM-based intelligent request router\n│   ├── data_analysis_agent.py # Agent for analyzing data files with visualization\n│   ├── search_agent.py        # Agent for web searches and information retrieval\n│   └── code_generator_agent.py # Agent for generating code based on descriptions\n├── tools/                     # Contains tool implementations\n│   ├── code_generator_tool.py # Generates code in various programming languages\n│   ├── data_analysis_tool.py  # Analyzes data and creates visualizations\n│   ├── data_reader_tool.py    # Reads data from various file formats\n│   ├── report_generator_tool.py # Generates formatted reports\n│   └── web_search_tool.py     # Performs web searches\n├── input_data/                # Directory for input data files (CSV, Excel)\n├── analysis_output/plots/     # Generated data visualizations\n├── reports/                   # Generated analysis reports\n├── generated_code/            # Generated code outputs\n├── server.py                  # MCP Server implementation using FastMCP\n├── requests_log.txt           # Log of requests and responses\n└── README.md                  # This file\n```\n\n## Prerequisites\n\n- Python 3.9+\n- Groq and OpenRouter Key\n\n## Working Flow Architecture\n![image](https://github.com/user-attachments/assets/dfc10783-23b3-4804-b2d3-a7aa07a9ab09)\n\n## Setup\n\n1. Clone this repository\n2. Create a virtual environment:\n   ```\n   python -m venv venv\n   source venv/bin/activate  # On Windows: venv\\Scripts\\activate\n   ```\n3. Install dependencies:\n   ```\n   pip install -r requirements.txt\n   ```\n4. Set up your Groq \u0026 Openrouter Key:\n  add key in .env if available otherwise create file as \n  ```\n  touch .env \n  ```\n  add key\n   ```\n   OPENROUTER_API_KEY=\"ADD_Your_Key\"\n   GROQ_API_KEY=\"ADD_Your_Key\" \n   \n   ```\n\n## Running the MCP Server\n\n```\npython server.py\n```\n\nThis will start the MCP server on `http://0.0.0.0:8080`\n\n## Available Agents\n\n### Coordinator Agent\n\nThe coordinator agent uses LLM-based routing to direct requests to the most appropriate specialized agent. It analyzes the content of the request and determines which agent can best handle it.\n\n### Search Agent\n\nPerforms web searches and provides information on various topics.\n\n**Example Request:**\n```\ncurl -X POST http://localhost:8080/ask -H \"Content-Type: application/json\" -d '{\"query\":\"What is Model Context Protocol?\"}'\n```\n\n### Data Analysis Agent\n\nAnalyzes data from various file formats (CSV, Excel) and generates reports with visualizations.\n\n**Example Request:**\n```\ncurl -X POST http://localhost:8080/ask -H \"Content-Type: application/json\" -d '{\"file_path\": \"sales_data.xlsx\",\"query\":\"make a report for these data\"}'\n```\n\n### Code Generator Agent\n\nGenerates code in various programming languages based on natural language descriptions.\n\n**Example Request:**\n```\ncurl -X POST http://localhost:8080/ask -H \"Content-Type: application/json\" -d '{\"query\":\"Python code for fibonacci series\",\"language\":\"python\"}'\n```\n\n## API Endpoints\n\n- `/ask` - General endpoint that routes to the appropriate specialized agent\n- `/search` - Endpoint for direct web searches\n- `/analyze-data` - Endpoint for data analysis\n- `/generate-code` - Endpoint for code generation\n- `/chat/completions` - Chat completion endpoint for conversational interaction\n\n## MCP Tools\n\nThe server exposes the following MCP tools:\n\n- `ask` - Routes the user's query to the most appropriate agent\n- `search` - Searches the web for information\n- `analyze_data` - Analyzes data files and generates reports with visualizations\n- `generate_code` - Generates code based on natural language descriptions\n\n## Extending This Project\n\nTo add new agents:\n1. Create a new file in the `agents/` directory\n2. Implement the agent class with an async `process()` method\n3. Update the coordinator agent to recognize and route to the new agent\n\nTo add new tools:\n1. Create a new file in the `tools/` directory\n2. Implement the tool functionality with comprehensive docstrings\n3. Import and use the tool in your agents\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzayedrais%2Fai_agent_with_mcp","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fzayedrais%2Fai_agent_with_mcp","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzayedrais%2Fai_agent_with_mcp/lists"}