Meet ContextCheck: Our Open-Source Framework for LLM & RAG Testing! Check it out on Github!

in Blog

August 08, 2024

Introduction to Amazon Bedrock and Generative AI

Author:




Edwin Lisowski

CSO & Co-Founder


Reading time:




9 minutes


Generative AI has proven to be a disruptive technology with the potential to revolutionize business intelligence, customer service, advertising, and other market-driving factors. However, implementing generative AI into business operations is quite challenging, mostly due to the resource-intensive nature of model development and deployment. [1]

Generative-AI-CTA

In a bid to streamline the model development process, various IT companies have come up with intuitive platforms designed to minimize the workload associated with model development.

For instance, Amazon Web Services (AWS), one of the leading companies offering cloud-based services, has recently released Amazon Bedrock – a transformative service designed to facilitate model building on Amazon’s cloud computing platform.

In this article, we explore what Amazon Bedrock is, along with the various tools and capabilities that promise to make it a leading platform in generative AI model development.

What is Amazon Bedrock?

Amazon Bedrock is a fully managed service by AWS that provides access to leading foundational models through a single endpoint. With Bedrock, you get access to leading foundational models along with a broad set of capabilities that allow you to build, customize, and deploy generative AI applications.

The comprehensive capabilities of Amazon Bedrock allow you to:

  • experiment with some of the leading foundational models on the market
  • customize them privately with your data using retrieval-augmented generation (RAG)
  • fine-tuning techniques, and create managed agents that can execute complex business operations like managing inventory and processing insurance claims…

… all without having to write a single line of code!

Ultimately, Bedrock aims to democratize access to Gen AI technology and simplify the development of generative AI applications. This way, even businesses with limited infrastructures and machine learning expertise can easily utilize various foundational models to build powerful Gen AI applications for their specific business use cases. What’s even more impressive is that businesses don’t need to deal with the hassle of managing the associated infrastructure, thus minimizing operational costs.

The available foundational models on Amazon Bedrock have been trained on massive datasets of high-quality data using cutting-edge techniques. They can also be fine-tuned and customized to specialize in specific tasks. This eliminates the need for organizations to invest a tremendous amount of monetary and human resources to build models from scratch.

Instead, developers and organizations can experiment with various models seamlessly and securely, customize them for various tasks, and integrate them with existing business applications. Organizations can also choose to evolve and reimagine their products, potentially leading to better sales and customer satisfaction.

Read more: Amazon Bedrock: A User’s Guide to benefits and utilization

Generative AI and Amazon Bedrock

Amazon Web Services (AWS) recently announced several generative AI innovations that will allow organizations of all sizes to build new generative AI applications, enhance employee productivity, and ultimately transform their business intelligence initiatives.

Here are some of the most notable capabilities poised to make Bedrock the leading choice for gen AI application development:

Amazon Bedrock custom model import capability

Since it was first launched in April 2023, Amazon Bedrock users have been leveraging the system’s capability to import data and customize publicly available models for domain-specific tasks. By combining the beneficial attributes of the different foundational models and large language models available on Bedrock with their own data, developers can enjoy a compounding intelligence effect. [2]

The added intelligence gained by combining various systems results in more robust Gen AI applications that can cater to a wider range of use cases. Essentially, this is AI’s version of ‘two heads are better than one.’

That said, recent improvements in the latest release of Bedrock provide an easy and secure way for users to add their own custom models to the platform. Essentially, users can now import and access their own custom models as a fully managed service on Bedrock, vastly improving their choices and capabilities when building Gen AI applications.

The system comes with an easy-to-use UI that enables organizations to easily incorporate models into Amazon Bedrock. These can be models customized on Amazon SageMaker, or other third-party tools or cloud services. The models are typically passed through an automated validation process, after which organizations can easily access their custom models just like any other model in Bedrock.

This new capability makes it easier for organizations to choose a suitable combination of Amazon Bedrock foundational models, large language models, and their own custom models through the same API.

Currently, the service is only available in preview and only supports some of the most popular open model architectures like Mistral, FlanT-5, and Llama. However, AWS stated that there are plans for more architectures in the future.

Model evaluation

What models work best for your specific application? This is arguably the most important consideration when building a Gen AI application as models typically have different capabilities, making them uniquely suitable for certain use cases. [3]

By carefully evaluating the models available, organizations can effectively assess, compare, and select the best model for deploying Gen AI applications. This process requires a delicate balance of model performance and accuracy. Up until recently, organizations had to evaluate models individually, making it a laborious and time-consuming endeavor – ultimately leading to slow building and delivery of Gen AI applications.

Amazon Bedrock’s model evaluation feature offers a fast and reliable way for organizations to analyze and compare different models. Ultimately, this reduces the time taken to evaluate models, making it easier to bring new models into the market faster.

Users can utilize the feature by selecting predefined evaluation criteria e.g., accuracy and robustness, and selecting from a wide variety of publicly available datasets or uploading their own prompt libraries. That said, you may need to set up human-based workflows for subjective criteria or content requiring nuanced judgment.

Once the setup process is complete, Bedrock will run an evaluation and generate a report. With this report, users can understand how the model performs across selected criteria, enabling them to select the best models for their use cases.

Amazon Titan Embeddings

The latest release of Amazon Bedrock also features an improved version of the Amazon Titan Image Generator. This Titan version comes with invisible watermarking and the latest version of Amazon Text Embeddings.

This is greatly beneficial to users working in industries like advertising, e-commerce, and entertainment since they can now access the Amazon Titan Image Generator, generate high-quality images from scratch, and edit or enhance existing images at low cost.

Like with most image-generation AI applications on the market, all you need to do is type a text description into a prompt field, and Titan will turn the text into whatever image or style you describe.

What’s even more impressive is that Amazon Titan applies an invisible watermark to all generated images, making it easier to identify AI-generated images. This way AWS is able to promote the transparent, safe, and secure development of AI technology and reduce the spread of disinformation. The model can also check for watermarks, enabling users to determine whether the image was generated by Titan.

The new version of Amazon Titan (Amazon Titan Text Embeddings V2) is optimized for working with Retrieval Augmented Generation (RAG) use cases. This makes it suitable for a wide variety of use cases including information retrieval, personalized recommendations, and question-and-answer chatbots.

RAG is a popular model-customization technique owing to its ability to allow foundational models to connect to additional knowledge resources that they can reference to produce more accurate responses. Unfortunately, these operations are both computationally and resource-intensive.

Read more: RAG vs Fine-Tuning: A Comparative Analysis of LLM Learning Techniques

Amazon Titan Text Embeddings V2 aims to solve this by giving users the option to leverage flexible embedding sizes, thus catering to diverse application needs including high-accuracy synchronous workflows and low-latency mobile deployments. Ultimately, this can retain a huge percentage of the accuracy for RAG use cases and reduce overall storage by up to four times.

Enhanced privacy control

With privacy and content safety remaining a major concern for organizations, any Gen AI application looking to improve its standing across various industries must be implemented in a safe, responsible, and trustworthy way. [4]

Read more: Data Management Strategy: Everything You Wanted to Know

Most of the models available on the market use built-in controls to filter undesirable and harmful content. However, this approach has proven ineffective as it carries the potential to negatively impact the quality of generated content. As such, organizations are looking towards curating models in such a way that doesn’t impact content relevance, aligns with company policies, and adheres to responsible AI principles.

Amazon Bedrock provides a fast and easy way to implement guardrails. Basically, all you have to do is provide a natural language description of the topics you want to keep out within your application’s context.

Users can also configure thresholds to filter generated content across areas like sexualized content, speech, insults, and violence. This is a markup on the already existing features that remove profanity or specific blocked words.

How to get started with Amazon Bedrock

Amazon Bedrock is a product of Amazon Web Services (AWS). As such, you need an AWS account to access Bedrock and start building. On your dashboard, you’ll find options to set up Bedrock and request model access to the specific models you want to enable.

One of the best ways to experiment with Amazon Bedrock is by using the Playground feature. This feature enables you to try different models before deciding on the one to use. For instance, you can use the playground feature to for image, text, and chat Gen AI use cases. You can also create an agent and test it on the console.

Once you have identified your use case, you can proceed with integrating the foundational models into your application without having to deal with the hustle of managing a complex infrastructure.

Final thoughts

Amazon Bedrock provides a revolutionary way to build Gen AI applications. With Amazon Bedrock, users can enjoy access to a wide selection of first and third-party large language models (LLMs) and foundation models from leading companies.

By incorporating beneficial technologies and features in an easy-to-use, a fully managed service, AWS will help businesses develop and scale their applications faster and more efficiently.

References

[1] Sas.com, Generative AI Challenges and Potential Unveiled: How to Achieve a Competitive Advantage, https://www.sas.com/content/dam/SAS/documents/marketing-whitepapers-ebooks/ebooks/en/generative-ai-challenges-and-potential-unveiled-113889.pdf, Accessed on August 7, 2024
[2] Binaryfolks.com, Custom AI Development, https://www.binaryfolks.com/blog/custom-ai-development,Accessed on August 7, 2024
[3] Community.AWS, Choose the Best Foundational Model for Your AI Applications, https://community.aws/content/2fKJW0z9PEIKec94DZwtYigCF7i/choose-the-best-foundational-model-for-your-ai-applications?lang=en,Accessed on August 7, 2024
[4] Axios.com, Generative AI’s privacy problem
https://www.axios.com/2024/03/14/generative-ai-privacy-problem-chatgpt-openai,Accessed on August 7, 2024



Category:


Generative AI