Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/build-on-aws/amazon-bedrock-custom-langchain-agent
Learn to build custom prompts and tools for LangChain agents
https://github.com/build-on-aws/amazon-bedrock-custom-langchain-agent
ai-agents amazon-bedrock langchain python streamlit
Last synced: 3 months ago
JSON representation
Learn to build custom prompts and tools for LangChain agents
- Host: GitHub
- URL: https://github.com/build-on-aws/amazon-bedrock-custom-langchain-agent
- Owner: build-on-aws
- License: mit-0
- Created: 2023-10-31T16:07:27.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2024-02-08T15:44:19.000Z (12 months ago)
- Last Synced: 2024-02-08T17:06:28.454Z (12 months ago)
- Topics: ai-agents, amazon-bedrock, langchain, python, streamlit
- Language: Python
- Homepage: https://community.aws/posts/amazon-bedrock-custom-langchain-agent
- Size: 17.5 MB
- Stars: 7
- Watchers: 6
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Contributing: CONTRIBUTING.md
- License: LICENSE
- Code of conduct: CODE_OF_CONDUCT.md
Awesome Lists containing this project
README
# Amazon Bedrock Custom LangChain Agent
Create a custom LangChain agent dubbed "Agent AWS" that queries the AWS Well-Architected Framework and deploys Lambda functions, all backed by Amazon Bedrock and housed in a Streamlit chatbot.
## Prerequisites
Before you begin, make sure you have the following:
* AWS Account: You'll need an AWS account with access to Claude via [Amazon Bedrock](https://us-east-1.console.aws.amazon.com/bedrock/home?region=us-east-1#/modelaccess).
* Lambda Role: Create an IAM role with Lambda execution permissions.
* S3 Bucket: Create an S3 bucket to store assets like Python deployment zips for Lambda.
* Python 3.9 or higherExport these in your terminal:
```bash
export LAMBDA_ROLE=arn:aws:iam::ACCOUNT_ID:role/YourLambdaExecutionRole
export S3_BUCKET=your_s3_bucket_name_here
```## Installation
Clone this repository:
```bash
git clone https://github.com/build-on-aws/amazon-bedrock-custom-langchain-agent.git
```Navigate into the project directory:
```bash
cd amazon-bedrock-custom-langchain-agent
```Install the required Python packages:
```bash
pip install -r requirements.txt
```## Usage
Run the Streamlit app:
```bash
streamlit run agent_aws_st.py
```You can also run the agent in the terminal:
```bash
python agent_aws.py
```## Security
See [CONTRIBUTING](CONTRIBUTING.md#security-issue-notifications) for more information.
## License
This library is licensed under the MIT-0 License. See the LICENSE file.