これは、この分野に存在する SEO の問題のほとんどがページ レベルで発生するためです。各クエリに勝つためには、カスタムで思慮深いコンテンツとユーザー エクスペリエンスの取り組みが必要です。Amazon のような企業では、インフラストラクチャを数千ページに拡張し、クロールバジェットなどを考慮する必要があることが多いため、、小規模な Web サイトで大規模な分析を行うことはほとんどありません。
やはりUX、コンテンツ、そして獲得が難しい自然リンクにフォーカスされた内容でした。シミュレーターがコンテンツとしてもリンク獲得の側面でも活路となる点は非常にうなずけます。「とは」に位置するコンテンツおいても、長期的なランキングを達成するためにスクロールせずに見える範囲で、簡潔な回答を提供する重要性を説いています。いわゆる「ゼロクリック対策」にも手を伸ばす必要がありそうですね。 – SEO Japan
// Store the OAuth token and logs in script properties const scriptProperties = PropertiesService.getScriptProperties(); const OPENAI_URL = “https://api.openai.com/v1/chat/completions”; const SYSTEM_MESSAGE = { role: “system”, content: “You are a helpful SEO expert.” };
function resetLogs() { scriptProperties.deleteProperty(‘customLogs’); // Clear logs for a new execution }
function getLogs() { return scriptProperties.getProperty(‘customLogs’) || ‘No logs available.’; }
function fetchOAuthToken() { let token = scriptProperties.getProperty(‘oauthToken’); if (!token) { token = ScriptApp.getOAuthToken(); scriptProperties.setProperty(‘oauthToken’, token); log(‘OAuth token fetched and stored.’); } return token; }
function onOpen() { const ui = SpreadsheetApp.getUi(); ui.createMenu(‘Search Console’) .addItem(‘Authorize GSC’, ‘promptReauthorization’) .addItem(‘Fetch GSC Properties’, ‘fetchGSCProperties’) .addItem(‘Inspect URL’, ‘inspectUrl’) // Add the Inspect URL button .addItem(‘AI Analyze’, ‘aiAnalyze’) // Add the AI Analyze button .addToUi(); }
function promptReauthorization() { const ui = SpreadsheetApp.getUi(); const response = ui.alert( ‘Re-authorize Script’, ‘Re-authorizing will revoke current permissions and require you to authorize again. Do you want to continue?’, ui.ButtonSet.YES_NO );
if (response === ui.Button.YES) { try { scriptProperties.deleteProperty(‘oauthToken’); // Clear old token const token = fetchOAuthToken(); // Fetch and store new token log(“OAuth Token: ” + token); ui.alert(‘Authorization successful. No further action is required.’); } catch (e) { ui.alert(‘Authorization failed: ‘ + e.toString()); } } else { ui.alert(‘Re-authorization canceled.’); } }
if (!urls || urls.length === 0) { sheet.getRange(‘A2’).setValue(‘No URLs found’).setFontWeight(‘bold’); sheet.getRange(‘B2’).clearContent(); log(`No URLs found for property ${selectedProperty}`); return; }
sheet.getRange(‘A2’).setValue(‘Select a URL’).setFontWeight(‘bold’); sheet.getRange(‘B2’).setDataValidation( SpreadsheetApp.newDataValidation() .requireValueInList([‘Select a URL’].concat(urls), true) .build() ); sheet.getRange(‘B2’).setValue(‘Select a URL’).setFontWeight(‘bold’); }
// Clear previous inspection results in A15:D30 sheet.getRange(‘A15:D30’).clearContent(); sheet.getRange(‘A15’).setValue(‘Inspecting…’).setFontWeight(‘bold’);
if (!url || url === ‘Select a URL’) { SpreadsheetApp.getUi().alert(‘Please select a valid URL in cell B2 before inspecting.’); sheet.getRange(‘A15’).setValue(‘No URL selected’).setFontWeight(‘bold’); return; }
const oauthToken = fetchOAuthToken();
try { const result = callUrlInspectionApi(property, url, oauthToken);
if (responseCode === 200) { const jsonResponse = JSON.parse(responseText);
if (jsonResponse && jsonResponse.inspectionResult) { return jsonResponse.inspectionResult; } else { log(`Unexpected API Response Structure: ${responseText}`); throw new Error(‘Unexpected API response format. “inspectionResult” field is missing.’); } } else { log(`Failed API Call: ${responseText}`); throw new Error(`Failed to inspect URL. Response Code: ${responseCode}. Response: ${responseText}`); } } catch (error) { log(`Error during API call: ${error}`); throw new Error(`Error inspecting URL: ${error.message}`); } }
function callChatGPT(prompt, temperature = 0.9, maxTokens = 800, model = “gpt-3.5-turbo”) { const sheet = SpreadsheetApp.getActiveSpreadsheet().getActiveSheet(); const secretKey = sheet.getRange(‘D1’).getValue().trim(); // Retrieve the OpenAI API key from D1
if (!secretKey) { throw new Error(“API Key is missing in cell D1. Please provide a valid OpenAI API key.”); }
if (responseData.choices && responseData.choices[0] && responseData.choices[0].message) { return responseData.choices[0].message.content.trim(); } else { log(“Unexpected response format from OpenAI: ” + JSON.stringify(responseData)); return “Sorry, I couldn’t process the request.”; } } catch (error) { log(“Error calling OpenAI API: ” + error); return “Sorry, there was an error processing your request.”; } }
// Validate input fields if (!url || keywords.length === 0 || inspectionData.some(row => row.length < 2 || !row[0].trim() || !row[1].trim())) { SpreadsheetApp.getUi().alert(“Ensure the following are filled before running AI Analyze:\n- URL in B2\n- Keywords in A3:A12\n- Inspection data in A16:B20”); return; }
// Prepare the prompt for ChatGPT const prompt = ` Analyze this URL: ${url} Also the view-source version from: ${url} against these keywords: ${keywords.join(“, “)} Considering the URL inspection data from Google Search Console: ${inspectionData.map(row => `${row[0]}: ${row[1]}`).join(“\n”)} Suggest a short list of specific recommendations on how I can improve the page’s SEO. Make sure the recommendations include details such as change this to that, or add something, etc… Be concrete with SEO recommendations. `;
// Display the prompt in G1 sheet.getRange(‘G1’).setValue(“Prompt Sent to ChatGPT”).setFontWeight(“bold”); sheet.getRange(‘G2:G30’).clearContent(); // Clear previous content in column G sheet.getRange(‘G2:G30’).merge(); // Merge cells G2:G30 sheet.getRange(‘G2’).setValue(prompt).setVerticalAlignment(“top”); // Add the prompt and align to top sheet.setColumnWidth(7, 400); // Set column G width to 400px
// Call ChatGPT API const analysisResult = callChatGPT(prompt);
// Display the result in the spreadsheet (Column F) sheet.getRange(‘F1’).setValue(“AI Analysis Result”).setFontWeight(“bold”); sheet.getRange(‘F2:F30’).clearContent(); // Clear previous content sheet.getRange(‘F2:F30’).merge(); // Merge the cells sheet.getRange(‘F2’).setValue(analysisResult).setVerticalAlignment(“top”); // Add the AI result and align to top sheet.setColumnWidth(6, 400); // Set column F width to 400px
AIを活用しEC事業者の支援と顧客への最適な購買体験を創出するプロジェクト「Commerce AI Lab.」ではどのような取り組みを行っているのだろうか
電通デジタルが2024年9月から本格的に始動したプロジェクト「Commerce AI Lab.(コマースエーアイラボ)」。AIを活用したEC事業者の業務効率化やサポート、顧客1人ひとりに最適な購買体験の創出と新たな価値創造を目的としている。ECでのAI活用に注目が集まるなか、電通デジタルはどのような取り組みを進めているのか。プロジェクト担当者に施策内容や今後の展望を取材した。(人物写真および部署名・役職名は、2024年9月25日に実施した「コマース支援事業におけるAI活用プロジェクトに関する説明会」時点)
「Commerce AI Lab.」はこれらの強みを掛け合わせた複数の取り組みを通じて、EC担当者の業務を効率的かつ迅速なサポート、顧客1人ひとりに沿った最適な購買体験の創出、新たな価値創造の提供を目的とするプロジェクト。電通デジタルの永山悟氏(電通デジタル コマースマーケティング部門 部門長)はこのプロジェクト発足について次のように話す。