New to Kendo UI for AngularStart a free 30-day trial

AIPromptComponent

Represents the Kendo UI AIPrompt component for Angular.

html
<kendo-aiprompt
  [promptCommands]="commands"
  [promptSuggestions]="suggestions"
  [promptOutputs]="outputs"
  [showOutputRating]="true"
  (promptRequest)="onPromptRequest($event)">
</kendo-aiprompt>

Selector

kendo-aiprompt

Export Name

Accessible in templates as #kendoAIPromptInstance="kendoAIPrompt"

Inputs

NameTypeDefaultDescription

activeView

number

The active view index of the AIPrompt component.

promptCommands

PromptCommand[]

Sets the collection of commands to render in the Command view.

promptOutputs

PromptOutput[]

Sets the collection of generated prompt outputs to render in the Output view.

promptSuggestions

string[]

Sets the collection of suggestions to render in the Prompt view.

showOutputRating

boolean

false

Specifies if the rating buttons appear in each Output view card. By default, the rating buttons do not appear.

Events

NameTypeDescription

activeViewChange

EventEmitter<number>

Fires when the activeView property is updated. Use this event for two-way binding of the activeView property.

commandExecute

EventEmitter<CommandExecuteEvent>

Fires when the user clicks a Command view command. The event data contains the selected command.

outputCopy

EventEmitter<PromptOutput>

Fires when the user clicks a Copy button in any Output view card.

outputRatingChange

EventEmitter<OutputRatingChangeEvent>

Fires when the user clicks a rating button in any Output view card.

promptRequest

EventEmitter<PromptRequestEvent>

Fires when the user clicks the Generate button in the Prompt view or the Retry button in the Output view. Use the event's isRetry field to determine the source element.

Methods

focus

Focuses the first focusable element in the AIPrompt component.

In this article
SelectorExport NameInputsEventsMethods
Not finding the help you need?
Contact Support