Skip to content

refactor(shell-docs): give each frontend its own pages and index each page once - #8321

Merged
tylerslaton merged 5 commits into
tylerslaton/docs-stack-1-frameworksfrom
tylerslaton/docs-stack-2-routing
Nov 11, 2026
Merged

tylerslaton merged 5 commits into
tylerslaton/docs-stack-1-frameworksfrom
tylerslaton/docs-stack-2-routing

Conversation

@tylerslaton

@tylerslaton tylerslaton commented Nov 11, 2026 •

Copy link
Copy Markdown
Contributor

Part 2 of 4 in a stack into tylerslaton/docs-shell-docs-v2. Merge the stack together.

Why

Each frontend's sidebar and pages came from a port of the old docs' filtering. Ten overlapping mechanisms decided whether a page applied to a frontend: the frontend: policy, allowlists, an 86-entry Angular redirect map, hand-built sidebars, and an 838-line sidebar regrouping. Pages a frontend lacked opened React's version. Every frontend × framework prefix served each page under its own self-canonical URL, so the sitemap listed 4,168 URLs for about 350 pages.

The rule

A page exists for a reader when it's in:

  • their frontend's folder (frontends/vue, frontends/angular, frontends/react-native; for Slack and Teams, their connect guide and then the shared channels/ guide);
  • their framework's own folder;
  • React's root pages (React readers only);
  • or docs/(shared).

Otherwise the URL 404s. A page that documents a showcase feature (snippet_cell) doesn't exist for a framework whose manifest lists that feature in not_supported_features, quarantined features included. whereIs() in src/lib/live-pages.ts applies the rule on the server and in the browser.

What changes

  • Sidebars. Each sidebar is its meta.json file, in the shape readers see:

    • the app frontends share docs/meta.json;
    • Slack and Teams use channels/meta.json;
    • the framework's own pages lead "Agent capabilities";
    • docs/(shared)/meta.json closes every sidebar.

    A row shows only when its page exists for the reader, and rows use nav_title.

  • Shared pages. The frontend-neutral pages move into the docs/(shared) route group. Their URLs don't change.

  • Stack picker. It opens the same page on the new stack when that stack has it, and the stack's home otherwise.

  • Indexing. Each page has one canonical URL: the framework is dropped unless the page is the framework's own, and the frontend is dropped unless the page is the frontend's own. The sitemap, llms-full.txt, search and MCP all list those URLs. The sitemap goes from 4,168 URLs to about 480.

  • Search. Entries are tagged with the frontends that have them, and results are filtered to the reader's frontend.

  • Redirects.

    • /react-spa/* → the React page.
    • An unscoped URL of a page the built-in agent lacks → the page under a framework that has it (308).
  • Removed. live-sidebar.ts, live-frontend-sidebar.ts, the frontend: metadata, CHANNEL_GUIDES, FRAMEWORK_WINS, and the authored/generated split.

  • Showcase search. The showcase app's search index builds its docs rows the same way, and its old regrouping and policy code goes.

Checks

  • tsc and check-live-mdx pass.
  • URL safety net: 4,112 of the 4,168 old sitemap URLs return 200 or redirect to one. The other 56 are pages a framework's showcase marks unsupported (interrupt, headless interrupts, state streaming, state rendering), such as /agno/human-in-the-loop/useInterrupt, and they 404 by design.
  • The showcase app's search index (showcase/scripts/generate-search-index.ts) is rebuilt from the new layout; its tests pass.
  • Sidebars were compared with the target branch for React, Mastra, LangGraph, Vue, Angular, Slack and React Native.

Heads-up

Most frameworks' manifests quarantine gen-ui-interrupt and interrupt-headless for a react-core bug that was fixed in 1.62.1. The interrupt pages therefore 404 for those frameworks, LangGraph included; LangGraph keeps its own interrupt-flow page. When the showcase lifts the quarantine after a D6 rerun, the pages come back with no docs change.

🤖 Generated with Claude Code

@tylerslaton
tylerslaton requested review from jpr5 and mme as code owners November 11, 2026 00:38
@coderabbitai

coderabbitai Bot commented Nov 11, 2026 •

Copy link
Copy Markdown
Contributor

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

🗂️ Base branches to auto review: 1

  • main

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

Run configuration

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • Trigger review
Pre-merge checks: Passed 1 · Inconclusive 1

Failed Failed checks: 1 inconclusive

Check name Status Explanation Resolution
Title check Pending This assessment has not completed. The check will be retried on the next pre-merge check run.
Passed Passed checks: 1 passed

Check name Status Explanation
Description Check Passed Check skipped - CodeRabbit’s high-level summary is enabled.
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

@tylerslaton
tylerslaton added this pull request to stack #8323 November 11, 2026 00:38
@github-actions

github-actions Bot commented Nov 11, 2026 •

Copy link
Copy Markdown
Contributor

Production Digest-Pinning Audit

All 44 services digest-pinned.

Run 2026-11-10 19:50:29 PST — 0 finding(s).

@tylerslaton tylerslaton changed the title tylerslaton/docs stack 2 routing refactor(shell-docs): give each frontend its own pages and index each page once Nov 11, 2026
tylerslaton and others added 5 commits November 10, 2026 19:46
Every frontend got React's sidebar (Slack readers saw the chat guides),
and a page a frontend lacked opened React's. Replace the ported filtering
(the frontend: policy, per-frontend allowlists, the Angular redirect map,
hand-built sidebars, the 838-line sidebar regrouping) with one rule:

- A page exists for a reader when it's in their frontend's folder
  (frontends/vue, frontends/angular, frontends/react-native; Slack's and
  Teams' connect guide, then the channels guide they share), their
  framework's own folder, React's root pages, or docs/(shared). Otherwise
  it's a 404. whereIs() in src/lib/live-pages.ts decides, on the server
  and in the browser.
- A page that documents a showcase feature (snippet_cell) doesn't exist
  for a framework whose manifest lists the feature in
  not_supported_features. An unscoped URL of such a page redirects to it
  under a framework that has it.
- The sidebars are their meta.json files, in the shape readers see: the app
  frontends share docs/meta.json, Slack and Teams use channels/meta.json,
  the framework's own pages lead Agent capabilities, and docs/(shared)/meta.json
  closes every sidebar. A row shows only when its page exists for the
  reader. Rows take a page's nav_title.
- The frontend-neutral pages (runtime, Intelligence, deploy, concepts,
  protocols, troubleshooting) move into the docs/(shared) route group;
  their URLs don't change.
- The stack picker opens the same page on the new frontend or framework
  when it has it, and the new stack's home when it doesn't.
- React SPA is React: /react-spa keeps its guide, other /react-spa/* URLs
  redirect to the React page.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Every frontend and framework prefix served each page under its own
self-canonical URL, so the sitemap listed 4,168 URLs for about 350 pages
(frontend-tools 20 times) and search returned up to 20 copies of a title.

- Each page has one canonical URL: the framework is dropped unless the page
  is the framework's own, and the frontend unless the page is the
  frontend's own (/vue/mastra/backend/copilot-runtime points at
  /backend/copilot-runtime). Framework landings and quickstarts keep their
  framework.
- The sitemap, llms-full.txt, search, and the MCP server list those URLs,
  from one list (livePages); the sitemap drops to about 480 URLs.
- Search entries are tagged with the frontends that have the page, and the
  dialog's results are filtered to the reader's frontend.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
…overview

Five folded URLs pointed at a page their framework's showcase marks
unsupported (state streaming, interrupt rendering), which now 404s for that
framework. Send them to the topic's overview instead.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
…s layout

The showcase app's search index re-derives the docs' navigation with a port
of the old docs app's logic (the frontend: policy, authored/generated
sidebars, an 838-line regrouping pass). After the docs moved the
frontend-neutral pages into docs/(shared) and wrote each sidebar's
meta.json in its final shape, the walk missed the shared pages and its
coverage check failed the build.

Compose sidebars the way the docs app does (the outline, the framework's
own pages first in Agent capabilities, then docs/(shared)/meta.json), read
meta.json link entries as rows, and decide a frontend's pages by where they
live. The regrouping code and the policy reader go. The index has 256 docs
rows; the coverage floor follows.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Moving the shared pages into docs/(shared) kept their URLs, since a route
group isn't part of the URL, but CrewAI's docs-link test looked for each
page only under docs/ and docs/integrations/crewai-flows/. It reported
/multi-agent/subagents, /agent-config and /backend/ag-ui as missing. Look
in docs/(shared) too.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@tylerslaton
tylerslaton force-pushed the tylerslaton/docs-stack-2-routing branch from 9d62355 to 174f7b5 Compare November 11, 2026 03:48
@tylerslaton
tylerslaton merged commit 2346cf0 into tylerslaton/docs-shell-docs-v2 Nov 11, 2026
25 of 37 checks passed
@tylerslaton
tylerslaton deleted the tylerslaton/docs-stack-2-routing branch November 11, 2026 04:20
tylerslaton added a commit that referenced this pull request Nov 12, 2026
One PR for the docs rebuild. It replaces #8214 and the
`tylerslaton/docs-shell-docs-v2` stack (#8320, #8321, #8322, #8325),
which had drifted onto two branches with different work on each. Both
old branches stay on origin, unchanged, as archives.

## What does this PR do?

It replaces `showcase/shell-docs` with the Fumadocs rebuild of
docs.copilotkit.ai, in place. There is no second docs app. The pages
stay at `showcase/shell-docs/src/content`, so git records them as edits
to the files that were already there. The plan is to merge this into
`main` and then rebase `2.0.0` on top.

### How this branch was put together
- **Base:** today's `main` (`4d647b76e8`).
- **#8214's 64 commits**, unchanged. `main`'s 8 newer commits don't
touch the docs or the showcase, so they replayed cleanly.
- **The stack's 19 commits** from `docs-shell-docs-v2`, on top. Where
they met work that #8214 had and the stack didn't, the conflicts were
resolved by hand, and each commit message says what changed:
- **Model pins.** The stack's setup snippets were written before #8214
pinned `gpt-6-luna`. A new last commit pins the 32 setup files the same
way the rest of the docs and each integration's own agent code do.
- **Angular.** `main`'s native generative UI guide
(`/angular/guides/generative-ui-components`) moves to
`/angular/generative-ui/native`, like the other Angular guides. It gets
a redirect and a row in the Angular generative UI overview.
- **Dark mode.** The `globals.css` sync and the scroll fix are applied
on top of `main`'s dark mode. They also cover `openai-agents-python`,
which `main` added since.
- **Checked:** every commit of both old branches has a counterpart here,
and a file-by-file three-way check found no content from either branch
missing. The few differences are newer `main` work (for example
`setup-dotnet` v6.1.0), #8214's adaptations to `main`, and the model
pins.

### What's in it
- **The new app.** It has the Spacious layout and brand theme, and a
framework and frontend picker that opens the chosen frontend's page.
Each frontend gets its own sidebar (Slack, Teams, Angular, Vue, React
Native).
  - Ask CopilotKit runs in the sidebar and at `/ask`.
- It adds the standard catalog Story pages and an examples playground.
That playground loads its catalog, generated from the showcase data,
only on `/examples`.
- It also brings Orama search that keeps the reader's scope, an MCP
server, llms.txt and Markdown routes (with the demo and setup code
inlined), telemetry, and the legacy redirect tables.
- **Pages.** `main`'s pages change in only two mechanical ways: page
imports are dropped, and pages with sub-pages move to `X/index.mdx` (13
renames). On top of that, the docs review's fixes are a separate diff,
as are a round of accuracy and link fixes from code review.
- **`public/`.** It keeps every file it had on `main`. Only new icons
and logos are added.
- **Code that read the old app's files.** The showcase shell's search
index keeps the old sidebar-reachability rules in
`showcase/scripts/lib/docs-searchable`, with the old app's tests ported
next to them. The shell image and the workflows, tests, skills and docs
that named old paths are updated too.

### From the stack (#8320–#8325)
- **One page per feature.** Each framework's copies of the shared pages
fold into the shared pages, which gate sections on the showcase's
supported features. The setup steps the copies carried move into each
integration's `docs/setup/*.mdx`. Stale URLs redirect, and a folded page
a framework can't show sends readers to that framework's overview.
- **Frontends by one rule.** Each frontend gets the pages it has, and
each page is listed and indexed once. The showcase decides a frontend's
own feature pages too.
- **Angular and React Native at React's URLs.** Angular's eight combined
guides become pages at React's slugs, with one-hop redirects from
`/angular/guides/*`. React Native gets 19 feature pages. The showcase
search reads both from their React slugs. The app frontends' "Using
these docs" pages and Angular's feature catalog page are gone.
- **Showcase demos.** Full-page chats fill the page in every
integration. Every integration's `globals.css` is now
langgraph-python's, `create-integration` copies it, and a test fails on
drift. The three tall demo pages scroll inside the page.
- **CrewAI docs links** point at the folded pages, and their test finds
pages in the `(shared)` route group.

### Review fixes (two code reviews)
- **Security:** Ask's API route now accepts only `info`, `agent/run`,
`agent/connect` and `agent/stop`, so the thread list, read and wipe
calls are rejected.
- The CopilotKit packages are on 1.84.1, which has the runtime's
thread-owner check and the scroll-to-bottom fix (#8159), so no patch is
needed.
- Every run is capped: a limit across all readers on top of the per-IP
one, size caps on context, state, tools and the whole request, the docs'
own tools only, and 10 steps.
- **Routing:**
- Legacy `/docs*` URLs redirect as on `main`, and unknown URLs answer
404.
- Framework landings render instead of redirecting, `/intelligence` is a
301 again, and Google Antigravity is back.
  - Each framework's docs mode now comes from its manifest.
- **Deploy:**
- The docs deploy check now verifies the runtime config the new app
serves (`/api/telemetry/config`, with a real PostHog key required in
production). The old app's server-written Clerk config, which the new
app doesn't have, is no longer required.
- The Docker image smoke-tests itself before it is pushed and runs as
`node`.
- Hosts (sign-up, Cloud, showcase, demos) come from the environment per
request, so staging no longer links to production.
- **CI:** `test_unit-shell-docs` builds and serves the app, then runs
the redirect check and a request to every page. The telemetry emitter
now finds the new app's `trackEvent` calls.

### Carried over from `main`
The rebuild uses `main`'s shared theme bridge from
`showcase/integrations/_shared/ts/theme.ts`. Where `main` had changed
the old app or the same pages, its changes are carried into the rebuild
in their own commits:
- **Models:** `main` moved every OpenAI sample to `gpt-6-luna` and made
it the only OpenAI model the allowlist ships. This branch's samples
follow, with `main`'s `reasoning_effort="none"` call shapes.
- **Generative UI:** `main`'s Angular, Vue and React Native additions to
the component guides, the React Native guide and its reference are kept.
Its two docs-pinning tests (`react-native-generative-ui-docs`,
`vue-generative-ui-docs`) now run in the showcase-scripts suite, under
`__tests__/docs-content`.
- **Telemetry:** `main`'s personless, bot-filterable `docs_pageview` and
`seo_redirect` (cookie `ph_docs_id`) are ported into
`src/lib/telemetry/proxy.ts`.
- **llms.txt:** `main`'s OpenBot section is in the new index.
- **Antigravity:** the real Antigravity mark from `main` is used.

## What merging does
- **Deploys:** `showcase_build` redeploys shell-docs, so
docs.staging.copilotkit.ai serves the new app. It also redeploys shell,
dojo, dashboard, the harness and every integration whose files changed.
Production changes only on promote.
- **Telemetry:** the registry update after merge will drop 9 docs events
the new app doesn't send. Examples: `markdown_copied`,
`open_in_llm_clicked`, `docs.framework_selected`,
`docs.frontend_selected`.

## Not in this PR
- A spend-capped OpenAI key and a shared rate-limit store for Ask; the
code limits are per instance. Also confirm `OPENAI_API_KEY` is set on
the Railway docs service.
- Moving the live layout out of `src/proto`.
- Held back: the Strands `threads-import` note on
`a2uiGenerationToolNames` waits for #8137.
- Two showcase integrations still link to docs pages that no longer
exist in `docs-links.json`: spring-ai (2 links) and built-in-agent (1).
No test checks them.

## Verification
Run on this branch:
- **shell-docs** (the `test_unit-shell-docs` steps):
  - `showcase-data`, `tsc`, oxlint, the LFS fetch and `next build` pass.
  - All 616 pages compile.
- Against `next start`: `check-redirects` passes 1034/1034, and
`check-live-pages` 506/506.
- **Repo suites:**
- showcase-scripts 3464/3464, including the `globals.css` drift guard
across all 23 integrations and `main`'s two generative UI docs tests.
  - The CrewAI docs-link tests pass for both CrewAI integrations.
  - The packaged-skill drift checks pass 8/8.
- The deprecated-import ratchet passes 8/8. Its baseline is regenerated
for the moved pages and shrinks from 81 to 74 entries, with nothing new
taught.
  - The model-name and Intelligence env-name checks are clean.
- **Nothing lost:**
- `git range-diff` pairs all 64 of #8214's commits unchanged. 72 of the
stack branch's 75 have a counterpart. The other three are a
`setup-dotnet` comment fix (superseded by `main`'s v6.1.0 pin), its
`gpt-6-luna` allowlist commit (covered by #8214's own), and the scroll
fix, rewritten here on top of dark mode.
- A three-way check of every file either branch changed found nothing
missing. The differences that remain are newer `main` work, the folded
pages, and the model pins.

## Related PRs and Issues
- Replaces #8214 (and #8160 before it), and the stack #8320, #8321,
#8322 and #8325, which merged into `tylerslaton/docs-shell-docs-v2`.
- Supersedes #8162 (its Dockerfile and LFS fetch are here).

## Checklist

- [x] I have read the [Contribution
Guide](https://github.com/copilotkit/copilotkit/blob/master/CONTRIBUTING.md)
- [x] If the PR changes or adds functionality, I have updated the
relevant documentation
- [x] If the PR contains a breaking change, the title has `!` (for
example `feat(react-core)!: ...`) and the description has a `BREAKING
CHANGE:` line with migration steps. See
[VERSIONING.md](https://github.com/CopilotKit/CopilotKit/blob/main/VERSIONING.md)
- [x] "Allow edits by maintainers" is checked (lets us help iterate on
your PR directly — faster turnaround for everyone)

BREAKING CHANGE: `showcase/shell-docs` is a new app. Its scripts, source
layout and dev server follow the Fumadocs rebuild; run it with `npm
install && npm run dev` in `showcase/shell-docs` (see its README).

🤖 Generated with [Claude Code](https://claude.com/claude-code)
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