squads-cli 0.6.1 → 0.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 (112) hide show
  1. package/README.md +196 -1152
  2. package/dist/auth-YW3UPFSB.js +23 -0
  3. package/dist/autonomy-BWTVDEAT.js +102 -0
  4. package/dist/autonomy-BWTVDEAT.js.map +1 -0
  5. package/dist/chunk-3KCWNZWW.js +401 -0
  6. package/dist/chunk-3KCWNZWW.js.map +1 -0
  7. package/dist/chunk-67RO2HKR.js +174 -0
  8. package/dist/chunk-67RO2HKR.js.map +1 -0
  9. package/dist/chunk-7JVD7RD4.js +275 -0
  10. package/dist/chunk-7JVD7RD4.js.map +1 -0
  11. package/dist/chunk-BODLDQY7.js +452 -0
  12. package/dist/chunk-BODLDQY7.js.map +1 -0
  13. package/dist/chunk-FFFCFZ6A.js +121 -0
  14. package/dist/chunk-FFFCFZ6A.js.map +1 -0
  15. package/dist/chunk-FIWT2NMM.js +165 -0
  16. package/dist/chunk-FIWT2NMM.js.map +1 -0
  17. package/dist/chunk-L6GQCHDF.js +222 -0
  18. package/dist/chunk-L6GQCHDF.js.map +1 -0
  19. package/dist/{chunk-O7UV3FWI.js → chunk-LDM62TIX.js} +2 -2
  20. package/dist/chunk-LDM62TIX.js.map +1 -0
  21. package/dist/chunk-LOA3KWYJ.js +294 -0
  22. package/dist/chunk-LOA3KWYJ.js.map +1 -0
  23. package/dist/chunk-NA45DFXY.js +616 -0
  24. package/dist/chunk-NA45DFXY.js.map +1 -0
  25. package/dist/{chunk-4CMAEQQY.js → chunk-NQN6JPI7.js} +4 -3
  26. package/dist/chunk-NQN6JPI7.js.map +1 -0
  27. package/dist/chunk-OQJHPULO.js +103 -0
  28. package/dist/chunk-OQJHPULO.js.map +1 -0
  29. package/dist/chunk-QHNUMM4V.js +87 -0
  30. package/dist/chunk-QHNUMM4V.js.map +1 -0
  31. package/dist/chunk-RM6BWILN.js +74 -0
  32. package/dist/chunk-RM6BWILN.js.map +1 -0
  33. package/dist/chunk-WBR5J7EX.js +90 -0
  34. package/dist/chunk-WBR5J7EX.js.map +1 -0
  35. package/dist/chunk-Z2UKDBNL.js +162 -0
  36. package/dist/chunk-Z2UKDBNL.js.map +1 -0
  37. package/dist/cli.js +2151 -12594
  38. package/dist/cli.js.map +1 -1
  39. package/dist/context-M2A2DOFV.js +291 -0
  40. package/dist/context-M2A2DOFV.js.map +1 -0
  41. package/dist/context-feed-JMNW4GAM.js +391 -0
  42. package/dist/context-feed-JMNW4GAM.js.map +1 -0
  43. package/dist/cost-N37I4UTA.js +274 -0
  44. package/dist/cost-N37I4UTA.js.map +1 -0
  45. package/dist/create-554W5HNU.js +286 -0
  46. package/dist/create-554W5HNU.js.map +1 -0
  47. package/dist/daemon-XWPQPPPN.js +546 -0
  48. package/dist/daemon-XWPQPPPN.js.map +1 -0
  49. package/dist/dashboard-L7YKVQEB.js +945 -0
  50. package/dist/dashboard-L7YKVQEB.js.map +1 -0
  51. package/dist/dashboard-MFNRLCEE.js +794 -0
  52. package/dist/dashboard-MFNRLCEE.js.map +1 -0
  53. package/dist/doctor-RG75M5RO.js +346 -0
  54. package/dist/doctor-RG75M5RO.js.map +1 -0
  55. package/dist/env-config-KCLDBKYX.js +21 -0
  56. package/dist/exec-JQKBF7BL.js +197 -0
  57. package/dist/exec-JQKBF7BL.js.map +1 -0
  58. package/dist/feedback-KA2UYBZG.js +229 -0
  59. package/dist/feedback-KA2UYBZG.js.map +1 -0
  60. package/dist/github-UQTM5KMS.js +23 -0
  61. package/dist/goal-EOPC5ZCD.js +168 -0
  62. package/dist/goal-EOPC5ZCD.js.map +1 -0
  63. package/dist/health-3FZDOSR5.js +209 -0
  64. package/dist/health-3FZDOSR5.js.map +1 -0
  65. package/dist/history-TFVXJEDH.js +229 -0
  66. package/dist/history-TFVXJEDH.js.map +1 -0
  67. package/dist/index.js +1 -1
  68. package/dist/index.js.map +1 -1
  69. package/dist/init-UOWTNMIE.js +747 -0
  70. package/dist/init-UOWTNMIE.js.map +1 -0
  71. package/dist/kpi-2SQ2WCVT.js +413 -0
  72. package/dist/kpi-2SQ2WCVT.js.map +1 -0
  73. package/dist/learn-6ERTERAO.js +269 -0
  74. package/dist/learn-6ERTERAO.js.map +1 -0
  75. package/dist/list-KSOMUBMB.js +92 -0
  76. package/dist/list-KSOMUBMB.js.map +1 -0
  77. package/dist/login-ST6PAXYE.js +155 -0
  78. package/dist/login-ST6PAXYE.js.map +1 -0
  79. package/dist/memory-3CSNKXIL.js +562 -0
  80. package/dist/memory-3CSNKXIL.js.map +1 -0
  81. package/dist/progress-FKG4V2VH.js +202 -0
  82. package/dist/progress-FKG4V2VH.js.map +1 -0
  83. package/dist/providers-66PDCORB.js +65 -0
  84. package/dist/providers-66PDCORB.js.map +1 -0
  85. package/dist/results-2MJFLWEO.js +224 -0
  86. package/dist/results-2MJFLWEO.js.map +1 -0
  87. package/dist/run-72OQLH5A.js +2685 -0
  88. package/dist/run-72OQLH5A.js.map +1 -0
  89. package/dist/session-6H67XPAQ.js +64 -0
  90. package/dist/session-6H67XPAQ.js.map +1 -0
  91. package/dist/{chunk-NHGLXN2F.js → sessions-GVQIMN4W.js} +23 -459
  92. package/dist/sessions-GVQIMN4W.js.map +1 -0
  93. package/dist/{squad-parser-4BI3G4RS.js → squad-parser-CM3HOIWM.js} +2 -2
  94. package/dist/squad-parser-CM3HOIWM.js.map +1 -0
  95. package/dist/stats-ONZI557Q.js +335 -0
  96. package/dist/stats-ONZI557Q.js.map +1 -0
  97. package/dist/status-FYH42FTB.js +346 -0
  98. package/dist/status-FYH42FTB.js.map +1 -0
  99. package/dist/sync-HJZJNXHW.js +800 -0
  100. package/dist/sync-HJZJNXHW.js.map +1 -0
  101. package/dist/update-B4WMUOPO.js +83 -0
  102. package/dist/update-B4WMUOPO.js.map +1 -0
  103. package/dist/{update-ALJKFFM7.js → update-L7FGHN6W.js} +2 -2
  104. package/dist/update-L7FGHN6W.js.map +1 -0
  105. package/package.json +18 -10
  106. package/dist/chunk-4CMAEQQY.js.map +0 -1
  107. package/dist/chunk-NHGLXN2F.js.map +0 -1
  108. package/dist/chunk-O7UV3FWI.js.map +0 -1
  109. package/dist/sessions-6PB7ALCE.js +0 -16
  110. /package/dist/{sessions-6PB7ALCE.js.map → auth-YW3UPFSB.js.map} +0 -0
  111. /package/dist/{squad-parser-4BI3G4RS.js.map → env-config-KCLDBKYX.js.map} +0 -0
  112. /package/dist/{update-ALJKFFM7.js.map → github-UQTM5KMS.js.map} +0 -0
@@ -0,0 +1,346 @@
1
+ #!/usr/bin/env node
2
+ import {
3
+ cleanupStaleSessions,
4
+ getLiveSessionSummaryAsync
5
+ } from "./chunk-BODLDQY7.js";
6
+ import {
7
+ fetchOperationalStatus
8
+ } from "./chunk-3KCWNZWW.js";
9
+ import {
10
+ formatDuration,
11
+ formatRelativeTime,
12
+ getExecutionStats,
13
+ listExecutions
14
+ } from "./chunk-67RO2HKR.js";
15
+ import {
16
+ Events,
17
+ track
18
+ } from "./chunk-L6GQCHDF.js";
19
+ import {
20
+ findSquadsDir,
21
+ listAgents,
22
+ listSquads,
23
+ loadSquad,
24
+ resolveExecutionContext
25
+ } from "./chunk-LDM62TIX.js";
26
+ import {
27
+ findMemoryDir,
28
+ getSquadState
29
+ } from "./chunk-ZTQ7ISUR.js";
30
+ import {
31
+ checkForUpdate
32
+ } from "./chunk-NQN6JPI7.js";
33
+ import {
34
+ RESET,
35
+ bold,
36
+ box,
37
+ colors,
38
+ gradient,
39
+ icons,
40
+ padEnd,
41
+ privacyHeader,
42
+ writeLine
43
+ } from "./chunk-N7KDWU4W.js";
44
+ import "./chunk-7OCVIDC7.js";
45
+
46
+ // src/commands/status.ts
47
+ import { existsSync, statSync } from "fs";
48
+ import { join } from "path";
49
+ async function statusCommand(squadName, options = {}) {
50
+ await track(Events.CLI_STATUS, { squad: squadName || "all", verbose: options.verbose });
51
+ const squadsDir = findSquadsDir();
52
+ if (!squadsDir) {
53
+ writeLine(`${colors.red}No .agents/squads directory found${RESET}`);
54
+ writeLine(`${colors.dim}Run \`squads init\` to create one.${RESET}`);
55
+ process.exit(1);
56
+ }
57
+ if (squadName) {
58
+ await showSquadStatus(squadName, squadsDir, options);
59
+ } else {
60
+ await showOverallStatus(squadsDir, options);
61
+ }
62
+ }
63
+ async function showOverallStatus(squadsDir, options) {
64
+ const squads = listSquads(squadsDir);
65
+ const memoryDir = findMemoryDir();
66
+ cleanupStaleSessions();
67
+ const sessionSummary = await getLiveSessionSummaryAsync();
68
+ if (options.json) {
69
+ const execStats2 = getExecutionStats({ since: new Date(Date.now() - 24 * 60 * 60 * 1e3) });
70
+ const squadData = squads.map((name) => {
71
+ const agents = listAgents(squadsDir, name);
72
+ const states = memoryDir ? getSquadState(name) : [];
73
+ return { name, agentCount: agents.length, memoryEntries: states.length };
74
+ });
75
+ console.log(JSON.stringify({
76
+ ok: true,
77
+ command: "status",
78
+ data: {
79
+ squads: squadData,
80
+ totalSquads: squads.length,
81
+ sessions: sessionSummary,
82
+ executions24h: execStats2,
83
+ memoryEnabled: !!memoryDir
84
+ }
85
+ }, null, 2));
86
+ return;
87
+ }
88
+ writeLine();
89
+ writeLine(` ${gradient("squads")} ${colors.dim}status${RESET}`);
90
+ const updateInfo = checkForUpdate();
91
+ if (updateInfo.updateAvailable) {
92
+ writeLine(` ${colors.cyan}\u2B06${RESET} Update available: ${colors.dim}${updateInfo.currentVersion}${RESET} \u2192 ${colors.green}${updateInfo.latestVersion}${RESET} ${colors.dim}(run \`squads update\`)${RESET}`);
93
+ }
94
+ if (sessionSummary.totalSessions > 0) {
95
+ const sessionText = sessionSummary.totalSessions === 1 ? "session" : "sessions";
96
+ const squadText = sessionSummary.squadCount === 1 ? "squad" : "squads";
97
+ let toolInfo = "";
98
+ if (sessionSummary.byTool && Object.keys(sessionSummary.byTool).length > 0) {
99
+ const toolParts = Object.entries(sessionSummary.byTool).sort((a, b) => b[1] - a[1]).map(([tool, count]) => `${colors.dim}${tool}${RESET} ${colors.cyan}${count}${RESET}`);
100
+ toolInfo = ` ${colors.dim}(${RESET}${toolParts.join(` ${colors.dim}\xB7${RESET} `)}${colors.dim})${RESET}`;
101
+ }
102
+ writeLine(` ${colors.green}${icons.active}${RESET} ${colors.white}${sessionSummary.totalSessions}${RESET} active ${sessionText} ${colors.dim}across${RESET} ${colors.cyan}${sessionSummary.squadCount}${RESET} ${squadText}${toolInfo}`);
103
+ }
104
+ writeLine();
105
+ const execStats = getExecutionStats({ since: new Date(Date.now() - 24 * 60 * 60 * 1e3) });
106
+ const execSummary = execStats.total > 0 ? `${colors.green}${execStats.completed}${RESET} ${colors.dim}completed${RESET}` + (execStats.failed > 0 ? ` ${colors.red}${execStats.failed}${RESET} ${colors.dim}failed${RESET}` : "") + (execStats.running > 0 ? ` ${colors.yellow}${execStats.running}${RESET} ${colors.dim}running${RESET}` : "") : `${colors.dim}no executions${RESET}`;
107
+ const totalSquads = squads.length;
108
+ const activeCount = squads.length;
109
+ writeLine(` ${colors.cyan}${activeCount}${RESET}/${totalSquads} squads ${colors.dim}\u2502${RESET} ${colors.dim}memory: ${memoryDir ? "enabled" : "none"}${RESET} ${colors.dim}\u2502${RESET} ${colors.dim}24h:${RESET} ${execSummary}`);
110
+ writeLine();
111
+ const w = { name: 16, agents: 8, memory: 14, activity: 12 };
112
+ const tableWidth = w.name + w.agents + w.memory + w.activity + 6;
113
+ writeLine(` ${colors.purple}${box.topLeft}${colors.dim}${box.horizontal.repeat(tableWidth)}${colors.purple}${box.topRight}${RESET}`);
114
+ const header = ` ${colors.purple}${box.vertical}${RESET} ${bold}${padEnd("SQUAD", w.name)}${RESET}${bold}${padEnd("AGENTS", w.agents)}${RESET}${bold}${padEnd("MEMORY", w.memory)}${RESET}${bold}ACTIVITY${RESET} ${colors.purple}${box.vertical}${RESET}`;
115
+ writeLine(header);
116
+ writeLine(` ${colors.purple}${box.teeRight}${colors.dim}${box.horizontal.repeat(tableWidth)}${colors.purple}${box.teeLeft}${RESET}`);
117
+ for (const squadName of squads) {
118
+ const agents = listAgents(squadsDir, squadName);
119
+ let memoryStatus = `${colors.dim}none${RESET}`;
120
+ let lastActivity = `${colors.dim}\u2014${RESET}`;
121
+ let activityColor = colors.dim;
122
+ if (memoryDir) {
123
+ const squadMemoryPath = join(memoryDir, squadName);
124
+ if (existsSync(squadMemoryPath)) {
125
+ const states = getSquadState(squadName);
126
+ memoryStatus = `${colors.green}${states.length} ${states.length === 1 ? "entry" : "entries"}${RESET}`;
127
+ let mostRecent = 0;
128
+ for (const state of states) {
129
+ const stat = statSync(state.path);
130
+ if (stat.mtimeMs > mostRecent) {
131
+ mostRecent = stat.mtimeMs;
132
+ }
133
+ }
134
+ if (mostRecent > 0) {
135
+ const daysAgo = Math.floor((Date.now() - mostRecent) / (1e3 * 60 * 60 * 24));
136
+ if (daysAgo === 0) {
137
+ lastActivity = "today";
138
+ activityColor = colors.green;
139
+ } else if (daysAgo === 1) {
140
+ lastActivity = "yesterday";
141
+ activityColor = colors.green;
142
+ } else if (daysAgo < 7) {
143
+ lastActivity = `${daysAgo}d ago`;
144
+ activityColor = colors.yellow;
145
+ } else {
146
+ lastActivity = `${daysAgo}d ago`;
147
+ activityColor = colors.dim;
148
+ }
149
+ }
150
+ }
151
+ }
152
+ const row = ` ${colors.purple}${box.vertical}${RESET} ${colors.cyan}${padEnd(squadName, w.name)}${RESET}${padEnd(String(agents.length), w.agents)}${padEnd(memoryStatus, w.memory)}${padEnd(`${activityColor}${lastActivity}${RESET}`, w.activity)}${colors.purple}${box.vertical}${RESET}`;
153
+ writeLine(row);
154
+ }
155
+ writeLine(` ${colors.purple}${box.bottomLeft}${colors.dim}${box.horizontal.repeat(tableWidth)}${colors.purple}${box.bottomRight}${RESET}`);
156
+ writeLine();
157
+ const repoSet = /* @__PURE__ */ new Set();
158
+ for (const name of squads) {
159
+ const squad = loadSquad(name);
160
+ if (squad?.repo) repoSet.add(squad.repo);
161
+ }
162
+ const ops = fetchOperationalStatus([...repoSet]);
163
+ const allRepoNames = [...ops.milestones.map((m) => m.repo), ...ops.openPRs.map((p) => p.repo)];
164
+ const repoColWidth = Math.max(10, ...allRepoNames.map((r) => r.length + 2));
165
+ if (ops.milestones.length > 0) {
166
+ writeLine(` ${bold}Milestones${RESET}`);
167
+ writeLine();
168
+ for (const ms of ops.milestones) {
169
+ const filled = Math.round(ms.percent / 10);
170
+ const bar = `${colors.green}${"\u2588".repeat(filled)}${colors.dim}${"\u2591".repeat(10 - filled)}${RESET}`;
171
+ const pctColor = ms.percent >= 80 ? colors.green : ms.percent >= 40 ? colors.yellow : colors.red;
172
+ writeLine(` ${colors.dim}${padEnd(ms.repo, repoColWidth)}${RESET}${padEnd(ms.title, 12)}${bar} ${pctColor}${ms.percent}%${RESET} ${colors.dim}(${ms.closedIssues}/${ms.totalIssues})${RESET}`);
173
+ }
174
+ writeLine();
175
+ }
176
+ if (ops.openPRs.length > 0) {
177
+ writeLine(` ${bold}Open PRs${RESET}`);
178
+ writeLine();
179
+ for (const pr of ops.openPRs) {
180
+ const title = pr.title.length > 50 ? pr.title.substring(0, 47) + "..." : pr.title;
181
+ writeLine(` ${colors.dim}${padEnd(pr.repo, repoColWidth)}${RESET}${colors.cyan}#${pr.number}${RESET} ${title}`);
182
+ }
183
+ writeLine();
184
+ }
185
+ if (ops.error) {
186
+ writeLine(` ${colors.dim}GitHub: ${ops.error} (run \`gh auth login\`)${RESET}`);
187
+ writeLine();
188
+ }
189
+ writeLine(` ${colors.dim}$${RESET} squads status ${colors.cyan}<squad>${RESET} ${colors.dim}Squad details${RESET}`);
190
+ writeLine(` ${colors.dim}$${RESET} squads dash ${colors.dim}Full dashboard${RESET}`);
191
+ writeLine(` ${colors.dim}$${RESET} squads run ${colors.cyan}<squad>${RESET} ${colors.dim}Execute a squad${RESET}`);
192
+ writeLine();
193
+ }
194
+ async function showSquadStatus(squadName, squadsDir, options) {
195
+ const squad = loadSquad(squadName);
196
+ if (!squad) {
197
+ if (options.json) {
198
+ console.log(JSON.stringify({ ok: false, command: "status", error: `Squad "${squadName}" not found` }, null, 2));
199
+ process.exit(1);
200
+ }
201
+ writeLine(`${colors.red}Squad "${squadName}" not found.${RESET}`);
202
+ process.exit(1);
203
+ }
204
+ if (options.json) {
205
+ const agents2 = listAgents(squadsDir, squadName);
206
+ const execContext2 = resolveExecutionContext(squad);
207
+ const recentExecs2 = listExecutions({ squad: squadName, limit: 5 });
208
+ const memDir = findMemoryDir();
209
+ const states = memDir ? getSquadState(squadName) : [];
210
+ console.log(JSON.stringify({
211
+ ok: true,
212
+ command: "status",
213
+ data: {
214
+ squad: {
215
+ name: squad.name,
216
+ mission: squad.mission || null,
217
+ agents: agents2.map((a) => ({ name: a.name, role: a.role || null, status: a.status || "active" })),
218
+ pipelines: squad.pipelines,
219
+ context: {
220
+ skills: execContext2.resolved.skills.map((s) => s.name),
221
+ mcpServers: execContext2.resolved.mcpServers,
222
+ model: squad.context?.model?.default || null
223
+ },
224
+ recentExecutions: recentExecs2,
225
+ memoryEntries: states.length
226
+ }
227
+ }
228
+ }, null, 2));
229
+ return;
230
+ }
231
+ writeLine();
232
+ const sensitiveSquads = ["client-"];
233
+ const isSensitive = sensitiveSquads.some((prefix) => squadName.startsWith(prefix));
234
+ if (isSensitive) {
235
+ writeLine(privacyHeader("internal"));
236
+ writeLine();
237
+ }
238
+ writeLine(` ${gradient("squads")} ${colors.dim}status${RESET} ${colors.cyan}${squad.name}${RESET}`);
239
+ writeLine();
240
+ if (squad.mission) {
241
+ writeLine(` ${colors.dim}${squad.mission}${RESET}`);
242
+ writeLine();
243
+ }
244
+ const agents = listAgents(squadsDir, squadName);
245
+ const w = { name: 24, role: 36 };
246
+ const tableWidth = w.name + w.role + 4;
247
+ writeLine(` ${bold}Agents${RESET} ${colors.dim}(${agents.length})${RESET}`);
248
+ writeLine();
249
+ writeLine(` ${colors.purple}${box.topLeft}${colors.dim}${box.horizontal.repeat(tableWidth)}${colors.purple}${box.topRight}${RESET}`);
250
+ for (const agent of agents) {
251
+ const status = agent.status?.toLowerCase() === "active" ? icons.active : icons.pending;
252
+ const role = options.verbose && agent.role ? `${colors.dim}${agent.role.substring(0, w.role - 2)}${RESET}` : "";
253
+ const row = ` ${colors.purple}${box.vertical}${RESET} ${status} ${padEnd(agent.name, w.name - 2)}${padEnd(role, w.role)}${colors.purple}${box.vertical}${RESET}`;
254
+ writeLine(row);
255
+ }
256
+ writeLine(` ${colors.purple}${box.bottomLeft}${colors.dim}${box.horizontal.repeat(tableWidth)}${colors.purple}${box.bottomRight}${RESET}`);
257
+ if (squad.pipelines.length > 0) {
258
+ writeLine();
259
+ writeLine(` ${bold}Pipelines${RESET}`);
260
+ for (const pipeline of squad.pipelines) {
261
+ writeLine(` ${colors.dim}${pipeline.agents.join(" \u2192 ")}${RESET}`);
262
+ }
263
+ }
264
+ const execContext = resolveExecutionContext(squad);
265
+ const hasContext = execContext.resolved.skills.length > 0 || execContext.resolved.mcpServers.length > 0 || squad.context?.model?.default;
266
+ if (hasContext) {
267
+ writeLine();
268
+ writeLine(` ${bold}Context${RESET}`);
269
+ if (execContext.resolved.mcpServers.length > 0) {
270
+ const sourceLabel = execContext.resolved.mcpSource === "squad-local" ? `${colors.green}local${RESET}` : execContext.resolved.mcpSource === "generated" ? `${colors.cyan}generated${RESET}` : execContext.resolved.mcpSource === "user-override" ? `${colors.yellow}override${RESET}` : "";
271
+ writeLine(` ${colors.dim}MCP:${RESET} ${colors.cyan}${execContext.resolved.mcpServers.join(", ")}${RESET}${sourceLabel ? ` ${colors.dim}(${sourceLabel})${RESET}` : ""}`);
272
+ }
273
+ if (execContext.resolved.skills.length > 0) {
274
+ const bySource = execContext.resolved.skills.reduce((acc, s) => {
275
+ acc[s.source] = acc[s.source] || [];
276
+ acc[s.source].push(s.name);
277
+ return acc;
278
+ }, {});
279
+ const skillParts = [];
280
+ if (bySource["squad-local"]) {
281
+ skillParts.push(`${colors.green}${bySource["squad-local"].join(", ")}${RESET} ${colors.dim}(local)${RESET}`);
282
+ }
283
+ if (bySource["project"]) {
284
+ skillParts.push(`${colors.cyan}${bySource["project"].join(", ")}${RESET}`);
285
+ }
286
+ if (bySource["global"]) {
287
+ skillParts.push(`${colors.dim}${bySource["global"].join(", ")}${RESET}`);
288
+ }
289
+ writeLine(` ${colors.dim}Skills:${RESET} ${skillParts.join(", ")}`);
290
+ }
291
+ if (squad.context?.model?.default) {
292
+ writeLine(` ${colors.dim}Model:${RESET} ${colors.white}${squad.context.model.default}${RESET}`);
293
+ }
294
+ }
295
+ const recentExecs = listExecutions({ squad: squadName, limit: 5 });
296
+ if (recentExecs.length > 0) {
297
+ writeLine();
298
+ writeLine(` ${bold}Recent Executions${RESET}`);
299
+ writeLine();
300
+ for (const exec of recentExecs) {
301
+ const statusIcon = exec.status === "completed" ? `${colors.green}\u25CF${RESET}` : exec.status === "failed" ? `${colors.red}\u25CF${RESET}` : `${colors.yellow}\u25C6${RESET}`;
302
+ const duration = exec.durationMs ? ` ${colors.dim}(${formatDuration(exec.durationMs)})${RESET}` : "";
303
+ const relTime = formatRelativeTime(exec.startTime);
304
+ writeLine(` ${statusIcon} ${colors.white}${exec.agent}${RESET}${duration} ${colors.dim}${relTime}${RESET}`);
305
+ if (exec.status === "failed" && exec.error && options.verbose) {
306
+ writeLine(` ${colors.red}\u2514 ${exec.error.substring(0, 60)}${exec.error.length > 60 ? "..." : ""}${RESET}`);
307
+ }
308
+ if (exec.status === "completed" && exec.outcome && options.verbose) {
309
+ writeLine(` ${colors.dim}\u2514 ${exec.outcome.substring(0, 60)}${exec.outcome.length > 60 ? "..." : ""}${RESET}`);
310
+ }
311
+ }
312
+ }
313
+ const memoryDir = findMemoryDir();
314
+ if (memoryDir) {
315
+ const states = getSquadState(squadName);
316
+ if (states.length > 0) {
317
+ writeLine();
318
+ writeLine(` ${bold}Memory${RESET} ${colors.dim}(${states.length} ${states.length === 1 ? "entry" : "entries"})${RESET}`);
319
+ writeLine();
320
+ for (const state of states) {
321
+ const updated = state.content.match(/Updated:\s*(\S+)/)?.[1] || "unknown";
322
+ writeLine(` ${icons.progress} ${colors.white}${state.agent}${RESET}`);
323
+ writeLine(` ${colors.dim}\u2514 updated: ${updated}${RESET}`);
324
+ if (options.verbose) {
325
+ const signalsMatch = state.content.match(/## Active Signals([\s\S]*?)(?=##|$)/);
326
+ if (signalsMatch) {
327
+ const signalLines = signalsMatch[1].split("\n").filter((l) => l.match(/^\d+\./)).slice(0, 3);
328
+ for (const sig of signalLines) {
329
+ writeLine(` ${colors.dim} ${sig.trim()}${RESET}`);
330
+ }
331
+ }
332
+ }
333
+ }
334
+ }
335
+ }
336
+ writeLine();
337
+ writeLine(` ${colors.dim}$${RESET} squads run ${colors.cyan}${squadName}${RESET} ${colors.dim}Run the squad${RESET}`);
338
+ writeLine(` ${colors.dim}$${RESET} squads dash ${colors.dim}ROI metrics & cost projections${RESET}`);
339
+ writeLine(` ${colors.dim}$${RESET} squads memory show ${colors.cyan}${squadName}${RESET} ${colors.dim}View full memory${RESET}`);
340
+ writeLine(` ${colors.dim}$${RESET} squads status ${colors.cyan}${squadName}${RESET} -v ${colors.dim}Verbose status${RESET}`);
341
+ writeLine();
342
+ }
343
+ export {
344
+ statusCommand
345
+ };
346
+ //# sourceMappingURL=status-FYH42FTB.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/commands/status.ts"],"sourcesContent":["import { existsSync, statSync } from 'fs';\nimport { join } from 'path';\nimport {\n findSquadsDir,\n loadSquad,\n listSquads,\n listAgents,\n resolveExecutionContext,\n} from '../lib/squad-parser.js';\nimport { findMemoryDir, getSquadState } from '../lib/memory.js';\nimport {\n getLiveSessionSummaryAsync,\n cleanupStaleSessions,\n} from '../lib/sessions.js';\nimport { fetchOperationalStatus } from '../lib/git.js';\nimport {\n listExecutions,\n getExecutionStats,\n formatDuration,\n formatRelativeTime,\n} from '../lib/executions.js';\nimport { checkForUpdate } from '../lib/update.js';\nimport { track, Events } from '../lib/telemetry.js';\nimport {\n colors,\n bold,\n RESET,\n gradient,\n box,\n padEnd,\n icons,\n writeLine,\n privacyHeader,\n} from '../lib/terminal.js';\n\ninterface StatusOptions {\n verbose?: boolean;\n json?: boolean;\n}\n\nexport async function statusCommand(\n squadName?: string,\n options: StatusOptions = {}\n): Promise<void> {\n await track(Events.CLI_STATUS, { squad: squadName || 'all', verbose: options.verbose });\n const squadsDir = findSquadsDir();\n\n if (!squadsDir) {\n writeLine(`${colors.red}No .agents/squads directory found${RESET}`);\n writeLine(`${colors.dim}Run \\`squads init\\` to create one.${RESET}`);\n process.exit(1);\n }\n\n if (squadName) {\n await showSquadStatus(squadName, squadsDir, options);\n } else {\n await showOverallStatus(squadsDir, options);\n }\n}\n\nasync function showOverallStatus(\n squadsDir: string,\n options: StatusOptions\n): Promise<void> {\n const squads = listSquads(squadsDir);\n const memoryDir = findMemoryDir();\n\n // Get active sessions (real-time process detection with parallel lsof)\n cleanupStaleSessions();\n const sessionSummary = await getLiveSessionSummaryAsync();\n\n // JSON output\n if (options.json) {\n const execStats = getExecutionStats({ since: new Date(Date.now() - 24 * 60 * 60 * 1000) });\n const squadData = squads.map(name => {\n const agents = listAgents(squadsDir, name);\n const states = memoryDir ? getSquadState(name) : [];\n return { name, agentCount: agents.length, memoryEntries: states.length };\n });\n console.log(JSON.stringify({\n ok: true,\n command: 'status',\n data: {\n squads: squadData,\n totalSquads: squads.length,\n sessions: sessionSummary,\n executions24h: execStats,\n memoryEnabled: !!memoryDir,\n },\n }, null, 2));\n return;\n }\n\n writeLine();\n writeLine(` ${gradient('squads')} ${colors.dim}status${RESET}`);\n\n // Check for updates (cached, non-blocking)\n const updateInfo = checkForUpdate();\n if (updateInfo.updateAvailable) {\n writeLine(` ${colors.cyan}⬆${RESET} Update available: ${colors.dim}${updateInfo.currentVersion}${RESET} → ${colors.green}${updateInfo.latestVersion}${RESET} ${colors.dim}(run \\`squads update\\`)${RESET}`);\n }\n\n // Session indicator line (only if there are active sessions)\n if (sessionSummary.totalSessions > 0) {\n const sessionText = sessionSummary.totalSessions === 1 ? 'session' : 'sessions';\n const squadText = sessionSummary.squadCount === 1 ? 'squad' : 'squads';\n\n // Build tool breakdown string (e.g., \"claude 4, cursor 2\")\n let toolInfo = '';\n if (sessionSummary.byTool && Object.keys(sessionSummary.byTool).length > 0) {\n const toolParts = Object.entries(sessionSummary.byTool)\n .sort((a, b) => b[1] - a[1]) // Sort by count descending\n .map(([tool, count]) => `${colors.dim}${tool}${RESET} ${colors.cyan}${count}${RESET}`);\n toolInfo = ` ${colors.dim}(${RESET}${toolParts.join(` ${colors.dim}·${RESET} `)}${colors.dim})${RESET}`;\n }\n\n writeLine(` ${colors.green}${icons.active}${RESET} ${colors.white}${sessionSummary.totalSessions}${RESET} active ${sessionText} ${colors.dim}across${RESET} ${colors.cyan}${sessionSummary.squadCount}${RESET} ${squadText}${toolInfo}`);\n }\n writeLine();\n\n // Execution stats (last 24h)\n const execStats = getExecutionStats({ since: new Date(Date.now() - 24 * 60 * 60 * 1000) });\n const execSummary = execStats.total > 0\n ? `${colors.green}${execStats.completed}${RESET} ${colors.dim}completed${RESET}` +\n (execStats.failed > 0 ? ` ${colors.red}${execStats.failed}${RESET} ${colors.dim}failed${RESET}` : '') +\n (execStats.running > 0 ? ` ${colors.yellow}${execStats.running}${RESET} ${colors.dim}running${RESET}` : '')\n : `${colors.dim}no executions${RESET}`;\n\n // Stats row\n const totalSquads = squads.length;\n const activeCount = squads.length; // All loaded squads are \"active\"\n writeLine(` ${colors.cyan}${activeCount}${RESET}/${totalSquads} squads ${colors.dim}│${RESET} ${colors.dim}memory: ${memoryDir ? 'enabled' : 'none'}${RESET} ${colors.dim}│${RESET} ${colors.dim}24h:${RESET} ${execSummary}`);\n writeLine();\n\n // Table\n const w = { name: 16, agents: 8, memory: 14, activity: 12 };\n const tableWidth = w.name + w.agents + w.memory + w.activity + 6;\n\n writeLine(` ${colors.purple}${box.topLeft}${colors.dim}${box.horizontal.repeat(tableWidth)}${colors.purple}${box.topRight}${RESET}`);\n\n const header = ` ${colors.purple}${box.vertical}${RESET} ` +\n `${bold}${padEnd('SQUAD', w.name)}${RESET}` +\n `${bold}${padEnd('AGENTS', w.agents)}${RESET}` +\n `${bold}${padEnd('MEMORY', w.memory)}${RESET}` +\n `${bold}ACTIVITY${RESET}` +\n ` ${colors.purple}${box.vertical}${RESET}`;\n writeLine(header);\n\n writeLine(` ${colors.purple}${box.teeRight}${colors.dim}${box.horizontal.repeat(tableWidth)}${colors.purple}${box.teeLeft}${RESET}`);\n\n for (const squadName of squads) {\n const agents = listAgents(squadsDir, squadName);\n\n // Check memory\n let memoryStatus = `${colors.dim}none${RESET}`;\n let lastActivity = `${colors.dim}—${RESET}`;\n let activityColor = colors.dim;\n\n if (memoryDir) {\n const squadMemoryPath = join(memoryDir, squadName);\n if (existsSync(squadMemoryPath)) {\n const states = getSquadState(squadName);\n memoryStatus = `${colors.green}${states.length} ${states.length === 1 ? 'entry' : 'entries'}${RESET}`;\n\n // Find most recent file\n let mostRecent = 0;\n for (const state of states) {\n const stat = statSync(state.path);\n if (stat.mtimeMs > mostRecent) {\n mostRecent = stat.mtimeMs;\n }\n }\n\n if (mostRecent > 0) {\n const daysAgo = Math.floor((Date.now() - mostRecent) / (1000 * 60 * 60 * 24));\n if (daysAgo === 0) {\n lastActivity = 'today';\n activityColor = colors.green;\n } else if (daysAgo === 1) {\n lastActivity = 'yesterday';\n activityColor = colors.green;\n } else if (daysAgo < 7) {\n lastActivity = `${daysAgo}d ago`;\n activityColor = colors.yellow;\n } else {\n lastActivity = `${daysAgo}d ago`;\n activityColor = colors.dim;\n }\n }\n }\n }\n\n const row = ` ${colors.purple}${box.vertical}${RESET} ` +\n `${colors.cyan}${padEnd(squadName, w.name)}${RESET}` +\n `${padEnd(String(agents.length), w.agents)}` +\n `${padEnd(memoryStatus, w.memory)}` +\n `${padEnd(`${activityColor}${lastActivity}${RESET}`, w.activity)}` +\n `${colors.purple}${box.vertical}${RESET}`;\n\n writeLine(row);\n }\n\n writeLine(` ${colors.purple}${box.bottomLeft}${colors.dim}${box.horizontal.repeat(tableWidth)}${colors.purple}${box.bottomRight}${RESET}`);\n writeLine();\n\n // Discover repos from squad definitions (SQUAD.md `repo` field)\n const repoSet = new Set<string>();\n for (const name of squads) {\n const squad = loadSquad(name);\n if (squad?.repo) repoSet.add(squad.repo);\n }\n const ops = fetchOperationalStatus([...repoSet]);\n\n // Compute column width from actual repo names\n const allRepoNames = [...ops.milestones.map(m => m.repo), ...ops.openPRs.map(p => p.repo)];\n const repoColWidth = Math.max(10, ...allRepoNames.map(r => r.length + 2));\n\n if (ops.milestones.length > 0) {\n writeLine(` ${bold}Milestones${RESET}`);\n writeLine();\n for (const ms of ops.milestones) {\n const filled = Math.round(ms.percent / 10);\n const bar = `${colors.green}${'█'.repeat(filled)}${colors.dim}${'░'.repeat(10 - filled)}${RESET}`;\n const pctColor = ms.percent >= 80 ? colors.green : ms.percent >= 40 ? colors.yellow : colors.red;\n writeLine(` ${colors.dim}${padEnd(ms.repo, repoColWidth)}${RESET}${padEnd(ms.title, 12)}${bar} ${pctColor}${ms.percent}%${RESET} ${colors.dim}(${ms.closedIssues}/${ms.totalIssues})${RESET}`);\n }\n writeLine();\n }\n\n if (ops.openPRs.length > 0) {\n writeLine(` ${bold}Open PRs${RESET}`);\n writeLine();\n for (const pr of ops.openPRs) {\n const title = pr.title.length > 50 ? pr.title.substring(0, 47) + '...' : pr.title;\n writeLine(` ${colors.dim}${padEnd(pr.repo, repoColWidth)}${RESET}${colors.cyan}#${pr.number}${RESET} ${title}`);\n }\n writeLine();\n }\n\n if (ops.error) {\n writeLine(` ${colors.dim}GitHub: ${ops.error} (run \\`gh auth login\\`)${RESET}`);\n writeLine();\n }\n\n // Commands\n writeLine(` ${colors.dim}$${RESET} squads status ${colors.cyan}<squad>${RESET} ${colors.dim}Squad details${RESET}`);\n writeLine(` ${colors.dim}$${RESET} squads dash ${colors.dim}Full dashboard${RESET}`);\n writeLine(` ${colors.dim}$${RESET} squads run ${colors.cyan}<squad>${RESET} ${colors.dim}Execute a squad${RESET}`);\n writeLine();\n}\n\nasync function showSquadStatus(\n squadName: string,\n squadsDir: string,\n options: StatusOptions\n): Promise<void> {\n const squad = loadSquad(squadName);\n\n if (!squad) {\n if (options.json) {\n console.log(JSON.stringify({ ok: false, command: 'status', error: `Squad \"${squadName}\" not found` }, null, 2));\n process.exit(1);\n }\n writeLine(`${colors.red}Squad \"${squadName}\" not found.${RESET}`);\n process.exit(1);\n }\n\n // JSON output for specific squad\n if (options.json) {\n const agents = listAgents(squadsDir, squadName);\n const execContext = resolveExecutionContext(squad);\n const recentExecs = listExecutions({ squad: squadName, limit: 5 });\n const memDir = findMemoryDir();\n const states = memDir ? getSquadState(squadName) : [];\n console.log(JSON.stringify({\n ok: true,\n command: 'status',\n data: {\n squad: {\n name: squad.name,\n mission: squad.mission || null,\n agents: agents.map(a => ({ name: a.name, role: a.role || null, status: a.status || 'active' })),\n pipelines: squad.pipelines,\n context: {\n skills: execContext.resolved.skills.map(s => s.name),\n mcpServers: execContext.resolved.mcpServers,\n model: squad.context?.model?.default || null,\n },\n recentExecutions: recentExecs,\n memoryEntries: states.length,\n },\n },\n }, null, 2));\n return;\n }\n\n writeLine();\n\n // Show privacy header for sensitive squads (client, finance, etc.)\n const sensitiveSquads = ['client-'];\n const isSensitive = sensitiveSquads.some(prefix => squadName.startsWith(prefix));\n if (isSensitive) {\n writeLine(privacyHeader('internal'));\n writeLine();\n }\n\n writeLine(` ${gradient('squads')} ${colors.dim}status${RESET} ${colors.cyan}${squad.name}${RESET}`);\n writeLine();\n\n // Mission\n if (squad.mission) {\n writeLine(` ${colors.dim}${squad.mission}${RESET}`);\n writeLine();\n }\n\n // Agents table\n const agents = listAgents(squadsDir, squadName);\n const w = { name: 24, role: 36 };\n const tableWidth = w.name + w.role + 4;\n\n writeLine(` ${bold}Agents${RESET} ${colors.dim}(${agents.length})${RESET}`);\n writeLine();\n\n writeLine(` ${colors.purple}${box.topLeft}${colors.dim}${box.horizontal.repeat(tableWidth)}${colors.purple}${box.topRight}${RESET}`);\n\n for (const agent of agents) {\n const status = agent.status?.toLowerCase() === 'active'\n ? icons.active\n : icons.pending;\n\n const role = options.verbose && agent.role\n ? `${colors.dim}${agent.role.substring(0, w.role - 2)}${RESET}`\n : '';\n\n const row = ` ${colors.purple}${box.vertical}${RESET} ` +\n `${status} ${padEnd(agent.name, w.name - 2)}` +\n `${padEnd(role, w.role)}` +\n `${colors.purple}${box.vertical}${RESET}`;\n\n writeLine(row);\n }\n\n writeLine(` ${colors.purple}${box.bottomLeft}${colors.dim}${box.horizontal.repeat(tableWidth)}${colors.purple}${box.bottomRight}${RESET}`);\n\n // Pipelines\n if (squad.pipelines.length > 0) {\n writeLine();\n writeLine(` ${bold}Pipelines${RESET}`);\n for (const pipeline of squad.pipelines) {\n writeLine(` ${colors.dim}${pipeline.agents.join(' → ')}${RESET}`);\n }\n }\n\n // Context profile\n const execContext = resolveExecutionContext(squad);\n const hasContext = execContext.resolved.skills.length > 0 ||\n execContext.resolved.mcpServers.length > 0 ||\n (squad.context?.model?.default);\n\n if (hasContext) {\n writeLine();\n writeLine(` ${bold}Context${RESET}`);\n\n // MCP servers\n if (execContext.resolved.mcpServers.length > 0) {\n const sourceLabel = execContext.resolved.mcpSource === 'squad-local' ? `${colors.green}local${RESET}` :\n execContext.resolved.mcpSource === 'generated' ? `${colors.cyan}generated${RESET}` :\n execContext.resolved.mcpSource === 'user-override' ? `${colors.yellow}override${RESET}` :\n '';\n writeLine(` ${colors.dim}MCP:${RESET} ${colors.cyan}${execContext.resolved.mcpServers.join(', ')}${RESET}${sourceLabel ? ` ${colors.dim}(${sourceLabel})${RESET}` : ''}`);\n }\n\n // Skills (grouped by source)\n if (execContext.resolved.skills.length > 0) {\n const bySource = execContext.resolved.skills.reduce((acc, s) => {\n acc[s.source] = acc[s.source] || [];\n acc[s.source].push(s.name);\n return acc;\n }, {} as Record<string, string[]>);\n\n const skillParts: string[] = [];\n if (bySource['squad-local']) {\n skillParts.push(`${colors.green}${bySource['squad-local'].join(', ')}${RESET} ${colors.dim}(local)${RESET}`);\n }\n if (bySource['project']) {\n skillParts.push(`${colors.cyan}${bySource['project'].join(', ')}${RESET}`);\n }\n if (bySource['global']) {\n skillParts.push(`${colors.dim}${bySource['global'].join(', ')}${RESET}`);\n }\n writeLine(` ${colors.dim}Skills:${RESET} ${skillParts.join(', ')}`);\n }\n\n // Model\n if (squad.context?.model?.default) {\n writeLine(` ${colors.dim}Model:${RESET} ${colors.white}${squad.context.model.default}${RESET}`);\n }\n }\n\n // Recent executions\n const recentExecs = listExecutions({ squad: squadName, limit: 5 });\n if (recentExecs.length > 0) {\n writeLine();\n writeLine(` ${bold}Recent Executions${RESET}`);\n writeLine();\n\n for (const exec of recentExecs) {\n // Use plain symbols - icons already have colors embedded\n const statusIcon = exec.status === 'completed' ? `${colors.green}●${RESET}` :\n exec.status === 'failed' ? `${colors.red}●${RESET}` :\n `${colors.yellow}◆${RESET}`;\n const duration = exec.durationMs ? ` ${colors.dim}(${formatDuration(exec.durationMs)})${RESET}` : '';\n const relTime = formatRelativeTime(exec.startTime);\n\n writeLine(` ${statusIcon} ${colors.white}${exec.agent}${RESET}${duration} ${colors.dim}${relTime}${RESET}`);\n\n // Show error message for failed executions\n if (exec.status === 'failed' && exec.error && options.verbose) {\n writeLine(` ${colors.red}└ ${exec.error.substring(0, 60)}${exec.error.length > 60 ? '...' : ''}${RESET}`);\n }\n\n // Show outcome for completed executions in verbose mode\n if (exec.status === 'completed' && exec.outcome && options.verbose) {\n writeLine(` ${colors.dim}└ ${exec.outcome.substring(0, 60)}${exec.outcome.length > 60 ? '...' : ''}${RESET}`);\n }\n }\n }\n\n // Memory state\n const memoryDir = findMemoryDir();\n if (memoryDir) {\n const states = getSquadState(squadName);\n\n if (states.length > 0) {\n writeLine();\n writeLine(` ${bold}Memory${RESET} ${colors.dim}(${states.length} ${states.length === 1 ? 'entry' : 'entries'})${RESET}`);\n writeLine();\n\n for (const state of states) {\n const updated = state.content.match(/Updated:\\s*(\\S+)/)?.[1] || 'unknown';\n writeLine(` ${icons.progress} ${colors.white}${state.agent}${RESET}`);\n writeLine(` ${colors.dim}└ updated: ${updated}${RESET}`);\n\n if (options.verbose) {\n const signalsMatch = state.content.match(/## Active Signals([\\s\\S]*?)(?=##|$)/);\n if (signalsMatch) {\n const signalLines = signalsMatch[1]\n .split('\\n')\n .filter(l => l.match(/^\\d+\\./))\n .slice(0, 3);\n\n for (const sig of signalLines) {\n writeLine(` ${colors.dim} ${sig.trim()}${RESET}`);\n }\n }\n }\n }\n }\n }\n\n writeLine();\n writeLine(` ${colors.dim}$${RESET} squads run ${colors.cyan}${squadName}${RESET} ${colors.dim}Run the squad${RESET}`);\n writeLine(` ${colors.dim}$${RESET} squads dash ${colors.dim}ROI metrics & cost projections${RESET}`);\n writeLine(` ${colors.dim}$${RESET} squads memory show ${colors.cyan}${squadName}${RESET} ${colors.dim}View full memory${RESET}`);\n writeLine(` ${colors.dim}$${RESET} squads status ${colors.cyan}${squadName}${RESET} -v ${colors.dim}Verbose status${RESET}`);\n writeLine();\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,SAAS,YAAY,gBAAgB;AACrC,SAAS,YAAY;AAuCrB,eAAsB,cACpB,WACA,UAAyB,CAAC,GACX;AACf,QAAM,MAAM,OAAO,YAAY,EAAE,OAAO,aAAa,OAAO,SAAS,QAAQ,QAAQ,CAAC;AACtF,QAAM,YAAY,cAAc;AAEhC,MAAI,CAAC,WAAW;AACd,cAAU,GAAG,OAAO,GAAG,oCAAoC,KAAK,EAAE;AAClE,cAAU,GAAG,OAAO,GAAG,qCAAqC,KAAK,EAAE;AACnE,YAAQ,KAAK,CAAC;AAAA,EAChB;AAEA,MAAI,WAAW;AACb,UAAM,gBAAgB,WAAW,WAAW,OAAO;AAAA,EACrD,OAAO;AACL,UAAM,kBAAkB,WAAW,OAAO;AAAA,EAC5C;AACF;AAEA,eAAe,kBACb,WACA,SACe;AACf,QA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