skills/tech-debt-capture/SKILL.md
Automated Phase 4 technical debt capture and Ticket creation. Parses work-log evaluation reports, extracts TD (Technical Debt) items, and creates Atomic Tickets using Single Responsibility Principle. Use: Extract technical debts from Phase 4 evaluation → Auto-map to target versions → Create tickets → Update todolist.
npx skillsauth add tarrragon/claude tech-debt-captureInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Automated technical debt capture from Phase 4 evaluation reports and conversion to Atomic Tickets.
目的: 將 Phase 4 重構評估識別的技術債務自動轉換為可執行的 Ticket
工作流程:
完整技術債務處理流程:
.claude/pm-rules/tech-debt.md
| 條件 | 說明 | 驗證方式 | | ------------------ | ------------------------ | ----------------------------- | | Phase 4 已完成 | 重構評估必須完成 | 工作日誌有 Phase 4 章節 | | 技術債務已記錄 | 工作日誌中有標準格式表格 | 表格包含 ID、描述、風險、時機 | | 表格格式正確 | 遵循標準格式 | 可被腳本自動解析 |
## 技術債務評估
| ID | 描述 | 風險等級 | 建議處理時機 | 影響範圍 |
| ------ | ------------------------------------------------- | -------- | ------------ | ------------ |
| TD-001 | book_tags 表缺少 book_id 索引,大量資料查詢效能低 | 低 | 下一版本 | database |
| TD-002 | BookRepository 和 TagRepository 錯誤處理邏輯重複 | 低 | 可選 | repositories |
| 應記錄 | 不應記錄 | | ------------------------ | ---------------------- | | 架構違反(層級依賴錯誤) | 當前版本範圍內的 Bug | | 重複程式碼 | 已在當前版本修復的問題 | | 效能最佳化機會 | 功能需求變更 | | 測試覆蓋缺口 | 使用者回報的功能問題 | | 文件缺失 | 新功能需求 |
風險等級分類:
| 風險等級 | 說明 | | -------- | ---- | | 高 | 可能影響使用者體驗或效能的重大問題 | | 中 | 影響維護成本但不嚴重的問題 | | 低 | 程式碼品質或架構改進 | | 極低 | 非功能性風格問題 |
| 風險等級 | 版本規則 | 範例 | | -------- | ---------------------------- | ------------------------------------------- | | 高 | 當前 UC 完成後的版本 | UC-08 v0.19.8 的高風險 TD -> v0.20.0 (UC-09) | | 中 | 當前 UC 完成後的版本 | UC-08 v0.19.8 的中風險 TD -> v0.20.0 (UC-09) | | 低 | 當前 UC 版本系列的後續小版本 | UC-08 的低風險 TD -> v0.20.x 或更後 | | 極低 | 可選改進,不強制排期 | TD-003 可選清理 |
決策邏輯:
1. 判斷技術債務來自哪個 UC 版本系列(Example: v0.19.8 = UC-08)
2. 根據風險等級選擇目標版本
├─ 高/中 -> 下一個 UC (v0.20.x)
└─ 低/極低 -> 當前 UC 版本系列或後續版本
3. 如果未指定 --target-version,自動推導
技術債務 Ticket 使用特殊格式,包含 ticket_type: "tech-debt" 和來源版本資訊。
完整 Ticket frontmatter 範本:
references/ticket-template.md通用 Ticket 格式規範:.claude/skills/ticket/references/create-command.md
{TargetVersion}-TD-{Seq:03d}
範例: 0.20.0-TD-001, 0.20.0-TD-004
docs/work-logs/v{TargetVersion}/tickets/
在 docs/todolist.yaml 末尾新增或更新技術債務追蹤區塊:
## 技術債務追蹤
| Ticket ID | 描述 | 來源版本 | 目標版本 | 風險 | 狀態 |
| ------------- | --------------------------- | -------- | -------- | ---- | ------- |
| 0.20.0-TD-001 | 新增 book_tags.book_id 索引 | v0.19.8 | v0.20.0 | 低 | pending |
/tech-debt-capture
引導式交互:選擇工作日誌 -> 確認 TD 清單 -> 確認版本對應 -> 建立 Ticket 並更新 todolist
uv run .claude/skills/tech-debt-capture/scripts/tech_debt_capturer.py capture \
docs/work-logs/v0.19.8-phase4-final-evaluation.md
更多 CLI 範例(預覽模式、初始化、列出):
references/cli-examples.md
--target-version 手動覆蓋python3.10+pyyaml 套件(UV 自動安裝)/ticket create - 手動建立 Atomic Ticket/ticket track - 追蹤和更新 Ticket 狀態.claude/pm-rules/tech-debt.md - 技術債務處理流程.claude/methodologies/atomic-ticket-methodology.md - 單一職責原則Last Updated: 2026-03-02 Version: 1.1.0 Maintainer: basil-hook-architect
development
Use when the user wants to design, redesign, shape, critique, audit, polish, clarify, distill, harden, optimize, adapt, animate, colorize, extract, or otherwise improve a frontend interface. Covers websites, landing pages, dashboards, product UI, app shells, components, forms, settings, onboarding, and empty states. Handles UX review, visual hierarchy, information architecture, cognitive load, accessibility, performance, responsive behavior, theming, anti-patterns, typography, fonts, spacing, layout, alignment, color, motion, micro-interactions, UX copy, error states, edge cases, i18n, and reusable design systems or tokens. Also use for bland designs that need to become bolder or more delightful, loud designs that should become quieter, live browser iteration on UI elements, or ambitious visual effects that should feel technically extraordinary. Not for backend-only or non-UI tasks.
development
Claude Code release notes 框架影響評估工具。比對 last-reviewed 版本篩出新版本,逐項分類(對框架有幫助 / 需評估 / 無影響 / 不適用),對採用項引導建 ANA + WRAP + spawn 落地。Use when: 執行 /release-notes 看到新版本、定期檢查 CC 更新、評估新功能對專案框架的影響時。Triggers: release notes, release-notes, CC 更新, claude code 更新, 版本更新評估, 新功能評估, 框架影響評估。
development
Assertion design judgment framework for flaky and design-quality issues. Use when writing tests, reviewing assertions, diagnosing flaky tests, or deciding if a timing/float/cache assertion is appropriate. Do NOT use for API syntax or refactoring.
tools
Chrome Extension 實機測試與 debug 工作流,以 chrome-devtools-mcp 為核心工具。Use when: (1) 完成功能後實機驗證 / manual test / 試看看 / 跑看看 / verify feature, (2) extension debug / popup 不作動 / content script 不注入 / service worker 報錯 / background 出問題, (3) 安裝 unpacked extension / load unpacked / 載入未封裝, (4) 看 console / 看 network / 看 log / view console / inspect requests, (5) 功能更新後重新載入 extension / rebuild reload / reload extension。涵蓋 Manifest V3 service worker / content script / popup / options page 的 chrome-devtools-mcp 工具呼叫流程。不取代 Puppeteer / Playwright 自動化 E2E(CI 用),定位為開發期手動驗證與 LLM-assisted debug。