@agentscope-ai/agentscope 0.0.2 → 0.0.4

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 (90) hide show
  1. package/LICENSE +202 -0
  2. package/dist/agent/index.d.mts +10 -10
  3. package/dist/agent/index.d.ts +10 -10
  4. package/dist/agent/index.js +104 -93
  5. package/dist/agent/index.js.map +1 -1
  6. package/dist/agent/index.mjs +104 -93
  7. package/dist/agent/index.mjs.map +1 -1
  8. package/dist/{base-BOx3UzOl.d.mts → base-1YVBgB4n.d.mts} +2 -2
  9. package/dist/{base-DYlBMCy_.d.mts → base-B_MQMHWr.d.mts} +3 -3
  10. package/dist/{base-Cwi4bjze.d.ts → base-BherSLRs.d.ts} +3 -3
  11. package/dist/{base-NX-knWOv.d.ts → base-CY4DMBH1.d.ts} +1 -1
  12. package/dist/{base-BoIps2RL.d.ts → base-ChWjyzPL.d.ts} +2 -2
  13. package/dist/{base-C7jwyH4Z.d.mts → base-ClilytRZ.d.mts} +1 -1
  14. package/dist/{block-VsnHrllL.d.mts → block-B72uPF1H.d.mts} +7 -5
  15. package/dist/{block-VsnHrllL.d.ts → block-B72uPF1H.d.ts} +7 -5
  16. package/dist/event/index.d.mts +105 -89
  17. package/dist/event/index.d.ts +105 -89
  18. package/dist/event/index.js +8 -8
  19. package/dist/event/index.js.map +1 -1
  20. package/dist/event/index.mjs +8 -8
  21. package/dist/event/index.mjs.map +1 -1
  22. package/dist/formatter/index.d.mts +4 -3
  23. package/dist/formatter/index.d.ts +4 -3
  24. package/dist/formatter/index.js +17 -17
  25. package/dist/formatter/index.js.map +1 -1
  26. package/dist/formatter/index.mjs +17 -17
  27. package/dist/formatter/index.mjs.map +1 -1
  28. package/dist/{index-BcatlwXQ.d.ts → index-BNfyKbQN.d.ts} +1 -1
  29. package/dist/{index-BTJDlKvQ.d.mts → index-UQCwdfet.d.mts} +1 -1
  30. package/dist/mcp/index.d.mts +2 -2
  31. package/dist/mcp/index.d.ts +2 -2
  32. package/dist/mcp/index.js +1 -1
  33. package/dist/mcp/index.js.map +1 -1
  34. package/dist/mcp/index.mjs +1 -1
  35. package/dist/mcp/index.mjs.map +1 -1
  36. package/dist/message/index.d.mts +3 -2
  37. package/dist/message/index.d.ts +3 -2
  38. package/dist/message/index.js +204 -5
  39. package/dist/message/index.js.map +1 -1
  40. package/dist/message/index.mjs +200 -5
  41. package/dist/message/index.mjs.map +1 -1
  42. package/dist/message-CPZd0NIc.d.ts +133 -0
  43. package/dist/message-DgpfAaHK.d.mts +133 -0
  44. package/dist/model/index.d.mts +6 -5
  45. package/dist/model/index.d.ts +6 -5
  46. package/dist/model/index.js +39 -28
  47. package/dist/model/index.js.map +1 -1
  48. package/dist/model/index.mjs +39 -28
  49. package/dist/model/index.mjs.map +1 -1
  50. package/dist/storage/index.d.mts +4 -3
  51. package/dist/storage/index.d.ts +4 -3
  52. package/dist/storage/index.js +4 -4
  53. package/dist/storage/index.js.map +1 -1
  54. package/dist/storage/index.mjs +4 -4
  55. package/dist/storage/index.mjs.map +1 -1
  56. package/dist/tool/index.d.mts +4 -4
  57. package/dist/tool/index.d.ts +4 -4
  58. package/dist/{toolkit-CEpulFi0.d.ts → toolkit-DeOlul5Y.d.ts} +2 -2
  59. package/dist/{toolkit-CGEZSZPa.d.mts → toolkit-jwe7NmVJ.d.mts} +2 -2
  60. package/package.json +87 -87
  61. package/src/agent/agent.test.ts +104 -71
  62. package/src/agent/agent.ts +112 -104
  63. package/src/agent/test-compression.ts +1 -1
  64. package/src/event/index.ts +96 -98
  65. package/src/formatter/base.ts +3 -3
  66. package/src/formatter/dashscope-chat-formatter.test.ts +11 -8
  67. package/src/formatter/dashscope-chat-formatter.ts +3 -3
  68. package/src/formatter/openai-chat-formatter.test.ts +13 -5
  69. package/src/formatter/openai-chat-formatter.ts +6 -6
  70. package/src/mcp/base.ts +1 -1
  71. package/src/mcp/http.test.ts +2 -0
  72. package/src/mcp/stdio.test.ts +1 -0
  73. package/src/message/append-event.test.ts +783 -0
  74. package/src/message/block.ts +8 -4
  75. package/src/message/index.ts +12 -1
  76. package/src/message/message.test.ts +3 -1
  77. package/src/message/message.ts +310 -47
  78. package/src/model/dashscope-model.test.ts +4 -0
  79. package/src/model/dashscope-model.ts +3 -0
  80. package/src/model/deepseek-model.test.ts +2 -0
  81. package/src/model/deepseek-model.ts +3 -0
  82. package/src/model/ollama-model.test.ts +1 -0
  83. package/src/model/ollama-model.ts +2 -0
  84. package/src/model/openai-model.ts +3 -0
  85. package/src/permission/index.ts +13 -0
  86. package/src/storage/file-system.test.ts +4 -3
  87. package/src/storage/file-system.ts +4 -4
  88. package/src/tool/toolkit.test.ts +12 -0
  89. package/dist/message-CkN21KaY.d.mts +0 -99
  90. package/dist/message-CzLeTlua.d.ts +0 -99
@@ -1,5 +1,5 @@
1
- import { M as Msg } from './message-CkN21KaY.mjs';
2
- import { T as TextBlock, D as DataBlock } from './block-VsnHrllL.mjs';
1
+ import { M as Msg } from './message-DgpfAaHK.mjs';
2
+ import { T as TextBlock, D as DataBlock } from './block-B72uPF1H.mjs';
3
3
 
4
4
  /**
5
5
  * Base class for message formatters.
@@ -1,8 +1,8 @@
1
1
  import { z } from 'zod';
2
2
  import { J as JSONSerializableObject, T as ToolSchema, a as ToolChoice } from './index-CAxQAkiP.mjs';
3
- import { T as TextBlock, b as ToolCallBlock, a as ThinkingBlock, D as DataBlock } from './block-VsnHrllL.mjs';
4
- import { F as FormatterBase } from './base-BOx3UzOl.mjs';
5
- import { M as Msg } from './message-CkN21KaY.mjs';
3
+ import { T as TextBlock, b as ToolCallBlock, a as ThinkingBlock, D as DataBlock } from './block-B72uPF1H.mjs';
4
+ import { F as FormatterBase } from './base-1YVBgB4n.mjs';
5
+ import { M as Msg } from './message-DgpfAaHK.mjs';
6
6
 
7
7
  /**
8
8
  * The usage structure for chat models.
@@ -1,8 +1,8 @@
1
1
  import { z } from 'zod';
2
2
  import { J as JSONSerializableObject, T as ToolSchema, a as ToolChoice } from './index-CAxQAkiP.js';
3
- import { T as TextBlock, b as ToolCallBlock, a as ThinkingBlock, D as DataBlock } from './block-VsnHrllL.js';
4
- import { F as FormatterBase } from './base-BoIps2RL.js';
5
- import { M as Msg } from './message-CzLeTlua.js';
3
+ import { T as TextBlock, b as ToolCallBlock, a as ThinkingBlock, D as DataBlock } from './block-B72uPF1H.js';
4
+ import { F as FormatterBase } from './base-ChWjyzPL.js';
5
+ import { M as Msg } from './message-CPZd0NIc.js';
6
6
 
7
7
  /**
8
8
  * The usage structure for chat models.
@@ -1,4 +1,4 @@
1
- import { M as Msg } from './message-CzLeTlua.js';
1
+ import { M as Msg } from './message-CPZd0NIc.js';
2
2
 
3
3
  /**
4
4
  * The complete agent state including both conversation context and metadata.
@@ -1,5 +1,5 @@
1
- import { M as Msg } from './message-CzLeTlua.js';
2
- import { T as TextBlock, D as DataBlock } from './block-VsnHrllL.js';
1
+ import { M as Msg } from './message-CPZd0NIc.js';
2
+ import { T as TextBlock, D as DataBlock } from './block-B72uPF1H.js';
3
3
 
4
4
  /**
5
5
  * Base class for message formatters.
@@ -1,4 +1,4 @@
1
- import { M as Msg } from './message-CkN21KaY.mjs';
1
+ import { M as Msg } from './message-DgpfAaHK.mjs';
2
2
 
3
3
  /**
4
4
  * The complete agent state including both conversation context and metadata.
@@ -13,29 +13,31 @@ interface HintBlock {
13
13
  hint: string;
14
14
  id: string;
15
15
  }
16
+ type ToolCallState = 'pending' | 'asking' | 'allowed' | 'submitted' | 'finished';
16
17
  interface ToolCallBlock {
17
18
  type: 'tool_call';
18
19
  name: string;
19
20
  id: string;
20
21
  input: string;
21
- awaitUserConfirmation?: boolean;
22
+ state: ToolCallState;
22
23
  }
24
+ type ToolResultState = 'success' | 'error' | 'interrupted' | 'denied' | 'running';
23
25
  interface ToolResultBlock {
24
26
  type: 'tool_result';
25
27
  id: string;
26
28
  name: string;
27
29
  output: string | (TextBlock | DataBlock)[];
28
- state: 'success' | 'error' | 'interrupted' | 'running';
30
+ state: ToolResultState;
29
31
  }
30
32
  interface Base64Source {
31
33
  type: 'base64';
32
34
  data: string;
33
- mediaType: string;
35
+ media_type: string;
34
36
  }
35
37
  interface URLSource {
36
38
  type: 'url';
37
39
  url: string;
38
- mediaType: string;
40
+ media_type: string;
39
41
  }
40
42
  interface DataBlock {
41
43
  type: 'data';
@@ -45,4 +47,4 @@ interface DataBlock {
45
47
  }
46
48
  type ContentBlock = TextBlock | ThinkingBlock | HintBlock | ToolCallBlock | ToolResultBlock | DataBlock;
47
49
 
48
- export type { Base64Source as B, ContentBlock as C, DataBlock as D, TextBlock as T, URLSource as U, ThinkingBlock as a, ToolCallBlock as b, ToolResultBlock as c };
50
+ export type { Base64Source as B, ContentBlock as C, DataBlock as D, TextBlock as T, URLSource as U, ThinkingBlock as a, ToolCallBlock as b, ToolCallState as c, ToolResultBlock as d, ToolResultState as e };
@@ -13,29 +13,31 @@ interface HintBlock {
13
13
  hint: string;
14
14
  id: string;
15
15
  }
16
+ type ToolCallState = 'pending' | 'asking' | 'allowed' | 'submitted' | 'finished';
16
17
  interface ToolCallBlock {
17
18
  type: 'tool_call';
18
19
  name: string;
19
20
  id: string;
20
21
  input: string;
21
- awaitUserConfirmation?: boolean;
22
+ state: ToolCallState;
22
23
  }
24
+ type ToolResultState = 'success' | 'error' | 'interrupted' | 'denied' | 'running';
23
25
  interface ToolResultBlock {
24
26
  type: 'tool_result';
25
27
  id: string;
26
28
  name: string;
27
29
  output: string | (TextBlock | DataBlock)[];
28
- state: 'success' | 'error' | 'interrupted' | 'running';
30
+ state: ToolResultState;
29
31
  }
30
32
  interface Base64Source {
31
33
  type: 'base64';
32
34
  data: string;
33
- mediaType: string;
35
+ media_type: string;
34
36
  }
35
37
  interface URLSource {
36
38
  type: 'url';
37
39
  url: string;
38
- mediaType: string;
40
+ media_type: string;
39
41
  }
40
42
  interface DataBlock {
41
43
  type: 'data';
@@ -45,4 +47,4 @@ interface DataBlock {
45
47
  }
46
48
  type ContentBlock = TextBlock | ThinkingBlock | HintBlock | ToolCallBlock | ToolResultBlock | DataBlock;
47
49
 
48
- export type { Base64Source as B, ContentBlock as C, DataBlock as D, TextBlock as T, URLSource as U, ThinkingBlock as a, ToolCallBlock as b, ToolResultBlock as c };
50
+ export type { Base64Source as B, ContentBlock as C, DataBlock as D, TextBlock as T, URLSource as U, ThinkingBlock as a, ToolCallBlock as b, ToolCallState as c, ToolResultBlock as d, ToolResultState as e };
@@ -1,16 +1,29 @@
1
- import { b as ToolCallBlock, c as ToolResultBlock } from '../block-VsnHrllL.mjs';
1
+ import { b as ToolCallBlock, d as ToolResultBlock } from '../block-B72uPF1H.mjs';
2
+
3
+ declare enum PermissionBehavior {
4
+ ALLOW = "allow",
5
+ DENY = "deny",
6
+ ASK = "ask",
7
+ PASSTHROUGH = "passthrough"
8
+ }
9
+ interface PermissionRule {
10
+ tool_name: string;
11
+ rule_content: string | null;
12
+ behavior: PermissionBehavior;
13
+ source: string;
14
+ }
2
15
 
3
16
  declare enum EventType {
4
- RUN_STARTED = "RUN_STARTED",
5
- RUN_FINISHED = "RUN_FINISHED",
6
- MODEL_CALL_STARTED = "MODEL_CALL_STARTED",
7
- MODEL_CALL_ENDED = "MODEL_CALL_ENDED",
17
+ REPLY_START = "REPLY_START",
18
+ REPLY_END = "REPLY_END",
19
+ MODEL_CALL_START = "MODEL_CALL_START",
20
+ MODEL_CALL_END = "MODEL_CALL_END",
8
21
  TEXT_BLOCK_START = "TEXT_BLOCK_START",
9
22
  TEXT_BLOCK_DELTA = "TEXT_BLOCK_DELTA",
10
23
  TEXT_BLOCK_END = "TEXT_BLOCK_END",
11
- BINARY_BLOCK_START = "BINARY_BLOCK_START",
12
- BINARY_BLOCK_DELTA = "BINARY_BLOCK_DELTA",
13
- BINARY_BLOCK_END = "BINARY_BLOCK_END",
24
+ DATA_BLOCK_START = "DATA_BLOCK_START",
25
+ DATA_BLOCK_DELTA = "DATA_BLOCK_DELTA",
26
+ DATA_BLOCK_END = "DATA_BLOCK_END",
14
27
  THINKING_BLOCK_START = "THINKING_BLOCK_START",
15
28
  THINKING_BLOCK_DELTA = "THINKING_BLOCK_DELTA",
16
29
  THINKING_BLOCK_END = "THINKING_BLOCK_END",
@@ -19,7 +32,7 @@ declare enum EventType {
19
32
  TOOL_CALL_END = "TOOL_CALL_END",
20
33
  TOOL_RESULT_START = "TOOL_RESULT_START",
21
34
  TOOL_RESULT_TEXT_DELTA = "TOOL_RESULT_TEXT_DELTA",
22
- TOOL_RESULT_BINARY_DELTA = "TOOL_RESULT_BINARY_DELTA",
35
+ TOOL_RESULT_DATA_DELTA = "TOOL_RESULT_DATA_DELTA",
23
36
  TOOL_RESULT_END = "TOOL_RESULT_END",
24
37
  EXCEED_MAX_ITERS = "EXCEED_MAX_ITERS",
25
38
  REQUIRE_USER_CONFIRM = "REQUIRE_USER_CONFIRM",
@@ -29,153 +42,156 @@ declare enum EventType {
29
42
  }
30
43
  interface EventBase {
31
44
  id: string;
32
- createdAt: string;
45
+ created_at: string;
33
46
  }
34
- interface RunStartedEvent extends EventBase {
35
- type: EventType.RUN_STARTED;
36
- sessionId: string;
37
- replyId: string;
47
+ interface ReplyStartEvent extends EventBase {
48
+ type: EventType.REPLY_START;
49
+ session_id: string;
50
+ reply_id: string;
38
51
  name: string;
39
52
  role: 'user' | 'assistant' | 'system';
40
53
  }
41
- interface RunFinishedEvent extends EventBase {
42
- type: EventType.RUN_FINISHED;
43
- sessionId: string;
44
- replyId: string;
54
+ interface ReplyEndEvent extends EventBase {
55
+ type: EventType.REPLY_END;
56
+ session_id: string;
57
+ reply_id: string;
45
58
  }
46
- interface ModelCallStartedEvent extends EventBase {
47
- type: EventType.MODEL_CALL_STARTED;
48
- replyId: string;
49
- modelName: string;
59
+ interface ModelCallStartEvent extends EventBase {
60
+ type: EventType.MODEL_CALL_START;
61
+ reply_id: string;
62
+ model_name: string;
50
63
  }
51
- interface ModelCallEndedEvent extends EventBase {
52
- type: EventType.MODEL_CALL_ENDED;
53
- replyId: string;
54
- inputTokens: number;
55
- outputTokens: number;
64
+ interface ModelCallEndEvent extends EventBase {
65
+ type: EventType.MODEL_CALL_END;
66
+ reply_id: string;
67
+ input_tokens: number;
68
+ output_tokens: number;
56
69
  }
57
70
  interface TextBlockStartEvent extends EventBase {
58
71
  type: EventType.TEXT_BLOCK_START;
59
- blockId: string;
60
- replyId: string;
72
+ block_id: string;
73
+ reply_id: string;
61
74
  }
62
75
  interface TextBlockDeltaEvent extends EventBase {
63
76
  type: EventType.TEXT_BLOCK_DELTA;
64
- replyId: string;
65
- blockId: string;
77
+ reply_id: string;
78
+ block_id: string;
66
79
  delta: string;
67
80
  }
68
81
  interface TextBlockEndEvent extends EventBase {
69
82
  type: EventType.TEXT_BLOCK_END;
70
- replyId: string;
71
- blockId: string;
72
- }
73
- interface BinaryBlockStartEvent extends EventBase {
74
- type: EventType.BINARY_BLOCK_START;
75
- replyId: string;
76
- blockId: string;
77
- mediaType: string;
78
- }
79
- interface BinaryBlockDeltaEvent extends EventBase {
80
- type: EventType.BINARY_BLOCK_DELTA;
81
- replyId: string;
82
- blockId: string;
83
+ reply_id: string;
84
+ block_id: string;
85
+ }
86
+ interface DataBlockStartEvent extends EventBase {
87
+ type: EventType.DATA_BLOCK_START;
88
+ reply_id: string;
89
+ block_id: string;
90
+ media_type: string;
91
+ }
92
+ interface DataBlockDeltaEvent extends EventBase {
93
+ type: EventType.DATA_BLOCK_DELTA;
94
+ reply_id: string;
95
+ block_id: string;
83
96
  data: string;
84
- mediaType: string;
97
+ media_type: string;
85
98
  }
86
- interface BinaryBlockEndEvent extends EventBase {
87
- type: EventType.BINARY_BLOCK_END;
88
- replyId: string;
89
- blockId: string;
99
+ interface DataBlockEndEvent extends EventBase {
100
+ type: EventType.DATA_BLOCK_END;
101
+ reply_id: string;
102
+ block_id: string;
90
103
  }
91
104
  interface ThinkingBlockStartEvent extends EventBase {
92
105
  type: EventType.THINKING_BLOCK_START;
93
- replyId: string;
94
- blockId: string;
106
+ reply_id: string;
107
+ block_id: string;
95
108
  }
96
109
  interface ThinkingBlockDeltaEvent extends EventBase {
97
110
  type: EventType.THINKING_BLOCK_DELTA;
98
- replyId: string;
99
- blockId: string;
111
+ reply_id: string;
112
+ block_id: string;
100
113
  delta: string;
101
114
  }
102
115
  interface ThinkingBlockEndEvent extends EventBase {
103
116
  type: EventType.THINKING_BLOCK_END;
104
- replyId: string;
105
- blockId: string;
117
+ reply_id: string;
118
+ block_id: string;
106
119
  }
107
120
  interface ToolCallStartEvent extends EventBase {
108
121
  type: EventType.TOOL_CALL_START;
109
- replyId: string;
110
- toolCallId: string;
111
- toolCallName: string;
122
+ reply_id: string;
123
+ tool_call_id: string;
124
+ tool_call_name: string;
112
125
  }
113
126
  interface ToolCallDeltaEvent extends EventBase {
114
127
  type: EventType.TOOL_CALL_DELTA;
115
- replyId: string;
116
- toolCallId: string;
128
+ reply_id: string;
129
+ tool_call_id: string;
117
130
  delta: string;
118
131
  }
119
132
  interface ToolCallEndEvent extends EventBase {
120
133
  type: EventType.TOOL_CALL_END;
121
- replyId: string;
122
- toolCallId: string;
134
+ reply_id: string;
135
+ tool_call_id: string;
123
136
  }
124
137
  interface ToolResultStartEvent extends EventBase {
125
138
  type: EventType.TOOL_RESULT_START;
126
- replyId: string;
127
- toolCallId: string;
128
- toolCallName: string;
139
+ reply_id: string;
140
+ tool_call_id: string;
141
+ tool_call_name: string;
129
142
  }
130
143
  interface ToolResultTextDeltaEvent extends EventBase {
131
144
  type: EventType.TOOL_RESULT_TEXT_DELTA;
132
- replyId: string;
133
- toolCallId: string;
145
+ reply_id: string;
146
+ tool_call_id: string;
147
+ block_id: string;
134
148
  delta: string;
135
149
  }
136
- interface ToolResultBinaryDeltaEvent extends EventBase {
137
- type: EventType.TOOL_RESULT_BINARY_DELTA;
138
- replyId: string;
139
- toolCallId: string;
140
- mediaType: string;
150
+ interface ToolResultDataDeltaEvent extends EventBase {
151
+ type: EventType.TOOL_RESULT_DATA_DELTA;
152
+ reply_id: string;
153
+ tool_call_id: string;
154
+ block_id: string;
155
+ media_type: string;
141
156
  data?: string;
142
157
  url?: string;
143
158
  }
144
159
  interface ToolResultEndEvent extends EventBase {
145
160
  type: EventType.TOOL_RESULT_END;
146
- replyId: string;
147
- toolCallId: string;
161
+ reply_id: string;
162
+ tool_call_id: string;
148
163
  state: ToolResultBlock['state'];
149
164
  }
150
165
  interface ExceedMaxItersEvent extends EventBase {
151
166
  type: EventType.EXCEED_MAX_ITERS;
152
- replyId: string;
153
- agentId: string;
167
+ reply_id: string;
154
168
  name: string;
155
169
  }
156
170
  interface RequireUserConfirmEvent extends EventBase {
157
171
  type: EventType.REQUIRE_USER_CONFIRM;
158
- replyId: string;
159
- toolCalls: ToolCallBlock[];
172
+ reply_id: string;
173
+ tool_calls: ToolCallBlock[];
160
174
  }
161
175
  interface RequireExternalExecutionEvent extends EventBase {
162
176
  type: EventType.REQUIRE_EXTERNAL_EXECUTION;
163
- replyId: string;
164
- toolCalls: ToolCallBlock[];
177
+ reply_id: string;
178
+ tool_calls: ToolCallBlock[];
179
+ }
180
+ interface ConfirmResult {
181
+ confirmed: boolean;
182
+ tool_call: ToolCallBlock;
183
+ rules?: PermissionRule[] | null;
165
184
  }
166
185
  interface UserConfirmResultEvent extends EventBase {
167
186
  type: EventType.USER_CONFIRM_RESULT;
168
- replyId: string;
169
- confirmResults: {
170
- confirmed: boolean;
171
- toolCall: ToolCallBlock;
172
- }[];
187
+ reply_id: string;
188
+ confirm_results: ConfirmResult[];
173
189
  }
174
190
  interface ExternalExecutionResultEvent extends EventBase {
175
191
  type: EventType.EXTERNAL_EXECUTION_RESULT;
176
- replyId: string;
177
- executionResults: ToolResultBlock[];
192
+ reply_id: string;
193
+ execution_results: ToolResultBlock[];
178
194
  }
179
- type AgentEvent = RunStartedEvent | RunFinishedEvent | ExceedMaxItersEvent | RequireUserConfirmEvent | RequireExternalExecutionEvent | ModelCallStartedEvent | ModelCallEndedEvent | TextBlockStartEvent | TextBlockDeltaEvent | TextBlockEndEvent | BinaryBlockStartEvent | BinaryBlockDeltaEvent | BinaryBlockEndEvent | ThinkingBlockStartEvent | ThinkingBlockDeltaEvent | ThinkingBlockEndEvent | ToolCallStartEvent | ToolCallDeltaEvent | ToolCallEndEvent | ToolResultStartEvent | ToolResultTextDeltaEvent | ToolResultBinaryDeltaEvent | ToolResultEndEvent | UserConfirmResultEvent | ExternalExecutionResultEvent;
195
+ type AgentEvent = ReplyStartEvent | ReplyEndEvent | ExceedMaxItersEvent | RequireUserConfirmEvent | RequireExternalExecutionEvent | ModelCallStartEvent | ModelCallEndEvent | TextBlockStartEvent | TextBlockDeltaEvent | TextBlockEndEvent | DataBlockStartEvent | DataBlockDeltaEvent | DataBlockEndEvent | ThinkingBlockStartEvent | ThinkingBlockDeltaEvent | ThinkingBlockEndEvent | ToolCallStartEvent | ToolCallDeltaEvent | ToolCallEndEvent | ToolResultStartEvent | ToolResultTextDeltaEvent | ToolResultDataDeltaEvent | ToolResultEndEvent | UserConfirmResultEvent | ExternalExecutionResultEvent;
180
196
 
181
- export { type AgentEvent, type BinaryBlockDeltaEvent, type BinaryBlockEndEvent, type BinaryBlockStartEvent, type EventBase, EventType, type ExceedMaxItersEvent, type ExternalExecutionResultEvent, type ModelCallEndedEvent, type ModelCallStartedEvent, type RequireExternalExecutionEvent, type RequireUserConfirmEvent, type RunFinishedEvent, type RunStartedEvent, type TextBlockDeltaEvent, type TextBlockEndEvent, type TextBlockStartEvent, type ThinkingBlockDeltaEvent, type ThinkingBlockEndEvent, type ThinkingBlockStartEvent, type ToolCallDeltaEvent, type ToolCallEndEvent, type ToolCallStartEvent, type ToolResultBinaryDeltaEvent, type ToolResultEndEvent, type ToolResultStartEvent, type ToolResultTextDeltaEvent, type UserConfirmResultEvent };
197
+ export { type AgentEvent, type ConfirmResult, type DataBlockDeltaEvent, type DataBlockEndEvent, type DataBlockStartEvent, type EventBase, EventType, type ExceedMaxItersEvent, type ExternalExecutionResultEvent, type ModelCallEndEvent, type ModelCallStartEvent, type ReplyEndEvent, type ReplyStartEvent, type RequireExternalExecutionEvent, type RequireUserConfirmEvent, type TextBlockDeltaEvent, type TextBlockEndEvent, type TextBlockStartEvent, type ThinkingBlockDeltaEvent, type ThinkingBlockEndEvent, type ThinkingBlockStartEvent, type ToolCallDeltaEvent, type ToolCallEndEvent, type ToolCallStartEvent, type ToolResultDataDeltaEvent, type ToolResultEndEvent, type ToolResultStartEvent, type ToolResultTextDeltaEvent, type UserConfirmResultEvent };