tribunal-kit 4.4.2 → 4.4.3
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/.agent/scripts/marathon_harness.js +799 -0
- package/.agent/scripts/prompt_compiler.js +56 -0
- package/.agent/skills/agent-organizer/SKILL.md +42 -0
- package/.agent/skills/agentic-patterns/SKILL.md +42 -0
- package/.agent/skills/ai-prompt-injection-defense/SKILL.md +42 -0
- package/.agent/skills/api-patterns/SKILL.md +42 -0
- package/.agent/skills/api-security-auditor/SKILL.md +42 -0
- package/.agent/skills/app-builder/SKILL.md +42 -0
- package/.agent/skills/appflow-wireframe/SKILL.md +42 -0
- package/.agent/skills/architecture/SKILL.md +42 -0
- package/.agent/skills/authentication-best-practices/SKILL.md +42 -0
- package/.agent/skills/backend-security-expert/SKILL.md +122 -0
- package/.agent/skills/bash-linux/SKILL.md +42 -0
- package/.agent/skills/behavioral-modes/SKILL.md +42 -0
- package/.agent/skills/brainstorming/SKILL.md +42 -0
- package/.agent/skills/building-native-ui/SKILL.md +42 -0
- package/.agent/skills/clean-code/SKILL.md +42 -0
- package/.agent/skills/code-review-checklist/SKILL.md +42 -0
- package/.agent/skills/config-validator/SKILL.md +42 -0
- package/.agent/skills/csharp-developer/SKILL.md +42 -0
- package/.agent/skills/data-validation-schemas/SKILL.md +42 -0
- package/.agent/skills/database-design/SKILL.md +42 -0
- package/.agent/skills/deployment-procedures/SKILL.md +42 -0
- package/.agent/skills/devops-engineer/SKILL.md +42 -0
- package/.agent/skills/devops-incident-responder/SKILL.md +42 -0
- package/.agent/skills/documentation-templates/SKILL.md +42 -0
- package/.agent/skills/edge-computing/SKILL.md +42 -0
- package/.agent/skills/error-resilience/SKILL.md +42 -0
- package/.agent/skills/extract-design-system/SKILL.md +42 -0
- package/.agent/skills/framer-motion-expert/SKILL.md +42 -0
- package/.agent/skills/frontend-design/SKILL.md +42 -0
- package/.agent/skills/frontend-security-expert/SKILL.md +123 -0
- package/.agent/skills/game-design-expert/SKILL.md +42 -0
- package/.agent/skills/game-engineering-expert/SKILL.md +42 -0
- package/.agent/skills/geo-fundamentals/SKILL.md +42 -0
- package/.agent/skills/github-operations/SKILL.md +42 -0
- package/.agent/skills/gsap-core/SKILL.md +42 -0
- package/.agent/skills/gsap-frameworks/SKILL.md +42 -0
- package/.agent/skills/gsap-performance/SKILL.md +42 -0
- package/.agent/skills/gsap-plugins/SKILL.md +42 -0
- package/.agent/skills/gsap-react/SKILL.md +42 -0
- package/.agent/skills/gsap-scrolltrigger/SKILL.md +42 -0
- package/.agent/skills/gsap-timeline/SKILL.md +42 -0
- package/.agent/skills/gsap-utils/SKILL.md +42 -0
- package/.agent/skills/i18n-localization/SKILL.md +42 -0
- package/.agent/skills/intelligent-routing/SKILL.md +42 -0
- package/.agent/skills/knowledge-graph/SKILL.md +42 -0
- package/.agent/skills/lint-and-validate/SKILL.md +42 -0
- package/.agent/skills/llm-engineering/SKILL.md +42 -0
- package/.agent/skills/local-first/SKILL.md +42 -0
- package/.agent/skills/mcp-builder/SKILL.md +42 -0
- package/.agent/skills/mobile-design/SKILL.md +42 -0
- package/.agent/skills/monorepo-management/SKILL.md +42 -0
- package/.agent/skills/motion-engineering/SKILL.md +42 -0
- package/.agent/skills/nextjs-react-expert/SKILL.md +42 -0
- package/.agent/skills/nodejs-best-practices/SKILL.md +42 -0
- package/.agent/skills/observability/SKILL.md +42 -0
- package/.agent/skills/parallel-agents/SKILL.md +42 -0
- package/.agent/skills/performance-profiling/SKILL.md +42 -0
- package/.agent/skills/plan-writing/SKILL.md +42 -0
- package/.agent/skills/platform-engineer/SKILL.md +42 -0
- package/.agent/skills/playwright-best-practices/SKILL.md +42 -0
- package/.agent/skills/powershell-windows/SKILL.md +42 -0
- package/.agent/skills/project-idioms/SKILL.md +42 -0
- package/.agent/skills/python-patterns/SKILL.md +42 -0
- package/.agent/skills/python-pro/SKILL.md +42 -0
- package/.agent/skills/react-specialist/SKILL.md +42 -0
- package/.agent/skills/readme-builder/SKILL.md +42 -0
- package/.agent/skills/realtime-patterns/SKILL.md +42 -0
- package/.agent/skills/red-team-tactics/SKILL.md +42 -0
- package/.agent/skills/rust-pro/SKILL.md +42 -0
- package/.agent/skills/seo-fundamentals/SKILL.md +42 -0
- package/.agent/skills/server-management/SKILL.md +42 -0
- package/.agent/skills/shadcn-ui-expert/SKILL.md +42 -0
- package/.agent/skills/skill-creator/SKILL.md +42 -0
- package/.agent/skills/sql-pro/SKILL.md +42 -0
- package/.agent/skills/supabase-postgres-best-practices/SKILL.md +42 -0
- package/.agent/skills/swiftui-expert/SKILL.md +42 -0
- package/.agent/skills/systematic-debugging/SKILL.md +42 -0
- package/.agent/skills/tailwind-patterns/SKILL.md +42 -0
- package/.agent/skills/tdd-workflow/SKILL.md +42 -0
- package/.agent/skills/test-result-analyzer/SKILL.md +42 -0
- package/.agent/skills/testing-patterns/SKILL.md +42 -0
- package/.agent/skills/trend-researcher/SKILL.md +42 -0
- package/.agent/skills/typescript-advanced/SKILL.md +42 -0
- package/.agent/skills/ui-ux-pro-max/SKILL.md +42 -0
- package/.agent/skills/ui-ux-researcher/SKILL.md +42 -0
- package/.agent/skills/vue-expert/SKILL.md +42 -0
- package/.agent/skills/vulnerability-scanner/SKILL.md +42 -0
- package/.agent/skills/web-accessibility-auditor/SKILL.md +42 -0
- package/.agent/skills/web-design-guidelines/SKILL.md +42 -0
- package/.agent/skills/webapp-testing/SKILL.md +42 -0
- package/.agent/skills/whimsy-injector/SKILL.md +42 -0
- package/.agent/skills/workflow-optimizer/SKILL.md +42 -0
- package/.agent/workflows/marathon.md +247 -0
- package/.agent/workflows/super-prompt.md +27 -0
- package/bin/tribunal-kit.js +47 -1
- package/package.json +3 -2
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
// VERIFY: Using native Node.js only. Zero dependencies to ensure instant execution.
|
|
3
|
+
|
|
4
|
+
const rawInput = process.argv.slice(2).join(' ');
|
|
5
|
+
|
|
6
|
+
if (!rawInput) {
|
|
7
|
+
console.error("Usage: node prompt_compiler.js \"Your conversational prompt here\"");
|
|
8
|
+
process.exit(1);
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
// 1. Strip conversational fluff (lowers token count)
|
|
12
|
+
let cleanInput = rawInput
|
|
13
|
+
.replace(/hey,? /gi, '')
|
|
14
|
+
.replace(/can you /gi, '')
|
|
15
|
+
.replace(/could you /gi, '')
|
|
16
|
+
.replace(/please /gi, '')
|
|
17
|
+
.replace(/i want to /gi, '')
|
|
18
|
+
.replace(/i need you to /gi, '')
|
|
19
|
+
.replace(/for me/gi, '')
|
|
20
|
+
.replace(/would it be possible to /gi, '')
|
|
21
|
+
.trim();
|
|
22
|
+
|
|
23
|
+
// 2. Extract Action (Intent mapping)
|
|
24
|
+
const actionMatch = cleanInput.match(/^(build|create|fix|debug|refactor|update|write|design|audit)\b/i);
|
|
25
|
+
const action = actionMatch ? actionMatch[1].toLowerCase() : 'execute';
|
|
26
|
+
|
|
27
|
+
// Remove the action from the target string
|
|
28
|
+
if (actionMatch) {
|
|
29
|
+
cleanInput = cleanInput.substring(actionMatch[0].length).trim();
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
// Strip leading articles
|
|
33
|
+
cleanInput = cleanInput.replace(/^(a|an|some)\s+/i, '');
|
|
34
|
+
|
|
35
|
+
// 3. Extract Technology Stack
|
|
36
|
+
const techKeywords = [
|
|
37
|
+
'react', 'tailwind', 'next.js', 'sql', 'postgres', 'express',
|
|
38
|
+
'python', 'node', 'vue', 'svelte', 'typescript', 'js', 'css',
|
|
39
|
+
'html', 'prisma', 'drizzle'
|
|
40
|
+
];
|
|
41
|
+
|
|
42
|
+
const stack = [];
|
|
43
|
+
techKeywords.forEach(tech => {
|
|
44
|
+
// Use word boundaries to prevent partial matches
|
|
45
|
+
const regex = new RegExp(`\\b${tech.replace('.', '\\.')}\\b`, 'i');
|
|
46
|
+
if (regex.test(cleanInput)) {
|
|
47
|
+
stack.push(tech.toLowerCase());
|
|
48
|
+
}
|
|
49
|
+
});
|
|
50
|
+
|
|
51
|
+
// 4. Output highly compressed YAML
|
|
52
|
+
console.log('---');
|
|
53
|
+
console.log(`action: ${action}`);
|
|
54
|
+
console.log(`target: ${cleanInput}`);
|
|
55
|
+
console.log(`stack: [${stack.join(', ')}]`);
|
|
56
|
+
console.log('---');
|
|
@@ -148,3 +148,45 @@ Review these questions before confirming output:
|
|
|
148
148
|
|
|
149
149
|
## VBC Protocol (Verification-Before-Completion)
|
|
150
150
|
You MUST verify existing code signatures and variables before attempting to modify or call them. No hallucination is permitted.
|
|
151
|
+
|
|
152
|
+
|
|
153
|
+
---
|
|
154
|
+
|
|
155
|
+
## 🤖 LLM-Specific Traps
|
|
156
|
+
|
|
157
|
+
AI coding assistants often fall into specific bad habits when dealing with this domain. These are strictly forbidden:
|
|
158
|
+
|
|
159
|
+
1. **Over-engineering:** Proposing complex abstractions or distributed systems when a simpler approach suffices.
|
|
160
|
+
2. **Hallucinated Libraries/Methods:** Using non-existent methods or packages. Always `// VERIFY` or check `package.json` / `requirements.txt`.
|
|
161
|
+
3. **Skipping Edge Cases:** Writing the "happy path" and ignoring error handling, timeouts, or data validation.
|
|
162
|
+
4. **Context Amnesia:** Forgetting the user's constraints and offering generic advice instead of tailored solutions.
|
|
163
|
+
5. **Silent Degradation:** Catching and suppressing errors without logging or re-raising.
|
|
164
|
+
|
|
165
|
+
---
|
|
166
|
+
|
|
167
|
+
## 🏛️ Tribunal Integration (Anti-Hallucination)
|
|
168
|
+
|
|
169
|
+
**Slash command: `/review` or `/tribunal-full`**
|
|
170
|
+
**Active reviewers: `logic-reviewer` · `security-auditor`**
|
|
171
|
+
|
|
172
|
+
### ❌ Forbidden AI Tropes
|
|
173
|
+
|
|
174
|
+
1. **Blind Assumptions:** Never make an assumption without documenting it clearly with `// VERIFY: [reason]`.
|
|
175
|
+
2. **Silent Degradation:** Catching and suppressing errors without logging or handling.
|
|
176
|
+
3. **Context Amnesia:** Forgetting the user's constraints and offering generic advice instead of tailored solutions.
|
|
177
|
+
|
|
178
|
+
### ✅ Pre-Flight Self-Audit
|
|
179
|
+
|
|
180
|
+
Review these questions before confirming output:
|
|
181
|
+
```
|
|
182
|
+
✅ Did I rely ONLY on real, verified tools and methods?
|
|
183
|
+
✅ Is this solution appropriately scoped to the user's constraints?
|
|
184
|
+
✅ Did I handle potential failure modes and edge cases?
|
|
185
|
+
✅ Have I avoided generic boilerplate that doesn't add value?
|
|
186
|
+
```
|
|
187
|
+
|
|
188
|
+
### 🛑 Verification-Before-Completion (VBC) Protocol
|
|
189
|
+
|
|
190
|
+
**CRITICAL:** You must follow a strict "evidence-based closeout" state machine.
|
|
191
|
+
- ❌ **Forbidden:** Declaring a task complete because the output "looks correct."
|
|
192
|
+
- ✅ **Required:** You are explicitly forbidden from finalizing any task without providing **concrete evidence** (terminal output, passing tests, compile success, or equivalent proof) that your output works as intended.
|
|
@@ -313,3 +313,45 @@ Review these questions before confirming output:
|
|
|
313
313
|
|
|
314
314
|
## VBC Protocol (Verification-Before-Completion)
|
|
315
315
|
You MUST verify existing code signatures and variables before attempting to modify or call them. No hallucination is permitted.
|
|
316
|
+
|
|
317
|
+
|
|
318
|
+
---
|
|
319
|
+
|
|
320
|
+
## 🤖 LLM-Specific Traps
|
|
321
|
+
|
|
322
|
+
AI coding assistants often fall into specific bad habits when dealing with this domain. These are strictly forbidden:
|
|
323
|
+
|
|
324
|
+
1. **Over-engineering:** Proposing complex abstractions or distributed systems when a simpler approach suffices.
|
|
325
|
+
2. **Hallucinated Libraries/Methods:** Using non-existent methods or packages. Always `// VERIFY` or check `package.json` / `requirements.txt`.
|
|
326
|
+
3. **Skipping Edge Cases:** Writing the "happy path" and ignoring error handling, timeouts, or data validation.
|
|
327
|
+
4. **Context Amnesia:** Forgetting the user's constraints and offering generic advice instead of tailored solutions.
|
|
328
|
+
5. **Silent Degradation:** Catching and suppressing errors without logging or re-raising.
|
|
329
|
+
|
|
330
|
+
---
|
|
331
|
+
|
|
332
|
+
## 🏛️ Tribunal Integration (Anti-Hallucination)
|
|
333
|
+
|
|
334
|
+
**Slash command: `/review` or `/tribunal-full`**
|
|
335
|
+
**Active reviewers: `logic-reviewer` · `security-auditor`**
|
|
336
|
+
|
|
337
|
+
### ❌ Forbidden AI Tropes
|
|
338
|
+
|
|
339
|
+
1. **Blind Assumptions:** Never make an assumption without documenting it clearly with `// VERIFY: [reason]`.
|
|
340
|
+
2. **Silent Degradation:** Catching and suppressing errors without logging or handling.
|
|
341
|
+
3. **Context Amnesia:** Forgetting the user's constraints and offering generic advice instead of tailored solutions.
|
|
342
|
+
|
|
343
|
+
### ✅ Pre-Flight Self-Audit
|
|
344
|
+
|
|
345
|
+
Review these questions before confirming output:
|
|
346
|
+
```
|
|
347
|
+
✅ Did I rely ONLY on real, verified tools and methods?
|
|
348
|
+
✅ Is this solution appropriately scoped to the user's constraints?
|
|
349
|
+
✅ Did I handle potential failure modes and edge cases?
|
|
350
|
+
✅ Have I avoided generic boilerplate that doesn't add value?
|
|
351
|
+
```
|
|
352
|
+
|
|
353
|
+
### 🛑 Verification-Before-Completion (VBC) Protocol
|
|
354
|
+
|
|
355
|
+
**CRITICAL:** You must follow a strict "evidence-based closeout" state machine.
|
|
356
|
+
- ❌ **Forbidden:** Declaring a task complete because the output "looks correct."
|
|
357
|
+
- ✅ **Required:** You are explicitly forbidden from finalizing any task without providing **concrete evidence** (terminal output, passing tests, compile success, or equivalent proof) that your output works as intended.
|
|
@@ -182,3 +182,45 @@ Review these questions before confirming output:
|
|
|
182
182
|
|
|
183
183
|
## VBC Protocol (Verification-Before-Completion)
|
|
184
184
|
You MUST verify existing code signatures and variables before attempting to modify or call them. No hallucination is permitted.
|
|
185
|
+
|
|
186
|
+
|
|
187
|
+
---
|
|
188
|
+
|
|
189
|
+
## 🤖 LLM-Specific Traps
|
|
190
|
+
|
|
191
|
+
AI coding assistants often fall into specific bad habits when dealing with this domain. These are strictly forbidden:
|
|
192
|
+
|
|
193
|
+
1. **Over-engineering:** Proposing complex abstractions or distributed systems when a simpler approach suffices.
|
|
194
|
+
2. **Hallucinated Libraries/Methods:** Using non-existent methods or packages. Always `// VERIFY` or check `package.json` / `requirements.txt`.
|
|
195
|
+
3. **Skipping Edge Cases:** Writing the "happy path" and ignoring error handling, timeouts, or data validation.
|
|
196
|
+
4. **Context Amnesia:** Forgetting the user's constraints and offering generic advice instead of tailored solutions.
|
|
197
|
+
5. **Silent Degradation:** Catching and suppressing errors without logging or re-raising.
|
|
198
|
+
|
|
199
|
+
---
|
|
200
|
+
|
|
201
|
+
## 🏛️ Tribunal Integration (Anti-Hallucination)
|
|
202
|
+
|
|
203
|
+
**Slash command: `/review` or `/tribunal-full`**
|
|
204
|
+
**Active reviewers: `logic-reviewer` · `security-auditor`**
|
|
205
|
+
|
|
206
|
+
### ❌ Forbidden AI Tropes
|
|
207
|
+
|
|
208
|
+
1. **Blind Assumptions:** Never make an assumption without documenting it clearly with `// VERIFY: [reason]`.
|
|
209
|
+
2. **Silent Degradation:** Catching and suppressing errors without logging or handling.
|
|
210
|
+
3. **Context Amnesia:** Forgetting the user's constraints and offering generic advice instead of tailored solutions.
|
|
211
|
+
|
|
212
|
+
### ✅ Pre-Flight Self-Audit
|
|
213
|
+
|
|
214
|
+
Review these questions before confirming output:
|
|
215
|
+
```
|
|
216
|
+
✅ Did I rely ONLY on real, verified tools and methods?
|
|
217
|
+
✅ Is this solution appropriately scoped to the user's constraints?
|
|
218
|
+
✅ Did I handle potential failure modes and edge cases?
|
|
219
|
+
✅ Have I avoided generic boilerplate that doesn't add value?
|
|
220
|
+
```
|
|
221
|
+
|
|
222
|
+
### 🛑 Verification-Before-Completion (VBC) Protocol
|
|
223
|
+
|
|
224
|
+
**CRITICAL:** You must follow a strict "evidence-based closeout" state machine.
|
|
225
|
+
- ❌ **Forbidden:** Declaring a task complete because the output "looks correct."
|
|
226
|
+
- ✅ **Required:** You are explicitly forbidden from finalizing any task without providing **concrete evidence** (terminal output, passing tests, compile success, or equivalent proof) that your output works as intended.
|
|
@@ -245,3 +245,45 @@ Review these questions before confirming output:
|
|
|
245
245
|
|
|
246
246
|
## VBC Protocol (Verification-Before-Completion)
|
|
247
247
|
You MUST verify existing code signatures and variables before attempting to modify or call them. No hallucination is permitted.
|
|
248
|
+
|
|
249
|
+
|
|
250
|
+
---
|
|
251
|
+
|
|
252
|
+
## 🤖 LLM-Specific Traps
|
|
253
|
+
|
|
254
|
+
AI coding assistants often fall into specific bad habits when dealing with this domain. These are strictly forbidden:
|
|
255
|
+
|
|
256
|
+
1. **Over-engineering:** Proposing complex abstractions or distributed systems when a simpler approach suffices.
|
|
257
|
+
2. **Hallucinated Libraries/Methods:** Using non-existent methods or packages. Always `// VERIFY` or check `package.json` / `requirements.txt`.
|
|
258
|
+
3. **Skipping Edge Cases:** Writing the "happy path" and ignoring error handling, timeouts, or data validation.
|
|
259
|
+
4. **Context Amnesia:** Forgetting the user's constraints and offering generic advice instead of tailored solutions.
|
|
260
|
+
5. **Silent Degradation:** Catching and suppressing errors without logging or re-raising.
|
|
261
|
+
|
|
262
|
+
---
|
|
263
|
+
|
|
264
|
+
## 🏛️ Tribunal Integration (Anti-Hallucination)
|
|
265
|
+
|
|
266
|
+
**Slash command: `/review` or `/tribunal-full`**
|
|
267
|
+
**Active reviewers: `logic-reviewer` · `security-auditor`**
|
|
268
|
+
|
|
269
|
+
### ❌ Forbidden AI Tropes
|
|
270
|
+
|
|
271
|
+
1. **Blind Assumptions:** Never make an assumption without documenting it clearly with `// VERIFY: [reason]`.
|
|
272
|
+
2. **Silent Degradation:** Catching and suppressing errors without logging or handling.
|
|
273
|
+
3. **Context Amnesia:** Forgetting the user's constraints and offering generic advice instead of tailored solutions.
|
|
274
|
+
|
|
275
|
+
### ✅ Pre-Flight Self-Audit
|
|
276
|
+
|
|
277
|
+
Review these questions before confirming output:
|
|
278
|
+
```
|
|
279
|
+
✅ Did I rely ONLY on real, verified tools and methods?
|
|
280
|
+
✅ Is this solution appropriately scoped to the user's constraints?
|
|
281
|
+
✅ Did I handle potential failure modes and edge cases?
|
|
282
|
+
✅ Have I avoided generic boilerplate that doesn't add value?
|
|
283
|
+
```
|
|
284
|
+
|
|
285
|
+
### 🛑 Verification-Before-Completion (VBC) Protocol
|
|
286
|
+
|
|
287
|
+
**CRITICAL:** You must follow a strict "evidence-based closeout" state machine.
|
|
288
|
+
- ❌ **Forbidden:** Declaring a task complete because the output "looks correct."
|
|
289
|
+
- ✅ **Required:** You are explicitly forbidden from finalizing any task without providing **concrete evidence** (terminal output, passing tests, compile success, or equivalent proof) that your output works as intended.
|
|
@@ -191,3 +191,45 @@ Review these questions before confirming output:
|
|
|
191
191
|
|
|
192
192
|
## VBC Protocol (Verification-Before-Completion)
|
|
193
193
|
You MUST verify existing code signatures and variables before attempting to modify or call them. No hallucination is permitted.
|
|
194
|
+
|
|
195
|
+
|
|
196
|
+
---
|
|
197
|
+
|
|
198
|
+
## 🤖 LLM-Specific Traps
|
|
199
|
+
|
|
200
|
+
AI coding assistants often fall into specific bad habits when dealing with this domain. These are strictly forbidden:
|
|
201
|
+
|
|
202
|
+
1. **Over-engineering:** Proposing complex abstractions or distributed systems when a simpler approach suffices.
|
|
203
|
+
2. **Hallucinated Libraries/Methods:** Using non-existent methods or packages. Always `// VERIFY` or check `package.json` / `requirements.txt`.
|
|
204
|
+
3. **Skipping Edge Cases:** Writing the "happy path" and ignoring error handling, timeouts, or data validation.
|
|
205
|
+
4. **Context Amnesia:** Forgetting the user's constraints and offering generic advice instead of tailored solutions.
|
|
206
|
+
5. **Silent Degradation:** Catching and suppressing errors without logging or re-raising.
|
|
207
|
+
|
|
208
|
+
---
|
|
209
|
+
|
|
210
|
+
## 🏛️ Tribunal Integration (Anti-Hallucination)
|
|
211
|
+
|
|
212
|
+
**Slash command: `/review` or `/tribunal-full`**
|
|
213
|
+
**Active reviewers: `logic-reviewer` · `security-auditor`**
|
|
214
|
+
|
|
215
|
+
### ❌ Forbidden AI Tropes
|
|
216
|
+
|
|
217
|
+
1. **Blind Assumptions:** Never make an assumption without documenting it clearly with `// VERIFY: [reason]`.
|
|
218
|
+
2. **Silent Degradation:** Catching and suppressing errors without logging or handling.
|
|
219
|
+
3. **Context Amnesia:** Forgetting the user's constraints and offering generic advice instead of tailored solutions.
|
|
220
|
+
|
|
221
|
+
### ✅ Pre-Flight Self-Audit
|
|
222
|
+
|
|
223
|
+
Review these questions before confirming output:
|
|
224
|
+
```
|
|
225
|
+
✅ Did I rely ONLY on real, verified tools and methods?
|
|
226
|
+
✅ Is this solution appropriately scoped to the user's constraints?
|
|
227
|
+
✅ Did I handle potential failure modes and edge cases?
|
|
228
|
+
✅ Have I avoided generic boilerplate that doesn't add value?
|
|
229
|
+
```
|
|
230
|
+
|
|
231
|
+
### 🛑 Verification-Before-Completion (VBC) Protocol
|
|
232
|
+
|
|
233
|
+
**CRITICAL:** You must follow a strict "evidence-based closeout" state machine.
|
|
234
|
+
- ❌ **Forbidden:** Declaring a task complete because the output "looks correct."
|
|
235
|
+
- ✅ **Required:** You are explicitly forbidden from finalizing any task without providing **concrete evidence** (terminal output, passing tests, compile success, or equivalent proof) that your output works as intended.
|
|
@@ -570,3 +570,45 @@ Review these questions before confirming output:
|
|
|
570
570
|
|
|
571
571
|
## VBC Protocol (Verification-Before-Completion)
|
|
572
572
|
You MUST verify existing code signatures and variables before attempting to modify or call them. No hallucination is permitted.
|
|
573
|
+
|
|
574
|
+
|
|
575
|
+
---
|
|
576
|
+
|
|
577
|
+
## 🤖 LLM-Specific Traps
|
|
578
|
+
|
|
579
|
+
AI coding assistants often fall into specific bad habits when dealing with this domain. These are strictly forbidden:
|
|
580
|
+
|
|
581
|
+
1. **Over-engineering:** Proposing complex abstractions or distributed systems when a simpler approach suffices.
|
|
582
|
+
2. **Hallucinated Libraries/Methods:** Using non-existent methods or packages. Always `// VERIFY` or check `package.json` / `requirements.txt`.
|
|
583
|
+
3. **Skipping Edge Cases:** Writing the "happy path" and ignoring error handling, timeouts, or data validation.
|
|
584
|
+
4. **Context Amnesia:** Forgetting the user's constraints and offering generic advice instead of tailored solutions.
|
|
585
|
+
5. **Silent Degradation:** Catching and suppressing errors without logging or re-raising.
|
|
586
|
+
|
|
587
|
+
---
|
|
588
|
+
|
|
589
|
+
## 🏛️ Tribunal Integration (Anti-Hallucination)
|
|
590
|
+
|
|
591
|
+
**Slash command: `/review` or `/tribunal-full`**
|
|
592
|
+
**Active reviewers: `logic-reviewer` · `security-auditor`**
|
|
593
|
+
|
|
594
|
+
### ❌ Forbidden AI Tropes
|
|
595
|
+
|
|
596
|
+
1. **Blind Assumptions:** Never make an assumption without documenting it clearly with `// VERIFY: [reason]`.
|
|
597
|
+
2. **Silent Degradation:** Catching and suppressing errors without logging or handling.
|
|
598
|
+
3. **Context Amnesia:** Forgetting the user's constraints and offering generic advice instead of tailored solutions.
|
|
599
|
+
|
|
600
|
+
### ✅ Pre-Flight Self-Audit
|
|
601
|
+
|
|
602
|
+
Review these questions before confirming output:
|
|
603
|
+
```
|
|
604
|
+
✅ Did I rely ONLY on real, verified tools and methods?
|
|
605
|
+
✅ Is this solution appropriately scoped to the user's constraints?
|
|
606
|
+
✅ Did I handle potential failure modes and edge cases?
|
|
607
|
+
✅ Have I avoided generic boilerplate that doesn't add value?
|
|
608
|
+
```
|
|
609
|
+
|
|
610
|
+
### 🛑 Verification-Before-Completion (VBC) Protocol
|
|
611
|
+
|
|
612
|
+
**CRITICAL:** You must follow a strict "evidence-based closeout" state machine.
|
|
613
|
+
- ❌ **Forbidden:** Declaring a task complete because the output "looks correct."
|
|
614
|
+
- ✅ **Required:** You are explicitly forbidden from finalizing any task without providing **concrete evidence** (terminal output, passing tests, compile success, or equivalent proof) that your output works as intended.
|
|
@@ -143,3 +143,45 @@ Review these questions before confirming output:
|
|
|
143
143
|
|
|
144
144
|
## VBC Protocol (Verification-Before-Completion)
|
|
145
145
|
You MUST verify existing code signatures and variables before attempting to modify or call them. No hallucination is permitted.
|
|
146
|
+
|
|
147
|
+
|
|
148
|
+
---
|
|
149
|
+
|
|
150
|
+
## 🤖 LLM-Specific Traps
|
|
151
|
+
|
|
152
|
+
AI coding assistants often fall into specific bad habits when dealing with this domain. These are strictly forbidden:
|
|
153
|
+
|
|
154
|
+
1. **Over-engineering:** Proposing complex abstractions or distributed systems when a simpler approach suffices.
|
|
155
|
+
2. **Hallucinated Libraries/Methods:** Using non-existent methods or packages. Always `// VERIFY` or check `package.json` / `requirements.txt`.
|
|
156
|
+
3. **Skipping Edge Cases:** Writing the "happy path" and ignoring error handling, timeouts, or data validation.
|
|
157
|
+
4. **Context Amnesia:** Forgetting the user's constraints and offering generic advice instead of tailored solutions.
|
|
158
|
+
5. **Silent Degradation:** Catching and suppressing errors without logging or re-raising.
|
|
159
|
+
|
|
160
|
+
---
|
|
161
|
+
|
|
162
|
+
## 🏛️ Tribunal Integration (Anti-Hallucination)
|
|
163
|
+
|
|
164
|
+
**Slash command: `/review` or `/tribunal-full`**
|
|
165
|
+
**Active reviewers: `logic-reviewer` · `security-auditor`**
|
|
166
|
+
|
|
167
|
+
### ❌ Forbidden AI Tropes
|
|
168
|
+
|
|
169
|
+
1. **Blind Assumptions:** Never make an assumption without documenting it clearly with `// VERIFY: [reason]`.
|
|
170
|
+
2. **Silent Degradation:** Catching and suppressing errors without logging or handling.
|
|
171
|
+
3. **Context Amnesia:** Forgetting the user's constraints and offering generic advice instead of tailored solutions.
|
|
172
|
+
|
|
173
|
+
### ✅ Pre-Flight Self-Audit
|
|
174
|
+
|
|
175
|
+
Review these questions before confirming output:
|
|
176
|
+
```
|
|
177
|
+
✅ Did I rely ONLY on real, verified tools and methods?
|
|
178
|
+
✅ Is this solution appropriately scoped to the user's constraints?
|
|
179
|
+
✅ Did I handle potential failure modes and edge cases?
|
|
180
|
+
✅ Have I avoided generic boilerplate that doesn't add value?
|
|
181
|
+
```
|
|
182
|
+
|
|
183
|
+
### 🛑 Verification-Before-Completion (VBC) Protocol
|
|
184
|
+
|
|
185
|
+
**CRITICAL:** You must follow a strict "evidence-based closeout" state machine.
|
|
186
|
+
- ❌ **Forbidden:** Declaring a task complete because the output "looks correct."
|
|
187
|
+
- ✅ **Required:** You are explicitly forbidden from finalizing any task without providing **concrete evidence** (terminal output, passing tests, compile success, or equivalent proof) that your output works as intended.
|
|
@@ -217,3 +217,45 @@ Review these questions before confirming output:
|
|
|
217
217
|
|
|
218
218
|
## VBC Protocol (Verification-Before-Completion)
|
|
219
219
|
You MUST verify existing code signatures and variables before attempting to modify or call them. No hallucination is permitted.
|
|
220
|
+
|
|
221
|
+
|
|
222
|
+
---
|
|
223
|
+
|
|
224
|
+
## 🤖 LLM-Specific Traps
|
|
225
|
+
|
|
226
|
+
AI coding assistants often fall into specific bad habits when dealing with this domain. These are strictly forbidden:
|
|
227
|
+
|
|
228
|
+
1. **Over-engineering:** Proposing complex abstractions or distributed systems when a simpler approach suffices.
|
|
229
|
+
2. **Hallucinated Libraries/Methods:** Using non-existent methods or packages. Always `// VERIFY` or check `package.json` / `requirements.txt`.
|
|
230
|
+
3. **Skipping Edge Cases:** Writing the "happy path" and ignoring error handling, timeouts, or data validation.
|
|
231
|
+
4. **Context Amnesia:** Forgetting the user's constraints and offering generic advice instead of tailored solutions.
|
|
232
|
+
5. **Silent Degradation:** Catching and suppressing errors without logging or re-raising.
|
|
233
|
+
|
|
234
|
+
---
|
|
235
|
+
|
|
236
|
+
## 🏛️ Tribunal Integration (Anti-Hallucination)
|
|
237
|
+
|
|
238
|
+
**Slash command: `/review` or `/tribunal-full`**
|
|
239
|
+
**Active reviewers: `logic-reviewer` · `security-auditor`**
|
|
240
|
+
|
|
241
|
+
### ❌ Forbidden AI Tropes
|
|
242
|
+
|
|
243
|
+
1. **Blind Assumptions:** Never make an assumption without documenting it clearly with `// VERIFY: [reason]`.
|
|
244
|
+
2. **Silent Degradation:** Catching and suppressing errors without logging or handling.
|
|
245
|
+
3. **Context Amnesia:** Forgetting the user's constraints and offering generic advice instead of tailored solutions.
|
|
246
|
+
|
|
247
|
+
### ✅ Pre-Flight Self-Audit
|
|
248
|
+
|
|
249
|
+
Review these questions before confirming output:
|
|
250
|
+
```
|
|
251
|
+
✅ Did I rely ONLY on real, verified tools and methods?
|
|
252
|
+
✅ Is this solution appropriately scoped to the user's constraints?
|
|
253
|
+
✅ Did I handle potential failure modes and edge cases?
|
|
254
|
+
✅ Have I avoided generic boilerplate that doesn't add value?
|
|
255
|
+
```
|
|
256
|
+
|
|
257
|
+
### 🛑 Verification-Before-Completion (VBC) Protocol
|
|
258
|
+
|
|
259
|
+
**CRITICAL:** You must follow a strict "evidence-based closeout" state machine.
|
|
260
|
+
- ❌ **Forbidden:** Declaring a task complete because the output "looks correct."
|
|
261
|
+
- ✅ **Required:** You are explicitly forbidden from finalizing any task without providing **concrete evidence** (terminal output, passing tests, compile success, or equivalent proof) that your output works as intended.
|
|
@@ -187,3 +187,45 @@ Review these questions before confirming output:
|
|
|
187
187
|
|
|
188
188
|
## VBC Protocol (Verification-Before-Completion)
|
|
189
189
|
You MUST verify existing code signatures and variables before attempting to modify or call them. No hallucination is permitted.
|
|
190
|
+
|
|
191
|
+
|
|
192
|
+
---
|
|
193
|
+
|
|
194
|
+
## 🤖 LLM-Specific Traps
|
|
195
|
+
|
|
196
|
+
AI coding assistants often fall into specific bad habits when dealing with this domain. These are strictly forbidden:
|
|
197
|
+
|
|
198
|
+
1. **Over-engineering:** Proposing complex abstractions or distributed systems when a simpler approach suffices.
|
|
199
|
+
2. **Hallucinated Libraries/Methods:** Using non-existent methods or packages. Always `// VERIFY` or check `package.json` / `requirements.txt`.
|
|
200
|
+
3. **Skipping Edge Cases:** Writing the "happy path" and ignoring error handling, timeouts, or data validation.
|
|
201
|
+
4. **Context Amnesia:** Forgetting the user's constraints and offering generic advice instead of tailored solutions.
|
|
202
|
+
5. **Silent Degradation:** Catching and suppressing errors without logging or re-raising.
|
|
203
|
+
|
|
204
|
+
---
|
|
205
|
+
|
|
206
|
+
## 🏛️ Tribunal Integration (Anti-Hallucination)
|
|
207
|
+
|
|
208
|
+
**Slash command: `/review` or `/tribunal-full`**
|
|
209
|
+
**Active reviewers: `logic-reviewer` · `security-auditor`**
|
|
210
|
+
|
|
211
|
+
### ❌ Forbidden AI Tropes
|
|
212
|
+
|
|
213
|
+
1. **Blind Assumptions:** Never make an assumption without documenting it clearly with `// VERIFY: [reason]`.
|
|
214
|
+
2. **Silent Degradation:** Catching and suppressing errors without logging or handling.
|
|
215
|
+
3. **Context Amnesia:** Forgetting the user's constraints and offering generic advice instead of tailored solutions.
|
|
216
|
+
|
|
217
|
+
### ✅ Pre-Flight Self-Audit
|
|
218
|
+
|
|
219
|
+
Review these questions before confirming output:
|
|
220
|
+
```
|
|
221
|
+
✅ Did I rely ONLY on real, verified tools and methods?
|
|
222
|
+
✅ Is this solution appropriately scoped to the user's constraints?
|
|
223
|
+
✅ Did I handle potential failure modes and edge cases?
|
|
224
|
+
✅ Have I avoided generic boilerplate that doesn't add value?
|
|
225
|
+
```
|
|
226
|
+
|
|
227
|
+
### 🛑 Verification-Before-Completion (VBC) Protocol
|
|
228
|
+
|
|
229
|
+
**CRITICAL:** You must follow a strict "evidence-based closeout" state machine.
|
|
230
|
+
- ❌ **Forbidden:** Declaring a task complete because the output "looks correct."
|
|
231
|
+
- ✅ **Required:** You are explicitly forbidden from finalizing any task without providing **concrete evidence** (terminal output, passing tests, compile success, or equivalent proof) that your output works as intended.
|
|
@@ -0,0 +1,122 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: backend-security-expert
|
|
3
|
+
description: Backend security auditing for modern server-side architectures. Focuses on Next.js Server Actions, Node.js/Edge APIs, JWT & Session architectures, ORM injection (Prisma/Drizzle), and RBAC implementation.
|
|
4
|
+
allowed-tools: Read, Write, Edit, Glob, Grep
|
|
5
|
+
version: 1.0.0
|
|
6
|
+
last-updated: 2026-05-22
|
|
7
|
+
applies-to-model: gemini-3-1-pro, claude-3-7-sonnet
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
# Backend Security Expert — Modern Server Architectures
|
|
11
|
+
|
|
12
|
+
## Hallucination Traps (Read First)
|
|
13
|
+
- ❌ Recommending session tokens without algorithm enforcement → ✅ Always verify JWT algorithms (`alg: "HS256"`) to prevent "None" attacks.
|
|
14
|
+
- ❌ Treating ORMs as automatically secure → ✅ Prisma and Drizzle can still be vulnerable if raw SQL/queries are dynamically interpolated.
|
|
15
|
+
- ❌ Assuming Next.js Server Actions are private APIs → ✅ Server Actions are public endpoints and must be authenticated and rate-limited.
|
|
16
|
+
- ❌ Leaving input validation to the controller logic → ✅ Always enforce strict schema boundaries (Zod/Pydantic) before business logic.
|
|
17
|
+
|
|
18
|
+
---
|
|
19
|
+
|
|
20
|
+
## 1. Next.js Server Actions & Edge APIs
|
|
21
|
+
Server Actions create implicit API endpoints. They must be treated like raw REST routes.
|
|
22
|
+
- **Authentication**: Validate the session ID/token at the very top of *every* Server Action.
|
|
23
|
+
- **Input Validation**: Parse all inputs using Zod. Do not trust TypeScript types, as they do not exist at runtime.
|
|
24
|
+
- **Rate Limiting**: Apply `@upstash/ratelimit` or similar to prevent brute force and abuse on public-facing actions.
|
|
25
|
+
|
|
26
|
+
## 2. Authentication & Authorization (RBAC)
|
|
27
|
+
- **Role-Based Access**: Check if the authenticated user has permission to perform the specific action, not just if they are logged in.
|
|
28
|
+
- **IDOR Prevention**: Always verify that the resource being modified belongs to the user requesting the modification (e.g., `WHERE userId = session.userId`).
|
|
29
|
+
- **Secrets Management**: Never hardcode API keys. Ensure they are loaded from `.env` and fail loudly if missing.
|
|
30
|
+
|
|
31
|
+
## 3. Database & ORM Security
|
|
32
|
+
- **NoSQL/ORM Injection**: Avoid passing raw JSON or objects directly into query constraints (e.g., MongoDB `$where` or Prisma raw queries).
|
|
33
|
+
- **Mass Assignment**: Never destructure user input directly into a database create/update call. Explicitly pick the fields allowed to be updated.
|
|
34
|
+
- **Query Depth**: For GraphQL backends, always implement depth limiting and cost analysis to prevent query-based DDoS.
|
|
35
|
+
|
|
36
|
+
## 4. Headers & Server Hardening
|
|
37
|
+
- **CORS**: Never use wildcard `Access-Control-Allow-Origin: *` for authenticated routes.
|
|
38
|
+
- **Security Headers**: Ensure Helmet (or equivalent Next.js headers config) is active for HSTS, X-Frame-Options, and Content-Type-Options.
|
|
39
|
+
|
|
40
|
+
---
|
|
41
|
+
|
|
42
|
+
AI coding assistants often fall into specific bad habits when dealing with this domain. These are strictly forbidden:
|
|
43
|
+
|
|
44
|
+
1. **Over-engineering:** Proposing complex abstractions or distributed systems when a simpler approach suffices.
|
|
45
|
+
2. **Hallucinated Libraries/Methods:** Using non-existent methods or packages. Always `// VERIFY` or check `package.json` / `requirements.txt`.
|
|
46
|
+
3. **Skipping Edge Cases:** Writing the "happy path" and ignoring error handling, timeouts, or data validation.
|
|
47
|
+
4. **Context Amnesia:** Forgetting the user's constraints and offering generic advice instead of tailored solutions.
|
|
48
|
+
5. **Silent Degradation:** Catching and suppressing errors without logging or re-raising.
|
|
49
|
+
|
|
50
|
+
---
|
|
51
|
+
|
|
52
|
+
**Slash command: `/review` or `/tribunal-full`**
|
|
53
|
+
**Active reviewers: `logic-reviewer` · `security-auditor`**
|
|
54
|
+
|
|
55
|
+
### ❌ Forbidden AI Tropes
|
|
56
|
+
|
|
57
|
+
1. **Blind Assumptions:** Never make an assumption without documenting it clearly with `// VERIFY: [reason]`.
|
|
58
|
+
2. **Silent Degradation:** Catching and suppressing errors without logging or handling.
|
|
59
|
+
3. **Context Amnesia:** Forgetting the user's constraints and offering generic advice instead of tailored solutions.
|
|
60
|
+
|
|
61
|
+
Review these questions before confirming output:
|
|
62
|
+
```
|
|
63
|
+
✅ Did I rely ONLY on real, verified tools and methods?
|
|
64
|
+
✅ Is this solution appropriately scoped to the user's constraints?
|
|
65
|
+
✅ Did I handle potential failure modes and edge cases?
|
|
66
|
+
✅ Have I avoided generic boilerplate that doesn't add value?
|
|
67
|
+
```
|
|
68
|
+
|
|
69
|
+
### 🛑 Verification-Before-Completion (VBC) Protocol
|
|
70
|
+
|
|
71
|
+
**CRITICAL:** You must follow a strict "evidence-based closeout" state machine.
|
|
72
|
+
- ❌ **Forbidden:** Declaring a task complete because the output "looks correct."
|
|
73
|
+
- ✅ **Required:** You are explicitly forbidden from finalizing any task without providing **concrete evidence** (terminal output, passing tests, compile success, or equivalent proof) that your output works as intended.
|
|
74
|
+
|
|
75
|
+
## Pre-Flight Checklist
|
|
76
|
+
- [ ] Have I reviewed the user's specific constraints and requests?
|
|
77
|
+
- [ ] Have I checked the environment for relevant existing implementations?
|
|
78
|
+
|
|
79
|
+
## VBC Protocol (Verification-Before-Completion)
|
|
80
|
+
You MUST verify existing code signatures and variables before attempting to modify or call them. No hallucination is permitted.
|
|
81
|
+
|
|
82
|
+
|
|
83
|
+
---
|
|
84
|
+
|
|
85
|
+
## 🤖 LLM-Specific Traps
|
|
86
|
+
|
|
87
|
+
AI coding assistants often fall into specific bad habits when dealing with this domain. These are strictly forbidden:
|
|
88
|
+
|
|
89
|
+
1. **Over-engineering:** Proposing complex abstractions or distributed systems when a simpler approach suffices.
|
|
90
|
+
2. **Hallucinated Libraries/Methods:** Using non-existent methods or packages. Always `// VERIFY` or check `package.json` / `requirements.txt`.
|
|
91
|
+
3. **Skipping Edge Cases:** Writing the "happy path" and ignoring error handling, timeouts, or data validation.
|
|
92
|
+
4. **Context Amnesia:** Forgetting the user's constraints and offering generic advice instead of tailored solutions.
|
|
93
|
+
5. **Silent Degradation:** Catching and suppressing errors without logging or re-raising.
|
|
94
|
+
|
|
95
|
+
---
|
|
96
|
+
|
|
97
|
+
## 🏛️ Tribunal Integration (Anti-Hallucination)
|
|
98
|
+
|
|
99
|
+
**Slash command: `/review` or `/tribunal-full`**
|
|
100
|
+
**Active reviewers: `logic-reviewer` · `security-auditor`**
|
|
101
|
+
|
|
102
|
+
### ❌ Forbidden AI Tropes
|
|
103
|
+
|
|
104
|
+
1. **Blind Assumptions:** Never make an assumption without documenting it clearly with `// VERIFY: [reason]`.
|
|
105
|
+
2. **Silent Degradation:** Catching and suppressing errors without logging or handling.
|
|
106
|
+
3. **Context Amnesia:** Forgetting the user's constraints and offering generic advice instead of tailored solutions.
|
|
107
|
+
|
|
108
|
+
### ✅ Pre-Flight Self-Audit
|
|
109
|
+
|
|
110
|
+
Review these questions before confirming output:
|
|
111
|
+
```
|
|
112
|
+
✅ Did I rely ONLY on real, verified tools and methods?
|
|
113
|
+
✅ Is this solution appropriately scoped to the user's constraints?
|
|
114
|
+
✅ Did I handle potential failure modes and edge cases?
|
|
115
|
+
✅ Have I avoided generic boilerplate that doesn't add value?
|
|
116
|
+
```
|
|
117
|
+
|
|
118
|
+
### 🛑 Verification-Before-Completion (VBC) Protocol
|
|
119
|
+
|
|
120
|
+
**CRITICAL:** You must follow a strict "evidence-based closeout" state machine.
|
|
121
|
+
- ❌ **Forbidden:** Declaring a task complete because the output "looks correct."
|
|
122
|
+
- ✅ **Required:** You are explicitly forbidden from finalizing any task without providing **concrete evidence** (terminal output, passing tests, compile success, or equivalent proof) that your output works as intended.
|
|
@@ -177,3 +177,45 @@ Review these questions before confirming output:
|
|
|
177
177
|
|
|
178
178
|
## VBC Protocol (Verification-Before-Completion)
|
|
179
179
|
You MUST verify existing code signatures and variables before attempting to modify or call them. No hallucination is permitted.
|
|
180
|
+
|
|
181
|
+
|
|
182
|
+
---
|
|
183
|
+
|
|
184
|
+
## 🤖 LLM-Specific Traps
|
|
185
|
+
|
|
186
|
+
AI coding assistants often fall into specific bad habits when dealing with this domain. These are strictly forbidden:
|
|
187
|
+
|
|
188
|
+
1. **Over-engineering:** Proposing complex abstractions or distributed systems when a simpler approach suffices.
|
|
189
|
+
2. **Hallucinated Libraries/Methods:** Using non-existent methods or packages. Always `// VERIFY` or check `package.json` / `requirements.txt`.
|
|
190
|
+
3. **Skipping Edge Cases:** Writing the "happy path" and ignoring error handling, timeouts, or data validation.
|
|
191
|
+
4. **Context Amnesia:** Forgetting the user's constraints and offering generic advice instead of tailored solutions.
|
|
192
|
+
5. **Silent Degradation:** Catching and suppressing errors without logging or re-raising.
|
|
193
|
+
|
|
194
|
+
---
|
|
195
|
+
|
|
196
|
+
## 🏛️ Tribunal Integration (Anti-Hallucination)
|
|
197
|
+
|
|
198
|
+
**Slash command: `/review` or `/tribunal-full`**
|
|
199
|
+
**Active reviewers: `logic-reviewer` · `security-auditor`**
|
|
200
|
+
|
|
201
|
+
### ❌ Forbidden AI Tropes
|
|
202
|
+
|
|
203
|
+
1. **Blind Assumptions:** Never make an assumption without documenting it clearly with `// VERIFY: [reason]`.
|
|
204
|
+
2. **Silent Degradation:** Catching and suppressing errors without logging or handling.
|
|
205
|
+
3. **Context Amnesia:** Forgetting the user's constraints and offering generic advice instead of tailored solutions.
|
|
206
|
+
|
|
207
|
+
### ✅ Pre-Flight Self-Audit
|
|
208
|
+
|
|
209
|
+
Review these questions before confirming output:
|
|
210
|
+
```
|
|
211
|
+
✅ Did I rely ONLY on real, verified tools and methods?
|
|
212
|
+
✅ Is this solution appropriately scoped to the user's constraints?
|
|
213
|
+
✅ Did I handle potential failure modes and edge cases?
|
|
214
|
+
✅ Have I avoided generic boilerplate that doesn't add value?
|
|
215
|
+
```
|
|
216
|
+
|
|
217
|
+
### 🛑 Verification-Before-Completion (VBC) Protocol
|
|
218
|
+
|
|
219
|
+
**CRITICAL:** You must follow a strict "evidence-based closeout" state machine.
|
|
220
|
+
- ❌ **Forbidden:** Declaring a task complete because the output "looks correct."
|
|
221
|
+
- ✅ **Required:** You are explicitly forbidden from finalizing any task without providing **concrete evidence** (terminal output, passing tests, compile success, or equivalent proof) that your output works as intended.
|