Partager via


ChatHistory.Remove(ChatMessageContent) Method

Definition

Removes the first occurrence of the specified message from the history.

public bool Remove (Microsoft.SemanticKernel.ChatMessageContent item);
abstract member Remove : Microsoft.SemanticKernel.ChatMessageContent -> bool
override this.Remove : Microsoft.SemanticKernel.ChatMessageContent -> bool
Public Function Remove (item As ChatMessageContent) As Boolean

Parameters

item
ChatMessageContent

The message to remove from the history.

Returns

true if the item was successfully removed; false if it wasn't located in the history.

Implements

Exceptions

item is null.

Applies to