Defines the fluent API for configuring the Kendo InlineAIPrompt for ASP.NET MVC.
Definition
Namespace:Kendo.Mvc.UI.Fluent
Assembly:Kendo.Mvc.dll
Syntax:
public class InlineAIPromptBuilder : WidgetBuilderBase<InlineAIPrompt, InlineAIPromptBuilder>, IHtmlString
Inheritance: objectWidgetBuilderBase<InlineAIPrompt, InlineAIPromptBuilder>InlineAIPromptBuilder
Implements:
Inherited Members
Constructors
Initializes a new instance of the InlineAIPrompt class.
public InlineAIPromptBuilder(InlineAIPrompt component)
The component.
Methods
Defines the commands for the AI tool. The commands are displayed in the AI tool dropdown.
public InlineAIPromptBuilder Commands(Action<EditorAISettingsCommandFactory> configurator)
The configurator for the commands setting.
Returns:The InlineAIPromptBuilder instance for fluent API chaining.
Specifies whether the underlying TextArea widget will be disabled or not.
public InlineAIPromptBuilder Enable(bool value)
The value that configures the enable.
Returns:Specifies whether the prompt outputs are HTML-encoded before being displayed in the output view. When set to true (default), the output is encoded and displayed as plain text, preventing any HTML formatting or scripts from being rendered.
public InlineAIPromptBuilder EncodedPromptOutputs(bool value)
The value that configures the encodedpromptoutputs.
Returns:Configures the client-side events.
public InlineAIPromptBuilder Events(Action<InlineAIPromptEventBuilder> configurator)
The client events action.
Returns:Sets the widget in a streaming mode.
public InlineAIPromptBuilder IsStreaming(bool value)
The value that configures the isstreaming.
Returns:The text messages displayed in the prompt send and stop output retrieval buttons.
public InlineAIPromptBuilder Messages(Action<InlineAIPromptMessagesSettingsBuilder> configurator)
The action that configures the messages.
Returns:An array of action configurations for the output cards. Can contain strings for built-in actions or objects with custom action properties.Built-in actions: - "copy" - Copy output content to clipboard. - "retry" - Retry generating the output. - "discard" - Clears the output content and closes the popup.Custom actions trigger the outputAction event with the action command and output data.
public InlineAIPromptBuilder OutputActions(Action<InlineAIPromptOutputActionFactory> configurator)
The InlineAIPromptOutputActionFactory for the outputactions setting.
Returns:Returns the current instance of InlineAIPromptBuilder .
Specifies the placeholder text for the underlying TextArea widget.
public InlineAIPromptBuilder Placeholder(string value)
The value that configures the placeholder.
Returns:The options that will be used for the popup initialization. For more details about the available options refer to Popup documentation.
public InlineAIPromptBuilder Popup(Action<InlineAIPromptPopupSettingsBuilder> configurator)
The action that configures the popup.
Returns:Specifies whether the underlying TextArea widget will be readonly or not.
public InlineAIPromptBuilder Readonly(bool value)
The value that configures the readonly.
Returns:A template function for customizing the display of output content. This function is called when an output's and final content needs to be rendered.The function receives an object with output (the output data) and prompt (the output prompt text) properties and should return HTML string.
public InlineAIPromptBuilder ResponseTemplate(string value)
The value that configures the responsetemplate.
Returns:A template function for customizing the display of output content. This function is called when an output's and final content needs to be rendered.The function receives an object with output (the output data) and prompt (the output prompt text) properties and should return HTML string.
public InlineAIPromptBuilder ResponseTemplate<TModel>(TemplateBuilder<TModel> template)
A Template component that configures the responsetemplate.
Returns:A template function for customizing the display of output content. This function is called when an output's and final content needs to be rendered.The function receives an object with output (the output data) and prompt (the output prompt text) properties and should return HTML string.
public InlineAIPromptBuilder ResponseTemplateHandler(string value)
The value that configures the responsetemplate.
Returns:A template function for customizing the display of output content. This function is called when an output's and final content needs to be rendered.The function receives an object with output (the output data) and prompt (the output prompt text) properties and should return HTML string.
public InlineAIPromptBuilder ResponseTemplateId(string value)
The value that configures the responsetemplate.
Returns:A template function for customizing the display of output content. This function is called when an output's and final content needs to be rendered.The function receives an object with output (the output data) and prompt (the output prompt text) properties and should return HTML string.
public InlineAIPromptBuilder ResponseTemplateView(MvcHtmlString value)
The value that configures the responsetemplate.
Returns:The URL of the AI service to use for generating outputs.
public InlineAIPromptBuilder Service(Action<AIPromptServiceSettingsBuilder> configurator)
The configurator for the service setting.
Returns:The EditorAISettingsBuilder instance for fluent API chaining.
Configures speech-to-text functionality for the prompt input. When true, enables speech-to-text with default settings. When false, disables the feature. When an object, configures custom speech-to-text options.
Configures speech-to-text functionality for the prompt input. When true, enables speech-to-text with default settings. When false, disables the feature. When an object, configures custom speech-to-text options.
public InlineAIPromptBuilder SpeechToText(Action<InlineAIPromptSpeechToTextSettingsBuilder> configurator)
The action that configures the speechtotext.
Returns:Configures speech-to-text functionality for the prompt input. When true, enables speech-to-text with default settings. When false, disables the feature. When an object, configures custom speech-to-text options.
public InlineAIPromptBuilder SpeechToText(bool enabled)
Enables or disables the speechtotext option.
Returns:Sets the systemPrompt's format which will be send to the specified AI Service. Exposes both a context and prompt metadata.
public InlineAIPromptBuilder SystemPrompt(string handler)
The value that configures the systemprompt action.
Returns: