Skip to main content

Where It Fits

CometChatAIAssistantChatHistory is a pre-built user interface widget designed to display the conversation history between users and an AI assistant within a chat application. It provides a structured and visually appealing way to present past interactions, making it easy for users to review previous messages and context.

Minimal Render

The simplest way to render CometChatAIAssistantChatHistory:
Simply adding the CometChatAIAssistantChatHistory component to the layout will only display the loading indicator. To fetch messages for a specific entity, you need to supplement it with User or Group Object.
You can also launch it using Navigator:
Or embed it as a widget:

Filtering

You can adjust the MessagesRequestBuilder to customize the message list. Numerous options are available to alter the builder to meet your specific needs.
The following parameters in messageRequestBuilder will always be altered inside the list:
  1. UID
  2. GUID
  3. types
  4. categories
For additional details on MessagesRequestBuilder, please visit MessagesRequestBuilder.

Actions and Events

Callback Props

Component-level callbacks that fire on specific user interactions:

Global UI Events

The CometChatAIAssistantChatHistory component does not produce any global UI events.

Custom View Slots

Customize the appearance of CometChatAIAssistantChatHistory by replacing default views with your own widgets.

Example: Custom Back Button

Example: Custom Loading State

Example: Custom Empty State

Date Separator Pattern

You can modify the date pattern of the chat history date separator using dateSeparatorPattern:

Styling

Customize the appearance of CometChatAIAssistantChatHistory using CometChatAIAssistantChatHistoryStyle.

Style Properties

Props Reference

Message List

Display messages in a conversation

Message Composer

Compose and send messages

Theming

Learn how to customize the look and feel

Localization

Support multiple languages in your app