Skip to main content

CLI tool to extract audio from video files and transcribe it with OpenAI speech-to-text.

Project description

nanovt

Transcribe video or audio files with OpenAI speech-to-text.

The script extracts audio with ffmpeg, converts it to mono 16 kHz WAV, splits it into short chunks, transcribes each chunk with OpenAI, and writes a single text file.

Requirements

  • Python 3.13+
  • ffmpeg
  • OPENAI_API_KEY in your environment

Installation

From PyPI:

pip install nanovt

Or install it as an isolated uv tool:

uv tool install nanovt

Usage

nanovt input.mp4

By default, input.mp4 writes input.txt.

To force a language, pass an optional language code. For example, English:

nanovt input.mp4 --language en

If --language is omitted, the model detects the language automatically.

Other useful options:

nanovt input.mp4 --chunk-seconds 180 --retries 3
nanovt input.mp4 --output transcript.txt
nanovt input.mp4 --keep-temp

For speaker-labeled dialogue transcription, enable diarization:

nanovt input.mp4 --diarize

This uses gpt-4o-transcribe-diarize by default and writes dialogue lines such as A: ..., B: ..., and C: ....

Development

uv sync --group dev
uv run pytest
uv run nanovt input.mp4

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

nanovt-0.2.2.tar.gz (44.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

nanovt-0.2.2-py3-none-any.whl (8.2 kB view details)

Uploaded Python 3

File details

Details for the file nanovt-0.2.2.tar.gz.

File metadata

  • Download URL: nanovt-0.2.2.tar.gz
  • Upload date:
  • Size: 44.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for nanovt-0.2.2.tar.gz
Algorithm Hash digest
SHA256 92e9f1fa120a074fa1258af3ce1bdf2d99a8310708e06ac2e0ff58740f381147
MD5 c2ace0f90ef3b9176657729866a4c9b1
BLAKE2b-256 ec8d02329d57bbd48205dcec66c7dcbfb3315069b38c8be5d59ad22679cd575a

See more details on using hashes here.

Provenance

The following attestation bundles were made for nanovt-0.2.2.tar.gz:

Publisher: publish.yml on undefined443/nanovt

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file nanovt-0.2.2-py3-none-any.whl.

File metadata

  • Download URL: nanovt-0.2.2-py3-none-any.whl
  • Upload date:
  • Size: 8.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for nanovt-0.2.2-py3-none-any.whl
Algorithm Hash digest
SHA256 6b9c6b9ff68445e3aafac7edbb658806a1098e56c4c4f07f8d492af5be6bf390
MD5 1ffe7f0c05d1f5c143ae8e1e68f99053
BLAKE2b-256 04dc6b5f03dbb272a137e611c588ad1f9e0c95561f662671411a72f598f62593

See more details on using hashes here.

Provenance

The following attestation bundles were made for nanovt-0.2.2-py3-none-any.whl:

Publisher: publish.yml on undefined443/nanovt

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

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