Automation library · Lead generation

Review and reply to business emails with Gmail and OpenAI

Started by an arriving email, and works across Email, Gmail, Google Drive and Qdrant. It puts DeepSeek and OpenAI behind a retrieval step, so answers are drawn from documents you supply rather than from the model alone. 22 steps: large, and worth reading before you trust it with anything live.

LargeCalls a model: DeepSeek, OpenAIRetrieval

22 stepsLarge: read it before trusting it with anything live
0Branches: places the flow splits
0Loops or waits
4Services it connects to

The flow

Starts it 1Model 12Logic 2Service 7

The steps in the order they run, from what starts it.

  1. 1Email Trigger (IMAP)Email Read ImapService
  2. 2Embeddings OpenAIEmbeddings Open AiModel
  3. 3OpenAILm Chat Open AiModel
  4. 4When clicking ‘Test workflow’Manual triggerStarts it
  5. 5Token SplitterText Splitter Token SplitterModel
  6. 6Embeddings OpenAI1Embeddings Open AiModel
  7. 7DeepSeek Chat ModelLm Chat Deep SeekModel
  8. 8MarkdownMarkdownLogic
  9. 9Qdrant Vector StoreVector Store QdrantModel
  10. 10Write emailAgentModel
  11. 11Email ReviewerAgentModel
  12. 12Text ClassifierText ClassifierModel
  13. 13Create collectionHttp RequestService
  14. 14Refresh collectionHttp RequestService
  15. 15Default Data LoaderDocument Default Data LoaderModel
  16. 16Qdrant Vector Store1Vector Store QdrantModel
  17. 17Email Summarization ChainChain SummarizationModel
  18. 18Edit FieldsSetLogic
  19. 19Send EmailEmail SendService
  20. 20Get folderGoogle DriveService
  21. 21GmailGmailService
  22. 22Download FilesGoogle DriveService

How it's built

Starts on
An arriving email
Steps
22
Size
Large: read it before trusting it with anything live
Connects to
Email, Gmail, Google Drive, Qdrant
Model
DeepSeek, OpenAI
Retrieval
Answers are drawn from documents you supply, not from the model alone

Questions

What does it need to run?

An n8n account, plus your own Email, Gmail, Google Drive and Qdrant accounts, and a key for DeepSeek and OpenAI. You connect your own accounts after importing it; none are included.

What starts it?

It starts on an arriving email.

Does it use AI?

Yes. It calls DeepSeek and OpenAI. Its answers draw on documents you give it, not on the model alone. Model calls are billed by the provider, not by n8n.

How long does it take to set up?

Take your time. At 22 steps it is large: read it before trusting it with anything live.

How do I import it?

Copy the workflow, open a new workflow in n8n and paste. The steps appear on the canvas, ready for your own accounts.

Before you run it

Nothing here has been tested by us. It is somebody's working automation, read and described from its own steps. Treat the connections it wants as a list of accounts it will touch, and read the 22 steps before you point it at anything that matters.