skills$openclaw/gemini-stt
araa478.9k

by araa47

gemini-stt – OpenClaw Skill

gemini-stt is an OpenClaw Skills integration for coding workflows. Transcribe audio files using Google's Gemini API or Vertex AI

8.9k stars4.1k forksSecurity L1
Updated Feb 7, 2026Created Feb 7, 2026coding

Skill Snapshot

namegemini-stt
descriptionTranscribe audio files using Google's Gemini API or Vertex AI OpenClaw Skills integration.
owneraraa47
repositoryaraa47/gemini-stt
languageMarkdown
licenseMIT
topics
securityL1
installopenclaw add @araa47/gemini-stt
last updatedFeb 7, 2026

Maintainer

araa47

araa47

Maintains gemini-stt in the OpenClaw Skills directory.

View GitHub profile
File Explorer
3 files
.
_meta.json
450 B
SKILL.md
3.5 KB
transcribe.py
8.4 KB
SKILL.md

name: gemini-stt description: Transcribe audio files using Google's Gemini API or Vertex AI metadata: {"clawdbot":{"emoji":"🎤","os":["linux","darwin"]}}

Gemini Speech-to-Text Skill

Transcribe audio files using Google's Gemini API or Vertex AI. Default model is gemini-2.0-flash-lite for fastest transcription.

Option 1: Vertex AI with Application Default Credentials (Recommended)

gcloud auth application-default login
gcloud config set project YOUR_PROJECT_ID

The script will automatically detect and use ADC when available.

Option 2: Direct Gemini API Key

Set GEMINI_API_KEY in environment (e.g., ~/.env or ~/.clawdbot/.env)

Requirements

  • Python 3.10+ (no external dependencies)
  • Either GEMINI_API_KEY or gcloud CLI with ADC configured

Supported Formats

  • .ogg / .opus (Telegram voice messages)
  • .mp3
  • .wav
  • .m4a

Usage

# Auto-detect auth (tries ADC first, then GEMINI_API_KEY)
python ~/.claude/skills/gemini-stt/transcribe.py /path/to/audio.ogg

# Force Vertex AI
python ~/.claude/skills/gemini-stt/transcribe.py /path/to/audio.ogg --vertex

# With a specific model
python ~/.claude/skills/gemini-stt/transcribe.py /path/to/audio.ogg --model gemini-2.5-pro

# Vertex AI with specific project and region
python ~/.claude/skills/gemini-stt/transcribe.py /path/to/audio.ogg --vertex --project my-project --region us-central1

# With Clawdbot media
python ~/.claude/skills/gemini-stt/transcribe.py ~/.clawdbot/media/inbound/voice-message.ogg

Options

OptionDescription
<audio_file>Path to the audio file (required)
--model, -mGemini model to use (default: gemini-2.0-flash-lite)
--vertex, -vForce use of Vertex AI with ADC
--project, -pGCP project ID (for Vertex, defaults to gcloud config)
--region, -rGCP region (for Vertex, default: us-central1)

Supported Models

Any Gemini model that supports audio input can be used. Recommended models:

ModelNotes
gemini-2.0-flash-liteDefault. Fastest transcription speed.
gemini-2.0-flashFast and cost-effective.
gemini-2.5-flash-liteLightweight 2.5 model.
gemini-2.5-flashBalanced speed and quality.
gemini-2.5-proHigher quality, slower.
gemini-3-flash-previewLatest flash model.
gemini-3-pro-previewLatest pro model, best quality.

See Gemini API Models for the latest list.

How It Works

  1. Reads the audio file and base64 encodes it
  2. Auto-detects authentication:
    • If ADC is available (gcloud), uses Vertex AI endpoint
    • Otherwise, uses GEMINI_API_KEY with direct Gemini API
  3. Sends to the selected Gemini model with transcription prompt
  4. Returns the transcribed text

Example Integration

For Clawdbot voice message handling:

# Transcribe incoming voice message
TRANSCRIPT=$(python ~/.claude/skills/gemini-stt/transcribe.py "$AUDIO_PATH")
echo "User said: $TRANSCRIPT"

Error Handling

The script exits with code 1 and prints to stderr on:

  • No authentication available (neither ADC nor GEMINI_API_KEY)
  • File not found
  • API errors
  • Missing GCP project (when using Vertex)

Notes

  • Uses Gemini 2.0 Flash Lite by default for fastest transcription
  • No external Python dependencies (uses stdlib only)
  • Automatically detects MIME type from file extension
  • Prefers Vertex AI with ADC when available (no API key management needed)
README.md

No README available.

Permissions & Security

Security level L1: Low-risk skills with minimal permissions. Review inputs and outputs before running in production.

Requirements

- Python 3.10+ (no external dependencies) - Either GEMINI_API_KEY or gcloud CLI with ADC configured

FAQ

How do I install gemini-stt?

Run openclaw add @araa47/gemini-stt in your terminal. This installs gemini-stt into your OpenClaw Skills catalog.

Does this skill run locally or in the cloud?

OpenClaw Skills execute locally by default. Review the SKILL.md and permissions before running any skill.

Where can I verify the source code?

The source repository is available at https://github.com/openclaw/skills/tree/main/skills/araa47/gemini-stt. Review commits and README documentation before installing.