@botharness/core 1.0.2 → 1.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -5,7 +5,42 @@ Notable changes to DeepSeekBot are recorded here. See the
5
5
 
6
6
  ## [Unreleased]
7
7
 
8
- Nothing yet since 1.0.2.
8
+ Nothing yet since 1.1.0.
9
+
10
+ ## [1.1.0] - 2026-10-06
11
+
12
+ PersonaBots can run Bot Schedules and manage them themselves, every Session starts with the Bot's Soul and Core Memory, the Channel sidebar sections share one card design, WeChat accepts voice transcripts and images, each Bot's Memory keeps a `.botharness/bot.json` profile for the Bot Marketplace, the plugin sends anonymous usage statistics that can be turned off, and Bot settings can install a DeepSeekBot update and restart DSH with one click.
13
+
14
+ ### Added
15
+
16
+ - Added a candidate personal WeChat voice source path using platform-provided transcripts and explicit missing-transcript states in the Bot Inbox, without adding ASR or audio playback; a real native voice → model → original-DM reply was confirmed by the Human ([#905](https://github.com/BotHarness/BotHarness/issues/905)).
17
+ - Added a source-preview WeChat image path with automatic image preview inside the original Inbox message bubble, native model image input and own-identity native image replies, with the original-DM image receipt confirmed by the Human ([#904](https://github.com/BotHarness/BotHarness/issues/904), [connection guide](docs/wechat-connection.md)).
18
+ - PersonaBots gain Bot Schedules: the Channel sidebar's Schedules section lets the Human create, edit, pause and delete minute, hourly or daily tasks; each firing lands in the Bot Inbox and wakes the Orchestrator, and every schedule shows its last 20 firings with links to the handling session ([#960](https://github.com/BotHarness/BotHarness/issues/960), [ADR-0133](docs/adr/0133-bot-schedules-wake-the-orchestrator-through-the-bot-inbox.md)).
19
+ - DeepSeekBot now writes `.botharness/bot.json` into each Bot's Memory when the Bot is created, and updates it when its name, roles or avatar change. Existing Bots get the file on the next start. A shared Bot therefore shows the same name, roles and avatar in the Bot Marketplace as in the sidebar ([#966](https://github.com/BotHarness/BotHarness/issues/966), [guide](docs/share-bot.md)).
20
+ - DeepSeekBot sends anonymous usage statistics from the DSH Host, tied only to a random install ID: `plugin_started` (plugin and DSH version, OS, architecture), `bot_created`, `bot_archived`, `bot_deleted`, `marketplace_bot_installed`, `connector_enabled` (connector type only), `avatar_edited`, one `daily_usage` summary (counts of PersonaBots, Sessions and messages, and the window in hours), and unhandled BotHarness errors in the Host as `$exception` reports with the error type and a stack reduced to package-relative file names, never the message or a file path; Bot mode explains this once in a notice linking the privacy page and source. Turn it off with the **Anonymous usage statistics** switch in Bot settings, which applies at once without a restart and is remembered; `telemetry: false` in the core plugin config, `DO_NOT_TRACK=1` or `BOTHARNESS_TELEMETRY=0` force it off and lock the switch ([#951](https://github.com/BotHarness/BotHarness/issues/951), [#952](https://github.com/BotHarness/BotHarness/issues/952), [ADR-0132](docs/adr/0132-anonymous-posthog-telemetry-and-campaign-short-links.md), [guide](docs/settings.md)).
21
+ - PersonaBots can manage their own Bot Schedules: ask a Bot to do something every hour or every day and it creates the schedule itself, marked as Bot-created in the sidebar; it can also change or delete any schedule the Human has not locked. The Human locks a schedule from its row or editor, at most 20 schedules can be enabled per Bot, the sidebar updates as soon as the Bot changes a schedule, and DSH's own `schedule_*` tools are refused in the Orchestrator so a Bot keeps one schedule list ([#961](https://github.com/BotHarness/BotHarness/issues/961)).
22
+ - Bot Schedules can now run weekly on chosen days, once at a date and time (turning themselves off afterwards), or on a five-field cron expression, all in the schedule's own time zone; the editor previews the next three runs, the Bot's schedule tools accept the same cadences, and **Run now** on a row wakes the Orchestrator immediately without moving the next planned run. The new [Schedules guide](docs/channel-sidebar/schedules.md) covers each cadence, Run now, pausing and locking ([#962](https://github.com/BotHarness/BotHarness/issues/962)).
23
+ - Bot settings can install a newer DeepSeekBot release with one click through DSH's Plugin Manager. On the web, **Restart now** then restarts `dsh web` in the same terminal and the page reconnects on its own; DSH Desktop shows how to quit and reopen. When the Plugin Manager is unavailable or the install fails, the reason and the manual update command are shown instead. The new [Update DeepSeekBot](docs/update-deepseekbot.md) guide covers each step ([#986](https://github.com/BotHarness/BotHarness/issues/986)).
24
+
25
+ ### Changed
26
+
27
+ - The Channel sidebar's Sessions, Bot Inbox and Workspace Grants sections now use the same card rows as Schedules, with an icon, status chips and a meta line on every row; a Bot Inbox item from a Bot Schedule now opens that schedule ([#972](https://github.com/BotHarness/BotHarness/issues/972)).
28
+ - The Channel sidebar's Computer and Browser sections now use the same card rows: a status card shows the target (local or Docker), a state chip such as Running, Needs setup or Paused, and its controls, and the Browser's open tabs are listed as card rows ([#975](https://github.com/BotHarness/BotHarness/issues/975)).
29
+ - The Bot Profile avatar area is now one Avatar section with two side-by-side choices, Design a pixel avatar and Upload an image, and marks the one in use; the duplicate Change avatar button is gone and the divider under the profile header has whitespace around it ([#985](https://github.com/BotHarness/BotHarness/issues/985)).
30
+ - A PersonaBot's persona file is now `SOUL.md`, its Soul, and every Session also starts with its Core Memory, `MEMORY.md`, so a new conversation already knows what the Bot remembers. Both are frozen for the Session with a character usage header (5,000 and 3,000 by default), new Bots get a short `MEMORY.md` template, and an existing `PERSONA.md` is renamed to `SOUL.md` on the next start ([#988](https://github.com/BotHarness/BotHarness/issues/988), [ADR-0134](docs/adr/0134-soul-and-core-memory-are-session-frozen-system-prompt-files.md)).
31
+ - Each Bot's profile has a Standing memory limits section for the `SOUL.md` and `MEMORY.md` character limits, with their approximate size in Chinese characters and English words, applied from the next Session. The Memory panel pins both files at the top with a Standing badge and their current usage, highlighted when over the limit, and Memory search now covers them ([#989](https://github.com/BotHarness/BotHarness/issues/989), [ADR-0134](docs/adr/0134-soul-and-core-memory-are-session-frozen-system-prompt-files.md)).
32
+
33
+ ### Fixed
34
+
35
+ - Lark user targets with an explicit private chat ID can receive unmentioned private messages into the same PersonaBot Inbox and reply through its bound identity; targets without that locator remain send-only ([#996](https://github.com/BotHarness/BotHarness/issues/996)).
36
+
37
+ ### Documentation
38
+
39
+ - Documented the development-source Discord file candidate with actual model save/process/import/original-thread result, independent unchanged-input/output byte proof and temporary Workspace write cleanup ([#1002](https://github.com/BotHarness/BotHarness/issues/1002), [verification](docs/dev/verification/discord-1002-source-files.md)).
40
+ - New guide [Bot Soul and Core Memory](docs/soul-and-core-memory.md): why `SOUL.md` and `MEMORY.md` start every Session frozen, what each file is for and why there is no `USER.md`, the character limits with their approximate size and token cost in Chinese and English, how to change them, what an over-limit file looks like, when edits take effect, and how to shape `MEMORY.md` together with the Bot ([#990](https://github.com/BotHarness/BotHarness/issues/990), [ADR-0134](docs/adr/0134-soul-and-core-memory-are-session-frozen-system-prompt-files.md)).
41
+ - The GitHub and npm READMEs cover Bot Schedules, the Bot Marketplace and update notes, add a Release highlights section drawn from this ledger, and replace the screenshots with a high-resolution gallery in which every avatar is a BotPixel pixel avatar ([#984](https://github.com/BotHarness/BotHarness/issues/984)).
42
+ - Documented the isolated Discord nearby context candidate: exact native source container, five-minute window, sparse Human-text minima and bounded continuation; real-model sparse pagination, canonical retention, original-thread reply and temporary permission restoration are verified independently of product promotion ([#981](https://github.com/BotHarness/BotHarness/issues/981), [guide](docs/dev/guides/im-provider-integration.md)).
43
+ - Documented final development-source Discord context acceptance with real model continuation, precise edited-source refusal, whole-page rollback and restored Message Content permissions ([#937](https://github.com/BotHarness/BotHarness/issues/937), [verification](docs/dev/verification/discord-937-context-reads.md)).
9
44
 
10
45
  ## [1.0.2] - 2026-10-06
11
46
 
package/CHANGELOG.zh.md CHANGED
@@ -5,7 +5,42 @@
5
5
 
6
6
  ## [Unreleased]
7
7
 
8
- 1.0.2 之后暂无变更。
8
+ 1.1.0 之后暂无变更。
9
+
10
+ ## [1.1.0] - 2026-10-06
11
+
12
+ PersonaBot 可设置并自行管理定时任务,每个会话都会带上 Bot 的 Soul 与核心记忆,Channel 侧栏各分区统一为卡片样式,微信支持语音转写和图片;每个 Bot 的 Memory 会保存供 Bot 市场使用的 `.botharness/bot.json`;插件会发送可关闭的匿名使用统计;Bot 设置可一键安装 DeepSeekBot 更新并重启 DSH。
13
+
14
+ ### Added
15
+
16
+ - 增加个人微信语音来源候选链路,使用平台提供的转写,在 Bot Inbox 区分有转写与缺少转写;不增加 ASR 或音频播放,真实原生语音 → 模型 → 原私聊回复已由 Human 确认([#905](https://github.com/BotHarness/BotHarness/issues/905))。
17
+ - 增加源码预览微信图片链路,支持 Inbox 原消息气泡内自动加载的 checked 图片预览、原生模型图片输入与本身份原生图片回复,Human 已确认原私聊收到内容一致的图片([#904](https://github.com/BotHarness/BotHarness/issues/904),[连接指南](docs/wechat-connection.md))。
18
+ - PersonaBot 新增定时任务(Bot Schedule):Channel 侧栏的「定时任务」分区可新建、编辑、暂停和删除按分钟、按小时或每天执行的任务;每次触发进入 Bot 收件箱并唤醒 Orchestrator,每个任务可查看最近 20 次触发及处理它的会话([#960](https://github.com/BotHarness/BotHarness/issues/960),[ADR-0133](docs/adr/0133-bot-schedules-wake-the-orchestrator-through-the-bot-inbox.md))。
19
+ - DeepSeekBot 现在会在创建 Bot 时,自动在它的 Memory 里写入 `.botharness/bot.json`,之后改名称、岗位或头像时同步更新;已有的 Bot 会在下次启动时补上。分享出去的 Bot 在 Bot 市场里显示的名称、岗位和头像,和侧栏里一致([#966](https://github.com/BotHarness/BotHarness/issues/966)、[教程](docs/share-bot.md))。
20
+ - DeepSeekBot 由 DSH 后台发送匿名使用统计,只关联一个随机安装 ID:`plugin_started`(插件和 DSH 版本、操作系统、架构),`bot_created`、`bot_archived`、`bot_deleted`、`marketplace_bot_installed`、`connector_enabled`(只含连接器类型)、`avatar_edited`,每天一次的 `daily_usage` 汇总(PersonaBot、会话和消息数量及统计时长),以及 BotHarness 后台未处理错误的 `$exception` 报告(错误类型和只保留包内文件名的调用栈,从不含错误信息或文件路径);Bot 模式会弹出一次说明,并链接隐私说明和源码。可在 Bot 设置中关掉「匿名使用统计」开关,立即生效、无需重启,并会被记住;在 core 插件配置中设置 `telemetry: false`,或设置 `DO_NOT_TRACK=1`、`BOTHARNESS_TELEMETRY=0`,会强制关闭并锁定该开关([#951](https://github.com/BotHarness/BotHarness/issues/951),[#952](https://github.com/BotHarness/BotHarness/issues/952),[ADR-0132](docs/adr/0132-anonymous-posthog-telemetry-and-campaign-short-links.md),[教程](docs/settings.md))。
21
+ - PersonaBot 可以自己管理定时任务:让 Bot「每小时检查一下 X」或「每天早上总结」,它会自己创建定时任务,侧栏里标为 Bot 创建;它也可以修改或删除你没有锁定的任务。你可以在任务行或编辑弹窗里锁定任务;每个 Bot 最多同时启用 20 个;Bot 改动后侧栏立即刷新;Orchestrator 中 DSH 自带的 `schedule_*` 工具会被拒绝,确保每个 Bot 只有一套定时任务([#961](https://github.com/BotHarness/BotHarness/issues/961))。
22
+ - 定时任务新增每周(选择星期几)、单次(指定日期和时间,触发后自动停用)和 5 段 Cron 三种频率,均按任务自己的时区计算;编辑弹窗会预览接下来三次触发时间,Bot 的定时任务工具也支持这些频率;任务行上的「立即运行」会马上唤醒 Orchestrator,且不改变下一次计划时间。新增[定时任务使用指南](docs/channel-sidebar/schedules.md),说明各种频率、立即运行、暂停与锁定([#962](https://github.com/BotHarness/BotHarness/issues/962))。
23
+ - Bot 设置可以通过 DSH 的插件管理一键安装新版本 DeepSeekBot。Web 版装完点「立即重启」,`dsh web` 会在同一个终端里重启,页面自动重新连接;DSH Desktop 会提示退出后重新打开。插件管理不可用或安装失败时,会显示原因和手动更新命令。新增[更新 DeepSeekBot](docs/update-deepseekbot.md)教程,说明每一步([#986](https://github.com/BotHarness/BotHarness/issues/986))。
24
+
25
+ ### Changed
26
+
27
+ - Channel 侧栏的会话、Bot 收件箱和工作区授权改用与定时任务相同的卡片行:每行带图标、状态 chip 和说明行;来自定时任务的收件箱条目现在可以点开对应的定时任务([#972](https://github.com/BotHarness/BotHarness/issues/972))。
28
+ - Channel 侧栏的电脑和浏览器分区也改用相同的卡片行:状态卡片显示目标(本机或 Docker)、运行中、需要设置、已暂停等状态 chip 和对应操作,浏览器打开的标签页也以卡片行列出([#975](https://github.com/BotHarness/BotHarness/issues/975))。
29
+ - Bot Profile 的头像区合并为一个「头像」分区,并排提供「设计像素头像」和「上传图片」两种方式,并标出正在使用的那种;去掉了重复的「更换头像」按钮,顶部分隔线上下留出空白([#985](https://github.com/BotHarness/BotHarness/issues/985))。
30
+ - PersonaBot 的人格文件改名为 `SOUL.md`(Soul),每个 Session 开始时还会带上 Core Memory `MEMORY.md`,新对话一开始就知道 Bot 记得什么。两者在整个 Session 内冻结,并带字符用量标注(默认上限 5,000 和 3,000 字符);新建的 Bot 会附带一份简短的 `MEMORY.md` 模板,已有的 `PERSONA.md` 会在下次启动时改名为 `SOUL.md`([#988](https://github.com/BotHarness/BotHarness/issues/988),[ADR-0134](docs/adr/0134-soul-and-core-memory-are-session-frozen-system-prompt-files.md))。
31
+ - 每个 Bot 的资料页新增「常驻记忆上限」,可分别设置 `SOUL.md` 和 `MEMORY.md` 的字符上限,并显示约合多少汉字和英文单词,从下一个 Session 开始生效。Memory 面板把这两个文件置顶,带「常驻」标记和当前用量,超限时标红;Memory 搜索现在也能搜到它们([#989](https://github.com/BotHarness/BotHarness/issues/989),[ADR-0134](docs/adr/0134-soul-and-core-memory-are-session-frozen-system-prompt-files.md))。
32
+
33
+ ### Fixed
34
+
35
+ - 带明确私聊 Chat ID 的 Lark 用户目标可以将未 @ 的私聊消息送进同一个 PersonaBot Inbox,并以绑定身份回复;未提供该标识的目标仍只支持发送([#996](https://github.com/BotHarness/BotHarness/issues/996))。
36
+
37
+ ### Documentation
38
+
39
+ - 记录开发来源 Discord 文件候选的真实模型保存/处理/导入/原 thread 结果、独立原件不变/输出字节证据及临时工作区写权限清理([#1002](https://github.com/BotHarness/BotHarness/issues/1002),[verification](docs/dev/verification/discord-1002-source-files.md))。
40
+ - 新增教程 [Bot 灵魂与核心记忆](docs/soul-and-core-memory.md):说明 `SOUL.md` 与 `MEMORY.md` 为什么在每个 Session 开始时冻结注入、两个文件分别代表什么、为什么没有 `USER.md`、字符上限及中英文的大致篇幅和 token 量、如何修改上限、超限时的样子、修改何时生效,以及如何和 Bot 一起塑造 `MEMORY.md`([#990](https://github.com/BotHarness/BotHarness/issues/990),[ADR-0134](docs/adr/0134-soul-and-core-memory-are-session-frozen-system-prompt-files.md))。
41
+ - GitHub 与 npm 的 README 补充定时任务、Bot 市场和更新提示,新增依据本 Ledger 整理的「版本亮点」,并换成高清截图表格,所有头像均为 BotPixel 像素头像([#984](https://github.com/BotHarness/BotHarness/issues/984))。
42
+ - 记录隔离 Discord nearby 上下文候选的准确原生来源范围、五分钟窗口、稀疏 Human 文本最小条数与有界续页;真实模型稀疏续页、canonical 留存、原 thread 回复和临时权限恢复已独立验证,产品提升仍另行管理([#981](https://github.com/BotHarness/BotHarness/issues/981),[指南](docs/dev/guides/im-provider-integration.md))。
43
+ - 补全 Discord 上下文开发来源验收文档,提供真实模型续页、准确的已编辑来源拒绝、整页回滚及消息正文权限恢复证据([#937](https://github.com/BotHarness/BotHarness/issues/937),[verification](docs/dev/verification/discord-937-context-reads.md))。
9
44
 
10
45
  ## [1.0.2] - 2026-10-06
11
46
 
package/dist/index.d.mts CHANGED
@@ -1,8 +1,8 @@
1
1
  import { DatabaseSync } from "node:sqlite";
2
2
  import { ToolCallKind, ToolCallView, ToolExecution } from "@deepseek-ai/dsh-tools";
3
3
  import { BlockAssembler, ContextFormed, ToolCallId } from "@deepseek-ai/dsh-llm";
4
- import { Agent, AgentHandle, AssistantStreamFrame, CreateAgentOptions, ModelSelection, ResumeAgentOptions } from "@deepseek-ai/dsh-agent";
5
4
  import { Session, SessionId } from "@deepseek-ai/dsh-session";
5
+ import { Agent, AgentHandle, AssistantStreamFrame, CreateAgentOptions, ModelSelection, ResumeAgentOptions } from "@deepseek-ai/dsh-agent";
6
6
  //#region node_modules/.pnpm/@deepseek-ai+cosmokit@1.8.5/node_modules/@deepseek-ai/cosmokit/lib/types/types.d.ts
7
7
  declare function isArrayBufferLike(value: any): value is ArrayBufferLike;
8
8
  declare function isArrayBufferSource(value: any): value is Binary.Source;
@@ -8021,6 +8021,11 @@ interface MessagingAttachment {
8021
8021
  sizeBytes?: number;
8022
8022
  mediaType?: string;
8023
8023
  }
8024
+ interface MessagingVoice {
8025
+ transcript: 'platform' | 'unavailable';
8026
+ itemId?: string;
8027
+ durationMs?: number;
8028
+ }
8024
8029
  interface MessagingInboundEvent {
8025
8030
  version: 1;
8026
8031
  channel: 'feishu' | 'slack' | 'discord' | 'weixin';
@@ -8046,6 +8051,7 @@ interface MessagingInboundEvent {
8046
8051
  at: string;
8047
8052
  text: string;
8048
8053
  attachments?: MessagingAttachment[];
8054
+ voice?: MessagingVoice;
8049
8055
  reply: MessagingReplyRoute;
8050
8056
  replay: {
8051
8057
  kind: 'provider-redelivery';
@@ -8157,6 +8163,7 @@ interface MessagingProvider {
8157
8163
  id: string;
8158
8164
  name: string;
8159
8165
  bytes: Uint8Array;
8166
+ mediaType?: string;
8160
8167
  };
8161
8168
  signal: AbortSignal;
8162
8169
  beforeSend?: () => boolean;
@@ -8297,6 +8304,16 @@ interface InboundMessaging {
8297
8304
  close(): void;
8298
8305
  }
8299
8306
  //#endregion
8307
+ //#region packages/core/src/telemetry/service.d.ts
8308
+ type TelemetryValue = string | number | boolean;
8309
+ type TelemetryCapture = (event: string, properties?: Record<string, TelemetryValue>) => void;
8310
+ type TelemetryLock = 'config' | 'DO_NOT_TRACK' | 'BOTHARNESS_TELEMETRY';
8311
+ interface TelemetryStatus {
8312
+ enabled: boolean;
8313
+ preference: boolean;
8314
+ lockedBy?: TelemetryLock;
8315
+ }
8316
+ //#endregion
8300
8317
  //#region packages/core/src/messaging/outbound.d.ts
8301
8318
  interface MessagingGrant {
8302
8319
  id: string;
@@ -8432,8 +8449,21 @@ export declare function createOutboundMessaging(options: {
8432
8449
  recover?: boolean;
8433
8450
  now?: () => Date;
8434
8451
  warn?: (message: string) => void;
8452
+ capture?: TelemetryCapture;
8435
8453
  }): OutboundMessaging;
8436
8454
  //#endregion
8455
+ //#region packages/core/src/memory/soul.d.ts
8456
+ interface StandingLimits {
8457
+ soul: number;
8458
+ coreMemory: number;
8459
+ }
8460
+ interface StandingUsage {
8461
+ path: string;
8462
+ role: 'soul' | 'coreMemory';
8463
+ chars: number;
8464
+ limit: number;
8465
+ }
8466
+ //#endregion
8437
8467
  //#region packages/core/src/models/presets.d.ts
8438
8468
  interface ModelRoute {
8439
8469
  provider: string;
@@ -8698,6 +8728,7 @@ interface PersonaBotRecord {
8698
8728
  computerAccess?: boolean;
8699
8729
  browserAccess?: boolean;
8700
8730
  browserProfile?: string;
8731
+ standingLimits?: StandingLimits;
8701
8732
  }
8702
8733
  interface CreatePersonaBotInput {
8703
8734
  slug: string;
@@ -8886,6 +8917,10 @@ interface PersonaBotRegistryOptions {
8886
8917
  initializeMemory?: (memoryDir: string) => MemoryRepositoryInitialization;
8887
8918
  cloneMemory?: (destination: string, url: string) => Promise<MemoryCloneResult>;
8888
8919
  onPurge?: (slug: string, removeFiles: () => void) => void;
8920
+ capture?: TelemetryCapture;
8921
+ syncDescriptor?: (memoryDir: string, record: PersonaBotRecord, options: {
8922
+ onlyIfMissing: boolean;
8923
+ }) => void;
8889
8924
  }
8890
8925
  interface PersonaBotRegistry {
8891
8926
  rootDir: string;
@@ -8904,6 +8939,7 @@ interface PersonaBotRegistry {
8904
8939
  setComputerAccess(slug: string, enabled: boolean): UpdatePersonaBotResult;
8905
8940
  setBrowserAccess(slug: string, enabled: boolean): UpdatePersonaBotResult;
8906
8941
  setBrowserProfile(slug: string, profile: string): UpdatePersonaBotResult;
8942
+ setStandingLimits(slug: string, limits: StandingLimits): UpdatePersonaBotResult;
8907
8943
  applyModelPreset(slug: string, preset: ModelPreset): UpdatePersonaBotResult;
8908
8944
  migrateLegacyModel(slug: string, expectedModel: string, route: ModelRoute): UpdatePersonaBotResult;
8909
8945
  customizeModelPlan(slug: string, orchestrator: PersonaBotModelPlan['orchestrator'], expectedRevision: number): UpdatePersonaBotResult;
@@ -8995,6 +9031,7 @@ interface MemoryAcceptedSnapshot {
8995
9031
  head: string | null;
8996
9032
  files: string[];
8997
9033
  provisional: boolean;
9034
+ standing: StandingUsage[];
8998
9035
  }
8999
9036
  interface MemoryChangeDelta {
9000
9037
  summary: string;
@@ -9193,7 +9230,7 @@ interface MemoryStore {
9193
9230
  read(path: string): MemoryEntry | undefined;
9194
9231
  write(input: MemoryWriteInput): Promise<MemoryWriteResult>;
9195
9232
  search(query: string): Promise<MemorySearchHit[]>;
9196
- persona(): string | undefined;
9233
+ standingPrompt(limits?: StandingLimits): string;
9197
9234
  history(limit?: number): MemoryCommit[];
9198
9235
  }
9199
9236
  export declare function createMemoryStore(options: MemoryStoreOptions): MemoryStore;
@@ -9260,6 +9297,81 @@ interface AssignmentReportPage {
9260
9297
  estimatedTokens: number;
9261
9298
  }
9262
9299
  //#endregion
9300
+ //#region packages/core/src/schedules/bot-schedules.d.ts
9301
+ type BotScheduleTrigger = {
9302
+ kind: 'every';
9303
+ everySeconds: number;
9304
+ } | {
9305
+ kind: 'daily';
9306
+ time: string;
9307
+ timeZone: string;
9308
+ } | {
9309
+ kind: 'weekly';
9310
+ time: string;
9311
+ timeZone: string;
9312
+ weekdays: number[];
9313
+ } | {
9314
+ kind: 'once';
9315
+ date: string;
9316
+ time: string;
9317
+ timeZone: string;
9318
+ } | {
9319
+ kind: 'cron';
9320
+ expression: string;
9321
+ timeZone: string;
9322
+ };
9323
+ type BotScheduleCreator = 'human' | 'personabot';
9324
+ type BotScheduleFiringState = 'pending' | 'observed' | 'handled' | 'coalesced' | 'skipped';
9325
+ interface BotScheduleFiring {
9326
+ id: string;
9327
+ scheduleId: string;
9328
+ trigger: 'planned' | 'manual';
9329
+ occurrenceAt: string;
9330
+ firedAt: string;
9331
+ state: BotScheduleFiringState;
9332
+ sourceEventId?: string;
9333
+ sessionId?: string;
9334
+ }
9335
+ interface BotSchedule {
9336
+ id: string;
9337
+ botSlug: string;
9338
+ title: string;
9339
+ prompt: string;
9340
+ trigger: BotScheduleTrigger;
9341
+ enabled: boolean;
9342
+ creator: BotScheduleCreator;
9343
+ locked: boolean;
9344
+ nextRunAt?: string;
9345
+ lastFiring?: BotScheduleFiring;
9346
+ createdAt: string;
9347
+ updatedAt: string;
9348
+ }
9349
+ interface BotScheduleInput {
9350
+ title: string;
9351
+ prompt: string;
9352
+ trigger: BotScheduleTrigger;
9353
+ enabled?: boolean;
9354
+ locked?: boolean;
9355
+ }
9356
+ interface BotScheduleChange {
9357
+ title?: string;
9358
+ prompt?: string;
9359
+ trigger?: BotScheduleTrigger;
9360
+ enabled?: boolean;
9361
+ locked?: boolean;
9362
+ }
9363
+ interface BotScheduleStore {
9364
+ list(botSlug: string): BotSchedule[];
9365
+ create(botSlug: string, input: BotScheduleInput, creator: BotScheduleCreator): BotSchedule;
9366
+ update(botSlug: string, id: string, change: BotScheduleChange, actor: BotScheduleCreator): BotSchedule;
9367
+ remove(botSlug: string, id: string, actor: BotScheduleCreator): boolean;
9368
+ history(botSlug: string, id: string): BotScheduleFiring[];
9369
+ runNow(botSlug: string, id: string): BotScheduleFiring;
9370
+ tick(): void;
9371
+ start(): void;
9372
+ close(): void;
9373
+ }
9374
+ //#endregion
9263
9375
  //#region packages/core/src/runtime/bot-runtime.d.ts
9264
9376
  type AssignmentActivity = 'working' | 'idle' | 'error' | 'stopping' | 'stopped';
9265
9377
  type AssignmentReportState = 'progress' | 'completed' | 'blocked' | 'waiting-human' | 'failed';
@@ -9408,6 +9520,12 @@ interface OrchestratorAgentRun {
9408
9520
  resetImmediateDelivery(sourceClass: 'human-dm' | 'bot-dm' | 'group-mention'): BotSourcePolicy;
9409
9521
  };
9410
9522
  assignments: OrchestratorAssignmentAccess;
9523
+ schedules?: {
9524
+ list(): BotSchedule[];
9525
+ create(input: BotScheduleInput): BotSchedule;
9526
+ update(id: string, change: BotScheduleChange): BotSchedule;
9527
+ remove(id: string): boolean;
9528
+ };
9411
9529
  memory?: {
9412
9530
  switchBranch(branch: string): {
9413
9531
  from: string;
@@ -9645,6 +9763,7 @@ interface BotRuntime {
9645
9763
  listAssignments(botSlug: string): AssignmentSummary[];
9646
9764
  getAssignment(botSlug: string, sessionId: string): AssignmentDetail | undefined;
9647
9765
  admitExternalSource?(botSlug: string, sourceEventId: string): void;
9766
+ admitScheduleFiring?(botSlug: string): void;
9648
9767
  resumePendingDigests?(botSlug: string): void;
9649
9768
  whenIdle(): Promise<void>;
9650
9769
  close(): Promise<void>;
@@ -9654,6 +9773,7 @@ interface BotRuntimeOptions {
9654
9773
  externalMessaging?: OutboundMessaging;
9655
9774
  database: OperationalDatabaseOwner;
9656
9775
  sourcePolicy?: BotSourcePolicyStore;
9776
+ schedules?: Pick<BotScheduleStore, 'list' | 'create' | 'update' | 'remove'>;
9657
9777
  registry: PersonaBotRegistry;
9658
9778
  channels: ChannelStore;
9659
9779
  agents: BotAgentAdapter;
@@ -10440,6 +10560,7 @@ interface BotAttentionItem {
10440
10560
  assignmentReportState?: 'progress' | 'completed' | 'blocked' | 'waiting-human' | 'failed';
10441
10561
  assignmentTurn?: number;
10442
10562
  relatedReportSourceEventId?: string;
10563
+ scheduleId?: string;
10443
10564
  sourceAvailable: boolean;
10444
10565
  authorKind: 'human' | 'bot' | 'bridged' | 'system';
10445
10566
  authorBotSlug?: string;
@@ -10450,6 +10571,7 @@ interface BotAttentionItem {
10450
10571
  conversationId: string;
10451
10572
  senderId: string;
10452
10573
  senderName?: string;
10574
+ voice?: NonNullable<ExternalSource['event']['voice']>;
10453
10575
  };
10454
10576
  summary: string;
10455
10577
  }
@@ -10690,6 +10812,7 @@ interface BotHarnessConfig {
10690
10812
  agentPreset?: string;
10691
10813
  activityDetailConsumers?: string[];
10692
10814
  marketplaceUrl?: string;
10815
+ telemetry?: boolean;
10693
10816
  }
10694
10817
  export declare const DEFAULT_CONFIG: BotHarnessConfig;
10695
10818
  declare const Config$1: Schema<Schemastery.ObjectS<NoInfer<{
@@ -10697,11 +10820,13 @@ declare const Config$1: Schema<Schemastery.ObjectS<NoInfer<{
10697
10820
  activityDetailConsumers: Schema<string[], string[], "defined">;
10698
10821
  agentPreset: Schema<string, string, "defined">;
10699
10822
  marketplaceUrl: Schema<string, string, "defined">;
10823
+ telemetry: Schema<boolean, boolean, "defined">;
10700
10824
  }>>, Schemastery.ObjectT<NoInfer<{
10701
10825
  enabled: Schema<boolean, boolean, "defined">;
10702
10826
  activityDetailConsumers: Schema<string[], string[], "defined">;
10703
10827
  agentPreset: Schema<string, string, "defined">;
10704
10828
  marketplaceUrl: Schema<string, string, "defined">;
10829
+ telemetry: Schema<boolean, boolean, "defined">;
10705
10830
  }>>, "plain">;
10706
10831
  interface BotHarnessCore {
10707
10832
  rootDir: string;
@@ -10724,6 +10849,7 @@ interface BotHarnessCore {
10724
10849
  runtime: BotRuntime;
10725
10850
  attention: BotAttentionQuery;
10726
10851
  sourcePolicy: BotSourcePolicyStore;
10852
+ schedules: BotScheduleStore;
10727
10853
  humanAttention: HumanAttentionQuery;
10728
10854
  humanAttentionDecisions: HumanAttentionDecisions;
10729
10855
  grants: WorkspaceGrantStore;
@@ -10751,6 +10877,7 @@ export declare function createCore(options?: {
10751
10877
  onOutputCommitted?: (event: PersonaBotOutputCommitted) => void;
10752
10878
  activeQuestionMessageIds?: () => readonly string[];
10753
10879
  activeToolApprovalMessageIds?: () => readonly string[];
10880
+ capture?: TelemetryCapture;
10754
10881
  }): BotHarnessCore;
10755
10882
  export declare function apply(ctx: Context, config: BotHarnessConfig): void;
10756
10883
  declare module '@deepseek-ai/cordis' {
@@ -10868,10 +10995,36 @@ type ReleaseUpdate = {
10868
10995
  current: string;
10869
10996
  latest: string;
10870
10997
  releases: ReleaseNote[];
10998
+ installable: boolean;
10999
+ } | {
11000
+ status: 'restart-required';
11001
+ current: string;
11002
+ installed: string;
11003
+ restartable: boolean;
11004
+ };
11005
+ type ReleaseInstallFailure = 'unavailable' | 'invalid-version' | 'network' | 'incompatible' | 'build-blocked' | 'failed';
11006
+ type ReleaseInstall = {
11007
+ status: 'installed';
11008
+ current: string;
11009
+ installed: string;
11010
+ restartable: boolean;
11011
+ } | {
11012
+ status: 'failed';
11013
+ reason: ReleaseInstallFailure;
11014
+ diagnostic?: string;
11015
+ logPath?: string;
11016
+ };
11017
+ type ReleaseRestart = {
11018
+ status: 'restarting';
11019
+ } | {
11020
+ status: 'failed';
11021
+ reason: 'unavailable' | 'not-pending';
10871
11022
  };
10872
11023
  interface ReleaseService {
10873
11024
  info(since?: string): ReleaseInfo;
10874
11025
  update(): Promise<ReleaseUpdate>;
11026
+ install(version: string): Promise<ReleaseInstall>;
11027
+ restart(): Promise<ReleaseRestart>;
10875
11028
  }
10876
11029
  //#endregion
10877
11030
  //#region packages/core/src/channels/profile-activity.d.ts
@@ -10979,6 +11132,7 @@ interface PersonaBotSummary {
10979
11132
  avatar?: string;
10980
11133
  appearance?: AvatarAppearance | RetainedAvatarAppearance;
10981
11134
  paused?: boolean;
11135
+ standingLimits: StandingLimits;
10982
11136
  aggregateState: AggregatedState;
10983
11137
  workspaces: string[];
10984
11138
  createdAt: string;
@@ -11389,6 +11543,9 @@ interface BridgeMethods {
11389
11543
  browserProfileSet(payload: unknown): BridgeResult<{
11390
11544
  bot: PersonaBotDetail;
11391
11545
  }>;
11546
+ standingLimitsSet(payload: unknown): BridgeResult<{
11547
+ bot: PersonaBotDetail;
11548
+ }>;
11392
11549
  botAvatarSet(payload: unknown): BridgeResult<{
11393
11550
  bot: PersonaBotDetail;
11394
11551
  }>;
@@ -11407,6 +11564,31 @@ interface BridgeMethods {
11407
11564
  }>>;
11408
11565
  releaseInfo(payload: unknown): BridgeResult<ReleaseInfo>;
11409
11566
  releaseUpdate(): Promise<BridgeResult<ReleaseUpdate>>;
11567
+ releaseInstall(payload: unknown): Promise<BridgeResult<ReleaseInstall>>;
11568
+ releaseRestart(payload: unknown): Promise<BridgeResult<ReleaseRestart>>;
11569
+ telemetryStatus(): BridgeResult<TelemetryStatus>;
11570
+ telemetrySet(payload: unknown): BridgeResult<TelemetryStatus>;
11571
+ scheduleList(payload: unknown): BridgeResult<{
11572
+ schedules: BotSchedule[];
11573
+ }>;
11574
+ scheduleCreate(payload: unknown): BridgeResult<{
11575
+ schedule: BotSchedule;
11576
+ }>;
11577
+ scheduleUpdate(payload: unknown): BridgeResult<{
11578
+ schedule: BotSchedule;
11579
+ }>;
11580
+ scheduleDelete(payload: unknown): BridgeResult<{
11581
+ removed: boolean;
11582
+ }>;
11583
+ scheduleHistory(payload: unknown): BridgeResult<{
11584
+ firings: BotScheduleFiring[];
11585
+ }>;
11586
+ scheduleRunNow(payload: unknown): BridgeResult<{
11587
+ firing: BotScheduleFiring;
11588
+ }>;
11589
+ schedulePreview(payload: unknown): BridgeResult<{
11590
+ occurrences: string[];
11591
+ }>;
11410
11592
  }
11411
11593
  interface BridgeMethodsDeps {
11412
11594
  warn?: (message: string) => void;
@@ -11425,6 +11607,7 @@ interface BridgeMethodsDeps {
11425
11607
  runtime?: BotRuntime;
11426
11608
  attention?: BotAttentionQuery;
11427
11609
  sourcePolicy?: BotSourcePolicyStore;
11610
+ schedules?: BotScheduleStore;
11428
11611
  humanAttention?: HumanAttentionQuery;
11429
11612
  humanAttentionDecisions?: HumanAttentionDecisions;
11430
11613
  grants?: WorkspaceGrantStore;
@@ -11448,6 +11631,11 @@ interface BridgeMethodsDeps {
11448
11631
  createBotId?: () => string;
11449
11632
  marketplace?: MarketplaceClient;
11450
11633
  release?: ReleaseService;
11634
+ telemetry?: {
11635
+ status(): TelemetryStatus;
11636
+ setPreference(enabled: boolean): TelemetryStatus;
11637
+ capture?: TelemetryCapture;
11638
+ };
11451
11639
  }
11452
11640
  export declare function createBridgeMethods(deps: BridgeMethodsDeps): BridgeMethods;
11453
11641
  //#endregion
@@ -11566,6 +11754,9 @@ export declare class BotharnessBridgeService extends TypertRemoteService {
11566
11754
  browserProfileSet(slug: string, profile: string): {
11567
11755
  bot: PersonaBotDetail;
11568
11756
  };
11757
+ standingLimitsSet(slug: string, soul: number, coreMemory: number): {
11758
+ bot: PersonaBotDetail;
11759
+ };
11569
11760
  botAvatarSet(channelId: string, avatar: string | null): {
11570
11761
  bot: PersonaBotDetail;
11571
11762
  };
@@ -11815,6 +12006,31 @@ export declare class BotharnessBridgeService extends TypertRemoteService {
11815
12006
  marketplaceDetail(id: string): Promise<MarketplaceDetail>;
11816
12007
  releaseInfo(since?: string): Promise<ReleaseInfo>;
11817
12008
  releaseUpdate(): Promise<ReleaseUpdate>;
12009
+ releaseInstall(version: string): Promise<ReleaseInstall>;
12010
+ releaseRestart(): Promise<ReleaseRestart>;
12011
+ telemetryStatus(): TelemetryStatus;
12012
+ telemetrySet(enabled: boolean): TelemetryStatus;
12013
+ scheduleList(slug: string): {
12014
+ schedules: BotSchedule[];
12015
+ };
12016
+ scheduleCreate(slug: string, input: BotScheduleInput): {
12017
+ schedule: BotSchedule;
12018
+ };
12019
+ scheduleUpdate(slug: string, id: string, change: BotScheduleChange): {
12020
+ schedule: BotSchedule;
12021
+ };
12022
+ scheduleDelete(slug: string, id: string): {
12023
+ removed: boolean;
12024
+ };
12025
+ scheduleHistory(slug: string, id: string): {
12026
+ firings: BotScheduleFiring[];
12027
+ };
12028
+ scheduleRunNow(slug: string, id: string): {
12029
+ firing: BotScheduleFiring;
12030
+ };
12031
+ schedulePreview(trigger: BotScheduleTrigger): {
12032
+ occurrences: string[];
12033
+ };
11818
12034
  }
11819
12035
  export declare function registerBridge(ctx: Context, methods: BridgeMethods): BotharnessBridgeService;
11820
12036
  //#endregion
@@ -11990,6 +12206,7 @@ interface DshImOutboundService {
11990
12206
  id: string;
11991
12207
  name: string;
11992
12208
  bytes: Uint8Array;
12209
+ mediaType?: string;
11993
12210
  }, options: {
11994
12211
  expectedFingerprint: string;
11995
12212
  signal: AbortSignal;
@@ -12017,6 +12234,8 @@ interface DshImOutboundService {
12017
12234
  expectedFingerprint: string;
12018
12235
  signal: AbortSignal;
12019
12236
  sourceFiles?: boolean;
12237
+ sourceImages?: boolean;
12238
+ sourceVoiceTranscripts?: boolean;
12020
12239
  ordinaryText?: boolean;
12021
12240
  onEcho?(event: unknown, context: {
12022
12241
  signal: AbortSignal;