Converse MCP Enhanced
Multi-model AI conversation MCP for Claude Desktop. Seamlessly integrate with GPT-4, Gemini, xAI, Perplexity, and local models via Ollama.
README
Converse MCP Enhanced
Multi-model AI conversation MCP for Claude Desktop. Seamlessly integrate with GPT-4, Gemini, xAI, Perplexity, and local models via Ollama. Achieve 80-95% cost savings through intelligent routing and local model prioritization.
๐ Features
- 10+ AI Models: GPT-4, Claude, Gemini, xAI Grok, Perplexity, Ollama
- 80-95% Cost Savings: Smart routing prioritizes local models via Ollama
- Parallel Processing: Query multiple models simultaneously for consensus
- Web Search Integration: Real-time information via Perplexity Sonar
- Conversation Memory: Persistent context across sessions
- Smart Fallbacks: Automatic failover to ensure reliability
- Zero Setup Ollama: Auto-detection and configuration
๐ Supported Models
API Models
- OpenAI: GPT-4, GPT-3.5 Turbo
- Anthropic: Claude 3 Opus, Sonnet, Haiku
- Google: Gemini Pro, Gemini Ultra
- xAI: Grok-1, Grok-2
- Perplexity: Sonar (with web search)
Local Models (via Ollama)
- Llama 3 (8B, 70B)
- Mistral, Mixtral
- CodeLlama
- Phi-2
- Neural Chat
- Any Ollama-compatible model
๐ฐ Cost Optimization Strategy
Priority Order (Highest to Lowest):
1. Ollama local models (FREE) - ALWAYS FIRST
2. Intelligent model selection based on query
3. API models only as fallback
Result: 100% FREE operation when Ollama available
๐ง Smart Model Selection (v1.1.0)
The system automatically selects the optimal Ollama model:
- Simple queries (<50 chars) โ phi3:mini (fastest)
- Code-related โ codellama:7b
- Complex queries (>200 chars) โ qwen2.5-coder:32b
- Default โ llama3.2:3b (balanced)
๐ฆ Installation
Via NPM (Recommended)
npm install -g converse-mcp-enhanced
Manual Installation
git clone https://github.com/justmy2satoshis/converse-mcp-enhanced.git
cd converse-mcp-enhanced
npm install
๐ง Configuration
Add to your Claude Desktop configuration file:
Windows: %APPDATA%\Claude\claude_desktop_config.json
macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
{
"mcpServers": {
"converse": {
"command": "node",
"args": ["C:\\path\\to\\converse-mcp-enhanced\\src\\server.js"],
"env": {
"OPENAI_API_KEY": "sk-...",
"GOOGLE_API_KEY": "...",
"XAI_API_KEY": "...",
"PERPLEXITY_API_KEY": "...",
"OLLAMA_HOST": "http://localhost:11434"
}
}
}
}
๐ Usage Examples
Single Model Query
const response = await chat({
model: "auto", // Automatic model selection
prompt: "Explain quantum computing",
temperature: 0.7
});
Multi-Model Consensus
const consensus = await consensus({
models: ["gpt-4", "gemini-pro", "llama3"],
prompt: "Should we use microservices architecture?",
enable_cross_feedback: true
});
Web Search Integration
const results = await chat({
model: "perplexity",
prompt: "Latest developments in AI safety",
use_websearch: true
});
Cost-Optimized Query
const response = await chat({
model: "auto",
prompt: "Generate unit tests for this function",
prefer_local: true, // Prioritize Ollama models
max_cost: 0.01 // Cost limit in USD
});
๐ก Use Cases
Development Assistance
- Code generation with local models (free)
- Multi-model code review for quality
- Documentation with web search context
Research & Analysis
- Consensus building across models
- Real-time information via Perplexity
- Complex reasoning with chain-of-thought
Cost Management
- 95% of queries handled by Ollama
- API models only for specialized tasks
- Automatic caching reduces redundant calls
๐๏ธ Architecture
converse-mcp-enhanced/
โโโ src/
โ โโโ server.js # Main MCP server
โ โโโ models/
โ โ โโโ router.js # Intelligent routing
โ โ โโโ ollama.js # Ollama integration
โ โ โโโ providers/ # API integrations
โ โโโ consensus.js # Multi-model consensus
โ โโโ cache.js # Response caching
โโโ examples/ # Usage examples
โโโ tests/ # Test suite
โโโ package.json
๐ Performance Metrics
| Metric | Value | Notes |
|---|---|---|
| Cost Savings | 80-95% | Via Ollama prioritization |
| Response Time | <500ms | For cached/local |
| Availability | 99.9% | With fallbacks |
| Model Coverage | 10+ | And growing |
| Parallel Queries | 5+ | Simultaneous models |
๐งช Testing
npm test
Tests include:
- Model routing logic
- Cost optimization algorithms
- Consensus mechanisms
- Fallback scenarios
๐ค Contributing
Contributions welcome! See CONTRIBUTING.md for guidelines.
Priority Areas
- Additional model providers
- Enhanced caching strategies
- Cost optimization improvements
- Consensus algorithms
๐ Security
- API keys stored securely in environment
- No logging of sensitive data
- Local model priority reduces data exposure
- Optional request encryption
๐ License
MIT License - see LICENSE file for details
๐ Acknowledgments
- Anthropic for Model Context Protocol
- Ollama team for local model infrastructure
- OpenAI, Google, xAI, Perplexity for APIs
- Community contributors
๐ง Support
- Issues: GitHub Issues
- Discussions: GitHub Discussions
๐ฆ Status
- โ Production Ready
- โ 10+ models integrated
- โ Ollama auto-configuration
- โ Cost optimization active
- โ Claude Desktop compatible
Note: Requires Claude Desktop with MCP support. Ollama recommended for maximum cost savings.
Built with โค๏ธ for developers who want powerful AI without breaking the bank
Recommended Servers
playwright-mcp
A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.
Magic Component Platform (MCP)
An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.
Audiense Insights MCP Server
Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.
VeyraX MCP
Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.
graphlit-mcp-server
The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.
Kagi MCP Server
An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.
E2B
Using MCP to run code via e2b.
Neon Database
MCP server for interacting with Neon Management API and databases
Exa Search
A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.
Qdrant Server
This repository is an example of how to create a MCP server for Qdrant, a vector search engine.