Skip to main content

Subify-CLI

Subify-CLI is a local subtitle product for short English .mp4 recordings. It turns spoken audio into timed text, burns that text into a new video, and delivers both artifacts in a single ZIP.

The source file is never overwritten. Current scope is .mp4 input up to 12 minutes.

Website: subify-cli.vercel.app

Why it exists

A sidecar .srt file is useful for editing. Many players and social workflows still need burned-in captions: the subtitle pixels live in the picture, so the video remains readable without a separate file.

Subify keeps those two outputs together. Automatic speech recognition produces the transcript. FFmpeg hard-subtitles the frames. Packaging puts the editable SRT and the subtitled MP4 in one archive.

All of this runs on the machine that hosts Subify. Transcription uses Faster-Whisper with English locked (language="en"). There is no cloud transcription API in this repository.

How the pipeline works

video
  -> audio extraction
  -> English transcription
  -> SRT generation
  -> subtitle embedding
  -> ZIP packaging
  1. Audio extraction. FFmpeg pulls a temporary mono 16 kHz PCM WAV, which is the format Faster-Whisper expects.
  2. Transcription. Faster-Whisper maps that audio to timestamped English segments.
  3. SRT generation. Those segments are written as a standard SubRip (.srt) file.
  4. Embedding. FFmpeg burns the SRT into a new MP4. The original video is left untouched.
  5. Packaging. The SRT and the subtitled MP4 are zipped for delivery.

generate-srt stops after step 3. embed starts from an existing video and SRT and only performs embedding.

Requirements

  • Python 3.11 or newer
  • FFmpeg and FFprobe are set up automatically by Subify on first run when they are not already available.

Installation

Install Subify-CLI with pip:

pip install subify-cli

Then run:

subify doctor
subify

Usage

Running subify with no arguments opens the interactive shell. Slash commands drive that session:

/process "lesson.mp4"
/generate-srt "lesson.mp4"
/embed "lesson.mp4" "lesson.srt"

Also available in the shell: /help, /version, /config, /history, /clear, /doctor, /exit.

The same work can be invoked directly:

Command What it does
subify process <video> Full pipeline. Writes a ZIP.
subify generate-srt <video> English .srt only. No embed, no ZIP.
subify embed <video> <srt> Burns an existing SRT into a new MP4. No Whisper.
subify doctor Checks Python, FFmpeg, FFprobe, Faster-Whisper, and write access.

Optional flags: --output-dir to choose the destination, --show-transcript to print segments after process or generate-srt.

subify --help
subify --version

Output

Default directory: Downloads/Subify under the current user’s home folder.

For lesson.mp4:

  • processlesson_subify.zip containing lesson.srt and lesson_subtitled.mp4
  • generate-srtlesson.srt
  • embedlesson_subtitled.mp4

If lesson_subify.zip already exists, a numbered name such as lesson_subify (1).zip is used.

Telegram

The Telegram adapter polls for .mp4 uploads, runs the same process pipeline, and sends the ZIP back to the chat.

Set SUBIFY_TELEGRAM_BOT_TOKEN in the environment, then:

python -m telegram

Development

python -m venv .venv
python -m pip install -e .
python -m unittest discover -s tests

Download files

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

Source Distribution

subify_cli-0.1.0.tar.gz (49.4 kB view details)

Uploaded Source

Built Distribution

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

subify_cli-0.1.0-py3-none-any.whl (37.3 kB view details)

Uploaded Python 3

File details

Details for the file subify_cli-0.1.0.tar.gz.

File metadata

  • Download URL: subify_cli-0.1.0.tar.gz
  • Upload date:
  • Size: 49.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.11.1

File hashes

Hashes for subify_cli-0.1.0.tar.gz
Algorithm Hash digest
SHA256 29fa43adc262d8febba2a9186c2ee84119ba0e1233b647dcf73f23bb7c4e96fb
MD5 9fff102f6dbeaa6c523aacadb36a0a9e
BLAKE2b-256 3fa749174586836dd9a3e8941ff28959117f16bc74ddeb82bce1f0af86775c19

See more details on using hashes here.

File details

Details for the file subify_cli-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: subify_cli-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 37.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.11.1

File hashes

Hashes for subify_cli-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 36ba2a8b13670702379a4061d3d6641aad1ed104e646b7ece4dda7d67314554d
MD5 9196afab528e6845e533f646632818e5
BLAKE2b-256 bb77978e4a3b135f12df31831f30f364fd449bb939d7512cdeca3ca9079bf542

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page