Modules

The SDK is split into focused modules. Add only what you need. Each module has its own dependency footprint.

Core

ModuleWhat it providesDependencies
StrandsAgents Agent, tools, hooks, multi-agent (Graph, Swarm, A2A), session, MCP, @Tool macro, @StructuredOutput macro Foundation only
StrandsAgentsMacros Compiler plugin backing @Tool and @StructuredOutput SwiftSyntax

Model Providers

ModuleWhat it providesDependencies
StrandsBedrockProvider AWS Bedrock ConverseStream (Claude, Titan, Llama, Mistral, and more) aws-sdk-swift
StrandsAnthropicProvider Anthropic Messages API direct integration None
StrandsOpenAIProvider OpenAI Chat Completions; also works with Groq, Together AI, and any compatible endpoint None
StrandsGeminiProvider Google Gemini API None
StrandsMLXProvider On-device LLM inference on Apple Silicon via MLX Swift LM mlx-swift-lm

Voice and Streaming

ModuleWhat it providesDependencies
StrandsBidiStreaming Bidirectional voice agents: OpenAI Realtime, AWS Nova Sonic, Google Gemini Live aws-sdk-swift
StrandsMLXBidiProvider Fully on-device voice pipeline: STT + LLM + TTS on Apple Silicon mlx-audio-swift

Observability

ModuleWhat it providesDependencies
StrandsOTelObservability OpenTelemetry tracing using gen_ai semantic conventions. Exports to Datadog, Jaeger, AWS X-Ray, or any OTLP backend. opentelemetry-swift

Minimal Setups

Cloud agent

Package.swift: Cloud agentSwift
.target(
    name: "MyApp",
    dependencies: [
        .product(name: "StrandsAgents",         package: "strands-agents-swift"),
        .product(name: "StrandsAnthropicProvider", package: "strands-agents-swift"),
    ]
)

Local inference agent

Package.swift: Local agent (Apple Silicon)Swift
.target(
    name: "MyApp",
    dependencies: [
        .product(name: "StrandsAgents",     package: "strands-agents-swift"),
        .product(name: "StrandsMLXProvider", package: "strands-agents-swift"),
    ]
)

Full stack (Bedrock + observability + voice)

Package.swift: Full stackSwift
.target(
    name: "MyApp",
    dependencies: [
        .product(name: "StrandsAgents",          package: "strands-agents-swift"),
        .product(name: "StrandsBedrockProvider",  package: "strands-agents-swift"),
        .product(name: "StrandsOTelObservability",package: "strands-agents-swift"),
        .product(name: "StrandsBidiStreaming",     package: "strands-agents-swift"),
    ]
)