@songsid/agend 2.3.2-beta.8 → 2.3.2

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 (243) hide show
  1. package/README.md +6 -0
  2. package/README.zh-TW.md +6 -0
  3. package/dist/agent-cli.js +48 -0
  4. package/dist/agent-cli.js.map +1 -1
  5. package/dist/agent-endpoint.js +6 -0
  6. package/dist/agent-endpoint.js.map +1 -1
  7. package/dist/agent-whats-new.js +3 -0
  8. package/dist/agent-whats-new.js.map +1 -1
  9. package/dist/auth-api.js +2 -0
  10. package/dist/auth-api.js.map +1 -1
  11. package/dist/backend/claude-code.js +23 -1
  12. package/dist/backend/claude-code.js.map +1 -1
  13. package/dist/backend/codex-session-lookup.d.ts +15 -0
  14. package/dist/backend/codex-session-lookup.js +58 -0
  15. package/dist/backend/codex-session-lookup.js.map +1 -1
  16. package/dist/backend/codex.js +15 -4
  17. package/dist/backend/codex.js.map +1 -1
  18. package/dist/backend/kiro-classic-archive.d.ts +57 -0
  19. package/dist/backend/kiro-classic-archive.js +622 -0
  20. package/dist/backend/kiro-classic-archive.js.map +1 -0
  21. package/dist/backend/kiro-classic-links.d.ts +24 -0
  22. package/dist/backend/kiro-classic-links.js +135 -0
  23. package/dist/backend/kiro-classic-links.js.map +1 -0
  24. package/dist/backend/kiro-identity.d.ts +100 -1
  25. package/dist/backend/kiro-identity.js +262 -31
  26. package/dist/backend/kiro-identity.js.map +1 -1
  27. package/dist/backend/kiro-migration-verify.d.ts +10 -0
  28. package/dist/backend/kiro-migration-verify.js +52 -0
  29. package/dist/backend/kiro-migration-verify.js.map +1 -0
  30. package/dist/backend/kiro-reconcile-store.d.ts +27 -0
  31. package/dist/backend/kiro-reconcile-store.js +344 -0
  32. package/dist/backend/kiro-reconcile-store.js.map +1 -0
  33. package/dist/backend/kiro-v2-store-worker.js +35 -1
  34. package/dist/backend/kiro-v2-store-worker.js.map +1 -1
  35. package/dist/backend/kiro-v2-store.d.ts +31 -1
  36. package/dist/backend/kiro-v2-store.js +22 -12
  37. package/dist/backend/kiro-v2-store.js.map +1 -1
  38. package/dist/backend/kiro.d.ts +124 -1
  39. package/dist/backend/kiro.js +553 -29
  40. package/dist/backend/kiro.js.map +1 -1
  41. package/dist/backend/types.d.ts +102 -0
  42. package/dist/backend/types.js +9 -0
  43. package/dist/backend/types.js.map +1 -1
  44. package/dist/cache-service.d.ts +13 -1
  45. package/dist/cache-service.js +45 -2
  46. package/dist/cache-service.js.map +1 -1
  47. package/dist/channel/ipc-timeouts.js +3 -0
  48. package/dist/channel/ipc-timeouts.js.map +1 -1
  49. package/dist/channel/mcp-tools.js +40 -5
  50. package/dist/channel/mcp-tools.js.map +1 -1
  51. package/dist/channel/tool-router.js +2 -1
  52. package/dist/channel/tool-router.js.map +1 -1
  53. package/dist/classic-channel-manager.d.ts +6 -0
  54. package/dist/classic-channel-manager.js +25 -0
  55. package/dist/classic-channel-manager.js.map +1 -1
  56. package/dist/cli.js +50 -4
  57. package/dist/cli.js.map +1 -1
  58. package/dist/config-validator.d.ts +7 -1
  59. package/dist/config-validator.js +17 -8
  60. package/dist/config-validator.js.map +1 -1
  61. package/dist/config.js +2 -0
  62. package/dist/config.js.map +1 -1
  63. package/dist/daemon.d.ts +66 -0
  64. package/dist/daemon.js +421 -19
  65. package/dist/daemon.js.map +1 -1
  66. package/dist/dashboard-permissions.d.ts +15 -4
  67. package/dist/dashboard-permissions.js +49 -23
  68. package/dist/dashboard-permissions.js.map +1 -1
  69. package/dist/doctor.js +2 -1
  70. package/dist/doctor.js.map +1 -1
  71. package/dist/fleet-control-audit.d.ts +1 -1
  72. package/dist/fleet-control-audit.js +3 -0
  73. package/dist/fleet-control-audit.js.map +1 -1
  74. package/dist/fleet-manager.d.ts +90 -3
  75. package/dist/fleet-manager.js +569 -41
  76. package/dist/fleet-manager.js.map +1 -1
  77. package/dist/forged-envelope-scan.d.ts +9 -0
  78. package/dist/forged-envelope-scan.js +30 -5
  79. package/dist/forged-envelope-scan.js.map +1 -1
  80. package/dist/general-instance.d.ts +24 -0
  81. package/dist/general-instance.js +53 -0
  82. package/dist/general-instance.js.map +1 -1
  83. package/dist/general-knowledge/skills/docker-install/SKILL.md +25 -0
  84. package/dist/general-knowledge/skills/fleet-config/SKILL.md +5 -3
  85. package/dist/general-knowledge/skills/fleet-restart/SKILL.md +1 -1
  86. package/dist/general-knowledge/skills/kiro-engine-migration/SKILL.md +34 -0
  87. package/dist/general-knowledge/skills/session-management/SKILL.md +1 -1
  88. package/dist/general-knowledge/skills/tui-effort/SKILL.md +1 -1
  89. package/dist/general-knowledge/skills/web-appearance/SKILL.canvas-worker-off.md +32 -0
  90. package/dist/general-knowledge/skills/web-appearance/SKILL.md +32 -0
  91. package/dist/general-knowledge/skills/web-dashboard/SKILL.canvas-worker-off.md +60 -18
  92. package/dist/general-knowledge/skills/web-dashboard/SKILL.md +60 -18
  93. package/dist/instance-config-impact.js +3 -2
  94. package/dist/instance-config-impact.js.map +1 -1
  95. package/dist/instance-lifecycle.d.ts +4 -0
  96. package/dist/instance-lifecycle.js +7 -0
  97. package/dist/instance-lifecycle.js.map +1 -1
  98. package/dist/kiro-migrate.d.ts +19 -2
  99. package/dist/kiro-migrate.js +133 -35
  100. package/dist/kiro-migrate.js.map +1 -1
  101. package/dist/kiro-reconcile.d.ts +21 -0
  102. package/dist/kiro-reconcile.js +88 -0
  103. package/dist/kiro-reconcile.js.map +1 -0
  104. package/dist/kiro-session-proof.d.ts +41 -0
  105. package/dist/kiro-session-proof.js +89 -0
  106. package/dist/kiro-session-proof.js.map +1 -0
  107. package/dist/kiro-tui-forensic.d.ts +19 -0
  108. package/dist/kiro-tui-forensic.js +124 -0
  109. package/dist/kiro-tui-forensic.js.map +1 -0
  110. package/dist/locale.js +198 -0
  111. package/dist/locale.js.map +1 -1
  112. package/dist/log-service.js +2 -2
  113. package/dist/log-service.js.map +1 -1
  114. package/dist/needs-you.d.ts +3 -1
  115. package/dist/needs-you.js +4 -2
  116. package/dist/needs-you.js.map +1 -1
  117. package/dist/office-levels.d.ts +64 -0
  118. package/dist/office-levels.js +66 -0
  119. package/dist/office-levels.js.map +1 -0
  120. package/dist/office-share-page.d.ts +3 -1
  121. package/dist/office-share-page.js +8 -3
  122. package/dist/office-share-page.js.map +1 -1
  123. package/dist/office-share-service.d.ts +6 -3
  124. package/dist/office-share-service.js +12 -8
  125. package/dist/office-share-service.js.map +1 -1
  126. package/dist/office-share.d.ts +80 -13
  127. package/dist/office-share.js +145 -25
  128. package/dist/office-share.js.map +1 -1
  129. package/dist/outbound-handlers.js +20 -1
  130. package/dist/outbound-handlers.js.map +1 -1
  131. package/dist/outbound-schemas.d.ts +47 -2
  132. package/dist/outbound-schemas.js +41 -2
  133. package/dist/outbound-schemas.js.map +1 -1
  134. package/dist/public-web-gateway.js +1 -1
  135. package/dist/public-web-gateway.js.map +1 -1
  136. package/dist/quickstart-api.d.ts +39 -1
  137. package/dist/quickstart-api.js +115 -17
  138. package/dist/quickstart-api.js.map +1 -1
  139. package/dist/remote-card-answer.d.ts +83 -0
  140. package/dist/remote-card-answer.js +208 -0
  141. package/dist/remote-card-answer.js.map +1 -0
  142. package/dist/remote-card-prompt.d.ts +38 -0
  143. package/dist/remote-card-prompt.js +86 -0
  144. package/dist/remote-card-prompt.js.map +1 -0
  145. package/dist/scheduler/task-board.d.ts +28 -6
  146. package/dist/scheduler/task-board.js +66 -11
  147. package/dist/scheduler/task-board.js.map +1 -1
  148. package/dist/service-installer.d.ts +13 -0
  149. package/dist/service-installer.js +15 -0
  150. package/dist/service-installer.js.map +1 -1
  151. package/dist/service-owner.d.ts +25 -0
  152. package/dist/service-owner.js +43 -2
  153. package/dist/service-owner.js.map +1 -1
  154. package/dist/settings-api.d.ts +2 -0
  155. package/dist/settings-api.js +18 -12
  156. package/dist/settings-api.js.map +1 -1
  157. package/dist/settings-change.js +10 -5
  158. package/dist/settings-change.js.map +1 -1
  159. package/dist/settings-effect.js +7 -4
  160. package/dist/settings-effect.js.map +1 -1
  161. package/dist/settings-instance-patch.js +1 -1
  162. package/dist/settings-instance-patch.js.map +1 -1
  163. package/dist/setup-form.d.ts +2 -2
  164. package/dist/setup-form.js +139 -93
  165. package/dist/setup-form.js.map +1 -1
  166. package/dist/setup-i18n.d.ts +25 -0
  167. package/dist/setup-i18n.js +226 -0
  168. package/dist/setup-i18n.js.map +1 -0
  169. package/dist/task-board-waker.js +7 -2
  170. package/dist/task-board-waker.js.map +1 -1
  171. package/dist/tool-permissions.js +18 -0
  172. package/dist/tool-permissions.js.map +1 -1
  173. package/dist/transcript-sources.d.ts +1 -0
  174. package/dist/transcript-sources.js +20 -3
  175. package/dist/transcript-sources.js.map +1 -1
  176. package/dist/types.d.ts +10 -0
  177. package/dist/ui/backend-signin.js +4 -3
  178. package/dist/ui/chat-store.js +3 -2
  179. package/dist/ui/chat-strings.js +2 -2
  180. package/dist/ui/fleet-office-card.js +114 -0
  181. package/dist/ui/fleet-office-editor.js +81 -9
  182. package/dist/ui/fleet-office-layout.js +87 -10
  183. package/dist/ui/fleet-office-levels.js +105 -0
  184. package/dist/ui/fleet-office-model.js +9 -1
  185. package/dist/ui/fleet-office-pack.d.ts +18 -3
  186. package/dist/ui/fleet-office-pack.js +217 -23
  187. package/dist/ui/fleet-office-skin.js +39 -3
  188. package/dist/ui/fleet-office-store.js +74 -3
  189. package/dist/ui/fleet-office-view.js +8 -0
  190. package/dist/ui/fleet-office-zones.js +102 -19
  191. package/dist/ui/fleet-office.js +323 -50
  192. package/dist/ui/fleet-org.js +2 -0
  193. package/dist/ui/fleet-task-card.js +2 -2
  194. package/dist/ui/fleet-task-common.js +30 -7
  195. package/dist/ui/fleet-task-work.js +2 -2
  196. package/dist/ui/fleet-tasks.js +10 -11
  197. package/dist/ui/office-share-dialog.js +31 -7
  198. package/dist/ui/office-share-page.js +50 -1
  199. package/dist/ui/panel-chat.js +14 -2
  200. package/dist/ui/panel-log.js +4 -4
  201. package/dist/ui/panel-needs.js +1 -1
  202. package/dist/ui/panel-settings.js +16 -8
  203. package/dist/ui/settings-discord.js +3 -2
  204. package/dist/ui/settings-guests.js +17 -7
  205. package/dist/ui/settings-model.js +17 -9
  206. package/dist/ui/settings-registry.js +1 -0
  207. package/dist/ui/settings-strings.js +16 -4
  208. package/dist/ui/settings-token.js +3 -2
  209. package/dist/ui/settings-wizard.js +25 -9
  210. package/dist/ui/shared/app-i18n.js +2 -2
  211. package/dist/ui/shared/app-stream.js +1 -1
  212. package/dist/ui/shared/app.css +74 -2
  213. package/dist/ui/shared/setup-host-text.js +107 -0
  214. package/dist/ui/structured-signin.js +89 -38
  215. package/dist/usage-rollup.d.ts +34 -3
  216. package/dist/usage-rollup.js +56 -3
  217. package/dist/usage-rollup.js.map +1 -1
  218. package/dist/web-api.d.ts +10 -1
  219. package/dist/web-api.js +207 -17
  220. package/dist/web-api.js.map +1 -1
  221. package/dist/web-auth.js +1 -1
  222. package/dist/web-auth.js.map +1 -1
  223. package/dist/web-office-acts.d.ts +5 -2
  224. package/dist/web-office-acts.js +9 -4
  225. package/dist/web-office-acts.js.map +1 -1
  226. package/dist/web-office-pack-read.d.ts +35 -0
  227. package/dist/web-office-pack-read.js +252 -0
  228. package/dist/web-office-pack-read.js.map +1 -0
  229. package/dist/web-office-pack-tools.d.ts +241 -0
  230. package/dist/web-office-pack-tools.js +785 -0
  231. package/dist/web-office-pack-tools.js.map +1 -0
  232. package/dist/web-office-skins.d.ts +68 -4
  233. package/dist/web-office-skins.js +324 -33
  234. package/dist/web-office-skins.js.map +1 -1
  235. package/dist/web-office-store.d.ts +47 -4
  236. package/dist/web-office-store.js +149 -15
  237. package/dist/web-office-store.js.map +1 -1
  238. package/dist/web-settings-patch.d.ts +3 -1
  239. package/dist/web-settings-patch.js +4 -1
  240. package/dist/web-settings-patch.js.map +1 -1
  241. package/dist/workflow-templates/default.md +1 -1
  242. package/package.json +2 -2
  243. package/templates/windows-shortcuts.ps1 +18 -17
@@ -80,6 +80,12 @@ export declare function scanKiroInstanceForForgedEnvelopes(opts: {
80
80
  * data.sqlite3, not the shared store.
81
81
  */
82
82
  storeHome?: string;
83
+ /** Engine-selected TUI read; no SQLite fallback. */
84
+ tui?: {
85
+ sessionsDir?: string;
86
+ sessionId: string;
87
+ stillOwned: () => boolean;
88
+ };
83
89
  alreadyReportedIds?: Set<string>;
84
90
  }): KiroForgedScanResult;
85
91
  export interface ScanTargetConfig {
@@ -87,6 +93,7 @@ export interface ScanTargetConfig {
87
93
  backend: string;
88
94
  workingDirectory?: string;
89
95
  backendOptions?: Record<string, Record<string, unknown>>;
96
+ kiroUi?: InstanceConfig["kiro_ui"];
90
97
  }
91
98
  /**
92
99
  * Effective per-instance scan config, merged EXACTLY like the daemon's
@@ -135,6 +142,8 @@ export declare function executeForgedEnvelopeScan(opts: {
135
142
  outboxDbPath: string;
136
143
  dataDir: string;
137
144
  kiroDbOverride?: string;
145
+ /** Explicit TUI root for offline rigs; never changes the engine selection. */
146
+ kiroSessionsOverride?: string;
138
147
  alreadyReportedIds?: Set<string>;
139
148
  }): ScanCommandResult;
140
149
  export declare function loadReportedEnvelopeIds(dataDir: string): Set<string>;
@@ -11,8 +11,7 @@ import { ensureAgendHome } from "./agend-home.js";
11
11
  * triggers a verification warning; retention expiry also makes a real message
12
12
  * unverifiable, so this is not proof that the receiver fabricated the turn.
13
13
  *
14
- * Only kiro has a reader here: its conversation store
15
- * (`~/.local/share/kiro-cli/data.sqlite3`, conversations_v2) is on disk.
14
+ * Kiro classic uses conversations_v2 in data.sqlite3; TUI uses the owned, pinned session JSONL.
16
15
  * Claude jsonl / Codex rollouts / other backends are per-backend follow-ups.
17
16
  *
18
17
  * Everything query-side is read-only: the kiro store opens readonly and the
@@ -22,6 +21,8 @@ import { ensureAgendHome } from "./agend-home.js";
22
21
  import { t } from "./locale.js";
23
22
  import { existsSync, readFileSync, writeFileSync } from "node:fs";
24
23
  import { join } from "node:path";
24
+ import { kiroEngineFloor, kiroOwnedConversation } from "./backend/kiro-identity.js";
25
+ import { readKiroTuiAssistantTexts } from "./kiro-tui-forensic.js";
25
26
  import { credentialStoreHomeForInstance } from "./backend/credential-profile.js";
26
27
  import { deepMergeGeneric, getEffectiveInstanceDefaults } from "./config.js";
27
28
  import { DeliveryOutbox, deliveryStatusSelector } from "./delivery-outbox.js";
@@ -162,7 +163,9 @@ export function scanKiroInstanceForForgedEnvelopes(opts) {
162
163
  instanceName: opts.instanceName, conversationId: null, checked: 0, delivered: 0, unverifiable: 0, findings: [],
163
164
  };
164
165
  const kiroDbPath = opts.kiroDbPath ?? kiroStoreDbPath(opts.storeHome);
165
- const convo = readKiroAssistantTexts(opts.workingDirectory, kiroDbPath);
166
+ const convo = opts.tui
167
+ ? readKiroTuiAssistantTexts(opts.tui)
168
+ : readKiroAssistantTexts(opts.workingDirectory, kiroDbPath);
166
169
  if (convo.kind === "unreadable") {
167
170
  return { ...base, status: "unreadable-store", reason: convo.reason };
168
171
  }
@@ -209,6 +212,7 @@ export function resolveScanTarget(name, rawInstance, fleetDefaults) {
209
212
  backend,
210
213
  workingDirectory: merged.working_directory,
211
214
  backendOptions: merged.backend_options,
215
+ ...(merged.kiro_ui ? { kiroUi: merged.kiro_ui } : {}),
212
216
  };
213
217
  }
214
218
  /**
@@ -234,6 +238,13 @@ export function executeForgedEnvelopeScan(opts) {
234
238
  });
235
239
  continue;
236
240
  }
241
+ const floor = kiroEngineFloor(opts.dataDir, target.name);
242
+ if (target.kiroUi === "v3" || floor === "v3") {
243
+ unreadable++;
244
+ rows.push({ instance: target.name, backend: target.backend, status: "unreadable-store",
245
+ reason: "V3 has no supported stable forensic session store; no TUI or classic fallback is permitted.", findings: [] });
246
+ continue;
247
+ }
237
248
  if (!target.workingDirectory) {
238
249
  incomplete++;
239
250
  rows.push({
@@ -245,11 +256,24 @@ export function executeForgedEnvelopeScan(opts) {
245
256
  });
246
257
  continue;
247
258
  }
248
- // A profiled instance writes its transcript to its own store, not the
249
- // shared one — scan the store its CLI actually uses.
259
+ // Profiles relocate classic SQLite only; V2 uses its shared session root and profile-specific ownership key.
250
260
  const storeHome = opts.kiroDbOverride
251
261
  ? undefined
252
262
  : credentialStoreHomeForInstance(opts.dataDir, target.backend, target.backendOptions?.[target.backend]);
263
+ let tui;
264
+ if (target.kiroUi === "tui" || floor === "v2") {
265
+ const identity = { agendHome: opts.dataDir, instance: target.name, engine: "v2",
266
+ workingDirectory: target.workingDirectory, credentialProfile: typeof target.backendOptions?.[target.backend]?.credential_profile === "string"
267
+ ? target.backendOptions[target.backend].credential_profile : null };
268
+ const sessionId = kiroOwnedConversation(identity);
269
+ if (!sessionId) {
270
+ unreadable++;
271
+ rows.push({ instance: target.name, backend: target.backend, status: "unreadable-store",
272
+ reason: "No owned, pinned TUI session is recorded for this directory and credential profile; the classic conversation is frozen.", findings: [] });
273
+ continue;
274
+ }
275
+ tui = { sessionId, sessionsDir: opts.kiroSessionsOverride, stillOwned: () => kiroOwnedConversation(identity) === sessionId };
276
+ }
253
277
  const result = scanKiroInstanceForForgedEnvelopes({
254
278
  instanceName: target.name,
255
279
  workingDirectory: target.workingDirectory,
@@ -257,6 +281,7 @@ export function executeForgedEnvelopeScan(opts) {
257
281
  knownInstances: opts.knownInstances,
258
282
  ...(opts.kiroDbOverride ? { kiroDbPath: opts.kiroDbOverride } : {}),
259
283
  ...(storeHome ? { storeHome } : {}),
284
+ ...(tui ? { tui } : {}),
260
285
  alreadyReportedIds: reported,
261
286
  });
262
287
  for (const f of result.findings)
@@ -1 +1 @@
1
- {"version":3,"file":"forged-envelope-scan.js","sourceRoot":"","sources":["../src/forged-envelope-scan.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,iBAAiB,CAAC;AAClD;;;;;;;;;;;;;;;;;;;GAmBG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,aAAa,CAAC;AAChC,OAAO,EAAE,UAAU,EAAE,YAAY,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;AAClE,OAAO,EAAE,IAAI,EAAE,MAAM,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AO,EAAE,8BAA8B,CAAC,EAAE,OAAO,CAAC,CAE1F,CAAC;QACF,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,GAAG,CAAC,oBAAoB,CAAC;YAAE,OAAO,IAAI,GAAG,EAAE,CAAC;QAC/D,OAAO,IAAI,GAAG,CAAC,GAAG,CAAC,oBAAoB,CAAC,MAAM,CAAC,CAAC,EAAE,EAAgB,EAAE,CAAC,OAAO,EAAE,KAAK,QAAQ,CAAC,CAAC,CAAC;IAChG,CAAC;IAAC,MAAM,CAAC;QACP,OAAO,IAAI,GAAG,EAAE,CAAC;IACnB,CAAC;AACH,CAAC;AAED,MAAM,UAAU,yBAAyB,CAAC,OAAe,EAAE,GAAqB;IAC9E,MAAM,MAAM,GAAG,uBAAuB,CAAC,OAAO,CAAC,CAAC;IAChD,KAAK,MAAM,EAAE,IAAI,GAAG;QAAE,MAAM,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC;IACrC,eAAe,CAAC,OAAO,CAAC,CAAC;IACzB,MAAM,IAAI,GAAG,IAAI,CAAC,OAAO,EAAE,8BAA8B,CAAC,CAAC;IAC3D,aAAa,CAAC,IAAI,EAAE,IAAI,CAAC,SAAS,CAAC,EAAE,oBAAoB,EAAE,CAAC,GAAG,MAAM,CAAC,EAAE,EAAE,IAAI,EAAE,CAAC,CAAC,EAAE,EAAE,QAAQ,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,CAAC,CAAC;AACzH,CAAC"}
@@ -7,3 +7,27 @@ export declare const GENERAL_PAUSE_ERROR = "General cannot be paused";
7
7
  * general_topic covers renamed and per-world General instances.
8
8
  */
9
9
  export declare function isGeneralInstance(config: FleetConfig | null | undefined, name: string): boolean;
10
+ /** M-2069: the name a fleet's General has by default (the auto-created one, and the setup's first agent). */
11
+ export declare const GENERAL_NAME = "general";
12
+ /**
13
+ * M-2069: the topic a General on this connection is bound to: the chat's own General — Telegram's built-in General
14
+ * topic (thread 1), the Discord connection's general channel — never a new forum topic. Null for a Discord connection
15
+ * without a valid general channel: a new General is then left unbound, as the fleet's own General is (autoCreateTopics),
16
+ * and an adopted one keeps the topic it has.
17
+ */
18
+ export declare function generalTopicFor(channel: Record<string, unknown>): number | string | null;
19
+ /**
20
+ * M-2069: an agent named "general" is the General to its daemon, its tool profile and the pause guard, but the fleet
21
+ * picks its dispatcher by general_topic. In a chat fleet with no General, the auto-General would be skipped (its name
22
+ * is taken) and the fleet would run with no dispatcher. So that agent is made the General — on the primary connection,
23
+ * in the chat's own General topic where it has one (Telegram's thread 1; Discord's general channel — without one, it
24
+ * keeps the topic it has). On Telegram a stray forum topic it was given is left behind, unrouted. Left alone: a
25
+ * "general" bound to another connection, a fleet that already has a General, and (#2744 review) a "general" working in
26
+ * a folder AgEnD does not own (`ownFolder`) — the General's instructions would land in a project of the user's; the
27
+ * fleet then adds its General under a free name (Phase 3). Returns whether the config changed.
28
+ */
29
+ export declare function adoptGeneralByName(fleet: FleetConfig, logger: {
30
+ warn(obj: unknown, msg?: string): void;
31
+ }, ownFolder: (dir: string) => boolean): boolean;
32
+ /** M-2069: the first free name for a General the fleet creates: `base`, else `base-2`, `base-3`, … */
33
+ export declare function freeGeneralName(instances: Record<string, unknown>, base: string): string;
@@ -1,3 +1,4 @@
1
+ import { discordGeneralChannelId } from "./discord-general.js";
1
2
  /** Stable user-facing error shared by every manual pause entry point. */
2
3
  export const GENERAL_PAUSE_ERROR = "General cannot be paused";
3
4
  /**
@@ -8,4 +9,56 @@ export const GENERAL_PAUSE_ERROR = "General cannot be paused";
8
9
  export function isGeneralInstance(config, name) {
9
10
  return name === "general" || config?.instances[name]?.general_topic === true;
10
11
  }
12
+ /** M-2069: the name a fleet's General has by default (the auto-created one, and the setup's first agent). */
13
+ export const GENERAL_NAME = "general";
14
+ /**
15
+ * M-2069: the topic a General on this connection is bound to: the chat's own General — Telegram's built-in General
16
+ * topic (thread 1), the Discord connection's general channel — never a new forum topic. Null for a Discord connection
17
+ * without a valid general channel: a new General is then left unbound, as the fleet's own General is (autoCreateTopics),
18
+ * and an adopted one keeps the topic it has.
19
+ */
20
+ export function generalTopicFor(channel) {
21
+ if (channel.type === "telegram")
22
+ return 1;
23
+ if (channel.type !== "discord")
24
+ return null;
25
+ const general = discordGeneralChannelId(channel);
26
+ return general != null && /^\d{17,}$/.test(general) ? general : null;
27
+ }
28
+ /**
29
+ * M-2069: an agent named "general" is the General to its daemon, its tool profile and the pause guard, but the fleet
30
+ * picks its dispatcher by general_topic. In a chat fleet with no General, the auto-General would be skipped (its name
31
+ * is taken) and the fleet would run with no dispatcher. So that agent is made the General — on the primary connection,
32
+ * in the chat's own General topic where it has one (Telegram's thread 1; Discord's general channel — without one, it
33
+ * keeps the topic it has). On Telegram a stray forum topic it was given is left behind, unrouted. Left alone: a
34
+ * "general" bound to another connection, a fleet that already has a General, and (#2744 review) a "general" working in
35
+ * a folder AgEnD does not own (`ownFolder`) — the General's instructions would land in a project of the user's; the
36
+ * fleet then adds its General under a free name (Phase 3). Returns whether the config changed.
37
+ */
38
+ export function adoptGeneralByName(fleet, logger, ownFolder) {
39
+ const channels = (fleet.channels ?? (fleet.channel ? [fleet.channel] : []));
40
+ if (!channels.length || !Object.hasOwn(fleet.instances, GENERAL_NAME))
41
+ return false;
42
+ const inst = fleet.instances[GENERAL_NAME];
43
+ if (inst.general_topic === true || Object.values(fleet.instances).some(cfg => cfg.general_topic === true))
44
+ return false;
45
+ const primary = channels[0], primaryId = String(primary.id ?? primary.type);
46
+ if (inst.channel_id != null && inst.channel_id !== primaryId)
47
+ return false;
48
+ if (!ownFolder(inst.working_directory))
49
+ return false;
50
+ const topic = generalTopicFor(primary), from = inst.topic_id ?? null;
51
+ inst.general_topic = true;
52
+ if (topic != null)
53
+ inst.topic_id = topic;
54
+ logger.warn({ name: GENERAL_NAME, topic_from: from, topic_to: inst.topic_id ?? null }, "An agent named general had no general_topic and the fleet had no General — made it the General (its chat's General topic)");
55
+ return true;
56
+ }
57
+ /** M-2069: the first free name for a General the fleet creates: `base`, else `base-2`, `base-3`, … */
58
+ export function freeGeneralName(instances, base) {
59
+ let name = base;
60
+ for (let n = 2; Object.hasOwn(instances, name); n++)
61
+ name = `${base}-${n}`;
62
+ return name;
63
+ }
11
64
  //# sourceMappingURL=general-instance.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"general-instance.js","sourceRoot":"","sources":["../src/general-instance.ts"],"names":[],"mappings":"AAEA,yEAAyE;AACzE,MAAM,CAAC,MAAM,mBAAmB,GAAG,0BAA0B,CAAC;AAE9D;;;;GAIG;AACH,MAAM,UAAU,iBAAiB,CAAC,MAAsC,EAAE,IAAY;IACpF,OAAO,IAAI,KAAK,SAAS,IAAI,MAAM,EAAE,SAAS,CAAC,IAAI,CAAC,EAAE,aAAa,KAAK,IAAI,CAAC;AAC/E,CAAC"}
1
+ {"version":3,"file":"general-instance.js","sourceRoot":"","sources":["../src/general-instance.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,uBAAuB,EAAE,MAAM,sBAAsB,CAAC;AAE/D,yEAAyE;AACzE,MAAM,CAAC,MAAM,mBAAmB,GAAG,0BAA0B,CAAC;AAE9D;;;;GAIG;AACH,MAAM,UAAU,iBAAiB,CAAC,MAAsC,EAAE,IAAY;IACpF,OAAO,IAAI,KAAK,SAAS,IAAI,MAAM,EAAE,SAAS,CAAC,IAAI,CAAC,EAAE,aAAa,KAAK,IAAI,CAAC;AAC/E,CAAC;AAED,6GAA6G;AAC7G,MAAM,CAAC,MAAM,YAAY,GAAG,SAAS,CAAC;AAEtC;;;;;GAKG;AACH,MAAM,UAAU,eAAe,CAAC,OAAgC;IAC9D,IAAI,OAAO,CAAC,IAAI,KAAK,UAAU;QAAE,OAAO,CAAC,CAAC;IAC1C,IAAI,OAAO,CAAC,IAAI,KAAK,SAAS;QAAE,OAAO,IAAI,CAAC;IAC5C,MAAM,OAAO,GAAG,uBAAuB,CAAC,OAAO,CAAC,CAAC;IACjD,OAAO,OAAO,IAAI,IAAI,IAAI,WAAW,CAAC,IAAI,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AAI;QAAE,IAAI,CAAC,QAAQ,GAAG,KAAK,CAAC;IACzC,MAAM,CAAC,IAAI,CAAC,EAAE,IAAI,EAAE,YAAY,EAAE,UAAU,EAAE,IAAI,EAAE,QAAQ,EAAE,IAAI,CAAC,QAAQ,IAAI,IAAI,EAAE,EACnF,2HAA2H,CAAC,CAAC;IAC/H,OAAO,IAAI,CAAC;AACd,CAAC;AAED,sGAAsG;AACtG,MAAM,UAAU,eAAe,CAAC,SAAkC,EAAE,IAAY;IAC9E,IAAI,IAAI,GAAG,IAAI,CAAC;IAChB,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,MAAM,CAAC,MAAM,CAAC,SAAS,EAAE,IAAI,CAAC,EAAE,CAAC,EAAE;QAAE,IAAI,GAAG,GAAG,IAAI,IAAI,CAAC,EAAE,CAAC;IAC3E,OAAO,IAAI,CAAC;AACd,CAAC"}
@@ -0,0 +1,25 @@
1
+ ---
2
+ name: docker-install
3
+ description: Set up AgEnD in Docker for a person, or maintain one — follow the Docker runbook step by step
4
+ roles: [general]
5
+ ---
6
+
7
+ ## AgEnD in Docker
8
+
9
+ When a person wants AgEnD in Docker (a trial, a demo, a machine without Node.js), or asks you to maintain an existing
10
+ Docker install, follow the runbook exactly. It has the Dockerfile, entrypoint, compose file, CLI installs, first
11
+ fleet.yaml, verification, updates, backups and troubleshooting:
12
+
13
+ - English: https://github.com/songsid/AgEnD/blob/main/docs/docker.md
14
+ - 繁體中文: https://github.com/songsid/AgEnD/blob/main/docs/docker.zh-TW.md
15
+
16
+ Read the raw file (`https://raw.githubusercontent.com/songsid/AgEnD/main/docs/docker.md`) before you start, and run
17
+ every check it gives.
18
+
19
+ **Rules that hold even without the runbook at hand:**
20
+ - Never run `agend update`, `agend restart`, `agend stop` or `agend install` inside the container, and never `/update`
21
+ in that fleet's chat. Update by rebuilding the image (`docker compose build --pull --no-cache && docker compose up -d`);
22
+ restart with `docker compose restart`.
23
+ - Tokens and API keys go in the compose folder's `.env`, never in fleet.yaml or a chat.
24
+ - The dashboard stays published on `127.0.0.1` unless the person asks otherwise.
25
+ - AgEnD's data, the CLIs and their logins live in the `agend-home` volume: back it up before anything destructive.
@@ -38,11 +38,13 @@ For `backend: kiro-cli` instances, `kiro_ui` selects the CLI's UI/agent profile:
38
38
  instances:
39
39
  my-kiro:
40
40
  backend: kiro-cli
41
- kiro_ui: legacy # default — current stable behavior
42
- # kiro_ui: tui # try the newer TUI
41
+ kiro_ui: tui # what every new kiro instance is written with (#2598)
42
+ # kiro_ui: legacy # the classic engine; also what an entry with no kiro_ui runs
43
43
  ```
44
44
  `kiro_ui: v3` is refused by validation — do not set it.
45
- Leave unset (or `legacy`) unless testing a newer profile. Ignored by other backends.
45
+ kiro-cli 3.0 drops the classic engine. Never change `kiro_ui` by hand to move an instance: that starts it on an
46
+ empty conversation. An existing classic instance moves with its conversation through `migrate_kiro_instance`
47
+ (the kiro-engine-migration skill). Ignored by other backends.
46
48
 
47
49
  ## Reply completion guard
48
50
 
@@ -35,7 +35,7 @@ agend update --yes # from a fleet session: the installed channel's la
35
35
  agend update --version 2.2.0 --yes # a specific version
36
36
  ```
37
37
 
38
- It installs the selected release, checks the install, and restarts the fleet service. `--alpha` / `--beta` / `--stable` pick a channel; details in docs/cli.md.
38
+ It installs the selected release, checks the install, and restarts the fleet service. `--alpha` / `--beta` / `--stable` pick a channel; details in docs/cli.md. A beta install stays on the beta channel: to move it to the stable release (for example from a 2.3.2 beta to 2.3.2), use `agend update --stable --yes`, and only when the user asked for it.
39
39
 
40
40
  **Manual restart (if update isn't needed):**
41
41
  ```bash
@@ -43,6 +43,7 @@ The user has already been shown the plain notice in this topic. When they ask, e
43
43
  - **Go back to a kiro-cli version that ran them.** `history` shows which versions launches were prepared
44
44
  with; the user knows which of those worked. Installing such a version again is the likely way back, but
45
45
  do not promise it. The user, or whoever administers the host, does this; you do not.
46
+ - **Move it to the TUI engine** with its conversation (below), if the user wants that.
46
47
  - **Wait for AgEnD's migration to V3.** It will convert each conversation once, verify it, and switch the
47
48
  instance, one instance at a time and only with the user's confirmation. It is not available yet: say so
48
49
  plainly, and never promise a date.
@@ -63,11 +64,44 @@ coordinator-level tool; you do not have it). It carries the conversation: the in
63
64
  resumed once under the TUI and becomes its own. A fleet admin confirms each move in this General topic: a
64
65
  "Move it / Cancel" prompt. Explain it if asked; never press it on the user's behalf.
65
66
 
67
+ The Confirm prompt warns about sudo/interactive passwords and explains both launches. AgEnD requires an idle
68
+ instance, a supported Kiro 2.34+ version and a known model. It carries once, verifies the owned V2 reader, then does
69
+ an ordinary restart: while the target CLI is stopped, it archives the exact frozen classic rows before removing
70
+ the duplicate from Kiro's index. It verifies the same conversation/model and attached V2 transcript again, and
71
+ reports the forensic verdict in General and the instance's topic. Queued work waits until this finishes. Failure
72
+ stops and error-pauses the instance; inspect the cause before an explicit retry. Never use a fresh conversation
73
+ or classic as a recovery shortcut. Archives are private and restorable with `agend kiro restore-classic` (see CLI docs).
74
+ The raw Log-history gate remains closed: the verification proves the launched/pinned reader, not ongoing pane
75
+ session identity after `/chat` or `/clear`.
76
+
77
+ - **After a `/compact`** classic kiro continues under a new conversation id. The move follows the same proven
78
+ compaction chain a classic restart follows and carries the newest conversation. When the chain can't be proven
79
+ (the store can't be read, two conversations continue the old one, or one belongs to another instance), the move
80
+ is refused and nothing changes: tell the user why, don't retry with `start_fresh`.
66
81
  - After the move, `kiro_engine_status` shows `kiro_ui: tui` and `engine_floor: "tui"`.
67
82
  - It is one-way. AgEnD refuses to launch a moved instance on classic again, because that would resume the frozen
68
83
  classic copy and lose everything done since. A refusal that names the engine floor means someone set `kiro_ui`
69
84
  back. The fix is to set it to `tui` again, never to remove the floor.
70
85
 
86
+ ## Other kiro behaviour users ask about
87
+
88
+ - **kiro never updates itself under AgEnD.** Every kiro process AgEnD starts carries `KIRO_NO_AUTO_UPDATE=1`, so a
89
+ self-update to kiro-cli 3.0 can't break classic instances. `app.disableAutoupdates: true` in
90
+ `~/.kiro/settings/cli.json` also stops kiro-cli's own updates; that file is the user's to change, not yours.
91
+ - **Classic restarts follow a `/compact` (#2714, #2738)** to the conversation kiro kept writing, only on proof it is
92
+ this instance's. When it can't be proven, or the check passes its 30 s / 2 GiB limit, the instance resumes the
93
+ conversation on record and the Log tab says why.
94
+ - **Two conversations after an interrupted carry (#2753).** When a stopped TUI instance has its original carried
95
+ conversation and a newer one with work, recovery holds instead of choosing. `reconcile_kiro_instance` (full and
96
+ coordinator tool sets) asks a fleet admin to confirm, in General, keeping the original and archiving the named
97
+ newer one intact. Offer it only after the user chose those exact ids; docs/kiro-reconciliation.md explains it.
98
+ - **"Kiro's terminal is in use by another program" (#2682).** While a kiro pane runs `/editor`, `/transcript`, a
99
+ `!` command or a focused `/kvim` panel (legacy: `/editor`, `/reply`, `!`), AgEnD holds deliveries. Tell the user
100
+ to finish or close that program in the instance's pane; held messages go in once kiro's input row is back.
101
+ - **A retired model (#2648).** An instance with no model of its own whose saved conversation uses a model kiro no
102
+ longer offers resumes on kiro's default model and says so once. One configured to use that model is told once to
103
+ pick another; it is never switched.
104
+
71
105
  ## One kiro agent per instance (#906)
72
106
 
73
107
  Since kiro-cli 2.21, each AgEnD kiro instance (tui / v2 engine) runs as its own kiro agent, holding only its own
@@ -151,7 +151,7 @@ for ts, sid in sorted(out, reverse=True):
151
151
  ```
152
152
  It opens many files, but only one line each, so it stays cheap.
153
153
 
154
- **Restore:** `codex exec resume <session-id> "<prompt>"` non-interactively, or `codex resume <session-id>` for the TUI (bare `codex resume` opens a picker). AgEnD launches `codex resume <id>` with the thread recorded for this exact directory; `codex resume --last` is only its fallback (an unreadable session DB, no other codex instance in the repository). The ID argument also accepts a session *name*.
154
+ **Restore:** `codex exec resume <session-id> "<prompt>"` non-interactively, or `codex resume <session-id>` for the TUI (bare `codex resume` opens a picker). AgEnD launches `codex resume <id>` with the thread recorded for this exact directory; `codex resume --last` is only its fallback (an unreadable session DB, no other codex instance in the repository). On a machine where Codex never ran, a missing session DB means a new conversation, with no warning (#2743). The ID argument also accepts a session *name*.
155
155
 
156
156
  **Summary:** ❌ none available without parsing. `session_meta` carries only id/cwd/timestamp; to describe a session you must read further `event_msg` lines. Tell the user the timestamp and let them pick, rather than guessing at a topic.
157
157
 
@@ -18,7 +18,7 @@ instances:
18
18
  ```
19
19
 
20
20
  **kiro_ui 模式差異:**
21
- - `kiro_ui: tui`:Kiro v2 TUI(需明確設定;預設是 `legacy`);本 skill 適用。
21
+ - `kiro_ui: tui`:Kiro v2 TUI(新建立的 kiro instance 都會寫入這個值;沒設定 `kiro_ui` 的既有項目仍是 `legacy`);本 skill 適用。
22
22
  - `kiro_ui: v3`:目前會被設定驗證拒絕,不要設定。
23
23
  - `kiro_ui: legacy`:舊 UI,互動行為不同,本 skill 不適用。
24
24
 
@@ -288,6 +288,38 @@ are not in your list), you can direct your own character for a moment:
288
288
  { "go": { "person": "atlas" }, "say": "Review's ready", "seconds": 20 }
289
289
  ```
290
290
 
291
+ ## Office skin packs (everyone's)
292
+
293
+ The Office view draws offices in **skin packs**, which every viewer on the fleet sees. When a person switches the
294
+ **office_packs** dashboard feature on for you (`office_pack_access: true`, its own switch — off until then, and the
295
+ tools are not in your list), you can publish them yourself instead of asking a person to upload each fix by hand:
296
+
297
+ - `office_pack_list {}` first: each pack's `id`, `name`, `files`, `bytes`, `version`, `previous` (a kept previous
298
+ version you can restore, or null) and the `offices` drawn in it; the stored offices and their style; the fleet's
299
+ `approval` (`"apply"`: at once; `"approve"`: a fleet admin's yes first — the default); your `pending` changes; the
300
+ `limits` and what is `left` of your hour.
301
+ - `office_pack_check { dir }` runs the host's own checks and stores nothing: `{ result: "PACK OK", packs: [...] }` or the
302
+ first refusal. `dir` is a folder with its `manifest.json` and the PNGs at the paths the manifest names, in your working
303
+ directory or the fleet's shared folder (`~/.agend/shared`); a symlink is followed and must stay inside. Only those
304
+ files are read. Or `manifest` (the object) + `files` (`{ "<name it uses>": "<path>" }`); `packs: [...]` for several.
305
+ - `office_pack_upload` (the same inputs) keeps it — an id the fleet keeps is **replaced** at once (no delete first; on
306
+ any failure the old one stays) and its previous version is kept. If a stored office's layout overrides would no
307
+ longer fit (a seat count changed, a seat left its area, an item is gone), check and upload refuse with the office
308
+ and the rule: fix the pack, or send `drop_invalid_overrides: true` to drop exactly those entries (the result names
309
+ them). With `"approve"` the answer is `{ pending }`: it waits for an admin's yes — say so; do not upload it again. A pending change that drops layout entries is applied
310
+ only if it still drops exactly the entries its notice named: if an office was edited meanwhile, the approval is
311
+ refused and you send the change again (#2695).
312
+ - `office_pack_restore { id }` brings back the previous version (the replaced one becomes the previous);
313
+ `office_pack_delete { id, keep_previous? }`; `office_set_style { office, pack }` points a stored office at a pack or a
314
+ built-in style (pixel, studio, cozy).
315
+ - Every change is logged with each picture's sha256 and told to the fleet's admins. At most **20 batches and 200 MiB an
316
+ hour**: one call is one batch (up to 16 packs), so send a whole set of fixes in one `packs: [...]`.
317
+ - `office_pack_check` has its own allowance: at most **60 checks and 1 GiB (as sent) an hour**. Every check counts,
318
+ passed or refused, so fix what a refusal names before checking again. `office_pack_list` shows `check_left`.
319
+
320
+ The skin-pack manifest format — every key, its ranges, a minimal example — and the limits are in the Office guide:
321
+ [docs/office.md → Make a skin pack](https://github.com/songsid/AgEnD/blob/main/docs/office.md#make-a-skin-pack). Point people there too when they ask how the Office works.
322
+
291
323
  ## Limits
292
324
 
293
325
  - At least **30 s** between changes, at most **10 changes an hour** — refused with `rate_limited` and
@@ -296,6 +296,38 @@ are not in your list), you can direct your own character for a moment:
296
296
  { "go": { "person": "atlas" }, "say": "Review's ready", "seconds": 20 }
297
297
  ```
298
298
 
299
+ ## Office skin packs (everyone's)
300
+
301
+ The Office view draws offices in **skin packs**, which every viewer on the fleet sees. When a person switches the
302
+ **office_packs** dashboard feature on for you (`office_pack_access: true`, its own switch — off until then, and the
303
+ tools are not in your list), you can publish them yourself instead of asking a person to upload each fix by hand:
304
+
305
+ - `office_pack_list {}` first: each pack's `id`, `name`, `files`, `bytes`, `version`, `previous` (a kept previous
306
+ version you can restore, or null) and the `offices` drawn in it; the stored offices and their style; the fleet's
307
+ `approval` (`"apply"`: at once; `"approve"`: a fleet admin's yes first — the default); your `pending` changes; the
308
+ `limits` and what is `left` of your hour.
309
+ - `office_pack_check { dir }` runs the host's own checks and stores nothing: `{ result: "PACK OK", packs: [...] }` or the
310
+ first refusal. `dir` is a folder with its `manifest.json` and the PNGs at the paths the manifest names, in your working
311
+ directory or the fleet's shared folder (`~/.agend/shared`); a symlink is followed and must stay inside. Only those
312
+ files are read. Or `manifest` (the object) + `files` (`{ "<name it uses>": "<path>" }`); `packs: [...]` for several.
313
+ - `office_pack_upload` (the same inputs) keeps it — an id the fleet keeps is **replaced** at once (no delete first; on
314
+ any failure the old one stays) and its previous version is kept. If a stored office's layout overrides would no
315
+ longer fit (a seat count changed, a seat left its area, an item is gone), check and upload refuse with the office
316
+ and the rule: fix the pack, or send `drop_invalid_overrides: true` to drop exactly those entries (the result names
317
+ them). With `"approve"` the answer is `{ pending }`: it waits for an admin's yes — say so; do not upload it again. A pending change that drops layout entries is applied
318
+ only if it still drops exactly the entries its notice named: if an office was edited meanwhile, the approval is
319
+ refused and you send the change again (#2695).
320
+ - `office_pack_restore { id }` brings back the previous version (the replaced one becomes the previous);
321
+ `office_pack_delete { id, keep_previous? }`; `office_set_style { office, pack }` points a stored office at a pack or a
322
+ built-in style (pixel, studio, cozy).
323
+ - Every change is logged with each picture's sha256 and told to the fleet's admins. At most **20 batches and 200 MiB an
324
+ hour**: one call is one batch (up to 16 packs), so send a whole set of fixes in one `packs: [...]`.
325
+ - `office_pack_check` has its own allowance: at most **60 checks and 1 GiB (as sent) an hour**. Every check counts,
326
+ passed or refused, so fix what a refusal names before checking again. `office_pack_list` shows `check_left`.
327
+
328
+ The skin-pack manifest format — every key, its ranges, a minimal example — and the limits are in the Office guide:
329
+ [docs/office.md → Make a skin pack](https://github.com/songsid/AgEnD/blob/main/docs/office.md#make-a-skin-pack). Point people there too when they ask how the Office works.
330
+
299
331
  ## Mods
300
332
 
301
333
  A mod is one file, `<name>-<version>.agendmod.json`, that carries a look: a theme with its pictures, card text,