Add Groq cloud STT engine#513
Open
johnalpha911 wants to merge 2 commits into
Open
Conversation
Contributor
|
The point of wirepod is to run all the base Vector functions locally, no? Wouldn't this defeat the point of that because of it being a cloud STT? |
Author
That's a fair point but this was mostly made to bridge the gap between accuracy and the need to have good hardware because as I mentioned with the cloud whisper you get free almost zero delay and very accurate transcription that's why I thought it would be a helpful addition |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds a new speech-to-text engine, groq, that streams Vector's captured audio to Groq's OpenAI-compatible transcription API (running whisper-large-v3) instead of running a model locally.
This gives low-power hosts — a Raspberry Pi 3B+ in particular — accurate, open-vocabulary recognition that isn't achievable with a local model on 1 GB of ARM. The Pi only captures and forwards audio; Groq does the inference. It also handles accented English and non-English languages (e.g. Greek) far better than the small local VOSK model, and is fast enough that there's no perceptible delay on short commands.
What's included
chipper/pkg/wirepod/stt/groq/Groq.go — the engine. Implements the standard interface (Name, Init, STT). Drains the audio stream to end-of-speech, wraps the PCM as WAV, POSTs it, parses the response, lowercases it. Includes brief retries on transient errors and fail-fast on client errors like a bad key.
chipper/cmd/groq/main.go — entry point, matching the other engines.
chipper/start.sh — adds the groq branch to STT dispatch.
setup.sh — adds Groq Whisper as menu option 5, an API-key prompt, and the build step.
Configuration (env vars in source.sh)
GROQ_API_KEY (required)
GROQ_STT_MODEL (default whisper-large-v3; also whisper-large-v3-turbo)
GROQ_STT_LANGUAGE (default auto-detect; e.g. en, el)
GROQ_STT_PROMPT (optional biasing prompt)
GROQ_API_URL (override for OpenAI-compatible endpoints)
Notes
No new Go dependencies — reuses the audio libraries the existing Whisper module already pulls in.
The build is CGO but does not link any local STT library, so there's no libvosk/whisper.cpp runtime requirement.
Testing
Built and run on a Raspberry Pi 3B+ (Debian trixie, aarch64) against a live Vector. Confirmed correct transcription of short commands with no perceptible latency, custom intents matching as before, and clean startup/error logging