Last Updated: 2025-10-19 | Version: 2.1 | Status: ✅ QWEN3 32B ACTIVE
Latest Update (2025-10-19): The system now uses Qwen3 32B for advanced reasoning in critical agents:
- 🎯 Coordinator (Robert Thompson) - Strategic decisions
- 📊 Trend Agent (Dr. Michael Rodriguez) - Statistical forecasting with deep analysis
- 💼 Research Agent (Jennifer Park) - Financial analysis with CFA-level rigor
Qwen3 32B Advantages:
- ✅ Enhanced reasoning capabilities (surpasses QwQ across mathematics, code, logic)
- ✅ Dual-mode capability (thinking + non-thinking modes)
- ✅ 131K context window (full capability on Groq)
- ✅ Superior statistical forecasting with quantitative methods
- ✅ Detailed competitive analysis with specific metrics
Technical Details:
- Model ID:
qwen/qwen3-32b(replaces deprecatedqwen-qwq-32b) - Response Time: 3-4 seconds per analysis
- Cost: 100% FREE on Groq ($0.29/M input tokens if paid tier needed)
Your app uses a 100% FREE & OPEN SOURCE agentic AI system with 11 specialized agents:
┌────────────────────────────────────────────────────────────────────┐
│ MULTI-AGENT AI SYSTEM ARCHITECTURE (11 AGENTS) │
├────────────────────────────────────────────────────────────────────┤
│ │
│ ┌────────────────────────────────────────────────────────────┐ │
│ │ 🧠 COORDINATOR AGENT (Qwen QwQ-32B via Groq) ⭐ NEW! │ │
│ │ Robert Thompson, MBA - Chief Product Officer │ │
│ │ - Advanced reasoning for strategic decisions │ │
│ │ - Orchestrates all 10 specialist agents │ │
│ │ - Synthesizes findings with deep analysis │ │
│ └────────────────────────────────────────────────────────────┘ │
│ │ │
│ ┌─────────────────┼─────────────────┐ │
│ ▼ ▼ ▼ │
│ ┌──────────────────┐ ┌──────────────────┐ ┌────────────────┐ │
│ │ SCANNER AGENT │ │ 🧠 TREND AGENT │ │ 🧠 RESEARCH │ │
│ │ Dr. Sarah Chen │ │ Dr. Rodriguez │ │ Jennifer Park │ │
│ │ │ │ │ │ MBA/CFA │ │
│ │ Llama-3.3 70B │ │ Qwen QwQ-32B ⭐ │ │ Qwen QwQ-32B ⭐ │ │
│ │ (Groq) │ │ (Groq) │ │ (Groq) │ │
│ │ │ │ │ │ │ │
│ │ Tasks: │ │ Tasks: │ │ Tasks: │ │
│ │ • SEO keywords │ │ • Trend forecast │ │ • Profit calc │ │
│ │ • Categorize │ │ • Statistical │ │ • Financial │ │
│ │ • Description │ │ analysis │ │ modeling │ │
│ │ • Target market │ │ • Hype cycle │ │ • CFA-level │ │
│ │ │ │ • Demand predict │ │ analysis │ │
│ └──────────────────┘ └──────────────────┘ └────────────────┘ │
│ │
│ + 7 MORE SPECIALIST AGENTS (Llama-3.1 8B): │
│ • Quality Officer • Pricing Director • Viral Specialist │
│ • Competition Analyst • Supply Chain • Psychology • Data Science │
│ │
│ All agents run SEQUENTIALLY with 0.8s delays (rate limit safe) │
└────────────────────────────────────────────────────────────────────┘
-
🧠 Qwen3 32B (Groq) ⭐ UPGRADED - Advanced Reasoning Model
- Coordinator Agent (Robert Thompson)
- Trend Agent (Dr. Michael Rodriguez)
- Research Agent (Jennifer Park)
-
Llama-3.3 70B (Groq) - High Quality Analysis
- Scanner Agent (Dr. Sarah Chen)
-
Llama-3.1 8B Instant (Groq) - Fast & Efficient
- 7 Specialist Agents (Quality, Pricing, Viral, Competition, Supply, Psychology, Data Science)
💰 Cost: 100% FREE - All models run on Groq's free tier!
When a product is discovered:
-
Phase 1: Three specialist agents analyze the product in parallel:
- Scanner Agent: Extracts features, keywords, optimized descriptions
- Trend Agent: Analyzes market trends, seasonality, demand trajectory
- Research Agent: Evaluates profit potential, competition, pricing
-
Phase 2: Coordinator Agent (Qwen) synthesizes all findings:
- Reviews all specialist reports
- Makes informed decisions using advanced reasoning
- Provides final recommendations
- Includes confidence scores
-
Fallback System: Multiple layers of reliability:
- Groq models tried first (fastest)
- HuggingFace models as backup
- Rule-based analysis if all AI fails
Create or update C:\Users\timud\Documents\product-trend-automation\.env:
# ==================== AI SERVICE API KEYS ====================
# ALL FREE & OPEN SOURCE MODELS ONLY
# Groq API (FREE & FAST - REQUIRED)
GROQ_API_KEY=your_groq_api_key_here
# Hugging Face API (FREE - REQUIRED)
HUGGINGFACE_API_KEY=your_huggingface_api_key_here
# Google Trends (No API key needed)
GOOGLE_TRENDS_ENABLED=True
# Database
DATABASE_URL=postgresql://postgres:postgres@localhost:5432/product_trends
# Redis
REDIS_URL=redis://localhost:6379/0
# Security
SECRET_KEY=CHANGE-THIS-TO-A-SECURE-RANDOM-STRING-IN-PRODUCTION
ALGORITHM=HS256
# Compliance
REQUIRE_MANUAL_APPROVAL=False
AUTO_POST_ENABLED=Falsecd C:\Users\timud\Documents\product-trend-automation
docker-compose up -dTerminal 1 - Backend:
cd C:\Users\timud\Documents\product-trend-automation\backend
python -m venv venv
venv\Scripts\activate
pip install -r requirements.txt
uvicorn api.main:app --reloadTerminal 2 - Frontend:
cd C:\Users\timud\Documents\product-trend-automation\frontend
npm install
npm run devTerminal 3 - Celery Worker (for background AI analysis):
cd C:\Users\timud\Documents\product-trend-automation\backend
venv\Scripts\activate
celery -A tasks.celery_app worker --loglevel=info --pool=solo- Open browser:
http://localhost:3000 - Click "Scan Trends Now" button
- Watch the multi-agent system in action in the backend logs
- Products will appear in "Pending Review" after AI analysis
When the agentic system runs, you'll see:
============================================================
🤖 MULTI-AGENT AI SYSTEM ACTIVATED 🤖
✓ Coordinator: Qwen (via Groq)
✓ Scanner Agent: Mixtral-8x7B (Hugging Face)
✓ Trend Agent: Mistral-7B (Hugging Face)
✓ Research Agent: Llama-3-8B (Hugging Face)
============================================================
============================================================
[AgenticAI] Starting multi-agent analysis for: Smart LED Light Bulbs
============================================================
[Phase 1] Deploying specialist agents...
[Scanner Agent] Analyzing product details...
[Trend Agent] Analyzing market trends...
[Research Agent] Evaluating market opportunity...
[Scanner Agent] ✓ Analysis complete (Llama-3.3 70B via Groq)
[Trend Agent] ✓ Trend analysis complete (DeepSeek R1 via Groq)
[Research Agent] ✓ Market research complete (Llama-3.2 11B)
[Phase 1] ✓ All specialist agents completed
[Phase 2] Coordinator agent synthesizing results...
[Coordinator Agent] ✓ Final decision: APPROVE
[Coordinator Agent] Confidence: 87%
============================================================
[AgenticAI] ✓ Multi-agent analysis complete!
============================================================
- Scan for trending products
- View products by status (All, Pending, Approved, Posted)
- NEW: Rejected products excluded from "All" view
- Analytics dashboard with stats
- NEW: Full product management interface
- Search products by title, description, or category
- Filter by status with counts
- View rejected products in separate tab
- ✅ Approve products
- ❌ Reject products (with reason tracking)
- 📤 Post to platforms (Amazon, eBay, TikTok, etc.)
- 100% Free: No OpenAI/Anthropic costs
- Parallel Processing: All agents run simultaneously
- Advanced Models: Using state-of-the-art open-source LLMs
- Fallback System: Multiple layers of redundancy
- Specialized Agents: Each agent is an expert in its domain
- Coordinator Reasoning: Qwen provides human-like decision making
- Qwen-2.5 72B: 6,000 requests/day
- Llama-3.3 70B: 14,400 requests/day
- DeepSeek R1: 14,400 requests/day
- Speed: Up to 800 tokens/second!
- Mixtral 8x7B: Unlimited (rate limited)
- Phi-3 Medium: Unlimited (rate limited)
- Llama-3.2 11B: Unlimited (rate limited)
backend/services/ai_analysis/agentic_system.py- Multi-agent AI systemAGENTIC_AI_SETUP.md- This file
backend/api/main.py- Fixed search endpoint error handlingbackend/services/ai_analysis/product_analyzer.py- Integrated agentic systemfrontend/src/pages/index.tsx- Fixed rejected products filterfrontend/src/pages/products.tsx- Full implementation with search.env.example- Added Groq and HuggingFace API key docs
- Start the app using the instructions above
- Click "Scan Trends Now" to discover products
- Watch the logs to see the multi-agent system in action
- Review products and approve/reject them
- Post to platforms (configure platform API keys first)
- ✅ FIXED: Error now properly handled and reported
- ✅ FIXED: Excluded from "All Products" view by default
- Check
.envfile has bothGROQ_API_KEYandHUGGINGFACE_API_KEY - Verify API keys are valid
- Check backend logs for initialization message
- Normal: HuggingFace models take 10-20s to load first time
- Solution: System automatically retries with 10s delay
- Alternative: Groq models load instantly (used first)
- Groq is faster: Scanner and Trend agents try Groq first for speed
- HuggingFace is reliable: Automatically falls back if Groq is busy
- Parallel = Fast: All 3 specialist agents run at the same time
- Confidence scores: Coordinator provides transparency on decisions
- Audit trail: All agent reports saved for review
No OpenAI costs, no Anthropic costs, just pure open-source AI power! 🚀
Questions? Check the logs or review the code in:
backend/services/ai_analysis/agentic_system.pybackend/services/ai_analysis/product_analyzer.py