first commit

This commit is contained in:
Beyhan Oğur
2026-04-26 21:52:23 +03:00
commit 880f412e2c
2662 changed files with 866266 additions and 0 deletions

View File

@@ -0,0 +1,153 @@
# AWS Bedrock Batch API Schemas
BedrockBatchJobRequest:
type: object
required:
- roleArn
- inputDataConfig
- outputDataConfig
properties:
modelId:
type: string
description: Model ID for the batch job (optional, can be specified in request)
jobName:
type: string
description: Name for the batch job
roleArn:
type: string
description: IAM role ARN for the job
inputDataConfig:
type: object
properties:
s3InputDataConfig:
type: object
properties:
s3Uri:
type: string
description: S3 URI for input data
outputDataConfig:
type: object
properties:
s3OutputDataConfig:
type: object
properties:
s3Uri:
type: string
description: S3 URI for output data
timeoutDurationInHours:
type: integer
description: Timeout in hours
tags:
type: array
items:
type: object
properties:
key:
type: string
value:
type: string
BedrockBatchJobResponse:
type: object
properties:
jobArn:
type: string
status:
type: string
enum: [Submitted, InProgress, Completed, Failed, Stopping, Stopped, PartiallyCompleted, Expired, Validating, Scheduled]
jobName:
type: string
modelId:
type: string
roleArn:
type: string
inputDataConfig:
type: object
outputDataConfig:
type: object
vpcConfig:
type: object
properties:
securityGroupIds:
type: array
items:
type: string
subnetIds:
type: array
items:
type: string
submitTime:
type: string
format: date-time
lastModifiedTime:
type: string
format: date-time
endTime:
type: string
format: date-time
message:
type: string
clientRequestToken:
type: string
jobExpirationTime:
type: string
format: date-time
timeoutDurationInHours:
type: integer
BedrockBatchListRequest:
type: object
properties:
maxResults:
type: integer
nextToken:
type: string
statusEquals:
type: string
nameContains:
type: string
BedrockBatchListResponse:
type: object
properties:
invocationJobSummaries:
type: array
items:
$ref: '#/BedrockBatchJobSummary'
nextToken:
type: string
BedrockBatchJobSummary:
type: object
properties:
jobArn:
type: string
jobName:
type: string
modelId:
type: string
status:
type: string
submitTime:
type: string
format: date-time
lastModifiedTime:
type: string
format: date-time
endTime:
type: string
format: date-time
message:
type: string
BedrockBatchRetrieveResponse:
description: Uses same structure as BedrockBatchJobResponse
$ref: '#/BedrockBatchJobResponse'
BedrockBatchCancelResponse:
type: object
properties:
jobArn:
type: string
status:
type: string

View File

@@ -0,0 +1,15 @@
# AWS Bedrock Integration Common Types
BedrockError:
type: object
properties:
message:
type: string
type:
type: string
BedrockMessageRole:
type: string
enum:
- user
- assistant

View File

@@ -0,0 +1,367 @@
# AWS Bedrock Converse API Schemas
BedrockConverseRequest:
type: object
properties:
messages:
type: array
items:
$ref: '#/BedrockMessage'
description: Array of messages for the conversation
system:
type: array
items:
$ref: '#/BedrockSystemMessage'
description: System messages/prompts
inferenceConfig:
$ref: '#/BedrockInferenceConfig'
toolConfig:
$ref: '#/BedrockToolConfig'
guardrailConfig:
$ref: '#/BedrockGuardrailConfig'
additionalModelRequestFields:
type: object
description: Model-specific parameters
additionalModelResponseFieldPaths:
type: array
items:
type: string
performanceConfig:
$ref: '#/BedrockPerformanceConfig'
promptVariables:
type: object
additionalProperties:
$ref: '#/BedrockPromptVariable'
requestMetadata:
type: object
additionalProperties:
type: string
serviceTier:
$ref: '#/BedrockServiceTier'
# Bifrost-specific
fallbacks:
type: array
items:
type: string
BedrockMessage:
type: object
required:
- role
- content
properties:
role:
$ref: './common.yaml#/BedrockMessageRole'
content:
type: array
items:
$ref: '#/BedrockContentBlock'
BedrockSystemMessage:
type: object
properties:
text:
type: string
guardContent:
$ref: '#/BedrockGuardContent'
cachePoint:
$ref: '#/BedrockCachePoint'
BedrockContentBlock:
type: object
properties:
text:
type: string
image:
$ref: '#/BedrockImageSource'
document:
$ref: '#/BedrockDocumentSource'
toolUse:
$ref: '#/BedrockToolUse'
toolResult:
$ref: '#/BedrockToolResult'
guardContent:
$ref: '#/BedrockGuardContent'
reasoningContent:
$ref: '#/BedrockReasoningContent'
json:
type: object
description: JSON content for tool call results
cachePoint:
$ref: '#/BedrockCachePoint'
BedrockImageSource:
type: object
properties:
format:
type: string
enum: [jpeg, png, gif, webp]
source:
type: object
properties:
bytes:
type: string
format: byte
BedrockDocumentSource:
type: object
properties:
format:
type: string
enum: [pdf, csv, doc, docx, xls, xlsx, html, txt, md]
name:
type: string
source:
type: object
properties:
bytes:
type: string
format: byte
text:
type: string
description: Plain text content (for text-based documents)
BedrockToolUse:
type: object
properties:
toolUseId:
type: string
name:
type: string
input:
type: object
BedrockToolResult:
type: object
properties:
toolUseId:
type: string
content:
type: array
items:
$ref: '#/BedrockContentBlock'
status:
type: string
enum: [success, error]
BedrockGuardContent:
type: object
properties:
text:
type: object
properties:
text:
type: string
qualifiers:
type: array
items:
type: string
BedrockReasoningContent:
type: object
properties:
reasoningText:
type: object
properties:
text:
type: string
signature:
type: string
BedrockCachePoint:
type: object
properties:
type:
type: string
enum: [default]
BedrockInferenceConfig:
type: object
properties:
maxTokens:
type: integer
temperature:
type: number
topP:
type: number
stopSequences:
type: array
items:
type: string
BedrockToolConfig:
type: object
properties:
tools:
type: array
items:
$ref: '#/BedrockTool'
toolChoice:
$ref: '#/BedrockToolChoice'
BedrockTool:
type: object
properties:
toolSpec:
type: object
properties:
name:
type: string
description:
type: string
inputSchema:
type: object
properties:
json:
type: object
cachePoint:
$ref: '#/BedrockCachePoint'
BedrockToolChoice:
type: object
properties:
auto:
type: object
any:
type: object
tool:
type: object
properties:
name:
type: string
BedrockGuardrailConfig:
type: object
properties:
guardrailIdentifier:
type: string
guardrailVersion:
type: string
trace:
type: string
enum: [enabled, disabled]
BedrockPerformanceConfig:
type: object
properties:
latency:
type: string
enum: [standard, optimized]
BedrockPromptVariable:
type: object
properties:
text:
type: string
BedrockServiceTier:
type: object
properties:
type:
type: string
enum: [reserved, priority, default, flex]
# Response types
BedrockConverseResponse:
type: object
properties:
output:
type: object
properties:
message:
$ref: '#/BedrockMessage'
stopReason:
type: string
enum: [end_turn, tool_use, max_tokens, stop_sequence, guardrail_intervened, content_filtered]
usage:
$ref: '#/BedrockUsage'
metrics:
type: object
properties:
latencyMs:
type: integer
additionalModelResponseFields:
type: object
trace:
type: object
performanceConfig:
$ref: '#/BedrockPerformanceConfig'
serviceTier:
$ref: '#/BedrockServiceTier'
BedrockUsage:
type: object
properties:
inputTokens:
type: integer
outputTokens:
type: integer
totalTokens:
type: integer
cacheReadInputTokens:
type: integer
cacheWriteInputTokens:
type: integer
# Stream event types
BedrockStreamEvent:
type: object
description: Flat structure for streaming events matching actual Bedrock API response
properties:
role:
type: string
description: For messageStart events
contentBlockIndex:
type: integer
description: For content block events
delta:
$ref: '#/BedrockContentBlockDelta'
stopReason:
type: string
description: For messageStop events
start:
$ref: '#/BedrockContentBlockStart'
usage:
$ref: '#/BedrockUsage'
metrics:
type: object
properties:
latencyMs:
type: integer
trace:
type: object
additionalModelResponseFields:
type: object
invokeModelRawChunk:
type: string
format: byte
description: Raw bytes for legacy invoke stream
BedrockContentBlockDelta:
type: object
properties:
text:
type: string
reasoningContent:
type: object
properties:
text:
type: string
signature:
type: string
toolUse:
type: object
properties:
input:
type: string
BedrockContentBlockStart:
type: object
properties:
toolUse:
type: object
properties:
toolUseId:
type: string
name:
type: string

View File

@@ -0,0 +1,50 @@
# AWS Bedrock Invoke API Schemas (Legacy/Raw Model Invocation)
BedrockInvokeRequest:
type: object
description: |
Raw model invocation request. The body format depends on the model provider.
For Anthropic models, use Anthropic format. For other models, use their native format.
properties:
prompt:
type: string
description: Text prompt to complete
max_tokens:
type: integer
max_tokens_to_sample:
type: integer
description: Anthropic-style max tokens
temperature:
type: number
top_p:
type: number
top_k:
type: integer
stop:
type: array
items:
type: string
stop_sequences:
type: array
items:
type: string
description: Anthropic-style stop sequences
messages:
type: array
items:
type: object
description: For Claude 3 models
system:
description: System prompt (string or array of strings)
oneOf:
- type: string
- type: array
items:
type: string
anthropic_version:
type: string
BedrockInvokeResponse:
type: object
description: Raw model response. Format depends on the model provider.
additionalProperties: true