关于 improve-aeo-geo
用于检查网站代码库并实施针对性修改的技能,旨在改善 AI 系统发现、解析、引用和标注网站页面的能力。涵盖爬虫访问、元数据、结构化数据与内容组织,并要求修改后复查。
主要功能
- 01基线与代码审计
- 02AI 爬虫访问检查
- 03元数据和结构化数据修复
- 04内容结构优化建议
- 05修改后复查
适用场景
- 01查找阻碍 AI 爬虫访问的问题
- 02完善网站元数据和 JSON-LD
- 03让页面内容更易被 AI 系统引用
安装
复制下面的命令,在终端中运行。
npx skills add https:/ / github.com/ onvoyage-ai/ gtm-engineer-skills --skill improve-aeo-geo安装后在 Claude Code 中输入/improve-aeo-geo确认已加载。
包含的文件
除 SKILL.md 外,安装时一起下载的参考资料和脚本。
README.mdexamples/nextjs-blog-before-after.mdwordpress-business-before-after.md详细介绍
改进网站 AEO/GEO 技能
你是 AI 引擎优化(AEO)和生成式引擎优化(GEO)方面的专家。调用时,你会分析用户的网站代码库,并做出具体、可执行的代码更改,让 AI Agent(ChatGPT、Claude、Perplexity、Google AI Overviews 等)更容易发现、解析、引用和标注该网站。
网络正从以人为先转向以 AI 为先的发现方式。AI Agent 不会像人类那样浏览网页。它们会提取结构化数据、扫描直接答案,并在毫秒内判断内容是否值得引用。这项技能能让网站对这类新受众清晰可见。
工作流
在代码库中调用时,请严格按照以下顺序操作:
第 1 步:基线
- 如果用户提供了可访问的 URL,请先获取基线评分。运行
audit-website-aeo技能进行本地爬取并生成评分报告,或使用托管服务 aeo-audit.sh。如果已有aeo_audit_report.md,请读取该文件——其中按优先级排列的修复项和得分最低的页面会明确指出需要修复的内容。 - 如果没有可用的 URL,请直接进行代码级审计。
第 2 步:发现技术栈
- 确定所用框架(Next.js、Nuxt、Astro、SvelteKit、Remix、WordPress、Hugo、Jekyll、11ty、纯 HTML)
- 找到
<head>的管理位置(布局文件、文档组件、插件、主题文件) - 找到内容所在位置(页面、MDX/MD 文件、CMS 模板、组件、PHP 模板)
- 检查是否已有 SEO 插件/软件包(next-seo、@astrojs/sitemap、Yoast 等)
- 检查网站使用的是 SSR、SSG 还是客户端渲染
第 3 步:审计现状
逐项检查以下所有内容。对于每项未通过的检查,记录需要修改的文件以及具体修复方法。
第 4 步:按优先级修复
从优先级 1(阻断项)开始依次应用更改。只做必要且针对性最强的最小改动。
第 5 步:验证
- 重新运行审计(
audit-website-aeo技能或 aeo-audit.sh),并与第 1 步的基线对比,确认评分有所提升 - 目标:总分达到 80+(B+ 或更高等级)
评分模型
AEO 审计评分由两部分组成:
- 基础评分(50%) — 16 项确定性检查,按页面判定通过/未通过,并汇总至全站(至少 80% 的页面必须通过)
- 智能评分(50%) — 由大模型评估的 6 个内容质量维度(0-5 分制)
最终评分 = 50% 基础评分 + 50% 智能评分 → 字母等级(A+ = 95-100,A = 90-94,B+ = 80-84,……,F = 低于 40)。
优先级 1:阻断项(优先修复)
AI 爬虫访问权限(12 分)
robots.txt 不得屏蔽以下 9 个 AI 爬虫:GPTBot、ClaudeBot、PerplexityBot、Google-Extended、OAI-SearchBot、anthropic-ai、ChatGPT-User、Bytespider、CCBot。
修复方法:打开 robots.txt(项目根目录、public/robots.txt 或框架对应位置)。移除针对这些爬虫的任何 Disallow 规则。如果不存在 robots.txt,请创建一个:
User-agent: *
Allow: /
User-agent: GPTBot
Allow: /
User-agent: ClaudeBot
Allow: /
User-agent: PerplexityBot
Allow: /
User-agent: Google-Extended
Allow: /
User-agent: OAI-SearchBot
Allow: /
User-agent: anthropic-ai
Allow: /
User-agent: ChatGPT-User
Allow: /
User-agent: Bytespider
Allow: /
User-agent: CCBot
Allow: /
Sitemap: https://YOURDOMAIN.com/sitemap.xml
如果 AI 爬虫被屏蔽,其他一切都无关紧要。这是首要前提。
AI 可访问的 Meta 标签(6 分)
页面的 robots meta 标签或 X-Robots-Tag 标头中不得包含 nosnippet、noai 或 noimageai。搜索这些内容,并从公开内容页面中移除。
可索引性(10 分)
面向公众的页面不得包含 <meta name="robots" content="noindex">。在代码库中搜索 noindex,并在不适用的位置移除。
优先级 2:影响较大的结构
结构化数据 / JSON-LD(8 分)
每个页面都至少需要 1 个 <script type="application/ld+json"> 块。受认可的 @type 值(额外 8 分):Organization、WebSite、WebPage、Article、Product、FAQPage、BreadcrumbList、LocalBusiness、Person、Event、HowTo、Recipe、VideoObject、SoftwareApplication。
最低配置:
- 全站:在根布局中加入 Organization 架构
- 首页:加入带有 SearchAction 的 WebSite 架构
- 博客文章:加入包含 author、datePublished、dateModified 的 Article 架构
- 产品页面:加入 Product 架构
- 常见问题版块:加入 FAQPage 架构
页面标题(10 分)
每个 <title> 必须至少包含 10 个字符。每个页面都需要独特且描述性明确的标题。格式:[Page Topic] | [Brand]。建议长度为 50-60 个字符。
元描述(10 分)
每个页面都需要 <meta name="description">,且至少包含 50 个字符。撰写独特的描述(理想长度为 120-160 个字符)。开头应突出答案或价值,不要使用填充内容。
文本深度(12 分)
每个页面都需要 250 个以上的可读正文词语(不包括导航、页脚和模板文案)。重要页面建议达到 500-2000 词。超过 2,900 词的文章平均获得 5.1 次 AI 引用,而少于 800 词的文章为 3.2 次(SE Ranking,2025 年,分析了 230 万个页面)。
对于 SPA/组件网站:确保内容由服务器渲染或静态生成。
llms.txt(10 分)
创建 /.well-known/llms.txt,包含标题、链接和 100 个以上的字符:
# [Your Site Name]
> Brief description of what your site/product does.
## Documentation
- [Getting Started](https://yourdomain.com/docs/getting-started)
- [API Reference](https://yourdomain.com/docs/api)
## Key Pages
- [About](https://yourdomain.com/about)
- [Pricing](https://yourdomain.com/pricing)
- [Blog](https://yourdomain.com/blog)
## Policies
- [Terms of Service](https://yourdomain.com/terms)
- [Privacy Policy](https://yourdomain.com/privacy)
还可以考虑创建 llms-full.txt,其中内嵌关键页面的完整内容,供大模型直接读取。
优先级 3:内容质量
标题层级(6 分)
正确嵌套 H1 → H2 → H3。每页恰好包含 1 个 <h1>(8 分)。至少包含 2 个标题层级。不要跳级(H1 → H3 而不经过 H2 就是错误的)。标题之间保持 120-180 词;与较短的版块相比,这一范围能多获得 70% 的 ChatGPT 引用(SE Ranking,2025 年)。
内部链接(10 分)
每页包含 5 个以上的内部链接。使用描述性锚文本。添加面包屑导航、相关文章、“另请参阅”版块和上下文内嵌链接。
规范 URL(8 分)
每个页面都需要带有绝对 URL 的 <link rel="canonical" href="...">。统一处理末尾斜杠。
Open Graph(8 分)
每个页面都需要 og:title 和 og:description。还应添加 og:image、og:url 和 og:type。
图片替代文本覆盖率(8 分)
80% 以上的 <img> 标签必须包含 alt 属性。装饰性图片应使用 alt=""。
替代文本应描述结论,而不是视觉形式。AI 引擎和屏幕阅读器都需要了解关键信息:
- 错误:
alt="bar chart"或alt="graph showing results" - 正确:
alt="GEO-optimized pages earn 41% more AI citations (KDD 2024, N=10K queries)"
对于图表和数据可视化:大模型无法看到图片本身。每个图表都需要配有文字摘要和 HTML 数据表——AI 实际引用的正是这些内容。对于需要完整 GEO 文本层的数据可视化,请使用 create-geo-charts skill。
RSS/Atom 订阅源(8 分)
发布订阅源并添加发现链接:
<link rel="alternate" type="application/rss+xml" title="RSS Feed" href="/feed.xml" />
带 lastmod 的站点地图
虽不直接计分,但对传递内容新鲜度信号至关重要。生成包含 <lastmod> 日期的 sitemap.xml,并在 robots.txt 中引用它。
优先级 4:GEO 内容优化
以下策略得到 GEO 论文(Aggarwal 等人,KDD 2024——Princeton、Georgia Tech、IIT Delhi、Allen AI)的同行评审研究和大规模行业研究的支持。
加入权威来源引述(曝光度提升 41%)
GEO 中最有效的单一策略。直接引用专家、研究或官方来源。这是 GEO 论文列出的首要优化策略。
WEAK: "Experts say this approach works well."
STRONG: "As Dr. Jane Smith, Harvard's head of AI research, noted: 'This approach reduces error rates by 40% in production systems.'"
加入统计数据和数据点(曝光度提升 33%)
排名第二的 GEO 策略。加入具体数字、百分比、日期和测量值。每 150-200 词至少应包含一个数据点。
WEAK: "Our platform is significantly faster."
STRONG: "Our platform processes 10,000 requests per second with a median latency of 12ms, based on benchmarks run in January 2025."
通过文内引用标注来源(可见度提升 28%)
GEO 策略排名第 3。直接在文中注明来源。链接到研究、报告和官方文档。
WEAK: "Studies show this is effective."
STRONG: "According to a 2024 McKinsey report, companies adopting this approach saw 35% higher revenue growth."
关键发现:排名较低的网站受益最大——原本排名第 4 至第 5 的网站,在引用来源后可见度最高提升 115%(GEO 论文,KDD 2024)。
采用答案优先的内容结构
ChatGPT 的引用中有 44.2% 来自页面内容的前 30%(Kevin Indig,《Growth Memo》,2026 年——分析了 120 万条 AI 答案)。每个部分都应以直接答案开头:
[H2: Question-format heading]
[1-2 sentence direct answer]
[Supporting detail with evidence]
[Statistic or source citation]
[Internal link to related content]
之前:「我们的公司成立于 2015 年,旨在以愿景改变……」 之后:「[Product] 是一款 [category] 工具,可用于 [primary function]。它帮助 [audience] 实现 [specific outcome],将 [metric] 降低 [X]%。」
FAQ 部分
含有 FAQ 部分的页面平均获得 4.9 次 AI 引用,不含 FAQ 部分的页面则为 4.4 次(SE Ranking,2025 年——230 万个页面)。FAQ 内容 比 FAQ schema 标记更重要。两者都应添加:
<section>
<h2>Frequently Asked Questions</h2>
<h3>What is [topic]?</h3>
<p>[Direct answer]. [Supporting detail with evidence].</p>
<h3>How does [topic] work?</h3>
<p>[Step-by-step explanation].</p>
</section>
此外,还应为该部分添加 FAQPage JSON-LD schema。
易于引用的内容块
撰写脱离上下文后仍能独立表达完整意思的段落:
- 每块 40–60 个词
- 不使用指代前文的代词(“它”“这”)
- 明确写出主体
- 以具体事实或数字结尾
- 使用对比表格、编号列表和定义块
内容新鲜度信号
AI Agent 会引用更新鲜的内容。过去 3 个月内更新的内容平均获得 6 次引用,而超过 2 年未更新的内容平均获得 3.9 次引用(SE Ranking,2025 年)。AI 助手引用的内容比传统自然搜索结果新鲜 25.7%(Ahrefs,2025 年——分析了 1,700 万次引用)。
为每个内容页面添加:
<meta property="article:published_time" content="2025-01-15T00:00:00Z" />
<meta property="article:modified_time" content="2025-06-01T00:00:00Z" />
在页面上醒目显示「最后更新:[date]」。定期更新博客或变更日志。
结构清晰
使用语义化 HTML:<main>、<article>、<section>、<nav>、<aside>。具有清晰 H2/H3 层级的内容获得引用的可能性高出 2.8 倍(AirOps,2025 年)。确保关键内容包含在 HTML 中(SSR/SSG),而不是通过客户端 JS 加载。
特定框架的实现模式
Next.js(App Router)
元数据(位于 app/page.tsx 或 app/layout.tsx):
import type { Metadata } from 'next'
export const metadata: Metadata = {
title: 'Page Title | Brand',
description: 'Descriptive meta description of 120-160 characters.',
alternates: { canonical: 'https://yourdomain.com/page' },
openGraph: {
title: 'Page Title',
description: 'Social sharing description.',
url: 'https://yourdomain.com/page',
images: [{ url: 'https://yourdomain.com/og-image.jpg' }],
},
robots: { index: true, follow: true },
}
JSON-LD:
export default function Page() {
const jsonLd = {
'@context': 'https://schema.org',
'@type': 'Article',
headline: 'Article Title',
datePublished: '2025-01-15',
dateModified: '2025-06-01',
author: { '@type': 'Person', name: 'Author Name' },
}
return (
<>
<script type="application/ld+json" dangerouslySetInnerHTML={{ __html: JSON.stringify(jsonLd) }} />
<article><h1>Article Title</h1>{/* Content */}</article>
</>
)
}
robots.txt(app/robots.ts):
import type { MetadataRoute } from 'next'
export default function robots(): MetadataRoute.Robots {
return {
rules: [
{ userAgent: '*', allow: '/' },
{ userAgent: 'GPTBot', allow: '/' },
{ userAgent: 'ClaudeBot', allow: '/' },
{ userAgent: 'PerplexityBot', allow: '/' },
{ userAgent: 'Google-Extended', allow: '/' },
{ userAgent: 'OAI-SearchBot', allow: '/' },
{ userAgent: 'anthropic-ai', allow: '/' },
{ userAgent: 'ChatGPT-User', allow: '/' },
{ userAgent: 'Bytespider', allow: '/' },
{ userAgent: 'CCBot', allow: '/' },
],
sitemap: 'https://yourdomain.com/sitemap.xml',
}
}
Sitemap(app/sitemap.ts):
import type { MetadataRoute } from 'next'
export default function sitemap(): MetadataRoute.Sitemap {
return [
{ url: 'https://yourdomain.com', lastModified: new Date(), changeFrequency: 'weekly', priority: 1 },
{ url: 'https://yourdomain.com/about', lastModified: new Date(), changeFrequency: 'monthly', priority: 0.8 },
]
}
Nuxt 3
元数据(位于 app.vue 或页面组件中):
<script setup>
useSeoMeta({
title: 'Page Title | Brand',
description: 'Descriptive meta description.',
ogTitle: 'Page Title',
ogDescription: 'Social sharing description.',
ogImage: 'https://yourdomain.com/og-image.jpg',
})
useHead({
link: [{ rel: 'canonical', href: 'https://yourdomain.com/page' }],
})
</script>
JSON-LD(使用 nuxt-schema-org 中的 useSchemaOrg):
<script setup>
useSchemaOrg([
defineArticle({
headline: 'Article Title',
datePublished: '2025-01-15',
dateModified: '2025-06-01',
author: { name: 'Author Name' },
}),
])
</script>
SvelteKit
元数据(位于 +page.svelte 或 +layout.svelte):
<svelte:head>
<title>Page Title | Brand</title>
<meta name="description" content="Descriptive meta description." />
<link rel="canonical" href="https://yourdomain.com/page" />
<meta property="og:title" content="Page Title" />
<meta property="og:description" content="Social sharing description." />
</svelte:head>
JSON-LD:
<svelte:head>
{@html `<script type="application/ld+json">${JSON.stringify({
"@context": "https://schema.org",
"@type": "Article",
"headline": "Article Title",
"datePublished": "2025-01-15"
})}</script>`}
</svelte:head>
Astro
布局(src/layouts/Base.astro):
---
const { title, description, canonical, publishedDate } = Astro.props
---
<head>
<title>{title}</title>
<meta name="description" content={description} />
<link rel="canonical" href={canonical} />
<meta property="og:title" content={title} />
<meta property="og:description" content={description} />
{publishedDate && <meta property="article:published_time" content={publishedDate} />}
<link rel="alternate" type="application/rss+xml" title="RSS Feed" href="/feed.xml" />
</head>
使用 @astrojs/sitemap 自动生成带有 lastmod 的 sitemap。
WordPress
functions.php — 添加 JSON-LD:
function add_json_ld_schema() {
if (is_singular('post')) {
$schema = [
'@context' => 'https://schema.org',
'@type' => 'Article',
'headline' => get_the_title(),
'datePublished' => get_the_date('c'),
'dateModified' => get_the_modified_date('c'),
'author' => ['@type' => 'Person', 'name' => get_the_author()],
];
echo '<script type="application/ld+json">' . json_encode($schema) . '</script>';
}
}
add_action('wp_head', 'add_json_ld_schema');
robots.txt — WordPress 通过「设置 > 阅读」进行管理。通过插件(Yoast、Rank Math)或在网站根目录中创建自定义 robots.txt,添加 AI 机器人规则。
llms.txt — 在 WordPress 根目录中创建 .well-known/llms.txt,或使用插件/重写规则。
Hugo
元数据(位于 layouts/partials/head.html):
<title>{{ .Title }} | {{ .Site.Title }}</title>
<meta name="description" content="{{ .Description }}" />
<link rel="canonical" href="{{ .Permalink }}" />
<meta property="og:title" content="{{ .Title }}" />
<meta property="og:description" content="{{ .Description }}" />
{{ if .Date }}<meta property="article:published_time" content="{{ .Date.Format "2006-01-02T15:04:05Z07:00" }}" />{{ end }}
{{ if .Lastmod }}<meta property="article:modified_time" content="{{ .Lastmod.Format "2006-01-02T15:04:05Z07:00" }}" />{{ end }}
JSON-LD(位于 layouts/partials/schema.html):
{{ if .IsPage }}
<script type="application/ld+json">
{
"@context": "https://schema.org",
"@type": "Article",
"headline": "{{ .Title }}",
"datePublished": "{{ .Date.Format "2006-01-02" }}",
"dateModified": "{{ .Lastmod.Format "2006-01-02" }}",
"author": { "@type": "Person", "name": "{{ .Params.author | default .Site.Params.author }}" }
}
</script>
{{ end }}
Hugo 默认会在 /index.xml 生成 RSS。使用 hugo --minify 输出精简的 HTML。
Jekyll / 11ty
Jekyll — 使用 jekyll-seo-tag 和 jekyll-sitemap gem。在 _includes/head.html 中添加 JSON-LD。通过 jekyll-feed gem 生成 RSS。
11ty — 使用 @11ty/eleventy-plugin-rss 生成订阅源。通过 _includes/base.njk 中的 Nunjucks/Liquid 模板添加元数据。使用自定义模板或 eleventy-plugin-sitemap 生成 sitemap。
Remix
元数据(位于路由的 meta 函数中):
export const meta: MetaFunction = () => [
{ title: 'Page Title | Brand' },
{ name: 'description', content: 'Descriptive meta description.' },
{ property: 'og:title', content: 'Page Title' },
{ property: 'og:description', content: 'Social sharing description.' },
{ tagName: 'link', rel: 'canonical', href: 'https://yourdomain.com/page' },
]
验证清单
完成更改后,请确认:
- robots.txt 允许全部 9 个 AI 机器人
- 公开页面上没有 noindex、nosnippet、noai
- 每个页面都包含:标题(10 个以上字符)、元描述(50 个以上字符)、规范 URL
- 每个页面都包含:恰好 1 个 H1,以及正确的标题层级(H1 → H2 → H3)
- 每个页面都包含:带有已识别 @type 的 JSON-LD
- 每个页面都包含:og:title + og:description
- 每个页面都包含:250 个以上的正文单词
- 每个页面都包含:5 个以上的内部链接
- 80% 以上的图片包含 alt 文本
-
/.well-known/llms.txt存在且有效 - RSS/Atom 源存在,并可通过
<link>标签发现 - Sitemap.xml 存在且包含
<lastmod>日期 - 内容页面包含发布日期/修改日期(元数据 + 页面可见内容)
- 内容开头直接给出答案,而非铺垫
- 关键页面包含 FAQ 部分及 FAQPage schema
- 统计数据和具名来源均在文中引用
- 在适当情况下加入权威引述
目标:AEO 评分达到 80+(B+ 或更高)。请在 aeo-audit.sh 验证。
研究参考资料
本技能中的所有统计数据均来自可验证、经过同行评审或大规模的一手研究:
| 声明 | 来源 |
|---|---|
| 引述 = 可见度提升 41%;统计数据 = 提升 33%;引用来源 = 提升 28% | Aggarwal 等人,《GEO: Generative Engine Optimization》,KDD 2024(arXiv) |
| 排名较低的网站通过 GEO 优化最多可提升 115% | 同一篇 GEO 论文——排名第 4 至第 5 的网站提升最大 |
| ChatGPT 引用中有 44.2% 来自内容的前 30% | Kevin Indig,Growth Memo,2026 年 2 月——120 万条 AI 回答、1.8 万条引用 |
| 2,900 个以上单词的文章平均获得 5.1 条引用,而少于 800 个单词的文章为 3.2 条 | SE Ranking,2025 年 11 月——230 万个页面、29.5 万个域名 |
| 每个部分包含 120 至 180 个单词,ChatGPT 引用量增加 70% | 同一项 SE Ranking 研究 |
| 包含 FAQ 的部分平均获得 4.9 条引用,不含 FAQ 的部分为 4.4 条 | 同一项 SE Ranking 研究 |
| 3 个月内更新的内容平均获得 6 条引用,超过 2 年未更新的内容为 3.9 条 | 同一项 SE Ranking 研究 |
| AI 引用的内容比自然搜索结果中的内容新 25.7% | Ahrefs,2025 年——覆盖 7 个 AI 平台的 1,700 万条引用 |
| 采用 H2/H3 层级结构,获得引用的可能性提高 2.8 倍 | AirOps,2025 年 |
| 85% 的 AI Overview 引用来自过去 2 年内的内容 | Seer Interactive,2025 年 |
| ChatGPT 带来 87.4% 的 AI 引荐流量 | Conductor,2025 年 11 月——1.37 万个域名、33 亿次会话 |