docs(awooop): record t61 recurrence work items [skip ci]

This commit is contained in:
Your Name
2026-05-18 20:41:18 +08:00
parent bc99683432
commit 51660ecbb1
2 changed files with 53 additions and 0 deletions

View File

@@ -1,3 +1,47 @@
## 2026-05-18 | T61 Recurrence Repair Work Items
**背景**T60 已讓 recurrence group 顯示 `repair_summary``work_item`,但 production live group `DockerContainerUnhealthy / bitan-pharmacy-bitan-1` 仍呈現 `run_completed_no_repair``work_item.status=none`。這會讓 Operator 知道「沒有自動修復紀錄」,卻無法在 AwoooP 工作台接手、追蹤或轉 Ticket。
**修正**
- `run_completed_no_repair` 不再被歸類為 `none`,改成 open work item。
- recurrence work item 新增 `kind / next_step / reason`
- `automation_gap`Run 完成但沒有 `auto_repair_executions`
- `verification`:已有 auto-repair 但驗證/結果需追蹤。
- `approval_followup`:停在人工閘門。
- `investigation`Run 尚在調查。
- recurrence summary 新增 `automation_gap_group_total``failed_repair_group_total`
- `/awooop/work-items` 新增「重複告警工作項」面板,直接讀 `/api/v1/platform/events/dossier/recurrence`
- Runs 頁連到 `/awooop/work-items?work_item_id=...&incident_id=...`Work Items 頁會聚焦同一筆 recurrence work item。
- 補 zh-TW / en i18n。
**local verification**
- `python3 -m py_compile apps/api/src/services/channel_event_dossier_service.py apps/api/src/api/v1/platform/events.py apps/api/tests/test_channel_event_dossier_service.py`pass。
- `DATABASE_URL=postgresql+asyncpg://awoooi:awoooi@localhost:5432/awoooi PYTHONPATH=apps/api pytest apps/api/tests/test_channel_event_dossier_service.py -q`9 passed。
- `DATABASE_URL=... PYTHONPATH=apps/api ruff check --select F,E9,I ...`pass。
- `node -e "JSON.parse(...zh-TW.json); JSON.parse(...en.json)"`pass。
- `pnpm --dir apps/web run typecheck`pass。
- `pnpm --dir apps/web exec next lint --file src/app/[locale]/awooop/work-items/page.tsx --file src/app/[locale]/awooop/runs/page.tsx`pass with existing literal-string warnings in legacy Runs pageT61 新增文案已走 i18n。
- `NEXT_PUBLIC_API_URL=https://awoooi.wooo.work pnpm --dir apps/web run build`pass with existing Sentry setup warnings。
- `git diff --check`pass。
**production verification**
- `b5061452 feat(awooop): surface recurrence repair work items` pushed to Gitea main。
- Gitea Code Review `1801` successCD `1800` successdeploy marker `bc996834 chore(cd): deploy b506145 [skip ci]`
- Health`https://awoooi.wooo.work/api/v1/health``status=healthy``mock_mode=false`
- Recurrence API`/api/v1/platform/events/dossier/recurrence?project_id=awoooi&limit=20``200`
- `source_event_total=20``recurrence_group_total=2``recurrent_group_total=2``duplicate_event_total=9``linked_run_total=20``unlinked_event_total=0`
- T61 summary`auto_repair_linked_total=1``verified_repair_group_total=0``open_work_item_group_total=2``manual_gate_group_total=0``automation_gap_group_total=1``failed_repair_group_total=0`
- Top group`DockerContainerUnhealthy` / `bitan-pharmacy-bitan-1`latest incident=`INC-20260517-F25B4A`repair status=`run_completed_no_repair`work item=`incident:INC-20260517-F25B4A`status=`open`kind=`automation_gap`next step=`create_repair_ticket`reason=`completed_run_without_auto_repair`
- Frontend Playwright smoke`/zh-TW/awooop/work-items?project_id=awoooi&work_item_id=incident%3AINC-20260517-F25B4A&incident_id=INC-20260517-F25B4A` 顯示工作鏈路、重複告警工作項、`incident:INC-20260517-F25B4A``Run 已完成但沒有自動修復紀錄`,導航仍可見,`Application error=false`console errors=`0`
**目前整體進度**
- AwoooP observability / truth-chain 可回看:約 97.5%。
- 來源告警入庫、重複發生、Sentry / SignOz 與修復結果可見性:約 97%。
- Telegram callback detail/history 可追溯:約 96%。
- AI 自動修復閉環:約 96%T61 沒有假裝這類告警已自動修復,而是把 `run_completed_no_repair` 轉成 open work item / Ticket 入口。
- 前端 AI 自動化管理介面產品化:約 96%。
- 完整 AI 自動化管理產品化:約 91%。
## 2026-05-18 | T60 Recurrence Repair / Work Item Evidence
**背景**:統帥追問 Telegram 告警與重複告警雖然進了 AwoooP但仍看不出「是否真正 AI 自動修復」、「是否已進 work item / ticket」、「是否需要人工接手」。T59 已補 recurrence / linked run本輪把 recurrence group 繼續接到 incident id、auto-repair execution、latest verifier evidence 與 work item 狀態,並修掉 API DTO 會把新欄位濾掉的 contract 缺口。

View File

@@ -2192,6 +2192,15 @@ Phase 6 完成後
- 邊界T24 只是把 historical degraded 轉成可見補救工作佇列,尚未真正執行 replay / reverify / closure / Ticket creation。下一段要做安全執行入口先 read-only reverify 與 low-risk replay dry-run再把結果接到 closure 或 Ticket。
- 目前進度更新Alertmanager 低風險自動修復主線約 97%;完整 AI 自動化管理產品化約 89%。
**T61 Recurrence repair work items production verified2026-05-18 台北)**
- 觸發T60 已讓 recurrence group 顯示 `repair_summary``work_item`,但 production live group `DockerContainerUnhealthy / bitan-pharmacy-bitan-1` 仍是 `run_completed_no_repair` 且沒有 open work itemOperator 只能知道「沒修復」,不能在工作台接手。
- 修正:`run_completed_no_repair` 改成 open `automation_gap` work item並在 recurrence DTO 補 `kind / next_step / reason`summary 補 `automation_gap_group_total``failed_repair_group_total`。這是 read-side 工作鏈路,不直接執行修復、不自動關單、不批准 write action。
- UI`/awooop/work-items` 新增「重複告警工作項」面板,直接讀 `/api/v1/platform/events/dossier/recurrence`Runs 頁連到 Work Items 時可用 `work_item_id / incident_id` 聚焦同一筆 recurrence work item。
- Production deploy`b5061452 feat(awooop): surface recurrence repair work items` 已推 Gitea mainCode Review run `1801` successCD run `1800` successdeploy marker `bc996834 chore(cd): deploy b506145 [skip ci]`
- Production evidencehealth 200recurrence API 回 `open_work_item_group_total=2``automation_gap_group_total=1`、top group `DockerContainerUnhealthy / bitan-pharmacy-bitan-1``work_item_id=incident:INC-20260517-F25B4A``kind=automation_gap``next_step=create_repair_ticket``reason=completed_run_without_auto_repair`。Playwright smoke 確認 `/zh-TW/awooop/work-items?...work_item_id=incident:INC-20260517-F25B4A` 顯示重複告警工作項、聚焦 work item、導航可見console errors=0。
- 邊界T61 仍不宣稱該 DockerContainerUnhealthy 已真正 AI 自動修復它把「Run 完成但無 auto-repair execution」從不可操作證據轉成 open work item / Ticket 入口。下一段應定義安全的 Ticket / reverify / replay dry-run 執行入口。
- 目前進度更新AwoooP truth-chain 可回看約 97.5%AI 自動修復閉環約 96%;完整 AI 自動化管理產品化約 91%。
---
### 2026-04-20 晚 (台北) — C1-C4 全流程串接 — Playbook 鏈路保護commit de2d34d