Skip to content

Commit 14d223c

Browse files
wishket-pjwJeremyDev87
authored andcommitted
feat: add multi-language keyword support and mandatory mode detection rules
Add multi-language support for PLAN/ACT/EVAL keywords and mandatory mode detection rules across all adapters - Add 4 language keyword support (Korean, Japanese, Chinese, Spanish) - Add MANDATORY keyword mode detection section to all AI adapter rule files - Update parse_mode tool description with MANDATORY enforcement rules - Implement multi-language keyword parsing logic with comprehensive tests - Add multi-keyword detection and warning functionality close #122
1 parent 33345a4 commit 14d223c

11 files changed

Lines changed: 532 additions & 30 deletions

File tree

.antigravity/rules/instructions.md

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,36 @@ Available specialist agents:
8787

8888
See agent details in [packages/rules/.ai-rules/agents/README.md](../../packages/rules/.ai-rules/agents/README.md)
8989

90+
## 🔴 MANDATORY: Keyword Mode Detection
91+
92+
<CODINGBUDDY_CRITICAL_RULE>
93+
94+
**When user message starts with PLAN, ACT, or EVAL keyword (or localized: Korean 계획/실행/평가, Japanese 計画/実行/評価, Chinese 计划/执行/评估, Spanish PLANIFICAR/ACTUAR/EVALUAR):**
95+
96+
1. **IMMEDIATELY** follow the mode-specific rules from `packages/rules/.ai-rules/rules/core.md`
97+
2. Apply the mode's workflow **EXACTLY**
98+
3. Do NOT proceed with your own interpretation
99+
100+
**This is MANDATORY, not optional.**
101+
102+
Failure to follow mode rules when these keywords are present will result in:
103+
- Missed critical checklists (Devil's Advocate Analysis, Impact Radius Analysis)
104+
- Incomplete evaluations
105+
- Quality issues not caught before deployment
106+
107+
**Red Flags** (STOP if you think these):
108+
| Thought | Reality |
109+
|---------|---------|
110+
| "I can handle EVAL myself" | NO. Follow mode rules FIRST. |
111+
| "The rules are similar anyway" | NO. Each mode has specific checklists. |
112+
| "I already know what to do" | NO. Rules may have been updated. |
113+
114+
</CODINGBUDDY_CRITICAL_RULE>
115+
116+
Example: `EVAL`**즉시** EVAL 모드 규칙 적용 → Devil's Advocate Analysis 수행
117+
118+
---
119+
90120
## Antigravity-Specific Features
91121

92122
### Task Boundaries

.claude/rules/custom-instructions.md

Lines changed: 27 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -53,15 +53,35 @@ Follow the common rules defined in `packages/rules/.ai-rules/` for consistency a
5353

5454
See [packages/rules/.ai-rules/agents/README.md](../../packages/rules/.ai-rules/agents/README.md) for details.
5555

56-
## Keyword Invocation
56+
## 🔴 MANDATORY: Keyword Mode Detection
5757

58-
사용자 프롬프트가 `PLAN`, `ACT`, `EVAL` 키워드로 시작하면:
59-
1. `parse_mode` MCP 도구를 호출하여 모드와 규칙을 가져옴
60-
2. 반환된 `instructions`를 따라 작업 수행
61-
3. 반환된 `rules`를 컨텍스트로 활용
62-
4. `warnings`가 있으면 사용자에게 안내
58+
<CODINGBUDDY_CRITICAL_RULE>
6359

64-
예시: `PLAN 인증 기능 설계` → parse_mode 호출 → PLAN 모드로 작업
60+
**When user message starts with PLAN, ACT, or EVAL keyword (or localized: Korean 계획/실행/평가, Japanese 計画/実行/評価, Chinese 计划/执行/评估, Spanish PLANIFICAR/ACTUAR/EVALUAR):**
61+
62+
1. **IMMEDIATELY** call `mcp__codingbuddy__parse_mode` with the user's prompt
63+
2. Follow the returned `instructions` **EXACTLY**
64+
3. Apply the returned `rules` as context
65+
4. If `warnings` are present, inform the user
66+
67+
**This is MANDATORY, not optional.**
68+
69+
Failure to call `parse_mode` when these keywords are present will result in:
70+
- Missed critical checklists (Devil's Advocate Analysis, Impact Radius Analysis)
71+
- Incomplete evaluations
72+
- Quality issues not caught before deployment
73+
74+
**Red Flags** (STOP if you think these):
75+
| Thought | Reality |
76+
|---------|---------|
77+
| "I can handle EVAL myself" | NO. Call parse_mode FIRST. |
78+
| "The rules are similar anyway" | NO. Each mode has specific checklists. |
79+
| "I'll save a tool call" | NO. parse_mode MUST be called FIRST. |
80+
| "I already know what to do" | NO. Rules may have been updated. |
81+
82+
</CODINGBUDDY_CRITICAL_RULE>
83+
84+
예시: `PLAN 인증 기능 설계`**즉시** parse_mode 호출 → PLAN 모드로 작업
6585

6686
## Claude Code Specific
6787

.codex/rules/system-prompt.md

Lines changed: 27 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -117,15 +117,35 @@ For complete agent documentation, see [packages/rules/.ai-rules/agents/README.md
117117

118118
---
119119

120-
## Keyword Invocation
120+
## 🔴 MANDATORY: Keyword Mode Detection
121121

122-
When user prompt starts with `PLAN`, `ACT`, or `EVAL`:
123-
1. Call `parse_mode` MCP tool with the full prompt
124-
2. Follow returned `instructions` for the detected mode
125-
3. Use returned `rules` as context for the task
126-
4. If `warnings` exist, inform the user
122+
<CODINGBUDDY_CRITICAL_RULE>
127123

128-
Example: `PLAN design auth feature` → call parse_mode → work in PLAN mode
124+
**When user message starts with PLAN, ACT, or EVAL keyword (or localized: Korean 계획/실행/평가, Japanese 計画/実行/評価, Chinese 计划/执行/评估, Spanish PLANIFICAR/ACTUAR/EVALUAR):**
125+
126+
1. **IMMEDIATELY** call `parse_mode` MCP tool with the user's prompt
127+
2. Follow the returned `instructions` **EXACTLY**
128+
3. Apply the returned `rules` as context
129+
4. If `warnings` are present, inform the user
130+
131+
**This is MANDATORY, not optional.**
132+
133+
Failure to call `parse_mode` when these keywords are present will result in:
134+
- Missed critical checklists (Devil's Advocate Analysis, Impact Radius Analysis)
135+
- Incomplete evaluations
136+
- Quality issues not caught before deployment
137+
138+
**Red Flags** (STOP if you think these):
139+
| Thought | Reality |
140+
|---------|---------|
141+
| "I can handle EVAL myself" | NO. Call parse_mode FIRST. |
142+
| "The rules are similar anyway" | NO. Each mode has specific checklists. |
143+
| "I'll save a tool call" | NO. parse_mode MUST be called FIRST. |
144+
| "I already know what to do" | NO. Rules may have been updated. |
145+
146+
</CODINGBUDDY_CRITICAL_RULE>
147+
148+
Example: `PLAN design auth feature`**즉시** parse_mode 호출 → PLAN 모드로 작업
129149

130150
---
131151

.cursor/rules/imports.mdc

Lines changed: 27 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -123,15 +123,35 @@ For complete agent documentation, see [.ai-rules/agents/README.md](../../.ai-rul
123123

124124
---
125125

126-
## Keyword Invocation
126+
## 🔴 MANDATORY: Keyword Mode Detection
127127

128-
When user prompt starts with `PLAN`, `ACT`, or `EVAL`:
129-
1. Call `parse_mode` MCP tool with the full prompt
130-
2. Follow returned `instructions` for the detected mode
131-
3. Use returned `rules` as context for the task
132-
4. If `warnings` exist, inform the user
128+
<CODINGBUDDY_CRITICAL_RULE>
133129

134-
Example: `PLAN design auth feature` → call parse_mode → work in PLAN mode
130+
**When user message starts with PLAN, ACT, or EVAL keyword (or localized: Korean 계획/실행/평가, Japanese 計画/実行/評価, Chinese 计划/执行/评估, Spanish PLANIFICAR/ACTUAR/EVALUAR):**
131+
132+
1. **IMMEDIATELY** call `parse_mode` MCP tool with the user's prompt
133+
2. Follow the returned `instructions` **EXACTLY**
134+
3. Apply the returned `rules` as context
135+
4. If `warnings` are present, inform the user
136+
137+
**This is MANDATORY, not optional.**
138+
139+
Failure to call `parse_mode` when these keywords are present will result in:
140+
- Missed critical checklists (Devil's Advocate Analysis, Impact Radius Analysis)
141+
- Incomplete evaluations
142+
- Quality issues not caught before deployment
143+
144+
**Red Flags** (STOP if you think these):
145+
| Thought | Reality |
146+
|---------|---------|
147+
| "I can handle EVAL myself" | NO. Call parse_mode FIRST. |
148+
| "The rules are similar anyway" | NO. Each mode has specific checklists. |
149+
| "I'll save a tool call" | NO. parse_mode MUST be called FIRST. |
150+
| "I already know what to do" | NO. Rules may have been updated. |
151+
152+
</CODINGBUDDY_CRITICAL_RULE>
153+
154+
Example: `PLAN design auth feature` → **즉시** parse_mode 호출 → PLAN 모드로 작업
135155

136156
---
137157

.kiro/rules/guidelines.md

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,36 @@ See `packages/rules/.ai-rules/agents/`:
3636
- Accessibility (WCAG 2.1 AA compliance)
3737
- SEO, Architecture, Test Strategy, Design System, Documentation, Code Quality, DevOps
3838

39+
## 🔴 MANDATORY: Keyword Mode Detection
40+
41+
<CODINGBUDDY_CRITICAL_RULE>
42+
43+
**When user message starts with PLAN, ACT, or EVAL keyword (or localized: Korean 계획/실행/평가, Japanese 計画/実行/評価, Chinese 计划/执行/评估, Spanish PLANIFICAR/ACTUAR/EVALUAR):**
44+
45+
1. **IMMEDIATELY** follow the mode-specific rules from `packages/rules/.ai-rules/rules/core.md`
46+
2. Apply the mode's workflow **EXACTLY**
47+
3. Do NOT proceed with your own interpretation
48+
49+
**This is MANDATORY, not optional.**
50+
51+
Failure to follow mode rules when these keywords are present will result in:
52+
- Missed critical checklists (Devil's Advocate Analysis, Impact Radius Analysis)
53+
- Incomplete evaluations
54+
- Quality issues not caught before deployment
55+
56+
**Red Flags** (STOP if you think these):
57+
| Thought | Reality |
58+
|---------|---------|
59+
| "I can handle EVAL myself" | NO. Follow mode rules FIRST. |
60+
| "The rules are similar anyway" | NO. Each mode has specific checklists. |
61+
| "I already know what to do" | NO. Rules may have been updated. |
62+
63+
</CODINGBUDDY_CRITICAL_RULE>
64+
65+
Example: `EVAL`**즉시** EVAL 모드 규칙 적용 → Devil's Advocate Analysis 수행
66+
67+
---
68+
3969
## Kiro-Specific Features
4070

4171
### Communication

.q/rules/customizations.md

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,36 @@ Refer to `packages/rules/.ai-rules/agents/*.json`:
3333
- Performance optimization
3434
- Accessibility guidelines
3535

36+
## 🔴 MANDATORY: Keyword Mode Detection
37+
38+
<CODINGBUDDY_CRITICAL_RULE>
39+
40+
**When user message starts with PLAN, ACT, or EVAL keyword (or localized: Korean 계획/실행/평가, Japanese 計画/実行/評価, Chinese 计划/执行/评估, Spanish PLANIFICAR/ACTUAR/EVALUAR):**
41+
42+
1. **IMMEDIATELY** follow the mode-specific rules from `packages/rules/.ai-rules/rules/core.md`
43+
2. Apply the mode's workflow **EXACTLY**
44+
3. Do NOT proceed with your own interpretation
45+
46+
**This is MANDATORY, not optional.**
47+
48+
Failure to follow mode rules when these keywords are present will result in:
49+
- Missed critical checklists (Devil's Advocate Analysis, Impact Radius Analysis)
50+
- Incomplete evaluations
51+
- Quality issues not caught before deployment
52+
53+
**Red Flags** (STOP if you think these):
54+
| Thought | Reality |
55+
|---------|---------|
56+
| "I can handle EVAL myself" | NO. Follow mode rules FIRST. |
57+
| "The rules are similar anyway" | NO. Each mode has specific checklists. |
58+
| "I already know what to do" | NO. Rules may have been updated. |
59+
60+
</CODINGBUDDY_CRITICAL_RULE>
61+
62+
Example: `EVAL`**즉시** EVAL 모드 규칙 적용 → Devil's Advocate Analysis 수행
63+
64+
---
65+
3666
## Amazon Q Specific Features
3767

3868
### AWS Integration

0 commit comments

Comments
 (0)