aws-sdk-bedrockagentruntime 1.39.0 → 1.41.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: a0937c50cd571aabc4903c40c30472eda5ab8b4bf2ad1915c7f2704f26d07955
4
- data.tar.gz: cdf2181f560b55b48eb9a58316e557b14140a64194babaa9ce86a20cd14f9cd7
3
+ metadata.gz: 8fa1e662a49c9a1f9c3cb769cb7e767b8372ffa0307cfc29f876e16459e1ad8a
4
+ data.tar.gz: e366d900741f248f0b6723721e8c6fc22bed8fbb91359eaa1dbaf53b2c4d085b
5
5
  SHA512:
6
- metadata.gz: a6b7a30992848738210df2f7eb908f211a871f8bfc2be240949d5aad710c92caece3943aa12b19dd4e099ee4f2ed60eb32d0d565f28d962b9bbfa9fe2a1c2c98
7
- data.tar.gz: 3ed9c82f6329c19c154d6a4f0f7c9676ca7020bd753aafdaf320edbea466890fe672ab3168edcc752647c6d9665719aaeeada3eb9a8267c0c5154e5a71e51eff
6
+ metadata.gz: 87d3ecf4841e471f13bff33dccd9dadc9b5c6bea10b2044bd3a12959ae78912db7cb20e8f3f681e1fd756becf44bdd46dfdb4b72ad4798ee39d44a0c10d8925b
7
+ data.tar.gz: 204b0dc932d78525210498b6a5dfcd70cd0771ebe40ee341c1e8a013a1df9fd0c626a148d1ba820ba9171f649580af6ccda7c6d84841a8b995291b557d625465
data/CHANGELOG.md CHANGED
@@ -1,6 +1,16 @@
1
1
  Unreleased Changes
2
2
  ------------------
3
3
 
4
+ 1.41.0 (2025-01-30)
5
+ ------------------
6
+
7
+ * Feature - Add a 'reason' field to InternalServerException
8
+
9
+ 1.40.0 (2025-01-22)
10
+ ------------------
11
+
12
+ * Feature - Adds multi-turn input support for an Agent node in an Amazon Bedrock Flow
13
+
4
14
  1.39.0 (2025-01-15)
5
15
  ------------------
6
16
 
data/VERSION CHANGED
@@ -1 +1 @@
1
- 1.39.0
1
+ 1.41.0
@@ -1206,6 +1206,7 @@ module Aws::BedrockAgentRuntime
1206
1206
  #
1207
1207
  # For :internal_server_exception event available at #on_internal_server_exception_event callback and response eventstream enumerator:
1208
1208
  # event.message #=> String
1209
+ # event.reason #=> String
1209
1210
  #
1210
1211
  # For :model_not_ready_exception event available at #on_model_not_ready_exception_event callback and response eventstream enumerator:
1211
1212
  # event.message #=> String
@@ -1650,6 +1651,10 @@ module Aws::BedrockAgentRuntime
1650
1651
  #
1651
1652
  # [1]: https://docs.aws.amazon.com/bedrock/latest/userguide/flows-trace.html
1652
1653
  #
1654
+ # @option params [String] :execution_id
1655
+ # The unique identifier for the current flow execution. If you don't
1656
+ # provide a value, Amazon Bedrock creates the identifier for you.
1657
+ #
1653
1658
  # @option params [required, String] :flow_alias_identifier
1654
1659
  # The unique identifier of the flow alias.
1655
1660
  #
@@ -1665,6 +1670,7 @@ module Aws::BedrockAgentRuntime
1665
1670
  #
1666
1671
  # @return [Types::InvokeFlowResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
1667
1672
  #
1673
+ # * {Types::InvokeFlowResponse#execution_id #execution_id} => String
1668
1674
  # * {Types::InvokeFlowResponse#response_stream #response_stream} => Types::FlowResponseStream
1669
1675
  #
1670
1676
  # @example EventStream Operation Example
@@ -1725,6 +1731,9 @@ module Aws::BedrockAgentRuntime
1725
1731
  # handler.on_flow_completion_event_event do |event|
1726
1732
  # event # => Aws::BedrockAgentRuntime::Types::flowCompletionEvent
1727
1733
  # end
1734
+ # handler.on_flow_multi_turn_input_request_event_event do |event|
1735
+ # event # => Aws::BedrockAgentRuntime::Types::flowMultiTurnInputRequestEvent
1736
+ # end
1728
1737
  # handler.on_flow_output_event_event do |event|
1729
1738
  # event # => Aws::BedrockAgentRuntime::Types::flowOutputEvent
1730
1739
  # end
@@ -1768,6 +1777,9 @@ module Aws::BedrockAgentRuntime
1768
1777
  # stream.on_flow_completion_event_event do |event|
1769
1778
  # event # => Aws::BedrockAgentRuntime::Types::flowCompletionEvent
1770
1779
  # end
1780
+ # stream.on_flow_multi_turn_input_request_event_event do |event|
1781
+ # event # => Aws::BedrockAgentRuntime::Types::flowMultiTurnInputRequestEvent
1782
+ # end
1771
1783
  # stream.on_flow_output_event_event do |event|
1772
1784
  # event # => Aws::BedrockAgentRuntime::Types::flowOutputEvent
1773
1785
  # end
@@ -1811,6 +1823,9 @@ module Aws::BedrockAgentRuntime
1811
1823
  # handler.on_flow_completion_event_event do |event|
1812
1824
  # event # => Aws::BedrockAgentRuntime::Types::flowCompletionEvent
1813
1825
  # end
1826
+ # handler.on_flow_multi_turn_input_request_event_event do |event|
1827
+ # event # => Aws::BedrockAgentRuntime::Types::flowMultiTurnInputRequestEvent
1828
+ # end
1814
1829
  # handler.on_flow_output_event_event do |event|
1815
1830
  # event # => Aws::BedrockAgentRuntime::Types::flowOutputEvent
1816
1831
  # end
@@ -1853,6 +1868,7 @@ module Aws::BedrockAgentRuntime
1853
1868
  #
1854
1869
  # resp = client.invoke_flow({
1855
1870
  # enable_trace: false,
1871
+ # execution_id: "FlowExecutionId",
1856
1872
  # flow_alias_identifier: "FlowAliasIdentifier", # required
1857
1873
  # flow_identifier: "FlowIdentifier", # required
1858
1874
  # inputs: [ # required
@@ -1861,8 +1877,9 @@ module Aws::BedrockAgentRuntime
1861
1877
  # document: {
1862
1878
  # },
1863
1879
  # },
1880
+ # node_input_name: "NodeInputName",
1864
1881
  # node_name: "NodeName", # required
1865
- # node_output_name: "NodeOutputName", # required
1882
+ # node_output_name: "NodeOutputName",
1866
1883
  # },
1867
1884
  # ],
1868
1885
  # model_performance_configuration: {
@@ -1874,9 +1891,10 @@ module Aws::BedrockAgentRuntime
1874
1891
  #
1875
1892
  # @example Response structure
1876
1893
  #
1894
+ # resp.execution_id #=> String
1877
1895
  # All events are available at resp.response_stream:
1878
1896
  # resp.response_stream #=> Enumerator
1879
- # resp.response_stream.event_types #=> [:access_denied_exception, :bad_gateway_exception, :conflict_exception, :dependency_failed_exception, :flow_completion_event, :flow_output_event, :flow_trace_event, :internal_server_exception, :resource_not_found_exception, :service_quota_exceeded_exception, :throttling_exception, :validation_exception]
1897
+ # resp.response_stream.event_types #=> [:access_denied_exception, :bad_gateway_exception, :conflict_exception, :dependency_failed_exception, :flow_completion_event, :flow_multi_turn_input_request_event, :flow_output_event, :flow_trace_event, :internal_server_exception, :resource_not_found_exception, :service_quota_exceeded_exception, :throttling_exception, :validation_exception]
1880
1898
  #
1881
1899
  # For :access_denied_exception event available at #on_access_denied_exception_event callback and response eventstream enumerator:
1882
1900
  # event.message #=> String
@@ -1893,7 +1911,11 @@ module Aws::BedrockAgentRuntime
1893
1911
  # event.resource_name #=> String
1894
1912
  #
1895
1913
  # For :flow_completion_event event available at #on_flow_completion_event_event callback and response eventstream enumerator:
1896
- # event.completion_reason #=> String, one of "SUCCESS"
1914
+ # event.completion_reason #=> String, one of "SUCCESS", "INPUT_REQUIRED"
1915
+ #
1916
+ # For :flow_multi_turn_input_request_event event available at #on_flow_multi_turn_input_request_event_event callback and response eventstream enumerator:
1917
+ # event.node_name #=> String
1918
+ # event.node_type #=> String, one of "FlowInputNode", "FlowOutputNode", "LambdaFunctionNode", "KnowledgeBaseNode", "PromptNode", "ConditionNode", "LexNode"
1897
1919
  #
1898
1920
  # For :flow_output_event event available at #on_flow_output_event_event callback and response eventstream enumerator:
1899
1921
  # event.node_name #=> String
@@ -1915,6 +1937,7 @@ module Aws::BedrockAgentRuntime
1915
1937
  #
1916
1938
  # For :internal_server_exception event available at #on_internal_server_exception_event callback and response eventstream enumerator:
1917
1939
  # event.message #=> String
1940
+ # event.reason #=> String
1918
1941
  #
1919
1942
  # For :resource_not_found_exception event available at #on_resource_not_found_exception_event callback and response eventstream enumerator:
1920
1943
  # event.message #=> String
@@ -2575,6 +2598,7 @@ module Aws::BedrockAgentRuntime
2575
2598
  #
2576
2599
  # For :internal_server_exception event available at #on_internal_server_exception_event callback and response eventstream enumerator:
2577
2600
  # event.message #=> String
2601
+ # event.reason #=> String
2578
2602
  #
2579
2603
  # For :resource_not_found_exception event available at #on_resource_not_found_exception_event callback and response eventstream enumerator:
2580
2604
  # event.message #=> String
@@ -3183,6 +3207,7 @@ module Aws::BedrockAgentRuntime
3183
3207
  #
3184
3208
  # For :internal_server_exception event available at #on_internal_server_exception_event callback and response eventstream enumerator:
3185
3209
  # event.message #=> String
3210
+ # event.reason #=> String
3186
3211
  #
3187
3212
  # For :optimized_prompt_event event available at #on_optimized_prompt_event_event callback and response eventstream enumerator:
3188
3213
  # event.optimized_prompt.text_prompt.text #=> String
@@ -3799,6 +3824,9 @@ module Aws::BedrockAgentRuntime
3799
3824
  #
3800
3825
  # </note>
3801
3826
  #
3827
+ # This operation requires permission for the `
3828
+ # bedrock:RetrieveAndGenerate` action.
3829
+ #
3802
3830
  # @option params [required, Types::RetrieveAndGenerateInput] :input
3803
3831
  # Contains the query to be made to the knowledge base.
3804
3832
  #
@@ -4274,6 +4302,7 @@ module Aws::BedrockAgentRuntime
4274
4302
  #
4275
4303
  # For :internal_server_exception event available at #on_internal_server_exception_event callback and response eventstream enumerator:
4276
4304
  # event.message #=> String
4305
+ # event.reason #=> String
4277
4306
  #
4278
4307
  # For :output event available at #on_output_event callback and response eventstream enumerator:
4279
4308
  # event.text #=> String
@@ -4335,7 +4364,7 @@ module Aws::BedrockAgentRuntime
4335
4364
  tracer: tracer
4336
4365
  )
4337
4366
  context[:gem_name] = 'aws-sdk-bedrockagentruntime'
4338
- context[:gem_version] = '1.39.0'
4367
+ context[:gem_version] = '1.41.0'
4339
4368
  Seahorse::Client::Request.new(handlers, context)
4340
4369
  end
4341
4370
 
@@ -112,10 +112,13 @@ module Aws::BedrockAgentRuntime
112
112
  FlowAliasIdentifier = Shapes::StringShape.new(name: 'FlowAliasIdentifier')
113
113
  FlowCompletionEvent = Shapes::StructureShape.new(name: 'FlowCompletionEvent')
114
114
  FlowCompletionReason = Shapes::StringShape.new(name: 'FlowCompletionReason')
115
+ FlowExecutionId = Shapes::StringShape.new(name: 'FlowExecutionId')
115
116
  FlowIdentifier = Shapes::StringShape.new(name: 'FlowIdentifier')
116
117
  FlowInput = Shapes::StructureShape.new(name: 'FlowInput')
117
118
  FlowInputContent = Shapes::UnionShape.new(name: 'FlowInputContent')
118
119
  FlowInputs = Shapes::ListShape.new(name: 'FlowInputs')
120
+ FlowMultiTurnInputContent = Shapes::UnionShape.new(name: 'FlowMultiTurnInputContent')
121
+ FlowMultiTurnInputRequestEvent = Shapes::StructureShape.new(name: 'FlowMultiTurnInputRequestEvent')
119
122
  FlowOutputContent = Shapes::UnionShape.new(name: 'FlowOutputContent')
120
123
  FlowOutputEvent = Shapes::StructureShape.new(name: 'FlowOutputEvent')
121
124
  FlowResponseStream = Shapes::StructureShape.new(name: 'FlowResponseStream')
@@ -677,8 +680,9 @@ module Aws::BedrockAgentRuntime
677
680
  FlowCompletionEvent.struct_class = Types::FlowCompletionEvent
678
681
 
679
682
  FlowInput.add_member(:content, Shapes::ShapeRef.new(shape: FlowInputContent, required: true, location_name: "content"))
683
+ FlowInput.add_member(:node_input_name, Shapes::ShapeRef.new(shape: NodeInputName, location_name: "nodeInputName"))
680
684
  FlowInput.add_member(:node_name, Shapes::ShapeRef.new(shape: NodeName, required: true, location_name: "nodeName"))
681
- FlowInput.add_member(:node_output_name, Shapes::ShapeRef.new(shape: NodeOutputName, required: true, location_name: "nodeOutputName"))
685
+ FlowInput.add_member(:node_output_name, Shapes::ShapeRef.new(shape: NodeOutputName, location_name: "nodeOutputName"))
682
686
  FlowInput.struct_class = Types::FlowInput
683
687
 
684
688
  FlowInputContent.add_member(:document, Shapes::ShapeRef.new(shape: Document, location_name: "document"))
@@ -689,6 +693,17 @@ module Aws::BedrockAgentRuntime
689
693
 
690
694
  FlowInputs.member = Shapes::ShapeRef.new(shape: FlowInput)
691
695
 
696
+ FlowMultiTurnInputContent.add_member(:document, Shapes::ShapeRef.new(shape: Document, location_name: "document"))
697
+ FlowMultiTurnInputContent.add_member(:unknown, Shapes::ShapeRef.new(shape: nil, location_name: 'unknown'))
698
+ FlowMultiTurnInputContent.add_member_subclass(:document, Types::FlowMultiTurnInputContent::Document)
699
+ FlowMultiTurnInputContent.add_member_subclass(:unknown, Types::FlowMultiTurnInputContent::Unknown)
700
+ FlowMultiTurnInputContent.struct_class = Types::FlowMultiTurnInputContent
701
+
702
+ FlowMultiTurnInputRequestEvent.add_member(:content, Shapes::ShapeRef.new(shape: FlowMultiTurnInputContent, required: true, location_name: "content"))
703
+ FlowMultiTurnInputRequestEvent.add_member(:node_name, Shapes::ShapeRef.new(shape: NodeName, required: true, location_name: "nodeName"))
704
+ FlowMultiTurnInputRequestEvent.add_member(:node_type, Shapes::ShapeRef.new(shape: NodeType, required: true, location_name: "nodeType"))
705
+ FlowMultiTurnInputRequestEvent.struct_class = Types::FlowMultiTurnInputRequestEvent
706
+
692
707
  FlowOutputContent.add_member(:document, Shapes::ShapeRef.new(shape: Document, location_name: "document"))
693
708
  FlowOutputContent.add_member(:unknown, Shapes::ShapeRef.new(shape: nil, location_name: 'unknown'))
694
709
  FlowOutputContent.add_member_subclass(:document, Types::FlowOutputContent::Document)
@@ -705,6 +720,7 @@ module Aws::BedrockAgentRuntime
705
720
  FlowResponseStream.add_member(:conflict_exception, Shapes::ShapeRef.new(shape: ConflictException, location_name: "conflictException"))
706
721
  FlowResponseStream.add_member(:dependency_failed_exception, Shapes::ShapeRef.new(shape: DependencyFailedException, location_name: "dependencyFailedException"))
707
722
  FlowResponseStream.add_member(:flow_completion_event, Shapes::ShapeRef.new(shape: FlowCompletionEvent, event: true, location_name: "flowCompletionEvent"))
723
+ FlowResponseStream.add_member(:flow_multi_turn_input_request_event, Shapes::ShapeRef.new(shape: FlowMultiTurnInputRequestEvent, event: true, location_name: "flowMultiTurnInputRequestEvent"))
708
724
  FlowResponseStream.add_member(:flow_output_event, Shapes::ShapeRef.new(shape: FlowOutputEvent, event: true, location_name: "flowOutputEvent"))
709
725
  FlowResponseStream.add_member(:flow_trace_event, Shapes::ShapeRef.new(shape: FlowTraceEvent, event: true, location_name: "flowTraceEvent"))
710
726
  FlowResponseStream.add_member(:internal_server_exception, Shapes::ShapeRef.new(shape: InternalServerException, location_name: "internalServerException"))
@@ -992,6 +1008,7 @@ module Aws::BedrockAgentRuntime
992
1008
  InputPrompt.struct_class = Types::InputPrompt
993
1009
 
994
1010
  InternalServerException.add_member(:message, Shapes::ShapeRef.new(shape: NonBlankString, location_name: "message"))
1011
+ InternalServerException.add_member(:reason, Shapes::ShapeRef.new(shape: String, location_name: "reason"))
995
1012
  InternalServerException.struct_class = Types::InternalServerException
996
1013
 
997
1014
  InvocationInput.add_member(:action_group_invocation_input, Shapes::ShapeRef.new(shape: ActionGroupInvocationInput, location_name: "actionGroupInvocationInput"))
@@ -1042,12 +1059,14 @@ module Aws::BedrockAgentRuntime
1042
1059
  InvokeAgentResponse[:payload_member] = InvokeAgentResponse.member(:completion)
1043
1060
 
1044
1061
  InvokeFlowRequest.add_member(:enable_trace, Shapes::ShapeRef.new(shape: Boolean, location_name: "enableTrace"))
1062
+ InvokeFlowRequest.add_member(:execution_id, Shapes::ShapeRef.new(shape: FlowExecutionId, location_name: "executionId"))
1045
1063
  InvokeFlowRequest.add_member(:flow_alias_identifier, Shapes::ShapeRef.new(shape: FlowAliasIdentifier, required: true, location: "uri", location_name: "flowAliasIdentifier"))
1046
1064
  InvokeFlowRequest.add_member(:flow_identifier, Shapes::ShapeRef.new(shape: FlowIdentifier, required: true, location: "uri", location_name: "flowIdentifier"))
1047
1065
  InvokeFlowRequest.add_member(:inputs, Shapes::ShapeRef.new(shape: FlowInputs, required: true, location_name: "inputs"))
1048
1066
  InvokeFlowRequest.add_member(:model_performance_configuration, Shapes::ShapeRef.new(shape: ModelPerformanceConfiguration, location_name: "modelPerformanceConfiguration"))
1049
1067
  InvokeFlowRequest.struct_class = Types::InvokeFlowRequest
1050
1068
 
1069
+ InvokeFlowResponse.add_member(:execution_id, Shapes::ShapeRef.new(shape: FlowExecutionId, location: "header", location_name: "x-amz-bedrock-flow-execution-id"))
1051
1070
  InvokeFlowResponse.add_member(:response_stream, Shapes::ShapeRef.new(shape: FlowResponseStream, required: true, eventstream: true, location_name: "responseStream"))
1052
1071
  InvokeFlowResponse.struct_class = Types::InvokeFlowResponse
1053
1072
  InvokeFlowResponse[:payload] = :response_stream
@@ -127,6 +127,11 @@ module Aws::BedrockAgentRuntime
127
127
  def message
128
128
  @message || @data[:message]
129
129
  end
130
+
131
+ # @return [String]
132
+ def reason
133
+ @data[:reason]
134
+ end
130
135
  end
131
136
 
132
137
  class ModelNotReadyException < ServiceError
@@ -134,6 +134,10 @@ module Aws::BedrockAgentRuntime
134
134
  @event_emitter.on(:flow_completion_event, block) if block_given?
135
135
  end
136
136
 
137
+ def on_flow_multi_turn_input_request_event_event(&block)
138
+ @event_emitter.on(:flow_multi_turn_input_request_event, block) if block_given?
139
+ end
140
+
137
141
  def on_flow_output_event_event(&block)
138
142
  @event_emitter.on(:flow_output_event, block) if block_given?
139
143
  end
@@ -180,6 +184,7 @@ module Aws::BedrockAgentRuntime
180
184
  on_conflict_exception_event(&block)
181
185
  on_dependency_failed_exception_event(&block)
182
186
  on_flow_completion_event_event(&block)
187
+ on_flow_multi_turn_input_request_event_event(&block)
183
188
  on_flow_output_event_event(&block)
184
189
  on_flow_trace_event_event(&block)
185
190
  on_internal_server_exception_event(&block)
@@ -1197,6 +1197,10 @@ module Aws::BedrockAgentRuntime
1197
1197
  # Contains information about an input into the prompt flow.
1198
1198
  # @return [Types::FlowInputContent]
1199
1199
  #
1200
+ # @!attribute [rw] node_input_name
1201
+ # The name of the input from the flow input node.
1202
+ # @return [String]
1203
+ #
1200
1204
  # @!attribute [rw] node_name
1201
1205
  # The name of the flow input node that begins the prompt flow.
1202
1206
  # @return [String]
@@ -1210,6 +1214,7 @@ module Aws::BedrockAgentRuntime
1210
1214
  #
1211
1215
  class FlowInput < Struct.new(
1212
1216
  :content,
1217
+ :node_input_name,
1213
1218
  :node_name,
1214
1219
  :node_output_name)
1215
1220
  SENSITIVE = [:content]
@@ -1237,6 +1242,56 @@ module Aws::BedrockAgentRuntime
1237
1242
  class Unknown < FlowInputContent; end
1238
1243
  end
1239
1244
 
1245
+ # The content structure containing input information for multi-turn flow
1246
+ # interactions.
1247
+ #
1248
+ # @note FlowMultiTurnInputContent is a union - when returned from an API call exactly one value will be set and the returned type will be a subclass of FlowMultiTurnInputContent corresponding to the set member.
1249
+ #
1250
+ # @!attribute [rw] document
1251
+ # The requested additional input to send back to the multi-turn flow
1252
+ # node.
1253
+ # @return [Hash,Array,String,Numeric,Boolean]
1254
+ #
1255
+ # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-runtime-2023-07-26/FlowMultiTurnInputContent AWS API Documentation
1256
+ #
1257
+ class FlowMultiTurnInputContent < Struct.new(
1258
+ :document,
1259
+ :unknown)
1260
+ SENSITIVE = []
1261
+ include Aws::Structure
1262
+ include Aws::Structure::Union
1263
+
1264
+ class Document < FlowMultiTurnInputContent; end
1265
+ class Unknown < FlowMultiTurnInputContent; end
1266
+ end
1267
+
1268
+ # Response object from the flow multi-turn node requesting additional
1269
+ # information.
1270
+ #
1271
+ # @!attribute [rw] content
1272
+ # The content payload containing the input request details for the
1273
+ # multi-turn interaction.
1274
+ # @return [Types::FlowMultiTurnInputContent]
1275
+ #
1276
+ # @!attribute [rw] node_name
1277
+ # The name of the node in the flow that is requesting the input.
1278
+ # @return [String]
1279
+ #
1280
+ # @!attribute [rw] node_type
1281
+ # The type of the node in the flow that is requesting the input.
1282
+ # @return [String]
1283
+ #
1284
+ # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-runtime-2023-07-26/FlowMultiTurnInputRequestEvent AWS API Documentation
1285
+ #
1286
+ class FlowMultiTurnInputRequestEvent < Struct.new(
1287
+ :content,
1288
+ :node_name,
1289
+ :node_type,
1290
+ :event_type)
1291
+ SENSITIVE = []
1292
+ include Aws::Structure
1293
+ end
1294
+
1240
1295
  # Contains information about the content in an output from prompt flow
1241
1296
  # invocation.
1242
1297
  #
@@ -2608,10 +2663,17 @@ module Aws::BedrockAgentRuntime
2608
2663
  # @!attribute [rw] message
2609
2664
  # @return [String]
2610
2665
  #
2666
+ # @!attribute [rw] reason
2667
+ # The reason for the exception. If the reason is
2668
+ # `BEDROCK_MODEL_INVOCATION_SERVICE_UNAVAILABLE`, the model invocation
2669
+ # service is unavailable. Retry your request.
2670
+ # @return [String]
2671
+ #
2611
2672
  # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-runtime-2023-07-26/InternalServerException AWS API Documentation
2612
2673
  #
2613
2674
  class InternalServerException < Struct.new(
2614
2675
  :message,
2676
+ :reason,
2615
2677
  :event_type)
2616
2678
  SENSITIVE = []
2617
2679
  include Aws::Structure
@@ -2869,6 +2931,11 @@ module Aws::BedrockAgentRuntime
2869
2931
  # [1]: https://docs.aws.amazon.com/bedrock/latest/userguide/flows-trace.html
2870
2932
  # @return [Boolean]
2871
2933
  #
2934
+ # @!attribute [rw] execution_id
2935
+ # The unique identifier for the current flow execution. If you don't
2936
+ # provide a value, Amazon Bedrock creates the identifier for you.
2937
+ # @return [String]
2938
+ #
2872
2939
  # @!attribute [rw] flow_alias_identifier
2873
2940
  # The unique identifier of the flow alias.
2874
2941
  # @return [String]
@@ -2890,6 +2957,7 @@ module Aws::BedrockAgentRuntime
2890
2957
  #
2891
2958
  class InvokeFlowRequest < Struct.new(
2892
2959
  :enable_trace,
2960
+ :execution_id,
2893
2961
  :flow_alias_identifier,
2894
2962
  :flow_identifier,
2895
2963
  :inputs,
@@ -2898,6 +2966,10 @@ module Aws::BedrockAgentRuntime
2898
2966
  include Aws::Structure
2899
2967
  end
2900
2968
 
2969
+ # @!attribute [rw] execution_id
2970
+ # The unique identifier for the current flow execution.
2971
+ # @return [String]
2972
+ #
2901
2973
  # @!attribute [rw] response_stream
2902
2974
  # The output of the flow, returned as a stream. If there's an error,
2903
2975
  # the error is returned.
@@ -2906,6 +2978,7 @@ module Aws::BedrockAgentRuntime
2906
2978
  # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-agent-runtime-2023-07-26/InvokeFlowResponse AWS API Documentation
2907
2979
  #
2908
2980
  class InvokeFlowResponse < Struct.new(
2981
+ :execution_id,
2909
2982
  :response_stream)
2910
2983
  SENSITIVE = []
2911
2984
  include Aws::Structure
@@ -6256,6 +6329,7 @@ module Aws::BedrockAgentRuntime
6256
6329
  :conflict_exception,
6257
6330
  :dependency_failed_exception,
6258
6331
  :flow_completion_event,
6332
+ :flow_multi_turn_input_request_event,
6259
6333
  :flow_output_event,
6260
6334
  :flow_trace_event,
6261
6335
  :internal_server_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.39.0'
58
+ GEM_VERSION = '1.41.0'
59
59
 
60
60
  end
61
61
 
data/sig/client.rbs CHANGED
@@ -330,11 +330,13 @@ module Aws
330
330
 
331
331
  interface _InvokeFlowResponseSuccess
332
332
  include ::Seahorse::Client::_ResponseSuccess[Types::InvokeFlowResponse]
333
+ def execution_id: () -> ::String
333
334
  def response_stream: () -> Types::FlowResponseStream
334
335
  end
335
336
  # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/BedrockAgentRuntime/Client.html#invoke_flow-instance_method
336
337
  def invoke_flow: (
337
338
  ?enable_trace: bool,
339
+ ?execution_id: ::String,
338
340
  flow_alias_identifier: ::String,
339
341
  flow_identifier: ::String,
340
342
  inputs: Array[
@@ -343,8 +345,9 @@ module Aws
343
345
  document: {
344
346
  }?
345
347
  },
348
+ node_input_name: ::String?,
346
349
  node_name: ::String,
347
- node_output_name: ::String
350
+ node_output_name: ::String?
348
351
  },
349
352
  ],
350
353
  ?model_performance_configuration: {
data/sig/errors.rbs CHANGED
@@ -27,6 +27,7 @@ module Aws
27
27
  end
28
28
  class InternalServerException < ::Aws::Errors::ServiceError
29
29
  def message: () -> ::String
30
+ def reason: () -> ::String
30
31
  end
31
32
  class ModelNotReadyException < ::Aws::Errors::ServiceError
32
33
  def message: () -> ::String
data/sig/types.rbs CHANGED
@@ -333,13 +333,14 @@ module Aws::BedrockAgentRuntime
333
333
  end
334
334
 
335
335
  class FlowCompletionEvent
336
- attr_accessor completion_reason: ("SUCCESS")
336
+ attr_accessor completion_reason: ("SUCCESS" | "INPUT_REQUIRED")
337
337
  attr_accessor event_type: untyped
338
338
  SENSITIVE: []
339
339
  end
340
340
 
341
341
  class FlowInput
342
342
  attr_accessor content: Types::FlowInputContent
343
+ attr_accessor node_input_name: ::String
343
344
  attr_accessor node_name: ::String
344
345
  attr_accessor node_output_name: ::String
345
346
  SENSITIVE: [:content]
@@ -356,6 +357,25 @@ module Aws::BedrockAgentRuntime
356
357
  end
357
358
  end
358
359
 
360
+ class FlowMultiTurnInputContent
361
+ attr_accessor document: untyped
362
+ attr_accessor unknown: untyped
363
+ SENSITIVE: []
364
+
365
+ class Document < FlowMultiTurnInputContent
366
+ end
367
+ class Unknown < FlowMultiTurnInputContent
368
+ end
369
+ end
370
+
371
+ class FlowMultiTurnInputRequestEvent
372
+ attr_accessor content: Types::FlowMultiTurnInputContent
373
+ attr_accessor node_name: ::String
374
+ attr_accessor node_type: ("FlowInputNode" | "FlowOutputNode" | "LambdaFunctionNode" | "KnowledgeBaseNode" | "PromptNode" | "ConditionNode" | "LexNode")
375
+ attr_accessor event_type: untyped
376
+ SENSITIVE: []
377
+ end
378
+
359
379
  class FlowOutputContent
360
380
  attr_accessor document: untyped
361
381
  attr_accessor unknown: untyped
@@ -730,6 +750,7 @@ module Aws::BedrockAgentRuntime
730
750
 
731
751
  class InternalServerException
732
752
  attr_accessor message: ::String
753
+ attr_accessor reason: ::String
733
754
  attr_accessor event_type: untyped
734
755
  SENSITIVE: []
735
756
  end
@@ -797,6 +818,7 @@ module Aws::BedrockAgentRuntime
797
818
 
798
819
  class InvokeFlowRequest
799
820
  attr_accessor enable_trace: bool
821
+ attr_accessor execution_id: ::String
800
822
  attr_accessor flow_alias_identifier: ::String
801
823
  attr_accessor flow_identifier: ::String
802
824
  attr_accessor inputs: ::Array[Types::FlowInput]
@@ -805,6 +827,7 @@ module Aws::BedrockAgentRuntime
805
827
  end
806
828
 
807
829
  class InvokeFlowResponse
830
+ attr_accessor execution_id: ::String
808
831
  attr_accessor response_stream: Types::FlowResponseStream
809
832
  SENSITIVE: []
810
833
  end
@@ -1655,7 +1678,7 @@ module Aws::BedrockAgentRuntime
1655
1678
  end
1656
1679
 
1657
1680
  class FlowResponseStream < Enumerator[untyped, untyped]
1658
- def event_types: () -> [:access_denied_exception, :bad_gateway_exception, :conflict_exception, :dependency_failed_exception, :flow_completion_event, :flow_output_event, :flow_trace_event, :internal_server_exception, :resource_not_found_exception, :service_quota_exceeded_exception, :throttling_exception, :validation_exception]
1681
+ def event_types: () -> [:access_denied_exception, :bad_gateway_exception, :conflict_exception, :dependency_failed_exception, :flow_completion_event, :flow_multi_turn_input_request_event, :flow_output_event, :flow_trace_event, :internal_server_exception, :resource_not_found_exception, :service_quota_exceeded_exception, :throttling_exception, :validation_exception]
1659
1682
  end
1660
1683
 
1661
1684
  class InlineAgentResponseStream < 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.39.0
4
+ version: 1.41.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: 2025-01-15 00:00:00.000000000 Z
11
+ date: 2025-01-30 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: aws-sdk-core