{
  "name": "Generate Japanese Twitter posts with GPT-4, quality control, and Notion",
  "nodes": [
    {
      "id": "753b0708-0a28-4031-bfb1-d9adc567a0ab",
      "name": "Sticky Note - Content Generation",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -1504,
        -1088
      ],
      "parameters": {
        "width": 400,
        "height": 400,
        "content": "## 📅 Daily Content Generation Flow\n\nTriggers **Monday-Friday at 9:00 AM JST**\n\n**This section**:\n1. Gets Japanese cultural context (seasons, holidays, business events)\n2. Analyzes your past 30 days of"
      }
    },
    {
      "id": "caf02274-68f6-4ce7-aa56-f79af9bea8eb",
      "name": "Sticky Note - Quality Scoring",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -832,
        -1152
      ],
      "parameters": {
        "width": 380,
        "height": 484,
        "content": "## 🎯 AI Quality Scoring System\n\n**Evaluates content on 100-point scale**:\n- Engagement prediction (30 pts)\n- SEO/discoverability (20 pts)\n- Brand voice alignment (20 pts)\n- Readability (15 pts)\n- CTA "
      }
    },
    {
      "id": "e4561ad5-a3be-4aef-a080-6204a9b9f81e",
      "name": "Sticky Note - Improvement",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -416,
        -1152
      ],
      "parameters": {
        "width": 360,
        "height": 396,
        "content": "## 🔄 Self-Improvement Loop\n\nIf content scores **< 70 points** and **< 3 improvement attempts**:\n\n1. GPT-4 rewrites based on specific feedback\n2. Re-evaluates with quality scoring\n3. Repeats up to 3 ti"
      }
    },
    {
      "id": "5729b69f-86d8-47b5-99fd-1c526ae9c4bb",
      "name": "Sticky Note - Risk Analysis",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -32,
        -1280
      ],
      "parameters": {
        "width": 360,
        "height": 552,
        "content": "## ⚠️ Risk & Sentiment Analysis\n\n**Detects**:\n- Political/religious references\n- Gender/discriminatory language\n- Inappropriate disaster/accident mentions\n- Misleading advertising\n- Competitor attacks"
      }
    },
    {
      "id": "aabaf71e-f6eb-4058-a84e-69a970e5fe00",
      "name": "Sticky Note - Routing",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        448,
        -960
      ],
      "parameters": {
        "width": 340,
        "height": 504,
        "content": "## 🚦 Smart Routing Decision\n\n**Auto-approve** (posts immediately):\n- Quality score ≥ 70\n- Risk level = low\n\n**Requires approval**:\n- Quality score < 70 OR\n- Risk level = medium\n\n**Auto-reject**:\n- Ris"
      }
    },
    {
      "id": "410eb215-935f-4c82-b5f0-1bd1e8580c57",
      "name": "Sticky Note - Auto Approve",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        880,
        -880
      ],
      "parameters": {
        "width": 320,
        "height": 244,
        "content": "## ✅ Auto-Approved Path\n\n1. Saves to Notion (status: published)\n2. Posts to Twitter automatically\n3. No human intervention needed\n\nFor **high-confidence, low-risk content**"
      }
    },
    {
      "id": "f93e3471-ae8d-4c2c-bd98-5014c105c57f",
      "name": "Sticky Note - Approval Path",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        880,
        -288
      ],
      "parameters": {
        "width": 340,
        "height": 324,
        "content": "## 👤 Human Approval Path\n\n1. Saves to Notion (status: pending)\n2. Sends email to approval team with:\n   - Content preview\n   - Quality scores\n   - Risk assessment\n   - Improvement history\n3. Awaits ap"
      }
    },
    {
      "id": "ec996c7f-8057-496c-aef8-0e2615b096f0",
      "name": "Sticky Note - Webhook",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -1504,
        -320
      ],
      "parameters": {
        "width": 360,
        "height": 636,
        "content": "## 🔗 Approval Webhook\n\n**Endpoint**: `/approval-webhook`\n\n**Query parameters**:\n- `action`: approve / reject / edit\n- `id`: content ID from Notion\n\n**Body** (for edits):\n```json\n{\n  \"editedContent\": \""
      }
    },
    {
      "id": "bd65c75e-d488-4c39-8467-d21c4f3824bc",
      "name": "Sticky Note - Analytics",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -1504,
        336
      ],
      "parameters": {
        "width": 380,
        "height": 512,
        "content": "## 📊 Weekly Analytics Report\n\n**Triggers**: Every Monday at 10:00 AM\n\n1. Fetches past week's posts from Notion\n2. GPT-4 analyzes performance data\n3. Generates insights report including:\n   - Performan"
      }
    },
    {
      "id": "d6008133-2353-4db5-b7c1-e31c09be68ae",
      "name": "Sticky Note - Brand Voice",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -1072,
        -624
      ],
      "parameters": {
        "width": 360,
        "height": 420,
        "content": "## 🎨 Brand Voice Learning\n\nAnalyzes your **past 30 days** of posts:\n- Average post length\n- Emoji usage patterns\n- Common hashtags\n- Question-based posts frequency\n- Tone and phrasing\n\nGPT-4 creates a"
      }
    },
    {
      "id": "006b450d-05ee-4bad-8b93-7f712ca365f7",
      "name": "Schedule Daily Content Generation",
      "type": "n8n-nodes-base.scheduleTrigger",
      "position": [
        -1456,
        -608
      ]
    },
    {
      "id": "4d9a56a3-0b26-4ea9-9967-1050459bc6c2",
      "name": "Generate Content with GPT-4",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        -1232,
        -800
      ]
    },
    {
      "id": "bb8094a2-98eb-4e12-aa2c-a3f01a04fec8",
      "name": "Parse Generated Content",
      "type": "n8n-nodes-base.code",
      "position": [
        -1008,
        -800
      ]
    },
    {
      "id": "47c6f1df-ceab-4b18-b22f-4959d4be5760",
      "name": "AI Quality Scoring",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        -784,
        -800
      ]
    },
    {
      "id": "a65792c4-475e-41db-a1bd-9e83a621a983",
      "name": "Parse Quality Scores",
      "type": "n8n-nodes-base.code",
      "position": [
        -560,
        -864
      ]
    },
    {
      "id": "ea9f9825-4276-4f12-a417-f06f757360ed",
      "name": "Check if Improvement Needed",
      "type": "n8n-nodes-base.if",
      "position": [
        -336,
        -864
      ]
    },
    {
      "id": "74c37691-36e4-4222-b281-f2ea2dd613a1",
      "name": "Auto-Improve Content",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        64,
        -960
      ]
    },
    {
      "id": "833cc233-23d4-4d79-bc30-4e8f62d4f38c",
      "name": "Parse Improved Content",
      "type": "n8n-nodes-base.code",
      "position": [
        288,
        -864
      ]
    },
    {
      "id": "07ea81b3-eea8-40b5-93bf-a102bbc9d6b2",
      "name": "Sentiment & Risk Analysis",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        64,
        -784
      ]
    },
    {
      "id": "e31fb9b0-6bf9-4e05-91c3-ffbef666d5e6",
      "name": "Merge Risk Analysis",
      "type": "n8n-nodes-base.code",
      "position": [
        464,
        -448
      ]
    },
    {
      "id": "451a01cd-63ee-4f36-9363-083d0ee3e6f6",
      "name": "Decision Routing",
      "type": "n8n-nodes-base.if",
      "position": [
        672,
        -608
      ]
    },
    {
      "id": "ebb2b91a-1574-408a-ab8c-5148c985b575",
      "name": "Save to Notion (Auto-Approved)",
      "type": "n8n-nodes-base.notion",
      "position": [
        912,
        -608
      ]
    },
    {
      "id": "58147eae-9a9d-4a61-9153-611e3e958631",
      "name": "Save to Notion (Pending Approval)",
      "type": "n8n-nodes-base.notion",
      "position": [
        912,
        -416
      ]
    },
    {
      "id": "9013da0d-41b9-422c-91f9-926afbc6c497",
      "name": "Send Approval Email",
      "type": "n8n-nodes-base.emailSend",
      "position": [
        1232,
        -416
      ]
    },
    {
      "id": "4acc6a07-9613-4703-9232-bc3f3858fd8d",
      "name": "Post to Twitter (Auto-Approved)",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        1232,
        -608
      ]
    },
    {
      "id": "f599a7ef-39fb-46c7-8b1a-bcb7a589702e",
      "name": "Get Japanese Cultural Context",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        -1232,
        -608
      ]
    },
    {
      "id": "5f6ec1cb-e46b-4091-9b7c-3eeaa9600128",
      "name": "Get Past 30 Days Posts",
      "type": "n8n-nodes-base.notion",
      "position": [
        -928,
        -320
      ]
    },
    {
      "id": "7ad8ffaf-34f6-4550-a64f-327a1daa461b",
      "name": "Analyze Brand Voice",
      "type": "n8n-nodes-base.code",
      "position": [
        -640,
        -320
      ]
    },
    {
      "id": "d437b5ec-fb0e-46e1-badb-bf1f7a5bf22b",
      "name": "Create Brand Voice Profile",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        -368,
        -320
      ]
    },
    {
      "id": "8fdc27ce-4ee6-4b4e-9a06-38db4f5b6d7f",
      "name": "Webhook - Approval Dashboard",
      "type": "n8n-nodes-base.webhook",
      "position": [
        -1456,
        128
      ]
    },
    {
      "id": "b5e26e78-ec91-4c1f-b892-fa3c15b2d4ed",
      "name": "Process Approval Action",
      "type": "n8n-nodes-base.code",
      "position": [
        -1248,
        128
      ]
    },
    {
      "id": "0b302fff-97a9-48ba-9123-decbb8d3b370",
      "name": "Check Approval Action",
      "type": "n8n-nodes-base.if",
      "position": [
        -1008,
        128
      ]
    },
    {
      "id": "90bb9902-6237-4b2d-b132-d26515ca1921",
      "name": "Update Notion - Approved",
      "type": "n8n-nodes-base.notion",
      "position": [
        -784,
        32
      ]
    },
    {
      "id": "b2c8f814-39e4-4233-b35f-b65f0dcc1429",
      "name": "Update Notion - Rejected",
      "type": "n8n-nodes-base.notion",
      "position": [
        -784,
        224
      ]
    },
    {
      "id": "ba5bc1a8-dbd9-49b5-add9-a7bf257c6622",
      "name": "Weekly Performance Report Trigger",
      "type": "n8n-nodes-base.scheduleTrigger",
      "position": [
        -1456,
        720
      ]
    },
    {
      "id": "c45a573c-7956-4c4f-8fbe-372e8d0fba17",
      "name": "Get Past Week Posts",
      "type": "n8n-nodes-base.notion",
      "position": [
        -1248,
        720
      ]
    },
    {
      "id": "ae72df4a-5b2f-41bd-a58e-decaa7d0429c",
      "name": "Generate Weekly Analytics Report",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        -1008,
        720
      ]
    },
    {
      "id": "b8903692-a75a-40d4-8bd1-d07cacf51efc",
      "name": "Send Weekly Report Email",
      "type": "n8n-nodes-base.emailSend",
      "position": [
        -784,
        720
      ]
    },
    {
      "id": "e4135011-c917-41db-90c7-7904781cc800",
      "name": "Sticky Note - Main Overview",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -2176,
        -1136
      ],
      "parameters": {
        "width": 560,
        "height": 2164,
        "content": "## AI-Powered Japanese Social Media Content Generator with Quality Control\n\n### 🎯 Who's it for\n\nMarketing teams and social media managers in Japan who want to automate content creation while maintaini"
      }
    }
  ],
  "connections": {
    "Decision Routing": {
      "main": [
        [
          {
            "node": "Save to Notion (Auto-Approved)",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Save to Notion (Pending Approval)",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "AI Quality Scoring": {
      "main": [
        [
          {
            "node": "Parse Quality Scores",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Analyze Brand Voice": {
      "main": [
        [
          {
            "node": "Create Brand Voice Profile",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get Past Week Posts": {
      "main": [
        [
          {
            "node": "Generate Weekly Analytics Report",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Merge Risk Analysis": {
      "main": [
        [
          {
            "node": "Decision Routing",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Auto-Improve Content": {
      "main": [
        [
          {
            "node": "Parse Improved Content",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Parse Quality Scores": {
      "main": [
        [
          {
            "node": "Check if Improvement Needed",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Check Approval Action": {
      "main": [
        [
          {
            "node": "Update Notion - Approved",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Update Notion - Rejected",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get Past 30 Days Posts": {
      "main": [
        [
          {
            "node": "Analyze Brand Voice",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Parse Improved Content": {
      "main": [
        [
          {
            "node": "AI Quality Scoring",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Parse Generated Content": {
      "main": [
        [
          {
            "node": "AI Quality Scoring",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Process Approval Action": {
      "main": [
        [
          {
            "node": "Check Approval Action",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Sentiment & Risk Analysis": {
      "main": [
        [
          {
            "node": "Merge Risk Analysis",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Check if Improvement Needed": {
      "main": [
        [
          {
            "node": "Auto-Improve Content",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Sentiment & Risk Analysis",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Generate Content with GPT-4": {
      "main": [
        [
          {
            "node": "Parse Generated Content",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Webhook - Approval Dashboard": {
      "main": [
        [
          {
            "node": "Process Approval Action",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Save to Notion (Auto-Approved)": {
      "main": [
        [
          {
            "node": "Post to Twitter (Auto-Approved)",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Generate Weekly Analytics Report": {
      "main": [
        [
          {
            "node": "Send Weekly Report Email",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Save to Notion (Pending Approval)": {
      "main": [
        [
          {
            "node": "Send Approval Email",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Schedule Daily Content Generation": {
      "main": [
        [
          {
            "node": "Generate Content with GPT-4",
            "type": "main",
            "index": 0
          },
          {
            "node": "Get Japanese Cultural Context",
            "type": "main",
            "index": 0
          },
          {
            "node": "Get Past 30 Days Posts",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Weekly Performance Report Trigger": {
      "main": [
        [
          {
            "node": "Get Past Week Posts",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}