@su-record/vibe 2.5.12 → 2.5.14
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/CLAUDE.md +243 -251
- package/commands/vibe.analyze.md +3 -3
- package/commands/vibe.review.md +3 -3
- package/commands/vibe.run.md +75 -9
- package/commands/vibe.spec.md +7 -7
- package/commands/vibe.utils.md +62 -5
- package/dist/cli/setup/GlobalInstaller.d.ts +24 -0
- package/dist/cli/setup/GlobalInstaller.d.ts.map +1 -0
- package/dist/cli/setup/GlobalInstaller.js +130 -0
- package/dist/cli/setup/GlobalInstaller.js.map +1 -0
- package/dist/cli/setup/LanguageDetector.d.ts +16 -0
- package/dist/cli/setup/LanguageDetector.d.ts.map +1 -0
- package/dist/cli/setup/LanguageDetector.js +49 -0
- package/dist/cli/setup/LanguageDetector.js.map +1 -0
- package/dist/cli/setup/LegacyMigration.d.ts +25 -0
- package/dist/cli/setup/LegacyMigration.d.ts.map +1 -0
- package/dist/cli/setup/LegacyMigration.js +162 -0
- package/dist/cli/setup/LegacyMigration.js.map +1 -0
- package/dist/cli/setup/ProjectSetup.d.ts +30 -0
- package/dist/cli/setup/ProjectSetup.d.ts.map +1 -0
- package/dist/cli/setup/ProjectSetup.js +240 -0
- package/dist/cli/setup/ProjectSetup.js.map +1 -0
- package/dist/cli/setup/index.d.ts +14 -0
- package/dist/cli/setup/index.d.ts.map +1 -0
- package/dist/cli/setup/index.js +18 -0
- package/dist/cli/setup/index.js.map +1 -0
- package/dist/cli/setup.d.ts +10 -77
- package/dist/cli/setup.d.ts.map +1 -1
- package/dist/cli/setup.js +15 -592
- package/dist/cli/setup.js.map +1 -1
- package/dist/lib/llm/auth/ApiKeyManager.d.ts +21 -0
- package/dist/lib/llm/auth/ApiKeyManager.d.ts.map +1 -0
- package/dist/lib/llm/auth/ApiKeyManager.js +43 -0
- package/dist/lib/llm/auth/ApiKeyManager.js.map +1 -0
- package/dist/lib/llm/auth/ConfigManager.d.ts +29 -0
- package/dist/lib/llm/auth/ConfigManager.d.ts.map +1 -0
- package/dist/lib/llm/auth/ConfigManager.js +67 -0
- package/dist/lib/llm/auth/ConfigManager.js.map +1 -0
- package/dist/lib/llm/auth/index.d.ts +25 -0
- package/dist/lib/llm/auth/index.d.ts.map +1 -0
- package/dist/lib/llm/auth/index.js +83 -0
- package/dist/lib/llm/auth/index.js.map +1 -0
- package/dist/lib/llm/index.d.ts +10 -0
- package/dist/lib/llm/index.d.ts.map +1 -0
- package/dist/lib/llm/index.js +12 -0
- package/dist/lib/llm/index.js.map +1 -0
- package/dist/lib/llm/types.d.ts +96 -0
- package/dist/lib/llm/types.d.ts.map +1 -0
- package/dist/lib/llm/types.js +17 -0
- package/dist/lib/llm/types.js.map +1 -0
- package/dist/lib/llm/utils/index.d.ts +6 -0
- package/dist/lib/llm/utils/index.d.ts.map +1 -0
- package/dist/lib/llm/utils/index.js +6 -0
- package/dist/lib/llm/utils/index.js.map +1 -0
- package/dist/lib/llm/utils/retry.d.ts +25 -0
- package/dist/lib/llm/utils/retry.d.ts.map +1 -0
- package/dist/lib/llm/utils/retry.js +72 -0
- package/dist/lib/llm/utils/retry.js.map +1 -0
- package/dist/lib/llm/utils/stream.d.ts +13 -0
- package/dist/lib/llm/utils/stream.d.ts.map +1 -0
- package/dist/lib/llm/utils/stream.js +110 -0
- package/dist/lib/llm/utils/stream.js.map +1 -0
- package/dist/orchestrator/AgentExecutor.d.ts +23 -0
- package/dist/orchestrator/AgentExecutor.d.ts.map +1 -0
- package/dist/orchestrator/AgentExecutor.js +231 -0
- package/dist/orchestrator/AgentExecutor.js.map +1 -0
- package/dist/orchestrator/AgentManager.d.ts +73 -0
- package/dist/orchestrator/AgentManager.d.ts.map +1 -0
- package/dist/orchestrator/AgentManager.js +184 -0
- package/dist/orchestrator/AgentManager.js.map +1 -0
- package/dist/orchestrator/LLMCluster.d.ts +70 -0
- package/dist/orchestrator/LLMCluster.d.ts.map +1 -0
- package/dist/orchestrator/LLMCluster.js +91 -0
- package/dist/orchestrator/LLMCluster.js.map +1 -0
- package/dist/orchestrator/MultiLlmResearch.d.ts +27 -0
- package/dist/orchestrator/MultiLlmResearch.d.ts.map +1 -0
- package/dist/orchestrator/MultiLlmResearch.js +145 -0
- package/dist/orchestrator/MultiLlmResearch.js.map +1 -0
- package/dist/orchestrator/SessionStore.d.ts +41 -0
- package/dist/orchestrator/SessionStore.d.ts.map +1 -0
- package/dist/orchestrator/SessionStore.js +117 -0
- package/dist/orchestrator/SessionStore.js.map +1 -0
- package/dist/orchestrator/SmartRouter.d.ts +68 -0
- package/dist/orchestrator/SmartRouter.d.ts.map +1 -0
- package/dist/orchestrator/SmartRouter.js +256 -0
- package/dist/orchestrator/SmartRouter.js.map +1 -0
- package/dist/orchestrator/backgroundAgent.d.ts +10 -27
- package/dist/orchestrator/backgroundAgent.d.ts.map +1 -1
- package/dist/orchestrator/backgroundAgent.js +11 -345
- package/dist/orchestrator/backgroundAgent.js.map +1 -1
- package/dist/orchestrator/index.d.ts +3 -0
- package/dist/orchestrator/index.d.ts.map +1 -1
- package/dist/orchestrator/index.js +4 -0
- package/dist/orchestrator/index.js.map +1 -1
- package/dist/orchestrator/orchestrator.d.ts +19 -154
- package/dist/orchestrator/orchestrator.d.ts.map +1 -1
- package/dist/orchestrator/orchestrator.js +90 -514
- package/dist/orchestrator/orchestrator.js.map +1 -1
- package/dist/orchestrator/parallelResearch.d.ts +5 -12
- package/dist/orchestrator/parallelResearch.d.ts.map +1 -1
- package/dist/orchestrator/parallelResearch.js +10 -193
- package/dist/orchestrator/parallelResearch.js.map +1 -1
- package/hooks/scripts/generate-brand-assets.js +472 -0
- package/package.json +1 -1
- package/skills/brand-assets.md +141 -0
- package/skills/commerce-patterns.md +361 -0
- package/skills/e2e-commerce.md +304 -0
- package/skills/frontend-design.md +92 -0
- package/skills/seo-checklist.md +244 -0
package/CLAUDE.md
CHANGED
|
@@ -2,14 +2,6 @@
|
|
|
2
2
|
|
|
3
3
|
SPEC-driven AI Coding Framework (Claude Code Exclusive)
|
|
4
4
|
|
|
5
|
-
## Response Language
|
|
6
|
-
|
|
7
|
-
**IMPORTANT: Always respond in English unless the user explicitly requests otherwise.**
|
|
8
|
-
|
|
9
|
-
## Response Language
|
|
10
|
-
|
|
11
|
-
**IMPORTANT: Always respond in Korean (한국어) unless the user explicitly requests otherwise.**
|
|
12
|
-
|
|
13
5
|
## Code Quality Standards (Mandatory)
|
|
14
6
|
|
|
15
7
|
Follow these standards when writing code. See `~/.claude/vibe/rules/` (global) for detailed rules.
|
|
@@ -40,12 +32,12 @@ Follow these standards when writing code. See `~/.claude/vibe/rules/` (global) f
|
|
|
40
32
|
- No `@ts-ignore` → fix type issues at root
|
|
41
33
|
- Explicit return types on all functions
|
|
42
34
|
|
|
43
|
-
### TypeScript Rules
|
|
44
|
-
- No `any` type → use `unknown` + type guards
|
|
45
|
-
- No `as any` casting → define proper interfaces
|
|
46
|
-
- No `@ts-ignore` → fix type issues at root
|
|
47
|
-
- Explicit return types on all functions
|
|
48
|
-
|
|
35
|
+
### TypeScript Rules
|
|
36
|
+
- No `any` type → use `unknown` + type guards
|
|
37
|
+
- No `as any` casting → define proper interfaces
|
|
38
|
+
- No `@ts-ignore` → fix type issues at root
|
|
39
|
+
- Explicit return types on all functions
|
|
40
|
+
|
|
49
41
|
### Error Handling Required
|
|
50
42
|
- try-catch or error state required
|
|
51
43
|
- Loading state handling
|
|
@@ -452,240 +444,240 @@ flowchart TD
|
|
|
452
444
|
| 3. `/vibe.run` | Implementation + Gemini review | Manual start |
|
|
453
445
|
| 4. Agent Review | 13+ agent parallel review | ✅ Auto |
|
|
454
446
|
| 5. Auto-Fix | P1/P2 issue auto-fix | ✅ Auto |
|
|
455
|
-
|
|
456
|
-
---
|
|
457
|
-
name: my-skill
|
|
458
|
-
model: sonnet
|
|
459
|
-
triggers: [keyword1, keyword2]
|
|
460
|
-
---
|
|
461
|
-
```
|
|
462
|
-
|
|
463
|
-
### Trigger-Based Skill Injection
|
|
464
|
-
|
|
465
|
-
Skills in `~/.claude/vibe/skills/` or `.claude/vibe/skills/` auto-inject on keyword match.
|
|
466
|
-
|
|
467
|
-
### Multi-Line HUD
|
|
468
|
-
|
|
469
|
-
```bash
|
|
470
|
-
node hooks/scripts/hud-multiline.js multi # Tree view
|
|
471
|
-
node hooks/scripts/hud-multiline.js compact # 2-line view
|
|
472
|
-
node hooks/scripts/hud-multiline.js single # 1-line view
|
|
473
|
-
```
|
|
474
|
-
|
|
475
|
-
### Parallel Code Review (/vibe.review)
|
|
476
|
-
|
|
477
|
-
13+ specialized agents review code simultaneously:
|
|
478
|
-
|
|
479
|
-
```
|
|
480
|
-
┌─────────────────────────────────────────────────────────────────┐
|
|
481
|
-
│ 🚀 PARALLEL REVIEW AGENTS │
|
|
482
|
-
├─────────────────────────────────────────────────────────────────┤
|
|
483
|
-
│ Security │ security-reviewer, data-integrity-reviewer │
|
|
484
|
-
│ Performance │ performance-reviewer, complexity-reviewer │
|
|
485
|
-
│ Architecture │ architecture-reviewer, simplicity-reviewer │
|
|
486
|
-
│ Language-Specific │ python, typescript, rails, react reviewers │
|
|
487
|
-
│ Context │ git-history, test-coverage reviewers │
|
|
488
|
-
└─────────────────────────────────────────────────────────────────┘
|
|
489
|
-
```
|
|
490
|
-
|
|
491
|
-
**Priority System:**
|
|
492
|
-
- 🔴 P1 (Critical): Blocks merge
|
|
493
|
-
- 🟡 P2 (Important): Fix recommended
|
|
494
|
-
- 🔵 P3 (Nice-to-have): Backlog
|
|
495
|
-
|
|
496
|
-
### E2E Testing (/vibe.utils --e2e)
|
|
497
|
-
|
|
498
|
-
Playwright-based automated testing:
|
|
499
|
-
|
|
500
|
-
```bash
|
|
501
|
-
/vibe.utils --e2e "login flow" # Scenario test
|
|
502
|
-
/vibe.utils --e2e --visual # Visual regression test
|
|
503
|
-
/vibe.utils --e2e --record # Video recording
|
|
504
|
-
```
|
|
505
|
-
|
|
506
|
-
### Enhanced Research Agents
|
|
507
|
-
|
|
508
|
-
4 parallel research agents run **after requirements confirmed** during `/vibe.spec`:
|
|
509
|
-
|
|
510
|
-
```
|
|
511
|
-
Q&A to confirm requirements → Parallel research → SPEC writing
|
|
512
|
-
```
|
|
513
|
-
|
|
514
|
-
| Agent | Role |
|
|
515
|
-
|-------|------|
|
|
516
|
-
| best-practices-agent | Best practices for confirmed feature+stack |
|
|
517
|
-
| framework-docs-agent | Latest docs for confirmed stack (context7) |
|
|
518
|
-
| codebase-patterns-agent | Analyze existing similar patterns |
|
|
519
|
-
| security-advisory-agent | Security advisory for confirmed feature |
|
|
520
|
-
|
|
521
|
-
**⚠️ Research runs after requirements confirmed** (VIBE principle: requirements first)
|
|
522
|
-
|
|
523
|
-
## PTCF Structure
|
|
524
|
-
|
|
525
|
-
SPEC documents are AI-executable prompt format:
|
|
526
|
-
|
|
527
|
-
```
|
|
528
|
-
<role> AI role definition
|
|
529
|
-
<context> Background, tech stack, related code
|
|
530
|
-
<task> Phase-by-phase task list
|
|
531
|
-
<constraints> Constraints
|
|
532
|
-
<output_format> Files to create/modify
|
|
533
|
-
<acceptance> Verification criteria
|
|
534
|
-
```
|
|
535
|
-
|
|
536
|
-
## Built-in Tools
|
|
537
|
-
|
|
538
|
-
### Semantic Code Analysis
|
|
539
|
-
| Tool | Purpose |
|
|
540
|
-
|------|---------|
|
|
541
|
-
| `vibe_find_symbol` | Find symbol definitions |
|
|
542
|
-
| `vibe_find_references` | Find references |
|
|
543
|
-
| `vibe_analyze_complexity` | Analyze complexity |
|
|
544
|
-
| `vibe_validate_code_quality` | Validate quality |
|
|
545
|
-
|
|
546
|
-
### Context Management
|
|
547
|
-
| Tool | Purpose |
|
|
548
|
-
|------|---------|
|
|
549
|
-
| `vibe_start_session` | Start session (restore previous context) |
|
|
550
|
-
| `vibe_auto_save_context` | Save current state |
|
|
551
|
-
| `vibe_save_memory` | Save important decisions |
|
|
552
|
-
|
|
553
|
-
## Agents
|
|
554
|
-
|
|
555
|
-
### Review Agents (12)
|
|
556
|
-
```
|
|
557
|
-
.claude/agents/review/
|
|
558
|
-
├── security-reviewer.md # Security vulnerabilities
|
|
559
|
-
├── performance-reviewer.md # Performance bottlenecks
|
|
560
|
-
├── architecture-reviewer.md # Architecture violations
|
|
561
|
-
├── complexity-reviewer.md # Complexity exceeded
|
|
562
|
-
├── simplicity-reviewer.md # Over-abstraction
|
|
563
|
-
├── data-integrity-reviewer.md # Data integrity
|
|
564
|
-
├── test-coverage-reviewer.md # Missing tests
|
|
565
|
-
├── git-history-reviewer.md # Risk patterns
|
|
566
|
-
├── python-reviewer.md # Python specialist
|
|
567
|
-
├── typescript-reviewer.md # TypeScript specialist
|
|
568
|
-
├── rails-reviewer.md # Rails specialist
|
|
569
|
-
└── react-reviewer.md # React specialist
|
|
570
|
-
```
|
|
571
|
-
|
|
572
|
-
### Research Agents (4)
|
|
573
|
-
```
|
|
574
|
-
.claude/agents/research/
|
|
575
|
-
├── best-practices-agent.md # Best practices
|
|
576
|
-
├── framework-docs-agent.md # Framework docs
|
|
577
|
-
├── codebase-patterns-agent.md # Code pattern analysis
|
|
578
|
-
└── security-advisory-agent.md # Security advisory
|
|
579
|
-
```
|
|
580
|
-
|
|
581
|
-
## Skills
|
|
582
|
-
|
|
583
|
-
### Git Worktree
|
|
584
|
-
```bash
|
|
585
|
-
# Isolated environment for PR review
|
|
586
|
-
git worktree add ../review-123 origin/pr/123
|
|
587
|
-
cd ../review-123 && npm test
|
|
588
|
-
git worktree remove ../review-123
|
|
589
|
-
```
|
|
590
|
-
|
|
591
|
-
### Priority Todos
|
|
592
|
-
```
|
|
593
|
-
.claude/vibe/todos/
|
|
594
|
-
├── P1-security-sql-injection.md # 🔴 Blocks merge
|
|
595
|
-
├── P2-perf-n1-query.md # 🟡 Fix recommended
|
|
596
|
-
└── P3-style-extract-helper.md # 🔵 Backlog
|
|
597
|
-
```
|
|
598
|
-
|
|
599
|
-
## Context Management Strategy
|
|
600
|
-
|
|
601
|
-
### Model Selection
|
|
602
|
-
- **Exploration/Search**: Haiku (sub-agent default)
|
|
603
|
-
- **Implementation/Debugging**: Sonnet
|
|
604
|
-
- **Architecture/Complex logic**: Opus
|
|
605
|
-
|
|
606
|
-
### At 70%+ Context (⚠️ Important)
|
|
607
|
-
```
|
|
608
|
-
❌ Don't use /compact (risk of information loss/distortion)
|
|
609
|
-
✅ save_memory to store important decisions → /new for new session
|
|
610
|
-
```
|
|
611
|
-
|
|
612
|
-
vibe maintains context across sessions with its own memory system:
|
|
613
|
-
1. `save_memory` - Explicitly save important decisions
|
|
614
|
-
2. `/new` - Start new session
|
|
615
|
-
3. `start_session` - Auto-restore previous session
|
|
616
|
-
|
|
617
|
-
### Session Restore
|
|
618
|
-
To continue previous work in a new session:
|
|
619
|
-
```
|
|
620
|
-
/vibe.utils --continue
|
|
621
|
-
```
|
|
622
|
-
This command calls `vibe_start_session` to restore previous context from project memory.
|
|
623
|
-
|
|
624
|
-
### Other Commands
|
|
625
|
-
- `/rewind` - Revert to previous point
|
|
626
|
-
- `/context` - Check current usage
|
|
627
|
-
|
|
628
|
-
### Using context7
|
|
629
|
-
Use context7 plugin when you need latest library documentation:
|
|
630
|
-
```
|
|
631
|
-
"Search React 19 use() hook with context7"
|
|
632
|
-
```
|
|
633
|
-
|
|
634
|
-
## Documentation Guidelines
|
|
635
|
-
|
|
636
|
-
### Diagrams/Structure Representation
|
|
637
|
-
- Avoid ASCII boxes (┌─┐) → Alignment breaks with mixed-width characters
|
|
638
|
-
- Use alternatives:
|
|
639
|
-
- Mermaid diagrams (GitHub/Notion supported)
|
|
640
|
-
- Markdown tables
|
|
641
|
-
- Indentation + separators
|
|
642
|
-
|
|
643
|
-
### Preferred Formats
|
|
644
|
-
| Purpose | Recommended |
|
|
645
|
-
|---------|-------------|
|
|
646
|
-
| Flowcharts | Mermaid flowchart |
|
|
647
|
-
| Structure/Hierarchy | Indented lists |
|
|
648
|
-
| Comparisons/Lists | Markdown tables |
|
|
649
|
-
| Sequences | Mermaid sequenceDiagram |
|
|
650
|
-
|
|
651
|
-
## Git Commit Rules
|
|
652
|
-
|
|
653
|
-
**Must include:**
|
|
654
|
-
- `.claude/vibe/specs/`, `.claude/vibe/features/`, `.claude/vibe/todos/` (project docs)
|
|
655
|
-
- `.claude/vibe/config.json`, `.claude/vibe/constitution.md` (project config)
|
|
656
|
-
- `CLAUDE.md`
|
|
657
|
-
|
|
658
|
-
**Exclude (globally installed):**
|
|
659
|
-
- `~/.claude/vibe/rules/`, `~/.claude/vibe/languages/`, `~/.claude/vibe/templates/` (global)
|
|
660
|
-
- `~/.claude/commands/`, `~/.claude/agents/`, `~/.claude/skills/` (global)
|
|
661
|
-
- `.claude/settings.local.json` (personal settings)
|
|
662
|
-
|
|
663
|
-
## Getting Started
|
|
664
|
-
|
|
665
|
-
```bash
|
|
666
|
-
vibe init
|
|
667
|
-
/vibe.spec "login feature"
|
|
668
|
-
```
|
|
669
|
-
|
|
670
|
-
## Full Workflow
|
|
671
|
-
|
|
672
|
-
```mermaid
|
|
673
|
-
flowchart TD
|
|
674
|
-
A["/vibe.spec"] --> B["(auto) SPEC review"]
|
|
675
|
-
B --> C["SPEC auto-enhancement"]
|
|
676
|
-
C --> D["/vibe.run ultrawork"]
|
|
677
|
-
D --> E["Gemini code review"]
|
|
678
|
-
E --> F["(auto) 13+ Agent Review"]
|
|
679
|
-
F --> G{"P1/P2 issues?"}
|
|
680
|
-
G -->|Yes| H["(auto) Auto-Fix"]
|
|
681
|
-
H --> I["✅ Done"]
|
|
682
|
-
G -->|No| I
|
|
683
|
-
```
|
|
684
|
-
|
|
685
|
-
| Step | Description | Automation |
|
|
686
|
-
|------|-------------|------------|
|
|
687
|
-
| 1. `/vibe.spec` | Collect requirements + Generate SPEC | Manual start |
|
|
688
|
-
| 2. SPEC review | Gemini reviews SPEC + Auto-apply | ✅ Auto |
|
|
689
|
-
| 3. `/vibe.run` | Implementation + Gemini review | Manual start |
|
|
690
|
-
| 4. Agent Review | 13+ agent parallel review | ✅ Auto |
|
|
691
|
-
| 5. Auto-Fix | P1/P2 issue auto-fix | ✅ Auto |
|
|
447
|
+
|
|
448
|
+
---
|
|
449
|
+
name: my-skill
|
|
450
|
+
model: sonnet
|
|
451
|
+
triggers: [keyword1, keyword2]
|
|
452
|
+
---
|
|
453
|
+
```
|
|
454
|
+
|
|
455
|
+
### Trigger-Based Skill Injection
|
|
456
|
+
|
|
457
|
+
Skills in `~/.claude/vibe/skills/` or `.claude/vibe/skills/` auto-inject on keyword match.
|
|
458
|
+
|
|
459
|
+
### Multi-Line HUD
|
|
460
|
+
|
|
461
|
+
```bash
|
|
462
|
+
node hooks/scripts/hud-multiline.js multi # Tree view
|
|
463
|
+
node hooks/scripts/hud-multiline.js compact # 2-line view
|
|
464
|
+
node hooks/scripts/hud-multiline.js single # 1-line view
|
|
465
|
+
```
|
|
466
|
+
|
|
467
|
+
### Parallel Code Review (/vibe.review)
|
|
468
|
+
|
|
469
|
+
13+ specialized agents review code simultaneously:
|
|
470
|
+
|
|
471
|
+
```
|
|
472
|
+
┌─────────────────────────────────────────────────────────────────┐
|
|
473
|
+
│ 🚀 PARALLEL REVIEW AGENTS │
|
|
474
|
+
├─────────────────────────────────────────────────────────────────┤
|
|
475
|
+
│ Security │ security-reviewer, data-integrity-reviewer │
|
|
476
|
+
│ Performance │ performance-reviewer, complexity-reviewer │
|
|
477
|
+
│ Architecture │ architecture-reviewer, simplicity-reviewer │
|
|
478
|
+
│ Language-Specific │ python, typescript, rails, react reviewers │
|
|
479
|
+
│ Context │ git-history, test-coverage reviewers │
|
|
480
|
+
└─────────────────────────────────────────────────────────────────┘
|
|
481
|
+
```
|
|
482
|
+
|
|
483
|
+
**Priority System:**
|
|
484
|
+
- 🔴 P1 (Critical): Blocks merge
|
|
485
|
+
- 🟡 P2 (Important): Fix recommended
|
|
486
|
+
- 🔵 P3 (Nice-to-have): Backlog
|
|
487
|
+
|
|
488
|
+
### E2E Testing (/vibe.utils --e2e)
|
|
489
|
+
|
|
490
|
+
Playwright-based automated testing:
|
|
491
|
+
|
|
492
|
+
```bash
|
|
493
|
+
/vibe.utils --e2e "login flow" # Scenario test
|
|
494
|
+
/vibe.utils --e2e --visual # Visual regression test
|
|
495
|
+
/vibe.utils --e2e --record # Video recording
|
|
496
|
+
```
|
|
497
|
+
|
|
498
|
+
### Enhanced Research Agents
|
|
499
|
+
|
|
500
|
+
4 parallel research agents run **after requirements confirmed** during `/vibe.spec`:
|
|
501
|
+
|
|
502
|
+
```
|
|
503
|
+
Q&A to confirm requirements → Parallel research → SPEC writing
|
|
504
|
+
```
|
|
505
|
+
|
|
506
|
+
| Agent | Role |
|
|
507
|
+
|-------|------|
|
|
508
|
+
| best-practices-agent | Best practices for confirmed feature+stack |
|
|
509
|
+
| framework-docs-agent | Latest docs for confirmed stack (context7) |
|
|
510
|
+
| codebase-patterns-agent | Analyze existing similar patterns |
|
|
511
|
+
| security-advisory-agent | Security advisory for confirmed feature |
|
|
512
|
+
|
|
513
|
+
**⚠️ Research runs after requirements confirmed** (VIBE principle: requirements first)
|
|
514
|
+
|
|
515
|
+
## PTCF Structure
|
|
516
|
+
|
|
517
|
+
SPEC documents are AI-executable prompt format:
|
|
518
|
+
|
|
519
|
+
```
|
|
520
|
+
<role> AI role definition
|
|
521
|
+
<context> Background, tech stack, related code
|
|
522
|
+
<task> Phase-by-phase task list
|
|
523
|
+
<constraints> Constraints
|
|
524
|
+
<output_format> Files to create/modify
|
|
525
|
+
<acceptance> Verification criteria
|
|
526
|
+
```
|
|
527
|
+
|
|
528
|
+
## Built-in Tools
|
|
529
|
+
|
|
530
|
+
### Semantic Code Analysis
|
|
531
|
+
| Tool | Purpose |
|
|
532
|
+
|------|---------|
|
|
533
|
+
| `vibe_find_symbol` | Find symbol definitions |
|
|
534
|
+
| `vibe_find_references` | Find references |
|
|
535
|
+
| `vibe_analyze_complexity` | Analyze complexity |
|
|
536
|
+
| `vibe_validate_code_quality` | Validate quality |
|
|
537
|
+
|
|
538
|
+
### Context Management
|
|
539
|
+
| Tool | Purpose |
|
|
540
|
+
|------|---------|
|
|
541
|
+
| `vibe_start_session` | Start session (restore previous context) |
|
|
542
|
+
| `vibe_auto_save_context` | Save current state |
|
|
543
|
+
| `vibe_save_memory` | Save important decisions |
|
|
544
|
+
|
|
545
|
+
## Agents
|
|
546
|
+
|
|
547
|
+
### Review Agents (12)
|
|
548
|
+
```
|
|
549
|
+
.claude/agents/review/
|
|
550
|
+
├── security-reviewer.md # Security vulnerabilities
|
|
551
|
+
├── performance-reviewer.md # Performance bottlenecks
|
|
552
|
+
├── architecture-reviewer.md # Architecture violations
|
|
553
|
+
├── complexity-reviewer.md # Complexity exceeded
|
|
554
|
+
├── simplicity-reviewer.md # Over-abstraction
|
|
555
|
+
├── data-integrity-reviewer.md # Data integrity
|
|
556
|
+
├── test-coverage-reviewer.md # Missing tests
|
|
557
|
+
├── git-history-reviewer.md # Risk patterns
|
|
558
|
+
├── python-reviewer.md # Python specialist
|
|
559
|
+
├── typescript-reviewer.md # TypeScript specialist
|
|
560
|
+
├── rails-reviewer.md # Rails specialist
|
|
561
|
+
└── react-reviewer.md # React specialist
|
|
562
|
+
```
|
|
563
|
+
|
|
564
|
+
### Research Agents (4)
|
|
565
|
+
```
|
|
566
|
+
.claude/agents/research/
|
|
567
|
+
├── best-practices-agent.md # Best practices
|
|
568
|
+
├── framework-docs-agent.md # Framework docs
|
|
569
|
+
├── codebase-patterns-agent.md # Code pattern analysis
|
|
570
|
+
└── security-advisory-agent.md # Security advisory
|
|
571
|
+
```
|
|
572
|
+
|
|
573
|
+
## Skills
|
|
574
|
+
|
|
575
|
+
### Git Worktree
|
|
576
|
+
```bash
|
|
577
|
+
# Isolated environment for PR review
|
|
578
|
+
git worktree add ../review-123 origin/pr/123
|
|
579
|
+
cd ../review-123 && npm test
|
|
580
|
+
git worktree remove ../review-123
|
|
581
|
+
```
|
|
582
|
+
|
|
583
|
+
### Priority Todos
|
|
584
|
+
```
|
|
585
|
+
.claude/vibe/todos/
|
|
586
|
+
├── P1-security-sql-injection.md # 🔴 Blocks merge
|
|
587
|
+
├── P2-perf-n1-query.md # 🟡 Fix recommended
|
|
588
|
+
└── P3-style-extract-helper.md # 🔵 Backlog
|
|
589
|
+
```
|
|
590
|
+
|
|
591
|
+
## Context Management Strategy
|
|
592
|
+
|
|
593
|
+
### Model Selection
|
|
594
|
+
- **Exploration/Search**: Haiku (sub-agent default)
|
|
595
|
+
- **Implementation/Debugging**: Sonnet
|
|
596
|
+
- **Architecture/Complex logic**: Opus
|
|
597
|
+
|
|
598
|
+
### At 70%+ Context (⚠️ Important)
|
|
599
|
+
```
|
|
600
|
+
❌ Don't use /compact (risk of information loss/distortion)
|
|
601
|
+
✅ save_memory to store important decisions → /new for new session
|
|
602
|
+
```
|
|
603
|
+
|
|
604
|
+
vibe maintains context across sessions with its own memory system:
|
|
605
|
+
1. `save_memory` - Explicitly save important decisions
|
|
606
|
+
2. `/new` - Start new session
|
|
607
|
+
3. `start_session` - Auto-restore previous session
|
|
608
|
+
|
|
609
|
+
### Session Restore
|
|
610
|
+
To continue previous work in a new session:
|
|
611
|
+
```
|
|
612
|
+
/vibe.utils --continue
|
|
613
|
+
```
|
|
614
|
+
This command calls `vibe_start_session` to restore previous context from project memory.
|
|
615
|
+
|
|
616
|
+
### Other Commands
|
|
617
|
+
- `/rewind` - Revert to previous point
|
|
618
|
+
- `/context` - Check current usage
|
|
619
|
+
|
|
620
|
+
### Using context7
|
|
621
|
+
Use context7 plugin when you need latest library documentation:
|
|
622
|
+
```
|
|
623
|
+
"Search React 19 use() hook with context7"
|
|
624
|
+
```
|
|
625
|
+
|
|
626
|
+
## Documentation Guidelines
|
|
627
|
+
|
|
628
|
+
### Diagrams/Structure Representation
|
|
629
|
+
- Avoid ASCII boxes (┌─┐) → Alignment breaks with mixed-width characters
|
|
630
|
+
- Use alternatives:
|
|
631
|
+
- Mermaid diagrams (GitHub/Notion supported)
|
|
632
|
+
- Markdown tables
|
|
633
|
+
- Indentation + separators
|
|
634
|
+
|
|
635
|
+
### Preferred Formats
|
|
636
|
+
| Purpose | Recommended |
|
|
637
|
+
|---------|-------------|
|
|
638
|
+
| Flowcharts | Mermaid flowchart |
|
|
639
|
+
| Structure/Hierarchy | Indented lists |
|
|
640
|
+
| Comparisons/Lists | Markdown tables |
|
|
641
|
+
| Sequences | Mermaid sequenceDiagram |
|
|
642
|
+
|
|
643
|
+
## Git Commit Rules
|
|
644
|
+
|
|
645
|
+
**Must include:**
|
|
646
|
+
- `.claude/vibe/specs/`, `.claude/vibe/features/`, `.claude/vibe/todos/` (project docs)
|
|
647
|
+
- `.claude/vibe/config.json`, `.claude/vibe/constitution.md` (project config)
|
|
648
|
+
- `CLAUDE.md`
|
|
649
|
+
|
|
650
|
+
**Exclude (globally installed):**
|
|
651
|
+
- `~/.claude/vibe/rules/`, `~/.claude/vibe/languages/`, `~/.claude/vibe/templates/` (global)
|
|
652
|
+
- `~/.claude/commands/`, `~/.claude/agents/`, `~/.claude/skills/` (global)
|
|
653
|
+
- `.claude/settings.local.json` (personal settings)
|
|
654
|
+
|
|
655
|
+
## Getting Started
|
|
656
|
+
|
|
657
|
+
```bash
|
|
658
|
+
vibe init
|
|
659
|
+
/vibe.spec "login feature"
|
|
660
|
+
```
|
|
661
|
+
|
|
662
|
+
## Full Workflow
|
|
663
|
+
|
|
664
|
+
```mermaid
|
|
665
|
+
flowchart TD
|
|
666
|
+
A["/vibe.spec"] --> B["(auto) SPEC review"]
|
|
667
|
+
B --> C["SPEC auto-enhancement"]
|
|
668
|
+
C --> D["/vibe.run ultrawork"]
|
|
669
|
+
D --> E["Gemini code review"]
|
|
670
|
+
E --> F["(auto) 13+ Agent Review"]
|
|
671
|
+
F --> G{"P1/P2 issues?"}
|
|
672
|
+
G -->|Yes| H["(auto) Auto-Fix"]
|
|
673
|
+
H --> I["✅ Done"]
|
|
674
|
+
G -->|No| I
|
|
675
|
+
```
|
|
676
|
+
|
|
677
|
+
| Step | Description | Automation |
|
|
678
|
+
|------|-------------|------------|
|
|
679
|
+
| 1. `/vibe.spec` | Collect requirements + Generate SPEC | Manual start |
|
|
680
|
+
| 2. SPEC review | Gemini reviews SPEC + Auto-apply | ✅ Auto |
|
|
681
|
+
| 3. `/vibe.run` | Implementation + Gemini review | Manual start |
|
|
682
|
+
| 4. Agent Review | 13+ agent parallel review | ✅ Auto |
|
|
683
|
+
| 5. Auto-Fix | P1/P2 issue auto-fix | ✅ Auto |
|
package/commands/vibe.analyze.md
CHANGED
|
@@ -281,9 +281,9 @@ Score = Σ(checked items × weight) / 100
|
|
|
281
281
|
|
|
282
282
|
Grades:
|
|
283
283
|
- 95-100: ✅ EXCELLENT - Comprehensive analysis
|
|
284
|
-
-
|
|
285
|
-
-
|
|
286
|
-
- 0-
|
|
284
|
+
- 90-94: ⚠️ GOOD - Additional exploration recommended
|
|
285
|
+
- 80-89: ⚠️ FAIR - Needs more exploration
|
|
286
|
+
- 0-79: ❌ POOR - Incomplete, re-analyze
|
|
287
287
|
```
|
|
288
288
|
|
|
289
289
|
### Analysis Depth Levels
|
package/commands/vibe.review.md
CHANGED
|
@@ -265,9 +265,9 @@ Score = 100 - (P1 × 20) - (P2 × 5) - (P3 × 1)
|
|
|
265
265
|
|
|
266
266
|
Grades:
|
|
267
267
|
- 95-100: ✅ EXCELLENT - Merge ready
|
|
268
|
-
-
|
|
269
|
-
-
|
|
270
|
-
- 0-
|
|
268
|
+
- 90-94: ⚠️ GOOD - Minor fixes required before merge
|
|
269
|
+
- 80-89: ⚠️ FAIR - Must fix P2 issues
|
|
270
|
+
- 0-79: ❌ POOR - Block merge, fix P1/P2
|
|
271
271
|
```
|
|
272
272
|
|
|
273
273
|
### Merge Decision Matrix
|
package/commands/vibe.run.md
CHANGED
|
@@ -643,7 +643,73 @@ Phase N+1 Start (IMMEDIATE - exploration already done!)
|
|
|
643
643
|
3. **Constraint compliance**: Check `<constraints>`
|
|
644
644
|
4. **Run verification**: Execute verification commands
|
|
645
645
|
|
|
646
|
-
### 4.
|
|
646
|
+
### 4. Brand Assets Generation (Optional)
|
|
647
|
+
|
|
648
|
+
When starting a **new project** with brand context in SPEC, auto-generate app icons and favicons:
|
|
649
|
+
|
|
650
|
+
```
|
|
651
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
652
|
+
🎨 BRAND ASSETS GENERATION
|
|
653
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
654
|
+
|
|
655
|
+
[Check] Brand assets exist? → Skip if favicon.ico exists
|
|
656
|
+
[Check] Gemini API configured? → Required for image generation
|
|
657
|
+
[Check] SPEC has brand context? → Extract app name, colors, style
|
|
658
|
+
|
|
659
|
+
[Generate] Creating app icon with Gemini Image API...
|
|
660
|
+
- Prompt: "App icon for [AppName], [style], [color]..."
|
|
661
|
+
- Generated: 512x512 master icon
|
|
662
|
+
|
|
663
|
+
[Resize] Creating platform variants...
|
|
664
|
+
✅ favicon.ico (16/32/48)
|
|
665
|
+
✅ favicon-16x16.png
|
|
666
|
+
✅ favicon-32x32.png
|
|
667
|
+
✅ apple-touch-icon.png (180x180)
|
|
668
|
+
✅ android-chrome-192x192.png
|
|
669
|
+
✅ android-chrome-512x512.png
|
|
670
|
+
✅ site.webmanifest
|
|
671
|
+
|
|
672
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
673
|
+
✅ Brand assets generated in public/
|
|
674
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
675
|
+
```
|
|
676
|
+
|
|
677
|
+
**SPEC Brand Context Example:**
|
|
678
|
+
|
|
679
|
+
```xml
|
|
680
|
+
<context>
|
|
681
|
+
Brand:
|
|
682
|
+
- App Name: MyApp
|
|
683
|
+
- Primary Color: #2F6BFF
|
|
684
|
+
- Style: Modern, minimalist, flat design
|
|
685
|
+
- Icon Concept: Abstract geometric shape
|
|
686
|
+
</context>
|
|
687
|
+
```
|
|
688
|
+
|
|
689
|
+
**Trigger Conditions:**
|
|
690
|
+
- First `/vibe.run` execution (no existing icons)
|
|
691
|
+
- SPEC contains brand/design context
|
|
692
|
+
- Gemini API key configured (`vibe gemini auth`)
|
|
693
|
+
|
|
694
|
+
**Manual Generation:**
|
|
695
|
+
```bash
|
|
696
|
+
node hooks/scripts/generate-brand-assets.js \
|
|
697
|
+
--spec ".claude/vibe/specs/my-feature.md" \
|
|
698
|
+
--output "./public"
|
|
699
|
+
|
|
700
|
+
# Or with explicit values
|
|
701
|
+
node hooks/scripts/generate-brand-assets.js \
|
|
702
|
+
--name "MyApp" \
|
|
703
|
+
--color "#2F6BFF" \
|
|
704
|
+
--style "modern minimal" \
|
|
705
|
+
--output "./public"
|
|
706
|
+
```
|
|
707
|
+
|
|
708
|
+
**Fallback:** If Gemini Image fails, generates text monogram icon (first letter + primary color).
|
|
709
|
+
|
|
710
|
+
---
|
|
711
|
+
|
|
712
|
+
### 5. Gemini Code Review + Auto-Fix
|
|
647
713
|
|
|
648
714
|
After all scenarios are implemented, **Gemini reviews the code and auto-fixes based on feedback**:
|
|
649
715
|
|
|
@@ -722,7 +788,7 @@ node "$VIBE_SCRIPTS/llm-orchestrate.js" gemini orchestrate-json "Review this cod
|
|
|
722
788
|
- Skip and proceed on fallback response
|
|
723
789
|
- Must re-verify build/tests after fixes
|
|
724
790
|
|
|
725
|
-
###
|
|
791
|
+
### 6. Quality Report (Auto-generated)
|
|
726
792
|
|
|
727
793
|
After all scenarios complete + Gemini review, **quality report is auto-generated**:
|
|
728
794
|
|
|
@@ -767,7 +833,7 @@ After all scenarios complete + Gemini review, **quality report is auto-generated
|
|
|
767
833
|
|
|
768
834
|
**This alone is enough to trust quality.**
|
|
769
835
|
|
|
770
|
-
###
|
|
836
|
+
### 7. Update Feature File
|
|
771
837
|
|
|
772
838
|
Auto-update scenario status:
|
|
773
839
|
|
|
@@ -1004,18 +1070,18 @@ Score = Σ(checked items × weight) / 100
|
|
|
1004
1070
|
|
|
1005
1071
|
Grades:
|
|
1006
1072
|
- 95-100: ✅ EXCELLENT - Ready to merge
|
|
1007
|
-
-
|
|
1008
|
-
-
|
|
1009
|
-
- 0-
|
|
1073
|
+
- 90-94: ⚠️ GOOD - Minor improvements required before merge
|
|
1074
|
+
- 80-89: ⚠️ FAIR - Significant improvements required
|
|
1075
|
+
- 0-79: ❌ POOR - Major fixes needed
|
|
1010
1076
|
```
|
|
1011
1077
|
|
|
1012
1078
|
### Quality Gate Thresholds
|
|
1013
1079
|
|
|
1014
1080
|
| Gate | Minimum Score | Condition |
|
|
1015
1081
|
|------|---------------|-----------|
|
|
1016
|
-
| **Scenario Complete** |
|
|
1017
|
-
| **Phase Complete** |
|
|
1018
|
-
| **Feature Complete** |
|
|
1082
|
+
| **Scenario Complete** | 95 | Each scenario must score ≥95 |
|
|
1083
|
+
| **Phase Complete** | 95 | Average of all scenarios ≥95 |
|
|
1084
|
+
| **Feature Complete** | 95 | All phases complete + Gemini review |
|
|
1019
1085
|
|
|
1020
1086
|
### Auto-Fix Triggers
|
|
1021
1087
|
|