# Pre-built UI Prefabs

We provide several UI options to display character and user's transcript out of the box that players can use with the Convai Plugin. You can use and customize these prefabs.&#x20;

The ConvaiNPC and ConvaiGRPCAPI scripts look for GameObjects with Convai Chat UI Handler as a component, and send any transcripts to the script so that it can be displayed on screen.

## Types of UI

<figure><img src="https://413558230-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FEtUJA212Zc1S9ACc8T4l%2Fuploads%2FXfzLV1d0XyU0Grnqa2l2%2Fimage.png?alt=media&#x26;token=4bc187f0-8f9f-4945-8351-444780395081" alt=""><figcaption></figcaption></figure>

### ChatBox

**Prefab Name**: Convai Transcript Canvas - Chat

Both the user's and the character's transcripts are displayed one after other in a scrollable chat box.

<figure><img src="https://413558230-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FEtUJA212Zc1S9ACc8T4l%2Fuploads%2F0Zk1wAnyf5RXQWUC29yT%2Fimage.png?alt=media&#x26;token=42eaba3e-777f-4bff-97cb-255670042ac7" alt=""><figcaption></figcaption></figure>

### Subtitle

**Prefab Name**: Convai Transcript Canvas - Subtitle

The user and character transcripts are displayed in the bottom like subtitles.

<figure><img src="https://413558230-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FEtUJA212Zc1S9ACc8T4l%2Fuploads%2FvIdkJSh5EIAJexSXdPoW%2Fimage.png?alt=media&#x26;token=fe410464-b8c1-4b3b-8cf2-07db5427fc02" alt=""><figcaption></figcaption></figure>

### Question-Answer

**Prefab Name**: Convai Transcript Canvas - QA

The user's transcript is displayed in the top where as the character's transcript is displayed in the bottom.

<figure><img src="https://413558230-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FEtUJA212Zc1S9ACc8T4l%2Fuploads%2FTjDt3LxsA5SrDx6ve9oc%2Fimage.png?alt=media&#x26;token=dede99ef-3f54-4e6e-8867-3d0c1e9cee85" alt=""><figcaption></figcaption></figure>

### Mobile Optimised UI Styles

**Prefab Name**: Convai Transcript Canvas - Mobile Subtitle

Identical to [#subtitle](#subtitle "mention") UI. Includes a button that can be pressed and held for the user to speak. Ideal for portrait orientation of screen.

<figure><img src="https://413558230-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FEtUJA212Zc1S9ACc8T4l%2Fuploads%2FLgCKLMFp4GgiUSdozGCK%2Fimage.png?alt=media&#x26;token=6a706b9b-8996-4c2b-ba2d-00424556cef5" alt="" width="328"><figcaption></figcaption></figure>

**Prefab Name**: Convai Transcript Canvas - Mobile QA

<figure><img src="https://413558230-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FEtUJA212Zc1S9ACc8T4l%2Fuploads%2FjONNuodDLgthlr71LxkY%2Fimage.png?alt=media&#x26;token=0b8508a2-e217-48e4-a6ab-3452b7770c9c" alt="" width="331"><figcaption></figcaption></figure>

**Prefab Name**: Convai Transcript Canvas - Mobile Chat

<figure><img src="https://413558230-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FEtUJA212Zc1S9ACc8T4l%2Fuploads%2FpqxJrTapBuD10nH5IkG5%2Fimage.png?alt=media&#x26;token=1e6f74cf-76c6-4a9c-8a7e-e7eb7fcace37" alt="" width="327"><figcaption></figcaption></figure>

## [Convai Chat UI Handler Component](https://docs.convai.com/api-docs/plugins-and-integrations/unity-plugin/utilities/transcript-ui-system)

<figure><img src="https://413558230-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FEtUJA212Zc1S9ACc8T4l%2Fuploads%2FeSFdCu4aXPAINsalZULd%2Fimage%202.png?alt=media&#x26;token=3cd13959-3b74-4f9c-bb65-60ce7b946fb5" alt=""><figcaption></figcaption></figure>

### Functions to Know

<table><thead><tr><th width="265"></th><th></th></tr></thead><tbody><tr><td>SendCharacterText</td><td>A public function that sends a string of text to be displayed  as character transcript along with the name of the character who said it. </td></tr><tr><td>SendUserText</td><td>A public function that sends a string of text to be displayed  as user transcript.</td></tr></tbody></table>
