Skip to content

docs(showcase): documentation pass (Bundle 5 consolidation) - #4021

Closed
jpr5 wants to merge 6 commits into
mainfrom
feat/bundle-5-showcase-documentation
Closed

jpr5 wants to merge 6 commits into
mainfrom
feat/bundle-5-showcase-documentation

Conversation

@jpr5

@jpr5 jpr5 commented Apr 16, 2026

Copy link
Copy Markdown
Contributor

Bundle 5 consolidation — showcase documentation

Consolidates 6 documentation PRs into one. Net additions:

Refs: Full Action Inventory

jpr5 added 6 commits April 16, 2026 14:22
The showcase/ tree had a one-line README containing just the title. Replace
with a technical overview covering layout, artifact types, per-piece
responsibilities, local dev, the five e2e harnesses (including the
/test-aimock <slug> PR comment trigger), Railway deployment, and pointers
to INTEGRATION-CHECKLIST / QA-COVERAGE / STYLING-GUIDE.
Document which CI workflows fire on which triggers, what they test,
and clarify that the PROTECT_OUR_MAIN ruleset requires zero status
checks today (legacy required_status_checks.contexts is ghost data).

Companion to QA-COVERAGE.md: that tracks per-demo coverage, this
tracks per-workflow gating.

Skipping pre-commit: @copilotkit/sqlite-runner:test fails on main
(unrelated pre-existing runner.close undefined); docs-only change.

Refs J4 action-inventory item.
Adds showcase/aimock/README.md covering: what aimock is and why the
showcase uses it; the roles of feature-parity.json and smoke.json;
the hand-maintained sync policy and its two layers of load-time
schema validation (Dockerfile --validate-on-load + CI fixture test
from #3973); how to add/update a fixture; drift risk surfaces and
response; and the CI workflows that exercise the fixtures.
The showcase_aimock-e2e.yml workflow has been live but undiscoverable —
nothing in the repo tells contributors it exists. Add a Testing section
to showcase/README.md covering the trigger syntax, what runs, and
permissions, with a link back to the workflow file.

Relates to M6 in the action inventory.
@vercel

vercel Bot commented Apr 16, 2026 •

Copy link
Copy Markdown
Contributor

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
chat-with-your-data Ready Ready Preview, Comment Apr 16, 2026 9:27pm
docs Ready Ready Preview, Comment Apr 16, 2026 9:27pm
form-filling Ready Ready Preview, Comment Apr 16, 2026 9:27pm
research-canvas Ready Ready Preview, Comment Apr 16, 2026 9:27pm
travel Ready Ready Preview, Comment Apr 16, 2026 9:27pm

Request Review

@github-actions

Copy link
Copy Markdown
Contributor

📣 Social Copy Generator

Generate social media copies (Twitter/X, LinkedIn, Blog Post) for this PR using Claude.

  • Generate social media copies

@jpr5

jpr5 commented Apr 21, 2026

Copy link
Copy Markdown
Contributor Author

Subsumed by #4064 (Bundle 5 — showcase documentation pass). See #4064 for the consolidated version. README.md rewrite dropped (main's post-#4109 version is canonical); other 4 docs carried over with shell-dojolike refs fixed.

@jpr5 jpr5 closed this Apr 21, 2026
jpr5 added a commit that referenced this pull request Apr 22, 2026
…dening (#4064)

Rebased onto `feat/showcase-ops`. 10 commits, ~210 files, +8,200 /
-2,150 (approximate — see `git log`).

## Summary

Omnibus cleanup on top of `feat/showcase-ops`: QA parity,
`interrupts-langraph` → `interrupts-langgraph` typo rename, `hitl` →
`hitl-in-chat` catalog id rename, showcase documentation pass, workflow
filename standardization, plus hardening across showcase scripts, shell
components, and the LangGraph interrupts starter.

## Scope

### Bundle 0 — QA markdown parity (15 packages)
Stubs so every package has checklists for all 9 demos. Final inventory:
17 × 9 = 153 QA files. `langgraph-python` is intentionally excluded
because it migrated its HITL demo into `hitl-in-chat` + `hitl-in-app`
cells.

### Bundle 1 — `interrupts-langraph` → `interrupts-langgraph` typo
rename
Full directory rename plus internal Nx / pnpm / lockfile consistency.
Starter published at 0.1.5 with dep bumps (`@types/node ^22.19.11`,
`typescript ^5.9.3`, `zod ^3.25.76`, `@langchain/langgraph 1.1.5`,
`@langchain/core ^1.1.26`) and hardening below.

### Bundle 2 — `hitl` → `hitl-in-chat` catalog id rename
Catalog id renamed across 17 package manifests, shell registry, feature
registry, constraints (YAML + JSON). QA markdown and e2e specs renamed.
URL route `/demos/hitl` is intentionally retained (id vs route split
documented in the validator).

Exposed + fixed two real bugs in the legacy `hitl.spec.ts`: phantom
`data-role="assistant"` selector (matched nothing), and an
always-passing approval assertion. Rewrote per-package HITL README
content across all 17 packages (was describing the wrong "warm sunset
gradient" flow instead of StepSelector).

### Bundle 5 — Showcase documentation pass
Four new / updated docs consolidated here, subsuming sibling PR #4021:

- `showcase/TESTING.md` — canonical test-gating matrix across every
testing workflow, now using the `test_<layer>-<target>` names from
Bundle 6
- `showcase/aimock/README.md` — aimock fixture-sync docs
- `showcase/FRONTEND-STRATEGY.md` — multi-shell consolidation rationale;
inventory table uses current shell names (`shell`, `shell-dojo`,
`shell-docs`, `shell-dashboard`). The sibling branch's `shell-dojolike`
references were all audited and replaced
- `showcase/INTEGRATION-CHECKLIST.md` — adds two new sections:
- "Source of Truth: `examples/integrations/*` vs `showcase/packages/*`"
  - "LangGraph: Prebuilt vs Node-Based"

`showcase/README.md` from the sibling branch is **not** pulled — main's
post-#4109 version is canonical with a different premise.

### Bundle 6 — Workflow filename standardization
Renames 7 testing workflows to the `test_<layer>-<target>` naming scheme
with CI UI `name:` fields normalized to `test / <layer> / <target>`.
Subsumes sibling PR #4020:

- `e2e_dojo.yml` → `test_e2e-dojo.yml`
- `e2e_examples.yml` → `test_e2e-legacy-v1.yml`
- `showcase_aimock-e2e.yml` → `test_e2e-showcase-on-demand.yml`
- `test_doc-examples.yml` → `test_integration-docs.yml`
- `test_runtime-servers.yml` → `test_integration-runtime.yml`
- `starter_deployed_smoke.yml` → `test_smoke-starter-deployed.yml`
- `starter-smoke.yml` → `test_smoke-starter.yml`

The 8th rename in the source branch (`showcase_smoke-monitor.yml` →
`test_smoke-showcase-deployed.yml`) is **skipped** — `feat/showcase-ops`
(#4113) deletes that workflow entirely in favor of runtime probes. For
`test_e2e-showcase-on-demand.yml`, `git mv` uses main's current content
(preserving 5 hardening commits for readiness probes, trust-gate layers,
pip wheel fallback, and CR5–CR8 security fixes); only the `name:` field
is pulled from the rename branch.

Consumer references updated in `examples/e2e/AGENTS.md`,
`showcase/QA-COVERAGE.md`, `showcase/TESTING.md`,
`showcase/aimock/README.md`,
`showcase/scripts/create-integration/index.ts`, and
`showcase/scripts/__tests__/create-integration.test.ts`.

## Hardening

### `showcase/scripts/lib/manifest.ts`
- Tagged-union `ParsedManifest` parser (`ok` / `missing` /
`malformed{syntax|shape}` / `unreadable`) with deep-frozen output
- `DemoId` branded type with smart constructor
- `/demos/` route-prefix validation, empty-tail guard, duplicate-id
detection
- `backend_url` shape validation
- `ENOENT` / `EACCES` discrimination via `statSync`

### `showcase/scripts/validate-parity.ts`
- `routeToDirName` helper for id-vs-route resolution
- 13-variant `PackageIssue` discriminated union, `deriveMessage` as
single render source
- Typed error classes (`ManifestMalformedError`,
`ManifestUnreadableError`, `InvalidBaselineError`)
- `ValidateParityExitCode` literal union taxonomy
- `formatErrorChain` with cycle guard + depth cap
- Per-slug crash isolation: one malformed manifest no longer aborts the
batch
- Cooperates with `feat/showcase-ops`'s `auditableDemos` filter
(informational demos carrying a `command:` field are excluded from
parity checks)

### `showcase/scripts/create-integration/index.ts`
- Strict `parseArgs`: duplicate-flag rejection, `--slug` regex guard
(path-traversal protection), `--name` character allowlist (XSS guard on
generated JSX)
- `probePath` `statSync`-based fs probe replacing all `existsSync` call
sites
- Feature registry elementwise validation
- `updateWorkflows` exported for unit testing; uses `WORKFLOWS_DIR`
constant
- `showcase_drift-detection.yml` edit removed — superseded by the
`showcase-ops` service's `aimock_wiring` / image-drift probes which
enumerate services from Railway at runtime
- Generated health/debug routes distinguish `unconfigured` (env unset)
from `down` (reachable but error)
- Smoke route `AbortSignal.timeout` classification (Node 18+
`TimeoutError`)
- Fail-fast rejection of `--language dotnet` (no .NET generator branches
exist)
- Dropped invalid `X-Frame-Options: ALLOWALL` from generated
`next.config.ts`

### `showcase/scripts/__tests__/create-integration.test.ts`
- Hardening regression suite migrated off `execSync` +
`CREATE_INTEGRATION_SKIP_WORKFLOWS` onto `runGenerator()` so every test
writes entirely inside a per-suite tmpdir and never touches the real
`packages/` tree
- Direct-import coverage for `loadFeatureRegistry` failure modes (ENOENT
/ invalid JSON / shape-invalid) and `parseArgs` guard coverage

### `showcase/scripts/capture-previews.ts`
- `CaptureResult` tagged union replacing boolean+optional shape
- Strict `parseArgs`: hex/float/negative/zero `--concurrency` rejection,
unknown flag rejection, duplicate-flag rejection
- `readAllManifests` ENOENT/EACCES/EPERM discrimination
- `execFileSync` replacing template-interpolated `execSync` (no shell
injection)
- Filtered empty-targets exit-nonzero
- Response-timeout tagged as `CaptureFailure`
- Renamed `hitl` → `hitl-in-chat` config key; parses manifest via shared
`lib/manifest.ts` `parseManifest` instead of ad-hoc `YAML.parse`

### `showcase/shell/src/components/guided-flow.tsx`
- `isGuidedAnswers` runtime type guard on localStorage payload
(validates shape before trusting `JSON.parse` output; prior code did a
blind `as GuidedAnswers` cast)
- `StoredGuidedAnswers` accepts legacy `undefined` `language` from
pre-language-field versions while the in-memory shape stays strict
- `restoredRef` gate preventing persist effect from clobbering restored
data on initial render
- `persistWarnedRef` / `cleanupWarnedRef` warn-once refs for
localStorage diagnostics
- Module-load invariants throw on `FEATURE_OPTIONS`/`LANGUAGE_OPTIONS`
drift from their maps
- `FEATURE_MAP.tools` → `frontend-tools` (was `frontend-tools-sync`
which doesn't exist in the catalog), `FEATURE_MAP.hitl` → `hitl-in-chat`

### `examples/v2/interrupts-langgraph` (new starter)
- `ApprovalResumeSchema` zod validation at resume boundary (prevents
silent fall-through to cancelled)
- `isAIMessage` type predicate replacing unchecked cast
- `shouldContinue` multi-tool-call routing (mixed frontend + backend
batches)
- `bindTools` presence guard replacing non-null `!`
- Production `LANGGRAPH_DEPLOYMENT_URL` fail-fast at module load; dev
warn-fallback
- Production error-detail redaction in POST handler

### Infra
- `lefthook.yml`: `lint-fix` scoped to staged files via `oxlint --fix` /
`oxfmt --write` on `{staged_files}` (guarded against empty expansion),
replacing monorepo-wide `pnpm run lint && pnpm run format` on every
commit
- `showcase/.gitignore`: `**/tsconfig.tsbuildinfo` +
`packages/test-integration-tmp/` (fixture directory leaked by
`create-integration.test.ts` when the suite is killed before cleanup)
- Untracked 6 accidentally-committed `tsconfig.tsbuildinfo` files

## Base

Rebased onto `feat/showcase-ops` (was `main`). Dropped paths that
`feat/showcase-ops` or PR #4112 (`shell-docs` tech-debt) already
addressed differently:

- `showcase/shell/src/app/docs/[[...slug]]/page.tsx` — superseded by the
`shell-docs` split in #4112
- `showcase/shell/src/content/docs/frontend-tools.mdx` /
`human-in-the-loop.mdx` — don't exist on current main
- `showcase/shell/src/data/{constraints,demo-content,registry}.json` —
auto-generated; `feat/showcase-ops` has fresher generation
- `showcase/shell-dojolike/*` — directory deleted upstream

## Test plan

- [x] `pnpm -C showcase/scripts test` — 1095 tests green locally (21
files)
- [x] `pnpm -F @copilotkit/showcase-ops test` — 261 tests green locally
(24 files)
- [x] `pnpm exec oxfmt --check` on all changed files — clean
- [x] `pnpm exec oxlint` on all changed code files — 0 errors
(pre-existing warnings, none new)
- [x] `pnpm exec tsc --noEmit` on `showcase/shell-docs`,
`showcase/scripts`, `showcase/ops` — clean
- [x] YAML sanity: all 26 `.github/workflows/*.yml` parse
- [ ] CI green on PR
@jpr5
jpr5 deleted the feat/bundle-5-showcase-documentation branch April 29, 2026 06:33

This branch was successfully deployed

5 active deployments
Preview – research-canvas — c0ff7a7f Deployed Apr 16, 2026 by vercel[bot]
Preview – docs — c0ff7a7f Deployed Apr 16, 2026 by vercel[bot]
Preview – travel — c0ff7a7f Deployed Apr 16, 2026 by vercel[bot]
Preview – chat-with-your-data — c0ff7a7f Deployed Apr 16, 2026 by vercel[bot]
Preview – form-filling — c0ff7a7f Deployed Apr 16, 2026 by vercel[bot]
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