Skip to content

feat(pages-template): add SEO + JSON-LD per Google AI Search guide#482

Merged
tractorjuice merged 1 commit into
mainfrom
feat/pages-template-google-ai
May 16, 2026
Merged

feat(pages-template): add SEO + JSON-LD per Google AI Search guide#482
tractorjuice merged 1 commit into
mainfrom
feat/pages-template-google-ai

Conversation

@tractorjuice
Copy link
Copy Markdown
Owner

Summary

Companion to #481 — applies the same Google AI Search optimization items to the per-project docsites generated by /arckit:pages. Until now every generated site shared the same generic <head> (<title>Project Documentation - ArcKit</title>, description "Project documentation generated by ArcKit", no OG/Twitter, no structured data), so Google's AI indexer couldn't distinguish one ArcKit-generated site from another.

Template (pages-template.html, in lock-step in arckit-claude/ and .arckit/)

  • Project-specific <title> and meta description using {{REPO}}.
  • author meta using new {{REPO_OWNER}} placeholder.
  • OpenGraph + Twitter summary cards. No og:url / og:image — the site URL isn't known at template-fill time (custom domains exist) and Google would rather we omit than guess wrong.
  • JSON-LD @graph with three nodes wired by @id:
    • Organization for the repo owner.
    • SoftwareSourceCode with codeRepository: {{REPO_URL}}.
    • WebSite with publisher → Organization and about → SoftwareSourceCode.

Hook (arckit-claude/hooks/sync-guides.mjs)

  • New {{REPO_OWNER}} substitution mirroring the existing {{REPO}} / {{REPO_URL}} / {{CONTENT_BASE_URL}} / {{VERSION}} block. Backed by repoInfo.owner which parseRepoInfo() already extracts from .git/config.

Converter propagated to arckit-codex, arckit-copilot, arckit-opencode, arckit-paperclip (arckit-gemini/templates/ is gitignored).

Verification

  • After substitution on a realistic fixture (owner=tractorjuice, repo=arckit-test-project-v9): JSON-LD parses with three @graph nodes; no unresolved {{...}} placeholders remain.
  • All five extension-format template files diff-identical against the canonical.
  • markdownlint-cli2 'docs/*.md' clean (no markdown changed in this PR).

Test plan

  • In a test repo, run /arckit:pages and confirm the generated docs/index.html <head> shows project-specific title, meta description, and JSON-LD with Organization / SoftwareSourceCode / WebSite.
  • Paste the deployed test-repo Pages URL into Google's Rich Results Test and confirm all three schema types are detected without errors.

🤖 Generated with Claude Code

Applies the same actionable items from Google's AI optimization guide
(https://developers.google.com/search/docs/fundamentals/ai-optimization-guide)
that we just shipped for arckit.org to the per-project documentation
sites generated by /arckit:pages.

Currently the template's <head> is generic — title "Project
Documentation - ArcKit", description "Project documentation generated
by ArcKit", no OG/Twitter cards, no structured data. Google's AI
indexer therefore can't tell one ArcKit-generated docsite from
another.

Template changes (pages-template.html, in lock-step in
arckit-claude/ and .arckit/):
- Project-specific title + meta description using {{REPO}}.
- author meta using new {{REPO_OWNER}} placeholder.
- OpenGraph + Twitter (summary) cards — no og:url / og:image since
  the docsite URL isn't known at template-fill time (custom domains
  exist and we'd rather omit than guess wrong).
- JSON-LD @graph with three nodes wired by @id:
  - Organization for the repo owner.
  - SoftwareSourceCode pointing at codeRepository.
  - WebSite naming "{REPO} Architecture Documentation" with
    publisher → Organization and about → SoftwareSourceCode.

Hook change (arckit-claude/hooks/sync-guides.mjs):
- New {{REPO_OWNER}} substitution mirroring the existing
  {{REPO}}/{{REPO_URL}}/{{CONTENT_BASE_URL}}/{{VERSION}} block.
  Backed by repoInfo.owner which parseRepoInfo() already extracts
  from .git/config.

Converter propagated to arckit-codex, arckit-copilot, arckit-opencode,
arckit-paperclip (arckit-gemini/templates is gitignored).

Verified the substituted output parses as valid JSON-LD with three
@graph nodes and leaves no unresolved {{...}} placeholders.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@tractorjuice tractorjuice merged commit 23ba206 into main May 16, 2026
1 check passed
@tractorjuice tractorjuice deleted the feat/pages-template-google-ai branch May 16, 2026 10:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant