Spaces:
Sleeping
Sleeping
Angel
commited on
Commit
Β·
e29b955
1
Parent(s):
852e90b
Update README.md
Browse files
README.md
CHANGED
@@ -1,23 +1,25 @@
|
|
1 |
-
Andrew Huberman RAG-Based AI Chatbot Using YouTube Videos
|
2 |
-
|
|
|
3 |
Xyzbot is an AI chatbot designed to mimic Andrew Huberman by fetching and analyzing YouTube video transcripts from his channel. It automatically retrieves transcripts when new videos are uploaded, updates its knowledge base in ChromaDB, and provides citations linking to the specific video sources. The application is built using Streamlit and deployed in a Docker container.
|
4 |
|
5 |
-
π Features
|
6 |
-
Mimics Andrew Huberman by extracting insights from his YouTube videos
|
7 |
-
Automatically fetches transcripts when new videos are uploaded
|
8 |
-
Stores and updates knowledge base using ChromaDB
|
9 |
-
Uses RAG to generate accurate, citation-linked responses
|
10 |
-
Provides direct links to cited YouTube videos
|
11 |
-
Interactive Streamlit UI for seamless user experience
|
12 |
-
Deployed using Docker for easy scalability and portability
|
13 |
-
|
14 |
-
|
15 |
-
|
16 |
-
|
17 |
-
|
18 |
-
|
19 |
-
|
20 |
-
|
|
|
21 |
π¦ Xyzbot
|
22 |
βββ π Data
|
23 |
βββ π Example
|
@@ -48,60 +50,63 @@ Copy
|
|
48 |
βββ Dockerfile
|
49 |
βββ poetry.lock
|
50 |
βββ pyproject.toml
|
51 |
-
|
52 |
-
|
53 |
-
|
54 |
-
|
55 |
-
|
56 |
-
|
57 |
-
|
58 |
-
|
59 |
-
|
60 |
-
|
61 |
-
|
62 |
-
|
63 |
-
|
64 |
-
|
|
|
|
|
|
|
|
|
|
|
65 |
|
66 |
-
|
67 |
-
|
68 |
-
|
69 |
-
Google Gemini API Key: Sign up for Google Cloud and generate an API key here.
|
70 |
-
YouTube API Key: Get your YouTube API key from the Google Developer Console.
|
71 |
-
Setting Up Your .env File
|
72 |
-
After obtaining the API keys, create a .env file in the root of the project (or use the provided .env template) and add the following lines:
|
73 |
|
74 |
-
bash
|
75 |
-
Copy
|
76 |
-
GOOGLE_API_KEY=your_google_gemini_api_key_here
|
77 |
-
API_KEY=your_youtube_api_key_here
|
78 |
-
Make sure to replace your_google_gemini_api_key_here and your_youtube_api_key_here with the actual keys you obtained.
|
79 |
|
80 |
-
βΆοΈ Running the Application
|
81 |
-
Start the Streamlit app:
|
82 |
-
bash
|
83 |
-
|
84 |
-
|
85 |
-
Open http://localhost:8501
|
86 |
-
|
87 |
-
|
88 |
-
|
89 |
-
|
90 |
-
docker build -t xyzbot:latest .
|
91 |
-
|
92 |
-
|
93 |
-
|
94 |
-
docker run -p 8501:8501 xyzbot:latest
|
95 |
-
|
96 |
-
|
97 |
-
|
98 |
-
|
99 |
-
|
100 |
-
|
101 |
-
|
102 |
-
|
103 |
-
|
|
|
|
|
|
|
104 |
This project is licensed under the MIT License.
|
105 |
|
106 |
-
π€ Contributing
|
107 |
Contributions are welcome! Feel free to open an issue or submit a pull request.
|
|
|
|
|
|
|
|
|
|
1 |
+
# Andrew Huberman RAG-Based AI Chatbot Using YouTube Videos
|
2 |
+
|
3 |
+
## π Overview
|
4 |
Xyzbot is an AI chatbot designed to mimic Andrew Huberman by fetching and analyzing YouTube video transcripts from his channel. It automatically retrieves transcripts when new videos are uploaded, updates its knowledge base in ChromaDB, and provides citations linking to the specific video sources. The application is built using Streamlit and deployed in a Docker container.
|
5 |
|
6 |
+
## π Features
|
7 |
+
- Mimics Andrew Huberman by extracting insights from his YouTube videos
|
8 |
+
- Automatically fetches transcripts when new videos are uploaded
|
9 |
+
- Stores and updates knowledge base using ChromaDB
|
10 |
+
- Uses RAG to generate accurate, citation-linked responses
|
11 |
+
- Provides direct links to cited YouTube videos
|
12 |
+
- Interactive Streamlit UI for seamless user experience
|
13 |
+
- Deployed using Docker for easy scalability and portability
|
14 |
+
|
15 |
+
## π Tech Stack
|
16 |
+
- **Backend**: Python, LangChain, OpenAI API
|
17 |
+
- **Frontend**: Streamlit
|
18 |
+
- **Database**: ChromaDB (Vector Store)
|
19 |
+
- **Deployment**: Docker
|
20 |
+
|
21 |
+
## π Project Structure
|
22 |
+
```
|
23 |
π¦ Xyzbot
|
24 |
βββ π Data
|
25 |
βββ π Example
|
|
|
50 |
βββ Dockerfile
|
51 |
βββ poetry.lock
|
52 |
βββ pyproject.toml
|
53 |
+
```
|
54 |
+
|
55 |
+
## π§ Installation
|
56 |
+
1. Clone the repository:
|
57 |
+
```bash
|
58 |
+
git clone https://github.com/Angel-dash/Xyzbot.git
|
59 |
+
cd Xyzbot
|
60 |
+
```
|
61 |
+
2. Create a virtual environment and install dependencies:
|
62 |
+
```bash
|
63 |
+
python3 -m venv venv
|
64 |
+
source venv/bin/activate # On Windows use `venv\Scripts\activate`
|
65 |
+
pip install -r requirements.txt
|
66 |
+
```
|
67 |
+
## π― API Keys Required
|
68 |
+
To run this project, you'll need to obtain the following API keys:
|
69 |
+
|
70 |
+
- **Google Gemini API Key** (For language processing and AI capabilities)
|
71 |
+
- **YouTube API Key** (For fetching transcripts from YouTube)
|
72 |
|
73 |
+
### How to Get Your API Keys:
|
74 |
+
- **Google Gemini API Key**: [Sign up for Google Cloud and generate an API key here](https://cloud.google.com/docs/authentication/getting-started).
|
75 |
+
- **YouTube API Key**: [Get your YouTube API key from the Google Developer Console](https://console.developers.google.com/).
|
|
|
|
|
|
|
|
|
76 |
|
|
|
|
|
|
|
|
|
|
|
77 |
|
78 |
+
## βΆοΈ Running the Application
|
79 |
+
1. Start the Streamlit app:
|
80 |
+
```bash
|
81 |
+
streamlit run src/main.py
|
82 |
+
```
|
83 |
+
2. Open `http://localhost:8501/` in your browser.
|
84 |
+
|
85 |
+
## π³ Running with Docker
|
86 |
+
1. Build the Docker image:
|
87 |
+
```bash
|
88 |
+
docker build -t xyzbot:latest .
|
89 |
+
```
|
90 |
+
2. Run the container:
|
91 |
+
```bash
|
92 |
+
docker run -p 8501:8501 xyzbot:latest
|
93 |
+
```
|
94 |
+
|
95 |
+
## π Future Enhancements
|
96 |
+
- Improve response generation with fine-tuned LLMs
|
97 |
+
- Enable real-time monitoring of multiple YouTube channels
|
98 |
+
- Enhance citation formatting for better user experience
|
99 |
+
- Provide timestamps for specific content along with the links
|
100 |
+
- AI agent ability to detect greetings and unrelated topics
|
101 |
+
- Improve RAG by using a hybrid method
|
102 |
+
- Implement caching for better performance
|
103 |
+
|
104 |
+
## π License
|
105 |
This project is licensed under the MIT License.
|
106 |
|
107 |
+
## π€ Contributing
|
108 |
Contributions are welcome! Feel free to open an issue or submit a pull request.
|
109 |
+
|
110 |
+
---
|
111 |
+
**Author:** Angel Dash | **GitHub:** [Angel-dash](https://github.com/Angel-dash)
|
112 |
+
|