Created
December 5, 2025 21:58
-
-
Save unlocomqx/4abc87b25810d8f09112bf2acc369231 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| { | |
| "nodes": [ | |
| { | |
| "parameters": { | |
| "modelName": "models/gemini-2.5-pro", | |
| "options": {} | |
| }, | |
| "id": "a32c839f-144b-47a0-b6a4-bd619e645c81", | |
| "cid": "Ikx1Y2FzIFBleXJpbiI", | |
| "name": "Gemini 2.5 Flash", | |
| "type": "@n8n/n8n-nodes-langchain.lmChatGoogleGemini", | |
| "creator": "Lucas Peyrin", | |
| "position": [ | |
| 1904, | |
| 240 | |
| ], | |
| "typeVersion": 1, | |
| "credentials": { | |
| "googlePalmApi": { | |
| "id": "1hVMDAeIReNMOdNs", | |
| "name": "Google Gemini(PaLM) Api account" | |
| } | |
| }, | |
| "notes": "© 2025 Lucas Peyrin" | |
| }, | |
| { | |
| "parameters": {}, | |
| "id": "7e4ffdee-fe74-4560-925a-485a3ecc1e13", | |
| "cid": "Ikx1Y2FzIFBleXJpbiI", | |
| "name": "Gemini Query Embedding", | |
| "type": "@n8n/n8n-nodes-langchain.embeddingsGoogleGemini", | |
| "creator": "Lucas Peyrin", | |
| "position": [ | |
| 2368, | |
| 448 | |
| ], | |
| "typeVersion": 1, | |
| "credentials": { | |
| "googlePalmApi": { | |
| "id": "1hVMDAeIReNMOdNs", | |
| "name": "Google Gemini(PaLM) Api account" | |
| } | |
| }, | |
| "notes": "© 2025 Lucas Peyrin" | |
| }, | |
| { | |
| "parameters": { | |
| "promptType": "define", | |
| "text": "={{ $json.chatInput }}", | |
| "options": { | |
| "systemMessage": "=<role>\nYou are a specialized AI assistant, an expert in the Dynamic Product module documentation. Your sole mission is to help the Customer by providing accurate and factual information extracted exclusively from this documentation. You are meticulous, factual, and never deviate from your knowledge scope. You will receive the conversation between the customer and the seller. Respond as if you are the seller.\n</role>\n\n<instructions>\n<goal>\nYour primary goal is to provide precise and factual answers to the Customer questions about the Dynamic product module, which is a module that supports many types of fields and makes dynamic calculations to calculate the price & weight of a product.\n\nYour job is to generate a response to the support thread to solve the Customer problem or to answer their question.\n</goal>\n\n<context>\nYou operate according to a RAG (Retrieval-Augmented Generation) model. For each user question, use the appropriate tool to retrieve the necessary information from the Dynamic product documentation's vector database or from the Support vector database.\n\n**Mandatory rules:**\n\n1. **Single source of truth:** Your answer MUST be entirely and solely derived from the information present in the provided documentation or the support messages provided. The support messages will be passed to you as coming from Seller and Customer. Respond as if you are the seller.\n2. **Accuracy and implicit citation:** Base your answer as literally as possible on the documentation text. Rephrase for clarity and conciseness, but do not add any information not found there. Act as if the documentation is your only knowledge in the world.\n3. **Do not mention the process:** Never mention your tool or the fact that you are a RAG system in your answer to the user. Respond as an expert who directly consults their documentation.\n4. **The seller IP:** To get the correct IP, you must run the HTTP request tool to get the current IP. Do not put the IP between quotes, place it in a new line to make it easier to copy it.\n5. **No sensitive data:** NEVER share sensitive data such as emails, passwords, backoffice links and ftp access credentials.\n\n</context>\n\n<output_format>\n* **Greeting** Greet the Customer using their name if provided.\n* **No apology** You don't have to apologize if the customer is encountering a problem. It's sounds too dramatic. Keep it cool.\n* **Inquiring** Ask for the product link if the Customer is having an issue with a specific product and did not provide a product link.\n* **Maintenance mode** If the Customer's shop is in maintenance mode, ask them to add my IP to the maintenance settings.\n* **Clarity:** Provide a clear, concise, and direct answer.\n* **Structuring:** If the context contains steps, lists, or code examples, use Markdown syntax to format them legibly (bullet points, numbered lists, code blocks for code snippets, JSON, etc.).\n* **Tone:** Adopt a professional, helpful, and confident tone, that of a technical Dynamic product expert. Conclude the message with kind words.\n* **Signature:** Add \"Dynamic Product Support\" at the end.\n* **Language:** Respond in the same language as the customer.\n</output_format>\n</instructions>" | |
| } | |
| }, | |
| "id": "4af2d430-db2c-44b0-94f7-8cbe0109e3a5", | |
| "cid": "Ikx1Y2FzIFBleXJpbiI", | |
| "name": "n8n Docs AI Agent", | |
| "type": "@n8n/n8n-nodes-langchain.agent", | |
| "creator": "Lucas Peyrin", | |
| "position": [ | |
| 2096, | |
| 16 | |
| ], | |
| "typeVersion": 2.1, | |
| "alwaysOutputData": false, | |
| "executeOnce": false, | |
| "notes": "© 2025 Lucas Peyrin" | |
| }, | |
| { | |
| "parameters": { | |
| "sessionIdType": "customKey", | |
| "sessionKey": "={{ $json.threadId }}" | |
| }, | |
| "type": "@n8n/n8n-nodes-langchain.memoryBufferWindow", | |
| "typeVersion": 1.3, | |
| "position": [ | |
| 2032, | |
| 240 | |
| ], | |
| "id": "a0414d87-1af2-4b71-9f69-837685d4f1e3", | |
| "name": "Simple Memory" | |
| }, | |
| { | |
| "parameters": { | |
| "toolDescription": "Makes a HTTP request to get the current IP to be sent to the Customer. The IP will be used to allow the seller to view the shop in maintenance mode.", | |
| "url": "http://ip-api.com/json/unlocomqx.duckdns.org", | |
| "options": {}, | |
| "optimizeResponse": true, | |
| "fieldsToInclude": "selected", | |
| "fields": "query" | |
| }, | |
| "type": "n8n-nodes-base.httpRequestTool", | |
| "typeVersion": 4.2, | |
| "position": [ | |
| 2160, | |
| 240 | |
| ], | |
| "id": "c977d523-c246-4c8d-98ab-18442b1e56a8", | |
| "name": "Get Seller current IP", | |
| "notes": "Use this tool to get the current IP of the seller. The IP is useful to allow the seller to view the customer's shop when the shop is in maintenance mode." | |
| }, | |
| { | |
| "parameters": { | |
| "assignments": { | |
| "assignments": [ | |
| { | |
| "id": "1e9667cb-b9f4-42c9-ab57-2eea7cfc6a37", | |
| "name": "output", | |
| "value": "={{ $json.output }}", | |
| "type": "string" | |
| } | |
| ] | |
| }, | |
| "options": {} | |
| }, | |
| "type": "n8n-nodes-base.set", | |
| "typeVersion": 3.4, | |
| "position": [ | |
| 2944, | |
| 16 | |
| ], | |
| "id": "97b2aaea-e480-4833-863e-1e7e4d1c5df7", | |
| "name": "Return" | |
| }, | |
| { | |
| "parameters": { | |
| "workflowInputs": { | |
| "values": [ | |
| { | |
| "name": "chatInput", | |
| "type": "any" | |
| }, | |
| { | |
| "name": "threadId", | |
| "type": "any" | |
| } | |
| ] | |
| } | |
| }, | |
| "id": "c9dfeac7-06bc-4aa4-807b-9117da315ef4", | |
| "typeVersion": 1.1, | |
| "name": "Start", | |
| "type": "n8n-nodes-base.executeWorkflowTrigger", | |
| "position": [ | |
| 1456, | |
| 112 | |
| ] | |
| }, | |
| { | |
| "parameters": {}, | |
| "id": "c14a46c9-5086-4a89-bca4-5e48f9563aa9", | |
| "cid": "Ikx1Y2FzIFBleXJpbiI", | |
| "name": "Gemini Query Embedding1", | |
| "type": "@n8n/n8n-nodes-langchain.embeddingsGoogleGemini", | |
| "creator": "Lucas Peyrin", | |
| "position": [ | |
| 2656, | |
| 448 | |
| ], | |
| "typeVersion": 1, | |
| "credentials": { | |
| "googlePalmApi": { | |
| "id": "1hVMDAeIReNMOdNs", | |
| "name": "Google Gemini(PaLM) Api account" | |
| } | |
| }, | |
| "notes": "© 2025 Lucas Peyrin" | |
| }, | |
| { | |
| "parameters": { | |
| "mode": "retrieve-as-tool", | |
| "toolDescription": "Get related chunks of the official Dynamic Product documentation.", | |
| "qdrantCollection": { | |
| "__rl": true, | |
| "value": "dp-docs", | |
| "mode": "list", | |
| "cachedResultName": "dp-docs" | |
| }, | |
| "topK": 10, | |
| "options": {} | |
| }, | |
| "type": "@n8n/n8n-nodes-langchain.vectorStoreQdrant", | |
| "typeVersion": 1.3, | |
| "position": [ | |
| 2288, | |
| 240 | |
| ], | |
| "id": "ef5e073e-4973-4616-9b0d-f35d9048ced2", | |
| "name": "Docs Vector Store", | |
| "credentials": { | |
| "qdrantApi": { | |
| "id": "RH3RJkdv3kquotSh", | |
| "name": "QdrantApi account" | |
| } | |
| } | |
| }, | |
| { | |
| "parameters": { | |
| "mode": "retrieve-as-tool", | |
| "toolDescription": "Get related chunks of the support messages history.", | |
| "qdrantCollection": { | |
| "__rl": true, | |
| "value": "dp-support", | |
| "mode": "list", | |
| "cachedResultName": "dp-support" | |
| }, | |
| "topK": 10, | |
| "options": {} | |
| }, | |
| "type": "@n8n/n8n-nodes-langchain.vectorStoreQdrant", | |
| "typeVersion": 1.3, | |
| "position": [ | |
| 2576, | |
| 240 | |
| ], | |
| "id": "76aef67c-426b-41d7-aa1a-37e7158b807b", | |
| "name": "Support Vector Store", | |
| "credentials": { | |
| "qdrantApi": { | |
| "id": "RH3RJkdv3kquotSh", | |
| "name": "QdrantApi account" | |
| } | |
| } | |
| }, | |
| { | |
| "parameters": { | |
| "options": {} | |
| }, | |
| "type": "@n8n/n8n-nodes-langchain.chatTrigger", | |
| "typeVersion": 1.3, | |
| "position": [ | |
| 1456, | |
| -80 | |
| ], | |
| "id": "c2489d70-5117-4bb3-aa26-ab146a06f934", | |
| "name": "When chat message received", | |
| "webhookId": "53cec8f2-8d88-45eb-a36a-85144180432e" | |
| }, | |
| { | |
| "parameters": { | |
| "assignments": { | |
| "assignments": [ | |
| { | |
| "id": "1b072337-55b0-45f4-a595-27d0e60a69c0", | |
| "name": "threadId", | |
| "value": 0, | |
| "type": "number" | |
| }, | |
| { | |
| "id": "7b1f748b-527b-4da7-890c-92b5a3bb87dc", | |
| "name": "chatInput", | |
| "value": "={{ $json.chatInput }}", | |
| "type": "string" | |
| } | |
| ] | |
| }, | |
| "options": {} | |
| }, | |
| "type": "n8n-nodes-base.set", | |
| "typeVersion": 3.4, | |
| "position": [ | |
| 1680, | |
| 16 | |
| ], | |
| "id": "54c72fc0-90d2-4337-8b80-5a2d3d15b28c", | |
| "name": "Set fields" | |
| } | |
| ], | |
| "connections": { | |
| "Gemini 2.5 Flash": { | |
| "ai_languageModel": [ | |
| [ | |
| { | |
| "node": "n8n Docs AI Agent", | |
| "type": "ai_languageModel", | |
| "index": 0 | |
| } | |
| ] | |
| ] | |
| }, | |
| "Gemini Query Embedding": { | |
| "ai_embedding": [ | |
| [ | |
| { | |
| "node": "Docs Vector Store", | |
| "type": "ai_embedding", | |
| "index": 0 | |
| } | |
| ] | |
| ] | |
| }, | |
| "n8n Docs AI Agent": { | |
| "main": [ | |
| [ | |
| { | |
| "node": "Return", | |
| "type": "main", | |
| "index": 0 | |
| } | |
| ] | |
| ] | |
| }, | |
| "Simple Memory": { | |
| "ai_memory": [ | |
| [ | |
| { | |
| "node": "n8n Docs AI Agent", | |
| "type": "ai_memory", | |
| "index": 0 | |
| } | |
| ] | |
| ] | |
| }, | |
| "Get Seller current IP": { | |
| "ai_tool": [ | |
| [ | |
| { | |
| "node": "n8n Docs AI Agent", | |
| "type": "ai_tool", | |
| "index": 0 | |
| } | |
| ] | |
| ] | |
| }, | |
| "Start": { | |
| "main": [ | |
| [ | |
| { | |
| "node": "Set fields", | |
| "type": "main", | |
| "index": 0 | |
| } | |
| ] | |
| ] | |
| }, | |
| "Gemini Query Embedding1": { | |
| "ai_embedding": [ | |
| [ | |
| { | |
| "node": "Support Vector Store", | |
| "type": "ai_embedding", | |
| "index": 0 | |
| } | |
| ] | |
| ] | |
| }, | |
| "Docs Vector Store": { | |
| "ai_tool": [ | |
| [ | |
| { | |
| "node": "n8n Docs AI Agent", | |
| "type": "ai_tool", | |
| "index": 0 | |
| } | |
| ] | |
| ] | |
| }, | |
| "Support Vector Store": { | |
| "ai_tool": [ | |
| [ | |
| { | |
| "node": "n8n Docs AI Agent", | |
| "type": "ai_tool", | |
| "index": 0 | |
| } | |
| ] | |
| ] | |
| }, | |
| "When chat message received": { | |
| "main": [ | |
| [ | |
| { | |
| "node": "Set fields", | |
| "type": "main", | |
| "index": 0 | |
| } | |
| ] | |
| ] | |
| }, | |
| "Set fields": { | |
| "main": [ | |
| [ | |
| { | |
| "node": "n8n Docs AI Agent", | |
| "type": "main", | |
| "index": 0 | |
| } | |
| ] | |
| ] | |
| } | |
| }, | |
| "pinData": {}, | |
| "meta": { | |
| "instanceId": "97dfcfcc095a4aaee6c8b1a73f3b5266d6da286ef0f01947d5ed3bde8680014a" | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment