selfish-pipeline 1.1.0 → 1.2.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 (55) hide show
  1. package/.claude-plugin/marketplace.json +4 -4
  2. package/.claude-plugin/plugin.json +3 -5
  3. package/MIGRATION.md +46 -46
  4. package/README.md +20 -13
  5. package/agents/selfish-architect.md +8 -2
  6. package/agents/selfish-security.md +9 -2
  7. package/bin/cli.mjs +20 -20
  8. package/commands/analyze.md +76 -77
  9. package/commands/architect.md +90 -85
  10. package/commands/auto.md +231 -173
  11. package/commands/checkpoint.md +51 -51
  12. package/commands/clarify.md +53 -53
  13. package/commands/debug.md +69 -63
  14. package/commands/doctor.md +166 -0
  15. package/commands/implement.md +151 -95
  16. package/commands/init.md +195 -61
  17. package/commands/plan.md +114 -98
  18. package/commands/principles.md +62 -62
  19. package/commands/research.md +62 -62
  20. package/commands/resume.md +48 -47
  21. package/commands/review.md +135 -83
  22. package/commands/security.md +77 -76
  23. package/commands/spec.md +99 -83
  24. package/commands/tasks.md +84 -65
  25. package/commands/test.md +123 -0
  26. package/docs/critic-loop-rules.md +97 -0
  27. package/docs/nfr-templates.md +40 -0
  28. package/docs/phase-gate-protocol.md +44 -0
  29. package/hooks/hooks.json +36 -19
  30. package/package.json +3 -2
  31. package/scripts/pre-compact-checkpoint.sh +37 -33
  32. package/scripts/selfish-auto-format.sh +11 -11
  33. package/scripts/selfish-bash-guard.sh +33 -23
  34. package/scripts/selfish-config-change.sh +13 -13
  35. package/scripts/selfish-failure-hint.sh +23 -23
  36. package/scripts/selfish-notify.sh +19 -17
  37. package/scripts/selfish-parallel-validate.sh +158 -0
  38. package/scripts/selfish-permission-request.sh +18 -17
  39. package/scripts/selfish-pipeline-manage.sh +74 -11
  40. package/scripts/selfish-preflight-check.sh +102 -0
  41. package/scripts/selfish-session-end.sh +15 -15
  42. package/scripts/selfish-stop-gate.sh +31 -16
  43. package/scripts/selfish-subagent-context.sh +29 -15
  44. package/scripts/selfish-subagent-stop.sh +14 -14
  45. package/scripts/selfish-task-completed-gate.sh +17 -14
  46. package/scripts/selfish-teammate-idle.sh +13 -10
  47. package/scripts/selfish-timeline-log.sh +97 -0
  48. package/scripts/selfish-user-prompt-submit.sh +7 -7
  49. package/scripts/session-start-context.sh +20 -16
  50. package/scripts/track-selfish-changes.sh +13 -13
  51. package/templates/selfish.config.express-api.md +32 -32
  52. package/templates/selfish.config.monorepo.md +41 -41
  53. package/templates/selfish.config.nextjs-fsd.md +37 -37
  54. package/templates/selfish.config.react-spa.md +26 -26
  55. package/templates/selfish.config.template.md +37 -37
@@ -5,15 +5,15 @@
5
5
  "email": "relee6203@gmail.com"
6
6
  },
7
7
  "metadata": {
8
- "description": "Claude Code 전용 자동화 파이프라인 — spec → plan → tasks → implement → review → clean",
9
- "version": "1.1.0"
8
+ "description": "Automated pipeline for Claude Code — spec → plan → tasks → implement → review → clean",
9
+ "version": "1.2.0"
10
10
  },
11
11
  "plugins": [
12
12
  {
13
13
  "name": "selfish",
14
14
  "source": "./",
15
- "description": "Claude Code 전용 자동화 파이프라인. spec → plan → tasks → implement → review → clean 전체 개발 사이클을 자동화합니다.",
16
- "version": "1.1.0",
15
+ "description": "Automated pipeline for Claude Code. Automates the full development cycle: spec → plan → tasks → implement → review → clean.",
16
+ "version": "1.2.0",
17
17
  "category": "automation",
18
18
  "tags": ["pipeline", "automation", "spec", "plan", "implement", "review", "critic-loop"]
19
19
  }
@@ -1,13 +1,11 @@
1
1
  {
2
2
  "name": "selfish",
3
- "version": "1.1.0",
4
- "description": "Claude Code 전용 자동화 파이프라인. spec → plan → tasks → implement → review → clean 전체 개발 사이클을 자동화합니다.",
3
+ "version": "1.2.0",
4
+ "description": "Automated pipeline for Claude Code. Automates the full development cycle: spec → plan → tasks → implement → review → clean.",
5
5
  "author": { "name": "jhlee0409", "email": "relee6203@gmail.com" },
6
6
  "homepage": "https://github.com/jhlee0409/selfish-pipeline",
7
7
  "repository": "https://github.com/jhlee0409/selfish-pipeline",
8
8
  "license": "MIT",
9
9
  "keywords": ["pipeline", "automation", "spec", "plan", "implement", "review", "critic-loop"],
10
- "commands": "./commands/",
11
- "hooks": "./hooks/hooks.json",
12
- "agents": "./agents/"
10
+ "commands": "./commands/"
13
11
  }
package/MIGRATION.md CHANGED
@@ -1,27 +1,27 @@
1
1
  # Migration Guide: install.sh → Plugin
2
2
 
3
- > 기존 `git clone` + `install.sh` 방식에서 Claude Code 플러그인 방식으로 마이그레이션하는 가이드입니다.
3
+ > A guide for migrating from the `git clone` + `install.sh` approach to the Claude Code plugin system.
4
4
 
5
- ## 변경 요약
5
+ ## Summary of Changes
6
6
 
7
- | 항목 | 이전 | 이후 |
8
- |------|------|------|
9
- | 설치 | `git clone` + `./install.sh` | `/plugin install <url>` |
10
- | 커맨드 구분자 | `.` (`/selfish.spec`) | `:` (`/selfish:spec`) |
11
- | 커맨드 위치 | `~/.claude/commands/selfish.*.md` | 플러그인 내 `commands/*.md` |
12
- | Hook 스크립트 | `<project>/.claude/hooks/*.sh` | 플러그인 내 `scripts/*.sh` |
13
- | Hook 설정 | `<project>/.claude/settings.json` | 플러그인 내 `hooks/hooks.json` |
14
- | 설정 파일 | `.claude/selfish.config.md` (변경 없음) | `.claude/selfish.config.md` (변경 없음) |
7
+ | Item | Before | After |
8
+ |------|--------|-------|
9
+ | Installation | `git clone` + `./install.sh` | `/plugin install <url>` |
10
+ | Command separator | `.` (`/selfish.spec`) | `:` (`/selfish:spec`) |
11
+ | Command location | `~/.claude/commands/selfish.*.md` | `commands/*.md` inside the plugin |
12
+ | Hook scripts | `<project>/.claude/hooks/*.sh` | `scripts/*.sh` inside the plugin |
13
+ | Hook config | `<project>/.claude/settings.json` | `hooks/hooks.json` inside the plugin |
14
+ | Config file | `.claude/selfish.config.md` (unchanged) | `.claude/selfish.config.md` (unchanged) |
15
15
 
16
- ## 마이그레이션 절차
16
+ ## Migration Steps
17
17
 
18
- ### 1. 기존 파일 정리
18
+ ### 1. Clean Up Existing Files
19
19
 
20
20
  ```bash
21
- # 기존 커맨드 파일 삭제 (유저 레벨)
21
+ # Remove existing command files (user level)
22
22
  rm -f ~/.claude/commands/selfish.*.md
23
23
 
24
- # 기존 hook 스크립트 삭제 (프로젝트 레벨)
24
+ # Remove existing hook scripts (project level)
25
25
  rm -f .claude/hooks/session-start-context.sh
26
26
  rm -f .claude/hooks/pre-compact-checkpoint.sh
27
27
  rm -f .claude/hooks/track-selfish-changes.sh
@@ -29,72 +29,72 @@ rm -f .claude/hooks/selfish-stop-gate.sh
29
29
  rm -f .claude/hooks/selfish-pipeline-manage.sh
30
30
  ```
31
31
 
32
- ### 2. settings.json에서 selfish hook 제거
32
+ ### 2. Remove selfish hooks from settings.json
33
33
 
34
- `.claude/settings.json`에서 selfish 관련 hook 항목을 제거합니다.
35
- 플러그인이 자체 `hooks.json`으로 hook을 등록하므로 settings.json에서의 수동 설정이 불필요합니다.
34
+ Remove selfish-related hook entries from `.claude/settings.json`.
35
+ Since the plugin registers hooks via its own `hooks.json`, manual configuration in settings.json is no longer needed.
36
36
 
37
- 제거 대상 (settings.json):
37
+ Items to remove (from settings.json):
38
38
  - `SessionStart` → `session-start-context.sh`
39
39
  - `PreCompact` → `pre-compact-checkpoint.sh`
40
40
  - `PostToolUse` → `track-selfish-changes.sh`
41
41
  - `Stop` → `selfish-stop-gate.sh`
42
42
 
43
- > 다른 프로젝트 고유 hook이 settings.json 있다면 그것은 유지하세요.
43
+ > If you have other project-specific hooks in settings.json, keep those as they are.
44
44
 
45
- ### 3. 플러그인 설치
45
+ ### 3. Install the Plugin
46
46
 
47
47
  ```bash
48
48
  npx selfish-pipeline
49
49
  ```
50
50
 
51
- 또는 수동으로:
51
+ Or manually:
52
52
 
53
53
  ```bash
54
54
  claude plugin marketplace add jhlee0409/selfish-pipeline
55
55
  claude plugin install selfish@selfish-pipeline --scope user
56
56
  ```
57
57
 
58
- 기존 `install.sh`의 `--commands-only`에 해당하는 것은 **User** 스코프, 공유는 **Project** 스코프입니다.
58
+ The equivalent of `install.sh --commands-only` is the **User** scope; for team sharing, use the **Project** scope.
59
59
 
60
- ### 4. 커맨드명 변경
60
+ ### 4. Command Name Changes
61
61
 
62
- 모든 커맨드의 구분자가 `.`에서 `:`로 변경되었습니다:
62
+ The separator for all commands has changed from `.` to `:`:
63
63
 
64
64
  ```text
65
- # 이전
66
- /selfish.auto "기능 설명"
67
- /selfish.spec "기능 설명"
65
+ # Before
66
+ /selfish.auto "feature description"
67
+ /selfish.spec "feature description"
68
68
  /selfish.plan
69
69
 
70
- # 이후
71
- /selfish:auto "기능 설명"
72
- /selfish:spec "기능 설명"
70
+ # After
71
+ /selfish:auto "feature description"
72
+ /selfish:spec "feature description"
73
73
  /selfish:plan
74
74
  ```
75
75
 
76
- ### 5. 설정 파일 확인
76
+ ### 5. Verify Config File
77
77
 
78
- `.claude/selfish.config.md`는 **변경 없이 그대로 사용 가능**합니다.
78
+ `.claude/selfish.config.md` can be **used as-is without any changes**.
79
79
 
80
- 신규 프로젝트라면 `/selfish:init`으로 자동 생성할 수 있습니다.
80
+ For new projects, you can auto-generate it with `/selfish:init`.
81
81
 
82
- ## 변경되지 않는
82
+ ## What Stays the Same
83
83
 
84
- - `.claude/selfish.config.md` 파일 형식 경로
85
- - `specs/{feature}/` 아티팩트 경로
86
- - `memory/` 참조 (checkpoint, principles, research, decisions)
87
- - `.selfish-*` 상태 파일 경로
88
- - `git tag selfish/pre-*` 안전 태그
89
- - hook 스크립트 내부 로직
84
+ - `.claude/selfish.config.md` file format and path
85
+ - `specs/{feature}/` artifact paths
86
+ - `memory/` references (checkpoint, principles, research, decisions)
87
+ - `.selfish-*` state file paths
88
+ - `git tag selfish/pre-*` safety tags
89
+ - Internal logic of hook scripts
90
90
 
91
91
  ## FAQ
92
92
 
93
- **Q: 기존 프로젝트의 `.claude/selfish.config.md`를 다시 만들어야 하나요?**
94
- A: 아니요. 설정 파일 형식은 동일합니다. 그대로 사용하세요.
93
+ **Q: Do I need to recreate `.claude/selfish.config.md` for existing projects?**
94
+ A: No. The config file format is the same. Use it as-is.
95
95
 
96
- **Q: 여러 프로젝트에서 사용 중인데, 프로젝트마다 마이그레이션해야 하나요?**
97
- A: 플러그인은 번만 설치하면 됩니다. 프로젝트에서는 기존 `.claude/hooks/*.sh`와 settings.json의 selfish hook 항목만 정리하면 됩니다.
96
+ **Q: I'm using this across multiple projects. Do I need to migrate each one?**
97
+ A: You only need to install the plugin once. For each project, just clean up the existing `.claude/hooks/*.sh` files and selfish hook entries in settings.json.
98
98
 
99
- **Q: 이전 버전과 플러그인을 동시에 사용할 있나요?**
100
- A: 권장하지 않습니다. 커맨드명이 다르므로 (`/selfish.spec` vs `/selfish:spec`) 충돌은 없지만, hook이 중복 등록될 있습니다.
99
+ **Q: Can I use the old version and the plugin at the same time?**
100
+ A: This is not recommended. Since the command names differ (`/selfish.spec` vs `/selfish:spec`), there are no conflicts, but hooks may get registered twice.
package/README.md CHANGED
@@ -4,9 +4,9 @@
4
4
 
5
5
  [![npm version](https://img.shields.io/npm/v/selfish-pipeline)](https://www.npmjs.com/package/selfish-pipeline)
6
6
  [![license](https://img.shields.io/github/license/jhlee0409/selfish-pipeline)](./LICENSE)
7
- [![test](https://img.shields.io/badge/tests-101%20passed-brightgreen)]()
8
- [![hooks](https://img.shields.io/badge/hooks-15%20events-blue)]()
9
- [![commands](https://img.shields.io/badge/commands-16-orange)]()
7
+ [![test](https://img.shields.io/badge/tests-161%20passed-brightgreen)](#how-it-works)
8
+ [![hooks](https://img.shields.io/badge/hooks-15%20events-blue)](#15-hook-events)
9
+ [![commands](https://img.shields.io/badge/commands-18-orange)](#18-slash-commands)
10
10
 
11
11
  > Zero-dependency automation pipeline for Claude Code. One command (`/selfish:auto`) runs the entire cycle: write specs, design plans, break into tasks, implement code, review quality, and clean up — all with built-in CI gates and critic loops.
12
12
 
@@ -14,7 +14,7 @@
14
14
 
15
15
  Selfish Pipeline is a **Claude Code plugin** that transforms your development workflow into a fully automated pipeline. Instead of manually prompting Claude through each development phase, you run a single command and the pipeline handles everything — from writing feature specifications to final code review.
16
16
 
17
- - **16 slash commands** for every phase of development
17
+ - **18 slash commands** for every phase of development
18
18
  - **15 hook events** with 3 handler types (shell scripts, LLM prompts, subagents)
19
19
  - **5 project presets** for popular stacks (Next.js, React SPA, Express API, Monorepo)
20
20
  - **Persistent memory agents** that learn across sessions
@@ -75,9 +75,9 @@ Runs all 6 phases automatically with **Critic Loop** quality checks at each gate
75
75
  Spec (1/6) → Plan (2/6) → Tasks (3/6) → Implement (4/6) → Review (5/6) → Clean (6/6)
76
76
  ```
77
77
 
78
- ### 16 Slash Commands
78
+ ### 18 Slash Commands
79
79
 
80
- **User-invocable:**
80
+ **User and model (unrestricted):**
81
81
 
82
82
  | Command | Description |
83
83
  |---|---|
@@ -85,24 +85,31 @@ Spec (1/6) → Plan (2/6) → Tasks (3/6) → Implement (4/6) → Review (5/6)
85
85
  | `/selfish:spec` | Write feature specification with acceptance criteria |
86
86
  | `/selfish:plan` | Design implementation plan with file change map |
87
87
  | `/selfish:implement` | Execute code implementation with CI gates |
88
+ | `/selfish:test` | Test strategy planning and test writing |
88
89
  | `/selfish:review` | Code review with security scanning |
89
90
  | `/selfish:research` | Technical research with persistent storage |
90
- | `/selfish:init` | Project setup — detects stack and generates config |
91
+ | `/selfish:debug` | Bug diagnosis and fix |
91
92
 
92
- **Model-callable (internal):**
93
+ **User-only** (`disable-model-invocation: true`):
93
94
 
94
95
  | Command | Description |
95
96
  |---|---|
96
- | `/selfish:tasks` | Break plan into parallelizable tasks |
97
- | `/selfish:analyze` | Verify artifact consistency |
97
+ | `/selfish:init` | Project setup detects stack and generates config |
98
+ | `/selfish:doctor` | Diagnose project health and plugin setup |
98
99
  | `/selfish:architect` | Architecture analysis (persistent memory) |
99
100
  | `/selfish:security` | Security scan (persistent memory, isolated worktree) |
100
- | `/selfish:clarify` | Resolve spec ambiguities |
101
- | `/selfish:debug` | Bug diagnosis and fix |
102
101
  | `/selfish:principles` | Project principles management |
103
102
  | `/selfish:checkpoint` | Save session state |
104
103
  | `/selfish:resume` | Restore session state |
105
104
 
105
+ **Model-only** (`user-invocable: false`):
106
+
107
+ | Command | Description |
108
+ |---|---|
109
+ | `/selfish:tasks` | Break plan into parallelizable tasks |
110
+ | `/selfish:analyze` | Verify artifact consistency |
111
+ | `/selfish:clarify` | Resolve spec ambiguities |
112
+
106
113
  ### 15 Hook Events
107
114
 
108
115
  Every hook fires automatically — no configuration needed after install.
@@ -187,7 +194,7 @@ This detects your tech stack and generates `.claude/selfish.config.md` with:
187
194
  ## FAQ
188
195
 
189
196
  ### What is selfish-pipeline?
190
- A Claude Code plugin that automates the entire development cycle (spec → plan → tasks → implement → review → clean) through 16 slash commands and 15 hook events.
197
+ A Claude Code plugin that automates the entire development cycle (spec → plan → tasks → implement → review → clean) through 18 slash commands and 15 hook events.
191
198
 
192
199
  ### How does it compare to manual Claude Code workflows?
193
200
  Instead of manually prompting each step, selfish-pipeline orchestrates the full cycle with built-in quality gates that physically prevent skipping CI or security checks.
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: selfish-architect
3
- description: "아키텍처 분석 에이전트 — ADR 결정과 아키텍처 패턴을 세션 기억하여 일관된 설계 조언을 제공한다."
3
+ description: "Architecture analysis agentremembers ADR decisions and architecture patterns across sessions to provide consistent design guidance."
4
4
  tools:
5
5
  - Read
6
6
  - Grep
@@ -15,7 +15,13 @@ skills:
15
15
  - docs/phase-gate-protocol.md
16
16
  ---
17
17
 
18
- You are an architecture analysis agent for the selfish-pipeline project.
18
+ You are an architecture analysis agent for the current project.
19
+
20
+ ## Reference Documents
21
+
22
+ Before performing analysis, read these shared reference documents:
23
+ - `docs/critic-loop-rules.md` — Critic Loop execution rules
24
+ - `docs/phase-gate-protocol.md` — Phase gate validation protocol
19
25
 
20
26
  ## Memory Usage
21
27
 
@@ -1,12 +1,13 @@
1
1
  ---
2
2
  name: selfish-security
3
- description: "보안 스캔 에이전트취약점 패턴과 프로젝트별 보안 특성을 세션 기억하여 스캔 정밀도를 향상시킨다."
3
+ description: "Security scanning agentremembers vulnerability patterns and project-specific security characteristics across sessions to improve scan precision."
4
4
  tools:
5
5
  - Read
6
6
  - Grep
7
7
  - Glob
8
8
  - Bash
9
9
  - Task
10
+ - WebSearch
10
11
  model: sonnet
11
12
  memory: project
12
13
  isolation: worktree
@@ -15,7 +16,13 @@ skills:
15
16
  - docs/phase-gate-protocol.md
16
17
  ---
17
18
 
18
- You are a security scanning agent for the selfish-pipeline project.
19
+ You are a security scanning agent for the current project.
20
+
21
+ ## Reference Documents
22
+
23
+ Before performing scans, read these shared reference documents:
24
+ - `docs/critic-loop-rules.md` — Critic Loop execution rules
25
+ - `docs/phase-gate-protocol.md` — Phase gate validation protocol
19
26
 
20
27
  ## Memory Usage
21
28
 
package/bin/cli.mjs CHANGED
@@ -12,19 +12,19 @@ const SCOPES = [
12
12
  {
13
13
  key: "1",
14
14
  name: "user",
15
- label: "User (개인 전체 프로젝트)",
15
+ label: "User (all projects for this user)",
16
16
  desc: "~/.claude/settings.json",
17
17
  },
18
18
  {
19
19
  key: "2",
20
20
  name: "project",
21
- label: "Project ( 공유, git 커밋 가능)",
21
+ label: "Project (shared with team, committable)",
22
22
  desc: ".claude/settings.json",
23
23
  },
24
24
  {
25
25
  key: "3",
26
26
  name: "local",
27
- label: "Local ( 프로젝트만, gitignore)",
27
+ label: "Local (this project only, gitignored)",
28
28
  desc: ".claude/settings.local.json",
29
29
  },
30
30
  ];
@@ -44,48 +44,48 @@ async function main() {
44
44
  console.log(" ================================================");
45
45
  console.log();
46
46
 
47
- // claude CLI 존재 확인
47
+ // Check claude CLI exists
48
48
  try {
49
49
  execSync("claude --version", { stdio: "pipe" });
50
50
  } catch {
51
- console.error(" ✗ Claude Code CLI 설치되어 있지 않습니다.");
52
- console.error(" https://claude.ai/code 에서 설치하세요.");
51
+ console.error(" ✗ Claude Code CLI is not installed.");
52
+ console.error(" Install it from https://claude.ai/code");
53
53
  exit(1);
54
54
  }
55
55
 
56
56
  const rl = createInterface({ input: stdin, output: stdout });
57
57
 
58
58
  try {
59
- console.log(" 설치 범위를 선택하세요:\n");
59
+ console.log(" Select install scope:\n");
60
60
  for (const s of SCOPES) {
61
61
  console.log(` ${s.key}) ${s.label}`);
62
62
  console.log(` → ${s.desc}`);
63
63
  }
64
64
  console.log();
65
65
 
66
- const answer = await rl.question(" 선택 [1/2/3] (기본: 1): ");
66
+ const answer = await rl.question(" Choose [1/2/3] (default: 1): ");
67
67
  const choice = answer.trim() || "1";
68
68
  const scope = SCOPES.find((s) => s.key === choice);
69
69
 
70
70
  if (!scope) {
71
- console.error("\n ✗ 잘못된 선택입니다.");
71
+ console.error("\n ✗ Invalid selection.");
72
72
  exit(1);
73
73
  }
74
74
 
75
- console.log(`\n → ${scope.label} 스코프로 설치합니다...\n`);
75
+ console.log(`\n → Installing with ${scope.label} scope...\n`);
76
76
 
77
- // Step 1: 마켓플레이스 등록
78
- console.log(" [1/2] 마켓플레이스 등록...");
77
+ // Step 1: Register marketplace
78
+ console.log(" [1/2] Registering marketplace...");
79
79
  run(`claude plugin marketplace add ${GITHUB_REPO}`);
80
80
 
81
- // Step 2: 플러그인 설치
82
- console.log(` [2/2] 플러그인 설치 (--scope ${scope.name})...`);
81
+ // Step 2: Install plugin
82
+ console.log(` [2/2] Installing plugin (--scope ${scope.name})...`);
83
83
  const installed = run(
84
84
  `claude plugin install ${PLUGIN_NAME}@${MARKETPLACE_NAME} --scope ${scope.name}`
85
85
  );
86
86
 
87
87
  if (!installed) {
88
- console.error("\n ✗ 설치에 실패했습니다. 수동으로 시도하세요:");
88
+ console.error("\n ✗ Installation failed. Try manually:");
89
89
  console.error(` claude plugin marketplace add ${GITHUB_REPO}`);
90
90
  console.error(
91
91
  ` claude plugin install ${PLUGIN_NAME}@${MARKETPLACE_NAME} --scope ${scope.name}`
@@ -94,11 +94,11 @@ async function main() {
94
94
  }
95
95
 
96
96
  console.log();
97
- console.log(" ✓ 설치 완료!");
97
+ console.log(" ✓ Installation complete!");
98
98
  console.log();
99
- console.log(" 다음 단계:");
100
- console.log(" /selfish:init 프로젝트 설정 생성");
101
- console.log(' /selfish:auto "기능 설명" 파이프라인 실행');
99
+ console.log(" Next steps:");
100
+ console.log(" /selfish:init Create project config");
101
+ console.log(' /selfish:auto "feature desc" Run the pipeline');
102
102
  console.log();
103
103
  } finally {
104
104
  rl.close();
@@ -106,6 +106,6 @@ async function main() {
106
106
  }
107
107
 
108
108
  main().catch((err) => {
109
- console.error(`\n ✗ 설치 실패: ${err.message}`);
109
+ console.error(`\n ✗ Installation failed: ${err.message}`);
110
110
  exit(1);
111
111
  });
@@ -1,10 +1,9 @@
1
1
  ---
2
2
  name: selfish:analyze
3
- description: "아티팩트 정합성 검증 (읽기 전용)"
4
- argument-hint: "[검증 범위: spec-plan, tasks-only]"
3
+ description: "Artifact consistency validation (read-only)"
4
+ argument-hint: "[validation scope: spec-plan, tasks-only]"
5
5
  user-invocable: false
6
6
  context: fork
7
- agent: Explore
8
7
  allowed-tools:
9
8
  - Read
10
9
  - Grep
@@ -12,116 +11,116 @@ allowed-tools:
12
11
  model: haiku
13
12
  ---
14
13
 
15
- # /selfish:analyze — 아티팩트 정합성 검증
14
+ # /selfish:analyze — Artifact Consistency Validation
16
15
 
17
- > spec.md, plan.md, tasks.md 간의 일관성과 품질을 검증한다.
18
- > **읽기 전용** 파일을 수정하지 않는다.
16
+ > Validates consistency and quality across spec.md, plan.md, and tasks.md.
17
+ > **Read-only**does not modify any files.
19
18
 
20
- ## 인자
19
+ ## Arguments
21
20
 
22
- - `$ARGUMENTS` — (선택) 검증 범위 한정 (예: "spec-plan", "tasks-only")
21
+ - `$ARGUMENTS` — (optional) limit validation scope (e.g., "spec-plan", "tasks-only")
23
22
 
24
- ## 설정 로드
23
+ ## Config Load
25
24
 
26
- 프로젝트 루트의 `CLAUDE.md` 또는 `.claude/CLAUDE.md`에서 다음 설정을 읽어 `config` 변수에 할당:
25
+ Read the following settings from `CLAUDE.md` or `.claude/CLAUDE.md` at the project root and assign to the `config` variable:
27
26
 
28
27
  ```
29
- config.architecture = 프로젝트에서 사용하는 아키텍처 패턴
30
- (예: "FSD", "Clean Architecture", "Layered", "Modular Monolith")
31
- → CLAUDE.md 명시된 아키텍처 기준. 없으면 "레이어드 아키텍처"로 가정.
28
+ config.architecture = the architecture pattern used in the project
29
+ (e.g., "FSD", "Clean Architecture", "Layered", "Modular Monolith")
30
+ Architecture standard specified in CLAUDE.md. Assume "Layered Architecture" if not present.
32
31
  ```
33
32
 
34
- ## 실행 절차
33
+ ## Execution Steps
35
34
 
36
- ### 1. 아티팩트 로드
35
+ ### 1. Load Artifacts
37
36
 
38
- `specs/{feature}/`에서:
39
- - **spec.md** (필수)
40
- - **plan.md** (필수)
41
- - **tasks.md** (있으면)
42
- - **research.md** (있으면)
37
+ From `specs/{feature}/`:
38
+ - **spec.md** (required)
39
+ - **plan.md** (required)
40
+ - **tasks.md** (if present)
41
+ - **research.md** (if present)
43
42
 
44
- 누락 파일이 있으면 경고하되 있는 것으로 진행.
43
+ Warn about missing files but proceed with what is available.
45
44
 
46
- ### 2. 검증 수행
45
+ ### 2. Run Validation
47
46
 
48
- 6가지 카테고리를 검증:
47
+ Validate across 6 categories:
49
48
 
50
- #### A. 중복 감지 (DUPLICATION)
51
- - spec.md 내 유사한 요구사항
52
- - tasks.md 내 겹치는 태스크
49
+ #### A. Duplication Detection (DUPLICATION)
50
+ - Similar requirements within spec.md
51
+ - Overlapping tasks within tasks.md
53
52
 
54
- #### B. 모호성 감지 (AMBIGUITY)
55
- - 측정 불가능한 형용사 ("적절한", "빠른", "좋은")
56
- - TODO/TBD/FIXME 잔류
57
- - 불완전한 문장
53
+ #### B. Ambiguity Detection (AMBIGUITY)
54
+ - Unmeasurable adjectives ("appropriate", "fast", "good")
55
+ - Residual TODO/TBD/FIXME markers
56
+ - Incomplete sentences
58
57
 
59
- #### C. 커버리지 (COVERAGE)
60
- - spec → plan: 모든 FR-*/NFR-*가 plan에 반영되었는가?
61
- - plan → tasks: plan File Change Map 모든 항목이 tasks에 있는가?
62
- - spec → tasks: 모든 요구사항이 태스크에 매핑되는가?
58
+ #### C. Coverage Gaps (COVERAGE)
59
+ - spec → plan: Are all FR-*/NFR-* reflected in the plan?
60
+ - plan → tasks: Are all items in the plan's File Change Map present in tasks?
61
+ - spec → tasks: Are all requirements mapped to tasks?
63
62
 
64
- #### D. 불일치 (INCONSISTENCY)
65
- - 용어 드리프트 (같은 개념에 다른 이름)
66
- - 충돌하는 요구사항
67
- - plan 기술 결정과 tasks의 실행이 불일치
63
+ #### D. Inconsistencies (INCONSISTENCY)
64
+ - Terminology drift (different names for the same concept)
65
+ - Conflicting requirements
66
+ - Mismatches between technical decisions in plan and execution in tasks
68
67
 
69
- #### E. 원칙 준수 (PRINCIPLES)
70
- - memory/principles.md 있으면 MUST 원칙 대비 검증
71
- - {config.architecture} 규칙 위반 가능성
68
+ #### E. Principles Compliance (PRINCIPLES)
69
+ - Validate against MUST principles in memory/principles.md if present
70
+ - Potential violations of {config.architecture} rules
72
71
 
73
- #### F. 리스크 미식별 (RISK)
74
- - plan.md에 식별되지 않은 리스크가 있는가?
75
- - 외부 의존성 리스크
76
- - 성능 병목 가능성
72
+ #### F. Unidentified Risks (RISK)
73
+ - Are there risks not identified in plan.md?
74
+ - External dependency risks
75
+ - Potential performance bottlenecks
77
76
 
78
- ### 3. 심각도 분류
77
+ ### 3. Severity Classification
79
78
 
80
- | 심각도 | 기준 |
81
- |--------|------|
82
- | **CRITICAL** | 원칙 위반, 핵심 기능 차단, 보안 문제 |
83
- | **HIGH** | 중복/충돌, 테스트 불가능, 커버리지 |
84
- | **MEDIUM** | 용어 드리프트, 모호한 요구사항 |
85
- | **LOW** | 스타일 개선, 사소한 중복 |
79
+ | Severity | Criteria |
80
+ |----------|----------|
81
+ | **CRITICAL** | Principles violation, core feature blocker, security issue |
82
+ | **HIGH** | Duplication/conflict, untestable, coverage gap |
83
+ | **MEDIUM** | Terminology drift, ambiguous requirements |
84
+ | **LOW** | Style improvements, minor duplication |
86
85
 
87
- ### 4. 결과 출력 (콘솔)
86
+ ### 4. Output Results (console)
88
87
 
89
88
  ```markdown
90
- ## 정합성 분석 결과: {기능명}
89
+ ## Consistency Analysis Results: {feature name}
91
90
 
92
- ### 발견사항
93
- | ID | 카테고리 | 심각도 | 위치 | 요약 | 권장 조치 |
94
- |----|----------|--------|------|------|-----------|
95
- | A-001 | COVERAGE | HIGH | spec FR-003 | tasks에 매핑 없음 | 태스크 추가 |
96
- | A-002 | AMBIGUITY | MEDIUM | spec NFR-001 | "빠르게" 측정 불가 | 수치 기준 추가 |
91
+ ### Findings
92
+ | ID | Category | Severity | Location | Summary | Recommended Action |
93
+ |----|----------|----------|----------|---------|-------------------|
94
+ | A-001 | COVERAGE | HIGH | spec FR-003 | No mapping in tasks | Add task |
95
+ | A-002 | AMBIGUITY | MEDIUM | spec NFR-001 | "quickly" is unmeasurable | Add numeric threshold |
97
96
 
98
- ### 커버리지 요약
99
- | 매핑 | 비율 |
100
- |------|------|
97
+ ### Coverage Summary
98
+ | Mapping | Coverage |
99
+ |---------|----------|
101
100
  | spec → plan | {N}% |
102
101
  | plan → tasks | {N}% |
103
102
  | spec → tasks | {N}% |
104
103
 
105
- ### 메트릭스
106
- - 요구사항: {N}
107
- - 태스크: {N}
108
- - 이슈: CRITICAL {N} / HIGH {N} / MEDIUM {N} / LOW {N}
104
+ ### Metrics
105
+ - Total requirements: {N}
106
+ - Total tasks: {N}
107
+ - Issues: CRITICAL {N} / HIGH {N} / MEDIUM {N} / LOW {N}
109
108
 
110
- ### 다음 단계
111
- {CRITICAL/HIGH 이슈에 대한 구체적 조치 제안}
109
+ ### Next Steps
110
+ {Concrete action proposals for CRITICAL/HIGH issues}
112
111
  ```
113
112
 
114
- ### 5. 최종 출력
113
+ ### 5. Final Output
115
114
 
116
115
  ```
117
- 🔎 분석 완료
118
- ├─ 발견: CRITICAL {N} / HIGH {N} / MEDIUM {N} / LOW {N}
119
- ├─ 커버리지: spec→plan {N}%, plan→tasks {N}%, spec→tasks {N}%
120
- └─ 권장: {다음 액션}
116
+ Analysis complete
117
+ ├─ Found: CRITICAL {N} / HIGH {N} / MEDIUM {N} / LOW {N}
118
+ ├─ Coverage: spec→plan {N}%, plan→tasks {N}%, spec→tasks {N}%
119
+ └─ Recommended: {next action}
121
120
  ```
122
121
 
123
- ## 주의사항
122
+ ## Notes
124
123
 
125
- - **읽기 전용**: 어떤 파일도 수정하지 않는다. 보고만 한다.
126
- - **오탐 주의**: 모호성 감지가 과도하지 않도록. 컨텍스트를 고려.
127
- - **선택적**: 파이프라인에서 필수가 아님. plan → tasks → implement 직행 가능.
124
+ - **Read-only**: Do not modify any files. Report only.
125
+ - **Avoid false positives**: Do not over-flag ambiguity. Consider context.
126
+ - **Optional**: Not required in the pipeline. Can proceed plan → tasks → implement directly.