Commit Graph

87 Commits

Author SHA1 Message Date
Accusys 6c4c645337 docs: record charade pre_chunks cleanup (9.28M→57K rows, 19G→130M) 2026-08-16 08:49:11 +08:00
Accusys 0533248f2c fix: workspace pre_chunks dedup — stop 19GB re-dispatch bloat (A1) + charade analysis 2026-08-16 08:44:29 +08:00
Accusys 575623c765 docs: add cross-video FaceNet analysis report (WD vs KOBA)
- Completed FaceNet experiments on KOBA video (120 samples)
- Cross-video analysis confirms:
  - Face size impact on stability is CONSISTENT (Large > Medium > Small)
  - Bbox quality is CONSISTENT (Apple Vision ≈ MediaPipe)
  - Recognition accuracy depends on video content
- Key recommendations:
  - Minimum face size: 80px
  - Bbox strategy: Apple Vision (default) or MediaPipe (efficient)
  - Quality metric: Minimum similarity > 0.70
- Based on 240 total samples across 2 videos
2026-08-09 15:57:10 +08:00
Accusys 1f71ab4e14 docs: add FaceNet retest analysis report
- Completed 3 experiments using real FaceNet model (Inception ResNet V1)
- Key findings:
  - Large faces (>150px) have highest stability (0.9995)
  - Apple Vision and MediaPipe bboxes produce identical quality (0.899)
  - Face size affects recognition accuracy lower bound (0.760 vs 0.648)
- Recommendations:
  - Minimum face size: 80px
  - Ideal face size: >150px
  - Both AV and MP bboxes are acceptable
- Included detailed comparison with simplified model results
2026-08-09 14:43:33 +08:00
Accusys 61b774ab0b docs: add embedding vs face size analysis report
- Completed 3 experiments on WD video with 120 samples
- Key findings:
  - Apple Vision bbox produces higher quality embeddings (0.841 vs 0.748)
  - MediaPipe bbox is more precise but lower quality
  - Recommendation: Use Apple Vision bbox for embedding calculation
- Included detailed methodology, results, and recommendations
- Suggested bbox selection strategy and size filtering thresholds
2026-08-09 14:25:44 +08:00
Accusys 496895422f docs: add MediaPipe threshold POC report
- Tested confidence thresholds: 0.1, 0.2, 0.3, 0.4, 0.5
- Key finding: 0.3 is optimal threshold
  - Zero false positives (correctly rejects frames 671, 1116)
  - Same detection rate as 0.5 (100%)
  - More permissive than 0.5, may detect more faces in other videos
- Recommendation: Use 0.3 as default min_confidence for MediaPipe
- Updated dual-source filtering strategy:
  - Apple Vision: primary detector (min_confidence=0.5, min_size=1)
  - MediaPipe: verifier (min_confidence=0.3)
2026-08-09 13:36:51 +08:00
Accusys e1eae6a3d9 test: MediaPipe 1.0.0 vs 0.10.35 comparison results
- Upgraded MediaPipe from 0.10.35 to 1.0.0
- Re-ran same frame comparison experiment
- Key finding: MediaPipe 1.0.0 and 0.10.35 have identical performance
- Both versions: 2.5% recall, 100% precision (zero false positives)
- Apple Vision: 96.1% recall, 0% precision (3 false positives)
- Conclusion: MediaPipe is very conservative but reliable for false positive rejection
2026-08-09 12:55:49 +08:00
Accusys c7690f43d2 docs: add MediaPipe vs Apple Vision landmark comparison report
- Parallel detection on same frames (0, 3, 6, 9, 100, 200, 300, 400, 500, 671, 800, 1000, 1116, 1500)
- MediaPipe saves results as .mp_face.json format
- Key finding: MediaPipe 100% rejects false positives (frames 671, 1116)
- Trade-off: MediaPipe has lower recall (62.5% vs 100% for Apple Vision)
- Recommendation: Consider combining both detectors for best precision/recall balance
2026-08-09 12:42:56 +08:00
Accusys 5045d9f679 docs: update face_settings guide with correct log verification steps
- Updated log paths and examples to match actual implementation
- Added [WORKER] log verification
- Fixed swift_face log path (file_uuid.face_detect.json.log)
2026-08-08 23:24:08 +08:00
Accusys 658f509500 fix: pass face_settings to create_monitor_job in register and process endpoints
- files.rs: register_file now converts FaceSettings to json and passes to create_monitor_job
- processing.rs: ProcessRequest now includes face_settings field
- processing.rs: trigger_processing now passes face_settings to create_monitor_job and updates existing jobs
- docs: updated API examples to use correct endpoints (/api/v1/files/register and /api/v1/files/:uuid/process)
2026-08-08 22:16:06 +08:00
Accusys d5c7fd91d9 docs: add face_settings studio guide for Studio team reference
- Complete guide for FACE_MIN_CONFIDENCE and FACE_MIN_SIZE configuration
- Includes environment variable setup (shell export + launchd plist)
- API parameter examples with curl commands
- Log verification steps for all three layers (Rust/Python/Swift)
- Recommended values for different scenarios
- Database schema documentation
- FAQ section for common issues
2026-08-08 21:55:25 +08:00
Accusys 3d13a06bd9 feat: face fix deployment + trace_* regeneration + executor stderr filter fix
- swift_face.swift: frame rounding (.rounded()), conf 0.75, min_size 64
- trace_* directories regenerated for KOBA (37 traces, start_frame 5307)
- executor.rs: stderr filter now logs all non-empty stderr (was discarding)
- VAD not skippable in ASRX (main_fixed.py Step 2 always runs)
- Step 2.5 sentence boundary refinement added
- Cluster agent async endpoints + similarity transparency
- Keyword search: relationship text extraction, priority ordering
- Face fix handoff doc for Studio team
2026-08-05 00:13:50 +08:00
Accusys e22393d577 feat: permanent trace delete (mode:delete) + best-face fields in /traces
- delete_trace: add mode:'delete' → permanent removal (Qdrant points,
  trace_profiles, tkg_nodes, on-disk files), no undo/history written
- list_unassigned_traces: exclude status=deleted (REQ-2), consistent
  with /traces endpoint
- /traces: return real best_face_id/frame/confidence/bbox (highest
  confidence face per trace) instead of start_frame/avg_confidence
- docs: Studio delete Core req + FS detail fix patch + handoff v2
2026-08-02 14:18:44 +08:00
Accusys 1602656fb6 docs: add trace-thumb endpoint to Studio handoff 2026-08-01 02:28:52 +08:00
Accusys d7980133e9 docs: update Studio handoff with Core API配套 changes
Added Core API optimizations already deployed:
- Thumbnail API uses pre-cached key_face.jpg (8ms vs 500ms)
- Face-groups API supports ?include_trace_ids=false (-48% payload)

Updated Studio instructions to use these new endpoints.
2026-08-01 02:12:43 +08:00
Accusys 4ca967e979 docs: Studio face group performance optimization handoff
Document for Studio team to implement lazy loading + concurrency increase
for face group thumbnail loading. Expected improvement: Charade load time
from ~76s to <2s.
2026-08-01 01:58:50 +08:00
Accusys aab727b297 docs: trace_profile UPSERT fixes + Studio face group API gap analysis
- profile.rs: single/group/merge_groups/undo all use upsert_trace_profile
- trace_agent_api.rs: hard delete/merge snapshot + delete trace_profiles
- cluster_agent.rs, job_worker.rs: background name writes use UPSERT
- schema.rs: upsert_trace_profile helper (backfill from tkg_nodes)
- Studio 3 API gaps documented (cluster-results/identity-matches/similar)
2026-07-31 11:16:18 +08:00
Accusys 7272077b65 docs: trace_profile UPSERT fix plan with delete/undo/restore flow diagrams 2026-07-31 10:46:31 +08:00
Accusys 39a2cbc65b fix: face group name read consistency, sync_file_status fix, cleanup ghost records, identity_agent replaced with face_dedup
- get_face_groups_handler: COALESCE(tp.name, tn.label) for name consistency
- sync_file_status: compare JSON vs pre_chunks (not chunk table)
- face consistency: compare frames.len() not total_faces
- cleanup 2 ghost records with NULL file_name/file_path
- replace identity_agent with face_dedup in pipeline stages
- remove identity_agent_api.rs and all references
- update required_processors to match actual processors
- update AGENTS.md with team responsibilities
- add Studio pipeline changes documentation
2026-07-27 02:15:51 +08:00
Accusys 244af51edf docs: add file status sync API delivery document for Studio team 2026-07-19 22:00:34 +08:00
Accusys 84dda3b5bc docs: add full file paths section to pose/appearance POC document 2026-07-19 20:45:42 +08:00
Accusys d0b7bfa56b feat: add pose and appearance endpoints for face detail display
- Add GET /api/v1/file/:file_uuid/pose endpoint
- Add GET /api/v1/file/:file_uuid/appearance endpoint
- Keypoint deduplication (highest confidence)
- Add face-groups endpoint for Studio integration
- Add profile routes (trace-profile, file-profile)
- Update API documentation
2026-07-19 20:43:35 +08:00
Accusys 3eabd45882 fix: ASRX duplication, TKG edges, trace ingest, and add pipeline progress publishing
- ASRX handler no longer stores duplicate 'asr' pre_chunks
- Pre_chunks storage made idempotent (delete-before-insert)
- Rule 1 + trace_ingest changed to query 'asrx' not 'asr'
- Trace chunks removed (dynamic from TKG/Qdrant)
- TKG scroll_face_points fixed: trace_id >= 1 (not == 1)
- TKG AsrxSegmentEntry: start/end -> start_time/end_time (match ASRX JSON)
- Unregister error handling: log instead of silent discard
- Add publish_pipeline_progress calls at each pipeline stage
  (processors, rule1, face_trace, identity_agent, TKG, rule2, completion)
2026-07-02 10:43:46 +08:00
Accusys 4273576612 feat: implement skin_tone_trace node builder and standardize TKG node naming
- Add build_skin_tone_trace_nodes() to tkg.rs (Fitzpatrick I-VI classification)
- Add skin_tone_trace_nodes field to TkgResult
- Standardize node naming: _trace -> _track (text uses _region)
- Add external_id format column to Node Types table
- Add storage names to Edge Types table
- Create TKG_FORMATION_V1.0.md with Phase 0-4 definition, flow diagram, queries
- Add cross-reference from identity_agent_v4.0.md to TKG Formation
- Update Python scripts to executable mode
2026-06-25 03:09:16 +08:00
Accusys 406b2d5524 docs: update TKG documentation for Identity Agent V4.0
- Add new file: 2026-06-25_identity_agent_v4.0.md (M4 workspace)
  - Complete architecture overview
  - All phases completed
  - Thresholds, components, test results

- Update: API_WORKSPACE/modules/15_tkg.md
  - Correct node type: face_trace → face_track
  - Add text_region (replaces text_trace)
  - Add Identity Agent integration section
  - face_track status values (pending/suggested/confirmed/stranger)
  - Example face_track node with identity properties
2026-06-25 02:27:34 +08:00
Accusys 7e548f8b08 release: v1.3.0 - TKG node type renaming
Changes:
- Rust: face_trace → face_track (45 occurrences in 8 files)
- Rust: gaze_trace → gaze_track, lip_trace → lip_track
- Python: tkg_builder.py unified + pipeline_checklist.py fixed
- Swift: swift_hand.swift hand state detection (empty vs holding)

Node type changes:
  face_trace    → face_track
  person_trace  → body_track
  gaze_trace    → gaze_track
  lip_trace     → lip_track
  hand_trace    → hand_track
  speaker       → speaker_segment
  object        → detected_object
  text_trace    → text_region

Migration:
  PUBLIC schema: 12970 + 892 + 305 rows updated
2026-06-22 07:18:21 +08:00
Accusys 01dae66285 test: Production (3002) Phase 2.6-2.7 release test
Test Results:
- Health check: 20 identities ✅
- File info: Success ✅
- Rule2 chunks: 75 ✅
- TKG rebuild: Failed (face.json missing)

Status:
- Phase 2.6-2.7 code: Implemented ✅
- PostgreSQL fallback: Active (Qdrant empty)
- Rule2 identity resolution: Working ✅
- Qdrant collection: Green, 0 points

Recommendations:
- Keep Production running with PostgreSQL fallback
- New videos will auto-fill Qdrant collection
- Production performance: ~1.85s (PG fallback)
2026-06-21 05:20:39 +08:00
Accusys 2cfcfdd1af feat: Phase 2.6 edges migration to Qdrant (TKG-only architecture)
Phase 2.6.1: co_occurrence_edges migration
- build_co_occurrence_edges_from_qdrant()
- Qdrant embeddings → frame grouping → YOLO objects
- Result: 6679 edges (vs 6701 PostgreSQL)

Phase 2.6.2: face_face_edges migration
- build_face_face_edges_from_qdrant()
- Qdrant embeddings → frame grouping → face pairs
- mutual_gaze detection preserved
- Result: 6 edges (exact match)

Phase 2.6.3: speaker_face_edges migration
- build_speaker_face_edges_from_qdrant()
- Qdrant embeddings → trace_id frame ranges
- SPEAKS_AS edge creation

Architecture:
- All edges use Qdrant payload (no face_detections queries)
- PostgreSQL fallback for empty Qdrant
- Estimated 3.6x performance improvement

Testing:
- Playground (3003): ✓ All Phase 2.6 logs verified
- Edge counts: ✓ Close match with PostgreSQL
- Fallback: ✓ Working

Docs:
- docs_v1.0/DESIGN/TKG_PHASE2_6_EDGES_MIGRATION.md
- docs_v1.0/M4_workspace/2026-06-21_phase2_6_test.md
2026-06-21 04:47:49 +08:00
Accusys 0afc70fc5b test: Production (3002) Phase 2.5 release verification
Test results:
- TKG rebuild: 1.75s (2.4x faster than Playground)
- gaze_trace_nodes: 21 (PostgreSQL fallback)
- lip_trace_nodes: 21 (PostgreSQL fallback)
- Rule2 chunks: 75 ✓

Findings:
- Production faster than Playground (1.75s vs 4.2s)
- Qdrant collection empty (0 points)
- Using PostgreSQL fallback for Phase 2.5
- New videos will auto-populate Qdrant

Status: ✅ Release successful
2026-06-21 04:31:52 +08:00
Accusys c39805bb8e feat: Phase 2.5 gaze_trace and lip_trace Qdrant migration + Charade Q&A test
Phase 2.5.1: gaze_trace_nodes from Qdrant
- build_gaze_trace_nodes_from_qdrant()
- Read trace_id, frame, bbox from Qdrant payload
- Compute gaze stats (yaw, pitch, roll, gaze direction, blink)
- No PostgreSQL face_detections dependency

Phase 2.5.2: lip_trace_nodes from Qdrant + face.json
- build_lip_trace_nodes_from_qdrant()
- Match trace_id using Qdrant embeddings + face.json bbox
- Compute lip stats (openness, variance, speaking frames)
- Fixed face.json bbox structure (x,y,width,height not bbox object)

Test results:
- 23 gaze_trace nodes from Qdrant
- 23 lip_trace nodes from Qdrant + face.json
- 51 lip_sync edges created
- Charade Q&A: 20 identities, 75 relationship chunks

Docs:
- TKG_PHASE2_NONFACE_MIGRATION_V1.0.md (migration plan)
- 2026-06-21_charade_qa_test.md (Q&A test report)
2026-06-21 02:17:08 +08:00
Accusys 23c440104b feat: Phase 2-3 TKG-only architecture
Phase 2.1: build_face_trace_nodes_from_qdrant()
- Read trace_id, frame, bbox directly from Qdrant payload
- No dependency on face_detections table

Phase 2.3: Rule2 queries TKG nodes
- identity resolution from tkg_nodes.properties.identity_id
- TKG-only architecture (Phase 2.3)

Phase 3: Identity Agent updates TKG nodes
- match_faces_iterative() updates tkg_nodes.properties
- bind_identity_trace() syncs identity_id to TKG
- unbind_identity() removes identity_id from TKG

Test results:
- 23 face_trace nodes from Qdrant (Phase 2.1)
- 75 relationship chunks (Rule2)
- TKG rebuild: Phase0 → Phase1 → Phase2
2026-06-21 01:30:04 +08:00
Accusys e1572907ae feat: ASRX hybrid pipeline, identity history, worker fixes, checkpoint system 2026-06-02 07:13:23 +08:00
Accusys 874d688987 feat: deploy hybrid search (semantic+keyword+identity) with RRF fusion
- Replace smart_search with hybrid RRF implementation
- Add speaker_detections table for identity-agent binding
- Fix identity queries: direct SQL to avoid type mismatches
- Add debug logs to job_worker for processor debugging
- Deployed to production (3002) successfully

Key changes:
- search.rs: Complete rewrite with 3 strategies + RRF
- postgres_db.rs: speaker_detections table + identity query fixes
- job_worker.rs: Debug logs for output file checks

Tested:
- Hybrid search works with semantic + keyword + identity
- Identity search: 'identity:Charade' returns correct results
- Chinese keyword search: '調光' matches Charade summaries

Bugs found:
- Case mismatch: 'ASRX' vs 'asrx' in processors field
- Missing CUT dependency for ASRX processor
2026-06-01 15:15:17 +08:00
Accusys 04cbb71ca0 docs: save handoff - library page flash & filter fix 2026-05-29 23:12:09 +08:00
Accusys e96cc8c8de docs: record WordPress API URL update session progress 2026-05-29 19:06:15 +08:00
Accusys eec2eea880 docs: file_uuid generation rules for M4 2026-05-17 02:26:09 +08:00
Accusys 3a6c186575 docs: add REFERENCE docs, M4 workspace, Caddyfile 2026-05-16 03:11:32 +08:00
Accusys 9cf20d3f8e docs: reclassify — DESIGN→STANDARDS, conversion→M5_workspace, cleanup 2026-05-15 12:18:29 +08:00
Accusys 802beb2db6 docs: RCA — identity_uuid missing + file identities NULL appearance 2026-05-15 10:59:23 +08:00
Accusys a66bd6b7c2 chore: track M4's register_api_404 report 2026-05-15 03:28:38 +08:00
Accusys 263f017972 revert: remove /api/v1/register alias — not a valid endpoint, corrected M4 to use /api/v1/files/register 2026-05-15 03:12:32 +08:00
Accusys e5f2bba248 fix: add /api/v1/register alias for backward compatibility 2026-05-15 03:08:56 +08:00
Accusys 11f690ca35 docs: fix start/end → start_frame/end_frame in API docs 2026-05-14 17:57:00 +08:00
Accusys 26f243428d docs: pipeline services checklist for M4 2026-05-14 17:05:18 +08:00
Accusys c589eb10cf docs: respond to M4 binary crash analysis 2026-05-14 16:32:02 +08:00
Accusys 159684331e feat: GDINO A+B — time-bounded search (9s vs 130s) + parameterized interval 2026-05-14 13:57:25 +08:00
Accusys 2b633174b9 docs: reply to M4 with freshly built binary from HEAD 2026-05-14 03:45:55 +08:00
Accusys 0bd23fabd0 docs: M5 progress report — face tracker, bug fixes, pipeline 2026-05-14 03:37:01 +08:00
Accusys 79e455cc3d docs: deliver cut-based trace merge package 2026-05-14 03:12:55 +08:00
Accusys 4e933a554c docs: reply to M4 on trace schema hardcode fix 2026-05-14 02:56:59 +08:00