Multi-Agent RAG System for Automated Business Requirements Document Generation - n8n Workflow

Automate professional BRD creation using an advanced n8n workflow. Integrate multi-agent GPT, RAG via vector store, Google Sheets, and Drive for streamlined document generation and delivery. Leverage specialized n8n templates.

Workflow Preview

Ready to automate?

Download this n8n workflow template and start using it instantly.

Who is this best for?

Business Analysts seeking to reduce manual documentation time.
Project Managers needing standardized and traceable BRDs quickly.
Operations Teams processing high volumes of project requests.
Users looking for advanced n8n templates featuring complex AI agent orchestration.

Overview

This robust n8n workflow solves the complex problem of generating high-quality, structured Business Requirements Documents (BRDs) automatically from simple form submissions and unstructured supporting files. It leverages Retrieval-Augmented Generation (RAG) by extracting knowledge from uploaded PDFs and using that context to feed two specialized, cooperating AI agents (the General BRD Writer and the detailed Business Requirement Writer).

This comprehensive automation ensures every request is tracked in Google Sheets, documents are created in Google Docs, converted to PDF, archived in Google Drive, and delivered via email—all hands-free. This advanced n8n node setup minimizes human error and significantly accelerates the project initiation phase, making it one of the most powerful n8n templates available for technical documentation and sales enablement.

How it Works

This advanced n8n workflow follows a sophisticated, multi-stage pipeline:


  1. Request Capture & Tracking: The primary n8n trigger is the On form submission node, which starts the n8n workflow upon a user filling out the BRD request form. Request details are immediately logged into a Google Sheets tracking sheet, and all uploaded supporting files are saved to Google Drive.


  1. RAG Preparation: The workflow handles multiple uploaded files using a Code n8n node, extracts text from PDFs using the Extract from File n8n node, and generates embeddings using OpenAI. This contextual information is then stored in an in-memory vector store via the Insert Data to Store n8n node, creating the dynamic knowledge base (RAG) required by the agents.


  1. Multi-Agent Drafting: Two specialized AI agents, configured within the n8n workflow, run concurrently. The General BRD Writer Agent focuses on the executive summary, scope, and non-functional requirements. The Business Requirement Writer Agent focuses exclusively on detailed, structured business and functional requirements. Both agents utilize the Query Data Tool n8n node to retrieve facts from the embedded knowledge base, ensuring the final document is grounded in the source material.


  1. Content Assembly & Creation: The outputs from the two agents are combined using the Merge n8n node. A subsequent Code n8n node consolidates the markdown output and project metadata. The Create document file n8n node then uses an HTTP Request to generate a new file in Google Docs, populated with the finalized content.


  1. Archival: The Google Doc is converted into a PDF binary file using the Convert document to PDF Google Drive n8n node, archived in a dedicated Google Drive folder (Archiving PDF File), and prepared for distribution.


  1. Delivery & Completion: The Send BRD response email n8n node uses SendGrid to deliver the final BRD PDF attachment to the requester. The n8n workflow concludes by using the Mark request as completed Google Sheets n8n node to update the administrative tracking sheet, marking the project status as 'Completed'.

Installation Guide


  1. Importing the n8n Workflow: Copy the provided JSON data and import it directly into your n8n instance via the Workflow section. This provides you with the base n8n templates structure.

  2. Credential Setup: This n8n workflow requires credentials for:

OpenAI API (for models and embeddings).
Google Sheets (for tracking and status updates).
Google Drive (for file upload, document creation, and PDF conversion).
SendGrid (or your preferred email service, for delivery).

  1. Trigger Configuration: Activate the On form submission n8n trigger and note the webhook URL. This URL must be integrated with your external form provider (e.g., Google Forms, Typeform, etc.).

  2. Google Workspace Configuration: Update the Document ID in all Google Sheets n8n nodes and the necessary Drive Folder ID within the Configure metadata n8n node to point to your specific tracking spreadsheet and archive folder.

  3. Agent Customization: Review and customize the detailed system prompts in the General BRD Writer Agent and Business Requirement Writer Agent to align with your organization’s specific BRD standards, structure, and tone. This ensures the output of the n8n workflow meets your quality requirements.

Node Details

On form submission (n8n trigger): Acts as the starting point, capturing user input, including project details and binary file uploads (supporting documents).
Extract from File (n8n node): Converts uploaded binary files (e.g., PDFs) into extractable text chunks, essential for the RAG process.
Insert Data to Store (Langchain vectorStoreInMemory n8n node): Stores the embedded text data for fast contextual retrieval by the AI agents. Key Configuration: Uses a key named vectorstorekey.
OpenAI Chat Model / Embeddings (n8n node): Provides the necessary AI engine and embedding functionality for the RAG pipeline and agent execution. Key Configuration: Uses gpt-4 for reasoning and generation.
General BRD Writer Agent & Business Requirement Writer Agent (Langchain agent n8n node): Two specialized agents with distinct system prompts working collaboratively to generate different sections of the BRD. Key Configuration: Both agents utilize the knowledge_base tool to query the vector store.
Create document file (HTTP Request n8n node): Interacts with the Google Docs API to create the final document using the merged markdown content. Key Configuration: Uses multipart/related content type for creation and content insertion.
Convert document to PDF (GoogleDrive n8n node): Converts the newly created Google Doc into a PDF format for delivery and archiving.
Send BRD response email (SendGrid n8n node): Responsible for delivering the generated PDF to the requester using dynamic data mapping for personalization. Key Configuration: Attaches the PDF binary data output from the conversion step.


  • Mark request as completed (GoogleSheets n8n node): Updates the status of the request in the tracking sheet, ensuring the entire n8n workflow cycle is documented.

Related n8n Workflows

Free

Nodes: 17 Nodes
Updated: December 26 2025
View all
Created by

Empowering small and medium businesses with smart automation and practical AI, no big tech team required.

Featured*