Skip to content

This repository contains a collection of Generative AI samples and tuning configurations using Elastic and Langchain

Notifications You must be signed in to change notification settings

justincastilla/RAG-elastic-workshop

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

33 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

aws-generativeai-partner-samples

This repository contains a collection of Generative AI samples and examples using AWS services and AWS partner products.

About this Repository

This repository is subdivided into sections for participating partners. Each partner section has its own subsection of examples. These examples each provide a demonstration of a common service implementation, or infrastructure pattern that could be useful to build your own Generative AI Application

Getting Started

To get started with the code examples, clone the repository and navigate to the relevant partner directory. Refer to the detailed instructions provided in each partner directory's README.

Choose a notebook environment

This workshop is presented as a series of Python notebooks, which you can run from the environment of your choice:

Enable AWS IAM permissions for Bedrock

The AWS identity you assume from your environment (which is the Studio/notebook Execution Role from SageMaker, or could be a role or IAM User for self-managed notebooks or other use-cases), must have sufficient AWS IAM permissions to call the Amazon Bedrock service.

To grant Bedrock access to your identity, you can:

  • Open the AWS IAM Console
  • Find your Role (if using SageMaker or otherwise assuming an IAM Role), or else User
  • Select Add Permissions > Create Inline Policy to attach new inline permissions, open the JSON editor and paste in the below example policy:
{
    "Version": "2012-10-17",
    "Statement": [
        {
            "Sid": "BedrockFullAccess",
            "Effect": "Allow",
            "Action": ["bedrock:*"],
            "Resource": "*"
        }
    ]
}

⚠️ Note: With Amazon SageMaker, your notebook execution role will typically be separate from the user or role that you log in to the AWS Console with. If you'd like to explore the AWS Console for Amazon Bedrock, you'll need to grant permissions to your Console user/role too.

Clone and use the notebooks

ℹ️ Note: In SageMaker Studio, you can open a "System Terminal" to run these commands by clicking File > New > Terminal

Once your notebook environment is set up, clone this workshop repository into it.

git clone https://github.com/aws-samples/aws-generativeai-partner-samples
cd <your partner directory>

If you wish to clone a specific partner directory, please use the below set commands

git clone --depth 1 --no-checkout https://github.com/aws-samples/aws-generativeai-partner-samples
cd aws-generativeai-partner-samples/
git sparse-checkout set <INSERT_DESIRED_SUBDIRECTORY_RELATIVE-PATH>
git checkout

Contributing

We welcome community contributions! Please see CONTRIBUTING for more information.

License

This library is licensed under the MIT-0 License. See the LICENSE file.

About

This repository contains a collection of Generative AI samples and tuning configurations using Elastic and Langchain

Resources

Code of conduct

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Jupyter Notebook 100.0%