sparkecoder 0.1.113 → 0.1.114

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 (113) hide show
  1. package/dist/agent/index.d.ts +3 -3
  2. package/dist/agent/index.js +57 -1
  3. package/dist/agent/index.js.map +1 -1
  4. package/dist/cli.js +57 -1
  5. package/dist/cli.js.map +1 -1
  6. package/dist/db/index.d.ts +2 -2
  7. package/dist/{index-Biy5JTop.d.ts → index-Bi8Ek02A.d.ts} +104 -104
  8. package/dist/index.d.ts +5 -5
  9. package/dist/index.js +57 -1
  10. package/dist/index.js.map +1 -1
  11. package/dist/{schema-CYSKJZ3m.d.ts → schema-ecQSnCMz.d.ts} +3 -3
  12. package/dist/{search-CVVfuBPZ.d.ts → search-DOzC4ojH.d.ts} +4 -4
  13. package/dist/server/index.js +57 -1
  14. package/dist/server/index.js.map +1 -1
  15. package/dist/skills/default/computer-use.md +63 -2
  16. package/dist/skills/default/recording.md +172 -0
  17. package/dist/tools/index.d.ts +3 -3
  18. package/package.json +1 -1
  19. package/src/skills/default/computer-use.md +63 -2
  20. package/src/skills/default/recording.md +172 -0
  21. package/web/.next/BUILD_ID +1 -1
  22. package/web/.next/standalone/web/.next/BUILD_ID +1 -1
  23. package/web/.next/standalone/web/.next/build-manifest.json +2 -2
  24. package/web/.next/standalone/web/.next/prerender-manifest.json +3 -3
  25. package/web/.next/standalone/web/.next/server/app/_global-error.html +2 -2
  26. package/web/.next/standalone/web/.next/server/app/_global-error.rsc +1 -1
  27. package/web/.next/standalone/web/.next/server/app/_global-error.segments/__PAGE__.segment.rsc +1 -1
  28. package/web/.next/standalone/web/.next/server/app/_global-error.segments/_full.segment.rsc +1 -1
  29. package/web/.next/standalone/web/.next/server/app/_global-error.segments/_head.segment.rsc +1 -1
  30. package/web/.next/standalone/web/.next/server/app/_global-error.segments/_index.segment.rsc +1 -1
  31. package/web/.next/standalone/web/.next/server/app/_global-error.segments/_tree.segment.rsc +1 -1
  32. package/web/.next/standalone/web/.next/server/app/_not-found.html +1 -1
  33. package/web/.next/standalone/web/.next/server/app/_not-found.rsc +1 -1
  34. package/web/.next/standalone/web/.next/server/app/_not-found.segments/_full.segment.rsc +1 -1
  35. package/web/.next/standalone/web/.next/server/app/_not-found.segments/_head.segment.rsc +1 -1
  36. package/web/.next/standalone/web/.next/server/app/_not-found.segments/_index.segment.rsc +1 -1
  37. package/web/.next/standalone/web/.next/server/app/_not-found.segments/_not-found/__PAGE__.segment.rsc +1 -1
  38. package/web/.next/standalone/web/.next/server/app/_not-found.segments/_not-found.segment.rsc +1 -1
  39. package/web/.next/standalone/web/.next/server/app/_not-found.segments/_tree.segment.rsc +1 -1
  40. package/web/.next/standalone/web/.next/server/app/agents.html +1 -1
  41. package/web/.next/standalone/web/.next/server/app/agents.rsc +1 -1
  42. package/web/.next/standalone/web/.next/server/app/agents.segments/!KG1haW4p/agents/__PAGE__.segment.rsc +1 -1
  43. package/web/.next/standalone/web/.next/server/app/agents.segments/!KG1haW4p/agents.segment.rsc +1 -1
  44. package/web/.next/standalone/web/.next/server/app/agents.segments/!KG1haW4p.segment.rsc +1 -1
  45. package/web/.next/standalone/web/.next/server/app/agents.segments/_full.segment.rsc +1 -1
  46. package/web/.next/standalone/web/.next/server/app/agents.segments/_head.segment.rsc +1 -1
  47. package/web/.next/standalone/web/.next/server/app/agents.segments/_index.segment.rsc +1 -1
  48. package/web/.next/standalone/web/.next/server/app/agents.segments/_tree.segment.rsc +1 -1
  49. package/web/.next/standalone/web/.next/server/app/docs/installation.html +2 -2
  50. package/web/.next/standalone/web/.next/server/app/docs/installation.rsc +1 -1
  51. package/web/.next/standalone/web/.next/server/app/docs/installation.segments/_full.segment.rsc +1 -1
  52. package/web/.next/standalone/web/.next/server/app/docs/installation.segments/_head.segment.rsc +1 -1
  53. package/web/.next/standalone/web/.next/server/app/docs/installation.segments/_index.segment.rsc +1 -1
  54. package/web/.next/standalone/web/.next/server/app/docs/installation.segments/_tree.segment.rsc +1 -1
  55. package/web/.next/standalone/web/.next/server/app/docs/installation.segments/docs/installation/__PAGE__.segment.rsc +1 -1
  56. package/web/.next/standalone/web/.next/server/app/docs/installation.segments/docs/installation.segment.rsc +1 -1
  57. package/web/.next/standalone/web/.next/server/app/docs/installation.segments/docs.segment.rsc +1 -1
  58. package/web/.next/standalone/web/.next/server/app/docs/skills.html +2 -2
  59. package/web/.next/standalone/web/.next/server/app/docs/skills.rsc +1 -1
  60. package/web/.next/standalone/web/.next/server/app/docs/skills.segments/_full.segment.rsc +1 -1
  61. package/web/.next/standalone/web/.next/server/app/docs/skills.segments/_head.segment.rsc +1 -1
  62. package/web/.next/standalone/web/.next/server/app/docs/skills.segments/_index.segment.rsc +1 -1
  63. package/web/.next/standalone/web/.next/server/app/docs/skills.segments/_tree.segment.rsc +1 -1
  64. package/web/.next/standalone/web/.next/server/app/docs/skills.segments/docs/skills/__PAGE__.segment.rsc +1 -1
  65. package/web/.next/standalone/web/.next/server/app/docs/skills.segments/docs/skills.segment.rsc +1 -1
  66. package/web/.next/standalone/web/.next/server/app/docs/skills.segments/docs.segment.rsc +1 -1
  67. package/web/.next/standalone/web/.next/server/app/docs/tools.html +2 -2
  68. package/web/.next/standalone/web/.next/server/app/docs/tools.rsc +1 -1
  69. package/web/.next/standalone/web/.next/server/app/docs/tools.segments/_full.segment.rsc +1 -1
  70. package/web/.next/standalone/web/.next/server/app/docs/tools.segments/_head.segment.rsc +1 -1
  71. package/web/.next/standalone/web/.next/server/app/docs/tools.segments/_index.segment.rsc +1 -1
  72. package/web/.next/standalone/web/.next/server/app/docs/tools.segments/_tree.segment.rsc +1 -1
  73. package/web/.next/standalone/web/.next/server/app/docs/tools.segments/docs/tools/__PAGE__.segment.rsc +1 -1
  74. package/web/.next/standalone/web/.next/server/app/docs/tools.segments/docs/tools.segment.rsc +1 -1
  75. package/web/.next/standalone/web/.next/server/app/docs/tools.segments/docs.segment.rsc +1 -1
  76. package/web/.next/standalone/web/.next/server/app/docs.html +2 -2
  77. package/web/.next/standalone/web/.next/server/app/docs.rsc +1 -1
  78. package/web/.next/standalone/web/.next/server/app/docs.segments/_full.segment.rsc +1 -1
  79. package/web/.next/standalone/web/.next/server/app/docs.segments/_head.segment.rsc +1 -1
  80. package/web/.next/standalone/web/.next/server/app/docs.segments/_index.segment.rsc +1 -1
  81. package/web/.next/standalone/web/.next/server/app/docs.segments/_tree.segment.rsc +1 -1
  82. package/web/.next/standalone/web/.next/server/app/docs.segments/docs/__PAGE__.segment.rsc +1 -1
  83. package/web/.next/standalone/web/.next/server/app/docs.segments/docs.segment.rsc +1 -1
  84. package/web/.next/standalone/web/.next/server/app/index.html +1 -1
  85. package/web/.next/standalone/web/.next/server/app/index.rsc +1 -1
  86. package/web/.next/standalone/web/.next/server/app/index.segments/!KG1haW4p/__PAGE__.segment.rsc +1 -1
  87. package/web/.next/standalone/web/.next/server/app/index.segments/!KG1haW4p.segment.rsc +1 -1
  88. package/web/.next/standalone/web/.next/server/app/index.segments/_full.segment.rsc +1 -1
  89. package/web/.next/standalone/web/.next/server/app/index.segments/_head.segment.rsc +1 -1
  90. package/web/.next/standalone/web/.next/server/app/index.segments/_index.segment.rsc +1 -1
  91. package/web/.next/standalone/web/.next/server/app/index.segments/_tree.segment.rsc +1 -1
  92. package/web/.next/standalone/web/.next/server/app/settings.html +1 -1
  93. package/web/.next/standalone/web/.next/server/app/settings.rsc +1 -1
  94. package/web/.next/standalone/web/.next/server/app/settings.segments/!KG1haW4p/settings/__PAGE__.segment.rsc +1 -1
  95. package/web/.next/standalone/web/.next/server/app/settings.segments/!KG1haW4p/settings.segment.rsc +1 -1
  96. package/web/.next/standalone/web/.next/server/app/settings.segments/!KG1haW4p.segment.rsc +1 -1
  97. package/web/.next/standalone/web/.next/server/app/settings.segments/_full.segment.rsc +1 -1
  98. package/web/.next/standalone/web/.next/server/app/settings.segments/_head.segment.rsc +1 -1
  99. package/web/.next/standalone/web/.next/server/app/settings.segments/_index.segment.rsc +1 -1
  100. package/web/.next/standalone/web/.next/server/app/settings.segments/_tree.segment.rsc +1 -1
  101. package/web/.next/standalone/web/.next/server/pages/404.html +1 -1
  102. package/web/.next/standalone/web/.next/server/pages/500.html +2 -2
  103. package/web/.next/standalone/web/.next/server/server-reference-manifest.js +1 -1
  104. package/web/.next/standalone/web/.next/server/server-reference-manifest.json +1 -1
  105. /package/web/.next/standalone/web/.next/static/{mC7Yp8aJpCL22mrYVzIEG → N09EiHl0JwEgsGMdCtwpB}/_buildManifest.js +0 -0
  106. /package/web/.next/standalone/web/.next/static/{mC7Yp8aJpCL22mrYVzIEG → N09EiHl0JwEgsGMdCtwpB}/_clientMiddlewareManifest.json +0 -0
  107. /package/web/.next/standalone/web/.next/static/{mC7Yp8aJpCL22mrYVzIEG → N09EiHl0JwEgsGMdCtwpB}/_ssgManifest.js +0 -0
  108. /package/web/.next/standalone/web/.next/static/static/{mC7Yp8aJpCL22mrYVzIEG → N09EiHl0JwEgsGMdCtwpB}/_buildManifest.js +0 -0
  109. /package/web/.next/standalone/web/.next/static/static/{mC7Yp8aJpCL22mrYVzIEG → N09EiHl0JwEgsGMdCtwpB}/_clientMiddlewareManifest.json +0 -0
  110. /package/web/.next/standalone/web/.next/static/static/{mC7Yp8aJpCL22mrYVzIEG → N09EiHl0JwEgsGMdCtwpB}/_ssgManifest.js +0 -0
  111. /package/web/.next/static/{mC7Yp8aJpCL22mrYVzIEG → N09EiHl0JwEgsGMdCtwpB}/_buildManifest.js +0 -0
  112. /package/web/.next/static/{mC7Yp8aJpCL22mrYVzIEG → N09EiHl0JwEgsGMdCtwpB}/_clientMiddlewareManifest.json +0 -0
  113. /package/web/.next/static/{mC7Yp8aJpCL22mrYVzIEG → N09EiHl0JwEgsGMdCtwpB}/_ssgManifest.js +0 -0
@@ -1,5 +1,5 @@
1
- import { C as Checkpoint, F as FileBackup, M as ModelMessage, a as Message, S as Session, L as LoadedSkill, T as TodoItem, b as ToolExecution, A as ActiveStream, I as IndexStatusRecord, c as IndexedChunk, d as SubagentExecution, e as SubagentStep, f as Terminal } from '../schema-CYSKJZ3m.js';
2
- export { N as NewActiveStream, g as NewCheckpoint, h as NewFileBackup, i as NewIndexStatusRecord, j as NewIndexedChunk, k as NewMessage, l as NewSession, m as NewSubagentExecution, n as NewTerminal, o as NewTodoItem, p as NewToolExecution, q as SessionConfig, r as TaskConfig, U as UserContentPart, s as UserFilePart, t as UserImagePart, u as UserModelMessage, v as UserTextPart } from '../schema-CYSKJZ3m.js';
1
+ import { C as Checkpoint, F as FileBackup, M as ModelMessage, a as Message, S as Session, L as LoadedSkill, T as TodoItem, b as ToolExecution, A as ActiveStream, I as IndexStatusRecord, c as IndexedChunk, d as SubagentExecution, e as SubagentStep, f as Terminal } from '../schema-ecQSnCMz.js';
2
+ export { N as NewActiveStream, g as NewCheckpoint, h as NewFileBackup, i as NewIndexStatusRecord, j as NewIndexedChunk, k as NewMessage, l as NewSession, m as NewSubagentExecution, n as NewTerminal, o as NewTodoItem, p as NewToolExecution, q as SessionConfig, r as TaskConfig, U as UserContentPart, s as UserFilePart, t as UserImagePart, u as UserModelMessage, v as UserTextPart } from '../schema-ecQSnCMz.js';
3
3
  import 'drizzle-orm/sqlite-core';
4
4
 
5
5
  /**
@@ -1,7 +1,7 @@
1
1
  import { ModelMessage, streamText } from 'ai';
2
- import { S as Session, b as ToolExecution, r as TaskConfig } from './schema-CYSKJZ3m.js';
2
+ import { S as Session, b as ToolExecution, r as TaskConfig } from './schema-ecQSnCMz.js';
3
3
  import { z } from 'zod';
4
- import { B as BashToolProgress, W as WriteFileProgress, S as SearchToolProgress } from './search-CVVfuBPZ.js';
4
+ import { B as BashToolProgress, W as WriteFileProgress, S as SearchToolProgress } from './search-DOzC4ojH.js';
5
5
 
6
6
  declare const ToolApprovalConfigSchema: z.ZodObject<{
7
7
  bash: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
@@ -38,25 +38,25 @@ declare const SessionConfigSchema: z.ZodObject<{
38
38
  iterations: z.ZodOptional<z.ZodNumber>;
39
39
  parentTaskId: z.ZodOptional<z.ZodString>;
40
40
  }, "strip", z.ZodTypeAny, {
41
- status: "running" | "completed" | "failed";
41
+ status: "completed" | "failed" | "running";
42
42
  enabled: boolean;
43
43
  outputSchema: Record<string, unknown>;
44
- webhookUrl?: string | undefined;
44
+ error?: string | undefined;
45
45
  maxIterations?: number | undefined;
46
+ webhookUrl?: string | undefined;
47
+ parentTaskId?: string | undefined;
46
48
  result?: unknown;
47
- error?: string | undefined;
48
49
  iterations?: number | undefined;
49
- parentTaskId?: string | undefined;
50
50
  }, {
51
- status: "running" | "completed" | "failed";
51
+ status: "completed" | "failed" | "running";
52
52
  enabled: boolean;
53
53
  outputSchema: Record<string, unknown>;
54
- webhookUrl?: string | undefined;
54
+ error?: string | undefined;
55
55
  maxIterations?: number | undefined;
56
+ webhookUrl?: string | undefined;
57
+ parentTaskId?: string | undefined;
56
58
  result?: unknown;
57
- error?: string | undefined;
58
59
  iterations?: number | undefined;
59
- parentTaskId?: string | undefined;
60
60
  }>>;
61
61
  computerUseEnabled: z.ZodOptional<z.ZodBoolean>;
62
62
  computerUseDisplayWidth: z.ZodOptional<z.ZodNumber>;
@@ -87,20 +87,20 @@ declare const SessionConfigSchema: z.ZodObject<{
87
87
  lastFiredAt: z.ZodOptional<z.ZodString>;
88
88
  createdAt: z.ZodString;
89
89
  }, "strip", z.ZodTypeAny, {
90
- enabled: boolean;
91
90
  id: string;
92
91
  name: string;
93
- cron: string;
94
- prompt: string;
92
+ enabled: boolean;
95
93
  createdAt: string;
94
+ prompt: string;
95
+ cron: string;
96
96
  replyChannel?: string | undefined;
97
97
  lastFiredAt?: string | undefined;
98
98
  }, {
99
99
  id: string;
100
100
  name: string;
101
- cron: string;
102
- prompt: string;
103
101
  createdAt: string;
102
+ prompt: string;
103
+ cron: string;
104
104
  enabled?: boolean | undefined;
105
105
  replyChannel?: string | undefined;
106
106
  lastFiredAt?: string | undefined;
@@ -115,19 +115,19 @@ declare const SessionConfigSchema: z.ZodObject<{
115
115
  lastHitAt: z.ZodOptional<z.ZodString>;
116
116
  createdAt: z.ZodString;
117
117
  }, "strip", z.ZodTypeAny, {
118
+ token: string;
118
119
  id: string;
119
120
  name: string;
120
121
  createdAt: string;
121
- token: string;
122
122
  wake: "now" | "next";
123
123
  hitCount: number;
124
124
  template?: string | undefined;
125
125
  lastHitAt?: string | undefined;
126
126
  }, {
127
+ token: string;
127
128
  id: string;
128
129
  name: string;
129
130
  createdAt: string;
130
- token: string;
131
131
  wake?: "now" | "next" | undefined;
132
132
  template?: string | undefined;
133
133
  hitCount?: number | undefined;
@@ -137,96 +137,96 @@ declare const SessionConfigSchema: z.ZodObject<{
137
137
  maxContextChars: number;
138
138
  toolApprovals?: Record<string, boolean> | undefined;
139
139
  approvalWebhook?: string | undefined;
140
- skillsDirectory?: string | undefined;
140
+ webhooks?: {
141
+ token: string;
142
+ id: string;
143
+ name: string;
144
+ createdAt: string;
145
+ wake: "now" | "next";
146
+ hitCount: number;
147
+ template?: string | undefined;
148
+ lastHitAt?: string | undefined;
149
+ }[] | undefined;
150
+ slack?: {
151
+ channel?: string | undefined;
152
+ threadTs?: string | undefined;
153
+ teamId?: string | undefined;
154
+ } | undefined;
141
155
  task?: {
142
- status: "running" | "completed" | "failed";
156
+ status: "completed" | "failed" | "running";
143
157
  enabled: boolean;
144
158
  outputSchema: Record<string, unknown>;
145
- webhookUrl?: string | undefined;
159
+ error?: string | undefined;
146
160
  maxIterations?: number | undefined;
161
+ webhookUrl?: string | undefined;
162
+ parentTaskId?: string | undefined;
147
163
  result?: unknown;
148
- error?: string | undefined;
149
164
  iterations?: number | undefined;
150
- parentTaskId?: string | undefined;
151
165
  } | undefined;
166
+ skillsDirectory?: string | undefined;
152
167
  computerUseEnabled?: boolean | undefined;
153
168
  computerUseDisplayWidth?: number | undefined;
154
169
  computerUseDisplayHeight?: number | undefined;
155
170
  role?: "orchestrator" | "worker" | "chat" | undefined;
156
171
  personality?: string | undefined;
157
172
  orchestratorSessionId?: string | undefined;
158
- slack?: {
159
- channel?: string | undefined;
160
- threadTs?: string | undefined;
161
- teamId?: string | undefined;
162
- } | undefined;
163
173
  schedules?: {
164
- enabled: boolean;
165
174
  id: string;
166
175
  name: string;
167
- cron: string;
168
- prompt: string;
176
+ enabled: boolean;
169
177
  createdAt: string;
178
+ prompt: string;
179
+ cron: string;
170
180
  replyChannel?: string | undefined;
171
181
  lastFiredAt?: string | undefined;
172
182
  }[] | undefined;
183
+ }, {
184
+ toolApprovals?: Record<string, boolean> | undefined;
185
+ approvalWebhook?: string | undefined;
173
186
  webhooks?: {
187
+ token: string;
174
188
  id: string;
175
189
  name: string;
176
190
  createdAt: string;
177
- token: string;
178
- wake: "now" | "next";
179
- hitCount: number;
191
+ wake?: "now" | "next" | undefined;
180
192
  template?: string | undefined;
193
+ hitCount?: number | undefined;
181
194
  lastHitAt?: string | undefined;
182
195
  }[] | undefined;
183
- }, {
184
- toolApprovals?: Record<string, boolean> | undefined;
185
- approvalWebhook?: string | undefined;
186
- skillsDirectory?: string | undefined;
187
- maxContextChars?: number | undefined;
196
+ slack?: {
197
+ channel?: string | undefined;
198
+ threadTs?: string | undefined;
199
+ teamId?: string | undefined;
200
+ } | undefined;
188
201
  task?: {
189
- status: "running" | "completed" | "failed";
202
+ status: "completed" | "failed" | "running";
190
203
  enabled: boolean;
191
204
  outputSchema: Record<string, unknown>;
192
- webhookUrl?: string | undefined;
205
+ error?: string | undefined;
193
206
  maxIterations?: number | undefined;
207
+ webhookUrl?: string | undefined;
208
+ parentTaskId?: string | undefined;
194
209
  result?: unknown;
195
- error?: string | undefined;
196
210
  iterations?: number | undefined;
197
- parentTaskId?: string | undefined;
198
211
  } | undefined;
212
+ skillsDirectory?: string | undefined;
213
+ maxContextChars?: number | undefined;
199
214
  computerUseEnabled?: boolean | undefined;
200
215
  computerUseDisplayWidth?: number | undefined;
201
216
  computerUseDisplayHeight?: number | undefined;
202
217
  role?: "orchestrator" | "worker" | "chat" | undefined;
203
218
  personality?: string | undefined;
204
219
  orchestratorSessionId?: string | undefined;
205
- slack?: {
206
- channel?: string | undefined;
207
- threadTs?: string | undefined;
208
- teamId?: string | undefined;
209
- } | undefined;
210
220
  schedules?: {
211
221
  id: string;
212
222
  name: string;
213
- cron: string;
214
- prompt: string;
215
223
  createdAt: string;
224
+ prompt: string;
225
+ cron: string;
216
226
  enabled?: boolean | undefined;
217
227
  replyChannel?: string | undefined;
218
228
  lastFiredAt?: string | undefined;
219
229
  }[] | undefined;
220
- webhooks?: {
221
- id: string;
222
- name: string;
223
- createdAt: string;
224
- token: string;
225
- wake?: "now" | "next" | undefined;
226
- template?: string | undefined;
227
- hitCount?: number | undefined;
228
- lastHitAt?: string | undefined;
229
- }[] | undefined;
230
230
  }>;
231
231
  declare const SparkcoderConfigSchema: z.ZodObject<{
232
232
  defaultModel: z.ZodDefault<z.ZodString>;
@@ -392,15 +392,15 @@ declare const SparkcoderConfigSchema: z.ZodObject<{
392
392
  expiresAt?: string | undefined;
393
393
  }>>;
394
394
  }, "strip", z.ZodTypeAny, {
395
- enabled: boolean;
396
395
  id: string;
397
396
  name: string;
398
- createdAt: string;
399
397
  transport: "http" | "sse" | "stdio";
400
- args?: string[] | undefined;
398
+ enabled: boolean;
399
+ createdAt: string;
401
400
  url?: string | undefined;
402
401
  headers?: Record<string, string> | undefined;
403
402
  command?: string | undefined;
403
+ args?: string[] | undefined;
404
404
  oauth?: {
405
405
  authorizationUrl?: string | undefined;
406
406
  tokenUrl?: string | undefined;
@@ -413,13 +413,13 @@ declare const SparkcoderConfigSchema: z.ZodObject<{
413
413
  }, {
414
414
  id: string;
415
415
  name: string;
416
- createdAt: string;
417
416
  transport: "http" | "sse" | "stdio";
418
- enabled?: boolean | undefined;
419
- args?: string[] | undefined;
417
+ createdAt: string;
420
418
  url?: string | undefined;
421
419
  headers?: Record<string, string> | undefined;
422
420
  command?: string | undefined;
421
+ args?: string[] | undefined;
422
+ enabled?: boolean | undefined;
423
423
  oauth?: {
424
424
  authorizationUrl?: string | undefined;
425
425
  tokenUrl?: string | undefined;
@@ -432,15 +432,15 @@ declare const SparkcoderConfigSchema: z.ZodObject<{
432
432
  }>, "many">>>>;
433
433
  }, "strip", z.ZodTypeAny, {
434
434
  servers?: {
435
- enabled: boolean;
436
435
  id: string;
437
436
  name: string;
438
- createdAt: string;
439
437
  transport: "http" | "sse" | "stdio";
440
- args?: string[] | undefined;
438
+ enabled: boolean;
439
+ createdAt: string;
441
440
  url?: string | undefined;
442
441
  headers?: Record<string, string> | undefined;
443
442
  command?: string | undefined;
443
+ args?: string[] | undefined;
444
444
  oauth?: {
445
445
  authorizationUrl?: string | undefined;
446
446
  tokenUrl?: string | undefined;
@@ -455,13 +455,13 @@ declare const SparkcoderConfigSchema: z.ZodObject<{
455
455
  servers?: {
456
456
  id: string;
457
457
  name: string;
458
- createdAt: string;
459
458
  transport: "http" | "sse" | "stdio";
460
- enabled?: boolean | undefined;
461
- args?: string[] | undefined;
459
+ createdAt: string;
462
460
  url?: string | undefined;
463
461
  headers?: Record<string, string> | undefined;
464
462
  command?: string | undefined;
463
+ args?: string[] | undefined;
464
+ enabled?: boolean | undefined;
465
465
  oauth?: {
466
466
  authorizationUrl?: string | undefined;
467
467
  tokenUrl?: string | undefined;
@@ -504,6 +504,7 @@ declare const SparkcoderConfigSchema: z.ZodObject<{
504
504
  allowedEmails?: string[] | undefined;
505
505
  }>>;
506
506
  }, "strip", z.ZodTypeAny, {
507
+ defaultModel: string;
507
508
  toolApprovals: {
508
509
  bash: boolean;
509
510
  write_file: boolean;
@@ -511,7 +512,6 @@ declare const SparkcoderConfigSchema: z.ZodObject<{
511
512
  load_skill: boolean;
512
513
  todo: boolean;
513
514
  };
514
- defaultModel: string;
515
515
  skills: {
516
516
  directory: string;
517
517
  additionalDirectories: string[];
@@ -527,21 +527,11 @@ declare const SparkcoderConfigSchema: z.ZodObject<{
527
527
  publicUrl?: string | undefined;
528
528
  };
529
529
  databasePath: string;
530
+ workingDirectory?: string | undefined;
530
531
  approvalWebhook?: string | undefined;
531
- slack?: {
532
- botToken?: string | undefined;
533
- signingSecret?: string | undefined;
534
- defaultOrchestratorName?: string | undefined;
535
- allowedUsers?: string[] | undefined;
536
- allowedChannels?: string[] | undefined;
537
- allowDmsFromAnyone?: boolean | undefined;
538
- deniedReplyEnabled?: boolean | undefined;
539
- deniedReplyTemplate?: string | undefined;
540
- } | undefined;
541
532
  webhooks?: {
542
533
  token?: string | undefined;
543
534
  } | undefined;
544
- workingDirectory?: string | undefined;
545
535
  remoteServer?: {
546
536
  url?: string | undefined;
547
537
  authKey?: string | undefined;
@@ -554,17 +544,27 @@ declare const SparkcoderConfigSchema: z.ZodObject<{
554
544
  httpUrl?: string | undefined;
555
545
  namespace?: string | undefined;
556
546
  } | undefined;
547
+ slack?: {
548
+ botToken?: string | undefined;
549
+ signingSecret?: string | undefined;
550
+ defaultOrchestratorName?: string | undefined;
551
+ allowedUsers?: string[] | undefined;
552
+ allowedChannels?: string[] | undefined;
553
+ allowDmsFromAnyone?: boolean | undefined;
554
+ deniedReplyEnabled?: boolean | undefined;
555
+ deniedReplyTemplate?: string | undefined;
556
+ } | undefined;
557
557
  mcp?: {
558
558
  servers?: {
559
- enabled: boolean;
560
559
  id: string;
561
560
  name: string;
562
- createdAt: string;
563
561
  transport: "http" | "sse" | "stdio";
564
- args?: string[] | undefined;
562
+ enabled: boolean;
563
+ createdAt: string;
565
564
  url?: string | undefined;
566
565
  headers?: Record<string, string> | undefined;
567
566
  command?: string | undefined;
567
+ args?: string[] | undefined;
568
568
  oauth?: {
569
569
  authorizationUrl?: string | undefined;
570
570
  tokenUrl?: string | undefined;
@@ -585,6 +585,8 @@ declare const SparkcoderConfigSchema: z.ZodObject<{
585
585
  allowedEmails?: string[] | undefined;
586
586
  } | undefined;
587
587
  }, {
588
+ defaultModel?: string | undefined;
589
+ workingDirectory?: string | undefined;
588
590
  toolApprovals?: {
589
591
  bash?: boolean | undefined;
590
592
  write_file?: boolean | undefined;
@@ -593,21 +595,6 @@ declare const SparkcoderConfigSchema: z.ZodObject<{
593
595
  todo?: boolean | undefined;
594
596
  } | undefined;
595
597
  approvalWebhook?: string | undefined;
596
- slack?: {
597
- botToken?: string | undefined;
598
- signingSecret?: string | undefined;
599
- defaultOrchestratorName?: string | undefined;
600
- allowedUsers?: string[] | undefined;
601
- allowedChannels?: string[] | undefined;
602
- allowDmsFromAnyone?: boolean | undefined;
603
- deniedReplyEnabled?: boolean | undefined;
604
- deniedReplyTemplate?: string | undefined;
605
- } | undefined;
606
- webhooks?: {
607
- token?: string | undefined;
608
- } | undefined;
609
- workingDirectory?: string | undefined;
610
- defaultModel?: string | undefined;
611
598
  skills?: {
612
599
  directory?: string | undefined;
613
600
  additionalDirectories?: string[] | undefined;
@@ -622,6 +609,9 @@ declare const SparkcoderConfigSchema: z.ZodObject<{
622
609
  host?: string | undefined;
623
610
  publicUrl?: string | undefined;
624
611
  } | undefined;
612
+ webhooks?: {
613
+ token?: string | undefined;
614
+ } | undefined;
625
615
  databasePath?: string | undefined;
626
616
  remoteServer?: {
627
617
  url?: string | undefined;
@@ -635,17 +625,27 @@ declare const SparkcoderConfigSchema: z.ZodObject<{
635
625
  include?: string[] | undefined;
636
626
  exclude?: string[] | undefined;
637
627
  } | undefined;
628
+ slack?: {
629
+ botToken?: string | undefined;
630
+ signingSecret?: string | undefined;
631
+ defaultOrchestratorName?: string | undefined;
632
+ allowedUsers?: string[] | undefined;
633
+ allowedChannels?: string[] | undefined;
634
+ allowDmsFromAnyone?: boolean | undefined;
635
+ deniedReplyEnabled?: boolean | undefined;
636
+ deniedReplyTemplate?: string | undefined;
637
+ } | undefined;
638
638
  mcp?: {
639
639
  servers?: {
640
640
  id: string;
641
641
  name: string;
642
- createdAt: string;
643
642
  transport: "http" | "sse" | "stdio";
644
- enabled?: boolean | undefined;
645
- args?: string[] | undefined;
643
+ createdAt: string;
646
644
  url?: string | undefined;
647
645
  headers?: Record<string, string> | undefined;
648
646
  command?: string | undefined;
647
+ args?: string[] | undefined;
648
+ enabled?: boolean | undefined;
649
649
  oauth?: {
650
650
  authorizationUrl?: string | undefined;
651
651
  tokenUrl?: string | undefined;
package/dist/index.d.ts CHANGED
@@ -1,11 +1,11 @@
1
- import { R as ResolvedConfig } from './index-Biy5JTop.js';
2
- export { A as Agent, a as AgentOptions, b as AgentRunOptions, c as AgentStreamResult, S as SparkcoderConfig, T as ToolApprovalConfig } from './index-Biy5JTop.js';
1
+ import { R as ResolvedConfig } from './index-Bi8Ek02A.js';
2
+ export { A as Agent, a as AgentOptions, b as AgentRunOptions, c as AgentStreamResult, S as SparkcoderConfig, T as ToolApprovalConfig } from './index-Bi8Ek02A.js';
3
3
  export { ServerOptions, createApp, startServer, stopServer } from './server/index.js';
4
4
  export { checkpointQueries, closeDatabase, fileBackupQueries, getDb, initDatabase, messageQueries, sessionQueries, skillQueries, todoQueries, toolExecutionQueries } from './db/index.js';
5
- import { F as FileBackup, C as Checkpoint } from './schema-CYSKJZ3m.js';
6
- export { a as Message, M as ModelMessage, S as Session, q as SessionConfig, f as Terminal, T as TodoItem, b as ToolExecution } from './schema-CYSKJZ3m.js';
5
+ import { F as FileBackup, C as Checkpoint } from './schema-ecQSnCMz.js';
6
+ export { a as Message, M as ModelMessage, S as Session, q as SessionConfig, f as Terminal, T as TodoItem, b as ToolExecution } from './schema-ecQSnCMz.js';
7
7
  export { createLoadSkillTool, createReadFileTool, createTodoTool, createTools } from './tools/index.js';
8
- export { c as createBashTool, a as createWriteFileTool } from './search-CVVfuBPZ.js';
8
+ export { c as createBashTool, a as createWriteFileTool } from './search-DOzC4ojH.js';
9
9
  import 'ai';
10
10
  import 'zod';
11
11
  import 'hono/types';
package/dist/index.js CHANGED
@@ -7540,6 +7540,8 @@ ${JSON.stringify(outputSchema, null, 2)}
7540
7540
  `;
7541
7541
  }
7542
7542
  function buildOrchestratorPromptAddendum() {
7543
+ const platform3 = process.platform === "darwin" ? "darwin" : "other";
7544
+ const computerUseAvailable = platform3 === "darwin";
7543
7545
  return `
7544
7546
  ## Orchestrator Mode
7545
7547
 
@@ -7612,9 +7614,63 @@ If the user asks "add the GitHub MCP" or "remember that I prefer Python", load t
7612
7614
  ### Typical flow
7613
7615
 
7614
7616
  1. Inbound event arrives (any channel).
7615
- 2. You decompose, \`spawn\` one or more workers with explicit goals.
7617
+ 2. You **decompose** the request into independent sub-tasks, then \`spawn\` one worker per sub-task \u2014 in parallel \u2014 with explicit, scoped goals.
7616
7618
  3. Workers run autonomously. They wake you via SYSTEM events when done / failed / blocked.
7617
7619
  4. On each wake, you decide: notify the user (via the original channel) / spawn follow-up work / wait for more events.
7620
+
7621
+ ### Decomposition rule
7622
+
7623
+ If a single user message contains **multiple independent asks** that don't share state, spawn **one worker per ask, all in the same turn** (parallel \`spawn\` calls). They run concurrently and finish faster. Examples of when to split:
7624
+
7625
+ - *"Take a screenshot of the desktop AND open Calculator"*
7626
+ \u2192 spawn \`screenshot\` worker + spawn \`open-calculator\` worker (independent).
7627
+ - *"Run the tests and also tell me what changed since yesterday"*
7628
+ \u2192 spawn \`run-tests\` worker + spawn \`git-diff-since-yesterday\` worker.
7629
+ - *"Fix the typo in README and bump the version"*
7630
+ \u2192 spawn \`fix-readme-typo\` worker + spawn \`bump-version\` worker.
7631
+
7632
+ When NOT to split (keep as one worker):
7633
+
7634
+ - The asks share state (one's output feeds the other).
7635
+ - The asks are tightly coupled (e.g. *"refactor X and run its tests"* \u2014 the tests depend on the refactor).
7636
+ - The asks are trivially small (one or two tool calls each); spawning overhead exceeds the parallelism win.
7637
+
7638
+ ### Prefer headless tools
7639
+
7640
+ When spawning a worker, push it toward the *cheapest tool that gets the job done*:
7641
+
7642
+ 1. **Bash / file tools** for anything with a CLI (git, npm, brew, builds, tests, file editing, HTTP via curl, scripting).
7643
+ 2. **agent-browser** (\`load_skill browser\`) for *anything* in a web browser \u2014 refs from \`snapshot -i\` are deterministic, ~100\xD7 cheaper in tokens than pixel coordinates, work cross-platform, and don't need any host permissions.${computerUseAvailable ? `
7644
+ 3. **Computer use** is the last resort \u2014 only when the task genuinely requires a native macOS GUI app with no CLI / API equivalent (System Settings, Calculator, Finder operations that don't have CLI flags, complex cross-app drag/drop, demos where the user wants to *see* the screen).
7645
+
7646
+ A common anti-pattern: a worker reaches for computer use because the user phrased the request visually ("open the website and click the button"). Almost always wrong \u2014 that's a job for the browser skill, not the desktop. Coach the worker in its goal text: *"Use the browser skill (\`load_skill browser\` + \`agent-browser\` with refs from \`snapshot -i\`) to open the site and click the button. Don't use computer use for browser work."*
7647
+
7648
+ ### Serialize desktop / computer-use tasks
7649
+
7650
+ There is exactly **one** desktop, mouse, and keyboard on the host. If two or more workers both need the **\`computer\` tool** (clicking, typing, taking desktop screenshots, opening apps, switching windows), they will **fight over the same screen** \u2014 windows will steal focus from each other, screenshots will catch the wrong app, mouse clicks will land on the wrong target.
7651
+
7652
+ **Rule**: when spawning workers, look at each one's goal:
7653
+
7654
+ - Does it require **GUI interaction** (open an app, click, type in a window, screenshot the desktop, navigate the OS, drive a real browser/terminal window)? \u2192 mark it as a **desktop task**.
7655
+ - Does it only need **headless tools** (bash, file edits, web fetches, code analysis, git, builds, tests run non-interactively)? \u2192 it's a **headless task**.
7656
+
7657
+ Then:
7658
+
7659
+ - **Spawn ALL headless tasks in parallel** (in the same turn).
7660
+ - **Run desktop tasks one at a time**, even if there are multiple of them. Either:
7661
+ - Spawn the first one now, wait for its \`worker.completed\`, then spawn the next; OR
7662
+ - Tell the user the desktop tasks will run sequentially and pick the most important one first.
7663
+
7664
+ Example: *"Take a screenshot of Calculator AND run the test suite AND open System Settings"*:
7665
+ - \u2713 \`screenshot-calculator\` (desktop) \u2014 spawn now
7666
+ - \u2713 \`run-tests\` (headless) \u2014 spawn now, in parallel
7667
+ - \u23F3 \`open-system-settings\` (desktop) \u2014 wait until \`screenshot-calculator\` completes, THEN spawn.
7668
+
7669
+ Headless workers never interfere with desktop workers (they don't touch the screen), so they always run in parallel.
7670
+
7671
+ When you spawn a **desktop worker**, include a one-liner in the goal asking it to **record the session by default** (\`screencapture -v -V <seconds> -C\` on macOS) and return the recording path in its result, *unless* the task is long-running / boring / contains sensitive content. The recording lets you (and the user) replay what actually happened on screen. When the worker reports back, mention the recording path in your reply via the original channel.` : ""}
7672
+
7673
+ Default bias: **when in doubt, decompose**. Two workers running in parallel and reporting independently is almost always better UX than one worker doing things sequentially.
7618
7674
  `;
7619
7675
  }
7620
7676
  function createSummaryPrompt(conversationHistory) {