aws-sdk-bedrockruntime 1.17.0 → 1.25.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: e948bde4e28178c5d1046859bc1766ad18aab73d4b4a6a0cc251b5f4b66159fe
4
- data.tar.gz: 96b7093be2065ceca06bf4644bea0055c4bb1048a6d8d892915f5008137f7459
3
+ metadata.gz: d906df1bc397501e4ee608d6190153dbc590534090431219f77ffb5585f2a7ad
4
+ data.tar.gz: a3235cdff0088916b0473cbd845f8e5efc1e6846df6e49944bc42ca23795195f
5
5
  SHA512:
6
- metadata.gz: 47f8582f3c4c4f78a6ce0f6272c705702df29663a6afe2fcf5d22614d470164dea10ee3aad47dbd7b9e2b0c26662ee5b02af17ac8fec2bc138f20c372158da23
7
- data.tar.gz: 4cfdbfeddc2a7adafa369b949cfe0104c39d7cef1c08e2e1cc95bff903529ef0d037d43b40068210a6290bf55d335a32c0379360ac53a26d79202b48b983ed76
6
+ metadata.gz: 13b7cdd3c8b0452f15610ca7127fa4f9eb77bebea4adefa3aa05a3569d0941b7028ba476c19215a7853568d7f6d9067c23ac6335651bec5c119642e1115881d5
7
+ data.tar.gz: 1d78660873c94f80624af93f4d1acef972028c08cde78927425bd9c74f00cfcf8a8ac9f053af24d45fdfca409eb7a30da1eca6b52b1bb782b5dc3f81afaabd6a
data/CHANGELOG.md CHANGED
@@ -1,6 +1,46 @@
1
1
  Unreleased Changes
2
2
  ------------------
3
3
 
4
+ 1.25.0 (2024-09-24)
5
+ ------------------
6
+
7
+ * Feature - Code Generated Changes, see `./build_tools` or `aws-sdk-core`'s CHANGELOG.md for details.
8
+
9
+ 1.24.0 (2024-09-23)
10
+ ------------------
11
+
12
+ * Feature - Code Generated Changes, see `./build_tools` or `aws-sdk-core`'s CHANGELOG.md for details.
13
+
14
+ 1.23.0 (2024-09-20)
15
+ ------------------
16
+
17
+ * Feature - Code Generated Changes, see `./build_tools` or `aws-sdk-core`'s CHANGELOG.md for details.
18
+
19
+ 1.22.0 (2024-09-11)
20
+ ------------------
21
+
22
+ * Feature - Code Generated Changes, see `./build_tools` or `aws-sdk-core`'s CHANGELOG.md for details.
23
+
24
+ 1.21.0 (2024-09-10)
25
+ ------------------
26
+
27
+ * Feature - Code Generated Changes, see `./build_tools` or `aws-sdk-core`'s CHANGELOG.md for details.
28
+
29
+ 1.20.0 (2024-09-03)
30
+ ------------------
31
+
32
+ * Feature - Code Generated Changes, see `./build_tools` or `aws-sdk-core`'s CHANGELOG.md for details.
33
+
34
+ 1.19.0 (2024-08-29)
35
+ ------------------
36
+
37
+ * Feature - Add support for imported-model in invokeModel and InvokeModelWithResponseStream.
38
+
39
+ 1.18.0 (2024-08-27)
40
+ ------------------
41
+
42
+ * Feature - Amazon Bedrock SDK updates for Inference Profile.
43
+
4
44
  1.17.0 (2024-07-25)
5
45
  ------------------
6
46
 
data/VERSION CHANGED
@@ -1 +1 @@
1
- 1.17.0
1
+ 1.25.0
@@ -32,12 +32,11 @@ require 'aws-sdk-core/plugins/checksum_algorithm.rb'
32
32
  require 'aws-sdk-core/plugins/request_compression.rb'
33
33
  require 'aws-sdk-core/plugins/defaults_mode.rb'
34
34
  require 'aws-sdk-core/plugins/recursion_detection.rb'
35
+ require 'aws-sdk-core/plugins/telemetry.rb'
35
36
  require 'aws-sdk-core/plugins/sign.rb'
36
37
  require 'aws-sdk-core/plugins/protocols/rest_json.rb'
37
38
  require 'aws-sdk-core/plugins/event_stream_configuration.rb'
38
39
 
39
- Aws::Plugins::GlobalConfiguration.add_identifier(:bedrockruntime)
40
-
41
40
  module Aws::BedrockRuntime
42
41
  # An API client for BedrockRuntime. To construct a client, you need to configure a `:region` and `:credentials`.
43
42
  #
@@ -84,6 +83,7 @@ module Aws::BedrockRuntime
84
83
  add_plugin(Aws::Plugins::RequestCompression)
85
84
  add_plugin(Aws::Plugins::DefaultsMode)
86
85
  add_plugin(Aws::Plugins::RecursionDetection)
86
+ add_plugin(Aws::Plugins::Telemetry)
87
87
  add_plugin(Aws::Plugins::Sign)
88
88
  add_plugin(Aws::Plugins::Protocols::RestJson)
89
89
  add_plugin(Aws::Plugins::EventStreamConfiguration)
@@ -130,13 +130,15 @@ module Aws::BedrockRuntime
130
130
  # locations will be searched for credentials:
131
131
  #
132
132
  # * `Aws.config[:credentials]`
133
- # * The `:access_key_id`, `:secret_access_key`, and `:session_token` options.
134
- # * ENV['AWS_ACCESS_KEY_ID'], ENV['AWS_SECRET_ACCESS_KEY']
133
+ # * The `:access_key_id`, `:secret_access_key`, `:session_token`, and
134
+ # `:account_id` options.
135
+ # * ENV['AWS_ACCESS_KEY_ID'], ENV['AWS_SECRET_ACCESS_KEY'],
136
+ # ENV['AWS_SESSION_TOKEN'], and ENV['AWS_ACCOUNT_ID']
135
137
  # * `~/.aws/credentials`
136
138
  # * `~/.aws/config`
137
139
  # * EC2/ECS IMDS instance profile - When used by default, the timeouts
138
140
  # are very aggressive. Construct and pass an instance of
139
- # `Aws::InstanceProfileCredentails` or `Aws::ECSCredentials` to
141
+ # `Aws::InstanceProfileCredentials` or `Aws::ECSCredentials` to
140
142
  # enable retries and extended timeouts. Instance profile credential
141
143
  # fetching can be disabled by setting ENV['AWS_EC2_METADATA_DISABLED']
142
144
  # to true.
@@ -155,6 +157,8 @@ module Aws::BedrockRuntime
155
157
  #
156
158
  # @option options [String] :access_key_id
157
159
  #
160
+ # @option options [String] :account_id
161
+ #
158
162
  # @option options [Boolean] :active_endpoint_cache (false)
159
163
  # When set to `true`, a thread polling for endpoints will be running in
160
164
  # the background every 60 secs (default). Defaults to `false`.
@@ -341,6 +345,16 @@ module Aws::BedrockRuntime
341
345
  # ** Please note ** When response stubbing is enabled, no HTTP
342
346
  # requests are made, and retries are disabled.
343
347
  #
348
+ # @option options [Aws::Telemetry::TelemetryProviderBase] :telemetry_provider (Aws::Telemetry::NoOpTelemetryProvider)
349
+ # Allows you to provide a telemetry provider, which is used to
350
+ # emit telemetry data. By default, uses `NoOpTelemetryProvider` which
351
+ # will not record or emit any telemetry data. The SDK supports the
352
+ # following telemetry providers:
353
+ #
354
+ # * OpenTelemetry (OTel) - To use the OTel provider, install and require the
355
+ # `opentelemetry-sdk` gem and then, pass in an instance of a
356
+ # `Aws::Telemetry::OTelProvider` for telemetry provider.
357
+ #
344
358
  # @option options [Aws::TokenProvider] :token_provider
345
359
  # A Bearer Token Provider. This can be an instance of any one of the
346
360
  # following classes:
@@ -368,7 +382,9 @@ module Aws::BedrockRuntime
368
382
  # sending the request.
369
383
  #
370
384
  # @option options [Aws::BedrockRuntime::EndpointProvider] :endpoint_provider
371
- # The endpoint provider used to resolve endpoints. Any object that responds to `#resolve_endpoint(parameters)` where `parameters` is a Struct similar to `Aws::BedrockRuntime::EndpointParameters`
385
+ # The endpoint provider used to resolve endpoints. Any object that responds to
386
+ # `#resolve_endpoint(parameters)` where `parameters` is a Struct similar to
387
+ # `Aws::BedrockRuntime::EndpointParameters`.
372
388
  #
373
389
  # @option options [Float] :http_continue_timeout (1)
374
390
  # The number of seconds to wait for a 100-continue response before sending the
@@ -424,6 +440,12 @@ module Aws::BedrockRuntime
424
440
  # @option options [String] :ssl_ca_store
425
441
  # Sets the X509::Store to verify peer certificate.
426
442
  #
443
+ # @option options [OpenSSL::X509::Certificate] :ssl_cert
444
+ # Sets a client certificate when creating http connections.
445
+ #
446
+ # @option options [OpenSSL::PKey] :ssl_key
447
+ # Sets a client key when creating http connections.
448
+ #
427
449
  # @option options [Float] :ssl_timeout
428
450
  # Sets the SSL timeout in seconds
429
451
  #
@@ -548,26 +570,36 @@ module Aws::BedrockRuntime
548
570
  # @option params [required, String] :model_id
549
571
  # The identifier for the model that you want to call.
550
572
  #
551
- # The `modelId` to provide depends on the type of model that you use:
573
+ # The `modelId` to provide depends on the type of model or throughput
574
+ # that you use:
552
575
  #
553
576
  # * If you use a base model, specify the model ID or its ARN. For a list
554
577
  # of model IDs for base models, see [Amazon Bedrock base model IDs
555
578
  # (on-demand throughput)][1] in the Amazon Bedrock User Guide.
556
579
  #
580
+ # * If you use an inference profile, specify the inference profile ID or
581
+ # its ARN. For a list of inference profile IDs, see [Supported Regions
582
+ # and models for cross-region inference][2] in the Amazon Bedrock User
583
+ # Guide.
584
+ #
557
585
  # * If you use a provisioned model, specify the ARN of the Provisioned
558
586
  # Throughput. For more information, see [Run inference using a
559
- # Provisioned Throughput][2] in the Amazon Bedrock User Guide.
587
+ # Provisioned Throughput][3] in the Amazon Bedrock User Guide.
560
588
  #
561
589
  # * If you use a custom model, first purchase Provisioned Throughput for
562
590
  # it. Then specify the ARN of the resulting provisioned model. For
563
- # more information, see [Use a custom model in Amazon Bedrock][3] in
591
+ # more information, see [Use a custom model in Amazon Bedrock][4] in
564
592
  # the Amazon Bedrock User Guide.
565
593
  #
594
+ # The Converse API doesn't support [imported models][5].
595
+ #
566
596
  #
567
597
  #
568
598
  # [1]: https://docs.aws.amazon.com/bedrock/latest/userguide/model-ids.html#model-ids-arns
569
- # [2]: https://docs.aws.amazon.com/bedrock/latest/userguide/prov-thru-use.html
570
- # [3]: https://docs.aws.amazon.com/bedrock/latest/userguide/model-customization-use.html
599
+ # [2]: https://docs.aws.amazon.com/bedrock/latest/userguide/cross-region-inference-support.html
600
+ # [3]: https://docs.aws.amazon.com/bedrock/latest/userguide/prov-thru-use.html
601
+ # [4]: https://docs.aws.amazon.com/bedrock/latest/userguide/model-customization-use.html
602
+ # [5]: https://docs.aws.amazon.com/bedrock/latest/userguide/model-customization-import-model.html
571
603
  #
572
604
  # @option params [required, Array<Types::Message>] :messages
573
605
  # The messages that you want to send to the model.
@@ -891,26 +923,36 @@ module Aws::BedrockRuntime
891
923
  # @option params [required, String] :model_id
892
924
  # The ID for the model.
893
925
  #
894
- # The `modelId` to provide depends on the type of model that you use:
926
+ # The `modelId` to provide depends on the type of model or throughput
927
+ # that you use:
895
928
  #
896
929
  # * If you use a base model, specify the model ID or its ARN. For a list
897
930
  # of model IDs for base models, see [Amazon Bedrock base model IDs
898
931
  # (on-demand throughput)][1] in the Amazon Bedrock User Guide.
899
932
  #
933
+ # * If you use an inference profile, specify the inference profile ID or
934
+ # its ARN. For a list of inference profile IDs, see [Supported Regions
935
+ # and models for cross-region inference][2] in the Amazon Bedrock User
936
+ # Guide.
937
+ #
900
938
  # * If you use a provisioned model, specify the ARN of the Provisioned
901
939
  # Throughput. For more information, see [Run inference using a
902
- # Provisioned Throughput][2] in the Amazon Bedrock User Guide.
940
+ # Provisioned Throughput][3] in the Amazon Bedrock User Guide.
903
941
  #
904
942
  # * If you use a custom model, first purchase Provisioned Throughput for
905
943
  # it. Then specify the ARN of the resulting provisioned model. For
906
- # more information, see [Use a custom model in Amazon Bedrock][3] in
944
+ # more information, see [Use a custom model in Amazon Bedrock][4] in
907
945
  # the Amazon Bedrock User Guide.
908
946
  #
947
+ # The Converse API doesn't support [imported models][5].
948
+ #
909
949
  #
910
950
  #
911
951
  # [1]: https://docs.aws.amazon.com/bedrock/latest/userguide/model-ids.html#model-ids-arns
912
- # [2]: https://docs.aws.amazon.com/bedrock/latest/userguide/prov-thru-use.html
913
- # [3]: https://docs.aws.amazon.com/bedrock/latest/userguide/model-customization-use.html
952
+ # [2]: https://docs.aws.amazon.com/bedrock/latest/userguide/cross-region-inference-support.html
953
+ # [3]: https://docs.aws.amazon.com/bedrock/latest/userguide/prov-thru-use.html
954
+ # [4]: https://docs.aws.amazon.com/bedrock/latest/userguide/model-customization-use.html
955
+ # [5]: https://docs.aws.amazon.com/bedrock/latest/userguide/model-customization-import-model.html
914
956
  #
915
957
  # @option params [required, Array<Types::Message>] :messages
916
958
  # The messages that you want to send to the model.
@@ -1443,11 +1485,18 @@ module Aws::BedrockRuntime
1443
1485
  # more information, see [Use a custom model in Amazon Bedrock][3] in
1444
1486
  # the Amazon Bedrock User Guide.
1445
1487
  #
1488
+ # * If you use an [imported model][4], specify the ARN of the imported
1489
+ # model. You can get the model ARN from a successful call to
1490
+ # [CreateModelImportJob][5] or from the Imported models page in the
1491
+ # Amazon Bedrock console.
1492
+ #
1446
1493
  #
1447
1494
  #
1448
1495
  # [1]: https://docs.aws.amazon.com/bedrock/latest/userguide/model-ids.html#model-ids-arns
1449
1496
  # [2]: https://docs.aws.amazon.com/bedrock/latest/userguide/prov-thru-use.html
1450
1497
  # [3]: https://docs.aws.amazon.com/bedrock/latest/userguide/model-customization-use.html
1498
+ # [4]: https://docs.aws.amazon.com/bedrock/latest/userguide/model-customization-import-model.html
1499
+ # [5]: https://docs.aws.amazon.com/bedrock/latest/APIReference/API_CreateModelImportJob.html
1451
1500
  #
1452
1501
  # @option params [String] :trace
1453
1502
  # Specifies whether to enable or disable the Bedrock trace. If enabled,
@@ -1562,11 +1611,18 @@ module Aws::BedrockRuntime
1562
1611
  # more information, see [Use a custom model in Amazon Bedrock][3] in
1563
1612
  # the Amazon Bedrock User Guide.
1564
1613
  #
1614
+ # * If you use an [imported model][4], specify the ARN of the imported
1615
+ # model. You can get the model ARN from a successful call to
1616
+ # [CreateModelImportJob][5] or from the Imported models page in the
1617
+ # Amazon Bedrock console.
1618
+ #
1565
1619
  #
1566
1620
  #
1567
1621
  # [1]: https://docs.aws.amazon.com/bedrock/latest/userguide/model-ids.html#model-ids-arns
1568
1622
  # [2]: https://docs.aws.amazon.com/bedrock/latest/userguide/prov-thru-use.html
1569
1623
  # [3]: https://docs.aws.amazon.com/bedrock/latest/userguide/model-customization-use.html
1624
+ # [4]: https://docs.aws.amazon.com/bedrock/latest/userguide/model-customization-import-model.html
1625
+ # [5]: https://docs.aws.amazon.com/bedrock/latest/APIReference/API_CreateModelImportJob.html
1570
1626
  #
1571
1627
  # @option params [String] :trace
1572
1628
  # Specifies whether to enable or disable the Bedrock trace. If enabled,
@@ -1808,14 +1864,19 @@ module Aws::BedrockRuntime
1808
1864
  # @api private
1809
1865
  def build_request(operation_name, params = {})
1810
1866
  handlers = @handlers.for(operation_name)
1867
+ tracer = config.telemetry_provider.tracer_provider.tracer(
1868
+ Aws::Telemetry.module_to_tracer_name('Aws::BedrockRuntime')
1869
+ )
1811
1870
  context = Seahorse::Client::RequestContext.new(
1812
1871
  operation_name: operation_name,
1813
1872
  operation: config.api.operation(operation_name),
1814
1873
  client: self,
1815
1874
  params: params,
1816
- config: config)
1875
+ config: config,
1876
+ tracer: tracer
1877
+ )
1817
1878
  context[:gem_name] = 'aws-sdk-bedrockruntime'
1818
- context[:gem_version] = '1.17.0'
1879
+ context[:gem_version] = '1.25.0'
1819
1880
  Seahorse::Client::Request.new(handlers, context)
1820
1881
  end
1821
1882
 
@@ -7,6 +7,7 @@
7
7
  #
8
8
  # WARNING ABOUT GENERATED CODE
9
9
 
10
+
10
11
  module Aws::BedrockRuntime
11
12
  # @api private
12
13
  module ClientApi
@@ -14,70 +14,55 @@ module Aws::BedrockRuntime
14
14
 
15
15
  class ApplyGuardrail
16
16
  def self.build(context)
17
- unless context.config.regional_endpoint
18
- endpoint = context.config.endpoint.to_s
19
- end
20
17
  Aws::BedrockRuntime::EndpointParameters.new(
21
18
  region: context.config.region,
22
19
  use_dual_stack: context.config.use_dualstack_endpoint,
23
20
  use_fips: context.config.use_fips_endpoint,
24
- endpoint: endpoint,
21
+ endpoint: context.config.regional_endpoint ? nil : context.config.endpoint.to_s,
25
22
  )
26
23
  end
27
24
  end
28
25
 
29
26
  class Converse
30
27
  def self.build(context)
31
- unless context.config.regional_endpoint
32
- endpoint = context.config.endpoint.to_s
33
- end
34
28
  Aws::BedrockRuntime::EndpointParameters.new(
35
29
  region: context.config.region,
36
30
  use_dual_stack: context.config.use_dualstack_endpoint,
37
31
  use_fips: context.config.use_fips_endpoint,
38
- endpoint: endpoint,
32
+ endpoint: context.config.regional_endpoint ? nil : context.config.endpoint.to_s,
39
33
  )
40
34
  end
41
35
  end
42
36
 
43
37
  class ConverseStream
44
38
  def self.build(context)
45
- unless context.config.regional_endpoint
46
- endpoint = context.config.endpoint.to_s
47
- end
48
39
  Aws::BedrockRuntime::EndpointParameters.new(
49
40
  region: context.config.region,
50
41
  use_dual_stack: context.config.use_dualstack_endpoint,
51
42
  use_fips: context.config.use_fips_endpoint,
52
- endpoint: endpoint,
43
+ endpoint: context.config.regional_endpoint ? nil : context.config.endpoint.to_s,
53
44
  )
54
45
  end
55
46
  end
56
47
 
57
48
  class InvokeModel
58
49
  def self.build(context)
59
- unless context.config.regional_endpoint
60
- endpoint = context.config.endpoint.to_s
61
- end
62
50
  Aws::BedrockRuntime::EndpointParameters.new(
63
51
  region: context.config.region,
64
52
  use_dual_stack: context.config.use_dualstack_endpoint,
65
53
  use_fips: context.config.use_fips_endpoint,
66
- endpoint: endpoint,
54
+ endpoint: context.config.regional_endpoint ? nil : context.config.endpoint.to_s,
67
55
  )
68
56
  end
69
57
  end
70
58
 
71
59
  class InvokeModelWithResponseStream
72
60
  def self.build(context)
73
- unless context.config.regional_endpoint
74
- endpoint = context.config.endpoint.to_s
75
- end
76
61
  Aws::BedrockRuntime::EndpointParameters.new(
77
62
  region: context.config.region,
78
63
  use_dual_stack: context.config.use_dualstack_endpoint,
79
64
  use_fips: context.config.use_fips_endpoint,
80
- endpoint: endpoint,
65
+ endpoint: context.config.regional_endpoint ? nil : context.config.endpoint.to_s,
81
66
  )
82
67
  end
83
68
  end
@@ -113,6 +113,10 @@ module Aws::BedrockRuntime
113
113
  def message
114
114
  @message || @data[:message]
115
115
  end
116
+
117
+ def retryable?
118
+ true
119
+ end
116
120
  end
117
121
 
118
122
  class ModelStreamErrorException < ServiceError
@@ -15,11 +15,11 @@ module Aws::BedrockRuntime
15
15
  :endpoint_provider,
16
16
  doc_type: 'Aws::BedrockRuntime::EndpointProvider',
17
17
  rbs_type: 'untyped',
18
- docstring: 'The endpoint provider used to resolve endpoints. Any '\
19
- 'object that responds to `#resolve_endpoint(parameters)` '\
20
- 'where `parameters` is a Struct similar to '\
21
- '`Aws::BedrockRuntime::EndpointParameters`'
22
- ) do |cfg|
18
+ docstring: <<~DOCS) do |_cfg|
19
+ The endpoint provider used to resolve endpoints. Any object that responds to
20
+ `#resolve_endpoint(parameters)` where `parameters` is a Struct similar to
21
+ `Aws::BedrockRuntime::EndpointParameters`.
22
+ DOCS
23
23
  Aws::BedrockRuntime::EndpointProvider.new
24
24
  end
25
25
 
@@ -40,11 +40,23 @@ module Aws::BedrockRuntime
40
40
  context[:auth_scheme] =
41
41
  Aws::Endpoints.resolve_auth_scheme(context, endpoint)
42
42
 
43
- @handler.call(context)
43
+ with_metrics(context) { @handler.call(context) }
44
44
  end
45
45
 
46
46
  private
47
47
 
48
+ def with_metrics(context, &block)
49
+ metrics = []
50
+ metrics << 'ENDPOINT_OVERRIDE' unless context.config.regional_endpoint
51
+ if context[:auth_scheme] && context[:auth_scheme]['name'] == 'sigv4a'
52
+ metrics << 'SIGV4A_SIGNING'
53
+ end
54
+ if context.config.credentials&.credentials&.account_id
55
+ metrics << 'RESOLVED_ACCOUNT_ID'
56
+ end
57
+ Aws::Plugins::UserAgent.metric(*metrics, &block)
58
+ end
59
+
48
60
  def apply_endpoint_headers(context, headers)
49
61
  headers.each do |key, values|
50
62
  value = values
@@ -312,26 +312,36 @@ module Aws::BedrockRuntime
312
312
  # @!attribute [rw] model_id
313
313
  # The identifier for the model that you want to call.
314
314
  #
315
- # The `modelId` to provide depends on the type of model that you use:
315
+ # The `modelId` to provide depends on the type of model or throughput
316
+ # that you use:
316
317
  #
317
318
  # * If you use a base model, specify the model ID or its ARN. For a
318
319
  # list of model IDs for base models, see [Amazon Bedrock base model
319
320
  # IDs (on-demand throughput)][1] in the Amazon Bedrock User Guide.
320
321
  #
322
+ # * If you use an inference profile, specify the inference profile ID
323
+ # or its ARN. For a list of inference profile IDs, see [Supported
324
+ # Regions and models for cross-region inference][2] in the Amazon
325
+ # Bedrock User Guide.
326
+ #
321
327
  # * If you use a provisioned model, specify the ARN of the Provisioned
322
328
  # Throughput. For more information, see [Run inference using a
323
- # Provisioned Throughput][2] in the Amazon Bedrock User Guide.
329
+ # Provisioned Throughput][3] in the Amazon Bedrock User Guide.
324
330
  #
325
331
  # * If you use a custom model, first purchase Provisioned Throughput
326
332
  # for it. Then specify the ARN of the resulting provisioned model.
327
333
  # For more information, see [Use a custom model in Amazon
328
- # Bedrock][3] in the Amazon Bedrock User Guide.
334
+ # Bedrock][4] in the Amazon Bedrock User Guide.
335
+ #
336
+ # The Converse API doesn't support [imported models][5].
329
337
  #
330
338
  #
331
339
  #
332
340
  # [1]: https://docs.aws.amazon.com/bedrock/latest/userguide/model-ids.html#model-ids-arns
333
- # [2]: https://docs.aws.amazon.com/bedrock/latest/userguide/prov-thru-use.html
334
- # [3]: https://docs.aws.amazon.com/bedrock/latest/userguide/model-customization-use.html
341
+ # [2]: https://docs.aws.amazon.com/bedrock/latest/userguide/cross-region-inference-support.html
342
+ # [3]: https://docs.aws.amazon.com/bedrock/latest/userguide/prov-thru-use.html
343
+ # [4]: https://docs.aws.amazon.com/bedrock/latest/userguide/model-customization-use.html
344
+ # [5]: https://docs.aws.amazon.com/bedrock/latest/userguide/model-customization-import-model.html
335
345
  # @return [String]
336
346
  #
337
347
  # @!attribute [rw] messages
@@ -498,26 +508,36 @@ module Aws::BedrockRuntime
498
508
  # @!attribute [rw] model_id
499
509
  # The ID for the model.
500
510
  #
501
- # The `modelId` to provide depends on the type of model that you use:
511
+ # The `modelId` to provide depends on the type of model or throughput
512
+ # that you use:
502
513
  #
503
514
  # * If you use a base model, specify the model ID or its ARN. For a
504
515
  # list of model IDs for base models, see [Amazon Bedrock base model
505
516
  # IDs (on-demand throughput)][1] in the Amazon Bedrock User Guide.
506
517
  #
518
+ # * If you use an inference profile, specify the inference profile ID
519
+ # or its ARN. For a list of inference profile IDs, see [Supported
520
+ # Regions and models for cross-region inference][2] in the Amazon
521
+ # Bedrock User Guide.
522
+ #
507
523
  # * If you use a provisioned model, specify the ARN of the Provisioned
508
524
  # Throughput. For more information, see [Run inference using a
509
- # Provisioned Throughput][2] in the Amazon Bedrock User Guide.
525
+ # Provisioned Throughput][3] in the Amazon Bedrock User Guide.
510
526
  #
511
527
  # * If you use a custom model, first purchase Provisioned Throughput
512
528
  # for it. Then specify the ARN of the resulting provisioned model.
513
529
  # For more information, see [Use a custom model in Amazon
514
- # Bedrock][3] in the Amazon Bedrock User Guide.
530
+ # Bedrock][4] in the Amazon Bedrock User Guide.
531
+ #
532
+ # The Converse API doesn't support [imported models][5].
515
533
  #
516
534
  #
517
535
  #
518
536
  # [1]: https://docs.aws.amazon.com/bedrock/latest/userguide/model-ids.html#model-ids-arns
519
- # [2]: https://docs.aws.amazon.com/bedrock/latest/userguide/prov-thru-use.html
520
- # [3]: https://docs.aws.amazon.com/bedrock/latest/userguide/model-customization-use.html
537
+ # [2]: https://docs.aws.amazon.com/bedrock/latest/userguide/cross-region-inference-support.html
538
+ # [3]: https://docs.aws.amazon.com/bedrock/latest/userguide/prov-thru-use.html
539
+ # [4]: https://docs.aws.amazon.com/bedrock/latest/userguide/model-customization-use.html
540
+ # [5]: https://docs.aws.amazon.com/bedrock/latest/userguide/model-customization-import-model.html
521
541
  # @return [String]
522
542
  #
523
543
  # @!attribute [rw] messages
@@ -1399,11 +1419,18 @@ module Aws::BedrockRuntime
1399
1419
  # For more information, see [Use a custom model in Amazon
1400
1420
  # Bedrock][3] in the Amazon Bedrock User Guide.
1401
1421
  #
1422
+ # * If you use an [imported model][4], specify the ARN of the imported
1423
+ # model. You can get the model ARN from a successful call to
1424
+ # [CreateModelImportJob][5] or from the Imported models page in the
1425
+ # Amazon Bedrock console.
1426
+ #
1402
1427
  #
1403
1428
  #
1404
1429
  # [1]: https://docs.aws.amazon.com/bedrock/latest/userguide/model-ids.html#model-ids-arns
1405
1430
  # [2]: https://docs.aws.amazon.com/bedrock/latest/userguide/prov-thru-use.html
1406
1431
  # [3]: https://docs.aws.amazon.com/bedrock/latest/userguide/model-customization-use.html
1432
+ # [4]: https://docs.aws.amazon.com/bedrock/latest/userguide/model-customization-import-model.html
1433
+ # [5]: https://docs.aws.amazon.com/bedrock/latest/APIReference/API_CreateModelImportJob.html
1407
1434
  # @return [String]
1408
1435
  #
1409
1436
  # @!attribute [rw] trace
@@ -1510,11 +1537,18 @@ module Aws::BedrockRuntime
1510
1537
  # For more information, see [Use a custom model in Amazon
1511
1538
  # Bedrock][3] in the Amazon Bedrock User Guide.
1512
1539
  #
1540
+ # * If you use an [imported model][4], specify the ARN of the imported
1541
+ # model. You can get the model ARN from a successful call to
1542
+ # [CreateModelImportJob][5] or from the Imported models page in the
1543
+ # Amazon Bedrock console.
1544
+ #
1513
1545
  #
1514
1546
  #
1515
1547
  # [1]: https://docs.aws.amazon.com/bedrock/latest/userguide/model-ids.html#model-ids-arns
1516
1548
  # [2]: https://docs.aws.amazon.com/bedrock/latest/userguide/prov-thru-use.html
1517
1549
  # [3]: https://docs.aws.amazon.com/bedrock/latest/userguide/model-customization-use.html
1550
+ # [4]: https://docs.aws.amazon.com/bedrock/latest/userguide/model-customization-import-model.html
1551
+ # [5]: https://docs.aws.amazon.com/bedrock/latest/APIReference/API_CreateModelImportJob.html
1518
1552
  # @return [String]
1519
1553
  #
1520
1554
  # @!attribute [rw] trace
@@ -1675,7 +1709,13 @@ module Aws::BedrockRuntime
1675
1709
  end
1676
1710
 
1677
1711
  # The model specified in the request is not ready to serve inference
1678
- # requests.
1712
+ # requests. The AWS SDK will automatically retry the operation up to 5
1713
+ # times. For information about configuring automatic retries, see [Retry
1714
+ # behavior][1] in the *AWS SDKs and Tools* reference guide.
1715
+ #
1716
+ #
1717
+ #
1718
+ # [1]: https://docs.aws.amazon.com/sdkref/latest/guide/feature-retry-behavior.html
1679
1719
  #
1680
1720
  # @!attribute [rw] message
1681
1721
  # @return [String]
@@ -2233,3 +2273,4 @@ module Aws::BedrockRuntime
2233
2273
 
2234
2274
  end
2235
2275
  end
2276
+
@@ -11,18 +11,7 @@
11
11
  require 'aws-sdk-core'
12
12
  require 'aws-sigv4'
13
13
 
14
- require_relative 'aws-sdk-bedrockruntime/types'
15
- require_relative 'aws-sdk-bedrockruntime/client_api'
16
- require_relative 'aws-sdk-bedrockruntime/plugins/endpoints.rb'
17
- require_relative 'aws-sdk-bedrockruntime/client'
18
- require_relative 'aws-sdk-bedrockruntime/errors'
19
- require_relative 'aws-sdk-bedrockruntime/waiters'
20
- require_relative 'aws-sdk-bedrockruntime/resource'
21
- require_relative 'aws-sdk-bedrockruntime/endpoint_parameters'
22
- require_relative 'aws-sdk-bedrockruntime/endpoint_provider'
23
- require_relative 'aws-sdk-bedrockruntime/endpoints'
24
- require_relative 'aws-sdk-bedrockruntime/customizations'
25
- require_relative 'aws-sdk-bedrockruntime/event_streams'
14
+ Aws::Plugins::GlobalConfiguration.add_identifier(:bedrockruntime)
26
15
 
27
16
  # This module provides support for Amazon Bedrock Runtime. This module is available in the
28
17
  # `aws-sdk-bedrockruntime` gem.
@@ -53,7 +42,22 @@ require_relative 'aws-sdk-bedrockruntime/event_streams'
53
42
  #
54
43
  # @!group service
55
44
  module Aws::BedrockRuntime
45
+ autoload :Types, 'aws-sdk-bedrockruntime/types'
46
+ autoload :ClientApi, 'aws-sdk-bedrockruntime/client_api'
47
+ module Plugins
48
+ autoload :Endpoints, 'aws-sdk-bedrockruntime/plugins/endpoints.rb'
49
+ end
50
+ autoload :Client, 'aws-sdk-bedrockruntime/client'
51
+ autoload :Errors, 'aws-sdk-bedrockruntime/errors'
52
+ autoload :Waiters, 'aws-sdk-bedrockruntime/waiters'
53
+ autoload :Resource, 'aws-sdk-bedrockruntime/resource'
54
+ autoload :EndpointParameters, 'aws-sdk-bedrockruntime/endpoint_parameters'
55
+ autoload :EndpointProvider, 'aws-sdk-bedrockruntime/endpoint_provider'
56
+ autoload :Endpoints, 'aws-sdk-bedrockruntime/endpoints'
57
+ autoload :EventStreams, 'aws-sdk-bedrockruntime/event_streams'
56
58
 
57
- GEM_VERSION = '1.17.0'
59
+ GEM_VERSION = '1.25.0'
58
60
 
59
61
  end
62
+
63
+ require_relative 'aws-sdk-bedrockruntime/customizations'
data/sig/client.rbs CHANGED
@@ -15,6 +15,7 @@ module Aws
15
15
  ?credentials: untyped,
16
16
  ?region: String,
17
17
  ?access_key_id: String,
18
+ ?account_id: String,
18
19
  ?active_endpoint_cache: bool,
19
20
  ?adaptive_retry_wait_to_fill: bool,
20
21
  ?client_side_monitoring: bool,
@@ -53,6 +54,7 @@ module Aws
53
54
  ?session_token: String,
54
55
  ?sigv4a_signing_region_set: Array[String],
55
56
  ?stub_responses: untyped,
57
+ ?telemetry_provider: Aws::Telemetry::TelemetryProviderBase,
56
58
  ?token_provider: untyped,
57
59
  ?use_dualstack_endpoint: bool,
58
60
  ?use_fips_endpoint: bool,
data/sig/resource.rbs CHANGED
@@ -15,6 +15,7 @@ module Aws
15
15
  ?credentials: untyped,
16
16
  ?region: String,
17
17
  ?access_key_id: String,
18
+ ?account_id: String,
18
19
  ?active_endpoint_cache: bool,
19
20
  ?adaptive_retry_wait_to_fill: bool,
20
21
  ?client_side_monitoring: bool,
@@ -53,6 +54,7 @@ module Aws
53
54
  ?session_token: String,
54
55
  ?sigv4a_signing_region_set: Array[String],
55
56
  ?stub_responses: untyped,
57
+ ?telemetry_provider: Aws::Telemetry::TelemetryProviderBase,
56
58
  ?token_provider: untyped,
57
59
  ?use_dualstack_endpoint: bool,
58
60
  ?use_fips_endpoint: bool,
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: aws-sdk-bedrockruntime
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.17.0
4
+ version: 1.25.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-07-25 00:00:00.000000000 Z
11
+ date: 2024-09-24 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.201.0
22
+ version: 3.207.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.201.0
32
+ version: 3.207.0
33
33
  - !ruby/object:Gem::Dependency
34
34
  name: aws-sigv4
35
35
  requirement: !ruby/object:Gem::Requirement