agestra 4.10.5 → 4.12.0

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.
Files changed (39) hide show
  1. package/.claude-plugin/marketplace.json +1 -1
  2. package/.claude-plugin/plugin.json +1 -1
  3. package/.gemini/commands/agestra/implement.toml +3 -2
  4. package/AGENTS.md +1 -1
  5. package/GEMINI.md +1 -1
  6. package/README.ja.md +11 -3
  7. package/README.ko.md +12 -2
  8. package/README.md +19 -7
  9. package/README.zh.md +11 -3
  10. package/agents/agestra-designer.md +139 -138
  11. package/agents/agestra-ideator.md +163 -162
  12. package/agents/agestra-implementer.md +76 -0
  13. package/agents/agestra-moderator.md +106 -96
  14. package/agents/agestra-qa.md +215 -215
  15. package/agents/agestra-reviewer.md +132 -132
  16. package/agents/agestra-team-lead.md +455 -446
  17. package/commands/design.md +13 -18
  18. package/commands/idea.md +34 -74
  19. package/commands/implement.md +32 -10
  20. package/commands/review.md +30 -28
  21. package/commands/setup.md +1 -1
  22. package/dist/bundle.js +149 -145
  23. package/hooks/user-prompt-submit.js +95 -11
  24. package/package.json +11 -2
  25. package/scripts/host-assets/codex-assets.mjs +200 -0
  26. package/scripts/host-assets/gemini-assets.mjs +341 -0
  27. package/scripts/host-assets/manifest.mjs +211 -0
  28. package/scripts/install-host-mcp.mjs +195 -24
  29. package/scripts/uninstall-host-mcp.mjs +122 -8
  30. package/skills/build-fix.md +76 -76
  31. package/skills/cancel.md +66 -66
  32. package/skills/design.md +10 -10
  33. package/skills/idea.md +11 -11
  34. package/skills/leader.md +162 -0
  35. package/skills/provider-guide.md +196 -191
  36. package/skills/review.md +11 -11
  37. package/skills/setup.md +18 -18
  38. package/skills/trace.md +62 -62
  39. package/skills/worker-manage.md +75 -75
@@ -12,7 +12,7 @@
12
12
  "name": "agestra",
13
13
  "source": "./",
14
14
  "description": "Orchestrate Ollama, Gemini, and Codex for multi-AI debates, code review, and cross-validation",
15
- "version": "4.10.5",
15
+ "version": "4.12.0",
16
16
  "author": {
17
17
  "name": "mua-vtuber"
18
18
  },
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "agestra",
3
- "version": "4.10.5",
3
+ "version": "4.12.0",
4
4
  "description": "Claude Code plugin — orchestrate Ollama, Gemini, and Codex for multi-AI debates, code review, and cross-validation",
5
5
  "mcpServers": {
6
6
  "agestra": {
@@ -9,8 +9,9 @@ Use the shared workflow spec below as the source of truth and adapt it to the cu
9
9
  @{commands/implement.md}
10
10
 
11
11
  Gemini-specific rules:
12
- - Start with `environment_check` and `provider_list`.
12
+ - Start with `setup_status`, then `environment_check` and `provider_list`.
13
13
  - Prefer Agestra MCP tools and worker orchestration over ad-hoc shell-heavy implementation plans.
14
- - Translate Claude-specific wording into leader-host wording when Gemini is the active host.
14
+ - Treat "Leader-host only" as the Gemini-led local path when Gemini is the active host.
15
+ - Use the shared `agestra-implementer` role semantics for host-local code edits.
15
16
  - Keep the final answer in the user's language.
16
17
  """
package/AGENTS.md CHANGED
@@ -13,7 +13,7 @@ This repository includes a Codex-friendly host wrapper for Agestra.
13
13
  - Treat `commands/*.md` as the source of truth for Agestra workflows.
14
14
  - When the user asks for review, design, idea, or implementation help, start with `environment_check` and `provider_list`.
15
15
  - Prefer Agestra MCP tools over ad-hoc multi-provider prompting.
16
- - If a workflow mentions "Claude only", interpret that as the current leader-host-only path when Claude is not the active host.
16
+ - If any legacy workflow text mentions "Claude only", interpret that as the current leader-host-only path when Claude is not the active host.
17
17
 
18
18
  ## Workflow Mapping
19
19
 
package/GEMINI.md CHANGED
@@ -24,7 +24,7 @@ Each command delegates to the shared workflow specs in `commands/*.md`.
24
24
  - Start orchestration requests with `environment_check` and `provider_list`.
25
25
  - Prefer Agestra MCP tools instead of rebuilding workflows in free-form prompts.
26
26
  - Treat `commands/*.md` and `agents/*.md` as the canonical workflow and role assets.
27
- - If a shared workflow mentions "Claude only", translate that to the current leader-host-only path when Gemini is the active host.
27
+ - If any legacy shared workflow text mentions "Claude only", translate that to the current leader-host-only path when Gemini is the active host.
28
28
 
29
29
  ## Core MCP Tools
30
30
 
package/README.ja.md CHANGED
@@ -84,7 +84,7 @@ Gemini ではリポジトリ直下の [GEMINI.md](GEMINI.md) と、[`.gemini/com
84
84
  | `/agestra setup` | 初期 AI プロバイダー選択とセットアップ |
85
85
  | `/agestra implement [task]` | Claude only または Multi-AI モードで実装を進める |
86
86
 
87
- 外部プロバイダーが利用可能な場合、テキストコマンド(review、design、idea)は直接ディベートモードに入り、マルチ AI クロスバリデーションを行います。プロバイダーが検出されない場合、Claude が自動的に単独で作業します。
87
+ 外部プロバイダーが利用可能な場合、テキストコマンド(review、design、idea)は直接徹底討論モードに入り、マルチ AI クロスバリデーションを行います。プロバイダーが検出されない場合、Claude が自動的に単独で作業します。
88
88
 
89
89
  ## エージェント
90
90
 
@@ -106,8 +106,11 @@ Gemini ではリポジトリ直下の [GEMINI.md](GEMINI.md) と、[`.gemini/com
106
106
  | `cancel` | ワーカー、ディベート、チェーン、タスクの安全な停止 |
107
107
  | `build-fix` | build/typecheck/lint エラーの自動診断と修正 |
108
108
  | `trace` | エージェント実行タイムラインとフローダイアグラムの表示 |
109
+ | `setup` | 初期プロバイダー選択と `providers.config.json` 書き込み |
109
110
  | `design` | Multi-AI モード選択を含む設計探索ワークフロー |
110
111
  | `idea` | Multi-AI モード選択を含む改善案発見ワークフロー |
112
+ | `review` | Multi-AI モード選択を含むコード品質・セキュリティ・ハードコーディングレビューワークフロー |
113
+ | `leader` | マルチAI/プロバイダーオーケストレーションのエントリーポイント — 明示的なプロバイダー、ディベート、合意形成、相互検証シグナルを検知し、ドメイン分類後 `agestra-team-lead` へ委譲 |
111
114
 
112
115
  ---
113
116
 
@@ -137,7 +140,7 @@ Turborepo モノレポで、9 パッケージ構成です:
137
140
 
138
141
  ### 作業モード
139
142
 
140
- **Text work**(レビュー、設計、アイデア): プロバイダーあり → ディベートモード; なし → Claude only
143
+ **Text work**(レビュー、設計、アイデア): プロバイダーあり → 徹底討論モード; なし → Claude only
141
144
 
142
145
  **Implementation work**(team-lead orchestration):
143
146
  - **Claude만으로** — Claude がプロジェクト/グローバルエージェントを使って直接実装します。
@@ -314,7 +317,12 @@ agestra/
314
317
  │ ├── worker-manage.md # CLI ワーカー管理
315
318
  │ ├── cancel.md # 安全な操作キャンセル
316
319
  │ ├── build-fix.md # ビルドエラー自動修復
317
- └── trace.md # 実行タイムラインビューア
320
+ ├── trace.md # 実行タイムラインビューア
321
+ │ ├── setup.md # 初期プロバイダー選択
322
+ │ ├── design.md # 設計探索ワークフロー
323
+ │ ├── idea.md # 改善案発見ワークフロー
324
+ │ ├── review.md # コード品質レビューワークフロー
325
+ │ └── leader.md # マルチAIオーケストレーションルーター
318
326
  ├── hooks/
319
327
  │ └── user-prompt-submit.md # ツール推奨フック
320
328
  ├── dist/
package/README.ko.md CHANGED
@@ -70,6 +70,7 @@ Gemini는 저장소 루트의 [GEMINI.md](GEMINI.md)와 [`.gemini/commands/agest
70
70
 
71
71
  설치 후 Gemini에서 사용할 수 있는 명령:
72
72
 
73
+ - `/agestra:setup`
73
74
  - `/agestra:review`
74
75
  - `/agestra:design`
75
76
  - `/agestra:idea`
@@ -147,8 +148,11 @@ winget install BurntSushi.ripgrep.MSVC
147
148
  | `cancel` | 워커, 토론, 체인, 작업의 정상 종료 |
148
149
  | `build-fix` | 빌드/타입체크/린트 에러 자동 진단 및 수정 |
149
150
  | `trace` | 에이전트 실행 타임라인 및 흐름 다이어그램 조회 |
151
+ | `setup` | 초기 공급자 선택 및 `providers.config.json` 작성 |
150
152
  | `design` | 멀티 AI 모드 선택이 포함된 아키텍처 탐색 워크플로우 |
151
153
  | `idea` | 멀티 AI 모드 선택이 포함된 개선점 발굴 워크플로우 |
154
+ | `review` | 멀티 AI 모드 선택이 포함된 코드 품질·보안·하드코딩 리뷰 워크플로우 |
155
+ | `leader` | 멀티 AI/프로바이더 오케스트레이션 진입점 — 명시적인 프로바이더, 토론, 합의, 교차 검증 신호를 잡아 도메인을 분류한 뒤 `agestra-team-lead`에 위임 |
152
156
 
153
157
  ---
154
158
 
@@ -283,7 +287,7 @@ Turborepo 모노레포, 9개 패키지:
283
287
 
284
288
  ### providers.config.json
285
289
 
286
- `/agestra setup`이 생성합니다. 단일 플러그인 범위 경로에 저장됩니다 (해석 우선순위: `AGESTRA_CONFIG_PATH` 환경변수 → `$CLAUDE_PLUGIN_ROOT/providers.config.json` → `~/.agestra/providers.config.json`). 프로젝트 저장소에 두지 않으며 gitignore에도 등록되어 있습니다.
290
+ `/agestra setup`이 생성합니다. 기본 저장 위치는 호스트 공용 `~/.agestra/providers.config.json`입니다. 해석 우선순위는 `AGESTRA_CONFIG_PATH` 환경변수 → 기존 `~/.agestra/providers.config.json` → 기존 레거시 `$CLAUDE_PLUGIN_ROOT/providers.config.json` → 새 파일용 `~/.agestra/providers.config.json`입니다. 프로젝트 저장소에 두지 않으며 gitignore에도 등록되어 있습니다.
287
291
 
288
292
  | 필드 | 설명 |
289
293
  |------|------|
@@ -334,6 +338,7 @@ agestra/
334
338
  ├── .gemini/
335
339
  │ └── commands/
336
340
  │ └── agestra/
341
+ │ ├── setup.toml # Gemini CLI의 /agestra:setup
337
342
  │ ├── review.toml # Gemini CLI의 /agestra:review
338
343
  │ ├── design.toml # Gemini CLI의 /agestra:design
339
344
  │ ├── idea.toml # Gemini CLI의 /agestra:idea
@@ -355,7 +360,12 @@ agestra/
355
360
  │ ├── worker-manage.md # CLI 워커 관리
356
361
  │ ├── cancel.md # 정상 작업 취소
357
362
  │ ├── build-fix.md # 빌드 에러 자동 수정
358
- └── trace.md # 실행 타임라인 조회
363
+ ├── trace.md # 실행 타임라인 조회
364
+ │ ├── setup.md # 초기 공급자 선택
365
+ │ ├── design.md # 아키텍처 탐색 워크플로우
366
+ │ ├── idea.md # 개선점 발굴 워크플로우
367
+ │ ├── review.md # 코드 품질 리뷰 워크플로우
368
+ │ └── leader.md # 멀티 AI 오케스트레이션 라우터
359
369
  ├── hooks/
360
370
  │ └── user-prompt-submit.md # 도구 추천 hook
361
371
  ├── dist/
package/README.md CHANGED
@@ -70,6 +70,7 @@ Gemini uses the repository-level [GEMINI.md](GEMINI.md) context file plus projec
70
70
 
71
71
  Available Gemini commands after setup:
72
72
 
73
+ - `/agestra:setup`
73
74
  - `/agestra:review`
74
75
  - `/agestra:design`
75
76
  - `/agestra:idea`
@@ -123,15 +124,16 @@ All three hosts drive the same MCP server and shared workflow specs from `comman
123
124
  | `/agestra idea [topic]` | Discover improvements by comparing with similar projects |
124
125
  | `/agestra design [subject]` | Explore architecture and design trade-offs before implementation |
125
126
  | `/agestra setup` | Initial AI provider selection and setup |
126
- | `/agestra implement [task]` | Execute implementation in Claude-only or Multi-AI mode |
127
+ | `/agestra implement [task]` | Execute implementation through Leader-host-only or suggested AI distribution mode |
127
128
 
128
- When external providers are available, text commands (review, design, idea) go directly to debate mode for multi-AI cross-validation. When no providers are detected, Claude works alone automatically.
129
+ When external providers are available, text commands (review, design, idea) go directly to consensus debate mode for multi-AI cross-validation. When no providers are detected, the current leader host works with its local specialist agent automatically. Implementation requests first classify the task and can ask whether to propose an AI task distribution.
129
130
 
130
131
  ## Agents
131
132
 
132
133
  | Agent | Model | Role |
133
134
  |-------|-------|------|
134
135
  | `agestra-team-lead` | Sonnet | Full orchestrator — environment check, quality-based provider routing, work mode selection, CLI worker supervision, QA loop |
136
+ | `agestra-implementer` | Sonnet | Scoped implementation executor — code edits, test updates, local verification |
135
137
  | `agestra-reviewer` | Opus | Strict quality verifier — security, orphans, spec drift, test gaps |
136
138
  | `agestra-designer` | Opus | Architecture explorer — Socratic questioning, trade-off analysis |
137
139
  | `agestra-ideator` | Sonnet | Improvement discoverer — web research, competitive analysis |
@@ -147,8 +149,11 @@ When external providers are available, text commands (review, design, idea) go d
147
149
  | `cancel` | Graceful stop for workers, debates, chains, tasks |
148
150
  | `build-fix` | Auto-diagnose and fix build/typecheck/lint errors |
149
151
  | `trace` | View agent execution timeline and flow diagrams |
152
+ | `setup` | Initial provider selection and `providers.config.json` write |
150
153
  | `design` | Architecture exploration workflow with multi-AI mode selection |
151
154
  | `idea` | Improvement discovery workflow with multi-AI mode selection |
155
+ | `review` | Code quality / security / hardcoding review workflow with multi-AI mode selection |
156
+ | `leader` | Multi-AI/provider orchestration entry — catches explicit provider, debate, consensus, or cross-validation signals, classifies the domain, and hands off to `agestra-team-lead` |
152
157
 
153
158
  ---
154
159
 
@@ -178,11 +183,11 @@ Turborepo monorepo with 9 packages:
178
183
 
179
184
  ### Work Modes
180
185
 
181
- **Text work** (review, design, idea): providers available → debate mode; no providers → Claude only
186
+ **Text work** (review, design, idea): providers available → consensus debate mode; no providers → Leader-host only
182
187
 
183
188
  **Implementation work** (team-lead orchestration):
184
- - **Claude만으로**Claude implements directly with project/global agents.
185
- - **다른 AI 함께**CLI workers (Codex/Gemini) do autonomous coding in isolated git worktrees, Ollama handles simple tasks, Claude supervises and merges.
189
+ - **Leader-host only** `agestra-implementer` applies scoped code changes; reviewer/QA verify.
190
+ - **Suggested AI distribution**the team lead proposes a routing table, asks for approval, then dispatches Codex/Gemini CLI workers for suitable code edits and Ollama for simple/repetitive proposal work.
186
191
 
187
192
  ---
188
193
 
@@ -283,7 +288,7 @@ Turborepo monorepo with 9 packages:
283
288
 
284
289
  ### providers.config.json
285
290
 
286
- Created by `/agestra setup`. The file lives at a single plugin-scoped location (resolution order: `AGESTRA_CONFIG_PATH` env var → `$CLAUDE_PLUGIN_ROOT/providers.config.json` → `~/.agestra/providers.config.json`). It is not meant to sit in the project repo and is gitignored accordingly.
291
+ Created by `/agestra setup`. The default location is the host-shared `~/.agestra/providers.config.json`. Resolution order is `AGESTRA_CONFIG_PATH` env var → existing `~/.agestra/providers.config.json` → existing legacy `$CLAUDE_PLUGIN_ROOT/providers.config.json` → `~/.agestra/providers.config.json` for new writes. It is not meant to sit in the project repo and is gitignored accordingly.
287
292
 
288
293
  | Field | Description |
289
294
  |-------|-------------|
@@ -334,6 +339,7 @@ agestra/
334
339
  ├── .gemini/
335
340
  │ └── commands/
336
341
  │ └── agestra/
342
+ │ ├── setup.toml # /agestra:setup in Gemini CLI
337
343
  │ ├── review.toml # /agestra:review in Gemini CLI
338
344
  │ ├── design.toml # /agestra:design in Gemini CLI
339
345
  │ ├── idea.toml # /agestra:idea in Gemini CLI
@@ -347,6 +353,7 @@ agestra/
347
353
  │ ├── agestra-reviewer.md # Strict quality verifier (Opus)
348
354
  │ ├── agestra-designer.md # Architecture explorer (Opus)
349
355
  │ ├── agestra-ideator.md # Improvement discoverer (Sonnet)
356
+ │ ├── agestra-implementer.md # Scoped implementation executor (Sonnet)
350
357
  │ ├── agestra-moderator.md # Multi-mode facilitator (Sonnet)
351
358
  │ ├── agestra-qa.md # QA verifier (Opus, no code writes)
352
359
  │ └── agestra-team-lead.md # Full orchestrator (Sonnet, no code writes)
@@ -355,7 +362,12 @@ agestra/
355
362
  │ ├── worker-manage.md # CLI worker management
356
363
  │ ├── cancel.md # Graceful operation cancellation
357
364
  │ ├── build-fix.md # Build error auto-repair
358
- └── trace.md # Execution timeline viewer
365
+ ├── trace.md # Execution timeline viewer
366
+ │ ├── setup.md # Initial provider selection
367
+ │ ├── design.md # Architecture exploration workflow
368
+ │ ├── idea.md # Improvement discovery workflow
369
+ │ ├── review.md # Code quality review workflow
370
+ │ └── leader.md # Multi-AI orchestration entry router
359
371
  ├── hooks/
360
372
  │ └── user-prompt-submit.md # Tool recommendation hook
361
373
  ├── dist/
package/README.zh.md CHANGED
@@ -84,7 +84,7 @@ Gemini 会结合仓库根目录下的 [GEMINI.md](GEMINI.md) 与 [`.gemini/comma
84
84
  | `/agestra setup` | 初始 AI 提供方选择与设置 |
85
85
  | `/agestra implement [task]` | 以 Claude only 或 Multi-AI 模式执行实现 |
86
86
 
87
- 当外部提供方可用时,文本命令(review、design、idea)直接进入辩论模式,进行多 AI 交叉验证。当未检测到提供方时,Claude 自动独立工作。
87
+ 当外部提供方可用时,文本命令(review、design、idea)直接进入终极辩论模式,进行多 AI 交叉验证。当未检测到提供方时,Claude 自动独立工作。
88
88
 
89
89
  ## 代理
90
90
 
@@ -106,8 +106,11 @@ Gemini 会结合仓库根目录下的 [GEMINI.md](GEMINI.md) 与 [`.gemini/comma
106
106
  | `cancel` | 安全停止 worker、辩论、链路和任务 |
107
107
  | `build-fix` | 自动诊断并修复 build/typecheck/lint 错误 |
108
108
  | `trace` | 查看代理执行时间线与流程图 |
109
+ | `setup` | 初始提供方选择与 `providers.config.json` 写入 |
109
110
  | `design` | 包含 Multi-AI 模式选择的架构探索工作流 |
110
111
  | `idea` | 包含 Multi-AI 模式选择的改进发现工作流 |
112
+ | `review` | 包含 Multi-AI 模式选择的代码质量·安全·硬编码审查工作流 |
113
+ | `leader` | 多AI/提供方编排入口 — 捕获明确的提供方、辩论、共识或交叉验证信号,进行领域分类后委托给 `agestra-team-lead` |
111
114
 
112
115
  ---
113
116
 
@@ -137,7 +140,7 @@ Gemini 会结合仓库根目录下的 [GEMINI.md](GEMINI.md) 与 [`.gemini/comma
137
140
 
138
141
  ### 工作模式
139
142
 
140
- **文本工作**(review、design、idea):有提供方 → 辩论模式;无提供方 → Claude only
143
+ **文本工作**(review、design、idea):有提供方 → 终极辩论模式;无提供方 → Claude only
141
144
 
142
145
  **实现工作**(team-lead orchestration):
143
146
  - **Claude만으로** — Claude 直接结合项目/全局代理完成实现。
@@ -314,7 +317,12 @@ agestra/
314
317
  │ ├── worker-manage.md # CLI Worker 管理
315
318
  │ ├── cancel.md # 安全取消操作
316
319
  │ ├── build-fix.md # 构建错误自动修复
317
- └── trace.md # 执行时间线查看器
320
+ ├── trace.md # 执行时间线查看器
321
+ │ ├── setup.md # 初始提供方选择
322
+ │ ├── design.md # 架构探索工作流
323
+ │ ├── idea.md # 改进发现工作流
324
+ │ ├── review.md # 代码质量审查工作流
325
+ │ └── leader.md # 多AI 编排路由器
318
326
  ├── hooks/
319
327
  │ └── user-prompt-submit.md # 工具推荐 hook
320
328
  ├── dist/
@@ -1,138 +1,139 @@
1
- ---
2
- name: agestra-designer
3
- description: |
4
- Pre-implementation design explorer using Socratic questioning. Explores architecture,
5
- discusses design trade-offs, and establishes direction before coding.
6
-
7
- <example>
8
- Context: User needs to plan architecture before implementing
9
- user: "이 기능 어떻게 설계하면 좋을까?"
10
- assistant: "I'll use the agestra-designer agent to explore architecture approaches."
11
- <commentary>
12
- User wants design exploration before coding — designer asks clarifying questions and proposes approaches.
13
- </commentary>
14
- </example>
15
-
16
- <example>
17
- Context: User is comparing implementation approaches
18
- user: "REST vs GraphQL, 어떤 방향으로 가야할지 고민이야"
19
- assistant: "I'll use the agestra-designer agent to analyze trade-offs between the approaches."
20
- <commentary>
21
- Design trade-off discussion — designer explores pros/cons of each approach.
22
- </commentary>
23
- </example>
24
- model: opus
25
- color: blue
26
- ---
27
-
28
- <Role>
29
- You are a pre-implementation design explorer. Your job is to help the user find the right architecture before any code is written. You use Socratic questioning to understand intent, explore the codebase for existing patterns, propose multiple approaches with trade-offs, and produce a design document.
30
- </Role>
31
-
32
- <Scope>
33
- You design features and systems **for the current project** (the codebase you're running in). If the user's request is outside this project's scope — a new product idea, a business question, or something unrelated to this codebase — say so directly:
34
-
35
- > "This is outside the current project's scope. I design features within this codebase. If you're looking for project ideas, try `/agestra idea` instead."
36
-
37
- Do not attempt to design something that cannot be implemented in the current codebase.
38
- </Scope>
39
-
40
- <Workflow>
41
- Follow these phases in order. Do not skip phases.
42
-
43
- ### Phase 1: Understand (Clarity Gate)
44
-
45
- Before asking questions, check if the request is already clear. If it includes specific file paths, function names, or concrete acceptance criteria, score immediately — skip the interview if ambiguity is already low.
46
-
47
- **Clarity Dimensions:**
48
-
49
- | Dimension | Weight (greenfield) | Weight (brownfield) |
50
- |-----------|-------------------|-------------------|
51
- | Goal | 40% | 35% |
52
- | Constraints | 30% | 25% |
53
- | Success Criteria | 30% | 25% |
54
- | Context | N/A | 15% |
55
-
56
- Greenfield: no relevant source code exists for the feature.
57
- Brownfield: modifying or extending existing code.
58
-
59
- **After each user answer:**
60
- 1. Score all dimensions 0.0–1.0
61
- 2. Calculate: `ambiguity = 1 - weighted_sum`
62
- 3. Display progress to the user:
63
- ```
64
- Round {n} | Ambiguity: {score}% | Targeting: {weakest dimension}
65
- ```
66
- 4. If ambiguity <= 20% → proceed to Phase 2
67
- 5. If ambiguity > 20% → ask the next question targeting the WEAKEST dimension
68
-
69
- **Question targeting:** Always target the dimension with the lowest score. Ask ONE question at a time. Expose assumptions, not feature lists.
70
-
71
- | Dimension | Question Style |
72
- |-----------|---------------|
73
- | Goal | "What exactly happens when...?" / "What specific action does a user take first?" |
74
- | Constraints | "What are the boundaries?" / "Should this work offline?" |
75
- | Success Criteria | "How do we know it works?" / "What would make you say 'yes, that's it'?" |
76
- | Context (brownfield) | "How does this fit with existing...?" / "Extend or replace?" |
77
-
78
- **Challenge modes** (each used once, then return to normal):
79
- - Round 4+: **Contrarian** "What if the opposite were true? What if this constraint doesn't actually exist?"
80
- - Round 6+: **Simplifier** — "What's the simplest version that would still be valuable?"
81
- - Round 8+: **Ontologist** (if ambiguity still > 30%) "What IS this, really? One sentence."
82
-
83
- **Soft limits:**
84
- - Round 3+: allow early exit if user says "enough" — show ambiguity warning
85
- - Round 10: soft warning "We're at 10 rounds. Current ambiguity: {score}%. Continue or proceed?"
86
- - Round 20: hard capproceed with current clarity, note the risk
87
-
88
- ### Phase 2: Explore
89
- Search the codebase for relevant existing patterns:
90
- - Use Glob to find related files by name
91
- - Use Grep to find similar implementations
92
- - Use Read to understand existing architecture
93
- - Note conventions: naming, file organization, patterns used
94
-
95
- ### Phase 3: Propose
96
- Present 2-3 distinct approaches. For each:
97
- - **Approach name** one-line summary
98
- - **How it works** — architecture overview
99
- - **Fits with** — which existing patterns it aligns with
100
- - **Trade-offs** — pros and cons
101
- - **Effort** — relative complexity (low/medium/high)
102
-
103
- ### Phase 4: Refine
104
- Based on user feedback:
105
- - Deep-dive into the selected approach
106
- - Address concerns raised
107
- - Detail component boundaries and data flow
108
- - Identify risks and mitigation
109
-
110
- ### Phase 5: Document
111
- Write a design document to `docs/plans/` with this structure:
112
-
113
- ```markdown
114
- # [Feature/System Name] Design
115
-
116
- ## Problem
117
- ## Approach
118
- ## Architecture
119
- ## Components
120
- ## Data Flow
121
- ## Trade-offs & Decisions
122
- ## Open Questions
123
- ## Implementation Steps
124
- ```
125
- </Workflow>
126
-
127
- <Constraints>
128
- - Ask one question at a time. Do not dump multiple questions.
129
- - Present approaches before solutions. Let the user choose direction.
130
- - Always explore the codebase before proposing do not design in a vacuum.
131
- - Document all decisions made during the conversation in the final design document.
132
- - Do not write implementation code. Design documents only.
133
- - Communicate in the user's language.
134
- </Constraints>
135
-
136
- <Output_Format>
137
- Your final deliverable is a design document in `docs/plans/` following the template above. The document should be self-contained — someone reading it without conversation context should understand the design fully.
138
- </Output_Format>
1
+ ---
2
+ name: agestra-designer
3
+ description: |
4
+ Pre-implementation design explorer using Socratic questioning. Explores architecture,
5
+ discusses design trade-offs, and establishes direction before coding.
6
+
7
+ <example>
8
+ Context: User needs to plan architecture before implementing
9
+ user: "이 기능 어떻게 설계하면 좋을까?"
10
+ assistant: "I'll use the agestra-designer agent to explore architecture approaches."
11
+ <commentary>
12
+ User wants design exploration before coding — designer asks clarifying questions and proposes approaches.
13
+ </commentary>
14
+ </example>
15
+
16
+ <example>
17
+ Context: User is comparing implementation approaches
18
+ user: "REST vs GraphQL, 어떤 방향으로 가야할지 고민이야"
19
+ assistant: "I'll use the agestra-designer agent to analyze trade-offs between the approaches."
20
+ <commentary>
21
+ Design trade-off discussion — designer explores pros/cons of each approach.
22
+ </commentary>
23
+ </example>
24
+ model: opus
25
+ color: blue
26
+ disallowedTools: Edit, NotebookEdit
27
+ ---
28
+
29
+ <Role>
30
+ You are a pre-implementation design explorer. Your job is to help the user find the right architecture before any code is written. You use Socratic questioning to understand intent, explore the codebase for existing patterns, propose multiple approaches with trade-offs, and produce a design document.
31
+ </Role>
32
+
33
+ <Scope>
34
+ You design features and systems **for the current project** (the codebase you're running in). If the user's request is outside this project's scope — a new product idea, a business question, or something unrelated to this codebase — say so directly:
35
+
36
+ > "This is outside the current project's scope. I design features within this codebase. If you're looking for project ideas, try `/agestra idea` instead."
37
+
38
+ Do not attempt to design something that cannot be implemented in the current codebase.
39
+ </Scope>
40
+
41
+ <Workflow>
42
+ Follow these phases in order. Do not skip phases.
43
+
44
+ ### Phase 1: Understand (Clarity Gate)
45
+
46
+ Before asking questions, check if the request is already clear. If it includes specific file paths, function names, or concrete acceptance criteria, score immediately — skip the interview if ambiguity is already low.
47
+
48
+ **Clarity Dimensions:**
49
+
50
+ | Dimension | Weight (greenfield) | Weight (brownfield) |
51
+ |-----------|-------------------|-------------------|
52
+ | Goal | 40% | 35% |
53
+ | Constraints | 30% | 25% |
54
+ | Success Criteria | 30% | 25% |
55
+ | Context | N/A | 15% |
56
+
57
+ Greenfield: no relevant source code exists for the feature.
58
+ Brownfield: modifying or extending existing code.
59
+
60
+ **After each user answer:**
61
+ 1. Score all dimensions 0.0–1.0
62
+ 2. Calculate: `ambiguity = 1 - weighted_sum`
63
+ 3. Display progress to the user:
64
+ ```
65
+ Round {n} | Ambiguity: {score}% | Targeting: {weakest dimension}
66
+ ```
67
+ 4. If ambiguity <= 20% → proceed to Phase 2
68
+ 5. If ambiguity > 20% → ask the next question targeting the WEAKEST dimension
69
+
70
+ **Question targeting:** Always target the dimension with the lowest score. Ask ONE question at a time. Expose assumptions, not feature lists.
71
+
72
+ | Dimension | Question Style |
73
+ |-----------|---------------|
74
+ | Goal | "What exactly happens when...?" / "What specific action does a user take first?" |
75
+ | Constraints | "What are the boundaries?" / "Should this work offline?" |
76
+ | Success Criteria | "How do we know it works?" / "What would make you say 'yes, that's it'?" |
77
+ | Context (brownfield) | "How does this fit with existing...?" / "Extend or replace?" |
78
+
79
+ **Challenge modes** (each used once, then return to normal):
80
+ - Round 4+: **Contrarian** — "What if the opposite were true? What if this constraint doesn't actually exist?"
81
+ - Round 6+: **Simplifier** "What's the simplest version that would still be valuable?"
82
+ - Round 8+: **Ontologist** (if ambiguity still > 30%) — "What IS this, really? One sentence."
83
+
84
+ **Soft limits:**
85
+ - Round 3+: allow early exit if user says "enough" show ambiguity warning
86
+ - Round 10: soft warning"We're at 10 rounds. Current ambiguity: {score}%. Continue or proceed?"
87
+ - Round 20: hard cap — proceed with current clarity, note the risk
88
+
89
+ ### Phase 2: Explore
90
+ Search the codebase for relevant existing patterns:
91
+ - Use Glob to find related files by name
92
+ - Use Grep to find similar implementations
93
+ - Use Read to understand existing architecture
94
+ - Note conventions: naming, file organization, patterns used
95
+
96
+ ### Phase 3: Propose
97
+ Present 2-3 distinct approaches. For each:
98
+ - **Approach name** — one-line summary
99
+ - **How it works** — architecture overview
100
+ - **Fits with** — which existing patterns it aligns with
101
+ - **Trade-offs** — pros and cons
102
+ - **Effort** — relative complexity (low/medium/high)
103
+
104
+ ### Phase 4: Refine
105
+ Based on user feedback:
106
+ - Deep-dive into the selected approach
107
+ - Address concerns raised
108
+ - Detail component boundaries and data flow
109
+ - Identify risks and mitigation
110
+
111
+ ### Phase 5: Document
112
+ Write a design document to `docs/plans/` with this structure:
113
+
114
+ ```markdown
115
+ # [Feature/System Name] Design
116
+
117
+ ## Problem
118
+ ## Approach
119
+ ## Architecture
120
+ ## Components
121
+ ## Data Flow
122
+ ## Trade-offs & Decisions
123
+ ## Open Questions
124
+ ## Implementation Steps
125
+ ```
126
+ </Workflow>
127
+
128
+ <Constraints>
129
+ - Ask one question at a time. Do not dump multiple questions.
130
+ - Present approaches before solutions. Let the user choose direction.
131
+ - Always explore the codebase before proposing do not design in a vacuum.
132
+ - Document all decisions made during the conversation in the final design document.
133
+ - Do not write implementation code. Design documents only.
134
+ - Communicate in the user's language.
135
+ </Constraints>
136
+
137
+ <Output_Format>
138
+ Your final deliverable is a design document in `docs/plans/` following the template above. The document should be self-contained — someone reading it without conversation context should understand the design fully.
139
+ </Output_Format>