> ## Documentation Index
> Fetch the complete documentation index at: https://joe-pro-ai.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Quickstart

> Install Sluice Box on a Windows PC, set your environment, and open the desk on 127.0.0.1:7788.

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](https://ollama.com) with `gemma3:4b` as an offline fallback

## Install

**1. Create a virtual environment**

From the `sluice-box` folder:

```powershell theme={"dark"}
py -3.12 -m venv .venv
.\.venv\Scripts\python.exe -m pip install --upgrade pip
.\.venv\Scripts\python.exe -m pip install -r requirements.txt
copy .env.example .env
```

`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`.

```bash .env theme={"dark"}
SLUICE_BOX_PROFILE=meta
OPENROUTER_API_KEY=your-openrouter-key
MODEL_API_KEY=your-meta-model-api-key
```

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.

```powershell theme={"dark"}
.\.venv\Scripts\python.exe -m pip install -e ".[stt-openvino]"
```

```bash .env theme={"dark"}
STT_BACKEND=openvino
WHISPER_MODEL_DIR=models/whisper-large-v3-turbo-fp16-ov
```

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**

```powershell theme={"dark"}
.\start.ps1
```

`start.bat` does the same if PowerShell execution policy blocks the script. Both run:

```powershell theme={"dark"}
.\.venv\Scripts\python.exe -m uvicorn engine.server:app --host 127.0.0.1 --port 7788
```

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](https://joe-pro-ai.mintlify.site/topic-ledger.md#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`.

```powershell theme={"dark"}
.\.venv\Scripts\python.exe scripts\smoke_muse.py
```

## 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.

```powershell theme={"dark"}
.\.venv\Scripts\python.exe scripts\demo_replay.py --audio path\to\demo.wav
```

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:

```powershell theme={"dark"}
curl.exe -s -X POST -H "Origin: http://127.0.0.1:7788" --data-binary "@path\to\demo.wav" http://127.0.0.1:7788/listen-file
curl.exe -s -X POST -H "Origin: http://127.0.0.1:7788" http://127.0.0.1:7788/transcribe-now
curl.exe -s -X POST http://127.0.0.1:7788/stop-listening
```

> [!TIP]
>
> Every variable, with its default, is on the [Configuration](https://joe-pro-ai.mintlify.site/configuration.md) page.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.