aws-sdk-bedrockruntime 1.40.0 → 1.42.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: f7a837662b515ba7abb57443b3b4c98f82186b734db6e5d99396765bf2a26cca
4
- data.tar.gz: 171a08d8c626f90efc7294ed39dc3ca3263347ba3537472339e36af911be67c7
3
+ metadata.gz: 5862bdfbd9b0c0e6f73b50e0634bbd28365979915a69acc172ad46da94625bf1
4
+ data.tar.gz: 2a26d1fc84073607038a3b2348e94b8ede6c84123b7c388bdc2b40bd5385751c
5
5
  SHA512:
6
- metadata.gz: 2713518cae3eeadfb1579352be6f767ae60afb640f4e676eaa53cf83ba33c7833da21514ea4ae734f5030f0f671018bbab30c7f042bb8d3b013d3ecdc2212c7b
7
- data.tar.gz: '0483882a91210f48317d326abb28dc949d18dda87830f76c43c85b1e27c3550b766019d8c67c52c92c13977f7196ff5c4cde0057c9e1b76749d2d829a8876cf6'
6
+ metadata.gz: ad0426abbab3f12a405da055f07973a73b65dacdcf843d7e4e1b3bf19a6410bfd4dc5e896921ca718550c7d7675196af9a17dcdd72a0cf20f88660e0795a65a5
7
+ data.tar.gz: 8cce902c4baa88c39f96d7b43bab1c6c2596855953757b8412bf1fa1e8dcc06052fdc85f29ef0afd72a6d3fa58000e8f867869f4bd87d03f2e880b2fafc691f4
data/CHANGELOG.md CHANGED
@@ -1,6 +1,16 @@
1
1
  Unreleased Changes
2
2
  ------------------
3
3
 
4
+ 1.42.0 (2025-03-31)
5
+ ------------------
6
+
7
+ * Feature - Add Prompt Caching support to Converse and ConverseStream APIs
8
+
9
+ 1.41.0 (2025-03-28)
10
+ ------------------
11
+
12
+ * Feature - Launching Multi-modality Content Filter for Amazon Bedrock Guardrails.
13
+
4
14
  1.40.0 (2025-03-05)
5
15
  ------------------
6
16
 
data/VERSION CHANGED
@@ -1 +1 @@
1
- 1.40.0
1
+ 1.42.0
@@ -541,6 +541,7 @@ module Aws::BedrockRuntime
541
541
  # resp.usage.sensitive_information_policy_units #=> Integer
542
542
  # resp.usage.sensitive_information_policy_free_units #=> Integer
543
543
  # resp.usage.contextual_grounding_policy_units #=> Integer
544
+ # resp.usage.content_policy_image_units #=> Integer
544
545
  # resp.action #=> String, one of "NONE", "GUARDRAIL_INTERVENED"
545
546
  # resp.outputs #=> Array
546
547
  # resp.outputs[0].text #=> String
@@ -582,6 +583,7 @@ module Aws::BedrockRuntime
582
583
  # resp.assessments[0].invocation_metrics.usage.sensitive_information_policy_units #=> Integer
583
584
  # resp.assessments[0].invocation_metrics.usage.sensitive_information_policy_free_units #=> Integer
584
585
  # resp.assessments[0].invocation_metrics.usage.contextual_grounding_policy_units #=> Integer
586
+ # resp.assessments[0].invocation_metrics.usage.content_policy_image_units #=> Integer
585
587
  # resp.assessments[0].invocation_metrics.guardrail_coverage.text_characters.guarded #=> Integer
586
588
  # resp.assessments[0].invocation_metrics.guardrail_coverage.text_characters.total #=> Integer
587
589
  # resp.assessments[0].invocation_metrics.guardrail_coverage.images.guarded #=> Integer
@@ -867,6 +869,9 @@ module Aws::BedrockRuntime
867
869
  # },
868
870
  # },
869
871
  # },
872
+ # cache_point: {
873
+ # type: "default", # required, accepts default
874
+ # },
870
875
  # reasoning_content: {
871
876
  # reasoning_text: {
872
877
  # text: "String", # required
@@ -893,6 +898,9 @@ module Aws::BedrockRuntime
893
898
  # },
894
899
  # },
895
900
  # },
901
+ # cache_point: {
902
+ # type: "default", # required, accepts default
903
+ # },
896
904
  # },
897
905
  # ],
898
906
  # inference_config: {
@@ -912,6 +920,9 @@ module Aws::BedrockRuntime
912
920
  # },
913
921
  # },
914
922
  # },
923
+ # cache_point: {
924
+ # type: "default", # required, accepts default
925
+ # },
915
926
  # },
916
927
  # ],
917
928
  # tool_choice: {
@@ -979,6 +990,7 @@ module Aws::BedrockRuntime
979
990
  # resp.output.message.content[0].guard_content.text.qualifiers[0] #=> String, one of "grounding_source", "query", "guard_content"
980
991
  # resp.output.message.content[0].guard_content.image.format #=> String, one of "png", "jpeg"
981
992
  # resp.output.message.content[0].guard_content.image.source.bytes #=> String
993
+ # resp.output.message.content[0].cache_point.type #=> String, one of "default"
982
994
  # resp.output.message.content[0].reasoning_content.reasoning_text.text #=> String
983
995
  # resp.output.message.content[0].reasoning_content.reasoning_text.signature #=> String
984
996
  # resp.output.message.content[0].reasoning_content.redacted_content #=> String
@@ -986,6 +998,8 @@ module Aws::BedrockRuntime
986
998
  # resp.usage.input_tokens #=> Integer
987
999
  # resp.usage.output_tokens #=> Integer
988
1000
  # resp.usage.total_tokens #=> Integer
1001
+ # resp.usage.cache_read_input_tokens #=> Integer
1002
+ # resp.usage.cache_write_input_tokens #=> Integer
989
1003
  # resp.metrics.latency_ms #=> Integer
990
1004
  # resp.trace.guardrail.model_output #=> Array
991
1005
  # resp.trace.guardrail.model_output[0] #=> String
@@ -1027,6 +1041,7 @@ module Aws::BedrockRuntime
1027
1041
  # resp.trace.guardrail.input_assessment["String"].invocation_metrics.usage.sensitive_information_policy_units #=> Integer
1028
1042
  # resp.trace.guardrail.input_assessment["String"].invocation_metrics.usage.sensitive_information_policy_free_units #=> Integer
1029
1043
  # resp.trace.guardrail.input_assessment["String"].invocation_metrics.usage.contextual_grounding_policy_units #=> Integer
1044
+ # resp.trace.guardrail.input_assessment["String"].invocation_metrics.usage.content_policy_image_units #=> Integer
1030
1045
  # resp.trace.guardrail.input_assessment["String"].invocation_metrics.guardrail_coverage.text_characters.guarded #=> Integer
1031
1046
  # resp.trace.guardrail.input_assessment["String"].invocation_metrics.guardrail_coverage.text_characters.total #=> Integer
1032
1047
  # resp.trace.guardrail.input_assessment["String"].invocation_metrics.guardrail_coverage.images.guarded #=> Integer
@@ -1070,6 +1085,7 @@ module Aws::BedrockRuntime
1070
1085
  # resp.trace.guardrail.output_assessments["String"][0].invocation_metrics.usage.sensitive_information_policy_units #=> Integer
1071
1086
  # resp.trace.guardrail.output_assessments["String"][0].invocation_metrics.usage.sensitive_information_policy_free_units #=> Integer
1072
1087
  # resp.trace.guardrail.output_assessments["String"][0].invocation_metrics.usage.contextual_grounding_policy_units #=> Integer
1088
+ # resp.trace.guardrail.output_assessments["String"][0].invocation_metrics.usage.content_policy_image_units #=> Integer
1073
1089
  # resp.trace.guardrail.output_assessments["String"][0].invocation_metrics.guardrail_coverage.text_characters.guarded #=> Integer
1074
1090
  # resp.trace.guardrail.output_assessments["String"][0].invocation_metrics.guardrail_coverage.text_characters.total #=> Integer
1075
1091
  # resp.trace.guardrail.output_assessments["String"][0].invocation_metrics.guardrail_coverage.images.guarded #=> Integer
@@ -1531,6 +1547,9 @@ module Aws::BedrockRuntime
1531
1547
  # },
1532
1548
  # },
1533
1549
  # },
1550
+ # cache_point: {
1551
+ # type: "default", # required, accepts default
1552
+ # },
1534
1553
  # reasoning_content: {
1535
1554
  # reasoning_text: {
1536
1555
  # text: "String", # required
@@ -1557,6 +1576,9 @@ module Aws::BedrockRuntime
1557
1576
  # },
1558
1577
  # },
1559
1578
  # },
1579
+ # cache_point: {
1580
+ # type: "default", # required, accepts default
1581
+ # },
1560
1582
  # },
1561
1583
  # ],
1562
1584
  # inference_config: {
@@ -1576,6 +1598,9 @@ module Aws::BedrockRuntime
1576
1598
  # },
1577
1599
  # },
1578
1600
  # },
1601
+ # cache_point: {
1602
+ # type: "default", # required, accepts default
1603
+ # },
1579
1604
  # },
1580
1605
  # ],
1581
1606
  # tool_choice: {
@@ -1642,6 +1667,8 @@ module Aws::BedrockRuntime
1642
1667
  # event.usage.input_tokens #=> Integer
1643
1668
  # event.usage.output_tokens #=> Integer
1644
1669
  # event.usage.total_tokens #=> Integer
1670
+ # event.usage.cache_read_input_tokens #=> Integer
1671
+ # event.usage.cache_write_input_tokens #=> Integer
1645
1672
  # event.metrics.latency_ms #=> Integer
1646
1673
  # event.trace.guardrail.model_output #=> Array
1647
1674
  # event.trace.guardrail.model_output[0] #=> String
@@ -1683,6 +1710,7 @@ module Aws::BedrockRuntime
1683
1710
  # event.trace.guardrail.input_assessment["String"].invocation_metrics.usage.sensitive_information_policy_units #=> Integer
1684
1711
  # event.trace.guardrail.input_assessment["String"].invocation_metrics.usage.sensitive_information_policy_free_units #=> Integer
1685
1712
  # event.trace.guardrail.input_assessment["String"].invocation_metrics.usage.contextual_grounding_policy_units #=> Integer
1713
+ # event.trace.guardrail.input_assessment["String"].invocation_metrics.usage.content_policy_image_units #=> Integer
1686
1714
  # event.trace.guardrail.input_assessment["String"].invocation_metrics.guardrail_coverage.text_characters.guarded #=> Integer
1687
1715
  # event.trace.guardrail.input_assessment["String"].invocation_metrics.guardrail_coverage.text_characters.total #=> Integer
1688
1716
  # event.trace.guardrail.input_assessment["String"].invocation_metrics.guardrail_coverage.images.guarded #=> Integer
@@ -1726,6 +1754,7 @@ module Aws::BedrockRuntime
1726
1754
  # event.trace.guardrail.output_assessments["String"][0].invocation_metrics.usage.sensitive_information_policy_units #=> Integer
1727
1755
  # event.trace.guardrail.output_assessments["String"][0].invocation_metrics.usage.sensitive_information_policy_free_units #=> Integer
1728
1756
  # event.trace.guardrail.output_assessments["String"][0].invocation_metrics.usage.contextual_grounding_policy_units #=> Integer
1757
+ # event.trace.guardrail.output_assessments["String"][0].invocation_metrics.usage.content_policy_image_units #=> Integer
1729
1758
  # event.trace.guardrail.output_assessments["String"][0].invocation_metrics.guardrail_coverage.text_characters.guarded #=> Integer
1730
1759
  # event.trace.guardrail.output_assessments["String"][0].invocation_metrics.guardrail_coverage.text_characters.total #=> Integer
1731
1760
  # event.trace.guardrail.output_assessments["String"][0].invocation_metrics.guardrail_coverage.images.guarded #=> Integer
@@ -2469,7 +2498,7 @@ module Aws::BedrockRuntime
2469
2498
  tracer: tracer
2470
2499
  )
2471
2500
  context[:gem_name] = 'aws-sdk-bedrockruntime'
2472
- context[:gem_version] = '1.40.0'
2501
+ context[:gem_version] = '1.42.0'
2473
2502
  Seahorse::Client::Request.new(handlers, context)
2474
2503
  end
2475
2504
 
@@ -31,6 +31,8 @@ module Aws::BedrockRuntime
31
31
  AutoToolChoice = Shapes::StructureShape.new(name: 'AutoToolChoice')
32
32
  Blob = Shapes::BlobShape.new(name: 'Blob')
33
33
  Body = Shapes::BlobShape.new(name: 'Body')
34
+ CachePointBlock = Shapes::StructureShape.new(name: 'CachePointBlock')
35
+ CachePointType = Shapes::StringShape.new(name: 'CachePointType')
34
36
  ConflictException = Shapes::StructureShape.new(name: 'ConflictException')
35
37
  ContentBlock = Shapes::UnionShape.new(name: 'ContentBlock')
36
38
  ContentBlockDelta = Shapes::UnionShape.new(name: 'ContentBlockDelta')
@@ -79,6 +81,7 @@ module Aws::BedrockRuntime
79
81
  GuardrailContentFilterType = Shapes::StringShape.new(name: 'GuardrailContentFilterType')
80
82
  GuardrailContentPolicyAction = Shapes::StringShape.new(name: 'GuardrailContentPolicyAction')
81
83
  GuardrailContentPolicyAssessment = Shapes::StructureShape.new(name: 'GuardrailContentPolicyAssessment')
84
+ GuardrailContentPolicyImageUnitsProcessed = Shapes::IntegerShape.new(name: 'GuardrailContentPolicyImageUnitsProcessed')
82
85
  GuardrailContentPolicyUnitsProcessed = Shapes::IntegerShape.new(name: 'GuardrailContentPolicyUnitsProcessed')
83
86
  GuardrailContentQualifier = Shapes::StringShape.new(name: 'GuardrailContentQualifier')
84
87
  GuardrailContentQualifierList = Shapes::ListShape.new(name: 'GuardrailContentQualifierList')
@@ -219,6 +222,8 @@ module Aws::BedrockRuntime
219
222
  ThrottlingException = Shapes::StructureShape.new(name: 'ThrottlingException')
220
223
  Timestamp = Shapes::TimestampShape.new(name: 'Timestamp', timestampFormat: "iso8601")
221
224
  TokenUsage = Shapes::StructureShape.new(name: 'TokenUsage')
225
+ TokenUsageCacheReadInputTokensInteger = Shapes::IntegerShape.new(name: 'TokenUsageCacheReadInputTokensInteger')
226
+ TokenUsageCacheWriteInputTokensInteger = Shapes::IntegerShape.new(name: 'TokenUsageCacheWriteInputTokensInteger')
222
227
  TokenUsageInputTokensInteger = Shapes::IntegerShape.new(name: 'TokenUsageInputTokensInteger')
223
228
  TokenUsageOutputTokensInteger = Shapes::IntegerShape.new(name: 'TokenUsageOutputTokensInteger')
224
229
  TokenUsageTotalTokensInteger = Shapes::IntegerShape.new(name: 'TokenUsageTotalTokensInteger')
@@ -288,6 +293,9 @@ module Aws::BedrockRuntime
288
293
 
289
294
  AutoToolChoice.struct_class = Types::AutoToolChoice
290
295
 
296
+ CachePointBlock.add_member(:type, Shapes::ShapeRef.new(shape: CachePointType, required: true, location_name: "type"))
297
+ CachePointBlock.struct_class = Types::CachePointBlock
298
+
291
299
  ConflictException.add_member(:message, Shapes::ShapeRef.new(shape: NonBlankString, location_name: "message"))
292
300
  ConflictException.struct_class = Types::ConflictException
293
301
 
@@ -298,6 +306,7 @@ module Aws::BedrockRuntime
298
306
  ContentBlock.add_member(:tool_use, Shapes::ShapeRef.new(shape: ToolUseBlock, location_name: "toolUse"))
299
307
  ContentBlock.add_member(:tool_result, Shapes::ShapeRef.new(shape: ToolResultBlock, location_name: "toolResult"))
300
308
  ContentBlock.add_member(:guard_content, Shapes::ShapeRef.new(shape: GuardrailConverseContentBlock, location_name: "guardContent"))
309
+ ContentBlock.add_member(:cache_point, Shapes::ShapeRef.new(shape: CachePointBlock, location_name: "cachePoint"))
301
310
  ContentBlock.add_member(:reasoning_content, Shapes::ShapeRef.new(shape: ReasoningContentBlock, location_name: "reasoningContent"))
302
311
  ContentBlock.add_member(:unknown, Shapes::ShapeRef.new(shape: nil, location_name: 'unknown'))
303
312
  ContentBlock.add_member_subclass(:text, Types::ContentBlock::Text)
@@ -307,6 +316,7 @@ module Aws::BedrockRuntime
307
316
  ContentBlock.add_member_subclass(:tool_use, Types::ContentBlock::ToolUse)
308
317
  ContentBlock.add_member_subclass(:tool_result, Types::ContentBlock::ToolResult)
309
318
  ContentBlock.add_member_subclass(:guard_content, Types::ContentBlock::GuardContent)
319
+ ContentBlock.add_member_subclass(:cache_point, Types::ContentBlock::CachePoint)
310
320
  ContentBlock.add_member_subclass(:reasoning_content, Types::ContentBlock::ReasoningContent)
311
321
  ContentBlock.add_member_subclass(:unknown, Types::ContentBlock::Unknown)
312
322
  ContentBlock.struct_class = Types::ContentBlock
@@ -622,6 +632,7 @@ module Aws::BedrockRuntime
622
632
  GuardrailUsage.add_member(:sensitive_information_policy_units, Shapes::ShapeRef.new(shape: GuardrailSensitiveInformationPolicyUnitsProcessed, required: true, location_name: "sensitiveInformationPolicyUnits"))
623
633
  GuardrailUsage.add_member(:sensitive_information_policy_free_units, Shapes::ShapeRef.new(shape: GuardrailSensitiveInformationPolicyFreeUnitsProcessed, required: true, location_name: "sensitiveInformationPolicyFreeUnits"))
624
634
  GuardrailUsage.add_member(:contextual_grounding_policy_units, Shapes::ShapeRef.new(shape: GuardrailContextualGroundingPolicyUnitsProcessed, required: true, location_name: "contextualGroundingPolicyUnits"))
635
+ GuardrailUsage.add_member(:content_policy_image_units, Shapes::ShapeRef.new(shape: GuardrailContentPolicyImageUnitsProcessed, location_name: "contentPolicyImageUnits"))
625
636
  GuardrailUsage.struct_class = Types::GuardrailUsage
626
637
 
627
638
  GuardrailWordPolicyAssessment.add_member(:custom_words, Shapes::ShapeRef.new(shape: GuardrailCustomWordList, required: true, location_name: "customWords"))
@@ -811,9 +822,11 @@ module Aws::BedrockRuntime
811
822
 
812
823
  SystemContentBlock.add_member(:text, Shapes::ShapeRef.new(shape: NonEmptyString, location_name: "text"))
813
824
  SystemContentBlock.add_member(:guard_content, Shapes::ShapeRef.new(shape: GuardrailConverseContentBlock, location_name: "guardContent"))
825
+ SystemContentBlock.add_member(:cache_point, Shapes::ShapeRef.new(shape: CachePointBlock, location_name: "cachePoint"))
814
826
  SystemContentBlock.add_member(:unknown, Shapes::ShapeRef.new(shape: nil, location_name: 'unknown'))
815
827
  SystemContentBlock.add_member_subclass(:text, Types::SystemContentBlock::Text)
816
828
  SystemContentBlock.add_member_subclass(:guard_content, Types::SystemContentBlock::GuardContent)
829
+ SystemContentBlock.add_member_subclass(:cache_point, Types::SystemContentBlock::CachePoint)
817
830
  SystemContentBlock.add_member_subclass(:unknown, Types::SystemContentBlock::Unknown)
818
831
  SystemContentBlock.struct_class = Types::SystemContentBlock
819
832
 
@@ -831,11 +844,15 @@ module Aws::BedrockRuntime
831
844
  TokenUsage.add_member(:input_tokens, Shapes::ShapeRef.new(shape: TokenUsageInputTokensInteger, required: true, location_name: "inputTokens"))
832
845
  TokenUsage.add_member(:output_tokens, Shapes::ShapeRef.new(shape: TokenUsageOutputTokensInteger, required: true, location_name: "outputTokens"))
833
846
  TokenUsage.add_member(:total_tokens, Shapes::ShapeRef.new(shape: TokenUsageTotalTokensInteger, required: true, location_name: "totalTokens"))
847
+ TokenUsage.add_member(:cache_read_input_tokens, Shapes::ShapeRef.new(shape: TokenUsageCacheReadInputTokensInteger, location_name: "cacheReadInputTokens"))
848
+ TokenUsage.add_member(:cache_write_input_tokens, Shapes::ShapeRef.new(shape: TokenUsageCacheWriteInputTokensInteger, location_name: "cacheWriteInputTokens"))
834
849
  TokenUsage.struct_class = Types::TokenUsage
835
850
 
836
851
  Tool.add_member(:tool_spec, Shapes::ShapeRef.new(shape: ToolSpecification, location_name: "toolSpec"))
852
+ Tool.add_member(:cache_point, Shapes::ShapeRef.new(shape: CachePointBlock, location_name: "cachePoint"))
837
853
  Tool.add_member(:unknown, Shapes::ShapeRef.new(shape: nil, location_name: 'unknown'))
838
854
  Tool.add_member_subclass(:tool_spec, Types::Tool::ToolSpec)
855
+ Tool.add_member_subclass(:cache_point, Types::Tool::CachePoint)
839
856
  Tool.add_member_subclass(:unknown, Types::Tool::Unknown)
840
857
  Tool.struct_class = Types::Tool
841
858
 
@@ -208,6 +208,21 @@ module Aws::BedrockRuntime
208
208
  #
209
209
  class AutoToolChoice < Aws::EmptyStructure; end
210
210
 
211
+ # Defines a section of content to be cached for reuse in subsequent API
212
+ # calls.
213
+ #
214
+ # @!attribute [rw] type
215
+ # Specifies the type of cache point within the CachePointBlock.
216
+ # @return [String]
217
+ #
218
+ # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-runtime-2023-09-30/CachePointBlock AWS API Documentation
219
+ #
220
+ class CachePointBlock < Struct.new(
221
+ :type)
222
+ SENSITIVE = []
223
+ include Aws::Structure
224
+ end
225
+
211
226
  # Error occurred because of a conflict while performing an operation.
212
227
  #
213
228
  # @!attribute [rw] message
@@ -270,6 +285,10 @@ module Aws::BedrockRuntime
270
285
  # the *Amazon Bedrock User Guide*. </p>
271
286
  # @return [Types::GuardrailConverseContentBlock]
272
287
  #
288
+ # @!attribute [rw] cache_point
289
+ # CachePoint to include in the message.
290
+ # @return [Types::CachePointBlock]
291
+ #
273
292
  # @!attribute [rw] reasoning_content
274
293
  # Contains content regarding the reasoning that is carried out by the
275
294
  # model. Reasoning refers to a Chain of Thought (CoT) that the model
@@ -286,6 +305,7 @@ module Aws::BedrockRuntime
286
305
  :tool_use,
287
306
  :tool_result,
288
307
  :guard_content,
308
+ :cache_point,
289
309
  :reasoning_content,
290
310
  :unknown)
291
311
  SENSITIVE = [:reasoning_content]
@@ -299,6 +319,7 @@ module Aws::BedrockRuntime
299
319
  class ToolUse < ContentBlock; end
300
320
  class ToolResult < ContentBlock; end
301
321
  class GuardContent < ContentBlock; end
322
+ class CachePoint < ContentBlock; end
302
323
  class ReasoningContent < ContentBlock; end
303
324
  class Unknown < ContentBlock; end
304
325
  end
@@ -1713,6 +1734,10 @@ module Aws::BedrockRuntime
1713
1734
  # The contextual grounding policy units processed by the guardrail.
1714
1735
  # @return [Integer]
1715
1736
  #
1737
+ # @!attribute [rw] content_policy_image_units
1738
+ # The content policy image units processed by the guardrail.
1739
+ # @return [Integer]
1740
+ #
1716
1741
  # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-runtime-2023-09-30/GuardrailUsage AWS API Documentation
1717
1742
  #
1718
1743
  class GuardrailUsage < Struct.new(
@@ -1721,7 +1746,8 @@ module Aws::BedrockRuntime
1721
1746
  :word_policy_units,
1722
1747
  :sensitive_information_policy_units,
1723
1748
  :sensitive_information_policy_free_units,
1724
- :contextual_grounding_policy_units)
1749
+ :contextual_grounding_policy_units,
1750
+ :content_policy_image_units)
1725
1751
  SENSITIVE = []
1726
1752
  include Aws::Structure
1727
1753
  end
@@ -2693,11 +2719,16 @@ module Aws::BedrockRuntime
2693
2719
  # [2]: https://docs.aws.amazon.com/bedrock/latest/APIReference/API_runtime_ConverseStream.html
2694
2720
  # @return [Types::GuardrailConverseContentBlock]
2695
2721
  #
2722
+ # @!attribute [rw] cache_point
2723
+ # CachePoint to include in the system prompt.
2724
+ # @return [Types::CachePointBlock]
2725
+ #
2696
2726
  # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-runtime-2023-09-30/SystemContentBlock AWS API Documentation
2697
2727
  #
2698
2728
  class SystemContentBlock < Struct.new(
2699
2729
  :text,
2700
2730
  :guard_content,
2731
+ :cache_point,
2701
2732
  :unknown)
2702
2733
  SENSITIVE = []
2703
2734
  include Aws::Structure
@@ -2705,6 +2736,7 @@ module Aws::BedrockRuntime
2705
2736
 
2706
2737
  class Text < SystemContentBlock; end
2707
2738
  class GuardContent < SystemContentBlock; end
2739
+ class CachePoint < SystemContentBlock; end
2708
2740
  class Unknown < SystemContentBlock; end
2709
2741
  end
2710
2742
 
@@ -2761,12 +2793,22 @@ module Aws::BedrockRuntime
2761
2793
  # The total of input tokens and tokens generated by the model.
2762
2794
  # @return [Integer]
2763
2795
  #
2796
+ # @!attribute [rw] cache_read_input_tokens
2797
+ # The number of input tokens read from the cache for the request.
2798
+ # @return [Integer]
2799
+ #
2800
+ # @!attribute [rw] cache_write_input_tokens
2801
+ # The number of input tokens written to the cache for the request.
2802
+ # @return [Integer]
2803
+ #
2764
2804
  # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-runtime-2023-09-30/TokenUsage AWS API Documentation
2765
2805
  #
2766
2806
  class TokenUsage < Struct.new(
2767
2807
  :input_tokens,
2768
2808
  :output_tokens,
2769
- :total_tokens)
2809
+ :total_tokens,
2810
+ :cache_read_input_tokens,
2811
+ :cache_write_input_tokens)
2770
2812
  SENSITIVE = []
2771
2813
  include Aws::Structure
2772
2814
  end
@@ -2785,16 +2827,22 @@ module Aws::BedrockRuntime
2785
2827
  # The specfication for the tool.
2786
2828
  # @return [Types::ToolSpecification]
2787
2829
  #
2830
+ # @!attribute [rw] cache_point
2831
+ # CachePoint to include in the tool configuration.
2832
+ # @return [Types::CachePointBlock]
2833
+ #
2788
2834
  # @see http://docs.aws.amazon.com/goto/WebAPI/bedrock-runtime-2023-09-30/Tool AWS API Documentation
2789
2835
  #
2790
2836
  class Tool < Struct.new(
2791
2837
  :tool_spec,
2838
+ :cache_point,
2792
2839
  :unknown)
2793
2840
  SENSITIVE = []
2794
2841
  include Aws::Structure
2795
2842
  include Aws::Structure::Union
2796
2843
 
2797
2844
  class ToolSpec < Tool; end
2845
+ class CachePoint < Tool; end
2798
2846
  class Unknown < Tool; end
2799
2847
  end
2800
2848
 
@@ -56,7 +56,7 @@ module Aws::BedrockRuntime
56
56
  autoload :Endpoints, 'aws-sdk-bedrockruntime/endpoints'
57
57
  autoload :EventStreams, 'aws-sdk-bedrockruntime/event_streams'
58
58
 
59
- GEM_VERSION = '1.40.0'
59
+ GEM_VERSION = '1.42.0'
60
60
 
61
61
  end
62
62
 
data/sig/client.rbs CHANGED
@@ -204,6 +204,9 @@ module Aws
204
204
  }
205
205
  }?
206
206
  }?,
207
+ cache_point: {
208
+ type: ("default")
209
+ }?,
207
210
  reasoning_content: {
208
211
  reasoning_text: {
209
212
  text: ::String,
@@ -229,6 +232,9 @@ module Aws
229
232
  bytes: ::String?
230
233
  }
231
234
  }?
235
+ }?,
236
+ cache_point: {
237
+ type: ("default")
232
238
  }?
233
239
  },
234
240
  ],
@@ -248,6 +254,9 @@ module Aws
248
254
  json: {
249
255
  }?
250
256
  }
257
+ }?,
258
+ cache_point: {
259
+ type: ("default")
251
260
  }?
252
261
  },
253
262
  ],
@@ -367,6 +376,9 @@ module Aws
367
376
  }
368
377
  }?
369
378
  }?,
379
+ cache_point: {
380
+ type: ("default")
381
+ }?,
370
382
  reasoning_content: {
371
383
  reasoning_text: {
372
384
  text: ::String,
@@ -392,6 +404,9 @@ module Aws
392
404
  bytes: ::String?
393
405
  }
394
406
  }?
407
+ }?,
408
+ cache_point: {
409
+ type: ("default")
395
410
  }?
396
411
  },
397
412
  ],
@@ -411,6 +426,9 @@ module Aws
411
426
  json: {
412
427
  }?
413
428
  }
429
+ }?,
430
+ cache_point: {
431
+ type: ("default")
414
432
  }?
415
433
  },
416
434
  ],
data/sig/types.rbs CHANGED
@@ -67,6 +67,11 @@ module Aws::BedrockRuntime
67
67
  class AutoToolChoice < Aws::EmptyStructure
68
68
  end
69
69
 
70
+ class CachePointBlock
71
+ attr_accessor type: ("default")
72
+ SENSITIVE: []
73
+ end
74
+
70
75
  class ConflictException
71
76
  attr_accessor message: ::String
72
77
  SENSITIVE: []
@@ -80,6 +85,7 @@ module Aws::BedrockRuntime
80
85
  attr_accessor tool_use: Types::ToolUseBlock
81
86
  attr_accessor tool_result: Types::ToolResultBlock
82
87
  attr_accessor guard_content: Types::GuardrailConverseContentBlock
88
+ attr_accessor cache_point: Types::CachePointBlock
83
89
  attr_accessor reasoning_content: Types::ReasoningContentBlock
84
90
  attr_accessor unknown: untyped
85
91
  SENSITIVE: [:reasoning_content]
@@ -98,6 +104,8 @@ module Aws::BedrockRuntime
98
104
  end
99
105
  class GuardContent < ContentBlock
100
106
  end
107
+ class CachePoint < ContentBlock
108
+ end
101
109
  class ReasoningContent < ContentBlock
102
110
  end
103
111
  class Unknown < ContentBlock
@@ -491,6 +499,7 @@ module Aws::BedrockRuntime
491
499
  attr_accessor sensitive_information_policy_units: ::Integer
492
500
  attr_accessor sensitive_information_policy_free_units: ::Integer
493
501
  attr_accessor contextual_grounding_policy_units: ::Integer
502
+ attr_accessor content_policy_image_units: ::Integer
494
503
  SENSITIVE: []
495
504
  end
496
505
 
@@ -739,6 +748,7 @@ module Aws::BedrockRuntime
739
748
  class SystemContentBlock
740
749
  attr_accessor text: ::String
741
750
  attr_accessor guard_content: Types::GuardrailConverseContentBlock
751
+ attr_accessor cache_point: Types::CachePointBlock
742
752
  attr_accessor unknown: untyped
743
753
  SENSITIVE: []
744
754
 
@@ -746,6 +756,8 @@ module Aws::BedrockRuntime
746
756
  end
747
757
  class GuardContent < SystemContentBlock
748
758
  end
759
+ class CachePoint < SystemContentBlock
760
+ end
749
761
  class Unknown < SystemContentBlock
750
762
  end
751
763
  end
@@ -766,16 +778,21 @@ module Aws::BedrockRuntime
766
778
  attr_accessor input_tokens: ::Integer
767
779
  attr_accessor output_tokens: ::Integer
768
780
  attr_accessor total_tokens: ::Integer
781
+ attr_accessor cache_read_input_tokens: ::Integer
782
+ attr_accessor cache_write_input_tokens: ::Integer
769
783
  SENSITIVE: []
770
784
  end
771
785
 
772
786
  class Tool
773
787
  attr_accessor tool_spec: Types::ToolSpecification
788
+ attr_accessor cache_point: Types::CachePointBlock
774
789
  attr_accessor unknown: untyped
775
790
  SENSITIVE: []
776
791
 
777
792
  class ToolSpec < Tool
778
793
  end
794
+ class CachePoint < Tool
795
+ end
779
796
  class Unknown < Tool
780
797
  end
781
798
  end
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.40.0
4
+ version: 1.42.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-03-05 00:00:00.000000000 Z
11
+ date: 2025-03-31 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: aws-sdk-core