Multimodal MCP
by vsiwach
README.md
# Multimodal MCP - Personal Resume AI Agent
A personalized AI agent that reads your resume and provides intelligent responses about your professional background through a standardized MCP (Model Context Protocol) server interface. Built with RAG (Retrieval-Augmented Generation) capabilities and multimodal voice support.
## Features
- **Resume Processing**: Automatically reads and processes resume files (PDF, DOCX, TXT, MD)
- **RAG System**: Uses ChromaDB and sentence transformers for intelligent content retrieval
- **MCP Server**: Exposes functionality through standardized MCP protocol
- **Skill Matching**: Analyzes how well your skills match job requirements
- **Natural Language Interface**: Ask questions about your experience, skills, education, etc.
- **π€ Voice Support**: Web UI with voice input/output using OpenAI Whisper & TTS
- **π Web Interface**: Clean, Google-like UI with conversational history
- **βοΈ AWS Deployment**: Production-ready deployment with HTTPS on custom domain
## Quick Start
### Option 1: Web UI with Voice Support (Recommended)
1. **Install Dependencies**
```bash
pip install -r requirements.txt
```
2. **Set OpenAI API Key** (for voice features)
```bash
export OPENAI_API_KEY="sk-your-api-key-here"
```
3. **Add Your Resume**
```bash
cp your-resume.pdf data/
```
4. **Start Web Server**
```bash
cd src
python mcp_resume_server_web.py
```
5. **Open Browser**: Navigate to `http://localhost:8000`
π See [QUICKSTART_WEB_UI.md](QUICKSTART_WEB_UI.md) for detailed instructions.
### Option 2: MCP Server (Claude Desktop)
1. **Install Dependencies**
```bash
pip install -r requirements.txt
```
2. **Add Your Resume**
```bash
cp your-resume.pdf data/
```
3. **Run as MCP Server**
```bash
cd src
python mcp_resume_server.py
```
### Option 3: AWS Cloud Deployment
Deploy to AWS with HTTPS and custom domain:
```bash
cd deploy
./deploy.sh
```
π See [DEPLOYMENT.md](DEPLOYMENT.md) for complete AWS deployment guide.
## Architecture
### Deployment Options
This system supports three deployment modes:
#### 1. Local MCP Server (Claude Desktop)
```
ββββββββββββββββββββ
β Claude Desktop β
β β
ββββββββββ¬ββββββββββ
β stdio (JSON-RPC)
βΌ
ββββββββββββββββββββ βββββββββββββββββββ ββββββββββββββββββββ
β MCP Server ββββββΆβ Resume Agent ββββββΆβ RAG System β
β (stdio) β β β β (ChromaDB + β
ββββββββββββββββββββ βββββββββββββββββββ β Transformers) β
ββββββββββ¬ββββββββββ
β
βΌ
ββββββββββββββββββββ
β Resume Files β
β (PDF/DOCX/TXT) β
ββββββββββββββββββββ
```
#### 2. AWS Cloud Deployment with HTTPS
```
ββββββββββββββββββββ
β Claude Desktop β
β β
ββββββββββ¬ββββββββββ
β stdio
βΌ
ββββββββββββββββββββ
β HTTP Wrapper β
β (stdioβHTTP) β
ββββββββββ¬ββββββββββ
β HTTPS
βΌ
ββββββββββββββββββββ βββββββββββββββββββ ββββββββββββββββββββ
β Route 53 ββββββΆβ ACM Certificate β β β
β (vsiwach.live) β β (SSL/TLS) β β β
ββββββββββ¬ββββββββββ ββββββββββ¬βββββββββ β β
β β β β
βββββββββββββ¬βββββββββββββ β β
βΌ β β
βββββββββββββββββββββββ β AWS VPC β
β Application LB β β β
β (HTTPS:443) β β βββββββββββββββββ
ββββββββββββ¬βββββββββββ β β ECS Fargate ββ
β β β ββ
βΌ β β ββββββββββββ ββ
βββββββββββββββββββββββ β β βContainer β ββ
β Target Group β β β β β ββ
β (Health: /health) β β β β MCP HTTP β ββ
ββββββββββββ¬βββββββββββ β β β Server β ββ
β β β ββββββ¬ββββββ ββ
ββββββββββββββββββββββββββββββΌβββΌβββββββ ββ
β βββββββββββββββββ
ββββββββββββββββββββ
```
#### 3. Web UI with Voice Support
```
ββββββββββββββββββββ
β Web Browser β
β β
β ββββββββββββββ β
β β π€ Voice β β
β β π Audio β β
β ββββββββββββββ β
ββββββββββ¬ββββββββββ
β HTTP/HTTPS
βΌ
ββββββββββββββββββββ βββββββββββββββββββ ββββββββββββββββββββ
β Web UI Server ββββββΆβ Audio Wrapper ββββββΆβ OpenAI API β
β (FastAPI) β β β β β’ Whisper (STT) β
β β’ Text Chat β β β β β’ TTS (Voice) β
β β’ Voice Input β β β ββββββββββββββββββββ
β β’ Audio Output β β β
ββββββββββ¬ββββββββββ βββββββββββββββββββ
β
βΌ
ββββββββββββββββββββ βββββββββββββββββββ ββββββββββββββββββββ
β Resume Agent ββββββΆβ RAG System ββββββΆβ Resume Files β
β β β (ChromaDB + β β (PDF/DOCX/TXT) β
ββββββββββββββββββββ β Transformers) β ββββββββββββββββββββ
βββββββββββββββββββ
```
### Core Components
- **Resume RAG System**: ChromaDB + Sentence Transformers for semantic search
- **Personal Resume Agent**: Query processing and response generation
- **MCP Servers**: stdio (local), HTTP (AWS), Web UI (browser)
- **Audio Wrapper**: OpenAI Whisper (STT) + TTS for voice features
- **HTTP Wrapper**: Bridges stdio protocol to HTTP for remote deployment
- **AWS Infrastructure**: ECS Fargate + ALB + ACM for production deployment
## Project Structure
```
multimodal-mcp/
βββ src/
β βββ resume_rag.py # RAG system for resume processing
β βββ personal_resume_agent.py # Main agent logic
β βββ audio_wrapper.py # OpenAI STT/TTS integration
β βββ mcp_resume_server.py # MCP server (stdio)
β βββ mcp_resume_server_http.py # MCP server (HTTP/AWS)
β βββ mcp_resume_server_web.py # Web UI server with voice
β βββ static/ # Web UI files
β βββ index.html # Google-like UI
β βββ style.css # Styling
β βββ app.js # Frontend logic
βββ data/ # Resume files + vector DB
βββ deploy/ # AWS deployment scripts
β βββ deploy.sh # Automated deployment
β βββ cloudformation-template.yaml # Infrastructure as code
βββ tests/ # Test suite
βββ examples/ # Usage examples
βββ requirements.txt # Local dependencies
βββ requirements-aws.txt # AWS optimized dependencies
βββ mcp_http_wrapper.py # Stdio-to-HTTP bridge
```
## Usage Examples
### Direct Agent Usage
```python
from personal_resume_agent import PersonalResumeAgent
agent = PersonalResumeAgent()
await agent.initialize()
# Ask questions about your resume
result = await agent.process_query("What programming languages do I know?")
print(result['response'])
# Analyze skill match for a job
match = await agent.get_skill_match("Python, React, AWS, Docker")
print(f"Match: {match['match_percentage']}%")
```
### MCP Server Tools
The MCP server exposes these tools:
- `query_resume`: Ask questions about resume content
- `get_agent_info`: Get agent capabilities and status
- `analyze_skill_match`: Compare skills with job requirements
- `get_resume_summary`: Get overview of resume knowledge base
## Configuration
### Claude Desktop Integration
Add to your Claude Desktop config (`claude_desktop_config.json`):
**Local Mode:**
```json
{
"mcpServers": {
"personal-resume": {
"command": "python",
"args": ["/path/to/multimodal-mcp/src/mcp_resume_server.py"],
"cwd": "/path/to/multimodal-mcp"
}
}
}
```
**Remote AWS Mode:**
```json
{
"mcpServers": {
"personal-resume": {
"command": "python",
"args": ["/path/to/multimodal-mcp/mcp_http_wrapper.py"]
}
}
}
```
## Supported File Formats
- **PDF**: Extracted using PyPDF2
- **DOCX**: Processed with python-docx
- **TXT/MD**: Plain text files
## Requirements
- Python 3.8+
- ChromaDB for vector storage
- Sentence Transformers for embeddings
- PyPDF2 for PDF processing
- python-docx for Word documents
- OpenAI API key (for voice features)
## Privacy & Security
π **Important Privacy Notes:**
- All resume data is processed **locally** on your machine or in your AWS account
- No personal information is sent to external services (except OpenAI for voice features)
- Vector database is stored locally in `data/resume_vectordb/`
- The `data/` directory is excluded from version control
- Never commit personal resume files or API keys to public repositories
## Deployment
### Docker Image Optimization
The Docker image has been optimized from 4.34GB to 587MB (86% reduction) by:
- Using CPU-only PyTorch instead of GPU version
- Removing unnecessary CUDA dependencies
- Multi-stage build process
### AWS Infrastructure
Complete infrastructure deployed via CloudFormation:
- **ECS Fargate**: Serverless container orchestration
- **Application Load Balancer**: HTTPS termination and routing
- **ACM Certificate**: Automatic SSL/TLS for custom domain
- **CloudWatch**: Logging and monitoring
- **ECR**: Docker image registry
Estimated cost: ~$50/month
## Contributing
1. Fork the repository
2. Create a feature branch
3. Make your changes
4. Add tests if applicable
5. Submit a pull request
See [CONTRIBUTING.md](CONTRIBUTING.md) for details.
## License
MIT License - See LICENSE file for details.
## Documentation
- [Deployment Guide](DEPLOYMENT.md) - Complete AWS deployment instructions
- [Web UI Guide](WEB_UI_GUIDE.md) - Web interface and voice features
- [Quick Start](QUICKSTART_WEB_UI.md) - Get started in 5 minutes
- [Domain Setup](DOMAIN_SETUP.md) - Custom domain configuration
- [Implementation Summary](IMPLEMENTATION_SUMMARY.md) - Technical details
## Live Demo
π **Production Instance**: https://vsiwach.live (with HTTPS and voice support)
---
Built with β€οΈ using MCP, ChromaDB, FastAPI, and OpenAI
This server cannot be deployed
Maintenance
ActivityInactive
ResponsivenessNo recent community issues