Skip to content

spsjvc/supertinywhisper

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

37 Commits
 
 
 
 
 
 
 
 

Repository files navigation

supertinywhisper

A super tiny speech-to-text tool.

It's written in a few lines of Bash, and built with common tools you likely already have installed.

How it Works

supertinywhisper records your audio using ffmpeg (with settings optimized for speech), transcribes it using the OpenAI API, and outputs the resulting transcription to standard output. You can then pipe that into other tools and compose it however you like!

Dependencies

Required

  • ffmpeg - audio recording
  • curl - api calling
  • jq - json processing

Optional

Setup

  1. Get your API key from OpenAI Platform.

  2. Create the config directory and add your API key:

mkdir -p ~/.config/supertinywhisper
echo "your-api-key-here" > ~/.config/supertinywhisper/openai_api_key

Usage

For best experience, supertinywhisper should be bound to a keyboard shortcut and composed with other tools.

Pipe to typing tools

# X11
supertinywhisper | xdotool type --clearmodifiers --file -

# Wayland
supertinywhisper | wtype -

Pipe to clipboard

# X11
supertinywhisper | xclip -selection clipboard

# Wayland
supertinywhisper | wl-copy

Specify language

Specify the language using the ISO 639 code. This improves model accuracy and latency. Defaults to English.

# Spanish
supertinywhisper --language es | wtype -

# French
supertinywhisper --language fr | wtype -

Cancel

supertinywhisper --cancel

About

Super tiny speech-to-text tool

Resources

License

Stars

Watchers

Forks

Languages