An AI-powered investment advisory system that leverages multiple specialized agents orchestrated through LangGraph to provide comprehensive stock analysis and investment recommendations. Now featuring MCP integration, FastAPI backend, real-time dashboard, and enhanced UI capabilities.
Current Version: 1.1.0
Build Date: 2025-09-08
Python Compatibility: 3.8+
License: MIT
- v1.1.0 (2025-09-08): MCP integration, FastAPI backend, Node.js dashboard, enhanced UI, TOML configuration
- v1.0.0 (2025-09-01): Initial release with multi-agent architecture, GROQ integration, and comprehensive analysis
For detailed changelog, see CHANGELOG.md
- Multi-Agent Architecture: News research, financial data analysis, and expert recommendations
- MCP Integration: Model Context Protocol server for enhanced AI capabilities
- Automated Research: Gathers company news and financial data automatically
- AI-Powered Analysis: Synthesizes information into actionable insights
- Structured Outputs: Generates detailed analysis and recommendation reports
- Extensible Design: Easy to add new agents and tools
- CLI Interface: Command-line tool for direct system interaction
- Streamlit Web UI: Interactive web interface with enhanced file management
- FastAPI Backend: REST API for programmatic access and integrations
- Node.js Dashboard: Real-time web dashboard with Socket.IO updates
- Real-time Updates: Live analysis status and progress tracking
- Bulk Operations: Select and manage multiple files simultaneously
- Custom Styling: Comprehensive CSS customization system
- Configuration Management: TOML-based settings with environment override
- Enhanced Error Handling: Robust error recovery and user feedback
- Version Management: Semantic versioning with automated release tools
# Clone the repository
git clone https://github.com/bsoberoi/Investment-Advisor.git
cd Investment-Advisor
# Install Python dependencies
pip install -r requirements.txt
# Install Node.js dependencies (for dashboard)
cd dashboard
npm install
cd ..
# Run setup script
python setup.py
# Or use the new TOML configuration
python setup_config.py
# Create .env file with your API keys
echo "GROQ_API_KEY=your_groq_api_key_here" > .env
echo "GROQ_MODEL=llama-3.1-8b-instant" >> .env
echo "GROQ_TEMPERATURE=0.1" >> .env
# Analyze a stock
python main.py analyze AAPL
# Check version
python main.py version
# Use MCP-enhanced analysis
python main.py analyze AAPL --use-mcp
# Launch the web interface
streamlit run ui/app.py
# Start the REST API server
python run_fastapi.py
# Or
uvicorn api.main:app --reload --host 127.0.0.1 --port 8000
# Start the real-time dashboard
cd dashboard
npm start
# Access at http://localhost:3000
The system uses LangGraph and Groq LLMs to orchestrate four specialized agents:
- News Agent: Gathers company-related news and updates
- Data Agent: Retrieves financial data and statements
- Analyst Agent: Synthesizes information into comprehensive analysis
- Financial Expert Agent: Generates investment recommendations
- Core Engine: LangGraph orchestration with GROQ LLM integration
- MCP Server: Model Context Protocol for enhanced AI capabilities
- FastAPI Backend: REST API with async support and comprehensive endpoints
- Streamlit UI: Interactive web interface with file management
- Node.js Dashboard: Real-time dashboard with Socket.IO communication
- Configuration System: TOML-based settings with environment override
The system generates comprehensive outputs:
Analysis.md
: Detailed financial and contextual analysisRecommendation.md
: Buy/Hold/Sell recommendation with reasoning- Real-time Status: Live updates via Socket.IO in the dashboard
- API Responses: Structured JSON responses from FastAPI endpoints
- Log Files: Comprehensive logging for debugging and monitoring
Set these in your .env
file:
GROQ_API_KEY
(required)GROQ_MODEL
(optional, default:llama-3.1-8b-instant
)GROQ_TEMPERATURE
(optional, default:0.1
)
The system now supports comprehensive TOML configuration via config.toml
:
[project]
name = "Investment Advisor"
version = "1.1.0"
[api_keys]
groq_api_key = "your_groq_api_key_here"
[server]
host = "127.0.0.1"
port = 8000
dashboard_port = 3000
[mcp]
server_enabled = true
client_timeout = 60
See CONFIGURATION_GUIDE.md for detailed configuration options.
POST /analyze
- Submit stock analysis requestGET /analyze/{task_id}
- Get analysis resultsGET /analyze/{task_id}/status
- Check analysis status
GET /health
- Health checkGET /version
- Version informationGET /status
- System statusGET /files
- List analysis filesGET /files/{filename}
- Download specific file
# Submit analysis
curl -X POST "http://localhost:8000/analyze" \
-H "Content-Type: application/json" \
-d '{"symbol": "AAPL", "use_mcp": true}'
# Check status
curl "http://localhost:8000/analyze/{task_id}/status"
# Get results
curl "http://localhost:8000/analyze/{task_id}"
See FASTAPI_IMPLEMENTATION.md for complete API documentation.
The system includes comprehensive version management tools:
# Show current version information
python main.py version
# Show detailed version history
python version_manager.py --show
# Create a new release tag
python version_manager.py --tag 1.2.0
# List all git tags
python version_manager.py --list-tags
# Check git repository status
python version_manager.py --git-status
- Semantic Versioning: Follows MAJOR.MINOR.PATCH format
- Git Tagging: Automatic tag creation for releases
- Changelog: Comprehensive change tracking in CHANGELOG.md
- Build Information: Version, build date, and author tracking
- CHANGELOG.md - Detailed version history and changes
- CONFIGURATION_GUIDE.md - TOML configuration system
- FASTAPI_IMPLEMENTATION.md - API implementation guide
- STREAMLIT_CSS_GUIDE.md - UI customization guide
- USAGE_GUIDE.md - Complete usage instructions
- Technical_Design_Investment_Advisor.md - System architecture
- MCP_INTEGRATION_SUMMARY.md - MCP integration details
- dashboard/README.md - Node.js dashboard documentation
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature
) - Commit your changes (
git commit -m 'Add amazing feature'
) - Push to the branch (
git push origin feature/amazing-feature
) - Open a Pull Request
MIT License - see LICENSE file for details.