Skip to content

Issue when using Amazon Bedrock #175

Description

@cgrevisse

Hi team,

I'm not sure whether my configuration for Bedrock is correct, which I believe is not fully covered in the documentation/examples.

In <kb>/.openkb/config.yaml, I currently have:

language: en
model: bedrock/eu.anthropic.claude-sonnet-4-6
aws_access_key_id: os.environ/AWS_ACCESS_KEY_ID
aws_secret_access_key: os.environ/AWS_SECRET_ACCESS_KEY
aws_region_name: os.environ/AWS_REGION_NAME
pageindex_threshold: 20

In <kb>/.env, I have:

AWS_ACCESS_KEY_ID=[REDACTED]
AWS_SECRET_ACCESS_KEY=[REDACTED]
AWS_REGION_NAME=eu-central-1
LLM_API_KEY=bedrock-api-key-[REDACTED]

When executing query or chat, I get the following error:

[ERROR] litellm.BadRequestError: BedrockException - {"message":"The model returned the following errors: tool_choice.type: Field required"}

I found an open issue at BerriAI/litellm#27184.

  1. Is my configuration correct? For instance, I'm not sure whether LLM_API_KEY is necessary here, or whether it's enough with the access key/secret access key pair.
  2. Is the error I'm getting indeed a LiteLLM issue, or something that can be fixed in OpenKB?

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workinggood first issueGood for newcomers

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions