Urtzi Alfaro
8bfe4f2dd7
Fix Demo enterprise
2025-12-17 13:03:52 +01:00
Urtzi Alfaro
9f3b39bd28
Add comprehensive documentation and final improvements
...
Documentation Added:
- AI_INSIGHTS_DEMO_SETUP_GUIDE.md: Complete setup guide for demo sessions
- AI_INSIGHTS_DATA_FLOW.md: Architecture and data flow diagrams
- AI_INSIGHTS_QUICK_START.md: Quick reference guide
- DEMO_SESSION_ANALYSIS_REPORT.md: Detailed analysis of demo session d67eaae4
- ROOT_CAUSE_ANALYSIS_AND_FIXES.md: Complete analysis of 8 issues (6 fixed, 2 analyzed)
- COMPLETE_FIX_SUMMARY.md: Executive summary of all fixes
- FIX_MISSING_INSIGHTS.md: Forecasting and procurement fix guide
- FINAL_STATUS_SUMMARY.md: Status overview
- verify_fixes.sh: Automated verification script
- enhance_procurement_data.py: Procurement data enhancement script
Service Improvements:
- Demo session cleanup worker: Use proper settings for Redis configuration with TLS/auth
- Procurement service: Add Redis initialization with proper error handling and cleanup
- Production fixture: Remove duplicate worker assignments (cleaned 56 duplicates)
- Orchestrator fixture: Add purchase order metadata for better tracking
Impact:
- Complete documentation for troubleshooting and setup
- Improved Redis connection handling across services
- Clean production data without duplicates
- Better error handling and logging
🤖 Generated with Claude Code (https://claude.com/claude-code )
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com >
2025-12-16 11:32:45 +01:00
Urtzi Alfaro
dd79e6d85e
Fix procurement data structure and add price trends
...
Fixed critical structural issues in procurement fixture:
1. **Removed duplicate nested items** (32 items):
- Previous enhancement script incorrectly added 'items' arrays
inside purchase_orders
- Procurement service uses separate purchase_order_items table
- Removed all nested 'items' to match PurchaseOrderItem model
2. **Added price trends to existing PO items** (10 items updated):
- Harina T55: +8% (€0.85 → €0.92)
- Harina T65: +6% (€0.95 → €1.01)
- Mantequilla: +12% (€6.50 → €7.28) - highest increase
- Leche: -3% (€0.95 → €0.92) - seasonal surplus
- Levadura: +4% (€4.20 → €4.37)
- Azúcar: +2% (€1.10 → €1.12) - stable
3. **Recalculated PO totals** based on updated item prices
This enables procurement AI insights:
- Price trend analysis and alerts
- Supplier performance comparison
- Cost optimization recommendations
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com >
2025-12-16 11:01:43 +01:00
Urtzi Alfaro
c566967bea
Add AI insights feature
2025-12-15 21:14:22 +01:00
Urtzi Alfaro
5642b5a0c0
demo seed change 7
2025-12-15 13:39:33 +01:00
Urtzi Alfaro
56a1821256
demo seed change 5
2025-12-14 20:13:59 +01:00
Urtzi Alfaro
82f9622411
demo seed change 4
2025-12-14 19:05:37 +01:00
Urtzi Alfaro
4ae5356ad1
demo seed change 3
2025-12-14 16:04:16 +01:00
Urtzi Alfaro
a030bd14c8
demo seed change 2
2025-12-14 11:58:14 +01:00
Urtzi Alfaro
ff830a3415
demo seed change
2025-12-13 23:57:54 +01:00
Urtzi Alfaro
10c779858a
Fix enum mismatch: Update Python enums and seed data to match database uppercase values
...
- Fixed ProductType enum values from lowercase to uppercase (INGREDIENT, FINISHED_PRODUCT)
- Fixed UnitOfMeasure enum values from lowercase/abbreviated to uppercase (KILOGRAMS, LITERS, etc.)
- Fixed IngredientCategory enum values from lowercase to uppercase (FLOUR, YEAST, etc.)
- Fixed ProductCategory enum values from lowercase to uppercase (BREAD, CROISSANTS, etc.)
- Updated seed data files to use correct uppercase enum values
- Fixed hardcoded enum references throughout the codebase
- This resolves the InvalidTextRepresentationError when inserting inventory data
Generated by Mistral Vibe.
Co-Authored-By: Mistral Vibe <vibe@mistral.ai >
2025-12-13 16:49:04 +01:00