@leejungkiin/awkit 1.0.9 → 1.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +3 -3
- package/VERSION +1 -1
- package/bin/awf.js +1 -1
- package/bin/awk.js +287 -34
- package/core/AGENTS.md +8 -9
- package/core/GEMINI.md +77 -199
- package/package.json +2 -1
- package/skill-packs/neural-memory/skills/nm-memory-sync/SKILL.md +2 -2
- package/skills/CATALOG.md +3 -2
- package/skills/README.md +109 -0
- package/skills/android-re-analyzer/SKILL.md +238 -0
- package/skills/android-re-analyzer/references/api-extraction-patterns.md +119 -0
- package/skills/android-re-analyzer/references/call-flow-analysis.md +176 -0
- package/skills/android-re-analyzer/references/fernflower-usage.md +115 -0
- package/skills/android-re-analyzer/references/jadx-usage.md +116 -0
- package/skills/android-re-analyzer/references/setup-guide.md +221 -0
- package/skills/android-re-analyzer/scripts/check-deps.sh +129 -0
- package/skills/android-re-analyzer/scripts/decompile.sh +375 -0
- package/skills/android-re-analyzer/scripts/find-api-calls.sh +118 -0
- package/skills/android-re-analyzer/scripts/install-dep.sh +448 -0
- package/skills/awf-session-restore/SKILL.md +108 -184
- package/skills/beads-manager/SKILL.md +2 -2
- package/skills/brainstorm-agent/SKILL.md +47 -2
- package/skills/gemini-conductor/SKILL.md +234 -0
- package/skills/memory-sync/SKILL.md +29 -1
- package/skills/nm-memory-sync/SKILL.md +2 -2
- package/skills/orchestrator/SKILL.md +32 -154
- package/skills/skills/nm-memory-sync/SKILL.md +2 -2
- package/skills/smali-to-kotlin/SKILL.md +1 -1
- package/skills/smali-to-swift/SKILL.md +1 -1
- package/skills/swiftui-pro/SKILL.md +108 -0
- package/skills/swiftui-pro/agents/openai.yaml +10 -0
- package/skills/swiftui-pro/assets/swiftui-pro-icon.png +0 -0
- package/skills/swiftui-pro/assets/swiftui-pro-icon.svg +29 -0
- package/skills/swiftui-pro/references/accessibility.md +13 -0
- package/skills/swiftui-pro/references/api.md +39 -0
- package/skills/swiftui-pro/references/data.md +43 -0
- package/skills/swiftui-pro/references/design.md +31 -0
- package/skills/swiftui-pro/references/hygiene.md +9 -0
- package/skills/swiftui-pro/references/navigation.md +14 -0
- package/skills/swiftui-pro/references/performance.md +46 -0
- package/skills/swiftui-pro/references/swift.md +56 -0
- package/skills/swiftui-pro/references/views.md +35 -0
- package/skills/symphony-enforcer/SKILL.md +227 -0
- package/skills/symphony-orchestrator/SKILL.md +301 -0
- package/skills/telegram-notify/SKILL.md +57 -0
- package/symphony/LICENSE +21 -0
- package/symphony/README.md +178 -0
- package/symphony/app/api/agents/route.js +152 -0
- package/symphony/app/api/events/route.js +22 -0
- package/symphony/app/api/knowledge/route.js +253 -0
- package/symphony/app/api/locks/route.js +29 -0
- package/symphony/app/api/notes/route.js +125 -0
- package/symphony/app/api/preflight/route.js +23 -0
- package/symphony/app/api/projects/route.js +116 -0
- package/symphony/app/api/roles/route.js +134 -0
- package/symphony/app/api/skills/route.js +82 -0
- package/symphony/app/api/status/route.js +18 -0
- package/symphony/app/api/tasks/route.js +157 -0
- package/symphony/app/api/workflows/route.js +61 -0
- package/symphony/app/api/workspaces/route.js +15 -0
- package/symphony/app/globals.css +2605 -0
- package/symphony/app/layout.js +20 -0
- package/symphony/app/page.js +2122 -0
- package/symphony/cli/index.js +1060 -0
- package/symphony/core/agent-manager.js +357 -0
- package/symphony/core/context-bus.js +100 -0
- package/symphony/core/db.js +223 -0
- package/symphony/core/file-lock-manager.js +154 -0
- package/symphony/core/merge-pipeline.js +234 -0
- package/symphony/core/orchestrator.js +236 -0
- package/symphony/core/task-manager.js +335 -0
- package/symphony/core/workspace-manager.js +168 -0
- package/symphony/jsconfig.json +7 -0
- package/symphony/lib/core.mjs +1034 -0
- package/symphony/mcp/index.js +29 -0
- package/symphony/mcp/server.js +110 -0
- package/symphony/mcp/tools/context.js +80 -0
- package/symphony/mcp/tools/locks.js +99 -0
- package/symphony/mcp/tools/status.js +82 -0
- package/symphony/mcp/tools/tasks.js +216 -0
- package/symphony/mcp/tools/workspace.js +143 -0
- package/symphony/next.config.mjs +7 -0
- package/symphony/package.json +53 -0
- package/symphony/scripts/postinstall.js +49 -0
- package/symphony/symphony.config.js +41 -0
- package/templates/conductor-tracks.md +38 -0
- package/templates/workflow_dual_mode_template.md +5 -5
- package/workflows/_uncategorized/AGENTS.md +38 -0
- package/workflows/_uncategorized/decompile.md +67 -0
- package/workflows/_uncategorized/skill-health.md +7 -7
- package/workflows/ads/ads-audit.md +5 -5
- package/workflows/ads/ads-optimize.md +10 -10
- package/workflows/ads/adsExpert.md +7 -7
- package/workflows/conductor.md +97 -0
- package/workflows/context/auto-implement.md +4 -4
- package/workflows/context/codebase-sync.md +19 -8
- package/workflows/context/next.md +27 -27
- package/workflows/context/user-intent-analysis-workflow.md +4 -4
- package/workflows/expert/codeExpert.md +28 -31
- package/workflows/expert/debugExpert.md +11 -11
- package/workflows/expert/planExpert.md +21 -36
- package/workflows/git/smart-git-ops.md +49 -6
- package/workflows/lifecycle/debug.md +7 -7
- package/workflows/lifecycle/deploy.md +10 -10
- package/workflows/lifecycle/master-code-workflow.md +3 -3
- package/workflows/lifecycle/plan.md +19 -21
- package/workflows/quality/audit.md +1 -1
- package/workflows/quality/project-audit.md +1 -1
- package/workflows/roles/vibe-coding-master-workflow.md +2 -2
- package/workflows/smart-git-ops.md +146 -0
- package/workflows/ui/app-screen-analyzer.md +4 -4
- package/workflows/ui/create-feature.md +8 -8
- package/workflows/ui/create-spec-architect.md +11 -11
|
@@ -1,14 +1,25 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: awf-session-restore
|
|
3
|
-
description:
|
|
3
|
+
description: |
|
|
4
|
+
Silent context restoration via Symphony + NeuralMemory with strict project scoping.
|
|
5
|
+
Gathers Git, Symphony, and Brain context silently — no console spam.
|
|
6
|
+
Enforces Project ID → Brain Switch → Memory Read order to prevent cross-project contamination.
|
|
7
|
+
metadata:
|
|
8
|
+
stage: core
|
|
9
|
+
version: "7.0"
|
|
10
|
+
replaces: "v6.4"
|
|
11
|
+
requires: symphony-orchestrator
|
|
12
|
+
tags: [session, restore, context, symphony, neuralmemory, silent, multi-project]
|
|
4
13
|
trigger: session_start
|
|
14
|
+
invocation-type: auto
|
|
5
15
|
priority: 2
|
|
6
16
|
---
|
|
7
17
|
|
|
8
|
-
# AWF Session Restore (
|
|
18
|
+
# AWF Session Restore (v7.0 — Symphony Native)
|
|
9
19
|
|
|
10
|
-
> **Purpose:**
|
|
11
|
-
>
|
|
20
|
+
> **Purpose:** Silently gather unstructured context (Git, Plans, Memory) at session start.
|
|
21
|
+
> **Key Change v7.0:** Symphony-native. Strict brain scoping.
|
|
22
|
+
> **Output:** NO console block. Context injected silently for AI consumption.
|
|
12
23
|
|
|
13
24
|
---
|
|
14
25
|
|
|
@@ -21,237 +32,148 @@ Skill này **BẮT BUỘC** chạy khi:
|
|
|
21
32
|
|
|
22
33
|
---
|
|
23
34
|
|
|
24
|
-
##
|
|
35
|
+
## Position in Init Chain
|
|
25
36
|
|
|
26
|
-
### 0. Project Brain Lookup (CHẠY TRƯỚC BEADS)
|
|
27
|
-
|
|
28
|
-
**Mục đích:** Load project structure vào context — AI không cần scan cấu trúc lần nào nữa trong session này.
|
|
29
|
-
|
|
30
|
-
```bash
|
|
31
|
-
# Check project identity
|
|
32
|
-
cat .project-identity 2>/dev/null || echo "No .project-identity found"
|
|
33
|
-
|
|
34
|
-
# Check codebase map
|
|
35
|
-
cat CODEBASE.md 2>/dev/null || echo "No CODEBASE.md found"
|
|
36
37
|
```
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
38
|
+
symphony-orchestrator (Gate 0: Server health + project overview)
|
|
39
|
+
↓
|
|
40
|
+
awf-session-restore ← BẠN ĐANG Ở ĐÂY (Gate 0.5: Silent context gather)
|
|
41
|
+
↓
|
|
42
|
+
nm-memory-sync (Gate 1: Associative memory sync)
|
|
43
|
+
↓
|
|
44
|
+
symphony-enforcer (Gate 2: Project → Brain → Task → Confirmation block)
|
|
42
45
|
```
|
|
43
46
|
|
|
44
|
-
**
|
|
45
|
-
|
|
46
|
-
📚 No project identity found — raw mode
|
|
47
|
-
```
|
|
47
|
+
> **Chỉ `symphony-enforcer` mới in ra console block cho user.**
|
|
48
|
+
> `awf-session-restore` chạy NGẦM, không in gì.
|
|
48
49
|
|
|
49
50
|
---
|
|
50
51
|
|
|
51
|
-
|
|
52
|
+
## ⛔ Strict Execution Order (MANDATORY)
|
|
52
53
|
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
```
|
|
58
|
-
|
|
59
|
-
**Output:**
|
|
60
|
-
- Tasks đang làm dở
|
|
61
|
-
- Tasks blocked
|
|
62
|
-
- Tasks ready to start
|
|
63
|
-
|
|
64
|
-
**Priority 2: Brain (Knowledge & Plans)**
|
|
65
|
-
```bash
|
|
66
|
-
# Check active plans
|
|
67
|
-
cat brain/active_plans.json
|
|
54
|
+
> [!CAUTION]
|
|
55
|
+
> PHẢI tuân thủ thứ tự dưới đây. Vi phạm thứ tự = rò rỉ bộ nhớ đa dự án.
|
|
56
|
+
> TUYỆT ĐỐI KHÔNG gọi `nmem_context`, `nmem_recap`, hay bất kỳ MCP memory tool nào
|
|
57
|
+
> TRƯỚC KHI hoàn thành Step 1 và Step 2.
|
|
68
58
|
|
|
69
|
-
|
|
70
|
-
ls -lt brain/ | head -5
|
|
71
|
-
```
|
|
72
|
-
|
|
73
|
-
**Output:**
|
|
74
|
-
- Plan đang active
|
|
75
|
-
- Phase hiện tại
|
|
76
|
-
- Recent decisions/knowledge
|
|
59
|
+
### Step 1: Fetch Project Identity (CHẠY ĐẦU TIÊN)
|
|
77
60
|
|
|
78
|
-
**Priority 3: Git (Code State)**
|
|
79
61
|
```bash
|
|
80
|
-
|
|
81
|
-
git log -1
|
|
62
|
+
cat .project-identity 2>/dev/null || echo "NO_PROJECT"
|
|
82
63
|
```
|
|
83
64
|
|
|
84
|
-
**
|
|
85
|
-
|
|
86
|
-
- Commit gần nhất
|
|
87
|
-
|
|
88
|
-
---
|
|
65
|
+
**Nếu tìm thấy:** Extract `projectId` và `projectName` từ JSON.
|
|
66
|
+
**Nếu không:** Ghi nhận `raw mode` — các bước sau vẫn chạy nhưng không scope theo project.
|
|
89
67
|
|
|
90
|
-
### 2
|
|
68
|
+
### Step 2: Switch NeuralMemory Brain (CHẠY THỨ HAI)
|
|
91
69
|
|
|
92
|
-
|
|
70
|
+
> [!IMPORTANT]
|
|
71
|
+
> Step này PHẢI hoàn thành TRƯỚC KHI gọi bất kỳ `nmem_*` MCP tool nào.
|
|
93
72
|
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
- Project: FitBite Witness | Stage 3 | Clean Architecture + MVVM
|
|
99
|
-
- CODEBASE: Loaded (4 layers, 8 features indexed)
|
|
100
|
-
|
|
101
|
-
📿 **Beads Context:**
|
|
102
|
-
- In Progress: Task #123 "Implement Login API" (started 2h ago)
|
|
103
|
-
- Ready: 3 tasks
|
|
104
|
-
|
|
105
|
-
🧠 **Brain Context:**
|
|
106
|
-
- Active Plan: Shopping Cart - Phase 02 (50%)
|
|
107
|
-
- Last Save: 30 minutes ago
|
|
108
|
-
|
|
109
|
-
📂 **Git Context:**
|
|
110
|
-
- Changed Files: 3 files (src/api/auth/*.ts)
|
|
111
|
-
- Last Commit: "feat: add user model" (1 hour ago)
|
|
112
|
-
|
|
113
|
-
➡️ **SUGGESTED NEXT STEP:**
|
|
114
|
-
Continue task #123? `/codeExpert` or `/code`
|
|
73
|
+
Nếu Step 1 tìm thấy `projectId`:
|
|
74
|
+
```bash
|
|
75
|
+
# CLI command — ép NeuralMemory server đổi sang đúng brain
|
|
76
|
+
nmem brain use <projectId>
|
|
115
77
|
```
|
|
116
78
|
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
### 3. Smart Suggestions
|
|
79
|
+
**Chờ xác nhận đổi brain thành công** rồi mới tiếp tục Step 3.
|
|
120
80
|
|
|
121
|
-
|
|
81
|
+
### Step 3: Gather Context (song song — tất cả silent)
|
|
122
82
|
|
|
123
|
-
|
|
124
|
-
```
|
|
125
|
-
➡️ Tiếp tục task #123?
|
|
126
|
-
`/codeExpert` (Fast) or `/code` (Guided)
|
|
127
|
-
```
|
|
83
|
+
Sau khi brain đã switch, thu thập 3 nguồn context **song song**:
|
|
128
84
|
|
|
129
|
-
|
|
85
|
+
#### 3a. Git/Code State
|
|
86
|
+
```bash
|
|
87
|
+
git status --short 2>/dev/null
|
|
88
|
+
git log -1 --oneline 2>/dev/null
|
|
130
89
|
```
|
|
131
|
-
⚠️ Task #125 bị block bởi #120
|
|
132
90
|
|
|
133
|
-
|
|
134
|
-
|
|
91
|
+
#### 3b. Active Plans (scoped theo projectId)
|
|
92
|
+
```bash
|
|
93
|
+
# CHÚ Ý: Dùng projectId để scope đúng thư mục
|
|
94
|
+
ls -t brain/<projectId>/*/implementation_plan.md 2>/dev/null | head -1
|
|
135
95
|
```
|
|
136
96
|
|
|
137
|
-
|
|
97
|
+
Hoặc nếu dùng cấu trúc brain khác:
|
|
98
|
+
```bash
|
|
99
|
+
cat CODEBASE.md 2>/dev/null | head -5
|
|
138
100
|
```
|
|
139
|
-
📋 Có 3 tasks ready to start
|
|
140
101
|
|
|
141
|
-
|
|
142
|
-
|
|
102
|
+
#### 3c. Symphony Task State
|
|
103
|
+
```bash
|
|
104
|
+
symphony task list -P <projectId> -s in_progress --json 2>/dev/null
|
|
143
105
|
```
|
|
144
106
|
|
|
145
|
-
|
|
107
|
+
Hoặc dùng MCP tool (sau khi brain đã switch):
|
|
146
108
|
```
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
➡️ Bắt đầu dự án mới?
|
|
150
|
-
`/planExpert "Feature"` or `/brainstorm`
|
|
109
|
+
symphony_available_tasks(filter="my")
|
|
151
110
|
```
|
|
152
111
|
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
### 4. Memory Persistence
|
|
112
|
+
### Step 4: Compose Silent Context
|
|
156
113
|
|
|
157
|
-
|
|
114
|
+
**KHÔNG in ra console.** Tổng hợp thành context object ngầm cho AI sử dụng nội bộ:
|
|
158
115
|
|
|
159
116
|
```json
|
|
160
|
-
// brain/session.json
|
|
161
117
|
{
|
|
162
|
-
"
|
|
163
|
-
|
|
164
|
-
"
|
|
165
|
-
"
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
118
|
+
"project": {
|
|
119
|
+
"id": "<projectId>",
|
|
120
|
+
"name": "<projectName>",
|
|
121
|
+
"codebase_loaded": true
|
|
122
|
+
},
|
|
123
|
+
"git": {
|
|
124
|
+
"changed_files": ["file1.swift", "file2.swift"],
|
|
125
|
+
"last_commit": "feat: add auth module"
|
|
126
|
+
},
|
|
127
|
+
"symphony": {
|
|
128
|
+
"active_tasks": ["sym-XYZ"],
|
|
129
|
+
"ready_tasks_count": 3
|
|
172
130
|
},
|
|
173
|
-
"
|
|
174
|
-
"
|
|
175
|
-
"
|
|
176
|
-
"git": true
|
|
131
|
+
"brain": {
|
|
132
|
+
"switched_to": "<projectId>",
|
|
133
|
+
"active_plan": "plans/260316-auth/implementation_plan.md"
|
|
177
134
|
}
|
|
178
135
|
}
|
|
179
136
|
```
|
|
180
137
|
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
### Beads Unavailable
|
|
186
|
-
```
|
|
187
|
-
⚠️ Beads không khả dụng
|
|
188
|
-
|
|
189
|
-
Fallback: Dùng Brain + Git context
|
|
190
|
-
```
|
|
191
|
-
|
|
192
|
-
### Brain Empty
|
|
193
|
-
```
|
|
194
|
-
⚠️ Brain chưa có context
|
|
195
|
-
|
|
196
|
-
Gợi ý: `/plan` để tạo context mới
|
|
197
|
-
```
|
|
198
|
-
|
|
199
|
-
### All Sources Fail
|
|
200
|
-
```
|
|
201
|
-
❌ Không thể khôi phục context
|
|
202
|
-
|
|
203
|
-
➡️ Bắt đầu lại:
|
|
204
|
-
1. `/recap` để quét dự án
|
|
205
|
-
2. `/plan` để tạo plan mới
|
|
206
|
-
3. Kể cho em biết đang làm gì
|
|
207
|
-
```
|
|
138
|
+
AI dùng context này để:
|
|
139
|
+
- Hiểu user đang code dở gì
|
|
140
|
+
- Biết task nào đang in-progress
|
|
141
|
+
- Gợi ý tiếp tục đúng chỗ
|
|
208
142
|
|
|
209
143
|
---
|
|
210
144
|
|
|
211
|
-
##
|
|
212
|
-
|
|
213
|
-
### Auto-Trigger in Workflows
|
|
214
|
-
|
|
215
|
-
Các workflows tự động gọi session restore:
|
|
216
|
-
|
|
217
|
-
```markdown
|
|
218
|
-
# In /code workflow
|
|
219
|
-
1. Check session.json
|
|
220
|
-
2. If no context → Trigger awf-session-restore
|
|
221
|
-
3. Resume from restored context
|
|
222
|
-
```
|
|
223
|
-
|
|
224
|
-
### Manual Trigger
|
|
225
|
-
|
|
226
|
-
User có thể gọi thủ công:
|
|
145
|
+
## Error Handling
|
|
227
146
|
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
147
|
+
| Tình huống | Xử lý |
|
|
148
|
+
|-----------|--------|
|
|
149
|
+
| `.project-identity` không tồn tại | Raw mode — skip brain switch, vẫn thu thập Git + Symphony global |
|
|
150
|
+
| `nmem brain use` fail | Warning log — tiếp tục với Git + Symphony context |
|
|
151
|
+
| Symphony server down | Đã được `symphony-orchestrator` xử lý trước đó — nếu vẫn down thì skip |
|
|
152
|
+
| Git không phải repo | Skip git context — vẫn có Symphony + Brain |
|
|
153
|
+
| Tất cả fail | AI bắt đầu với clean state — không block workflow |
|
|
231
154
|
|
|
232
155
|
---
|
|
233
156
|
|
|
234
|
-
##
|
|
157
|
+
## What Changed from v6.4
|
|
235
158
|
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
159
|
+
| v6.4 (Old) | v7.0 (New) |
|
|
160
|
+
|------------|------------|
|
|
161
|
+
| CLI task list | `symphony task list` (Symphony MCP) |
|
|
162
|
+
| In block `🧠 SESSION RESTORED` | **Silent** — không in gì |
|
|
163
|
+
| Đọc `.project-identity` và `CODEBASE.md` | Chỉ đọc `.project-identity` (CODEBASE gate do orchestrator xử lý) |
|
|
164
|
+
| `brain/*` wildcard scan | `brain/<projectId>/` scoped access |
|
|
165
|
+
| Không switch brain trước khi đọc memory | **BẮT BUỘC** `nmem brain use` trước mọi memory read |
|
|
166
|
+
| Smart Suggestions block | Nhường cho `symphony next` |
|
|
167
|
+
| 3 sources: CLI + Brain + Git | 3 sources: Symphony + Brain + Git |
|
|
239
168
|
|
|
240
169
|
---
|
|
241
170
|
|
|
242
|
-
##
|
|
243
|
-
|
|
244
|
-
```
|
|
245
|
-
🧠 **WELCOME BACK!**
|
|
246
|
-
|
|
247
|
-
📿 **Beads:** Task #123 "Login API" (in_progress, 2h ago)
|
|
248
|
-
🧠 **Brain:** Plan "Shopping Cart" - Phase 02 (50%)
|
|
249
|
-
📂 **Git:** 3 files changed
|
|
250
|
-
|
|
251
|
-
➡️ **NEXT:** Continue coding? `/codeExpert`
|
|
171
|
+
## Integration Notes
|
|
252
172
|
|
|
253
|
-
|
|
254
|
-
|
|
173
|
+
- **symphony-orchestrator** đã check server health → skill này KHÔNG cần check lại.
|
|
174
|
+
- **symphony-enforcer** sẽ in confirmation block → skill này KHÔNG in gì.
|
|
175
|
+
- **nm-memory-sync** chạy SAU skill này → brain đã switch đúng project.
|
|
176
|
+
- **orchestrator** sẽ dispatch workflow → skill này chỉ gather context.
|
|
255
177
|
|
|
256
178
|
---
|
|
257
179
|
|
|
@@ -263,8 +185,10 @@ User có thể customize trong `brain/preferences.json`:
|
|
|
263
185
|
{
|
|
264
186
|
"session_restore": {
|
|
265
187
|
"auto_trigger": true,
|
|
266
|
-
"
|
|
267
|
-
"sources": ["beads", "brain", "git"]
|
|
188
|
+
"sources": ["symphony", "brain", "git"]
|
|
268
189
|
}
|
|
269
190
|
}
|
|
270
191
|
```
|
|
192
|
+
|
|
193
|
+
> **Removed:** `verbosity` option (no longer needed — always silent).
|
|
194
|
+
> **Removed:** Legacy CLI task source (replaced by Symphony MCP).
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: beads-manager
|
|
3
|
-
description:
|
|
3
|
+
description: "⚠️ DEPRECATED — Replaced by symphony-orchestrator. Do NOT use this skill."
|
|
4
4
|
version: 6.6.0
|
|
5
|
-
trigger:
|
|
5
|
+
trigger: never
|
|
6
6
|
invocation-type: auto
|
|
7
7
|
---
|
|
8
8
|
|
|
@@ -30,7 +30,7 @@ priority: medium
|
|
|
30
30
|
| Skill này LÀM | Skill này KHÔNG làm |
|
|
31
31
|
|---------------|---------------------|
|
|
32
32
|
| Brainstorm ý tưởng tính năng | Đọc/ghi brain/memory files |
|
|
33
|
-
| Tư vấn hướng đi sản phẩm | Track tasks (việc của
|
|
33
|
+
| Tư vấn hướng đi sản phẩm | Track tasks (việc của symphony-orchestrator) |
|
|
34
34
|
| Research thị trường | Sửa lỗi code |
|
|
35
35
|
| Tạo BRIEF.md output | Lên kế hoạch chi tiết (việc của /plan) |
|
|
36
36
|
| Phân tích đối thủ | Deploy |
|
|
@@ -249,6 +249,51 @@ Anh muốn làm gì tiếp:
|
|
|
249
249
|
|
|
250
250
|
---
|
|
251
251
|
|
|
252
|
+
## 💾 SYMPHONY NOTES AUTO-SAVE (BẮT BUỘC)
|
|
253
|
+
|
|
254
|
+
> **Rule:** Sau khi tạo BẤT KỲ brainstorm artifact nào (BRIEF.md, analysis, brainstorm doc),
|
|
255
|
+
> AI PHẢI POST metadata vào Symphony Notes API. Content ĐỌC TỪ FILE, KHÔNG lưu vào DB.
|
|
256
|
+
|
|
257
|
+
### Khi nào trigger:
|
|
258
|
+
|
|
259
|
+
```yaml
|
|
260
|
+
triggers:
|
|
261
|
+
- BRIEF.md tạo xong
|
|
262
|
+
- Analysis document tạo xong (pricing, market, competitor...)
|
|
263
|
+
- Brainstorm document tạo xong
|
|
264
|
+
- Bất kỳ artifact có giá trị lâu dài
|
|
265
|
+
```
|
|
266
|
+
|
|
267
|
+
### Cách thực hiện:
|
|
268
|
+
|
|
269
|
+
```bash
|
|
270
|
+
curl -X POST http://localhost:3100/api/notes -H 'Content-Type: application/json' -d '{
|
|
271
|
+
"projectId": "<current-project-id>",
|
|
272
|
+
"type": "brainstorm",
|
|
273
|
+
"title": "<artifact-title>",
|
|
274
|
+
"content": "<summary-2-3-lines-ONLY — KHÔNG copy full content>",
|
|
275
|
+
"filePath": "<absolute-path-to-artifact-file>",
|
|
276
|
+
"conversationId": "<current-conversation-id>",
|
|
277
|
+
"metadata": {
|
|
278
|
+
"mode": "quick|full|feature",
|
|
279
|
+
"tags": ["pricing", "features", "architecture", ...],
|
|
280
|
+
"created_by": "brainstorm-agent"
|
|
281
|
+
}
|
|
282
|
+
}'
|
|
283
|
+
```
|
|
284
|
+
|
|
285
|
+
### Quy tắc:
|
|
286
|
+
|
|
287
|
+
```yaml
|
|
288
|
+
rules:
|
|
289
|
+
- content CHỈ chứa summary ngắn 2-3 dòng
|
|
290
|
+
- filePath trỏ đến file .resolved hoặc .md thực tế
|
|
291
|
+
- Nếu Symphony server không chạy → skip (không block workflow)
|
|
292
|
+
- type: "brainstorm" cho ý tưởng, "analysis" cho phân tích dữ liệu
|
|
293
|
+
```
|
|
294
|
+
|
|
295
|
+
---
|
|
296
|
+
|
|
252
297
|
## 🚫 ANTI-PATTERNS
|
|
253
298
|
|
|
254
299
|
```yaml
|
|
@@ -285,7 +330,7 @@ Short messages — không dump wall of text
|
|
|
285
330
|
Works WITH: /brainstorm workflow (skill này hỗ trợ workflow)
|
|
286
331
|
Delegates TO: /plan (sau khi BRIEF xong)
|
|
287
332
|
NOT: memory-sync (hoàn toàn độc lập — memory-sync tự theo dõi)
|
|
288
|
-
NOT:
|
|
333
|
+
NOT: symphony-orchestrator (không tạo task, chỉ brainstorm)
|
|
289
334
|
Triggers: memory-sync W3 sẽ tự kích hoạt khi BRIEF.md tạo xong
|
|
290
335
|
```
|
|
291
336
|
|
|
@@ -0,0 +1,234 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: gemini-conductor
|
|
3
|
+
description: >-
|
|
4
|
+
Two-Agent Flow — Antigravity proactively invokes Gemini CLI (headless)
|
|
5
|
+
for project-wide analysis, strategic planning, and second opinions.
|
|
6
|
+
CLI runs on separate quota pool, extending AI capacity.
|
|
7
|
+
metadata:
|
|
8
|
+
stage: core
|
|
9
|
+
version: "1.0"
|
|
10
|
+
requires: gemini (npm i -g @anthropic-ai/gemini-cli)
|
|
11
|
+
tags: [conductor, cli, two-agent, strategy, analysis, delegation]
|
|
12
|
+
agent: Conductor
|
|
13
|
+
trigger: conditional
|
|
14
|
+
invocation-type: auto
|
|
15
|
+
priority: 5
|
|
16
|
+
---
|
|
17
|
+
|
|
18
|
+
# 🎼 Gemini Conductor Skill
|
|
19
|
+
|
|
20
|
+
> **Purpose:** Antigravity tự gọi Gemini CLI qua terminal khi cần tầm nhìn rộng hơn scope IDE.
|
|
21
|
+
> **Key Benefit:** CLI dùng quota pool riêng → nhân đôi AI capacity. Giảm tunnel vision.
|
|
22
|
+
|
|
23
|
+
---
|
|
24
|
+
|
|
25
|
+
## ⚠️ Core Principle
|
|
26
|
+
|
|
27
|
+
```
|
|
28
|
+
Antigravity (IDE) = Executor — code, debug, file edits
|
|
29
|
+
Gemini CLI = Conductor — analysis, strategy, review
|
|
30
|
+
|
|
31
|
+
Antigravity CHỦ ĐỘNG gọi CLI khi cần. User KHÔNG cần tự chuyển.
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
---
|
|
35
|
+
|
|
36
|
+
## 🎯 Trigger Conditions
|
|
37
|
+
|
|
38
|
+
Skill này kích hoạt khi Antigravity nhận diện task cần tầm nhìn rộng:
|
|
39
|
+
|
|
40
|
+
```yaml
|
|
41
|
+
auto_trigger:
|
|
42
|
+
high_confidence:
|
|
43
|
+
- Project-wide refactoring (>5 files affected)
|
|
44
|
+
- Architecture analysis / design review
|
|
45
|
+
- Cross-module dependency analysis
|
|
46
|
+
- Strategic planning for feature spanning multiple areas
|
|
47
|
+
- Need second opinion on complex technical decision
|
|
48
|
+
|
|
49
|
+
medium_confidence (confirm before invoking):
|
|
50
|
+
- Code review before commit (>3 files changed)
|
|
51
|
+
- Test plan generation for new feature
|
|
52
|
+
- Performance audit across codebase
|
|
53
|
+
|
|
54
|
+
never_trigger:
|
|
55
|
+
- Simple file edits (<3 files)
|
|
56
|
+
- Bug fix in single module
|
|
57
|
+
- UI changes in one screen
|
|
58
|
+
- Questions user can answer directly
|
|
59
|
+
```
|
|
60
|
+
|
|
61
|
+
---
|
|
62
|
+
|
|
63
|
+
## 🔧 CLI Invocation Pattern
|
|
64
|
+
|
|
65
|
+
### Base Command
|
|
66
|
+
|
|
67
|
+
```bash
|
|
68
|
+
gemini -p "ONLY edit/create .md files. DO NOT modify any code. <PROMPT>" \
|
|
69
|
+
--approval-mode auto \
|
|
70
|
+
-o json \
|
|
71
|
+
2>/dev/null
|
|
72
|
+
```
|
|
73
|
+
|
|
74
|
+
| Flag | Purpose |
|
|
75
|
+
|------|---------|
|
|
76
|
+
| `-p "..."` | Headless mode — MUST explicitly forbid editing source code. |
|
|
77
|
+
| `--approval-mode auto` | Allows CLI to execute file edits (only `.md`), bypassing prompts |
|
|
78
|
+
| `-o json` | Structured output for easy parsing |
|
|
79
|
+
|
|
80
|
+
### Safety Rules
|
|
81
|
+
|
|
82
|
+
```yaml
|
|
83
|
+
safety:
|
|
84
|
+
- CLI CHỈ ĐƯỢC PHÉP tạo/sửa file tài liệu (`.md`). TUYỆT ĐỐI KHÔNG ĐƯỢC sửa code thực tế.
|
|
85
|
+
- ALWAYS inject explicit file-editing restrictions into the `-p` prompt.
|
|
86
|
+
- Timeout: 60s max per CLI call
|
|
87
|
+
- If CLI fails → gracefully fallback to Antigravity-only mode
|
|
88
|
+
- NEVER pass secrets/tokens in -p prompt
|
|
89
|
+
- Working directory: ALWAYS set to project root
|
|
90
|
+
```
|
|
91
|
+
|
|
92
|
+
### Command Template
|
|
93
|
+
|
|
94
|
+
```bash
|
|
95
|
+
# Safe invocation with timeout
|
|
96
|
+
timeout 60 gemini -p "<prompt>. ONLY edit/create .md files. DO NOT touch source code." --approval-mode auto -o json 2>/dev/null
|
|
97
|
+
```
|
|
98
|
+
|
|
99
|
+
---
|
|
100
|
+
|
|
101
|
+
## 📋 Use Cases & Prompt Templates
|
|
102
|
+
|
|
103
|
+
### 1. Project Structure Analysis
|
|
104
|
+
|
|
105
|
+
```bash
|
|
106
|
+
gemini -p "Analyze the project structure in the current directory. \
|
|
107
|
+
List main modules, their responsibilities, and key dependencies. \
|
|
108
|
+
Output as structured JSON with modules array." \
|
|
109
|
+
--approval-mode plan -o json
|
|
110
|
+
```
|
|
111
|
+
|
|
112
|
+
**When:** Starting work on unfamiliar part of codebase, or after long gap.
|
|
113
|
+
|
|
114
|
+
### 2. Cross-Module Impact Analysis
|
|
115
|
+
|
|
116
|
+
```bash
|
|
117
|
+
gemini -p "I plan to modify <FILE_OR_MODULE>. \
|
|
118
|
+
Analyze which other files/modules depend on it and would be impacted. \
|
|
119
|
+
List files with risk level (high/medium/low)." \
|
|
120
|
+
--approval-mode plan -o json
|
|
121
|
+
```
|
|
122
|
+
|
|
123
|
+
**When:** Before refactoring that touches shared interfaces.
|
|
124
|
+
|
|
125
|
+
### 3. Strategic Refactoring Plan
|
|
126
|
+
|
|
127
|
+
```bash
|
|
128
|
+
gemini -p "Review the codebase and propose a refactoring strategy for <AREA>. \
|
|
129
|
+
Consider: current architecture, dependencies, risk, and migration path. \
|
|
130
|
+
Prioritize changes by impact and difficulty." \
|
|
131
|
+
--approval-mode plan -o json
|
|
132
|
+
```
|
|
133
|
+
|
|
134
|
+
**When:** Large-scale refactoring spanning multiple modules.
|
|
135
|
+
|
|
136
|
+
### 4. Second Opinion / Decision Support
|
|
137
|
+
|
|
138
|
+
```bash
|
|
139
|
+
gemini -p "Evaluate two approaches for <PROBLEM>: \
|
|
140
|
+
Approach A: <desc>. Approach B: <desc>. \
|
|
141
|
+
Compare: complexity, maintainability, performance, and risk. \
|
|
142
|
+
Recommend one with reasoning." \
|
|
143
|
+
--approval-mode plan -o json
|
|
144
|
+
```
|
|
145
|
+
|
|
146
|
+
**When:** Facing complex architectural decision.
|
|
147
|
+
|
|
148
|
+
### 5. Pre-Commit Code Review
|
|
149
|
+
|
|
150
|
+
```bash
|
|
151
|
+
gemini -p "Review the following code changes for potential issues: \
|
|
152
|
+
<DIFF_OR_DESCRIPTION>. \
|
|
153
|
+
Check for: bugs, security issues, performance problems, and best practices." \
|
|
154
|
+
--approval-mode plan -o json
|
|
155
|
+
```
|
|
156
|
+
|
|
157
|
+
**When:** Before committing changes across >3 files.
|
|
158
|
+
|
|
159
|
+
### 6. Test Strategy Generation
|
|
160
|
+
|
|
161
|
+
```bash
|
|
162
|
+
gemini -p "Generate a comprehensive test strategy for <FEATURE>. \
|
|
163
|
+
Include: unit tests, integration tests, edge cases, and test data. \
|
|
164
|
+
Consider existing test patterns in the project." \
|
|
165
|
+
--approval-mode plan -o json
|
|
166
|
+
```
|
|
167
|
+
|
|
168
|
+
**When:** Building new feature that needs thorough test coverage.
|
|
169
|
+
|
|
170
|
+
---
|
|
171
|
+
|
|
172
|
+
## 🔄 Integration Flow
|
|
173
|
+
|
|
174
|
+
```
|
|
175
|
+
1. Antigravity detects trigger condition
|
|
176
|
+
2. Build CLI prompt with relevant context
|
|
177
|
+
3. Run: run_command("timeout 60 gemini -p '...' --approval-mode plan -o json")
|
|
178
|
+
4. Parse CLI output (JSON or text)
|
|
179
|
+
5. Integrate insights into current task
|
|
180
|
+
6. Continue with code execution using enriched context
|
|
181
|
+
```
|
|
182
|
+
|
|
183
|
+
### Output Handling
|
|
184
|
+
|
|
185
|
+
```yaml
|
|
186
|
+
on_success:
|
|
187
|
+
- Parse JSON output from CLI
|
|
188
|
+
- Extract key insights, recommendations, file lists
|
|
189
|
+
- Use them to guide next code edits
|
|
190
|
+
- Optionally save analysis to conductor/tracks.md
|
|
191
|
+
|
|
192
|
+
on_timeout:
|
|
193
|
+
- Log: "⏳ CLI analysis timed out, proceeding with local context"
|
|
194
|
+
- Fall back to Antigravity-only analysis
|
|
195
|
+
|
|
196
|
+
on_error:
|
|
197
|
+
- Log: "⚠️ CLI invocation failed, continuing without conductor"
|
|
198
|
+
- Do NOT block the workflow — CLI is enhancement, not dependency
|
|
199
|
+
```
|
|
200
|
+
|
|
201
|
+
---
|
|
202
|
+
|
|
203
|
+
## 🚫 Anti-Patterns
|
|
204
|
+
|
|
205
|
+
```yaml
|
|
206
|
+
never_do:
|
|
207
|
+
- Call CLI for simple single-file edits
|
|
208
|
+
- Let CLI edit actual source code files (ONLY .md docs are allowed)
|
|
209
|
+
- Pass sensitive data (API keys, tokens) in prompts
|
|
210
|
+
- Block on CLI response indefinitely (always use timeout)
|
|
211
|
+
- Call CLI more than 3 times per task (diminishing returns)
|
|
212
|
+
- Ignore CLI output — if you called it, use the result
|
|
213
|
+
|
|
214
|
+
always_do:
|
|
215
|
+
- Mention to user when invoking CLI: "📡 Đang gọi Gemini CLI phân tích..."
|
|
216
|
+
- Include project-specific context in CLI prompt
|
|
217
|
+
- Summarize CLI findings before acting on them
|
|
218
|
+
- Fall back gracefully if CLI unavailable
|
|
219
|
+
```
|
|
220
|
+
|
|
221
|
+
---
|
|
222
|
+
|
|
223
|
+
## 🧩 Skill Relationships
|
|
224
|
+
|
|
225
|
+
```
|
|
226
|
+
Uses: run_command (to invoke gemini CLI)
|
|
227
|
+
Enhances: /plan, /code, /debug, /refactor workflows
|
|
228
|
+
Saves to: conductor/tracks.md (optional)
|
|
229
|
+
Independent of: NeuralMemory (CLI has its own context)
|
|
230
|
+
```
|
|
231
|
+
|
|
232
|
+
---
|
|
233
|
+
|
|
234
|
+
*gemini-conductor v1.0 — Two-Agent Flow Skill for Antigravity*
|