一键导入
measure-barge-in
Measure the barge-in pipeline (detection, latency, noise/echo rejection, command-vs-engagement) against the goal in .claude/goals/barge-in.json
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Measure the barge-in pipeline (detection, latency, noise/echo rejection, command-vs-engagement) against the goal in .claude/goals/barge-in.json
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
Post to Slack channels and manage Trello cards with natural language
Configure MCP session defaults for iOS development
Pre-commit validation ensuring lint and tests pass
Manage git worktrees for parallel Claude Code development sessions
基于 SOC 职业分类
| name | measure-barge-in |
| description | Measure the barge-in pipeline (detection, latency, noise/echo rejection, command-vs-engagement) against the goal in .claude/goals/barge-in.json |
Turns the goal "a single reliable barge-in pipeline with latency in the target
range" into objective numbers and grades them against the criteria in
.claude/goals/barge-in.json. This is the measurement the goal feature checks.
Critical rule: the goal is NOT met until a device run passes. The simulator
run is a fast, repeatable proxy for regression; it cannot prove the goal because
it does not exercise the real microphone, speaker echo, or hardware latency.
/measure-barge-in quick # full seed, lenient grading (INCONCLUSIVE allowed) - fast feedback
/measure-barge-in full # full seed, strict grading
/measure-barge-in baseline <name> # save the current run as a baseline
/measure-barge-in compare <name> # run, diffed against a saved baseline
All modes run the simulator INJECTION harness: generated audio is fed into the
real VAD + BargeInDetector. It measures detection, reaction latency, noise
rejection, and command-vs-engagement classification, but NOT the microphone,
speaker echo, or hardware latency. The goal's source of truth is a real-acoustic
DEVICE run (mic + speaker + echo) with the real streaming STT - a separate
workstream, not this script.
BargeInMeasurementHarness over the corpus, and prints the result JSON:
./scripts/measure-barge-in.sh <mode> [name]
build/barge-in-results/<mode>-<ts>.json
and grades each criterion in .claude/goals/barge-in.json, printing a
PASS / FAIL / INCONCLUSIVE / DEVICE-ONLY line per criterion.| Criterion | simulator | device |
|---|---|---|
| Barge-in reaction latency (median, p95) | proxy (real-time-paced injection) | true |
| Detection recall | yes (real VAD + detector) | true |
| Noise/echo false-positive rate | partial (sim VAD may be energy-based) | true |
| Command-vs-engagement macro F1 | yes (classifier on known text) | true (real STT transcript) |
| STT time-to-first-partial | device-only | true (real streaming STT) |
The harness uses no STT: on the simulator it classifies each TTS clip's known text (isolating the classifier), and STT time-to-first-partial is measured on device by the streaming-STT workstream. This keeps the harness off Apple Speech.
min_samples. On quick, INCONCLUSIVE (too few samples) is allowed.full/device) is
INCONCLUSIVE for lack of samples.0 = pass, 1 = fail, 2 = setup error (no simulator/device).BargeInDetector, VAD config, thresholds).device run).User: /measure-barge-in quick
Claude: Barge-in measurement: mode=quick ...
Barge-in goal: Single reliable barge-in + speech pipeline (mode=simulator, tier=target)
clips=4 positives=3 negatives=1 detected=3 falsePos=0 classified=3
------------------------------------------------------------------------
PASS Barge-in reaction latency (median) (gate): 96.0 ms (target <= 300)
PASS Detection recall (gate): 1.000 (target >= 0.95) [INCONCLUSIVE if < min_samples]
PASS Command-vs-engagement accuracy (gate): 1.000 (target >= 0.90)
DEVICE-ONLY STT time-to-first-partial (gate): measured on device only
------------------------------------------------------------------------
MEASUREMENT PASSED (simulator proxy; device run is the goal's source of truth)
.claude/goals/barge-in.jsonUnaMentis/Testing/BargeInHarness/UnaMentis/Core/Audio/BargeInDetector.swiftUnaMentis/Core/Audio/BargeInClassifier.swift