From 782f326a34e5a4e73cb20c9d0ba3b9e0cac30903 Mon Sep 17 00:00:00 2001 From: Accusys Date: Mon, 28 Sep 2026 02:10:19 +0800 Subject: [PATCH] feat: add TKG processor config support MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 新增: - TKG (Temporal Knowledge Graph) 處理器配置 - ToolSelector 支持 TKG 工具 工具優先級: 1. python (priority=0, enabled=true) - 腳本: store_traced_faces.py 2. rust (priority=1, enabled=false) - 待實現 ToolSelector 支持: - store_traced_faces.py - rust_tkg (未來) 目的: - 統一所有處理器配置架構 - 支持 TKG 配置驅動 --- config/processor_tools.json | 18 ++++++++++++++++++ src/core/processor/tool_selector.rs | 10 ++++++++++ 2 files changed, 28 insertions(+) diff --git a/config/processor_tools.json b/config/processor_tools.json index 45deb546..65d781a8 100644 --- a/config/processor_tools.json +++ b/config/processor_tools.json @@ -167,6 +167,24 @@ ], "default_tool": "python", "enabled": true + }, + "tkg": { + "tools": [ + { + "name": "python", + "priority": 0, + "enabled": true, + "parameters": {} + }, + { + "name": "rust", + "priority": 1, + "enabled": false, + "parameters": {} + } + ], + "default_tool": "python", + "enabled": true } } } diff --git a/src/core/processor/tool_selector.rs b/src/core/processor/tool_selector.rs index 50777d14..cfaf728a 100644 --- a/src/core/processor/tool_selector.rs +++ b/src/core/processor/tool_selector.rs @@ -162,6 +162,16 @@ impl ToolSelector { if script.exists() { Some(script) } else { None } } + // TKG (Temporal Knowledge Graph) tools + ("tkg", "python") => { + let script = executor.script_path("store_traced_faces.py"); + if script.exists() { Some(script) } else { None } + } + ("tkg", "rust") => { + // Future: Rust TKG implementation + executor.rust_binary_path("rust_tkg") + } + _ => None, } }