spalit2025
MCP Serverspalit2025public

research mcp client

๐Ÿค– AI Research Assistant - Claude chatbot with MCP integration for paper search, analysis, and academic discovery

Repository Info

0
Stars
0
Forks
0
Watchers
0
Issues
Python
Language
MIT License
License

About This Server

๐Ÿค– AI Research Assistant - Claude chatbot with MCP integration for paper search, analysis, and academic discovery

Model Context Protocol (MCP) - This server can be integrated with AI applications to provide additional context and capabilities, enabling enhanced AI interactions and functionality.

Documentation

๐Ÿค– Multi-Server AI Assistant

A Claude AI chatbot with advanced MCP (Model Context Protocol) integration that connects to multiple servers simultaneously for enhanced research, analysis, and productivity capabilities.

โœจ Features

  • ๐Ÿค– Interactive Chat Interface - Natural conversation with Claude AI
  • ๐Ÿ”ง Multi-Server MCP Integration - Connect to multiple MCP servers simultaneously
  • ๐Ÿ“š Research & Analysis - Search arXiv, analyze papers, and access academic resources
  • ๐Ÿ—‚๏ธ File System Access - Read, write, and manage files through MCP servers
  • ๐ŸŒ Web Content Fetching - Fetch and analyze web content with HTTP requests
  • ๐Ÿ—„๏ธ Database Operations - Query and manage databases via MCP tools
  • ๐Ÿ“ Prompt Templates - Execute predefined prompts with custom arguments
  • ๐Ÿ“š Resource Access - Access structured resources from MCP servers
  • ๐ŸŽฏ Intelligent Tool Selection - Claude automatically chooses the best tools for each task
  • โšก Async Performance - Fast, responsive interactions across all servers
  • ๐Ÿ›ก๏ธ Robust Error Handling - Graceful handling of server failures and tool errors
  • ๐Ÿ”„ Dynamic Configuration - Easy server management through JSON configuration
  • research-mcp-server - Academic research tools for arXiv integration
  • MCP Official Servers - Collection of official MCP server implementations

๐Ÿ“‹ Prerequisites

  • Python 3.10+
  • UV package manager (Installation guide)
  • Anthropic API key (Get one here)
  • One or more MCP servers - See Configuration for setup options

๐Ÿš€ Quick Start

1. Clone the Repository

git clone https://github.com/spalit2025/research-mcp-client.git
cd research-mcp-client

2. Install Dependencies

uv sync

3. Set Up Environment Variables

cp .env.example .env
# Edit .env and add your ANTHROPIC_API_KEY

4. Configure MCP Servers

cp server_config.example.json server_config.json
# Edit server_config.json to configure your MCP servers

5. Run the Chatbot

uv run mcp_chatbot.py

๐Ÿ’ฌ Usage Examples

The chatbot can now handle diverse tasks across multiple domains:

Research & Academic

๐Ÿ“ Query: Search for papers about machine learning transformers
๐Ÿ“ Query: Extract information from paper ID 2301.07041
๐Ÿ“ Query: Find recent papers on quantum computing

Web Content & Information Fetching

๐Ÿ“ Query: Fetch the content from https://arxiv.org/abs/2301.07041
๐Ÿ“ Query: Get the latest news from a technology website
๐Ÿ“ Query: Fetch and summarize content from a research blog

File Operations

๐Ÿ“ Query: Read the contents of my project README
๐Ÿ“ Query: Create a summary document from these files
๐Ÿ“ Query: List all Python files in the current directory
๐Ÿ“ Query: Show me the directory structure of my project

Combined Operations

๐Ÿ“ Query: Search for AI papers, fetch their abstracts, and save to a file
๐Ÿ“ Query: Read my research notes and find related papers on arXiv
๐Ÿ“ Query: Fetch web content and save it to a local file for analysis

Special Commands

# Resource Access
@folders                        # List available research folders
@machine_learning              # Access ML papers resource

# Prompt Templates
/prompts                       # List all available prompt templates
/prompt generate_search_prompt topic=AI    # Execute prompt with arguments
/prompt fetch url=https://example.com      # Execute fetch prompt

Commands

  • Type your queries naturally - Claude will choose the appropriate tools
  • Use quit, exit, or q to exit
  • Press Ctrl+C to interrupt

๐Ÿ—๏ธ Project Structure

research-mcp-client/
โ”œโ”€โ”€ mcp_chatbot.py              # Main multi-server chatbot application
โ”œโ”€โ”€ server_config.json          # Your MCP server configurations
โ”œโ”€โ”€ server_config.example.json  # Example server configurations
โ”œโ”€โ”€ pyproject.toml              # Project dependencies
โ”œโ”€โ”€ .env.example                # Environment variables template
โ”œโ”€โ”€ .env                        # Your API key (create from .env.example)
โ”œโ”€โ”€ README.md                   # This file
โ””โ”€โ”€ .venv/                      # Virtual environment (created by uv)

๐Ÿ”ง How It Works

  1. Configuration Loading - Reads server configurations from server_config.json
  2. Multi-Server Connection - Establishes connections to all configured MCP servers
  3. Capability Discovery - Automatically discovers tools, prompts, and resources from all servers
  4. Query Processing - User queries are processed by Claude AI with access to all available capabilities
  5. Intelligent Routing - Claude selects the appropriate server and capability for each task
  6. Special Commands - Handle resource access (@) and prompt execution (/) commands
  7. Response Integration - Results from multiple tools are seamlessly integrated into responses

๐Ÿ› ๏ธ Configuration

Server Configuration File

Create a server_config.json file to define your MCP servers:

{
  "mcpServers": {
    "research-server": {
      "command": "python",
      "args": ["/path/to/research-mcp-server/research_server.py"],
      "env": null
    },
    "fetch": {
      "command": "uvx",
      "args": ["mcp-server-fetch"],
      "env": null
    },
    "filesystem": {
      "command": "npx",
      "args": ["-y", "@modelcontextprotocol/server-filesystem", "/allowed/directory"],
      "env": null
    },
    "web-search": {
      "command": "npx",
      "args": ["-y", "@modelcontextprotocol/server-brave-search"],
      "env": {
        "BRAVE_API_KEY": "your-api-key-here"
      }
    },
    "database": {
      "command": "npx",
      "args": ["-y", "@modelcontextprotocol/server-sqlite", "/path/to/database.db"],
      "env": null
    }
  }
}

Available MCP Servers

Popular MCP servers you can integrate:

  • Research Server - Academic paper search and analysis (custom implementation)
  • Fetch Server - Web content fetching and HTTP requests (uvx mcp-server-fetch)
  • Filesystem Server - File and directory operations (npx @modelcontextprotocol/server-filesystem)
  • Brave Search - Web search capabilities (npx @modelcontextprotocol/server-brave-search)
  • SQLite Server - Database query and management (npx @modelcontextprotocol/server-sqlite)
  • Git Server - Git repository operations
  • Slack Server - Slack integration and messaging
  • Google Drive Server - Google Drive file access

Current Working Configuration

The project includes a working configuration with these servers:

  1. Research Server (2 tools, 1 prompt, 1 resource)

    • Tools: search_papers, extract_info - Search and analyze arXiv papers
    • Prompts: generate_search_prompt - Generate academic search prompts
    • Resources: papers://folders - Access research paper folders
  2. Fetch Server (1 tool, 1 prompt)

    • Tools: fetch - Fetch web content and convert to markdown
    • Prompts: fetch - Execute URL fetching with prompt templates
  3. Filesystem Server (11 tools)

    • read_file, write_file, edit_file - File operations
    • list_directory, directory_tree - Directory browsing
    • create_directory, move_file - File management
    • search_files, get_file_info - File discovery
    • read_multiple_files, list_allowed_directories - Batch operations

Total: 14 tools, 2 prompts, 1 resource across 3 servers

Environment Variables

Required environment variables in .env:

  • ANTHROPIC_API_KEY - Your Anthropic API key

Optional environment variables for specific servers:

  • BRAVE_API_KEY - For Brave search functionality
  • GOOGLE_APPLICATION_CREDENTIALS - For Google services
  • Other API keys as required by your chosen servers

๐ŸŽฏ Enhanced Interface

The chatbot now supports advanced MCP capabilities beyond just tools:

Special Command Syntax

  • @<resource> - Access MCP resources directly
    • @folders - List available research folders
    • @machine_learning - Access specific topic resources
  • /prompts - List all available prompt templates
  • /prompt <name> <args> - Execute prompt templates with arguments
    • /prompt generate_search_prompt topic=AI - Generate AI research prompts
    • /prompt fetch url=https://example.com - Execute fetch with prompts

Startup Information

When you start the chatbot, you'll see:

  • ๐Ÿ› ๏ธ Available tools from all connected servers
  • ๐Ÿ“ Available prompts for template-based queries
  • ๐Ÿ“š Available resources for structured data access
  • ๐Ÿ’ก Special commands help and syntax guide

Interactive Features

  • Natural language queries - Ask anything, Claude chooses the right tools
  • Multi-step workflows - Combine tools across different servers
  • Resource exploration - Browse and access structured data
  • Template execution - Use predefined prompts with custom parameters

๐Ÿ› Troubleshooting

Configuration Issues

  • โœ… Ensure server_config.json exists and is valid JSON
  • โœ… Check that all server paths and commands are correct
  • โœ… Verify required environment variables are set

Connection Issues

  • โœ… Test each server independently before adding to configuration
  • โœ… Check server dependencies are installed (Node.js for npx servers)
  • โœ… Verify file paths and permissions

API Issues

  • โœ… Verify your ANTHROPIC_API_KEY is set correctly in .env
  • โœ… Ensure you have sufficient API credits
  • โœ… Check your internet connection for web-based servers

Tool Errors

  • โœ… Check individual server logs for detailed error information
  • โœ… Verify tool arguments match expected schemas
  • โœ… Ensure all required API keys are configured

Common Solutions

# Reinstall dependencies
uv sync

# Test server configuration
python -c "import json; print(json.load(open('server_config.json')))"

# Check individual server
npx @modelcontextprotocol/inspector python /path/to/server.py

# Verify API key
echo $ANTHROPIC_API_KEY

๐Ÿ”„ Development

Adding New Servers

  1. Install the MCP server following its documentation
  2. Add server configuration to server_config.json
  3. Test the server independently
  4. Restart the chatbot to discover new tools

Making Changes

  1. Edit mcp_chatbot.py for core functionality
  2. Update server_config.json for server configurations
  3. Update pyproject.toml for dependencies
  4. Test with your configured servers
  5. Update documentation as needed

Server Development

  • The chatbot automatically discovers new tools from any server
  • No client-side changes needed when server tools are updated
  • Focus on improving the chat interface and error handling
  • Consider server-specific error handling for better user experience

๐Ÿ“ฆ Dependencies

  • anthropic - Claude AI API client
  • mcp - Model Context Protocol implementation
  • python-dotenv - Environment variable management
  • nest-asyncio - Async support for interactive environments

๐Ÿ“„ License

This project is licensed under the MIT License - see the LICENSE file for details.

๐Ÿค Contributing

  1. Fork the repository
  2. Create a feature branch (git checkout -b feature/amazing-feature)
  3. Make your changes and test with multiple servers
  4. Ensure configuration examples are updated
  5. Commit your changes (git commit -m 'Add some amazing feature')
  6. Push to the branch (git push origin feature/amazing-feature)
  7. Open a Pull Request

๐Ÿ™ Acknowledgments

  • Anthropic for Claude AI
  • Model Context Protocol for the excellent framework
  • MCP Community for server implementations
  • arXiv for providing access to research papers

๐Ÿ“ž Support

If you encounter any issues or have questions:

  1. Check the Troubleshooting section
  2. Review your server_config.json configuration
  3. Test individual servers with MCP Inspector
  4. Look at existing Issues
  5. Create a new issue with detailed information about your problem

Happy exploring with multiple MCP servers! ๐Ÿš€โœจ

Quick Start

1

Clone the repository

git clone https://github.com/spalit2025/research-mcp-client
2

Install dependencies

cd research-mcp-client
npm install
3

Follow the documentation

Check the repository's README.md file for specific installation and usage instructions.

Repository Details

Ownerspalit2025
Reporesearch-mcp-client
LanguagePython
LicenseMIT License
Last fetched8/10/2025

Recommended MCP Servers

๐Ÿ’ฌ

Discord MCP

Enable AI assistants to seamlessly interact with Discord servers, channels, and messages.

integrationsdiscordchat
๐Ÿ”—

Knit MCP

Connect AI agents to 200+ SaaS applications and automate workflows.

integrationsautomationsaas
๐Ÿ•ท๏ธ

Apify MCP Server

Deploy and interact with Apify actors for web scraping and data extraction.

apifycrawlerdata
๐ŸŒ

BrowserStack MCP

BrowserStack MCP Server for automated testing across multiple browsers.

testingqabrowsers
โšก

Zapier MCP

A Zapier server that provides automation capabilities for various apps.

zapierautomation