Overview
Migrate the second batch of 5 health assessment tools from FastMCP to Official MCP SDK, ensuring dynamic FAISS vector DB integration.
Tools to Migrate
create_health_protocol - Personalized health recommendations with optional parameters
analyze_supplement_stack - Supplement interaction analysis with list parameters
analyze_health_topic - Comprehensive topic analysis with FAISS search
analyze_forum_trends - Forum discussion analysis
trace_topic_evolution - Topic evolution over time
Key Requirements
- Dynamic FAISS Integration: All tools must fetch results dynamically from FAISS vector DB, not static strings
- Complex Parameters: Handle optional parameters, enums, and list types
- Search Integration: Maintain knowledge_searcher functionality
- Performance: Keep response time under 3 seconds
- Feature Flag:
ENABLE_BATCH2_MIGRATION for progressive rollout
Acceptance Criteria
Technical Approach
- Follow patterns from Batch 1 implementation
- Use Official MCP SDK types.Tool for registration
- Implement in handle_call_tool() with dynamic FAISS queries
- Ensure knowledge_searcher is properly initialized
Related
Testing
Tests will be added to validate:
- Dynamic FAISS retrieval
- Parameter handling variations
- Search functionality
- Performance metrics
- Integration with Batch 1