{"product_id":"n8n-rag-telegram-bot-supabase-togetherai-openrouter","title":"n8n RAG Telegram Bot: Supabase + TogetherAI + OpenRouter","description":"\u003ch3\u003eTurn your Google Docs into a RAG-ready Telegram chatbot—powered by Supabase + TogetherAI + OpenRouter in n8n\u003c\/h3\u003e\n\u003cp\u003eThis n8n RAG Telegram Bot workflow fetches content from Google Docs, converts it into vector embeddings, stores them in Supabase, and then answers chat queries using retrieval from your embedded document knowledge.\u003c\/p\u003e\n\n\u003ch3\u003eWhat this workflow does\u003c\/h3\u003e\n\u003cul\u003e\n  \u003cli\u003e\n\u003cb\u003eRun once to build your RAG knowledge base:\u003c\/b\u003e the first workflow is designed to be executed only one time. It retrieves your Google Docs content, splits it into chunks, creates embeddings for each chunk, and saves everything into the Supabase \u003ci\u003eembed\u003c\/i\u003e table.\u003c\/li\u003e\n  \u003cli\u003e\n\u003cb\u003eChunk and embed the document:\u003c\/b\u003e using a \u003cb\u003ecode\u003c\/b\u003e node, the document text is sliced into \u003cb\u003e1000-character chunks\u003c\/b\u003e for processing. For each chunk, an \u003cb\u003ehttpRequest\u003c\/b\u003e node calls the \u003cb\u003eTogetherAI embedding API\u003c\/b\u003e to generate vector embeddings.\u003c\/li\u003e\n  \u003cli\u003e\n\u003cb\u003eStart chat-based retrieval:\u003c\/b\u003e the second workflow triggers on a user chat message (\u003cb\u003echatTrigger\u003c\/b\u003e) and begins by sending an initial greeting.\u003c\/li\u003e\n  \u003cli\u003e\n\u003cb\u003eCreate embeddings for incoming queries:\u003c\/b\u003e it generates embeddings for the user’s message via an \u003cb\u003ehttpRequest\u003c\/b\u003e call to the TogetherAI embeddings endpoint, enabling embedding-based searching against the stored document vectors.\u003c\/li\u003e\n\u003c\/ul\u003e\n\n\u003ch3\u003eUse cases\u003c\/h3\u003e\n\u003cul\u003e\n  \u003cli\u003eAnswer questions inside a Telegram chat using knowledge from a Google Docs policy, SOP, or product documentation.\u003c\/li\u003e\n  \u003cli\u003eEnable SaaS support workflows where your internal docs are indexed once, then reused for fast Q\u0026amp;A.\u003c\/li\u003e\n  \u003cli\u003eBuild a lightweight RAG system for teams that want document-grounded responses without manual indexing.\u003c\/li\u003e\n\u003c\/ul\u003e\n\n\u003ch3\u003eTechnical details\u003c\/h3\u003e\n\u003cul\u003e\n  \u003cli\u003e\n\u003cb\u003en8n nodes:\u003c\/b\u003e \u003ci\u003etelegramTrigger\u003c\/i\u003e (currently disabled), \u003ci\u003egoogleDocs\u003c\/i\u003e, \u003ci\u003ecode\u003c\/i\u003e, \u003ci\u003ehttpRequest\u003c\/i\u003e, \u003ci\u003esupabase\u003c\/i\u003e, \u003ci\u003eaggregate\u003c\/i\u003e\n\u003c\/li\u003e\n  \u003cli\u003e\n\u003cb\u003eDocument ingestion:\u003c\/b\u003e Google Docs via \u003cb\u003eService Account authentication\u003c\/b\u003e\n\u003c\/li\u003e\n  \u003cli\u003e\n\u003cb\u003eEmbeddings:\u003c\/b\u003e TogetherAI embeddings API (document chunks + user query embeddings)\u003c\/li\u003e\n  \u003cli\u003e\n\u003cb\u003eVector storage:\u003c\/b\u003e Supabase \u003cb\u003eembed\u003c\/b\u003e table\u003c\/li\u003e\n\u003c\/ul\u003e","brand":"N8N Commerce","offers":[{"title":"Default Title","offer_id":45764343496883,"sku":"N8N-5680","price":39.99,"currency_code":"GBP","in_stock":true}],"thumbnail_url":"\/\/cdn.shopify.com\/s\/files\/1\/0749\/6279\/6723\/files\/7Zkhtfbb74fJAsin08WaL_cFDoTZ3K.png?v=1786007953","url":"https:\/\/buyflowscripts.com\/products\/n8n-rag-telegram-bot-supabase-togetherai-openrouter","provider":"N8N Commerce","version":"1.0","type":"link"}