{"id":48895,"date":"2026-01-09T20:19:55","date_gmt":"2026-01-09T12:19:55","guid":{"rendered":"https:\/\/www.geobok.com\/geo-toolkit\/ai-semantic-alignment-analyzer\/"},"modified":"2026-04-03T10:56:56","modified_gmt":"2026-04-03T02:56:56","slug":"ai-semantic-alignment-analyzer","status":"publish","type":"page","link":"https:\/\/www.geobok.com\/en\/geo-toolkit\/ai-semantic-alignment-analyzer\/","title":{"rendered":"AI Semantic Alignment Analyzer"},"content":{"rendered":"\n<style>\n\/* ===== \u672c\u5de5\u5177\u7279\u6709\u6837\u5f0f\uff08\u53cc\u8272\u533a\u57df\u3001\u8bc4\u5206\u6807\u7b7e\u7b49\uff09===== *\/\n.rog-section { padding: 22px; border-radius: 12px; border: 1px solid var(--geo-border); margin-bottom: 20px; }\n.rog-section.bg-intent { background: #fdfbff; border-color: #e9e5ff; }\n.rog-section.bg-corpus { background: #fffdf9; border-color: #f7ede2; }\n\n.rog-section-header { display: flex; align-items: center; gap: 10px; margin-bottom: 18px; flex-wrap: wrap; }\n.rog-title-text { font-size: 16px; font-weight: 800; color: var(--geo-text-primary); }\n.rog-subtitle-text { font-size: 13px; color: var(--geo-text-faint); }\n.rog-divider { width: 1px; height: 14px; background: var(--geo-border-strong); margin: 0 4px; }\n.rog-title-icon { width: 30px; height: 30px; display: flex; align-items: center; justify-content: center; border-radius: 6px; font-size: 16px; color: #fff; }\n.rog-title-icon.icon-pink { background: #db2777; }\n.rog-title-icon.icon-yellow { background: #d97706; }\n\n\/* \u5e26\u8272\u8fb9\u8f93\u5165\u6846 *\/\n.rog-input-box { display: flex; align-items: center; gap: 10px; padding: 4px; background: #fff; border: 1px solid var(--geo-border-strong); border-radius: 8px; transition: 0.25s; }\n.rog-input-box.intent { border-left: 5px solid #db2777; }\n.rog-input-box.intent:focus-within { border-color: #db2777; box-shadow: 0 0 0 4px rgba(219,39,119,0.08); }\n.rog-input-box.corpus { border-left: 5px solid #d97706; }\n.rog-input-box.corpus:focus-within { border-color: #d97706; box-shadow: 0 0 0 4px rgba(217,119,6,0.08); }\n.rog-input-box input, .rog-input-box select { border: none; outline: none; background: transparent; font-family: var(--geo-font-sans); }\n.rog-input-box input { flex: 1; padding: 12px 16px; font-size: 15px; color: var(--geo-text-primary); }\n.rog-input-box select { background: var(--geo-bg-page); border: 1px solid var(--geo-border); border-radius: 6px; padding: 0 10px; height: 38px; font-weight: 700; font-size: 13px; color: var(--geo-text-body); cursor: pointer; min-width: 140px; }\n.rog-fetch-btn { border: none; background: #475569; color: #fff; border-radius: 6px; padding: 0 18px; height: 38px; font-weight: 700; cursor: pointer; transition: 0.2s; font-size: 13px; }\n.rog-fetch-btn:hover { background: #1e293b; }\n\n\/* \u8bed\u6599\u6587\u672c\u6846 *\/\n.rog-textarea { width: 100%; padding: 16px 18px; font-size: 15px; line-height: 1.6; color: var(--geo-text-body); background: #fff; border: 1px solid var(--geo-border-strong); border-radius: 8px; border-left: 5px solid #fcd34d; box-sizing: border-box; resize: vertical; min-height: 100px; font-family: var(--geo-font-sans); transition: 0.25s; }\n.rog-textarea:focus { outline: none; border-color: #d97706; border-left-color: #d97706; box-shadow: 0 0 0 4px rgba(217,119,6,0.08); }\n\n\/* \u7247\u6bb5\u884c *\/\n.rog-segment-row { position: relative; margin-bottom: 15px; }\n.rog-btn-remove { position: absolute; top: -10px; right: -10px; width: 24px; height: 24px; background: #ef4444; border: 2px solid #fff; border-radius: 50%; display: flex; align-items: center; justify-content: center; cursor: pointer; box-shadow: 0 3px 8px rgba(239,68,68,0.4); z-index: 50; padding: 0; transition: transform 0.2s; }\n.rog-btn-remove:hover { transform: scale(1.15); background: #dc2626; }\n.rog-btn-remove::after { content: \"\"; width: 12px; height: 3px; background: #fff; border-radius: 2px; }\n\n\/* \u6dfb\u52a0\u6309\u94ae *\/\n.rog-btn-add { width: 100%; margin-top: 10px; padding: 12px; border: 1px dashed var(--geo-border-strong); border-radius: 8px; background: transparent; color: var(--geo-text-muted); font-weight: 700; cursor: pointer; display: flex; align-items: center; justify-content: center; gap: 8px; transition: 0.2s; font-size: 14px; font-family: var(--geo-font-sans); }\n.rog-btn-add:hover { border-color: #d97706; color: #d97706; background: #fffbeb; }\n\n\/* \u7ed3\u679c\u533a *\/\n.rog-stat-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-bottom: 25px; }\n.rog-stat-card { background: #fff; border: 1px solid var(--geo-border); border-radius: 12px; padding: 25px; text-align: center; box-shadow: var(--geo-shadow-sm); }\n.rog-stat-num { font-size: 2.4rem; font-weight: 800; color: var(--geo-text-primary); }\n.rog-stat-label { font-size: 13px; color: var(--geo-text-faint); font-weight: 700; text-transform: uppercase; }\n\n.rog-detail-item { padding: 20px; border: 1px solid var(--geo-border); border-radius: 10px; margin-bottom: 12px; background: #fff; display: flex; gap: 15px; align-items: flex-start; }\n.rog-score-tag { padding: 4px 10px; border-radius: 6px; font-weight: 800; font-size: 13px; min-width: 60px; text-align: center; }\n.tag-high { background: var(--geo-success-bg); color: #15803d; }\n.tag-low { background: var(--geo-danger-bg); color: #b91c1c; }\n.tag-mid { background: var(--geo-warn-bg); color: #a16207; }\n\n@media (max-width: 768px) {\n    .rog-input-box { flex-direction: column; align-items: stretch; padding: 10px; }\n    .rog-input-box select, .rog-fetch-btn { width: 100%; height: 42px; }\n    .rog-stat-grid { grid-template-columns: 1fr; }\n}\n<\/style>\n\n<div class=\"geo-card\">\n    <div class=\"geo-hero\">\n        <h2 class=\"geo-hero__title\">\u2696\ufe0f AI Semantic Alignment<\/h2>\n        <p class=\"geo-hero__desc\">Why doesn't the AI cite your content when answering specific queries?<\/p>\n    \n<div class=\"geo-about\">\n    <details class=\"geo-about__section\">\n        <summary>\ud83d\udcd6 What does this tool measure?<\/summary>\n        <div class=\"geo-about__body\">\n            <p>When someone asks AI a question, the system converts that query into a vector and hunts for the closest semantic match among indexed content chunks. This tool uses the same embedding approach (BGE model, cosine similarity) that RAG pipelines rely on.<\/p>\n            <p class=\"geo-about__ref\">See <em>Make AI Speak for You: The Definitive Guide to GEO<\/em>, Ch. 2.3 &amp; Ch. 3.5<\/p>\n        <\/div>\n    <\/details>\n    <details class=\"geo-about__section\">\n        <summary>\u2753 FAQ: GEO Impact<\/summary>\n        <div class=\"geo-about__body\">\n            <div class=\"geo-faq-item\"><h4>How is this different from keyword matching?<\/h4><p>Keyword matching requires exact words. Semantic matching cares about meaning \u2014 different phrases can be close in meaning.<\/p><\/div>\n            <div class=\"geo-faq-item\"><h4>What score should I aim for?<\/h4><p>0.8+ is a strong match. 0.6-0.8 is workable. Below 0.6 suggests your content drifts from what users are asking.<\/p><\/div>\n            <div class=\"geo-faq-item\"><h4>How do I close the gap?<\/h4><p>Build a richer semantic field: use synonyms naturally, cover different angles, phrase FAQs the way real users ask.<\/p><\/div>\n        <\/div>\n    <\/details>\n<\/div>\n<script type=\"application\/ld+json\">\n{\n  \"@context\": \"https:\/\/schema.org\",\n  \"@type\": \"FAQPage\",\n  \"mainEntity\": [\n    {\n      \"@type\": \"Question\",\n      \"name\": \"How is this different from keyword matching?\",\n      \"acceptedAnswer\": {\n        \"@type\": \"Answer\",\n        \"text\": \"Keyword matching requires exact words. Semantic matching cares about meaning \u2014 different phrases can be close in meaning.\"\n      }\n    },\n    {\n      \"@type\": \"Question\",\n      \"name\": \"What score should I aim for?\",\n      \"acceptedAnswer\": {\n        \"@type\": \"Answer\",\n        \"text\": \"0.8+ is a strong match. 0.6-0.8 is workable. Below 0.6 suggests your content drifts from what users are asking.\"\n      }\n    },\n    {\n      \"@type\": \"Question\",\n      \"name\": \"How do I close the gap?\",\n      \"acceptedAnswer\": {\n        \"@type\": \"Answer\",\n        \"text\": \"Build a richer semantic field: use synonyms naturally, cover different angles, phrase FAQs the way real users ask.\"\n      }\n    }\n  ]\n}\n<\/script>\n\n<\/div>\n\n    <div class=\"geo-action\">\n        <!-- \u68c0\u7d22\u610f\u56fe -->\n        <div class=\"rog-section bg-intent\">\n            <div class=\"rog-section-header\">\n                <div class=\"rog-title-icon icon-pink\">\ud83c\udfaf<\/div>\n                <div class=\"rog-title-text\">\u6a21\u62df\u68c0\u7d22\u6307\u4ee4 (User Prompt)<\/div>\n                <div class=\"rog-divider\"><\/div>\n                <div class=\"rog-subtitle-text\">\u8bbe\u5b9a\u7528\u6237\u5411 AI \u63d0\u95ee\u7684\u5177\u4f53\u60c5\u5883<\/div>\n            <\/div>\n            <div class=\"rog-input-box intent\">\n                <input type=\"text\" id=\"rog-query\" placeholder=\"Enter target query (e.g. What is GEO optimization?)\" >\n            <\/div>\n        <\/div>\n\n        <!-- \u5f85\u6d4b\u5185\u5bb9 -->\n        <div class=\"rog-section bg-corpus\">\n            <div class=\"rog-section-header\">\n                <div class=\"rog-title-icon icon-yellow\">\ud83d\udce6<\/div>\n                <div class=\"rog-title-text\">\u5f85\u6d4b\u5185\u5bb9\u7247\u6bb5 (Candidate Segments)<\/div>\n                <div class=\"rog-divider\"><\/div>\n                <div class=\"rog-subtitle-text\">\u63d0\u4f9b\u60a8\u5e0c\u671b\u88ab\u5f15\u7528\u7684\u5177\u4f53\u6bb5\u843d<\/div>\n            <\/div>\n            <div class=\"rog-input-box corpus\" style=\"margin-bottom:15px;\">\n                <input type=\"url\" id=\"rog-url\" placeholder=\"Enter URL to auto-extract content\" >\n                <select id=\"rog-mode\">\n                    <option value=\"natural\">\u81ea\u7136\u6bb5\u843d\u63d0\u53d6<\/option>\n                    <option value=\"smart\">\u667a\u80fd\u8bed\u4e49\u5207\u7247<\/option>\n                <\/select>\n                <button type=\"button\" class=\"rog-fetch-btn\" id=\"rog-fetch-btn\">\u63d0\u53d6<\/button>\n            <\/div>\n            <div id=\"rog-segments-list\"><\/div>\n            <button type=\"button\" class=\"rog-btn-add\" id=\"rog-add-btn\">\uff0b \u8ffd\u52a0\u8bed\u6599\u7247\u6bb5<\/button>\n        <\/div>\n\n        <button id=\"rog-submit\" class=\"geo-btn geo-btn--block\" style=\"padding:20px;font-size:16px;\">Analyze semantic alignment<\/button>\n    <\/div>\n\n    <!-- \u7ed3\u679c -->\n    <div id=\"rog-result\" class=\"geo-result\" style=\"padding:35px 40px;border-top:1px dashed var(--geo-border);background:#fcfdfe;\">\n        <div class=\"rog-section-header\">\n            <div class=\"rog-title-icon\" style=\"background:#2563eb;\">\ud83d\udcca<\/div>\n            <div class=\"rog-title-text\">\u8bca\u65ad\u7ed3\u8bba (Diagnostic Report)<\/div>\n        <\/div>\n        <div class=\"rog-stat-grid\">\n            <div class=\"rog-stat-card\"><div class=\"rog-stat-num\" id=\"rog-avg\">--<\/div><div class=\"rog-stat-label\">\u5e73\u5747\u53ec\u56de\u6982\u7387<\/div><\/div>\n            <div class=\"rog-stat-card\"><div class=\"rog-stat-num\" id=\"rog-bad\" style=\"color:#ef4444;\">--<\/div><div class=\"rog-stat-label\">\u4f4e\u5339\u914d\u566a\u58f0\u8bed\u6599<\/div><\/div>\n        <\/div>\n        <div id=\"rog-details\"><\/div>\n    <\/div>\n<\/div>\n\n<script>\ndocument.addEventListener('DOMContentLoaded', function(){\n    \/\/ \u521d\u59cb\u5316\uff1a\u6dfb\u52a0\u4e00\u884c\u7a7a\u7247\u6bb5\n    addSegmentRow();\n\n    function addSegmentRow(value){\n        var list = document.getElementById('rog-segments-list');\n        var div = document.createElement('div');\n        div.className = 'rog-segment-row';\n        var ta = document.createElement('textarea');\n        ta.className = 'rog-textarea rog-seg-input';\n        ta.placeholder = '\u8bf7\u5728\u6b64\u8f93\u5165\u6216\u7c98\u8d34\u9700\u8981\u5206\u6790\u7684\u8bed\u6599...';\n        if(value) ta.value = value;\n        var btn = document.createElement('button');\n        btn.type = 'button'; btn.className = 'rog-btn-remove'; btn.title = '\u79fb\u9664';\n        btn.onclick = function(){ if(list.children.length > 1) div.remove(); else ta.value=''; };\n        div.appendChild(ta); div.appendChild(btn); list.appendChild(div);\n    }\n    window._rogAddSegment = addSegmentRow;\n\n    \/\/ \u8ffd\u52a0\u6309\u94ae\n    document.getElementById('rog-add-btn').onclick = function(){ addSegmentRow(); };\n\n    \/\/ URL \u63d0\u53d6\n    document.getElementById('rog-fetch-btn').onclick = async function(){\n        var url = document.getElementById('rog-url').value.trim();\n        var mode = document.getElementById('rog-mode').value;\n        var fetchBtn = this;\n        var list = document.getElementById('rog-segments-list');\n        if(!url || !url.startsWith('http')){ alert('\u8bf7\u8f93\u5165\u6709\u6548\u7684 URL'); return; }\n\n        GeoAPI.disableBtn(fetchBtn,'...');\n        list.innerHTML = '<div class=\"geo-loading\"><div class=\"geo-spinner\"><\/div><span>' + GeoAPI.t('sem.loading') + '<\/span><\/div>';\n        try {\n            var res = await GeoAPI.post('\/fetch-text',{url:url, mode:mode});\n            list.innerHTML = '';\n            if(res.status==='success' && res.segments && res.segments.length>0){\n                res.segments.forEach(function(t){ addSegmentRow(t); });\n            } else { addSegmentRow(); alert('\u672a\u63d0\u53d6\u5230\u5185\u5bb9'); }\n        } catch(e){ list.innerHTML=''; addSegmentRow(); if(!e._geoAuthHandled) alert('\u6293\u53d6\u5931\u8d25: '+e.message); }\n        finally { GeoAPI.enableBtn(fetchBtn,'\u63d0\u53d6'); }\n    };\n\n    \/\/ \u8bed\u4e49\u5206\u6790\n    document.getElementById('rog-submit').onclick = async function(){\n        var query = document.getElementById('rog-query').value.trim();\n        var btn = this;\n        var resultEl = document.getElementById('rog-result');\n        var details = document.getElementById('rog-details');\n        var segs = Array.from(document.querySelectorAll('.rog-seg-input')).map(function(i){return i.value.trim();}).filter(function(t){return t.length>1;});\n\n        if(!query){ alert('\u8bf7\u8f93\u5165\u68c0\u7d22\u610f\u56fe'); return; }\n        if(segs.length===0){ alert('\u8bf7\u63d0\u4f9b\u8bed\u6599\u5185\u5bb9'); return; }\n\n        GeoAPI.disableBtn(btn, GeoAPI.t('sem.btn.loading'));\n        try {\n            var res = await GeoAPI.post('\/geo\/semantic-check',{query:query, segments:segs});\n            document.getElementById('rog-avg').innerText = (res.avg_score*100).toFixed(0)+'%';\n            document.getElementById('rog-bad').innerText = res.off_topic_count;\n            details.innerHTML = '';\n            res.details.forEach(function(item,index){\n                var tc = item.score >= 0.75 ? 'tag-high' : (item.score <= 0.50 ? 'tag-low' : 'tag-mid');\n                var div = document.createElement('div'); div.className = 'rog-detail-item';\n                div.innerHTML = '<div style=\"text-align:center;min-width:75px;\">'+\n                    '<div class=\"rog-score-tag '+tc+'\">'+(item.score*100).toFixed(0)+'%<\/div>'+\n                    '<div style=\"font-size:12px;color:var(--geo-text-faint);margin-top:6px;font-weight:700;\">#'+(index+1)+'<\/div><\/div>'+\n                    '<div style=\"flex:1;font-size:15px;color:var(--geo-text-body);line-height:1.7;\">'+GeoAPI.escapeHtml(item.content)+'<\/div>';\n                details.appendChild(div);\n            });\n            resultEl.style.display = 'block';\n            resultEl.classList.add('geo-result--visible');\n            resultEl.scrollIntoView({behavior:'smooth',block:'start'});\n        } catch(e){ if(!e._geoAuthHandled) alert('\u670d\u52a1\u6682\u65f6\u4e0d\u53ef\u7528: '+e.message); }\n        finally { GeoAPI.enableBtn(btn,'AI \u8bed\u4e49\u5bf9\u9f50\u5206\u6790'); }\n    };\n});\n<\/script>\n\n    \n","protected":false},"excerpt":{"rendered":"","protected":false},"author":1,"featured_media":0,"parent":48884,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"footnotes":""},"class_list":["post-48895","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/www.geobok.com\/en\/wp-json\/wp\/v2\/pages\/48895","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.geobok.com\/en\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/www.geobok.com\/en\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/www.geobok.com\/en\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.geobok.com\/en\/wp-json\/wp\/v2\/comments?post=48895"}],"version-history":[{"count":0,"href":"https:\/\/www.geobok.com\/en\/wp-json\/wp\/v2\/pages\/48895\/revisions"}],"up":[{"embeddable":true,"href":"https:\/\/www.geobok.com\/en\/wp-json\/wp\/v2\/pages\/48884"}],"wp:attachment":[{"href":"https:\/\/www.geobok.com\/en\/wp-json\/wp\/v2\/media?parent=48895"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}