صورة المنتج ← تعليقات بالعربية والإنجليزية

ضع صورة المنتج في مجلد Drive، والذكاء الاصطناعي يكتب تعليقات إنستجرام بالعربية والإنجليزية مع الهاشتاجات.

متوسط توفّر ~6 ساعة شهريًا المحتوى والتواصل الاجتماعيبواسطة فريق Flowngn

تعمل مع n8n · Make · Zapier

كيف تعمل

المشغّل: Google Drive — ملف جديد في مجلد المنتجات
  1. التقط الصورة الجديدة في مجلد Drive.
  2. نزّلها واجعل الذكاء الاصطناعي ينظر إلى المنتج.
  3. يكتب الذكاء الاصطناعي تعليقًا بالعربية وآخر بالإنجليزية وهاشتاجات بأسلوب علامتك.
  4. تُحفظ في جدول المحتوى مع رابط الصورة، جاهزة للمراجعة والنشر.

المخطط

GNew product photoGoogle Drive TriggerGDownload photoGoogle DriveWrite captionsBasic LLM ChainClaude modelAnthropic Chat Mo…{ }Read captionsCodeGSave to Content she…Google Sheets
مشغّل تطبيق كود ذكاء اصطناعي

الكود

كود JavaScript المستخدم في خطوات Code، وهو مضمَّن بالفعل في القالب بالأسفل.

Read captions · عقدة Code
// Mode: Run Once for Each Item
// The AI was asked for JSON like:
// {"product": "Black abaya", "ar": "...", "en": "...", "hashtags": "#abaya #..."}
const match = $json.text.match(/\{[\s\S]*\}/);
const c = match ? JSON.parse(match[0]) : {};
const file = $("New product photo").item.json;

return {
  json: {
    date: new Date().toISOString().slice(0, 10),
    file: file.name,
    photo: file.webViewLink,
    product: c.product || "",
    caption_ar: c.ar || "",
    caption_en: c.en || "",
    hashtags: c.hashtags || "",
    status: "Needs review",
  },
};

ابنِها بأداتك

اختر أداتك — نفس الأتمتة، خطوة بخطوة.

انسخه والصقه مباشرة في مساحة عمل n8n (Ctrl+V)، أو حمّله واستخدم Import from File. بعد ذلك اربط حساباتك واستبدل كل قيمة تبدأ بـ YOUR_. خطوات الذكاء الاصطناعي تستخدم نموذج Claude، ويمكنك استبداله بـ OpenAI أو Gemini أو Ollama.

ملف Workflow JSON
عرض الكود (206 سطر)
{
  "name": "صورة المنتج ← تعليقات بالعربية والإنجليزية (Flowngn)",
  "nodes": [
    {
      "parameters": {
        "content": "## صورة المنتج ← تعليقات بالعربية والإنجليزية\nضع صورة المنتج في مجلد Drive، والذكاء الاصطناعي يكتب تعليقات إنستجرام بالعربية والإنجليزية مع الهاشتاجات.\n\n**Setup**\n1. Open each node and connect your own credentials.\n2. Replace every YOUR_… placeholder.\n3. Test once, then activate.\n\nFree template from Flowngn",
        "height": 260,
        "width": 340
      },
      "id": "43ef6e94-927f-4bc8-a7a3-d4912df10d1f",
      "name": "Setup notes",
      "type": "n8n-nodes-base.stickyNote",
      "typeVersion": 1,
      "position": [
        -420,
        -60
      ]
    },
    {
      "parameters": {
        "pollTimes": {
          "item": [
            {
              "mode": "everyMinute"
            }
          ]
        },
        "triggerOn": "specificFolder",
        "folderToWatch": {
          "__rl": true,
          "value": "YOUR_PRODUCTS_FOLDER_ID",
          "mode": "id"
        },
        "event": "fileCreated",
        "options": {}
      },
      "id": "43ef6e94-927f-4bc8-a7a3-d4912df10d1f",
      "name": "New product photo",
      "type": "n8n-nodes-base.googleDriveTrigger",
      "typeVersion": 1,
      "position": [
        0,
        0
      ]
    },
    {
      "parameters": {
        "operation": "download",
        "fileId": {
          "__rl": true,
          "value": "={{ $json.id }}",
          "mode": "id"
        },
        "options": {}
      },
      "id": "43ef6e94-927f-4bc8-a7a3-d4912df10d1f",
      "name": "Download photo",
      "type": "n8n-nodes-base.googleDrive",
      "typeVersion": 3,
      "position": [
        300,
        0
      ]
    },
    {
      "parameters": {
        "promptType": "define",
        "text": "=You write Instagram captions for YOUR_BRAND. Brand voice: YOUR_BRAND_VOICE. Audience: YOUR_AUDIENCE.\nLook at this product photo. File name (may include product name and price): {{ $('New product photo').item.json.name }}\n\nReply ONLY with JSON: {\"product\": \"<short product name>\", \"ar\": \"<Arabic caption, 2-3 short lines, natural Gulf/Egyptian-friendly Arabic>\", \"en\": \"<English caption, 2-3 short lines>\", \"hashtags\": \"<8-10 relevant hashtags, Arabic and English>\"}. Never invent prices, materials or offers that aren't in the file name.",
        "passthroughBinaryImages": true
      },
      "id": "43ef6e94-927f-4bc8-a7a3-d4912df10d1f",
      "name": "Write captions",
      "type": "@n8n/n8n-nodes-langchain.chainLlm",
      "typeVersion": 1.5,
      "position": [
        600,
        0
      ]
    },
    {
      "parameters": {
        "model": {
          "__rl": true,
          "value": "claude-sonnet-5",
          "mode": "list"
        },
        "options": {}
      },
      "id": "43ef6e94-927f-4bc8-a7a3-d4912df10d1f",
      "name": "Claude model",
      "type": "@n8n/n8n-nodes-langchain.lmChatAnthropic",
      "typeVersion": 1.3,
      "position": [
        600,
        220
      ]
    },
    {
      "parameters": {
        "jsCode": "// Mode: Run Once for Each Item\n// The AI was asked for JSON like:\n// {\"product\": \"Black abaya\", \"ar\": \"...\", \"en\": \"...\", \"hashtags\": \"#abaya #...\"}\nconst match = $json.text.match(/\\{[\\s\\S]*\\}/);\nconst c = match ? JSON.parse(match[0]) : {};\nconst file = $(\"New product photo\").item.json;\n\nreturn {\n  json: {\n    date: new Date().toISOString().slice(0, 10),\n    file: file.name,\n    photo: file.webViewLink,\n    product: c.product || \"\",\n    caption_ar: c.ar || \"\",\n    caption_en: c.en || \"\",\n    hashtags: c.hashtags || \"\",\n    status: \"Needs review\",\n  },\n};",
        "mode": "runOnceForEachItem"
      },
      "id": "43ef6e94-927f-4bc8-a7a3-d4912df10d1f",
      "name": "Read captions",
      "type": "n8n-nodes-base.code",
      "typeVersion": 2,
      "position": [
        900,
        0
      ]
    },
    {
      "parameters": {
        "operation": "append",
        "documentId": {
          "__rl": true,
          "value": "YOUR_SPREADSHEET_ID",
          "mode": "id"
        },
        "sheetName": {
          "__rl": true,
          "value": "Content",
          "mode": "name"
        },
        "columns": {
          "mappingMode": "autoMapInputData",
          "value": {}
        },
        "options": {}
      },
      "id": "43ef6e94-927f-4bc8-a7a3-d4912df10d1f",
      "name": "Save to Content sheet",
      "type": "n8n-nodes-base.googleSheets",
      "typeVersion": 4.5,
      "position": [
        1200,
        0
      ]
    }
  ],
  "connections": {
    "New product photo": {
      "main": [
        [
          {
            "node": "Download photo",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Download photo": {
      "main": [
        [
          {
            "node": "Write captions",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Write captions": {
      "main": [
        [
          {
            "node": "Read captions",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Read captions": {
      "main": [
        [
          {
            "node": "Save to Content sheet",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Claude model": {
      "ai_languageModel": [
        [
          {
            "node": "Write captions",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    }
  },
  "pinData": {},
  "settings": {
    "executionOrder": "v1"
  },
  "meta": {
    "templateCredsSetupCompleted": false
  },
  "tags": []
}

← افتحها في ساحة التجربة لتعديلها

نصائح

  • سمِّ الملفات باسم المنتج وسعره ("black-abaya-450.jpg")، فالذكاء الاصطناعي يقرأ اسم الملف أيضًا.
  • استخدم نموذج ذكاء اصطناعي يقرأ الصور.

أتمتات مشابهة