docs(logbook): 記錄 2026-04-25 自動化飛輪四修 + Hermes + qwen3
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -6,7 +6,36 @@
|
||||
|
||||
---
|
||||
|
||||
## 🎯 2026-04-25(進行中)| AI 信心度 + Kubectl 安全防禦三層修復 ✅ 部署完成
|
||||
## 🎯 2026-04-25(進行中)| 自動化飛輪修復 × 4 + Hermes Ollama + qwen3:8b ✅
|
||||
|
||||
### B1:auto_execute 被 _ALLOWED_KUBECTL_PATTERN 全攔
|
||||
- **根因**: LLM 輸出 `kubectl rollout restart deployment <name>` 含 `deployment` keyword
|
||||
→ pattern 只允許直接接名稱 → `_action_safe=False` → 所有 low risk 告警降人工
|
||||
- **修法**: Pattern 加 `(?:(?:deployment|pod|...)\s+)?` optional group + `re.ASCII`
|
||||
- **驗證**: 12/12 test cases ✅,`auto_execute_blocked_unresolved_placeholder` 消失
|
||||
|
||||
### B2:auto_execute 路徑 KM 寫入斷鏈
|
||||
- **根因**: `_write_execution_result_to_km` 只在人工審核路徑呼叫
|
||||
- **修法**: `_auto_execute()` 完成後補 `_fire_and_forget(executor._write_execution_result_to_km)`
|
||||
|
||||
### B3:Hermes 回應為空(Claude Agent SDK → Ollama)
|
||||
- **根因**: `claude-agent-sdk` 需 `claude` CLI,K8s pod 無此 CLI
|
||||
- **修法**: 改 httpx + Ollama 本地模型(111 主機),零費用
|
||||
|
||||
### B4:Ollama 模型升級 qwen3:8b
|
||||
- qwen2.5-coder:7b + qwen2.5:7b-instruct → 統一改 qwen3:8b(Hybrid Thinking,4.9GB)
|
||||
- 111 主機 pull 完成,`gemma4` 尚未在 Ollama 釋出(保留 gemma3:4b)
|
||||
|
||||
### 部署狀態
|
||||
| Commit | 內容 | CI/CD |
|
||||
|--------|------|-------|
|
||||
| 6baa5054 | B1+B2 auto_execute 修復 | 🔄 進行中 |
|
||||
| 7b6df17d | qwen3:8b 模型路由 | 🔄 進行中 |
|
||||
| 250eca99 | Hermes Ollama 取代 SDK | ✅ 部署完成 |
|
||||
|
||||
---
|
||||
|
||||
## ✅ 2026-04-25(上午)| AI 信心度 + Kubectl 安全防禦三層修復 ✅ 部署完成
|
||||
|
||||
### 問題診斷
|
||||
- **症狀**: Telegram 告警 PHASE2_AGENTS 🔴 信心度 20-50%,自動化決策頻率低
|
||||
|
||||
Reference in New Issue
Block a user