How haricrazy1432-bot/emailautomation works
EmailAutomation centers on processing unread Gmail messages into validated replies, with a Streamlit dashboard that triggers and displays the API workflow. It also provides separate document indexing and semantic-query tools through both an API and a standalone command-line script. The email workflow is implemented twice: in main.py and in rag_api.py. The former references gmail_client although it imports gmail, so that path appears to have a runtime naming issue. RAG edges reflect the shown implementations; the repository’s small README gives no further capability details.
Main entry points: llm_client.py Validate reply · rag_api.py FastAPI service · minimal_rag_chroma.py Standalone RAG tools · main.py Standalone workflow
Components 20
Email processing
- Standalone workflow
main.py - API email workflow
rag_api.py - Fetch email
rag_api.py - Draft reply
llm_client.py - Validate reply
llm_client.py - Rewrite reply
llm_client.py - Send reply
gmail.py
API and dashboard
- Streamlit dashboard
rag_ui.py - FastAPI service
rag_api.py
Document retrieval
- Document extraction
rag_api.py - Document indexing
rag_api.py - Semantic query
rag_api.py - Chroma store
rag_api.py - Standalone RAG tools
minimal_rag_chroma.py - File watcher
minimal_rag_chroma.py
Integrations
- Gmail connector
gmail.py - LLM helpers
llm_client.py
Other components
- Operator
- Gmail service
- Documents
Connections 29
- Operator → Streamlit dashboard: uses
rag_ui.py - Streamlit dashboard → FastAPI service: triggers workflow
rag_ui.py - Streamlit dashboard → Gmail service: reads inbox
rag_ui.py - FastAPI service → API email workflow: invokes
rag_api.py - API email workflow → Fetch email: starts at
rag_api.py - Fetch email → Draft reply: then drafts
rag_api.py - Draft reply → Validate reply: then validates
rag_api.py - Validate reply → Rewrite reply: on failure
rag_api.py - Rewrite reply → Validate reply: revalidates
rag_api.py - Validate reply → Send reply: on approval
rag_api.py - Fetch email → Gmail connector: fetches from
rag_api.py - Send reply → Gmail service: sends via
gmail.py - Gmail connector → Gmail service: calls
gmail.py - Draft reply → LLM helpers: generates with
rag_api.py - Validate reply → LLM helpers: checks with
rag_api.py - Rewrite reply → LLM helpers: rewrites with
rag_api.py - Operator → Standalone workflow: runs directly
main.py - Standalone workflow → Gmail connector: fetches and sends
main.py - Standalone workflow → LLM helpers: drafts and checks
main.py - FastAPI service → Document extraction: indexes uploads
rag_api.py - Documents → Document extraction: uploaded to
rag_api.py - Document extraction → Document indexing: extracts text for
rag_api.py - Document indexing → Chroma store: stores embeddings
rag_api.py - FastAPI service → Semantic query: serves queries
rag_api.py - Semantic query → Chroma store: searches
rag_api.py - Operator → Standalone RAG tools: runs tools
minimal_rag_chroma.py - Documents → Standalone RAG tools: indexes files
minimal_rag_chroma.py - Standalone RAG tools → Chroma store: indexes and queries
minimal_rag_chroma.py - File watcher → Standalone RAG tools: reindexes changes
minimal_rag_chroma.py