@senguoyun/dsh-arkme 0.1.84 → 0.1.85

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 (64) hide show
  1. package/docs/self-role-cross-client.md +60 -0
  2. package/lib/client.js +1397 -419
  3. package/lib/client.js.map +1 -1
  4. package/lib/harness-model-client.js +58 -0
  5. package/lib/harness-native-selection-client.js +58 -0
  6. package/lib/harness-sidebar-client.js +40 -0
  7. package/lib/index.js +135 -66
  8. package/lib/persistent-extension.js +1 -1
  9. package/lib/{persistent-runtime-CuKplHIv.js → persistent-runtime-adGFmkIa.js} +457 -93
  10. package/lib/sdk.js +40 -0
  11. package/lib/types/arkme-service.d.ts +2 -3
  12. package/lib/types/arkme-service.d.ts.map +1 -1
  13. package/lib/types/client/ArkmeCalendarSurface.d.ts.map +1 -1
  14. package/lib/types/client/ArkmeFileViewer.d.ts.map +1 -1
  15. package/lib/types/client/ArkmeLongArticleDialog.d.ts +0 -1
  16. package/lib/types/client/ArkmeLongArticleDialog.d.ts.map +1 -1
  17. package/lib/types/client/ArkmeLongArticleDraftDialog.d.ts +11 -0
  18. package/lib/types/client/ArkmeLongArticleDraftDialog.d.ts.map +1 -0
  19. package/lib/types/client/ArkmeMarkdownBody.d.ts +2 -1
  20. package/lib/types/client/ArkmeMarkdownBody.d.ts.map +1 -1
  21. package/lib/types/client/ArkmePersistentShell.d.ts.map +1 -1
  22. package/lib/types/client/ArkmeRecordingSurface.d.ts.map +1 -1
  23. package/lib/types/client/ArkmeSelfRoleMenu.d.ts +15 -0
  24. package/lib/types/client/ArkmeSelfRoleMenu.d.ts.map +1 -0
  25. package/lib/types/client/ArkmeSelfRolePicker.d.ts.map +1 -1
  26. package/lib/types/client/ArkmeVirtualWorkspace.d.ts.map +1 -1
  27. package/lib/types/client/locale.d.ts +1 -1
  28. package/lib/types/client/locale.d.ts.map +1 -1
  29. package/lib/types/client/locales/actions-en.d.ts.map +1 -1
  30. package/lib/types/client/locales/en.d.ts.map +1 -1
  31. package/lib/types/client/realtime-client-events.d.ts.map +1 -1
  32. package/lib/types/client/recordings/ArkmeRecordingTimeline.d.ts.map +1 -1
  33. package/lib/types/local-database.d.ts +8 -10
  34. package/lib/types/local-database.d.ts.map +1 -1
  35. package/lib/types/markdown.d.ts +1 -0
  36. package/lib/types/markdown.d.ts.map +1 -1
  37. package/lib/types/recording-presentation.d.ts.map +1 -1
  38. package/lib/types/sdk/index.d.ts +11 -0
  39. package/lib/types/sdk/index.d.ts.map +1 -1
  40. package/lib/types/self-role-avatar-store.d.ts +1 -6
  41. package/lib/types/self-role-avatar-store.d.ts.map +1 -1
  42. package/lib/types/self-role-contract.d.ts +13 -0
  43. package/lib/types/self-role-contract.d.ts.map +1 -0
  44. package/lib/types/self-role-sync-store.d.ts +44 -0
  45. package/lib/types/self-role-sync-store.d.ts.map +1 -0
  46. package/lib/types/services/chat-realtime-service.d.ts +1 -0
  47. package/lib/types/services/chat-realtime-service.d.ts.map +1 -1
  48. package/lib/types/services/chat-service.d.ts.map +1 -1
  49. package/lib/types/services/media-service.d.ts +15 -0
  50. package/lib/types/services/media-service.d.ts.map +1 -1
  51. package/lib/types/services/record-service.d.ts +3 -0
  52. package/lib/types/services/record-service.d.ts.map +1 -1
  53. package/lib/types/services/search-service.d.ts.map +1 -1
  54. package/lib/types/services/self-role-service.d.ts +29 -0
  55. package/lib/types/services/self-role-service.d.ts.map +1 -0
  56. package/lib/types/tools/business/index.d.ts.map +1 -1
  57. package/lib/types/tools/business/records/create.d.ts.map +1 -1
  58. package/lib/types/tools/business/records/self-roles.d.ts +2 -0
  59. package/lib/types/tools/business/records/self-roles.d.ts.map +1 -0
  60. package/lib/types/tools/ports/index.d.ts +2 -1
  61. package/lib/types/tools/ports/index.d.ts.map +1 -1
  62. package/lib/types/types.d.ts +27 -1
  63. package/lib/types/types.d.ts.map +1 -1
  64. package/package.json +5 -5
@@ -1358,6 +1358,24 @@ Arkme 用户|Arkme user
1358
1358
  正在读取录音|Loading recordings
1359
1359
  当前窗口说话人统计|Speaker statistics for this range
1360
1360
  当前窗口说话人图例|Speakers in this range
1361
+ 全天说话人统计|All-day speaker statistics
1362
+ 全天说话人图例|All-day speakers
1363
+ 关闭全天说话人统计|Close all-day speaker statistics
1364
+ 时间轴记录|Timeline entry
1365
+ 时间未标注|Time unavailable
1366
+ 场景类型|Scene
1367
+ 场景说明|Scene note
1368
+ 环境说明|Environment note
1369
+ 评价|Assessment
1370
+ 评价分数|Assessment score
1371
+ 事件标签|Event tags
1372
+ 时段总结|Period summary
1373
+ 参与者|Participants
1374
+ 说话人备注|Speaker note
1375
+ 待办|To-do
1376
+ 代表性原话|Representative quotes
1377
+ 对话摘要|Dialogue summaries
1378
+ 其他信息|Other information
1361
1379
  暂停播放|Pause
1362
1380
  转发录音片段|Forward recording segment
1363
1381
  转发对象|Forwarding destination
@@ -2502,6 +2520,46 @@ AI 额度充值流程|AI point purchase
2502
2520
  if (normalized === "") throw new TypeError("Arkme call reference must not be empty");
2503
2521
  return await this.call("calls.history.summary.retry", { callRef: normalized }, signal);
2504
2522
  }
2523
+ async requireSelfRoles(signal) {
2524
+ if ((await this.capabilities(signal)).features.selfRoles !== true) throw new Error("当前 Arkme Provider 不支持跨端角色,请升级");
2525
+ }
2526
+ async listSelfRoles(expectedUserId, signal) {
2527
+ await this.requireSelfRoles(signal);
2528
+ return await this.call("self-roles.list", { expectedUserId }, signal);
2529
+ }
2530
+ async createSelfRole(expectedUserId, name, avatarRef, signal) {
2531
+ await this.requireSelfRoles(signal);
2532
+ return await this.call("self-roles.create", {
2533
+ expectedUserId,
2534
+ name,
2535
+ ...avatarRef === void 0 ? {} : { avatarRef }
2536
+ }, signal);
2537
+ }
2538
+ async updateSelfRole(expectedUserId, roleId, name, avatarRef, signal) {
2539
+ await this.requireSelfRoles(signal);
2540
+ return await this.call("self-roles.update", {
2541
+ expectedUserId,
2542
+ roleId,
2543
+ name,
2544
+ ...avatarRef === void 0 ? {} : { avatarRef }
2545
+ }, signal);
2546
+ }
2547
+ async deleteSelfRole(expectedUserId, roleId, signal) {
2548
+ await this.requireSelfRoles(signal);
2549
+ return await this.call("self-roles.delete", {
2550
+ expectedUserId,
2551
+ roleId
2552
+ }, signal);
2553
+ }
2554
+ async bindSelfRole(expectedUserId, sourceRef, recordUid, roleId, signal) {
2555
+ await this.requireSelfRoles(signal);
2556
+ return await this.call("self-roles.bind", {
2557
+ expectedUserId,
2558
+ sourceRef,
2559
+ recordUid,
2560
+ roleId
2561
+ }, signal);
2562
+ }
2505
2563
  async profile(options = {}) {
2506
2564
  return await this.call(options.refresh === true ? "user.profile.refresh" : "user.profile", void 0, options.signal);
2507
2565
  }
@@ -537,6 +537,46 @@ window.__ModuleLoader__.load({
537
537
  if (normalized === "") throw new TypeError("Arkme call reference must not be empty");
538
538
  return await this.call("calls.history.summary.retry", { callRef: normalized }, signal);
539
539
  }
540
+ async requireSelfRoles(signal) {
541
+ if ((await this.capabilities(signal)).features.selfRoles !== true) throw new Error("当前 Arkme Provider 不支持跨端角色,请升级");
542
+ }
543
+ async listSelfRoles(expectedUserId, signal) {
544
+ await this.requireSelfRoles(signal);
545
+ return await this.call("self-roles.list", { expectedUserId }, signal);
546
+ }
547
+ async createSelfRole(expectedUserId, name, avatarRef, signal) {
548
+ await this.requireSelfRoles(signal);
549
+ return await this.call("self-roles.create", {
550
+ expectedUserId,
551
+ name,
552
+ ...avatarRef === void 0 ? {} : { avatarRef }
553
+ }, signal);
554
+ }
555
+ async updateSelfRole(expectedUserId, roleId, name, avatarRef, signal) {
556
+ await this.requireSelfRoles(signal);
557
+ return await this.call("self-roles.update", {
558
+ expectedUserId,
559
+ roleId,
560
+ name,
561
+ ...avatarRef === void 0 ? {} : { avatarRef }
562
+ }, signal);
563
+ }
564
+ async deleteSelfRole(expectedUserId, roleId, signal) {
565
+ await this.requireSelfRoles(signal);
566
+ return await this.call("self-roles.delete", {
567
+ expectedUserId,
568
+ roleId
569
+ }, signal);
570
+ }
571
+ async bindSelfRole(expectedUserId, sourceRef, recordUid, roleId, signal) {
572
+ await this.requireSelfRoles(signal);
573
+ return await this.call("self-roles.bind", {
574
+ expectedUserId,
575
+ sourceRef,
576
+ recordUid,
577
+ roleId
578
+ }, signal);
579
+ }
540
580
  async profile(options = {}) {
541
581
  return await this.call(options.refresh === true ? "user.profile.refresh" : "user.profile", void 0, options.signal);
542
582
  }
@@ -3788,6 +3828,24 @@ Arkme 用户|Arkme user
3788
3828
  正在读取录音|Loading recordings
3789
3829
  当前窗口说话人统计|Speaker statistics for this range
3790
3830
  当前窗口说话人图例|Speakers in this range
3831
+ 全天说话人统计|All-day speaker statistics
3832
+ 全天说话人图例|All-day speakers
3833
+ 关闭全天说话人统计|Close all-day speaker statistics
3834
+ 时间轴记录|Timeline entry
3835
+ 时间未标注|Time unavailable
3836
+ 场景类型|Scene
3837
+ 场景说明|Scene note
3838
+ 环境说明|Environment note
3839
+ 评价|Assessment
3840
+ 评价分数|Assessment score
3841
+ 事件标签|Event tags
3842
+ 时段总结|Period summary
3843
+ 参与者|Participants
3844
+ 说话人备注|Speaker note
3845
+ 待办|To-do
3846
+ 代表性原话|Representative quotes
3847
+ 对话摘要|Dialogue summaries
3848
+ 其他信息|Other information
3791
3849
  暂停播放|Pause
3792
3850
  转发录音片段|Forward recording segment
3793
3851
  转发对象|Forwarding destination
@@ -479,6 +479,46 @@ window.__ModuleLoader__.load({
479
479
  if (normalized === "") throw new TypeError("Arkme call reference must not be empty");
480
480
  return await this.call("calls.history.summary.retry", { callRef: normalized }, signal);
481
481
  }
482
+ async requireSelfRoles(signal) {
483
+ if ((await this.capabilities(signal)).features.selfRoles !== true) throw new Error("当前 Arkme Provider 不支持跨端角色,请升级");
484
+ }
485
+ async listSelfRoles(expectedUserId, signal) {
486
+ await this.requireSelfRoles(signal);
487
+ return await this.call("self-roles.list", { expectedUserId }, signal);
488
+ }
489
+ async createSelfRole(expectedUserId, name, avatarRef, signal) {
490
+ await this.requireSelfRoles(signal);
491
+ return await this.call("self-roles.create", {
492
+ expectedUserId,
493
+ name,
494
+ ...avatarRef === void 0 ? {} : { avatarRef }
495
+ }, signal);
496
+ }
497
+ async updateSelfRole(expectedUserId, roleId, name, avatarRef, signal) {
498
+ await this.requireSelfRoles(signal);
499
+ return await this.call("self-roles.update", {
500
+ expectedUserId,
501
+ roleId,
502
+ name,
503
+ ...avatarRef === void 0 ? {} : { avatarRef }
504
+ }, signal);
505
+ }
506
+ async deleteSelfRole(expectedUserId, roleId, signal) {
507
+ await this.requireSelfRoles(signal);
508
+ return await this.call("self-roles.delete", {
509
+ expectedUserId,
510
+ roleId
511
+ }, signal);
512
+ }
513
+ async bindSelfRole(expectedUserId, sourceRef, recordUid, roleId, signal) {
514
+ await this.requireSelfRoles(signal);
515
+ return await this.call("self-roles.bind", {
516
+ expectedUserId,
517
+ sourceRef,
518
+ recordUid,
519
+ roleId
520
+ }, signal);
521
+ }
482
522
  async profile(options = {}) {
483
523
  return await this.call(options.refresh === true ? "user.profile.refresh" : "user.profile", void 0, options.signal);
484
524
  }
package/lib/index.js CHANGED
@@ -1,4 +1,4 @@
1
- import { A as inspectNativeBundleArtifactV3, At as ArkmeRecordReeditDraftConflict, Bt as __require, Ct as isRecentEmojiId, D as bundleSha256, Dt as ArkmePluginError, E as arkmeSandboxEntryId, F as assertExtensionArtifactSize, Ft as registerDSHAgentInputRecordSync, G as validateVoiceprintPcm16Wav, I as canonicalExtensionJson, It as createDesktopLifecycleReader, J as arkmeRequiredLinkMetadataFallback, K as arkmeExtensionShareRefFromLink, L as sha256Hex, Lt as __commonJSMin, M as packLocalNativeBundleDirectoryV3, Mt as parseArkmeRecordReeditMentions, N as readNativeBundleTarballV3, O as canonicalBundleJson, Ot as retryAfterMillis, P as renderArkmeSandboxHostEntry, Pt as parseArrangementBoardCachePages, Q as ARKME_PROVIDER_CONTRACT_VERSION, R as unpackArkmeExtension, Rt as __esmMin, S as ARKME_BUNDLE_ARTIFACT_KIND, St as recordingImportFileNameKey, T as ArkmeBundleArtifactError, Tt as registerManagedAiProvider, U as ARKME_EXTENSION_RUNTIME_UNAVAILABLE_MESSAGE, Vt as __toCommonJS, W as ArkmeService, X as arkmeRichBackgroundSound, Y as arkmeFileBackgroundSound, Z as ARKME_DEFAULT_SHARE_WEBSITE, _ as arkmeClientContentDigest, _t as isRecordingInstantOnOrAfterUnixEpoch, at as cachedMemberItem, b as verifyExtensionResolutionSignature, bt as sameRecordingImportIdentity, c as persistentExtensionBundleDirectory, ct as ARKME_RUNTIME_INSTANCE_ID, d as readPersistentExtensionActivation, dt as arkmeNormalizedFileMimeType, f as refreshPersistentClientWrapper, ft as arkmePickedFileKind, g as activeProfileExtensionOwnerConflicts, gt as ArkmeDirectMessageAdmissionError, h as renderArkmeBundleClientBundle, ht as SecretValue, i as invokePersistentArkmeExtension, it as applyMemberUpdate, j as packBundleFiles, jt as parseArkmeRecordReeditAttachments, k as inspectBundleArtifact, kt as recordOwnerId, l as persistentExtensionPackageIdentity, lt as ARKME_TOOL_FILE_MAX_BYTES, m as writePersistentExtensionActivation, mt as ArkmeOutgoingCallError, nt as ARKME_WORLD_PUBLISH_MAX_IMAGES, o as persistentArkmeExtensionRuntimeState, ot as mergeMemberJoinEvents, p as repairPersistentExtensionInstallation, pt as isArkmeBotAvatarRef, q as arkmeIsGenericLinkMetadataTitle, r as deactivatePersistentArkmeExtension, rt as ARKME_WORLD_PUBLISH_MAX_IMAGE_BYTES, s as materializePersistentExtensionBundle, st as validateMemberUpdate, t as activatePersistentArkmeExtension, u as quarantinePersistentExtension, ut as arkmeCanInlineLocalFile, v as arkmeClientContentDigestFromSource, vt as isUnresolvedRecordingImportJob, w as ARKME_NATIVE_BUNDLE_ARTIFACT_KIND, wt as normalizeRecentEmojiIds, x as verifyNativeBundleResolutionSignature, y as verifyBundleResolutionSignature, yt as recordingImportFileKind, z as ARKME_EXTENSION_FORMAT, zt as __exportAll } from "./persistent-runtime-CuKplHIv.js";
1
+ import { A as inspectNativeBundleArtifactV3, At as recordOwnerId, Bt as __exportAll, Ct as recordingImportFileNameKey, D as bundleSha256, E as arkmeSandboxEntryId, Et as registerManagedAiProvider, F as assertExtensionArtifactSize, Ft as parseArrangementBoardCachePages, G as validateVoiceprintPcm16Wav, Ht as __toCommonJS, I as canonicalExtensionJson, It as registerDSHAgentInputRecordSync, J as arkmeRequiredLinkMetadataFallback, K as arkmeExtensionShareRefFromLink, L as sha256Hex, Lt as createDesktopLifecycleReader, M as packLocalNativeBundleDirectoryV3, Mt as parseArkmeRecordReeditAttachments, N as readNativeBundleTarballV3, Nt as parseArkmeRecordReeditMentions, O as canonicalBundleJson, Ot as ArkmePluginError, P as renderArkmeSandboxHostEntry, Q as ARKME_PROVIDER_CONTRACT_VERSION, R as unpackArkmeExtension, Rt as __commonJSMin, S as ARKME_BUNDLE_ARTIFACT_KIND, T as ArkmeBundleArtifactError, Tt as normalizeRecentEmojiIds, U as ARKME_EXTENSION_RUNTIME_UNAVAILABLE_MESSAGE, Vt as __require, W as ArkmeService, X as arkmeRichBackgroundSound, Y as arkmeFileBackgroundSound, Z as ARKME_DEFAULT_SHARE_WEBSITE, _ as arkmeClientContentDigest, _t as ArkmeDirectMessageAdmissionError, at as cachedMemberItem, b as verifyExtensionResolutionSignature, bt as recordingImportFileKind, c as persistentExtensionBundleDirectory, ct as SelfRoleSyncStore, d as readPersistentExtensionActivation, dt as arkmeCanInlineLocalFile, f as refreshPersistentClientWrapper, ft as arkmeNormalizedFileMimeType, g as activeProfileExtensionOwnerConflicts, gt as SecretValue, h as renderArkmeBundleClientBundle, ht as ArkmeOutgoingCallError, i as invokePersistentArkmeExtension, it as applyMemberUpdate, j as packBundleFiles, jt as ArkmeRecordReeditDraftConflict, k as inspectBundleArtifact, kt as retryAfterMillis, l as persistentExtensionPackageIdentity, lt as ARKME_RUNTIME_INSTANCE_ID, m as writePersistentExtensionActivation, mt as isArkmeBotAvatarRef, nt as ARKME_WORLD_PUBLISH_MAX_IMAGES, o as persistentArkmeExtensionRuntimeState, ot as mergeMemberJoinEvents, p as repairPersistentExtensionInstallation, pt as arkmePickedFileKind, q as arkmeIsGenericLinkMetadataTitle, r as deactivatePersistentArkmeExtension, rt as ARKME_WORLD_PUBLISH_MAX_IMAGE_BYTES, s as materializePersistentExtensionBundle, st as validateMemberUpdate, t as activatePersistentArkmeExtension, u as quarantinePersistentExtension, ut as ARKME_TOOL_FILE_MAX_BYTES, v as arkmeClientContentDigestFromSource, vt as isRecordingInstantOnOrAfterUnixEpoch, w as ARKME_NATIVE_BUNDLE_ARTIFACT_KIND, wt as isRecentEmojiId, x as verifyNativeBundleResolutionSignature, xt as sameRecordingImportIdentity, y as verifyBundleResolutionSignature, yt as isUnresolvedRecordingImportJob, z as ARKME_EXTENSION_FORMAT, zt as __esmMin } from "./persistent-runtime-adGFmkIa.js";
2
2
  import { i as securePrivateFileSync, n as securePrivateDirectorySync, r as securePrivateFile, t as securePrivateDirectory } from "./private-filesystem-CGh4FtyA.js";
3
3
  import { _ as parsePluginUpdateManifest, b as validatePluginUpdateServiceOrigin, d as writePluginUpdateLifecycleLog, f as PluginUpdateInstallStateStore, g as existingCachedPluginArtifactPath, h as downloadAndCachePluginArtifact, m as PluginUpdateArtifactError, n as buildTargetInstallArgs, o as reconcilePluginUpdaterProfilePolicy, p as ARKME_PLUGIN_PACKAGE_NAME$1, t as assertTargetArtifactIntegrity, u as detachManagedProfilePluginLink, v as pluginUpdateEndpointUrl, y as validatePluginUpdateArtifactOrigin } from "./plugin-updater-helper-dNxHpiVg.js";
4
4
  import { i as prepareProfilePackageManager, n as isArkmeProfilePackageName, r as localExtensionPnpmArgs, t as applyArkmeProfileBundlePolicy } from "./profile-bundle-policy-8_y3QfHe.js";
@@ -86,7 +86,7 @@ function nativeRecord(value) {
86
86
  if (!value || typeof value !== "object" || Array.isArray(value)) throw new DshRemoteError("REMOTE_REQUEST_INVALID", "原生传输数据无效");
87
87
  return value;
88
88
  }
89
- function list$2(value) {
89
+ function list$3(value) {
90
90
  if (!Array.isArray(value)) throw new DshRemoteError("REMOTE_INVALID_RESPONSE", "原生列表数据无效");
91
91
  return value;
92
92
  }
@@ -158,7 +158,7 @@ var DshNativeTransport = class {
158
158
  const frame = nativeRecord(value);
159
159
  const ids = async (values) => await scope.owned(values.filter((v) => typeof v === "string"));
160
160
  if (endpoint === "session/list") {
161
- const items = list$2(frame.items), owned = await ids(items.map((item) => nativeRecord(item).sessionId));
161
+ const items = list$3(frame.items), owned = await ids(items.map((item) => nativeRecord(item).sessionId));
162
162
  return {
163
163
  ...frame,
164
164
  items: items.filter((item) => owned.has(String(nativeRecord(item).sessionId)))
@@ -175,20 +175,20 @@ var DshNativeTransport = class {
175
175
  }
176
176
  if (endpoint === "workspace/follow" || endpoint === "workspace/archiveSession") {
177
177
  const source = frame.type === "baseline" ? nativeRecord(frame.value) : frame;
178
- const items = source.items === void 0 ? [] : list$2(source.items);
179
- const owned = await ids([...(source.workspace === void 0 ? items : [source.workspace]).flatMap((item) => list$2(nativeRecord(item).sessionIds)), ...list$2(source.archivedSessionIds ?? [])]);
178
+ const items = source.items === void 0 ? [] : list$3(source.items);
179
+ const owned = await ids([...(source.workspace === void 0 ? items : [source.workspace]).flatMap((item) => list$3(nativeRecord(item).sessionIds)), ...list$3(source.archivedSessionIds ?? [])]);
180
180
  const project = (raw) => {
181
181
  const item = nativeRecord(raw);
182
182
  return {
183
183
  ...item,
184
- sessionIds: list$2(item.sessionIds).filter((id) => owned.has(String(id)))
184
+ sessionIds: list$3(item.sessionIds).filter((id) => owned.has(String(id)))
185
185
  };
186
186
  };
187
187
  const projected = {
188
188
  ...source,
189
189
  ...source.items === void 0 ? {} : { items: items.map(project).filter((item) => item.sessionIds.length > 0) },
190
190
  ...source.workspace === void 0 ? {} : { workspace: project(source.workspace) },
191
- ...source.archivedSessionIds === void 0 ? {} : { archivedSessionIds: list$2(source.archivedSessionIds).filter((id) => owned.has(String(id))) }
191
+ ...source.archivedSessionIds === void 0 ? {} : { archivedSessionIds: list$3(source.archivedSessionIds).filter((id) => owned.has(String(id))) }
192
192
  };
193
193
  if (source.workspace !== void 0 && nativeRecord(projected.workspace).sessionIds instanceof Array && nativeRecord(projected.workspace).sessionIds.length === 0) return void 0;
194
194
  return frame.type === "baseline" ? {
@@ -220,10 +220,10 @@ var DshNativeTransport = class {
220
220
  if (frame.type === "emit" && typeof frame.event === "string") {
221
221
  if (frame.event === "llm/adapters-updated") return frame;
222
222
  if (frame.event.startsWith("api-session/")) {
223
- const first = list$2(frame.args)[0], id = frame.event === "api-session/added" ? nativeRecord(first).sessionId : first;
223
+ const first = list$3(frame.args)[0], id = frame.event === "api-session/added" ? nativeRecord(first).sessionId : first;
224
224
  return (await ids([id])).has(String(id)) ? frame : void 0;
225
225
  }
226
- if (["agent-preset/selected", "goal/activation-changed"].includes(frame.event)) return (await ids([list$2(frame.args)[0]])).has(String(list$2(frame.args)[0])) ? frame : void 0;
226
+ if (["agent-preset/selected", "goal/activation-changed"].includes(frame.event)) return (await ids([list$3(frame.args)[0]])).has(String(list$3(frame.args)[0])) ? frame : void 0;
227
227
  }
228
228
  return;
229
229
  }
@@ -1457,7 +1457,7 @@ const MAX_OPEN_CALLS_PER_SESSION = 512;
1457
1457
  function record$4(value) {
1458
1458
  return value !== null && typeof value === "object" && !Array.isArray(value) ? value : {};
1459
1459
  }
1460
- function list$1(value) {
1460
+ function list$2(value) {
1461
1461
  return Array.isArray(value) ? value : [];
1462
1462
  }
1463
1463
  function firstLine(value) {
@@ -1480,7 +1480,7 @@ function parseArguments(value) {
1480
1480
  function contentText(value) {
1481
1481
  const parts = [];
1482
1482
  const collect = (candidate) => {
1483
- for (const raw of list$1(candidate)) {
1483
+ for (const raw of list$2(candidate)) {
1484
1484
  const block = record$4(raw);
1485
1485
  if (block.type === "text" && typeof block.text === "string" && block.text.trim() !== "") parts.push(block.text.trimEnd());
1486
1486
  else if (block.type === "tool-result") collect(block.content);
@@ -1560,13 +1560,13 @@ function toolPresentation(data) {
1560
1560
  let summary = "";
1561
1561
  if (failed && errorSummary !== "") summary = errorSummary;
1562
1562
  else if (normalizedName === "ask_user_question") {
1563
- const count = list$1(args.questions).length;
1563
+ const count = list$2(args.questions).length;
1564
1564
  summary = count === 0 ? "" : data.status === "completed" ? `${count}/${count} 已回答` : `${count} 个问题`;
1565
1565
  } else if (typeof resultView.summary === "string") summary = firstLine(resultView.summary);
1566
1566
  else if (typeof resultView.title === "string") summary = firstLine(resultView.title);
1567
1567
  else if (card === "terminal") summary = firstLine(callView.description) || firstLine(callView.title);
1568
1568
  else if (typeof callView.title === "string") summary = firstLine(callView.title);
1569
- else if (normalizedName === "web_search") summary = list$1(args.queries).filter((value) => typeof value === "string").join(", ");
1569
+ else if (normalizedName === "web_search") summary = list$2(args.queries).filter((value) => typeof value === "string").join(", ");
1570
1570
  else summary = safeArgumentSummary(normalizedName, args);
1571
1571
  if (title === "Tool call" && name !== "" && !summary.startsWith(name)) summary = summary === "" ? name : `${name} · ${summary}`;
1572
1572
  if (failed && errorSummary !== "") summary = errorSummary;
@@ -1598,7 +1598,7 @@ function presentationForTimelineNode(kind, data) {
1598
1598
  case "context": return contextPresentation(data);
1599
1599
  case "tool": return toolPresentation(data);
1600
1600
  case "command": {
1601
- const name = firstLine(record$4(record$4(list$1(data.events).at(-1)).data).name);
1601
+ const name = firstLine(record$4(record$4(list$2(data.events).at(-1)).data).name);
1602
1602
  return {
1603
1603
  version: 1,
1604
1604
  format: "summary",
@@ -1760,7 +1760,7 @@ const MAX_TURN_PROJECTION_BYTES = 4 * 1024 * 1024;
1760
1760
  function record$3(value) {
1761
1761
  return value !== null && typeof value === "object" && !Array.isArray(value) ? value : {};
1762
1762
  }
1763
- function list(value) {
1763
+ function list$1(value) {
1764
1764
  return Array.isArray(value) ? value : [];
1765
1765
  }
1766
1766
  function nonEmptyId(value) {
@@ -1830,7 +1830,7 @@ function foldLifecycle(nodes, entry, ref, kind) {
1830
1830
  time: previous?.time ?? entry.event.time,
1831
1831
  data: {
1832
1832
  ...previous?.data,
1833
- events: [...list(previous?.data.events), entry.event]
1833
+ events: [...list$1(previous?.data.events), entry.event]
1834
1834
  },
1835
1835
  sourceSeqs: [...previous?.sourceSeqs ?? [], entry.event.seq]
1836
1836
  });
@@ -1912,7 +1912,7 @@ function projectDshHistoryNodes(entries) {
1912
1912
  if (!isAppendSurface(entry)) break;
1913
1913
  const key = stepKey(data, event.seq);
1914
1914
  const message = record$3(data.message);
1915
- const content = list(message.content ?? data.content).map(record$3);
1915
+ const content = list$1(message.content ?? data.content).map(record$3);
1916
1916
  assistantBlocks.set(key, content);
1917
1917
  const ref = `assistant:${key}`;
1918
1918
  const previous = nodes.get(ref);
@@ -1985,7 +1985,7 @@ function projectDshHistoryNodes(entries) {
1985
1985
  ...previous,
1986
1986
  data: {
1987
1987
  ...previous.data,
1988
- dispatches: [...list(previous.data.dispatches), data]
1988
+ dispatches: [...list$1(previous.data.dispatches), data]
1989
1989
  },
1990
1990
  sourceSeqs: [...previous.sourceSeqs, event.seq]
1991
1991
  });
@@ -14779,7 +14779,7 @@ async function dispatchArkmeHostOperation(service, operation, params, updateMana
14779
14779
  case "arko.cancel": return await service.arkoCancel(numberParam(params, "sessionId", 0), numberParam(params, "assistantMsgId", 0), stringParam(params, "runUid"));
14780
14780
  case "self-roles.list": return await service.listSelfRoles(numberParam(params, "expectedUserId", 0));
14781
14781
  case "self-roles.create": return await service.createSelfRole(numberParam(params, "expectedUserId", 0), stringParam(params, "name"), params.avatarRef === void 0 ? void 0 : stringParam(params, "avatarRef"));
14782
- case "self-roles.update": return await service.updateSelfRole(numberParam(params, "expectedUserId", 0), stringParam(params, "roleId"), stringParam(params, "name"), params.avatarRef === void 0 ? void 0 : stringParam(params, "avatarRef"));
14782
+ case "self-roles.update": return await service.updateSelfRole(numberParam(params, "expectedUserId", 0), stringParam(params, "roleId"), params.name === void 0 ? void 0 : stringParam(params, "name"), params.avatarRef === void 0 ? void 0 : stringParam(params, "avatarRef"));
14783
14783
  case "self-roles.delete": return await service.deleteSelfRole(numberParam(params, "expectedUserId", 0), stringParam(params, "roleId"));
14784
14784
  case "self-roles.bind": return await service.bindSelfRole(numberParam(params, "expectedUserId", 0), stringParam(params, "sourceRef"), stringParam(params, "recordUid"), stringParam(params, "roleId"));
14785
14785
  case "self-roles.unbind": return await service.unbindSelfRole(numberParam(params, "expectedUserId", 0), stringParam(params, "recordUid"), stringParam(params, "roleId"));
@@ -19605,6 +19605,7 @@ function selfRoleSnapshotFromRow(row) {
19605
19605
  }
19606
19606
  var ArkmeLocalDatabase = class {
19607
19607
  operationalState;
19608
+ selfRoleSync;
19608
19609
  commonGroups;
19609
19610
  path;
19610
19611
  database;
@@ -19742,6 +19743,7 @@ var ArkmeLocalDatabase = class {
19742
19743
  }
19743
19744
  });
19744
19745
  this.commonGroups = new CommonGroupDatabase(this.database, (work) => this.transaction(work));
19746
+ this.selfRoleSync = new SelfRoleSyncStore(this.database, (action) => this.transaction(action));
19745
19747
  const recordColumns = this.database.prepare("PRAGMA table_info(record_cache)").all();
19746
19748
  if (!recordColumns.some((column) => column.name === "sender_avatar_ref")) this.database.exec("ALTER TABLE record_cache ADD COLUMN sender_avatar_ref TEXT");
19747
19749
  if (!recordColumns.some((column) => column.name === "sender_name")) this.database.exec("ALTER TABLE record_cache ADD COLUMN sender_name TEXT");
@@ -19785,35 +19787,9 @@ var ArkmeLocalDatabase = class {
19785
19787
  async listSelfRoles(userId) {
19786
19788
  return this.database.prepare(`
19787
19789
  SELECT role_id, name, avatar_ref, created_at_millis, updated_at_millis
19788
- FROM self_role WHERE user_id = ? ORDER BY created_at_millis, role_id
19790
+ FROM self_role WHERE user_id = ? AND deleted=0 ORDER BY created_at_millis, role_id
19789
19791
  `).all(userId).map(selfRoleFromRow);
19790
19792
  }
19791
- /** Historical uploaded avatars occur both on live roles and frozen message presentation. */
19792
- async legacySelfRoleAvatarRefs(userId) {
19793
- return this.database.prepare(`
19794
- SELECT avatar_ref FROM self_role WHERE user_id = ? AND avatar_ref LIKE 'file_asset://%'
19795
- UNION
19796
- SELECT avatar_ref FROM self_role_record WHERE user_id = ? AND avatar_ref LIKE 'file_asset://%'
19797
- `).all(userId, userId).map((row) => row.avatar_ref).filter((ref) => /^file_asset:\/\/[A-Za-z0-9_-]{8,128}$/.test(ref));
19798
- }
19799
- /** Replace only byte-equivalent avatar refs; names and historical role identities stay frozen. */
19800
- async replaceSelfRoleAvatarRef(userId, oldRef, newRef) {
19801
- if (!/^file_asset:\/\/[A-Za-z0-9_-]{8,128}$/.test(oldRef) || !/^arkme-self-role-image-v1\.[0-9a-f-]{36}$/i.test(newRef)) return 0;
19802
- let changed = 0;
19803
- this.transaction(() => {
19804
- const now = Date.now();
19805
- const roles = this.database.prepare(`
19806
- UPDATE self_role
19807
- SET avatar_ref = ?, updated_at_millis = CASE WHEN updated_at_millis >= ? THEN updated_at_millis + 1 ELSE ? END
19808
- WHERE user_id = ? AND avatar_ref = ?
19809
- `).run(newRef, now, now, userId, oldRef);
19810
- const records = this.database.prepare(`
19811
- UPDATE self_role_record SET avatar_ref = ? WHERE user_id = ? AND avatar_ref = ?
19812
- `).run(newRef, userId, oldRef);
19813
- changed = Number(roles.changes) + Number(records.changes);
19814
- });
19815
- return changed;
19816
- }
19817
19793
  async createSelfRole(userId, name, avatarRef) {
19818
19794
  const role = {
19819
19795
  roleId: randomUUID(),
@@ -19823,36 +19799,37 @@ var ArkmeLocalDatabase = class {
19823
19799
  updatedAtMillis: Date.now()
19824
19800
  };
19825
19801
  this.transaction(() => {
19826
- if (this.database.prepare("SELECT count(*) AS count FROM self_role WHERE user_id = ?").get(userId).count >= 20) throw new Error("self-role-limit");
19802
+ if (this.database.prepare("SELECT count(*) AS count FROM self_role WHERE user_id = ? AND deleted=0").get(userId).count >= 20) throw new Error("self-role-limit");
19827
19803
  this.database.prepare(`
19828
- INSERT INTO self_role (user_id, role_id, name, avatar_ref, created_at_millis, updated_at_millis)
19829
- VALUES (?, ?, ?, ?, ?, ?)
19830
- `).run(userId, role.roleId, name, avatarRef ?? null, role.createdAtMillis, role.updatedAtMillis);
19804
+ INSERT INTO self_role (user_id, role_id, name, avatar_ref, created_at_millis, updated_at_millis, name_at, avatar_at)
19805
+ VALUES (?, ?, ?, ?, ?, ?, ?, ?)
19806
+ `).run(userId, role.roleId, name, avatarRef ?? null, role.createdAtMillis, role.updatedAtMillis, role.updatedAtMillis, role.updatedAtMillis);
19831
19807
  });
19832
19808
  return role;
19833
19809
  }
19834
19810
  async updateSelfRole(userId, roleId, name, avatarRef) {
19835
19811
  const row = this.database.prepare(`
19836
19812
  SELECT role_id, name, avatar_ref, created_at_millis, updated_at_millis
19837
- FROM self_role WHERE user_id = ? AND role_id = ?
19813
+ FROM self_role WHERE user_id = ? AND role_id = ? AND deleted=0
19838
19814
  `).get(userId, roleId);
19839
19815
  if (row === void 0) return void 0;
19816
+ const nextName = name ?? row.name;
19840
19817
  const nextAvatarRef = avatarRef === void 0 ? row.avatar_ref : avatarRef || null;
19841
19818
  const updatedAtMillis = Math.max(Date.now(), row.updated_at_millis + 1);
19842
19819
  this.database.prepare(`
19843
- UPDATE self_role SET name = ?, avatar_ref = ?, updated_at_millis = ?
19820
+ UPDATE self_role SET name_at=CASE WHEN name != ? THEN ? ELSE name_at END, avatar_at=CASE WHEN COALESCE(avatar_ref,'') != ? THEN ? ELSE avatar_at END, name = ?, avatar_ref = ?, updated_at_millis = ?
19844
19821
  WHERE user_id = ? AND role_id = ?
19845
- `).run(name, nextAvatarRef, updatedAtMillis, userId, roleId);
19822
+ `).run(nextName, updatedAtMillis, nextAvatarRef ?? "", updatedAtMillis, nextName, nextAvatarRef, updatedAtMillis, userId, roleId);
19846
19823
  this.secureDatabaseFiles();
19847
19824
  return selfRoleFromRow({
19848
19825
  ...row,
19849
- name,
19826
+ name: nextName,
19850
19827
  avatar_ref: nextAvatarRef,
19851
19828
  updated_at_millis: updatedAtMillis
19852
19829
  });
19853
19830
  }
19854
19831
  async deleteSelfRole(userId, roleId) {
19855
- const result = this.database.prepare("DELETE FROM self_role WHERE user_id = ? AND role_id = ?").run(userId, roleId);
19832
+ const result = this.database.prepare("UPDATE self_role SET deleted=1, deleted_at=MAX(?,updated_at_millis+1),updated_at_millis=MAX(?,updated_at_millis+1) WHERE user_id = ? AND role_id = ? AND deleted=0").run(Date.now(), Date.now(), userId, roleId);
19856
19833
  this.secureDatabaseFiles();
19857
19834
  return Number(result.changes) > 0;
19858
19835
  }
@@ -19861,7 +19838,7 @@ var ArkmeLocalDatabase = class {
19861
19838
  this.transaction(() => {
19862
19839
  const role = this.database.prepare(`
19863
19840
  SELECT role_id, name, avatar_ref, created_at_millis, updated_at_millis
19864
- FROM self_role WHERE user_id = ? AND role_id = ?
19841
+ FROM self_role WHERE user_id = ? AND role_id = ? AND deleted=0
19865
19842
  `).get(userId, roleId);
19866
19843
  if (role === void 0) return;
19867
19844
  const existing = this.database.prepare(`
@@ -19886,7 +19863,7 @@ var ArkmeLocalDatabase = class {
19886
19863
  return snapshot;
19887
19864
  }
19888
19865
  async unbindSelfRole(userId, recordUid, roleId) {
19889
- this.database.prepare("DELETE FROM self_role_record WHERE user_id = ? AND record_uid = ? AND role_id = ?").run(userId, recordUid, roleId);
19866
+ this.database.prepare("DELETE FROM self_role_record WHERE user_id = ? AND record_uid = ? AND role_id = ? AND cloud_ack=0").run(userId, recordUid, roleId);
19890
19867
  this.secureDatabaseFiles();
19891
19868
  }
19892
19869
  async rebindSelfRole(userId, recordUid, newRecordUid) {
@@ -19894,7 +19871,7 @@ var ArkmeLocalDatabase = class {
19894
19871
  let rebound = false;
19895
19872
  this.transaction(() => {
19896
19873
  const source = this.database.prepare(`
19897
- SELECT role_id, role_name, avatar_ref FROM self_role_record WHERE user_id = ? AND record_uid = ?
19874
+ SELECT role_id, role_name, avatar_ref, cloud_ack FROM self_role_record WHERE user_id = ? AND record_uid = ?
19898
19875
  `).get(userId, recordUid);
19899
19876
  const target = this.database.prepare(`
19900
19877
  SELECT role_id, role_name, avatar_ref FROM self_role_record WHERE user_id = ? AND record_uid = ?
@@ -19903,6 +19880,7 @@ var ArkmeLocalDatabase = class {
19903
19880
  rebound = target !== void 0;
19904
19881
  return;
19905
19882
  }
19883
+ if (source.cloud_ack === 1) throw new Error("self-role-record-conflict");
19906
19884
  if (target !== void 0 && (target.role_id !== source.role_id || target.role_name !== source.role_name || target.avatar_ref !== source.avatar_ref)) throw new Error("self-role-record-conflict");
19907
19885
  if (target === void 0) this.database.prepare(`
19908
19886
  INSERT INTO self_role_record (user_id, record_uid, role_id, role_name, avatar_ref, bound_at_millis)
@@ -19923,8 +19901,8 @@ var ArkmeLocalDatabase = class {
19923
19901
  `).all(userId, ...uniqueUids);
19924
19902
  return new Map(rows.map((row) => [row.record_uid, selfRoleSnapshotFromRow(row)]));
19925
19903
  }
19926
- /** Stable, account-scoped pages for a future idempotent cloud backfill. No local row is marked synced or removed. */
19927
- async selfRoleMigrationBatch(userId, afterRecordUid = "", limit = 200) {
19904
+ /** Stable, account-scoped pages for a account-scoped snapshot inspection. No local row is marked synced or removed. */
19905
+ async selfRoleBindings(userId, afterRecordUid = "", limit = 200) {
19928
19906
  const pageSize = Math.min(200, Math.max(1, Math.trunc(limit) || 200));
19929
19907
  const rows = this.database.prepare(`
19930
19908
  SELECT record_uid, role_id, role_name, avatar_ref, bound_at_millis
@@ -20455,6 +20433,7 @@ var ArkmeLocalDatabase = class {
20455
20433
  }
20456
20434
  upsertSyncedRecord(userId, item) {
20457
20435
  const now = Date.now();
20436
+ if (item.selfRole) this.selfRoleSync.cacheSnapshot(userId, item.recordUid, item.selfRole);
20458
20437
  this.database.prepare(`
20459
20438
  INSERT INTO record_cache (
20460
20439
  user_id, record_uid, send_at_millis, title, text_content, template_kind,
@@ -26992,6 +26971,79 @@ function isArkmeCoreToolModule(module) {
26992
26971
  function isArkmeContextToolModule(module) {
26993
26972
  return module.meta.phase === "attachments" || module.meta.phase === "host";
26994
26973
  }
26974
+ const selfRoleToolModules = [defineArkmeCoreToolModule({
26975
+ meta: {
26976
+ id: "business.records.self-roles-list.v1",
26977
+ toolName: "arkme_self_roles_list",
26978
+ kind: "business",
26979
+ phase: "core",
26980
+ effect: "read",
26981
+ profiles: ["business", "hybrid"]
26982
+ },
26983
+ create: (ports) => defineTool({
26984
+ name: "arkme_self_roles_list",
26985
+ description: "List private display roles for the current account. Roles never change the real author or permissions.",
26986
+ parameters: { expected_user_id: {
26987
+ type: "integer",
26988
+ required: true,
26989
+ description: "Current account user ID from the account profile."
26990
+ } },
26991
+ output: TEXT_OUTPUT$3,
26992
+ isConcurrencySafe: () => true,
26993
+ execute: async (args) => taggedJSON("发言角色", await ports.listSelfRoles(args.expected_user_id))
26994
+ })
26995
+ }), defineArkmeCoreToolModule({
26996
+ meta: {
26997
+ id: "business.records.self-roles-write.v1",
26998
+ toolName: "arkme_self_roles_write",
26999
+ kind: "business",
27000
+ phase: "core",
27001
+ effect: "write",
27002
+ grant: "explicit-user-write",
27003
+ profiles: ["business", "hybrid"]
27004
+ },
27005
+ create: (ports) => defineTool({
27006
+ name: "arkme_self_roles_write",
27007
+ description: "Only on explicit user request, create, update or delete a private display role. Writes persist locally while offline. Avatar references must come from the current account file upload tools; never use URLs. Deletion preserves historical message presentation.",
27008
+ parameters: {
27009
+ expected_user_id: {
27010
+ type: "integer",
27011
+ required: true,
27012
+ description: "Current account user ID."
27013
+ },
27014
+ action: {
27015
+ type: "string",
27016
+ required: true,
27017
+ enum: [
27018
+ "create",
27019
+ "update",
27020
+ "delete"
27021
+ ],
27022
+ description: "Requested operation."
27023
+ },
27024
+ role_id: {
27025
+ type: "string",
27026
+ description: "Existing role ID, required except create."
27027
+ },
27028
+ name: {
27029
+ type: "string",
27030
+ description: "1–20 character role name; required for create. On update omit unchanged fields."
27031
+ },
27032
+ avatar_ref: {
27033
+ type: "string",
27034
+ description: "Current account file_asset:// reference; empty clears avatar."
27035
+ }
27036
+ },
27037
+ output: TEXT_OUTPUT$3,
27038
+ execute: async (args) => {
27039
+ const uid = args.expected_user_id;
27040
+ if (args.action === "create") return taggedJSON("角色已保存", await ports.createSelfRole(uid, args.name ?? "", args.avatar_ref));
27041
+ if (args.action === "update") return taggedJSON("角色已保存", await ports.updateSelfRole(uid, args.role_id ?? "", args.name, args.avatar_ref));
27042
+ if (args.action === "delete") return taggedJSON("角色已删除", await ports.deleteSelfRole(uid, args.role_id ?? ""));
27043
+ throw new Error("Unsupported role operation");
27044
+ }
27045
+ })
27046
+ })];
26995
27047
  //#endregion
26996
27048
  //#region src/tools/business/conversation/private-interactions.ts
26997
27049
  const privateInteractionSummaryToolModule = defineArkmeCoreToolModule({
@@ -30761,14 +30813,30 @@ const createRecordToolModule = defineArkmeCoreToolModule({
30761
30813
  return defineTool({
30762
30814
  name: "arkme_record_create",
30763
30815
  description: "Save plain text to the signed-in user's Arkme default category. Call only after an explicit human request in the current conversation. The write is cached locally before remote sync.",
30764
- parameters: { text: {
30765
- type: "string",
30766
- required: true,
30767
- description: "Exact plain-text content the user explicitly asked to save to Arkme."
30768
- } },
30816
+ parameters: {
30817
+ role_id: {
30818
+ type: "string",
30819
+ description: "Optional role ID explicitly selected by the user from arkme_self_roles_list."
30820
+ },
30821
+ expected_user_id: {
30822
+ type: "integer",
30823
+ description: "Required with role_id; the currently selected account user ID."
30824
+ },
30825
+ text: {
30826
+ type: "string",
30827
+ required: true,
30828
+ description: "Exact plain-text content the user explicitly asked to save to Arkme."
30829
+ }
30830
+ },
30769
30831
  output: TEXT_OUTPUT$3,
30770
30832
  async execute(args, exec) {
30771
- return formatWriteResult(await ports.createTextForConversation(recordUidForToolCall(String(exec.callId)), args.text));
30833
+ const recordUid = recordUidForToolCall(String(exec.callId));
30834
+ if (args.role_id !== void 0) {
30835
+ if (!args.expected_user_id) throw new Error("选择角色时必须提供当前账号 expected_user_id");
30836
+ const target = await ports.selfTarget();
30837
+ await ports.bindSelfRole(args.expected_user_id, target.sourceRef, recordUid, args.role_id);
30838
+ }
30839
+ return formatWriteResult(await ports.createTextForConversation(recordUid, args.text));
30772
30840
  }
30773
30841
  });
30774
30842
  }
@@ -32465,6 +32533,7 @@ const voiceprintToolModules = [
32465
32533
  //#region src/tools/business/index.ts
32466
32534
  /** Stable model-facing order retained from the pre-catalog registration path. */
32467
32535
  const businessToolModules = [
32536
+ ...selfRoleToolModules,
32468
32537
  directoryReadToolModule,
32469
32538
  recentRecordsToolModule,
32470
32539
  ...accountBusinessToolModules,
@@ -1,2 +1,2 @@
1
- import { a as persistentArkmeExtensionActive, i as invokePersistentArkmeExtension, n as applyPersistentArkmeHostExtension, o as persistentArkmeExtensionRuntimeState, r as deactivatePersistentArkmeExtension, t as activatePersistentArkmeExtension } from "./persistent-runtime-CuKplHIv.js";
1
+ import { a as persistentArkmeExtensionActive, i as invokePersistentArkmeExtension, n as applyPersistentArkmeHostExtension, o as persistentArkmeExtensionRuntimeState, r as deactivatePersistentArkmeExtension, t as activatePersistentArkmeExtension } from "./persistent-runtime-adGFmkIa.js";
2
2
  export { activatePersistentArkmeExtension, applyPersistentArkmeHostExtension, deactivatePersistentArkmeExtension, invokePersistentArkmeExtension, persistentArkmeExtensionActive, persistentArkmeExtensionRuntimeState };