Skip to main content

Extract audio from YouTube videos or local audio files and convert it into text.

Project description

youtube_to_text

yt2t is a command-line tool and extracts audio from YouTube video urls or a local audio file and converts it into text. It supports multiple languages and can optionally ignore YouTube transcripts.

Features

  • Extract audio from YouTube video URLs or a local audio file
  • Convert audio to text using local openai-whisper library
  • Support for multiple languages
  • Option to ignore YouTube transcripts and download youtube audio file directly

Installation

To install this project using pipx, use the following command:

from PyPI

pip install yt2t

from GitHub

git clone https://github.com/JFK/youtube_to_text.git
cd youtube_to_text
pipx install .

Usage

To convert audio files to text, run the following command:

yt2t [YouTube video URL or local audio file path] [-l language] [-ig]

Example:

yt2t https://www.youtube.com/watch?v=example -l 

Options:

-l : Specify the language of the audio (default is ja). -ig : Ignore YouTube direct transcripts and generate text from a provided audio file.

License

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

yt2t-0.1.3.tar.gz (7.6 kB view details)

Uploaded Source

Built Distribution

yt2t-0.1.3-py3-none-any.whl (8.6 kB view details)

Uploaded Python 3

File details

Details for the file yt2t-0.1.3.tar.gz.

File metadata

  • Download URL: yt2t-0.1.3.tar.gz
  • Upload date:
  • Size: 7.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.0 CPython/3.11.0rc1

File hashes

Hashes for yt2t-0.1.3.tar.gz
Algorithm Hash digest
SHA256 98f975129783000e6b959d9ccbbacf87c225e4842e413f1ee3d6fca1b4a600be
MD5 c09296e5e26fc988c9dcf6fa9721d5da
BLAKE2b-256 885b802e83922f177360c951a87e4312653e976ca2ea6e32f45d1250f4b7faa7

See more details on using hashes here.

File details

Details for the file yt2t-0.1.3-py3-none-any.whl.

File metadata

  • Download URL: yt2t-0.1.3-py3-none-any.whl
  • Upload date:
  • Size: 8.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.0 CPython/3.11.0rc1

File hashes

Hashes for yt2t-0.1.3-py3-none-any.whl
Algorithm Hash digest
SHA256 b45ef5f3ec31cf34dce500a09e111b76b6d9fa5a997e8968f7bdaaa3b46d49f9
MD5 7a9969161ddaa231de2b96c100735e98
BLAKE2b-256 83e6d25190b4b82b4f5d8b0c55a31b453762007a7d580068d2d8b6d9e192822a

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page