This project provides tools to record audio from the microphone, save it as an MP3 file, and transcribe the recorded audio to text.
- Python 3.x
-
Clone the repository:
git clone https://github.com/thomascaneday/notetaker.git cd notetaker -
Install the required libraries using
requirements.txt:pip install -r requirements.txt
-
Run the
record.pyscript to start recording audio:python record.py
-
Press
Enterto stop the recording. The audio will be saved asrecording.wavandrecording.mp3.
-
Run the
transcribe.pyscript to transcribe the recorded audio:python transcribe.py
-
The transcription will be saved in
transcription.txtand printed in the console.
-
Run the
summarize.pyscript to summarize the content of a.txtfile into lecture notes using OpenAI's GPT-4:python summarize.py
-
Ensure you provide the correct file path and OpenAI API key in the script. The summarized lecture notes will be printed in the console.
Contributions are welcome! Please open an issue or submit a pull request for any changes.
Creating a virtual environment (venv) can help manage dependencies and avoid conflicts between packages. Using a virtual environment is generally recommended for Python projects to ensure a clean, isolated environment. Here's how you can create and use a virtual environment:
-
Create a Virtual Environment: Navigate to your project directory and create a virtual environment by running:
python -m venv venv
This creates a
venvdirectory in your project folder that contains a clean Python environment. -
Activate the Virtual Environment:
- On Windows:
venv\Scripts\activate
- On macOS/Linux:
source venv/bin/activate
After activation, your terminal should show the name of the virtual environment (e.g.,
(venv)) at the beginning of the command line prompt. - On Windows:
-
Upgrade
pipandsetuptoolsin the Virtual Environment:pip install --upgrade pip setuptools
-
Install the Required Packages: Now, try installing the packages from your
requirements.txtfile:pip install -r requirements.txt
-
Deactivate the Virtual Environment: When you're done working in the virtual environment, you can deactivate it by running:
deactivate
Using a virtual environment can help avoid issues caused by conflicting dependencies and ensure that your project's dependencies are managed independently from other projects or the system Python installation.