docs: LEARNING.md + fuzz/ placeholder + README dev-loop (spec §7, §6.3)

LEARNING.md indexes ten concept-to-file pointers (the spec floor was
five) — the newtype pattern, exhaustive enum match, sans-IO, trait
extension seams, thiserror + hot-path match-and-continue, Arc<Mutex>
vs Arc<RwLock>, DashMap, str0m's single-mutation invariant, graceful
shutdown, include_str!. fuzz/README.md pre-paves the layout (no
hostile-bytes surface in slice 1; harnesses land at step 5 per the
out-of-scope table). README's new dev-loop section documents the
libopus FFI prerequisite and the manual e2e steps.
This commit is contained in:
adlee-was-taken
2026-06-28 13:06:37 -04:00
parent f92e6f467b
commit f765fc2b27
3 changed files with 137 additions and 0 deletions

View File

@@ -8,6 +8,48 @@ or its architecture.
> technical builder uses to stand up a contact center* — and re-aims it at a category AI is
> actively disrupting, instead of a PBX category UCaaS already ate.
## Slice 1 dev loop (WebRTC media loopback)
> Build prerequisite: install libopus (the `opus` crate links it via FFI):
> ```bash
> sudo apt-get install -y libopus-dev # Debian/Ubuntu
> # Fedora: sudo dnf install -y opus-devel
> # macOS: brew install opus
> ```
> This is the one system dependency in slice 1. Opus is FFI per PORT_PLAN
> §7's "🦀 Core (FFI)" disposition — the codec surface Rust doesn't need
> to re-implement.
Run the server:
```bash
cargo run
# listening on http://0.0.0.0:8080
```
Open a browser to `http://localhost:8080/`, click "Start call", grant
microphone permission. Speak — you should hear yourself back within
~200 ms (no perceptible delay). Click "Hang up" to tear down; server
logs `Closing → Closed`.
Verbose tracing:
```bash
RUST_LOG=rutster=debug cargo run
```
### Slice 1 "done" checklist (spec §6.5)
On a clean checkout:
1. `cargo test --all` passes.
2. `cargo fmt --check` passes.
3. `cargo clippy -- -D warnings` passes.
4. `cargo deny check` passes.
5. `cargo run` + browser manual e2e: speak → hear echo within ~200 ms.
6. Hang-up button triggers `Closing → Closed` in server logs.
7. Every stub crate compiles; its doc-comment names its scheduled step.
8. `LEARNING.md` indexes at least 5 "to learn X, read Y" pointers.
## Why it exists
Asterisk won because contact centers were **built on it** (Vicidial, GOautodial, a thousand