Phase 6.4 - Modular Architecture: - Add lewooogo-brain adapters for LLM providers - Add lewooogo-data dual memory (Redis + PostgreSQL) - Implement consensus engine for multi-agent decisions - Add incident memory service for historical context Phase 9 - Agent Teams (Claude Agent SDK): - Add base agent class with Claude Sonnet 4 integration - Implement action planner, blast radius, and security agents - Add agent API endpoints and proposal workflow - Integrate ADR-009 OpenClaw Agent Teams architecture DevOps & CI/CD: - Add GitHub Actions CI/CD workflows (ci.yaml, cd.yaml) - Add pre-commit hooks and secrets baseline - Add docker-compose for local development - Update Kubernetes network policies Frontend Improvements: - Add auto-healing error boundary component - Update i18n messages for agent features - Enhance dual-state incident card with execution feedback Documentation: - Add 7 ADRs covering MCP, design system, architecture decisions - Update ARCHITECTURE_MEMORY.md with modular design - Add GLOBAL_RULES.md and SOUL.md for project identity Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2.9 KiB
2.9 KiB
AWOOOI Project Configuration
此文件由 Claude Code 自動讀取,定義專案核心規則
專案架構
- apps/api/ - FastAPI 後端 (Python)
- apps/web/ - Next.js 前端 (TypeScript)
- k8s/ - Kubernetes 配置
- packages/ - 共用套件
Skills 載入指令
執行任務前,請先讀取相關 Skill:
| 任務類型 | Skill 路徑 |
|---|---|
| 前端修改 | .agents/skills/01-awoooi-frontend-aesthetics.md |
| 後端修改 | .agents/skills/02-lewooogo-backend-core.md |
| AI/決策邏輯 | .agents/skills/03-openclaw-cognitive-expert.md |
| DevOps/K8s | .agents/skills/04-awoooi-devops-commander.md |
| 測試/診斷 | .agents/skills/05-awoooi-sre-qa.md |
| Git/依賴 | .agents/skills/06-awoooi-monorepo-master.md |
核心鐵律 (簡版)
- i18n 零硬編碼 - 所有 UI 文字必須用 next-intl
- 禁止 SQLite - 只用 PostgreSQL
- 禁止 latest tag - K8s image 必須精確版本
- CORS 白名單 - 禁止
* - Dry-Run 先行 - K8s 變更必須先 dry-run
- Memory 同步 - 任務完成後更新 Memory MD
Memory 系統
長期記憶存放在:~/.claude/projects/-Users-ogt-awoooi/memory/
索引文件:MEMORY.md
自動化工作流 (2026-03-23 統帥授權)
| Automation | 路徑 | 用途 |
|---|---|---|
| 開發循環 | .agents/automations/01-dev-cycle.md |
修改後自動檢查 |
| 部署驗證 | .agents/automations/02-deploy-verify.md |
部署後自動驗證 |
| Memory 同步 | .agents/automations/03-memory-sync.md |
任務完成自動更新 |
Tier 分級 (自動化程度)
| Tier | 說明 | 範例 |
|---|---|---|
| 0 | ✅ 完全自動 | Read, Grep, curl 診斷 |
| 1 | ✅ 完全自動 | Edit, Write (非敏感路徑) |
| 2 | ⚡ 快速確認 | git commit, pnpm build |
| 3 | 🔐 詳細確認 | git push, kubectl apply |
多視窗協調 (2026-03-23 統帥授權)
| 視窗 | 角色 | 負責目錄 |
|---|---|---|
| A | 架構師 | docs/ + memory/ + 跨域協調 |
| B | 前端 | apps/web/** |
| C | 後端 | apps/api/** + packages/** |
| D | UI/UX | components/** + tailwind |
| E | 資安 | NetworkPolicy + Secrets |
| F | CI/CD | .github/ + k8s/** |
視窗管理指令
/視窗 新增 G:[角色]
/視窗 調整 D:[新角色]
/視窗 刪除 F
/視窗 查看
詳細協議: memory/reference_multiwindow_protocol.md
2026-03-23 Props Mapping 教訓
事故: Y/n 按鈕灰色無法點擊,因為
mapToDualState()遺漏傳遞decision欄位
鐵律: 新增 API 欄位時的檢查清單
- API Response 有該欄位 ✓
- Mapper 函數有轉換該欄位 ✓ ← 常遺漏
- TypeScript 型別有定義該欄位 ✓
- 組件 Props 有接收該欄位 ✓
- 組件有使用該欄位 ✓
快速診斷
# 確認 API 有回傳
curl -s API_URL | jq '.[0].decision'
# 確認 Mapper 有轉換
grep -n "decision" apps/web/src/app/*/page.tsx