Class DefaultResourceAiDelegate
java.lang.Object
com.inductiveautomation.ignition.gateway.config.DefaultResourceAiDelegate
- All Implemented Interfaces:
ResourceAiDelegate
The standard
ResourceAiDelegate, holding a fixed capability level, an optional
description, and the resource type's diagnostic contributions. Instances are immutable and safe
to share between resource types.
Build one with newBuilder(), or use DEFAULT to grant ResourceAiDelegate.AiCapability.Read with no description and no diagnostics.
-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from interface ResourceAiDelegate
ResourceAiDelegate.AiCapability -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final ResourceAiDelegateA shared delegate that grantsResourceAiDelegate.AiCapability.Read, supplies no description, and contributes no diagnostics. -
Constructor Summary
ConstructorsConstructorDescriptionDefaultResourceAiDelegate(ResourceAiDelegate.AiCapability capability, @Nullable String description, Set<String> additionalSensitiveKeys, ResourceDiagnostics diagnostics) -
Method Summary
Modifier and TypeMethodDescriptionConfiguration field names that must be blanked before this type's configuration is shown to an agent, beyond the ones any resource type has blanked for it.@NonNull ResourceAiDelegate.AiCapabilityHow much of this resource type AI agents may see.A short prose explanation of what this resource type is and what an agent can do with it, used verbatim as context for a model.@NonNull ResourceDiagnosticsWhat a diagnostic digest for this resource type should know: how these resources fail, where their log events are, and what live state is worth reporting.Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface ResourceAiDelegate
configAsJson
-
Field Details
-
DEFAULT
A shared delegate that grantsResourceAiDelegate.AiCapability.Read, supplies no description, and contributes no diagnostics. This is whatResourceTypeMeta.getAiDelegate()returns for resource types that don't configure one.
-
-
Constructor Details
-
DefaultResourceAiDelegate
public DefaultResourceAiDelegate(ResourceAiDelegate.AiCapability capability, @Nullable String description, Set<String> additionalSensitiveKeys, ResourceDiagnostics diagnostics) - Parameters:
capability- the highest capability to grant.description- the prose description handed to the model, or null for none.additionalSensitiveKeys- configuration field names to blank; copied.diagnostics- what a digest for this resource type should know.
-
-
Method Details
-
getCapability
Description copied from interface:ResourceAiDelegateHow much of this resource type AI agents may see.- Specified by:
getCapabilityin interfaceResourceAiDelegate- Returns:
- the highest capability this resource type grants;
ResourceAiDelegate.AiCapability.Readby default.
-
getDescription
Description copied from interface:ResourceAiDelegateA short prose explanation of what this resource type is and what an agent can do with it, used verbatim as context for a model. Not localized, because it is written for a model and models are prompted in English. When empty, consumers fall back toResourceTypeMeta.getDescription(java.util.Locale)and the resource category name.- Specified by:
getDescriptionin interfaceResourceAiDelegate- Returns:
- the description of this resource type, or an empty optional if none is provided.
-
additionalSensitiveKeys
Description copied from interface:ResourceAiDelegateConfiguration field names that must be blanked before this type's configuration is shown to an agent, beyond the ones any resource type has blanked for it.For a field that carries a secret without being named like one: a free-form driver property blob, say, where there is no way to tell a credential from a tuning parameter. Declared here because only the subsystem knows which of its fields those are.
- Specified by:
additionalSensitiveKeysin interfaceResourceAiDelegate- Returns:
- extra field names to blank, matched case-insensitively; empty by default.
-
getDiagnostics
Description copied from interface:ResourceAiDelegateWhat a diagnostic digest for this resource type should know: how these resources fail, where their log events are, and what live state is worth reporting. Declaring anything here is also what puts a digest panel on this type's page.- Specified by:
getDiagnosticsin interfaceResourceAiDelegate- Returns:
- this resource type's diagnostic contributions; contributes nothing by default.
- See Also:
-
newBuilder
-