@songsid/agend 2.4.0-beta.20 → 2.4.0-beta.21

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (176) hide show
  1. package/dist/agent-cli-instructions.md +1 -1
  2. package/dist/backend/claude-carry.d.ts +11 -0
  3. package/dist/backend/claude-carry.js +88 -6
  4. package/dist/backend/claude-carry.js.map +1 -1
  5. package/dist/build-provenance.json +1 -1
  6. package/dist/channel/mcp-tools.js +6 -4
  7. package/dist/channel/mcp-tools.js.map +1 -1
  8. package/dist/contact-change-proposals.d.ts +47 -0
  9. package/dist/contact-change-proposals.js +131 -0
  10. package/dist/contact-change-proposals.js.map +1 -0
  11. package/dist/fleet-manager.d.ts +25 -1
  12. package/dist/fleet-manager.js +166 -3
  13. package/dist/fleet-manager.js.map +1 -1
  14. package/dist/general-knowledge/skills/concepts/SKILL.md +2 -1
  15. package/dist/general-knowledge/skills/hub/SKILL.md +39 -2
  16. package/dist/general-knowledge/skills/task-board/SKILL.md +4 -0
  17. package/dist/general-knowledge/skills/web-appearance/SKILL.md +1 -1
  18. package/dist/general-knowledge/skills/web-dashboard/SKILL.md +16 -6
  19. package/dist/hub/agent-pictures-model.d.ts +147 -0
  20. package/dist/hub/agent-pictures-model.js +64 -0
  21. package/dist/hub/agent-pictures-model.js.map +1 -0
  22. package/dist/hub/agent-pictures.d.ts +52 -0
  23. package/dist/hub/agent-pictures.js +202 -0
  24. package/dist/hub/agent-pictures.js.map +1 -0
  25. package/dist/hub/client.d.ts +2 -0
  26. package/dist/hub/client.js +16 -2
  27. package/dist/hub/client.js.map +1 -1
  28. package/dist/hub/compose/member.d.ts +10 -2
  29. package/dist/hub/compose/member.js +32 -8
  30. package/dist/hub/compose/member.js.map +1 -1
  31. package/dist/hub/compose/server.d.ts +1 -0
  32. package/dist/hub/compose/server.js +4 -2
  33. package/dist/hub/compose/server.js.map +1 -1
  34. package/dist/hub/direct-posts-model.d.ts +1 -0
  35. package/dist/hub/direct-posts-model.js +2 -0
  36. package/dist/hub/direct-posts-model.js.map +1 -0
  37. package/dist/hub/direct-posts.d.ts +36 -0
  38. package/dist/hub/direct-posts.js +145 -0
  39. package/dist/hub/direct-posts.js.map +1 -0
  40. package/dist/hub/http/compose.d.ts +2 -0
  41. package/dist/hub/http/compose.js +155 -19
  42. package/dist/hub/http/compose.js.map +1 -1
  43. package/dist/hub/http/core.d.ts +9 -1
  44. package/dist/hub/http/core.js +21 -1
  45. package/dist/hub/http/core.js.map +1 -1
  46. package/dist/hub/http/schema.js +6 -0
  47. package/dist/hub/http/schema.js.map +1 -1
  48. package/dist/hub/join/service.d.ts +2 -0
  49. package/dist/hub/join/service.js +7 -3
  50. package/dist/hub/join/service.js.map +1 -1
  51. package/dist/hub/mcp/policy.d.ts +1 -1
  52. package/dist/hub/member/agent-pictures.d.ts +43 -0
  53. package/dist/hub/member/agent-pictures.js +125 -0
  54. package/dist/hub/member/agent-pictures.js.map +1 -0
  55. package/dist/hub/member/direct-rooms.d.ts +9 -0
  56. package/dist/hub/member/direct-rooms.js +14 -0
  57. package/dist/hub/member/direct-rooms.js.map +1 -0
  58. package/dist/hub/member/room-post.d.ts +11 -10
  59. package/dist/hub/member/room-post.js +51 -7
  60. package/dist/hub/member/room-post.js.map +1 -1
  61. package/dist/hub/policy.d.ts +11 -2
  62. package/dist/hub/policy.js +60 -7
  63. package/dist/hub/policy.js.map +1 -1
  64. package/dist/hub/protocol.d.ts +123 -1
  65. package/dist/hub/protocol.js +17 -7
  66. package/dist/hub/protocol.js.map +1 -1
  67. package/dist/hub/representative.d.ts +28 -0
  68. package/dist/hub/representative.js +127 -12
  69. package/dist/hub/representative.js.map +1 -1
  70. package/dist/hub/rooms/agents.d.ts +2 -0
  71. package/dist/hub/rooms/agents.js +14 -3
  72. package/dist/hub/rooms/agents.js.map +1 -1
  73. package/dist/hub/rooms/direct-view.d.ts +3 -2
  74. package/dist/hub/rooms/direct-view.js +23 -8
  75. package/dist/hub/rooms/direct-view.js.map +1 -1
  76. package/dist/hub/rooms/office.d.ts +9 -0
  77. package/dist/hub/rooms/office.js +10 -2
  78. package/dist/hub/rooms/office.js.map +1 -1
  79. package/dist/hub/rooms/service.d.ts +32 -1
  80. package/dist/hub/rooms/service.js +37 -3
  81. package/dist/hub/rooms/service.js.map +1 -1
  82. package/dist/hub/rooms/types.d.ts +5 -2
  83. package/dist/hub/rooms.d.ts +9 -0
  84. package/dist/hub/rooms.js +97 -26
  85. package/dist/hub/rooms.js.map +1 -1
  86. package/dist/hub/runtime.d.ts +1 -1
  87. package/dist/hub/server.js +19 -2
  88. package/dist/hub/server.js.map +1 -1
  89. package/dist/hub/session-directory-transition.d.ts +1 -0
  90. package/dist/hub/session-directory-transition.js +15 -9
  91. package/dist/hub/session-directory-transition.js.map +1 -1
  92. package/dist/hub/session-limits.d.ts +58 -0
  93. package/dist/hub/session-limits.js +121 -0
  94. package/dist/hub/session-limits.js.map +1 -0
  95. package/dist/hub/sessions.d.ts +1 -1
  96. package/dist/hub/sessions.js +13 -7
  97. package/dist/hub/sessions.js.map +1 -1
  98. package/dist/hub/settings-directory-decision.js +1 -1
  99. package/dist/hub/settings-directory-decision.js.map +1 -1
  100. package/dist/hub/types.d.ts +8 -2
  101. package/dist/hub-picture-reduce.d.ts +14 -0
  102. package/dist/hub-picture-reduce.js +49 -0
  103. package/dist/hub-picture-reduce.js.map +1 -0
  104. package/dist/hub-picture-worker.d.ts +1 -0
  105. package/dist/hub-picture-worker.js +11 -0
  106. package/dist/hub-picture-worker.js.map +1 -0
  107. package/dist/hub-report-target.d.ts +6 -0
  108. package/dist/hub-report-target.js +6 -0
  109. package/dist/hub-report-target.js.map +1 -1
  110. package/dist/locale.js +90 -2
  111. package/dist/locale.js.map +1 -1
  112. package/dist/needs-you.d.ts +4 -0
  113. package/dist/needs-you.js +2 -0
  114. package/dist/needs-you.js.map +1 -1
  115. package/dist/outbound-handlers.d.ts +4 -0
  116. package/dist/outbound-handlers.js +37 -4
  117. package/dist/outbound-handlers.js.map +1 -1
  118. package/dist/outbound-schemas.d.ts +2 -0
  119. package/dist/outbound-schemas.js +6 -4
  120. package/dist/outbound-schemas.js.map +1 -1
  121. package/dist/task-board-tool.d.ts +17 -0
  122. package/dist/task-board-tool.js +58 -6
  123. package/dist/task-board-tool.js.map +1 -1
  124. package/dist/tool-permissions.js +2 -2
  125. package/dist/tool-permissions.js.map +1 -1
  126. package/dist/ui/contact-tool-groups.js +1 -1
  127. package/dist/ui/fleet-canvas.js +2 -1
  128. package/dist/ui/fleet-office-card.js +20 -5
  129. package/dist/ui/fleet-office-dialogue.d.ts +6 -3
  130. package/dist/ui/fleet-office-dialogue.js +13 -3
  131. package/dist/ui/fleet-office-layout.js +13 -13
  132. package/dist/ui/fleet-office-model.js +3 -2
  133. package/dist/ui/fleet-office-overview.js +1 -1
  134. package/dist/ui/fleet-office-pack.d.ts +17 -7
  135. package/dist/ui/fleet-office-pack.js +106 -38
  136. package/dist/ui/fleet-office-play.js +11 -4
  137. package/dist/ui/fleet-office-skin.js +25 -11
  138. package/dist/ui/fleet-office-store.js +10 -1
  139. package/dist/ui/fleet-office-talk.js +423 -0
  140. package/dist/ui/fleet-office-view.js +26 -17
  141. package/dist/ui/fleet-office-zones.js +20 -12
  142. package/dist/ui/fleet-office.js +173 -44
  143. package/dist/ui/fleet-task-common.js +1 -1
  144. package/dist/ui/fleet-task-sort.js +88 -0
  145. package/dist/ui/fleet-task-view.js +38 -9
  146. package/dist/ui/fleet-tasks.js +47 -15
  147. package/dist/ui/hub-chat-store.js +4 -3
  148. package/dist/ui/hub-chat-strings.js +2 -0
  149. package/dist/ui/hub-client.js +3 -0
  150. package/dist/ui/hub-my-agents-strings.js +2 -2
  151. package/dist/ui/hub-my-agents.js +3 -0
  152. package/dist/ui/hub-room-composer.js +24 -4
  153. package/dist/ui/hub-room-members.js +7 -3
  154. package/dist/ui/hub-room-office.js +2 -1
  155. package/dist/ui/hub-room-presence.js +9 -0
  156. package/dist/ui/hub-room-strings.js +18 -2
  157. package/dist/ui/hub-room-thread.js +82 -13
  158. package/dist/ui/hub-room-working.js +37 -0
  159. package/dist/ui/hub-session-limits.js +79 -0
  160. package/dist/ui/panel-hub.js +41 -6
  161. package/dist/ui/panel-needs.js +28 -2
  162. package/dist/ui/shared/app.css +84 -3
  163. package/dist/ui/shared/chat-strings.js +1 -1
  164. package/dist/ui/shared/hub-owner.css +5 -0
  165. package/dist/ui/shared/hub-rooms-u2.css +3 -0
  166. package/dist/ui/shared/office-dialogue.css +110 -0
  167. package/dist/ui/shared/task-board.css +103 -7
  168. package/dist/web-api.d.ts +5 -0
  169. package/dist/web-api.js +29 -0
  170. package/dist/web-api.js.map +1 -1
  171. package/dist/web-office-skins.d.ts +8 -2
  172. package/dist/web-office-skins.js +33 -14
  173. package/dist/web-office-skins.js.map +1 -1
  174. package/dist/web-office-store.js +5 -3
  175. package/dist/web-office-store.js.map +1 -1
  176. package/package.json +1 -1
@@ -1,3 +1,4 @@
1
+ import { prepareContactChange } from "./contact-change-proposals.js";
1
2
  import { detectMonitoringPlatform } from './host-monitoring-defaults.js';
2
3
  import { SharedDefaultAdoption } from "./shared-default-adoption.js";
3
4
  import { scopedDefaultModel } from "./model-defaults.js";
@@ -2773,6 +2774,7 @@ export class FleetManager {
2773
2774
  boundHub: () => this.hubMemberBinding?.(this.dataDir)?.hubId ?? null,
2774
2775
  agents: () => this.hubMemberAgents(),
2775
2776
  catalogAgents: () => this.hubCatalogAgents(),
2777
+ pictureSources: agent => this.hubPictureSources(agent),
2776
2778
  sharingNotice: value => this.recordHubSharingNotice(value),
2777
2779
  attachSharing: controller => { this.hubSharingController = controller; },
2778
2780
  maxCrossInstanceMessageBytes: () => this.fleetConfig?.defaults?.max_cross_instance_message_bytes,
@@ -2821,7 +2823,7 @@ export class FleetManager {
2821
2823
  : this.getInstanceAdapterId(agent) === actor.adapter_id && this.isFleetAdmin(actor.user_id, actor.adapter_id),
2822
2824
  }, caller.agent, receiptId),
2823
2825
  attachExposures: api => this.attachHubMemberExposures(api),
2824
- attachAttention: read => this.attachHubExecutionAttention(read),
2826
+ attachAttention: (read, retry) => this.attachHubExecutionAttention(read, retry),
2825
2827
  updates: { idle: () => this.hubUpdateIdle(), busy: () => !!this.webUpdateOwned || isUpdateInProgress(this.dataDir),
2826
2828
  canInstall: () => this.hubUpdateCanInstall(), launch: (row, control) => this.launchHubUpdate(row, control),
2827
2829
  active: id => this.hubUpdateOwned?.id === id, outcome: row => this.hubUpdateOutcome(row), notify: n => this.recordHubUpdateNotice(n) },
@@ -2930,6 +2932,63 @@ export class FleetManager {
2930
2932
  : { ...base, shareable: true };
2931
2933
  });
2932
2934
  }
2935
+ /**
2936
+ * M-3533 R2b: an agent's pictures for the Hub's room offices, as this Fleet shows them (hub-office-visit.md "Decided while
2937
+ * building"). The disc is the sidebar's (webIdentityImage + instance-nav.js avatarOf): a profile picture, else its theme
2938
+ * avatar while the owner shows agents' themes (fx.show), else its bot's avatar, else a Discord custom persona emoji; a
2939
+ * Unicode emoji or an initial is no picture (the catalog's emoji stays). The portrait is the identity card's (a person's,
2940
+ * else the agent's own). Cheap keys only: the bytes are read when a key changes (hub/member/agent-pictures.ts).
2941
+ */
2942
+ hubPictureSources(name) {
2943
+ let disc = null;
2944
+ let portrait = null;
2945
+ try {
2946
+ const profileFile = profileIdentities(this.dataDir).get(name)?.avatar_path;
2947
+ let profileVersion = null;
2948
+ if (profileFile && imageMimeForFile(profileFile)) {
2949
+ try {
2950
+ profileVersion = Math.floor(statSync(join(this.dataDir, "avatars", basename(profileFile))).mtimeMs).toString(36);
2951
+ }
2952
+ catch { /* removed */ }
2953
+ }
2954
+ let theme = { v: 1 };
2955
+ try {
2956
+ theme = this.themeStore.get(name).theme;
2957
+ }
2958
+ catch { /* unreadable themes: none */ }
2959
+ let themesShown = true;
2960
+ try {
2961
+ themesShown = this.webPrefs.read(OPERATOR).values["fx.show"] !== false;
2962
+ }
2963
+ catch { /* the default: shown */ }
2964
+ // The key names the file and its version (Prism #4393: two agents' uploads may share an mtime).
2965
+ if (profileVersion)
2966
+ disc = { key: `profile:${basename(profileFile)}:${profileVersion}`, load: () => this.webImage("avatar", name) };
2967
+ else if (themesShown && theme.avatar) {
2968
+ const id = theme.avatar;
2969
+ disc = { key: `theme:${id}`, load: () => this.themeStore.asset(name, id) };
2970
+ }
2971
+ else {
2972
+ const bots = this.webBots(), connection = bots.own.get(name) ?? bots.speaking.get(name);
2973
+ const owner = connection ? this.botOwner(connection) : null;
2974
+ const source = connection && owner?.adapter.fetchBotAvatar ? this.botAvatarSource(connection, owner) : null;
2975
+ const bot = source ? this.webImageCache("avatars").peek(source.key, source.load) : null;
2976
+ if (source && bot)
2977
+ disc = { key: `${source.key}:${bot.version}`, load: () => this.webImageCache("avatars").read(source.key) };
2978
+ else {
2979
+ const emoji = normalizeEmoji(this.ownInstanceConfig(name)?.status_emojis?.delivered);
2980
+ const cached = emoji?.kind === "custom" ? this.webImageCache("emoji").read(`emoji:${emoji.id}`) : null;
2981
+ if (emoji?.kind === "custom" && cached)
2982
+ disc = { key: `emoji:${emoji.id}:${cached.version}`, load: () => this.webImageCache("emoji").read(`emoji:${emoji.id}`) };
2983
+ }
2984
+ }
2985
+ const person = humanCards(this.dataDir).get(name)?.portrait ?? null, own = theme.card?.portrait ?? null;
2986
+ if (person || own)
2987
+ portrait = { key: person ? `card:${person}` : `agent-card:${own}`, load: () => cardPicture({ dataDir: this.dataDir, themeStore: this.themeStore }, name, "portrait") };
2988
+ }
2989
+ catch { /* unreadable: no pictures */ }
2990
+ return { disc, portrait };
2991
+ }
2933
2992
  /** The actual launch target, including Classic's own effective backend/folder; never aliases a room to a Fleet topic. */
2934
2993
  hubAgentConfig(agent) {
2935
2994
  const instances = this.fleetConfig?.instances ?? {};
@@ -3682,6 +3741,8 @@ export class FleetManager {
3682
3741
  /** #3292: "Keep sign-in alive" (signin-keepalive.ts); built at startup, stopped at shutdown. */
3683
3742
  signInKeepAlive = null;
3684
3743
  hubExecutionAttention = null;
3744
+ /** M-3632: the member's "Try again" for a held Hub question (null while no member runs). */
3745
+ hubHeldRetry = null;
3685
3746
  missedOfflineStore = null;
3686
3747
  configHistory = null;
3687
3748
  configHistoryTimer = null;
@@ -6278,6 +6339,93 @@ export class FleetManager {
6278
6339
  originRevision: service.host.store.originRevision(name) });
6279
6340
  return this.contactPermissions(name, actor);
6280
6341
  }
6342
+ /** General can propose only. The platform callback supplies the human actor. */
6343
+ async requestContactChange(requester, raw, callerCurrent) {
6344
+ if (!callerCurrent() || this.fleetConfig?.instances[requester]?.general_topic !== true)
6345
+ throw Error("general-only");
6346
+ if (this.hubContactRestricted(requester))
6347
+ throw Error("hub-contact-restricted");
6348
+ const pending = [...this.pendingNonceButtons.values()].filter(e => e.prefix === "contact-change:");
6349
+ if (pending.length >= 64 || pending.filter(e => e.generalName === requester).length >= 8)
6350
+ throw Error("contact-proposal-limit");
6351
+ const service = this.contactService();
6352
+ const plan = prepareContactChange(raw, { service, label: n => this.fleetConfig?.instances[n]?.display_name || this.contactRoom(n)?.displayName || n, timeZone: () => this.usageZone(), mode: n => { const room = this.contactRoom(n); return room ? room.restrictedMode ? "restricted" : "legacy" : undefined; },
6353
+ generation: n => this.contactGeneration(n), modeAdmin: (n, p) => this.contactAdminOf(n, p),
6354
+ write: (n, value, p) => this.writeContactPermissions(n, value, p), decide: (id, value, p) => this.decideContactAuthorization(id, value, p) });
6355
+ const targetAdapter = this.contactAdapter(plan.target);
6356
+ if (!targetAdapter || !["discord", "telegram"].includes(targetAdapter.type))
6357
+ throw Error("contact-proposal-use-web");
6358
+ const routes = Object.keys(this.fleetConfig?.instances ?? {}).flatMap(n => {
6359
+ const route = this.settingsGeneralRoute(n, targetAdapter.type, new Set());
6360
+ return route && route.adapterId === targetAdapter.id && route.adapter === targetAdapter ? [{ name: n, ...route }] : [];
6361
+ });
6362
+ if (routes.length !== 1)
6363
+ throw Error("contact-proposal-route-unavailable");
6364
+ const route = routes[0], requesterPin = this.lifecyclePin(requester), deadline = performance.now() + 5 * 60_000;
6365
+ let retired = false;
6366
+ const current = () => !retired && !this.shuttingDown && performance.now() < deadline && callerCurrent() && requesterPin()
6367
+ && this.fleetConfig?.instances[requester]?.general_topic === true && !this.hubContactRestricted(requester)
6368
+ && route.current() && this.contactAdapter(plan.target) === targetAdapter && this.adapters.get(targetAdapter.id) === targetAdapter && plan.current();
6369
+ if (!current())
6370
+ throw Error("conflict");
6371
+ const posted = this.postNonceButtonPromptOrThrow({ prefix: "contact-change:", alertType: "clear_confirm", instanceName: route.name,
6372
+ adapter: route.adapter, adapterId: route.adapterId, chatId: route.chatId, threadId: route.topic,
6373
+ message: [t("contactProposal.title"), ...plan.summary].join("\n"),
6374
+ choices: [{ action: "confirm", label: t("contactProposal.confirm") }, { action: "cancel", label: t("contactProposal.cancel") }],
6375
+ expiredText: t("contactProposal.expired"), timeoutMs: 5 * 60_000,
6376
+ extra: { generalName: requester, contactChange: { plan, current } } });
6377
+ const retire = (nonce) => {
6378
+ const entry = this.pendingNonceButtons.get(nonce);
6379
+ if (!entry)
6380
+ return;
6381
+ this.pendingNonceButtons.delete(nonce);
6382
+ if (entry.timer)
6383
+ clearTimeout(entry.timer);
6384
+ void this.retireNonceButtons(entry, entry.messageId ?? "", t("contactProposal.expired"));
6385
+ };
6386
+ void posted.then(nonce => { if (retired || !current())
6387
+ retire(nonce); }, () => { });
6388
+ try {
6389
+ const nonce = await withinBudget(posted, performance.now() + 5000);
6390
+ if (!current()) {
6391
+ retire(nonce);
6392
+ throw Error("conflict");
6393
+ }
6394
+ return { status: "awaiting_platform_admin_confirmation" };
6395
+ }
6396
+ catch (error) {
6397
+ retired = true;
6398
+ throw error;
6399
+ }
6400
+ }
6401
+ async handleContactChangeCallback(data, adapterId, adapter) {
6402
+ if (!data.callbackData.startsWith("contact-change:"))
6403
+ return false;
6404
+ const person = data.userId && adapter && this.adapters.get(adapterId) === adapter && adapter.id === adapterId
6405
+ && (adapter.type === "discord" || adapter.type === "telegram") && data.userId !== adapter.getBotUserId?.()
6406
+ ? { platform: adapter.type, adapterId, userId: data.userId, label: data.username || data.userId } : null;
6407
+ const claimed = this.consumeNonceCallback("contact-change:", /^contact-change:([0-9a-f]{32}):(confirm|cancel)$/, data, adapterId, adapter, undefined, (_user, entry) => !!person && !!entry.messageId && !this.webPromptClicks.has(data) && entry.contactChange?.plan.authorized(person) === true);
6408
+ if (claimed === null)
6409
+ return false;
6410
+ if (claimed === "consumed")
6411
+ return true;
6412
+ const { entry, action } = claimed;
6413
+ const stillCurrent = entry.lifecycleCurrent?.() === true && entry.contactChange?.current() === true;
6414
+ let text = t(stillCurrent ? "contactProposal.cancelled" : "contactProposal.expired");
6415
+ if (action === "confirm" && stillCurrent) {
6416
+ try {
6417
+ if (!person)
6418
+ throw Error("forbidden");
6419
+ entry.contactChange.plan.apply(person);
6420
+ text = entry.contactChange.plan.success;
6421
+ }
6422
+ catch {
6423
+ text = t("contactProposal.failed");
6424
+ }
6425
+ }
6426
+ await this.retireNonceButtons(entry, entry.messageId ?? data.messageId, text);
6427
+ return true;
6428
+ }
6281
6429
  contactAuthorization(id, actor) {
6282
6430
  const service = this.contactService(), ticket = service.host.store.get(id);
6283
6431
  if (!ticket)
@@ -11261,7 +11409,7 @@ export class FleetManager {
11261
11409
  result = { carried: false, reason: `copy failed: ${err.message}` };
11262
11410
  }
11263
11411
  if (result.carried) {
11264
- const fields = { name, from: sw.from ?? "default", to: sw.to ?? "default", bytes: result.bytes, ms: result.ms, replacedOlderCopy: result.replacedOlderCopy };
11412
+ const fields = { name, from: sw.from ?? "default", to: sw.to ?? "default", bytes: result.bytes, ms: result.ms, replacedOlderCopy: result.replacedOlderCopy, ...(result.backedUp ? { backedUp: result.backedUp } : {}) };
11265
11413
  if (result.bytes > CARRY_LARGE_BYTES)
11266
11414
  this.logger.warn(fields, "Conversation carried to the new credential profile (a large transcript)");
11267
11415
  else
@@ -20644,6 +20792,8 @@ export class FleetManager {
20644
20792
  return true;
20645
20793
  if (await this.handleLoginBackendSelect(data, adapterId, adapter))
20646
20794
  return true;
20795
+ if (await this.handleContactChangeCallback(data, adapterId, adapter))
20796
+ return true;
20647
20797
  if (await this.handleSettingsChangeCallback(data, adapterId, adapter))
20648
20798
  return true;
20649
20799
  if (await this.handleKiroMigrateCallback(data, adapterId, adapter))
@@ -20720,9 +20870,22 @@ export class FleetManager {
20720
20870
  return this.needsYou?.webItems() ?? [];
20721
20871
  }
20722
20872
  /** Enabled member composition supplies only a local attention reader, never an approval/execution callback. */
20723
- attachHubExecutionAttention(read) {
20873
+ attachHubExecutionAttention(read, retry = null) {
20724
20874
  this.hubExecutionAttention = read;
20875
+ this.hubHeldRetry = read ? retry : null;
20876
+ this.needsYou?.poke();
20877
+ }
20878
+ /**
20879
+ * M-3632: Needs you → "Try again" on held Hub work (`hub:hold:<row>`). The question goes back through the member's whole
20880
+ * hand-off, including the Hub's begin lease; nothing is delivered without it.
20881
+ */
20882
+ retryHubHeld(itemId) {
20883
+ const id = itemId.startsWith("hub:") ? itemId.slice(4) : itemId;
20884
+ if (!this.hubHeldRetry || !id.startsWith("hold:"))
20885
+ return { status: 404, code: "not-found" };
20886
+ const code = this.hubHeldRetry(id);
20725
20887
  this.needsYou?.poke();
20888
+ return { status: code === "queued" ? 200 : code === "not-found" ? 404 : 409, code };
20726
20889
  }
20727
20890
  /**
20728
20891
  * #1389: the org chart's structure for the web — the instances the dashboard lists (getUiStatus's names), General,