Files & Documents

Answer Questions About PDF Files Using AI

16 nodes 121 111 Automatic trigger
Download

Workflow Description

Automate loading PDFs from Google Drive, splitting content into searchable text segments, and creating an intelligent knowledge base with embeddings. Users can ask questions through a chat interface and receive accurate answers directly from the document content.

How it works

  1. 1.Load PDF from Google Drive and extract full text content
  2. 2.Split text into manageable chunks using recursive character splitting
  3. 3.Generate embeddings and store chunks in vector database for semantic search
  4. 4.Receive user question through chat interface trigger
  5. 5.Retrieve most relevant document sections matching the query
  6. 6.Generate and return accurate answer grounded in PDF content

Use cases

  • Enable employees to query company policies and procedures stored in PDF documents
  • Extract specific details from contracts and lengthy reports automatically
  • Provide customer support with instant answers based on product documentation files

Requirements

  • Active Google Drive account with file access permissions
  • OpenAI API key with GPT-3.5 or later model access
  • Configured Pinecone vector database for embeddings storage

Service Value

Ideal as a smart automation service combining integrations and AI to produce ready-to-use results.

Apps Used

Google Drive Text Splitter OpenAI Document Default Data Loader LLM Chain Vector Store Chat Trigger

Details

Trigger Automatic trigger
Nodes 16
Apps 7
Views 121
Downloads 111

How to Use

  1. 1.Click "Download Template"
  2. 2.Open your n8n dashboard
  3. 3.Go to Workflows > Import from File
  4. 4.Select downloaded file and configure credentials

Nodes Used (16)

/

Google Drive

Google Drive

#1

Recursive Character Text Splitter

Text Splitter Recursive Character Text Splitter

#2

Embeddings OpenAI

OpenAI

#3

Sticky Note

Sticky Note

#4

Sticky Note1

Sticky Note

#5

Default Data Loader

Document Default Data Loader

#6

Sticky Note2

Sticky Note

#7

Question and Answer Chain

Chain Retrieval Qa

#8

OpenAI Chat Model

OpenAI

#9

Embeddings OpenAI2

OpenAI

#10

Vector Store Retriever

Retriever Vector Store

#11

Read Pinecone Vector Store

Vector Store Pinecone

#12

Insert into Pinecone vector store

Vector Store Pinecone

#13

When clicking 'Chat' button below

Chat Trigger

#14

When clicking 'Test Workflow' button

Manual Trigger

#15

Set Google Drive file URL

Set

#16