Skip to main content

Hr policy retrieval using Slack, S3, and GPT-4.1-mini with RAG

Workflow preview

Workflow preview
100%
Hr policy retrieval using Slack, S3, and GPT-4.1-mini with RAG preview
Open on n8n.io

Important notice

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

1. Workflow Overview

HR Chatbot with RAG: Retrieve Company Policies via Slack, Amazon S3, and OpenAI Overview Answer HR and company policy questions via Slack, powered by a Knowledge Base of internal documents stored i...

Best for

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

Tools used

n8n-nodes-base.slacktrigger, @n8n/n8n-nodes-langchain.agent, @n8n/n8n-nodes-langchain.memorybufferwindow, @n8n/n8n-nodes-langchain.toolvectorstore, @n8n/n8n-nodes-langchain.vectorstoreinmemory, @n8n/n8n-nodes-langchain.embeddingsopenai, @n8n/n8n-nodes-langchain.lmchatopenai, n8n-nodes-base.manualtrigger

Source and attribution

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

Original n8n.io source

1.1 Workflow description

Title
Hr policy retrieval using Slack, S3, and GPT-4.1-mini with RAG
Workflow name
Hr policy retrieval using Slack, S3, and GPT-4.1-mini with RAG

HR Chatbot with RAG: Retrieve Company Policies via Slack, Amazon S3, and OpenAI

Overview

Answer HR and company policy questions via Slack, powered by a Knowledge Base of internal documents stored in S3. The assistant uses vector search and an OpenAI Chat Model to retrieve accurate answers.

The HR Assistant is an AI-powered Slack bot that allows employees to ask questions in natural language and get accurate answers from company documentation. Documents are managed through an ingestion workflow that retrieves files from S3, transforms them into embeddings, and stores them in a vector database. On Slack, the assistant interprets questions, searches the Knowledge Base, and responds with concise and reliable answers, or clearly states when information isn’t available.

How it works

Normal interaction

  • An employee asks a question in Slack (e.g., “How many vacation days do I have?”).
  • The assistant checks the Knowledge Base (vector store).
  • If relevant information is found, the assistant provides a clear answer.
  • If not, it responds with: “That answer doesn’t appear to be covered in the materials I have access to.”

Standardized process of Knowledge Base ingestion

  1. Trigger – The ingestion workflow is manually executed.
  2. S3 Download – Files are pulled from the company’s S3 bucket.
  3. Data Loader – Documents are pre-processed and split into chunks.
  4. Embeddings – Each chunk is converted into an embedding via OpenAI.
  5. Vector Store – Embeddings are stored in the Knowledge Base (vector DB).
  6. Chatbot Workflow – When questions arrive via Slack, the assistant queries the vector store to find the most relevant context before generating a response.

Required Connections

To use the HR Assistant effectively, you need:

  • A Slack workspace, where the bot is installed and invited to relevant channels.
  • An S3 bucket containing company documents (e.g., HR policies, procedures).
  • Access to OpenAI API keys for both embeddings and chat models.
  • Proper permissions to fetch documents from S3 and write to the vector store.
  • A configured n8n instance with both ingestion and chatbot workflows.

Setup Time

≈ 20–30 minutes (depending on number of documents and Slack integration).

Customising this workflow

  • Add more document sources (e.g., Google Drive, Confluence) in the ingestion pipeline.
  • Expand the Slack integration to allow commands like /askHR or to restrict the bot to only respond when @mentioned.
  • Add scheduled ingestion (instead of manual trigger) to automatically refresh the Knowledge Base from S3.
  • Connect analytics nodes to monitor which HR topics employees ask most often.

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 - Slack Trigger

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

Block 2 - Chatbot

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

Block 3 - Simple Memory

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

Block 4 - Knowledge Base Search

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

Block 5 - Knowledge Base

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

Block 6 - Knowledge Base Embeddings

Type / Role
@n8n/n8n-nodes-langchain.embeddingsOpenAi - embeddingsOpenAi
Config choices
Version 1.2

Block 7 - Conversation Model

Type / Role
@n8n/n8n-nodes-langchain.lmChatOpenAi - lmChatOpenAi
Config choices
Version 1.2

Block 8 - Knowledge Base Response Chat Model

Type / Role
@n8n/n8n-nodes-langchain.lmChatOpenAi - lmChatOpenAi
Config choices
Version 1.2

Block 9 - Manual Trigger

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

Block 10 - S3 Document Downloader

Type / Role
n8n-nodes-base.awsS3 - awsS3
Config choices
Version 2

Block 11 - Knowledge Base storage

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

Block 12 - Knowledge Base Embeddings Generator

Type / Role
@n8n/n8n-nodes-langchain.embeddingsOpenAi - embeddingsOpenAi
Config choices
Version 1.2

Block 13 - Document Loader

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

Block 14 - Sticky Note

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

Block 15 - Sticky Note1

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 Note5

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

Block 19 - Sticky Note4

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 Note7

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

Block 22 - Response

Type / Role
n8n-nodes-base.set - set
Config choices
Version 3.4

Block 23 - Try Again

Type / Role
n8n-nodes-base.set - set
Config choices
Version 3.4

Block 24 - Send a message

Type / Role
n8n-nodes-base.slack - slack
Config choices
Version 2.3

3. Summary Table

Workflow Hr policy retrieval using Slack, S3, and GPT-4.1-mini with RAG
Complexity advanced
Nodes 24
Categories AI RAG, Multimodal AI
Author Humble Turtle
Published 22 Aug 2025

4. Reproducing the Workflow from Scratch

  1. 1. Download the workflow JSON

    Use the JSON export at /data/workflows/7745/7745.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 Hr policy retrieval using Slack, S3, and GPT-4.1-mini with RAG do?

HR Chatbot with RAG: Retrieve Company Policies via Slack, Amazon S3, and OpenAI Overview Answer HR and company policy questions via Slack, powered by a Knowledge Base of internal documents stored i...

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 AI RAG, Multimodal AI use case.