io.github.cdklabs.generative_ai_cdk_constructs.bedrock.AgentProps Maven / Gradle / Ivy
Show all versions of generative-ai-cdk-constructs Show documentation
package io.github.cdklabs.generative_ai_cdk_constructs.bedrock;
/**
* (experimental) Properties for a Bedrock Agent.
*/
@javax.annotation.Generated(value = "jsii-pacmak/1.103.1 (build bef2dea)", date = "2024-10-01T15:41:28.671Z")
@software.amazon.jsii.Jsii(module = io.github.cdklabs.generative_ai_cdk_constructs.$Module.class, fqn = "@cdklabs/generative-ai-cdk-constructs.bedrock.AgentProps")
@software.amazon.jsii.Jsii.Proxy(AgentProps.Jsii$Proxy.class)
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
public interface AgentProps extends software.amazon.jsii.JsiiSerializable {
/**
* (experimental) The Bedrock text foundation model for the agent to use.
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
@org.jetbrains.annotations.NotNull io.github.cdklabs.generative_ai_cdk_constructs.bedrock.BedrockFoundationModel getFoundationModel();
/**
* (experimental) A narrative instruction to provide the agent as context.
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
@org.jetbrains.annotations.NotNull java.lang.String getInstruction();
/**
* (experimental) AgentActionGroup to make available to the agent.
*
* Default: - No AgentActionGroup is used.
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
default @org.jetbrains.annotations.Nullable java.util.List getActionGroups() {
return null;
}
/**
* (experimental) Name of the alias for the agent.
*
* Default: - No alias is created.
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
default @org.jetbrains.annotations.Nullable java.lang.String getAliasName() {
return null;
}
/**
* (experimental) A description of the agent.
*
* Default: - No description is provided.
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
default @org.jetbrains.annotations.Nullable java.lang.String getDescription() {
return null;
}
/**
* (experimental) Select whether the agent can prompt additional information from the user when it does not have enough information to respond to an utterance.
*
* Default: - False
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
default @org.jetbrains.annotations.Nullable java.lang.Boolean getEnableUserInput() {
return null;
}
/**
* (experimental) KMS encryption key to use for the agent.
*
* Default: - An AWS managed key is used.
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
default @org.jetbrains.annotations.Nullable software.amazon.awscdk.services.kms.IKey getEncryptionKey() {
return null;
}
/**
* (experimental) The existing IAM Role for the agent with a trust policy that allows the Bedrock service to assume the role.
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
default @org.jetbrains.annotations.Nullable software.amazon.awscdk.services.iam.Role getExistingRole() {
return null;
}
/**
* (experimental) Guardrail configuration.
*
* Warning: If you provide a guardrail configuration through the constructor,
* you will need to provide the correct permissions for your agent to access
* the guardrails. If you want the permissions to be configured on your behalf,
* use the addGuardrail method.
*
* Default: - No guardrails associated to the agent.
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
default @org.jetbrains.annotations.Nullable io.github.cdklabs.generative_ai_cdk_constructs.bedrock.GuardrailConfiguration getGuardrailConfiguration() {
return null;
}
/**
* (experimental) How long sessions should be kept open for the agent.
*
* Default: - 1 hour
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
default @org.jetbrains.annotations.Nullable software.amazon.awscdk.Duration getIdleSessionTTL() {
return null;
}
/**
* (experimental) Knowledge Bases to make available to the agent.
*
* Default: - No knowledge base is used.
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
default @org.jetbrains.annotations.Nullable java.util.List getKnowledgeBases() {
return null;
}
/**
* (experimental) The name of the agent.
*
* Default: - A name is automatically generated.
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
default @org.jetbrains.annotations.Nullable java.lang.String getName() {
return null;
}
/**
* (experimental) Overrides for the agent.
*
* Default: - No overrides are provided.
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
default @org.jetbrains.annotations.Nullable io.github.cdklabs.generative_ai_cdk_constructs.bedrock.PromptOverrideConfiguration getPromptOverrideConfiguration() {
return null;
}
/**
* (experimental) Whether to prepare the agent for use.
*
* Default: - false
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
default @org.jetbrains.annotations.Nullable java.lang.Boolean getShouldPrepareAgent() {
return null;
}
/**
* (experimental) OPTIONAL: Tag (KEY-VALUE) bedrock agent resource.
*
* Default: - false
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
default @org.jetbrains.annotations.Nullable java.util.Map getTags() {
return null;
}
/**
* @return a {@link Builder} of {@link AgentProps}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
static Builder builder() {
return new Builder();
}
/**
* A builder for {@link AgentProps}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
public static final class Builder implements software.amazon.jsii.Builder {
io.github.cdklabs.generative_ai_cdk_constructs.bedrock.BedrockFoundationModel foundationModel;
java.lang.String instruction;
java.util.List actionGroups;
java.lang.String aliasName;
java.lang.String description;
java.lang.Boolean enableUserInput;
software.amazon.awscdk.services.kms.IKey encryptionKey;
software.amazon.awscdk.services.iam.Role existingRole;
io.github.cdklabs.generative_ai_cdk_constructs.bedrock.GuardrailConfiguration guardrailConfiguration;
software.amazon.awscdk.Duration idleSessionTtl;
java.util.List knowledgeBases;
java.lang.String name;
io.github.cdklabs.generative_ai_cdk_constructs.bedrock.PromptOverrideConfiguration promptOverrideConfiguration;
java.lang.Boolean shouldPrepareAgent;
java.util.Map tags;
/**
* Sets the value of {@link AgentProps#getFoundationModel}
* @param foundationModel The Bedrock text foundation model for the agent to use. This parameter is required.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
public Builder foundationModel(io.github.cdklabs.generative_ai_cdk_constructs.bedrock.BedrockFoundationModel foundationModel) {
this.foundationModel = foundationModel;
return this;
}
/**
* Sets the value of {@link AgentProps#getInstruction}
* @param instruction A narrative instruction to provide the agent as context. This parameter is required.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
public Builder instruction(java.lang.String instruction) {
this.instruction = instruction;
return this;
}
/**
* Sets the value of {@link AgentProps#getActionGroups}
* @param actionGroups AgentActionGroup to make available to the agent.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
@SuppressWarnings("unchecked")
public Builder actionGroups(java.util.List extends io.github.cdklabs.generative_ai_cdk_constructs.bedrock.AgentActionGroup> actionGroups) {
this.actionGroups = (java.util.List)actionGroups;
return this;
}
/**
* Sets the value of {@link AgentProps#getAliasName}
* @param aliasName Name of the alias for the agent.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
public Builder aliasName(java.lang.String aliasName) {
this.aliasName = aliasName;
return this;
}
/**
* Sets the value of {@link AgentProps#getDescription}
* @param description A description of the agent.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
public Builder description(java.lang.String description) {
this.description = description;
return this;
}
/**
* Sets the value of {@link AgentProps#getEnableUserInput}
* @param enableUserInput Select whether the agent can prompt additional information from the user when it does not have enough information to respond to an utterance.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
public Builder enableUserInput(java.lang.Boolean enableUserInput) {
this.enableUserInput = enableUserInput;
return this;
}
/**
* Sets the value of {@link AgentProps#getEncryptionKey}
* @param encryptionKey KMS encryption key to use for the agent.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
public Builder encryptionKey(software.amazon.awscdk.services.kms.IKey encryptionKey) {
this.encryptionKey = encryptionKey;
return this;
}
/**
* Sets the value of {@link AgentProps#getExistingRole}
* @param existingRole The existing IAM Role for the agent with a trust policy that allows the Bedrock service to assume the role.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
public Builder existingRole(software.amazon.awscdk.services.iam.Role existingRole) {
this.existingRole = existingRole;
return this;
}
/**
* Sets the value of {@link AgentProps#getGuardrailConfiguration}
* @param guardrailConfiguration Guardrail configuration.
* Warning: If you provide a guardrail configuration through the constructor,
* you will need to provide the correct permissions for your agent to access
* the guardrails. If you want the permissions to be configured on your behalf,
* use the addGuardrail method.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
public Builder guardrailConfiguration(io.github.cdklabs.generative_ai_cdk_constructs.bedrock.GuardrailConfiguration guardrailConfiguration) {
this.guardrailConfiguration = guardrailConfiguration;
return this;
}
/**
* Sets the value of {@link AgentProps#getIdleSessionTtl}
* @param idleSessionTtl How long sessions should be kept open for the agent.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
public Builder idleSessionTtl(software.amazon.awscdk.Duration idleSessionTtl) {
this.idleSessionTtl = idleSessionTtl;
return this;
}
/**
* Sets the value of {@link AgentProps#getKnowledgeBases}
* @param knowledgeBases Knowledge Bases to make available to the agent.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
@SuppressWarnings("unchecked")
public Builder knowledgeBases(java.util.List extends io.github.cdklabs.generative_ai_cdk_constructs.bedrock.KnowledgeBase> knowledgeBases) {
this.knowledgeBases = (java.util.List)knowledgeBases;
return this;
}
/**
* Sets the value of {@link AgentProps#getName}
* @param name The name of the agent.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
public Builder name(java.lang.String name) {
this.name = name;
return this;
}
/**
* Sets the value of {@link AgentProps#getPromptOverrideConfiguration}
* @param promptOverrideConfiguration Overrides for the agent.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
public Builder promptOverrideConfiguration(io.github.cdklabs.generative_ai_cdk_constructs.bedrock.PromptOverrideConfiguration promptOverrideConfiguration) {
this.promptOverrideConfiguration = promptOverrideConfiguration;
return this;
}
/**
* Sets the value of {@link AgentProps#getShouldPrepareAgent}
* @param shouldPrepareAgent Whether to prepare the agent for use.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
public Builder shouldPrepareAgent(java.lang.Boolean shouldPrepareAgent) {
this.shouldPrepareAgent = shouldPrepareAgent;
return this;
}
/**
* Sets the value of {@link AgentProps#getTags}
* @param tags OPTIONAL: Tag (KEY-VALUE) bedrock agent resource.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
public Builder tags(java.util.Map tags) {
this.tags = tags;
return this;
}
/**
* Builds the configured instance.
* @return a new instance of {@link AgentProps}
* @throws NullPointerException if any required attribute was not provided
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
@Override
public AgentProps build() {
return new Jsii$Proxy(this);
}
}
/**
* An implementation for {@link AgentProps}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
@software.amazon.jsii.Internal
final class Jsii$Proxy extends software.amazon.jsii.JsiiObject implements AgentProps {
private final io.github.cdklabs.generative_ai_cdk_constructs.bedrock.BedrockFoundationModel foundationModel;
private final java.lang.String instruction;
private final java.util.List actionGroups;
private final java.lang.String aliasName;
private final java.lang.String description;
private final java.lang.Boolean enableUserInput;
private final software.amazon.awscdk.services.kms.IKey encryptionKey;
private final software.amazon.awscdk.services.iam.Role existingRole;
private final io.github.cdklabs.generative_ai_cdk_constructs.bedrock.GuardrailConfiguration guardrailConfiguration;
private final software.amazon.awscdk.Duration idleSessionTtl;
private final java.util.List knowledgeBases;
private final java.lang.String name;
private final io.github.cdklabs.generative_ai_cdk_constructs.bedrock.PromptOverrideConfiguration promptOverrideConfiguration;
private final java.lang.Boolean shouldPrepareAgent;
private final java.util.Map tags;
/**
* Constructor that initializes the object based on values retrieved from the JsiiObject.
* @param objRef Reference to the JSII managed object.
*/
protected Jsii$Proxy(final software.amazon.jsii.JsiiObjectRef objRef) {
super(objRef);
this.foundationModel = software.amazon.jsii.Kernel.get(this, "foundationModel", software.amazon.jsii.NativeType.forClass(io.github.cdklabs.generative_ai_cdk_constructs.bedrock.BedrockFoundationModel.class));
this.instruction = software.amazon.jsii.Kernel.get(this, "instruction", software.amazon.jsii.NativeType.forClass(java.lang.String.class));
this.actionGroups = software.amazon.jsii.Kernel.get(this, "actionGroups", software.amazon.jsii.NativeType.listOf(software.amazon.jsii.NativeType.forClass(io.github.cdklabs.generative_ai_cdk_constructs.bedrock.AgentActionGroup.class)));
this.aliasName = software.amazon.jsii.Kernel.get(this, "aliasName", software.amazon.jsii.NativeType.forClass(java.lang.String.class));
this.description = software.amazon.jsii.Kernel.get(this, "description", software.amazon.jsii.NativeType.forClass(java.lang.String.class));
this.enableUserInput = software.amazon.jsii.Kernel.get(this, "enableUserInput", software.amazon.jsii.NativeType.forClass(java.lang.Boolean.class));
this.encryptionKey = software.amazon.jsii.Kernel.get(this, "encryptionKey", software.amazon.jsii.NativeType.forClass(software.amazon.awscdk.services.kms.IKey.class));
this.existingRole = software.amazon.jsii.Kernel.get(this, "existingRole", software.amazon.jsii.NativeType.forClass(software.amazon.awscdk.services.iam.Role.class));
this.guardrailConfiguration = software.amazon.jsii.Kernel.get(this, "guardrailConfiguration", software.amazon.jsii.NativeType.forClass(io.github.cdklabs.generative_ai_cdk_constructs.bedrock.GuardrailConfiguration.class));
this.idleSessionTtl = software.amazon.jsii.Kernel.get(this, "idleSessionTTL", software.amazon.jsii.NativeType.forClass(software.amazon.awscdk.Duration.class));
this.knowledgeBases = software.amazon.jsii.Kernel.get(this, "knowledgeBases", software.amazon.jsii.NativeType.listOf(software.amazon.jsii.NativeType.forClass(io.github.cdklabs.generative_ai_cdk_constructs.bedrock.KnowledgeBase.class)));
this.name = software.amazon.jsii.Kernel.get(this, "name", software.amazon.jsii.NativeType.forClass(java.lang.String.class));
this.promptOverrideConfiguration = software.amazon.jsii.Kernel.get(this, "promptOverrideConfiguration", software.amazon.jsii.NativeType.forClass(io.github.cdklabs.generative_ai_cdk_constructs.bedrock.PromptOverrideConfiguration.class));
this.shouldPrepareAgent = software.amazon.jsii.Kernel.get(this, "shouldPrepareAgent", software.amazon.jsii.NativeType.forClass(java.lang.Boolean.class));
this.tags = software.amazon.jsii.Kernel.get(this, "tags", software.amazon.jsii.NativeType.mapOf(software.amazon.jsii.NativeType.forClass(java.lang.String.class)));
}
/**
* Constructor that initializes the object based on literal property values passed by the {@link Builder}.
*/
@SuppressWarnings("unchecked")
protected Jsii$Proxy(final Builder builder) {
super(software.amazon.jsii.JsiiObject.InitializationMode.JSII);
this.foundationModel = java.util.Objects.requireNonNull(builder.foundationModel, "foundationModel is required");
this.instruction = java.util.Objects.requireNonNull(builder.instruction, "instruction is required");
this.actionGroups = (java.util.List)builder.actionGroups;
this.aliasName = builder.aliasName;
this.description = builder.description;
this.enableUserInput = builder.enableUserInput;
this.encryptionKey = builder.encryptionKey;
this.existingRole = builder.existingRole;
this.guardrailConfiguration = builder.guardrailConfiguration;
this.idleSessionTtl = builder.idleSessionTtl;
this.knowledgeBases = (java.util.List)builder.knowledgeBases;
this.name = builder.name;
this.promptOverrideConfiguration = builder.promptOverrideConfiguration;
this.shouldPrepareAgent = builder.shouldPrepareAgent;
this.tags = builder.tags;
}
@Override
public final io.github.cdklabs.generative_ai_cdk_constructs.bedrock.BedrockFoundationModel getFoundationModel() {
return this.foundationModel;
}
@Override
public final java.lang.String getInstruction() {
return this.instruction;
}
@Override
public final java.util.List getActionGroups() {
return this.actionGroups;
}
@Override
public final java.lang.String getAliasName() {
return this.aliasName;
}
@Override
public final java.lang.String getDescription() {
return this.description;
}
@Override
public final java.lang.Boolean getEnableUserInput() {
return this.enableUserInput;
}
@Override
public final software.amazon.awscdk.services.kms.IKey getEncryptionKey() {
return this.encryptionKey;
}
@Override
public final software.amazon.awscdk.services.iam.Role getExistingRole() {
return this.existingRole;
}
@Override
public final io.github.cdklabs.generative_ai_cdk_constructs.bedrock.GuardrailConfiguration getGuardrailConfiguration() {
return this.guardrailConfiguration;
}
@Override
public final software.amazon.awscdk.Duration getIdleSessionTTL() {
return this.idleSessionTtl;
}
@Override
public final java.util.List getKnowledgeBases() {
return this.knowledgeBases;
}
@Override
public final java.lang.String getName() {
return this.name;
}
@Override
public final io.github.cdklabs.generative_ai_cdk_constructs.bedrock.PromptOverrideConfiguration getPromptOverrideConfiguration() {
return this.promptOverrideConfiguration;
}
@Override
public final java.lang.Boolean getShouldPrepareAgent() {
return this.shouldPrepareAgent;
}
@Override
public final java.util.Map getTags() {
return this.tags;
}
@Override
@software.amazon.jsii.Internal
public com.fasterxml.jackson.databind.JsonNode $jsii$toJson() {
final com.fasterxml.jackson.databind.ObjectMapper om = software.amazon.jsii.JsiiObjectMapper.INSTANCE;
final com.fasterxml.jackson.databind.node.ObjectNode data = com.fasterxml.jackson.databind.node.JsonNodeFactory.instance.objectNode();
data.set("foundationModel", om.valueToTree(this.getFoundationModel()));
data.set("instruction", om.valueToTree(this.getInstruction()));
if (this.getActionGroups() != null) {
data.set("actionGroups", om.valueToTree(this.getActionGroups()));
}
if (this.getAliasName() != null) {
data.set("aliasName", om.valueToTree(this.getAliasName()));
}
if (this.getDescription() != null) {
data.set("description", om.valueToTree(this.getDescription()));
}
if (this.getEnableUserInput() != null) {
data.set("enableUserInput", om.valueToTree(this.getEnableUserInput()));
}
if (this.getEncryptionKey() != null) {
data.set("encryptionKey", om.valueToTree(this.getEncryptionKey()));
}
if (this.getExistingRole() != null) {
data.set("existingRole", om.valueToTree(this.getExistingRole()));
}
if (this.getGuardrailConfiguration() != null) {
data.set("guardrailConfiguration", om.valueToTree(this.getGuardrailConfiguration()));
}
if (this.getIdleSessionTTL() != null) {
data.set("idleSessionTTL", om.valueToTree(this.getIdleSessionTTL()));
}
if (this.getKnowledgeBases() != null) {
data.set("knowledgeBases", om.valueToTree(this.getKnowledgeBases()));
}
if (this.getName() != null) {
data.set("name", om.valueToTree(this.getName()));
}
if (this.getPromptOverrideConfiguration() != null) {
data.set("promptOverrideConfiguration", om.valueToTree(this.getPromptOverrideConfiguration()));
}
if (this.getShouldPrepareAgent() != null) {
data.set("shouldPrepareAgent", om.valueToTree(this.getShouldPrepareAgent()));
}
if (this.getTags() != null) {
data.set("tags", om.valueToTree(this.getTags()));
}
final com.fasterxml.jackson.databind.node.ObjectNode struct = com.fasterxml.jackson.databind.node.JsonNodeFactory.instance.objectNode();
struct.set("fqn", om.valueToTree("@cdklabs/generative-ai-cdk-constructs.bedrock.AgentProps"));
struct.set("data", data);
final com.fasterxml.jackson.databind.node.ObjectNode obj = com.fasterxml.jackson.databind.node.JsonNodeFactory.instance.objectNode();
obj.set("$jsii.struct", struct);
return obj;
}
@Override
public final boolean equals(final Object o) {
if (this == o) return true;
if (o == null || getClass() != o.getClass()) return false;
AgentProps.Jsii$Proxy that = (AgentProps.Jsii$Proxy) o;
if (!foundationModel.equals(that.foundationModel)) return false;
if (!instruction.equals(that.instruction)) return false;
if (this.actionGroups != null ? !this.actionGroups.equals(that.actionGroups) : that.actionGroups != null) return false;
if (this.aliasName != null ? !this.aliasName.equals(that.aliasName) : that.aliasName != null) return false;
if (this.description != null ? !this.description.equals(that.description) : that.description != null) return false;
if (this.enableUserInput != null ? !this.enableUserInput.equals(that.enableUserInput) : that.enableUserInput != null) return false;
if (this.encryptionKey != null ? !this.encryptionKey.equals(that.encryptionKey) : that.encryptionKey != null) return false;
if (this.existingRole != null ? !this.existingRole.equals(that.existingRole) : that.existingRole != null) return false;
if (this.guardrailConfiguration != null ? !this.guardrailConfiguration.equals(that.guardrailConfiguration) : that.guardrailConfiguration != null) return false;
if (this.idleSessionTtl != null ? !this.idleSessionTtl.equals(that.idleSessionTtl) : that.idleSessionTtl != null) return false;
if (this.knowledgeBases != null ? !this.knowledgeBases.equals(that.knowledgeBases) : that.knowledgeBases != null) return false;
if (this.name != null ? !this.name.equals(that.name) : that.name != null) return false;
if (this.promptOverrideConfiguration != null ? !this.promptOverrideConfiguration.equals(that.promptOverrideConfiguration) : that.promptOverrideConfiguration != null) return false;
if (this.shouldPrepareAgent != null ? !this.shouldPrepareAgent.equals(that.shouldPrepareAgent) : that.shouldPrepareAgent != null) return false;
return this.tags != null ? this.tags.equals(that.tags) : that.tags == null;
}
@Override
public final int hashCode() {
int result = this.foundationModel.hashCode();
result = 31 * result + (this.instruction.hashCode());
result = 31 * result + (this.actionGroups != null ? this.actionGroups.hashCode() : 0);
result = 31 * result + (this.aliasName != null ? this.aliasName.hashCode() : 0);
result = 31 * result + (this.description != null ? this.description.hashCode() : 0);
result = 31 * result + (this.enableUserInput != null ? this.enableUserInput.hashCode() : 0);
result = 31 * result + (this.encryptionKey != null ? this.encryptionKey.hashCode() : 0);
result = 31 * result + (this.existingRole != null ? this.existingRole.hashCode() : 0);
result = 31 * result + (this.guardrailConfiguration != null ? this.guardrailConfiguration.hashCode() : 0);
result = 31 * result + (this.idleSessionTtl != null ? this.idleSessionTtl.hashCode() : 0);
result = 31 * result + (this.knowledgeBases != null ? this.knowledgeBases.hashCode() : 0);
result = 31 * result + (this.name != null ? this.name.hashCode() : 0);
result = 31 * result + (this.promptOverrideConfiguration != null ? this.promptOverrideConfiguration.hashCode() : 0);
result = 31 * result + (this.shouldPrepareAgent != null ? this.shouldPrepareAgent.hashCode() : 0);
result = 31 * result + (this.tags != null ? this.tags.hashCode() : 0);
return result;
}
}
}