aws-sdk-bedrockagentruntime 1.37.0 → 1.39.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 5763023f6a0f5edc0d3ccfa6dbfc881b7dbd0167c7d2a6f2328f99e698f275a8
4
- data.tar.gz: fcbdb4c717cb80b1ebf2479d520e71a429cc700d283f5101dcfd6a3b307cebc7
3
+ metadata.gz: a0937c50cd571aabc4903c40c30472eda5ab8b4bf2ad1915c7f2704f26d07955
4
+ data.tar.gz: cdf2181f560b55b48eb9a58316e557b14140a64194babaa9ce86a20cd14f9cd7
5
5
  SHA512:
6
- metadata.gz: df2af2820f48a6520ac57de2b6c3e48eeddbaceaf966e4298ff012d10b460d86a52cb6b710e9cc598cf411258b0efb556666286da9de6d927c0d863539b2cd63
7
- data.tar.gz: a02ab42034b2a47cb480d26129a857e81044f971d6fcf63ae46ba4aae9c85672d685a07827a1553dd904074f7ab71fe74c575595696cb0bd9fed01bd99eb21ec
6
+ metadata.gz: a6b7a30992848738210df2f7eb908f211a871f8bfc2be240949d5aad710c92caece3943aa12b19dd4e099ee4f2ed60eb32d0d565f28d962b9bbfa9fe2a1c2c98
7
+ data.tar.gz: 3ed9c82f6329c19c154d6a4f0f7c9676ca7020bd753aafdaf320edbea466890fe672ab3168edcc752647c6d9665719aaeeada3eb9a8267c0c5154e5a71e51eff
data/CHANGELOG.md CHANGED
@@ -1,6 +1,16 @@
1
1
  Unreleased Changes
2
2
  ------------------
3
3
 
4
+ 1.39.0 (2025-01-15)
5
+ ------------------
6
+
7
+ * Feature - Now supports streaming for inline agents.
8
+
9
+ 1.38.0 (2024-12-20)
10
+ ------------------
11
+
12
+ * Feature - bedrock agents now supports long term memory and performance configs. Invokeflow supports performance configs. RetrieveAndGenerate performance configs
13
+
4
14
  1.37.0 (2024-12-04)
5
15
  ------------------
6
16
 
data/VERSION CHANGED
@@ -1 +1 @@
1
- 1.37.0
1
+ 1.39.0
@@ -268,11 +268,34 @@ module Aws::BedrockAgentRuntime
268
268
  # Used when loading credentials from the shared credentials file
269
269
  # at HOME/.aws/credentials. When not specified, 'default' is used.
270
270
  #
271
+ # @option options [String] :request_checksum_calculation ("when_supported")
272
+ # Determines when a checksum will be calculated for request payloads. Values are:
273
+ #
274
+ # * `when_supported` - (default) When set, a checksum will be
275
+ # calculated for all request payloads of operations modeled with the
276
+ # `httpChecksum` trait where `requestChecksumRequired` is `true` and/or a
277
+ # `requestAlgorithmMember` is modeled.
278
+ # * `when_required` - When set, a checksum will only be calculated for
279
+ # request payloads of operations modeled with the `httpChecksum` trait where
280
+ # `requestChecksumRequired` is `true` or where a `requestAlgorithmMember`
281
+ # is modeled and supplied.
282
+ #
271
283
  # @option options [Integer] :request_min_compression_size_bytes (10240)
272
284
  # The minimum size in bytes that triggers compression for request
273
285
  # bodies. The value must be non-negative integer value between 0
274
286
  # and 10485780 bytes inclusive.
275
287
  #
288
+ # @option options [String] :response_checksum_validation ("when_supported")
289
+ # Determines when checksum validation will be performed on response payloads. Values are:
290
+ #
291
+ # * `when_supported` - (default) When set, checksum validation is performed on all
292
+ # response payloads of operations modeled with the `httpChecksum` trait where
293
+ # `responseAlgorithms` is modeled, except when no modeled checksum algorithms
294
+ # are supported.
295
+ # * `when_required` - When set, checksum validation is not performed on
296
+ # response payloads of operations unless the checksum algorithm is supported and
297
+ # the `requestValidationModeMember` member is set to `ENABLED`.
298
+ #
276
299
  # @option options [Proc] :retry_backoff
277
300
  # A proc or lambda used for backoff. Defaults to 2**retries * retry_base_delay.
278
301
  # This option is only used in the `legacy` retry mode.
@@ -469,6 +492,9 @@ module Aws::BedrockAgentRuntime
469
492
  # @option params [String] :memory_id
470
493
  # The unique identifier of the memory.
471
494
  #
495
+ # @option params [String] :session_id
496
+ # The unique session identifier of the memory.
497
+ #
472
498
  # @return [Struct] Returns an empty {Seahorse::Client::Response response}.
473
499
  #
474
500
  # @example Request syntax with placeholder values
@@ -477,6 +503,7 @@ module Aws::BedrockAgentRuntime
477
503
  # agent_alias_id: "AgentAliasId", # required
478
504
  # agent_id: "AgentId", # required
479
505
  # memory_id: "MemoryId",
506
+ # session_id: "SessionId",
480
507
  # })
481
508
  #
482
509
  # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-runtime-2023-07-26/DeleteAgentMemory AWS API Documentation
@@ -604,10 +631,7 @@ module Aws::BedrockAgentRuntime
604
631
  req.send_request(options)
605
632
  end
606
633
 
607
- # <note markdown="1"> The CLI doesn't support streaming operations in Amazon Bedrock,
608
- # including `InvokeAgent`.
609
- #
610
- # </note>
634
+ # <note> </note>
611
635
  #
612
636
  # Sends a prompt for the agent to process and respond to. Note the
613
637
  # following fields for the request:
@@ -621,13 +645,26 @@ module Aws::BedrockAgentRuntime
621
645
  # final result it yielded. For more information, see [Trace
622
646
  # enablement][1].
623
647
  #
648
+ # * To stream agent responses, make sure that only orchestration prompt
649
+ # is enabled. Agent streaming is not supported for the following
650
+ # steps:
651
+ #
652
+ # * `Pre-processing`
653
+ #
654
+ # * `Post-processing`
655
+ #
656
+ # * Agent with 1 Knowledge base and `User Input` not enabled
624
657
  # * End a conversation by setting `endSession` to `true`.
625
658
  #
626
659
  # * In the `sessionState` object, you can include attributes for the
627
660
  # session or prompt or, if you configured an action group to return
628
661
  # control, results from invocation of the action group.
629
662
  #
630
- # The response is returned in the `bytes` field of the `chunk` object.
663
+ # The response contains both **chunk** and **trace** attributes.
664
+ #
665
+ # The final response is returned in the `bytes` field of the `chunk`
666
+ # object. The `InvokeAgent` returns one chunk for the entire
667
+ # interaction.
631
668
  #
632
669
  # * The `attribution` object contains citations for parts of the
633
670
  # response.
@@ -651,6 +688,9 @@ module Aws::BedrockAgentRuntime
651
688
  # @option params [required, String] :agent_id
652
689
  # The unique identifier of the agent to use.
653
690
  #
691
+ # @option params [Types::BedrockModelConfigurations] :bedrock_model_configurations
692
+ # Model performance settings for the request.
693
+ #
654
694
  # @option params [Boolean] :enable_trace
655
695
  # Specifies whether to turn on the trace or not to track the agent's
656
696
  # reasoning process. For more information, see [Trace enablement][1].
@@ -696,6 +736,11 @@ module Aws::BedrockAgentRuntime
696
736
  # @option params [Types::StreamingConfigurations] :streaming_configurations
697
737
  # Specifies the configurations for streaming.
698
738
  #
739
+ # <note markdown="1"> To use agent streaming, you need permissions to perform the
740
+ # `bedrock:InvokeModelWithResponseStream` action.
741
+ #
742
+ # </note>
743
+ #
699
744
  # @return [Types::InvokeAgentResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
700
745
  #
701
746
  # * {Types::InvokeAgentResponse#completion #completion} => Types::ResponseStream
@@ -767,6 +812,9 @@ module Aws::BedrockAgentRuntime
767
812
  # handler.on_internal_server_exception_event do |event|
768
813
  # event # => Aws::BedrockAgentRuntime::Types::internalServerException
769
814
  # end
815
+ # handler.on_model_not_ready_exception_event do |event|
816
+ # event # => Aws::BedrockAgentRuntime::Types::modelNotReadyException
817
+ # end
770
818
  # handler.on_resource_not_found_exception_event do |event|
771
819
  # event # => Aws::BedrockAgentRuntime::Types::resourceNotFoundException
772
820
  # end
@@ -813,6 +861,9 @@ module Aws::BedrockAgentRuntime
813
861
  # stream.on_internal_server_exception_event do |event|
814
862
  # event # => Aws::BedrockAgentRuntime::Types::internalServerException
815
863
  # end
864
+ # stream.on_model_not_ready_exception_event do |event|
865
+ # event # => Aws::BedrockAgentRuntime::Types::modelNotReadyException
866
+ # end
816
867
  # stream.on_resource_not_found_exception_event do |event|
817
868
  # event # => Aws::BedrockAgentRuntime::Types::resourceNotFoundException
818
869
  # end
@@ -859,6 +910,9 @@ module Aws::BedrockAgentRuntime
859
910
  # handler.on_internal_server_exception_event do |event|
860
911
  # event # => Aws::BedrockAgentRuntime::Types::internalServerException
861
912
  # end
913
+ # handler.on_model_not_ready_exception_event do |event|
914
+ # event # => Aws::BedrockAgentRuntime::Types::modelNotReadyException
915
+ # end
862
916
  # handler.on_resource_not_found_exception_event do |event|
863
917
  # event # => Aws::BedrockAgentRuntime::Types::resourceNotFoundException
864
918
  # end
@@ -899,6 +953,11 @@ module Aws::BedrockAgentRuntime
899
953
  # resp = client.invoke_agent({
900
954
  # agent_alias_id: "AgentAliasId", # required
901
955
  # agent_id: "AgentId", # required
956
+ # bedrock_model_configurations: {
957
+ # performance_config: {
958
+ # latency: "standard", # accepts standard, optimized
959
+ # },
960
+ # },
902
961
  # enable_trace: false,
903
962
  # end_session: false,
904
963
  # input_text: "InputText",
@@ -1098,7 +1157,7 @@ module Aws::BedrockAgentRuntime
1098
1157
  #
1099
1158
  # All events are available at resp.completion:
1100
1159
  # resp.completion #=> Enumerator
1101
- # resp.completion.event_types #=> [:access_denied_exception, :bad_gateway_exception, :chunk, :conflict_exception, :dependency_failed_exception, :files, :internal_server_exception, :resource_not_found_exception, :return_control, :service_quota_exceeded_exception, :throttling_exception, :trace, :validation_exception]
1160
+ # resp.completion.event_types #=> [:access_denied_exception, :bad_gateway_exception, :chunk, :conflict_exception, :dependency_failed_exception, :files, :internal_server_exception, :model_not_ready_exception, :resource_not_found_exception, :return_control, :service_quota_exceeded_exception, :throttling_exception, :trace, :validation_exception]
1102
1161
  #
1103
1162
  # For :access_denied_exception event available at #on_access_denied_exception_event callback and response eventstream enumerator:
1104
1163
  # event.message #=> String
@@ -1148,6 +1207,9 @@ module Aws::BedrockAgentRuntime
1148
1207
  # For :internal_server_exception event available at #on_internal_server_exception_event callback and response eventstream enumerator:
1149
1208
  # event.message #=> String
1150
1209
  #
1210
+ # For :model_not_ready_exception event available at #on_model_not_ready_exception_event callback and response eventstream enumerator:
1211
+ # event.message #=> String
1212
+ #
1151
1213
  # For :resource_not_found_exception event available at #on_resource_not_found_exception_event callback and response eventstream enumerator:
1152
1214
  # event.message #=> String
1153
1215
  #
@@ -1598,6 +1660,9 @@ module Aws::BedrockAgentRuntime
1598
1660
  # A list of objects, each containing information about an input into the
1599
1661
  # flow.
1600
1662
  #
1663
+ # @option params [Types::ModelPerformanceConfiguration] :model_performance_configuration
1664
+ # Model performance settings for the request.
1665
+ #
1601
1666
  # @return [Types::InvokeFlowResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
1602
1667
  #
1603
1668
  # * {Types::InvokeFlowResponse#response_stream #response_stream} => Types::FlowResponseStream
@@ -1800,6 +1865,11 @@ module Aws::BedrockAgentRuntime
1800
1865
  # node_output_name: "NodeOutputName", # required
1801
1866
  # },
1802
1867
  # ],
1868
+ # model_performance_configuration: {
1869
+ # performance_config: {
1870
+ # latency: "standard", # accepts standard, optimized
1871
+ # },
1872
+ # },
1803
1873
  # })
1804
1874
  #
1805
1875
  # @example Response structure
@@ -1905,10 +1975,7 @@ module Aws::BedrockAgentRuntime
1905
1975
  # one knowledge base, uses default prompts, has no action group, and
1906
1976
  # user input is disabled.
1907
1977
  #
1908
- # <note markdown="1"> The CLI doesn't support streaming operations in Amazon Bedrock,
1909
- # including `InvokeInlineAgent`.
1910
- #
1911
- # </note>
1978
+ # <note> </note>
1912
1979
  #
1913
1980
  #
1914
1981
  #
@@ -1918,6 +1985,9 @@ module Aws::BedrockAgentRuntime
1918
1985
  # A list of action groups with each action group defining the action the
1919
1986
  # inline agent needs to carry out.
1920
1987
  #
1988
+ # @option params [Types::InlineBedrockModelConfigurations] :bedrock_model_configurations
1989
+ # Model settings for the request.
1990
+ #
1921
1991
  # @option params [String] :customer_encryption_key_arn
1922
1992
  # The Amazon Resource Name (ARN) of the Amazon Web Services KMS key to
1923
1993
  # use to encrypt your inline agent.
@@ -1996,6 +2066,14 @@ module Aws::BedrockAgentRuntime
1996
2066
  # The unique identifier of the session. Use the same value across
1997
2067
  # requests to continue the same conversation.
1998
2068
  #
2069
+ # @option params [Types::StreamingConfigurations] :streaming_configurations
2070
+ # Specifies the configurations for streaming.
2071
+ #
2072
+ # <note markdown="1"> To use agent streaming, you need permissions to perform the
2073
+ # `bedrock:InvokeModelWithResponseStream` action.
2074
+ #
2075
+ # </note>
2076
+ #
1999
2077
  # @return [Types::InvokeInlineAgentResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
2000
2078
  #
2001
2079
  # * {Types::InvokeInlineAgentResponse#completion #completion} => Types::InlineAgentResponseStream
@@ -2230,6 +2308,11 @@ module Aws::BedrockAgentRuntime
2230
2308
  # parent_action_group_signature: "AMAZON.UserInput", # accepts AMAZON.UserInput, AMAZON.CodeInterpreter
2231
2309
  # },
2232
2310
  # ],
2311
+ # bedrock_model_configurations: {
2312
+ # performance_config: {
2313
+ # latency: "standard", # accepts standard, optimized
2314
+ # },
2315
+ # },
2233
2316
  # customer_encryption_key_arn: "KmsKeyArn",
2234
2317
  # enable_trace: false,
2235
2318
  # end_session: false,
@@ -2433,6 +2516,10 @@ module Aws::BedrockAgentRuntime
2433
2516
  # ],
2434
2517
  # },
2435
2518
  # session_id: "SessionId", # required
2519
+ # streaming_configurations: {
2520
+ # apply_guardrail_interval: 1,
2521
+ # stream_final_response: false,
2522
+ # },
2436
2523
  # })
2437
2524
  #
2438
2525
  # @example Response structure
@@ -3475,6 +3562,9 @@ module Aws::BedrockAgentRuntime
3475
3562
  # top_p: 1.0,
3476
3563
  # },
3477
3564
  # },
3565
+ # performance_config: {
3566
+ # latency: "standard", # accepts standard, optimized
3567
+ # },
3478
3568
  # prompt_template: {
3479
3569
  # text_prompt_template: "TextPromptTemplate",
3480
3570
  # },
@@ -3512,6 +3602,9 @@ module Aws::BedrockAgentRuntime
3512
3602
  # top_p: 1.0,
3513
3603
  # },
3514
3604
  # },
3605
+ # performance_config: {
3606
+ # latency: "standard", # accepts standard, optimized
3607
+ # },
3515
3608
  # prompt_template: {
3516
3609
  # text_prompt_template: "TextPromptTemplate",
3517
3610
  # },
@@ -3531,6 +3624,9 @@ module Aws::BedrockAgentRuntime
3531
3624
  # top_p: 1.0,
3532
3625
  # },
3533
3626
  # },
3627
+ # performance_config: {
3628
+ # latency: "standard", # accepts standard, optimized
3629
+ # },
3534
3630
  # prompt_template: {
3535
3631
  # text_prompt_template: "TextPromptTemplate",
3536
3632
  # },
@@ -3937,6 +4033,9 @@ module Aws::BedrockAgentRuntime
3937
4033
  # top_p: 1.0,
3938
4034
  # },
3939
4035
  # },
4036
+ # performance_config: {
4037
+ # latency: "standard", # accepts standard, optimized
4038
+ # },
3940
4039
  # prompt_template: {
3941
4040
  # text_prompt_template: "TextPromptTemplate",
3942
4041
  # },
@@ -3974,6 +4073,9 @@ module Aws::BedrockAgentRuntime
3974
4073
  # top_p: 1.0,
3975
4074
  # },
3976
4075
  # },
4076
+ # performance_config: {
4077
+ # latency: "standard", # accepts standard, optimized
4078
+ # },
3977
4079
  # prompt_template: {
3978
4080
  # text_prompt_template: "TextPromptTemplate",
3979
4081
  # },
@@ -3993,6 +4095,9 @@ module Aws::BedrockAgentRuntime
3993
4095
  # top_p: 1.0,
3994
4096
  # },
3995
4097
  # },
4098
+ # performance_config: {
4099
+ # latency: "standard", # accepts standard, optimized
4100
+ # },
3996
4101
  # prompt_template: {
3997
4102
  # text_prompt_template: "TextPromptTemplate",
3998
4103
  # },
@@ -4230,7 +4335,7 @@ module Aws::BedrockAgentRuntime
4230
4335
  tracer: tracer
4231
4336
  )
4232
4337
  context[:gem_name] = 'aws-sdk-bedrockagentruntime'
4233
- context[:gem_version] = '1.37.0'
4338
+ context[:gem_version] = '1.39.0'
4234
4339
  Seahorse::Client::Request.new(handlers, context)
4235
4340
  end
4236
4341
 
@@ -51,6 +51,7 @@ module Aws::BedrockAgentRuntime
51
51
  BadGatewayException = Shapes::StructureShape.new(name: 'BadGatewayException')
52
52
  BasePromptTemplate = Shapes::StringShape.new(name: 'BasePromptTemplate')
53
53
  BedrockModelArn = Shapes::StringShape.new(name: 'BedrockModelArn')
54
+ BedrockModelConfigurations = Shapes::StructureShape.new(name: 'BedrockModelConfigurations')
54
55
  BedrockRerankingConfiguration = Shapes::StructureShape.new(name: 'BedrockRerankingConfiguration')
55
56
  BedrockRerankingConfigurationNumberOfResultsInteger = Shapes::IntegerShape.new(name: 'BedrockRerankingConfigurationNumberOfResultsInteger')
56
57
  BedrockRerankingModelArn = Shapes::StringShape.new(name: 'BedrockRerankingModelArn')
@@ -195,6 +196,7 @@ module Aws::BedrockAgentRuntime
195
196
  InlineAgentResponseStream = Shapes::StructureShape.new(name: 'InlineAgentResponseStream')
196
197
  InlineAgentReturnControlPayload = Shapes::StructureShape.new(name: 'InlineAgentReturnControlPayload')
197
198
  InlineAgentTracePart = Shapes::StructureShape.new(name: 'InlineAgentTracePart')
199
+ InlineBedrockModelConfigurations = Shapes::StructureShape.new(name: 'InlineBedrockModelConfigurations')
198
200
  InlineSessionState = Shapes::StructureShape.new(name: 'InlineSessionState')
199
201
  InputFile = Shapes::StructureShape.new(name: 'InputFile')
200
202
  InputFiles = Shapes::ListShape.new(name: 'InputFiles')
@@ -254,6 +256,8 @@ module Aws::BedrockAgentRuntime
254
256
  MimeType = Shapes::StringShape.new(name: 'MimeType')
255
257
  ModelIdentifier = Shapes::StringShape.new(name: 'ModelIdentifier')
256
258
  ModelInvocationInput = Shapes::StructureShape.new(name: 'ModelInvocationInput')
259
+ ModelNotReadyException = Shapes::StructureShape.new(name: 'ModelNotReadyException')
260
+ ModelPerformanceConfiguration = Shapes::StructureShape.new(name: 'ModelPerformanceConfiguration')
257
261
  Name = Shapes::StringShape.new(name: 'Name')
258
262
  NextToken = Shapes::StringShape.new(name: 'NextToken')
259
263
  NodeInputName = Shapes::StringShape.new(name: 'NodeInputName')
@@ -286,6 +290,8 @@ module Aws::BedrockAgentRuntime
286
290
  Payload = Shapes::StringShape.new(name: 'Payload')
287
291
  PayloadPart = Shapes::StructureShape.new(name: 'PayloadPart')
288
292
  PayloadType = Shapes::StringShape.new(name: 'PayloadType')
293
+ PerformanceConfigLatency = Shapes::StringShape.new(name: 'PerformanceConfigLatency')
294
+ PerformanceConfiguration = Shapes::StructureShape.new(name: 'PerformanceConfiguration')
289
295
  PostProcessingModelInvocationOutput = Shapes::StructureShape.new(name: 'PostProcessingModelInvocationOutput')
290
296
  PostProcessingParsedResponse = Shapes::StructureShape.new(name: 'PostProcessingParsedResponse')
291
297
  PostProcessingTrace = Shapes::UnionShape.new(name: 'PostProcessingTrace')
@@ -536,6 +542,9 @@ module Aws::BedrockAgentRuntime
536
542
  BadGatewayException.add_member(:resource_name, Shapes::ShapeRef.new(shape: NonBlankString, location_name: "resourceName"))
537
543
  BadGatewayException.struct_class = Types::BadGatewayException
538
544
 
545
+ BedrockModelConfigurations.add_member(:performance_config, Shapes::ShapeRef.new(shape: PerformanceConfiguration, location_name: "performanceConfig"))
546
+ BedrockModelConfigurations.struct_class = Types::BedrockModelConfigurations
547
+
539
548
  BedrockRerankingConfiguration.add_member(:model_configuration, Shapes::ShapeRef.new(shape: BedrockRerankingModelConfiguration, required: true, location_name: "modelConfiguration"))
540
549
  BedrockRerankingConfiguration.add_member(:number_of_results, Shapes::ShapeRef.new(shape: BedrockRerankingConfigurationNumberOfResultsInteger, location_name: "numberOfResults"))
541
550
  BedrockRerankingConfiguration.struct_class = Types::BedrockRerankingConfiguration
@@ -610,6 +619,7 @@ module Aws::BedrockAgentRuntime
610
619
  DeleteAgentMemoryRequest.add_member(:agent_alias_id, Shapes::ShapeRef.new(shape: AgentAliasId, required: true, location: "uri", location_name: "agentAliasId"))
611
620
  DeleteAgentMemoryRequest.add_member(:agent_id, Shapes::ShapeRef.new(shape: AgentId, required: true, location: "uri", location_name: "agentId"))
612
621
  DeleteAgentMemoryRequest.add_member(:memory_id, Shapes::ShapeRef.new(shape: MemoryId, location: "querystring", location_name: "memoryId"))
622
+ DeleteAgentMemoryRequest.add_member(:session_id, Shapes::ShapeRef.new(shape: SessionId, location: "querystring", location_name: "sessionId"))
613
623
  DeleteAgentMemoryRequest.struct_class = Types::DeleteAgentMemoryRequest
614
624
 
615
625
  DeleteAgentMemoryResponse.struct_class = Types::DeleteAgentMemoryResponse
@@ -628,6 +638,7 @@ module Aws::BedrockAgentRuntime
628
638
  ExternalSourcesGenerationConfiguration.add_member(:additional_model_request_fields, Shapes::ShapeRef.new(shape: AdditionalModelRequestFields, location_name: "additionalModelRequestFields"))
629
639
  ExternalSourcesGenerationConfiguration.add_member(:guardrail_configuration, Shapes::ShapeRef.new(shape: GuardrailConfiguration, location_name: "guardrailConfiguration"))
630
640
  ExternalSourcesGenerationConfiguration.add_member(:inference_config, Shapes::ShapeRef.new(shape: InferenceConfig, location_name: "inferenceConfig"))
641
+ ExternalSourcesGenerationConfiguration.add_member(:performance_config, Shapes::ShapeRef.new(shape: PerformanceConfiguration, location_name: "performanceConfig"))
631
642
  ExternalSourcesGenerationConfiguration.add_member(:prompt_template, Shapes::ShapeRef.new(shape: PromptTemplate, location_name: "promptTemplate"))
632
643
  ExternalSourcesGenerationConfiguration.struct_class = Types::ExternalSourcesGenerationConfiguration
633
644
 
@@ -816,6 +827,7 @@ module Aws::BedrockAgentRuntime
816
827
  GenerationConfiguration.add_member(:additional_model_request_fields, Shapes::ShapeRef.new(shape: AdditionalModelRequestFields, location_name: "additionalModelRequestFields"))
817
828
  GenerationConfiguration.add_member(:guardrail_configuration, Shapes::ShapeRef.new(shape: GuardrailConfiguration, location_name: "guardrailConfiguration"))
818
829
  GenerationConfiguration.add_member(:inference_config, Shapes::ShapeRef.new(shape: InferenceConfig, location_name: "inferenceConfig"))
830
+ GenerationConfiguration.add_member(:performance_config, Shapes::ShapeRef.new(shape: PerformanceConfiguration, location_name: "performanceConfig"))
819
831
  GenerationConfiguration.add_member(:prompt_template, Shapes::ShapeRef.new(shape: PromptTemplate, location_name: "promptTemplate"))
820
832
  GenerationConfiguration.struct_class = Types::GenerationConfiguration
821
833
 
@@ -956,6 +968,9 @@ module Aws::BedrockAgentRuntime
956
968
  InlineAgentTracePart.add_member(:trace, Shapes::ShapeRef.new(shape: Trace, location_name: "trace"))
957
969
  InlineAgentTracePart.struct_class = Types::InlineAgentTracePart
958
970
 
971
+ InlineBedrockModelConfigurations.add_member(:performance_config, Shapes::ShapeRef.new(shape: PerformanceConfiguration, location_name: "performanceConfig"))
972
+ InlineBedrockModelConfigurations.struct_class = Types::InlineBedrockModelConfigurations
973
+
959
974
  InlineSessionState.add_member(:files, Shapes::ShapeRef.new(shape: InputFiles, location_name: "files"))
960
975
  InlineSessionState.add_member(:invocation_id, Shapes::ShapeRef.new(shape: String, location_name: "invocationId"))
961
976
  InlineSessionState.add_member(:prompt_session_attributes, Shapes::ShapeRef.new(shape: PromptSessionAttributesMap, location_name: "promptSessionAttributes"))
@@ -1007,6 +1022,7 @@ module Aws::BedrockAgentRuntime
1007
1022
 
1008
1023
  InvokeAgentRequest.add_member(:agent_alias_id, Shapes::ShapeRef.new(shape: AgentAliasId, required: true, location: "uri", location_name: "agentAliasId"))
1009
1024
  InvokeAgentRequest.add_member(:agent_id, Shapes::ShapeRef.new(shape: AgentId, required: true, location: "uri", location_name: "agentId"))
1025
+ InvokeAgentRequest.add_member(:bedrock_model_configurations, Shapes::ShapeRef.new(shape: BedrockModelConfigurations, location_name: "bedrockModelConfigurations"))
1010
1026
  InvokeAgentRequest.add_member(:enable_trace, Shapes::ShapeRef.new(shape: Boolean, location_name: "enableTrace"))
1011
1027
  InvokeAgentRequest.add_member(:end_session, Shapes::ShapeRef.new(shape: Boolean, location_name: "endSession"))
1012
1028
  InvokeAgentRequest.add_member(:input_text, Shapes::ShapeRef.new(shape: InputText, location_name: "inputText"))
@@ -1029,6 +1045,7 @@ module Aws::BedrockAgentRuntime
1029
1045
  InvokeFlowRequest.add_member(:flow_alias_identifier, Shapes::ShapeRef.new(shape: FlowAliasIdentifier, required: true, location: "uri", location_name: "flowAliasIdentifier"))
1030
1046
  InvokeFlowRequest.add_member(:flow_identifier, Shapes::ShapeRef.new(shape: FlowIdentifier, required: true, location: "uri", location_name: "flowIdentifier"))
1031
1047
  InvokeFlowRequest.add_member(:inputs, Shapes::ShapeRef.new(shape: FlowInputs, required: true, location_name: "inputs"))
1048
+ InvokeFlowRequest.add_member(:model_performance_configuration, Shapes::ShapeRef.new(shape: ModelPerformanceConfiguration, location_name: "modelPerformanceConfiguration"))
1032
1049
  InvokeFlowRequest.struct_class = Types::InvokeFlowRequest
1033
1050
 
1034
1051
  InvokeFlowResponse.add_member(:response_stream, Shapes::ShapeRef.new(shape: FlowResponseStream, required: true, eventstream: true, location_name: "responseStream"))
@@ -1037,6 +1054,7 @@ module Aws::BedrockAgentRuntime
1037
1054
  InvokeFlowResponse[:payload_member] = InvokeFlowResponse.member(:response_stream)
1038
1055
 
1039
1056
  InvokeInlineAgentRequest.add_member(:action_groups, Shapes::ShapeRef.new(shape: AgentActionGroups, location_name: "actionGroups"))
1057
+ InvokeInlineAgentRequest.add_member(:bedrock_model_configurations, Shapes::ShapeRef.new(shape: InlineBedrockModelConfigurations, location_name: "bedrockModelConfigurations"))
1040
1058
  InvokeInlineAgentRequest.add_member(:customer_encryption_key_arn, Shapes::ShapeRef.new(shape: KmsKeyArn, location_name: "customerEncryptionKeyArn"))
1041
1059
  InvokeInlineAgentRequest.add_member(:enable_trace, Shapes::ShapeRef.new(shape: Boolean, location_name: "enableTrace"))
1042
1060
  InvokeInlineAgentRequest.add_member(:end_session, Shapes::ShapeRef.new(shape: Boolean, location_name: "endSession"))
@@ -1049,6 +1067,7 @@ module Aws::BedrockAgentRuntime
1049
1067
  InvokeInlineAgentRequest.add_member(:knowledge_bases, Shapes::ShapeRef.new(shape: KnowledgeBases, location_name: "knowledgeBases"))
1050
1068
  InvokeInlineAgentRequest.add_member(:prompt_override_configuration, Shapes::ShapeRef.new(shape: PromptOverrideConfiguration, location_name: "promptOverrideConfiguration"))
1051
1069
  InvokeInlineAgentRequest.add_member(:session_id, Shapes::ShapeRef.new(shape: SessionId, required: true, location: "uri", location_name: "sessionId"))
1070
+ InvokeInlineAgentRequest.add_member(:streaming_configurations, Shapes::ShapeRef.new(shape: StreamingConfigurations, location_name: "streamingConfigurations"))
1052
1071
  InvokeInlineAgentRequest.struct_class = Types::InvokeInlineAgentRequest
1053
1072
 
1054
1073
  InvokeInlineAgentResponse.add_member(:completion, Shapes::ShapeRef.new(shape: InlineAgentResponseStream, required: true, eventstream: true, location_name: "completion"))
@@ -1151,6 +1170,12 @@ module Aws::BedrockAgentRuntime
1151
1170
  ModelInvocationInput.add_member(:type, Shapes::ShapeRef.new(shape: PromptType, location_name: "type"))
1152
1171
  ModelInvocationInput.struct_class = Types::ModelInvocationInput
1153
1172
 
1173
+ ModelNotReadyException.add_member(:message, Shapes::ShapeRef.new(shape: NonBlankString, location_name: "message"))
1174
+ ModelNotReadyException.struct_class = Types::ModelNotReadyException
1175
+
1176
+ ModelPerformanceConfiguration.add_member(:performance_config, Shapes::ShapeRef.new(shape: PerformanceConfiguration, location_name: "performanceConfig"))
1177
+ ModelPerformanceConfiguration.struct_class = Types::ModelPerformanceConfiguration
1178
+
1154
1179
  Observation.add_member(:action_group_invocation_output, Shapes::ShapeRef.new(shape: ActionGroupInvocationOutput, location_name: "actionGroupInvocationOutput"))
1155
1180
  Observation.add_member(:agent_collaborator_invocation_output, Shapes::ShapeRef.new(shape: AgentCollaboratorInvocationOutput, location_name: "agentCollaboratorInvocationOutput"))
1156
1181
  Observation.add_member(:code_interpreter_invocation_output, Shapes::ShapeRef.new(shape: CodeInterpreterInvocationOutput, location_name: "codeInterpreterInvocationOutput"))
@@ -1191,6 +1216,7 @@ module Aws::BedrockAgentRuntime
1191
1216
 
1192
1217
  OrchestrationConfiguration.add_member(:additional_model_request_fields, Shapes::ShapeRef.new(shape: AdditionalModelRequestFields, location_name: "additionalModelRequestFields"))
1193
1218
  OrchestrationConfiguration.add_member(:inference_config, Shapes::ShapeRef.new(shape: InferenceConfig, location_name: "inferenceConfig"))
1219
+ OrchestrationConfiguration.add_member(:performance_config, Shapes::ShapeRef.new(shape: PerformanceConfiguration, location_name: "performanceConfig"))
1194
1220
  OrchestrationConfiguration.add_member(:prompt_template, Shapes::ShapeRef.new(shape: PromptTemplate, location_name: "promptTemplate"))
1195
1221
  OrchestrationConfiguration.add_member(:query_transformation_configuration, Shapes::ShapeRef.new(shape: QueryTransformationConfiguration, location_name: "queryTransformationConfiguration"))
1196
1222
  OrchestrationConfiguration.struct_class = Types::OrchestrationConfiguration
@@ -1242,6 +1268,9 @@ module Aws::BedrockAgentRuntime
1242
1268
  PayloadPart.add_member(:bytes, Shapes::ShapeRef.new(shape: PartBody, location_name: "bytes"))
1243
1269
  PayloadPart.struct_class = Types::PayloadPart
1244
1270
 
1271
+ PerformanceConfiguration.add_member(:latency, Shapes::ShapeRef.new(shape: PerformanceConfigLatency, location_name: "latency"))
1272
+ PerformanceConfiguration.struct_class = Types::PerformanceConfiguration
1273
+
1245
1274
  PostProcessingModelInvocationOutput.add_member(:metadata, Shapes::ShapeRef.new(shape: Metadata, location_name: "metadata"))
1246
1275
  PostProcessingModelInvocationOutput.add_member(:parsed_response, Shapes::ShapeRef.new(shape: PostProcessingParsedResponse, location_name: "parsedResponse"))
1247
1276
  PostProcessingModelInvocationOutput.add_member(:raw_response, Shapes::ShapeRef.new(shape: RawResponse, location_name: "rawResponse"))
@@ -1385,6 +1414,7 @@ module Aws::BedrockAgentRuntime
1385
1414
  ResponseStream.add_member(:dependency_failed_exception, Shapes::ShapeRef.new(shape: DependencyFailedException, location_name: "dependencyFailedException"))
1386
1415
  ResponseStream.add_member(:files, Shapes::ShapeRef.new(shape: FilePart, event: true, location_name: "files"))
1387
1416
  ResponseStream.add_member(:internal_server_exception, Shapes::ShapeRef.new(shape: InternalServerException, location_name: "internalServerException"))
1417
+ ResponseStream.add_member(:model_not_ready_exception, Shapes::ShapeRef.new(shape: ModelNotReadyException, location_name: "modelNotReadyException"))
1388
1418
  ResponseStream.add_member(:resource_not_found_exception, Shapes::ShapeRef.new(shape: ResourceNotFoundException, location_name: "resourceNotFoundException"))
1389
1419
  ResponseStream.add_member(:return_control, Shapes::ShapeRef.new(shape: ReturnControlPayload, event: true, location_name: "returnControl"))
1390
1420
  ResponseStream.add_member(:service_quota_exceeded_exception, Shapes::ShapeRef.new(shape: ServiceQuotaExceededException, location_name: "serviceQuotaExceededException"))
@@ -1769,6 +1799,7 @@ module Aws::BedrockAgentRuntime
1769
1799
  o.http_request_uri = "/agents/{agentId}/agentAliases/{agentAliasId}/sessions/{sessionId}/text"
1770
1800
  o.input = Shapes::ShapeRef.new(shape: InvokeAgentRequest)
1771
1801
  o.output = Shapes::ShapeRef.new(shape: InvokeAgentResponse)
1802
+ o.errors << Shapes::ShapeRef.new(shape: ModelNotReadyException)
1772
1803
  o.errors << Shapes::ShapeRef.new(shape: ConflictException)
1773
1804
  o.errors << Shapes::ShapeRef.new(shape: ResourceNotFoundException)
1774
1805
  o.errors << Shapes::ShapeRef.new(shape: ValidationException)
@@ -32,6 +32,7 @@ module Aws::BedrockAgentRuntime
32
32
  # * {ConflictException}
33
33
  # * {DependencyFailedException}
34
34
  # * {InternalServerException}
35
+ # * {ModelNotReadyException}
35
36
  # * {ResourceNotFoundException}
36
37
  # * {ServiceQuotaExceededException}
37
38
  # * {ThrottlingException}
@@ -128,6 +129,21 @@ module Aws::BedrockAgentRuntime
128
129
  end
129
130
  end
130
131
 
132
+ class ModelNotReadyException < ServiceError
133
+
134
+ # @param [Seahorse::Client::RequestContext] context
135
+ # @param [String] message
136
+ # @param [Aws::BedrockAgentRuntime::Types::ModelNotReadyException] data
137
+ def initialize(context, message, data = Aws::EmptyStructure.new)
138
+ super(context, message, data)
139
+ end
140
+
141
+ # @return [String]
142
+ def message
143
+ @message || @data[:message]
144
+ end
145
+ end
146
+
131
147
  class ResourceNotFoundException < ServiceError
132
148
 
133
149
  # @param [Seahorse::Client::RequestContext] context
@@ -43,6 +43,10 @@ module Aws::BedrockAgentRuntime
43
43
  @event_emitter.on(:internal_server_exception, block) if block_given?
44
44
  end
45
45
 
46
+ def on_model_not_ready_exception_event(&block)
47
+ @event_emitter.on(:model_not_ready_exception, block) if block_given?
48
+ end
49
+
46
50
  def on_resource_not_found_exception_event(&block)
47
51
  @event_emitter.on(:resource_not_found_exception, block) if block_given?
48
52
  end
@@ -87,6 +91,7 @@ module Aws::BedrockAgentRuntime
87
91
  on_dependency_failed_exception_event(&block)
88
92
  on_files_event(&block)
89
93
  on_internal_server_exception_event(&block)
94
+ on_model_not_ready_exception_event(&block)
90
95
  on_resource_not_found_exception_event(&block)
91
96
  on_return_control_event(&block)
92
97
  on_service_quota_exceeded_exception_event(&block)
@@ -224,7 +224,7 @@ module Aws::BedrockAgentRuntime
224
224
  #
225
225
  #
226
226
  #
227
- # [1]: https://docs.aws.amazon.com/https:/docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_Observation.html
227
+ # [1]: https://docs.aws.amazon.com/bedrock/latest/APIReference/API_agent-runtime_Observation.html
228
228
  # @return [String]
229
229
  #
230
230
  # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-runtime-2023-07-26/AgentActionGroup AWS API Documentation
@@ -581,6 +581,20 @@ module Aws::BedrockAgentRuntime
581
581
  include Aws::Structure
582
582
  end
583
583
 
584
+ # Settings for a model called with InvokeAgent.
585
+ #
586
+ # @!attribute [rw] performance_config
587
+ # The performance configuration for the model.
588
+ # @return [Types::PerformanceConfiguration]
589
+ #
590
+ # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-runtime-2023-07-26/BedrockModelConfigurations AWS API Documentation
591
+ #
592
+ class BedrockModelConfigurations < Struct.new(
593
+ :performance_config)
594
+ SENSITIVE = []
595
+ include Aws::Structure
596
+ end
597
+
584
598
  # Contains configurations for an Amazon Bedrock reranker model.
585
599
  #
586
600
  # @!attribute [rw] model_configuration
@@ -906,12 +920,17 @@ module Aws::BedrockAgentRuntime
906
920
  # The unique identifier of the memory.
907
921
  # @return [String]
908
922
  #
923
+ # @!attribute [rw] session_id
924
+ # The unique session identifier of the memory.
925
+ # @return [String]
926
+ #
909
927
  # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-runtime-2023-07-26/DeleteAgentMemoryRequest AWS API Documentation
910
928
  #
911
929
  class DeleteAgentMemoryRequest < Struct.new(
912
930
  :agent_alias_id,
913
931
  :agent_id,
914
- :memory_id)
932
+ :memory_id,
933
+ :session_id)
915
934
  SENSITIVE = []
916
935
  include Aws::Structure
917
936
  end
@@ -986,6 +1005,10 @@ module Aws::BedrockAgentRuntime
986
1005
  # to generate responses while using an external source.
987
1006
  # @return [Types::InferenceConfig]
988
1007
  #
1008
+ # @!attribute [rw] performance_config
1009
+ # The latency configuration for the model.
1010
+ # @return [Types::PerformanceConfiguration]
1011
+ #
989
1012
  # @!attribute [rw] prompt_template
990
1013
  # Contain the textPromptTemplate string for the external source
991
1014
  # wrapper object.
@@ -997,6 +1020,7 @@ module Aws::BedrockAgentRuntime
997
1020
  :additional_model_request_fields,
998
1021
  :guardrail_configuration,
999
1022
  :inference_config,
1023
+ :performance_config,
1000
1024
  :prompt_template)
1001
1025
  SENSITIVE = []
1002
1026
  include Aws::Structure
@@ -1844,6 +1868,10 @@ module Aws::BedrockAgentRuntime
1844
1868
  # to generate responses while using a knowledge base as a source.
1845
1869
  # @return [Types::InferenceConfig]
1846
1870
  #
1871
+ # @!attribute [rw] performance_config
1872
+ # The latency configuration for the model.
1873
+ # @return [Types::PerformanceConfiguration]
1874
+ #
1847
1875
  # @!attribute [rw] prompt_template
1848
1876
  # Contains the template for the prompt that's sent to the model for
1849
1877
  # response generation. Generation prompts must include the
@@ -1861,6 +1889,7 @@ module Aws::BedrockAgentRuntime
1861
1889
  :additional_model_request_fields,
1862
1890
  :guardrail_configuration,
1863
1891
  :inference_config,
1892
+ :performance_config,
1864
1893
  :prompt_template)
1865
1894
  SENSITIVE = []
1866
1895
  include Aws::Structure
@@ -2449,6 +2478,20 @@ module Aws::BedrockAgentRuntime
2449
2478
  include Aws::Structure
2450
2479
  end
2451
2480
 
2481
+ # Settings for a model called with InvokeInlineAgent.
2482
+ #
2483
+ # @!attribute [rw] performance_config
2484
+ # The latency configuration for the model.
2485
+ # @return [Types::PerformanceConfiguration]
2486
+ #
2487
+ # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-runtime-2023-07-26/InlineBedrockModelConfigurations AWS API Documentation
2488
+ #
2489
+ class InlineBedrockModelConfigurations < Struct.new(
2490
+ :performance_config)
2491
+ SENSITIVE = []
2492
+ include Aws::Structure
2493
+ end
2494
+
2452
2495
  # Contains parameters that specify various attributes that persist
2453
2496
  # across a session or prompt. You can define session state attributes as
2454
2497
  # key-value pairs when writing a [Lambda function][1] for an action
@@ -2707,6 +2750,10 @@ module Aws::BedrockAgentRuntime
2707
2750
  # The unique identifier of the agent to use.
2708
2751
  # @return [String]
2709
2752
  #
2753
+ # @!attribute [rw] bedrock_model_configurations
2754
+ # Model performance settings for the request.
2755
+ # @return [Types::BedrockModelConfigurations]
2756
+ #
2710
2757
  # @!attribute [rw] enable_trace
2711
2758
  # Specifies whether to turn on the trace or not to track the agent's
2712
2759
  # reasoning process. For more information, see [Trace enablement][1].
@@ -2758,6 +2805,11 @@ module Aws::BedrockAgentRuntime
2758
2805
  #
2759
2806
  # @!attribute [rw] streaming_configurations
2760
2807
  # Specifies the configurations for streaming.
2808
+ #
2809
+ # <note markdown="1"> To use agent streaming, you need permissions to perform the
2810
+ # `bedrock:InvokeModelWithResponseStream` action.
2811
+ #
2812
+ # </note>
2761
2813
  # @return [Types::StreamingConfigurations]
2762
2814
  #
2763
2815
  # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-runtime-2023-07-26/InvokeAgentRequest AWS API Documentation
@@ -2765,6 +2817,7 @@ module Aws::BedrockAgentRuntime
2765
2817
  class InvokeAgentRequest < Struct.new(
2766
2818
  :agent_alias_id,
2767
2819
  :agent_id,
2820
+ :bedrock_model_configurations,
2768
2821
  :enable_trace,
2769
2822
  :end_session,
2770
2823
  :input_text,
@@ -2829,13 +2882,18 @@ module Aws::BedrockAgentRuntime
2829
2882
  # the flow.
2830
2883
  # @return [Array<Types::FlowInput>]
2831
2884
  #
2885
+ # @!attribute [rw] model_performance_configuration
2886
+ # Model performance settings for the request.
2887
+ # @return [Types::ModelPerformanceConfiguration]
2888
+ #
2832
2889
  # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-runtime-2023-07-26/InvokeFlowRequest AWS API Documentation
2833
2890
  #
2834
2891
  class InvokeFlowRequest < Struct.new(
2835
2892
  :enable_trace,
2836
2893
  :flow_alias_identifier,
2837
2894
  :flow_identifier,
2838
- :inputs)
2895
+ :inputs,
2896
+ :model_performance_configuration)
2839
2897
  SENSITIVE = []
2840
2898
  include Aws::Structure
2841
2899
  end
@@ -2858,6 +2916,10 @@ module Aws::BedrockAgentRuntime
2858
2916
  # the inline agent needs to carry out.
2859
2917
  # @return [Array<Types::AgentActionGroup>]
2860
2918
  #
2919
+ # @!attribute [rw] bedrock_model_configurations
2920
+ # Model settings for the request.
2921
+ # @return [Types::InlineBedrockModelConfigurations]
2922
+ #
2861
2923
  # @!attribute [rw] customer_encryption_key_arn
2862
2924
  # The Amazon Resource Name (ARN) of the Amazon Web Services KMS key to
2863
2925
  # use to encrypt your inline agent.
@@ -2949,10 +3011,20 @@ module Aws::BedrockAgentRuntime
2949
3011
  # requests to continue the same conversation.
2950
3012
  # @return [String]
2951
3013
  #
3014
+ # @!attribute [rw] streaming_configurations
3015
+ # Specifies the configurations for streaming.
3016
+ #
3017
+ # <note markdown="1"> To use agent streaming, you need permissions to perform the
3018
+ # `bedrock:InvokeModelWithResponseStream` action.
3019
+ #
3020
+ # </note>
3021
+ # @return [Types::StreamingConfigurations]
3022
+ #
2952
3023
  # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-runtime-2023-07-26/InvokeInlineAgentRequest AWS API Documentation
2953
3024
  #
2954
3025
  class InvokeInlineAgentRequest < Struct.new(
2955
3026
  :action_groups,
3027
+ :bedrock_model_configurations,
2956
3028
  :customer_encryption_key_arn,
2957
3029
  :enable_trace,
2958
3030
  :end_session,
@@ -2964,7 +3036,8 @@ module Aws::BedrockAgentRuntime
2964
3036
  :instruction,
2965
3037
  :knowledge_bases,
2966
3038
  :prompt_override_configuration,
2967
- :session_id)
3039
+ :session_id,
3040
+ :streaming_configurations)
2968
3041
  SENSITIVE = [:input_text, :instruction, :prompt_override_configuration]
2969
3042
  include Aws::Structure
2970
3043
  end
@@ -3529,6 +3602,41 @@ module Aws::BedrockAgentRuntime
3529
3602
  include Aws::Structure
3530
3603
  end
3531
3604
 
3605
+ # The model specified in the request is not ready to serve inference
3606
+ # requests. The AWS SDK will automatically retry the operation up to 5
3607
+ # times. For information about configuring automatic retries, see [Retry
3608
+ # behavior][1] in the *AWS SDKs and Tools* reference guide.
3609
+ #
3610
+ #
3611
+ #
3612
+ # [1]: https://docs.aws.amazon.com/sdkref/latest/guide/feature-retry-behavior.html
3613
+ #
3614
+ # @!attribute [rw] message
3615
+ # @return [String]
3616
+ #
3617
+ # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-runtime-2023-07-26/ModelNotReadyException AWS API Documentation
3618
+ #
3619
+ class ModelNotReadyException < Struct.new(
3620
+ :message,
3621
+ :event_type)
3622
+ SENSITIVE = []
3623
+ include Aws::Structure
3624
+ end
3625
+
3626
+ # The performance configuration for a model called with InvokeFlow.
3627
+ #
3628
+ # @!attribute [rw] performance_config
3629
+ # The latency configuration for the model.
3630
+ # @return [Types::PerformanceConfiguration]
3631
+ #
3632
+ # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-runtime-2023-07-26/ModelPerformanceConfiguration AWS API Documentation
3633
+ #
3634
+ class ModelPerformanceConfiguration < Struct.new(
3635
+ :performance_config)
3636
+ SENSITIVE = []
3637
+ include Aws::Structure
3638
+ end
3639
+
3532
3640
  # Contains the result or output of an action group or knowledge base, or
3533
3641
  # the response to the user.
3534
3642
  #
@@ -3678,6 +3786,10 @@ module Aws::BedrockAgentRuntime
3678
3786
  # to generate responses while using a knowledge base as a source.
3679
3787
  # @return [Types::InferenceConfig]
3680
3788
  #
3789
+ # @!attribute [rw] performance_config
3790
+ # The latency configuration for the model.
3791
+ # @return [Types::PerformanceConfiguration]
3792
+ #
3681
3793
  # @!attribute [rw] prompt_template
3682
3794
  # Contains the template for the prompt that's sent to the model.
3683
3795
  # Orchestration prompts must include the `$conversation_history$` and
@@ -3699,6 +3811,7 @@ module Aws::BedrockAgentRuntime
3699
3811
  class OrchestrationConfiguration < Struct.new(
3700
3812
  :additional_model_request_fields,
3701
3813
  :inference_config,
3814
+ :performance_config,
3702
3815
  :prompt_template,
3703
3816
  :query_transformation_configuration)
3704
3817
  SENSITIVE = []
@@ -3890,6 +4003,20 @@ module Aws::BedrockAgentRuntime
3890
4003
  include Aws::Structure
3891
4004
  end
3892
4005
 
4006
+ # Performance settings for a model.
4007
+ #
4008
+ # @!attribute [rw] latency
4009
+ # To use a latency-optimized version of the model, set to `optimized`.
4010
+ # @return [String]
4011
+ #
4012
+ # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-runtime-2023-07-26/PerformanceConfiguration AWS API Documentation
4013
+ #
4014
+ class PerformanceConfiguration < Struct.new(
4015
+ :latency)
4016
+ SENSITIVE = []
4017
+ include Aws::Structure
4018
+ end
4019
+
3893
4020
  # The foundation model output from the post-processing step.
3894
4021
  #
3895
4022
  # @!attribute [rw] metadata
@@ -6214,6 +6341,7 @@ module Aws::BedrockAgentRuntime
6214
6341
  :dependency_failed_exception,
6215
6342
  :files,
6216
6343
  :internal_server_exception,
6344
+ :model_not_ready_exception,
6217
6345
  :resource_not_found_exception,
6218
6346
  :return_control,
6219
6347
  :service_quota_exceeded_exception,
@@ -55,7 +55,7 @@ module Aws::BedrockAgentRuntime
55
55
  autoload :Endpoints, 'aws-sdk-bedrockagentruntime/endpoints'
56
56
  autoload :EventStreams, 'aws-sdk-bedrockagentruntime/event_streams'
57
57
 
58
- GEM_VERSION = '1.37.0'
58
+ GEM_VERSION = '1.39.0'
59
59
 
60
60
  end
61
61
 
data/sig/client.rbs CHANGED
@@ -42,7 +42,9 @@ module Aws
42
42
  ?max_attempts: Integer,
43
43
  ?output_event_stream_handler: Proc,
44
44
  ?profile: String,
45
+ ?request_checksum_calculation: String,
45
46
  ?request_min_compression_size_bytes: Integer,
47
+ ?response_checksum_validation: String,
46
48
  ?retry_backoff: Proc,
47
49
  ?retry_base_delay: Float,
48
50
  ?retry_jitter: (:none | :equal | :full | ^(Integer) -> Integer),
@@ -85,7 +87,8 @@ module Aws
85
87
  def delete_agent_memory: (
86
88
  agent_alias_id: ::String,
87
89
  agent_id: ::String,
88
- ?memory_id: ::String
90
+ ?memory_id: ::String,
91
+ ?session_id: ::String
89
92
  ) -> _DeleteAgentMemoryResponseSuccess
90
93
  | (Hash[Symbol, untyped] params, ?Hash[Symbol, untyped] options) -> _DeleteAgentMemoryResponseSuccess
91
94
 
@@ -138,6 +141,11 @@ module Aws
138
141
  def invoke_agent: (
139
142
  agent_alias_id: ::String,
140
143
  agent_id: ::String,
144
+ ?bedrock_model_configurations: {
145
+ performance_config: {
146
+ latency: ("standard" | "optimized")?
147
+ }?
148
+ },
141
149
  ?enable_trace: bool,
142
150
  ?end_session: bool,
143
151
  ?input_text: ::String,
@@ -338,7 +346,12 @@ module Aws
338
346
  node_name: ::String,
339
347
  node_output_name: ::String
340
348
  },
341
- ]
349
+ ],
350
+ ?model_performance_configuration: {
351
+ performance_config: {
352
+ latency: ("standard" | "optimized")?
353
+ }?
354
+ }
342
355
  ) ?{ (*untyped) -> void } -> _InvokeFlowResponseSuccess
343
356
  | (Hash[Symbol, untyped] params, ?Hash[Symbol, untyped] options) ?{ (*untyped) -> void } -> _InvokeFlowResponseSuccess
344
357
 
@@ -382,6 +395,11 @@ module Aws
382
395
  parent_action_group_signature: ("AMAZON.UserInput" | "AMAZON.CodeInterpreter")?
383
396
  },
384
397
  ],
398
+ ?bedrock_model_configurations: {
399
+ performance_config: {
400
+ latency: ("standard" | "optimized")?
401
+ }?
402
+ },
385
403
  ?customer_encryption_key_arn: ::String,
386
404
  ?enable_trace: bool,
387
405
  ?end_session: bool,
@@ -570,7 +588,11 @@ module Aws
570
588
  },
571
589
  ]
572
590
  },
573
- session_id: ::String
591
+ session_id: ::String,
592
+ ?streaming_configurations: {
593
+ apply_guardrail_interval: ::Integer?,
594
+ stream_final_response: bool?
595
+ }
574
596
  ) ?{ (*untyped) -> void } -> _InvokeInlineAgentResponseSuccess
575
597
  | (Hash[Symbol, untyped] params, ?Hash[Symbol, untyped] options) ?{ (*untyped) -> void } -> _InvokeInlineAgentResponseSuccess
576
598
 
@@ -786,6 +808,9 @@ module Aws
786
808
  top_p: ::Float?
787
809
  }?
788
810
  }?,
811
+ performance_config: {
812
+ latency: ("standard" | "optimized")?
813
+ }?,
789
814
  prompt_template: {
790
815
  text_prompt_template: ::String?
791
816
  }?
@@ -821,6 +846,9 @@ module Aws
821
846
  top_p: ::Float?
822
847
  }?
823
848
  }?,
849
+ performance_config: {
850
+ latency: ("standard" | "optimized")?
851
+ }?,
824
852
  prompt_template: {
825
853
  text_prompt_template: ::String?
826
854
  }?
@@ -838,6 +866,9 @@ module Aws
838
866
  top_p: ::Float?
839
867
  }?
840
868
  }?,
869
+ performance_config: {
870
+ latency: ("standard" | "optimized")?
871
+ }?,
841
872
  prompt_template: {
842
873
  text_prompt_template: ::String?
843
874
  }?,
@@ -987,6 +1018,9 @@ module Aws
987
1018
  top_p: ::Float?
988
1019
  }?
989
1020
  }?,
1021
+ performance_config: {
1022
+ latency: ("standard" | "optimized")?
1023
+ }?,
990
1024
  prompt_template: {
991
1025
  text_prompt_template: ::String?
992
1026
  }?
@@ -1022,6 +1056,9 @@ module Aws
1022
1056
  top_p: ::Float?
1023
1057
  }?
1024
1058
  }?,
1059
+ performance_config: {
1060
+ latency: ("standard" | "optimized")?
1061
+ }?,
1025
1062
  prompt_template: {
1026
1063
  text_prompt_template: ::String?
1027
1064
  }?
@@ -1039,6 +1076,9 @@ module Aws
1039
1076
  top_p: ::Float?
1040
1077
  }?
1041
1078
  }?,
1079
+ performance_config: {
1080
+ latency: ("standard" | "optimized")?
1081
+ }?,
1042
1082
  prompt_template: {
1043
1083
  text_prompt_template: ::String?
1044
1084
  }?,
data/sig/errors.rbs CHANGED
@@ -28,6 +28,9 @@ module Aws
28
28
  class InternalServerException < ::Aws::Errors::ServiceError
29
29
  def message: () -> ::String
30
30
  end
31
+ class ModelNotReadyException < ::Aws::Errors::ServiceError
32
+ def message: () -> ::String
33
+ end
31
34
  class ResourceNotFoundException < ::Aws::Errors::ServiceError
32
35
  def message: () -> ::String
33
36
  end
data/sig/resource.rbs CHANGED
@@ -42,7 +42,9 @@ module Aws
42
42
  ?max_attempts: Integer,
43
43
  ?output_event_stream_handler: Proc,
44
44
  ?profile: String,
45
+ ?request_checksum_calculation: String,
45
46
  ?request_min_compression_size_bytes: Integer,
47
+ ?response_checksum_validation: String,
46
48
  ?retry_backoff: Proc,
47
49
  ?retry_base_delay: Float,
48
50
  ?retry_jitter: (:none | :equal | :full | ^(Integer) -> Integer),
data/sig/types.rbs CHANGED
@@ -151,6 +151,11 @@ module Aws::BedrockAgentRuntime
151
151
  SENSITIVE: []
152
152
  end
153
153
 
154
+ class BedrockModelConfigurations
155
+ attr_accessor performance_config: Types::PerformanceConfiguration
156
+ SENSITIVE: []
157
+ end
158
+
154
159
  class BedrockRerankingConfiguration
155
160
  attr_accessor model_configuration: Types::BedrockRerankingModelConfiguration
156
161
  attr_accessor number_of_results: ::Integer
@@ -255,6 +260,7 @@ module Aws::BedrockAgentRuntime
255
260
  attr_accessor agent_alias_id: ::String
256
261
  attr_accessor agent_id: ::String
257
262
  attr_accessor memory_id: ::String
263
+ attr_accessor session_id: ::String
258
264
  SENSITIVE: []
259
265
  end
260
266
 
@@ -279,6 +285,7 @@ module Aws::BedrockAgentRuntime
279
285
  attr_accessor additional_model_request_fields: ::Hash[::String, untyped]
280
286
  attr_accessor guardrail_configuration: Types::GuardrailConfiguration
281
287
  attr_accessor inference_config: Types::InferenceConfig
288
+ attr_accessor performance_config: Types::PerformanceConfiguration
282
289
  attr_accessor prompt_template: Types::PromptTemplate
283
290
  SENSITIVE: []
284
291
  end
@@ -523,6 +530,7 @@ module Aws::BedrockAgentRuntime
523
530
  attr_accessor additional_model_request_fields: ::Hash[::String, untyped]
524
531
  attr_accessor guardrail_configuration: Types::GuardrailConfiguration
525
532
  attr_accessor inference_config: Types::InferenceConfig
533
+ attr_accessor performance_config: Types::PerformanceConfiguration
526
534
  attr_accessor prompt_template: Types::PromptTemplate
527
535
  SENSITIVE: []
528
536
  end
@@ -688,6 +696,11 @@ module Aws::BedrockAgentRuntime
688
696
  SENSITIVE: [:trace]
689
697
  end
690
698
 
699
+ class InlineBedrockModelConfigurations
700
+ attr_accessor performance_config: Types::PerformanceConfiguration
701
+ SENSITIVE: []
702
+ end
703
+
691
704
  class InlineSessionState
692
705
  attr_accessor files: ::Array[Types::InputFile]
693
706
  attr_accessor invocation_id: ::String
@@ -762,6 +775,7 @@ module Aws::BedrockAgentRuntime
762
775
  class InvokeAgentRequest
763
776
  attr_accessor agent_alias_id: ::String
764
777
  attr_accessor agent_id: ::String
778
+ attr_accessor bedrock_model_configurations: Types::BedrockModelConfigurations
765
779
  attr_accessor enable_trace: bool
766
780
  attr_accessor end_session: bool
767
781
  attr_accessor input_text: ::String
@@ -786,6 +800,7 @@ module Aws::BedrockAgentRuntime
786
800
  attr_accessor flow_alias_identifier: ::String
787
801
  attr_accessor flow_identifier: ::String
788
802
  attr_accessor inputs: ::Array[Types::FlowInput]
803
+ attr_accessor model_performance_configuration: Types::ModelPerformanceConfiguration
789
804
  SENSITIVE: []
790
805
  end
791
806
 
@@ -796,6 +811,7 @@ module Aws::BedrockAgentRuntime
796
811
 
797
812
  class InvokeInlineAgentRequest
798
813
  attr_accessor action_groups: ::Array[Types::AgentActionGroup]
814
+ attr_accessor bedrock_model_configurations: Types::InlineBedrockModelConfigurations
799
815
  attr_accessor customer_encryption_key_arn: ::String
800
816
  attr_accessor enable_trace: bool
801
817
  attr_accessor end_session: bool
@@ -808,6 +824,7 @@ module Aws::BedrockAgentRuntime
808
824
  attr_accessor knowledge_bases: ::Array[Types::KnowledgeBase]
809
825
  attr_accessor prompt_override_configuration: Types::PromptOverrideConfiguration
810
826
  attr_accessor session_id: ::String
827
+ attr_accessor streaming_configurations: Types::StreamingConfigurations
811
828
  SENSITIVE: [:input_text, :instruction, :prompt_override_configuration]
812
829
  end
813
830
 
@@ -934,6 +951,17 @@ module Aws::BedrockAgentRuntime
934
951
  SENSITIVE: [:text]
935
952
  end
936
953
 
954
+ class ModelNotReadyException
955
+ attr_accessor message: ::String
956
+ attr_accessor event_type: untyped
957
+ SENSITIVE: []
958
+ end
959
+
960
+ class ModelPerformanceConfiguration
961
+ attr_accessor performance_config: Types::PerformanceConfiguration
962
+ SENSITIVE: []
963
+ end
964
+
937
965
  class Observation
938
966
  attr_accessor action_group_invocation_output: Types::ActionGroupInvocationOutput
939
967
  attr_accessor agent_collaborator_invocation_output: Types::AgentCollaboratorInvocationOutput
@@ -977,6 +1005,7 @@ module Aws::BedrockAgentRuntime
977
1005
  class OrchestrationConfiguration
978
1006
  attr_accessor additional_model_request_fields: ::Hash[::String, untyped]
979
1007
  attr_accessor inference_config: Types::InferenceConfig
1008
+ attr_accessor performance_config: Types::PerformanceConfiguration
980
1009
  attr_accessor prompt_template: Types::PromptTemplate
981
1010
  attr_accessor query_transformation_configuration: Types::QueryTransformationConfiguration
982
1011
  SENSITIVE: []
@@ -1040,6 +1069,11 @@ module Aws::BedrockAgentRuntime
1040
1069
  SENSITIVE: [:bytes]
1041
1070
  end
1042
1071
 
1072
+ class PerformanceConfiguration
1073
+ attr_accessor latency: ("standard" | "optimized")
1074
+ SENSITIVE: []
1075
+ end
1076
+
1043
1077
  class PostProcessingModelInvocationOutput
1044
1078
  attr_accessor metadata: Types::Metadata
1045
1079
  attr_accessor parsed_response: Types::PostProcessingParsedResponse
@@ -1633,7 +1667,7 @@ module Aws::BedrockAgentRuntime
1633
1667
  end
1634
1668
 
1635
1669
  class ResponseStream < Enumerator[untyped, untyped]
1636
- def event_types: () -> [:access_denied_exception, :bad_gateway_exception, :chunk, :conflict_exception, :dependency_failed_exception, :files, :internal_server_exception, :resource_not_found_exception, :return_control, :service_quota_exceeded_exception, :throttling_exception, :trace, :validation_exception]
1670
+ def event_types: () -> [:access_denied_exception, :bad_gateway_exception, :chunk, :conflict_exception, :dependency_failed_exception, :files, :internal_server_exception, :model_not_ready_exception, :resource_not_found_exception, :return_control, :service_quota_exceeded_exception, :throttling_exception, :trace, :validation_exception]
1637
1671
  end
1638
1672
 
1639
1673
  class RetrieveAndGenerateStreamResponseOutput < Enumerator[untyped, untyped]
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: aws-sdk-bedrockagentruntime
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.37.0
4
+ version: 1.39.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Amazon Web Services
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-12-04 00:00:00.000000000 Z
11
+ date: 2025-01-15 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: aws-sdk-core
@@ -19,7 +19,7 @@ dependencies:
19
19
  version: '3'
20
20
  - - ">="
21
21
  - !ruby/object:Gem::Version
22
- version: 3.210.0
22
+ version: 3.216.0
23
23
  type: :runtime
24
24
  prerelease: false
25
25
  version_requirements: !ruby/object:Gem::Requirement
@@ -29,7 +29,7 @@ dependencies:
29
29
  version: '3'
30
30
  - - ">="
31
31
  - !ruby/object:Gem::Version
32
- version: 3.210.0
32
+ version: 3.216.0
33
33
  - !ruby/object:Gem::Dependency
34
34
  name: aws-sigv4
35
35
  requirement: !ruby/object:Gem::Requirement