# Role-Specific Message Configuration

The Chat component provides a powerful configuration system that allows you to customize message behavior and appearance differently for author messages (messages from the local user) versus receiver messages (messages from other users) using the [`authorMessageSettings`](https://www.telerik.com/kendo-react-ui-develop/components/conversationalui/api/chatprops#authormessagesettings) and [`receiverMessageSettings`](https://www.telerik.com/kendo-react-ui-develop/components/conversationalui/api/chatprops#receivermessagesettings) properties.

## Configuration Overview

Both `authorMessageSettings` and `receiverMessageSettings` accept a `MessageSettings` object that allows you to override global message settings for each message type independently:

* [`allowMessageCollapse`](https://www.telerik.com/kendo-react-ui-develop/components/conversationalui/chat/messages/appearance#expanding-and-collapsing-messages)
* [`messageWidthMode`](https://www.telerik.com/kendo-react-ui-develop/components/conversationalui/chat/messages/appearance#messages-width)
* [`messageTemplate`](https://www.telerik.com/kendo-react-ui-develop/components/conversationalui/chat/customization/message-templates)
* [`messageContentTemplate`](https://www.telerik.com/kendo-react-ui-develop/components/conversationalui/chat/customization/message-content-templates)
* [`messageToolbarActions`](https://www.telerik.com/kendo-react-ui-develop/components/conversationalui/chat/messages/tools#toolbar-tools)
* [`messageContextMenuActions`](https://www.telerik.com/kendo-react-ui-develop/components/conversationalui/chat/messages/tools#context-menu)
* [`fileActions`](https://www.telerik.com/kendo-react-ui-develop/components/conversationalui/chat/messages/tools#file-actions)
* [`showAvatar`](https://www.telerik.com/kendo-react-ui-develop/components/conversationalui/chat/messages/appearance#avatar-visibility)
* [`showUsername`](https://www.telerik.com/kendo-react-ui-develop/components/conversationalui/chat/messages/appearance#username-visibility)

> When you configure both global settings and role-specific settings, the role-specific settings take precedence.

## AI Assistant Interface Example

The following example demonstrates an AI Assistant interface using role-specific configuration. AI messages use a custom template with full width, while user messages maintain a cleaner standard appearance with toolbar actions:

[Demo Source](https://demos.telerik.com/kendo-react-ui/conversational-ui/chat/messages/role-specific/ai-assistant/source.txt)

## Suggested Links

* [Message Appearance](https://www.telerik.com/kendo-react-ui-develop/components/conversationalui/chat/messages/appearance)
* [Message Templates](https://www.telerik.com/kendo-react-ui-develop/components/conversationalui/chat/customization/message-templates)
* [Message Content Templates](https://www.telerik.com/kendo-react-ui-develop/components/conversationalui/chat/customization/message-content-templates)
* [Chat API Reference](https://www.telerik.com/kendo-react-ui-develop/components/conversationalui/api)
