feat(awooop): show source ref gap recency
All checks were successful
CD Pipeline / tests (push) Successful in 1m32s
Code Review / ai-code-review (push) Successful in 12s
CD Pipeline / build-and-deploy (push) Successful in 3m41s
CD Pipeline / post-deploy-checks (push) Successful in 2m13s

This commit is contained in:
Your Name
2026-05-25 20:12:19 +08:00
parent f30405997d
commit a8b7299d1c
7 changed files with 151 additions and 9 deletions

View File

@@ -20804,3 +20804,68 @@ GET /api/v1/health:
- KM governance約 84.6%。
- AI Provider lane visibility約 92.2%。
- 完整 AI 自動化管理產品化:約 97.55%。
---
## 2026-05-25 T189 — Source Refs Gap Recency Breakdown
**背景**
- T188 已把 `按鈕缺 incident refs 682` 拆出 top prefixes。
- 但 operator 仍無法判斷這些缺口是 legacy 積欠,還是仍在最近持續重複新增。
- 這直接對應統帥要求Telegram / 前端必須能看出告警是否一直重複發生,以及目前跑到哪個階段。
**本輪修正**
- `/api/v1/platform/runs/callback-replies`
`outbound_reply_markup_missing_incident_ref_top_prefixes` 每個 item 新增:
- `recent_24h_total`
- `first_sent_at`
- `last_sent_at`
- Run 監控 `TG Callback Evidence` 的 top prefixes 顯示改為:
- `silence 27624h 22最後 05/25 18:59`
- `unknown 15424h 0最後 05/19 02:23`
- 這讓 operator 可以直接分辨:
- `24h = 0`:舊資料缺口,不是正在洗版。
- `24h > 0`:仍需追來源 template / gateway。
**local validation完成**
```text
python3 -m py_compile apps/api/src/services/platform_operator_service.py apps/api/src/api/v1/platform/operator_runs.py apps/api/tests/test_awooop_operator_timeline_labels.py
jq empty apps/web/messages/zh-TW.json apps/web/messages/en.json
PYTHONPATH=. DATABASE_URL='postgresql+asyncpg://test:test@localhost/test' /Users/ogt/.pyenv/shims/pytest tests/test_awooop_operator_timeline_labels.py -q
53 passed in 1.37s
pnpm --dir apps/web exec tsc --noEmit --tsBuildInfoFile /tmp/awoooi-t189-tsconfig.tsbuildinfo
pnpm --dir apps/web lint -- --file 'src/app/[locale]/awooop/runs/page.tsx'
pass with pre-existing i18next/no-literal-string warnings in the same file
NEXT_PUBLIC_API_URL=https://awoooi.wooo.work pnpm --dir apps/web run build
pass; Sentry global-error / instrumentation-client warnings are pre-existing
```
**production read-only preflight完成**
```text
kubectl exec -n awoooi-prod deploy/awoooi-api -- production DB read-only SQL
silence = 276, recent_24h_total = 22, last_sent_at = 2026-05-25T10:59:49Z
unknown = 154, recent_24h_total = 0, last_sent_at = 2026-05-18T18:23:04Z
drift_view = 144, recent_24h_total = 0, last_sent_at = 2026-05-18T18:14:27Z
ai_advisory_handled = 52, recent_24h_total = 23, last_sent_at = 2026-05-25T12:07:17Z
approve = 50, recent_24h_total = 0, last_sent_at = 2026-05-13T04:00:04Z
```
**目前整體進度**
- AwoooP 告警可觀測鏈:約 99.64%。
- 低風險自動修復閉環:約 95.8%。
- 前端 AI 自動化管理介面同步:約 99.35%。
- 首頁 KPI / 小龍蝦流程 truth alignment約 96.5%。
- Telegram 詳情 / 歷史可追溯:約 99.0%。
- Telegram outbound / callback DB coverage 可視化:約 99.35%。
- callback / DB replayability約 98.5%。
- MCP / 自建 MCP 可視化:約 95.1%。
- Sentry / SigNoz source correlation約 94.45%。
- Ansible / PlayBook 可視化:約 92.6%。
- KM governance約 84.6%。
- AI Provider lane visibility約 92.2%。
- 完整 AI 自動化管理產品化:約 97.6%。