@blade-hq/agent-client 2612.0.0-beta.71 → 2612.0.0-beta.72

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/dist/index.js CHANGED
@@ -26,7 +26,7 @@ import {
26
26
  parseAskUserQuestion,
27
27
  transformSlashCommand,
28
28
  userFacingErrorText
29
- } from "./chunk-DMVWOTJB.js";
29
+ } from "./chunk-T5PXAGPI.js";
30
30
  export {
31
31
  AgentSession,
32
32
  AgentSessionError,
package/dist/internal.js CHANGED
@@ -95,7 +95,7 @@ import {
95
95
  withTurns,
96
96
  workflowEntriesFromOutput,
97
97
  workflowNameFromArguments
98
- } from "./chunk-DMVWOTJB.js";
98
+ } from "./chunk-T5PXAGPI.js";
99
99
 
100
100
  // src/polling-backoff.ts
101
101
  var MAX_BACKOFF_MS = 6e4;
@@ -3,6 +3,8 @@ export interface ContextAttachment {
3
3
  id: string;
4
4
  label: string;
5
5
  content: string;
6
+ /** Explicitly remove or restore a named Context. Ordinary updates cannot revive a removed source. */
7
+ action?: "remove" | "restore";
6
8
  /** Project plain text as a named session Context; the producer supplies full state. */
7
9
  update_format?: "snapshot" | "diff";
8
10
  data?: Record<string, unknown> | null;
@@ -165,6 +165,7 @@ export declare class AgentSession {
165
165
  private lastDeliveredSystemError;
166
166
  private systemErrorGeneration;
167
167
  private subscriptionReplaySource;
168
+ private readonly lifetimeAbort;
168
169
  private disposed;
169
170
  private getAppContext;
170
171
  private sendPending;
@@ -15,6 +15,7 @@ export declare namespace ChatSendPayloadSchema {
15
15
  type Id = string;
16
16
  type Label = string;
17
17
  type Content = string;
18
+ type Action = (("remove" | "restore") | null);
18
19
  type UpdateFormat = (("snapshot" | "diff") | null);
19
20
  type Data = ({
20
21
  [k: string]: unknown;
@@ -95,6 +96,7 @@ export declare namespace ChatSendPayloadSchema {
95
96
  id: Id;
96
97
  label: Label;
97
98
  content: Content;
99
+ action?: Action;
98
100
  update_format?: UpdateFormat;
99
101
  data?: Data;
100
102
  files?: Files;
@@ -155,6 +157,7 @@ export declare namespace ChatAppendPayloadSchema {
155
157
  type Id = string;
156
158
  type Label = string;
157
159
  type Content = string;
160
+ type Action = (("remove" | "restore") | null);
158
161
  type UpdateFormat = (("snapshot" | "diff") | null);
159
162
  type Data = ({
160
163
  [k: string]: unknown;
@@ -192,6 +195,7 @@ export declare namespace ChatAppendPayloadSchema {
192
195
  id: Id;
193
196
  label: Label;
194
197
  content: Content;
198
+ action?: Action;
195
199
  update_format?: UpdateFormat;
196
200
  data?: Data;
197
201
  files?: Files;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@blade-hq/agent-client",
3
- "version": "2612.0.0-beta.71",
3
+ "version": "2612.0.0-beta.72",
4
4
  "description": "Blade Agent 框架无关客户端:会话实时状态机、REST 通道、弹窗登录、页面协作。浏览器与 Node.js 通用。",
5
5
  "repository": {
6
6
  "type": "git",
package/public-api.md CHANGED
@@ -702,6 +702,7 @@ contentPreview: (content: MessageContent, maxLen?: number) => string
702
702
  ## `ContextAttachment` (interface)
703
703
 
704
704
  ```ts
705
+ action: "remove" | "restore" | undefined
705
706
  content: string
706
707
  data: Record<string, unknown> | null | undefined
707
708
  files: { name: string; session_id?: string; path?: string; }[] | undefined
@@ -1076,6 +1077,7 @@ export type PhoneState = "enabled" | "offline" | "idle"
1076
1077
  ## `PluginFileOpener` (interface)
1077
1078
 
1078
1079
  ```ts
1080
+ default: boolean | undefined
1079
1081
  extensions: string[]
1080
1082
  id: string
1081
1083
  label: string