Skip to content

Type definitions#

Index > AgentsforBedrockRuntime > Type definitions

Auto-generated documentation for AgentsforBedrockRuntime type annotations stubs module mypy-boto3-bedrock-agent-runtime.

BlobTypeDef#

# BlobTypeDef definition

BlobTypeDef = Union[
    str,
    bytes,
    IO[Any],
    StreamingBody,
]

AccessDeniedExceptionTypeDef#

# AccessDeniedExceptionTypeDef definition

class AccessDeniedExceptionTypeDef(TypedDict):
    message: NotRequired[str],

ParameterTypeDef#

# ParameterTypeDef definition

class ParameterTypeDef(TypedDict):
    name: NotRequired[str],
    type: NotRequired[str],
    value: NotRequired[str],

ActionGroupInvocationOutputTypeDef#

# ActionGroupInvocationOutputTypeDef definition

class ActionGroupInvocationOutputTypeDef(TypedDict):
    text: NotRequired[str],

ApiParameterTypeDef#

# ApiParameterTypeDef definition

class ApiParameterTypeDef(TypedDict):
    name: NotRequired[str],
    type: NotRequired[str],
    value: NotRequired[str],

ContentBodyTypeDef#

# ContentBodyTypeDef definition

class ContentBodyTypeDef(TypedDict):
    body: NotRequired[str],

BadGatewayExceptionTypeDef#

# BadGatewayExceptionTypeDef definition

class BadGatewayExceptionTypeDef(TypedDict):
    message: NotRequired[str],
    resourceName: NotRequired[str],

ConflictExceptionTypeDef#

# ConflictExceptionTypeDef definition

class ConflictExceptionTypeDef(TypedDict):
    message: NotRequired[str],

DependencyFailedExceptionTypeDef#

# DependencyFailedExceptionTypeDef definition

class DependencyFailedExceptionTypeDef(TypedDict):
    message: NotRequired[str],
    resourceName: NotRequired[str],

S3ObjectDocTypeDef#

# S3ObjectDocTypeDef definition

class S3ObjectDocTypeDef(TypedDict):
    uri: str,

PromptTemplateTypeDef#

# PromptTemplateTypeDef definition

class PromptTemplateTypeDef(TypedDict):
    textPromptTemplate: NotRequired[str],

FailureTraceTypeDef#

# FailureTraceTypeDef definition

class FailureTraceTypeDef(TypedDict):
    failureReason: NotRequired[str],
    traceId: NotRequired[str],

FilterAttributeTypeDef#

# FilterAttributeTypeDef definition

class FilterAttributeTypeDef(TypedDict):
    key: str,
    value: Mapping[str, Any],

FinalResponseTypeDef#

# FinalResponseTypeDef definition

class FinalResponseTypeDef(TypedDict):
    text: NotRequired[str],

FunctionParameterTypeDef#

# FunctionParameterTypeDef definition

class FunctionParameterTypeDef(TypedDict):
    name: NotRequired[str],
    type: NotRequired[str],
    value: NotRequired[str],

InferenceConfigurationTypeDef#

# InferenceConfigurationTypeDef definition

class InferenceConfigurationTypeDef(TypedDict):
    maximumLength: NotRequired[int],
    stopSequences: NotRequired[List[str]],
    temperature: NotRequired[float],
    topK: NotRequired[int],
    topP: NotRequired[float],

InternalServerExceptionTypeDef#

# InternalServerExceptionTypeDef definition

class InternalServerExceptionTypeDef(TypedDict):
    message: NotRequired[str],

KnowledgeBaseLookupInputTypeDef#

# KnowledgeBaseLookupInputTypeDef definition

class KnowledgeBaseLookupInputTypeDef(TypedDict):
    knowledgeBaseId: NotRequired[str],
    text: NotRequired[str],

ResponseMetadataTypeDef#

# ResponseMetadataTypeDef definition

class ResponseMetadataTypeDef(TypedDict):
    RequestId: str,
    HTTPStatusCode: int,
    HTTPHeaders: Dict[str, str],
    RetryAttempts: int,
    HostId: NotRequired[str],

KnowledgeBaseQueryTypeDef#

# KnowledgeBaseQueryTypeDef definition

class KnowledgeBaseQueryTypeDef(TypedDict):
    text: str,

KnowledgeBaseVectorSearchConfigurationTypeDef#

# KnowledgeBaseVectorSearchConfigurationTypeDef definition

class KnowledgeBaseVectorSearchConfigurationTypeDef(TypedDict):
    filter: NotRequired[RetrievalFilterTypeDef],  # (1)
    numberOfResults: NotRequired[int],
    overrideSearchType: NotRequired[SearchTypeType],  # (2)
  1. See RetrievalFilterTypeDef
  2. See SearchTypeType

RetrievalResultContentTypeDef#

# RetrievalResultContentTypeDef definition

class RetrievalResultContentTypeDef(TypedDict):
    text: str,

RepromptResponseTypeDef#

# RepromptResponseTypeDef definition

class RepromptResponseTypeDef(TypedDict):
    source: NotRequired[SourceType],  # (1)
    text: NotRequired[str],
  1. See SourceType

RationaleTypeDef#

# RationaleTypeDef definition

class RationaleTypeDef(TypedDict):
    text: NotRequired[str],
    traceId: NotRequired[str],

PaginatorConfigTypeDef#

# PaginatorConfigTypeDef definition

class PaginatorConfigTypeDef(TypedDict):
    MaxItems: NotRequired[int],
    PageSize: NotRequired[int],
    StartingToken: NotRequired[str],

PostProcessingParsedResponseTypeDef#

# PostProcessingParsedResponseTypeDef definition

class PostProcessingParsedResponseTypeDef(TypedDict):
    text: NotRequired[str],

PreProcessingParsedResponseTypeDef#

# PreProcessingParsedResponseTypeDef definition

class PreProcessingParsedResponseTypeDef(TypedDict):
    isValid: NotRequired[bool],
    rationale: NotRequired[str],

ResourceNotFoundExceptionTypeDef#

# ResourceNotFoundExceptionTypeDef definition

class ResourceNotFoundExceptionTypeDef(TypedDict):
    message: NotRequired[str],

ServiceQuotaExceededExceptionTypeDef#

# ServiceQuotaExceededExceptionTypeDef definition

class ServiceQuotaExceededExceptionTypeDef(TypedDict):
    message: NotRequired[str],

ThrottlingExceptionTypeDef#

# ThrottlingExceptionTypeDef definition

class ThrottlingExceptionTypeDef(TypedDict):
    message: NotRequired[str],

ValidationExceptionTypeDef#

# ValidationExceptionTypeDef definition

class ValidationExceptionTypeDef(TypedDict):
    message: NotRequired[str],

RetrievalResultS3LocationTypeDef#

# RetrievalResultS3LocationTypeDef definition

class RetrievalResultS3LocationTypeDef(TypedDict):
    uri: NotRequired[str],

RetrieveAndGenerateInputTypeDef#

# RetrieveAndGenerateInputTypeDef definition

class RetrieveAndGenerateInputTypeDef(TypedDict):
    text: str,

RetrieveAndGenerateOutputTypeDef#

# RetrieveAndGenerateOutputTypeDef definition

class RetrieveAndGenerateOutputTypeDef(TypedDict):
    text: str,

RetrieveAndGenerateSessionConfigurationTypeDef#

# RetrieveAndGenerateSessionConfigurationTypeDef definition

class RetrieveAndGenerateSessionConfigurationTypeDef(TypedDict):
    kmsKeyArn: str,

SpanTypeDef#

# SpanTypeDef definition

class SpanTypeDef(TypedDict):
    end: NotRequired[int],
    start: NotRequired[int],

PropertyParametersTypeDef#

# PropertyParametersTypeDef definition

class PropertyParametersTypeDef(TypedDict):
    properties: NotRequired[List[ParameterTypeDef]],  # (1)
  1. See ParameterTypeDef

RequestBodyTypeDef#

# RequestBodyTypeDef definition

class RequestBodyTypeDef(TypedDict):
    content: NotRequired[Dict[str, List[ParameterTypeDef]]],  # (1)
  1. See ParameterTypeDef

ApiResultTypeDef#

# ApiResultTypeDef definition

class ApiResultTypeDef(TypedDict):
    actionGroup: str,
    apiPath: NotRequired[str],
    httpMethod: NotRequired[str],
    httpStatusCode: NotRequired[int],
    responseBody: NotRequired[Mapping[str, ContentBodyTypeDef]],  # (1)
    responseState: NotRequired[ResponseStateType],  # (2)
  1. See ContentBodyTypeDef
  2. See ResponseStateType

FunctionResultTypeDef#

# FunctionResultTypeDef definition

class FunctionResultTypeDef(TypedDict):
    actionGroup: str,
    function: NotRequired[str],
    responseBody: NotRequired[Mapping[str, ContentBodyTypeDef]],  # (1)
    responseState: NotRequired[ResponseStateType],  # (2)
  1. See ContentBodyTypeDef
  2. See ResponseStateType

ByteContentDocTypeDef#

# ByteContentDocTypeDef definition

class ByteContentDocTypeDef(TypedDict):
    contentType: str,
    data: Union[str, bytes, IO[Any], StreamingBody],
    identifier: str,

ExternalSourcesGenerationConfigurationTypeDef#

# ExternalSourcesGenerationConfigurationTypeDef definition

class ExternalSourcesGenerationConfigurationTypeDef(TypedDict):
    promptTemplate: NotRequired[PromptTemplateTypeDef],  # (1)
  1. See PromptTemplateTypeDef

GenerationConfigurationTypeDef#

# GenerationConfigurationTypeDef definition

class GenerationConfigurationTypeDef(TypedDict):
    promptTemplate: NotRequired[PromptTemplateTypeDef],  # (1)
  1. See PromptTemplateTypeDef

RetrievalFilterTypeDef#

# RetrievalFilterTypeDef definition

class RetrievalFilterTypeDef(TypedDict):
    andAll: NotRequired[Sequence[Dict[str, Any]]],
    equals: NotRequired[FilterAttributeTypeDef],  # (1)
    greaterThan: NotRequired[FilterAttributeTypeDef],  # (1)
    greaterThanOrEquals: NotRequired[FilterAttributeTypeDef],  # (1)
    in: NotRequired[FilterAttributeTypeDef],  # (1)
    lessThan: NotRequired[FilterAttributeTypeDef],  # (1)
    lessThanOrEquals: NotRequired[FilterAttributeTypeDef],  # (1)
    notEquals: NotRequired[FilterAttributeTypeDef],  # (1)
    notIn: NotRequired[FilterAttributeTypeDef],  # (1)
    orAll: NotRequired[Sequence[Dict[str, Any]]],
    startsWith: NotRequired[FilterAttributeTypeDef],  # (1)
  1. See FilterAttributeTypeDef
  2. See FilterAttributeTypeDef
  3. See FilterAttributeTypeDef
  4. See FilterAttributeTypeDef
  5. See FilterAttributeTypeDef
  6. See FilterAttributeTypeDef
  7. See FilterAttributeTypeDef
  8. See FilterAttributeTypeDef
  9. See FilterAttributeTypeDef

FunctionInvocationInputTypeDef#

# FunctionInvocationInputTypeDef definition

class FunctionInvocationInputTypeDef(TypedDict):
    actionGroup: str,
    function: NotRequired[str],
    parameters: NotRequired[List[FunctionParameterTypeDef]],  # (1)
  1. See FunctionParameterTypeDef

ModelInvocationInputTypeDef#

# ModelInvocationInputTypeDef definition

class ModelInvocationInputTypeDef(TypedDict):
    inferenceConfiguration: NotRequired[InferenceConfigurationTypeDef],  # (1)
    overrideLambda: NotRequired[str],
    parserMode: NotRequired[CreationModeType],  # (2)
    promptCreationMode: NotRequired[CreationModeType],  # (2)
    text: NotRequired[str],
    traceId: NotRequired[str],
    type: NotRequired[PromptTypeType],  # (4)
  1. See InferenceConfigurationTypeDef
  2. See CreationModeType
  3. See CreationModeType
  4. See PromptTypeType

KnowledgeBaseRetrievalConfigurationTypeDef#

# KnowledgeBaseRetrievalConfigurationTypeDef definition

class KnowledgeBaseRetrievalConfigurationTypeDef(TypedDict):
    vectorSearchConfiguration: KnowledgeBaseVectorSearchConfigurationTypeDef,  # (1)
  1. See KnowledgeBaseVectorSearchConfigurationTypeDef

PostProcessingModelInvocationOutputTypeDef#

# PostProcessingModelInvocationOutputTypeDef definition

class PostProcessingModelInvocationOutputTypeDef(TypedDict):
    parsedResponse: NotRequired[PostProcessingParsedResponseTypeDef],  # (1)
    traceId: NotRequired[str],
  1. See PostProcessingParsedResponseTypeDef

PreProcessingModelInvocationOutputTypeDef#

# PreProcessingModelInvocationOutputTypeDef definition

class PreProcessingModelInvocationOutputTypeDef(TypedDict):
    parsedResponse: NotRequired[PreProcessingParsedResponseTypeDef],  # (1)
    traceId: NotRequired[str],
  1. See PreProcessingParsedResponseTypeDef

RetrievalResultLocationTypeDef#

# RetrievalResultLocationTypeDef definition

class RetrievalResultLocationTypeDef(TypedDict):
    type: RetrievalResultLocationTypeType,  # (2)
    s3Location: NotRequired[RetrievalResultS3LocationTypeDef],  # (1)
  1. See RetrievalResultS3LocationTypeDef
  2. See RetrievalResultLocationTypeType

TextResponsePartTypeDef#

# TextResponsePartTypeDef definition

class TextResponsePartTypeDef(TypedDict):
    span: NotRequired[SpanTypeDef],  # (1)
    text: NotRequired[str],
  1. See SpanTypeDef

ApiRequestBodyTypeDef#

# ApiRequestBodyTypeDef definition

class ApiRequestBodyTypeDef(TypedDict):
    content: NotRequired[Dict[str, PropertyParametersTypeDef]],  # (1)
  1. See PropertyParametersTypeDef

ActionGroupInvocationInputTypeDef#

# ActionGroupInvocationInputTypeDef definition

class ActionGroupInvocationInputTypeDef(TypedDict):
    actionGroupName: NotRequired[str],
    apiPath: NotRequired[str],
    function: NotRequired[str],
    parameters: NotRequired[List[ParameterTypeDef]],  # (1)
    requestBody: NotRequired[RequestBodyTypeDef],  # (2)
    verb: NotRequired[str],
  1. See ParameterTypeDef
  2. See RequestBodyTypeDef

InvocationResultMemberTypeDef#

# InvocationResultMemberTypeDef definition

class InvocationResultMemberTypeDef(TypedDict):
    apiResult: NotRequired[ApiResultTypeDef],  # (1)
    functionResult: NotRequired[FunctionResultTypeDef],  # (2)
  1. See ApiResultTypeDef
  2. See FunctionResultTypeDef

ExternalSourceTypeDef#

# ExternalSourceTypeDef definition

class ExternalSourceTypeDef(TypedDict):
    sourceType: ExternalSourceTypeType,  # (3)
    byteContent: NotRequired[ByteContentDocTypeDef],  # (1)
    s3Location: NotRequired[S3ObjectDocTypeDef],  # (2)
  1. See ByteContentDocTypeDef
  2. See S3ObjectDocTypeDef
  3. See ExternalSourceTypeType

KnowledgeBaseRetrieveAndGenerateConfigurationTypeDef#

# KnowledgeBaseRetrieveAndGenerateConfigurationTypeDef definition

class KnowledgeBaseRetrieveAndGenerateConfigurationTypeDef(TypedDict):
    knowledgeBaseId: str,
    modelArn: str,
    generationConfiguration: NotRequired[GenerationConfigurationTypeDef],  # (1)
    retrievalConfiguration: NotRequired[KnowledgeBaseRetrievalConfigurationTypeDef],  # (2)
  1. See GenerationConfigurationTypeDef
  2. See KnowledgeBaseRetrievalConfigurationTypeDef

RetrieveRequestRequestTypeDef#

# RetrieveRequestRequestTypeDef definition

class RetrieveRequestRequestTypeDef(TypedDict):
    knowledgeBaseId: str,
    retrievalQuery: KnowledgeBaseQueryTypeDef,  # (1)
    nextToken: NotRequired[str],
    retrievalConfiguration: NotRequired[KnowledgeBaseRetrievalConfigurationTypeDef],  # (2)
  1. See KnowledgeBaseQueryTypeDef
  2. See KnowledgeBaseRetrievalConfigurationTypeDef

RetrieveRequestRetrievePaginateTypeDef#

# RetrieveRequestRetrievePaginateTypeDef definition

class RetrieveRequestRetrievePaginateTypeDef(TypedDict):
    knowledgeBaseId: str,
    retrievalQuery: KnowledgeBaseQueryTypeDef,  # (1)
    retrievalConfiguration: NotRequired[KnowledgeBaseRetrievalConfigurationTypeDef],  # (2)
    PaginationConfig: NotRequired[PaginatorConfigTypeDef],  # (3)
  1. See KnowledgeBaseQueryTypeDef
  2. See KnowledgeBaseRetrievalConfigurationTypeDef
  3. See PaginatorConfigTypeDef

PostProcessingTraceTypeDef#

# PostProcessingTraceTypeDef definition

class PostProcessingTraceTypeDef(TypedDict):
    modelInvocationInput: NotRequired[ModelInvocationInputTypeDef],  # (1)
    modelInvocationOutput: NotRequired[PostProcessingModelInvocationOutputTypeDef],  # (2)
  1. See ModelInvocationInputTypeDef
  2. See PostProcessingModelInvocationOutputTypeDef

PreProcessingTraceTypeDef#

# PreProcessingTraceTypeDef definition

class PreProcessingTraceTypeDef(TypedDict):
    modelInvocationInput: NotRequired[ModelInvocationInputTypeDef],  # (1)
    modelInvocationOutput: NotRequired[PreProcessingModelInvocationOutputTypeDef],  # (2)
  1. See ModelInvocationInputTypeDef
  2. See PreProcessingModelInvocationOutputTypeDef

KnowledgeBaseRetrievalResultTypeDef#

# KnowledgeBaseRetrievalResultTypeDef definition

class KnowledgeBaseRetrievalResultTypeDef(TypedDict):
    content: RetrievalResultContentTypeDef,  # (1)
    location: NotRequired[RetrievalResultLocationTypeDef],  # (2)
    metadata: NotRequired[Dict[str, Dict[str, Any]]],
    score: NotRequired[float],
  1. See RetrievalResultContentTypeDef
  2. See RetrievalResultLocationTypeDef

RetrievedReferenceTypeDef#

# RetrievedReferenceTypeDef definition

class RetrievedReferenceTypeDef(TypedDict):
    content: NotRequired[RetrievalResultContentTypeDef],  # (1)
    location: NotRequired[RetrievalResultLocationTypeDef],  # (2)
    metadata: NotRequired[Dict[str, Dict[str, Any]]],
  1. See RetrievalResultContentTypeDef
  2. See RetrievalResultLocationTypeDef

GeneratedResponsePartTypeDef#

# GeneratedResponsePartTypeDef definition

class GeneratedResponsePartTypeDef(TypedDict):
    textResponsePart: NotRequired[TextResponsePartTypeDef],  # (1)
  1. See TextResponsePartTypeDef

ApiInvocationInputTypeDef#

# ApiInvocationInputTypeDef definition

class ApiInvocationInputTypeDef(TypedDict):
    actionGroup: str,
    apiPath: NotRequired[str],
    httpMethod: NotRequired[str],
    parameters: NotRequired[List[ApiParameterTypeDef]],  # (1)
    requestBody: NotRequired[ApiRequestBodyTypeDef],  # (2)
  1. See ApiParameterTypeDef
  2. See ApiRequestBodyTypeDef

InvocationInputTypeDef#

# InvocationInputTypeDef definition

class InvocationInputTypeDef(TypedDict):
    actionGroupInvocationInput: NotRequired[ActionGroupInvocationInputTypeDef],  # (1)
    invocationType: NotRequired[InvocationTypeType],  # (2)
    knowledgeBaseLookupInput: NotRequired[KnowledgeBaseLookupInputTypeDef],  # (3)
    traceId: NotRequired[str],
  1. See ActionGroupInvocationInputTypeDef
  2. See InvocationTypeType
  3. See KnowledgeBaseLookupInputTypeDef

SessionStateTypeDef#

# SessionStateTypeDef definition

class SessionStateTypeDef(TypedDict):
    invocationId: NotRequired[str],
    promptSessionAttributes: NotRequired[Mapping[str, str]],
    returnControlInvocationResults: NotRequired[Sequence[InvocationResultMemberTypeDef]],  # (1)
    sessionAttributes: NotRequired[Mapping[str, str]],
  1. See InvocationResultMemberTypeDef

ExternalSourcesRetrieveAndGenerateConfigurationTypeDef#

# ExternalSourcesRetrieveAndGenerateConfigurationTypeDef definition

class ExternalSourcesRetrieveAndGenerateConfigurationTypeDef(TypedDict):
    modelArn: str,
    sources: Sequence[ExternalSourceTypeDef],  # (2)
    generationConfiguration: NotRequired[ExternalSourcesGenerationConfigurationTypeDef],  # (1)
  1. See ExternalSourcesGenerationConfigurationTypeDef
  2. See ExternalSourceTypeDef

RetrieveResponseTypeDef#

# RetrieveResponseTypeDef definition

class RetrieveResponseTypeDef(TypedDict):
    nextToken: str,
    retrievalResults: List[KnowledgeBaseRetrievalResultTypeDef],  # (1)
    ResponseMetadata: ResponseMetadataTypeDef,  # (2)
  1. See KnowledgeBaseRetrievalResultTypeDef
  2. See ResponseMetadataTypeDef

KnowledgeBaseLookupOutputTypeDef#

# KnowledgeBaseLookupOutputTypeDef definition

class KnowledgeBaseLookupOutputTypeDef(TypedDict):
    retrievedReferences: NotRequired[List[RetrievedReferenceTypeDef]],  # (1)
  1. See RetrievedReferenceTypeDef

CitationTypeDef#

# CitationTypeDef definition

class CitationTypeDef(TypedDict):
    generatedResponsePart: NotRequired[GeneratedResponsePartTypeDef],  # (1)
    retrievedReferences: NotRequired[List[RetrievedReferenceTypeDef]],  # (2)
  1. See GeneratedResponsePartTypeDef
  2. See RetrievedReferenceTypeDef

InvocationInputMemberTypeDef#

# InvocationInputMemberTypeDef definition

class InvocationInputMemberTypeDef(TypedDict):
    apiInvocationInput: NotRequired[ApiInvocationInputTypeDef],  # (1)
    functionInvocationInput: NotRequired[FunctionInvocationInputTypeDef],  # (2)
  1. See ApiInvocationInputTypeDef
  2. See FunctionInvocationInputTypeDef

InvokeAgentRequestRequestTypeDef#

# InvokeAgentRequestRequestTypeDef definition

class InvokeAgentRequestRequestTypeDef(TypedDict):
    agentAliasId: str,
    agentId: str,
    sessionId: str,
    enableTrace: NotRequired[bool],
    endSession: NotRequired[bool],
    inputText: NotRequired[str],
    sessionState: NotRequired[SessionStateTypeDef],  # (1)
  1. See SessionStateTypeDef

RetrieveAndGenerateConfigurationTypeDef#

# RetrieveAndGenerateConfigurationTypeDef definition

class RetrieveAndGenerateConfigurationTypeDef(TypedDict):
    type: RetrieveAndGenerateTypeType,  # (3)
    externalSourcesConfiguration: NotRequired[ExternalSourcesRetrieveAndGenerateConfigurationTypeDef],  # (1)
    knowledgeBaseConfiguration: NotRequired[KnowledgeBaseRetrieveAndGenerateConfigurationTypeDef],  # (2)
  1. See ExternalSourcesRetrieveAndGenerateConfigurationTypeDef
  2. See KnowledgeBaseRetrieveAndGenerateConfigurationTypeDef
  3. See RetrieveAndGenerateTypeType

ObservationTypeDef#

# ObservationTypeDef definition

class ObservationTypeDef(TypedDict):
    actionGroupInvocationOutput: NotRequired[ActionGroupInvocationOutputTypeDef],  # (1)
    finalResponse: NotRequired[FinalResponseTypeDef],  # (2)
    knowledgeBaseLookupOutput: NotRequired[KnowledgeBaseLookupOutputTypeDef],  # (3)
    repromptResponse: NotRequired[RepromptResponseTypeDef],  # (4)
    traceId: NotRequired[str],
    type: NotRequired[TypeType],  # (5)
  1. See ActionGroupInvocationOutputTypeDef
  2. See FinalResponseTypeDef
  3. See KnowledgeBaseLookupOutputTypeDef
  4. See RepromptResponseTypeDef
  5. See TypeType

AttributionTypeDef#

# AttributionTypeDef definition

class AttributionTypeDef(TypedDict):
    citations: NotRequired[List[CitationTypeDef]],  # (1)
  1. See CitationTypeDef

RetrieveAndGenerateResponseTypeDef#

# RetrieveAndGenerateResponseTypeDef definition

class RetrieveAndGenerateResponseTypeDef(TypedDict):
    citations: List[CitationTypeDef],  # (1)
    output: RetrieveAndGenerateOutputTypeDef,  # (2)
    sessionId: str,
    ResponseMetadata: ResponseMetadataTypeDef,  # (3)
  1. See CitationTypeDef
  2. See RetrieveAndGenerateOutputTypeDef
  3. See ResponseMetadataTypeDef

ReturnControlPayloadTypeDef#

# ReturnControlPayloadTypeDef definition

class ReturnControlPayloadTypeDef(TypedDict):
    invocationId: NotRequired[str],
    invocationInputs: NotRequired[List[InvocationInputMemberTypeDef]],  # (1)
  1. See InvocationInputMemberTypeDef

RetrieveAndGenerateRequestRequestTypeDef#

# RetrieveAndGenerateRequestRequestTypeDef definition

class RetrieveAndGenerateRequestRequestTypeDef(TypedDict):
    input: RetrieveAndGenerateInputTypeDef,  # (1)
    retrieveAndGenerateConfiguration: NotRequired[RetrieveAndGenerateConfigurationTypeDef],  # (2)
    sessionConfiguration: NotRequired[RetrieveAndGenerateSessionConfigurationTypeDef],  # (3)
    sessionId: NotRequired[str],
  1. See RetrieveAndGenerateInputTypeDef
  2. See RetrieveAndGenerateConfigurationTypeDef
  3. See RetrieveAndGenerateSessionConfigurationTypeDef

OrchestrationTraceTypeDef#

# OrchestrationTraceTypeDef definition

class OrchestrationTraceTypeDef(TypedDict):
    invocationInput: NotRequired[InvocationInputTypeDef],  # (1)
    modelInvocationInput: NotRequired[ModelInvocationInputTypeDef],  # (2)
    observation: NotRequired[ObservationTypeDef],  # (3)
    rationale: NotRequired[RationaleTypeDef],  # (4)
  1. See InvocationInputTypeDef
  2. See ModelInvocationInputTypeDef
  3. See ObservationTypeDef
  4. See RationaleTypeDef

PayloadPartTypeDef#

# PayloadPartTypeDef definition

class PayloadPartTypeDef(TypedDict):
    attribution: NotRequired[AttributionTypeDef],  # (1)
    bytes: NotRequired[bytes],
  1. See AttributionTypeDef

TraceTypeDef#

# TraceTypeDef definition

class TraceTypeDef(TypedDict):
    failureTrace: NotRequired[FailureTraceTypeDef],  # (1)
    orchestrationTrace: NotRequired[OrchestrationTraceTypeDef],  # (2)
    postProcessingTrace: NotRequired[PostProcessingTraceTypeDef],  # (3)
    preProcessingTrace: NotRequired[PreProcessingTraceTypeDef],  # (4)
  1. See FailureTraceTypeDef
  2. See OrchestrationTraceTypeDef
  3. See PostProcessingTraceTypeDef
  4. See PreProcessingTraceTypeDef

TracePartTypeDef#

# TracePartTypeDef definition

class TracePartTypeDef(TypedDict):
    agentAliasId: NotRequired[str],
    agentId: NotRequired[str],
    agentVersion: NotRequired[str],
    sessionId: NotRequired[str],
    trace: NotRequired[TraceTypeDef],  # (1)
  1. See TraceTypeDef

ResponseStreamTypeDef#

# ResponseStreamTypeDef definition

class ResponseStreamTypeDef(TypedDict):
    accessDeniedException: NotRequired[AccessDeniedExceptionTypeDef],  # (1)
    badGatewayException: NotRequired[BadGatewayExceptionTypeDef],  # (2)
    chunk: NotRequired[PayloadPartTypeDef],  # (3)
    conflictException: NotRequired[ConflictExceptionTypeDef],  # (4)
    dependencyFailedException: NotRequired[DependencyFailedExceptionTypeDef],  # (5)
    internalServerException: NotRequired[InternalServerExceptionTypeDef],  # (6)
    resourceNotFoundException: NotRequired[ResourceNotFoundExceptionTypeDef],  # (7)
    returnControl: NotRequired[ReturnControlPayloadTypeDef],  # (8)
    serviceQuotaExceededException: NotRequired[ServiceQuotaExceededExceptionTypeDef],  # (9)
    throttlingException: NotRequired[ThrottlingExceptionTypeDef],  # (10)
    trace: NotRequired[TracePartTypeDef],  # (11)
    validationException: NotRequired[ValidationExceptionTypeDef],  # (12)
  1. See AccessDeniedExceptionTypeDef
  2. See BadGatewayExceptionTypeDef
  3. See PayloadPartTypeDef
  4. See ConflictExceptionTypeDef
  5. See DependencyFailedExceptionTypeDef
  6. See InternalServerExceptionTypeDef
  7. See ResourceNotFoundExceptionTypeDef
  8. See ReturnControlPayloadTypeDef
  9. See ServiceQuotaExceededExceptionTypeDef
  10. See ThrottlingExceptionTypeDef
  11. See TracePartTypeDef
  12. See ValidationExceptionTypeDef

InvokeAgentResponseTypeDef#

# InvokeAgentResponseTypeDef definition

class InvokeAgentResponseTypeDef(TypedDict):
    completion: EventStream[ResponseStreamTypeDef],  # (1)
    contentType: str,
    sessionId: str,
    ResponseMetadata: ResponseMetadataTypeDef,  # (2)
  1. See ResponseStreamTypeDef
  2. See ResponseMetadataTypeDef