feat: Implementar PWA, Analytics, Reportes PDF y mejoras OCR
FASE 1 - PWA y Frontend: - Crear templates/base.html, dashboard.html, analytics.html, executive.html - Crear static/css/main.css con diseño responsivo - Agregar static/js/app.js, pwa.js, camera.js, charts.js - Implementar manifest.json y service-worker.js para PWA - Soporte para captura de tickets desde cámara móvil FASE 2 - Analytics: - Crear módulo analytics/ con predictions.py, trends.py, comparisons.py - Implementar predicción básica con promedio móvil + tendencia lineal - Agregar endpoints /api/analytics/trends, predictions, comparisons - Integrar Chart.js para gráficas interactivas FASE 3 - Reportes PDF: - Crear módulo reports/ con pdf_generator.py - Implementar SalesReportPDF con generar_reporte_diario y ejecutivo - Agregar comando /reporte [diario|semanal|ejecutivo] - Agregar endpoints /api/reports/generate y /api/reports/download FASE 4 - Mejoras OCR: - Crear módulo ocr/ con processor.py, preprocessor.py, patterns.py - Implementar AmountDetector con patrones múltiples de montos - Agregar preprocesador adaptativo con pipelines para diferentes condiciones - Soporte para corrección de rotación (deskew) y threshold Otsu Dependencias agregadas: - reportlab, matplotlib (PDF) - scipy, pandas (analytics) - imutils, deskew, cachetools (OCR) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
15
sales-bot/analytics/__init__.py
Normal file
15
sales-bot/analytics/__init__.py
Normal file
@@ -0,0 +1,15 @@
|
||||
"""
|
||||
Analytics module for Sales Bot
|
||||
Provides predictions, trends, and performance analysis
|
||||
"""
|
||||
|
||||
from .predictions import prediccion_basica, calcular_tendencia
|
||||
from .trends import TrendAnalyzer
|
||||
from .comparisons import ComparisonAnalyzer
|
||||
|
||||
__all__ = [
|
||||
'prediccion_basica',
|
||||
'calcular_tendencia',
|
||||
'TrendAnalyzer',
|
||||
'ComparisonAnalyzer'
|
||||
]
|
||||
Reference in New Issue
Block a user