Quick overview
This workflow powers a RAG chatbot that answers chat messages using a Groq Llama model grounded in a Pinecone knowledge base, and automatically updates that knowledge base by ingesting new files added to a specific Google Drive folder using Google Gemini embeddings and Cohere reranking.
How it works
- Receives an incoming chat message via a public webhook-based chat trigger.
- Uses a Groq Chat Model to run an AI agent that answers strictly from retrieved context and maintains short-term conversation memory.
- Retrieves relevant knowledge base chunks from a Pinecone vector index using Google Gemini embeddings and Cohere reranking.
- Returns the grounded response back to the chat client.
- Triggers every minute when a new file is created in a specific Google Drive folder.
- Downloads the new file, splits it into chunks, generates embeddings with Google Gemini, and inserts the chunks into the same Pinecone index for future retrieval.
Setup
- Add credentials for Groq, Pinecone, Cohere, Google Drive OAuth2, and the Google Gemini (PaLM) API.
- Set the Google Drive folder to watch for new documents and ensure the account has access to read files in that folder.
- Create or select the target Pinecone index (set to
erhan8n in this workflow) and ensure its vector dimensions match the Google Gemini embedding model you use.
- Copy the chat trigger’s public webhook URL and configure it in your chat/UI client that sends messages into the workflow.