Reading from S3 using Amazon Lex

0

Hello

I want to upload different text files to S3 and then be able to ask to a Lex Chatbot about the text in S3, how can I achieve that?

For example: I upload a file that says that I have an appointment today

Then, I ask Lex if I have appointments today, and the chatbot reply 'yes'

ignacio
asked 15 days ago674 views
2 Answers
3

You can accomplish this with the QnAIntent in Amazon Lex. Request access to the models that you will need. (Try the Cohere models for embeddings) https://catalog.us-east-1.prod.workshops.aws/workshops/b5506ec7-e09f-4aab-b50a-c194cfa5a6d7/en-US/prerequisites/request-model-access

Then check out the Conversational FAQ section of this workshop. It goes through how to set it up step by step. https://catalog.us-east-1.prod.workshops.aws/workshops/b5506ec7-e09f-4aab-b50a-c194cfa5a6d7/en-US/create-qna-intent

QnAIntent now also supports Claude3 Sonnet and Haiku in select regions.

profile pictureAWS
answered 15 days ago
  • thank you for your answer Thomas. Its a great solution but im concerned about the pricing. I dont know much of Amazon OpenSearch Serverless, it will be running every hour or just when data is sync?

  • If you use Amazon OpenSearch Serverless it would cost every hour as it never scales down to zero. It is possible to set this up with another database such as Amazon Aurora which can provide a lower cost than OpenSearch for the vector database, however it is a bit more work as there is not easy create option for that at present.

  • You can also check out the "Chat with a single document" feature. With that you don't need to have a vector database. You can specify an S3 URI in a lambda function. https://aws.amazon.com/blogs/machine-learning/knowledge-bases-in-amazon-bedrock-now-simplifies-asking-questions-on-a-single-document/

1

This can be potentially achieved using Bedrock Knowledge Base and Lex Conversational FAQ. Refer this video for a demo and walk through.

Sai
answered 15 days ago
  • but if i build a Bedrock Knowledge Base using Amazon OpenSearch Serverless, Amazon OpenSearch Serverless will charge me every hour or just when the data is sync?

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