A Chrome extension that helps you stay focused on your study topics while watching YouTube videos. You can add your study topic name, and the extension uses the GROQ LLM API in the background to check if the video title and description match your study topic. If the video is related, you can watch it; otherwise, the video is blocked to help you avoid distractions.
- Add your study topic to focus on.
- Uses GROQ LLM API to analyze video title and description.
- Blocks videos that do not match your study topic.
- Built with React and Vite.
- Environment variables managed securely using
.envand Vite.
-
Clone the repository.
-
Create a
.envfile in the project root with your GROQ API key:VITE_GROQ_API_KEY=your_groq_api_key_here -
Install dependencies:
npm install
-
Run the development server:
npm run dev
-
Build the extension for production:
npm run build
- Load the unpacked extension in Chrome from the
distfolder after building. - Add your study topic in the extension popup.
- When you navigate to a new YouTube video, the extension checks if the video matches your study topic using the GROQ LLM.
- If the video is unrelated, it will be blocked with a message.
src/content/content.js: Content script that checks video relevance using GROQ API.src/popup/: React components for the extension popup UI..env: Environment variables file (not committed to version control).vite.config.js: Vite configuration.manifest.json: Chrome extension manifest.
- Make sure to keep your
.envfile secure and do not commit it to version control. - The API key is injected at build time by Vite.
MIT License