1.7 KiB
1.7 KiB
Repository Guidelines
Project Structure & Module Organization
lel.shis the primary entrypoint; it records audio, runswhisper, and prints the transcript.env/is a local Python virtual environment (optional) used to install runtime dependencies.- There are no separate source, test, or asset directories at this time.
Build, Test, and Development Commands
./lel.shstreams transcription from the microphone until you press Enter.- Example with overrides:
WHISPER_MODEL=small WHISPER_LANG=pt WHISPER_DEVICE=cuda ./lel.sh. - Dependencies expected on PATH:
ffmpegandwhisper(the OpenAI Whisper CLI).
Coding Style & Naming Conventions
- Shell scripts use Bash with
set -euo pipefail. - Indentation is two spaces; prefer lowercase variable names for locals and uppercase for environment-configured values.
- Keep functions small and focused; add comments only where the intent is not obvious.
Testing Guidelines
- No automated tests are present.
- If you add tests, include a brief note in
AGENTS.mdwith the runner command and test location.
Commit & Pull Request Guidelines
- Commit history is minimal and does not establish a convention; use short, imperative messages (e.g., "Add device override").
- PRs should include a concise description, repro steps, and any environment variables or dependencies added.
Configuration Tips
- Audio input is controlled via
WHISPER_FFMPEG_IN(defaultpulse:default), e.g.,alsa:default. - Streaming is on by default; set
WHISPER_STREAM=0to transcribe after recording. - Segment duration for streaming is
WHISPER_SEGMENT_SEC(default5). - Model, language, device, and extra args can be set with
WHISPER_MODEL,WHISPER_LANG,WHISPER_DEVICE, andWHISPER_EXTRA_ARGS.