This project aims to create RockTalk, a ChatGPT-like chatbot webapp using Streamlit for the frontend, LangChain for the logic, and Amazon Bedrock as the backend. The webapp will provide a user-friendly interface for interacting with various Language Models (LLMs) and offer advanced features for customization and data input.
- Contextual chat with session history
- Multiple session management
- Create new sessions
- Switch between existing sessions
- Delete sessions
- Edit previous chat messages within a session
- Customizable LLM settings
- Adjust context window size
- Set number of output tokens
- Support for multiple input types:
- Text input
- PDF documents
- Folder structures
- ZIP files
- Web links / Internet access
- Additional connectors (e.g., databases, APIs)
- Frontend: Streamlit
- Backend: Amazon Bedrock
- Logic/Integration: LangChain
- Set up the development environment
- Create the basic Streamlit interface for RockTalk
- Integrate LangChain with Bedrock backend
- Implement core chat functionality
- Add session management features
- Develop LLM settings customization
- Integrate support for various input types
- Implement advanced features (editing, multiple sessions)
- Optimize performance and user experience
- Test and debug
- Deploy RockTalk webapp
To set up and run RockTalk locally, follow these steps:
- Clone the repository
- (Optional) Create python environment
- `conda create -n rock 'python<3.11'
- Install python requirements
pip install -r requirements.txt
- (Optional) Disable Streamlit telemetry:
- To disable Streamlit's usage statistics collection, run the following command:
- (Optional) Disable Streamlit telemetry:
- To disable Streamlit's usage statistics collection, create or edit the Streamlit configuration file:
- On Linux/macOS:
~/.streamlit/config.toml
- On Windows:
%UserProfile%\.streamlit\config.toml
- On Linux/macOS:
- Add the following line to the file:
[browser] gatherUsageStats = false
- To disable Streamlit's usage statistics collection, create or edit the Streamlit configuration file:
- Configure AWS credentials:
- Set up your AWS credentials for accessing Amazon Bedrock. You can do this by configuring the AWS CLI or setting environment variables.
- Set up environment variables:
- Create a
.env
file in the project root directory. - Add necessary environment variables (e.g., AWS_ACCESS_KEY_ID, AWS_SECRET_ACCESS_KEY, AWS_DEFAULT_REGION).
- Create a
- Run the application:
- Start the Streamlit app by running:
streamlit run app.py
- Start the Streamlit app by running:
- Access the webapp:
- Open your web browser and navigate to
http://localhost:8501
to interact with RockTalk.
- Open your web browser and navigate to
Note: Make sure you have the necessary permissions and budget and access to Amazon Bedrock before running the application.
(Guidelines for contributing to the RockTalk project)