Addresses code-review findings on the HITL attribution change:
- Correct the render-prop JSDoc: agentId is the tool's STATIC registration
scope (undefined for unscoped tools), not the runtime sub-agent; toolCallId
is the key to correlate with runtime attribution (onToolExecutionStart /
event stream). Removes the over-claim that agentId resumes 'the correct
sub-agent'.
- Compare props.status against the ToolCallStatus enum instead of string
literals (removes silent drift risk).
- Inject name/description/agentId in the otherwise-unreachable fallback branch
so attribution is never silently dropped if a status is ever added; cast
the narrowed-never props to a record so the spread typechecks.
Behavior-preserving for the three live statuses; e2e suite green (13/13).
The HITL render callback received args/status/result but no attribution, so
a UI could not tell which run raised an interrupt — the blocker for rendering
and resuming human-in-the-loop stops that originate from a subagent.
- Add toolCallId (already delivered at runtime via the renderer props spread;
this only surfaces it in the type) and agentId (sourced from the tool's own
registration) to all three ReactHumanInTheLoop render-prop variants.
- Thread agentId through useHumanInTheLoop's enhanced props.
- e2e tests assert both reach the render props through the real CopilotChat
pipeline, and that agentId is undefined for an unscoped tool.
No shared renderer-contract or dispatch changes; no runtime behavior change.
Fire agent turns async so a blocking HITL awaitChoice cannot pause grammy sequential polling (which deadlocked the poll loop and drained the process). Add a bot.catch error boundary so update-processing errors are logged and polling continues. Fold a replied-to message (media + quoted text) into the turn. Decode text-like uploads (CSV/JSON/XML/text) to a text part instead of an unsupported binary file part.
awaitChoice resolved the waiter with evt.value, which platforms whose callback payload cannot carry it (Telegram, 64-byte callback_data) deliver as undefined. The registry now returns the clicked element value from dispatch, and create-bot falls back to it when the event has none. Slack (value-in-payload) is unchanged.
Bring the Slack adapter up to the current native streaming API surface
(chat.startStream/appendStream/stopStream, GA Oct 2025) and remove the
type-erasure workarounds.
- Remove `as unknown as Parameters<...>` casts in favor of the SDK's typed
args (ChatStartStream/AppendStream/StopStream/PostMessage/UpdateArguments).
- Stream a whole turn into ONE message: drop the per-message continuation
splitting (no documented cumulative cap; matches vercel/chat), keeping the
12k per-append chunking.
- Surface tool progress as native in-message `task_update` chunks
(task_display_mode "timeline"), degrading to `🔧` rows where
structured chunks are unavailable.
- Add opt-in AI feedback buttons via `slack({ feedback })` — a typed
context_actions/feedback_buttons row attached at stopStream, with clicks
routed adapter-locally (bypassing the engine's interaction dispatch).
- Scope recipient_user_id/recipient_team_id to channel targets only.
- Lower the native flush floor to ~600ms (appendStream Tier-4), legacy stays
800ms.
Engine: add an optional, backward-compatible RunRenderer.finish() hook called
after runAgentLoop so a turn-scoped renderer can finalize its stream.
Unify WhatsApp with main's Slack+Discord multi-adapter demo: WhatsApp becomes a
third env-gated platform block in examples/slack/app/index.ts (listening on
Railway $PORT, with a malformed-PORT guard). Keep the platform-aware
senderContext (also fixes the Discord 'Slack user' label); drop the superseded
buildAdapters helper for main's inline per-platform pattern. package.json takes
main's ~0.0.2 bumps + bot-discord and adds bot-whatsapp (workspace:~); README
intro + deploy section cover all three surfaces.
Throw when a catalog definition has no matching renderer so createCatalog
satisfies strict check-types under Angular's tsconfig.
Co-authored-by: Cursor <cursoragent@cursor.com>
Modern @a2ui/web_core and @angular/cdk subpath exports require bundler
resolution so angular:check-types can resolve the new A2UI imports.
Co-authored-by: Cursor <cursoragent@cursor.com>
Align surface operation normalization and catalog test fixtures with the
RendererProps contract so the changed A2UI web-components pass tsc.
Co-authored-by: Cursor <cursoragent@cursor.com>
Remove the hand-written types entry from exports["."] so ng-packagr can
generate deterministic published package metadata without warnings.
Co-authored-by: Cursor <cursoragent@cursor.com>
- Implemented audio transcription capabilities with error handling.
- Refactored CopilotChat component to utilize a directive for handling attachments.
- Improved CopilotChatReasoningMessage to manage streaming state and elapsed time more efficiently.
- Added new scroll view component for better message display and auto-scrolling behavior.
- Updated styles for A2UI surface components to enhance layout and scrolling.
- Enhanced tests for OpenGenerativeUIRenderer to ensure proper height measurement.
Apply the common Angular CLI schematics to code which has been added
by Soverius.
We can do a follow-up for the high amount of effects, but we have to be
careful. We need tests first to do a refactoring for that.
## Release monorepo v1.60.2
**Scope:** `monorepo` | **Bump:** `patch`
---
### How this release process works
1. **This PR was created automatically** by the "release / create-pr"
workflow.
It bumped the `monorepo` packages to `1.60.2`
and generated AI-enhanced release notes.
2. **CI runs on this PR** — the full test suite (unit tests, lint, type
checks, build)
must pass before merging. This is the review gate.
3. **Review the release notes** in `release-notes.md` in this PR.
If a Notion draft was created, you can edit the release notes there
before merging.
4. **When this PR is merged**, the `release / publish` workflow
automatically:
- Builds all packages
- Publishes the `monorepo` packages to npm at version `1.60.2`
- Creates git tag `monorepo/v1.60.2`
- Creates a GitHub Release with the final release notes
### Before merging
- [ ] CI is green (tests, lint, types, build)
- [ ] Version bumps look correct
- [ ] Release notes are accurate (edit in Notion if a draft was created)
---
> **Do not merge until CI is fully green.** The full test suite runs
automatically on this PR.
grammY-based adapter implementing the PlatformAdapter interface. Long-polling by default with webhook/auto ingress opt-in. Topic-aware hybrid threading. HTML rendering with a plain-text format fallback, chunked-edit streaming, callback_query HITL, and inbound file ingestion. Ships a built-in Telegram user-lookup tool and platform context, plus a full unit test suite.
- webhook: don't let GET / health shadow the verify handshake when WHATSAPP_PATH=/
- adapters: fail loud on a malformed PORT instead of binding NaN
- tests: cover the id-only senderContext branch, the 404-regression for the
health route, and the PORT guard
- docs: update README senderContext snippets to the 2-arg signature
## Summary
Built-in Agent docs now render at bare root URLs, such as `/quickstart`,
instead of under `/built-in-agent`. Legacy `/built-in-agent/*` and
`/integrations/built-in-agent/*` paths continue to redirect to canonical
root or backend URLs.
## Why
The Built-in Agent is the default docs surface, so public docs URLs
should not expose it as a sub-slug. Existing links still need to keep
working, and root-page navigation must stay stable regardless of a
visitor's stored framework selection.
## How
- Root docs resolve Built-in Agent authored pages first while preserving
reserved routes like `/ag-ui` and framework-prefixed docs.
- Redirect rules in `next.config.ts` and `seo-redirects.ts` point
retired Built-in Agent and unselected paths directly at canonical
destinations, with regression coverage that prevents redirect
destinations from targeting `/built-in-agent`.
- The sidebar/framework provider treats bare URLs as the default
Built-in Agent surface instead of letting a stored framework value
rewrite root-page chrome.
- MDX link and search-result href rewriting strip retired Built-in Agent
prefixes on root-rendered pages while preserving explicit
cross-framework links.
- Stale docs links, sitemap, `llms.txt`, markdown exports, and OG
resolution now align with the root-served Built-in Agent surface.
- Showcase generated-data tests now serialize shared fixture restoration
to avoid concurrent drift in CI.
## Verification
- GitHub checks are green on `f655013dd2576a46dc17b5901eb4dc501cb21028`.
- `npm --prefix showcase/shell-docs run test --
src/lib/__tests__/search-hrefs.test.ts
src/lib/__tests__/docs-link-rewrite.test.ts
src/lib/__tests__/seo-redirects.test.ts
src/lib/__tests__/next-config-redirects.test.ts
src/components/__tests__/docs-landing-next.test.tsx
'src/app/[framework]/[[...slug]]/__tests__/framework-root-shell-layout.test.ts'`
- `npm --prefix showcase/shell-docs run test -- --exclude
src/app/__tests__/public-assets.test.ts`
- `npm --prefix showcase/shell-docs run typecheck`
- `npm --prefix showcase/shell-docs run lint`
- `npm --prefix showcase/shell-docs run build`
- `npm --prefix showcase/scripts run test`
- `pnpm exec nx run @copilotkit/bot-slack:build --skip-nx-cache
--verbose`
Address review: the popout dismiss control was a focusable interactive
element (role="button" + tabindex) rendered INSIDE the floating inspector
<button>. That violates the HTML button content model — a <button> may not
contain interactive descendants or descendants with tabindex, even when the
descendant isn't itself a <button>.
Render the announcement preview as a SIBLING of the floating button inside a
position: relative wrapper, so the dismiss affordance becomes a real
<button type="button">. The wrapper preserves the absolute positioning, so
the bubble still anchors to the button's edge (verified live: identical
placement). Native button keyboard handling replaces the manual Enter/Space
keydown shim. stopPropagation still keeps the X from bubbling to the preview
body (which opens the inspector).
Behavior unchanged and re-verified in a real browser: X persists the
timestamp + hides the bubble without opening the inspector; body-click opens
without persisting. web-inspector suite 32/32 green.
(--no-verify: the full-package pre-commit suite has pre-existing, unrelated
failures in core/runtime/sdk-js transport tests; this change only touches
packages/web-inspector.)
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
The announcement preview bubble that pops out of the floating inspector
button had no dismiss control of its own. Its only hide paths
(handleAnnouncementPreviewClick / openInspector) cleared an in-memory flag
without persisting, so on the next mount fetchAnnouncement() recomputed
showAnnouncementPreview from the stored timestamp — which only the in-window
banner X ever wrote. Result: the popout reappeared on every reload unless the
user opened the inspector and dismissed the inner banner.
Add an X control to the popout that calls markAnnouncementSeen() (persists the
timestamp) and stopPropagation() (so the X does not bubble up and open the
inspector). The control is a role="button" span — the popout renders inside the
floating <button>, so a nested <button> would be invalid HTML. Includes
Enter/Space keyboard support and focus-visible styling.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
- render: walk the real renderToIR tree — read text nodes' `value` and recurse
into nested containers, so card text and buttons inside <Actions> render
(previously produced zero payloads → silent no-send)
- render: value-only buttons (awaitChoice HITL confirm/cancel) now render,
encoding the value in the reply id so the engine's waiter resolves
- adapter: native WhatsApp typing indicator on every inbound (read receipt +
typing_indicator); supportsTyping = true
- ingress: resolve quote-replies — the webhook sends only the quoted message's
id, so look it up in history and prepend its text to the turn
- adapter: record every outbound message (text + cards) in history keyed by its
wamid, so quote-replies to the bot's own messages resolve too
- tests: +9 covering the renderToIR shape, value-only buttons, typing, quote
resolution, and outbound recording (71 total)
## Summary
- Update the default tool-call renderer to use dark-theme-aware classes
for the card, header, status badge, and detail panels
- Add coverage for the dark theme styling path in unit tests
- Add a Storybook example that demonstrates the default tool renderer on
a dark CopilotKit surface
## Testing
- Added unit tests for the renderer’s dark-theme class output and
expanded details state
- Not run (not requested)
## What does this PR do?
Ports the `usePinToSend` spacer fix from #5386 to the Vue package.
`packages/vue/src/v2/hooks/use-pin-to-send.ts` is a documented 1:1
parity port of the React hook and retained the shrink-only
`ResizeObserver`: when content below the anchored user message loses
height (suggestions swapping in, input container resizing after
streaming), the spacer could not grow back, so total scrollable height
dropped and the pinned message shifted — the same defect class reported
in #5355.
- Lets the spacer adjust in both directions so total scrollable space
below the pinned bubble stays constant.
- Mirrors the test change from #5386 1:1 in the Vue suite (red/green:
the updated assertion fails on the shrink-only implementation, passes
with the fix).
- Updates the `PARITY.md` row and hook JSDoc that documented the old
shrink-only semantics.
Vue has no scroll-to-bottom button, so the scroll-listener half of #5386
does not apply here.
## Related PRs and Issues
- Follow-up to #5386
- Relates to #5355 (Vue side of the same spacer defect)
## Tests
- `nx test @copilotkit/vue` — 1001 passed (94 files), including the
mirrored `adjusts spacer as content height changes to keep the user
message pinned` case
- `nx build @copilotkit/vue` — green (dts build)
- `oxfmt --check` clean on touched files
- Pre-existing on main, untouched by this diff: 176 package-wide lint
errors (identical count on clean main) and
`@copilotkit/core:check-types` failures
🤖 Generated with [Claude Code](https://claude.com/claude-code)
## Release bot-slack v0.0.2
**Scope:** `bot-slack` | **Bump:** `patch`
---
### How this release process works
1. **This PR was created automatically** by the "release / create-pr"
workflow.
It bumped the `bot-slack` packages to `0.0.2`
and generated AI-enhanced release notes.
2. **CI runs on this PR** — the full test suite (unit tests, lint, type
checks, build)
must pass before merging. This is the review gate.
3. **Review the release notes** in `release-notes.md` in this PR.
If a Notion draft was created, you can edit the release notes there
before merging.
4. **When this PR is merged**, the `release / publish` workflow
automatically:
- Builds all packages
- Publishes the `bot-slack` packages to npm at version `0.0.2`
- Creates git tag `bot-slack/v0.0.2`
- Creates a GitHub Release with the final release notes
### Before merging
- [ ] CI is green (tests, lint, types, build)
- [ ] Version bumps look correct
- [ ] Release notes are accurate (edit in Notion if a draft was created)
---
> **Do not merge until CI is fully green.** The full test suite runs
automatically on this PR.
## Summary
Convert `useInterrupt::resolve` and the demo-local
`useHeadlessInterrupt::resolve` callbacks from fire-and-forget into
`async` + `return await copilotkit.runAgent(...)`, so callers receive a
Promise that settles when the resume run settles.
## Mechanism
Pre-fix: `resolve(...)` called `copilotkit.runAgent({...})` without
`await` and without `return` — the arrow returned `undefined`. The
showcase harness DOM-settle check on the assistant confirmation bubble
timed out because consumers had no handle to sequence against the resume
run's settle.
Post-fix:
- Framework `useInterrupt::resolve` is `async`, `return await`s
`runAgent`, wraps in try/catch + `setPendingEvent(null)` +
`console.error` + rethrow on rejection.
- `onRunFailed` now also `setPendingEvent(null)` — symmetric with
`onRunStartedEvent`, prevents stuck popups on run failure.
- `InterruptHandlerProps.resolve` / `InterruptRenderProps.resolve` typed
`() => Promise<RunAgentResult>` (was `() => void`).
- The same fix-pattern applied to 13 demo-local `useHeadlessInterrupt`
implementations across integrations: ag2, agno, claude-sdk-typescript,
crewai-crews, langgraph-{fastapi,python,typescript}, langroid,
llamaindex, mastra, pydantic-ai, spring-ai, strands.
## Verification
- **Unit:** new tests `resolve returns a Promise that settles when
runAgent settles (RESUME-PATH)` + `resolve rejects when runAgent
rejects, logs the failure, and clears pending (RESUME-PATH-REJECT)`.
Red-then-green on baseline. 22/22 react-core hook tests passing.
- **Backplane (end-to-end):** showcase control plane on langgraph-python
via `./bin/showcase test langgraph-python:gen-ui-interrupt --d5 --direct
--verbose` (GREEN, 70.1s, was RED-RESUME-PATH baseline) and
`:interrupt-headless --d5 --direct --verbose` (GREEN, 7.7s, was
RED-RESUME-PATH baseline). Built Docker artifact + aimock D6 fixture
replay — staging-equivalent path.
## CR
4 review rounds × 7 unbiased agents = 28 agent-runs. 2 Procedure 3
audits (3 promotions in round 1 → Fix C + D; 0 promotions in round 2).
Convergence achieved per agent-confirmed `bucket (a) empty` + Procedure
3 zero `PROMOTE_TO_A`.
## Out of scope (deferred follow-ups)
- **No manifest unquarantine.** A prior version of this branch flipped
`interrupt-headless` and `gen-ui-interrupt` from
`not_supported_features` to `features` across 12 manifests, but Phase 4
backplane validation across 8 PATCHED integrations × 2 demos surfaced
(a) `langgraph-fastapi:gen-ui-interrupt` still RED-RESUME-PATH because
the framework patch doesn't propagate from workspace to the
integration's Docker image without a published `@copilotkit/react-core`
release, and (b) a separate popup-mount RED-RUNTIME-OTHER cluster across
6 integrations that's pre-existing rot unrelated to this PR. Manifest
unquarantine + `@copilotkit/react-core` version bump are deferred to a
follow-up `copilotkit-release` PR after this fix lands.
- **No version bump.** Release follows in a separate PR.
- **Bucket (c) follow-up backlog** (audit verdicts: 11 STAY_IN_C):
- JSON.parse guarding in showcase demos (pre-existing, all 13)
- Type-design quirks in `InterruptHandlerProps.result` (non-nullable in
type, nullable in runtime)
- `renderInChat` dynamic toggle leak (pre-existing edge case)
- JSDoc clarity ("symmetric with onRunFailed" wording, `@typeParam
TRenderInChat`, `event.value` "any" → "unknown")
- StrictMode test coverage gap
- 13× duplicate `useHeadlessInterrupt` → bucket (d): consolidate into a
shared module in a future PR
## Files changed
16 files, +486/-154:
- `packages/react-core/src/v2/hooks/use-interrupt.tsx`
- `packages/react-core/src/v2/hooks/__tests__/use-interrupt.test.tsx`
- `packages/react-core/src/v2/types/interrupt.ts`
- 13×
`showcase/integrations/<integ>/src/app/demos/interrupt-headless/page.tsx`
## Test plan
- [x] react-core unit tests (22/22 passing including new RESUME-PATH +
RESUME-PATH-REJECT regression tests)
- [x] Backplane D5 probe on langgraph-python (gen-ui-interrupt +
interrupt-headless GREEN end-to-end via the showcase control plane)
- [ ] CI green on this PR
resolve() previously called copilotkit.runAgent(...) without await and
without return, so callers had no handle to sequence against the resume
run's settle. The harness DOM-settle check timed out for any consumer
awaiting the assistant confirmation bubble.
Changes:
- Make resolve async, return await copilotkit.runAgent(...) so callers
receive a Promise that settles when the resume run settles.
- Update InterruptHandlerProps / InterruptRenderProps resolve return
type from () => void to () => Promise<RunAgentResult>.
- Wrap runAgent in try/catch + setPendingEvent(null) + rethrow, so
rejection clears the popup AND propagates to awaiting callers
(mirrors onRunFailed handler symmetry; closes the case where
runAgent rejects before any run-failed event fires, e.g. network
error pre-RUN_STARTED).
- onRunFailed now also setPendingEvent(null) symmetric with
onRunStartedEvent.
- Regression tests: RESUME-PATH asserts resolve() returns a Promise
that settles 1:1 with runAgent; RESUME-PATH-REJECT asserts rejection
propagates, popup clears, console.error logs.
Update package READMEs + ARCHITECTURE for the assistant pane, native streaming,
and the new onThreadStarted / setSuggestedPrompts / setTitle surface. Reverse
the slack.mdx callout that told users to delete the assistant scopes (now
required), and enable the pane in the examples/slack manifest (assistant_view +
assistant:write + assistant_thread_* events) with a dev-ex onThreadStarted
greeting and the assistant config.
Activate Slack's assistant pane and native streaming as the default experience,
with zero config and safe degradation. The portable surface lands in
@copilotkit/bot (onThreadStarted lifecycle, capability-gated
thread.setSuggestedPrompts/setTitle, two SurfaceCapabilities flags + optional
adapter methods); @copilotkit/bot-slack adds the Bolt Assistant middleware
(assistant.ts), the chat.startStream transport with automatic legacy fallback
(native-stream.ts), a per-thread no-double-delivery listener guard, and
renderer pane-status mode. Everything degrades, never throws.