How nathsanfer/datavision_insights works
CTI Insights is a web application for turning commercial Excel spreadsheets into standardized customer records, database-backed analysis, dashboards, and strategic insights. The main workflow runs from user upload through server-side validation and Python ETL to stored results; users then view dashboards and insights. The frontend also supports login, registration, profile management, and upload history, while administrators manage accounts. Edges follow the README and shown source references/calls; some controller and integration wiring is unsampled, so uncertain links are marked dashed.
Main entry points: api.js HTTP client · main.py Batch processing · Dashboard.vue Dashboard · AuthService.java Authentication service
Components 28
Web interface
- Spreadsheet upload
frontend-vue/src/views/Upload.vue - Dashboard
frontend-vue/src/views/Dashboard.vue - Insights view
frontend-vue/src/views/Insights.vue - Batch history
frontend-vue/src/views/Historico.vue - Login and register
frontend-vue/src/views/Login.vue - Profile
frontend-vue/src/views/Profile.vue - Upload state
frontend-vue/src/stores/uploadStore.js - Session state
frontend-vue/src/stores/auth.js - HTTP client
frontend-vue/src/services/api.js
API and accounts
- REST API
backend-java/src/main/java/com/cti/backend_java/controllers/UploadController.java - Authentication routes
backend-java/src/main/java/com/cti/backend_java/controllers/AuthController.java - Admin user routes
backend-java/src/main/java/com/cti/backend_java/controllers/AdminUsuarioController.java - Authentication service
backend-java/src/main/java/com/cti/backend_java/services/AuthService.java - JWT service
backend-java/src/main/java/com/cti/backend_java/security/JwtService.java - User repository
backend-java/src/main/java/com/cti/backend_java/repository/UsuarioRepository.java - Insights routes
backend-java/src/main/java/com/cti/backend_java/controllers/InsightsController.java - Batch history routes
backend-java/src/main/java/com/cti/backend_java/controllers/LotesController.java
Upload processing
- Upload orchestration
backend-java/src/main/java/com/cti/backend_java/services/UploadService.java - Row validation
backend-java/src/main/java/com/cti/backend_java/services/ClienteValidacaoService.java - Python ETL bridge
backend-java/src/main/java/com/cti/backend_java/services/PythonEtlService.java
Analysis and storage
- Python processing API
analytics-python/api.py - Batch processing
analytics-python/main.py - Data cleaning
analytics-python/limpeza.py - Statistical analysis
analytics-python/analise.py - Insight generation
analytics-python/insights.py - Batch data storage
analytics-python/banco.py
Other components
- User
- PostgreSQL
Connections 33
- User → Spreadsheet upload: uploads spreadsheet
- User → Login and register: uses account access
- User → Dashboard: views results
- Spreadsheet upload → Upload state: manages upload
- Dashboard → Upload state: uses upload state
frontend-vue/src/views/Dashboard.vue - Upload state → HTTP client: requests data
frontend-vue/src/stores/uploadStore.js - Dashboard → HTTP client: requests data
frontend-vue/src/views/Dashboard.vue - Insights view → HTTP client: requests insights
- Batch history → HTTP client: requests history
- Profile → HTTP client: requests profile
frontend-vue/src/views/Profile.vue - Login and register → Session state: updates session
- Session state → HTTP client: sends login
frontend-vue/src/stores/auth.js - HTTP client → REST API: calls REST API
- REST API → Upload orchestration: delegates upload
- Authentication routes → Authentication service: delegates authentication
backend-java/src/main/java/com/cti/backend_java/controllers/AuthController.java - Authentication routes → User repository: reads current user
backend-java/src/main/java/com/cti/backend_java/controllers/AuthController.java - Authentication service → User repository: reads and saves users
backend-java/src/main/java/com/cti/backend_java/services/AuthService.java - Admin user routes → User repository: manages users
backend-java/src/main/java/com/cti/backend_java/controllers/AdminUsuarioController.java - Authentication service → JWT service: issues tokens
backend-java/src/main/java/com/cti/backend_java/services/AuthService.java - Upload orchestration → Row validation: validates rows
backend-java/src/main/java/com/cti/backend_java/services/UploadService.java - Upload orchestration → Python ETL bridge: sends valid rows
backend-java/src/main/java/com/cti/backend_java/services/UploadService.java - Python ETL bridge → Python processing API: forwards batch
- Python processing API → Batch processing: invokes processing
analytics-python/main.py - Batch processing → Data cleaning: cleans rows
analytics-python/main.py - Batch processing → Statistical analysis: calculates metrics
analytics-python/main.py - Statistical analysis → Data cleaning: uses cleaned data
analytics-python/analise.py - Statistical analysis → Insight generation: generates insights
analytics-python/analise.py - Batch processing → Batch data storage: stores batch results
analytics-python/main.py - Batch data storage → PostgreSQL: writes records
- Insights routes → HTTP client: serves insight data
- Batch history routes → HTTP client: serves batch history
- Insights view → Insights routes: loads insights
- Batch history → Batch history routes: loads batches