Real-ESRGAN AI、Google Drive、Airtable を使用してバッチで人物写真の品質を向上
これはContent Creation, Multimodal AI分野の自動化ワークフローで、12個のノードを含みます。主にCode, Airtable, GoogleDrive, HttpRequest, ManualTriggerなどのノードを使用。 Real-ESRGAN AI、Google Drive、Airtable を使ってポートレート写真の品質をバッチアップグレード
- •Airtable API Key
- •Google Drive API認証情報
- •ターゲットAPIの認証情報が必要な場合あり
{
"meta": {
"instanceId": "9e721f64f4f5b8df656a4e0e1b663225a53ad0de7655a0878df9764d30956485",
"templateCredsSetupCompleted": true
},
"nodes": [
{
"id": "3a204dbb-8945-4fd1-8d09-9980a664128f",
"name": "ワークフロー実行時",
"type": "n8n-nodes-base.manualTrigger",
"position": [
-1024,
-848
],
"parameters": {},
"typeVersion": 1
},
{
"id": "1d9e1318-89b1-436f-abf1-0ea269f35644",
"name": "フォルダ作成",
"type": "n8n-nodes-base.googleDrive",
"position": [
-768,
-848
],
"parameters": {
"name": "=< Folder Name >",
"driveId": {
"__rl": true,
"mode": "list",
"value": ""
},
"options": {},
"folderId": {
"__rl": true,
"mode": "list",
"value": ""
},
"resource": "folder"
},
"credentials": {
"googleDriveOAuth2Api": {
"id": "AKldzSoqKzegF8kI",
"name": "Vertical Google Drive account"
}
},
"typeVersion": 3
},
{
"id": "f44f1434-e002-4478-bbd5-498dff5a8e40",
"name": "アイテムをループ処理",
"type": "n8n-nodes-base.splitInBatches",
"position": [
-64,
-848
],
"parameters": {
"options": {}
},
"typeVersion": 3
},
{
"id": "af7d12c5-fd15-4ed3-8bf4-11901dc21f89",
"name": "Google Drive にアップロード",
"type": "n8n-nodes-base.googleDrive",
"onError": "continueRegularOutput",
"position": [
832,
-848
],
"parameters": {
"name": "={{ 'Upscaled_Picture' + $now.format('yyyy-MM-dd_HH-mm-ss') + '.png' }}",
"driveId": {
"__rl": true,
"mode": "list",
"value": "My Drive"
},
"options": {},
"folderId": {
"__rl": true,
"mode": "id",
"value": "={{ $json.gdriveUploadFolderId }}"
}
},
"credentials": {
"googleDriveOAuth2Api": {
"id": "AKldzSoqKzegF8kI",
"name": "Vertical Google Drive account"
}
},
"typeVersion": 3
},
{
"id": "6bab8092-e2a1-4640-acf5-07e4e15d656f",
"name": "高解像度画像をダウンロード",
"type": "n8n-nodes-base.httpRequest",
"onError": "continueRegularOutput",
"position": [
384,
-928
],
"parameters": {
"url": "={{ $json.output }}",
"options": {
"response": {
"response": {
"responseFormat": "file"
}
}
}
},
"typeVersion": 4.2
},
{
"id": "444a3467-8416-4dfd-ad89-1be387ea4613",
"name": "Airtable 出力からポートレートURLを抽出",
"type": "n8n-nodes-base.code",
"position": [
-288,
-848
],
"parameters": {
"jsCode": "// N8N Code Node - Extract Portrait Photo URLs from Airtable Output\n\n// Input data from Airtable\nconst airtableData = $input.all()[0].json;\n\n// Get Google Drive folder ID from previous node\nconst folderId = $node[\"Create folder\"].json.id;\n\n// Extract URLs from PortraitFotoAuswahl array\nconst portraitUrls = [];\n\nif (airtableData.PortraitFotoAuswahl && Array.isArray(airtableData.PortraitFotoAuswahl)) {\n airtableData.PortraitFotoAuswahl.forEach((item, index) => {\n if (item.url) {\n portraitUrls.push({\n index: index,\n url: item.url,\n filename: item.filename || `portrait_${index}`,\n size: item.size || null,\n width: item.width || null,\n height: item.height || null,\n gdriveUploadFolderId: folderId\n });\n }\n });\n}\n\n// Return array of URLs with folder ID\nreturn portraitUrls.map(item => ({\n json: {\n url: item.url,\n index: item.index,\n filename: item.filename,\n size: item.size,\n width: item.width,\n height: item.height,\n gdriveUploadFolderId: item.gdriveUploadFolderId\n }\n}));"
},
"typeVersion": 2
},
{
"id": "5868126e-c299-4574-9170-ce02655a59ad",
"name": "Replicate Upscaler",
"type": "n8n-nodes-base.httpRequest",
"position": [
160,
-928
],
"parameters": {
"url": "https://api.replicate.com/v1/predictions",
"method": "POST",
"options": {},
"jsonBody": "={\n \"version\": \"nightmareai/real-esrgan:f121d640bd286e1fdc67f9799164c1d5be36ff74576ee11c803ae5b665dd46aa\",\n \"input\": {\n \"image\": \"{{ $json.url }}\",\n \"scale\": 2,\n \"face_enhance\": false\n }\n} ",
"sendBody": true,
"sendHeaders": true,
"specifyBody": "json",
"authentication": "genericCredentialType",
"genericAuthType": "httpHeaderAuth",
"headerParameters": {
"parameters": [
{
"name": "Prefer",
"value": "wait"
}
]
}
},
"credentials": {
"httpHeaderAuth": {
"id": "FovFPj60gDUn3HP0",
"name": "Replicate"
}
},
"typeVersion": 4.2
},
{
"id": "94532da7-1ca5-4d71-b906-677964f0490f",
"name": "GDriveアップロードフォルダIDを設定",
"type": "n8n-nodes-base.code",
"position": [
608,
-928
],
"parameters": {
"jsCode": "// Set Node JavaScript Code\nconst currentItem = $input.all()[0];\nconst loopData = $node[\"Loop Over Items\"].json;\n\nreturn [{\n json: {\n gdriveUploadFolderId: loopData.gdriveUploadFolderId,\n originalFilename: loopData.filename,\n originalIndex: loopData.index\n },\n binary: currentItem.binary\n}];"
},
"typeVersion": 2
},
{
"id": "711fea9d-9b12-48cb-b66f-2fa75b014142",
"name": "付箋ノート",
"type": "n8n-nodes-base.stickyNote",
"position": [
-1568,
-976
],
"parameters": {
"color": 4,
"width": 304,
"height": 368,
"content": "## Information\n\nThis Node will Upscale Multiple Pictures from A Dataspace in Airtable \n\n1. it will create A folder in Drive\n2. it will take pictures stored in the airtable Dataspace\n3. It will run over Items to upscale in Replicate the pictures\n4. It will store the pictures in Drive\n\nPlease Upload the Pictures in Airtable in a column: PortraitFotoAuswahl "
},
"typeVersion": 1
},
{
"id": "97297413-8022-4966-8117-944edf4736fc",
"name": "Picturesからレコードを取得",
"type": "n8n-nodes-base.airtable",
"position": [
-496,
-848
],
"parameters": {
"id": "=< enter Record ID >",
"base": {
"__rl": true,
"mode": "id",
"value": ""
},
"table": {
"__rl": true,
"mode": "id",
"value": ""
},
"options": {}
},
"credentials": {
"airtableTokenApi": {
"id": "yPMIQY5qCFGtB5FX",
"name": "Book your fantasy Airtable"
}
},
"typeVersion": 2.1
},
{
"id": "45e45d37-8afc-48a2-ab4b-557b985c9741",
"name": "付箋ノート1",
"type": "n8n-nodes-base.stickyNote",
"position": [
-576,
-960
],
"parameters": {
"height": 352,
"content": "## Enter Record from Stored Data\n"
},
"typeVersion": 1
},
{
"id": "73b660f8-f518-42d8-8970-234a956f412a",
"name": "付箋ノート2",
"type": "n8n-nodes-base.stickyNote",
"position": [
-832,
-960
],
"parameters": {
"height": 352,
"content": "## Add Folder Name"
},
"typeVersion": 1
}
],
"pinData": {},
"connections": {
"1d9e1318-89b1-436f-abf1-0ea269f35644": {
"main": [
[
{
"node": "97297413-8022-4966-8117-944edf4736fc",
"type": "main",
"index": 0
}
]
]
},
"f44f1434-e002-4478-bbd5-498dff5a8e40": {
"main": [
[],
[
{
"node": "5868126e-c299-4574-9170-ce02655a59ad",
"type": "main",
"index": 0
}
]
]
},
"6bab8092-e2a1-4640-acf5-07e4e15d656f": {
"main": [
[
{
"node": "94532da7-1ca5-4d71-b906-677964f0490f",
"type": "main",
"index": 0
}
]
]
},
"5868126e-c299-4574-9170-ce02655a59ad": {
"main": [
[
{
"node": "6bab8092-e2a1-4640-acf5-07e4e15d656f",
"type": "main",
"index": 0
}
]
]
},
"af7d12c5-fd15-4ed3-8bf4-11901dc21f89": {
"main": [
[
{
"node": "f44f1434-e002-4478-bbd5-498dff5a8e40",
"type": "main",
"index": 0
}
]
]
},
"97297413-8022-4966-8117-944edf4736fc": {
"main": [
[
{
"node": "444a3467-8416-4dfd-ad89-1be387ea4613",
"type": "main",
"index": 0
}
]
]
},
"94532da7-1ca5-4d71-b906-677964f0490f": {
"main": [
[
{
"node": "af7d12c5-fd15-4ed3-8bf4-11901dc21f89",
"type": "main",
"index": 0
}
]
]
},
"3a204dbb-8945-4fd1-8d09-9980a664128f": {
"main": [
[
{
"node": "1d9e1318-89b1-436f-abf1-0ea269f35644",
"type": "main",
"index": 0
}
]
]
},
"444a3467-8416-4dfd-ad89-1be387ea4613": {
"main": [
[
{
"node": "f44f1434-e002-4478-bbd5-498dff5a8e40",
"type": "main",
"index": 0
}
]
]
}
}
}このワークフローの使い方は?
上記のJSON設定コードをコピーし、n8nインスタンスで新しいワークフローを作成して「JSONからインポート」を選択、設定を貼り付けて認証情報を必要に応じて変更してください。
このワークフローはどんな場面に適していますか?
中級 - コンテンツ作成, マルチモーダルAI
有料ですか?
このワークフローは完全無料です。ただし、ワークフローで使用するサードパーティサービス(OpenAI APIなど)は別途料金が発生する場合があります。
関連ワークフロー
Robert Schröder
@saitsI'm a self-taught n8n automation specialist from Zürich with 2 years of intensive experience building complex workflows. My focus lies in creating practical, production-ready workflows that solve real business challenges - from AI-powered content generation to data management and process automation. Each workflow I share reflects tested, optimized solutions that deliver measurable results.
このワークフローを共有