Skip to main content

LLM-powered FFmpeg command assistant

Project description

llmpeg

LLM-powered FFmpeg command assistant that converts natural language instructions into ffmpeg commands.

Repository: https://github.com/imortaltatsu/llmpeg
PyPI Package: https://pypi.org/project/llmpeg/

Features

  • Conversational interface that converts natural language instructions into ffmpeg commands
  • GPT-compatible API support (OpenRouter, Ollama, or custom endpoints)
  • Interactive file selection when requests are ambiguous
  • Automatic command validation and error correction
  • Support for compression, conversion, and cropping operations

Installation

From PyPI (Recommended)

Using pip:

pip install llmpeg

Using pipx (isolated installation, recommended for CLI tools):

pipx install llmpeg

Using uv:

uv pip install llmpeg

From Git Repository

Using pip:

pip install git+https://github.com/imortaltatsu/llmpeg.git

Using pipx:

pipx install git+https://github.com/imortaltatsu/llmpeg.git

Using uv:

uv pip install git+https://github.com/imortaltatsu/llmpeg.git

Using uvx (run without installing):

uvx git+https://github.com/imortaltatsu/llmpeg.git

Local Development

# Clone the repository
git clone https://github.com/imortaltatsu/llmpeg.git
cd llmpeg

# Install in development mode
uv sync
# or
pip install -e .

Setup

After installation, configure your API settings:

# Interactive setup
llmpeg setup init

# Or use environment variables
export LLMPEG_PROVIDER=openrouter
export LLMPEG_API_KEY=your-api-key
export LLMPEG_MODEL_NAME=gpt-oss:20b

Usage

# Single command
llmpeg -p "convert sample.png to jpg"

# Interactive mode
llmpeg

# Setup commands
llmpeg setup init    # Configure API settings
llmpeg setup show    # Show current configuration
llmpeg setup test    # Test API connection

Configuration

Configuration is stored in ~/.llmpeg/config.py or ~/.llmpeg/config.json.

Supported providers:

  • OpenRouter: Use gpt-oss:20b or other models
  • Ollama: Local Ollama instance (defaults to gpt-oss:20b)
  • Custom: Any OpenAI-compatible API endpoint

Requirements

  • Python 3.12+
  • FFmpeg installed and available in PATH
  • API access (OpenRouter API key, Ollama running locally, or custom endpoint)

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

llmpeg-0.1.1.tar.gz (19.9 kB view details)

Uploaded Source

Built Distribution

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

llmpeg-0.1.1-py3-none-any.whl (21.5 kB view details)

Uploaded Python 3

File details

Details for the file llmpeg-0.1.1.tar.gz.

File metadata

  • Download URL: llmpeg-0.1.1.tar.gz
  • Upload date:
  • Size: 19.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.11

File hashes

Hashes for llmpeg-0.1.1.tar.gz
Algorithm Hash digest
SHA256 4b7e7dfb4e0cc8d582f0c2c21a30b7854e0f529137c4f5a6e559c01e9cc4388c
MD5 5522b4d850eade29878f94484556c0ad
BLAKE2b-256 664c9596655778861a72dcf8c409a02a5e57ea96507b14930ab2531f6737dfcc

See more details on using hashes here.

File details

Details for the file llmpeg-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: llmpeg-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 21.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.11

File hashes

Hashes for llmpeg-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 09adc330504eb525334a06496e5159d050a5b27ac9b13b3676c9b6f1ae1f5ee8
MD5 2c63f1ae4f342e0a4a22e165cd724508
BLAKE2b-256 80160a664b0bad8ae67df58f14d9222760d020986edbfde71877d11662b7fa61

See more details on using hashes here.

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