Package org.netxms.client.ai
Class AiOperator
java.lang.Object
org.netxms.client.ai.AiOperator
AI operator instance - perpetual adaptive monitoring loop. Configuration fields have setters
and can be changed by the client; adaptive state fields (current focus, watch list, memento)
are managed by the operator itself and are read-only.
-
Constructor Summary
ConstructorsConstructorDescriptionAiOperator(String name) Create new AI operator instance definition with default settings (for subsequent creation on server).AiOperator(NXCPMessage msg, long baseId) Create AI operator instance object from NXCP message. -
Method Summary
Modifier and TypeMethodDescriptionvoidfillMessage(NXCPMessage msg) Fill NXCP message with configuration data for create/modify request.intintintgetId()intintintgetName()intintintlongbooleanbooleanvoidsetDailyTokenBudget(int dailyTokenBudget) voidsetDescription(String description) voidsetEnabled(boolean enabled) voidsetMaxInterval(int maxInterval) voidsetMinInterval(int minInterval) voidsetModelSlot(String modelSlot) voidvoidsetObservationMaxRecords(int observationMaxRecords) voidsetObservationRetentionDays(int observationRetentionDays) voidsetPersonaPrompt(String personaPrompt) voidsetScopeFilter(String scopeFilter)
-
Constructor Details
-
AiOperator
Create new AI operator instance definition with default settings (for subsequent creation on server).- Parameters:
name- instance name
-
AiOperator
Create AI operator instance object from NXCP message.- Parameters:
msg- NXCP messagebaseId- base ID for fields
-
-
Method Details
-
fillMessage
Fill NXCP message with configuration data for create/modify request.- Parameters:
msg- NXCP message
-
getId
public int getId()- Returns:
- the id
-
getName
- Returns:
- the name
-
setName
- Parameters:
name- the name to set
-
getDescription
- Returns:
- the description
-
setDescription
- Parameters:
description- the description to set
-
getOwnerUserId
public int getOwnerUserId()- Returns:
- the ownerUserId
-
isEnabled
public boolean isEnabled()- Returns:
- true if the instance is enabled
-
setEnabled
public void setEnabled(boolean enabled) - Parameters:
enabled- true to enable the instance
-
isExecuting
public boolean isExecuting()- Returns:
- true if an iteration is currently running
-
getScopeFilter
- Returns:
- the scopeFilter
-
setScopeFilter
- Parameters:
scopeFilter- the scopeFilter to set
-
getModelSlot
- Returns:
- the modelSlot
-
setModelSlot
- Parameters:
modelSlot- the modelSlot to set
-
getMinInterval
public int getMinInterval()- Returns:
- the minInterval
-
setMinInterval
public void setMinInterval(int minInterval) - Parameters:
minInterval- the minInterval to set
-
getMaxInterval
public int getMaxInterval()- Returns:
- the maxInterval
-
setMaxInterval
public void setMaxInterval(int maxInterval) - Parameters:
maxInterval- the maxInterval to set
-
getDailyTokenBudget
public int getDailyTokenBudget()- Returns:
- the dailyTokenBudget
-
setDailyTokenBudget
public void setDailyTokenBudget(int dailyTokenBudget) - Parameters:
dailyTokenBudget- the dailyTokenBudget to set
-
getTokensUsedToday
public long getTokensUsedToday()- Returns:
- LLM tokens used within the current usage day (UTC)
-
getPersonaPrompt
- Returns:
- the personaPrompt
-
setPersonaPrompt
- Parameters:
personaPrompt- the personaPrompt to set
-
getCurrentFocus
- Returns:
- current focus set by the operator itself
-
getWatchList
- Returns:
- watch list maintained by the operator itself
-
getMemento
- Returns:
- state carried between iterations by the operator itself
-
getObservationRetentionDays
public int getObservationRetentionDays()- Returns:
- the observationRetentionDays
-
setObservationRetentionDays
public void setObservationRetentionDays(int observationRetentionDays) - Parameters:
observationRetentionDays- the observationRetentionDays to set
-
getObservationMaxRecords
public int getObservationMaxRecords()- Returns:
- the observationMaxRecords
-
setObservationMaxRecords
public void setObservationMaxRecords(int observationMaxRecords) - Parameters:
observationMaxRecords- the observationMaxRecords to set
-
getLastExecutionTime
- Returns:
- the lastExecutionTime
-
getNextExecutionTime
- Returns:
- the nextExecutionTime
-
getIteration
public int getIteration()- Returns:
- number of completed iterations
-
getConsecutiveFailures
public int getConsecutiveFailures()- Returns:
- number of consecutive failed executions
-
getLastExplanation
- Returns:
- explanation returned by the last execution
-
getCreationTime
- Returns:
- the creationTime
-
getModificationTime
- Returns:
- the modificationTime
-