81d43666c7
Phase 1 (Assist Core + Guardrail) complete. 8 slices, 4 waves, 24 tasks. 12 REQs covered (3 ASSIST + 3 NFR + 6 IDEATE). 92 new tests (409 total). G-049 + G-067 MUSTs resolved. Verify: APPROVE_WITH_NOTES, 5 P1+ flagged. Live Assist voice loop: shift-bounded sessions, context-binding, 3-layer guardrail (prompt + regex filter + audit log), tap-to-talk client control, warm WebRTC, reconnect logic, incremental audit write, PII policy, consent disclosure, mode-conflict enforcement. ---ci--- project: praxis phase: 1 milestone: v0.5 status: complete requirements: covered: [REQ-ASSIST-01, REQ-ASSIST-02, REQ-ASSIST-03, REQ-NFR-ASSIST-02, REQ-NFR-ASSIST-03, REQ-NFR-ASSIST-04, REQ-IDEATE-01, REQ-IDEATE-02, REQ-IDEATE-03, REQ-IDEATE-05, REQ-IDEATE-08, REQ-IDEATE-09] partial: [] ---/ci---
15 lines
920 B
SQL
15 lines
920 B
SQL
-- Migration 0004 — v0.5 Live Assist (D-062, REQ-NFR-ASSIST-04, D-060 layer 3, REQ-IDEATE-09).
|
|
-- Additive: existing practice sessions are unaffected (defaults preserve v0.1-v0.4 behavior).
|
|
|
|
-- session_type: 'practice' (default, existing) | 'assist' (new v0.5).
|
|
-- SQLite ALTER TABLE ADD COLUMN with a DEFAULT keeps existing rows as 'practice'.
|
|
ALTER TABLE sessions ADD COLUMN session_type TEXT NOT NULL DEFAULT 'practice';
|
|
|
|
-- guardrail_verdict_json: per-turn guardrail verdict (D-060 layer 3, REQ-IDEATE-09).
|
|
-- Nullable — only assist turns populate it; existing practice turns stay NULL.
|
|
ALTER TABLE turns ADD COLUMN guardrail_verdict_json TEXT;
|
|
|
|
-- Index for the mode-conflict check (REQ-IDEATE-03): find active sessions by type.
|
|
-- ended_at IS NULL means the session is still active (no end timestamp).
|
|
CREATE INDEX IF NOT EXISTS idx_sessions_active_by_type
|
|
ON sessions (learner_id, session_type, ended_at); |