Files
momentry_core/config/admin_config.json
T
Accusys 0fe09afdb6 fix: prevent 'running' status deadlock in worker
** Problem:
- Worker set processor status to 'running' BEFORE checking capacity
- If capacity limit reached, processor was skipped but status stuck at 'running'
- Worker would skip processors with 'running' status on next poll (deadlock)

** Root Cause:
- Line 591-600: update_processor_progress(..., 'running')
- Line 1434: check capacity (TOO LATE!)
- Result: status='running' but processor never started

** Fix:
- Move capacity check BEFORE setting 'running' status
- If capacity limit reached, mark as 'skipped' immediately
- Prevents 'running' status from being set when processor won't actually run

** Impact:
- Fixes UI 'Deep Scan' deadlock issue
- Workers will no longer get stuck in infinite loop
- Processor status will accurately reflect actual state

** Files Changed:
- src/worker/job_worker.rs: Moved capacity check to line 591-592
- Removed duplicate capacity check at line 1464-1493
2026-09-18 03:53:39 +08:00

137 lines
6.4 KiB
JSON

{
"filter_config": {
"face": {
"min_capture_quality": 0.25,
"min_confidence": 0.4,
"min_size": 5
}
},
"llm_config": {
"chat": {
"model": "gemma-4-12b-it",
"timeout": 300,
"url": "http://localhost:8080/v1/chat/completions"
},
"embedding": {
"model": "embeddinggemma-300m",
"timeout": 30,
"url": "http://localhost:11436/v1/embeddings"
},
"summary": {
"model": "gemma-4-12b-it",
"timeout": 300,
"url": "http://localhost:8080/v1/chat/completions"
},
"vision": {
"model": "llava-v1.6-vicuna-13b",
"timeout": 120,
"url": "http://localhost:8091/v1/chat/completions"
}
},
"processor_config": {
"face": {
"enabled": true,
"timeout": 3600
}
},
"system_config": {},
"version": "1.0.0",
"vlm_prompts": {
"rust_vlm_summary": {
"description": "Rust VLM summary for trace",
"max_tokens": 512,
"system_prompt": "You are a scene analysis assistant for a video surveillance/DAM system. Given a video key frame, write a concise summary (2-4 sentences, in the same language as the user) describing: what is happening, the people present (clothing/appearance), the setting/location, and any notable objects or actions. Be factual and specific.",
"user_prompt": "Summarize this key frame."
},
"scene_animals": {
"description": "Scene animals",
"max_tokens": 100,
"prompt": "What animals are visible? Answer in JSON: {\"has_animals\": true/false, \"animals\": [\"list recognizable names or brief descriptions\"]. Use empty list if none or unclear.}"
},
"scene_desc": {
"description": "Scene description",
"max_tokens": 100,
"prompt": "Describe this scene briefly. Include: location type, main objects, people count, activity. If uncertain, say 'unclear'. Do not guess."
},
"scene_lighting": {
"description": "Scene lighting",
"max_tokens": 20,
"prompt": "What is the lighting? Answer one word: day, night, indoor-light, mixed, or unknown."
},
"scene_location": {
"description": "Location classification",
"max_tokens": 100,
"prompt": "Classify the location. Answer in JSON: {\"location\": \"indoor/outdoor/unknown\", \"setting\": \"office/street/home/nature/studio/unknown\"}. Use 'unknown' if uncertain."
},
"scene_objects": {
"description": "Objects and vehicles",
"max_tokens": 100,
"prompt": "What notable objects or vehicles are visible? Answer in JSON: {\"vehicles\": [\"car\", \"bus\", etc.], \"objects\": [\"table\", \"chair\", etc.]}. Use empty lists if none or unclear."
},
"scene_people_count": {
"description": "People count",
"max_tokens": 20,
"prompt": "How many people are visible? Answer a number or 'unclear'."
},
"scene_plants": {
"description": "Scene plants",
"max_tokens": 100,
"prompt": "What plants are visible? Answer in JSON: {\"has_plants\": true/false, \"plants\": [\"list recognizable names or brief descriptions\"]. Use empty list if none or unclear.}"
},
"scene_tags": {
"description": "Scene tags",
"max_tokens": 50,
"prompt": "List 5 tags for this scene, comma-separated. Only include what is clearly visible. Examples: office, street, sunny, crowd, nature."
},
"scene_weather": {
"description": "Weather condition",
"max_tokens": 20,
"prompt": "If outdoor, what is the weather? Answer one word: sunny, cloudy, rainy, night, or unknown. If indoor, answer 'indoor'."
},
"trace_animals": {
"description": "Animals detection",
"max_tokens": 100,
"prompt": "What animals are clearly visible? Answer in JSON: {\"has_animals\": true/false, \"animals\": [\"list recognizable animals by name. If not recognizable, describe briefly what you see. Use empty list if none or uncertain.\"]}"
},
"trace_background": {
"description": "Background description",
"max_tokens": 100,
"prompt": "Describe the background and environment. For EACH visible object, state its COLOR and type. Include: wall color, monitor colors, furniture colors, equipment colors. If color unclear, say 'unclear'."
},
"trace_bg_tags": {
"description": "Background tags",
"max_tokens": 50,
"prompt": "List 5 tags for the background/scene, comma-separated. Examples: office, street, sunny, building, car, trees."
},
"trace_clothing": {
"description": "Clothing details",
"max_tokens": 100,
"prompt": "Describe this person's clothing in detail. For EACH item, you MUST specify the COLOR: shirt color, pants color, jacket color, hat color, glasses frame color, shoe color. Format: 'color + item' (e.g., 'black hoodie', 'blue jeans'). If color is unclear, say 'unclear color'. Do not skip colors. Include any visible text or logos."
},
"trace_desc": {
"description": "Person description",
"max_tokens": 100,
"prompt": "Describe this person briefly. For EVERY item, include COLOR: hair color, skin tone, clothing colors. If uncertain, say 'unknown color'. Be concise and honest."
},
"trace_hand_objects": {
"description": "Objects in hand",
"max_tokens": 50,
"prompt": "Look at the person's hands. What objects are they holding or touching? For EACH object, state its COLOR and type (e.g., 'red cup', 'black phone'). If hands not visible, say 'hands not visible'. If empty, say 'empty hands'."
},
"trace_lighting": {
"description": "Lighting condition",
"max_tokens": 20,
"prompt": "What is the lighting condition? Answer one word: day, night, indoor-light, mixed, or unknown. If uncertain, answer 'unknown'."
},
"trace_plants": {
"description": "Plants detection",
"max_tokens": 100,
"prompt": "What plants, trees, or flowers are clearly visible? Answer in JSON: {\"has_plants\": true/false, \"plants\": [\"list recognizable plants by name. If not recognizable, describe briefly what you see. Use empty list if none or uncertain.\"]}"
},
"trace_scene": {
"description": "Scene classification",
"max_tokens": 100,
"prompt": "Classify the scene. Answer in JSON: {\"location\": \"indoor/outdoor/unknown\", \"weather\": \"sunny/cloudy/rainy/night/unknown\", \"setting\": \"office/street/home/nature/studio/unknown\", \"transportation\": \"car/train/bus/none/unknown\"}. Use 'unknown' if uncertain."
}
}
}