Automation library · Chat assistants

Self-learning AI assistant with Telegram and Pinecone RAG

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

LargeCalls a model: OpenAIRetrieval

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

The flow

Starts it 2Model 11Logic 5Service 5

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

  1. 1Telegram TriggerTelegram triggerStarts it
  2. 2Embeddings OpenAIEmbeddings Open AiModel
  3. 3Google DocsGoogle Docs ToolService
  4. 4Embeddings OpenAI1Embeddings Open AiModel
  5. 5Recursive Character Text SplitterText Splitter Recursive Character Text SplitterModel
  6. 6Schedule TriggerSchedule triggerStarts it
  7. 7DeepseekLm Chat Open AiModel
  8. 8Window Buffer MemoryMemory Buffer WindowModel
  9. 9SwitchSwitchLogic
  10. 10Pinecone Vector StoreVector Store PineconeModel
  11. 11AI AgentAgentModel
  12. 12Pinecone Vector Store1Vector Store PineconeModel
  13. 13Default Data LoaderDocument Default Data LoaderModel
  14. 14Google Docs1Google DocsService
  15. 15Edit Fields_TextSetLogic
  16. 16DownloadAudioTelegramService
  17. 17OpenAI1Open AiModel
  18. 18TelegramTelegramService
  19. 19Google Docs2Google DocsService
  20. 20Edit FieldsSetLogic
  21. 21OpenAIOpen AiModel
  22. 22Edit Fields_ImageSetLogic
  23. 23Edit Fields_AudioSetLogic

How it's built

Starts on
An incoming Telegram message
Steps
23, with 1 branch
Size
Large: read it before trusting it with anything live
Connects to
Google Docs, Pinecone, Telegram
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 Docs, Pinecone and Telegram 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 Telegram 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 23 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 23 steps before you point it at anything that matters.