---
phase: 5
slug: proximity-algorithm
status: complete
nyquist_compliant: true
wave_0_complete: true
created: 2026-03-22
updated: 2026-03-23
---

# Phase 5 — Validation Strategy

> Per-phase validation contract for feedback sampling during execution.

---

## Test Infrastructure

| Property | Value |
|----------|-------|
| **Framework** | PowerShell verification scripts |
| **Config file** | none |
| **Quick run command** | `powershell -ExecutionPolicy Bypass -File scripts/verify_algorithm.ps1` |
| **Full suite command** | `powershell -ExecutionPolicy Bypass -File scripts/verify_algorithm.ps1` |
| **Estimated runtime** | ~5 seconds |

---

## Sampling Rate

- **After every task commit:** Run `powershell -ExecutionPolicy Bypass -File scripts/verify_algorithm.ps1`
- **After every plan wave:** Run full verification
- **Before `/gsd:verify-work`:** Full suite must be green
- **Max feedback latency:** 5 seconds

---

## Per-Task Verification Map

| Task ID | Plan | Wave | Requirement | Test Type | Automated Command | File Exists | Status |
|---------|------|------|-------------|-----------|-------------------|-------------|--------|
| 05-01-01 | 01 | 1 | PROX-01..06 | build + log | `cmake --build build --config Release` + vrserver log | yes | green |
| 05-01-02 | 01 | 1 | PROX-01..06 | log + pipe | `verify_algorithm.ps1` full suite | yes | green |

---

## Wave 0 Requirements

Existing infrastructure covers all phase requirements. `scripts/verify_algorithm.ps1` checks calibration subtraction, sample validation, moving average, hysteresis detection, and threshold clamping via vrserver log and pipe status output.

---

## Manual-Only Verifications

| Behavior | Requirement | Why Manual | Test Instructions |
|----------|-------------|------------|-------------------|
| person_detected transitions match headset on/off | PROX-04, PROX-05 | Requires physical headset on/off head | Wear headset, verify person_detected=true in status; remove, verify false |

---

## Validation Sign-Off

- [x] All tasks have `<automated>` verify or Wave 0 dependencies
- [x] Sampling continuity: no 3 consecutive tasks without automated verify
- [x] Wave 0 covers all MISSING references
- [x] No watch-mode flags
- [x] Feedback latency < 5s
- [x] `nyquist_compliant: true` set in frontmatter

**Approval:** passed

## Validation Audit 2026-03-23

| Metric | Count |
|--------|-------|
| Gaps found | 0 |
| Resolved | 0 |
| Escalated | 0 |
