CopilotKit v1.56.5
A patch release on the 1.56 line. No breaking API changes — fixes to the runtime stream converters, reasoning lifecycle, LangGraph wrappers, Express compatibility, and React chat surfaces, plus a new LangGraph state-injection helper and a new memory runner package.
Install
npm install @copilotkit/react-core@1.56.5 @copilotkit/react-ui@1.56.5 @copilotkit/runtime@1.56.5Features
- LangGraph state injection in
@copilotkit/sdk-js—createCopilotkitMiddlewarenow exposes anExposeStateOption(boolean | readonly string[]) that injects selected graph state into the CopilotKit middleware. (#4354)
Runtime fixes (@copilotkit/runtime)
- TanStack converter — stop converting the stream after
RUN_FINISHED. The TanStackchat()engine runs a multi-turn agent loop and callsprocessToolCalls()on frontend-only tools, which produced an unmatchedTOOL_CALL_ENDand tripped the AG-UI verify middleware. (#4476) - TanStack state-tool detection — fall back to
rawContent ?? raw.resultso state-tool results are recognised even when only the legacy field is populated. (a48e9a17) - Reasoning lifecycle — close any open reasoning message on
REASONING_END, and reopen cleanly when a newREASONING_STARTarrives. (18f6c1e2) - Reasoning lifecycle — track
REASONINGmessage-open and run-open state separately to avoid duplicateREASONING_MESSAGE_ENDevents. (7bcd2f81) - LangGraph subagents — default
streamSubgraphstotruein the agent wrapper.@ag-ui/langgraph0.0.31+ flipped the default toundefined, breaking subagent streaming; this restores the previous behaviour while preserving any explicit caller override via nullish coalescing. (#4446) - Express 4/5 compatibility — replace string wildcards with RegExp routes in the Express adapter and switch to
{*splat}syntax for path-to-regexp v8, so the runtime works across Express 4, 4.20+, and 5. (#4447)
SDK fixes (@copilotkit/sdk-js)
- Zod v4 state fields preserved in LangGraph
output_schema— adds azodStatehelper that attaches a~standard.jsonSchema.inputhook to Standard-Schema-compatible schemas. Without it, Zod v4 fields carry only~standard.validate+vendor, so LangGraph'sisStandardJSONSchema()returned false andgetJsonSchemaFromSchemasilently dropped fields from the graph'soutput_schema, which then filtered them out ofSTATE_SNAPSHOTevents. (#4358)
React fixes (@copilotkit/react-core, @copilotkit/react-ui)
- Suggestions on the welcome screen — pills marked
available: "always"now render on the welcome screen when aruntimeUrlis configured, instead of being hidden until the first message. (#4462) - Input overlay observer — re-attach the chat-input overlay observer when leaving the welcome screen, so overlays mount correctly on the first user interaction after welcome. (#4472)
- Image attachments — render image attachments as compact 80×80 thumbnails laid out in a horizontal row above the message text (rather than 300×300 stacked below), aligning with conventional chat UIs. (#4459)
Dependency hygiene
- Bump
@ag-ui/*packages to0.0.53. (#4477) - Deep security sweep across the workspace — 155 advisories down to 3 unfixable transitives (
parse-git-config,elliptic). Includes ~36 new pnpm overrides for resolvable transitives plus storybook/vite/vitest devDep bumps. (868f6b17)
Build / packaging
@copilotkit/a2ui-renderer— remove a redundantprepackscript that was breaking canary publishes withENOENT. (#4467)
Monorepo
- The
@copilotkit/vscode-extensionpackage has been removed from this monorepo and migrated to its own repository at CopilotKit/vscode-extension. (#4335)
Packages republished at 1.56.5
@copilotkit/runtime, @copilotkit/react-core, @copilotkit/react-ui, @copilotkit/core, @copilotkit/shared, @copilotkit/runtime-client-gql, @copilotkit/sdk-js, @copilotkit/voice, @copilotkit/web-inspector, @copilotkit/a2ui-renderer, @copilotkit/react-textarea, and @copilotkit/sqlite-runner.