TTMSFNCCloudAI Class
Component that sends prompts, files, tools, assistant operations, and audio requests to AI services.
API unit family: TMSFNCCloudAI
Inherits from: TTMSFNCCloudBase
Syntax
TTMSFNCCloudAI = class(TTMSFNCCloudBase)
Properties
| Name |
Description |
| APIKeys |
Gets or sets the API keys used by service requests. |
| AssistantRole |
Gets or sets assistant-role prompt lines added to requests. |
| Assistants |
Gets the assistants returned by assistant list requests. |
| Busy |
Indicates whether one or more service requests are currently running. |
| Context |
Gets or sets user context lines sent with requests. |
| Files |
Gets the files and content items attached to requests. |
| Models |
Gets the model names returned by the most recent model request. |
| Service |
Gets or sets the service used for requests. |
| Settings |
Gets or sets model, generation, endpoint, and feature settings. |
| SystemRole |
Gets or sets system-role prompt lines added to requests. |
| Tools |
Gets or sets callable tools exposed to supported services. |
| Usage |
Gets accumulated usage counters across requests. |
Methods
| Name |
Description |
| AddFile |
Adds a local file to the request content collection. |
| AddText |
Adds inline text to the request content collection. |
| AddURL |
Adds a URL to the request content collection. |
| CheckStatus |
Checks the status of the current assistant run. |
| ClearFiles |
Clears all file and content items attached to requests. |
| CreateAssistant |
Creates an assistant with instructions and tool capabilities. |
| CreateMessage |
Adds a message to an assistant thread. |
| CreateThread |
Creates a new assistant conversation thread. |
| Execute |
Executes a request using the current service, context, files, tools, and settings. |
| GetActiveServices |
Returns active services that match the requested capability filters. |
| GetAssistants |
Requests the list of assistants from the current service. |
| GetFiles |
Requests the list of files known by the current service. |
| GetModels |
Requests the available model list for the current service. |
| GetServices |
Returns services that match the requested capability filters. |
| RunThread |
Starts an assistant run for the specified thread and assistant. |
| RunThreadAndWait |
Starts an assistant run and polls until it completes. |
| Speak |
Generates speech audio from text. |
| Transcribe |
Transcribes audio from a file. |
| Translate |
Transcribes and translates audio from a file to English. |
| UploadFile |
Uploads a file for later use in AI requests. |
Events
| Name |
Description |
| OnExecuted |
Fires after a prompt execution request completes. |
| OnFileDeleted |
Fires after a file delete request completes. |
| OnFileUpload |
Fires after a file upload request completes. |
| OnGetAssistants |
Fires after the assistant list request completes. |
| OnGetFiles |
Fires after the file list request completes. |
| OnGetModels |
Fires after the model list request completes. |
| OnSpeechAudio |
Fires after speech audio generation completes. |
| OnTranscribeAudio |
Fires after audio transcription or translation completes. |