Test local de n8n
Ceci est unInternal Wiki, AI RAGworkflow d'automatisation du domainecontenant 20 nœuds.Utilise principalement des nœuds comme Set, GoogleDrive, Agent, ExtractFromFile, LmOllama. Utiliser Llama3, Postgres, Qdrant et Google Drive pour créer un système de questions-réponses sur les documents privés
- •Informations d'identification Google Drive API
- •Informations de connexion au serveur Qdrant
- •Informations de connexion à la base de données PostgreSQL
Nœuds utilisés (20)
Catégorie
{
"id": "VqgG9dsRgPuxiNDW",
"meta": {
"instanceId": "5ddd5df8055e38d81880227d5c6dcdf1994486d01343a3c0e8e3e8bba2c674e7",
"templateCredsSetupCompleted": true
},
"name": "n8n local test",
"tags": [],
"nodes": [
{
"id": "250ff8ae-f645-4644-af93-f2148549ed86",
"name": "À la réception d'un message chat",
"type": "@n8n/n8n-nodes-langchain.chatTrigger",
"position": [
-940,
580
],
"webhookId": "e0526870-3bc3-4dfc-9914-8e68363c4621",
"parameters": {
"options": {}
},
"typeVersion": 1.1
},
{
"id": "fbcc24b9-f983-49af-a7b9-dc78277e746c",
"name": "Agent IA",
"type": "@n8n/n8n-nodes-langchain.agent",
"position": [
-660,
560
],
"parameters": {
"options": {
"systemMessage": "You are a helpful assistant you have access to a knowledge base"
}
},
"typeVersion": 2
},
{
"id": "03cfe40b-62ca-41af-ba97-80072e018e3d",
"name": "Ollama Chat Model",
"type": "@n8n/n8n-nodes-langchain.lmChatOllama",
"position": [
-840,
400
],
"parameters": {
"model": "llama3.2:latest",
"options": {}
},
"credentials": {
"ollamaApi": {
"id": "n77wZlvZvtjVPvN8",
"name": "Ollama account"
}
},
"typeVersion": 1
},
{
"id": "5c16650c-44a9-4c5f-b8f2-d0e9e5a0f41d",
"name": "Mémoire de chat Postgres",
"type": "@n8n/n8n-nodes-langchain.memoryPostgresChat",
"position": [
-720,
380
],
"parameters": {},
"credentials": {
"postgres": {
"id": "dd7SihZdZXIWFCAf",
"name": "Postgres account"
}
},
"typeVersion": 1.3
},
{
"id": "d975770d-0463-480c-aa70-33395f5f40b2",
"name": "Magasin de vecteurs Qdrant",
"type": "@n8n/n8n-nodes-langchain.vectorStoreQdrant",
"position": [
660,
460
],
"parameters": {
"options": {},
"qdrantCollection": {
"__rl": true,
"mode": "list",
"value": "midjourney",
"cachedResultName": "midjourney"
}
},
"credentials": {
"qdrantApi": {
"id": "cbWjDnr5YQkhxhly",
"name": "QdrantApi account"
}
},
"typeVersion": 1.1
},
{
"id": "a5282142-d4dc-40b9-bff9-93df5fc5905f",
"name": "Ollama Model",
"type": "@n8n/n8n-nodes-langchain.lmOllama",
"position": [
400,
360
],
"parameters": {
"options": {}
},
"credentials": {
"ollamaApi": {
"id": "n77wZlvZvtjVPvN8",
"name": "Ollama account"
}
},
"typeVersion": 1
},
{
"id": "76a8d5b3-0c41-4f6c-b3c1-6a00ce555b23",
"name": "Embeddings Ollama",
"type": "@n8n/n8n-nodes-langchain.embeddingsOllama",
"position": [
480,
520
],
"parameters": {},
"credentials": {
"ollamaApi": {
"id": "n77wZlvZvtjVPvN8",
"name": "Ollama account"
}
},
"typeVersion": 1
},
{
"id": "3d6d64f3-b1d3-4453-9f17-6d3a55273407",
"name": "Répondre aux questions avec un magasin de vecteurs",
"type": "@n8n/n8n-nodes-langchain.toolVectorStore",
"position": [
620,
320
],
"parameters": {
"description": "this tool will be used to retrieve knowledge"
},
"typeVersion": 1.1
},
{
"id": "312d4235-a534-45f2-8cba-475b12874281",
"name": "Note adhésive",
"type": "n8n-nodes-base.stickyNote",
"position": [
-960,
320
],
"parameters": {
"color": 7,
"width": 660,
"height": 480,
"content": "## Local Rag AI AGENT \n"
},
"typeVersion": 1
},
{
"id": "832d366c-3eb4-4845-8661-067fc12d278b",
"name": "Note adhésive1",
"type": "n8n-nodes-base.stickyNote",
"position": [
240,
240
],
"parameters": {
"color": 4,
"width": 720,
"height": 460,
"content": "## Qdrant Vector store and Ollama Embeddings\n"
},
"typeVersion": 1
},
{
"id": "49d25a7c-432c-4794-ad49-c6dc57685120",
"name": "Fichier créé",
"type": "n8n-nodes-base.googleDriveTrigger",
"position": [
-760,
900
],
"parameters": {
"event": "fileCreated",
"options": {},
"pollTimes": {
"item": [
{
"mode": "everyMinute"
}
]
},
"triggerOn": "specificFolder",
"folderToWatch": {
"__rl": true,
"mode": "list",
"value": "1uf6zZN51rgAuQgid4-Oi314f6mJIQdiB",
"cachedResultUrl": "https://drive.google.com/drive/folders/1uf6zZN51rgAuQgid4-Oi314f6mJIQdiB",
"cachedResultName": "Daex"
}
},
"credentials": {
"googleDriveOAuth2Api": {
"id": "Libd6umJKamTZGV1",
"name": "Google Drive account"
}
},
"typeVersion": 1
},
{
"id": "39b32d2b-b4c7-44de-8f86-f519be58e4b5",
"name": "Fichier mis à jour",
"type": "n8n-nodes-base.googleDriveTrigger",
"position": [
-760,
1100
],
"parameters": {
"event": "fileUpdated",
"options": {},
"pollTimes": {
"item": [
{
"mode": "everyMinute"
}
]
},
"triggerOn": "specificFolder",
"folderToWatch": {
"__rl": true,
"mode": "list",
"value": "1914m3M7kRzkd5RJqAfzRY9EBcJrKemZC",
"cachedResultUrl": "https://drive.google.com/drive/folders/1914m3M7kRzkd5RJqAfzRY9EBcJrKemZC",
"cachedResultName": "Meeting Notes"
}
},
"credentials": {
"googleDriveOAuth2Api": {
"id": "Libd6umJKamTZGV1",
"name": "Google Drive account"
}
},
"typeVersion": 1
},
{
"id": "b5cf9dc7-7bd9-41a3-b736-6417de3cf4b0",
"name": "Définir l'ID du fichier",
"type": "n8n-nodes-base.set",
"position": [
-540,
1000
],
"parameters": {
"options": {},
"assignments": {
"assignments": [
{
"id": "10646eae-ae46-4327-a4dc-9987c2d76173",
"name": "file_id",
"type": "string",
"value": "={{ $json.id }}"
},
{
"id": "dd0aa081-79e7-4714-8a67-1e898285554c",
"name": "folder_id",
"type": "string",
"value": "={{ $json.parents[0] }}"
}
]
}
},
"typeVersion": 3.4
},
{
"id": "fee137e8-a785-4a07-a3f7-84f1d15438f8",
"name": "Télécharger le fichier",
"type": "n8n-nodes-base.googleDrive",
"position": [
-100,
1000
],
"parameters": {
"fileId": {
"__rl": true,
"mode": "id",
"value": "={{ $('Set File ID').item.json.file_id }}"
},
"options": {
"googleFileConversion": {
"conversion": {
"docsToFormat": "text/plain"
}
}
},
"operation": "download"
},
"credentials": {
"googleDriveOAuth2Api": {
"id": "Libd6umJKamTZGV1",
"name": "Google Drive account"
}
},
"executeOnce": true,
"typeVersion": 3
},
{
"id": "03adfdbf-1dc4-48c4-9263-5660f1abb505",
"name": "Extraire le texte du document",
"type": "n8n-nodes-base.extractFromFile",
"position": [
120,
1000
],
"parameters": {
"options": {},
"operation": "text"
},
"typeVersion": 1,
"alwaysOutputData": true
},
{
"id": "5490338c-f7a4-4e14-a493-b2f3d60af56f",
"name": "Chargeur de données par défaut",
"type": "@n8n/n8n-nodes-langchain.documentDefaultDataLoader",
"position": [
460,
1222.5
],
"parameters": {
"options": {
"metadata": {
"metadataValues": [
{
"name": "file_id",
"value": "={{ $('Set File ID').item.json.file_id }}"
},
{
"name": "folder_id",
"value": "={{ $('Set File ID').item.json.folder_id }}"
}
]
}
}
},
"typeVersion": 1
},
{
"id": "1bcb0f4f-92bb-40e6-a1a9-2a2acd232202",
"name": "Séparateur de texte récursif",
"type": "@n8n/n8n-nodes-langchain.textSplitterRecursiveCharacterTextSplitter",
"position": [
548,
1420
],
"parameters": {
"options": {},
"chunkSize": 100
},
"typeVersion": 1
},
{
"id": "f3f1d04c-050e-4aa6-85b1-cbb4b3eaf591",
"name": "Embeddings Ollama1",
"type": "@n8n/n8n-nodes-langchain.embeddingsOllama",
"position": [
340,
1220
],
"parameters": {
"model": "llama3.2:latest"
},
"credentials": {
"ollamaApi": {
"id": "n77wZlvZvtjVPvN8",
"name": "Ollama account"
}
},
"typeVersion": 1
},
{
"id": "066b5093-a034-43e8-a5ea-72aea5770d6c",
"name": "Insertion dans le magasin de vecteurs Qdrant",
"type": "@n8n/n8n-nodes-langchain.vectorStoreQdrant",
"position": [
340,
980
],
"parameters": {
"mode": "insert",
"options": {},
"qdrantCollection": {
"__rl": true,
"mode": "list",
"value": "midjourney",
"cachedResultName": "midjourney"
}
},
"credentials": {
"qdrantApi": {
"id": "cbWjDnr5YQkhxhly",
"name": "QdrantApi account"
}
},
"typeVersion": 1
},
{
"id": "d85eda28-8be7-4b0d-97bf-254c39a3f690",
"name": "Note adhésive4",
"type": "n8n-nodes-base.stickyNote",
"position": [
-806.5,
855
],
"parameters": {
"color": 5,
"width": 1568.9362829025763,
"height": 705.2695614889159,
"content": "## Workflow to Create Local Knowledgebase from Google Drive Folder"
},
"typeVersion": 1
}
],
"active": false,
"pinData": {},
"settings": {
"executionOrder": "v1"
},
"versionId": "ecc4d322-242f-4c1e-a43a-18d79efde064",
"connections": {
"b5cf9dc7-7bd9-41a3-b736-6417de3cf4b0": {
"main": [
[
{
"node": "fee137e8-a785-4a07-a3f7-84f1d15438f8",
"type": "main",
"index": 0
}
]
]
},
"49d25a7c-432c-4794-ad49-c6dc57685120": {
"main": [
[
{
"node": "b5cf9dc7-7bd9-41a3-b736-6417de3cf4b0",
"type": "main",
"index": 0
}
]
]
},
"39b32d2b-b4c7-44de-8f86-f519be58e4b5": {
"main": [
[
{
"node": "b5cf9dc7-7bd9-41a3-b736-6417de3cf4b0",
"type": "main",
"index": 0
}
]
]
},
"a5282142-d4dc-40b9-bff9-93df5fc5905f": {
"ai_languageModel": [
[
{
"node": "3d6d64f3-b1d3-4453-9f17-6d3a55273407",
"type": "ai_languageModel",
"index": 0
}
]
]
},
"fee137e8-a785-4a07-a3f7-84f1d15438f8": {
"main": [
[
{
"node": "03adfdbf-1dc4-48c4-9263-5660f1abb505",
"type": "main",
"index": 0
}
]
]
},
"76a8d5b3-0c41-4f6c-b3c1-6a00ce555b23": {
"ai_embedding": [
[
{
"node": "d975770d-0463-480c-aa70-33395f5f40b2",
"type": "ai_embedding",
"index": 0
}
]
]
},
"03cfe40b-62ca-41af-ba97-80072e018e3d": {
"ai_languageModel": [
[
{
"node": "fbcc24b9-f983-49af-a7b9-dc78277e746c",
"type": "ai_languageModel",
"index": 0
}
]
]
},
"f3f1d04c-050e-4aa6-85b1-cbb4b3eaf591": {
"ai_embedding": [
[
{
"node": "066b5093-a034-43e8-a5ea-72aea5770d6c",
"type": "ai_embedding",
"index": 0
}
]
]
},
"5490338c-f7a4-4e14-a493-b2f3d60af56f": {
"ai_document": [
[
{
"node": "066b5093-a034-43e8-a5ea-72aea5770d6c",
"type": "ai_document",
"index": 0
}
]
]
},
"d975770d-0463-480c-aa70-33395f5f40b2": {
"ai_vectorStore": [
[
{
"node": "3d6d64f3-b1d3-4453-9f17-6d3a55273407",
"type": "ai_vectorStore",
"index": 0
}
]
]
},
"5c16650c-44a9-4c5f-b8f2-d0e9e5a0f41d": {
"ai_memory": [
[
{
"node": "fbcc24b9-f983-49af-a7b9-dc78277e746c",
"type": "ai_memory",
"index": 0
}
]
]
},
"03adfdbf-1dc4-48c4-9263-5660f1abb505": {
"main": [
[
{
"node": "066b5093-a034-43e8-a5ea-72aea5770d6c",
"type": "main",
"index": 0
}
]
]
},
"250ff8ae-f645-4644-af93-f2148549ed86": {
"main": [
[
{
"node": "fbcc24b9-f983-49af-a7b9-dc78277e746c",
"type": "main",
"index": 0
}
]
]
},
"1bcb0f4f-92bb-40e6-a1a9-2a2acd232202": {
"ai_textSplitter": [
[
{
"node": "5490338c-f7a4-4e14-a493-b2f3d60af56f",
"type": "ai_textSplitter",
"index": 0
}
]
]
},
"3d6d64f3-b1d3-4453-9f17-6d3a55273407": {
"ai_tool": [
[
{
"node": "fbcc24b9-f983-49af-a7b9-dc78277e746c",
"type": "ai_tool",
"index": 0
}
]
]
}
}
}Comment utiliser ce workflow ?
Copiez le code de configuration JSON ci-dessus, créez un nouveau workflow dans votre instance n8n et sélectionnez "Importer depuis le JSON", collez la configuration et modifiez les paramètres d'authentification selon vos besoins.
Dans quelles scénarios ce workflow est-il adapté ?
Avancé - Wiki interne, RAG IA
Est-ce payant ?
Ce workflow est entièrement gratuit et peut être utilisé directement. Veuillez noter que les services tiers utilisés dans le workflow (comme l'API OpenAI) peuvent nécessiter un paiement de votre part.
Workflows recommandés
David Olusola
@dae221AI automation consultant working with ambitious businesses on their most complex operational challenges. For project inquiries, reach me at david@daexai.com
Partager ce workflow