Skip to main content
Sluice Box is a single-user desk for a Windows PC. Live system audio uses WASAPI loopback, so live listening needs Windows. Paste mode and the test suite run anywhere Python runs.

Requirements

  • Windows 10 or 11 for live audio capture
  • Python 3.12 to 3.14 (requires-python = ">=3.12,<3.15")
  • An OpenRouter API key for Muse Spark Open
  • Optional: a Meta Model API key for Muse Spark 1.3 and Muse Voice Transcribe (pay-as-you-go on the Meta developer team; Sluice Box stops at $5 by default)
  • Optional: Ollama with gemma3:4b as an offline fallback

Install

1

Create a virtual environment

From the sluice-box folder:
requirements.txt installs FastAPI, uvicorn[standard], websockets, NumPy, python-dotenv, and pyaudiowpatch on Windows.
2

Set the Meta profile

Edit .env. The values below are placeholders. Never commit .env.
.env
With both keys blank the UI still runs, paste falls back to Ollama when it is running, and the tests stay offline.
3

Optional: install local Whisper

Local speech to text uses OpenVINO. Install the extra, then point WHISPER_MODEL_DIR at an OpenVINO Whisper export.
.env
Relative paths resolve from the sluice-box folder. The loader reads the model’s own processor, so large-v3 and turbo exports get their 128 mel bins. The extra pins nncf<3, because nncf 3.x breaks the optimum.intel import with OpenVINO 2025.4.
4

Start the desk

start.bat does the same if PowerShell execution policy blocks the script. Both run:
and open http://127.0.0.1:7788.

Check that it works

  1. The corner of the page reads engine ready, not live updates unavailable.
  2. GET http://127.0.0.1:7788/health shows the profile, realtime: true, and the model names. It never returns an API key.
  3. Paste one sentence and press Enter. A transcript row appears, then a card. In the Meta profile the provenance line names Muse Spark Open.
  4. Choose a loopback or microphone input and press Start listening. A spoken sentence becomes a ledger row and a card. If Muse Voice Transcribe fails, the corner reads stt: whisper and the desk uses local Whisper.
  5. While someone is still talking, press Transcribe now (or T). The words so far appear without waiting for a pause. Press Stop listening mid-sentence: the cut-off sentence still lands as a row marked kept at stop. Press Start listening again and the turn numbers continue. See Keeping the last thing said.

One real Muse call

The tests never call a live model. This script makes one real Muse Spark Open request and prints which request shape the provider accepted: path: chat, path: responses, or path: text.

Replay a recording

With the desk running, this script posts a 16-bit WAV you already have to /replay, and the desk transcribes it and builds cards as if it came from loopback. The script calls no model itself. Keep the file out of the repository.
To try Stop and Transcribe now without an X Space, play a WAV through the live pipeline at real speed, then stop it part way:
Every variable, with its default, is on the Configuration page.