Commit Graph
69 Commits
Author SHA1 Message Date
ilaandClaude Opus 4.8 d92b53d7a3 chore(tasks): start T-309 V2 interaction and sqlite persistence
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-23 21:54:17 +08:00
ilaandClaude Opus 4.8 58fd92aa80 feat(v2): T-308 group monitor/settings into white cards for visual separation
Adds a card() surface (white rounded panel, 1px #C8D4E3 stroke, 8px radius)
matching the light-Windows spec, and groups the monitor (video / status+
controls / gallery) and settings (camera / params / deps) into cards so the
gray-blue page shows through the gutters. Components were previously flat on
one background with no separation. Cross-compiles for Windows.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-23 21:40:18 +08:00
ilaandClaude Opus 4.8 03d3f83f1d feat(v2): T-308C editable settings form (camera + params) applied on start
Settings tab is now an editable, scrollable form: camera connection
(host/port/channel/user/masked password/transport/timeout/low-latency) and
common detection params, each with a save button that writes the untracked
local config. cmd/silver-pose pre-fills from the local file, passes the
config path, and the controller reloads config on each Start so saved edits
apply next run. UI cross-compiles for Windows.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-23 21:30:23 +08:00
ilaandClaude Opus 4.8 8840bdd115 chore(tasks): T-306/T-307 done; start T-308 UI+settings enhancements
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-23 21:12:20 +08:00
ilaandClaude Opus 4.8 ea24fc4c4b feat(v2): compact monitor status row, small buttons, screenshot gallery
Right panel now shows connection+detection status on one line, small
start/stop buttons on one line, event text with the red-note inline, and a
3x3 reverse-chronological gallery of recent confirmed screenshots filling
the rest. Double-clicking a thumbnail opens a full-image overlay. Gallery
items are collected off the UI thread from confirmed updates (deduped by
event id) and each ImageOp is built once and cached. Cross-compiles for
Windows; no new deps.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-23 20:58:45 +08:00
ilaandClaude Opus 4.8 8440bdefdf chore(tasks): start T-307 V2 monitor UI polish and screenshot gallery
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-23 20:56:22 +08:00
ilaandClaude Opus 4.8 97c1c4a974 fix(v2): pin onnxruntime_go to v1.12.1 to match onnxruntime 1.19.2 DLL
v1.31.0 requested ORT_API_VERSION 26 (onnxruntime 1.26); the field DLL is
Python 3.8's onnxruntime 1.19.2 (API 19), so GetApi(26) returned NULL and
init failed. v1.12.1 targets ORT API 19, matching the existing DLL with no
download. Verified: native cgo build of internal/spike compiles ort.go
against v1.12.1; Gio UI still cross-compiles for Windows.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-23 16:04:09 +08:00
ilaandClaude Opus 4.8 5075f7ae4d docs: T-306 done, Gio window verified on Windows
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-23 14:28:48 +08:00
ilaandClaude Opus 4.8 4188a2b06c feat(v2): migrate UI from Walk to Gio
Rewrites internal/ui/window.go in Gio, keeping the Window interface
(NewWindow/Run/Present/PresentAlert/ReportIssue) and the pure-Go ViewModel.
Background updates mutate shared state under a lock and Invalidate; the Gio
loop renders the latest frame. Dual tabs, widget.Image for render's RGBA, a
self-drawn confirm dialog and a MessageBeep sound. Drops lxn/walk (and the
TTM_ADDTOOL/comctl class of problems). Verified via GOOS=windows CGO_ENABLED=0
build of the UI packages; full app build needs Windows+CGo for onnxruntime.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-23 14:26:19 +08:00
ilaandClaude Opus 4.8 18e1331f8f chore(tasks): start T-306 migrate V2 UI Walk->Gio
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-23 14:20:54 +08:00
ilaandClaude Opus 4.8 8d71889d9c docs: adopt Gio for V2 UI after spike passed on Windows; add T-306 migration
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-23 14:16:40 +08:00
ilaandClaude Opus 4.8 43ec154075 feat(v2): Gio UI spike, cross-compiles CGo-free for Windows
Adds cmd/gio-spike: a minimal Gio window (dual tabs, an *image.RGBA video
area, start/stop) that avoids the Walk TTM_ADDTOOL/comctl manifest problem
entirely. Verified via GOOS=windows CGO_ENABLED=0 go build (11MB single
exe). Windows visual smoke pending. Existing Walk ui-spike left untouched.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-23 08:45:21 +08:00
ilaandClaude Opus 4.8 677a0d587b chore(tasks): start T-305 V2 Gio UI spike (Walk TTM_ADDTOOL)
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-22 22:49:01 +08:00
ila 536396f373 feat(v2): add realtime command and release tooling 2026-07-22 21:28:57 +08:00
ila 2ae3415fbf chore(tasks): start T-304 Go demo delivery 2026-07-22 21:08:01 +08:00
ila ca971306eb docs(t303): record demo fall false negative 2026-07-22 20:49:41 +08:00
ila 1298369054 feat(v2): add fall event regression engine 2026-07-22 16:18:16 +08:00
ila 258fa49259 chore(tasks): start T-303 Go event regression 2026-07-22 16:05:36 +08:00
ila 22aadf2b26 feat(v2): complete Go inference and UI spike 2026-07-22 16:01:28 +08:00
ila 104608751a chore(tasks): start T-302 Go spike 2026-07-22 15:46:49 +08:00
ila b013263dae docs(progress): record T-301 ONNX consistency 2026-07-22 15:14:41 +08:00
ila 2544456549 chore(tasks): start T-301 ONNX consistency 2026-07-22 15:12:29 +08:00
ila 084082055d feat(v1): add demo runbook and release package 2026-07-22 15:10:11 +08:00
ila 3b263a87ea chore(tasks): start T-205 demo release package 2026-07-22 15:05:58 +08:00
ila 30437f0479 docs(acceptance): complete T-204 field validation 2026-07-22 15:05:31 +08:00
ilaandClaude Opus 4.8 8b33f61112 feat(v1): chinese screenshot labels via Pillow with ASCII fallback
annotate_frame draws Chinese labels (e.g. '确认摔倒 P-0001') using a CJK
font via Pillow when available (Windows uses Microsoft YaHei), and falls
back to the ASCII cv2 label when Pillow or a CJK font is missing. 86 tests
pass.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-22 00:10:07 +08:00
ilaandClaude Opus 4.8 c5e4d87b42 chore(tasks): start T-213 chinese screenshot annotation
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-22 00:08:01 +08:00
ilaandClaude Opus 4.8 6e69518742 feat(v1): latest-frame-only reader thread for low-latency RTSP
Adds _FrameGrabber which decodes in a background thread and keeps only the
newest frame; VideoSource drop_stale (STREAM only) returns the latest frame
so a slow consumer never builds a backlog. app enables it for streams.
REPLAY is unchanged. 82 tests pass.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-22 00:04:00 +08:00
ilaandClaude Opus 4.8 b32c36fc44 chore(tasks): start T-212 latest-frame-only reader for low latency
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-22 00:02:01 +08:00
ilaandClaude Opus 4.8 d3cd8ecb55 feat(v1): edit detection sensitivity from the settings tab
Adds write_local_event_tuning and a sensitivity group (confirm window,
horizontal angle, require-rapid-drop, require-lower-body) that persists to
the untracked local config and applies next start. 79 tests pass.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-22 00:00:51 +08:00
ilaandClaude Opus 4.8 922609f236 chore(tasks): start T-211 sensitivity params in settings
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-21 23:58:52 +08:00
ilaandClaude Opus 4.8 578aa49f99 docs(T-204): record false-positive pass on real stream (no tuning needed)
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-21 23:55:40 +08:00
ilaandClaude Opus 4.8 68f30d416f chore(tasks): start T-204 false-positive verification and tuning
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-21 23:51:59 +08:00
ilaandClaude Opus 4.8 f1a8d0ea47 test(v1): lock reconnect and disconnect-no-alarm behavior; close T-203
Adds a mid-stream drop recovery test and a pipeline test proving a
disconnected frame yields no events and interrupts a pending suspect
(stream loss never alarms). Live preview and fall detection on the real
Hikvision stream were confirmed on Windows. 74 tests pass.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-21 23:49:21 +08:00
ilaandClaude Opus 4.8 b35082a643 fix(v1): use ASCII screenshot annotation to avoid garbled text
cv2.putText only supports ASCII (Hershey fonts); the middle-dot in the
label rendered as garbage on saved screenshots. screenshot_label builds
an ASCII-only 'ID STATE' string for the annotation; the Qt live-view
label is unchanged. 72 tests pass.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-21 23:38:53 +08:00
ilaandClaude Opus 4.8 7029468037 chore(tasks): start T-210 fix garbled screenshot annotation
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-21 23:37:18 +08:00
ilaandClaude Opus 4.8 b1f0e8aeb4 feat(v1): relax fall sensitivity for low overhead cameras
Adds configurable event.require_rapid_drop (default off), require_lower_body
(default off) and horizontal_angle_threshold_degrees (default 45). With the
lenient defaults a sustained horizontal pose alone enters SUSPECT and confirms
after the confirm window, which is now the main false-positive guard; missing
knees/ankles no longer reject the pose. Thresholds flow into config_version.
End-to-end smoke confirms a lying pose; 70 tests pass.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-21 23:29:16 +08:00
ilaandClaude Opus 4.8 5f29a8e60f chore(tasks): start T-209 relax overhead fall sensitivity
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-21 23:23:45 +08:00
ilaandClaude Opus 4.8 bf86b5612f feat(v1): per-frame fall decision diagnostics overlay
PersonAnalysis now carries the policy Evidence; view_model builds a Qt-free
per-person diagnostic line (acc/horiz/ang/rapid/cand/state, or the reject
reason) and VideoView overlays it in a corner. Read-only, no decision change;
locates where a real fall stops. 67 tests pass.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-21 23:14:05 +08:00
ilaandClaude Opus 4.8 2eeaba0ab8 chore(tasks): start T-208 per-frame fall decision diagnostics
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-21 23:10:53 +08:00
ilaandClaude Opus 4.8 1471e7ce78 feat(v1): configurable low-latency capture options
Config gains source.transport (tcp/udp), timeout_seconds and low_latency;
build_ffmpeg_options assembles OPENCV_FFMPEG_CAPTURE_OPTIONS and app.py
sets it into the environment before opening the stream, so tuning lives
in config/settings instead of a launch script. Settings tab exposes a
dropdown/number/checkbox rather than the raw option string. 64 tests pass.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-21 22:56:14 +08:00
ilaandClaude Opus 4.8 8c03d5b7e2 chore(tasks): start T-207 low-latency capture options in config
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-21 22:51:49 +08:00
ilaandClaude Opus 4.8 2603a10fb1 feat(v1): settings camera connection test and preview
Settings tab gains a camera group (host/port/channel/user/masked password),
a background connection-test worker that probes one frame off the GUI
thread and shows it in a preview, and a save button that writes the
structured source to the untracked config.local.json. 60 tests pass;
Qt shell compiles and needs a Windows smoke.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-21 22:44:09 +08:00
ilaandClaude Opus 4.8 59925b8e30 chore(tasks): start T-206 structured camera config and connection test
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-21 22:34:59 +08:00
ilaandClaude Opus 4.8 61b43e276d chore(tasks): start T-203 with live Hikvision stream verified
VideoSource STREAM connects to the real camera (1920x1080, monotonic
timestamps) and a bad address goes to retrying without alarm. Credentials
stay in the SILVER_POSE_RTSP_URL env var only; no address in the repo.
GUI preview and live pose overlay remain to be smoked on Windows.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-21 21:45:07 +08:00
ilaandClaude Opus 4.8 04422d9ca0 fix(v1): wire model confidence, explicit source mode, unique event ids
A: PoseAdapter.set_confidence_threshold is applied on start, so the
   settings model-confidence field actually affects inference.
B: config source.mode ('stream'|'replay') is explicit; app no longer
   guesses the source type from the URL prefix.
C: FallStateMachine takes a session_id and from_config generates a
   unique one per run, so event ids never collide across restarts
   (no screenshot overwrite or duplicate JSONL identity in a day).

51 tests pass.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-21 20:54:34 +08:00
ilaandClaude Opus 4.8 7443a8f031 chore(tasks): block T-203..T-205 pending on-site stream and recordings
Reconnect/state/idempotency logic is implemented and unit-tested; the
unmet acceptance is on-site Hikvision preview (T-203) and consented fall
and counter-example recordings with field safety (T-204, T-205). Not
marked DONE without real observable evidence.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-21 19:50:19 +08:00
ilaandClaude Opus 4.8 afe7a5e781 feat(v1): add local alerts, screenshot and JSONL event log
AlertDispatcher de-duplicates by event_id and fires each side effect once
per CONFIRMED: annotated screenshot, one JSONL line (config_version,
source_id, no rtsp/credentials), sound and popup via injectable sink.
44 tests pass; real-frame artifact smoke verified.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-21 19:49:20 +08:00
ilaandClaude Opus 4.8 861532ffb0 chore(tasks): start T-202 local alerts and event log
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-21 19:44:36 +08:00
ilaandClaude Opus 4.8 289f781134 feat(v1): add PyQt dual-tab monitor and settings UI
Qt-free view_model builds monitor view state and isolates the settings
draft from the running config snapshot; gui.py/app.py are a thin PyQt5
shell that only renders already-decided FrameAnalysis. 39 tests pass.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-21 19:43:49 +08:00