Automation library · Documents and files

Multimodal Political AI Chatbot for WhatsApp: Text, Voice

Started by an incoming WhatsApp message, and works across Google Drive, Pinecone and WhatsApp. It puts OpenAI behind a retrieval step, so answers are drawn from documents you supply rather than from the model alone. 37 steps, 3 branches: large, and worth reading before you trust it with anything live.

LargeCalls a model: OpenAIRetrieval

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

The flow

Starts it 3Model 14Logic 8Service 12

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

  1. 1WhatsApp TriggerWhats App triggerStarts it
  2. 2OpenAI Chat ModelLm Chat Open AiModel
  3. 3Simple MemoryMemory Buffer WindowModel
  4. 4Recursive Character Text SplitterText Splitter Recursive Character Text SplitterModel
  5. 5Google Drive File UpdatedGoogle Drive triggerStarts it
  6. 6Google Drive File CreatedGoogle Drive triggerStarts it
  7. 7Embeddings OpenAI1Embeddings Open AiModel
  8. 8Embeddings OpenAI2Embeddings Open AiModel
  9. 9OpenAI Chat Model1Lm Chat Open AiModel
  10. 10Input typeSwitchLogic
  11. 11AI Agent1AgentModel
  12. 12Default Data Loader1Document Default Data LoaderModel
  13. 13Download File From Google DriveGoogle DriveService
  14. 14Pinecone Vector StoreVector Store PineconeModel
  15. 15Pinecone Vector Store (Retrieval)Vector Store PineconeModel
  16. 16Vector Store ToolTool Vector StoreModel
  17. 17TextSetLogic
  18. 18Get Audio UrlWhats AppService
  19. 19Get Image UrlWhats AppService
  20. 20Only PDF FileIfLogic
  21. 21Not supportedWhats AppService
  22. 22From audio to audio?IfLogic
  23. 23Download AudioHttp RequestService
  24. 24Download ImageHttp RequestService
  25. 25Get File UrlWhats AppService
  26. 26Incorrect formatWhats AppService
  27. 27Generate Audio ResponseOpen AiModel
  28. 28Send messageWhats AppService
  29. 29Transcribe AudioOpen AiModel
  30. 30Analyze ImageOpen AiModel
  31. 31Download FileHttp RequestService
  32. 32Fix mimeType for AudioCodeLogic
  33. 33AudioSetLogic
  34. 34ImageSetLogic
  35. 35Extract from FileExtract From FileService
  36. 36Send audioWhats AppService
  37. 37FileSetLogic

How it's built

Starts on
An incoming WhatsApp message
Steps
37, with 3 branches
Size
Large: read it before trusting it with anything live
Connects to
Google Drive, Pinecone, WhatsApp
Model
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 Google Drive, Pinecone and WhatsApp accounts, and a key for OpenAI. You connect your own accounts after importing it; none are included.

What starts it?

It starts on an incoming WhatsApp message.

Does it use AI?

Yes. It calls 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 37 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 37 steps before you point it at anything that matters.