feat: 시스템 상태 질문 사전 라우팅 — 추론 모델/서버 상태 조회
"추론 모델 일하고 있어?" → backend health 체크 후 직접 응답 Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -149,6 +149,16 @@ def _pre_route(message: str) -> dict | None:
|
||||
if query:
|
||||
return {"action": "tools", "tool": "document", "operation": "search", "params": {"query": query}}
|
||||
|
||||
# 시스템 상태 질문
|
||||
if any(k in msg for k in ["추론 모델", "gemma", "젬마", "상태", "서버 상태", "시스템"]) and any(k in msg for k in ["돌아", "일하", "작동", "상태", "건강", "살아"]):
|
||||
health = backend_registry.health_summary()
|
||||
lines = []
|
||||
for role, info in health.items():
|
||||
status = "✅ 정상" if info["healthy"] else "❌ 연결 안 됨"
|
||||
lines.append(f"• {info['name']} ({role}): {status} ({info['latency_ms']:.0f}ms)")
|
||||
status_text = "\n".join(lines)
|
||||
return {"action": "direct", "response": f"현재 시스템 상태야:\n{status_text}", "prompt": ""}
|
||||
|
||||
# pending_draft 확인 응답
|
||||
if msg in ("확인", "예", "yes", "ㅇㅇ", "응", "네", "좋아", "ok"):
|
||||
return {"action": "tools", "tool": "calendar", "operation": "create_confirmed", "params": {}}
|
||||
|
||||
Reference in New Issue
Block a user