Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .github/workflows/integration_tests.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
name: Integration Tests

permissions: read-all

on:
workflow_call:
inputs:
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/pull_request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@ name: Build, tests & soundness checks

on: [pull_request, workflow_dispatch]

permissions: read-all

jobs:
swift-bedrock-library:
runs-on: ubuntu-latest
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/swift-6-language-mode.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
name: Swift 6 language mode

permissions: read-all

on:
workflow_call:

Expand Down
6 changes: 3 additions & 3 deletions Package.swift
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,10 @@ let package = Package(
],
dependencies: [
.package(url: "https://github.com/apple/swift-argument-parser.git", from: "1.6.1"),
.package(url: "https://github.com/awslabs/aws-sdk-swift", from: "1.5.16"),
.package(url: "https://github.com/smithy-lang/smithy-swift", from: "0.152.0"),
.package(url: "https://github.com/awslabs/aws-sdk-swift", from: "1.5.51"),
.package(url: "https://github.com/smithy-lang/smithy-swift", from: "0.158.0"),
.package(url: "https://github.com/apple/swift-log.git", from: "1.6.4"),
.package(url: "https://github.com/awslabs/aws-crt-swift", from: "0.52.1"),
.package(url: "https://github.com/awslabs/aws-crt-swift", from: "0.53.0"),
],
targets: [
.target(
Expand Down
17 changes: 17 additions & 0 deletions Sources/Models/Anthropic/AnthropicBedrockModels.swift
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ typealias ClaudeV3_5Sonnet = AnthropicText
typealias ClaudeV3_7Sonnet = AnthropicText
typealias Claude_Sonnet_v4 = AnthropicText
typealias Claude_Opus_v4 = AnthropicText
typealias Claude_Sonnet_v4_5 = AnthropicText

// text
// https://docs.aws.amazon.com/bedrock/latest/userguide/model-parameters-anthropic-claude-messages.html
Expand Down Expand Up @@ -219,4 +220,20 @@ extension BedrockModel {
maxReasoningTokens: Parameter(.maxReasoningTokens, minValue: 1_024, maxValue: 8_191, defaultValue: 4_096)
)
)
public static let claude_sonnet_v4_5: BedrockModel = BedrockModel(
id: "anthropic.claude-sonnet-4-5-20250929-v1:0",
name: "Claude Sonnet v4.5",
modality: Claude_Sonnet_v4_5(
parameters: TextGenerationParameters(
temperature: Parameter(.temperature, minValue: 0, maxValue: 1, defaultValue: 1),
maxTokens: Parameter(.maxTokens, minValue: 1, maxValue: 64_000, defaultValue: 8_192),
topP: Parameter(.topP, minValue: 0, maxValue: 1, defaultValue: 0.999),
topK: Parameter(.topK, minValue: 0, maxValue: 500, defaultValue: 0),
stopSequences: StopSequenceParams(maxSequences: 8191, defaultValue: []),
maxPromptSize: 200_000
),
features: [.textGeneration, .systemPrompts, .document, .vision, .toolUse, .reasoning],
maxReasoningTokens: Parameter(.maxReasoningTokens, minValue: 1_024, maxValue: 8_191, defaultValue: 4_096)
)
)
}
Loading