MBAGPT is a chat application that leverages the power of GPT-3.5-turbo to provide conversational responses with access to multiple data sources. It allows users to ask questions and receive answers from different knowledge bases (vectorDBs), such as Alex Hormozi, Warren Buffett and Richard Branson as well as answer general queries with the ChatGPT API as a fallback.
- Chat interface for interacting with the chatbot powered by GPT-3.5-turbo.
- Integration with Hormozi, Buffett and Branson databases for retrieving relevant documents.
- Semantic search functionality to provide informative snippets from the databases.
- Intent classification to route user queries to the appropriate database.
- HTML templates for displaying chat history and messages.
- Persistence of embeddings using the Chroma vector store.
- OpenAI API key integration for authentication.
- Clone the repository:
git clone https://github.com/wombyz/MBAGPT.git
- Install the required dependencies:
pip install -r requirements.txt
- Set up your credentials:
- Sign up on the OpenAI website and obtain an API key.
- Create a new file called "secrets.toml" in the .streamlit folder.
- Set your OpenAI API key (required) and pinecone creds (optional) in the secrets.toml file or as an environment variable.
- Update the code in the app to use the correct method for accessing the API key.
- Run the indexing script to create the vector databases:
python indexing.py
This script will create the Buffet and Branson vector databases by indexing the documents. Make sure to have the necessary PDF documents in the appropriate directories (./docs/buffett/
and ./docs/branson/
) before running the script.
- Run the application:
streamlit run app.py
-
Access the application by navigating to
http://localhost:8501
in your web browser. -
Enter your prompt in the input box and press Enter.
-
The chatbot will process your prompt and provide a response based on the available data sources.
-
The chat history will be displayed on the screen, showing both user and assistant messages.
Contributions are welcome! If you would like to contribute to this project, please follow these steps:
-
Fork the repository.
-
Create a new branch for your feature or bug fix.
-
Implement your changes and ensure that the code passes all tests.
-
Submit a pull request with a detailed description of your changes.
This project is licensed under the MIT License.