Repository navigation
fix(seo): social images, canonicals, titles, intros, structured data and sitemap / SEO:社交图片、canonical、标题、简介、结构化数据与 sitemap - #1548
Merged
Merged
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
This was referenced Oct 28, 2026
Merged
Patch [email protected] through root patchedDependencies. Unpatched, the self-hosted optimizer reads a local source image through a mocked request that reuses the browser socket. When the browser cancels the image, the read is dropped and every later request for that variant hangs until the server restarts. A unit test fails if a Next upgrade loses the patch, and the unit and E2E workflows now run when patches/ changes. 中文:通过根目录 patchedDependencies 为 [email protected] 打补丁。未打补丁时, 自托管图片优化器复用浏览器 socket 读取本地源图,浏览器取消请求后读取被丢弃, 同一尺寸的后续请求会一直挂起,直到服务重启。新增单元测试在升级 Next 丢失补丁 时失败,patches/ 变更也会触发单元测试与 E2E 工作流。
…mediately cachedJson now takes the request. It answers with brotli, gzip or plain JSON per Accept-Encoding, always sends Vary and a strong ETag, and returns 304 for a matching If-None-Match. Browsers reuse a response for 60 s. Route data, ISR page data (db-page) and CDN responses (db-cdn) carry separate tags, so an ingest expires route data at once and lets pages and the CDN refresh in the background. purgeAll, purgeCollectiveX and purgeOperatorX accept immediate, exposed through /api/v1/invalidate and the admin scripts. Fixture builds send no-store. The ingest and deploy workflows warm the dashboard APIs with a browser Accept-Encoding. The datasets route shares a per-slug cache helper. Docs, API reference text and catalog digests follow. 中文:cachedJson 改为接收请求对象,按 Accept-Encoding 返回 brotli、gzip 或 未压缩 JSON,并始终携带 Vary 与强 ETag,命中 If-None-Match 时返回 304;浏览器 复用响应 60 秒。路由数据、ISR 页面数据(db-page)与 CDN 响应(db-cdn)使用 独立标签,ingest 后路由数据立即失效,页面与 CDN 在后台刷新。purgeAll、 purgeCollectiveX、purgeOperatorX 支持 immediate,并通过 /api/v1/invalidate 与管理脚本提供。fixture 构建返回 no-store。ingest 与部署工作流以浏览器的 Accept-Encoding 预热仪表板 API。datasets 路由改用按 slug 共享的缓存。同步更新 文档、API 参考文案与路由目录摘要。
…ility The latest benchmarks request depends only on the model, so useChartData starts it alongside /api/v1/availability through a second observer on the same query key. Bulk id lookups split at each route's id limit, skip ids a fresh lookup already covered, and track freshness per id. Placeholder rows never cross a query scope. InferenceContext keeps the URL's label overrides until the sequence resolves. The coach-mark E2E waits for the overlay chart to settle before pinning a point. 中文:最新 benchmark 请求只依赖模型,useChartData 现通过同一 query key 的 第二个观察者,与 /api/v1/availability 并行发起。批量 ID 查询按各路由上限分片, 跳过已有新鲜结果的 ID,并按 ID 记录新鲜度。占位数据不再跨查询范围复用。 InferenceContext 在序列确定前保留 URL 中的标签设置。coach-mark E2E 等待叠加 图表稳定后再固定数据点。
… resolves The latest-rows prefetch fills the same query key that the sequence-gated observer reads, and a disabled React Query observer still returns cached data. Once the prefetch landed, useChartData filtered those rows by the provisional 8k/1k default and painted it, then swapped to the resolved sequence (often AgenticTraces). While prefetching, the hook now ignores that key's rows and stays loading. The network request still runs in parallel with availability, and the resolved query reads the cache without a second fetch. 中文:最新数据预取会写入与按序列门控的查询相同的 query key,而被禁用的 React Query 观察者仍会返回缓存数据。预取完成后,useChartData 会按临时的 8k/1k 默认序列过滤并绘制这些数据,随后再切换到实际序列(通常是 AgenticTraces)。现在预取期间,该 hook 不使用此 key 的数据并保持加载状态。 网络请求仍与 availability 并行发起,序列确定后直接读取缓存,不会再次请求。
Add lib/seo helpers. socialMetadata keeps og:image, og:locale and the large Twitter card on pages that set their own title. fitMetaTitle and clampMetaDescription hold titles and descriptions to search limits. chipMeta, datasetJsonLd and sitemap lastmod helpers are new too. Every non-compare page and its /zh sibling uses them. Dashboard tabs render a TabIntro h1, and the landing, about and quotes pages lead with an h1. The root layout drops its site-wide canonical and the author suffix in the title template, and /inference becomes self-canonical. Compare Dataset JSON-LD nodes carry description, license and creator. The sitemap reports real data dates instead of the build time. Model aliases redirect permanently, and next.config adds one-hop SEO redirects and a Content-Language header. 中文:新增 lib/seo 工具。socialMetadata 让自定义标题的页面保留 og:image、 og:locale 与大图 Twitter 卡片,fitMetaTitle 与 clampMetaDescription 将标题和 描述控制在搜索引擎长度内,另有 chipMeta、datasetJsonLd 与 sitemap lastmod 工具。所有非 compare 页面及其 /zh 版本改用这些工具。仪表板标签页渲染 TabIntro h1,首页、about 与 quotes 页面以 h1 开头。根布局移除全站 canonical 与标题模板 中的作者后缀,/inference 改为自引用 canonical。compare 的 Dataset JSON-LD 节点 补充 description、license 与 creator。sitemap 使用真实数据日期而非构建时间。 模型别名改为永久重定向,next.config 新增一跳 SEO 重定向与 Content-Language 头。
The Chinese per-model inference page rendered the generic ZhTabIntro copy, so every /zh/inference/<slug> shared one h1. Add an intro to inferenceModelMeta/inferenceModelMetaZh and pass title + intro to the intro card on both the EN and ZH pages. Other ZH per-model pages (historical, calculator, profit-estimator*) already use MODEL_TAB_META_ZH. 中文:/zh/inference/[model] 页面此前沿用通用的中文简介,各模型页的 h1 完全相同。现为中英文模型元数据补充按模型生成的简介,并在中英文页面中传入模型专属标题与简介。其余中文按模型页面(历史趋势、计算器、利润估算器)已使用 MODEL_TAB_META_ZH,无需改动。
The qwen/minimax ranking slugs, the renamed MiniMax M3 blog post and /media only had English 308s, so the /zh copies of those URLs returned 404. They now use LOCALE_PREFIXES like the neighbouring SEO redirects, with tests for the /zh hops. 中文:已失效的排行榜 slug、更名的 MiniMax M3 博客与 /media 原先只有英文 308 跳转,导致对应 /zh 路径返回 404。现与相邻 SEO 跳转一样使用 LOCALE_PREFIXES,并为 /zh 跳转补充测试。
Versus titles like "A vs B: Specs, Price & Power" overflowed META_TITLE_MAX for long chip names. chipMetaTitle/chipVsMetaTitle now pick the longest descriptor that fits via fitMetaTitle (EN and ZH), and a test checks every chip and versus title in both locales. 中文:芯片名称较长时,对比页标题会超出 META_TITLE_MAX。现通过 fitMetaTitle 依次尝试从长到短的中英文标题,并新增测试确保所有芯片页与对比页标题均不超限。
/zh/chips and /zh/quotes (and several other index pages) had descriptions over META_DESCRIPTION_MAX. Rewrite them to fit, give compare index pages a short search snippet while JSON-LD keeps the full text, and add a test that loads every static page metadata and checks its locale budget (EN 155, ZH 120). 中文:/zh/chips、/zh/quotes 等多个索引页的描述超出 META_DESCRIPTION_MAX。现已改写以符合长度限制,对比索引页使用简短摘要(JSON-LD 保留完整描述),并新增测试检查所有静态页面描述是否符合各语言上限(英文 155,中文 120)。
adibarra
force-pushed
the
fix/dashboard-data-waterfall
branch
from
October 29, 2026 02:06
9869176 to
0a00217
Compare
adibarra
force-pushed
the
fix/seo-metadata
branch
from
October 29, 2026 02:06
44261b2 to
f04705d
Compare
中文:将 master 合并到 fix/seo-metadata
This comment has been minimized.
This comment has been minimized.
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes using default effort and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit b201d66. Configure here.
inferenceModelMetaZh now falls back to the short model name when the detailed description exceeds the zh budget, like the English builder. 中文:中文模型描述限制在 120 字符以内。详细描述超出中文长度上限时,inferenceModelMetaZh 改用简短模型名,与英文一致。
This branch was successfully deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Summary
Part 4 of the stack split from #1530. Review and merge in order. CI only runs on PRs that target
master, so each layer was verified locally; the combined change passed full CI on #1530.Stack (merge in order):
About a third of sitemap URLs had no
og:image./inferencecanonicalized to/and was missing from the sitemap. English dashboards had no h1, titles and descriptions ran long, and Dataset rich results were invalid.socialMetadatahelper gives every page outside compare, run, rankings, overview and the blog index (EN and ZH) anog:imageand asummary_large_imagecard./inferenceis self-canonical and in the sitemap. The root-layout canonical is removed.%s | InferenceX. Titles are capped at 47 characters before the suffix, descriptions at 155 (EN) and 120 (ZH). A test enforces the description budget on every static page, which led to hand-shortened copy on about a dozen EN and ZH pages (about, overview, rankings, model index, compare indexes, chips, quotes and others); worth a copy review. Chips descriptions lead with specs and price; glossary titles are "What Is X?"; chip versus titles fall back to shorter forms for long SKUs.TabIntroh1 and intro, matching ZH./inference/[model]and/zh/inference/[model]both use a model-specific h1 and intro. Landing, about and quotes lead with an h1.description,licenseandcreator.lastmod, and revalidates hourly./agentx/<slug>URLs return 404. Model aliases redirect permanently.next.configadds 308s for dead URLs (EN and/zh) andContent-Languagefor/zh.Compare, run and rankings metadata is in the next PR. Until then those pages still include the supporters line that
docs/i18n.mddescribes as removed.Validation details
Targeted Cypress (Chrome): navigation 31/31, zh-pages 24/24. Lint, format, typecheck and the full unit suite pass on this layer.
AI model disclosure
anthropic/claude-opus-5-5(runtime-exposed identifier for the coordinating agent).PR checklist
inferencex-skillschanges (no filters or views change)/zhsiblingdocs/chinese-copy.md(Chinese maintainer review pending)中文
本 PR 为从 #1530 拆分的 stack 中的第 4 部分,请按顺序审核与合并。CI 只在以
master为目标的 PR 上运行,因此每一层都在本地验证;整体改动已在 #1530 上通过完整 CI。约三分之一的 sitemap URL 没有
og:image;/inference的 canonical 指向/且不在 sitemap 中;英文 dashboard 没有 h1;标题与描述过长;Dataset 富结果无效。socialMetadata,除 compare、run、rankings、overview 与博客索引外的所有中英文页面都输出og:image与summary_large_image卡片。/inference改为自引用并加入 sitemap,移除根布局 canonical。%s | InferenceX;标题(后缀前)不超过 47 字符,描述英文不超过 155、中文不超过 120 字符。新增测试对所有静态页的描述长度进行约束,因此手动缩短了十余个中英文页面的文案(about、overview、rankings、模型索引、各 compare 索引、chips、quotes 等),建议审阅。芯片页描述优先给出规格与价格;术语页标题改为 “What Is X?”;SKU 名称较长时,芯片对比页标题会退回更短的形式。TabIntroh1 与简介,与中文页一致;/inference/[model]与/zh/inference/[model]均使用包含模型名的 h1 与简介;首页、about、quotes 以 h1 开头。description、license、creator。lastmod使用真实数据日期,并每小时重新生成。/agentx/<slug>返回 404;模型别名永久跳转;next.config为失效 URL 增加 308,并为/zh返回Content-Language。compare、run、rankings 的元数据在下一个 PR 中处理;在此之前,这些页面的描述仍包含
docs/i18n.md中已说明移除的支持者说明。验证:定向 Cypress(Chrome):navigation 31/31、zh-pages 24/24。本层的 lint、格式、类型检查与完整单元测试均通过。
AI 模型使用说明:协调 agent 使用
anthropic/claude-opus-5-5(运行环境提供的标识),负责审计、规划与整合改动、拆分 stack 以及撰写提交与 PR 文本;委派的子 agent 在同一环境中实现各部分、构建 stack 并运行验证,其确切模型标识无法获取,因此无法确认。Note
Medium Risk
Wide metadata, canonical, redirect, and sitemap changes affect how search engines and social crawlers interpret most URLs; mistakes could alter indexing or sharing previews site-wide.
Overview
This PR is a broad SEO and crawlability pass across English and Chinese routes.
Social and canonicals. Most pages now spread a shared
socialMetadata()helper so custom titles/descriptions still getog:image, locale, andsummary_large_image./inferenceis self-canonical and listed separately from/in the sitemap; the root layout drops its site-wide canonical. The default title template becomes%s | InferenceX(without the author suffix).On-page SEO. English dashboards gain server-rendered
TabIntroblocks (TAB_INTRO+ optional model-specific copy), aligned with existingZhTabIntro. Per-model inference pages render model-specific h1/intro; landing AgentX hero, about, and quotes promote key headings to h1. Titles and descriptions are tightened viafitMetaTitle()/clampMetaDescription()(including new chip-meta helpers); many static pages get shorter meta copy, and compare index pages use shorter snippets while keeping longer text in JSON-LD.Structured data, sitemap, routing. Compare Dataset JSON-LD nodes pick up description, license, and creator. The sitemap adds agentic-workload-explorer sections, derives
lastmodfrom benchmark/content dates, and revalidates hourly.next.configadds locale-aware 308 redirects,Content-Languageheaders for EN/zh, and tests for those routes. Unknown/agentx/[slug]pages 404 vialookupDatasetPage; model alias routes use permanent redirects.Reviewed by Cursor Bugbot for commit 0816077. Bugbot is set up for automated code reviews on this repo. Configure here.