Skip to main content

IPL cricket rules Q&A chat bot using RAG and Google Gemini API

Workflow preview

Workflow preview
100%
IPL cricket rules Q&A chat bot using RAG and Google Gemini API preview
Open on n8n.io

Important notice

This workflow is provided as-is. Please review and test before using in production.

1. Workflow Overview

This workflow has 2 Broad Steps Step 1 Vector store creation with set of ipl rules using Google Gemini Embedding. This will we used to drive RAG for model grouding Step 2 Connecting the vector stor...

Best for

  • Engineering automation workflows
  • Multimodal AI automation workflows
  • advanced n8n builders looking for reusable templates

Tools used

@n8n/n8n-nodes-langchain.chattrigger, @n8n/n8n-nodes-langchain.agent, @n8n/n8n-nodes-langchain.memorybufferwindow, @n8n/n8n-nodes-langchain.vectorstoreinmemory, @n8n/n8n-nodes-langchain.lmchatgooglegemini, @n8n/n8n-nodes-langchain.embeddingsgooglegemini, @n8n/n8n-nodes-langchain.documentdefaultdataloader, @n8n/n8n-nodes-langchain.textsplitterrecursivecharactertextsplitter

Source and attribution

This workflow is cataloged by N8N Workflows and links back to its original n8n.io source page by Sidd.

Original n8n.io source

1.1 Workflow description

Title
IPL cricket rules Q&A chat bot using RAG and Google Gemini API
Workflow name
IPL cricket rules Q&A chat bot using RAG and Google Gemini API

This workflow has 2 Broad Steps

Step 1 - Vector store creation with set of ipl rules using Google Gemini Embedding. This will we used to drive RAG for model grouding

Step 2 - Connecting the vector store with google gemini API model and enabling a chat interface to drive the chat bot

Step 1

Load the reference material (run once via the Manual Trigger)

1.1 Manual Trigger → HTTP Request downloads the IPL “Match Playing Conditions” PDF.

1.2 Default Data Loader extracts text from the PDF.

**Type of data is binary

1.3 Recursive Character Text Splitter breaks the text into overlapping chunks.

**This step ensures that the data chunks that are created in vector store have some overlap and hence less chance of hallucination **Chunk size and chunk overlap are 2 variables to manage this

1.4 Embeddings Google Gemini (1) converts each chunk to a vector.

**Connect the model with google gemini model. You will need your own api key for this **Make note of the embedding model also since the same embedding model has to be selected in Step 2

1.5 Simple Vector Store 1 inserts those vectors into an in-memory store under key

**Make note of the vector store name since it is same vector store you will have to use in Step 2

Note: Google gemini API key credential needed

##Using Vector store nodes provided by n8n is the best way to get started to test out the workflow before you switch to more enterprise grade vector store nodes

Step 2

2.1 Chat Trigger to initiate n8n native chat interface

2.2 Simple Memory keeps the last 20 chat turns for context. This value can be edited within the node

2.3 Simple Vector Store (retrieve-as-tool mode) receives the user’s query embedding,

finds the top-10 most relevant chunks stored in step 1, and supplies them as tool output. This will drive RAG

**The name of vector store should match from Step 1, the embedding rule should match step 1

2.4 Google Gemini Chat Model is the language model that is used as the llm model

2.5 AI Agent orchestrates everything:

** Uses the system prompt (“You are a cricket expert… If info is missing, say ‘Sorry I don’t know’”). to prompt the model ** Has access to the memory (2.2) and the RAG tool (2.3). ** Generates the final response with Google Gemini, strictly limited to the retrieved IPL cricket rules data.

Note: Google gemini API key credential needed

##Using simple memory store nodes provided by n8n is the best way to get started to test out the workflow before you switch to more enterprise grade vector store nodes

1.2 Logical Blocks

This catalog entry is organized from the workflow JSON. The node-level section below shows the executable blocks available for review before importing the template.

2. Block-by-Block Analysis

Block 1 - When chat message received

Type / Role
@n8n/n8n-nodes-langchain.chatTrigger - chatTrigger
Config choices
Version 1.1

Block 2 - AI Agent

Type / Role
@n8n/n8n-nodes-langchain.agent - agent
Config choices
Version 2.1

Block 3 - Simple Memory

Type / Role
@n8n/n8n-nodes-langchain.memoryBufferWindow - memoryBufferWindow
Config choices
Version 1.3

Block 4 - Simple Vector Store

Type / Role
@n8n/n8n-nodes-langchain.vectorStoreInMemory - vectorStoreInMemory
Config choices
Version 1.3

Block 5 - Google Gemini Chat Model

Type / Role
@n8n/n8n-nodes-langchain.lmChatGoogleGemini - lmChatGoogleGemini
Config choices
Version 1

Block 6 - Embeddings Google Gemini

Type / Role
@n8n/n8n-nodes-langchain.embeddingsGoogleGemini - embeddingsGoogleGemini
Config choices
Version 1

Block 7 - Simple Vector Store1

Type / Role
@n8n/n8n-nodes-langchain.vectorStoreInMemory - vectorStoreInMemory
Config choices
Version 1.3

Block 8 - Embeddings Google Gemini1

Type / Role
@n8n/n8n-nodes-langchain.embeddingsGoogleGemini - embeddingsGoogleGemini
Config choices
Version 1

Block 9 - Default Data Loader

Type / Role
@n8n/n8n-nodes-langchain.documentDefaultDataLoader - documentDefaultDataLoader
Config choices
Version 1.1

Block 10 - Recursive Character Text Splitter

Type / Role
@n8n/n8n-nodes-langchain.textSplitterRecursiveCharacterTextSplitter - textSplitterRecursiveCharacterTextSplitter
Config choices
Version 1

Block 11 - HTTP Request

Type / Role
n8n-nodes-base.httpRequest - httpRequest
Config choices
Version 4.2

Block 12 - When clicking ‘Execute workflow’

Type / Role
n8n-nodes-base.manualTrigger - manualTrigger
Config choices
Version 1

Block 13 - Sticky Note

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 14 - Sticky Note1

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 15 - Sticky Note7

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 16 - Sticky Note2

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 17 - Sticky Note3

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 18 - Sticky Note4

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 19 - Sticky Note5

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 20 - Sticky Note6

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 21 - Sticky Note8

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 22 - Sticky Note9

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 23 - Sticky Note10

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 24 - Sticky Note11

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

3. Summary Table

Workflow IPL cricket rules Q&A chat bot using RAG and Google Gemini API
Complexity advanced
Nodes 24
Categories Engineering, Multimodal AI
Author Sidd
Published 15 Aug 2025

4. Reproducing the Workflow from Scratch

  1. 1. Download the workflow JSON

    Use the JSON export at /data/workflows/7413/7413.json as the source template for this automation.

  2. 2. Import the template into n8n

    Open n8n, import the downloaded JSON, and review each node before activating the workflow.

  3. 3. Configure credentials and variables

    Replace placeholder credentials, API keys, webhook URLs, account IDs, and environment-specific values with your own settings.

  4. 4. Test with sample data

    Run the workflow manually or in a staging workspace, inspect node output, and confirm downstream systems receive the expected data.

  5. 5. Activate and monitor

    Enable the workflow only after testing, then monitor executions, errors, and rate limits during the first production runs.

5. General Notes & Resources

Review imported nodes carefully before activation. This catalog entry is intended to help you inspect the workflow structure, understand required services, and find related templates faster.

Node names, credentials, schedules, webhook paths, and external service limits may need adjustment for your workspace.

Frequently asked questions

What does IPL cricket rules Q&A chat bot using RAG and Google Gemini API do?

This workflow has 2 Broad Steps Step 1 Vector store creation with set of ipl rules using Google Gemini Embedding. This will we used to drive RAG for model grouding Step 2 Connecting the vector stor...

What do I need before importing this workflow?

Review the workflow JSON, configure any required credentials in n8n, and test the automation in a safe workspace before using it in production.

Can I customize this workflow?

Yes. Use the block-by-block analysis and the downloadable JSON to inspect each node, then adjust credentials, prompts, schedules, filters, or destinations for your Engineering, Multimodal AI use case.