@xpert-ai/contracts 3.19.0 → 3.21.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/index.cjs.js +425 -20
- package/index.esm.js +372 -22
- package/package.json +5 -2
- package/src/agent/ai-model.d.ts +1 -0
- package/src/agent/token.d.ts +4 -0
- package/src/ai/agent-output-delivery.model.d.ts +31 -0
- package/src/ai/agent-runtime.model.d.ts +53 -0
- package/src/ai/ai-model.model.d.ts +3 -0
- package/src/ai/assistant-binding.model.d.ts +3 -0
- package/src/ai/assistant-configuration.model.d.ts +31 -0
- package/src/ai/bosi.model.d.ts +73 -0
- package/src/ai/chat-group-entity.model.d.ts +93 -0
- package/src/ai/chat-group.model.d.ts +298 -0
- package/src/ai/chat-message-envelope.model.d.ts +55 -0
- package/src/ai/chat-message.model.d.ts +10 -0
- package/src/ai/chat.model.d.ts +26 -0
- package/src/ai/conversation-entry.model.d.ts +18 -0
- package/src/ai/execution-activity.model.d.ts +547 -0
- package/src/ai/index.d.ts +11 -0
- package/src/ai/mcp-capability.model.d.ts +5 -1
- package/src/ai/membership.model.d.ts +5 -0
- package/src/ai/model-execution.model.d.ts +265 -0
- package/src/ai/model-gateway.model.d.ts +15 -3
- package/src/ai/model-usage.model.d.ts +19 -0
- package/src/ai/project-task-graph.model.d.ts +12 -0
- package/src/ai/project-task-runtime.model.d.ts +1106 -0
- package/src/ai/project-task-type.model.d.ts +13 -0
- package/src/ai/prompt-workflow.model.d.ts +4 -0
- package/src/ai/realtime-voice.model.d.ts +90 -0
- package/src/ai/realtime-voice.transport.d.ts +54 -0
- package/src/ai/resource-card.d.ts +2 -0
- package/src/ai/sandbox-terminal.model.d.ts +1 -0
- package/src/ai/thread-activity.model.d.ts +14 -0
- package/src/ai/xpert-agent-execution.model.d.ts +4 -0
- package/src/ai/xpert-project.model.d.ts +21 -0
- package/src/ai/xpert-template.model.d.ts +23 -5
- package/src/ai/xpert-tool-mcp.model.d.ts +6 -0
- package/src/ai/xpert.model.d.ts +7 -2
- package/src/api-key.model.d.ts +37 -2
- package/src/default-agent-plugins.d.ts +19 -0
- package/src/i18n.model.d.ts +1 -0
- package/src/index.d.ts +5 -0
- package/src/plugin-application.d.ts +256 -0
- package/src/plugin-management.d.ts +112 -0
- package/src/plugin.d.ts +3 -319
- package/src/runtime-control.d.ts +13 -0
- package/src/secret-token.model.d.ts +8 -1
- package/src/setup-plugins.d.ts +75 -0
- package/src/types.d.ts +4 -0
- package/src/view-extension/model.d.ts +22 -1
- package/src/view-extension/workbench.d.ts +6 -2
|
@@ -6,6 +6,7 @@ import { LongTermMemoryTypeEnum } from './xpert.model';
|
|
|
6
6
|
import { IXpertAgentExecution, XpertAgentExecutionStatusEnum } from './xpert-agent-execution.model';
|
|
7
7
|
import { JSONValue } from '../core.model';
|
|
8
8
|
import { IStorageFile } from '../storage-file.model';
|
|
9
|
+
import type { TChatMessageEnvelope } from './chat-message-envelope.model';
|
|
9
10
|
export type TSummaryJob = Record<LongTermMemoryTypeEnum, {
|
|
10
11
|
jobId: number | string;
|
|
11
12
|
status: string;
|
|
@@ -52,10 +53,19 @@ export type TChatFileElementReference = ChatKitReferenceBase & TChatFileElementR
|
|
|
52
53
|
type: 'file_element';
|
|
53
54
|
};
|
|
54
55
|
export type TChatReference = ChatKitReference | TChatElementReference | TChatFileElementReference;
|
|
56
|
+
export * from './chat-message-envelope.model';
|
|
55
57
|
/**
|
|
56
58
|
* Chat message entity type
|
|
57
59
|
*/
|
|
58
60
|
export interface IChatMessage extends IBasePerTenantAndOrganizationEntityModel, Omit<Omit<CopilotBaseMessage, 'createdAt'>, 'id'> {
|
|
61
|
+
/**
|
|
62
|
+
* Server-assigned order within a conversation using sequenced messages (currently group chat).
|
|
63
|
+
* Stable across message updates; use for ordering/history cursors, not identity or cross-thread order.
|
|
64
|
+
* Optional for legacy/unsequenced messages; distinct from the conversation's state revision.
|
|
65
|
+
*/
|
|
66
|
+
sequence?: number;
|
|
67
|
+
/** Persisted host-owned provenance; read-only through public message APIs. */
|
|
68
|
+
messageEnvelope?: TChatMessageEnvelope | null;
|
|
59
69
|
parent?: IChatMessage | null;
|
|
60
70
|
children?: IChatMessage[];
|
|
61
71
|
parentId?: string | null;
|
package/src/ai/chat.model.d.ts
CHANGED
|
@@ -14,6 +14,13 @@ import { TInterrupt } from '../agent/interrupt';
|
|
|
14
14
|
import { IUser } from '../user.model';
|
|
15
15
|
import type { RuntimeCapabilitiesSelection } from '@xpert-ai/chatkit-types';
|
|
16
16
|
export type TChatConversationOptions = {
|
|
17
|
+
/** First Project binding is deferred until a human submits the application's setup App. */
|
|
18
|
+
projectCreation?: {
|
|
19
|
+
status: 'awaiting_confirmation';
|
|
20
|
+
} | {
|
|
21
|
+
status: 'confirmed';
|
|
22
|
+
confirmationId: string;
|
|
23
|
+
};
|
|
17
24
|
/** Preserve an explicit no-Project choice across reloads and subsequent sends. */
|
|
18
25
|
projectSelection?: import('./project-selection.model').ProjectSelection;
|
|
19
26
|
/** Persisted resources augment the entry Agent without changing the Assistant graph. */
|
|
@@ -104,6 +111,7 @@ export type TChatMessageBranching = {
|
|
|
104
111
|
available: boolean;
|
|
105
112
|
reason?: TChatMessageBranchUnavailableReason;
|
|
106
113
|
};
|
|
114
|
+
/** @deprecated Legacy presentation metadata. Run control no longer stores or returns display snapshots. */
|
|
107
115
|
export type TChatThreadDisplayPause = {
|
|
108
116
|
executionId: string;
|
|
109
117
|
pauseId: string;
|
|
@@ -125,6 +133,8 @@ export declare const ChatThreadPurpose: {
|
|
|
125
133
|
export type TChatThreadPurpose = (typeof ChatThreadPurpose)[keyof typeof ChatThreadPurpose];
|
|
126
134
|
/** Machine-readable keys stored in `ChatConversationThread.metadata`. */
|
|
127
135
|
export type TChatThreadMetadata = {
|
|
136
|
+
/** User-editable branch label, independent of the conversation title. */
|
|
137
|
+
title?: string;
|
|
128
138
|
primary?: boolean;
|
|
129
139
|
purpose?: TChatThreadPurpose;
|
|
130
140
|
/** Graph revision the edited input was captured on; cleared after the first successful run. */
|
|
@@ -166,6 +176,22 @@ export type TSensitiveOperation = {
|
|
|
166
176
|
* Corresponds to the thread in the [Agent Protocol](https://github.com/langchain-ai/agent-protocol).
|
|
167
177
|
*/
|
|
168
178
|
export interface IChatConversation extends IBasePerTenantAndOrganizationEntityModel {
|
|
179
|
+
/**
|
|
180
|
+
* `private`: ordinary chat; `group`: shared public transcript; `group_assistant_runtime`:
|
|
181
|
+
* one member Assistant's isolated execution history. Optional for legacy DTOs (treated as private).
|
|
182
|
+
* Group xpertId identifies the primary Assistant; runtime records require separate access checks.
|
|
183
|
+
*/
|
|
184
|
+
purpose?: 'private' | 'group' | 'group_assistant_runtime';
|
|
185
|
+
/**
|
|
186
|
+
* Server-maintained state version, currently used by group snapshots. Also advances for updates
|
|
187
|
+
* that append no message (e.g. membership/delivery changes); not a count, sequence or replay cursor.
|
|
188
|
+
*/
|
|
189
|
+
revision?: number;
|
|
190
|
+
/**
|
|
191
|
+
* Highest server-allocated message sequence in this conversation (zero before the first allocation).
|
|
192
|
+
* Used for ordering/read positions, not the number of retained messages; updates reuse their sequence.
|
|
193
|
+
*/
|
|
194
|
+
lastMessageSequence?: number;
|
|
169
195
|
branchSource?: TConversationBranchSource | null;
|
|
170
196
|
/**
|
|
171
197
|
* Non-persistent, response-only field populated by the sidebar endpoint.
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Authorized metadata for opening a conversation in the shared ChatKit shell.
|
|
3
|
+
* Select the private/group adapter by purpose, not by title, route text or the presence of xpertId.
|
|
4
|
+
* Excludes messages and runtime configuration; group Assistant runtimes are opened through their
|
|
5
|
+
* separately authorized execution view, never as a third top-level chat adapter here.
|
|
6
|
+
*/
|
|
7
|
+
export interface ChatConversationEntry {
|
|
8
|
+
/** ChatConversation ID; for group entries this is also the API groupId. */
|
|
9
|
+
id: string;
|
|
10
|
+
/** Thread belonging to this conversation; not a group member's separate runtime thread. */
|
|
11
|
+
threadId: string;
|
|
12
|
+
/** Owning Xpert ID for private chat or primary Assistant's Xpert ID for a group; null when unbound. */
|
|
13
|
+
xpertId: string | null;
|
|
14
|
+
/** Display title; clients may provide a localized fallback when absent. */
|
|
15
|
+
title: string | null;
|
|
16
|
+
/** Server-resolved adapter discriminator; internal group_assistant_runtime records are excluded. */
|
|
17
|
+
purpose: 'private' | 'group';
|
|
18
|
+
}
|
|
@@ -0,0 +1,547 @@
|
|
|
1
|
+
import { z } from 'zod/v3';
|
|
2
|
+
export declare const codingExecutionViewKey = "platform.coding-execution__execution";
|
|
3
|
+
export declare const executionActivityCapabilitiesSchema: z.ZodObject<{
|
|
4
|
+
version: z.ZodLiteral<1>;
|
|
5
|
+
presentation: z.ZodLiteral<"coding">;
|
|
6
|
+
}, "strict", z.ZodTypeAny, {
|
|
7
|
+
version?: 1;
|
|
8
|
+
presentation?: "coding";
|
|
9
|
+
}, {
|
|
10
|
+
version?: 1;
|
|
11
|
+
presentation?: "coding";
|
|
12
|
+
}>;
|
|
13
|
+
export type ExecutionActivityCapabilities = z.infer<typeof executionActivityCapabilitiesSchema>;
|
|
14
|
+
export declare const executionActivityItemSchema: z.ZodObject<{
|
|
15
|
+
id: z.ZodString;
|
|
16
|
+
occurredAt: z.ZodOptional<z.ZodString>;
|
|
17
|
+
content: z.ZodDiscriminatedUnion<"kind", [z.ZodObject<{
|
|
18
|
+
kind: z.ZodLiteral<"message">;
|
|
19
|
+
text: z.ZodString;
|
|
20
|
+
}, "strict", z.ZodTypeAny, {
|
|
21
|
+
text?: string;
|
|
22
|
+
kind?: "message";
|
|
23
|
+
}, {
|
|
24
|
+
text?: string;
|
|
25
|
+
kind?: "message";
|
|
26
|
+
}>, z.ZodObject<{
|
|
27
|
+
kind: z.ZodLiteral<"tool">;
|
|
28
|
+
name: z.ZodOptional<z.ZodString>;
|
|
29
|
+
status: z.ZodEnum<["running", "succeeded", "failed", "unknown"]>;
|
|
30
|
+
input: z.ZodOptional<z.ZodString>;
|
|
31
|
+
output: z.ZodOptional<z.ZodString>;
|
|
32
|
+
truncated: z.ZodOptional<z.ZodBoolean>;
|
|
33
|
+
outputRef: z.ZodOptional<z.ZodObject<{
|
|
34
|
+
key: z.ZodString;
|
|
35
|
+
length: z.ZodNumber;
|
|
36
|
+
}, "strict", z.ZodTypeAny, {
|
|
37
|
+
length?: number;
|
|
38
|
+
key?: string;
|
|
39
|
+
}, {
|
|
40
|
+
length?: number;
|
|
41
|
+
key?: string;
|
|
42
|
+
}>>;
|
|
43
|
+
detail: z.ZodOptional<z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
|
|
44
|
+
type: z.ZodLiteral<"command">;
|
|
45
|
+
command: z.ZodString;
|
|
46
|
+
cwd: z.ZodOptional<z.ZodString>;
|
|
47
|
+
exitCode: z.ZodOptional<z.ZodNumber>;
|
|
48
|
+
outputMode: z.ZodLiteral<"merged">;
|
|
49
|
+
}, "strict", z.ZodTypeAny, {
|
|
50
|
+
type?: "command";
|
|
51
|
+
command?: string;
|
|
52
|
+
cwd?: string;
|
|
53
|
+
exitCode?: number;
|
|
54
|
+
outputMode?: "merged";
|
|
55
|
+
}, {
|
|
56
|
+
type?: "command";
|
|
57
|
+
command?: string;
|
|
58
|
+
cwd?: string;
|
|
59
|
+
exitCode?: number;
|
|
60
|
+
outputMode?: "merged";
|
|
61
|
+
}>, z.ZodObject<{
|
|
62
|
+
type: z.ZodLiteral<"file_change">;
|
|
63
|
+
files: z.ZodArray<z.ZodObject<{
|
|
64
|
+
path: z.ZodString;
|
|
65
|
+
change: z.ZodEnum<["created", "modified", "deleted", "reported"]>;
|
|
66
|
+
patch: z.ZodOptional<z.ZodString>;
|
|
67
|
+
}, "strict", z.ZodTypeAny, {
|
|
68
|
+
path?: string;
|
|
69
|
+
patch?: string;
|
|
70
|
+
change?: "created" | "deleted" | "modified" | "reported";
|
|
71
|
+
}, {
|
|
72
|
+
path?: string;
|
|
73
|
+
patch?: string;
|
|
74
|
+
change?: "created" | "deleted" | "modified" | "reported";
|
|
75
|
+
}>, "many">;
|
|
76
|
+
}, "strict", z.ZodTypeAny, {
|
|
77
|
+
type?: "file_change";
|
|
78
|
+
files?: {
|
|
79
|
+
path?: string;
|
|
80
|
+
patch?: string;
|
|
81
|
+
change?: "created" | "deleted" | "modified" | "reported";
|
|
82
|
+
}[];
|
|
83
|
+
}, {
|
|
84
|
+
type?: "file_change";
|
|
85
|
+
files?: {
|
|
86
|
+
path?: string;
|
|
87
|
+
patch?: string;
|
|
88
|
+
change?: "created" | "deleted" | "modified" | "reported";
|
|
89
|
+
}[];
|
|
90
|
+
}>]>>;
|
|
91
|
+
}, "strict", z.ZodTypeAny, {
|
|
92
|
+
status?: "succeeded" | "failed" | "running" | "unknown";
|
|
93
|
+
name?: string;
|
|
94
|
+
input?: string;
|
|
95
|
+
output?: string;
|
|
96
|
+
kind?: "tool";
|
|
97
|
+
detail?: {
|
|
98
|
+
type?: "command";
|
|
99
|
+
command?: string;
|
|
100
|
+
cwd?: string;
|
|
101
|
+
exitCode?: number;
|
|
102
|
+
outputMode?: "merged";
|
|
103
|
+
} | {
|
|
104
|
+
type?: "file_change";
|
|
105
|
+
files?: {
|
|
106
|
+
path?: string;
|
|
107
|
+
patch?: string;
|
|
108
|
+
change?: "created" | "deleted" | "modified" | "reported";
|
|
109
|
+
}[];
|
|
110
|
+
};
|
|
111
|
+
truncated?: boolean;
|
|
112
|
+
outputRef?: {
|
|
113
|
+
length?: number;
|
|
114
|
+
key?: string;
|
|
115
|
+
};
|
|
116
|
+
}, {
|
|
117
|
+
status?: "succeeded" | "failed" | "running" | "unknown";
|
|
118
|
+
name?: string;
|
|
119
|
+
input?: string;
|
|
120
|
+
output?: string;
|
|
121
|
+
kind?: "tool";
|
|
122
|
+
detail?: {
|
|
123
|
+
type?: "command";
|
|
124
|
+
command?: string;
|
|
125
|
+
cwd?: string;
|
|
126
|
+
exitCode?: number;
|
|
127
|
+
outputMode?: "merged";
|
|
128
|
+
} | {
|
|
129
|
+
type?: "file_change";
|
|
130
|
+
files?: {
|
|
131
|
+
path?: string;
|
|
132
|
+
patch?: string;
|
|
133
|
+
change?: "created" | "deleted" | "modified" | "reported";
|
|
134
|
+
}[];
|
|
135
|
+
};
|
|
136
|
+
truncated?: boolean;
|
|
137
|
+
outputRef?: {
|
|
138
|
+
length?: number;
|
|
139
|
+
key?: string;
|
|
140
|
+
};
|
|
141
|
+
}>, z.ZodObject<{
|
|
142
|
+
kind: z.ZodLiteral<"diagnostic">;
|
|
143
|
+
code: z.ZodString;
|
|
144
|
+
text: z.ZodString;
|
|
145
|
+
}, "strict", z.ZodTypeAny, {
|
|
146
|
+
code?: string;
|
|
147
|
+
text?: string;
|
|
148
|
+
kind?: "diagnostic";
|
|
149
|
+
}, {
|
|
150
|
+
code?: string;
|
|
151
|
+
text?: string;
|
|
152
|
+
kind?: "diagnostic";
|
|
153
|
+
}>]>;
|
|
154
|
+
}, "strict", z.ZodTypeAny, {
|
|
155
|
+
id?: string;
|
|
156
|
+
content?: {
|
|
157
|
+
text?: string;
|
|
158
|
+
kind?: "message";
|
|
159
|
+
} | {
|
|
160
|
+
status?: "succeeded" | "failed" | "running" | "unknown";
|
|
161
|
+
name?: string;
|
|
162
|
+
input?: string;
|
|
163
|
+
output?: string;
|
|
164
|
+
kind?: "tool";
|
|
165
|
+
detail?: {
|
|
166
|
+
type?: "command";
|
|
167
|
+
command?: string;
|
|
168
|
+
cwd?: string;
|
|
169
|
+
exitCode?: number;
|
|
170
|
+
outputMode?: "merged";
|
|
171
|
+
} | {
|
|
172
|
+
type?: "file_change";
|
|
173
|
+
files?: {
|
|
174
|
+
path?: string;
|
|
175
|
+
patch?: string;
|
|
176
|
+
change?: "created" | "deleted" | "modified" | "reported";
|
|
177
|
+
}[];
|
|
178
|
+
};
|
|
179
|
+
truncated?: boolean;
|
|
180
|
+
outputRef?: {
|
|
181
|
+
length?: number;
|
|
182
|
+
key?: string;
|
|
183
|
+
};
|
|
184
|
+
} | {
|
|
185
|
+
code?: string;
|
|
186
|
+
text?: string;
|
|
187
|
+
kind?: "diagnostic";
|
|
188
|
+
};
|
|
189
|
+
occurredAt?: string;
|
|
190
|
+
}, {
|
|
191
|
+
id?: string;
|
|
192
|
+
content?: {
|
|
193
|
+
text?: string;
|
|
194
|
+
kind?: "message";
|
|
195
|
+
} | {
|
|
196
|
+
status?: "succeeded" | "failed" | "running" | "unknown";
|
|
197
|
+
name?: string;
|
|
198
|
+
input?: string;
|
|
199
|
+
output?: string;
|
|
200
|
+
kind?: "tool";
|
|
201
|
+
detail?: {
|
|
202
|
+
type?: "command";
|
|
203
|
+
command?: string;
|
|
204
|
+
cwd?: string;
|
|
205
|
+
exitCode?: number;
|
|
206
|
+
outputMode?: "merged";
|
|
207
|
+
} | {
|
|
208
|
+
type?: "file_change";
|
|
209
|
+
files?: {
|
|
210
|
+
path?: string;
|
|
211
|
+
patch?: string;
|
|
212
|
+
change?: "created" | "deleted" | "modified" | "reported";
|
|
213
|
+
}[];
|
|
214
|
+
};
|
|
215
|
+
truncated?: boolean;
|
|
216
|
+
outputRef?: {
|
|
217
|
+
length?: number;
|
|
218
|
+
key?: string;
|
|
219
|
+
};
|
|
220
|
+
} | {
|
|
221
|
+
code?: string;
|
|
222
|
+
text?: string;
|
|
223
|
+
kind?: "diagnostic";
|
|
224
|
+
};
|
|
225
|
+
occurredAt?: string;
|
|
226
|
+
}>;
|
|
227
|
+
export type ExecutionActivityItem = z.infer<typeof executionActivityItemSchema>;
|
|
228
|
+
export declare const executionActivityBatchSchema: z.ZodObject<{
|
|
229
|
+
items: z.ZodArray<z.ZodObject<{
|
|
230
|
+
id: z.ZodString;
|
|
231
|
+
occurredAt: z.ZodOptional<z.ZodString>;
|
|
232
|
+
content: z.ZodDiscriminatedUnion<"kind", [z.ZodObject<{
|
|
233
|
+
kind: z.ZodLiteral<"message">;
|
|
234
|
+
text: z.ZodString;
|
|
235
|
+
}, "strict", z.ZodTypeAny, {
|
|
236
|
+
text?: string;
|
|
237
|
+
kind?: "message";
|
|
238
|
+
}, {
|
|
239
|
+
text?: string;
|
|
240
|
+
kind?: "message";
|
|
241
|
+
}>, z.ZodObject<{
|
|
242
|
+
kind: z.ZodLiteral<"tool">;
|
|
243
|
+
name: z.ZodOptional<z.ZodString>;
|
|
244
|
+
status: z.ZodEnum<["running", "succeeded", "failed", "unknown"]>;
|
|
245
|
+
input: z.ZodOptional<z.ZodString>;
|
|
246
|
+
output: z.ZodOptional<z.ZodString>;
|
|
247
|
+
truncated: z.ZodOptional<z.ZodBoolean>;
|
|
248
|
+
outputRef: z.ZodOptional<z.ZodObject<{
|
|
249
|
+
key: z.ZodString;
|
|
250
|
+
length: z.ZodNumber;
|
|
251
|
+
}, "strict", z.ZodTypeAny, {
|
|
252
|
+
length?: number;
|
|
253
|
+
key?: string;
|
|
254
|
+
}, {
|
|
255
|
+
length?: number;
|
|
256
|
+
key?: string;
|
|
257
|
+
}>>;
|
|
258
|
+
detail: z.ZodOptional<z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
|
|
259
|
+
type: z.ZodLiteral<"command">;
|
|
260
|
+
command: z.ZodString;
|
|
261
|
+
cwd: z.ZodOptional<z.ZodString>;
|
|
262
|
+
exitCode: z.ZodOptional<z.ZodNumber>;
|
|
263
|
+
outputMode: z.ZodLiteral<"merged">;
|
|
264
|
+
}, "strict", z.ZodTypeAny, {
|
|
265
|
+
type?: "command";
|
|
266
|
+
command?: string;
|
|
267
|
+
cwd?: string;
|
|
268
|
+
exitCode?: number;
|
|
269
|
+
outputMode?: "merged";
|
|
270
|
+
}, {
|
|
271
|
+
type?: "command";
|
|
272
|
+
command?: string;
|
|
273
|
+
cwd?: string;
|
|
274
|
+
exitCode?: number;
|
|
275
|
+
outputMode?: "merged";
|
|
276
|
+
}>, z.ZodObject<{
|
|
277
|
+
type: z.ZodLiteral<"file_change">;
|
|
278
|
+
files: z.ZodArray<z.ZodObject<{
|
|
279
|
+
path: z.ZodString;
|
|
280
|
+
change: z.ZodEnum<["created", "modified", "deleted", "reported"]>;
|
|
281
|
+
patch: z.ZodOptional<z.ZodString>;
|
|
282
|
+
}, "strict", z.ZodTypeAny, {
|
|
283
|
+
path?: string;
|
|
284
|
+
patch?: string;
|
|
285
|
+
change?: "created" | "deleted" | "modified" | "reported";
|
|
286
|
+
}, {
|
|
287
|
+
path?: string;
|
|
288
|
+
patch?: string;
|
|
289
|
+
change?: "created" | "deleted" | "modified" | "reported";
|
|
290
|
+
}>, "many">;
|
|
291
|
+
}, "strict", z.ZodTypeAny, {
|
|
292
|
+
type?: "file_change";
|
|
293
|
+
files?: {
|
|
294
|
+
path?: string;
|
|
295
|
+
patch?: string;
|
|
296
|
+
change?: "created" | "deleted" | "modified" | "reported";
|
|
297
|
+
}[];
|
|
298
|
+
}, {
|
|
299
|
+
type?: "file_change";
|
|
300
|
+
files?: {
|
|
301
|
+
path?: string;
|
|
302
|
+
patch?: string;
|
|
303
|
+
change?: "created" | "deleted" | "modified" | "reported";
|
|
304
|
+
}[];
|
|
305
|
+
}>]>>;
|
|
306
|
+
}, "strict", z.ZodTypeAny, {
|
|
307
|
+
status?: "succeeded" | "failed" | "running" | "unknown";
|
|
308
|
+
name?: string;
|
|
309
|
+
input?: string;
|
|
310
|
+
output?: string;
|
|
311
|
+
kind?: "tool";
|
|
312
|
+
detail?: {
|
|
313
|
+
type?: "command";
|
|
314
|
+
command?: string;
|
|
315
|
+
cwd?: string;
|
|
316
|
+
exitCode?: number;
|
|
317
|
+
outputMode?: "merged";
|
|
318
|
+
} | {
|
|
319
|
+
type?: "file_change";
|
|
320
|
+
files?: {
|
|
321
|
+
path?: string;
|
|
322
|
+
patch?: string;
|
|
323
|
+
change?: "created" | "deleted" | "modified" | "reported";
|
|
324
|
+
}[];
|
|
325
|
+
};
|
|
326
|
+
truncated?: boolean;
|
|
327
|
+
outputRef?: {
|
|
328
|
+
length?: number;
|
|
329
|
+
key?: string;
|
|
330
|
+
};
|
|
331
|
+
}, {
|
|
332
|
+
status?: "succeeded" | "failed" | "running" | "unknown";
|
|
333
|
+
name?: string;
|
|
334
|
+
input?: string;
|
|
335
|
+
output?: string;
|
|
336
|
+
kind?: "tool";
|
|
337
|
+
detail?: {
|
|
338
|
+
type?: "command";
|
|
339
|
+
command?: string;
|
|
340
|
+
cwd?: string;
|
|
341
|
+
exitCode?: number;
|
|
342
|
+
outputMode?: "merged";
|
|
343
|
+
} | {
|
|
344
|
+
type?: "file_change";
|
|
345
|
+
files?: {
|
|
346
|
+
path?: string;
|
|
347
|
+
patch?: string;
|
|
348
|
+
change?: "created" | "deleted" | "modified" | "reported";
|
|
349
|
+
}[];
|
|
350
|
+
};
|
|
351
|
+
truncated?: boolean;
|
|
352
|
+
outputRef?: {
|
|
353
|
+
length?: number;
|
|
354
|
+
key?: string;
|
|
355
|
+
};
|
|
356
|
+
}>, z.ZodObject<{
|
|
357
|
+
kind: z.ZodLiteral<"diagnostic">;
|
|
358
|
+
code: z.ZodString;
|
|
359
|
+
text: z.ZodString;
|
|
360
|
+
}, "strict", z.ZodTypeAny, {
|
|
361
|
+
code?: string;
|
|
362
|
+
text?: string;
|
|
363
|
+
kind?: "diagnostic";
|
|
364
|
+
}, {
|
|
365
|
+
code?: string;
|
|
366
|
+
text?: string;
|
|
367
|
+
kind?: "diagnostic";
|
|
368
|
+
}>]>;
|
|
369
|
+
}, "strict", z.ZodTypeAny, {
|
|
370
|
+
id?: string;
|
|
371
|
+
content?: {
|
|
372
|
+
text?: string;
|
|
373
|
+
kind?: "message";
|
|
374
|
+
} | {
|
|
375
|
+
status?: "succeeded" | "failed" | "running" | "unknown";
|
|
376
|
+
name?: string;
|
|
377
|
+
input?: string;
|
|
378
|
+
output?: string;
|
|
379
|
+
kind?: "tool";
|
|
380
|
+
detail?: {
|
|
381
|
+
type?: "command";
|
|
382
|
+
command?: string;
|
|
383
|
+
cwd?: string;
|
|
384
|
+
exitCode?: number;
|
|
385
|
+
outputMode?: "merged";
|
|
386
|
+
} | {
|
|
387
|
+
type?: "file_change";
|
|
388
|
+
files?: {
|
|
389
|
+
path?: string;
|
|
390
|
+
patch?: string;
|
|
391
|
+
change?: "created" | "deleted" | "modified" | "reported";
|
|
392
|
+
}[];
|
|
393
|
+
};
|
|
394
|
+
truncated?: boolean;
|
|
395
|
+
outputRef?: {
|
|
396
|
+
length?: number;
|
|
397
|
+
key?: string;
|
|
398
|
+
};
|
|
399
|
+
} | {
|
|
400
|
+
code?: string;
|
|
401
|
+
text?: string;
|
|
402
|
+
kind?: "diagnostic";
|
|
403
|
+
};
|
|
404
|
+
occurredAt?: string;
|
|
405
|
+
}, {
|
|
406
|
+
id?: string;
|
|
407
|
+
content?: {
|
|
408
|
+
text?: string;
|
|
409
|
+
kind?: "message";
|
|
410
|
+
} | {
|
|
411
|
+
status?: "succeeded" | "failed" | "running" | "unknown";
|
|
412
|
+
name?: string;
|
|
413
|
+
input?: string;
|
|
414
|
+
output?: string;
|
|
415
|
+
kind?: "tool";
|
|
416
|
+
detail?: {
|
|
417
|
+
type?: "command";
|
|
418
|
+
command?: string;
|
|
419
|
+
cwd?: string;
|
|
420
|
+
exitCode?: number;
|
|
421
|
+
outputMode?: "merged";
|
|
422
|
+
} | {
|
|
423
|
+
type?: "file_change";
|
|
424
|
+
files?: {
|
|
425
|
+
path?: string;
|
|
426
|
+
patch?: string;
|
|
427
|
+
change?: "created" | "deleted" | "modified" | "reported";
|
|
428
|
+
}[];
|
|
429
|
+
};
|
|
430
|
+
truncated?: boolean;
|
|
431
|
+
outputRef?: {
|
|
432
|
+
length?: number;
|
|
433
|
+
key?: string;
|
|
434
|
+
};
|
|
435
|
+
} | {
|
|
436
|
+
code?: string;
|
|
437
|
+
text?: string;
|
|
438
|
+
kind?: "diagnostic";
|
|
439
|
+
};
|
|
440
|
+
occurredAt?: string;
|
|
441
|
+
}>, "many">;
|
|
442
|
+
sourceCursor: z.ZodOptional<z.ZodString>;
|
|
443
|
+
expectedSourceCursor: z.ZodOptional<z.ZodString>;
|
|
444
|
+
complete: z.ZodOptional<z.ZodBoolean>;
|
|
445
|
+
gaps: z.ZodOptional<z.ZodArray<z.ZodEnum<["source_truncated", "storage_unavailable", "capture_limit", "interrupted", "source_lost"]>, "many">>;
|
|
446
|
+
}, "strict", z.ZodTypeAny, {
|
|
447
|
+
complete?: boolean;
|
|
448
|
+
items?: {
|
|
449
|
+
id?: string;
|
|
450
|
+
content?: {
|
|
451
|
+
text?: string;
|
|
452
|
+
kind?: "message";
|
|
453
|
+
} | {
|
|
454
|
+
status?: "succeeded" | "failed" | "running" | "unknown";
|
|
455
|
+
name?: string;
|
|
456
|
+
input?: string;
|
|
457
|
+
output?: string;
|
|
458
|
+
kind?: "tool";
|
|
459
|
+
detail?: {
|
|
460
|
+
type?: "command";
|
|
461
|
+
command?: string;
|
|
462
|
+
cwd?: string;
|
|
463
|
+
exitCode?: number;
|
|
464
|
+
outputMode?: "merged";
|
|
465
|
+
} | {
|
|
466
|
+
type?: "file_change";
|
|
467
|
+
files?: {
|
|
468
|
+
path?: string;
|
|
469
|
+
patch?: string;
|
|
470
|
+
change?: "created" | "deleted" | "modified" | "reported";
|
|
471
|
+
}[];
|
|
472
|
+
};
|
|
473
|
+
truncated?: boolean;
|
|
474
|
+
outputRef?: {
|
|
475
|
+
length?: number;
|
|
476
|
+
key?: string;
|
|
477
|
+
};
|
|
478
|
+
} | {
|
|
479
|
+
code?: string;
|
|
480
|
+
text?: string;
|
|
481
|
+
kind?: "diagnostic";
|
|
482
|
+
};
|
|
483
|
+
occurredAt?: string;
|
|
484
|
+
}[];
|
|
485
|
+
sourceCursor?: string;
|
|
486
|
+
expectedSourceCursor?: string;
|
|
487
|
+
gaps?: ("interrupted" | "source_truncated" | "storage_unavailable" | "capture_limit" | "source_lost")[];
|
|
488
|
+
}, {
|
|
489
|
+
complete?: boolean;
|
|
490
|
+
items?: {
|
|
491
|
+
id?: string;
|
|
492
|
+
content?: {
|
|
493
|
+
text?: string;
|
|
494
|
+
kind?: "message";
|
|
495
|
+
} | {
|
|
496
|
+
status?: "succeeded" | "failed" | "running" | "unknown";
|
|
497
|
+
name?: string;
|
|
498
|
+
input?: string;
|
|
499
|
+
output?: string;
|
|
500
|
+
kind?: "tool";
|
|
501
|
+
detail?: {
|
|
502
|
+
type?: "command";
|
|
503
|
+
command?: string;
|
|
504
|
+
cwd?: string;
|
|
505
|
+
exitCode?: number;
|
|
506
|
+
outputMode?: "merged";
|
|
507
|
+
} | {
|
|
508
|
+
type?: "file_change";
|
|
509
|
+
files?: {
|
|
510
|
+
path?: string;
|
|
511
|
+
patch?: string;
|
|
512
|
+
change?: "created" | "deleted" | "modified" | "reported";
|
|
513
|
+
}[];
|
|
514
|
+
};
|
|
515
|
+
truncated?: boolean;
|
|
516
|
+
outputRef?: {
|
|
517
|
+
length?: number;
|
|
518
|
+
key?: string;
|
|
519
|
+
};
|
|
520
|
+
} | {
|
|
521
|
+
code?: string;
|
|
522
|
+
text?: string;
|
|
523
|
+
kind?: "diagnostic";
|
|
524
|
+
};
|
|
525
|
+
occurredAt?: string;
|
|
526
|
+
}[];
|
|
527
|
+
sourceCursor?: string;
|
|
528
|
+
expectedSourceCursor?: string;
|
|
529
|
+
gaps?: ("interrupted" | "source_truncated" | "storage_unavailable" | "capture_limit" | "source_lost")[];
|
|
530
|
+
}>;
|
|
531
|
+
export type ExecutionActivityBatch = z.infer<typeof executionActivityBatchSchema>;
|
|
532
|
+
export type ExecutionActivityGap = NonNullable<ExecutionActivityBatch['gaps']>[number];
|
|
533
|
+
export interface ExecutionActivityCheckpoint {
|
|
534
|
+
sourceCursor?: string;
|
|
535
|
+
seq: number;
|
|
536
|
+
}
|
|
537
|
+
export interface ExecutionActivityPage {
|
|
538
|
+
items: Array<ExecutionActivityItem & {
|
|
539
|
+
seq: number;
|
|
540
|
+
firstSeq: number;
|
|
541
|
+
observedAt: string;
|
|
542
|
+
}>;
|
|
543
|
+
nextCursor: number;
|
|
544
|
+
hasMore: boolean;
|
|
545
|
+
state: 'not_recorded' | 'recording' | 'closed' | 'expired';
|
|
546
|
+
gaps: ExecutionActivityGap[];
|
|
547
|
+
}
|
package/src/ai/index.d.ts
CHANGED
|
@@ -7,12 +7,15 @@ export type { TChatRequest } from './xpert-chat.model';
|
|
|
7
7
|
export type { ProjectSelection } from './project-selection.model';
|
|
8
8
|
export { CHAT_EVENT_TYPE_FOLLOW_UP_CONSUMED } from './chat-event.model';
|
|
9
9
|
export * from './assistant-binding.model';
|
|
10
|
+
export * from './bosi.model';
|
|
10
11
|
export * from './assistant-order';
|
|
11
12
|
export * from './assistant-model.model';
|
|
12
13
|
export * from './assistant-user-preference.model';
|
|
13
14
|
export * from './ai-model.model';
|
|
14
15
|
export * from './ai.model';
|
|
15
16
|
export * from './chat-event.model';
|
|
17
|
+
export { createResourceCardContent, isResourceCardContent, parseResourceCard, parseResourceCardContent, resourceCardId, upsertResourceCardContent } from './resource-card';
|
|
18
|
+
export type { ConversationResourceCard, ResourceCardImage, ResourceCardOpenTarget, ResourceCardScalar, TMessageContentResourceCard } from './resource-card';
|
|
16
19
|
export * from './thread-goal.model';
|
|
17
20
|
export * from './chat.model';
|
|
18
21
|
export * from './chat-message.model';
|
|
@@ -95,3 +98,11 @@ export * from './clawxpert-conversation-scope.model';
|
|
|
95
98
|
export * from './knowledge-keyword-analyzer.model';
|
|
96
99
|
export * from './assistant-configuration.model';
|
|
97
100
|
export * from './assistant-trigger.model';
|
|
101
|
+
export * from './model-execution.model';
|
|
102
|
+
export * from './agent-runtime.model';
|
|
103
|
+
export * from './project-task-runtime.model';
|
|
104
|
+
export * from './realtime-voice.model';
|
|
105
|
+
export * from './chat-group.model';
|
|
106
|
+
export * from './chat-group-entity.model';
|
|
107
|
+
export * from './conversation-entry.model';
|
|
108
|
+
export type { ThreadActivitySnapshot } from './thread-activity.model';
|
|
@@ -1,4 +1,6 @@
|
|
|
1
1
|
import type { McpCapabilityApprovalMode } from './mcp-publication.model';
|
|
2
|
+
import type { I18nObject } from '../types';
|
|
3
|
+
import type { TMcpAppRefresh } from './xpert-tool-mcp.model';
|
|
2
4
|
import type { JSONValue } from '../core.model';
|
|
3
5
|
export declare const MCP_CAPABILITY_DESCRIPTOR_VERSION: 1;
|
|
4
6
|
export declare const MCP_CAPABILITY_TYPES: readonly ["tool", "resource", "resource_template", "prompt", "app"];
|
|
@@ -82,7 +84,9 @@ export interface McpPromptCapabilityDescriptor extends McpCapabilityDescriptorBa
|
|
|
82
84
|
argumentSchema: McpJsonSchema;
|
|
83
85
|
supportsCompletion?: boolean;
|
|
84
86
|
}
|
|
85
|
-
export interface McpAppCapabilityDescriptor extends McpCapabilityDescriptorBase {
|
|
87
|
+
export interface McpAppCapabilityDescriptor extends Omit<McpCapabilityDescriptorBase, 'title'> {
|
|
88
|
+
title?: string | I18nObject;
|
|
89
|
+
refresh?: TMcpAppRefresh;
|
|
86
90
|
capabilityType: 'app';
|
|
87
91
|
entry: string;
|
|
88
92
|
csp?: {
|