- lib/pending-query.mjs: new state machine for query accumulation
wake word, silence timer, send/cancel/pause/resume, instant dispatch,
mode toggle (always listen / stop listening), mode query
- query-demo.mjs: refactored to use Pending_Query; wake word on by default
with silence timer; chimes for dispatch/working/cancel/activate
- tts-server.mjs: track last_speak_at, expose /activity endpoint,
chime playback via Python queue (soundfile + librosa), preload on startup
- chatterbox-server.py: chime and preload commands via stdin protocol
- lib/chatterbox-tts.mjs: play_chime and preload_chime methods
- test-chime.mjs: simple chime test script
- voices.yaml: configured ready/cancel/working/dispatch chimes
- CLEANUP-PLAN.md: updated with current state, command vocabulary, future plans
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
YAML chimes section maps event names to arbitrary file paths.
Falls back to chimes/<name>.wav or .ogg if not listed.
Allows custom locations and formats without renaming files.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
POST /chime {name} plays chimes/<name>.wav or .ogg via pacat.
Goes through the same queue as speak so playback stays ordered.
chimes/ directory holds the audio files (not committed).
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
A single transient noise no longer resets the silence timer.
Only sustained audio energy counts as speech.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
on_audio was resetting the timer on every chunk including silence,
so the timeout never fired. Now passes the raw chunk and checks RMS;
only resets if energy is above 0.02 (speech, not ambient silence).
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
STT (Silero VAD + Whisper via sherpa-onnx), Chatterbox TTS HTTP server,
query completeness classifier (Ollama), multi-voice demo scripts, and
planning docs. Kept as reference; clean rewrite planned in separate repos.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>