AutomationFlowsAI & RAG › Generate Deep Research Markdown Reports with Gpt, Tavily Search, and Google…

Generate Deep Research Markdown Reports with Gpt, Tavily Search, and Google…

Original n8n title: Generate Deep Research Markdown Reports with Gpt, Tavily Search, and Google Sheets

ByArchit Jain @architjn on n8n.io

This workflow generates deep researched report in markdown format and saves it in Google Sheet, that I then use for generating blogs for my website - Architjn Blogs User submits a search topic through a form. AI generates five deep-dive subtopics for that main topic. AI creates…

Event trigger★★★★★ complexityAI-powered36 nodesAgentOpenRouter ChatOutput Parser StructuredGoogle SheetsForm TriggerHTTP Request
AI & RAG Trigger: Event Nodes: 36 Complexity: ★★★★★ AI nodes: yes Added:

This workflow corresponds to n8n.io template #5040 — we link there as the canonical source.

This workflow follows the Agent → Form Trigger recipe pattern — see all workflows that pair these two integrations.

The workflow JSON

Copy or download the full n8n JSON below. Paste it into a new n8n workflow, add your credentials, activate. Full import guide →

Download .json
{
  "id": "oIEM1QnxTXuxJK06",
  "meta": {
    "templateCredsSetupCompleted": true
  },
  "name": "Blog Research Agent",
  "tags": [],
  "nodes": [
    {
      "id": "461f5b9e-aae4-440d-ab06-8a1fda2067d2",
      "name": "Plan Topics",
      "type": "@n8n/n8n-nodes-langchain.agent",
      "position": [
        300,
        360
      ],
      "parameters": {},
      "typeVersion": 1.8
    },
    {
      "id": "a6da4abd-c14c-4c83-bd11-669d430f81c6",
      "name": "OpenRouter Chat Model",
      "type": "@n8n/n8n-nodes-langchain.lmChatOpenRouter",
      "position": [
        300,
        600
      ],
      "parameters": {},
      "typeVersion": 1
    },
    {
      "id": "b17c5fa2-2775-46a6-99ac-c33e3cb59be7",
      "name": "5 Topics",
      "type": "@n8n/n8n-nodes-langchain.outputParserStructured",
      "position": [
        480,
        600
      ],
      "parameters": {},
      "typeVersion": 1.2
    },
    {
      "id": "85f3a5e2-d9cd-4fbc-862c-ad2fa8942c4f",
      "name": "Intro",
      "type": "@n8n/n8n-nodes-langchain.agent",
      "position": [
        840,
        360
      ],
      "parameters": {},
      "typeVersion": 1.8
    },
    {
      "id": "60c9b770-eb5d-4ec4-a1d4-1ce2570858a1",
      "name": "OpenRouter Chat Model1",
      "type": "@n8n/n8n-nodes-langchain.lmChatOpenRouter",
      "position": [
        820,
        600
      ],
      "parameters": {},
      "typeVersion": 1
    },
    {
      "id": "dcf99d6f-664e-4bb1-af2f-1cbb36763072",
      "name": "Split Out",
      "type": "n8n-nodes-base.splitOut",
      "position": [
        840,
        200
      ],
      "parameters": {},
      "typeVersion": 1
    },
    {
      "id": "836f8995-e123-461f-b505-71e065605684",
      "name": "Merge",
      "type": "n8n-nodes-base.merge",
      "position": [
        1480,
        340
      ],
      "parameters": {},
      "typeVersion": 3
    },
    {
      "id": "18680074-aad2-4106-9e1c-c7713ce1c32c",
      "name": "Set Topics",
      "type": "n8n-nodes-base.set",
      "position": [
        840,
        20
      ],
      "parameters": {},
      "typeVersion": 3.4
    },
    {
      "id": "d7cba83c-f997-4af3-8ffa-900d8875b88a",
      "name": "Merge1",
      "type": "n8n-nodes-base.merge",
      "position": [
        1300,
        180
      ],
      "parameters": {},
      "typeVersion": 3
    },
    {
      "id": "66e44854-4520-48cc-9bab-7b939ee43ae4",
      "name": "Split Out1",
      "type": "n8n-nodes-base.splitOut",
      "position": [
        1060,
        20
      ],
      "parameters": {},
      "typeVersion": 1
    },
    {
      "id": "eed6db9e-16fa-4ac0-b21f-8738a0423517",
      "name": "Get Sources",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        2460,
        240
      ],
      "parameters": {},
      "typeVersion": 4.5,
      "alwaysOutputData": true
    },
    {
      "id": "5647860e-f4ec-45ca-bd3a-1f7a55e586f0",
      "name": "OpenRouter Chat Model7",
      "type": "@n8n/n8n-nodes-langchain.lmChatOpenRouter",
      "position": [
        3240,
        520
      ],
      "parameters": {},
      "typeVersion": 1
    },
    {
      "id": "4a5c66ba-d062-4de9-8f81-ba87a84c162e",
      "name": "Sources",
      "type": "@n8n/n8n-nodes-langchain.agent",
      "position": [
        2660,
        240
      ],
      "parameters": {},
      "typeVersion": 1.8
    },
    {
      "id": "d3182822-2501-4a79-8638-655bc791ed44",
      "name": "Send Sources",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        2980,
        240
      ],
      "parameters": {},
      "typeVersion": 4.5,
      "alwaysOutputData": true
    },
    {
      "id": "db8a1543-2caf-4c55-8289-849b6006cf1a",
      "name": "Get All Content",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        3180,
        240
      ],
      "parameters": {},
      "typeVersion": 4.5
    },
    {
      "id": "547a265e-2e9e-4442-8ef2-88f2dd4c28c0",
      "name": "Table of Contents",
      "type": "@n8n/n8n-nodes-langchain.agent",
      "position": [
        2220,
        500
      ],
      "parameters": {},
      "typeVersion": 1.8
    },
    {
      "id": "7d357654-56ea-48ba-95f4-fd82e36a9c14",
      "name": "Send ToC",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        2580,
        500
      ],
      "parameters": {},
      "typeVersion": 4.5
    },
    {
      "id": "5477b03c-b667-4c4f-9452-a49ff4602544",
      "name": "Send Intro",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        1180,
        360
      ],
      "parameters": {},
      "typeVersion": 4.5
    },
    {
      "id": "7a67e38c-e0c9-478a-b522-f7b3aa960b1f",
      "name": "Title, Intro, Chapters",
      "type": "@n8n/n8n-nodes-langchain.outputParserStructured",
      "position": [
        1040,
        600
      ],
      "parameters": {},
      "typeVersion": 1.2
    },
    {
      "id": "5d496c36-6e2a-4413-8e91-b6a32f05bcce",
      "name": "Sticky Note",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        0,
        -120
      ],
      "parameters": {
        "content": ""
      },
      "typeVersion": 1
    },
    {
      "id": "e481fc15-4bdf-4b50-8f9a-ad0510848884",
      "name": "Sticky Note6",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        1940,
        -120
      ],
      "parameters": {
        "content": ""
      },
      "typeVersion": 1
    },
    {
      "id": "cc17a444-2cc2-47e5-96ac-d95c83db00f9",
      "name": "On form submission",
      "type": "n8n-nodes-base.formTrigger",
      "position": [
        80,
        360
      ],
      "parameters": {},
      "typeVersion": 2.2
    },
    {
      "id": "58f892de-f9b0-44bd-b5d8-9807fd49f3b6",
      "name": "Loop Over Items",
      "type": "n8n-nodes-base.splitInBatches",
      "position": [
        60,
        1280
      ],
      "parameters": {},
      "typeVersion": 3
    },
    {
      "id": "0d335eb8-8be3-4f85-ad17-0b0d0599f29d",
      "name": "OpenRouter Chat Model8",
      "type": "@n8n/n8n-nodes-langchain.lmChatOpenRouter",
      "position": [
        920,
        1560
      ],
      "parameters": {},
      "typeVersion": 1
    },
    {
      "id": "ccd0951b-80a3-44dd-bc21-45fa20ad077e",
      "name": "Tavily5",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        500,
        1300
      ],
      "parameters": {},
      "typeVersion": 4.2
    },
    {
      "id": "f30bc7f6-ce08-44ed-a782-d630b81b3d02",
      "name": "Split Out7",
      "type": "n8n-nodes-base.splitOut",
      "position": [
        700,
        1300
      ],
      "parameters": {},
      "typeVersion": 1
    },
    {
      "id": "420f21be-5b2c-4a33-912c-106459b8837e",
      "name": "Code5",
      "type": "n8n-nodes-base.code",
      "position": [
        880,
        1300
      ],
      "parameters": {},
      "typeVersion": 2
    },
    {
      "id": "9e20afd7-1dd1-43ec-8e47-6885c738aa15",
      "name": "Aggregate10",
      "type": "n8n-nodes-base.aggregate",
      "position": [
        1420,
        1440
      ],
      "parameters": {},
      "typeVersion": 1
    },
    {
      "id": "ed34ddd8-0fbe-43ab-bb2d-d7f386eb29e7",
      "name": "Writer5",
      "type": "@n8n/n8n-nodes-langchain.agent",
      "position": [
        1060,
        1440
      ],
      "parameters": {},
      "typeVersion": 1.8
    },
    {
      "id": "79ed8d33-211f-40b3-b10a-70d936426df5",
      "name": "Aggregate11",
      "type": "n8n-nodes-base.aggregate",
      "position": [
        1420,
        1300
      ],
      "parameters": {},
      "typeVersion": 1
    },
    {
      "id": "713cefcf-2a8b-404e-abc8-e2876b78c74f",
      "name": "Merge8",
      "type": "n8n-nodes-base.merge",
      "position": [
        1760,
        1580
      ],
      "parameters": {},
      "typeVersion": 3
    },
    {
      "id": "d2787e68-d02c-43da-8e80-d115020779fb",
      "name": "Aggregate12",
      "type": "n8n-nodes-base.aggregate",
      "position": [
        500,
        1020
      ],
      "parameters": {},
      "typeVersion": 1
    },
    {
      "id": "f7f57f46-44c8-4783-85cd-df842d58544b",
      "name": "Google Sheets",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        700,
        1020
      ],
      "parameters": {},
      "typeVersion": 4.5,
      "alwaysOutputData": true
    },
    {
      "id": "26f9b7cb-802e-4ee2-ac49-a7789b0081dd",
      "name": "Sticky Note1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        0,
        900
      ],
      "parameters": {
        "content": ""
      },
      "typeVersion": 1
    },
    {
      "id": "7f707137-6524-4e17-86a3-71fb5b1449e5",
      "name": "Get Sections",
      "type": "n8n-nodes-base.code",
      "position": [
        1560,
        1580
      ],
      "parameters": {},
      "typeVersion": 2
    },
    {
      "id": "0819b92f-9dcb-434f-aaa9-adc74608442d",
      "name": "Sticky Note2",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -560,
        -120
      ],
      "parameters": {
        "content": ""
      },
      "typeVersion": 1
    }
  ],
  "active": false,
  "settings": {
    "executionOrder": "v1"
  },
  "versionId": "25ab24ba-e488-4ef0-943b-b6fc68c80dfc",
  "connections": {
    "Code5": {
      "main": [
        [
          {
            "node": "Writer5",
            "type": "main",
            "index": 0
          },
          {
            "node": "Aggregate11",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Intro": {
      "main": [
        [
          {
            "node": "Send Intro",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Merge": {
      "main": [
        [
          {
            "node": "Loop Over Items",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Merge1": {
      "main": [
        [
          {
            "node": "Merge",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Merge8": {
      "main": [
        [
          {
            "node": "Loop Over Items",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Sources": {
      "main": [
        [
          {
            "node": "Send Sources",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Tavily5": {
      "main": [
        [
          {
            "node": "Split Out7",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Writer5": {
      "main": [
        [
          {
            "node": "Aggregate10",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "5 Topics": {
      "ai_outputParser": [
        [
          {
            "node": "Plan Topics",
            "type": "ai_outputParser",
            "index": 0
          }
        ]
      ]
    },
    "Send ToC": {
      "main": [
        []
      ]
    },
    "Split Out": {
      "main": [
        [
          {
            "node": "Merge1",
            "type": "main",
            "index": 1
          }
        ]
      ]
    },
    "Send Intro": {
      "main": [
        [
          {
            "node": "Merge",
            "type": "main",
            "index": 1
          }
        ]
      ]
    },
    "Set Topics": {
      "main": [
        [
          {
            "node": "Split Out1",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Split Out1": {
      "main": [
        [
          {
            "node": "Merge1",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Split Out7": {
      "main": [
        [
          {
            "node": "Code5",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Aggregate10": {
      "main": [
        [
          {
            "node": "Get Sections",
            "type": "main",
            "index": 0
          },
          {
            "node": "Merge8",
            "type": "main",
            "index": 1
          }
        ]
      ]
    },
    "Aggregate11": {
      "main": [
        [
          {
            "node": "Merge8",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Aggregate12": {
      "main": [
        [
          {
            "node": "Google Sheets",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get Sources": {
      "main": [
        [
          {
            "node": "Sources",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Plan Topics": {
      "main": [
        [
          {
            "node": "Intro",
            "type": "main",
            "index": 0
          },
          {
            "node": "Split Out",
            "type": "main",
            "index": 0
          },
          {
            "node": "Set Topics",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get Sections": {
      "main": [
        [
          {
            "node": "Merge8",
            "type": "main",
            "index": 2
          }
        ]
      ]
    },
    "Send Sources": {
      "main": [
        [
          {
            "node": "Get All Content",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Google Sheets": {
      "main": [
        [
          {
            "node": "Get Sources",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get All Content": {
      "main": [
        [
          {
            "node": "Table of Contents",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Loop Over Items": {
      "main": [
        [
          {
            "node": "Aggregate12",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Tavily5",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Table of Contents": {
      "main": [
        [
          {
            "node": "Send ToC",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "On form submission": {
      "main": [
        [
          {
            "node": "Plan Topics",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "OpenRouter Chat Model": {
      "ai_languageModel": [
        [
          {
            "node": "Plan Topics",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "OpenRouter Chat Model1": {
      "ai_languageModel": [
        [
          {
            "node": "Intro",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "OpenRouter Chat Model7": {
      "ai_languageModel": [
        [
          {
            "node": "Sources",
            "type": "ai_languageModel",
            "index": 0
          },
          {
            "node": "Table of Contents",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "OpenRouter Chat Model8": {
      "ai_languageModel": [
        [
          {
            "node": "Writer5",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "Title, Intro, Chapters": {
      "ai_outputParser": [
        [
          {
            "node": "Intro",
            "type": "ai_outputParser",
            "index": 0
          }
        ]
      ]
    }
  }
}
Pro

For the full experience including quality scoring and batch install features for each workflow upgrade to Pro

About this workflow

This workflow generates deep researched report in markdown format and saves it in Google Sheet, that I then use for generating blogs for my website - Architjn Blogs User submits a search topic through a form. AI generates five deep-dive subtopics for that main topic. AI creates…

Source: https://n8n.io/workflows/5040/ — original creator credit. Request a take-down →

More AI & RAG workflows → · Browse all categories →

Related workflows

Workflows that share integrations, category, or trigger type with this one. All free to copy and import.

AI & RAG

🧠 Automate end-to-end SEO blog creation and WordPress publishing using a GPT-5 multi-agent workflow with real-time research, metadata generation, and optional featured images.

Output Parser Structured, HTTP Request, OpenAI +10
AI & RAG

YouTube Strategist. Uses formTrigger, splitOut, splitInBatches, agent. Event-driven trigger; 50 nodes.

Form Trigger, Agent, OpenRouter Chat +5
AI & RAG

This advanced multi-phase n8n workflow automates the complete research, analysis, and ideation pipeline for a YouTube strategist. It scrapes competitor channels, analyzes top-performing titles and thu

Form Trigger, Agent, OpenRouter Chat +5
AI & RAG

An automated workflow for creating Veo3.1 videos and posting them to YouTube.

Google Sheets, Form Trigger, YouTube +5
AI & RAG

An automated workflow for creating Veo3 videos and posting them to YouTube.

Google Sheets, Form Trigger, Output Parser Structured +5