aws-sdk-bedrockagentruntime 1.2.0 → 1.3.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.
@@ -53,6 +53,6 @@ require_relative 'aws-sdk-bedrockagentruntime/event_streams'
53
53
  # @!group service
54
54
  module Aws::BedrockAgentRuntime
55
55
 
56
- GEM_VERSION = '1.2.0'
56
+ GEM_VERSION = '1.3.0'
57
57
 
58
58
  end
data/sig/client.rbs CHANGED
@@ -83,54 +83,52 @@ module Aws
83
83
  end
84
84
  # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/BedrockAgentRuntime/Client.html#invoke_agent-instance_method
85
85
  def invoke_agent: (
86
- ?session_state: {
87
- session_attributes: Hash[::String, ::String]?,
88
- prompt_session_attributes: Hash[::String, ::String]?
89
- },
90
- agent_id: ::String,
91
86
  agent_alias_id: ::String,
92
- session_id: ::String,
93
- ?end_session: bool,
87
+ agent_id: ::String,
94
88
  ?enable_trace: bool,
95
- input_text: ::String
89
+ ?end_session: bool,
90
+ input_text: ::String,
91
+ session_id: ::String,
92
+ ?session_state: {
93
+ prompt_session_attributes: Hash[::String, ::String]?,
94
+ session_attributes: Hash[::String, ::String]?
95
+ }
96
96
  ) ?{ (*untyped) -> void } -> _InvokeAgentResponseSuccess
97
97
  | (Hash[Symbol, untyped] params, ?Hash[Symbol, untyped] options) ?{ (*untyped) -> void } -> _InvokeAgentResponseSuccess
98
98
 
99
99
  interface _RetrieveResponseSuccess
100
100
  include ::Seahorse::Client::_ResponseSuccess[Types::RetrieveResponse]
101
- def retrieval_results: () -> ::Array[Types::KnowledgeBaseRetrievalResult]
102
101
  def next_token: () -> ::String
102
+ def retrieval_results: () -> ::Array[Types::KnowledgeBaseRetrievalResult]
103
103
  end
104
104
  # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/BedrockAgentRuntime/Client.html#retrieve-instance_method
105
105
  def retrieve: (
106
106
  knowledge_base_id: ::String,
107
- retrieval_query: {
108
- text: ::String
109
- },
107
+ ?next_token: ::String,
110
108
  ?retrieval_configuration: {
111
109
  vector_search_configuration: {
112
110
  number_of_results: ::Integer?,
113
111
  override_search_type: ("HYBRID" | "SEMANTIC")?
114
112
  }
115
113
  },
116
- ?next_token: ::String
114
+ retrieval_query: {
115
+ text: ::String
116
+ }
117
117
  ) -> _RetrieveResponseSuccess
118
118
  | (Hash[Symbol, untyped] params, ?Hash[Symbol, untyped] options) -> _RetrieveResponseSuccess
119
119
 
120
120
  interface _RetrieveAndGenerateResponseSuccess
121
121
  include ::Seahorse::Client::_ResponseSuccess[Types::RetrieveAndGenerateResponse]
122
- def session_id: () -> ::String
123
- def output: () -> Types::RetrieveAndGenerateOutput
124
122
  def citations: () -> ::Array[Types::Citation]
123
+ def output: () -> Types::RetrieveAndGenerateOutput
124
+ def session_id: () -> ::String
125
125
  end
126
126
  # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/BedrockAgentRuntime/Client.html#retrieve_and_generate-instance_method
127
127
  def retrieve_and_generate: (
128
- ?session_id: ::String,
129
128
  input: {
130
129
  text: ::String
131
130
  },
132
131
  ?retrieve_and_generate_configuration: {
133
- type: ("KNOWLEDGE_BASE"),
134
132
  knowledge_base_configuration: {
135
133
  knowledge_base_id: ::String,
136
134
  model_arn: ::String,
@@ -140,11 +138,13 @@ module Aws
140
138
  override_search_type: ("HYBRID" | "SEMANTIC")?
141
139
  }
142
140
  }?
143
- }?
141
+ }?,
142
+ type: ("KNOWLEDGE_BASE")
144
143
  },
145
144
  ?session_configuration: {
146
145
  kms_key_arn: ::String
147
- }
146
+ },
147
+ ?session_id: ::String
148
148
  ) -> _RetrieveAndGenerateResponseSuccess
149
149
  | (Hash[Symbol, untyped] params, ?Hash[Symbol, untyped] options) -> _RetrieveAndGenerateResponseSuccess
150
150
  end
data/sig/types.rbs CHANGED
@@ -16,11 +16,11 @@ module Aws::BedrockAgentRuntime
16
16
 
17
17
  class ActionGroupInvocationInput
18
18
  attr_accessor action_group_name: ::String
19
- attr_accessor verb: ::String
20
19
  attr_accessor api_path: ::String
21
20
  attr_accessor parameters: ::Array[Types::Parameter]
22
21
  attr_accessor request_body: Types::RequestBody
23
- SENSITIVE: [:action_group_name, :verb, :api_path]
22
+ attr_accessor verb: ::String
23
+ SENSITIVE: [:action_group_name, :api_path, :verb]
24
24
  end
25
25
 
26
26
  class ActionGroupInvocationOutput
@@ -60,8 +60,8 @@ module Aws::BedrockAgentRuntime
60
60
  end
61
61
 
62
62
  class FailureTrace
63
- attr_accessor trace_id: ::String
64
63
  attr_accessor failure_reason: ::String
64
+ attr_accessor trace_id: ::String
65
65
  SENSITIVE: [:failure_reason]
66
66
  end
67
67
 
@@ -76,11 +76,11 @@ module Aws::BedrockAgentRuntime
76
76
  end
77
77
 
78
78
  class InferenceConfiguration
79
- attr_accessor temperature: ::Float
80
- attr_accessor top_p: ::Float
81
- attr_accessor top_k: ::Integer
82
79
  attr_accessor maximum_length: ::Integer
83
80
  attr_accessor stop_sequences: ::Array[::String]
81
+ attr_accessor temperature: ::Float
82
+ attr_accessor top_k: ::Integer
83
+ attr_accessor top_p: ::Float
84
84
  SENSITIVE: []
85
85
  end
86
86
 
@@ -91,21 +91,21 @@ module Aws::BedrockAgentRuntime
91
91
  end
92
92
 
93
93
  class InvocationInput
94
- attr_accessor trace_id: ::String
95
- attr_accessor invocation_type: ("ACTION_GROUP" | "KNOWLEDGE_BASE" | "FINISH")
96
94
  attr_accessor action_group_invocation_input: Types::ActionGroupInvocationInput
95
+ attr_accessor invocation_type: ("ACTION_GROUP" | "KNOWLEDGE_BASE" | "FINISH")
97
96
  attr_accessor knowledge_base_lookup_input: Types::KnowledgeBaseLookupInput
97
+ attr_accessor trace_id: ::String
98
98
  SENSITIVE: []
99
99
  end
100
100
 
101
101
  class InvokeAgentRequest
102
- attr_accessor session_state: Types::SessionState
103
- attr_accessor agent_id: ::String
104
102
  attr_accessor agent_alias_id: ::String
105
- attr_accessor session_id: ::String
106
- attr_accessor end_session: bool
103
+ attr_accessor agent_id: ::String
107
104
  attr_accessor enable_trace: bool
105
+ attr_accessor end_session: bool
108
106
  attr_accessor input_text: ::String
107
+ attr_accessor session_id: ::String
108
+ attr_accessor session_state: Types::SessionState
109
109
  SENSITIVE: [:input_text]
110
110
  end
111
111
 
@@ -117,9 +117,9 @@ module Aws::BedrockAgentRuntime
117
117
  end
118
118
 
119
119
  class KnowledgeBaseLookupInput
120
- attr_accessor text: ::String
121
120
  attr_accessor knowledge_base_id: ::String
122
- SENSITIVE: [:text, :knowledge_base_id]
121
+ attr_accessor text: ::String
122
+ SENSITIVE: [:knowledge_base_id, :text]
123
123
  end
124
124
 
125
125
  class KnowledgeBaseLookupOutput
@@ -158,41 +158,41 @@ module Aws::BedrockAgentRuntime
158
158
  end
159
159
 
160
160
  class ModelInvocationInput
161
- attr_accessor trace_id: ::String
162
- attr_accessor text: ::String
163
- attr_accessor type: ("PRE_PROCESSING" | "ORCHESTRATION" | "KNOWLEDGE_BASE_RESPONSE_GENERATION" | "POST_PROCESSING")
164
161
  attr_accessor inference_configuration: Types::InferenceConfiguration
165
162
  attr_accessor override_lambda: ::String
166
- attr_accessor prompt_creation_mode: ("DEFAULT" | "OVERRIDDEN")
167
163
  attr_accessor parser_mode: ("DEFAULT" | "OVERRIDDEN")
164
+ attr_accessor prompt_creation_mode: ("DEFAULT" | "OVERRIDDEN")
165
+ attr_accessor text: ::String
166
+ attr_accessor trace_id: ::String
167
+ attr_accessor type: ("PRE_PROCESSING" | "ORCHESTRATION" | "KNOWLEDGE_BASE_RESPONSE_GENERATION" | "POST_PROCESSING")
168
168
  SENSITIVE: [:text]
169
169
  end
170
170
 
171
171
  class Observation
172
- attr_accessor trace_id: ::String
173
- attr_accessor type: ("ACTION_GROUP" | "KNOWLEDGE_BASE" | "FINISH" | "ASK_USER" | "REPROMPT")
174
172
  attr_accessor action_group_invocation_output: Types::ActionGroupInvocationOutput
175
- attr_accessor knowledge_base_lookup_output: Types::KnowledgeBaseLookupOutput
176
173
  attr_accessor final_response: Types::FinalResponse
174
+ attr_accessor knowledge_base_lookup_output: Types::KnowledgeBaseLookupOutput
177
175
  attr_accessor reprompt_response: Types::RepromptResponse
176
+ attr_accessor trace_id: ::String
177
+ attr_accessor type: ("ACTION_GROUP" | "KNOWLEDGE_BASE" | "FINISH" | "ASK_USER" | "REPROMPT")
178
178
  SENSITIVE: [:reprompt_response]
179
179
  end
180
180
 
181
181
  class OrchestrationTrace
182
- attr_accessor rationale: Types::Rationale
183
182
  attr_accessor invocation_input: Types::InvocationInput
184
- attr_accessor observation: Types::Observation
185
183
  attr_accessor model_invocation_input: Types::ModelInvocationInput
184
+ attr_accessor observation: Types::Observation
185
+ attr_accessor rationale: Types::Rationale
186
186
  attr_accessor unknown: untyped
187
- SENSITIVE: [:rationale, :invocation_input, :observation, :model_invocation_input]
187
+ SENSITIVE: [:invocation_input, :model_invocation_input, :observation, :rationale]
188
188
 
189
- class Rationale < OrchestrationTrace
190
- end
191
189
  class InvocationInput < OrchestrationTrace
192
190
  end
191
+ class ModelInvocationInput < OrchestrationTrace
192
+ end
193
193
  class Observation < OrchestrationTrace
194
194
  end
195
- class ModelInvocationInput < OrchestrationTrace
195
+ class Rationale < OrchestrationTrace
196
196
  end
197
197
  class Unknown < OrchestrationTrace
198
198
  end
@@ -206,15 +206,15 @@ module Aws::BedrockAgentRuntime
206
206
  end
207
207
 
208
208
  class PayloadPart
209
- attr_accessor bytes: ::String
210
209
  attr_accessor attribution: Types::Attribution
210
+ attr_accessor bytes: ::String
211
211
  attr_accessor event_type: untyped
212
212
  SENSITIVE: [:bytes]
213
213
  end
214
214
 
215
215
  class PostProcessingModelInvocationOutput
216
- attr_accessor trace_id: ::String
217
216
  attr_accessor parsed_response: Types::PostProcessingParsedResponse
217
+ attr_accessor trace_id: ::String
218
218
  SENSITIVE: [:parsed_response]
219
219
  end
220
220
 
@@ -238,14 +238,14 @@ module Aws::BedrockAgentRuntime
238
238
  end
239
239
 
240
240
  class PreProcessingModelInvocationOutput
241
- attr_accessor trace_id: ::String
242
241
  attr_accessor parsed_response: Types::PreProcessingParsedResponse
242
+ attr_accessor trace_id: ::String
243
243
  SENSITIVE: [:parsed_response]
244
244
  end
245
245
 
246
246
  class PreProcessingParsedResponse
247
- attr_accessor rationale: ::String
248
247
  attr_accessor is_valid: bool
248
+ attr_accessor rationale: ::String
249
249
  SENSITIVE: [:rationale]
250
250
  end
251
251
 
@@ -264,14 +264,14 @@ module Aws::BedrockAgentRuntime
264
264
  end
265
265
 
266
266
  class Rationale
267
- attr_accessor trace_id: ::String
268
267
  attr_accessor text: ::String
268
+ attr_accessor trace_id: ::String
269
269
  SENSITIVE: [:text]
270
270
  end
271
271
 
272
272
  class RepromptResponse
273
- attr_accessor text: ::String
274
273
  attr_accessor source: ("ACTION_GROUP" | "KNOWLEDGE_BASE" | "PARSER")
274
+ attr_accessor text: ::String
275
275
  SENSITIVE: [:source]
276
276
  end
277
277
 
@@ -292,8 +292,8 @@ module Aws::BedrockAgentRuntime
292
292
  end
293
293
 
294
294
  class RetrievalResultLocation
295
- attr_accessor type: ("S3")
296
295
  attr_accessor s3_location: Types::RetrievalResultS3Location
296
+ attr_accessor type: ("S3")
297
297
  SENSITIVE: []
298
298
  end
299
299
 
@@ -303,8 +303,8 @@ module Aws::BedrockAgentRuntime
303
303
  end
304
304
 
305
305
  class RetrieveAndGenerateConfiguration
306
- attr_accessor type: ("KNOWLEDGE_BASE")
307
306
  attr_accessor knowledge_base_configuration: Types::KnowledgeBaseRetrieveAndGenerateConfiguration
307
+ attr_accessor type: ("KNOWLEDGE_BASE")
308
308
  SENSITIVE: []
309
309
  end
310
310
 
@@ -319,17 +319,17 @@ module Aws::BedrockAgentRuntime
319
319
  end
320
320
 
321
321
  class RetrieveAndGenerateRequest
322
- attr_accessor session_id: ::String
323
322
  attr_accessor input: Types::RetrieveAndGenerateInput
324
323
  attr_accessor retrieve_and_generate_configuration: Types::RetrieveAndGenerateConfiguration
325
324
  attr_accessor session_configuration: Types::RetrieveAndGenerateSessionConfiguration
325
+ attr_accessor session_id: ::String
326
326
  SENSITIVE: [:input]
327
327
  end
328
328
 
329
329
  class RetrieveAndGenerateResponse
330
- attr_accessor session_id: ::String
331
- attr_accessor output: Types::RetrieveAndGenerateOutput
332
330
  attr_accessor citations: ::Array[Types::Citation]
331
+ attr_accessor output: Types::RetrieveAndGenerateOutput
332
+ attr_accessor session_id: ::String
333
333
  SENSITIVE: [:output]
334
334
  end
335
335
 
@@ -340,15 +340,15 @@ module Aws::BedrockAgentRuntime
340
340
 
341
341
  class RetrieveRequest
342
342
  attr_accessor knowledge_base_id: ::String
343
- attr_accessor retrieval_query: Types::KnowledgeBaseQuery
344
- attr_accessor retrieval_configuration: Types::KnowledgeBaseRetrievalConfiguration
345
343
  attr_accessor next_token: ::String
344
+ attr_accessor retrieval_configuration: Types::KnowledgeBaseRetrievalConfiguration
345
+ attr_accessor retrieval_query: Types::KnowledgeBaseQuery
346
346
  SENSITIVE: [:retrieval_query]
347
347
  end
348
348
 
349
349
  class RetrieveResponse
350
- attr_accessor retrieval_results: ::Array[Types::KnowledgeBaseRetrievalResult]
351
350
  attr_accessor next_token: ::String
351
+ attr_accessor retrieval_results: ::Array[Types::KnowledgeBaseRetrievalResult]
352
352
  SENSITIVE: [:retrieval_results]
353
353
  end
354
354
 
@@ -365,20 +365,20 @@ module Aws::BedrockAgentRuntime
365
365
  end
366
366
 
367
367
  class SessionState
368
- attr_accessor session_attributes: ::Hash[::String, ::String]
369
368
  attr_accessor prompt_session_attributes: ::Hash[::String, ::String]
369
+ attr_accessor session_attributes: ::Hash[::String, ::String]
370
370
  SENSITIVE: []
371
371
  end
372
372
 
373
373
  class Span
374
- attr_accessor start: ::Integer
375
374
  attr_accessor end: ::Integer
375
+ attr_accessor start: ::Integer
376
376
  SENSITIVE: []
377
377
  end
378
378
 
379
379
  class TextResponsePart
380
- attr_accessor text: ::String
381
380
  attr_accessor span: Types::Span
381
+ attr_accessor text: ::String
382
382
  SENSITIVE: []
383
383
  end
384
384
 
@@ -389,28 +389,28 @@ module Aws::BedrockAgentRuntime
389
389
  end
390
390
 
391
391
  class Trace
392
- attr_accessor pre_processing_trace: Types::PreProcessingTrace
392
+ attr_accessor failure_trace: Types::FailureTrace
393
393
  attr_accessor orchestration_trace: Types::OrchestrationTrace
394
394
  attr_accessor post_processing_trace: Types::PostProcessingTrace
395
- attr_accessor failure_trace: Types::FailureTrace
395
+ attr_accessor pre_processing_trace: Types::PreProcessingTrace
396
396
  attr_accessor unknown: untyped
397
- SENSITIVE: [:pre_processing_trace, :orchestration_trace, :post_processing_trace, :failure_trace]
397
+ SENSITIVE: [:failure_trace, :orchestration_trace, :post_processing_trace, :pre_processing_trace]
398
398
 
399
- class PreProcessingTrace < Trace
399
+ class FailureTrace < Trace
400
400
  end
401
401
  class OrchestrationTrace < Trace
402
402
  end
403
403
  class PostProcessingTrace < Trace
404
404
  end
405
- class FailureTrace < Trace
405
+ class PreProcessingTrace < Trace
406
406
  end
407
407
  class Unknown < Trace
408
408
  end
409
409
  end
410
410
 
411
411
  class TracePart
412
- attr_accessor agent_id: ::String
413
412
  attr_accessor agent_alias_id: ::String
413
+ attr_accessor agent_id: ::String
414
414
  attr_accessor session_id: ::String
415
415
  attr_accessor trace: Types::Trace
416
416
  attr_accessor event_type: untyped
@@ -424,7 +424,7 @@ module Aws::BedrockAgentRuntime
424
424
  end
425
425
 
426
426
  class ResponseStream < Enumerator[untyped, untyped]
427
- def event_types: () -> [:chunk, :trace, :internal_server_exception, :validation_exception, :resource_not_found_exception, :service_quota_exceeded_exception, :throttling_exception, :access_denied_exception, :conflict_exception, :dependency_failed_exception, :bad_gateway_exception]
427
+ def event_types: () -> [:access_denied_exception, :bad_gateway_exception, :chunk, :conflict_exception, :dependency_failed_exception, :internal_server_exception, :resource_not_found_exception, :service_quota_exceeded_exception, :throttling_exception, :trace, :validation_exception]
428
428
  end
429
429
  end
430
430
  end
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.2.0
4
+ version: 1.3.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-02-28 00:00:00.000000000 Z
11
+ date: 2024-03-08 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: aws-sdk-core