Commit Graph

797 Commits

Author SHA1 Message Date
Jordan Ritter 2769cff509 fix(showcase): bump @ag-ui/client to 0.0.48 on reasoning-emitting backends
llamaindex, agno, and claude-sdk-python emit AG-UI REASONING_MESSAGE_*
events but pinned @ag-ui/client ^0.0.43, whose @ag-ui/core discriminated
union lacks the REASONING_MESSAGE_* variants — the frontend threw
invalid_union_discriminator and the reasoning demo broke. Pin all three
to exact 0.0.48 (matching the claude-sdk-typescript fix in #5323),
regenerate their lockfiles so @ag-ui/core resolves to 0.0.48 with zero
0.0.43 nodes, and ratchet the validate-pins drift baseline down from 60
to 57 to reflect the now-exact pins. Verified locally on the built-image
showcase rig: D5 green and the D6 reasoning-display probe passes for all
three backends with zero invalid_union_discriminator.
2026-06-08 12:56:52 -07:00
github-actions[bot] 9e668797a4 style: auto-fix formatting 2026-06-08 11:15:14 -07:00
Jordan Ritter d865bfcc03 docs(showcase): document genuine reasoning SDK limitations + correct reasoning demo docs 2026-06-08 11:15:13 -07:00
Jordan Ritter 4875150001 fix(showcase): rename reasoning demo ids + restore probe coverage 2026-06-08 11:15:13 -07:00
Jordan Ritter d445b19642 fix(showcase): forward valid AG-UI reasoning role on claude-sdk-typescript (+@ag-ui/client 0.0.48) 2026-06-08 11:15:12 -07:00
Jordan Ritter f425077ea7 fix(showcase): emit reasoning via OpenAI Responses API on llamaindex 2026-06-08 11:12:57 -07:00
Jordan Ritter 73bfaeac29 fix(showcase): emit reasoning via chat-completions adapter on built-in-agent 2026-06-08 11:12:57 -07:00
Jordan Ritter 71df4222fe fix(showcase): emit native reasoning_content on agno reasoning handler 2026-06-08 11:12:57 -07:00
Jordan Ritter 8ae72bd2c7 fix(showcase): emit native reasoning (REASONING_MESSAGE_*) on claude-sdk-python reasoning agents 2026-06-08 11:12:57 -07:00
Ran Shem Tov c85c140f05 feat: update all dependencies to use latest a2ui implementation features 2026-06-08 12:09:20 +02:00
github-actions[bot] c023a03fac style: auto-fix formatting 2026-06-08 05:23:16 +00:00
Jordan Ritter b284d89615 fix(built-in-agent): pin @copilotkit/runtime 1.59.4 + tanstack; remove obsolete SSOT override 2026-06-07 22:19:51 -07:00
Jordan Ritter fe3af73086 fix(mastra): gen-a2ui throw + role normalizer + cmdk bump; probe-YAML comment fixes; dashboard validateCell tag enforcement 2026-06-07 22:19:47 -07:00
Jordan Ritter 54e426c2dd fix(spring-ai): controller error-path lifecycle (RUN_STARTED ordering, finalize) 2026-06-07 22:19:41 -07:00
Jordan Ritter e89581d12c fix(ms-agent-dotnet): A2uiSecondaryToolCaller fail-loud + error mapping + guards 2026-06-07 22:19:30 -07:00
Jordan Ritter 154c1cfab1 fix(showcase): harden header-forwarding shims (fail-loud, async-detect) across python integrations 2026-06-07 22:19:26 -07:00
Jordan Ritter f0fe456a43 fix(agno): HITL tool-pairing, reasoning RUN_ERROR/TOOL_CALL_RESULT, reasoning route wiring, uvloop loop-pin for header forwarding 2026-06-07 22:19:19 -07:00
Jordan Ritter ca2bc2c152 fix(showcase): specialize strands + spring-ai declarative-hashbrown/json-render backends (+ fixtures, manifests, controller guards) 2026-06-07 13:53:28 -07:00
Jordan Ritter 8d9dc82606 fix(showcase): render beautiful-chat chart/scheduler generative-UI on built-in-agent and claude-sdk-python 2026-06-07 13:53:19 -07:00
Jordan Ritter ffa51c7ee8 chore(showcase): remove the temporary x-diag-probe instrumentation 2026-06-07 13:53:07 -07:00
github-actions[bot] b4b5f10d55 style: auto-fix formatting 2026-06-07 17:04:33 +00:00
Jordan Ritter 94f564a0f8 fix(showcase): align mastra to ai SDK v5 for the gen-a2ui secondary call 2026-06-07 10:00:40 -07:00
Jordan Ritter 6e34ea836e fix(showcase): pydantic-ai gen-ui forwards the real conversation to its secondary call 2026-06-07 10:00:40 -07:00
Jordan Ritter 4920128332 fix(showcase): forward x-aimock-context across the AG-UI SSE-pump boundary in ms-agent-dotnet 2026-06-07 10:00:35 -07:00
Jordan Ritter e1cf704e13 fix(showcase): propagate x-aimock-context to off-thread gen-ui secondary call across Python backends 2026-06-07 10:00:29 -07:00
Jordan Ritter 46e66d8d4b fix(showcase): add missing per-pill copilotkit routes for agno/langroid/llamaindex/spring-ai/strands 2026-06-07 10:00:24 -07:00
github-actions[bot] c73afd1e3d style: auto-fix formatting 2026-06-06 19:26:25 +00:00
Jordan Ritter 469d79b029 diag(showcase): ungated x-diag-probe (thread+ctx) on outbound LLM calls to localize native-tool context loss 2026-06-06 12:24:44 -07:00
github-actions[bot] 1e5a9b77cd style: auto-fix formatting 2026-06-06 17:44:07 +00:00
Jordan Ritter bd77954ab5 feat(showcase): instrument per-framework x-aimock-context forwarding with gated CVDIAG breadcrumb
Add CVDIAG logging + x-diag-hops breadcrumb (route-<fw>/backend-<fw>) at each forwarding hop across LangGraph (py/ts/fastapi), google-adk, the self-contained Node + Python shims, spring-ai (Java) and ms-agent (.NET). Breadcrumb append is gated on diagnostic-header presence so non-diagnostic traffic stays byte-identical; surfaces previously-silent forwarding misses (empty configurable, missing httpx event-hooks target, swallowed hook-install errors).
2026-06-06 10:40:25 -07:00
Jordan Ritter 5240ba813c fix(showcase): quarantine gen-ui-interrupt/interrupt-headless pills via not_supported_features
Move gen-ui-interrupt + interrupt-headless from features: to
not_supported_features: across affected integration manifests, and align
the generate-registry/generate-catalog scripts tests to the resulting
wired-feature counts (derive expected lengths from the parsed manifest
rather than hardcoding pre-quarantine numbers).
2026-06-06 02:30:26 -07:00
Jordan Ritter 0cbc990e42 fix(showcase): forward x-aimock-context on all built-in-agent demo routes 2026-06-06 02:30:17 -07:00
Jordan Ritter 5c72d1addd fix(showcase): propagate x-aimock-context across AG-UI SDK pooled-thread hop in spring-ai 2026-06-06 02:30:13 -07:00
github-actions[bot] 83404f8ca5 style: auto-fix formatting 2026-06-05 15:54:58 +00:00
Ran Shem Tov efd35f0f8d chore: align all a2ui instances with the latest implementations 2026-06-05 17:54:16 +02:00
Ran Shem Tov 20aa327a8c fix(showcase): enable injectA2UITool for langgraph-python declarative-gen-ui
It was left at false while fastapi/typescript are true. Under the opt-in
A2UI model false means no tool is injected, so the python demo rendered
no surfaces (and the docs code-tab showed no injectA2UITool). Set true to
match the other langgraph integrations.
2026-06-05 11:25:23 +02:00
Ran Shem Tov f64bba25e4 chore(showcase): move canonical @copilotkit version to 1.59.4
Bump canonicalCopilotKitVersion 1.59.2 -> 1.59.4 and pin every
integration's @copilotkit/* to 1.59.4 (locks regenerated). Keeps the
whole showcase on one version instead of letting the langgraph A2UI
demos deviate. Existing per-slug overrides (built-in-agent pkg.pr.new,
ms-agent-harness-dotnet 1.57.2) unchanged.
2026-06-04 20:50:18 +02:00
Ran Shem Tov 57f1f99faa chore(showcase): pin langgraph integrations to stable releases
copilotkit 0.1.94a3->0.1.94 (py), @copilotkit/* 1.59.2->1.59.4 +
sdk-js alpha.3->1.59.4 (ts). Drop the @ag-ui/langgraph override —
runtime 1.59.4 now carries @ag-ui/a2ui-middleware 0.0.6 (the
injectA2UITool forward) + @ag-ui/langgraph 0.0.37. Locks regenerated.
2026-06-04 20:25:25 +02:00
Ran Shemtov 37577a20c1 Merge branch 'main' into feat/copilotkit-middleware-auto-a2ui 2026-06-04 19:16:50 +02:00
Ran Shem Tov 59cbce0301 fix(showcase): sync langgraph locks to @ag-ui/langgraph 0.0.37 + rebaseline pins
- Regenerate fastapi/typescript/ts-agent package-lock.json so npm ci
  matches package.json (@ag-ui/langgraph 0.0.37); fixes build-check.
- Bump validate-pins fail-baseline hash for the langgraph-fastapi
  ag-ui-langgraph >=0.0.38 floor (count unchanged at 63).
2026-06-04 18:53:48 +02:00
Mark 84cdb702d2 Merge branch 'main' into tyler/confident-meitner-019a9f 2026-06-04 09:50:18 -07:00
Ran Shem Tov 3ca0f194b8 feat(sdk): gate auto-A2UI injection on injectA2UITool (opt-in)
The A2UI middleware (@ag-ui/a2ui-middleware) forwards injectA2UITool on
forwardedProps; ag-ui-langgraph surfaces it into agent state at
state["ag-ui"]["inject_a2ui_tool"]. The CopilotKit LangGraph middleware
(py + js) now reads that flag and only injects generate_a2ui when it is
truthy (opt-in), drops the runtime's render_a2ui so the model sees one
A2UI tool, and skips if the agent already defines generate_a2ui. The
catalog only binds surfaces; it is no longer the gate.

Reverts the earlier runtime-forward + context-channel approach.

Deps: ag-ui-langgraph>=0.0.38 (py), @ag-ui/langgraph 0.0.37 (sdk-js),
@ag-ui/a2ui-middleware 0.0.6 + @ag-ui/langgraph 0.0.37 (runtime);
.npmrc min-release-age exclude for @ag-ui/a2ui-middleware. Showcase
langgraph pins bumped to copilotkit==0.1.94a3 / sdk-js 1.59.3-alpha.3 /
@ag-ui/langgraph 0.0.37.
2026-06-04 18:37:03 +02:00
Ran Shem Tov 02b11c985d feat(showcase): drive dynamic A2UI via CopilotKitMiddleware (langgraph)
The declarative-gen-ui demo across the three langgraph integrations now
relies on the middleware to inject and execute generate_a2ui — the agents
collapse to create_agent + CopilotKitMiddleware with no hand-rolled tool.
Adds render_a2ui fixtures for the new tool path and pins the integrations
to the A2UI alpha SDKs (copilotkit 0.1.94a1, @copilotkit/sdk-js 1.59.3-alpha.1).
2026-06-04 18:36:12 +02:00
Jordan Ritter 92726458a2 fix(showcase): make Railway promote flow fault-tolerant (#5200)
## Summary

The showcase Railway promote CI flow could not promote the fleet: an
`all` promote was blocked end-to-end whenever a single service was red,
and the reported failure traced to `showcase-ag2` being chronically red
on staging.

Root causes and fixes:

- **ag2 crash-on-import (the red service).** `gen_ui_agent.py` carried
`from __future__ import annotations`, which stringified the `set_steps`
tool's `context_variables: ContextVariables` parameter into an
unresolved `ForwardRef`. AG2's tool-schema generation then raised
`PydanticUserError` at import time, so the process never came up and the
staging healthcheck failed on every deploy since 2026-05-31. Removed the
import (matching the working sibling agents) and added a regression test
that statically asserts the future-import stays absent
(version-independent) plus a live import check.

- **Promote loop was all-or-nothing.** The per-service loop ran under
`set -euo pipefail`, so the first failing service aborted the whole
`all` promote, leaving the rest unpromoted. Extracted the loop into
`showcase/scripts/promote-fleet.sh`, which attempts every service,
accumulates succeeded/failed sets, exits non-zero only after attempting
all, and exports `succeeded_csv`.

- **`verify-prod` defeated the best-effort design.** It was skipped on
any non-zero promote and verified the full requested set. It now runs
`if: !cancelled()` and scopes `--services` to the succeeded set.

- **Staging precondition blocked the fleet.**
`verify-staging-precondition` failed the whole `all` promote when any
one service was staging-red. It is now advisory — `promote` runs
regardless, and `bin/railway`'s per-service P2/P3 staging-green gates
authoritatively refuse red services while green services promote.
`notify` success keys on PROMOTE && PROD.

- **Regression tests now gate in CI.** Added a `shell-script-tests` job
(bats + shellcheck) to `showcase_validate.yml`, plus input-validation
hardening in the script (fail-loud on empty / all-empty CSV,
`RAILWAY_BIN` executability check, whitespace trim).

## Test plan

- [x] ag2 regression test passes in the 3.12 venv (`PYTHONPATH=".:src"
pytest tests/python/`) — 2/2
- [x] `promote-fleet.bats` — 12/12 (best-effort loop, succeeded_csv
export, empty/whitespace/missing-binary guards, digest forwarding)
- [x] `shellcheck promote-fleet.sh` clean; `actionlint` clean on both
workflows
- [ ] CI green on this PR
2026-06-03 22:26:20 -07:00
Jordan Ritter 2cacf48ec0 fix(showcase): migrate dead useInterrupt to useHumanInTheLoop for Strategy-B gen-ui-interrupt demos
The gen-ui-interrupt demo across non-LangGraph integrations used
`useInterrupt`, which only renders in response to an AG-UI `on_interrupt`
event emitted by LangGraph's native `interrupt()` primitive. These
backends never emit that event — they expose `schedule_meeting` as a
frontend/HITL tool over the normal tool-call channel (Strategy B) — so
the picker never mounted.

Migrate the 8 clean Strategy-B integrations (ag2, agno, crewai-crews,
mastra, pydantic-ai, spring-ai, llamaindex, claude-sdk-typescript) to
`useHumanInTheLoop`, mirroring the ms-agent-python / ms-agent-dotnet
reference: same `name: "schedule_meeting"`, same zod `{ topic, attendee }`
parameters, same TimePickerCard render, resolving via `respond(...)`.
The framework-specific comment is generalized for accuracy.

The 3 LangGraph integrations keep `useInterrupt` (native interrupt).
built-in-agent and claude-sdk-python already use the equivalent working
`useFrontendTool` pattern and are left unchanged. strands and langroid
are intentionally NOT migrated — their backends declare a
`schedule_meeting(reason)` tool whose param shape conflicts with the
`topic`/`attendee` reference, which needs separate resolution.
2026-06-03 16:38:57 -07:00
Jordan Ritter 0cf30cc030 fix(showcase): resolve ag2 gen_ui_agent crash-on-import from stringified forward-ref
`from __future__ import annotations` turned the set_steps tool's
`context_variables: ContextVariables` param into an unresolved ForwardRef at
AG2 tool-schema-generation time, raising PydanticUserError on import and failing
the showcase-ag2 staging healthcheck since 2026-05-31. Removing it matches the
working sibling agents. Adds a regression test that statically asserts the
future-import stays absent (version-independent) plus a live import check.
2026-06-03 14:01:09 -07:00
Jordan Ritter 72156dbb83 fix(showcase): bump @ag-ui/langgraph to 0.0.36 in langgraph integrations
Carries ag-ui PR #1784 (skip regeneration check when command.resume is
set) into the three langgraph showcase stacks. ag-ui 0.0.35 incorrectly
ran the regenerate path on a resumed run, breaking the gen-ui-interrupt
D6 cell. 0.0.36 adds the command.resume guard.

Pins @ag-ui/langgraph 0.0.36 via npm overrides (transitive dep of
@copilotkit/runtime) in langgraph-python, langgraph-typescript, and
langgraph-fastapi, and regenerates each per-integration package-lock.json.
2026-06-02 15:17:41 -07:00
Tyler Slaton 3486944356 fix(showcase): controlled gen-UI — reliable 2nd-suggestion render + sidebar tag (OSS-137) (#5029)
## What & why


[OSS-137](https://linear.app/copilotkit/issue/OSS-137/controlled-gen-ui-demo-optimize-2nd-suggestion-prompt-rename-sidebar)
— the **Controlled Generative UI** demo (`gen-ui-tool-based`) had two
issues, scoped here to **LangGraph-Python** and **Google ADK** (per the
ticket; other 16 integrations roll out later).

### 1. 2nd suggestion didn't reliably render UI
The "Traffic pie chart" chip (`"Show me a pie chart of website traffic
by source."`) names a subject but supplies no numbers, so the agent
**asked the user for data** instead of rendering a chart.

**Fix:** a system-prompt directive (both LGP + ADK agents) instructing
the agent to invent plausible illustrative sample values, call
`render_*` immediately, and **never** reply with a clarifying question.
The suggestion copy stays clean — behavior is carried by the system
prompt, not by leaking "(use sample data)" hints into the UI.

### 2. Sidebar tag → product language
Retagged the demo from `generative-ui` → `controlled-generative-ui` (LGP
+ ADK), so the dojo sidebar pill reads **"Controlled Generative UI"** —
the established taxonomy already used in `shared/feature-registry.json`
and the dashboard catalog.

## Tests
Added D5 aimock fixture entries mirroring all three suggestion chips
(bar / traffic-pie / market-share) so the suggestion-click path has
deterministic coverage. The existing `"revenue by category"` probe
message is **preserved**, so the
[dashboard](https://dashboard.showcase.copilotkit.ai/#matrix:links,health)
D5 row for the edited row stays green.

## Acceptance check
- [x] 2nd suggestion renders UI without asking for data (system-prompt
directive; verified locally against the live agent)
- [x] Sidebar entry tagged "Controlled Generative UI"
- [x] Sample/hallucinated data supplied via system prompt
- [x] Scoped to LGP + ADK
- [x] Tests augmented (D5 fixtures for every chip)
- [x] D5 still shown for the edited row (probe message unchanged)

## Out of scope (left out deliberately)
`package-lock.json` churn from a local reinstall (un-pins `latest`) was
**not** committed.

🤖 Generated with [Claude Code](https://claude.com/claude-code)
2026-06-02 11:31:17 -07:00
Jordan Ritter b96660b7ab test(showcase): complete LGP spec parity for 9 baseline integrations (#5141)
## Summary

Adds the 5 missing LGP-canonical e2e specs to each of the 9 baseline
integrations and removes 2 orphan specs that point at zero-file demos.

- Adds 5 canonical e2e specs (`declarative-hashbrown`,
`declarative-json-render`, `reasoning-custom`, `reasoning-default`,
`threadid-frontend-tool-roundtrip`) to each of the 9 baseline
integrations (`ag2`, `agno`, `crewai-crews`, `langgraph-fastapi`,
`langroid`, `llamaindex`, `mastra`, `spring-ai`, `strands`) — 45 specs
total, **byte-identical** to the `langgraph-python` canonical gold
source. The matching demos already existed from #5127's page-mirror, but
the specs themselves were never copied across.
- Deletes 2 orphan specs that reference demos with zero backing files:
`shared-state-write` (×9) and `reasoning-default-render` (×8).
- `validate-parity.ts` reports **19 pass / 0 fail**. The other 15
frameworks were already clean.
- Note: `claude-sdk-python` has the same orphan-spec condition and is
left for a future sweep (out of scope here).

## Test plan

- [x] Parity validator (`validate-parity.ts`) green: 19/0.
- [ ] Real signal: the added cells running green in a clean staging d6
run.
2026-05-31 21:38:29 -07:00
Jordan Ritter 4dc8d465d4 fix(showcase): bake LANGGRAPH_HTTP configurable_headers into langgraph.json
Move the required, uniform D6 header-conveyance config on-disk so it rides
image promotion instead of depending on a per-environment env var. Prod was
missing the LANGGRAPH_HTTP configurable_headers env var, and baking the
`http.configurable_headers.include: ["x-*"]` setting directly into the
langgraph-python and langgraph-fastapi langgraph.json files removes the
promote-time drift gap (the config now travels with the image rather than
being re-supplied at each promotion).

langgraph-typescript needs no change — its header conveyance is pure-code.
2026-05-31 20:33:45 -07:00