Category: Automations › AI Customer Support · Best for: Businesses with manuals, FAQs and policies · Platform: n8n · Steps: 35
What it does
Put your files in Google Drive, and the chatbot answers questions from them.
This workflow creates a powerful RAG (Retrieval-Augmented Generation) chatbot that can process, store, and interact with documents from Google Drive using Qdrant vector storage and Google's Gemini AI.
Works with: Gemini, OpenAI, Memory Buffer Window, Embeddings OpenAI, Google Drive, Text Splitter Token Splitter, Agent, Vector Store Qdrant, Document Default Data Loader, Information Extractor, Google Docs, Telegram
What you get
- The n8n workflow file (
workflow.json), ready to import - This setup guide
- The list of fields to change for your own accounts (see Install below)
- Email support if you get stuck
Before you start
-
An n8n account. Easiest: n8n Cloud (free trial). Self-host for free with Docker:
docker run -it --rm -p 5678:5678 -v n8n_data:/home/node/.n8n docker.n8n.io/n8nio/n8n, then open http://localhost:5678. -
Accounts and API keys for these services:
- Qdrant vector database: how to connect (used by Qdrant Vector Store, Qdrant Vector Store Tool)
- Google (Sheets, Gmail, Drive, Calendar, Docs): how to connect (used by Google Gemini Chat Model, Download File From Google Drive, Find File Ids in Google Drive Folder, Google Gemini Chat Model1, Google Drive, Update Chat History)
- OpenAI API key: how to connect (used by text-embeddings-3-large, gpt-4o-mini1, text-embeddings-3-large1, OpenAI Chat Model)
- Telegram bot token from @BotFather: how to connect (used by Confirm Qdrant Delete Points, Send Declined Message, Send Completed Message)
Install
- In n8n, click Create workflow (top right).
- Click the ⋯ menu → Import from file and choose
workflow.json. Or open the file, copy everything and paste it onto the empty canvas with Ctrl/Cmd + V. - Open each node with a red warning triangle and pick or create the matching credential from the list above.
- Point these fields at your own sheets, chats and accounts:
- Confirm Qdrant Delete Points →
chatId: choose your own - Send Declined Message →
chatId: choose your own - Google Drive →
driveId: choose your own - Google Drive →
folderId: choose your own - Send Completed Message →
chatId: choose your own
- Confirm Qdrant Delete Points →
- Click Save.
Test it
- Click Test workflow (or Execute workflow). When clicking ‘Test workflow’ starts it. Trigger it once with real sample data.
- Click each node to check its output. A green tick means the step worked.
- Fix any red node: it's almost always a credential or a field that still points at a sheet or chat that isn't yours.
Go live
Toggle Active (top right). From now on it runs on its own. Check Executions in the left sidebar to see every run.
How it works, step by step
- When clicking ‘Test workflow’ starts the workflow (Manual).
- Webhook starts the workflow (Webhook).
- When chat message received starts the workflow (Chat).
- Google Gemini Chat Model1 uses AI (Gemini).
- OpenAI Chat Model uses AI (OpenAI).
- Window Buffer Memory uses AI (Memory Buffer Window).
- gpt-4o-mini1 uses AI (OpenAI).
- text-embeddings-3-large1 uses AI (Embeddings OpenAI).
- Google Drive uses Google Drive to createFromText.
- text-embeddings-3-large uses AI (Embeddings OpenAI).
- Token Splitter uses AI (Text Splitter Token Splitter).
- Google Gemini Chat Model uses AI (Gemini).
- Google Folder ID reshapes the data for the next step.
- AI Agent uses AI (Agent).
- Delete Qdrant Points by File ID reshapes the data for the next step.
- Qdrant Vector Store Tool uses AI (Vector Store Qdrant).
- Qdrant Vector Store uses AI (Vector Store Qdrant).
- Data Loader uses AI (Document Default Data Loader).
- Extract Meta Data uses AI (Information Extractor).
- Find File Ids in Google Drive Folder uses Google Drive to fileFolder.
- Update Chat History uses Google Docs to update.
- Respond to User reshapes the data for the next step.
- Merge2 uses Merge.
- Wait pauses before continuing.
- Merge uses Merge.
- File Id List uses Summarize.
- Qdrant Collection Name reshapes the data for the next step.
- Loop Over Items uses Split In Batches.
- Merge1 uses Merge.
- Send Completed Message uses Telegram.
- Download File From Google Drive uses Google Drive to download.
- Confirm Qdrant Delete Points uses Telegram to sendAndWait.
- Get File Contents uses Extract From File to text.
- If checks a condition and routes items accordingly.
- Send Declined Message uses Telegram.
Extra setup notes
These notes are also on the canvas as yellow sticky notes:
Prepare Qdrant Vector Store
Perform Qdrant Vector Store Operations
Workflow Config
- Google Drive Folder Id
- Qdrant Collection Name
- List of Google Drive File Id's
Extract Metadata for Qdrant Hybrid Search
Google Drive
Save Documents to Qdrant Vector Store
Delete From Qdrant Vector Store
This operation can not be undone!!!
Human In The Loop
User must verify deletion of points from Qdrant vector store
Start Here!
Retrieve Content from Qdrant Vector Store
Chat with Your Documents
Step 1 - Save Documents to Qdrant Vector Store
Step 2 - Chat with Your Documents from Qdrant Vector Store
Save Chat History
AI-Powered RAG Chatbot with Google Drive Integration
This workflow creates a powerful RAG (Retrieval-Augmented Generation) chatbot that can process, store, and interact with documents from Google Drive using Qdrant vector storage and Google's Gemini AI.
How It Works
Document Processing & Storage
- Retrieves documents from a specified Google Drive folder
- Processes and splits documents into manageable chunks
- Extracts metadata using AI for enhanced search capabilities
- Stores document vectors in Qdrant for efficient retrieval
Intelligent Chat Interface
- Provides a conversational interface powered by Google Gemini
- Uses RAG to retrieve relevant context from stored documents
- Maintains chat history in Google Docs for reference
- Delivers accurate, context-aware responses
Vector Store Management
- Features secure delete operations with human verification
- Includes Telegram notifications for important operations
- Maintains data integrity with proper version control
- Supports batch processing of documents
Setup Steps
-
Configure API Credentials:
- Set up Google Drive & Docs access
- Configure Gemini AI API
- Set up Qdrant vector store connection
- Add Telegram bot for notifications
-
Configure Document Sources:
- Set Google Drive folder ID
- Define Qdrant collection name
- Set up document processing parameters
-
Test and Deploy:
- Verify document processing
- Test chat functionality
- Confirm vector store operations
- Check notification system
This workflow is ideal for organizations needing to create intelligent chatbots that can access and understand large document repositories while maintaining context and providing accurate responses through RAG technology.
Troubleshooting
- "Credentials not found": open the node and select your credential again.
- Google "access blocked": in Google Cloud, add your email as a test user on the OAuth consent screen.
- Webhook not firing: copy the node's Production URL (not Test URL) into the other app, and make sure the workflow is Active.
- AI node errors: check your API key has billing enabled and the model name exists on your plan.
- Nothing happens on schedule: the workflow must be Active, and self-hosted n8n must stay running.
Need help?
Reply to your Morning Method order email and we'll help you get it running.
© Morning Method