.NET Workflows - Capture the identifier of the LastMessage (the workflow input) (#1372)

* Fixed

* Test fix
This commit is contained in:
Chris
2025-10-10 06:45:09 +00:00
committed by GitHub
parent 2c9cf6f59d
commit 7e1fd67e76
8 changed files with 99 additions and 9 deletions
@@ -67,8 +67,8 @@ public abstract class RootExecutor<TInput> : Executor<TInput>, IResettableExecut
}
await declarativeContext.QueueConversationUpdateAsync(this._conversationId, isExternal: true, cancellationToken).ConfigureAwait(false);
await this._agentProvider.CreateMessageAsync(this._conversationId, input, cancellationToken).ConfigureAwait(false);
await declarativeContext.SetLastMessageAsync(input).ConfigureAwait(false);
ChatMessage inputMessage = await this._agentProvider.CreateMessageAsync(this._conversationId, input, cancellationToken).ConfigureAwait(false);
await declarativeContext.SetLastMessageAsync(inputMessage).ConfigureAwait(false);
await declarativeContext.SendResultMessageAsync(this.Id, cancellationToken).ConfigureAwait(false);
}