{
  "id": "Uz3L0EpsCqsr7aFV",
  "name": "Ultimate Blog Content Author RAG AI Agent + Perplexity Research",
  "tags": [],
  "nodes": [
    {
      "id": "6ebbb531-ac74-477e-8db9-098ed6a809a8",
      "name": "Anthropic Chat Model",
      "type": "@n8n/n8n-nodes-langchain.lmChatAnthropic",
      "position": [
        -80,
        224
      ],
      "parameters": {
        "model": {
          "__rl": true,
          "mode": "list",
          "value": "claude-sonnet-4-20250514",
          "cachedResultName": "Claude 4 Sonnet"
        },
        "options": {}
      },
      "typeVersion": 1.3
    },
    {
      "id": "6c677236-70db-43af-9bc2-22437a253c8e",
      "name": "Pinecone Vector Store",
      "type": "@n8n/n8n-nodes-langchain.vectorStorePinecone",
      "position": [
        384,
        224
      ],
      "parameters": {
        "mode": "retrieve-as-tool",
        "options": {},
        "pineconeIndex": {
          "__rl": true,
          "mode": "list",
          "value": "<<<PINECONE_INDEX>>>",
          "cachedResultName": "<<<PINECONE_INDEX_NAME>>>"
        },
        "toolDescription": "Refer to Pinecone Vector Database for similar style Blogs"
      },
      "typeVersion": 1.3
    },
    {
      "id": "ebc335c7-a58c-4474-8e4b-57994736fe3d",
      "name": "Embeddings OpenAI",
      "type": "@n8n/n8n-nodes-langchain.embeddingsOpenAi",
      "position": [
        496,
        400
      ],
      "parameters": {
        "options": {}
      },
      "typeVersion": 1.2
    },
    {
      "id": "0febdaf1-3548-45b1-9cb5-654f2da17abd",
      "name": "Blogpost AI Agent",
      "type": "@n8n/n8n-nodes-langchain.agent",
      "position": [
        48,
        0
      ],
      "parameters": {
        "text": "={{ $json['Blogpost Idea'] }}",
        "options": {
          "systemMessage": "=You are an expert blogpost writer AI Agent.\nYour only task is to generate a complete, engaging, and well-structured blogpost based on the user\u2019s provided blogpost idea.\n\n\ud83d\udd12 Constraints:\n\nAlways write in clear, professional, and natural language.\n\nOutput only the final blogpost content \u2014 no explanations, commentary, or metadata.\n\nStructure the blogpost with:\n\nA catchy title\n\nAn engaging introduction\n\nWell-organized sections with subheadings\n\nA concise and impactful conclusion\n\nLength: at least 800 words (unless the user specifies otherwise).\n\nTailor tone and style to suit the topic (e.g., educational, conversational, persuasive, or technical).\n\nInclude examples, analogies, or step-by-step breakdowns when helpful.\n\nDo not repeat the user\u2019s input verbatim; expand it into a fully developed article.\n\nDo not include system prompts, notes, or formatting instructions in your output.\n\nThe user will provide the blogpost idea. You will return the finished blogpost.\n\n##Tool\nUse the Pinecone Vector Store Tool to refer to the style of blogpost that the user want.\n\nUse the Perplexity Tool attached to research relevant news and latest information about the blog content"
        },
        "promptType": "define"
      },
      "typeVersion": 2.2
    },
    {
      "id": "0332a3a7-fd9e-4d78-83e6-fd8efaedf3cc",
      "name": "Create a document",
      "type": "n8n-nodes-base.googleDocs",
      "position": [
        720,
        0
      ],
      "parameters": {
        "title": "Blogpost",
        "folderId": "<<<GOOGLE_DRIVE_FOLDER_ID>>>"
      },
      "typeVersion": 2
    },
    {
      "id": "f1127452-a013-43ef-80d4-95ea3eab249f",
      "name": "Update a document",
      "type": "n8n-nodes-base.googleDocs",
      "position": [
        992,
        0
      ],
      "parameters": {
        "actionsUi": {
          "actionFields": [
            {
              "text": "={{ $('Blogpost AI Agent').item.json.output }}",
              "action": "insert"
            }
          ]
        },
        "operation": "update",
        "documentURL": "<<<GOOGLE_DOC_URL>>>"
      },
      "typeVersion": 2
    },
    {
      "id": "1b35134a-10d2-40be-96ba-3ed71cef93fa",
      "name": "Slack Trigger",
      "type": "n8n-nodes-base.slackTrigger",
      "position": [
        -352,
        0
      ],
      "parameters": {
        "options": {},
        "trigger": [
          "app_mention"
        ],
        "channelId": {
          "__rl": true,
          "mode": "id",
          "value": "<<<SLACK_CHANNEL_ID>>>"
        }
      },
      "typeVersion": 1
    },
    {
      "id": "899b1b78-95f6-4424-9ea9-d51cfa44bc46",
      "name": "Simple Memory",
      "type": "@n8n/n8n-nodes-langchain.memoryBufferWindow",
      "position": [
        80,
        224
      ],
      "parameters": {
        "contextWindowLength": 15
      },
      "typeVersion": 1.3
    },
    {
      "id": "4fa88631-8e4f-4952-b0eb-1205bde7d759",
      "name": "Message a model in Perplexity",
      "type": "n8n-nodes-base.perplexityTool",
      "position": [
        256,
        224
      ],
      "parameters": {
        "model": "sonar-pro",
        "options": {},
        "messages": {
          "message": [
            {
              "content": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('message0_Text', ``, 'string') }}"
            }
          ]
        },
        "simplify": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Simplify_Output', ``, 'boolean') }}",
        "requestOptions": {}
      },
      "typeVersion": 1
    },
    {
      "id": "3a7751f2-4073-4ac9-9707-dde3ca854ece",
      "name": "Sticky Note",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -560,
        -208
      ],
      "parameters": {
        "width": 432,
        "height": 880,
        "content": "Slack Trigger"
      },
      "typeVersion": 1
    },
    {
      "id": "17656652-74cc-4bd5-a793-bc4131d3b60c",
      "name": "Sticky Note1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -112,
        -208
      ],
      "parameters": {
        "color": 5,
        "width": 752,
        "height": 880,
        "content": "Blogpost AI Agent"
      },
      "typeVersion": 1
    },
    {
      "id": "528cd1cc-3015-4d93-9697-6202cd13083c",
      "name": "Sticky Note2",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        656,
        -208
      ],
      "parameters": {
        "color": 6,
        "width": 272,
        "height": 880,
        "content": "Document Creation"
      },
      "typeVersion": 1
    },
    {
      "id": "3fe67e52-6ce7-441c-a7d6-5377ad478022",
      "name": "Sticky Note3",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        944,
        -208
      ],
      "parameters": {
        "color": 2,
        "width": 272,
        "height": 880,
        "content": "Write Blog Content to Google Doc"
      },
      "typeVersion": 1
    },
    {
      "id": "dd56b80b-c511-4f7b-b546-98ddf3190513",
      "name": "Sticky Note4",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -1184,
        -208
      ],
      "parameters": {
        "color": 4,
        "width": 592,
        "height": 976,
        "content": "\u270d\ufe0f Ultimate AI Blog Content Creator with Slack + Pinecone + Perplexity\n\nDescription\nTurn your marketing team\u2019s blog ideas into full, research-backed, brand-aligned articles with one Slack mention. This workflow connects Slack, Pinecone, and Perplexity to deliver high-impact blog posts that match your company\u2019s voice and leverage the latest research \u2014 all written directly into Google Docs for immediate publishing.\n\n\ud83d\udc49 Watch step-by-step build of this workflow on: www.youtube.com/@automatewithmarc\n\nHow It Works\n\nSlack Trigger \u2013 Marketing team members @mention the bot with a blog idea.\n\nPerplexity Tool \u2013 Gathers the most up-to-date insights and research on the topic.\n\nPinecone Vector DB \u2013 Injects your brand guidelines, tone, and style from stored vectors.\n\nAI Blogpost Agent \u2013 Powered by Anthropic/OpenAI, it blends research + style to create a polished, structured blog post.\n\nSimple Memory \u2013 Keeps context across requests for more consistent content.\n\nGoogle Docs \u2013 Creates and updates a document with the generated article, ready for review or publishing.\n\nWhy Content Teams Will Love It\n\n\u26a1 Faster turnaround \u2014 go from idea to publish-ready blog in minutes.\n\n\ud83d\udcdd On-brand every time \u2014 uses your Pinecone-stored brand guidelines.\n\n\ud83c\udf0d Research-driven \u2014 Perplexity ensures content is current and credible.\n\n\ud83e\udd1d Team-friendly \u2014 triggered right inside Slack for effortless collaboration.\n\nRequirements\n\nSlack App (with app_mentions:read, chat:write)\n\nPinecone account with embedded brand guideline vectors\n\nPerplexity API key\n\nAnthropic/OpenAI API key\n\nGoogle Docs account"
      },
      "typeVersion": 1
    }
  ],
  "active": false,
  "settings": {
    "executionOrder": "v1"
  },
  "connections": {
    "Simple Memory": {
      "ai_memory": [
        [
          {
            "node": "Blogpost AI Agent",
            "type": "ai_memory",
            "index": 0
          }
        ]
      ]
    },
    "Slack Trigger": {
      "main": [
        [
          {
            "node": "Blogpost AI Agent",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Blogpost AI Agent": {
      "main": [
        [
          {
            "node": "Create a document",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Create a document": {
      "main": [
        [
          {
            "node": "Update a document",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Embeddings OpenAI": {
      "ai_embedding": [
        [
          {
            "node": "Pinecone Vector Store",
            "type": "ai_embedding",
            "index": 0
          }
        ]
      ]
    },
    "Anthropic Chat Model": {
      "ai_languageModel": [
        [
          {
            "node": "Blogpost AI Agent",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "Pinecone Vector Store": {
      "ai_tool": [
        [
          {
            "node": "Blogpost AI Agent",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "Message a model in Perplexity": {
      "ai_tool": [
        [
          {
            "node": "Blogpost AI Agent",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    }
  }
}