fix(p0): 實測修正 — timeout 依 benchmark 調整,_local_fallback_chain 移除雲端 Nemotron
- config.py: NEMOTRON_DIAGNOSE_TIMEOUT_SECONDS=60s (NIM 實測 11-45s + 15s buffer) - config.py: OLLAMA_DIAGNOSE_TIMEOUT_SECONDS=200s (Ollama 實測 ~173s + 27s buffer) - ollama.py: 新增 per-task timeout (diagnose/force_local 用 200s) - ai_router.py: _local_fallback_chain 移除 Nemotron (NIM=雲端,不可進 local chain) - ai_router.py: v4.2 — Option C 分情境路由正式確立 Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -85,13 +85,16 @@ class Settings(BaseSettings):
|
||||
description="Phase 22: True=異步更新 (先推 OpenClaw), False=同步等待",
|
||||
)
|
||||
# 2026-04-04 ogt: Phase 25 P0 — DIAGNOSE Privacy-First 專用 timeout
|
||||
# 實測依據 (2026-04-04):
|
||||
# NIM 雲端: 11-45s (免費 tier,偶有排隊) → 60s timeout (45s + 15s buffer)
|
||||
# Ollama 本地 llama3.2:3b: ~173s 首次推理 → 200s timeout (173s + 27s buffer)
|
||||
NEMOTRON_DIAGNOSE_TIMEOUT_SECONDS: int = Field(
|
||||
default=30,
|
||||
description="Phase 25 P0: DIAGNOSE 任務 Nemotron timeout (秒),比 Tool Calling 短",
|
||||
default=60,
|
||||
description="Phase 25 P0: 一般 DIAGNOSE 任務 NIM timeout (秒),實測 11-45s,60s 含 buffer",
|
||||
)
|
||||
OLLAMA_DIAGNOSE_TIMEOUT_SECONDS: int = Field(
|
||||
default=60,
|
||||
description="Phase 25 P0: DIAGNOSE 任務 Ollama backup timeout (秒),Ollama 較慢",
|
||||
default=200,
|
||||
description="Phase 25 P0: FORCE_LOCAL DIAGNOSE Ollama timeout (秒),實測 ~173s,200s 含 buffer",
|
||||
)
|
||||
|
||||
# ==========================================================================
|
||||
|
||||
Reference in New Issue
Block a user