@leejungkiin/awkit 1.7.1 → 1.7.4
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/bin/awk.js +576 -84
- package/core/CLAUDE.md +1 -1
- package/core/GEMINI.md +148 -167
- package/core/GEMINI.md.bak +149 -116
- package/core/skill-runtime-manifest.json +3 -0
- package/docs/Claude Fable 5.md +3826 -0
- package/docs/android_kotlin_system_instruction.md +210 -0
- package/docs/brainstorm_ponytail_integration.md +146 -0
- package/docs/brainstorm_smart_setup.md +113 -0
- package/docs/deep-research-report (1).md +293 -0
- package/docs/history/GEMINI.v1.md +135 -0
- package/docs/history/brainstorm_antigravity_unified_architecture.v1.md +105 -0
- package/docs/history/implementation_plan.v1.md +58 -0
- package/package.json +4 -1
- package/scripts/artifact-storage.js +130 -0
- package/scripts/automation-gate.js +35 -2
- package/scripts/claude-plan.js +76 -0
- package/scripts/dependency-manager.js +210 -0
- package/scripts/exec-rtk.js +11 -5
- package/scripts/i18n-helper.js +381 -0
- package/scripts/multi-model-pipeline.js +144 -0
- package/skill-packs/mobile-ios/pack.json +4 -2
- package/skill-packs/reverse-engineering/pack.json +1 -0
- package/skills/CATALOG.md +20 -0
- package/skills/GEMINI.md +9 -1
- package/skills/TRIGGER_INDEX.md +10 -0
- package/skills/ai-music/SKILL.md +275 -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/animal-island-ui-style/SKILL.md +1450 -0
- package/skills/app-store-review-agent/SKILL.md +164 -0
- package/skills/app-store-review-agent/references/guidelines/README.md +154 -0
- package/skills/app-store-review-agent/references/guidelines/by-app-type/ai_apps.md +37 -0
- package/skills/app-store-review-agent/references/guidelines/by-app-type/all_apps.md +50 -0
- package/skills/app-store-review-agent/references/guidelines/by-app-type/crypto_finance.md +31 -0
- package/skills/app-store-review-agent/references/guidelines/by-app-type/games.md +31 -0
- package/skills/app-store-review-agent/references/guidelines/by-app-type/health_fitness.md +31 -0
- package/skills/app-store-review-agent/references/guidelines/by-app-type/kids.md +27 -0
- package/skills/app-store-review-agent/references/guidelines/by-app-type/macos.md +38 -0
- package/skills/app-store-review-agent/references/guidelines/by-app-type/social_ugc.md +32 -0
- package/skills/app-store-review-agent/references/guidelines/by-app-type/subscription_iap.md +34 -0
- package/skills/app-store-review-agent/references/guidelines/by-app-type/vpn.md +18 -0
- package/skills/app-store-review-agent/references/rules/design/minimum_functionality.md +96 -0
- package/skills/app-store-review-agent/references/rules/design/sign_in_with_apple.md +54 -0
- package/skills/app-store-review-agent/references/rules/entitlements/unused_entitlements.md +83 -0
- package/skills/app-store-review-agent/references/rules/metadata/accurate_metadata.md +54 -0
- package/skills/app-store-review-agent/references/rules/metadata/apple_trademark.md +99 -0
- package/skills/app-store-review-agent/references/rules/metadata/china_storefront.md +72 -0
- package/skills/app-store-review-agent/references/rules/metadata/competitor_terms.md +56 -0
- package/skills/app-store-review-agent/references/rules/metadata/subscription_metadata.md +81 -0
- package/skills/app-store-review-agent/references/rules/privacy/privacy_manifest.md +84 -0
- package/skills/app-store-review-agent/references/rules/privacy/unnecessary_data.md +60 -0
- package/skills/app-store-review-agent/references/rules/subscription/misleading_pricing.md +63 -0
- package/skills/app-store-review-agent/references/rules/subscription/missing_tos_pp.md +54 -0
- package/skills/awf-ponytail/SKILL.md +91 -0
- package/skills/awf-ponytail-review/SKILL.md +67 -0
- package/skills/awf-session-restore/SKILL.md +3 -3
- package/skills/brainstorm-agent/SKILL.md +11 -2
- package/skills/brainstorm-agent/templates/brief-template.md +8 -0
- package/skills/claude-planner/SKILL.md +47 -0
- package/skills/code-review/SKILL.md +87 -0
- package/skills/expo-game-development/SKILL.md +163 -0
- package/skills/flutter/LICENSE.txt +202 -0
- package/skills/flutter/SKILL.md +127 -0
- package/skills/flutter-project-creater/LICENSE.txt +202 -0
- package/skills/flutter-project-creater/SKILL.md +106 -0
- package/skills/game-developer/SKILL.md +163 -0
- package/skills/game-developer/references/ecs-patterns.md +501 -0
- package/skills/game-developer/references/multiplayer-networking.md +475 -0
- package/skills/game-developer/references/performance-optimization.md +422 -0
- package/skills/game-developer/references/unity-patterns.md +271 -0
- package/skills/game-developer/references/unreal-cpp.md +352 -0
- package/skills/generate-gui-assets/SKILL.md +305 -0
- package/skills/generate-gui-assets/agents/openai.yaml +4 -0
- package/skills/generate-gui-assets/references/catalog-schema.md +58 -0
- package/skills/generate-gui-assets/references/extraction-techniques.md +21 -0
- package/skills/generate-gui-assets/references/prompt-patterns.md +58 -0
- package/skills/generate-gui-assets/scripts/__pycache__/clean_chroma_edges.cpython-311.pyc +0 -0
- package/skills/generate-gui-assets/scripts/build_gui_contact_sheet.py +51 -0
- package/skills/generate-gui-assets/scripts/clean_chroma_edges.py +262 -0
- package/skills/generate-gui-assets/scripts/copy_approved_icons.py +64 -0
- package/skills/generate-gui-assets/scripts/prepare_gui_asset_run.py +91 -0
- package/skills/generate-gui-assets/scripts/suggest_grid_options.py +63 -0
- package/skills/generate-gui-assets/scripts/validate_gui_catalog.py +50 -0
- package/skills/godot-game-development/SKILL.md +142 -0
- package/skills/hatch-pet/LICENSE.txt +201 -0
- package/skills/hatch-pet/SKILL.md +420 -0
- package/skills/hatch-pet/agents/openai.yaml +4 -0
- package/skills/hatch-pet/references/animation-rows.md +29 -0
- package/skills/hatch-pet/references/codex-pet-contract.md +35 -0
- package/skills/hatch-pet/references/qa-rubric.md +60 -0
- package/skills/hatch-pet/scripts/__pycache__/clean_chroma_edges.cpython-311.pyc +0 -0
- package/skills/hatch-pet/scripts/clean_chroma_edges.py +262 -0
- package/skills/hatch-pet/scripts/compose_atlas.py +150 -0
- package/skills/hatch-pet/scripts/derive_running_left_from_running_right.py +143 -0
- package/skills/hatch-pet/scripts/extract_strip_frames.py +323 -0
- package/skills/hatch-pet/scripts/finalize_pet_run.py +382 -0
- package/skills/hatch-pet/scripts/generate_pet_images.py +287 -0
- package/skills/hatch-pet/scripts/inspect_frames.py +246 -0
- package/skills/hatch-pet/scripts/make_contact_sheet.py +96 -0
- package/skills/hatch-pet/scripts/package_custom_pet.py +108 -0
- package/skills/hatch-pet/scripts/pet_job_status.py +117 -0
- package/skills/hatch-pet/scripts/prepare_pet_run.py +673 -0
- package/skills/hatch-pet/scripts/queue_pet_repairs.py +172 -0
- package/skills/hatch-pet/scripts/record_imagegen_result.py +250 -0
- package/skills/hatch-pet/scripts/render_animation_videos.py +134 -0
- package/skills/hatch-pet/scripts/render_animation_videos.sh +5 -0
- package/skills/hatch-pet/scripts/validate_atlas.py +139 -0
- package/skills/i18n-orchestrator/SKILL.md +37 -0
- package/skills/ios-simulator-skill/SKILL.md +390 -0
- package/skills/ios-simulator-skill/scripts/accessibility_audit.py +300 -0
- package/skills/ios-simulator-skill/scripts/app_launcher.py +326 -0
- package/skills/ios-simulator-skill/scripts/app_state_capture.py +400 -0
- package/skills/ios-simulator-skill/scripts/appearance.py +385 -0
- package/skills/ios-simulator-skill/scripts/build_and_test.py +348 -0
- package/skills/ios-simulator-skill/scripts/clipboard.py +103 -0
- package/skills/ios-simulator-skill/scripts/common/__init__.py +61 -0
- package/skills/ios-simulator-skill/scripts/common/cache_utils.py +289 -0
- package/skills/ios-simulator-skill/scripts/common/device_utils.py +462 -0
- package/skills/ios-simulator-skill/scripts/common/env_config.py +35 -0
- package/skills/ios-simulator-skill/scripts/common/hang_pipeline.py +862 -0
- package/skills/ios-simulator-skill/scripts/common/hang_sessions.py +490 -0
- package/skills/ios-simulator-skill/scripts/common/idb_utils.py +180 -0
- package/skills/ios-simulator-skill/scripts/common/screenshot_utils.py +338 -0
- package/skills/ios-simulator-skill/scripts/container.py +668 -0
- package/skills/ios-simulator-skill/scripts/gesture.py +394 -0
- package/skills/ios-simulator-skill/scripts/hang_watcher.py +1533 -0
- package/skills/ios-simulator-skill/scripts/keyboard.py +391 -0
- package/skills/ios-simulator-skill/scripts/localization_audit.py +483 -0
- package/skills/ios-simulator-skill/scripts/location.py +467 -0
- package/skills/ios-simulator-skill/scripts/log_monitor.py +493 -0
- package/skills/ios-simulator-skill/scripts/model_inspector.py +645 -0
- package/skills/ios-simulator-skill/scripts/navigator.py +461 -0
- package/skills/ios-simulator-skill/scripts/privacy_manager.py +310 -0
- package/skills/ios-simulator-skill/scripts/push_notification.py +240 -0
- package/skills/ios-simulator-skill/scripts/screen_mapper.py +296 -0
- package/skills/ios-simulator-skill/scripts/sim_health_check.sh +245 -0
- package/skills/ios-simulator-skill/scripts/sim_list.py +299 -0
- package/skills/ios-simulator-skill/scripts/simctl_boot.py +312 -0
- package/skills/ios-simulator-skill/scripts/simctl_create.py +316 -0
- package/skills/ios-simulator-skill/scripts/simctl_delete.py +357 -0
- package/skills/ios-simulator-skill/scripts/simctl_erase.py +351 -0
- package/skills/ios-simulator-skill/scripts/simctl_shutdown.py +290 -0
- package/skills/ios-simulator-skill/scripts/simulator_selector.py +375 -0
- package/skills/ios-simulator-skill/scripts/status_bar.py +250 -0
- package/skills/ios-simulator-skill/scripts/test_recorder.py +323 -0
- package/skills/ios-simulator-skill/scripts/visual_diff.py +235 -0
- package/skills/ios-simulator-skill/scripts/xcode/__init__.py +13 -0
- package/skills/ios-simulator-skill/scripts/xcode/builder.py +397 -0
- package/skills/ios-simulator-skill/scripts/xcode/cache.py +204 -0
- package/skills/ios-simulator-skill/scripts/xcode/config.py +178 -0
- package/skills/ios-simulator-skill/scripts/xcode/reporter.py +343 -0
- package/skills/ios-simulator-skill/scripts/xcode/xcresult.py +451 -0
- package/skills/ios-visual-qa-strategist/SKILL.md +111 -0
- package/skills/ios-visual-qa-strategist/agents/openai.yaml +4 -0
- package/skills/ios-visual-qa-strategist/references/ios-tool-selection.md +61 -0
- package/skills/ios-visual-qa-strategist/references/minimal-capture-policy.md +56 -0
- package/skills/ios-visual-qa-strategist/references/visual-reasoning-heuristics.md +53 -0
- package/skills/orchestrator/SKILL.md +0 -20
- package/skills/persistent-storage/SKILL.md +55 -0
- package/skills/short-maker/SKILL.md +23 -0
- package/skills/short-maker/scripts/effects.js +56 -0
- package/skills/short-maker/scripts/shortmaker-bridge.js +332 -0
- package/skills/short-maker/scripts/videomix.js +601 -0
- package/skills/short-maker/templates/hyperframes/cinematic-character.template.html +172 -0
- package/skills/short-maker/templates/hyperframes/index.template.html +194 -0
- package/skills/smali-to-kotlin/SKILL.md +128 -0
- package/skills/smali-to-kotlin/examples/getting-started/tech-stack.md +58 -0
- package/skills/smali-to-kotlin/examples/pipeline/data-ui-parity.md +118 -0
- package/skills/smali-to-kotlin/examples/pipeline/scanner-and-bootstrap.md +106 -0
- package/skills/smali-to-kotlin/library-patterns.md +189 -0
- package/skills/smali-to-kotlin/phase-0-discovery.md +128 -0
- package/skills/smali-to-kotlin/phase-1-architecture.md +166 -0
- package/skills/smali-to-kotlin/phase-2-blueprint-ui.md +347 -0
- package/skills/smali-to-kotlin/phase-2-blueprint.md +228 -0
- package/skills/smali-to-kotlin/phase-3-build.md +248 -0
- package/skills/smali-to-kotlin/phase-3-logic-build.md +268 -0
- package/skills/smali-to-kotlin/smali-reading-guide.md +310 -0
- package/skills/smali-to-kotlin/templates/app-map.md +101 -0
- package/skills/smali-to-kotlin/templates/architecture.md +142 -0
- package/skills/smali-to-kotlin/templates/blueprint.md +145 -0
- package/skills/spec-gate/SKILL.md +6 -2
- package/skills/symphony-enforcer/SKILL.md +8 -0
- package/skills/symphony-enforcer/examples/mindful-stop.md +2 -0
- package/skills/symphony-enforcer/examples/three-phase.md +16 -0
- package/skills/symphony-enforcer/examples/trigger-points.md +7 -1
- package/skills/unity-game-development/SKILL.md +231 -0
- package/skills/video-edit/SKILL.md +36 -0
- package/skills/video-edit/scripts/video_edit.py +324 -0
- package/templates/project-identity/android.json +2 -2
- package/templates/project-identity/backend-nestjs.json +2 -2
- package/templates/project-identity/expo.json +2 -2
- package/templates/project-identity/ios.json +2 -2
- package/templates/project-identity/web-nextjs.json +2 -2
- package/templates/setup-mapping.json +48 -0
- package/templates/specs/design-template.md +161 -71
- package/templates/specs/requirements-template.md +65 -133
- package/templates/specs/task-spec-template.xml +3 -0
- package/workflows/_uncategorized/critic.md +40 -0
- package/workflows/_uncategorized/git-rebase-flow.md +81 -0
- package/workflows/_uncategorized/image-gen.md +118 -0
- package/workflows/_uncategorized/multi-model-pipeline.md +60 -0
- package/workflows/_uncategorized/pixel-gen.md +86 -0
- package/workflows/_uncategorized/pixel-setup.md +90 -0
- package/workflows/_uncategorized/ponytail-review.md +59 -0
- package/workflows/_uncategorized/reverse-android-build.md +222 -0
- package/workflows/_uncategorized/reverse-android-design.md +139 -0
- package/workflows/_uncategorized/reverse-android-discover.md +150 -0
- package/workflows/_uncategorized/reverse-android-scan.md +158 -0
- package/workflows/_uncategorized/reverse-android.md +143 -0
- package/workflows/_uncategorized/reverse-ios-build.md +240 -0
- package/workflows/_uncategorized/reverse-ios-design.md +112 -0
- package/workflows/_uncategorized/reverse-ios-discover.md +120 -0
- package/workflows/_uncategorized/reverse-ios-scan.md +155 -0
- package/workflows/_uncategorized/reverse-ios.md +152 -0
- package/workflows/_uncategorized/safety-router.md +34 -0
- package/workflows/_uncategorized/teach.md +89 -0
- package/workflows/_uncategorized/verify-ui.md +53 -0
- package/workflows/_uncategorized/visualize-screenshots.md +34 -0
- package/workflows/ads/ads-analyst.md +201 -0
- package/workflows/ads/ads-audit.md +106 -0
- package/workflows/ads/ads-optimize.md +97 -0
- package/workflows/ads/ads-targeting.md +241 -0
- package/workflows/ads/adsExpert.md +160 -0
- package/workflows/ads/smali-ads-config.md +400 -0
- package/workflows/ads/smali-ads-flow.md +331 -0
- package/workflows/ads/smali-ads-interstitial.md +377 -0
- package/workflows/ads/smali-ads-native.md +382 -0
- package/workflows/context/teach.md +89 -0
- package/workflows/gitnexus.md +8 -8
- package/workflows/lifecycle/brainstorm.md +43 -0
- package/workflows/lifecycle/code.md +5 -0
- package/workflows/lifecycle/init.md +23 -5
- package/workflows/lifecycle/multi-model-pipeline.md +60 -0
- package/workflows/quality/ponytail-review.md +59 -0
- package/workflows/roles/critic.md +40 -0
- package/workflows/roles/safety-router.md +34 -0
package/core/CLAUDE.md
CHANGED
|
@@ -127,7 +127,7 @@ Khi AI cần tự quyết định mà không hỏi user:
|
|
|
127
127
|
- Risk HIGH/CRITICAL → PHẢI cảnh báo user trước khi sửa.
|
|
128
128
|
- Explore code lạ → ưu tiên `gitnexus_query` thay vì grep thủ công.
|
|
129
129
|
- Rename symbol → PHẢI dùng `gitnexus_rename` (dry_run trước).
|
|
130
|
-
- Index stale → cảnh báo "⚠️ chạy `npx gitnexus analyze`".
|
|
130
|
+
- Index stale → cảnh báo "⚠️ chạy `pnpm dlx gitnexus analyze` (hoặc `npx gitnexus analyze`)".
|
|
131
131
|
|
|
132
132
|
---
|
|
133
133
|
|
package/core/GEMINI.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
# GEMINI.md — Antigravity v12.
|
|
1
|
+
# GEMINI.md — Antigravity v12.6
|
|
2
2
|
|
|
3
|
-
> Rules
|
|
3
|
+
> Rules only. Updated: 2026-06-15
|
|
4
4
|
|
|
5
5
|
---
|
|
6
6
|
|
|
@@ -14,28 +14,17 @@
|
|
|
14
14
|
## Session Protocol
|
|
15
15
|
|
|
16
16
|
> [!CAUTION]
|
|
17
|
-
> MỌI session
|
|
18
|
-
> Bỏ qua = vi phạm. KHÔNG CÓ NGOẠI LỆ.
|
|
17
|
+
> MỌI session code/debug/plan PHẢI chạy init chain TRƯỚC action. Bỏ qua = vi phạm.
|
|
19
18
|
|
|
20
19
|
### Init Chain (BẮT BUỘC)
|
|
21
|
-
|
|
22
20
|
```
|
|
23
|
-
symphony-orchestrator → awf-session-restore → nm-memory-sync → orchestrator → action
|
|
21
|
+
symphony-orchestrator → awf-session-restore (gitnexus state) → nm-memory-sync → orchestrator → action
|
|
24
22
|
```
|
|
25
23
|
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
- Câu hỏi đơn giản (hỏi-đáp, giải thích) → không cần init chain.
|
|
31
|
-
- User nói rõ bỏ qua → được phép.
|
|
32
|
-
|
|
33
|
-
### Exit Protocol
|
|
34
|
-
|
|
35
|
-
- Task done → auto-complete Symphony → **BẮT BUỘC** `symphony next` + present gợi ý.
|
|
36
|
-
- Kết thúc message → **LUÔN** kèm "Next steps" section.
|
|
37
|
-
- `nm-memory-sync` auto-save (W1–W4 triggers).
|
|
38
|
-
- Deploy/push → kiểm tra in-progress tasks trước, confirm với user.
|
|
24
|
+
- **Ngoại lệ:** Câu hỏi đơn giản hoặc user yêu cầu bỏ qua.
|
|
25
|
+
- **Exit Protocol:** Task done → `symphony next` + present "Next steps" (gồm `🧘 Dừng phiên` nếu ≥3 tasks done hoặc xong Gate lớn). nm-memory-sync auto-save. Deploy/push → check in-progress tasks trước.
|
|
26
|
+
- **Context Recovery:** Re-read `.project-identity`, GEMINI.md, chạy `nmem_recall`, thông báo user.
|
|
27
|
+
- **File-Level Guards:** Khi sửa `symphony/**/*.json`, `.project-identity`, hoặc `**/SKILL.md` → Đọc lại SKILL.md tương ứng.
|
|
39
28
|
|
|
40
29
|
---
|
|
41
30
|
|
|
@@ -43,168 +32,160 @@ Mỗi skill tự xử lý gate logic riêng — xem SKILL.md của từng skill.
|
|
|
43
32
|
|
|
44
33
|
### Code
|
|
45
34
|
- Production quality. File < 500 lines.
|
|
46
|
-
- Không sửa code ngoài scope.
|
|
47
|
-
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
-
|
|
66
|
-
- `
|
|
67
|
-
-
|
|
68
|
-
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
-
|
|
83
|
-
-
|
|
84
|
-
-
|
|
85
|
-
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
-
|
|
95
|
-
-
|
|
96
|
-
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
-
|
|
100
|
-
-
|
|
101
|
-
- Trong lúc code, nếu cần sửa schema/UI khác approved design → ⛔ DỪNG, quay Gate 2/2.5 tương ứng.
|
|
102
|
-
- Chi tiết: xem `orchestrator/SKILL.md` (triage) + `symphony-enforcer/SKILL.md` (TP1.7 checkpoints).
|
|
35
|
+
- Không sửa code ngoài scope. Không hardcode secrets → `.env`. Không `git reset --hard`.
|
|
36
|
+
- AI models: Gemini 2.5+ hoặc mới hơn. Firebase: Firebase AI Logic SDK.
|
|
37
|
+
|
|
38
|
+
### Lazy Dev Mode (Ponytail Rules)
|
|
39
|
+
- **Mặc định BẬT.** Tắt qua `.project-identity`: `automation.ponytailMode.enabled: false`.
|
|
40
|
+
- **Ladder of Simplicity** — TRƯỚC khi viết code, dừng ở bậc đầu tiên thỏa mãn:
|
|
41
|
+
1. YAGNI: Không cần → bỏ qua, nói 1 dòng.
|
|
42
|
+
2. Stdlib có? → Dùng stdlib.
|
|
43
|
+
3. Native platform có? → Dùng native (`<input type="date">`, CSS transitions, DB constraints).
|
|
44
|
+
4. Dependency đã cài có? → Dùng nó. KHÔNG thêm dependency mới trừ khi user cho phép.
|
|
45
|
+
5. Viết được 1 dòng? → 1 dòng.
|
|
46
|
+
6. Chỉ khi tất cả trên không thỏa: viết lượng code tối thiểu.
|
|
47
|
+
- **Complexity Guard**: CẤM tạo abstractions không được yêu cầu (interface 1 implementation, factory 1 product, config cho giá trị không đổi). CẤM boilerplate "cho tương lai".
|
|
48
|
+
- **Simplification Marker**: Đánh dấu giản lược có chủ đích bằng `// ponytail: [giới hạn], [upgrade path]`.
|
|
49
|
+
- **Ngoại lệ KHÔNG được lazy**: Input validation tại trust boundaries, error handling chống mất dữ liệu, security, accessibility, và mọi thứ user yêu cầu rõ ràng.
|
|
50
|
+
|
|
51
|
+
### Auto-Commit After Build (BẮT BUỘC)
|
|
52
|
+
- Build OK → TỰ ĐỘNG `git add` → `git commit` → `git push`. KHÔNG hỏi user.
|
|
53
|
+
- **Commit Message (MANDATORY):** AI PHẢI tự tạo commit message MÔ TẢ cụ thể công việc đã làm. CẤM message chung chung (`update`, `wip`, `changes`).
|
|
54
|
+
- Format: `type(scope): mô tả ngắn gọn` (conventional commits).
|
|
55
|
+
- Ví dụ ĐÚNG: `feat(auth): add Google sign-in flow`, `fix(home): resolve banner overlap on iPad`, `refactor(scripts): smart commit message generator`.
|
|
56
|
+
- Ví dụ SAI: `chore: update`, `feat(app): update development`, `update files`.
|
|
57
|
+
- AI PHẢI truyền message khi gọi: `awkit gate git auto "feat(scope): mô tả"`.
|
|
58
|
+
- Push (non-force) SafeToAutoRun=true.
|
|
59
|
+
- Push fail → retry `git pull --rebase && git push` 1 lần. Vẫn fail → báo user, KHÔNG force push.
|
|
60
|
+
|
|
61
|
+
### Command Wrapper & Build Automation
|
|
62
|
+
- Build: CHỈ dùng `awkit build`. CẤM gọi native (`xcodebuild`, `./gradlew`, `npm run build`).
|
|
63
|
+
- `automation.build.enabled: false` → DỪNG, báo user. KHÔNG fallback native.
|
|
64
|
+
- Thêm params qua `--`: `awkit build -- -destination '...'`. Bypass wrapper = VI PHẠM.
|
|
65
|
+
|
|
66
|
+
### 7-Gate System
|
|
67
|
+
- Triage: TRIVIAL (→ Gate 4 thẳng) | MODERATE (→ G3+4+5) | COMPLEX (→ all gates).
|
|
68
|
+
- Gates: G1 brainstorm → G1.5 module-spec (COMPLEX+>3mod) → G2 spec-gate → G2.5 visual (skip nếu backend) → G3 symphony-enforcer → G4 execution → G5 verification.
|
|
69
|
+
- **Goal Mode Override:** Khi đang ở goal mode (`/goal`, active Codex goal, hoặc user nói rõ "goal mode") → gates là checklist nội bộ, KHÔNG dừng chờ user approval ở G2/G2.5/G4 checkpoints. AI tự chọn best-effort, tự verify, ghi assumption, rồi tiếp tục tới khi goal complete/bị block thật sự. Safety/destructive/security vẫn phải hỏi.
|
|
70
|
+
- **Gate 4 Three-Phase:**
|
|
71
|
+
- Phase A 🏗️ Infrastructure → B 🎨 UI Shell (mock) → C ⚡ Logic (real data).
|
|
72
|
+
- COMPLEX+UI: 3 phases bắt buộc. MODERATE+UI: A+C gộp, B optional. TRIVIAL: bypass.
|
|
73
|
+
- Phase B xong → checkpoint UI; normal mode chờ "APPROVE UI", goal mode tự verify và đi tiếp.
|
|
74
|
+
- Mỗi feature Phase C xong → checkpoint user test; goal mode batch/tự verify và đi tiếp.
|
|
75
|
+
- Kiro: `.kiro/specs/` → auto-accelerate G1,1.5,2,3.
|
|
76
|
+
- **Gate 2 Claude Planner (New):** Khi Gate 2 (Spec/Architecture Planning) kích hoạt cho MODERATE hoặc COMPLEX tasks, AI tự động chạy `claude-planner` bằng cách gọi `scripts/claude-plan.js`. Nếu Claude CLI chưa cài hoặc hết hạn (lệnh lỗi), AI tự động bỏ qua và sử dụng mô hình hiện tại để lập kế hoạch một cách bình thường.
|
|
77
|
+
- Sửa schema/UI ngoài approved design → ⛔ DỪNG quay G2/2.5.
|
|
78
|
+
- Chi tiết: `orchestrator/SKILL.md` + `symphony-enforcer/SKILL.md`.
|
|
79
|
+
|
|
80
|
+
### Mindful Stop
|
|
81
|
+
- Iterate ≥3 lần trên 1 feature → DỪNG: "⏸️ Đề xuất commit và trải nghiệm thực tế."
|
|
82
|
+
- Keywords [polish, optimize, refine, tối ưu, tweak] → hỏi "Vấn đề cụ thể? Hay phòng ngừa?" → không rõ → backlog P2.
|
|
83
|
+
- ≥3 tasks done hoặc xong Gate lớn → suggest "🧘 Dừng phiên".
|
|
84
|
+
- Goal mode → KHÔNG dừng vì milestone/gate; chỉ note ngắn "rest suggested" rồi tiếp tục.
|
|
85
|
+
- KHÔNG tự đề xuất tối ưu trừ security/crash bug.
|
|
86
|
+
|
|
87
|
+
### Token Budget & Auto-Recap
|
|
88
|
+
- Chủ động giám sát ngân sách token của phiên làm việc.
|
|
89
|
+
- Nếu token tích lũy đạt trên `150,000` tokens, Agent phải tự động kích hoạt workflow `/recap` ngầm để nén ngữ cảnh và lưu file trạng thái `.brain/session.json` gọn gàng trước khi tiếp tục.
|
|
103
90
|
|
|
104
91
|
### NeuralMemory
|
|
105
|
-
- Brain = projectId.
|
|
106
|
-
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
-
|
|
126
|
-
-
|
|
127
|
-
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
-
|
|
133
|
-
-
|
|
134
|
-
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
92
|
+
- Brain = projectId. PHẢI switch brain TRƯỚC mọi nmem call.
|
|
93
|
+
- `nmem_remember()` tag projectId. Cross-brain: `nmem_recall(query, brains=["default", projectId])`.
|
|
94
|
+
|
|
95
|
+
### Memory Discipline & Boundaries
|
|
96
|
+
- Khi áp dụng thông tin từ NeuralMemory:
|
|
97
|
+
1. KHÔNG dùng meta-commentary hay các từ chỉ thị dữ liệu: CẤM dùng "Tôi thấy từ profile...", "Dựa trên bộ nhớ...", "Tôi nhớ rằng...".
|
|
98
|
+
2. Phản hồi tự nhiên như thể vốn đã biết thông tin đó, giống như một đồng nghiệp con người.
|
|
99
|
+
3. KHÔNG tự động gợi nhắc các thông tin nhạy cảm cũ nếu người dùng không chủ động đề cập.
|
|
100
|
+
|
|
101
|
+
### Anti-Yapping & Token Optimization
|
|
102
|
+
- Sau khi dùng tool sửa code → KHÔNG in lại code trong chat. Tóm tắt bằng bullets.
|
|
103
|
+
- Code block trong chat: tối đa 10 dòng. Show diff → dùng `render_diffs()`.
|
|
104
|
+
|
|
105
|
+
### Image Generation Efficiency
|
|
106
|
+
- Image gen: grid/spritesheet cho batch variants, không gen từng ảnh rời.
|
|
107
|
+
|
|
108
|
+
### Proactive UI Asset Generation (MANDATORY)
|
|
109
|
+
- **Asset Audit:** Trong Gate 2.5 (Visual Design) và Gate 4 Phase B (UI Shell), BẮT BUỘC rà soát mã nguồn/thiết kế để phát hiện các UI assets bị thiếu (nút bấm, panel, icon, pet, egg...).
|
|
110
|
+
- **Cấm Placeholders:** TUYỆT ĐỐI KHÔNG dùng placeholder rỗng hoặc icon hệ thống chung chung nếu thiếu asset.
|
|
111
|
+
- **Tự động ủy thác Codex CLI:** BẮT BUỘC gọi trực tiếp lệnh non-interactive `codex exec` của Codex CLI để thực hiện tạo asset.
|
|
112
|
+
- **Cấu trúc Lệnh:**
|
|
113
|
+
- Đối với UI assets: `codex exec "Generate GUI asset: [Prompt/Style/Theme] and save it to [path] using the generate-gui-assets skill rules."`
|
|
114
|
+
- Đối với Pet/Egg assets: `codex exec "Generate pet companion asset: [Pet Type/State] and save it to [path] using the hatch-pet skill rules and grid configuration [grid]."`
|
|
115
|
+
- **Chi tiết & Approval:** Tự động thiết lập prompt chi tiết dựa trên Theme của App, tuân thủ tiêu chuẩn Solid Background và hỏi ý kiến user trước khi thực thi lệnh.
|
|
116
|
+
|
|
117
|
+
|
|
118
|
+
### Communication (CAVEMAN ULTRA)
|
|
119
|
+
- Chat: Tiếng Việt, tối đa 1-2 câu ngắn. Code/Docs: Tiếng Anh.
|
|
120
|
+
- CẤM giải thích dài, chào hỏi. Chỉ xuất KẾT QUẢ.
|
|
121
|
+
- Planning artifacts (implementation_plan.md, walkthrough.md) VẪN chi tiết theo format chuẩn.
|
|
122
|
+
- Tài liệu thảo luận & brainstorm (Brief, Requirements, Brainstorm) PHẢI dùng tiếng Việt (hoặc ngôn ngữ giao tiếp của User), chỉ Code/Architecture mới bắt buộc dùng tiếng Anh.
|
|
123
|
+
|
|
124
|
+
### Brainstorm & Plan Integrity (BPIP)
|
|
125
|
+
- CẤM ghi đè (overwrite) toàn bộ BRIEF.md hoặc plan.md khi tinh chỉnh ý tưởng.
|
|
126
|
+
- PHẢI sử dụng công cụ sửa code (replace_file_content) để cập nhật từng phần.
|
|
127
|
+
- PHẢI duy trì bảng Revision History ở đầu mỗi file design/planning.
|
|
128
|
+
- PHẢI lưu bản sao dự phòng vào `docs/history/` trước khi sửa đổi lớn (định dạng `[filename].v[N].md`, ví dụ: `implementation_plan.v1.md`).
|
|
129
|
+
|
|
130
|
+
|
|
131
|
+
### Anti-sycophancy
|
|
132
|
+
- Push back khi approach có vấn đề. Nêu ưu+nhược, không chỉ list ưu điểm.
|
|
133
|
+
- Cảnh báo TRƯỚC khi implement nếu vi phạm best practices. Nói "Tôi không chắc" khi không chắc.
|
|
134
|
+
|
|
135
|
+
### Wise Teacher Protocol
|
|
136
|
+
- Khi người dùng kích hoạt `/teach`, áp dụng cơ chế Incremental Learning:
|
|
137
|
+
1. Đảm bảo user hiểu 3 phần: Vấn đề (Problem), Giải pháp (Solution), Bối cảnh (Broader Context).
|
|
138
|
+
2. Bắt buộc yêu cầu user tự trình bày hiểu biết (restatement) trước khi giảng dạy.
|
|
139
|
+
3. Cung cấp 3 cấp độ giải thích linh hoạt: ELI5, ELI14, và ELII (Intern).
|
|
140
|
+
4. Đánh giá kiểm tra qua trắc nghiệm (`AskUserQuestion`), chỉ hiện đáp án sau khi user submit.
|
|
141
|
+
5. Luôn ghi chép và cập nhật checklist học tập tại `.brain/teach_checklist.md`.
|
|
142
|
+
|
|
143
|
+
### Safety Guardrails
|
|
144
|
+
- CẤM SafeToAutoRun cho: recursive delete (`rm -rf`), force push, `DROP/DELETE` (no WHERE), docker prune, publish, deploy production.
|
|
145
|
+
- Commit: CHỈ qua `awkit gate git auto`. CẤM `git commit` trực tiếp qua bash.
|
|
146
|
+
- Destructive command → double-confirm user. Không chắc → hỏi trước.
|
|
147
|
+
|
|
148
|
+
### Subagent Orchestration & Protocol
|
|
149
|
+
- **Định tuyến trước, Tìm kiếm sau:** Tuyệt đối không dùng `grep_search` hoặc `list_dir` diện rộng để định vị subagents (như `critic`). Bắt buộc tra cứu chỉ mục tại `skills/CATALOG.md`, `skills/TRIGGER_INDEX.md` hoặc `skills/review/SKILL.md` trước.
|
|
150
|
+
- **Tận dụng Subagents Cô lập:** Sử dụng built-in subagents (`research` cho tìm kiếm codebase/log thô, `browser` cho các tác vụ UI) để tránh ô nhiễm context trên luồng chat chính.
|
|
151
|
+
- **Khởi tạo và Phân quyền:**
|
|
152
|
+
- Định nghĩa custom subagent bằng `define_subagent` (ví dụ: `critic` phải cấu hình read-only toolsets).
|
|
153
|
+
- Tái sử dụng subagent ở trạng thái `Idle` qua việc gửi tin nhắn thay vì tạo mới.
|
|
154
|
+
- Tuân thủ giới hạn lồng tác tử (nesting limit) tối đa 10 cấp.
|
|
155
|
+
|
|
156
|
+
### Mandatory Check-Then-Act Protocol (🔥 BẮT BUỘC)
|
|
157
|
+
- TRƯỚC khi dùng công cụ sửa code/run command lần đầu mỗi task, PHẢI tự trả lời trong `<thought>` (KHÔNG in ra chat):
|
|
158
|
+
1. Init Chain đã chạy?
|
|
159
|
+
2. KIẾN TRÚC: Đã xem CODEBASE.md? Đang sửa Definition (gốc) hay Usage (ngọn)? (Cấm grep bừa bãi).
|
|
160
|
+
3. Sửa symbol lớn? → `gitnexus_impact` trước.
|
|
161
|
+
4. Commit → `awkit gate git auto` only.
|
|
162
|
+
|
|
163
|
+
### Decision Principles
|
|
164
|
+
Complete>Shortcuts, Evidence>Assumptions, Standard>Custom, Explicit>Implicit, Test>Trust, Small>Big, Root>Leaves.
|
|
151
165
|
|
|
152
166
|
### Project Context
|
|
153
167
|
- CODEBASE.md tồn tại → KHÔNG scan raw directory.
|
|
154
168
|
- KHÔNG hỏi user về project structure.
|
|
155
169
|
- CODEBASE.md outdated → ghi chú "⚠️ dùng /codebase-sync".
|
|
156
170
|
|
|
157
|
-
### GitNexus (
|
|
158
|
-
-
|
|
159
|
-
-
|
|
160
|
-
-
|
|
161
|
-
-
|
|
162
|
-
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
-
|
|
166
|
-
|
|
167
|
-
### Kiro Specs (IDE Integration)
|
|
168
|
-
- `.kiro/specs/` tồn tại → PHẢI dùng làm source of truth cho Gates 1, 1.5, 2, 3.
|
|
169
|
-
- `requirements.md` → Gate 1 (Spec) + Gate 1.5 (Module Spec) AUTO-PASS.
|
|
170
|
-
- `design.md` → Gate 2 (Architecture) AUTO-APPROVE (pre-approved by IDE).
|
|
171
|
-
- `tasks.md` → Gate 3 (Tasks) AUTO-IMPORT vào Symphony.
|
|
172
|
-
- `.kiro/specs` ưu tiên hơn `docs/specs` khi cả hai tồn tại.
|
|
173
|
-
- Gate 2.5 (Visual) và Gate 5 (Verification) KHÔNG bị ảnh hưởng.
|
|
174
|
-
- Khi code (Gate 4), PHẢI đối chiếu với `.kiro/specs/<module>/` tương ứng.
|
|
175
|
-
- Chi tiết: xem `orchestrator/SKILL.md` (Kiro Spec Detection section).
|
|
176
|
-
|
|
177
|
-
### Multi-Agent Flow (Conductor / CLI Fallback)
|
|
178
|
-
- Việc gọi CLI bên ngoài (như `gemini`, `codex`) là **HOÀN TOÀN TÙY CHỌN** nhằm tối ưu token và mở rộng góc nhìn.
|
|
179
|
-
- Nếu CLI chưa cài đặt, bị lỗi auth, hoặc timeout → **BỎ QUA NGAY LẬP TỨC** và chạy bằng bộ công cụ chính của IDE. KHÔNG BẮT BUỘC. KHÔNG yêu cầu user cài đặt.
|
|
180
|
-
- CLI dùng **quota pool riêng** → không ảnh hưởng Antigravity quota.
|
|
181
|
-
- Trigger: refactor diện rộng, architecture analysis, cross-module review, kiểm tra logic lỗi.
|
|
182
|
-
- LUÔN dùng chế độ read-only (`--approval-mode plan` hoặc `suggest`). CLI KHÔNG ĐƯỢC phép sửa files trực tiếp.
|
|
183
|
-
- Thông báo user: "📡 Đang gọi CLI..." trước khi gọi. Nếu lỗi, báo cáo fallback nhẹ nhàng.
|
|
184
|
-
- Chi tiết: xem `gemini-conductor/SKILL.md` và `codex-conductor/SKILL.md`.
|
|
171
|
+
### Tư Duy Kiến Trúc & GitNexus (Anti-Grep-First)
|
|
172
|
+
- **Top-Down:** LUÔN đọc `CODEBASE.md` trước để map requirement vào đúng Layer kiến trúc.
|
|
173
|
+
- **Root > Leaves:** Đổi GIÁ TRỊ → Tìm Definition (gốc: theme, config, entity). CẤM grep blind value ở Usage (ngọn).
|
|
174
|
+
- **GitNexus Graph:** Có Anchor Class → `gitnexus_context` để hiểu luồng, `gitnexus_impact` TRƯỚC KHI sửa.
|
|
175
|
+
- `.gitnexus/` tồn tại → BẮT BUỘC dùng GitNexus. `gitnexus_detect_changes()` trước commit.
|
|
176
|
+
- Chi tiết: `gitnexus-intelligence/SKILL.md`.
|
|
177
|
+
|
|
178
|
+
### Kiro Specs
|
|
179
|
+
- `.kiro/specs/` tồn tại → source of truth: requirements.md (G1+1.5 AUTO-PASS), design.md (G2 AUTO-APPROVE), tasks.md (G3 AUTO-IMPORT).
|
|
180
|
+
- Gate 4 code PHẢI đối chiếu `.kiro/specs/<module>/`. Chi tiết: `orchestrator/SKILL.md`.
|
|
185
181
|
|
|
186
182
|
---
|
|
187
183
|
|
|
188
184
|
## Routing
|
|
189
185
|
|
|
190
|
-
- **Execution order:** `symphony-orchestrator` → `awf-session-restore` → `nm-memory-sync` → `symphony-enforcer` → `orchestrator` (triage + gate-check) → action
|
|
186
|
+
- **Execution order:** `symphony-orchestrator` → `awf-session-restore` (gitnexus state) → `nm-memory-sync` → `symphony-enforcer` → `orchestrator` (triage + gate-check) → action
|
|
191
187
|
- **Gate skills:** `orchestrator` (triage) → `brainstorm-agent` (G1) → `module-spec-writer` (G1.5) → `spec-gate` (G2) → `visual-design-gate` (G2.5) → `symphony-enforcer` (G3) → `verification-gate` (G5)
|
|
192
188
|
- **Code intelligence:** `gitnexus-intelligence` (impact analysis, blast radius, safe refactoring)
|
|
193
189
|
- **Skill catalog:** xem `orchestrator/SKILL.md`
|
|
194
|
-
- **Workflows:** 75+ (
|
|
190
|
+
- **Workflows:** 75+ (/xxx). Core: /init /code /debug /recap /next /todo /gitnexus /teach
|
|
195
191
|
- **Shortcuts:** `/todo` `/done` `/next`
|
|
196
|
-
|
|
197
|
-
---
|
|
198
|
-
|
|
199
|
-
## Paths
|
|
200
|
-
|
|
201
|
-
```
|
|
202
|
-
~/.gemini/antigravity/
|
|
203
|
-
├── GEMINI.md # Rules (file này)
|
|
204
|
-
├── global_workflows/ # Workflows
|
|
205
|
-
├── skills/ # Skills (auto-activate)
|
|
206
|
-
├── brain/ # Knowledge
|
|
207
|
-
├── symphony/ # Task DB
|
|
208
|
-
├── templates/ # Templates
|
|
209
|
-
└── schemas/ # Schemas
|
|
210
|
-
```
|