error by adding bedrock Knowledgebase to AWS LEX.

0

arn:aws:bedrock:us-east-1:[object Promise]:knowledge-base/LFGADULHAHFL

An error occurred 1 validation error detected: Value at 'qnAIntentConfiguration.dataSourceConfiguration.bedrockKnowledgeStoreConfiguration.bedrockKnowledgeBaseArn' failed to satisfy constraint: Member must satisfy regular expression pattern: ^arn:aws(-[^:]+)?:bedrock:[a-z0-9-]{1,40}:[0-9]{12}:knowledge-base/[A-Za-z0-9]{10}$|^[A-Za-z0-9]{10}$

asked 10 days ago102 views
4 Answers
0

Are you sure you provided the correct arn of the knowledge base in lex? it seems like the arn issue. can you reverify it?

I had used the following youtube video for setup which was highly helpful, you can follow the same https://www.youtube.com/watch?v=4esqnMlMo8I

answered 10 days ago
  • @widpra

    Unfortunately, I cannot manually add the ARN. In Lex, the only way to associate the Bedrock Knowledge Base is by its ID. Specifically, within the Lex Intent under "QnAIntent," there's an option labeled "Knowledge base for Amazon Bedrock Id." After you enter the Knowledge Base ID there, the ARN appears in a grey field below, which means it's automatically populated and non-editable. Since the ARN field is grey, you cannot modify it. The ARN in the grey field shows like this : arn:aws:bedrock:us-east-1:[object Promise]:knowledge-base/HGSLPWJCUL

0

Yes, I'm using the same tutorial. I tried it 2 weeks ago and everything working fine. Tried it again this week and getting [object promise] in ARN. No idea why. I've tried everything to no avail. Super frustrating because when the bad ARN comes up you can't edit the field to fix it.

AWS Please help ASAP

answered 8 days ago
0
answered 6 days ago
0

The issue is that Lex is having trouble retrieving the promise for Associated ARN...To fix this, use your cloud shell to update the id...

Use this format: aws lexv2-models update-intent
--bot-id <your-bot-id>
--bot-version DRAFT
--locale-id <your-locale-id>
--intent-id <your-intent-id>
--intent-name <your-intent-name>
--description "Updated QnA intent with Bedrock KB"
--parent-intent-signature "AMAZON.QnAIntent"
--qn-a-intent-configuration '{ "dataSourceConfiguration": { "bedrockKnowledgeStoreConfiguration": { "bedrockKnowledgeBaseArn": "arn:aws:bedrock:<your-region>:<your-account-id>:knowledge-base/<your-knowledge-base-id>" } }, "bedrockModelConfiguration": { "modelArn": "arn:aws:bedrock:<your-region>::foundation-model/anthropic.claude-3-haiku-20240307-v1:0" } }'

where locale-id is your language id e.g "en_US"

answered 4 days ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions