How john-helder/email-automator works
Email Automator is a FastAPI-backed email analysis and reply application with a simple web dashboard. Users can register or log in, then submit email text for category-based NLP, structural analysis, or an AI-generated reply; the dashboard is documented to display results. Authentication and the database flow are supported by sampled source. Several analysis modules and frontend scripts were not sampled, so their internal wiring is shown only where supported by source or README capabilities.
Main entry points: ia_routes.py Email API routes · auth_router.py Authentication routes · auth_service.py Auth service · main.py FastAPI application
Components 21
Web interface
- Dashboard
frontend/dashboard.html - Login and registration UI
frontend/auth.js - Analysis UI
frontend/ia.js - Reply dashboard script
frontend/app.js
API and routing
- FastAPI application
src/main.py - Email API routes
src/routes/ia_routes.py
Authentication
- Authentication routes
src/auth/routes/auth_router.py - Auth controller
src/auth/controller/auth_controller.py - Auth service
src/auth/service/auth_service.py - User model
src/auth/models/user_model.py - Password and JWT security
src/auth/security
Email intelligence
- NLP classification and replies
src/routes/nlp_utils.py - Email analysis controller
src/controllers/email_controller.py - Structural email analyzer
src/services/email_analyzer.py - AI reply service
src/services/auto_responder.py - AI request controller
src/controllers/ia_controller.py - Groq response service
src/services/ia_service.py
State and AI integration
- SQLite database
src/database.py - Groq client setup
src/config/groq_cliente.py
Other components
- User
- Groq API
Connections 23
- User → Dashboard: uses
- User → Login and registration UI: registers or logs in
- Dashboard → Reply dashboard script: runs
- Login and registration UI → Authentication routes: sends credentials
- Analysis UI → Email API routes: submits email
- Reply dashboard script → Email API routes: requests reply
- FastAPI application → Authentication routes: mounts
- FastAPI application → Email API routes: mounts
- Authentication routes → Auth controller: dispatches
- Auth controller → Auth service: calls
- Auth service → User model: queries and persists
- Auth service → SQLite database: uses session
- Authentication routes → SQLite database: gets session
- Auth service → Password and JWT security: hashes and issues token
- Authentication routes → Password and JWT security: validates JWT
- Email API routes → NLP classification and replies: classifies and drafts
- Email API routes → Email analysis controller: dispatches analysis
- Email analysis controller → Structural email analyzer: calls
- Email API routes → AI reply service: requests reply
- Email API routes → AI request controller: dispatches prompt
- Groq response service → Groq client setup: gets client
- Groq client setup → Groq API: creates client
- Groq response service → Groq API: sends prompt