Document Q&A system with Voyage-Context-3 embeddings and MongoDB Atlas
Ready for 3.0What this workflow does
This AI workflow has 43 nodes and runs manually, when you click “Execute workflow” (plus 2 other triggers). Along the way it connects MongoDB, OpenAI Chat Model and OpenAI. It also calls api.voyageai.com over HTTP.
How it runs
Trigger: Manually, when you click “Execute workflow” (plus 2 other triggers).
- Set Variables (Edit Fields (Set)): sets 1 field: url
- Loop Over Items (Loop Over Items (Split in Batches)): loops over the items in batches
- Get Query (Edit Fields (Set)): sets 1 field: query
- Clear Collection (MongoDB): delete
- Generate Clarifying Questions (Information Extractor): extracts structured fields from text with AI, with model: OpenAI Chat Model
- Import Research Paper (HTTP Request): calls an HTTP API
- Chunk Page Text (Code): runs custom JavaScript code
- Combine Content & Metadata (Edit Fields (Set)): sets 2 fields: text, metadata
- Split Questions (Split Out): splits a list into separate items
- Extract from File: extracts data from a file (pdf)
…plus 25 more steps. See the full node list below.
Services it uses
HTTP calls to: api.voyageai.com
Before you upgrade to n8n 3.0
Nothing in this workflow is removed in n8n 3.0, so it should import and run after the upgrade.
Nodes used (20)
- Manual Trigger
n8n-nodes-base.manualTrigger - HTTP Request
n8n-nodes-base.httpRequest - Extract from File
n8n-nodes-base.extractFromFile - Split Out
n8n-nodes-base.splitOut - No Operation, do nothing
n8n-nodes-base.noOp - Code
n8n-nodes-base.code - Loop Over Items (Split in Batches)
n8n-nodes-base.splitInBatches - Edit Fields (Set)
n8n-nodes-base.set - Execute Workflow Trigger
n8n-nodes-base.executeWorkflowTrigger - Execute Sub-workflow
n8n-nodes-base.executeWorkflow - MongoDB
n8n-nodes-base.mongoDb - Wait
n8n-nodes-base.wait - Aggregate
n8n-nodes-base.aggregate - OpenAI Chat Model
@n8n/n8n-nodes-langchain.lmChatOpenAi - Information Extractor
@n8n/n8n-nodes-langchain.informationExtractor - Chat Trigger
@n8n/n8n-nodes-langchain.chatTrigger - Chat
@n8n/n8n-nodes-langchain.chat - OpenAI
@n8n/n8n-nodes-langchain.openAi - Mongo Db Tool
n8n-nodes-base.mongoDbTool - Merge
n8n-nodes-base.merge
From the author
On my never-ending quest to find the best embeddings model, I was intrigued to come across Voyage-Context-3 by MongoDB and was excited to give it a try. This template implements the embedding model on a Arxiv research paper and stores the results in a Vector…