This is the documentation for the development version.
There are no official binaries for it; build it from the source code in git.
Download links on these pages work only after the release.
For the current release, see version 7.0.
RegisterAITask
- RegisterAITask(taskDescription, prompt): int
-
Registers a new AI task for asynchronous processing.
Table 1. Parameters taskDescription
String
Description of the AI task
prompt
String
Prompt to send to the AI assistant
ReturnInteger task ID which can be used to track the task’s execution and retrieve results, or
nullif the script is executed on behalf of a user without the "Manage AI tasks" system access right.
Use this function for long-running AI operations where you don’t need an immediate response. For synchronous AI queries, use QueryAIAssistant.
// Register an AI task for later processing
taskId = RegisterAITask("Analyze alarm patterns", "Review recent alarms and identify patterns");
println("Registered AI task with ID: " .. taskId);
See also