From 098ccb0006c653db1aeaad6e6567fa0bef7978d5 Mon Sep 17 00:00:00 2001 From: cfdaily Date: Sun, 31 May 2026 07:02:12 +0800 Subject: [PATCH] auto-sync: 2026-05-31 07:02:12 (catch-all) --- src/main.py | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/main.py b/src/main.py index e361589..e14aa36 100644 --- a/src/main.py +++ b/src/main.py @@ -134,6 +134,15 @@ async def lifespan(app: FastAPI): max_concurrent_sessions=daemon_config.get("max_concurrent_sessions", 3), default_cooldown_seconds=daemon_config.get("cooldown_seconds", 120), ) + # BootstrapBuilder(L2 引擎注入层) + template_dir = DATA_ROOT.parent / "prompt_templates" + if not template_dir.exists(): + template_dir = Path("prompt_templates") + bootstrap_builder = BootstrapBuilder( + template_dir=template_dir, + max_tokens=4096, + ) + spawner = AgentSpawner( dry_run=False, agent_timeout=daemon_config.get("agent_timeout", 630), @@ -143,6 +152,7 @@ async def lifespan(app: FastAPI): api_host=api_host, api_port=api_port, counter=counter, + bootstrap_builder=bootstrap_builder, ) # 构建 Agent 能力画像(v2.6.1 路由)