ChatMemory

A feature that allows storing and loading conversation history between an agent and a user.

ChatMemory enables agents to persist and retrieve past conversations, allowing for continuity across multiple agent sessions.

Example usage:

val agent = AIAgent(...) {
installChatMemory {
chatHistoryProvider = MyChatHistoryProvider()
}
}

Example with a sliding window to limit the number of stored messages:

val agent = AIAgent(...) {
installChatMemory {
chatHistoryProvider = MyChatHistoryProvider()
windowSize(20) // keep only the last 20 messages
}
}

Constructors

Link copied to clipboard
constructor()

Types

Link copied to clipboard

Companion object implementing agent feature, handling ChatMemory creation and installation.