MCP server by mkomera
Agentic AI MCP Toolkit
A Model Context Protocol (MCP) implementation enabling AI agents to autonomously discover, select, and chain tools across multiple platforms. Build agentic AI systems where LLMs reason about which tools to use and orchestrate complex multi-step workflows.
Architecture
┌────────────────────────────────────────────────────────────────┐
│ Agentic AI MCP Toolkit │
├────────────────────────────────────────────────────────────────┤
│ │
│ ┌─────────────┐ ┌──────────────────┐ ┌────────────┐ │
│ │ AI Agent │────>│ MCP Orchestrator │────>│ Tool │ │
│ │ (LLM + │ │ (Tool Discovery │ │ Registry │ │
│ │ Reasoning)│<────│ + Selection) │<────│ (30+) │ │
│ └─────────────┘ └──────────────────┘ └────────────┘ │
│ │ │ │
│ v v │
│ ┌─────────────┐ ┌──────────────────┐ ┌────────────┐ │
│ │ Response │ │ Multi-Transport │ │ Platform │ │
│ │ Generation │ │ (SSE + REST + │ │ Adapters │ │
│ │ │ │ stdio) │ │ │ │
│ └─────────────┘ └──────────────────┘ └────────────┘ │
│ │
│ Platforms: Git | Project Mgmt | Databases | Documents | APIs │
└────────────────────────────────────────────────────────────────┘
Features
- Model Context Protocol — standard protocol for AI-tool communication
- 30+ built-in tools — Git operations, project management, database queries, document search
- Multi-transport — SSE (Server-Sent Events), REST API, stdio for IDE integration
- Autonomous tool selection — LLM decides which tools to use based on user intent
- Tool chaining — multi-step workflows where output of one tool feeds into another
- Platform adapters — extensible adapters for any API
- Conversation context — maintains context across tool calls within a session
- OpenAI-compatible function calling interface
Quick Start
git clone https://github.com/mkomera/agentic-ai-mcp-toolkit.git
cd agentic-ai-mcp-toolkit
pip install -r requirements.txt
cp .env.example .env
# Run MCP Server
python -m mcp_server.main --transport sse --port 8080
# Run Chat UI (optional)
python -m chat_ui.app --port 5000
Project Structure
agentic-ai-mcp-toolkit/
├── mcp_server/
│ ├── main.py # MCP server entry point
│ ├── protocol.py # MCP protocol implementation
│ ├── transport/
│ │ ├── sse.py # Server-Sent Events transport
│ │ ├── rest.py # REST API transport
│ │ └── stdio.py # stdio for IDE integration
│ ├── tools/
│ │ ├── registry.py # Tool registration and discovery
│ │ ├── git_tools.py # Git operations
│ │ ├── project_tools.py # Project management
│ │ ├── database_tools.py # Database queries
│ │ └── custom_tool.py # Base class for custom tools
│ └── orchestrator/
│ ├── agent.py # LLM agent with tool-calling
│ ├── planner.py # Multi-step plan generation
│ └── executor.py # Tool execution with error handling
├── chat_ui/
│ ├── app.py # FastAPI chat interface
│ └── templates/
├── adapters/
│ ├── github_adapter.py
│ ├── gitlab_adapter.py
│ └── sql_adapter.py
├── examples/
│ ├── basic_agent.py
│ ├── multi_step_workflow.py
│ └── custom_tool_example.py
├── tests/
├── requirements.txt
├── Dockerfile
└── README.md
Usage
Basic Agent with Tool Calling
from mcp_server.orchestrator.agent import MCPAgent
agent = MCPAgent(
llm_provider="bedrock",
tools=["git_tools", "project_tools", "database_tools"]
)
response = agent.run("Find all open bugs in the auth module and check related recent commits")
# Agent autonomously:
# 1. Calls project_tools.search_issues(query="auth", status="open", type="bug")
# 2. Calls git_tools.search_commits(query="auth", days=7)
# 3. Correlates results and generates summary
print(response.answer)
print(response.tools_used)
Custom Tool
from mcp_server.tools.custom_tool import BaseTool
class MonitoringTool(BaseTool):
name = "check_service_health"
description = "Check the health status of a microservice"
parameters = {
"service_name": {"type": "string", "description": "Name of the service"}
}
def execute(self, service_name: str):
health = self.http_client.get(f"http://{service_name}/health")
return {"status": health.status_code, "response": health.json()}
agent.register_tool(MonitoringTool())
Built-in Tools
| Category | Tools | |----------|-------| | Git | list_repos, search_code, list_branches, list_prs, get_pr_diff, list_commits | | Project Mgmt | list_issues, create_issue, search_work_items, list_boards | | Database | execute_query, list_tables, describe_schema, search_records | | Documents | search_docs, get_document, ingest_document | | Pipelines | list_pipelines, get_status, trigger_pipeline, get_logs |
Transport Options
# SSE (for web clients)
python -m mcp_server.main --transport sse --port 8080
# REST (for API integration)
python -m mcp_server.main --transport rest --port 8080
# stdio (for VS Code / IDE extensions)
python -m mcp_server.main --transport stdio
License
MIT