aws-samples / amazon-bedrock-workshop

This is a workshop designed for Amazon Bedrock a foundational model service.
https://catalog.us-east-1.prod.workshops.aws/workshops/a4bdb007-5600-4368-81c5-ff5b4154f518/en-US/20-intro
MIT No Attribution
1.39k stars 591 forks source link

AccessDenied in Lab0 when using Titan Embed Model #63

Closed MarcCCreposAWS closed 11 months ago

MarcCCreposAWS commented 11 months ago

I faced an AccessDenied (i.e. "AccessDeniedException") when trying to use Titan Embedding from the Bedrock Workshop Notebook in Lab0 ("00_Intro")

I looked over the recommended ModelID in the AWS Management Console and it used a different modelID for using titan embeddings. (Workshop uses: "amazon.titan-embed-g1-text-02" while Bedrock Management Console recommends: "amazon.titan-embed-text-v1".) By changing the name to the latter, the embedding part of Lab_0 ("00_Intro"), worked fine.

Amazon Bedrock User Guide (https://docs.aws.amazon.com/pdfs/bedrock/latest/userguide/bedrock-ug.pdf#what-is-service - Page 38 ) also recommends the same naming convention as the Management Console.

WithNameAdjustment

WithoutNameAdjustment

ConsoleSample

lauerarnaud commented 11 months ago

@MarcCCreposAWS thanks for feedback. Raised a PR to upgrade to the latest Titan Embeddings models: amazon.titan-embed-text-v1 that went live with Bedrock GA and should this. https://github.com/aws-samples/amazon-bedrock-workshop/pull/81.

lauerarnaud commented 11 months ago

PR merged.