Python library to summarize talks
Project description
talk-summarizer
Python library to summarize talks. Turn a video file into a PDF report with a summary of each section of the talk.
summarize_talk.py - operates on a talk/lecture where there is a video of the speaker and slides.
- uses
ffmpegto extract the audio from the video - uses
whisperto transcribe the audio - uses
OpenCVto identify slide transitions and extract slides - uses
OpenAIto summarize each section
Installation
Install this library using pip:
pip install talk-summarizer
Usage
python talk_summarizer/summarize_talk.py \
--output_dir output \
--video_file video.mp4 \
--no-summarize \
--whisper_model tiny
Development
To contribute to this library, first checkout the code. Then create a new virtual environment:
cd talk-summarizer
python -m venv venv
source venv/bin/activate
Now install the dependencies and test dependencies:
pip install -r requirements.txt
To run the tests:
pytest
Install pre-commit hooks:
pre-commit install
Set API keys
Make sure your OPENAI_API_KEY is set as an environment variable in either your .bashrc or .zshrc file. For example:
export OPENAI_API_KEY=sk-1234...
TODO
- get output directory working (ffmpeg not working with output directory)
- create different tasks like
transcribe(video --> audio, transcript, overall summary). Right nowsummarize_talkworks on a video (video with slides --> audio, slide images, transcript, section summaries, overall summary, report) - add more unit tests
- use
pyproject.tomlinstead ofsetup.py
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file talk-summarizer-0.0.1.tar.gz.
File metadata
- Download URL: talk-summarizer-0.0.1.tar.gz
- Upload date:
- Size: 10.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
5a2bad62c742e83b8853c718f2dfce9f8259e65e3a2befec68e53f611a0e644e
|
|
| MD5 |
0131b62909c8948d1eec9164c2416b70
|
|
| BLAKE2b-256 |
fe8c18ed19b2b26b23eea538613e9c207bd5b0699fb8ba329a5e1a9963c5f8d4
|
File details
Details for the file talk_summarizer-0.0.1-py3-none-any.whl.
File metadata
- Download URL: talk_summarizer-0.0.1-py3-none-any.whl
- Upload date:
- Size: 10.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6101978dd5011f7acb1c39fd8ace2ffffcaf2bf3ace62c222d369f10c3ec4065
|
|
| MD5 |
3eb22ad244085995d72dac38430267c2
|
|
| BLAKE2b-256 |
ff9f55f3ada88bc3e0831c9fcfa238a5333cd6fa69f5707ce98712f1ebd1cb4e
|