Bug description
I'm experimenting with embeddings and encountered this error when using Bedrock / Titan embedding models:
software.amazon.awssdk.services.bedrockruntime.model.ValidationException: Malformed input request: 2 schema violations found, please reformat your input and try again. (Service: BedrockRuntime, Status Code: 400, Request ID: 062cc802-99ce-4d2f-99e2-ea9102c091f3)"
I don't get this error when using embeddings with OpenAI or anything else, so it seems to be Bedrock / Titan specific. Sorry I don't have more information - I'm just experimenting and wanted to pass this info on.
Environment
Spring AI version 1.0.0-M1, Java 1.21, no vector store. AWS account with the Titan models enabled.
Bug description I'm experimenting with embeddings and encountered this error when using Bedrock / Titan embedding models: software.amazon.awssdk.services.bedrockruntime.model.ValidationException: Malformed input request: 2 schema violations found, please reformat your input and try again. (Service: BedrockRuntime, Status Code: 400, Request ID: 062cc802-99ce-4d2f-99e2-ea9102c091f3)"
I don't get this error when using embeddings with OpenAI or anything else, so it seems to be Bedrock / Titan specific. Sorry I don't have more information - I'm just experimenting and wanted to pass this info on.
Environment Spring AI version 1.0.0-M1, Java 1.21, no vector store. AWS account with the Titan models enabled.
Steps to reproduce I followed the steps in the documentation here (https://docs.spring.io/spring-ai/reference/api/embeddings/bedrock-titan-embedding.html), though I switched models to amazon.titan-embed-text-v1 and amazon.titan-embed-text-v2:0.
Expected behavior I was expecting a normal API call to Bedrock
Minimal Complete Reproducible example See: https://docs.spring.io/spring-ai/reference/api/embeddings/bedrock-titan-embedding.html, but try models amazon.titan-embed-text-v1 and amazon.titan-embed-text-v2:0.