@hailer/mcp 1.1.13 → 1.1.15

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 (176) hide show
  1. package/.claude/.context-watchdog.json +1 -0
  2. package/.claude/.session-checked +1 -0
  3. package/.claude/CLAUDE.md +370 -0
  4. package/.claude/agents/agent-ada-skill-builder.md +94 -0
  5. package/.claude/agents/agent-alejandro-function-fields.md +342 -0
  6. package/.claude/agents/agent-bjorn-config-audit.md +103 -0
  7. package/.claude/agents/agent-builder-agent-creator.md +130 -0
  8. package/.claude/agents/agent-code-simplifier.md +53 -0
  9. package/.claude/agents/agent-dmitri-activity-crud.md +159 -0
  10. package/.claude/agents/agent-giuseppe-app-builder.md +208 -0
  11. package/.claude/agents/agent-gunther-mcp-tools.md +39 -0
  12. package/.claude/agents/agent-helga-workflow-config.md +204 -0
  13. package/.claude/agents/agent-igor-activity-mover-automation.md +125 -0
  14. package/.claude/agents/agent-ingrid-doc-templates.md +261 -0
  15. package/.claude/agents/agent-ivan-monolith.md +154 -0
  16. package/.claude/agents/agent-kenji-data-reader.md +86 -0
  17. package/.claude/agents/agent-lars-code-inspector.md +102 -0
  18. package/.claude/agents/agent-marco-mockup-builder.md +110 -0
  19. package/.claude/agents/agent-marcus-api-documenter.md +323 -0
  20. package/.claude/agents/agent-marketplace-publisher.md +280 -0
  21. package/.claude/agents/agent-marketplace-reviewer.md +309 -0
  22. package/.claude/agents/agent-permissions-handler.md +208 -0
  23. package/.claude/agents/agent-simple-writer.md +48 -0
  24. package/.claude/agents/agent-svetlana-code-review.md +171 -0
  25. package/.claude/agents/agent-tanya-test-runner.md +333 -0
  26. package/.claude/agents/agent-ui-designer.md +100 -0
  27. package/.claude/agents/agent-viktor-sql-insights.md +212 -0
  28. package/.claude/agents/agent-web-search.md +55 -0
  29. package/.claude/agents/agent-yevgeni-discussions.md +45 -0
  30. package/.claude/agents/agent-zara-zapier.md +159 -0
  31. package/.claude/agents/ragnar.md +68 -0
  32. package/.claude/commands/app-squad.md +135 -0
  33. package/.claude/commands/audit-squad.md +158 -0
  34. package/.claude/commands/autoplan.md +563 -0
  35. package/.claude/commands/cleanup-squad.md +98 -0
  36. package/.claude/commands/config-squad.md +106 -0
  37. package/.claude/commands/crud-squad.md +87 -0
  38. package/.claude/commands/data-squad.md +97 -0
  39. package/.claude/commands/debug-squad.md +303 -0
  40. package/.claude/commands/doc-squad.md +65 -0
  41. package/.claude/commands/handoff.md +137 -0
  42. package/.claude/commands/health.md +49 -0
  43. package/.claude/commands/help.md +29 -0
  44. package/.claude/commands/help:agents.md +151 -0
  45. package/.claude/commands/help:commands.md +78 -0
  46. package/.claude/commands/help:faq.md +79 -0
  47. package/.claude/commands/help:plugins.md +50 -0
  48. package/.claude/commands/help:skills.md +93 -0
  49. package/.claude/commands/help:tools.md +75 -0
  50. package/.claude/commands/hotfix-squad.md +112 -0
  51. package/.claude/commands/integration-squad.md +82 -0
  52. package/.claude/commands/janitor-squad.md +167 -0
  53. package/.claude/commands/learn-auto.md +120 -0
  54. package/.claude/commands/learn.md +120 -0
  55. package/.claude/commands/mcp-list.md +27 -0
  56. package/.claude/commands/onboard-squad.md +140 -0
  57. package/.claude/commands/plan-workspace.md +732 -0
  58. package/.claude/commands/prd.md +130 -0
  59. package/.claude/commands/project-status.md +82 -0
  60. package/.claude/commands/publish.md +138 -0
  61. package/.claude/commands/recap.md +69 -0
  62. package/.claude/commands/restore.md +64 -0
  63. package/.claude/commands/review-squad.md +152 -0
  64. package/.claude/commands/save.md +24 -0
  65. package/.claude/commands/stats.md +19 -0
  66. package/.claude/commands/swarm.md +210 -0
  67. package/.claude/commands/tool-builder.md +39 -0
  68. package/.claude/commands/ws-pull.md +44 -0
  69. package/.claude/skills/SDK-activity-patterns/SKILL.md +428 -0
  70. package/.claude/skills/SDK-document-templates/SKILL.md +1033 -0
  71. package/.claude/skills/SDK-function-fields/SKILL.md +542 -0
  72. package/.claude/skills/SDK-generate-skill/SKILL.md +92 -0
  73. package/.claude/skills/SDK-init-skill/SKILL.md +127 -0
  74. package/.claude/skills/SDK-insight-queries/SKILL.md +787 -0
  75. package/.claude/skills/SDK-ws-config-skill/SKILL.md +1139 -0
  76. package/.claude/skills/agent-structure/SKILL.md +98 -0
  77. package/.claude/skills/api-documentation-patterns/SKILL.md +474 -0
  78. package/.claude/skills/chrome-mcp-reference/SKILL.md +370 -0
  79. package/.claude/skills/delegation-routing/SKILL.md +202 -0
  80. package/.claude/skills/frontend-design/SKILL.md +254 -0
  81. package/.claude/skills/hailer-activity-mover/SKILL.md +213 -0
  82. package/.claude/skills/hailer-api-client/SKILL.md +518 -0
  83. package/.claude/skills/hailer-app-builder/SKILL.md +1440 -0
  84. package/.claude/skills/hailer-apps-pictures/SKILL.md +269 -0
  85. package/.claude/skills/hailer-design-system/SKILL.md +231 -0
  86. package/.claude/skills/hailer-monolith-automations/SKILL.md +686 -0
  87. package/.claude/skills/hailer-permissions-system/SKILL.md +121 -0
  88. package/.claude/skills/hailer-project-protocol/SKILL.md +488 -0
  89. package/.claude/skills/hailer-rest-api/SKILL.md +61 -0
  90. package/.claude/skills/hailer-rest-api/hailer-activities.md +184 -0
  91. package/.claude/skills/hailer-rest-api/hailer-admin.md +473 -0
  92. package/.claude/skills/hailer-rest-api/hailer-calendar.md +256 -0
  93. package/.claude/skills/hailer-rest-api/hailer-feed.md +249 -0
  94. package/.claude/skills/hailer-rest-api/hailer-insights.md +195 -0
  95. package/.claude/skills/hailer-rest-api/hailer-messaging.md +276 -0
  96. package/.claude/skills/hailer-rest-api/hailer-workflows.md +283 -0
  97. package/.claude/skills/insight-join-patterns/SKILL.md +174 -0
  98. package/.claude/skills/integration-patterns/SKILL.md +421 -0
  99. package/.claude/skills/json-only-output/SKILL.md +72 -0
  100. package/.claude/skills/lsp-setup/SKILL.md +160 -0
  101. package/.claude/skills/mcp-direct-tools/SKILL.md +153 -0
  102. package/.claude/skills/optional-parameters/SKILL.md +72 -0
  103. package/.claude/skills/publish-hailer-app/SKILL.md +221 -0
  104. package/.claude/skills/testing-patterns/SKILL.md +630 -0
  105. package/.claude/skills/tool-builder/SKILL.md +250 -0
  106. package/.claude/skills/tool-parameter-usage/SKILL.md +126 -0
  107. package/.claude/skills/tool-response-verification/SKILL.md +92 -0
  108. package/.claude/skills/zapier-hailer-patterns/SKILL.md +581 -0
  109. package/.opencode/agent/agent-ada-skill-builder.md +35 -0
  110. package/.opencode/agent/agent-alejandro-function-fields.md +39 -0
  111. package/.opencode/agent/agent-bjorn-config-audit.md +36 -0
  112. package/.opencode/agent/agent-builder-agent-creator.md +39 -0
  113. package/.opencode/agent/agent-code-simplifier.md +31 -0
  114. package/.opencode/agent/agent-dmitri-activity-crud.md +40 -0
  115. package/.opencode/agent/agent-giuseppe-app-builder.md +37 -0
  116. package/.opencode/agent/agent-gunther-mcp-tools.md +39 -0
  117. package/.opencode/agent/agent-helga-workflow-config.md +204 -0
  118. package/.opencode/agent/agent-igor-activity-mover-automation.md +46 -0
  119. package/.opencode/agent/agent-ingrid-doc-templates.md +39 -0
  120. package/.opencode/agent/agent-ivan-monolith.md +46 -0
  121. package/.opencode/agent/agent-kenji-data-reader.md +53 -0
  122. package/.opencode/agent/agent-lars-code-inspector.md +28 -0
  123. package/.opencode/agent/agent-marco-mockup-builder.md +42 -0
  124. package/.opencode/agent/agent-marcus-api-documenter.md +53 -0
  125. package/.opencode/agent/agent-marketplace-publisher.md +44 -0
  126. package/.opencode/agent/agent-marketplace-reviewer.md +42 -0
  127. package/.opencode/agent/agent-permissions-handler.md +50 -0
  128. package/.opencode/agent/agent-simple-writer.md +45 -0
  129. package/.opencode/agent/agent-svetlana-code-review.md +39 -0
  130. package/.opencode/agent/agent-tanya-test-runner.md +57 -0
  131. package/.opencode/agent/agent-ui-designer.md +56 -0
  132. package/.opencode/agent/agent-viktor-sql-insights.md +34 -0
  133. package/.opencode/agent/agent-web-search.md +42 -0
  134. package/.opencode/agent/agent-yevgeni-discussions.md +37 -0
  135. package/.opencode/agent/agent-zara-zapier.md +53 -0
  136. package/.opencode/commands/app-squad.md +135 -0
  137. package/.opencode/commands/audit-squad.md +158 -0
  138. package/.opencode/commands/autoplan.md +563 -0
  139. package/.opencode/commands/cleanup-squad.md +98 -0
  140. package/.opencode/commands/config-squad.md +106 -0
  141. package/.opencode/commands/crud-squad.md +87 -0
  142. package/.opencode/commands/data-squad.md +97 -0
  143. package/.opencode/commands/debug-squad.md +303 -0
  144. package/.opencode/commands/doc-squad.md +65 -0
  145. package/.opencode/commands/handoff.md +137 -0
  146. package/.opencode/commands/health.md +49 -0
  147. package/.opencode/commands/help-agents.md +151 -0
  148. package/.opencode/commands/help-commands.md +32 -0
  149. package/.opencode/commands/help-faq.md +29 -0
  150. package/.opencode/commands/help-plugins.md +28 -0
  151. package/.opencode/commands/help-skills.md +7 -0
  152. package/.opencode/commands/help-tools.md +40 -0
  153. package/.opencode/commands/help.md +28 -0
  154. package/.opencode/commands/hotfix-squad.md +112 -0
  155. package/.opencode/commands/integration-squad.md +82 -0
  156. package/.opencode/commands/janitor-squad.md +167 -0
  157. package/.opencode/commands/learn-auto.md +120 -0
  158. package/.opencode/commands/learn.md +120 -0
  159. package/.opencode/commands/mcp-list.md +27 -0
  160. package/.opencode/commands/onboard-squad.md +140 -0
  161. package/.opencode/commands/plan-workspace.md +732 -0
  162. package/.opencode/commands/prd.md +131 -0
  163. package/.opencode/commands/project-status.md +82 -0
  164. package/.opencode/commands/publish.md +138 -0
  165. package/.opencode/commands/recap.md +69 -0
  166. package/.opencode/commands/restore.md +64 -0
  167. package/.opencode/commands/review-squad.md +152 -0
  168. package/.opencode/commands/save.md +24 -0
  169. package/.opencode/commands/stats.md +19 -0
  170. package/.opencode/commands/swarm.md +210 -0
  171. package/.opencode/commands/tool-builder.md +39 -0
  172. package/.opencode/commands/ws-pull.md +44 -0
  173. package/.opencode/opencode.json +21 -0
  174. package/package.json +1 -1
  175. package/scripts/postinstall.cjs +64 -0
  176. package/scripts/test-hal-tools.ts +154 -0
@@ -0,0 +1,210 @@
1
+ ---
2
+ description: Orchestrator-driven parallel swarm for large-scale tasks
3
+ argument-hint: "description of what to do across many items"
4
+ allowed-tools: Task, Bash, Read, Glob
5
+ ---
6
+
7
+ # Swarm
8
+
9
+ Orchestrator-driven parallel execution: analyze the task, discover work items, pick agents, split into chunks, dispatch workers, aggregate results.
10
+
11
+ **Goal:** $ARGUMENTS
12
+
13
+ ## Protocol
14
+
15
+ ### Step 1: Analyze the Task
16
+
17
+ Read `$ARGUMENTS` and determine:
18
+
19
+ - **What needs to be done?** (review, edit, check, migrate, update, clean up)
20
+ - **What are the work items?** (files, activities, workflows, agents, skills, configs)
21
+ - **What scope?** (explicit path/glob from user, or infer from task description)
22
+
23
+ If the scope is unclear, use Glob or Bash to discover items:
24
+
25
+ ```
26
+ # Files
27
+ Glob("src/**/*.ts")
28
+ Glob(".claude/agents/*.md")
29
+ Glob("workspace/*/fields.ts")
30
+
31
+ # Activities (use Kenji to count/list)
32
+ Task(subagent_type="agent-kenji-data-reader", prompt="Count and list activity IDs for [workflow]")
33
+ ```
34
+
35
+ If fewer than 5 items are discovered, **abort swarm** and suggest running a regular squad or single agent instead. Swarm is for scale.
36
+
37
+ ### Step 2: Pick Agent(s)
38
+
39
+ Based on the task type, select the right agent(s):
40
+
41
+ | Task Type | Agent | Examples |
42
+ |-----------|-------|---------|
43
+ | Code review, security audit | **Svetlana** | "review for bugs", "security check", "find vulnerabilities" |
44
+ | Dead code, unused imports, type errors | **Lars** | "find dead code", "check types", "unused imports" |
45
+ | Small edits, string replacements, rule additions | **Simple Writer** | "add header to each file", "replace X with Y", "update rule" |
46
+ | Code cleanup, simplification | **Code Simplifier** | "clean up", "simplify", "refactor for clarity" |
47
+ | Config audit, structure validation | **Bjorn** | "check config", "validate structure", "audit settings" |
48
+ | Data state checks, field validation | **Kenji** | "check all activities", "verify field values", "find missing data" |
49
+ | Query patterns, data analysis | **Viktor** | "analyze patterns", "find anomalies across workflows" |
50
+ | Activity updates, bulk mutations | **Dmitri** | "update all activities", "move to phase", "set field values" |
51
+
52
+ **Multi-agent swarms:** If the task spans multiple domains, assign different agent types to different items. For example, "clean up the project" might use Lars for `.ts` files, Bjorn for config files, and Code Simplifier for app components.
53
+
54
+ ### Step 3: Calculate Workers
55
+
56
+ ```
57
+ items_count = total discovered items
58
+ items_per_worker = 10 (default)
59
+ max_workers = 5
60
+
61
+ worker_count = min(ceil(items_count / items_per_worker), max_workers)
62
+ ```
63
+
64
+ Split items into `worker_count` chunks. Try to keep chunks roughly equal size.
65
+
66
+ For multi-agent swarms, group items by agent type first, then chunk within each type.
67
+
68
+ ### Step 4: Dispatch Workers
69
+
70
+ Launch all workers in parallel using multiple Task tool calls in a single message. All workers run in background (`run_in_background: true`).
71
+
72
+ Each worker gets:
73
+
74
+ ```
75
+ Task(subagent_type="[selected-agent]",
76
+ run_in_background: true,
77
+ prompt="SWARM WORKER [N] of [TOTAL]
78
+
79
+ TASK: [User's description from $ARGUMENTS]
80
+
81
+ YOUR ITEMS ([count]):
82
+ - [item 1]
83
+ - [item 2]
84
+ - [item 3]
85
+ ...
86
+
87
+ Process each item and report results in this format:
88
+
89
+ RESULTS:
90
+ - [item]: [status] - [details]
91
+ - [item]: [status] - [details]
92
+
93
+ SUMMARY:
94
+ - Processed: [count]
95
+ - Passed: [count]
96
+ - Issues found: [count]
97
+ - Failed: [count]")
98
+ ```
99
+
100
+ Tell the user:
101
+ ```
102
+ Launched [worker_count] workers across [items_count] items.
103
+ Running in background - what else do you want to work on?
104
+ ```
105
+
106
+ ### Step 5: Collect Results
107
+
108
+ When workers complete (check via Read on output files or TaskOutput), aggregate all results.
109
+
110
+ If any worker failed or timed out:
111
+ - Report which items were in the failed worker's batch
112
+ - Offer to retry just those items
113
+
114
+ ### Step 6: Report
115
+
116
+ ```markdown
117
+ ## Swarm Report
118
+
119
+ ### Task
120
+ [User's description]
121
+
122
+ ### Execution
123
+ - **Items:** [total count]
124
+ - **Workers:** [worker count] x [agent type(s)]
125
+ - **Duration:** [time from dispatch to last worker completion]
126
+
127
+ ---
128
+
129
+ ### Results by Worker
130
+
131
+ #### Worker 1 ([agent type]) - [X items]
132
+ - [item]: [status] - [details]
133
+ - [item]: [status] - [details]
134
+ ...
135
+
136
+ #### Worker 2 ([agent type]) - [X items]
137
+ ...
138
+
139
+ ---
140
+
141
+ ### Aggregate Summary
142
+
143
+ | Status | Count |
144
+ |--------|-------|
145
+ | Passed / Clean | X |
146
+ | Issues Found | X |
147
+ | Failed / Error | X |
148
+
149
+ ### Issues Found
150
+ [Grouped and deduplicated list of all issues across all workers]
151
+
152
+ 1. **[item]**: [issue description]
153
+ 2. **[item]**: [issue description]
154
+ ...
155
+
156
+ ### Failed Items
157
+ [If any workers failed, list their items for retry]
158
+
159
+ ### Next Steps
160
+ - [Suggested follow-up based on results]
161
+ - [If issues found: suggest /hotfix-squad or Simple Writer to fix]
162
+ - [If edits made: suggest /review-squad to verify]
163
+ ```
164
+
165
+ ## Options
166
+
167
+ | Flag | Effect |
168
+ |------|--------|
169
+ | `--workers=N` | Override worker count (default: auto-calculated, max 5) |
170
+ | `--dry-run` | Show what would be dispatched without actually running |
171
+ | `--no-bg` | Run workers in foreground (wait for all to complete) |
172
+
173
+ ## Examples
174
+
175
+ ```
176
+ # Review all source files for security
177
+ /swarm "review all TypeScript files in src/ for security vulnerabilities"
178
+ → Discovers 47 .ts files, spawns 5 Svetlana workers
179
+
180
+ # Bulk edit agent files
181
+ /swarm "add a '## Version History' section to every agent file"
182
+ → Discovers 27 agent .md files, spawns 3 Simple Writer workers
183
+
184
+ # Validate workspace configs
185
+ /swarm "check all workflow field definitions for missing descriptions"
186
+ → Discovers 12 fields.ts files, spawns 2 Kenji workers
187
+
188
+ # Multi-agent cleanup
189
+ /swarm "clean up the entire apps/ directory"
190
+ → Discovers 34 files: 20 .tsx → Code Simplifier, 8 .ts → Lars, 6 configs → Bjorn
191
+ → Spawns 5 workers across 3 agent types
192
+
193
+ # Data validation
194
+ /swarm "verify all Customer activities have a valid email field"
195
+ → Kenji counts 200 customers, spawns 5 Kenji workers (40 each)
196
+
197
+ # Dry run to preview
198
+ /swarm "update all skills to use consistent headers" --dry-run
199
+ → Shows: "Would dispatch 4 Simple Writer workers across 32 skill files"
200
+ ```
201
+
202
+ ## Notes
203
+
204
+ - Minimum 5 items to trigger swarm (below that, use a regular agent)
205
+ - Default max 5 workers to avoid overwhelming the system
206
+ - Workers run in background by default so user can keep working
207
+ - Multi-agent swarms naturally emerge from the orchestrator's routing logic
208
+ - For write operations (Dmitri, Simple Writer), consider running --dry-run first
209
+ - Swarm vs Squad: Swarm is raw parallel execution without quality gates. Workers operate independently. Squads have convergence, synthesis, and loops. Use swarm for bulk independent items, squads for coordinated workflows.
210
+ - Swarm + squad can combine: `/swarm "review src/"` finds issues, then user can run `/hotfix-squad` on results. This is a manual handoff - user confirms.
@@ -0,0 +1,39 @@
1
+ ---
2
+ description: Activate tool-builder mode to implement a new MCP tool
3
+ ---
4
+
5
+ # Tool Builder Mode
6
+
7
+ Loading `tool-builder` skill for MCP tool patterns...
8
+
9
+ **What tool should I build?**
10
+
11
+ Please provide:
12
+
13
+ - **Tool Name**: `tool_name` (snake_case)
14
+ - **Purpose**: What does it do?
15
+ - **API Endpoint**: `v3.endpoint.method`
16
+ - **Request Format**: `[arg1, arg2]`
17
+ - **Response Format**: What the API returns
18
+ - **Target File**: Which file in `src/mcp/tools/`?
19
+ - **Tool Group**: READ | WRITE | PLAYGROUND
20
+
21
+ ---
22
+
23
+ **Example:**
24
+ ```
25
+ Tool Name: list_insights
26
+ Purpose: List all insights in workspace
27
+ API Endpoint: v3.insight.list
28
+ Request: [workspaceId]
29
+ Response: { insights: [{_id, name, query, sources}] }
30
+ Target File: insight.ts
31
+ Tool Group: PLAYGROUND
32
+ ```
33
+
34
+ I'll:
35
+ 1. Load tool-builder skill
36
+ 2. Read existing patterns in target file
37
+ 3. Implement the tool
38
+ 4. Register in src/app.ts
39
+ 5. Report what was created
@@ -0,0 +1,44 @@
1
+ ---
2
+ description: Pull workspace configuration from Hailer (READ-ONLY)
3
+ ---
4
+
5
+ Pull the current workspace configuration from Hailer and save it locally.
6
+
7
+ **What this does:**
8
+ - Downloads workflows, insights, teams, groups, and phases from Hailer workspace
9
+ - Saves configuration as JSON files to the `WORKSPACE_CONFIG_PATH` directory
10
+ - READ-ONLY operation - does not modify anything on Hailer
11
+ - Safe to run anytime
12
+
13
+ **Requirements:**
14
+ - Must have `WORKSPACE_CONFIG_PATH` set in `.env.local`
15
+ - Hailer credentials must be configured
16
+
17
+ **Instructions for Claude:**
18
+
19
+ 1. Read `.env.local` file to get `WORKSPACE_CONFIG_PATH`
20
+ 2. Run: `cd "$WORKSPACE_CONFIG_PATH" && npm run pull`
21
+ 3. **AUTOMATICALLY read the generated files to load context:**
22
+ - Read `workspace/enums.ts` (complete file - contains ALL field and phase IDs)
23
+ - List `workspace/` directory to see all workflow folders
24
+ - Read 1-2 example workflow configs (main.ts, fields.ts, phases.ts) to understand structure
25
+ 4. Provide summary of what workflows were pulled and confirm context is loaded
26
+
27
+ **What gets downloaded:**
28
+ - `workspace/enums.ts` - Type-safe field and phase ID enums for ALL workflows
29
+ - `workspace/workflows.ts` - Main workflows export
30
+ - `workspace/insights.ts` - SQL insight definitions
31
+ - `workspace/teams.ts` - Team structures
32
+ - `workspace/groups.ts` - User groups
33
+ - `workspace/<workflow_name>/` - Individual workflow configs (main.ts, fields.ts, phases.ts)
34
+
35
+ **Why automatic reading matters:**
36
+ - Loads all field/phase IDs into conversation context immediately
37
+ - Enables local-first strategy without manual file reads
38
+ - Saves 75% of API calls and hundreds of tokens on subsequent operations
39
+ - You'll know the workspace structure instantly
40
+
41
+ **Common use cases:**
42
+ - Backup current workspace configuration
43
+ - Review workflow structures locally
44
+ - Prepare for making configuration changes