- Added GET /api/v1/file/:uuid/data-consistency endpoint
Checks consistency across tkg_nodes, trace_profiles, FS trace dirs, and Qdrant
- Marked 6 old face documents as deprecated with link to Face_Operations_Complete.md
- Created trace_sync module with sync_trace_label() to sync labels across:
1. tkg_nodes.label (PostgreSQL)
2. trace_profiles.name (PostgreSQL)
3. trace_profile.json label (FS)
4. Qdrant _faces payload.label (NEW - was missing)
- Fixed is_tkg_done: allow 0 trace dirs if tkg_nodes exist
(prevents permanent stuck in 'Scanning' status)
- Updated Face Cluster to use sync_trace_label
- Updated merge_trace to use sync_trace_label + cleanup source dir
- Created Face_Operations_Complete.md reference document
(consolidates all face-related docs into single source of truth)
- Added endpoint to serve trace_profile.json files
- Fixes Studio proxy bug (missing file_uuid in path)
- Studio proxy at proxy.rs:809 constructs path without file_uuid
- Core endpoint now provides correct implementation
- Studio can proxy to this endpoint instead of local file reading
- Worker was calling Python store_traced_faces.py instead of Rust version
- This caused trace_id=0 in Qdrant, blocking TKG and file completion
- Now uses rust_binary_path() to find and execute rust_store_traced_faces
- Also removed all Python implementations from processor config
- Removed POSE processor (deprecated)
- Added redis_publisher.py symlink for face clustering
Fixed: file stuck in 'Scanning' due to trace stability check failure
- Add DynamicSemaphore, SystemMonitor, VlmMonitor, AutoScaler
- Replace static SCENE_VLM_SEM with dynamic version (max: 3)
- Start AutoScaler in Worker::run() for automatic adjustment
- Configured for M5Max48: 48GB, thresholds at 38GB/41GB
- Expected processing time: 23-28 days for 10000 files
Note: VLM response tracking to be added separately if needed
- Update face clustering processor
- Update TKG processor
- Update Rust face cluster and trace storage
- Add M4 workspace documentation
Note: Work in progress, not yet tested
- Add TraceProfilePath struct for path parameters
- Refactor get_trace_profile_handler to support both formats:
- Query parameters: /api/v1/trace-profile?file_uuid=...&trace_id=...
- Path parameters: /api/v1/trace-profile/:file_uuid/:trace_id
- Maintain backward compatibility with existing query parameter format
- Fix 404 error when Studio calls trace profile API with path format
Fixes: Studio right-click key frame trace profile error
Deployment: Released to production (3002) on 2026-10-17
## Problem
- Rust Face Tracing only generated face_traced.json
- Did not update trace_id in Qdrant
- Caused trace_id to remain null in Qdrant
- Face Clustering failed due to missing trace_ids
## Solution
Added two functions:
- build_trace_mapping(): Build (frame, bbox) -> trace_id mapping
- update_qdrant_trace_ids(): Batch update Qdrant points with trace_ids
## Flow
1. Read embeddings from Qdrant
2. Calculate traces (IoU + Similarity)
3. Generate face_traced.json
4. Update trace_ids in Qdrant (NEW)
## Testing
- Previous: trace_id=null in Qdrant
- After: trace_id correctly set
- Face Clustering now works
## Files Changed
- tools/cli/rust/src/bin/rust_store_traced_faces.rs
Closes #QDRANT_TRACE_ID_NULL
Core changes:
- Face clustering threshold: 0.35 → 0.15 (better male/female separation)
- Add auto-filtering for low-quality clusters (face_count<20, bbox_area>150000)
- Add filesystem fallback for trace-profile API
Face clustering improvements:
- Correctly separates male and female faces
- Filters hand detections and isolated faces
- Result: 2 persons (186 male, 174 female) vs 4 persons before
Trace profile API:
- GET /api/v1/trace-profile?file_uuid=X&trace_id=Y
- Returns data from PostgreSQL or filesystem fallback
- Simplifies frontend: no need to know filesystem structure
- Fixes Studio 'trace profile not found' error
Issue: docs_v1.0/M4_workspace/2026-10-16_studio_trace_profile_bug_report.md
Consolidated snapshot (previously WIP in working tree).
- core/pipeline_config: new module loading config/pipeline_flows.json as the
source of truth for stage execution mode (parallel/blocking) and dependencies
- worker/job_worker: dispatch Scene VLM to a background task when the stage is
declared parallel, unblocking the worker poll loop; resolve processor
dependencies from pipeline_flows.json (fallback to built-in)
- config/pipeline_flows.json: asrx depends on [cut, asr]
- scripts/fix_stuck_jobs: fix UTC timezone comparison, raise default threshold
to 6h, skip jobs with recent processor activity
- rust_asrx: Rust speaker diarization CLI + processor wiring
- processor metadata helper; fast_face_clustering script; file_progress pipeline
API; scan API; VAD updates
Major Changes:
- Pipeline Queue integration completed (internal.file + pipeline.commands)
- Fixed old job_worker database compatibility with new command_queue table
- Compiled Swift OCR binary (was missing, causing empty OCR results)
- Added deep scan functionality through re-scan API
Fixes:
- Changed CommandJob.id from i32 to i64 for database compatibility
- Added UUID generation in create_command (message_id field)
- Fixed claim_pending_commands to query queue_name = 'internal.file'
- Fixed field mappings: command_id → message_id, job_type → command_type
- Added support for 'processing' status in CommandJobStatus
Queue System:
- internal.file queue: for register/unregister/re-scan commands (job_worker)
- pipeline.commands queue: for vectorize/store_asrx/etc commands (pipeline_worker)
Documentation:
- Added comprehensive queue system documentation
- Created M4 workspace status reports
- Updated AGENTS.md with queue system details
- Core API now calls MarkBase API instead of scanning filesystem
- Returns file_uuid and file_path from MarkBase
- Merges Core database registration status
- Returns 176 files (116 from MarkBase + 60 registered but deleted)
- Tested and verified on M5Max128
Related: #markbase-integration
Issue: Files with face_traced.json status=null and total_faces=0 stuck in PROCESSING forever
Root cause:
- ingestion_complete checks trace_status == 'no_faces' to skip TKG
- But some old files have status=null instead of 'no_faces'
- TKG check fails because no nodes for no-face videos
Solution:
- Check both status='no_faces' AND total_faces=0
- Skip TKG check for no-face videos (total_faces=0)
- Also update face_cluster_done to handle total_faces=0
Impact:
- Fixes stuck files with null status in face_traced.json
- Consistent with scan.rs fix (commit 0d11c601)
Affected: M4ProMini file 18173b62d80bf829910348fa1a6ddcf5
- Gemma4 returns both content and reasoning_content
- reasoning_content is the thinking process, not the final answer
- content contains the actual scene description
- Changed priority: content first, reasoning_content as fallback
Fixes: Scene VLM generated 0 descriptions issue
Root cause: Using reasoning_content (thinking) instead of content (answer)
- Document 60s timeout implementation
- Provide frontend configuration guide
- List test results and query optimization tips
- Add monitoring and logging guidelines