AI-powered manufacturing quote system that uses intelligent agents to generate accurate, competitive quotes. This project demonstrates a multi-agent LLM architecture for optimizing quoting processes in manufacturing.
- Multi-Agent AI System utilizing specialized agents for different aspects of quote generation
- Interactive Dashboard with performance metrics and visualization
- Quote Generation with AI-powered pricing strategy and recommendations
- Market Insights for data-driven business decisions
- Semantic Search to find similar historical projects
QuoteGenius uses a collaborative agent architecture:
- Coordinator Agent: Orchestrates the entire quote generation process
- Data Analyst Agent: Analyzes project requirements and historical data
- Quote Generator Agent: Creates detailed quotes with line-item breakdown
- Pricing Optimizer Agent: Maximizes win probability while maintaining margins
- Knowledge Base Agent: Applies business rules and domain expertise
The system leverages vector databases for semantic similarity and structured databases for relational data storage.
- Python 3.9+
- OpenAI API key
- Clone the repository
git clone https://github.com/your-username/QuoteGenius.git
cd QuoteGenius
- Create a virtual environment
python -m venv venv
source venv/bin/activate # On Windows: venv\Scripts\activate
- Install dependencies
pip install -r requirements.txt
- Create a
.env
file with your OpenAI API key
OPENAI_API_KEY=your_api_key_here
Run the application with the following command:
python run.py
For demo mode only (no backend required):
python run.py --ui-only
The dashboard provides an overview of quoting performance with metrics including:
- Total quotes year-to-date
- Win rate with trend
- Average quote value
- Response time statistics
- Navigate to the "Generate Quote" page
- Select a customer or add a new one
- Enter project details and material requirements
- Click "Generate Quote" to start the AI process
- Review the generated quote with pricing breakdown
- Optionally click "Optimize Quote" for AI-driven price optimization
Explore data-driven insights including:
- Price trends by industry
- Win rate analysis by response time and quote value
- Customer portfolio visualization
- Material cost trends and forecasts
The multi-agent system consists of:
-
Coordinator Agent (
agents/coordinator.py
):- Manages workflow between specialized agents
- Delegates tasks and aggregates results
- Provides a unified interface to the API layer
-
Data Analyst Agent (
agents/data_analyst.py
):- Analyzes project requirements
- Retrieves and analyzes historical data
- Identifies patterns and insights
-
Quote Generator Agent (
agents/quote_generator.py
):- Creates detailed quotes with line-item breakdown
- Applies business rules to pricing
- Generates comprehensive documentation
-
Pricing Optimizer Agent (
agents/pricing_optimizer.py
):- Optimizes pricing strategy for maximum win probability
- Balances competitiveness with profitability
- Incorporates market conditions and customer relationship
-
Knowledge Base Agent (
agents/knowledge_base.py
):- Manages domain-specific knowledge
- Applies business rules and policies
- Generates strategic recommendations
-
Vector Database (
db/vector_store.py
):- Stores embeddings for semantic search capabilities
- Enables similarity matching for projects and rules
- Implemented using Chroma vector database
-
Structured Database (
db/structured_db.py
):- Stores relational data (quotes, customers, feedback)
- Tracks quote history and performance
- Implemented using SQLite
The Streamlit-based UI (app_ui.py
) provides:
- Interactive dashboard with performance metrics
- Quote generation interface with dynamic forms
- Visualization of quote breakdown and recommendations
- Historical data analysis and filtering
The FastAPI backend (app.py
) provides:
- RESTful endpoints for quote generation and retrieval
- Integration with the agent system
- Data validation and error handling
- User submits a quote request through the UI
- Request is sent to the API layer
- Coordinator agent receives the request and orchestrates the process:
- Data Analyst agent retrieves similar projects
- Knowledge Base agent provides relevant business rules
- Quote Generator creates the initial quote
- Pricing Optimizer fine-tunes pricing strategy
- Response is returned to the UI for display
- Quote is stored in the database if accepted
The system uses OpenAI's embedding models to convert text into vector embeddings, enabling:
- Semantic search for similar projects
- Relevant business rule retrieval
- Pattern recognition in historical data
Each agent leverages OpenAI's GPT models through structured prompts:
- Data analysis prompts focus on pattern recognition
- Quote generation prompts emphasize completeness and accuracy
- Pricing optimization prompts balance competitiveness and profitability
For demonstration purposes, the system generates realistic mock data:
- Historical quotes with detailed breakdowns
- Customer profiles with relationship history
- Business rules reflecting industry practices
- Material pricing trends over time
- Integration with ERP and CRM systems
- Fine-tuned domain-specific LLM models
- Automated learning from win/loss outcomes
- Competitor analysis capabilities
This project is licensed under the MIT License - see the LICENSE file for details.