Repository navigation
Conversation
Core AgentSession has an optional regenerate(messageId), and React Chat offers Regenerate whenever a session supplies it. The LangGraph runtime does; the AG-UI runtime did not, so AG-UI chats had no Regenerate action even though the Angular AG-UI adapter supports it. The plain native owner now has regenerate(messageId, options?) with the Angular adapter's semantics: it finds the root assistant record (or the reasoning record a reasoning-only answer is shown under), keeps history through the user message before it, drops everything after, and sends a run with that history and the current state without adding the prompt again. It rejects without sending after disposal, during a run, while a decision waits, for an id that is not an assistant record, and when no prompt precedes it, matching the core contract. A failed regenerate can be retried from the same trimmed history. createAgentSession forwards it as the core regenerate. The client-tool owner is left without it because its ledger owns the call history, as it is for retry. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
blove
enabled auto-merge
November 18, 2026 01:01
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Core
AgentSessionhas an optionalregenerate(messageId), and ReactChatshows a Regenerate action whenever a session supplies it. The LangGraph runtime supplies it. The AG-UI React runtime did not, so AG-UI chats had no Regenerate action, even though the Angular AG-UI adapter hasregenerate(libs/ag-ui/src/lib/to-agent.ts).createSession(plain native owner) gainsregenerate(messageId, options?)with the Angular adapter's semantics: it finds the root assistant record (or the reasoning record that a reasoning-only answer is shown under, which is the id the core view uses), keeps history through the user message before it, drops everything after, and sends a run with that history and the current state. The prompt is not added again. Regenerating an earlier answer drops every later turn, as in Angular.createAgentSessionforwards it as the coreregenerate, so ReactChatoffers Regenerate for AG-UI sessions.regenerate: its ledger owns the history of the calls it ran, and trimming that history is not supported.retryis absent there for a similar reason.installed-types.tsgains type probes for the new method.Verification
nx run-many -t runtime-quality runtime-type-tests type-tests lint test -p ag-ui: 44 files / 745 tests pass (newregenerate.spec.ts, 9 tests, written first and seen failing), lint has 0 errors.nx run-many -t test lint type-tests -p react: 100 files pass, lint has 0 errors.node --test scripts/react-parity/verify-packages.spec.mjs: 103 pass.ag-ui-candidate-package.spec.mjs: 28 pass.node scripts/react-parity/verify-ag-ui-candidate.mjs:verified-ag-ui-candidateafter building core/content/angular/react,npm ciin deployments/ag-ui-mastra, and a uv env. The first attempt used the shared/tmpPython env and failed withNo module named 'langchain_core', probably because another agent re-synced that env at the same time. It passed with a private env.inventory.mjs --check --drift warn: valid.🤖 Generated with Claude Code