LearnNewsExamplesConnect
Frontmatter
assigneesneo-gemini-julia
createdAtOct 24, 2026, 3:09 AM
updatedAtOct 25, 2026, 2:10 AM
githubUrlhttps://github.com/neomjs/neo/issues/20089
authorneo-gemini-julia
commentsCount0
parentIssuenull
subIssues[]
subIssuesCompleted0
subIssuesTotal0
contentTrust
projected
quarantined0
signals[]
blockedBy[]
blocking[]
closedAtOct 25, 2026, 2:10 AM

Stop 19,795 raw ticket/PR routes and 2,253-item SSR sidebars from diluting Google Search Console indexing

Closed v13.4.0/archive-v13-4-0-chunk-3 enhancementaiarchitecturebuildportal
neo-gemini-julia
neo-gemini-julia commented on Oct 24, 2026, 3:09 AM

Context

In Google Search Console (Last 3 months, inspected with @tobiu on 2026-10-24), https://neomjs.com ranks almost exclusively for Air India flight numbers (ai12742 — 4,137 impressions / 0 clicks; ai10794 — 699 impressions / 0 clicks), CI error strings ("git_no_lazy_fetch" "2.43" — 578 impressions / 0 clicks), and bare "neo", with zero rankings for relevant engineering keywords (agent os, multi-threaded web framework, offscreencanvas worker, mcp memory core, etc.).

Sweep Attestations (ticket-create §1a):

  • Live latest-open sweep: checked latest 20 open issues in neomjs/neo (#19145–#20086) and neomjs/middleware-v2 (#9–#34) at 2026-10-24T01:07:10Z; no equivalent open ticket found.
  • A2A in-flight claim sweep: checked latest 30 messages (status: 'all'); no competing claim on sitemap ticket dilution or SSR ticket sidebar bloat.
  • MC sweep: query_raw_memories({query: "middleware-v2 Googlebot Search Console sitemap SsrService canonical SEO"}), 10 results; no prior decision addressing the 98.5% ticket/PR sitemap skew or 2,253-item SSR sidebar DOM bloat.
  • Own-assignment sweep: 0 open issues assigned to @neo-gemini-julia in neomjs/neo or neomjs/middleware-v2.

The Problem

Live empirical inspection of https://neomjs.com/sitemap.xml and https://neomjs.com/news/tickets/12742 (as User-Agent: Googlebot) revealed two compounding structural causes:

  1. Extreme Sitemap & llms.txt Dilution (98.5% raw issue/PR churn vs 0.6% documentation):

    • Out of 20,266 total URLs in https://neomjs.com/sitemap.xml (and 20,900 lines in apps/portal/llms.txt):
      • 12,553 (61.9%) are /news/tickets/*
      • 6,895 (34.0%) are /news/pulls/*
      • 347 (1.7%) are /news/discussions/*
      • 151 (0.7%) are /news/releases/*
      • Only 124 (0.61%) are /learn/* guides, 20 (0.10%) are /news/blog/* posts, 94 (0.46%) are /examples/*, and 81 (0.40%) are /apps/*.
    • Submitting 19,795 raw GitHub issue/PR/discussion URLs in the single flat sitemap.xml (and llms.txt) swamps crawl budget and context windows, telling Google and LLM crawlers that neomjs.com is an issue-tracker mirror rather than an engineering documentation and product site.
  2. ~360 KB / 2,253-item Sidebar TreeList Boilerplate & Raw Frontmatter in Every Ticket SSR Page:

    • Fetching https://neomjs.com/news/tickets/12742 as Googlebot returns 359,525 bytes (~360 KB) of HTML, of which over 90% is 2,253 <li class="neo-list-item"> nodes inside the left-hand neo-treelist-1 sidebar (~4.5 GB of identical ticket-title boilerplate repeated across 12,553 ticket pages when idMap.json is not served).
    • Furthermore, Portal.view.news.tickets.Component#frontMatterToHtml (apps/portal/view/news/tickets/Component.mjs:67-103) renders raw markdown frontmatter (id: 12742, title, state, labels: ai) as table rows at the very top of <article> even though title, state, and labels are already rendered in the <h1> heading and <div class="neo-ticket-labels"> badge bar right below it — tokenizing id 12742 ... labels ai into ai12742 and ai10794 and causing Google Search Console to match thousands of searches for Air India flight AI 12742 and AI 10794 (4,836 combined impressions, 0 clicks)!

The Architectural Reality

  • Design authority: "The SEO Generator script produces two distinct artifacts with different scopes: 1. llms.txt (Curated Context)... 2. sitemap.xml (Exhaustive Index): Contains all routes from llms.txt PLUS all ticket routes. This ensures search engines can index our entire knowledge base, including resolved issues, while keeping the LLM context file lean." (buildScripts/docs/seo/generate.mjs)
  • That original design assumption scaled poorly once the repository grew from a few hundred tickets to 19,795 tickets/PRs/discussions (98.5% of sitemap.xml and llms.txt).
  • Meanwhile, Portal.view.news.pulls.Component#frontMatterToHtml (apps/portal/view/news/pulls/Component.mjs:81) already skips number via a skip map, whereas Portal.view.news.tickets.Component#frontMatterToHtml (apps/portal/view/news/tickets/Component.mjs:67-103) still renders duplicate id, title, state, and labels rows inside <table class="neo-frontmatter-table">.

The Fix

  1. In buildScripts/docs/seo/generate.mjs (neomjs/neo):
    • Exclude raw tickets, pull-requests, and discussions archive categories from getSitemapXml() and getLlmsTxt() by default (includeArchives = false), keeping sitemap.xml and llms.txt focused on /, /learn/*, /news/blog/*, /news/releases/*, /examples/*, /apps/*, and /docs (~476 high-value canonical pages) while supporting includeArchives: true / --include-archives when an exhaustive archive dump is explicitly requested.
    • Skip scanning collectIssueRoutes, collectPullRoutes, and collectDiscussionRoutes inside collectAllRoutes when includeArchives: false so getSitemapXml and getLlmsTxt also avoid scanning 19,795 corpus files unnecessarily, while getContentRoutes and getContentRouteObjects continue to default to includeArchives = true for SPA route-table consumers.
  2. In apps/portal/view/news/tickets/Component.mjs (Portal.view.news.tickets.Component#frontMatterToHtml):
    • Omit id, title, state, and labels rows from frontMatterToHtml(data) (matching Portal.view.news.pulls.Component#frontMatterToHtml's skip pattern), since those four fields are already rendered in the ticket <h1> title and .neo-ticket-labels badge bar, eliminating duplicate metadata rows and raw id: <number> + labels: ai token combinations at the top of ticket pages.

Contract Ledger Matrix

Target Surface Source of Authority Proposed Behavior Fallback Docs Evidence
getSitemapXml & getLlmsTxt (buildScripts/docs/seo/generate.mjs) buildScripts/docs/seo/generate.mjs:758-1230 (amends scope) Excludes raw /news/tickets/*, /news/pulls/*, and /news/discussions/* churn from primary sitemap.xml and llms.txt by default (includeArchives = false) includeArchives: true option / --include-archives CLI flag Module & function JSDoc in buildScripts/docs/seo/generate.mjs test/playwright/unit/buildScripts/docs/seo/Generate.spec.mjs
Portal.view.news.tickets.Component#frontMatterToHtml (apps/portal/view/news/tickets/Component.mjs) apps/portal/view/news/tickets/Component.mjs:67-103 & apps/portal/view/news/pulls/Component.mjs:77-112 Skips id, title, state, and labels rows in .neo-frontmatter-table (already rendered in H1 + .neo-ticket-labels header badges) and returns '' when no non-header rows remain Other frontmatter keys (author, createdAt, updatedAt, closedAt, subIssues, etc.) continue to render in .neo-frontmatter-table Method JSDoc in apps/portal/view/news/tickets/Component.mjs test/playwright/unit/apps/portal/view/news/tickets/Component.spec.mjs

Decision Record impact

none (amends JSDoc design assumption in buildScripts/docs/seo/generate.mjs)

Acceptance Criteria

  • Primary sitemap.xml and llms.txt generated by buildScripts/docs/seo/generate.mjs include /, /learn/*, /news/blog/*, /news/releases/*, /examples/*, and /apps/* without flooding 98.5% of entries with /news/tickets/*, /news/pulls/*, and /news/discussions/* (while includeArchives: true / --include-archives retains them when requested, and getContentRoutes() continues to return all SPA routes).
  • Portal.view.news.tickets.Component#frontMatterToHtml (apps/portal/view/news/tickets/Component.mjs) omits duplicate id, title, state, and labels rows from .neo-frontmatter-table so raw id: <number> and labels: ai frontmatter table tokens are not emitted ahead of the H1 title.
  • JSDoc in buildScripts/docs/seo/generate.mjs and apps/portal/view/news/tickets/Component.mjs is updated to reflect why raw ticket/PR/discussion churn and duplicate frontmatter rows are excluded from primary search and LLM indexing.

Out of Scope

  • Per-route <title>, <meta name="description">, and <link rel="canonical"> injection in SsrService.mjs (tracked in sibling neomjs/middleware-v2#35 & #36).
  • Doubled /news/blog/blog/<slug> route bug (resolved in neomjs/neo#20088 / PR #20096).

Avoided Traps

  • Keeping 19,795 raw tickets/PRs indexed in primary sitemap.xml and llms.txt: Even with proper <title> tags, 19,795 auto-generated issue/PR pages outnumber our 124 /learn/* guides by 160:1, guaranteeing crawl-budget and topical-authority dilution on a domain with limited external backlinks and blowing through LLM context windows (1.5 MB llms.txt).

Related

  • neomjs/neo#20088
  • neomjs/middleware-v2#35
  • neomjs/middleware-v2#36

unowned-rationale: Filed upfront during operator-directed SEO/Search Console root-cause audit; claimed and in progress by @neo-gemini-julia. Origin Session ID: 7bbb249d-903b-4ad7-b69c-658b286ce4a0 Retrieval Hint: "ai12742 ai10794 git_no_lazy_fetch sitemap.xml 12553 tickets 2253 neo-list-item"

tobiu referenced in commit a845007 - "fix(seo): exclude raw ticket and PR archives from primary sitemap and llms.txt (#20089) (#20097)" on Oct 25, 2026, 2:10 AM
tobiu closed this issue on Oct 25, 2026, 2:10 AM