Cheaper, faster, accurate answers with memory summarization & dynamic routing!
Ready for 3.0What this workflow does
This AI workflow has 25 nodes and runs manually, when you click “Execute workflow” (plus 1 other trigger). Along the way it connects Model Selector, Google Gemini Chat Model, Postgres and Telegram and 1 more.
How it runs
Trigger: Manually, when you click “Execute workflow” (plus 1 other trigger).
- Create Chat Memory Table (Postgres): run a query
- Input Message Router (Switch): routes items into 2 branches
- Typing… (Telegram): send chat action
- get_message (text) (Edit Fields (Set)): sets 2 fields: message, chat_id
- Download Voice Message (Telegram): work with file
- get_error_message (Edit Fields (Set)): sets 2 fields: message, chat_id
- Normalize input (Edit Fields (Set)): sets 2 fields: message, chat_id
- Fix mime (Code): runs custom JavaScript code
- Get Chat Memory (Postgres): select
- Analyze voice message (Google Gemini): analyze (audio)
…plus 7 more steps. See the full node list below.
Services it uses
Other Telegram + Google Gemini templates (354) · Other Telegram + PostgreSQL templates (70) · Other Google Gemini + PostgreSQL templates (47)
Before you upgrade to n8n 3.0
Nothing in this workflow is removed in n8n 3.0, so it should import and run after the upgrade.
Nodes used (14)
- Model Selector
@n8n/n8n-nodes-langchain.modelSelector - Structured Output Parser
@n8n/n8n-nodes-langchain.outputParserStructured - Google Gemini Chat Model
@n8n/n8n-nodes-langchain.lmChatGoogleGemini - Postgres
n8n-nodes-base.postgres - Code
n8n-nodes-base.code - Telegram
n8n-nodes-base.telegram - Edit Fields (Set)
n8n-nodes-base.set - Google Gemini
@n8n/n8n-nodes-langchain.googleGemini - Switch
n8n-nodes-base.switch - Telegram Trigger
n8n-nodes-base.telegramTrigger - Aggregate
n8n-nodes-base.aggregate - AI Agent
@n8n/n8n-nodes-langchain.agent - Manual Trigger
n8n-nodes-base.manualTrigger - Basic LLM Chain
@n8n/n8n-nodes-langchain.chainLlm
From the author
🤖💬 Smart Telegram AI Assistant with Memory Summarization & Dynamic Model Selection > Optimize your AI workflows, cut costs, and get faster, more accurate answers. --- 📋 Description Tired of expensive AI calls, slow responses, or bots that forget your…