Self-host a Telegram customer support bot that answers from your Google Docs
Run a nightly ingestion that chunks docs and writes Gemini embeddings to Pinecone
Keep multi-turn memory of each customer chat in Postgres
Reuse the n8n workflows as a starting point for a Slack or WhatsApp agent
You must wire up Google Docs, Gemini API, Pinecone, Postgres, and Telegram bot credentials in n8n before the workflows run end to end.
This repository is a template for an automated customer support agent. It is not a single program you install; it is a recipe for wiring together several existing online services so that they answer customer questions on behalf of a business. The visible interface is Telegram, the popular messaging app, so a user simply chats with a Telegram account and gets answers as if a human support rep were typing on the other end. The glue that holds the pieces together is n8n, a workflow tool that lets you connect different services using a visual diagram instead of writing a full application. There are two workflows in the project. The first one takes business documents stored in Google Docs, splits them into small chunks, and turns each chunk into a numerical fingerprint called an embedding using a Google AI model named Gemini. Those fingerprints are saved in Pinecone, a database designed to search by meaning rather than by exact word match. The second workflow runs every time a customer sends a Telegram message. It looks up the most relevant pieces of company knowledge in Pinecone, feeds them to Gemini together with the customer's question, and sends Gemini's reply back to the user. A Postgres database keeps track of past messages so the agent remembers what was said earlier in the same conversation. This pattern, where a language model is grounded in your own documents, is commonly called RAG, short for retrieval augmented generation. The README also lists planned additions, including confidence scoring on answers, better ranking of retrieved snippets, and support for WhatsApp, web chat, and Slack.
Generated 2026-05-22 · Model: sonnet-4-6 · Verify against the repo before relying on details.