lib/aws-sdk-bedrockagent/client.rb in aws-sdk-bedrockagent-1.3.0 vs lib/aws-sdk-bedrockagent/client.rb in aws-sdk-bedrockagent-1.4.0

- old
+ new

@@ -386,294 +386,408 @@ super end # @!group API Operations - # Associate a Knowledge Base to an existing Amazon Bedrock Agent + # Associates a knowledge base with an agent. If a knowledge base is + # associated and its `indexState` is set to `Enabled`, the agent queries + # the knowledge base for information to augment its response to the + # user. # # @option params [required, String] :agent_id - # Id generated at the server side when an Agent is created + # The unique identifier of the agent with which you want to associate + # the knowledge base. # # @option params [required, String] :agent_version - # Draft Version of the Agent. + # The version of the agent with which you want to associate the + # knowledge base. # - # @option params [required, String] :knowledge_base_id - # Identifier for a resource. - # # @option params [required, String] :description - # Description of the Resource. + # A description of what the agent should use the knowledge base for. # + # @option params [required, String] :knowledge_base_id + # The unique identifier of the knowledge base to associate with the + # agent. + # # @option params [String] :knowledge_base_state - # State of the knowledge base; whether it is enabled or disabled + # Specifies whether to use the knowledge base or not when sending an + # [InvokeAgent][1] request. # + # + # + # [1]: https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_InvokeAgent.html + # # @return [Types::AssociateAgentKnowledgeBaseResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: # # * {Types::AssociateAgentKnowledgeBaseResponse#agent_knowledge_base #agent_knowledge_base} => Types::AgentKnowledgeBase # # @example Request syntax with placeholder values # # resp = client.associate_agent_knowledge_base({ # agent_id: "Id", # required # agent_version: "DraftVersion", # required - # knowledge_base_id: "Id", # required # description: "Description", # required + # knowledge_base_id: "Id", # required # knowledge_base_state: "ENABLED", # accepts ENABLED, DISABLED # }) # # @example Response structure # # resp.agent_knowledge_base.agent_id #=> String # resp.agent_knowledge_base.agent_version #=> String - # resp.agent_knowledge_base.knowledge_base_id #=> String - # resp.agent_knowledge_base.description #=> String # resp.agent_knowledge_base.created_at #=> Time - # resp.agent_knowledge_base.updated_at #=> Time + # resp.agent_knowledge_base.description #=> String + # resp.agent_knowledge_base.knowledge_base_id #=> String # resp.agent_knowledge_base.knowledge_base_state #=> String, one of "ENABLED", "DISABLED" + # resp.agent_knowledge_base.updated_at #=> Time # # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/AssociateAgentKnowledgeBase AWS API Documentation # # @overload associate_agent_knowledge_base(params = {}) # @param [Hash] params ({}) def associate_agent_knowledge_base(params = {}, options = {}) req = build_request(:associate_agent_knowledge_base, params) req.send_request(options) end - # Creates an Amazon Bedrock Agent + # Creates an agent that orchestrates interactions between foundation + # models, data sources, software applications, user conversations, and + # APIs to carry out tasks to help customers. # + # * Specify the following fields for security purposes. + # + # * `agentResourceRoleArn` – The ARN of the role with permissions to + # create an agent. + # + # * (Optional) `customerEncryptionKeyArn` – The ARN of a KMS key to + # encrypt the creation of the agent. + # + # * (Optional) `idleSessionTTLinSeconds` – Specify the number of + # seconds for which the agent should maintain session information. + # After this time expires, the subsequent `InvokeAgent` request + # begins a new session. + # + # * To override the default prompt behavior for agent orchestration and + # to use advanced prompts, include a `promptOverrideConfiguration` + # object. For more information, see [Advanced prompts][1]. + # + # * If you agent fails to be created, the response returns a list of + # `failureReasons` alongside a list of `recommendedActions` for you to + # troubleshoot. + # + # + # + # [1]: https://docs.aws.amazon.com/bedrock/latest/userguide/advanced-prompts.html + # # @option params [required, String] :agent_name - # Name for a resource. + # A name for the agent that you create. # + # @option params [required, String] :agent_resource_role_arn + # The ARN of the IAM role with permissions to create the agent. The ARN + # must begin with `AmazonBedrockExecutionRoleForAgents_`. + # # @option params [String] :client_token - # Client specified token used for idempotency checks + # A unique, case-sensitive identifier to ensure that the API request + # completes no more than one time. If this token matches a previous + # request, Amazon Bedrock ignores the request, but does not return an + # error. For more information, see [Ensuring idempotency][1]. # # **A suitable default value is auto-generated.** You should normally # not need to pass this option.** # - # @option params [String] :instruction - # Instruction for the agent. # - # @option params [String] :foundation_model - # ARN or name of a Bedrock model. # + # [1]: https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html + # + # @option params [String] :customer_encryption_key_arn + # The ARN of the KMS key with which to encrypt the agent. + # # @option params [String] :description - # Description of the Resource. + # A description of the agent. # + # @option params [String] :foundation_model + # The foundation model to be used for orchestration by the agent you + # create. + # # @option params [Integer] :idle_session_ttl_in_seconds - # Max Session Time. + # The number of seconds for which Amazon Bedrock keeps information about + # a user's conversation with the agent. # - # @option params [required, String] :agent_resource_role_arn - # ARN of a IAM role. + # A user interaction remains active for the amount of time specified. If + # no conversation occurs during this time, the session expires and + # Amazon Bedrock deletes any data provided before the timeout. # - # @option params [String] :customer_encryption_key_arn - # A KMS key ARN + # @option params [String] :instruction + # Instructions that tell the agent what it should do and how it should + # interact with users. # - # @option params [Hash<String,String>] :tags - # A map of tag keys and values - # # @option params [Types::PromptOverrideConfiguration] :prompt_override_configuration - # Configuration for prompt override. + # Contains configurations to override prompts in different parts of an + # agent sequence. For more information, see [Advanced prompts][1]. # + # + # + # [1]: https://docs.aws.amazon.com/bedrock/latest/userguide/advanced-prompts.html + # + # @option params [Hash<String,String>] :tags + # Any tags that you want to attach to the agent. + # # @return [Types::CreateAgentResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: # # * {Types::CreateAgentResponse#agent #agent} => Types::Agent # # @example Request syntax with placeholder values # # resp = client.create_agent({ # agent_name: "Name", # required + # agent_resource_role_arn: "AgentRoleArn", # required # client_token: "ClientToken", - # instruction: "Instruction", - # foundation_model: "ModelIdentifier", + # customer_encryption_key_arn: "KmsKeyArn", # description: "Description", + # foundation_model: "ModelIdentifier", # idle_session_ttl_in_seconds: 1, - # agent_resource_role_arn: "AgentRoleArn", # required - # customer_encryption_key_arn: "KmsKeyArn", - # tags: { - # "TagKey" => "TagValue", - # }, + # instruction: "Instruction", # prompt_override_configuration: { + # override_lambda: "LambdaArn", # prompt_configurations: [ # required # { - # prompt_type: "PRE_PROCESSING", # accepts PRE_PROCESSING, ORCHESTRATION, POST_PROCESSING, KNOWLEDGE_BASE_RESPONSE_GENERATION - # prompt_creation_mode: "DEFAULT", # accepts DEFAULT, OVERRIDDEN - # prompt_state: "ENABLED", # accepts ENABLED, DISABLED # base_prompt_template: "BasePromptTemplate", # inference_configuration: { - # temperature: 1.0, - # top_p: 1.0, - # top_k: 1, # maximum_length: 1, # stop_sequences: ["String"], + # temperature: 1.0, + # top_k: 1, + # top_p: 1.0, # }, # parser_mode: "DEFAULT", # accepts DEFAULT, OVERRIDDEN + # prompt_creation_mode: "DEFAULT", # accepts DEFAULT, OVERRIDDEN + # prompt_state: "ENABLED", # accepts ENABLED, DISABLED + # prompt_type: "PRE_PROCESSING", # accepts PRE_PROCESSING, ORCHESTRATION, POST_PROCESSING, KNOWLEDGE_BASE_RESPONSE_GENERATION # }, # ], - # override_lambda: "LambdaArn", # }, + # tags: { + # "TagKey" => "TagValue", + # }, # }) # # @example Response structure # + # resp.agent.agent_arn #=> String # resp.agent.agent_id #=> String # resp.agent.agent_name #=> String - # resp.agent.agent_arn #=> String + # resp.agent.agent_resource_role_arn #=> String + # resp.agent.agent_status #=> String, one of "CREATING", "PREPARING", "PREPARED", "NOT_PREPARED", "DELETING", "FAILED", "VERSIONING", "UPDATING" # resp.agent.agent_version #=> String # resp.agent.client_token #=> String - # resp.agent.instruction #=> String - # resp.agent.agent_status #=> String, one of "CREATING", "PREPARING", "PREPARED", "NOT_PREPARED", "DELETING", "FAILED", "VERSIONING", "UPDATING" - # resp.agent.foundation_model #=> String - # resp.agent.description #=> String - # resp.agent.idle_session_ttl_in_seconds #=> Integer - # resp.agent.agent_resource_role_arn #=> String - # resp.agent.customer_encryption_key_arn #=> String # resp.agent.created_at #=> Time - # resp.agent.updated_at #=> Time - # resp.agent.prepared_at #=> Time + # resp.agent.customer_encryption_key_arn #=> String + # resp.agent.description #=> String # resp.agent.failure_reasons #=> Array # resp.agent.failure_reasons[0] #=> String - # resp.agent.recommended_actions #=> Array - # resp.agent.recommended_actions[0] #=> String + # resp.agent.foundation_model #=> String + # resp.agent.idle_session_ttl_in_seconds #=> Integer + # resp.agent.instruction #=> String + # resp.agent.prepared_at #=> Time + # resp.agent.prompt_override_configuration.override_lambda #=> String # resp.agent.prompt_override_configuration.prompt_configurations #=> Array - # resp.agent.prompt_override_configuration.prompt_configurations[0].prompt_type #=> String, one of "PRE_PROCESSING", "ORCHESTRATION", "POST_PROCESSING", "KNOWLEDGE_BASE_RESPONSE_GENERATION" - # resp.agent.prompt_override_configuration.prompt_configurations[0].prompt_creation_mode #=> String, one of "DEFAULT", "OVERRIDDEN" - # resp.agent.prompt_override_configuration.prompt_configurations[0].prompt_state #=> String, one of "ENABLED", "DISABLED" # resp.agent.prompt_override_configuration.prompt_configurations[0].base_prompt_template #=> String - # resp.agent.prompt_override_configuration.prompt_configurations[0].inference_configuration.temperature #=> Float - # resp.agent.prompt_override_configuration.prompt_configurations[0].inference_configuration.top_p #=> Float - # resp.agent.prompt_override_configuration.prompt_configurations[0].inference_configuration.top_k #=> Integer # resp.agent.prompt_override_configuration.prompt_configurations[0].inference_configuration.maximum_length #=> Integer # resp.agent.prompt_override_configuration.prompt_configurations[0].inference_configuration.stop_sequences #=> Array # resp.agent.prompt_override_configuration.prompt_configurations[0].inference_configuration.stop_sequences[0] #=> String + # resp.agent.prompt_override_configuration.prompt_configurations[0].inference_configuration.temperature #=> Float + # resp.agent.prompt_override_configuration.prompt_configurations[0].inference_configuration.top_k #=> Integer + # resp.agent.prompt_override_configuration.prompt_configurations[0].inference_configuration.top_p #=> Float # resp.agent.prompt_override_configuration.prompt_configurations[0].parser_mode #=> String, one of "DEFAULT", "OVERRIDDEN" - # resp.agent.prompt_override_configuration.override_lambda #=> String + # resp.agent.prompt_override_configuration.prompt_configurations[0].prompt_creation_mode #=> String, one of "DEFAULT", "OVERRIDDEN" + # resp.agent.prompt_override_configuration.prompt_configurations[0].prompt_state #=> String, one of "ENABLED", "DISABLED" + # resp.agent.prompt_override_configuration.prompt_configurations[0].prompt_type #=> String, one of "PRE_PROCESSING", "ORCHESTRATION", "POST_PROCESSING", "KNOWLEDGE_BASE_RESPONSE_GENERATION" + # resp.agent.recommended_actions #=> Array + # resp.agent.recommended_actions[0] #=> String + # resp.agent.updated_at #=> Time # # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/CreateAgent AWS API Documentation # # @overload create_agent(params = {}) # @param [Hash] params ({}) def create_agent(params = {}, options = {}) req = build_request(:create_agent, params) req.send_request(options) end - # Creates an Action Group for existing Amazon Bedrock Agent + # Creates an action group for an agent. An action group represents the + # actions that an agent can carry out for the customer by defining the + # APIs that an agent can call and the logic for calling them. # + # To allow your agent to request the user for additional information + # when trying to complete a task, add an action group with the + # `parentActionGroupSignature` field set to `AMAZON.UserInput`. You must + # leave the `description`, `apiSchema`, and `actionGroupExecutor` fields + # blank for this action group. During orchestration, if your agent + # determines that it needs to invoke an API in an action group, but + # doesn't have enough information to complete the API request, it will + # invoke this action group instead and return an [Observation][1] + # reprompting the user for more information. + # + # + # + # [1]: https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_Observation.html + # + # @option params [Types::ActionGroupExecutor] :action_group_executor + # The ARN of the Lambda function containing the business logic that is + # carried out upon invoking the action. + # + # @option params [required, String] :action_group_name + # The name to give the action group. + # + # @option params [String] :action_group_state + # Specifies whether the action group is available for the agent to + # invoke or not when sending an [InvokeAgent][1] request. + # + # + # + # [1]: https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_InvokeAgent.html + # # @option params [required, String] :agent_id - # Id generated at the server side when an Agent is created + # The unique identifier of the agent for which to create the action + # group. # # @option params [required, String] :agent_version - # Draft Version of the Agent. + # The version of the agent for which to create the action group. # - # @option params [required, String] :action_group_name - # Name for a resource. + # @option params [Types::APISchema] :api_schema + # Contains either details about the S3 object containing the OpenAPI + # schema for the action group or the JSON or YAML-formatted payload + # defining the schema. For more information, see [Action group OpenAPI + # schemas][1]. # + # + # + # [1]: https://docs.aws.amazon.com/bedrock/latest/userguide/agents-api-schema.html + # # @option params [String] :client_token - # Client specified token used for idempotency checks + # A unique, case-sensitive identifier to ensure that the API request + # completes no more than one time. If this token matches a previous + # request, Amazon Bedrock ignores the request, but does not return an + # error. For more information, see [Ensuring idempotency][1]. # # **A suitable default value is auto-generated.** You should normally # not need to pass this option.** # + # + # + # [1]: https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html + # # @option params [String] :description - # Description of the Resource. + # A description of the action group. # # @option params [String] :parent_action_group_signature - # Action Group Signature for a BuiltIn Action + # To allow your agent to request the user for additional information + # when trying to complete a task, set this field to `AMAZON.UserInput`. + # You must leave the `description`, `apiSchema`, and + # `actionGroupExecutor` fields blank for this action group. # - # @option params [Types::ActionGroupExecutor] :action_group_executor - # Type of Executors for an Action Group + # During orchestration, if your agent determines that it needs to invoke + # an API in an action group, but doesn't have enough information to + # complete the API request, it will invoke this action group instead and + # return an [Observation][1] reprompting the user for more information. # - # @option params [Types::APISchema] :api_schema - # Contains information about the API Schema for the Action Group # - # @option params [String] :action_group_state - # State of the action group # + # [1]: https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_Observation.html + # # @return [Types::CreateAgentActionGroupResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: # # * {Types::CreateAgentActionGroupResponse#agent_action_group #agent_action_group} => Types::AgentActionGroup # # @example Request syntax with placeholder values # # resp = client.create_agent_action_group({ - # agent_id: "Id", # required - # agent_version: "DraftVersion", # required - # action_group_name: "Name", # required - # client_token: "ClientToken", - # description: "Description", - # parent_action_group_signature: "AMAZON.UserInput", # accepts AMAZON.UserInput # action_group_executor: { # lambda: "LambdaArn", # }, + # action_group_name: "Name", # required + # action_group_state: "ENABLED", # accepts ENABLED, DISABLED + # agent_id: "Id", # required + # agent_version: "DraftVersion", # required # api_schema: { + # payload: "Payload", # s3: { # s3_bucket_name: "S3BucketName", # s3_object_key: "S3ObjectKey", # }, - # payload: "Payload", # }, - # action_group_state: "ENABLED", # accepts ENABLED, DISABLED + # client_token: "ClientToken", + # description: "Description", + # parent_action_group_signature: "AMAZON.UserInput", # accepts AMAZON.UserInput # }) # # @example Response structure # - # resp.agent_action_group.agent_id #=> String - # resp.agent_action_group.agent_version #=> String + # resp.agent_action_group.action_group_executor.lambda #=> String # resp.agent_action_group.action_group_id #=> String # resp.agent_action_group.action_group_name #=> String + # resp.agent_action_group.action_group_state #=> String, one of "ENABLED", "DISABLED" + # resp.agent_action_group.agent_id #=> String + # resp.agent_action_group.agent_version #=> String + # resp.agent_action_group.api_schema.payload #=> String + # resp.agent_action_group.api_schema.s3.s3_bucket_name #=> String + # resp.agent_action_group.api_schema.s3.s3_object_key #=> String # resp.agent_action_group.client_token #=> String - # resp.agent_action_group.description #=> String # resp.agent_action_group.created_at #=> Time - # resp.agent_action_group.updated_at #=> Time + # resp.agent_action_group.description #=> String # resp.agent_action_group.parent_action_signature #=> String, one of "AMAZON.UserInput" - # resp.agent_action_group.action_group_executor.lambda #=> String - # resp.agent_action_group.api_schema.s3.s3_bucket_name #=> String - # resp.agent_action_group.api_schema.s3.s3_object_key #=> String - # resp.agent_action_group.api_schema.payload #=> String - # resp.agent_action_group.action_group_state #=> String, one of "ENABLED", "DISABLED" + # resp.agent_action_group.updated_at #=> Time # # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/CreateAgentActionGroup AWS API Documentation # # @overload create_agent_action_group(params = {}) # @param [Hash] params ({}) def create_agent_action_group(params = {}, options = {}) req = build_request(:create_agent_action_group, params) req.send_request(options) end - # Creates an Alias for an existing Amazon Bedrock Agent + # Creates an alias of an agent that can be used to deploy the agent. # - # @option params [required, String] :agent_id - # Id generated at the server side when an Agent is created - # # @option params [required, String] :agent_alias_name - # Name for a resource. + # The name of the alias. # + # @option params [required, String] :agent_id + # The unique identifier of the agent. + # # @option params [String] :client_token - # Client specified token used for idempotency checks + # A unique, case-sensitive identifier to ensure that the API request + # completes no more than one time. If this token matches a previous + # request, Amazon Bedrock ignores the request, but does not return an + # error. For more information, see [Ensuring idempotency][1]. # # **A suitable default value is auto-generated.** You should normally # not need to pass this option.** # + # + # + # [1]: https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html + # # @option params [String] :description - # Description of the Resource. + # A description of the alias of the agent. # # @option params [Array<Types::AgentAliasRoutingConfigurationListItem>] :routing_configuration - # Routing configuration for an Agent alias. + # Contains details about the routing configuration of the alias. # # @option params [Hash<String,String>] :tags - # A map of tag keys and values + # Any tags that you want to attach to the alias of the agent. # # @return [Types::CreateAgentAliasResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: # # * {Types::CreateAgentAliasResponse#agent_alias #agent_alias} => Types::AgentAlias # # @example Request syntax with placeholder values # # resp = client.create_agent_alias({ - # agent_id: "Id", # required # agent_alias_name: "Name", # required + # agent_id: "Id", # required # client_token: "ClientToken", # description: "Description", # routing_configuration: [ # { # agent_version: "Version", # required @@ -684,80 +798,91 @@ # }, # }) # # @example Response structure # - # resp.agent_alias.agent_id #=> String + # resp.agent_alias.agent_alias_arn #=> String + # resp.agent_alias.agent_alias_history_events #=> Array + # resp.agent_alias.agent_alias_history_events[0].end_date #=> Time + # resp.agent_alias.agent_alias_history_events[0].routing_configuration #=> Array + # resp.agent_alias.agent_alias_history_events[0].routing_configuration[0].agent_version #=> String + # resp.agent_alias.agent_alias_history_events[0].start_date #=> Time # resp.agent_alias.agent_alias_id #=> String # resp.agent_alias.agent_alias_name #=> String - # resp.agent_alias.agent_alias_arn #=> String + # resp.agent_alias.agent_alias_status #=> String, one of "CREATING", "PREPARED", "FAILED", "UPDATING", "DELETING" + # resp.agent_alias.agent_id #=> String # resp.agent_alias.client_token #=> String + # resp.agent_alias.created_at #=> Time # resp.agent_alias.description #=> String # resp.agent_alias.routing_configuration #=> Array # resp.agent_alias.routing_configuration[0].agent_version #=> String - # resp.agent_alias.created_at #=> Time # resp.agent_alias.updated_at #=> Time - # resp.agent_alias.agent_alias_history_events #=> Array - # resp.agent_alias.agent_alias_history_events[0].routing_configuration #=> Array - # resp.agent_alias.agent_alias_history_events[0].routing_configuration[0].agent_version #=> String - # resp.agent_alias.agent_alias_history_events[0].end_date #=> Time - # resp.agent_alias.agent_alias_history_events[0].start_date #=> Time - # resp.agent_alias.agent_alias_status #=> String, one of "CREATING", "PREPARED", "FAILED", "UPDATING", "DELETING" # # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/CreateAgentAlias AWS API Documentation # # @overload create_agent_alias(params = {}) # @param [Hash] params ({}) def create_agent_alias(params = {}, options = {}) req = build_request(:create_agent_alias, params) req.send_request(options) end - # Create a new data source + # Sets up a data source to be added to a knowledge base. # - # @option params [required, String] :knowledge_base_id - # Identifier for a resource. + # You can't change the `chunkingConfiguration` after you create the + # data source. # # @option params [String] :client_token - # Client specified token used for idempotency checks + # A unique, case-sensitive identifier to ensure that the API request + # completes no more than one time. If this token matches a previous + # request, Amazon Bedrock ignores the request, but does not return an + # error. For more information, see [Ensuring idempotency][1]. # # **A suitable default value is auto-generated.** You should normally # not need to pass this option.** # - # @option params [required, String] :name - # Name for a resource. # - # @option params [String] :description - # Description of the Resource. # + # [1]: https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html + # # @option params [required, Types::DataSourceConfiguration] :data_source_configuration - # Specifies a raw data source location to ingest. + # Contains metadata about where the data source is stored. # + # @option params [String] :description + # A description of the data source. + # + # @option params [required, String] :knowledge_base_id + # The unique identifier of the knowledge base to which to add the data + # source. + # + # @option params [required, String] :name + # The name of the data source. + # # @option params [Types::ServerSideEncryptionConfiguration] :server_side_encryption_configuration - # Server-side encryption configuration. + # Contains details about the server-side encryption for the data source. # # @option params [Types::VectorIngestionConfiguration] :vector_ingestion_configuration - # Configures ingestion for a vector knowledge base + # Contains details about how to ingest the documents in the data source. # # @return [Types::CreateDataSourceResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: # # * {Types::CreateDataSourceResponse#data_source #data_source} => Types::DataSource # # @example Request syntax with placeholder values # # resp = client.create_data_source({ - # knowledge_base_id: "Id", # required # client_token: "ClientToken", - # name: "Name", # required - # description: "Description", # data_source_configuration: { # required - # type: "S3", # required, accepts S3 # s3_configuration: { # bucket_arn: "S3BucketArn", # required # inclusion_prefixes: ["S3Prefix"], # }, + # type: "S3", # required, accepts S3 # }, + # description: "Description", + # knowledge_base_id: "Id", # required + # name: "Name", # required # server_side_encryption_configuration: { # kms_key_arn: "KmsKeyArn", # }, # vector_ingestion_configuration: { # chunking_configuration: { @@ -770,183 +895,239 @@ # }, # }) # # @example Response structure # - # resp.data_source.knowledge_base_id #=> String - # resp.data_source.data_source_id #=> String - # resp.data_source.name #=> String - # resp.data_source.status #=> String, one of "AVAILABLE", "DELETING" - # resp.data_source.description #=> String - # resp.data_source.data_source_configuration.type #=> String, one of "S3" + # resp.data_source.created_at #=> Time # resp.data_source.data_source_configuration.s3_configuration.bucket_arn #=> String # resp.data_source.data_source_configuration.s3_configuration.inclusion_prefixes #=> Array # resp.data_source.data_source_configuration.s3_configuration.inclusion_prefixes[0] #=> String + # resp.data_source.data_source_configuration.type #=> String, one of "S3" + # resp.data_source.data_source_id #=> String + # resp.data_source.description #=> String + # resp.data_source.knowledge_base_id #=> String + # resp.data_source.name #=> String # resp.data_source.server_side_encryption_configuration.kms_key_arn #=> String + # resp.data_source.status #=> String, one of "AVAILABLE", "DELETING" + # resp.data_source.updated_at #=> Time # resp.data_source.vector_ingestion_configuration.chunking_configuration.chunking_strategy #=> String, one of "FIXED_SIZE", "NONE" # resp.data_source.vector_ingestion_configuration.chunking_configuration.fixed_size_chunking_configuration.max_tokens #=> Integer # resp.data_source.vector_ingestion_configuration.chunking_configuration.fixed_size_chunking_configuration.overlap_percentage #=> Integer - # resp.data_source.created_at #=> Time - # resp.data_source.updated_at #=> Time # # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/CreateDataSource AWS API Documentation # # @overload create_data_source(params = {}) # @param [Hash] params ({}) def create_data_source(params = {}, options = {}) req = build_request(:create_data_source, params) req.send_request(options) end - # Create a new knowledge base + # Creates a knowledge base that contains data sources from which + # information can be queried and used by LLMs. To create a knowledge + # base, you must first set up your data sources and configure a + # supported vector store. For more information, see [Set up your data + # for ingestion][1]. # + # <note markdown="1"> If you prefer to let Amazon Bedrock create and manage a vector store + # for you in Amazon OpenSearch Service, use the console. For more + # information, see [Create a knowledge base][2]. + # + # </note> + # + # * Provide the `name` and an optional `description`. + # + # * Provide the ARN with permissions to create a knowledge base in the + # `roleArn` field. + # + # * Provide the embedding model to use in the `embeddingModelArn` field + # in the `knowledgeBaseConfiguration` object. + # + # * Provide the configuration for your vector store in the + # `storageConfiguration` object. + # + # * For an Amazon OpenSearch Service database, use the + # `opensearchServerlessConfiguration` object. For more information, + # see [Create a vector store in Amazon OpenSearch Service][3]. + # + # * For an Amazon Aurora database, use the `RdsConfiguration` object. + # For more information, see [Create a vector store in Amazon + # Aurora][4]. + # + # * For a Pinecone database, use the `pineconeConfiguration` object. + # For more information, see [Create a vector store in Pinecone][5]. + # + # * For a Redis Enterprise Cloud database, use the + # `redisEnterpriseCloudConfiguration` object. For more information, + # see [Create a vector store in Redis Enterprise Cloud][6]. + # + # + # + # [1]: https://docs.aws.amazon.com/bedrock/latest/userguide/knowledge-base-setup.html + # [2]: https://docs.aws.amazon.com/bedrock/latest/userguide/knowledge-base-create + # [3]: https://docs.aws.amazon.com/bedrock/latest/userguide/knowledge-base-setup-oss.html + # [4]: https://docs.aws.amazon.com/bedrock/latest/userguide/knowledge-base-setup-rds.html + # [5]: https://docs.aws.amazon.com/bedrock/latest/userguide/knowledge-base-setup-pinecone.html + # [6]: https://docs.aws.amazon.com/bedrock/latest/userguide/knowledge-base-setup-redis.html + # # @option params [String] :client_token - # Client specified token used for idempotency checks + # A unique, case-sensitive identifier to ensure that the API request + # completes no more than one time. If this token matches a previous + # request, Amazon Bedrock ignores the request, but does not return an + # error. For more information, see [Ensuring idempotency][1]. # # **A suitable default value is auto-generated.** You should normally # not need to pass this option.** # - # @option params [required, String] :name - # Name for a resource. # - # @option params [String] :description - # Description of the Resource. # - # @option params [required, String] :role_arn - # ARN of a IAM role. + # [1]: https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html # + # @option params [String] :description + # A description of the knowledge base. + # # @option params [required, Types::KnowledgeBaseConfiguration] :knowledge_base_configuration - # Configures a bedrock knowledge base. + # Contains details about the embeddings model used for the knowledge + # base. # + # @option params [required, String] :name + # A name for the knowledge base. + # + # @option params [required, String] :role_arn + # The ARN of the IAM role with permissions to create the knowledge base. + # # @option params [required, Types::StorageConfiguration] :storage_configuration - # Configures the physical storage of ingested data in a knowledge base. + # Contains details about the configuration of the vector database used + # for the knowledge base. # # @option params [Hash<String,String>] :tags - # A map of tag keys and values + # Specify the key-value pairs for the tags that you want to attach to + # your knowledge base in this object. # # @return [Types::CreateKnowledgeBaseResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: # # * {Types::CreateKnowledgeBaseResponse#knowledge_base #knowledge_base} => Types::KnowledgeBase # # @example Request syntax with placeholder values # # resp = client.create_knowledge_base({ # client_token: "ClientToken", - # name: "Name", # required # description: "Description", - # role_arn: "KnowledgeBaseRoleArn", # required # knowledge_base_configuration: { # required # type: "VECTOR", # required, accepts VECTOR # vector_knowledge_base_configuration: { # embedding_model_arn: "BedrockEmbeddingModelArn", # required # }, # }, + # name: "Name", # required + # role_arn: "KnowledgeBaseRoleArn", # required # storage_configuration: { # required - # type: "OPENSEARCH_SERVERLESS", # required, accepts OPENSEARCH_SERVERLESS, PINECONE, REDIS_ENTERPRISE_CLOUD, RDS # opensearch_serverless_configuration: { # collection_arn: "OpenSearchServerlessCollectionArn", # required - # vector_index_name: "OpenSearchServerlessIndexName", # required # field_mapping: { # required - # vector_field: "FieldName", # required - # text_field: "FieldName", # required # metadata_field: "FieldName", # required + # text_field: "FieldName", # required + # vector_field: "FieldName", # required # }, + # vector_index_name: "OpenSearchServerlessIndexName", # required # }, # pinecone_configuration: { # connection_string: "PineconeConnectionString", # required # credentials_secret_arn: "SecretArn", # required - # namespace: "PineconeNamespace", # field_mapping: { # required - # text_field: "FieldName", # required # metadata_field: "FieldName", # required - # }, - # }, - # redis_enterprise_cloud_configuration: { - # endpoint: "RedisEnterpriseCloudEndpoint", # required - # vector_index_name: "RedisEnterpriseCloudIndexName", # required - # credentials_secret_arn: "SecretArn", # required - # field_mapping: { # required - # vector_field: "FieldName", # required # text_field: "FieldName", # required - # metadata_field: "FieldName", # required # }, + # namespace: "PineconeNamespace", # }, # rds_configuration: { - # resource_arn: "RdsArn", # required # credentials_secret_arn: "SecretArn", # required # database_name: "RdsDatabaseName", # required - # table_name: "RdsTableName", # required # field_mapping: { # required + # metadata_field: "ColumnName", # required # primary_key_field: "ColumnName", # required - # vector_field: "ColumnName", # required # text_field: "ColumnName", # required - # metadata_field: "ColumnName", # required + # vector_field: "ColumnName", # required # }, + # resource_arn: "RdsArn", # required + # table_name: "RdsTableName", # required # }, + # redis_enterprise_cloud_configuration: { + # credentials_secret_arn: "SecretArn", # required + # endpoint: "RedisEnterpriseCloudEndpoint", # required + # field_mapping: { # required + # metadata_field: "FieldName", # required + # text_field: "FieldName", # required + # vector_field: "FieldName", # required + # }, + # vector_index_name: "RedisEnterpriseCloudIndexName", # required + # }, + # type: "OPENSEARCH_SERVERLESS", # required, accepts OPENSEARCH_SERVERLESS, PINECONE, REDIS_ENTERPRISE_CLOUD, RDS # }, # tags: { # "TagKey" => "TagValue", # }, # }) # # @example Response structure # - # resp.knowledge_base.knowledge_base_id #=> String - # resp.knowledge_base.name #=> String - # resp.knowledge_base.knowledge_base_arn #=> String + # resp.knowledge_base.created_at #=> Time # resp.knowledge_base.description #=> String - # resp.knowledge_base.role_arn #=> String + # resp.knowledge_base.failure_reasons #=> Array + # resp.knowledge_base.failure_reasons[0] #=> String + # resp.knowledge_base.knowledge_base_arn #=> String # resp.knowledge_base.knowledge_base_configuration.type #=> String, one of "VECTOR" # resp.knowledge_base.knowledge_base_configuration.vector_knowledge_base_configuration.embedding_model_arn #=> String - # resp.knowledge_base.storage_configuration.type #=> String, one of "OPENSEARCH_SERVERLESS", "PINECONE", "REDIS_ENTERPRISE_CLOUD", "RDS" + # resp.knowledge_base.knowledge_base_id #=> String + # resp.knowledge_base.name #=> String + # resp.knowledge_base.role_arn #=> String + # resp.knowledge_base.status #=> String, one of "CREATING", "ACTIVE", "DELETING", "UPDATING", "FAILED" # resp.knowledge_base.storage_configuration.opensearch_serverless_configuration.collection_arn #=> String - # resp.knowledge_base.storage_configuration.opensearch_serverless_configuration.vector_index_name #=> String - # resp.knowledge_base.storage_configuration.opensearch_serverless_configuration.field_mapping.vector_field #=> String - # resp.knowledge_base.storage_configuration.opensearch_serverless_configuration.field_mapping.text_field #=> String # resp.knowledge_base.storage_configuration.opensearch_serverless_configuration.field_mapping.metadata_field #=> String + # resp.knowledge_base.storage_configuration.opensearch_serverless_configuration.field_mapping.text_field #=> String + # resp.knowledge_base.storage_configuration.opensearch_serverless_configuration.field_mapping.vector_field #=> String + # resp.knowledge_base.storage_configuration.opensearch_serverless_configuration.vector_index_name #=> String # resp.knowledge_base.storage_configuration.pinecone_configuration.connection_string #=> String # resp.knowledge_base.storage_configuration.pinecone_configuration.credentials_secret_arn #=> String - # resp.knowledge_base.storage_configuration.pinecone_configuration.namespace #=> String - # resp.knowledge_base.storage_configuration.pinecone_configuration.field_mapping.text_field #=> String # resp.knowledge_base.storage_configuration.pinecone_configuration.field_mapping.metadata_field #=> String - # resp.knowledge_base.storage_configuration.redis_enterprise_cloud_configuration.endpoint #=> String - # resp.knowledge_base.storage_configuration.redis_enterprise_cloud_configuration.vector_index_name #=> String - # resp.knowledge_base.storage_configuration.redis_enterprise_cloud_configuration.credentials_secret_arn #=> String - # resp.knowledge_base.storage_configuration.redis_enterprise_cloud_configuration.field_mapping.vector_field #=> String - # resp.knowledge_base.storage_configuration.redis_enterprise_cloud_configuration.field_mapping.text_field #=> String - # resp.knowledge_base.storage_configuration.redis_enterprise_cloud_configuration.field_mapping.metadata_field #=> String - # resp.knowledge_base.storage_configuration.rds_configuration.resource_arn #=> String + # resp.knowledge_base.storage_configuration.pinecone_configuration.field_mapping.text_field #=> String + # resp.knowledge_base.storage_configuration.pinecone_configuration.namespace #=> String # resp.knowledge_base.storage_configuration.rds_configuration.credentials_secret_arn #=> String # resp.knowledge_base.storage_configuration.rds_configuration.database_name #=> String - # resp.knowledge_base.storage_configuration.rds_configuration.table_name #=> String + # resp.knowledge_base.storage_configuration.rds_configuration.field_mapping.metadata_field #=> String # resp.knowledge_base.storage_configuration.rds_configuration.field_mapping.primary_key_field #=> String - # resp.knowledge_base.storage_configuration.rds_configuration.field_mapping.vector_field #=> String # resp.knowledge_base.storage_configuration.rds_configuration.field_mapping.text_field #=> String - # resp.knowledge_base.storage_configuration.rds_configuration.field_mapping.metadata_field #=> String - # resp.knowledge_base.status #=> String, one of "CREATING", "ACTIVE", "DELETING", "UPDATING", "FAILED" - # resp.knowledge_base.created_at #=> Time + # resp.knowledge_base.storage_configuration.rds_configuration.field_mapping.vector_field #=> String + # resp.knowledge_base.storage_configuration.rds_configuration.resource_arn #=> String + # resp.knowledge_base.storage_configuration.rds_configuration.table_name #=> String + # resp.knowledge_base.storage_configuration.redis_enterprise_cloud_configuration.credentials_secret_arn #=> String + # resp.knowledge_base.storage_configuration.redis_enterprise_cloud_configuration.endpoint #=> String + # resp.knowledge_base.storage_configuration.redis_enterprise_cloud_configuration.field_mapping.metadata_field #=> String + # resp.knowledge_base.storage_configuration.redis_enterprise_cloud_configuration.field_mapping.text_field #=> String + # resp.knowledge_base.storage_configuration.redis_enterprise_cloud_configuration.field_mapping.vector_field #=> String + # resp.knowledge_base.storage_configuration.redis_enterprise_cloud_configuration.vector_index_name #=> String + # resp.knowledge_base.storage_configuration.type #=> String, one of "OPENSEARCH_SERVERLESS", "PINECONE", "REDIS_ENTERPRISE_CLOUD", "RDS" # resp.knowledge_base.updated_at #=> Time - # resp.knowledge_base.failure_reasons #=> Array - # resp.knowledge_base.failure_reasons[0] #=> String # # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/CreateKnowledgeBase AWS API Documentation # # @overload create_knowledge_base(params = {}) # @param [Hash] params ({}) def create_knowledge_base(params = {}, options = {}) req = build_request(:create_knowledge_base, params) req.send_request(options) end - # Deletes an Agent for existing Amazon Bedrock Agent + # Deletes an agent. # # @option params [required, String] :agent_id - # Id generated at the server side when an Agent is created + # The unique identifier of the agent to delete. # # @option params [Boolean] :skip_resource_in_use_check - # Skips checking if resource is in use when set to true. Defaults to - # false + # By default, this value is `false` and deletion is stopped if the + # resource is in use. If you set it to `true`, the resource will be + # deleted even if the resource is in use. # # @return [Types::DeleteAgentResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: # # * {Types::DeleteAgentResponse#agent_id #agent_id} => String # * {Types::DeleteAgentResponse#agent_status #agent_status} => String @@ -970,33 +1151,34 @@ def delete_agent(params = {}, options = {}) req = build_request(:delete_agent, params) req.send_request(options) end - # Deletes an Action Group for existing Amazon Bedrock Agent. + # Deletes an action group in an agent. # + # @option params [required, String] :action_group_id + # The unique identifier of the action group to delete. + # # @option params [required, String] :agent_id - # Id generated at the server side when an Agent is created + # The unique identifier of the agent that the action group belongs to. # # @option params [required, String] :agent_version - # Draft Version of the Agent. + # The version of the agent that the action group belongs to. # - # @option params [required, String] :action_group_id - # Id generated at the server side when an Agent ActionGroup is created - # # @option params [Boolean] :skip_resource_in_use_check - # Skips checking if resource is in use when set to true. Defaults to - # false + # By default, this value is `false` and deletion is stopped if the + # resource is in use. If you set it to `true`, the resource will be + # deleted even if the resource is in use. # # @return [Struct] Returns an empty {Seahorse::Client::Response response}. # # @example Request syntax with placeholder values # # resp = client.delete_agent_action_group({ + # action_group_id: "Id", # required # agent_id: "Id", # required # agent_version: "DraftVersion", # required - # action_group_id: "Id", # required # skip_resource_in_use_check: false, # }) # # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/DeleteAgentActionGroup AWS API Documentation # @@ -1005,63 +1187,64 @@ def delete_agent_action_group(params = {}, options = {}) req = build_request(:delete_agent_action_group, params) req.send_request(options) end - # Deletes an Alias for a Amazon Bedrock Agent + # Deletes an alias of an agent. # - # @option params [required, String] :agent_id - # Id generated at the server side when an Agent is created - # # @option params [required, String] :agent_alias_id - # Id generated at the server side when an Agent Alias is created + # The unique identifier of the alias to delete. # + # @option params [required, String] :agent_id + # The unique identifier of the agent that the alias belongs to. + # # @return [Types::DeleteAgentAliasResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: # - # * {Types::DeleteAgentAliasResponse#agent_id #agent_id} => String # * {Types::DeleteAgentAliasResponse#agent_alias_id #agent_alias_id} => String # * {Types::DeleteAgentAliasResponse#agent_alias_status #agent_alias_status} => String + # * {Types::DeleteAgentAliasResponse#agent_id #agent_id} => String # # @example Request syntax with placeholder values # # resp = client.delete_agent_alias({ - # agent_id: "Id", # required # agent_alias_id: "AgentAliasId", # required + # agent_id: "Id", # required # }) # # @example Response structure # - # resp.agent_id #=> String # resp.agent_alias_id #=> String # resp.agent_alias_status #=> String, one of "CREATING", "PREPARED", "FAILED", "UPDATING", "DELETING" + # resp.agent_id #=> String # # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/DeleteAgentAlias AWS API Documentation # # @overload delete_agent_alias(params = {}) # @param [Hash] params ({}) def delete_agent_alias(params = {}, options = {}) req = build_request(:delete_agent_alias, params) req.send_request(options) end - # Deletes an Agent version for existing Amazon Bedrock Agent + # Deletes a version of an agent. # # @option params [required, String] :agent_id - # Id generated at the server side when an Agent is created + # The unique identifier of the agent that the version belongs to. # # @option params [required, String] :agent_version - # Numerical Agent Version. + # The version of the agent to delete. # # @option params [Boolean] :skip_resource_in_use_check - # Skips checking if resource is in use when set to true. Defaults to - # false + # By default, this value is `false` and deletion is stopped if the + # resource is in use. If you set it to `true`, the resource will be + # deleted even if the resource is in use. # # @return [Types::DeleteAgentVersionResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: # # * {Types::DeleteAgentVersionResponse#agent_id #agent_id} => String - # * {Types::DeleteAgentVersionResponse#agent_version #agent_version} => String # * {Types::DeleteAgentVersionResponse#agent_status #agent_status} => String + # * {Types::DeleteAgentVersionResponse#agent_version #agent_version} => String # # @example Request syntax with placeholder values # # resp = client.delete_agent_version({ # agent_id: "Id", # required @@ -1070,47 +1253,48 @@ # }) # # @example Response structure # # resp.agent_id #=> String - # resp.agent_version #=> String # resp.agent_status #=> String, one of "CREATING", "PREPARING", "PREPARED", "NOT_PREPARED", "DELETING", "FAILED", "VERSIONING", "UPDATING" + # resp.agent_version #=> String # # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/DeleteAgentVersion AWS API Documentation # # @overload delete_agent_version(params = {}) # @param [Hash] params ({}) def delete_agent_version(params = {}, options = {}) req = build_request(:delete_agent_version, params) req.send_request(options) end - # Delete an existing data source + # Deletes a data source from a knowledge base. # - # @option params [required, String] :knowledge_base_id - # Identifier for a resource. - # # @option params [required, String] :data_source_id - # Identifier for a resource. + # The unique identifier of the data source to delete. # + # @option params [required, String] :knowledge_base_id + # The unique identifier of the knowledge base from which to delete the + # data source. + # # @return [Types::DeleteDataSourceResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: # - # * {Types::DeleteDataSourceResponse#knowledge_base_id #knowledge_base_id} => String # * {Types::DeleteDataSourceResponse#data_source_id #data_source_id} => String + # * {Types::DeleteDataSourceResponse#knowledge_base_id #knowledge_base_id} => String # * {Types::DeleteDataSourceResponse#status #status} => String # # @example Request syntax with placeholder values # # resp = client.delete_data_source({ - # knowledge_base_id: "Id", # required # data_source_id: "Id", # required + # knowledge_base_id: "Id", # required # }) # # @example Response structure # - # resp.knowledge_base_id #=> String # resp.data_source_id #=> String + # resp.knowledge_base_id #=> String # resp.status #=> String, one of "AVAILABLE", "DELETING" # # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/DeleteDataSource AWS API Documentation # # @overload delete_data_source(params = {}) @@ -1118,14 +1302,20 @@ def delete_data_source(params = {}, options = {}) req = build_request(:delete_data_source, params) req.send_request(options) end - # Delete an existing knowledge base + # Deletes a knowledge base. Before deleting a knowledge base, you should + # disassociate the knowledge base from any agents that it is associated + # with by making a [DisassociateAgentKnowledgeBase][1] request. # + # + # + # [1]: https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_DisassociateAgentKnowledgeBase.html + # # @option params [required, String] :knowledge_base_id - # Identifier for a resource. + # The unique identifier of the knowledge base to delete. # # @return [Types::DeleteKnowledgeBaseResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: # # * {Types::DeleteKnowledgeBaseResponse#knowledge_base_id #knowledge_base_id} => String # * {Types::DeleteKnowledgeBaseResponse#status #status} => String @@ -1148,21 +1338,22 @@ def delete_knowledge_base(params = {}, options = {}) req = build_request(:delete_knowledge_base, params) req.send_request(options) end - # Disassociate an existing Knowledge Base from an Amazon Bedrock Agent + # Disassociates a knowledge base from an agent. # # @option params [required, String] :agent_id - # Id generated at the server side when an Agent is created + # The unique identifier of the agent from which to disassociate the + # knowledge base. # # @option params [required, String] :agent_version - # Draft Version of the Agent. + # The version of the agent from which to disassociate the knowledge + # base. # # @option params [required, String] :knowledge_base_id - # Id generated at the server side when a Knowledge Base is associated to - # an Agent + # The unique identifier of the knowledge base to disassociate. # # @return [Struct] Returns an empty {Seahorse::Client::Response response}. # # @example Request syntax with placeholder values # @@ -1179,14 +1370,14 @@ def disassociate_agent_knowledge_base(params = {}, options = {}) req = build_request(:disassociate_agent_knowledge_base, params) req.send_request(options) end - # Gets an Agent for existing Amazon Bedrock Agent + # Gets information about an agent. # # @option params [required, String] :agent_id - # Id generated at the server side when an Agent is created + # The unique identifier of the agent. # # @return [Types::GetAgentResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: # # * {Types::GetAgentResponse#agent #agent} => Types::Agent # @@ -1196,159 +1387,161 @@ # agent_id: "Id", # required # }) # # @example Response structure # + # resp.agent.agent_arn #=> String # resp.agent.agent_id #=> String # resp.agent.agent_name #=> String - # resp.agent.agent_arn #=> String + # resp.agent.agent_resource_role_arn #=> String + # resp.agent.agent_status #=> String, one of "CREATING", "PREPARING", "PREPARED", "NOT_PREPARED", "DELETING", "FAILED", "VERSIONING", "UPDATING" # resp.agent.agent_version #=> String # resp.agent.client_token #=> String - # resp.agent.instruction #=> String - # resp.agent.agent_status #=> String, one of "CREATING", "PREPARING", "PREPARED", "NOT_PREPARED", "DELETING", "FAILED", "VERSIONING", "UPDATING" - # resp.agent.foundation_model #=> String - # resp.agent.description #=> String - # resp.agent.idle_session_ttl_in_seconds #=> Integer - # resp.agent.agent_resource_role_arn #=> String - # resp.agent.customer_encryption_key_arn #=> String # resp.agent.created_at #=> Time - # resp.agent.updated_at #=> Time - # resp.agent.prepared_at #=> Time + # resp.agent.customer_encryption_key_arn #=> String + # resp.agent.description #=> String # resp.agent.failure_reasons #=> Array # resp.agent.failure_reasons[0] #=> String - # resp.agent.recommended_actions #=> Array - # resp.agent.recommended_actions[0] #=> String + # resp.agent.foundation_model #=> String + # resp.agent.idle_session_ttl_in_seconds #=> Integer + # resp.agent.instruction #=> String + # resp.agent.prepared_at #=> Time + # resp.agent.prompt_override_configuration.override_lambda #=> String # resp.agent.prompt_override_configuration.prompt_configurations #=> Array - # resp.agent.prompt_override_configuration.prompt_configurations[0].prompt_type #=> String, one of "PRE_PROCESSING", "ORCHESTRATION", "POST_PROCESSING", "KNOWLEDGE_BASE_RESPONSE_GENERATION" - # resp.agent.prompt_override_configuration.prompt_configurations[0].prompt_creation_mode #=> String, one of "DEFAULT", "OVERRIDDEN" - # resp.agent.prompt_override_configuration.prompt_configurations[0].prompt_state #=> String, one of "ENABLED", "DISABLED" # resp.agent.prompt_override_configuration.prompt_configurations[0].base_prompt_template #=> String - # resp.agent.prompt_override_configuration.prompt_configurations[0].inference_configuration.temperature #=> Float - # resp.agent.prompt_override_configuration.prompt_configurations[0].inference_configuration.top_p #=> Float - # resp.agent.prompt_override_configuration.prompt_configurations[0].inference_configuration.top_k #=> Integer # resp.agent.prompt_override_configuration.prompt_configurations[0].inference_configuration.maximum_length #=> Integer # resp.agent.prompt_override_configuration.prompt_configurations[0].inference_configuration.stop_sequences #=> Array # resp.agent.prompt_override_configuration.prompt_configurations[0].inference_configuration.stop_sequences[0] #=> String + # resp.agent.prompt_override_configuration.prompt_configurations[0].inference_configuration.temperature #=> Float + # resp.agent.prompt_override_configuration.prompt_configurations[0].inference_configuration.top_k #=> Integer + # resp.agent.prompt_override_configuration.prompt_configurations[0].inference_configuration.top_p #=> Float # resp.agent.prompt_override_configuration.prompt_configurations[0].parser_mode #=> String, one of "DEFAULT", "OVERRIDDEN" - # resp.agent.prompt_override_configuration.override_lambda #=> String + # resp.agent.prompt_override_configuration.prompt_configurations[0].prompt_creation_mode #=> String, one of "DEFAULT", "OVERRIDDEN" + # resp.agent.prompt_override_configuration.prompt_configurations[0].prompt_state #=> String, one of "ENABLED", "DISABLED" + # resp.agent.prompt_override_configuration.prompt_configurations[0].prompt_type #=> String, one of "PRE_PROCESSING", "ORCHESTRATION", "POST_PROCESSING", "KNOWLEDGE_BASE_RESPONSE_GENERATION" + # resp.agent.recommended_actions #=> Array + # resp.agent.recommended_actions[0] #=> String + # resp.agent.updated_at #=> Time # # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetAgent AWS API Documentation # # @overload get_agent(params = {}) # @param [Hash] params ({}) def get_agent(params = {}, options = {}) req = build_request(:get_agent, params) req.send_request(options) end - # Gets an Action Group for existing Amazon Bedrock Agent Version + # Gets information about an action group for an agent. # + # @option params [required, String] :action_group_id + # The unique identifier of the action group for which to get + # information. + # # @option params [required, String] :agent_id - # Id generated at the server side when an Agent is created + # The unique identifier of the agent that the action group belongs to. # # @option params [required, String] :agent_version - # Version number generated when a version is created + # The version of the agent that the action group belongs to. # - # @option params [required, String] :action_group_id - # Id generated at the server side when an Agent Action Group is created - # # @return [Types::GetAgentActionGroupResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: # # * {Types::GetAgentActionGroupResponse#agent_action_group #agent_action_group} => Types::AgentActionGroup # # @example Request syntax with placeholder values # # resp = client.get_agent_action_group({ + # action_group_id: "Id", # required # agent_id: "Id", # required # agent_version: "Version", # required - # action_group_id: "Id", # required # }) # # @example Response structure # - # resp.agent_action_group.agent_id #=> String - # resp.agent_action_group.agent_version #=> String + # resp.agent_action_group.action_group_executor.lambda #=> String # resp.agent_action_group.action_group_id #=> String # resp.agent_action_group.action_group_name #=> String + # resp.agent_action_group.action_group_state #=> String, one of "ENABLED", "DISABLED" + # resp.agent_action_group.agent_id #=> String + # resp.agent_action_group.agent_version #=> String + # resp.agent_action_group.api_schema.payload #=> String + # resp.agent_action_group.api_schema.s3.s3_bucket_name #=> String + # resp.agent_action_group.api_schema.s3.s3_object_key #=> String # resp.agent_action_group.client_token #=> String - # resp.agent_action_group.description #=> String # resp.agent_action_group.created_at #=> Time - # resp.agent_action_group.updated_at #=> Time + # resp.agent_action_group.description #=> String # resp.agent_action_group.parent_action_signature #=> String, one of "AMAZON.UserInput" - # resp.agent_action_group.action_group_executor.lambda #=> String - # resp.agent_action_group.api_schema.s3.s3_bucket_name #=> String - # resp.agent_action_group.api_schema.s3.s3_object_key #=> String - # resp.agent_action_group.api_schema.payload #=> String - # resp.agent_action_group.action_group_state #=> String, one of "ENABLED", "DISABLED" + # resp.agent_action_group.updated_at #=> Time # # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetAgentActionGroup AWS API Documentation # # @overload get_agent_action_group(params = {}) # @param [Hash] params ({}) def get_agent_action_group(params = {}, options = {}) req = build_request(:get_agent_action_group, params) req.send_request(options) end - # Describes an Alias for a Amazon Bedrock Agent + # Gets information about an alias of an agent. # - # @option params [required, String] :agent_id - # Id generated at the server side when an Agent is created - # # @option params [required, String] :agent_alias_id - # Id generated at the server side when an Agent Alias is created + # The unique identifier of the alias for which to get information. # + # @option params [required, String] :agent_id + # The unique identifier of the agent to which the alias to get + # information belongs. + # # @return [Types::GetAgentAliasResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: # # * {Types::GetAgentAliasResponse#agent_alias #agent_alias} => Types::AgentAlias # # @example Request syntax with placeholder values # # resp = client.get_agent_alias({ - # agent_id: "Id", # required # agent_alias_id: "AgentAliasId", # required + # agent_id: "Id", # required # }) # # @example Response structure # - # resp.agent_alias.agent_id #=> String + # resp.agent_alias.agent_alias_arn #=> String + # resp.agent_alias.agent_alias_history_events #=> Array + # resp.agent_alias.agent_alias_history_events[0].end_date #=> Time + # resp.agent_alias.agent_alias_history_events[0].routing_configuration #=> Array + # resp.agent_alias.agent_alias_history_events[0].routing_configuration[0].agent_version #=> String + # resp.agent_alias.agent_alias_history_events[0].start_date #=> Time # resp.agent_alias.agent_alias_id #=> String # resp.agent_alias.agent_alias_name #=> String - # resp.agent_alias.agent_alias_arn #=> String + # resp.agent_alias.agent_alias_status #=> String, one of "CREATING", "PREPARED", "FAILED", "UPDATING", "DELETING" + # resp.agent_alias.agent_id #=> String # resp.agent_alias.client_token #=> String + # resp.agent_alias.created_at #=> Time # resp.agent_alias.description #=> String # resp.agent_alias.routing_configuration #=> Array # resp.agent_alias.routing_configuration[0].agent_version #=> String - # resp.agent_alias.created_at #=> Time # resp.agent_alias.updated_at #=> Time - # resp.agent_alias.agent_alias_history_events #=> Array - # resp.agent_alias.agent_alias_history_events[0].routing_configuration #=> Array - # resp.agent_alias.agent_alias_history_events[0].routing_configuration[0].agent_version #=> String - # resp.agent_alias.agent_alias_history_events[0].end_date #=> Time - # resp.agent_alias.agent_alias_history_events[0].start_date #=> Time - # resp.agent_alias.agent_alias_status #=> String, one of "CREATING", "PREPARED", "FAILED", "UPDATING", "DELETING" # # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetAgentAlias AWS API Documentation # # @overload get_agent_alias(params = {}) # @param [Hash] params ({}) def get_agent_alias(params = {}, options = {}) req = build_request(:get_agent_alias, params) req.send_request(options) end - # Gets a knowledge base associated to an existing Amazon Bedrock Agent - # Version + # Gets information about a knowledge base associated with an agent. # # @option params [required, String] :agent_id - # Id generated at the server side when an Agent is created + # The unique identifier of the agent with which the knowledge base is + # associated. # # @option params [required, String] :agent_version - # Version number generated when a version is created + # The version of the agent with which the knowledge base is associated. # # @option params [required, String] :knowledge_base_id - # Id generated at the server side when a Knowledge Base is associated + # The unique identifier of the knowledge base associated with the agent. # # @return [Types::GetAgentKnowledgeBaseResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: # # * {Types::GetAgentKnowledgeBaseResponse#agent_knowledge_base #agent_knowledge_base} => Types::AgentKnowledgeBase # @@ -1362,32 +1555,32 @@ # # @example Response structure # # resp.agent_knowledge_base.agent_id #=> String # resp.agent_knowledge_base.agent_version #=> String - # resp.agent_knowledge_base.knowledge_base_id #=> String - # resp.agent_knowledge_base.description #=> String # resp.agent_knowledge_base.created_at #=> Time - # resp.agent_knowledge_base.updated_at #=> Time + # resp.agent_knowledge_base.description #=> String + # resp.agent_knowledge_base.knowledge_base_id #=> String # resp.agent_knowledge_base.knowledge_base_state #=> String, one of "ENABLED", "DISABLED" + # resp.agent_knowledge_base.updated_at #=> Time # # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetAgentKnowledgeBase AWS API Documentation # # @overload get_agent_knowledge_base(params = {}) # @param [Hash] params ({}) def get_agent_knowledge_base(params = {}, options = {}) req = build_request(:get_agent_knowledge_base, params) req.send_request(options) end - # Gets an Agent version for existing Amazon Bedrock Agent + # Gets details about a version of an agent. # # @option params [required, String] :agent_id - # Id generated at the server side when an Agent is created + # The unique identifier of the agent. # # @option params [required, String] :agent_version - # Numerical Agent Version. + # The version of the agent. # # @return [Types::GetAgentVersionResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: # # * {Types::GetAgentVersionResponse#agent_version #agent_version} => Types::AgentVersion # @@ -1398,134 +1591,139 @@ # agent_version: "NumericalVersion", # required # }) # # @example Response structure # + # resp.agent_version.agent_arn #=> String # resp.agent_version.agent_id #=> String # resp.agent_version.agent_name #=> String - # resp.agent_version.agent_arn #=> String - # resp.agent_version.version #=> String - # resp.agent_version.instruction #=> String - # resp.agent_version.agent_status #=> String, one of "CREATING", "PREPARING", "PREPARED", "NOT_PREPARED", "DELETING", "FAILED", "VERSIONING", "UPDATING" - # resp.agent_version.foundation_model #=> String - # resp.agent_version.description #=> String - # resp.agent_version.idle_session_ttl_in_seconds #=> Integer # resp.agent_version.agent_resource_role_arn #=> String - # resp.agent_version.customer_encryption_key_arn #=> String + # resp.agent_version.agent_status #=> String, one of "CREATING", "PREPARING", "PREPARED", "NOT_PREPARED", "DELETING", "FAILED", "VERSIONING", "UPDATING" # resp.agent_version.created_at #=> Time - # resp.agent_version.updated_at #=> Time + # resp.agent_version.customer_encryption_key_arn #=> String + # resp.agent_version.description #=> String # resp.agent_version.failure_reasons #=> Array # resp.agent_version.failure_reasons[0] #=> String - # resp.agent_version.recommended_actions #=> Array - # resp.agent_version.recommended_actions[0] #=> String + # resp.agent_version.foundation_model #=> String + # resp.agent_version.idle_session_ttl_in_seconds #=> Integer + # resp.agent_version.instruction #=> String + # resp.agent_version.prompt_override_configuration.override_lambda #=> String # resp.agent_version.prompt_override_configuration.prompt_configurations #=> Array - # resp.agent_version.prompt_override_configuration.prompt_configurations[0].prompt_type #=> String, one of "PRE_PROCESSING", "ORCHESTRATION", "POST_PROCESSING", "KNOWLEDGE_BASE_RESPONSE_GENERATION" - # resp.agent_version.prompt_override_configuration.prompt_configurations[0].prompt_creation_mode #=> String, one of "DEFAULT", "OVERRIDDEN" - # resp.agent_version.prompt_override_configuration.prompt_configurations[0].prompt_state #=> String, one of "ENABLED", "DISABLED" # resp.agent_version.prompt_override_configuration.prompt_configurations[0].base_prompt_template #=> String - # resp.agent_version.prompt_override_configuration.prompt_configurations[0].inference_configuration.temperature #=> Float - # resp.agent_version.prompt_override_configuration.prompt_configurations[0].inference_configuration.top_p #=> Float - # resp.agent_version.prompt_override_configuration.prompt_configurations[0].inference_configuration.top_k #=> Integer # resp.agent_version.prompt_override_configuration.prompt_configurations[0].inference_configuration.maximum_length #=> Integer # resp.agent_version.prompt_override_configuration.prompt_configurations[0].inference_configuration.stop_sequences #=> Array # resp.agent_version.prompt_override_configuration.prompt_configurations[0].inference_configuration.stop_sequences[0] #=> String + # resp.agent_version.prompt_override_configuration.prompt_configurations[0].inference_configuration.temperature #=> Float + # resp.agent_version.prompt_override_configuration.prompt_configurations[0].inference_configuration.top_k #=> Integer + # resp.agent_version.prompt_override_configuration.prompt_configurations[0].inference_configuration.top_p #=> Float # resp.agent_version.prompt_override_configuration.prompt_configurations[0].parser_mode #=> String, one of "DEFAULT", "OVERRIDDEN" - # resp.agent_version.prompt_override_configuration.override_lambda #=> String + # resp.agent_version.prompt_override_configuration.prompt_configurations[0].prompt_creation_mode #=> String, one of "DEFAULT", "OVERRIDDEN" + # resp.agent_version.prompt_override_configuration.prompt_configurations[0].prompt_state #=> String, one of "ENABLED", "DISABLED" + # resp.agent_version.prompt_override_configuration.prompt_configurations[0].prompt_type #=> String, one of "PRE_PROCESSING", "ORCHESTRATION", "POST_PROCESSING", "KNOWLEDGE_BASE_RESPONSE_GENERATION" + # resp.agent_version.recommended_actions #=> Array + # resp.agent_version.recommended_actions[0] #=> String + # resp.agent_version.updated_at #=> Time + # resp.agent_version.version #=> String # # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetAgentVersion AWS API Documentation # # @overload get_agent_version(params = {}) # @param [Hash] params ({}) def get_agent_version(params = {}, options = {}) req = build_request(:get_agent_version, params) req.send_request(options) end - # Get an existing data source + # Gets information about a data source. # - # @option params [required, String] :knowledge_base_id - # Identifier for a resource. - # # @option params [required, String] :data_source_id - # Identifier for a resource. + # The unique identifier of the data source. # + # @option params [required, String] :knowledge_base_id + # The unique identifier of the knowledge base that the data source was + # added to. + # # @return [Types::GetDataSourceResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: # # * {Types::GetDataSourceResponse#data_source #data_source} => Types::DataSource # # @example Request syntax with placeholder values # # resp = client.get_data_source({ - # knowledge_base_id: "Id", # required # data_source_id: "Id", # required + # knowledge_base_id: "Id", # required # }) # # @example Response structure # - # resp.data_source.knowledge_base_id #=> String - # resp.data_source.data_source_id #=> String - # resp.data_source.name #=> String - # resp.data_source.status #=> String, one of "AVAILABLE", "DELETING" - # resp.data_source.description #=> String - # resp.data_source.data_source_configuration.type #=> String, one of "S3" + # resp.data_source.created_at #=> Time # resp.data_source.data_source_configuration.s3_configuration.bucket_arn #=> String # resp.data_source.data_source_configuration.s3_configuration.inclusion_prefixes #=> Array # resp.data_source.data_source_configuration.s3_configuration.inclusion_prefixes[0] #=> String + # resp.data_source.data_source_configuration.type #=> String, one of "S3" + # resp.data_source.data_source_id #=> String + # resp.data_source.description #=> String + # resp.data_source.knowledge_base_id #=> String + # resp.data_source.name #=> String # resp.data_source.server_side_encryption_configuration.kms_key_arn #=> String + # resp.data_source.status #=> String, one of "AVAILABLE", "DELETING" + # resp.data_source.updated_at #=> Time # resp.data_source.vector_ingestion_configuration.chunking_configuration.chunking_strategy #=> String, one of "FIXED_SIZE", "NONE" # resp.data_source.vector_ingestion_configuration.chunking_configuration.fixed_size_chunking_configuration.max_tokens #=> Integer # resp.data_source.vector_ingestion_configuration.chunking_configuration.fixed_size_chunking_configuration.overlap_percentage #=> Integer - # resp.data_source.created_at #=> Time - # resp.data_source.updated_at #=> Time # # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetDataSource AWS API Documentation # # @overload get_data_source(params = {}) # @param [Hash] params ({}) def get_data_source(params = {}, options = {}) req = build_request(:get_data_source, params) req.send_request(options) end - # Get an ingestion job + # Gets information about a ingestion job, in which a data source is + # added to a knowledge base. # - # @option params [required, String] :knowledge_base_id - # Identifier for a resource. - # # @option params [required, String] :data_source_id - # Identifier for a resource. + # The unique identifier of the data source in the ingestion job. # # @option params [required, String] :ingestion_job_id - # Identifier for a resource. + # The unique identifier of the ingestion job. # + # @option params [required, String] :knowledge_base_id + # The unique identifier of the knowledge base for which the ingestion + # job applies. + # # @return [Types::GetIngestionJobResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: # # * {Types::GetIngestionJobResponse#ingestion_job #ingestion_job} => Types::IngestionJob # # @example Request syntax with placeholder values # # resp = client.get_ingestion_job({ - # knowledge_base_id: "Id", # required # data_source_id: "Id", # required # ingestion_job_id: "Id", # required + # knowledge_base_id: "Id", # required # }) # # @example Response structure # - # resp.ingestion_job.knowledge_base_id #=> String # resp.ingestion_job.data_source_id #=> String - # resp.ingestion_job.ingestion_job_id #=> String # resp.ingestion_job.description #=> String - # resp.ingestion_job.status #=> String, one of "STARTING", "IN_PROGRESS", "COMPLETE", "FAILED" - # resp.ingestion_job.statistics.number_of_documents_scanned #=> Integer - # resp.ingestion_job.statistics.number_of_new_documents_indexed #=> Integer - # resp.ingestion_job.statistics.number_of_modified_documents_indexed #=> Integer - # resp.ingestion_job.statistics.number_of_documents_deleted #=> Integer - # resp.ingestion_job.statistics.number_of_documents_failed #=> Integer # resp.ingestion_job.failure_reasons #=> Array # resp.ingestion_job.failure_reasons[0] #=> String + # resp.ingestion_job.ingestion_job_id #=> String + # resp.ingestion_job.knowledge_base_id #=> String # resp.ingestion_job.started_at #=> Time + # resp.ingestion_job.statistics.number_of_documents_deleted #=> Integer + # resp.ingestion_job.statistics.number_of_documents_failed #=> Integer + # resp.ingestion_job.statistics.number_of_documents_scanned #=> Integer + # resp.ingestion_job.statistics.number_of_metadata_documents_modified #=> Integer + # resp.ingestion_job.statistics.number_of_metadata_documents_scanned #=> Integer + # resp.ingestion_job.statistics.number_of_modified_documents_indexed #=> Integer + # resp.ingestion_job.statistics.number_of_new_documents_indexed #=> Integer + # resp.ingestion_job.status #=> String, one of "STARTING", "IN_PROGRESS", "COMPLETE", "FAILED" # resp.ingestion_job.updated_at #=> Time # # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetIngestionJob AWS API Documentation # # @overload get_ingestion_job(params = {}) @@ -1533,14 +1731,15 @@ def get_ingestion_job(params = {}, options = {}) req = build_request(:get_ingestion_job, params) req.send_request(options) end - # Get an existing knowledge base + # Gets information about a knoweldge base. # # @option params [required, String] :knowledge_base_id - # Identifier for a resource. + # The unique identifier of the knowledge base for which to get + # information. # # @return [Types::GetKnowledgeBaseResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: # # * {Types::GetKnowledgeBaseResponse#knowledge_base #knowledge_base} => Types::KnowledgeBase # @@ -1550,70 +1749,76 @@ # knowledge_base_id: "Id", # required # }) # # @example Response structure # - # resp.knowledge_base.knowledge_base_id #=> String - # resp.knowledge_base.name #=> String - # resp.knowledge_base.knowledge_base_arn #=> String + # resp.knowledge_base.created_at #=> Time # resp.knowledge_base.description #=> String - # resp.knowledge_base.role_arn #=> String + # resp.knowledge_base.failure_reasons #=> Array + # resp.knowledge_base.failure_reasons[0] #=> String + # resp.knowledge_base.knowledge_base_arn #=> String # resp.knowledge_base.knowledge_base_configuration.type #=> String, one of "VECTOR" # resp.knowledge_base.knowledge_base_configuration.vector_knowledge_base_configuration.embedding_model_arn #=> String - # resp.knowledge_base.storage_configuration.type #=> String, one of "OPENSEARCH_SERVERLESS", "PINECONE", "REDIS_ENTERPRISE_CLOUD", "RDS" + # resp.knowledge_base.knowledge_base_id #=> String + # resp.knowledge_base.name #=> String + # resp.knowledge_base.role_arn #=> String + # resp.knowledge_base.status #=> String, one of "CREATING", "ACTIVE", "DELETING", "UPDATING", "FAILED" # resp.knowledge_base.storage_configuration.opensearch_serverless_configuration.collection_arn #=> String - # resp.knowledge_base.storage_configuration.opensearch_serverless_configuration.vector_index_name #=> String - # resp.knowledge_base.storage_configuration.opensearch_serverless_configuration.field_mapping.vector_field #=> String - # resp.knowledge_base.storage_configuration.opensearch_serverless_configuration.field_mapping.text_field #=> String # resp.knowledge_base.storage_configuration.opensearch_serverless_configuration.field_mapping.metadata_field #=> String + # resp.knowledge_base.storage_configuration.opensearch_serverless_configuration.field_mapping.text_field #=> String + # resp.knowledge_base.storage_configuration.opensearch_serverless_configuration.field_mapping.vector_field #=> String + # resp.knowledge_base.storage_configuration.opensearch_serverless_configuration.vector_index_name #=> String # resp.knowledge_base.storage_configuration.pinecone_configuration.connection_string #=> String # resp.knowledge_base.storage_configuration.pinecone_configuration.credentials_secret_arn #=> String - # resp.knowledge_base.storage_configuration.pinecone_configuration.namespace #=> String - # resp.knowledge_base.storage_configuration.pinecone_configuration.field_mapping.text_field #=> String # resp.knowledge_base.storage_configuration.pinecone_configuration.field_mapping.metadata_field #=> String - # resp.knowledge_base.storage_configuration.redis_enterprise_cloud_configuration.endpoint #=> String - # resp.knowledge_base.storage_configuration.redis_enterprise_cloud_configuration.vector_index_name #=> String - # resp.knowledge_base.storage_configuration.redis_enterprise_cloud_configuration.credentials_secret_arn #=> String - # resp.knowledge_base.storage_configuration.redis_enterprise_cloud_configuration.field_mapping.vector_field #=> String - # resp.knowledge_base.storage_configuration.redis_enterprise_cloud_configuration.field_mapping.text_field #=> String - # resp.knowledge_base.storage_configuration.redis_enterprise_cloud_configuration.field_mapping.metadata_field #=> String - # resp.knowledge_base.storage_configuration.rds_configuration.resource_arn #=> String + # resp.knowledge_base.storage_configuration.pinecone_configuration.field_mapping.text_field #=> String + # resp.knowledge_base.storage_configuration.pinecone_configuration.namespace #=> String # resp.knowledge_base.storage_configuration.rds_configuration.credentials_secret_arn #=> String # resp.knowledge_base.storage_configuration.rds_configuration.database_name #=> String - # resp.knowledge_base.storage_configuration.rds_configuration.table_name #=> String + # resp.knowledge_base.storage_configuration.rds_configuration.field_mapping.metadata_field #=> String # resp.knowledge_base.storage_configuration.rds_configuration.field_mapping.primary_key_field #=> String - # resp.knowledge_base.storage_configuration.rds_configuration.field_mapping.vector_field #=> String # resp.knowledge_base.storage_configuration.rds_configuration.field_mapping.text_field #=> String - # resp.knowledge_base.storage_configuration.rds_configuration.field_mapping.metadata_field #=> String - # resp.knowledge_base.status #=> String, one of "CREATING", "ACTIVE", "DELETING", "UPDATING", "FAILED" - # resp.knowledge_base.created_at #=> Time + # resp.knowledge_base.storage_configuration.rds_configuration.field_mapping.vector_field #=> String + # resp.knowledge_base.storage_configuration.rds_configuration.resource_arn #=> String + # resp.knowledge_base.storage_configuration.rds_configuration.table_name #=> String + # resp.knowledge_base.storage_configuration.redis_enterprise_cloud_configuration.credentials_secret_arn #=> String + # resp.knowledge_base.storage_configuration.redis_enterprise_cloud_configuration.endpoint #=> String + # resp.knowledge_base.storage_configuration.redis_enterprise_cloud_configuration.field_mapping.metadata_field #=> String + # resp.knowledge_base.storage_configuration.redis_enterprise_cloud_configuration.field_mapping.text_field #=> String + # resp.knowledge_base.storage_configuration.redis_enterprise_cloud_configuration.field_mapping.vector_field #=> String + # resp.knowledge_base.storage_configuration.redis_enterprise_cloud_configuration.vector_index_name #=> String + # resp.knowledge_base.storage_configuration.type #=> String, one of "OPENSEARCH_SERVERLESS", "PINECONE", "REDIS_ENTERPRISE_CLOUD", "RDS" # resp.knowledge_base.updated_at #=> Time - # resp.knowledge_base.failure_reasons #=> Array - # resp.knowledge_base.failure_reasons[0] #=> String # # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/GetKnowledgeBase AWS API Documentation # # @overload get_knowledge_base(params = {}) # @param [Hash] params ({}) def get_knowledge_base(params = {}, options = {}) req = build_request(:get_knowledge_base, params) req.send_request(options) end - # Lists an Action Group for existing Amazon Bedrock Agent Version + # Lists the action groups for an agent and information about each one. # # @option params [required, String] :agent_id - # Id generated at the server side when an Agent is Listed + # The unique identifier of the agent. # # @option params [required, String] :agent_version - # Id generated at the server side when an Agent is Listed + # The version of the agent. # # @option params [Integer] :max_results - # Max Results. + # The maximum number of results to return in the response. If the total + # number of results is greater than this value, use the token returned + # in the response in the `nextToken` field when making another request + # to return the next batch of results. # # @option params [String] :next_token - # Opaque continuation token of previous paginated response. + # If the total number of results is greater than the `maxResults` value + # provided in the request, enter the token returned in the `nextToken` + # field in the response in this field to return the next batch of + # results. # # @return [Types::ListAgentActionGroupsResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: # # * {Types::ListAgentActionGroupsResponse#action_group_summaries #action_group_summaries} => Array&lt;Types::ActionGroupSummary&gt; # * {Types::ListAgentActionGroupsResponse#next_token #next_token} => String @@ -1646,20 +1851,26 @@ def list_agent_action_groups(params = {}, options = {}) req = build_request(:list_agent_action_groups, params) req.send_request(options) end - # Lists all the Aliases for an Amazon Bedrock Agent + # Lists the aliases of an agent and information about each one. # # @option params [required, String] :agent_id - # Id generated at the server side when an Agent is created + # The unique identifier of the agent. # # @option params [Integer] :max_results - # Max Results. + # The maximum number of results to return in the response. If the total + # number of results is greater than this value, use the token returned + # in the response in the `nextToken` field when making another request + # to return the next batch of results. # # @option params [String] :next_token - # Opaque continuation token of previous paginated response. + # If the total number of results is greater than the `maxResults` value + # provided in the request, enter the token returned in the `nextToken` + # field in the response in this field to return the next batch of + # results. # # @return [Types::ListAgentAliasesResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: # # * {Types::ListAgentAliasesResponse#agent_alias_summaries #agent_alias_summaries} => Array&lt;Types::AgentAliasSummary&gt; # * {Types::ListAgentAliasesResponse#next_token #next_token} => String @@ -1677,15 +1888,15 @@ # @example Response structure # # resp.agent_alias_summaries #=> Array # resp.agent_alias_summaries[0].agent_alias_id #=> String # resp.agent_alias_summaries[0].agent_alias_name #=> String + # resp.agent_alias_summaries[0].agent_alias_status #=> String, one of "CREATING", "PREPARED", "FAILED", "UPDATING", "DELETING" + # resp.agent_alias_summaries[0].created_at #=> Time # resp.agent_alias_summaries[0].description #=> String # resp.agent_alias_summaries[0].routing_configuration #=> Array # resp.agent_alias_summaries[0].routing_configuration[0].agent_version #=> String - # resp.agent_alias_summaries[0].agent_alias_status #=> String, one of "CREATING", "PREPARED", "FAILED", "UPDATING", "DELETING" - # resp.agent_alias_summaries[0].created_at #=> Time # resp.agent_alias_summaries[0].updated_at #=> Time # resp.next_token #=> String # # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListAgentAliases AWS API Documentation # @@ -1694,24 +1905,32 @@ def list_agent_aliases(params = {}, options = {}) req = build_request(:list_agent_aliases, params) req.send_request(options) end - # List of Knowledge Bases associated to an existing Amazon Bedrock Agent - # Version + # Lists knowledge bases associated with an agent and information about + # each one. # # @option params [required, String] :agent_id - # Id generated at the server side when an Agent is created + # The unique identifier of the agent for which to return information + # about knowledge bases associated with it. # # @option params [required, String] :agent_version - # Version number generated when a version is created + # The version of the agent for which to return information about + # knowledge bases associated with it. # # @option params [Integer] :max_results - # Max Results. + # The maximum number of results to return in the response. If the total + # number of results is greater than this value, use the token returned + # in the response in the `nextToken` field when making another request + # to return the next batch of results. # # @option params [String] :next_token - # Opaque continuation token of previous paginated response. + # If the total number of results is greater than the `maxResults` value + # provided in the request, enter the token returned in the `nextToken` + # field in the response in this field to return the next batch of + # results. # # @return [Types::ListAgentKnowledgeBasesResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: # # * {Types::ListAgentKnowledgeBasesResponse#agent_knowledge_base_summaries #agent_knowledge_base_summaries} => Array&lt;Types::AgentKnowledgeBaseSummary&gt; # * {Types::ListAgentKnowledgeBasesResponse#next_token #next_token} => String @@ -1728,12 +1947,12 @@ # }) # # @example Response structure # # resp.agent_knowledge_base_summaries #=> Array - # resp.agent_knowledge_base_summaries[0].knowledge_base_id #=> String # resp.agent_knowledge_base_summaries[0].description #=> String + # resp.agent_knowledge_base_summaries[0].knowledge_base_id #=> String # resp.agent_knowledge_base_summaries[0].knowledge_base_state #=> String, one of "ENABLED", "DISABLED" # resp.agent_knowledge_base_summaries[0].updated_at #=> Time # resp.next_token #=> String # # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListAgentKnowledgeBases AWS API Documentation @@ -1743,20 +1962,26 @@ def list_agent_knowledge_bases(params = {}, options = {}) req = build_request(:list_agent_knowledge_bases, params) req.send_request(options) end - # Lists Agent Versions + # Lists the versions of an agent and information about each version. # # @option params [required, String] :agent_id - # Id generated at the server side when an Agent is created + # The unique identifier of the agent. # # @option params [Integer] :max_results - # Max Results. + # The maximum number of results to return in the response. If the total + # number of results is greater than this value, use the token returned + # in the response in the `nextToken` field when making another request + # to return the next batch of results. # # @option params [String] :next_token - # Opaque continuation token of previous paginated response. + # If the total number of results is greater than the `maxResults` value + # provided in the request, enter the token returned in the `nextToken` + # field in the response in this field to return the next batch of + # results. # # @return [Types::ListAgentVersionsResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: # # * {Types::ListAgentVersionsResponse#agent_version_summaries #agent_version_summaries} => Array&lt;Types::AgentVersionSummary&gt; # * {Types::ListAgentVersionsResponse#next_token #next_token} => String @@ -1776,12 +2001,12 @@ # resp.agent_version_summaries #=> Array # resp.agent_version_summaries[0].agent_name #=> String # resp.agent_version_summaries[0].agent_status #=> String, one of "CREATING", "PREPARING", "PREPARED", "NOT_PREPARED", "DELETING", "FAILED", "VERSIONING", "UPDATING" # resp.agent_version_summaries[0].agent_version #=> String # resp.agent_version_summaries[0].created_at #=> Time - # resp.agent_version_summaries[0].updated_at #=> Time # resp.agent_version_summaries[0].description #=> String + # resp.agent_version_summaries[0].updated_at #=> Time # resp.next_token #=> String # # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListAgentVersions AWS API Documentation # # @overload list_agent_versions(params = {}) @@ -1789,17 +2014,24 @@ def list_agent_versions(params = {}, options = {}) req = build_request(:list_agent_versions, params) req.send_request(options) end - # Lists Agents + # Lists the agents belonging to an account and information about each + # agent. # # @option params [Integer] :max_results - # Max Results. + # The maximum number of results to return in the response. If the total + # number of results is greater than this value, use the token returned + # in the response in the `nextToken` field when making another request + # to return the next batch of results. # # @option params [String] :next_token - # Opaque continuation token of previous paginated response. + # If the total number of results is greater than the `maxResults` value + # provided in the request, enter the token returned in the `nextToken` + # field in the response in this field to return the next batch of + # results. # # @return [Types::ListAgentsResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: # # * {Types::ListAgentsResponse#agent_summaries #agent_summaries} => Array&lt;Types::AgentSummary&gt; # * {Types::ListAgentsResponse#next_token #next_token} => String @@ -1818,12 +2050,12 @@ # resp.agent_summaries #=> Array # resp.agent_summaries[0].agent_id #=> String # resp.agent_summaries[0].agent_name #=> String # resp.agent_summaries[0].agent_status #=> String, one of "CREATING", "PREPARING", "PREPARED", "NOT_PREPARED", "DELETING", "FAILED", "VERSIONING", "UPDATING" # resp.agent_summaries[0].description #=> String - # resp.agent_summaries[0].updated_at #=> Time # resp.agent_summaries[0].latest_agent_version #=> String + # resp.agent_summaries[0].updated_at #=> Time # resp.next_token #=> String # # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListAgents AWS API Documentation # # @overload list_agents(params = {}) @@ -1831,20 +2063,28 @@ def list_agents(params = {}, options = {}) req = build_request(:list_agents, params) req.send_request(options) end - # List data sources + # Lists the data sources in a knowledge base and information about each + # one. # # @option params [required, String] :knowledge_base_id - # Identifier for a resource. + # The unique identifier of the knowledge base for which to return a list + # of information. # # @option params [Integer] :max_results - # Max Results. + # The maximum number of results to return in the response. If the total + # number of results is greater than this value, use the token returned + # in the response in the `nextToken` field when making another request + # to return the next batch of results. # # @option params [String] :next_token - # Opaque continuation token of previous paginated response. + # If the total number of results is greater than the `maxResults` value + # provided in the request, enter the token returned in the `nextToken` + # field in the response in this field to return the next batch of + # results. # # @return [Types::ListDataSourcesResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: # # * {Types::ListDataSourcesResponse#data_source_summaries #data_source_summaries} => Array&lt;Types::DataSourceSummary&gt; # * {Types::ListDataSourcesResponse#next_token #next_token} => String @@ -1860,15 +2100,15 @@ # }) # # @example Response structure # # resp.data_source_summaries #=> Array - # resp.data_source_summaries[0].knowledge_base_id #=> String # resp.data_source_summaries[0].data_source_id #=> String + # resp.data_source_summaries[0].description #=> String + # resp.data_source_summaries[0].knowledge_base_id #=> String # resp.data_source_summaries[0].name #=> String # resp.data_source_summaries[0].status #=> String, one of "AVAILABLE", "DELETING" - # resp.data_source_summaries[0].description #=> String # resp.data_source_summaries[0].updated_at #=> Time # resp.next_token #=> String # # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListDataSources AWS API Documentation # @@ -1877,72 +2117,83 @@ def list_data_sources(params = {}, options = {}) req = build_request(:list_data_sources, params) req.send_request(options) end - # List ingestion jobs + # Lists the ingestion jobs for a data source and information about each + # of them. # - # @option params [required, String] :knowledge_base_id - # Identifier for a resource. - # # @option params [required, String] :data_source_id - # Identifier for a resource. + # The unique identifier of the data source for which to return ingestion + # jobs. # # @option params [Array<Types::IngestionJobFilter>] :filters - # List of IngestionJobFilters + # Contains a definition of a filter for which to filter the results. # - # @option params [Types::IngestionJobSortBy] :sort_by - # Sorts the response returned by ListIngestionJobs operation. + # @option params [required, String] :knowledge_base_id + # The unique identifier of the knowledge base for which to return + # ingestion jobs. # # @option params [Integer] :max_results - # Max Results. + # The maximum number of results to return in the response. If the total + # number of results is greater than this value, use the token returned + # in the response in the `nextToken` field when making another request + # to return the next batch of results. # # @option params [String] :next_token - # Opaque continuation token of previous paginated response. + # If the total number of results is greater than the `maxResults` value + # provided in the request, enter the token returned in the `nextToken` + # field in the response in this field to return the next batch of + # results. # + # @option params [Types::IngestionJobSortBy] :sort_by + # Contains details about how to sort the results. + # # @return [Types::ListIngestionJobsResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: # # * {Types::ListIngestionJobsResponse#ingestion_job_summaries #ingestion_job_summaries} => Array&lt;Types::IngestionJobSummary&gt; # * {Types::ListIngestionJobsResponse#next_token #next_token} => String # # The returned {Seahorse::Client::Response response} is a pageable response and is Enumerable. For details on usage see {Aws::PageableResponse PageableResponse}. # # @example Request syntax with placeholder values # # resp = client.list_ingestion_jobs({ - # knowledge_base_id: "Id", # required # data_source_id: "Id", # required # filters: [ # { # attribute: "STATUS", # required, accepts STATUS # operator: "EQ", # required, accepts EQ # values: ["IngestionJobFilterValue"], # required # }, # ], + # knowledge_base_id: "Id", # required + # max_results: 1, + # next_token: "NextToken", # sort_by: { # attribute: "STATUS", # required, accepts STATUS, STARTED_AT # order: "ASCENDING", # required, accepts ASCENDING, DESCENDING # }, - # max_results: 1, - # next_token: "NextToken", # }) # # @example Response structure # # resp.ingestion_job_summaries #=> Array - # resp.ingestion_job_summaries[0].knowledge_base_id #=> String # resp.ingestion_job_summaries[0].data_source_id #=> String - # resp.ingestion_job_summaries[0].ingestion_job_id #=> String # resp.ingestion_job_summaries[0].description #=> String - # resp.ingestion_job_summaries[0].status #=> String, one of "STARTING", "IN_PROGRESS", "COMPLETE", "FAILED" + # resp.ingestion_job_summaries[0].ingestion_job_id #=> String + # resp.ingestion_job_summaries[0].knowledge_base_id #=> String # resp.ingestion_job_summaries[0].started_at #=> Time - # resp.ingestion_job_summaries[0].updated_at #=> Time - # resp.ingestion_job_summaries[0].statistics.number_of_documents_scanned #=> Integer - # resp.ingestion_job_summaries[0].statistics.number_of_new_documents_indexed #=> Integer - # resp.ingestion_job_summaries[0].statistics.number_of_modified_documents_indexed #=> Integer # resp.ingestion_job_summaries[0].statistics.number_of_documents_deleted #=> Integer # resp.ingestion_job_summaries[0].statistics.number_of_documents_failed #=> Integer + # resp.ingestion_job_summaries[0].statistics.number_of_documents_scanned #=> Integer + # resp.ingestion_job_summaries[0].statistics.number_of_metadata_documents_modified #=> Integer + # resp.ingestion_job_summaries[0].statistics.number_of_metadata_documents_scanned #=> Integer + # resp.ingestion_job_summaries[0].statistics.number_of_modified_documents_indexed #=> Integer + # resp.ingestion_job_summaries[0].statistics.number_of_new_documents_indexed #=> Integer + # resp.ingestion_job_summaries[0].status #=> String, one of "STARTING", "IN_PROGRESS", "COMPLETE", "FAILED" + # resp.ingestion_job_summaries[0].updated_at #=> Time # resp.next_token #=> String # # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListIngestionJobs AWS API Documentation # # @overload list_ingestion_jobs(params = {}) @@ -1950,17 +2201,24 @@ def list_ingestion_jobs(params = {}, options = {}) req = build_request(:list_ingestion_jobs, params) req.send_request(options) end - # List Knowledge Bases + # Lists the knowledge bases in an account and information about each of + # them. # # @option params [Integer] :max_results - # Max Results. + # The maximum number of results to return in the response. If the total + # number of results is greater than this value, use the token returned + # in the response in the `nextToken` field when making another request + # to return the next batch of results. # # @option params [String] :next_token - # Opaque continuation token of previous paginated response. + # If the total number of results is greater than the `maxResults` value + # provided in the request, enter the token returned in the `nextToken` + # field in the response in this field to return the next batch of + # results. # # @return [Types::ListKnowledgeBasesResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: # # * {Types::ListKnowledgeBasesResponse#knowledge_base_summaries #knowledge_base_summaries} => Array&lt;Types::KnowledgeBaseSummary&gt; # * {Types::ListKnowledgeBasesResponse#next_token #next_token} => String @@ -1975,13 +2233,13 @@ # }) # # @example Response structure # # resp.knowledge_base_summaries #=> Array + # resp.knowledge_base_summaries[0].description #=> String # resp.knowledge_base_summaries[0].knowledge_base_id #=> String # resp.knowledge_base_summaries[0].name #=> String - # resp.knowledge_base_summaries[0].description #=> String # resp.knowledge_base_summaries[0].status #=> String, one of "CREATING", "ACTIVE", "DELETING", "UPDATING", "FAILED" # resp.knowledge_base_summaries[0].updated_at #=> Time # resp.next_token #=> String # # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/ListKnowledgeBases AWS API Documentation @@ -1991,14 +2249,14 @@ def list_knowledge_bases(params = {}, options = {}) req = build_request(:list_knowledge_bases, params) req.send_request(options) end - # List tags for a resource + # List all the tags for the resource you specify. # # @option params [required, String] :resource_arn - # ARN of Taggable resources: \[Agent, AgentAlias, Knowledge-Base\] + # The ARN of the resource for which to list tags. # # @return [Types::ListTagsForResourceResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: # # * {Types::ListTagsForResourceResponse#tags #tags} => Hash&lt;String,String&gt; # @@ -2020,14 +2278,16 @@ def list_tags_for_resource(params = {}, options = {}) req = build_request(:list_tags_for_resource, params) req.send_request(options) end - # Prepares an existing Amazon Bedrock Agent to receive runtime requests + # Creates a `DRAFT` version of the agent that can be used for internal + # testing. # # @option params [required, String] :agent_id - # Id generated at the server side when an Agent is created + # The unique identifier of the agent for which to create a `DRAFT` + # version. # # @return [Types::PrepareAgentResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: # # * {Types::PrepareAgentResponse#agent_id #agent_id} => String # * {Types::PrepareAgentResponse#agent_status #agent_status} => String @@ -2054,55 +2314,66 @@ def prepare_agent(params = {}, options = {}) req = build_request(:prepare_agent, params) req.send_request(options) end - # Start a new ingestion job + # Begins an ingestion job, in which a data source is added to a + # knowledge base. # - # @option params [required, String] :knowledge_base_id - # Identifier for a resource. - # - # @option params [required, String] :data_source_id - # Identifier for a resource. - # # @option params [String] :client_token - # Client specified token used for idempotency checks + # A unique, case-sensitive identifier to ensure that the API request + # completes no more than one time. If this token matches a previous + # request, Amazon Bedrock ignores the request, but does not return an + # error. For more information, see [Ensuring idempotency][1]. # # **A suitable default value is auto-generated.** You should normally # not need to pass this option.** # + # + # + # [1]: https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html + # + # @option params [required, String] :data_source_id + # The unique identifier of the data source to ingest. + # # @option params [String] :description - # Description of the Resource. + # A description of the ingestion job. # + # @option params [required, String] :knowledge_base_id + # The unique identifier of the knowledge base to which to add the data + # source. + # # @return [Types::StartIngestionJobResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: # # * {Types::StartIngestionJobResponse#ingestion_job #ingestion_job} => Types::IngestionJob # # @example Request syntax with placeholder values # # resp = client.start_ingestion_job({ - # knowledge_base_id: "Id", # required - # data_source_id: "Id", # required # client_token: "ClientToken", + # data_source_id: "Id", # required # description: "Description", + # knowledge_base_id: "Id", # required # }) # # @example Response structure # - # resp.ingestion_job.knowledge_base_id #=> String # resp.ingestion_job.data_source_id #=> String - # resp.ingestion_job.ingestion_job_id #=> String # resp.ingestion_job.description #=> String - # resp.ingestion_job.status #=> String, one of "STARTING", "IN_PROGRESS", "COMPLETE", "FAILED" - # resp.ingestion_job.statistics.number_of_documents_scanned #=> Integer - # resp.ingestion_job.statistics.number_of_new_documents_indexed #=> Integer - # resp.ingestion_job.statistics.number_of_modified_documents_indexed #=> Integer - # resp.ingestion_job.statistics.number_of_documents_deleted #=> Integer - # resp.ingestion_job.statistics.number_of_documents_failed #=> Integer # resp.ingestion_job.failure_reasons #=> Array # resp.ingestion_job.failure_reasons[0] #=> String + # resp.ingestion_job.ingestion_job_id #=> String + # resp.ingestion_job.knowledge_base_id #=> String # resp.ingestion_job.started_at #=> Time + # resp.ingestion_job.statistics.number_of_documents_deleted #=> Integer + # resp.ingestion_job.statistics.number_of_documents_failed #=> Integer + # resp.ingestion_job.statistics.number_of_documents_scanned #=> Integer + # resp.ingestion_job.statistics.number_of_metadata_documents_modified #=> Integer + # resp.ingestion_job.statistics.number_of_metadata_documents_scanned #=> Integer + # resp.ingestion_job.statistics.number_of_modified_documents_indexed #=> Integer + # resp.ingestion_job.statistics.number_of_new_documents_indexed #=> Integer + # resp.ingestion_job.status #=> String, one of "STARTING", "IN_PROGRESS", "COMPLETE", "FAILED" # resp.ingestion_job.updated_at #=> Time # # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/StartIngestionJob AWS API Documentation # # @overload start_ingestion_job(params = {}) @@ -2110,17 +2381,23 @@ def start_ingestion_job(params = {}, options = {}) req = build_request(:start_ingestion_job, params) req.send_request(options) end - # Tag a resource + # Associate tags with a resource. For more information, see [Tagging + # resources][1] in the Amazon Bedrock User Guide. # + # + # + # [1]: https://docs.aws.amazon.com/bedrock/latest/userguide/what-is-service.html + # # @option params [required, String] :resource_arn - # ARN of Taggable resources: \[Agent, AgentAlias, Knowledge-Base\] + # The ARN of the resource to tag. # # @option params [required, Hash<String,String>] :tags - # A map of tag keys and values + # An object containing key-value pairs that define the tags to attach to + # the resource. # # @return [Struct] Returns an empty {Seahorse::Client::Response response}. # # @example Request syntax with placeholder values # @@ -2138,17 +2415,17 @@ def tag_resource(params = {}, options = {}) req = build_request(:tag_resource, params) req.send_request(options) end - # Untag a resource + # Remove tags from a resource. # # @option params [required, String] :resource_arn - # ARN of Taggable resources: \[Agent, AgentAlias, Knowledge-Base\] + # The ARN of the resource from which to remove tags. # # @option params [required, Array<String>] :tag_keys - # List of Tag Keys + # A list of keys of the tags to remove from the resource. # # @return [Struct] Returns an empty {Seahorse::Client::Response response}. # # @example Request syntax with placeholder values # @@ -2164,357 +2441,408 @@ def untag_resource(params = {}, options = {}) req = build_request(:untag_resource, params) req.send_request(options) end - # Updates an existing Amazon Bedrock Agent + # Updates the configuration of an agent. # # @option params [required, String] :agent_id - # Id generated at the server side when an Agent is created + # The unique identifier of the agent. # # @option params [required, String] :agent_name - # Name for a resource. + # Specifies a new name for the agent. # - # @option params [String] :instruction - # Instruction for the agent. + # @option params [required, String] :agent_resource_role_arn + # The ARN of the IAM role with permissions to update the agent. The ARN + # must begin with `AmazonBedrockExecutionRoleForAgents_`. # - # @option params [String] :foundation_model - # ARN or name of a Bedrock model. + # @option params [String] :customer_encryption_key_arn + # The ARN of the KMS key with which to encrypt the agent. # # @option params [String] :description - # Description of the Resource. + # Specifies a new description of the agent. # + # @option params [required, String] :foundation_model + # Specifies a new foundation model to be used for orchestration by the + # agent. + # # @option params [Integer] :idle_session_ttl_in_seconds - # Max Session Time. + # The number of seconds for which Amazon Bedrock keeps information about + # a user's conversation with the agent. # - # @option params [required, String] :agent_resource_role_arn - # ARN of a IAM role. + # A user interaction remains active for the amount of time specified. If + # no conversation occurs during this time, the session expires and + # Amazon Bedrock deletes any data provided before the timeout. # - # @option params [String] :customer_encryption_key_arn - # A KMS key ARN + # @option params [String] :instruction + # Specifies new instructions that tell the agent what it should do and + # how it should interact with users. # # @option params [Types::PromptOverrideConfiguration] :prompt_override_configuration - # Configuration for prompt override. + # Contains configurations to override prompts in different parts of an + # agent sequence. For more information, see [Advanced prompts][1]. # + # + # + # [1]: https://docs.aws.amazon.com/bedrock/latest/userguide/advanced-prompts.html + # # @return [Types::UpdateAgentResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: # # * {Types::UpdateAgentResponse#agent #agent} => Types::Agent # # @example Request syntax with placeholder values # # resp = client.update_agent({ # agent_id: "Id", # required # agent_name: "Name", # required - # instruction: "Instruction", - # foundation_model: "ModelIdentifier", - # description: "Description", - # idle_session_ttl_in_seconds: 1, # agent_resource_role_arn: "AgentRoleArn", # required # customer_encryption_key_arn: "KmsKeyArn", + # description: "Description", + # foundation_model: "ModelIdentifier", # required + # idle_session_ttl_in_seconds: 1, + # instruction: "Instruction", # prompt_override_configuration: { + # override_lambda: "LambdaArn", # prompt_configurations: [ # required # { - # prompt_type: "PRE_PROCESSING", # accepts PRE_PROCESSING, ORCHESTRATION, POST_PROCESSING, KNOWLEDGE_BASE_RESPONSE_GENERATION - # prompt_creation_mode: "DEFAULT", # accepts DEFAULT, OVERRIDDEN - # prompt_state: "ENABLED", # accepts ENABLED, DISABLED # base_prompt_template: "BasePromptTemplate", # inference_configuration: { - # temperature: 1.0, - # top_p: 1.0, - # top_k: 1, # maximum_length: 1, # stop_sequences: ["String"], + # temperature: 1.0, + # top_k: 1, + # top_p: 1.0, # }, # parser_mode: "DEFAULT", # accepts DEFAULT, OVERRIDDEN + # prompt_creation_mode: "DEFAULT", # accepts DEFAULT, OVERRIDDEN + # prompt_state: "ENABLED", # accepts ENABLED, DISABLED + # prompt_type: "PRE_PROCESSING", # accepts PRE_PROCESSING, ORCHESTRATION, POST_PROCESSING, KNOWLEDGE_BASE_RESPONSE_GENERATION # }, # ], - # override_lambda: "LambdaArn", # }, # }) # # @example Response structure # + # resp.agent.agent_arn #=> String # resp.agent.agent_id #=> String # resp.agent.agent_name #=> String - # resp.agent.agent_arn #=> String + # resp.agent.agent_resource_role_arn #=> String + # resp.agent.agent_status #=> String, one of "CREATING", "PREPARING", "PREPARED", "NOT_PREPARED", "DELETING", "FAILED", "VERSIONING", "UPDATING" # resp.agent.agent_version #=> String # resp.agent.client_token #=> String - # resp.agent.instruction #=> String - # resp.agent.agent_status #=> String, one of "CREATING", "PREPARING", "PREPARED", "NOT_PREPARED", "DELETING", "FAILED", "VERSIONING", "UPDATING" - # resp.agent.foundation_model #=> String - # resp.agent.description #=> String - # resp.agent.idle_session_ttl_in_seconds #=> Integer - # resp.agent.agent_resource_role_arn #=> String - # resp.agent.customer_encryption_key_arn #=> String # resp.agent.created_at #=> Time - # resp.agent.updated_at #=> Time - # resp.agent.prepared_at #=> Time + # resp.agent.customer_encryption_key_arn #=> String + # resp.agent.description #=> String # resp.agent.failure_reasons #=> Array # resp.agent.failure_reasons[0] #=> String - # resp.agent.recommended_actions #=> Array - # resp.agent.recommended_actions[0] #=> String + # resp.agent.foundation_model #=> String + # resp.agent.idle_session_ttl_in_seconds #=> Integer + # resp.agent.instruction #=> String + # resp.agent.prepared_at #=> Time + # resp.agent.prompt_override_configuration.override_lambda #=> String # resp.agent.prompt_override_configuration.prompt_configurations #=> Array - # resp.agent.prompt_override_configuration.prompt_configurations[0].prompt_type #=> String, one of "PRE_PROCESSING", "ORCHESTRATION", "POST_PROCESSING", "KNOWLEDGE_BASE_RESPONSE_GENERATION" - # resp.agent.prompt_override_configuration.prompt_configurations[0].prompt_creation_mode #=> String, one of "DEFAULT", "OVERRIDDEN" - # resp.agent.prompt_override_configuration.prompt_configurations[0].prompt_state #=> String, one of "ENABLED", "DISABLED" # resp.agent.prompt_override_configuration.prompt_configurations[0].base_prompt_template #=> String - # resp.agent.prompt_override_configuration.prompt_configurations[0].inference_configuration.temperature #=> Float - # resp.agent.prompt_override_configuration.prompt_configurations[0].inference_configuration.top_p #=> Float - # resp.agent.prompt_override_configuration.prompt_configurations[0].inference_configuration.top_k #=> Integer # resp.agent.prompt_override_configuration.prompt_configurations[0].inference_configuration.maximum_length #=> Integer # resp.agent.prompt_override_configuration.prompt_configurations[0].inference_configuration.stop_sequences #=> Array # resp.agent.prompt_override_configuration.prompt_configurations[0].inference_configuration.stop_sequences[0] #=> String + # resp.agent.prompt_override_configuration.prompt_configurations[0].inference_configuration.temperature #=> Float + # resp.agent.prompt_override_configuration.prompt_configurations[0].inference_configuration.top_k #=> Integer + # resp.agent.prompt_override_configuration.prompt_configurations[0].inference_configuration.top_p #=> Float # resp.agent.prompt_override_configuration.prompt_configurations[0].parser_mode #=> String, one of "DEFAULT", "OVERRIDDEN" - # resp.agent.prompt_override_configuration.override_lambda #=> String + # resp.agent.prompt_override_configuration.prompt_configurations[0].prompt_creation_mode #=> String, one of "DEFAULT", "OVERRIDDEN" + # resp.agent.prompt_override_configuration.prompt_configurations[0].prompt_state #=> String, one of "ENABLED", "DISABLED" + # resp.agent.prompt_override_configuration.prompt_configurations[0].prompt_type #=> String, one of "PRE_PROCESSING", "ORCHESTRATION", "POST_PROCESSING", "KNOWLEDGE_BASE_RESPONSE_GENERATION" + # resp.agent.recommended_actions #=> Array + # resp.agent.recommended_actions[0] #=> String + # resp.agent.updated_at #=> Time # # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/UpdateAgent AWS API Documentation # # @overload update_agent(params = {}) # @param [Hash] params ({}) def update_agent(params = {}, options = {}) req = build_request(:update_agent, params) req.send_request(options) end - # Updates an existing Action Group for Amazon Bedrock Agent + # Updates the configuration for an action group for an agent. # + # @option params [Types::ActionGroupExecutor] :action_group_executor + # The ARN of the Lambda function containing the business logic that is + # carried out upon invoking the action. + # + # @option params [required, String] :action_group_id + # The unique identifier of the action group. + # + # @option params [required, String] :action_group_name + # Specifies a new name for the action group. + # + # @option params [String] :action_group_state + # Specifies whether the action group is available for the agent to + # invoke or not when sending an [InvokeAgent][1] request. + # + # + # + # [1]: https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_InvokeAgent.html + # # @option params [required, String] :agent_id - # Id generated at the server side when an Agent is created + # The unique identifier of the agent for which to update the action + # group. # # @option params [required, String] :agent_version - # Draft Version of the Agent. + # The unique identifier of the agent version for which to update the + # action group. # - # @option params [required, String] :action_group_id - # Id generated at the server side when an Action Group is created under - # Agent + # @option params [Types::APISchema] :api_schema + # Contains either details about the S3 object containing the OpenAPI + # schema for the action group or the JSON or YAML-formatted payload + # defining the schema. For more information, see [Action group OpenAPI + # schemas][1]. # - # @option params [required, String] :action_group_name - # Name for a resource. # + # + # [1]: https://docs.aws.amazon.com/bedrock/latest/userguide/agents-api-schema.html + # # @option params [String] :description - # Description of the Resource. + # Specifies a new name for the action group. # # @option params [String] :parent_action_group_signature - # Action Group Signature for a BuiltIn Action + # To allow your agent to request the user for additional information + # when trying to complete a task, set this field to `AMAZON.UserInput`. + # You must leave the `description`, `apiSchema`, and + # `actionGroupExecutor` fields blank for this action group. # - # @option params [Types::ActionGroupExecutor] :action_group_executor - # Type of Executors for an Action Group + # During orchestration, if your agent determines that it needs to invoke + # an API in an action group, but doesn't have enough information to + # complete the API request, it will invoke this action group instead and + # return an [Observation][1] reprompting the user for more information. # - # @option params [String] :action_group_state - # State of the action group # - # @option params [Types::APISchema] :api_schema - # Contains information about the API Schema for the Action Group # + # [1]: https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_Observation.html + # # @return [Types::UpdateAgentActionGroupResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: # # * {Types::UpdateAgentActionGroupResponse#agent_action_group #agent_action_group} => Types::AgentActionGroup # # @example Request syntax with placeholder values # # resp = client.update_agent_action_group({ - # agent_id: "Id", # required - # agent_version: "DraftVersion", # required - # action_group_id: "Id", # required - # action_group_name: "Name", # required - # description: "Description", - # parent_action_group_signature: "AMAZON.UserInput", # accepts AMAZON.UserInput # action_group_executor: { # lambda: "LambdaArn", # }, + # action_group_id: "Id", # required + # action_group_name: "Name", # required # action_group_state: "ENABLED", # accepts ENABLED, DISABLED + # agent_id: "Id", # required + # agent_version: "DraftVersion", # required # api_schema: { + # payload: "Payload", # s3: { # s3_bucket_name: "S3BucketName", # s3_object_key: "S3ObjectKey", # }, - # payload: "Payload", # }, + # description: "Description", + # parent_action_group_signature: "AMAZON.UserInput", # accepts AMAZON.UserInput # }) # # @example Response structure # - # resp.agent_action_group.agent_id #=> String - # resp.agent_action_group.agent_version #=> String + # resp.agent_action_group.action_group_executor.lambda #=> String # resp.agent_action_group.action_group_id #=> String # resp.agent_action_group.action_group_name #=> String + # resp.agent_action_group.action_group_state #=> String, one of "ENABLED", "DISABLED" + # resp.agent_action_group.agent_id #=> String + # resp.agent_action_group.agent_version #=> String + # resp.agent_action_group.api_schema.payload #=> String + # resp.agent_action_group.api_schema.s3.s3_bucket_name #=> String + # resp.agent_action_group.api_schema.s3.s3_object_key #=> String # resp.agent_action_group.client_token #=> String - # resp.agent_action_group.description #=> String # resp.agent_action_group.created_at #=> Time - # resp.agent_action_group.updated_at #=> Time + # resp.agent_action_group.description #=> String # resp.agent_action_group.parent_action_signature #=> String, one of "AMAZON.UserInput" - # resp.agent_action_group.action_group_executor.lambda #=> String - # resp.agent_action_group.api_schema.s3.s3_bucket_name #=> String - # resp.agent_action_group.api_schema.s3.s3_object_key #=> String - # resp.agent_action_group.api_schema.payload #=> String - # resp.agent_action_group.action_group_state #=> String, one of "ENABLED", "DISABLED" + # resp.agent_action_group.updated_at #=> Time # # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/UpdateAgentActionGroup AWS API Documentation # # @overload update_agent_action_group(params = {}) # @param [Hash] params ({}) def update_agent_action_group(params = {}, options = {}) req = build_request(:update_agent_action_group, params) req.send_request(options) end - # Updates an existing Alias for an Amazon Bedrock Agent + # Updates configurations for an alias of an agent. # - # @option params [required, String] :agent_id - # Id generated at the server side when an Agent is created - # # @option params [required, String] :agent_alias_id - # Id generated at the server side when an Agent Alias is created + # The unique identifier of the alias. # # @option params [required, String] :agent_alias_name - # Name for a resource. + # Specifies a new name for the alias. # + # @option params [required, String] :agent_id + # The unique identifier of the agent. + # # @option params [String] :description - # Description of the Resource. + # Specifies a new description for the alias. # # @option params [Array<Types::AgentAliasRoutingConfigurationListItem>] :routing_configuration - # Routing configuration for an Agent alias. + # Contains details about the routing configuration of the alias. # # @return [Types::UpdateAgentAliasResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: # # * {Types::UpdateAgentAliasResponse#agent_alias #agent_alias} => Types::AgentAlias # # @example Request syntax with placeholder values # # resp = client.update_agent_alias({ - # agent_id: "Id", # required # agent_alias_id: "AgentAliasId", # required # agent_alias_name: "Name", # required + # agent_id: "Id", # required # description: "Description", # routing_configuration: [ # { # agent_version: "Version", # required # }, # ], # }) # # @example Response structure # - # resp.agent_alias.agent_id #=> String + # resp.agent_alias.agent_alias_arn #=> String + # resp.agent_alias.agent_alias_history_events #=> Array + # resp.agent_alias.agent_alias_history_events[0].end_date #=> Time + # resp.agent_alias.agent_alias_history_events[0].routing_configuration #=> Array + # resp.agent_alias.agent_alias_history_events[0].routing_configuration[0].agent_version #=> String + # resp.agent_alias.agent_alias_history_events[0].start_date #=> Time # resp.agent_alias.agent_alias_id #=> String # resp.agent_alias.agent_alias_name #=> String - # resp.agent_alias.agent_alias_arn #=> String + # resp.agent_alias.agent_alias_status #=> String, one of "CREATING", "PREPARED", "FAILED", "UPDATING", "DELETING" + # resp.agent_alias.agent_id #=> String # resp.agent_alias.client_token #=> String + # resp.agent_alias.created_at #=> Time # resp.agent_alias.description #=> String # resp.agent_alias.routing_configuration #=> Array # resp.agent_alias.routing_configuration[0].agent_version #=> String - # resp.agent_alias.created_at #=> Time # resp.agent_alias.updated_at #=> Time - # resp.agent_alias.agent_alias_history_events #=> Array - # resp.agent_alias.agent_alias_history_events[0].routing_configuration #=> Array - # resp.agent_alias.agent_alias_history_events[0].routing_configuration[0].agent_version #=> String - # resp.agent_alias.agent_alias_history_events[0].end_date #=> Time - # resp.agent_alias.agent_alias_history_events[0].start_date #=> Time - # resp.agent_alias.agent_alias_status #=> String, one of "CREATING", "PREPARED", "FAILED", "UPDATING", "DELETING" # # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/UpdateAgentAlias AWS API Documentation # # @overload update_agent_alias(params = {}) # @param [Hash] params ({}) def update_agent_alias(params = {}, options = {}) req = build_request(:update_agent_alias, params) req.send_request(options) end - # Updates an existing Knowledge Base associated to an Amazon Bedrock - # Agent + # Updates the configuration for a knowledge base that has been + # associated with an agent. # # @option params [required, String] :agent_id - # Id generated at the server side when an Agent is created + # The unique identifier of the agent associated with the knowledge base + # that you want to update. # # @option params [required, String] :agent_version - # Draft Version of the Agent. + # The version of the agent associated with the knowledge base that you + # want to update. # - # @option params [required, String] :knowledge_base_id - # Id generated at the server side when a Knowledge Base is associated to - # an Agent - # # @option params [String] :description - # Description of the Resource. + # Specifies a new description for the knowledge base associated with an + # agent. # + # @option params [required, String] :knowledge_base_id + # The unique identifier of the knowledge base that has been associated + # with an agent. + # # @option params [String] :knowledge_base_state - # State of the knowledge base; whether it is enabled or disabled + # Specifies whether the agent uses the knowledge base or not when + # sending an [InvokeAgent][1] request. # + # + # + # [1]: https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_InvokeAgent.html + # # @return [Types::UpdateAgentKnowledgeBaseResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: # # * {Types::UpdateAgentKnowledgeBaseResponse#agent_knowledge_base #agent_knowledge_base} => Types::AgentKnowledgeBase # # @example Request syntax with placeholder values # # resp = client.update_agent_knowledge_base({ # agent_id: "Id", # required # agent_version: "DraftVersion", # required - # knowledge_base_id: "Id", # required # description: "Description", + # knowledge_base_id: "Id", # required # knowledge_base_state: "ENABLED", # accepts ENABLED, DISABLED # }) # # @example Response structure # # resp.agent_knowledge_base.agent_id #=> String # resp.agent_knowledge_base.agent_version #=> String - # resp.agent_knowledge_base.knowledge_base_id #=> String - # resp.agent_knowledge_base.description #=> String # resp.agent_knowledge_base.created_at #=> Time - # resp.agent_knowledge_base.updated_at #=> Time + # resp.agent_knowledge_base.description #=> String + # resp.agent_knowledge_base.knowledge_base_id #=> String # resp.agent_knowledge_base.knowledge_base_state #=> String, one of "ENABLED", "DISABLED" + # resp.agent_knowledge_base.updated_at #=> Time # # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/UpdateAgentKnowledgeBase AWS API Documentation # # @overload update_agent_knowledge_base(params = {}) # @param [Hash] params ({}) def update_agent_knowledge_base(params = {}, options = {}) req = build_request(:update_agent_knowledge_base, params) req.send_request(options) end - # Update an existing data source + # Updates configurations for a data source. # - # @option params [required, String] :knowledge_base_id - # Identifier for a resource. + # You can't change the `chunkingConfiguration` after you create the + # data source. Specify the existing `chunkingConfiguration`. # + # @option params [required, Types::DataSourceConfiguration] :data_source_configuration + # Contains details about the storage configuration of the data source. + # # @option params [required, String] :data_source_id - # Identifier for a resource. + # The unique identifier of the data source. # - # @option params [required, String] :name - # Name for a resource. - # # @option params [String] :description - # Description of the Resource. + # Specifies a new description for the data source. # - # @option params [required, Types::DataSourceConfiguration] :data_source_configuration - # Specifies a raw data source location to ingest. + # @option params [required, String] :knowledge_base_id + # The unique identifier of the knowledge base to which the data source + # belongs. # + # @option params [required, String] :name + # Specifies a new name for the data source. + # # @option params [Types::ServerSideEncryptionConfiguration] :server_side_encryption_configuration - # Server-side encryption configuration. + # Contains details about server-side encryption of the data source. # # @option params [Types::VectorIngestionConfiguration] :vector_ingestion_configuration - # Configures ingestion for a vector knowledge base + # Contains details about how to ingest the documents in the data source. # # @return [Types::UpdateDataSourceResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: # # * {Types::UpdateDataSourceResponse#data_source #data_source} => Types::DataSource # # @example Request syntax with placeholder values # # resp = client.update_data_source({ - # knowledge_base_id: "Id", # required - # data_source_id: "Id", # required - # name: "Name", # required - # description: "Description", # data_source_configuration: { # required - # type: "S3", # required, accepts S3 # s3_configuration: { # bucket_arn: "S3BucketArn", # required # inclusion_prefixes: ["S3Prefix"], # }, + # type: "S3", # required, accepts S3 # }, + # data_source_id: "Id", # required + # description: "Description", + # knowledge_base_id: "Id", # required + # name: "Name", # required # server_side_encryption_configuration: { # kms_key_arn: "KmsKeyArn", # }, # vector_ingestion_configuration: { # chunking_configuration: { @@ -2527,156 +2855,180 @@ # }, # }) # # @example Response structure # - # resp.data_source.knowledge_base_id #=> String - # resp.data_source.data_source_id #=> String - # resp.data_source.name #=> String - # resp.data_source.status #=> String, one of "AVAILABLE", "DELETING" - # resp.data_source.description #=> String - # resp.data_source.data_source_configuration.type #=> String, one of "S3" + # resp.data_source.created_at #=> Time # resp.data_source.data_source_configuration.s3_configuration.bucket_arn #=> String # resp.data_source.data_source_configuration.s3_configuration.inclusion_prefixes #=> Array # resp.data_source.data_source_configuration.s3_configuration.inclusion_prefixes[0] #=> String + # resp.data_source.data_source_configuration.type #=> String, one of "S3" + # resp.data_source.data_source_id #=> String + # resp.data_source.description #=> String + # resp.data_source.knowledge_base_id #=> String + # resp.data_source.name #=> String # resp.data_source.server_side_encryption_configuration.kms_key_arn #=> String + # resp.data_source.status #=> String, one of "AVAILABLE", "DELETING" + # resp.data_source.updated_at #=> Time # resp.data_source.vector_ingestion_configuration.chunking_configuration.chunking_strategy #=> String, one of "FIXED_SIZE", "NONE" # resp.data_source.vector_ingestion_configuration.chunking_configuration.fixed_size_chunking_configuration.max_tokens #=> Integer # resp.data_source.vector_ingestion_configuration.chunking_configuration.fixed_size_chunking_configuration.overlap_percentage #=> Integer - # resp.data_source.created_at #=> Time - # resp.data_source.updated_at #=> Time # # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/UpdateDataSource AWS API Documentation # # @overload update_data_source(params = {}) # @param [Hash] params ({}) def update_data_source(params = {}, options = {}) req = build_request(:update_data_source, params) req.send_request(options) end - # Update an existing knowledge base + # Updates the configuration of a knowledge base with the fields that you + # specify. Because all fields will be overwritten, you must include the + # same values for fields that you want to keep the same. # - # @option params [required, String] :knowledge_base_id - # Identifier for a resource. + # You can change the following fields: # - # @option params [required, String] :name - # Name for a resource. + # * `name` # - # @option params [String] :description - # Description of the Resource. + # * `description` # - # @option params [required, String] :role_arn - # ARN of a IAM role. + # * `roleArn` # + # You can't change the `knowledgeBaseConfiguration` or + # `storageConfiguration` fields, so you must specify the same + # configurations as when you created the knowledge base. You can send a + # [GetKnowledgeBase][1] request and copy the same configurations. + # + # + # + # [1]: https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent_GetKnowledgeBase.html + # + # @option params [String] :description + # Specifies a new description for the knowledge base. + # # @option params [required, Types::KnowledgeBaseConfiguration] :knowledge_base_configuration - # Configures a bedrock knowledge base. + # Specifies the configuration for the embeddings model used for the + # knowledge base. You must use the same configuration as when the + # knowledge base was created. # + # @option params [required, String] :knowledge_base_id + # The unique identifier of the knowledge base to update. + # + # @option params [required, String] :name + # Specifies a new name for the knowledge base. + # + # @option params [required, String] :role_arn + # Specifies a different Amazon Resource Name (ARN) of the IAM role with + # permissions to modify the knowledge base. + # # @option params [required, Types::StorageConfiguration] :storage_configuration - # Configures the physical storage of ingested data in a knowledge base. + # Specifies the configuration for the vector store used for the + # knowledge base. You must use the same configuration as when the + # knowledge base was created. # # @return [Types::UpdateKnowledgeBaseResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods: # # * {Types::UpdateKnowledgeBaseResponse#knowledge_base #knowledge_base} => Types::KnowledgeBase # # @example Request syntax with placeholder values # # resp = client.update_knowledge_base({ - # knowledge_base_id: "Id", # required - # name: "Name", # required # description: "Description", - # role_arn: "KnowledgeBaseRoleArn", # required # knowledge_base_configuration: { # required # type: "VECTOR", # required, accepts VECTOR # vector_knowledge_base_configuration: { # embedding_model_arn: "BedrockEmbeddingModelArn", # required # }, # }, + # knowledge_base_id: "Id", # required + # name: "Name", # required + # role_arn: "KnowledgeBaseRoleArn", # required # storage_configuration: { # required - # type: "OPENSEARCH_SERVERLESS", # required, accepts OPENSEARCH_SERVERLESS, PINECONE, REDIS_ENTERPRISE_CLOUD, RDS # opensearch_serverless_configuration: { # collection_arn: "OpenSearchServerlessCollectionArn", # required - # vector_index_name: "OpenSearchServerlessIndexName", # required # field_mapping: { # required - # vector_field: "FieldName", # required - # text_field: "FieldName", # required # metadata_field: "FieldName", # required + # text_field: "FieldName", # required + # vector_field: "FieldName", # required # }, + # vector_index_name: "OpenSearchServerlessIndexName", # required # }, # pinecone_configuration: { # connection_string: "PineconeConnectionString", # required # credentials_secret_arn: "SecretArn", # required - # namespace: "PineconeNamespace", # field_mapping: { # required - # text_field: "FieldName", # required # metadata_field: "FieldName", # required - # }, - # }, - # redis_enterprise_cloud_configuration: { - # endpoint: "RedisEnterpriseCloudEndpoint", # required - # vector_index_name: "RedisEnterpriseCloudIndexName", # required - # credentials_secret_arn: "SecretArn", # required - # field_mapping: { # required - # vector_field: "FieldName", # required # text_field: "FieldName", # required - # metadata_field: "FieldName", # required # }, + # namespace: "PineconeNamespace", # }, # rds_configuration: { - # resource_arn: "RdsArn", # required # credentials_secret_arn: "SecretArn", # required # database_name: "RdsDatabaseName", # required - # table_name: "RdsTableName", # required # field_mapping: { # required + # metadata_field: "ColumnName", # required # primary_key_field: "ColumnName", # required - # vector_field: "ColumnName", # required # text_field: "ColumnName", # required - # metadata_field: "ColumnName", # required + # vector_field: "ColumnName", # required # }, + # resource_arn: "RdsArn", # required + # table_name: "RdsTableName", # required # }, + # redis_enterprise_cloud_configuration: { + # credentials_secret_arn: "SecretArn", # required + # endpoint: "RedisEnterpriseCloudEndpoint", # required + # field_mapping: { # required + # metadata_field: "FieldName", # required + # text_field: "FieldName", # required + # vector_field: "FieldName", # required + # }, + # vector_index_name: "RedisEnterpriseCloudIndexName", # required + # }, + # type: "OPENSEARCH_SERVERLESS", # required, accepts OPENSEARCH_SERVERLESS, PINECONE, REDIS_ENTERPRISE_CLOUD, RDS # }, # }) # # @example Response structure # - # resp.knowledge_base.knowledge_base_id #=> String - # resp.knowledge_base.name #=> String - # resp.knowledge_base.knowledge_base_arn #=> String + # resp.knowledge_base.created_at #=> Time # resp.knowledge_base.description #=> String - # resp.knowledge_base.role_arn #=> String + # resp.knowledge_base.failure_reasons #=> Array + # resp.knowledge_base.failure_reasons[0] #=> String + # resp.knowledge_base.knowledge_base_arn #=> String # resp.knowledge_base.knowledge_base_configuration.type #=> String, one of "VECTOR" # resp.knowledge_base.knowledge_base_configuration.vector_knowledge_base_configuration.embedding_model_arn #=> String - # resp.knowledge_base.storage_configuration.type #=> String, one of "OPENSEARCH_SERVERLESS", "PINECONE", "REDIS_ENTERPRISE_CLOUD", "RDS" + # resp.knowledge_base.knowledge_base_id #=> String + # resp.knowledge_base.name #=> String + # resp.knowledge_base.role_arn #=> String + # resp.knowledge_base.status #=> String, one of "CREATING", "ACTIVE", "DELETING", "UPDATING", "FAILED" # resp.knowledge_base.storage_configuration.opensearch_serverless_configuration.collection_arn #=> String - # resp.knowledge_base.storage_configuration.opensearch_serverless_configuration.vector_index_name #=> String - # resp.knowledge_base.storage_configuration.opensearch_serverless_configuration.field_mapping.vector_field #=> String - # resp.knowledge_base.storage_configuration.opensearch_serverless_configuration.field_mapping.text_field #=> String # resp.knowledge_base.storage_configuration.opensearch_serverless_configuration.field_mapping.metadata_field #=> String + # resp.knowledge_base.storage_configuration.opensearch_serverless_configuration.field_mapping.text_field #=> String + # resp.knowledge_base.storage_configuration.opensearch_serverless_configuration.field_mapping.vector_field #=> String + # resp.knowledge_base.storage_configuration.opensearch_serverless_configuration.vector_index_name #=> String # resp.knowledge_base.storage_configuration.pinecone_configuration.connection_string #=> String # resp.knowledge_base.storage_configuration.pinecone_configuration.credentials_secret_arn #=> String - # resp.knowledge_base.storage_configuration.pinecone_configuration.namespace #=> String - # resp.knowledge_base.storage_configuration.pinecone_configuration.field_mapping.text_field #=> String # resp.knowledge_base.storage_configuration.pinecone_configuration.field_mapping.metadata_field #=> String - # resp.knowledge_base.storage_configuration.redis_enterprise_cloud_configuration.endpoint #=> String - # resp.knowledge_base.storage_configuration.redis_enterprise_cloud_configuration.vector_index_name #=> String - # resp.knowledge_base.storage_configuration.redis_enterprise_cloud_configuration.credentials_secret_arn #=> String - # resp.knowledge_base.storage_configuration.redis_enterprise_cloud_configuration.field_mapping.vector_field #=> String - # resp.knowledge_base.storage_configuration.redis_enterprise_cloud_configuration.field_mapping.text_field #=> String - # resp.knowledge_base.storage_configuration.redis_enterprise_cloud_configuration.field_mapping.metadata_field #=> String - # resp.knowledge_base.storage_configuration.rds_configuration.resource_arn #=> String + # resp.knowledge_base.storage_configuration.pinecone_configuration.field_mapping.text_field #=> String + # resp.knowledge_base.storage_configuration.pinecone_configuration.namespace #=> String # resp.knowledge_base.storage_configuration.rds_configuration.credentials_secret_arn #=> String # resp.knowledge_base.storage_configuration.rds_configuration.database_name #=> String - # resp.knowledge_base.storage_configuration.rds_configuration.table_name #=> String + # resp.knowledge_base.storage_configuration.rds_configuration.field_mapping.metadata_field #=> String # resp.knowledge_base.storage_configuration.rds_configuration.field_mapping.primary_key_field #=> String - # resp.knowledge_base.storage_configuration.rds_configuration.field_mapping.vector_field #=> String # resp.knowledge_base.storage_configuration.rds_configuration.field_mapping.text_field #=> String - # resp.knowledge_base.storage_configuration.rds_configuration.field_mapping.metadata_field #=> String - # resp.knowledge_base.status #=> String, one of "CREATING", "ACTIVE", "DELETING", "UPDATING", "FAILED" - # resp.knowledge_base.created_at #=> Time + # resp.knowledge_base.storage_configuration.rds_configuration.field_mapping.vector_field #=> String + # resp.knowledge_base.storage_configuration.rds_configuration.resource_arn #=> String + # resp.knowledge_base.storage_configuration.rds_configuration.table_name #=> String + # resp.knowledge_base.storage_configuration.redis_enterprise_cloud_configuration.credentials_secret_arn #=> String + # resp.knowledge_base.storage_configuration.redis_enterprise_cloud_configuration.endpoint #=> String + # resp.knowledge_base.storage_configuration.redis_enterprise_cloud_configuration.field_mapping.metadata_field #=> String + # resp.knowledge_base.storage_configuration.redis_enterprise_cloud_configuration.field_mapping.text_field #=> String + # resp.knowledge_base.storage_configuration.redis_enterprise_cloud_configuration.field_mapping.vector_field #=> String + # resp.knowledge_base.storage_configuration.redis_enterprise_cloud_configuration.vector_index_name #=> String + # resp.knowledge_base.storage_configuration.type #=> String, one of "OPENSEARCH_SERVERLESS", "PINECONE", "REDIS_ENTERPRISE_CLOUD", "RDS" # resp.knowledge_base.updated_at #=> Time - # resp.knowledge_base.failure_reasons #=> Array - # resp.knowledge_base.failure_reasons[0] #=> String # # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-2023-06-05/UpdateKnowledgeBase AWS API Documentation # # @overload update_knowledge_base(params = {}) # @param [Hash] params ({}) @@ -2696,10 +3048,10 @@ operation: config.api.operation(operation_name), client: self, params: params, config: config) context[:gem_name] = 'aws-sdk-bedrockagent' - context[:gem_version] = '1.3.0' + context[:gem_version] = '1.4.0' Seahorse::Client::Request.new(handlers, context) end # @api private # @deprecated