Class: Aws::BedrockRuntime::Types::ContentBlock
- Inherits:
-
Struct
- Object
- Struct
- Aws::BedrockRuntime::Types::ContentBlock
- Defined in:
- gems/aws-sdk-bedrockruntime/lib/aws-sdk-bedrockruntime/types.rb
Overview
ContentBlock is a union - when making an API calls you must set exactly one of the members.
ContentBlock is a union - when returned from an API call exactly one value will be set and the returned type will be a subclass of ContentBlock corresponding to the set member.
A block of content for a message that you pass to, or receive from, a model with the Converse or ConverseStream API operations.
Direct Known Subclasses
CachePoint, CitationsContent, Document, GuardContent, Image, ReasoningContent, Text, ToolResult, ToolUse, Unknown, Video
Defined Under Namespace
Classes: CachePoint, CitationsContent, Document, GuardContent, Image, ReasoningContent, Text, ToolResult, ToolUse, Unknown, Video
Constant Summary collapse
- SENSITIVE =
[:reasoning_content]
Instance Attribute Summary collapse
-
#cache_point ⇒ Types::CachePointBlock
CachePoint to include in the message.
-
#citations_content ⇒ Types::CitationsContentBlock
A content block that contains both generated text and associated citation information, providing traceability between the response and source documents.
-
#document ⇒ Types::DocumentBlock
A document to include in the message.
-
#guard_content ⇒ Types::GuardrailConverseContentBlock
Contains the content to assess with the guardrail.
-
#image ⇒ Types::ImageBlock
Image to include in the message.
-
#reasoning_content ⇒ Types::ReasoningContentBlock
Contains content regarding the reasoning that is carried out by the model.
-
#text ⇒ String
Text to include in the message.
-
#tool_result ⇒ Types::ToolResultBlock
The result for a tool request that a model makes.
-
#tool_use ⇒ Types::ToolUseBlock
Information about a tool use request from a model.
-
#unknown ⇒ Object
Returns the value of attribute unknown.
-
#video ⇒ Types::VideoBlock
Video to include in the message.
Instance Attribute Details
#cache_point ⇒ Types::CachePointBlock
CachePoint to include in the message.
566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 |
# File 'gems/aws-sdk-bedrockruntime/lib/aws-sdk-bedrockruntime/types.rb', line 566 class ContentBlock < Struct.new( :text, :image, :document, :video, :tool_use, :tool_result, :guard_content, :cache_point, :reasoning_content, :citations_content, :unknown) SENSITIVE = [:reasoning_content] include Aws::Structure include Aws::Structure::Union class Text < ContentBlock; end class Image < ContentBlock; end class Document < ContentBlock; end class Video < ContentBlock; end class ToolUse < ContentBlock; end class ToolResult < ContentBlock; end class GuardContent < ContentBlock; end class CachePoint < ContentBlock; end class ReasoningContent < ContentBlock; end class CitationsContent < ContentBlock; end class Unknown < ContentBlock; end end |
#citations_content ⇒ Types::CitationsContentBlock
A content block that contains both generated text and associated citation information, providing traceability between the response and source documents.
566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 |
# File 'gems/aws-sdk-bedrockruntime/lib/aws-sdk-bedrockruntime/types.rb', line 566 class ContentBlock < Struct.new( :text, :image, :document, :video, :tool_use, :tool_result, :guard_content, :cache_point, :reasoning_content, :citations_content, :unknown) SENSITIVE = [:reasoning_content] include Aws::Structure include Aws::Structure::Union class Text < ContentBlock; end class Image < ContentBlock; end class Document < ContentBlock; end class Video < ContentBlock; end class ToolUse < ContentBlock; end class ToolResult < ContentBlock; end class GuardContent < ContentBlock; end class CachePoint < ContentBlock; end class ReasoningContent < ContentBlock; end class CitationsContent < ContentBlock; end class Unknown < ContentBlock; end end |
#document ⇒ Types::DocumentBlock
A document to include in the message.
566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 |
# File 'gems/aws-sdk-bedrockruntime/lib/aws-sdk-bedrockruntime/types.rb', line 566 class ContentBlock < Struct.new( :text, :image, :document, :video, :tool_use, :tool_result, :guard_content, :cache_point, :reasoning_content, :citations_content, :unknown) SENSITIVE = [:reasoning_content] include Aws::Structure include Aws::Structure::Union class Text < ContentBlock; end class Image < ContentBlock; end class Document < ContentBlock; end class Video < ContentBlock; end class ToolUse < ContentBlock; end class ToolResult < ContentBlock; end class GuardContent < ContentBlock; end class CachePoint < ContentBlock; end class ReasoningContent < ContentBlock; end class CitationsContent < ContentBlock; end class Unknown < ContentBlock; end end |
#guard_content ⇒ Types::GuardrailConverseContentBlock
Contains the content to assess with the guardrail. If you don't
specify guardContent
in a call to the Converse API, the guardrail
(if passed in the Converse API) assesses the entire message.
For more information, see Use a guardrail with the Converse API in the Amazon Bedrock User Guide.
566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 |
# File 'gems/aws-sdk-bedrockruntime/lib/aws-sdk-bedrockruntime/types.rb', line 566 class ContentBlock < Struct.new( :text, :image, :document, :video, :tool_use, :tool_result, :guard_content, :cache_point, :reasoning_content, :citations_content, :unknown) SENSITIVE = [:reasoning_content] include Aws::Structure include Aws::Structure::Union class Text < ContentBlock; end class Image < ContentBlock; end class Document < ContentBlock; end class Video < ContentBlock; end class ToolUse < ContentBlock; end class ToolResult < ContentBlock; end class GuardContent < ContentBlock; end class CachePoint < ContentBlock; end class ReasoningContent < ContentBlock; end class CitationsContent < ContentBlock; end class Unknown < ContentBlock; end end |
#image ⇒ Types::ImageBlock
Image to include in the message.
566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 |
# File 'gems/aws-sdk-bedrockruntime/lib/aws-sdk-bedrockruntime/types.rb', line 566 class ContentBlock < Struct.new( :text, :image, :document, :video, :tool_use, :tool_result, :guard_content, :cache_point, :reasoning_content, :citations_content, :unknown) SENSITIVE = [:reasoning_content] include Aws::Structure include Aws::Structure::Union class Text < ContentBlock; end class Image < ContentBlock; end class Document < ContentBlock; end class Video < ContentBlock; end class ToolUse < ContentBlock; end class ToolResult < ContentBlock; end class GuardContent < ContentBlock; end class CachePoint < ContentBlock; end class ReasoningContent < ContentBlock; end class CitationsContent < ContentBlock; end class Unknown < ContentBlock; end end |
#reasoning_content ⇒ Types::ReasoningContentBlock
Contains content regarding the reasoning that is carried out by the model. Reasoning refers to a Chain of Thought (CoT) that the model generates to enhance the accuracy of its final response.
566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 |
# File 'gems/aws-sdk-bedrockruntime/lib/aws-sdk-bedrockruntime/types.rb', line 566 class ContentBlock < Struct.new( :text, :image, :document, :video, :tool_use, :tool_result, :guard_content, :cache_point, :reasoning_content, :citations_content, :unknown) SENSITIVE = [:reasoning_content] include Aws::Structure include Aws::Structure::Union class Text < ContentBlock; end class Image < ContentBlock; end class Document < ContentBlock; end class Video < ContentBlock; end class ToolUse < ContentBlock; end class ToolResult < ContentBlock; end class GuardContent < ContentBlock; end class CachePoint < ContentBlock; end class ReasoningContent < ContentBlock; end class CitationsContent < ContentBlock; end class Unknown < ContentBlock; end end |
#text ⇒ String
Text to include in the message.
566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 |
# File 'gems/aws-sdk-bedrockruntime/lib/aws-sdk-bedrockruntime/types.rb', line 566 class ContentBlock < Struct.new( :text, :image, :document, :video, :tool_use, :tool_result, :guard_content, :cache_point, :reasoning_content, :citations_content, :unknown) SENSITIVE = [:reasoning_content] include Aws::Structure include Aws::Structure::Union class Text < ContentBlock; end class Image < ContentBlock; end class Document < ContentBlock; end class Video < ContentBlock; end class ToolUse < ContentBlock; end class ToolResult < ContentBlock; end class GuardContent < ContentBlock; end class CachePoint < ContentBlock; end class ReasoningContent < ContentBlock; end class CitationsContent < ContentBlock; end class Unknown < ContentBlock; end end |
#tool_result ⇒ Types::ToolResultBlock
The result for a tool request that a model makes.
566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 |
# File 'gems/aws-sdk-bedrockruntime/lib/aws-sdk-bedrockruntime/types.rb', line 566 class ContentBlock < Struct.new( :text, :image, :document, :video, :tool_use, :tool_result, :guard_content, :cache_point, :reasoning_content, :citations_content, :unknown) SENSITIVE = [:reasoning_content] include Aws::Structure include Aws::Structure::Union class Text < ContentBlock; end class Image < ContentBlock; end class Document < ContentBlock; end class Video < ContentBlock; end class ToolUse < ContentBlock; end class ToolResult < ContentBlock; end class GuardContent < ContentBlock; end class CachePoint < ContentBlock; end class ReasoningContent < ContentBlock; end class CitationsContent < ContentBlock; end class Unknown < ContentBlock; end end |
#tool_use ⇒ Types::ToolUseBlock
Information about a tool use request from a model.
566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 |
# File 'gems/aws-sdk-bedrockruntime/lib/aws-sdk-bedrockruntime/types.rb', line 566 class ContentBlock < Struct.new( :text, :image, :document, :video, :tool_use, :tool_result, :guard_content, :cache_point, :reasoning_content, :citations_content, :unknown) SENSITIVE = [:reasoning_content] include Aws::Structure include Aws::Structure::Union class Text < ContentBlock; end class Image < ContentBlock; end class Document < ContentBlock; end class Video < ContentBlock; end class ToolUse < ContentBlock; end class ToolResult < ContentBlock; end class GuardContent < ContentBlock; end class CachePoint < ContentBlock; end class ReasoningContent < ContentBlock; end class CitationsContent < ContentBlock; end class Unknown < ContentBlock; end end |
#unknown ⇒ Object
Returns the value of attribute unknown
566 567 568 |
# File 'gems/aws-sdk-bedrockruntime/lib/aws-sdk-bedrockruntime/types.rb', line 566 def unknown @unknown end |
#video ⇒ Types::VideoBlock
Video to include in the message.
566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 |
# File 'gems/aws-sdk-bedrockruntime/lib/aws-sdk-bedrockruntime/types.rb', line 566 class ContentBlock < Struct.new( :text, :image, :document, :video, :tool_use, :tool_result, :guard_content, :cache_point, :reasoning_content, :citations_content, :unknown) SENSITIVE = [:reasoning_content] include Aws::Structure include Aws::Structure::Union class Text < ContentBlock; end class Image < ContentBlock; end class Document < ContentBlock; end class Video < ContentBlock; end class ToolUse < ContentBlock; end class ToolResult < ContentBlock; end class GuardContent < ContentBlock; end class CachePoint < ContentBlock; end class ReasoningContent < ContentBlock; end class CitationsContent < ContentBlock; end class Unknown < ContentBlock; end end |