Skip to content

v1.17.0

Latest

Choose a tag to compare

@sebsto sebsto released this 16 Jun 11:37
b89d5e8

xAI Grok 4.3

Grok 4.3 is now available through the library via the bedrock-mantle endpoint. It works with both the Chat Completions and Responses APIs.

  • xAI Grok 4.3 (.grok_4_3)

Grok 4.3 has a 1M-token context window and is currently only available in us-west-2. Parameter defaults match xAI's published values: temperature=0.7, top_p=0.95, max_completion_tokens=131_072.

let bedrock = try await BedrockService(region: .uswest2)

let reply = try await bedrock.completeChatCompletion(
    "Explain quantum entanglement in two sentences.",
    with: .grok_4_3,
    authentication: .default
)
print(reply.text)

The Responses API works the same way:

let response = try await bedrock.createResponse(
    "What are three benefits of open-source software?",
    with: .grok_4_3,
    authentication: .default
)
print(response.text)

New example

  • Examples/xai-grok/ shows both the Chat Completions and Responses APIs with Grok 4.3.

What's Changed

  • Add xAI Grok 4.3 model support by @sebsto in #93

Full Changelog: v1.16.0...v1.17.0