OG T
|
723e8ef251
|
feat(api): Phase 21.3 Weekly Report (ADR-041)
E2E Health Check / e2e-health (push) Successful in 16s
- 新增 WeeklyReportMessage dataclass (telegram_gateway.py)
- 新增 WeeklyReportService (整合 StatsService + K3sMonitor)
- 新增 CronJob (每週五 18:00 台北)
- 新增 API 端點 (/stats/weekly/preview, /stats/weekly/report)
Phase 21 定期報告機制全部完成!
- 21.1 Daily E2E Schedule ✅
- 21.2 K3s Telegram Report ✅
- 21.3 Weekly Report ✅
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-31 11:28:46 +08:00 |
|
OG T
|
4c0f15d7b3
|
fix: 修復 3 個 P0 Bug
E2E Health Check / e2e-health (push) Successful in 18s
1. E2E Health: Docker 容器無法訪問內網 IP,改用公網域名
2. metrics_repository: asyncpg 需要 datetime 物件,不能用字串
3. metrics_repository: PostgreSQL 用 date_trunc 而非 strftime
2026-03-31 ogt: 首席架構師審查發現並修復
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-31 11:27:51 +08:00 |
|
OG T
|
b2e41ebac6
|
feat(api): Phase 21.2 K3s Status Telegram Report (ADR-041)
E2E Health Check / e2e-health (push) Successful in 19s
- 新增 K3sStatusMessage dataclass (telegram_gateway.py)
- 新增 K3sMonitorService (Prometheus 數據收集)
- 新增 CronJob (每日 09:00 台北)
- 新增 API 端點 (/stats/k3s/status, /stats/k3s/report)
Phase 21 定期報告機制 (統帥已批准)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-31 11:25:27 +08:00 |
|
OG T
|
ce6b1b1c64
|
docs: 更新 LOGBOOK - #17 i18n Hydration 完成
前端 P1 改進全部完成:
- #15 SSE + 樂觀更新 (8c8664c)
- #16 DOM Bypass (0b87018)
- #17 i18n Hydration (f25e94e)
首席架構師審查: 96/100 OUTSTANDING
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-31 11:23:38 +08:00 |
|
OG T
|
77d0fe784f
|
fix(api): AnomalyFrequency.model_dump() → to_dict() (dataclass 非 Pydantic)
E2E Health Check / e2e-health (push) Has been cancelled
CD Pipeline / build-and-deploy (push) Successful in 4m47s
2026-03-31 ogt: AnomalyFrequency 是 @dataclass,沒有 model_dump() 方法
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-31 11:14:24 +08:00 |
|
OG T
|
f771931aa0
|
fix(ai): NVIDIA cost limit /bin/zsh.00 >= /bin/zsh.00 永遠 True Bug
CD Pipeline / build-and-deploy (push) Successful in 4m43s
E2E Health Check / e2e-health (push) Successful in 20s
2026-03-31 ogt: 修復免費 Tier 設定 total_cost_usd: 0.0
導致 current_cost >= cost_limit 永遠成立的問題。
改用 999999.0 表示無成本限制。
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-31 11:08:08 +08:00 |
|
OG T
|
adaef514dc
|
feat(api): Phase C P1 Telegram Gateway OTEL 追蹤
CD Pipeline / build-and-deploy (push) Successful in 4m33s
E2E Health Check / e2e-health (push) Successful in 18s
- 新增 _tracer for awoooi.telegram_gateway
- _send_request: 追蹤所有 API 呼叫 (method, chat_id, message_id)
- send_cicd_progress: 追蹤 CI/CD 通知 (含重試次數)
首席架構師審查 P1 改進 - 可觀測性
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-30 01:56:50 +08:00 |
|
OG T
|
13bb1496b0
|
refactor(api): Phase B P1 可靠性強化 (2 項)
E2E Health Check / e2e-health (push) Has been cancelled
CD Pipeline / build-and-deploy (push) Has been cancelled
1. send_cicd_progress 重試機制 (指數退避 1,2,4 秒)
2. K8s Repository 封裝 (IK8sRepository + K8sRepository)
首席架構師審查 P1 改進 - 模組化合規
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-30 01:52:59 +08:00 |
|
OG T
|
bb85d89874
|
refactor(api): Phase A P1 快速勝利 (3 項)
CD Pipeline / build-and-deploy (push) Has been cancelled
E2E Health Check / e2e-health (push) Has been cancelled
1. 常數提取: SSE_DELAY_SECONDS, MAX_APPROVAL_DISPLAY
2. 錯誤訊息安全化: sanitize_error_message() 移除敏感資訊
3. CI/CD alertname 配置化: is_cicd_alertname() 函數
首席架構師審查 P1 改進 (非阻塞)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-30 01:44:42 +08:00 |
|
OG T
|
8d70df3ea2
|
fix(ai): NVIDIA 加入 Rate Limiter 檢查
CD Pipeline / build-and-deploy (push) Has been cancelled
E2E Health Check / e2e-health (push) Has been cancelled
2026-03-30 ogt: 修復 AI 仲裁降級問題
問題: NVIDIA RPM=5 限制未在 fallback 檢查
修正: 加入 nvidia 到 rate_limiter 檢查清單
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-30 01:18:11 +08:00 |
|
OG T
|
19fff8339d
|
feat(api): Phase 19.4 Terminal Service 真實 API 整合
整合真實後端服務,移除 Mock 數據:
_handle_approval_action:
- 使用 ApprovalDBService.get_pending_approvals()
- 顯示待簽核清單摘要 (最多 5 個)
- 渲染第一個待簽核項目的 ApprovalCard
_handle_status_query:
- 使用 K8s API 查詢 Pod 狀態
- 統計 Running/Ready/Total Pods
- 顯示問題 Pods (非 Running 或 NotReady)
- 查詢 Deployment 健康狀態
測試覆蓋:
- 6 個新增 API 整合測試
- 總計 60 個測試通過
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-30 01:17:03 +08:00 |
|
OG T
|
288ba7593e
|
fix(telegram): CI/CD 告警簡化 + 心跳台北時區
E2E Health Check / e2e-health (push) Has been cancelled
CD Pipeline / build-and-deploy (push) Has been cancelled
2026-03-30 ogt: 告警格式修正
CI/CD 告警:
- 新增 CICDProgressMessage 簡潔格式
- webhooks.py 偵測 CD_*/CI_*/E2E_* 前綴
- 跳過 AI 仲裁,直接發送簡潔通知
心跳訊息:
- 修正 UTC → 台北時區 (feedback_timezone_taipei.md)
- 簡化格式,移除冗餘資訊
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-30 01:15:38 +08:00 |
|
OG T
|
000533d32e
|
feat(ai): promote Nvidia nemotron as default arbitrator for high complexity/risk incidents
CD Pipeline / build-and-deploy (push) Successful in 4m35s
E2E Health Check / e2e-health (push) Successful in 16s
|
2026-03-30 00:26:53 +08:00 |
|
OG T
|
89f0bae3f2
|
feat(safety-net): complete wave 1 atomicity (adr-038, adr-039, debounce, graceful degrade, xclaim)
E2E Health Check / e2e-health (push) Has been cancelled
CD Pipeline / build-and-deploy (push) Has been cancelled
|
2026-03-29 23:55:38 +08:00 |
|
OG T
|
da6d6ed006
|
chore: trigger cd pipeline directly
CD Pipeline / build-and-deploy (push) Failing after 28s
E2E Health Check / e2e-health (push) Successful in 17s
|
2026-03-29 22:38:59 +08:00 |
|
OG T
|
3eb3051a73
|
fix(ci): 修復 docker socket 重複掛載 (1774793847)
CD Pipeline / build-and-deploy (push) Failing after 3m22s
E2E Health Check / e2e-health (push) Failing after 11s
|
2026-03-29 22:17:27 +08:00 |
|
OG T
|
f5b19cf108
|
feat(learning): 實作 Playbook 信心度調整機制 (ADR-030)
- 新增 _promote_playbook: 高評分提升信心度 +0.1
- 新增 _demote_playbook: 低評分降低信心度 -0.15
- 新增 find_by_source_incident: 按 incident_id 查詢 Playbook
- 新增 adjust_confidence: 信心度調整 + 狀態自動轉換
- 新增 Playbook.failure_rate 屬性
自動狀態轉換:
- ai_confidence >= 0.9 + DRAFT → 自動 APPROVED
- ai_confidence < 0.3 + failure_rate > 50% → 自動 DEPRECATED
測試: 13 案例全部通過
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-29 22:10:49 +08:00 |
|
OG T
|
4707102498
|
feat(telegram): 實作 6 種新訊息模板 (ADR-038)
2026-03-29 ogt: Telegram 訊息模板完整實作
新增訊息類型:
- SentryErrorMessage: Sentry 錯誤通知 (含 Stack Trace)
- ResourceWarnMessage: 資源耗盡警告 (含 CPU/Memory/Disk)
- RepairReportMessage: 自動修復每日報告
- DailySummaryMessage: 每日系統狀態摘要
- DeploySuccessMessage: CD 部署成功通知
- RateLimitMessage: API 限額警告
新增發送方法:
- send_sentry_error()
- send_resource_warning()
- send_repair_report()
- send_daily_summary()
- send_deploy_success()
- send_rate_limit_warning()
新增按鈕:
- Sentry: [🔍 查看詳情] [🔕 靜默 1h]
- Resource: [⚡ 自動擴展] [🔕 靜默 1h]
測試: 14 測試案例全部通過
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-29 21:23:07 +08:00 |
|
OG T
|
6416f56748
|
fix(e2e): 修正 HMAC Header 名稱 X-Webhook-Signature → X-Signature-256
- API 期望 X-Signature-256,E2E 腳本使用錯誤的 Header 名稱
- 修復後 Daily E2E Health Check 應能通過
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-29 21:16:50 +08:00 |
|
OG T
|
8bd51ea7c8
|
fix(e2e): 新增 HMAC 簽名支援
E2E 腳本現在會:
- 讀取 WEBHOOK_HMAC_SECRET 環境變數
- 計算 HMAC-SHA256 簽名
- 加入 X-Webhook-Signature header
修復生產環境 401 驗證失敗問題
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-29 20:54:28 +08:00 |
|
OG T
|
c80a69bd88
|
fix(lint): 修復 NVIDIA_LATENCY_HISTOGRAM 使用方式
- 移除錯誤的 .labels() 調用 (Histogram 無 labels)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-29 20:53:55 +08:00 |
|
OG T
|
2a3e627c37
|
fix(api): 修正 NVIDIA_LATENCY_SECONDS → NVIDIA_LATENCY_HISTOGRAM
2026-03-29 ogt: CI lint 修復 - 變數名稱錯誤
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-29 20:52:57 +08:00 |
|
OG T
|
04bfff9d19
|
refactor(ai): 模組化重構 - NVIDIA chat 移至 NvidiaProvider
符合 feedback_lewooogo_modular_enforcement.md 規範:
- 移除 openclaw.py 中的 _call_nvidia() (重複邏輯)
- 新增 NvidiaProvider.chat() 方法
- 更新 INvidiaProvider Protocol
- openclaw.py 改用 get_nvidia_provider().chat()
- 測試移至 test_nvidia_chat.py
架構層次:
- Router → Service → Provider (正確)
- 禁止 Service 層重複實作已存在的 Provider 功能
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-29 20:49:23 +08:00 |
|
OG T
|
1df21dcd07
|
fix(ai): P0/P1 修復 NVIDIA RCA 整合
修復項目:
- P1-1: 從 ModelRegistry 取得模型 (非 hardcoded)
- P1-2: models.json 新增 nvidia.rca 模型定義
- P0: 新增 test_openclaw_nvidia.py 測試
首席架構師審查 74/120 → 預期 85+
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-29 20:33:10 +08:00 |
|
OG T
|
79134fb019
|
feat(ai): 新增 NVIDIA Nemotron 到告警 Fallback Chain
- 新增 _call_nvidia() 一般告警支援 (非 Tool Calling)
- Fallback 順序: Gemini → Nvidia → Ollama → Claude
- Nvidia 免費 tier ($0),含 Token 追蹤
解決: Gemini 超限 (500/500) 後無法 fallback 問題
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-29 20:28:24 +08:00 |
|
OG T
|
5cad3707ee
|
fix(api): 補齊 prometheus-client 依賴 + 停用 Nightly LLM Tests
首席架構師審查 2026-03-29:
- 問題: metrics.py import prometheus_client 但未加入依賴
- 影響: API Pod CrashLoopBackOff
- 修復: 新增 prometheus-client>=0.20.0
統帥指示: 停用 Nightly LLM Tests 減少 Runner 負載
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-29 17:05:20 +08:00 |
|
OG T
|
8724ed7dcf
|
fix(mcp): P1 修復 - DI 一致性 + 測試補充 + 配置優化
首席架構師審查 P1 修復清單:
P1-1 RAG Provider DI 模式一致性:
- 支援 rag_service 參數注入
- 新增 close() 方法
- TYPE_CHECKING 延遲導入
P1-3 RAG 測試補充:
- test_rag_provider.py (9 tests)
- DI 注入/Lazy Load/Tool Schema/驗證/Close
P1-4 Grafana Config 快取優化:
- URL/Key 首次查詢後快取
- 減少重複 settings 存取
P1-5 Embedding 維度配置化:
- MODEL_DIMENSIONS 字典 (qwen/llama/nomic)
- default_dimension 參數
- 支援更多模型
測試: 9/9 PASSED
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-29 16:23:30 +08:00 |
|
OG T
|
b97f9364fb
|
feat(k8s): add Worker HPA + fix non-AI confidence values
Wave 2 Deployment:
- Worker HPA: min:1 max:3, CPU 70%, Memory 80%
- 前置條件: XCLAIM + terminationGracePeriodSeconds:90 (Wave 1 ✅)
- 比 API/Web 更保守的擴縮策略 (120s up, 600s down)
Confidence Fix:
- 非 AI 分析來源 (fallback/playbook/historical/consensus) 設 confidence=0.0
- 避免混淆 AI 信心度與其他指標 (成功率/相似度)
- 涉及: github_webhook, decision_manager, intent_classifier, learning_service
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-29 16:09:37 +08:00 |
|
OG T
|
938df7f291
|
fix(api): 全面清除假信心分數 - 遵循 feedback_confidence_truthfulness.md
🔴 違規修正: 規則匹配/Expert System 不是 AI 分析,confidence 必須 = 0.0
修正檔案:
- agents/action_planner.py: 0.9 → 0.0
- agents/blast_radius.py: 0.85/0.5/0.9 → 0.0
- agents/security.py: 計算公式 → 0.0
- signoz_webhook.py: 0.7 → 0.0
- auto_approve.py: default 0.5 → 0.0
- ci_auto_repair.py: 整個計算函數 → return 0.0
- error_analyzer_service.py: default 0.5 → 0.0
- intent_classifier.py: 計算公式 → 0.0
- openclaw.py: default 0.5 → 0.0
- resource_resolver.py: 0.8 → 0.0
- k8s_naming.py: 0.9/0.7 → 0.0
只有 LLM 真實分析返回的 confidence 才能 > 0
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-29 16:00:46 +08:00 |
|
OG T
|
19b00a1ca0
|
fix(api): 移除 Consensus Engine 假信心分數
🔴 違反鐵律: feedback_confidence_truthfulness.md
Expert System 必須 confidence = 0.0,禁止假裝 AI 仲裁
修正:
- SREAgent: 0.85/0.80/0.75/0.60 → 0.0
- SecurityAgent: 0.70/0.85 → 0.0
- CostAgent: 0.75 → 0.0
- PerformanceAgent: 0.80/0.70 → 0.0
所有規則匹配現在正確顯示為「⚙️ 規則匹配」而非「🤖 AI 仲裁」
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-29 15:57:04 +08:00 |
|
OG T
|
89a2339796
|
feat(api): ADR-038 Circuit Breaker 整合 + Graceful Degradation
sentry_webhook.py:
- 整合 OpenClawGuard (Circuit Breaker + Semaphore)
- 斷路狀態快速失敗,不呼叫 OpenClaw
- 並發控制: 最多 3 個同時 LLM 推理
anomaly_counter.py:
- record_anomaly() Redis 故障 Graceful Degradation
- 失敗時返回預設 AnomalyFrequency (count=0)
- 不中斷主流程
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-29 15:55:51 +08:00 |
|
OG T
|
39396dc57a
|
feat(worker): Wave 1 Signal Worker XCLAIM + Graceful Shutdown
ADR-038/039 Wave 1 強化:
- 新增 Active Sweeper: XPENDING + XCLAIM 回收閒置訊息
- PENDING_IDLE_MS: 60秒無ACK則可被回收
- SWEEP_INTERVAL_S: 每30秒掃描一次
- Graceful Shutdown: 75秒超時 (搭配 K8s 90秒)
- 超過 MAX_RETRIES 的訊息強制 ACK
K8s Worker Deployment:
- 新增 terminationGracePeriodSeconds: 90
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-29 15:53:05 +08:00 |
|
OG T
|
27509db212
|
feat(api): Wave 1 安全網 - Circuit Breaker + Global Repair Cooldown
ADR-038: OpenClaw 雙層保護
- Layer 1: Circuit Breaker (5 failures → 60s cooldown)
- Layer 2: Concurrency Semaphore (max 3 concurrent)
- 新增 src/core/circuit_breaker.py
ADR-039: 全域修復熔斷
- Global Cooldown: 5 repairs/15min → freeze
- StatefulSet Blacklist: postgres/redis/clickhouse 禁止自動重啟
- 新增 src/services/global_repair_cooldown.py
- 整合到 auto_repair_service.py
測試:
- test_circuit_breaker.py (狀態轉換 + Semaphore)
- test_global_repair_cooldown.py (黑名單 + 計數閾值)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-29 15:48:03 +08:00 |
|
OG T
|
2c79cba629
|
fix(api): 修復最後 2 個 bare except 錯誤
- scripts/test_nemotron_tool_calling.py: except -> except Exception
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-29 15:37:02 +08:00 |
|
OG T
|
d89f0520f9
|
fix(api): 修復 34 個 Ruff lint 錯誤
- 自動修復 import 排序、unused imports
- 手動修復 raise from、isinstance union、unused variable
- scripts/ 暫時保留 (非 CI 阻擋)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-29 15:27:49 +08:00 |
|
OG T
|
5f9a6a7e55
|
fix(ai): 移除假信心分數 + 顯示 AI 模型來源
問題: AI 仲裁顯示硬編碼信心分數 (0.75/0.88/0.92/0.70)
修復:
- decision_manager: 預設 confidence 0.75 → 0.0
- decision_manager: Expert System confidence=0.0 + is_rule_based
- openclaw: 所有 Mock Response confidence → 0.0
- telegram_gateway: 新增 ai_provider 欄位
- telegram_gateway: 動態來源標籤 (Ollama/Gemini/Claude/規則匹配)
Telegram 卡片顯示:
- confidence > 0 + provider=ollama → 🤖 Ollama 仲裁
- confidence > 0 + provider=gemini → 🤖 Gemini 仲裁
- confidence > 0 + provider=claude → 🤖 Claude 仲裁
- confidence == 0 → ⚙️ 規則匹配
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-29 15:19:51 +08:00 |
|
OG T
|
49f21dc4e1
|
test(api): P1-3/P1-4 ApprovalRequestCreate + Telegram 測試
P1-3: ApprovalRequestCreate 欄位對齊測試 (13 tests)
- 必填欄位驗證 (action, description, requested_by)
- BlastRadius Model 驗證
- SignOz/Sentry/GitHub Webhook 格式驗證
- Pydantic v2 額外欄位行為驗證
P1-4: Telegram 整合驗證測試 (19 tests)
- SignOzMetricsBlock 格式化
- TelegramMessage 結構
- 風險等級 Emoji 映射
- Webhook → Telegram 訊息流程
遵循: feedback_no_mock_testing.md (禁止 Mock)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-29 11:28:33 +08:00 |
|
OG T
|
ac2715e541
|
fix(api): P1-2 ApprovalRequestCreate 欄位對齊
修正 SignOz + GitHub Webhook 的 ApprovalRequestCreate:
Before (錯誤欄位):
- action_type, target_resource, source
- blast_radius=BlastRadius.SINGLE (enum 不存在)
- dry_run_check=DryRunCheck.SKIPPED (錯誤格式)
- 缺少 action, description, requested_by
After (正確欄位):
- action, description (必填)
- blast_radius=BlastRadius(...) (Pydantic Model)
- dry_run_checks=[] (list)
- requested_by (必填)
- 其他欄位移至 metadata
遵循: ApprovalRequestBase schema (approval.py)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-29 11:17:27 +08:00 |
|
OG T
|
50c055b547
|
feat(api): Phase D-G P0 修正 - Learning Repository 積木化
新增:
- ILearningRepository Protocol (interfaces.py)
- LearningRepository (Redis 持久化層)
- Learning API 端點 (/api/v1/learning/*)
- LearningService.get_recommended_fix() 方法
- LearningService.get_learning_summary() 方法
修正:
- Service 不直接依賴 Redis Client (透過 Repository)
- 符合 leWOOOgo 積木化原則
- 首席架構師審查: 74/100 → 92/100
更新:
- ADR-030: 新增 Phase D-G P0 修正章節
- Skill 02: v1.9 → v2.0
- Runner 修復: 序列建構解決 _runner_file_commands 衝突
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-29 11:03:51 +08:00 |
|
OG T
|
ae21ba2cc6
|
feat(ai): Phase 20 P3 優化 - Circuit Breaker + 指數退避 + Prometheus
P3-1: Circuit Breaker 狀態機 (CLOSED/OPEN/HALF_OPEN)
- 連續 3 次失敗觸發斷路
- 60 秒後自動嘗試恢復
- 防止連鎖故障
P3-2: 指數退避重試
- 基礎延遲 1s,最大 30s
- 含 10% jitter 避免雷鳴
P3-3: Prometheus Metrics
- nvidia_tool_call_requests_total (status, tool_name)
- nvidia_tool_call_latency_seconds (histogram)
- nvidia_circuit_breaker_state_changes_total
測試: 25 → 34 PASSED
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-29 01:49:08 +08:00 |
|
OG T
|
d9a6f9d066
|
feat(api): Sentry Session Replay UX 自動監控
Phase 19 UX 監控 - 善用 Sentry Session Replay:
- SentryService: 新增 list_replays, get_ux_audit_summary
- 偵測: 憤怒點擊 (Rage Clicks) + 死亡點擊 (Dead Clicks)
- 偵測: 有錯誤的 Session Replay
- 偵測: UI 相關錯誤 (TypeError/render)
- API: GET /api/v1/errors/ux-audit 端點
- 腳本: audit_ux_sentry.py CLI 工具
統帥回饋: "AI都要全自動化!" ✅
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-29 01:48:59 +08:00 |
|
OG T
|
d6dc80bcbc
|
fix(sentry): OpenClaw URL 修正 8088→8089
ADR-028 端口統一,Sentry webhook 漏掉更新
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-29 01:46:28 +08:00 |
|
OG T
|
b0b91a59e5
|
fix(telegram): 修復簽核按鈕無作用 - 方法名稱錯誤
根本原因:
- telegram_gateway.py 呼叫 service.add_signature() 但該方法不存在
- telegram.py 呼叫 service.reject() 但該方法不存在
- 正確方法為 sign_approval() 和 reject_approval()
修復:
- _execute_approval_action: add_signature → sign_approval
- _execute_approval_action: reject → reject_approval
- telegram webhook: 同步修復
影響範圍:
- Telegram 簽核/拒絕/稍後/靜默按鈕現在正常運作
- 前端 Y/n 按鈕本就使用正確 API (不受影響)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-29 01:36:38 +08:00 |
|
OG T
|
179e659f14
|
chore: 清理 Playwright 產物 + kube-state-metrics 告警擴充
清理工作:
- .gitignore 新增 playwright-report/ 和 test-results/ 排除
- 保留 phase19/ 參考截圖目錄
kube-state-metrics 告警擴充 (P3):
- CronJobLastRunFailed: Job 執行失敗
- DaemonSetMissingPods: DaemonSet 缺少 Pod
- StatefulSetReplicasMismatch: StatefulSet 副本不足
- ContainerWaiting: ImagePullBackOff/CrashLoopBackOff 偵測
- PDBViolation: PDB 健康 Pod 數不足
- NodeUnschedulable: 節點標記為不可排程
新增:
- apps/api/scripts/test_nemotron_tool_calling.py (E2E 比較測試)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-29 01:28:35 +08:00 |
|
OG T
|
4f7282a97a
|
fix(ai): Phase 20 P2 修復 - Protocol + 邊界測試 + model_registry
P2-1: 定義 INvidiaProvider Protocol (@runtime_checkable)
P2-2: 補充邊界測試 15 → 25 案例
P2-3: model_registry 新增 NVIDIA + tool_calling_fallback_order
首席架構師評分: 82 → 86 → 90/100
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-29 01:24:17 +08:00 |
|
OG T
|
6de1c0ff3b
|
fix(ai): 修復 Pydantic validation error + tuple unpacking
1. kubectl_command 允許 None (LLM 可能返回 null)
2. 加入 field_validator 將 null 轉換為空字串
3. generate_incident_proposal 完整解包 6 值 (含 ai_tokens/ai_cost)
2026-03-29 ogt: Gemini API validation 修復
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-29 00:46:02 +08:00 |
|
OG T
|
fb643eb645
|
feat(ai): ADR-036 Nemotron E2E 驗證腳本
新增 verify_nemotron_e2e.py:
- 測試 NVIDIA API 連線
- 測試 AIRouter 整合
- 測試高風險 Tool 檢測
- 測試繁體中文 Tool Calling
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-29 00:11:40 +08:00 |
|
OG T
|
7c905c4bf3
|
fix(ai): 修復 generate_incident_proposal tuple unpacking 錯誤
- _call_with_cache 返回 6 值 (含 ai_tokens/ai_cost)
- generate_incident_proposal 解包只取 4 值導致 ValueError
- 修復: 完整解包 6 值並傳遞 ai_tokens/ai_cost 到 proposal_dict
2026-03-29 ogt: Token/Cost 追蹤補遺
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-29 00:03:22 +08:00 |
|
OG T
|
b77e151387
|
feat(ai): ADR-036 NVIDIA Nemotron Tool Calling 整合
Phase 20 - 提升 Tool Calling 精準度 50% → 83.3%
新增:
- src/models/nvidia.py: Pydantic Schema
- src/services/nvidia_provider.py: NvidiaProvider 類別
- tests/test_nvidia_provider.py: 15 項單元測試 (全部通過)
修改:
- ai_router.py: AIProvider.NVIDIA + route_tool_calling()
- ai_rate_limiter.py: NVIDIA 限制 (5 RPM, 100/day)
- models.json: NVIDIA 配置
- cd.yaml: Secrets 注入 NVIDIA_API_KEY
路由策略:
- Tool Calling: Nemotron → Gemini → Claude
- 一般對話: Ollama → Gemini → Claude (不變)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-29 00:00:08 +08:00 |
|
OG T
|
6ac0f8c0e5
|
chore: force API rebuild (runner temp file fix)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-03-28 23:47:18 +08:00 |
|