InMemoryChatHistoryProviderOptions Class
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Represents configuration options for InMemoryChatHistoryProvider.
public sealed class InMemoryChatHistoryProviderOptions
type InMemoryChatHistoryProviderOptions = class
Public NotInheritable Class InMemoryChatHistoryProviderOptions
- Inheritance
-
InMemoryChatHistoryProviderOptions
Constructors
| Name | Description |
|---|---|
| InMemoryChatHistoryProviderOptions() | |
Properties
| Name | Description |
|---|---|
| ChatReducer |
Gets or sets an optional IChatReducer instance used to process, reduce, or optimize chat messages. This can be used to implement strategies like message summarization, truncation, or cleanup. |
| JsonSerializerOptions |
Gets or sets optional JSON serializer options for serializing the state of this provider. This is valuable for cases like when the chat history contains custom AIContent types and source generated serializers are required, or Native AOT / Trimming is required. |
| ProvideOutputMessageFilter |
Gets or sets an optional filter function applied to messages produced by this provider during InvokingAsync(ChatHistoryProvider+InvokingContext, CancellationToken). |
| ReducerTriggerEvent |
Gets or sets when the message reducer should be invoked. The default is BeforeMessagesRetrieval, which applies reduction logic when messages are retrieved for agent consumption. |
| StateInitializer |
Gets or sets an optional delegate that initializes the provider state on the first invocation.
If |
| StateKey |
Gets or sets an optional key to use for storing the state in the StateBag.
If |
| StorageInputRequestMessageFilter |
Gets or sets an optional filter function applied to request messages before they are added to storage during InvokedAsync(ChatHistoryProvider+InvokedContext, CancellationToken). |
| StorageInputResponseMessageFilter |
Gets or sets an optional filter function applied to response messages before they are added to storage during InvokedAsync(ChatHistoryProvider+InvokedContext, CancellationToken). |