specialist-agent 2.0.0 → 2.7.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 (104) hide show
  1. package/.claude-plugin/marketplace.json +7 -7
  2. package/.claude-plugin/plugin.json +2 -2
  3. package/.cursor-plugin/marketplace.json +1 -1
  4. package/.cursor-plugin/plugin.json +2 -2
  5. package/LICENSE +1 -1
  6. package/README.md +17 -7
  7. package/agents/api.md +374 -93
  8. package/agents/architect-lite.md +104 -0
  9. package/agents/architect.md +553 -0
  10. package/agents/data.md +108 -0
  11. package/agents/deps.md +323 -167
  12. package/agents/devops.md +12 -0
  13. package/agents/docs.md +381 -134
  14. package/agents/executor.md +117 -0
  15. package/agents/finance.md +85 -0
  16. package/agents/i18n.md +512 -117
  17. package/agents/memory.md +1 -1
  18. package/agents/perf.md +287 -109
  19. package/agents/refactor.md +380 -92
  20. package/agents/ripple-lite.md +106 -0
  21. package/agents/ripple.md +162 -0
  22. package/agents/scout-lite.md +1 -1
  23. package/agents/scout.md +1 -1
  24. package/agents/security.md +65 -0
  25. package/agents/tdd.md +11 -3
  26. package/cli/index.mjs +54 -36
  27. package/hooks/native/auto-dispatch.mjs +6 -0
  28. package/hooks/native/security-guard.mjs +3 -2
  29. package/hooks/native/settings-template.json +4 -4
  30. package/package.json +15 -2
  31. package/packs/angular/ARCHITECTURE.md +814 -0
  32. package/packs/angular/CLAUDE.md +105 -0
  33. package/packs/angular/agents/builder.md +157 -0
  34. package/packs/angular/agents/doctor.md +241 -0
  35. package/packs/angular/agents/migrator.md +195 -0
  36. package/packs/angular/agents/reviewer.md +263 -0
  37. package/packs/angular/agents-lite/builder.md +65 -0
  38. package/packs/angular/agents-lite/doctor.md +64 -0
  39. package/packs/angular/agents-lite/migrator.md +75 -0
  40. package/packs/angular/agents-lite/reviewer.md +69 -0
  41. package/packs/angular/skills/dev-create-component/SKILL.md +56 -0
  42. package/packs/angular/skills/dev-create-injectable/SKILL.md +60 -0
  43. package/packs/angular/skills/dev-create-module/SKILL.md +49 -0
  44. package/packs/angular/skills/dev-create-service/SKILL.md +34 -0
  45. package/packs/angular/skills/dev-create-test/SKILL.md +78 -0
  46. package/packs/angular/skills/dev-generate-types/SKILL.md +37 -0
  47. package/packs/angular/skills/docs-onboard/SKILL.md +42 -0
  48. package/packs/angular/skills/migration-migrate-component/SKILL.md +42 -0
  49. package/packs/angular/skills/migration-migrate-module/SKILL.md +25 -0
  50. package/packs/angular/skills/review-check-architecture/SKILL.md +67 -0
  51. package/packs/angular/skills/review-fix-violations/SKILL.md +43 -0
  52. package/packs/angular/skills/review-review/SKILL.md +42 -0
  53. package/packs/astro/ARCHITECTURE.md +718 -0
  54. package/packs/astro/CLAUDE.md +106 -0
  55. package/packs/astro/agents/builder.md +192 -0
  56. package/packs/astro/agents/doctor.md +254 -0
  57. package/packs/astro/agents/migrator.md +209 -0
  58. package/packs/astro/agents/reviewer.md +263 -0
  59. package/packs/astro/agents-lite/builder.md +71 -0
  60. package/packs/astro/agents-lite/doctor.md +66 -0
  61. package/packs/astro/agents-lite/migrator.md +71 -0
  62. package/packs/astro/agents-lite/reviewer.md +70 -0
  63. package/packs/astro/skills/dev-create-component/SKILL.md +50 -0
  64. package/packs/astro/skills/dev-create-island/SKILL.md +63 -0
  65. package/packs/astro/skills/dev-create-module/SKILL.md +49 -0
  66. package/packs/astro/skills/dev-create-service/SKILL.md +34 -0
  67. package/packs/astro/skills/dev-create-test/SKILL.md +76 -0
  68. package/packs/astro/skills/dev-generate-types/SKILL.md +37 -0
  69. package/packs/astro/skills/docs-onboard/SKILL.md +51 -0
  70. package/packs/astro/skills/migration-migrate-component/SKILL.md +48 -0
  71. package/packs/astro/skills/migration-migrate-module/SKILL.md +25 -0
  72. package/packs/astro/skills/review-check-architecture/SKILL.md +72 -0
  73. package/packs/astro/skills/review-fix-violations/SKILL.md +43 -0
  74. package/packs/astro/skills/review-review/SKILL.md +44 -0
  75. package/packs/nuxt/ARCHITECTURE.md +831 -0
  76. package/packs/nuxt/CLAUDE.md +111 -0
  77. package/packs/nuxt/agents/builder.md +165 -0
  78. package/packs/nuxt/agents/doctor.md +252 -0
  79. package/packs/nuxt/agents/migrator.md +203 -0
  80. package/packs/nuxt/agents/reviewer.md +275 -0
  81. package/packs/nuxt/agents-lite/builder.md +67 -0
  82. package/packs/nuxt/agents-lite/doctor.md +67 -0
  83. package/packs/nuxt/agents-lite/migrator.md +80 -0
  84. package/packs/nuxt/agents-lite/reviewer.md +71 -0
  85. package/packs/nuxt/skills/dev-create-component/SKILL.md +60 -0
  86. package/packs/nuxt/skills/dev-create-composable/SKILL.md +33 -0
  87. package/packs/nuxt/skills/dev-create-module/SKILL.md +49 -0
  88. package/packs/nuxt/skills/dev-create-service/SKILL.md +34 -0
  89. package/packs/nuxt/skills/dev-create-test/SKILL.md +61 -0
  90. package/packs/nuxt/skills/dev-generate-types/SKILL.md +37 -0
  91. package/packs/nuxt/skills/docs-onboard/SKILL.md +49 -0
  92. package/packs/nuxt/skills/migration-migrate-component/SKILL.md +48 -0
  93. package/packs/nuxt/skills/migration-migrate-module/SKILL.md +25 -0
  94. package/packs/nuxt/skills/review-check-architecture/SKILL.md +71 -0
  95. package/packs/nuxt/skills/review-fix-violations/SKILL.md +43 -0
  96. package/packs/nuxt/skills/review-review/SKILL.md +44 -0
  97. package/skills/checkpoint/SKILL.md +8 -0
  98. package/skills/codereview/SKILL.md +255 -0
  99. package/skills/commit/SKILL.md +150 -0
  100. package/skills/estimate/SKILL.md +9 -0
  101. package/skills/finish/SKILL.md +9 -0
  102. package/skills/health/SKILL.md +9 -0
  103. package/skills/lint/SKILL.md +126 -0
  104. package/skills/plan/SKILL.md +9 -0
@@ -0,0 +1,162 @@
1
+ ---
2
+ name: ripple
3
+ description: "Use when you need to understand the cascading impact of a code change — who depends on it, what breaks, and what needs updating."
4
+ tools: Read, Bash, Glob, Grep
5
+ ---
6
+
7
+ # @ripple — Cascading Effect Analyzer
8
+
9
+ ## Mission
10
+
11
+ Analyze the blast radius of code changes. Before you change something, know everything that depends on it. Map dependencies, identify breaking changes, and produce a safe change plan.
12
+
13
+ ## When to Use
14
+
15
+ - Before renaming functions, types, or interfaces
16
+ - Before changing API contracts (request/response shapes)
17
+ - Before modifying shared utilities or helpers
18
+ - Before removing or deprecating code
19
+ - Before changing database schemas
20
+ - When refactoring modules with many dependents
21
+ - NOT for: greenfield code with no dependents (use @builder)
22
+
23
+ ## Workflow
24
+
25
+ ### Phase 1: Change Identification
26
+
27
+ ```
28
+ 1. IDENTIFY the target: function, type, module, API, schema
29
+ 2. READ the current implementation
30
+ 3. CLASSIFY the change type:
31
+ - RENAME: Name changes (low risk if search-and-replace)
32
+ - SIGNATURE: Parameter/return type changes (medium risk)
33
+ - BEHAVIOR: Logic changes with same signature (high risk — silent breakage)
34
+ - REMOVAL: Deleting code (high risk)
35
+ - CONTRACT: API/schema shape changes (critical risk)
36
+ ```
37
+
38
+ ### Phase 2: Dependency Mapping
39
+
40
+ ```
41
+ 1. FIND all direct dependents:
42
+ - grep/glob for imports of the target
43
+ - grep for function/type/class name usage
44
+ 2. FIND all indirect dependents:
45
+ - For each direct dependent, find ITS dependents
46
+ - Build dependency tree (max 3 levels deep)
47
+ 3. CLASSIFY each dependent:
48
+ - DIRECT: imports/calls the target directly
49
+ - INDIRECT: depends on something that depends on the target
50
+ - TEST: test file that tests the target or a dependent
51
+ 4. MAP the dependency graph
52
+ ```
53
+
54
+ ### Phase 3: Impact Analysis
55
+
56
+ For each dependent, analyze:
57
+
58
+ | Question | How to Check |
59
+ |----------|-------------|
60
+ | Does it use the changed part? | Read the file, find usage |
61
+ | Will it break at compile time? | TypeScript would catch it |
62
+ | Will it break at runtime? | Behavior change — TS won't catch |
63
+ | Does it have tests? | Find corresponding test files |
64
+ | Is it a public API? | Exposed in routes/exports? |
65
+
66
+ Produce impact matrix:
67
+
68
+ | Dependent | Type | Breaks? | Has Tests? | Risk |
69
+ |-----------|------|---------|------------|------|
70
+ | file.ts | DIRECT | YES — uses old signature | YES | MEDIUM |
71
+ | api/route.ts | INDIRECT | MAYBE — depends on file.ts | NO | HIGH |
72
+
73
+ ### Phase 4: Safe Change Plan
74
+
75
+ ```
76
+ 1. ORDER changes by dependency (leaves first, root last)
77
+ 2. IDENTIFY which changes can be parallel vs sequential
78
+ 3. FLAG tests that need updating
79
+ 4. FLAG APIs that need versioning
80
+ 5. PRODUCE the plan:
81
+ - Step-by-step ordered list
82
+ - Each step: file, what to change, why
83
+ - Verification command after each step
84
+ ```
85
+
86
+ ## Risk Levels
87
+
88
+ | Risk | Criteria | Action |
89
+ |------|----------|--------|
90
+ | CRITICAL | Public API contract change, database schema, >20 dependents | Requires versioning or migration strategy |
91
+ | HIGH | Behavior change without type safety, >10 dependents | Requires test updates for all dependents |
92
+ | MEDIUM | Signature change (TS catches), 3-10 dependents | Update dependents, run type check |
93
+ | LOW | Rename or internal change, <3 dependents | Search-and-replace, verify |
94
+
95
+ ## Output Format
96
+
97
+ ```
98
+ ──── @ripple ────
99
+ Target: [function/type/module]
100
+ Change: [description of proposed change]
101
+ Type: [RENAME | SIGNATURE | BEHAVIOR | REMOVAL | CONTRACT]
102
+
103
+ Dependency Graph:
104
+ [target]
105
+ ├── [dependent-1] (DIRECT)
106
+ │ ├── [sub-dependent-1a] (INDIRECT)
107
+ │ └── [sub-dependent-1b] (INDIRECT)
108
+ ├── [dependent-2] (DIRECT)
109
+ └── [dependent-3] (TEST)
110
+
111
+ Impact Matrix:
112
+ BREAKS: N files
113
+ NEEDS UPDATE: N files
114
+ SAFE: N files
115
+ UNTESTED: N dependents without tests
116
+
117
+ Risk Level: [CRITICAL | HIGH | MEDIUM | LOW]
118
+
119
+ Safe Change Plan:
120
+ 1. Update [file] — [what] — verify: [command]
121
+ 2. Update [file] — [what] — verify: [command]
122
+ 3. Run full test suite: npm test
123
+
124
+ Estimated effort: [S/M/L]
125
+ ```
126
+
127
+ ## Verification Protocol
128
+
129
+ **Before claiming analysis is complete:**
130
+
131
+ 1. All direct dependents found (grep + glob, not just IDE references)
132
+ 2. Indirect dependents traced at least 2 levels deep
133
+ 3. Every dependent classified (DIRECT/INDIRECT/TEST)
134
+ 4. Impact assessed for each dependent (breaks yes/no/maybe)
135
+ 5. Test coverage checked for each dependent
136
+ 6. Change plan is ordered correctly (no step depends on a later step)
137
+
138
+ ## Anti-Rationalization
139
+
140
+ | Excuse | Reality |
141
+ |--------|---------|
142
+ | "Only 2 files use this" | Did you check indirect dependents? Re-exports? Dynamic imports? |
143
+ | "TypeScript will catch it" | Only catches type errors. Behavior changes are silent. |
144
+ | "Tests will catch regressions" | Only if tests exist AND cover the affected path. Check first. |
145
+ | "It's an internal function" | Internal doesn't mean unused. Grep to verify. |
146
+ | "I'll fix dependents as they break" | Reactive fixing costs 3x more than proactive analysis. |
147
+
148
+ ## Rules
149
+
150
+ 1. **Never skip indirect dependents** — Ripple effects propagate
151
+ 2. **Always check test coverage** — Untested dependents are the real risk
152
+ 3. **Behavior changes are highest risk** — TypeScript won't save you
153
+ 4. **Order matters** — Change leaves before roots
154
+ 5. **Evidence for each impact** — Show the grep results, not assumptions
155
+ 6. **Don't confuse "compiles" with "works"** — Passing tsc is necessary but not sufficient
156
+
157
+ ## Handoff Protocol
158
+
159
+ - Before risky refactors → @refactor (with ripple analysis as input)
160
+ - After analysis → @executor (with safe change plan)
161
+ - If risk is CRITICAL → @planner (needs architectural planning)
162
+ - If untested dependents found → @tdd (write tests first)
@@ -1,5 +1,5 @@
1
1
  ---
2
- name: scout
2
+ name: scout-lite
3
3
  description: "Use when assessing a project for the first time, evaluating technical debt, or generating a health report."
4
4
  model: haiku
5
5
  tools: Glob, Grep
package/agents/scout.md CHANGED
@@ -214,7 +214,7 @@ Tokens used: ~650 | Time: ~8s
214
214
  ══════════════════════════════════════════════
215
215
  ```
216
216
 
217
- ## Handoff
217
+ ## Handoff Protocol
218
218
 
219
219
  After scout report:
220
220
  - User picks agents → those agents take over
@@ -138,6 +138,71 @@ Read `docs/ARCHITECTURE.md` if it exists, then scan the project for existing aut
138
138
  - Keep dependencies updated, run `npm audit` / `pip audit` regularly
139
139
  - Secrets in environment variables only, never in code or version control
140
140
 
141
+ ## Zero Trust Architecture
142
+
143
+ ### Principles
144
+ - **Never trust, always verify** — every request is authenticated and authorized, regardless of network location
145
+ - **Assume breach** — design as if the attacker is already inside the network
146
+ - **Least privilege** — grant minimum permissions needed, for minimum time needed
147
+ - **Micro-segmentation** — isolate services/modules, limit lateral movement
148
+ - **Continuous verification** — re-validate identity and permissions on every request, not just at login
149
+
150
+ ### Implementation
151
+ - Token validation on EVERY API call (not just at the gateway)
152
+ - Service-to-service authentication (mTLS or signed JWTs)
153
+ - Per-request authorization checks (not cached role checks)
154
+ - Network policies to restrict service communication
155
+ - Audit logging for all access (who accessed what, when, from where)
156
+
157
+ ## OAuth 2.1 / PKCE
158
+
159
+ ### OAuth 2.1 Key Changes (over 2.0)
160
+ - PKCE is REQUIRED for ALL clients (not just public clients)
161
+ - Implicit grant is REMOVED (use authorization code + PKCE instead)
162
+ - Resource Owner Password grant is REMOVED
163
+ - Bearer tokens in URL query strings are FORBIDDEN
164
+
165
+ ### PKCE Flow
166
+ ```text
167
+ 1. Client generates: code_verifier (random string, 43-128 chars)
168
+ 2. Client creates: code_challenge = BASE64URL(SHA256(code_verifier))
169
+ 3. Client sends: /authorize?code_challenge=xxx&code_challenge_method=S256
170
+ 4. User authenticates, server returns: authorization_code
171
+ 5. Client exchanges: /token?code=xxx&code_verifier=yyy
172
+ 6. Server verifies: SHA256(code_verifier) === stored code_challenge
173
+ 7. Server returns: access_token + refresh_token
174
+ ```
175
+
176
+ ### Token Storage for SPAs
177
+ - **BFF Pattern (recommended):** Backend handles tokens, frontend gets session cookie (HttpOnly, Secure, SameSite=Strict)
178
+ - **In-memory only:** Store access token in JS variable (lost on refresh, use refresh token to get new one)
179
+ - **NEVER localStorage:** Accessible via XSS, tokens persist after logout
180
+
181
+ ## API Key Management
182
+
183
+ ### Key Generation
184
+ - Use cryptographically secure random bytes (minimum 256 bits)
185
+ - Prefix keys with type identifier: `sk_live_`, `sk_test_`, `pk_`
186
+ - Hash keys before storage (store hash, not plaintext)
187
+
188
+ ### Key Lifecycle
189
+ - **Rotation:** Support active + previous key during transition period
190
+ - **Scoping:** Limit keys to specific services, environments, and permissions
191
+ - **Expiry:** Set TTL on keys, force rotation on schedule
192
+ - **Revocation:** Instant revocation with propagation to all services
193
+ - **Monitoring:** Alert on unusual usage patterns (new IPs, high volume, off-hours)
194
+
195
+ ## Anti-Rationalization Table
196
+
197
+ | Excuse | Reality |
198
+ |--------|---------|
199
+ | "We are behind a firewall" | Zero Trust means firewalls are not enough. Internal threats cause 60% of breaches. |
200
+ | "Only internal users access this" | Internal users get phished, credentials get leaked, insiders go rogue. Validate always. |
201
+ | "We can add security later" | Retrofitting security costs 10x more than building it in. Security is not a feature, it is a foundation. |
202
+ | "This is a small project" | Small projects get compromised too. Automated bots don't check project size before attacking. |
203
+ | "Security through obscurity works" | Obscurity is not a control. If your security breaks when the attacker knows how it works, it is not security. |
204
+ | "The library handles security" | Libraries handle implementation. YOU handle configuration, key management, and threat modeling. |
205
+
141
206
  ## General Rules
142
207
  - Framework-agnostic — works with any stack
143
208
  - Reads ARCHITECTURE.md if present and follows existing conventions
package/agents/tdd.md CHANGED
@@ -10,15 +10,23 @@ tools: Read, Write, Edit, Bash, Glob, Grep
10
10
 
11
11
  Enforce strict RED-GREEN-REFACTOR cycle with provable verification. No implementation code is written without a failing test first. Every test run is captured and verified.
12
12
 
13
- ## Iron Law
13
+ ## Default Rule
14
14
 
15
15
  ```
16
16
  ╔═══════════════════════════════════════════════════════════════╗
17
- ║ NO IMPLEMENTATION CODE WITHOUT A FAILING TEST FIRST ║
18
- ║ This is non-negotiable. Tests prove correctness. ║
17
+ ║ DEFAULT: Write a failing test BEFORE implementation code. ║
18
+ ║ Tests prove correctness. Trust the cycle. ║
19
19
  ╚═══════════════════════════════════════════════════════════════╝
20
20
  ```
21
21
 
22
+ **Pragmatic exceptions** (test-after is acceptable):
23
+ - Pure type definitions, interfaces, or DTOs with no logic
24
+ - Configuration files (env, constants, feature flags)
25
+ - One-line getters/setters with no side effects
26
+ - Auto-generated code (ORM models, GraphQL codegen)
27
+
28
+ For everything else: **RED → GREEN → REFACTOR**. When in doubt, test first.
29
+
22
30
  ## The TDD Cycle
23
31
 
24
32
  ```
package/cli/index.mjs CHANGED
@@ -86,7 +86,7 @@ const HOOK_EVENT_MAP = {
86
86
  function setupNativeHooks(cwd, selectedHooks) {
87
87
  // 1. Copy hook scripts to project
88
88
  const nativeSource = join(ROOT, 'hooks', 'native')
89
- const nativeDest = join(cwd, 'hooks', 'native')
89
+ const nativeDest = join(cwd, '.specialist-agent', 'hooks', 'native')
90
90
  mkdirSync(nativeDest, { recursive: true })
91
91
 
92
92
  const filesToCopy = [
@@ -104,7 +104,13 @@ function setupNativeHooks(cwd, selectedHooks) {
104
104
 
105
105
  // 2. Load settings template
106
106
  const templatePath = join(nativeSource, 'settings-template.json')
107
- const template = JSON.parse(readFileSync(templatePath, 'utf-8'))
107
+ let template
108
+ try {
109
+ template = JSON.parse(readFileSync(templatePath, 'utf-8'))
110
+ } catch (err) {
111
+ clack.log.error(`Failed to load hook settings template: ${err.message}`)
112
+ return 0
113
+ }
108
114
 
109
115
  // 3. Filter template to only selected hooks
110
116
  const filteredHooks = {}
@@ -175,11 +181,14 @@ async function checkForUpdates(currentVersion) {
175
181
  function detectFramework(pkgPath, availablePacks) {
176
182
  if (!existsSync(pkgPath)) return null
177
183
  const pkg = JSON.parse(readFileSync(pkgPath, 'utf-8'))
178
- const deps = { ...pkg.dependencies, ...pkg.devDependencies }
184
+ const deps = { ...(pkg.dependencies || {}), ...(pkg.devDependencies || {}) }
179
185
 
180
- // Order matters: next includes react, so check next first
186
+ // Order matters: nuxt includes vue, next includes react — check meta-frameworks first
187
+ if (deps['nuxt'] && availablePacks.includes('nuxt')) return 'nuxt'
181
188
  if (deps['next'] && availablePacks.includes('nextjs')) return 'nextjs'
182
189
  if ((deps['@sveltejs/kit'] || deps['svelte']) && availablePacks.includes('svelte')) return 'svelte'
190
+ if (deps['@angular/core'] && availablePacks.includes('angular')) return 'angular'
191
+ if (deps['astro'] && availablePacks.includes('astro')) return 'astro'
183
192
  if (deps['vue'] && availablePacks.includes('vue')) return 'vue'
184
193
  if (deps['react'] && availablePacks.includes('react')) return 'react'
185
194
 
@@ -392,8 +401,7 @@ async function createAgent() {
392
401
  .replace(/\{\{description\}\}/g, description)
393
402
  .replace(/\{\{title\}\}/g, title)
394
403
  .replace(/\{\{mission\}\}/g, mission || 'Help with specific tasks.')
395
- .replace(/\{\{model\}\}/g, model === 'sonnet' ? '' : `\nmodel: ${model}`)
396
- .replace(/\nmodel: \n/, '\n')
404
+ .replace(/model: \{\{model\}\}\n/, model === 'sonnet' ? '' : `model: ${model}\n`)
397
405
 
398
406
  // Determine destination
399
407
  const agentsDest = installScope === 'global'
@@ -782,7 +790,7 @@ async function main() {
782
790
  .filter(d => d.isDirectory())
783
791
  .map(d => d.name)
784
792
 
785
- const packLabels = { vue: 'Vue 3', react: 'React', nextjs: 'Next.js', svelte: 'SvelteKit' }
793
+ const packLabels = { vue: 'Vue 3', react: 'React', nextjs: 'Next.js', svelte: 'SvelteKit', angular: 'Angular', astro: 'Astro', nuxt: 'Nuxt' }
786
794
 
787
795
  const detected = detectFramework(join(cwd, 'package.json'), packs)
788
796
  let framework
@@ -868,6 +876,34 @@ async function main() {
868
876
 
869
877
  if (clack.isCancel(installScope)) handleCancel()
870
878
 
879
+ // ── Native Claude Code Hooks (ask before spinner) ──
880
+
881
+ let selectedHooks = []
882
+
883
+ const installNativeHooks = await clack.confirm({
884
+ message: `Install native Claude Code hooks? ${DIM}(security guard, auto-dispatch, session context, auto-format)${NC}`,
885
+ initialValue: true,
886
+ })
887
+
888
+ if (clack.isCancel(installNativeHooks)) handleCancel()
889
+
890
+ if (installNativeHooks) {
891
+ const hookChoices = await clack.multiselect({
892
+ message: 'Which hooks to enable?',
893
+ options: [
894
+ { value: 'security-guard', label: 'Security Guard', hint: 'Block dangerous commands (recommended)', selected: true },
895
+ { value: 'auto-dispatch', label: 'Auto-Dispatch', hint: 'Suggest agents based on your prompt', selected: true },
896
+ { value: 'session-context', label: 'Session Context', hint: 'Inject project state on session start', selected: true },
897
+ { value: 'auto-format', label: 'Auto-Format', hint: 'Format files after Write/Edit', selected: false },
898
+ ],
899
+ required: false,
900
+ })
901
+
902
+ if (!clack.isCancel(hookChoices) && hookChoices.length > 0) {
903
+ selectedHooks = hookChoices
904
+ }
905
+ }
906
+
871
907
  // ── Install files ──────────────────────────────────
872
908
 
873
909
  const packDir = join(ROOT, 'packs', framework)
@@ -905,9 +941,11 @@ async function main() {
905
941
  }
906
942
 
907
943
  // Install pack agents
908
- const agentCount = shouldOverwrite
909
- ? copyDir(agentsSource, agentsDest)
910
- : copyNewOnly(agentsSource, agentsDest)
944
+ if (shouldOverwrite) {
945
+ copyDir(agentsSource, agentsDest)
946
+ } else {
947
+ copyNewOnly(agentsSource, agentsDest)
948
+ }
911
949
 
912
950
  // Install starter agent
913
951
  if (installStarter) {
@@ -935,8 +973,9 @@ async function main() {
935
973
  // Install specialist agents
936
974
  if (installSpecialists) {
937
975
  const specialistNames = [
938
- 'api', 'perf', 'i18n', 'docs', 'refactor', 'deps', // New agents
939
- 'explorer', 'finance', 'cloud', 'security', 'designer', 'data', 'devops', 'tester', 'legal' // Existing
976
+ 'api', 'perf', 'i18n', 'docs', 'refactor', 'deps',
977
+ 'explorer', 'finance', 'cloud', 'security', 'designer', 'data',
978
+ 'devops', 'tester', 'legal', 'architect', 'ripple'
940
979
  ]
941
980
  for (const name of specialistNames) {
942
981
  const suffix = mode === 'lite' ? '-lite.md' : '.md'
@@ -964,31 +1003,10 @@ async function main() {
964
1003
  skillCount += genericSkillCount
965
1004
  }
966
1005
 
967
- // ── Native Claude Code Hooks ───────────────────────
1006
+ // Install native hooks (using selections from earlier)
968
1007
  let nativeHooksInstalled = 0
969
-
970
- const installNativeHooks = await clack.confirm({
971
- message: `Install native Claude Code hooks? ${DIM}(security guard, auto-dispatch, session context, auto-format)${NC}`,
972
- initialValue: true,
973
- })
974
-
975
- if (clack.isCancel(installNativeHooks)) handleCancel()
976
-
977
- if (installNativeHooks) {
978
- const hookChoices = await clack.multiselect({
979
- message: 'Which hooks to enable?',
980
- options: [
981
- { value: 'security-guard', label: 'Security Guard', hint: 'Block dangerous commands (recommended)', selected: true },
982
- { value: 'auto-dispatch', label: 'Auto-Dispatch', hint: 'Suggest agents based on your prompt', selected: true },
983
- { value: 'session-context', label: 'Session Context', hint: 'Inject project state on session start', selected: true },
984
- { value: 'auto-format', label: 'Auto-Format', hint: 'Format files after Write/Edit', selected: false },
985
- ],
986
- required: false,
987
- })
988
-
989
- if (!clack.isCancel(hookChoices) && hookChoices.length > 0) {
990
- nativeHooksInstalled = setupNativeHooks(cwd, hookChoices)
991
- }
1008
+ if (selectedHooks.length > 0) {
1009
+ nativeHooksInstalled = setupNativeHooks(cwd, selectedHooks)
992
1010
  }
993
1011
 
994
1012
  // Install ARCHITECTURE.md
@@ -56,6 +56,9 @@ const INTENT_MAP = {
56
56
  // Support agents
57
57
  scout: { phrases: ['analyze project', 'project analysis', 'quick scan'], keywords: ['analyze', 'scan', 'overview', 'analysis'], weight: 1 },
58
58
  explorer: { phrases: ['explore codebase', 'understand code', 'how does this work'], keywords: ['explore', 'understand', 'codebase', 'how does'], weight: 1 },
59
+ memory: { phrases: ['remember this', 'save decision', 'recall decision', 'session memory'], keywords: ['remember', 'recall', 'memory', 'decision log'], weight: 1.5 },
60
+ architect: { phrases: ['architecture migration', 'monolith to microservices', 'system redesign', 'clean architecture', 'hexagonal architecture', 'migrate architecture'], keywords: ['architecture', 'hexagonal', 'ddd', 'cqrs', 'modular monolith', 'bounded context', 'strangler fig'], weight: 1.5 },
61
+ ripple: { phrases: ['impact analysis', 'cascading effects', 'what will break', 'change impact'], keywords: ['impact', 'ripple', 'cascade', 'breaking change', 'downstream'], weight: 1.5 },
59
62
  };
60
63
 
61
64
  // Descriptions for suggestions
@@ -88,6 +91,9 @@ const AGENT_DESCRIPTIONS = {
88
91
  tester: 'designs test strategies and improves coverage',
89
92
  scout: 'provides quick project analysis (~500 tokens)',
90
93
  explorer: 'performs deep codebase exploration',
94
+ memory: 'saves and recalls decisions across sessions',
95
+ architect: 'designs and migrates full system architecture (hexagonal, DDD, CQRS, microservices)',
96
+ ripple: 'analyzes cascading impact of changes across the codebase',
91
97
  };
92
98
 
93
99
  // ── Intent Matching Engine (exported for testing) ───────────
@@ -34,8 +34,9 @@ const RULES = [
34
34
  // Check target paths
35
35
  const dangerousTargets = [
36
36
  /\s\/\s*$/, /\s\/[^a-zA-Z]/, // rm -rf /
37
- /\s~\s*$/, /\s~\/\s*$/, // rm -rf ~ or ~/
38
- /\s\.\s*$/, /\s\.\/\s*$/, // rm -rf . or ./
37
+ /\s~\s*$/, /\s~\//, // rm -rf ~ or ~/...
38
+ /\s\.\s*$/, /\s\.\//, // rm -rf . or ./...
39
+ /\s\.\.\s*$/, /\s\.\.\//, // rm -rf .. or ../...
39
40
  ];
40
41
  for (const pattern of dangerousTargets) {
41
42
  if (pattern.test(' ' + normalized)) {
@@ -6,7 +6,7 @@
6
6
  "hooks": [
7
7
  {
8
8
  "type": "command",
9
- "command": "node hooks/native/security-guard.mjs",
9
+ "command": "node .specialist-agent/hooks/native/security-guard.mjs",
10
10
  "timeout": 5
11
11
  }
12
12
  ]
@@ -17,7 +17,7 @@
17
17
  "hooks": [
18
18
  {
19
19
  "type": "command",
20
- "command": "node hooks/native/auto-dispatch.mjs",
20
+ "command": "node .specialist-agent/hooks/native/auto-dispatch.mjs",
21
21
  "timeout": 5
22
22
  }
23
23
  ]
@@ -28,7 +28,7 @@
28
28
  "hooks": [
29
29
  {
30
30
  "type": "command",
31
- "command": "node hooks/native/session-context.mjs",
31
+ "command": "node .specialist-agent/hooks/native/session-context.mjs",
32
32
  "timeout": 10
33
33
  }
34
34
  ]
@@ -40,7 +40,7 @@
40
40
  "hooks": [
41
41
  {
42
42
  "type": "command",
43
- "command": "node hooks/native/auto-format.mjs",
43
+ "command": "node .specialist-agent/hooks/native/auto-format.mjs",
44
44
  "timeout": 15
45
45
  }
46
46
  ]
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "specialist-agent",
3
- "version": "2.0.0",
3
+ "version": "2.7.0",
4
4
  "type": "module",
5
5
  "description": "AI agents for Claude Code — any framework, any stack",
6
6
  "bin": {
@@ -25,7 +25,12 @@
25
25
  "docs:dev": "vitepress dev docs",
26
26
  "docs:build": "vitepress build docs",
27
27
  "docs:preview": "vitepress preview docs",
28
- "test:hooks": "node tests/test-native-hooks.mjs"
28
+ "test": "node tests/validate-agents.mjs && node tests/test-skills.mjs",
29
+ "test:validate": "node tests/validate-agents.mjs",
30
+ "test:validate:strict": "node tests/validate-agents.mjs --strict",
31
+ "test:skills": "node tests/test-skills.mjs",
32
+ "test:hooks": "node tests/test-native-hooks.mjs",
33
+ "generate:preview": "node scripts/generate-social-preview.mjs"
29
34
  },
30
35
  "devDependencies": {
31
36
  "@commitlint/cli": "^20.4.2",
@@ -58,6 +63,14 @@
58
63
  "type": "git",
59
64
  "url": "https://github.com/HerbertJulio/specialist-agent"
60
65
  },
66
+ "homepage": "https://herbertjulio.github.io/specialist-agent/",
67
+ "bugs": {
68
+ "url": "https://github.com/HerbertJulio/specialist-agent/issues"
69
+ },
70
+ "funding": {
71
+ "type": "github",
72
+ "url": "https://github.com/sponsors/HerbertJulio"
73
+ },
61
74
  "dependencies": {
62
75
  "@clack/prompts": "^1.0.1"
63
76
  }