@xpert-ai/contracts 3.16.0 → 3.17.1
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 +197 -35
- package/index.esm.js +185 -33
- package/package.json +1 -1
- package/src/agent/ai-model.d.ts +4 -1
- package/src/agent/graph.d.ts +2 -0
- package/src/ai/ai-model.model.d.ts +6 -1
- package/src/ai/evolution/candidate.d.ts +67 -0
- package/src/ai/evolution/capability-version.d.ts +45 -0
- package/src/ai/evolution/evaluation.d.ts +93 -0
- package/src/ai/evolution/example.d.ts +42 -0
- package/src/ai/evolution/experience.d.ts +21 -0
- package/src/ai/evolution/governance.d.ts +87 -0
- package/src/ai/evolution/index.d.ts +11 -0
- package/src/ai/evolution/learning-event.d.ts +69 -0
- package/src/ai/evolution/provider.d.ts +30 -0
- package/src/ai/evolution/release.d.ts +144 -0
- package/src/ai/evolution/runtime.d.ts +81 -0
- package/src/ai/evolution/target.d.ts +83 -0
- package/src/ai/index.d.ts +3 -0
- package/src/ai/knowledge-doc-chunk.model.d.ts +143 -0
- package/src/ai/knowledge-doc.model.d.ts +53 -4
- package/src/ai/knowledge-filter.model.d.ts +92 -0
- package/src/ai/knowledge-retrieval-log.model.d.ts +16 -0
- package/src/ai/knowledgebase-task.model.d.ts +3 -1
- package/src/ai/knowledgebase.model.d.ts +6 -0
- package/src/ai/membership.model.d.ts +40 -7
- package/src/ai/model-gateway.model.d.ts +5 -0
- package/src/ai/model-usage.model.d.ts +163 -0
- package/src/ai/role-permissions.d.ts +4 -1
- package/src/ai/xpert-agent-execution.model.d.ts +2 -0
- package/src/ai/xpert.model.d.ts +23 -11
- package/src/plugin.d.ts +4 -0
- package/src/tenant.model.d.ts +1 -1
- package/src/view-extension/model.d.ts +12 -1
|
@@ -5,6 +5,7 @@ export declare enum AIPermissionsEnum {
|
|
|
5
5
|
KNOWLEDGEBASE_EDIT = "KNOWLEDGEBASE_EDIT",
|
|
6
6
|
COPILOT_VIEW = "COPILOT_VIEW",
|
|
7
7
|
COPILOT_EDIT = "COPILOT_EDIT",
|
|
8
|
+
MODEL_USAGE_MONITOR = "MODEL_USAGE_MONITOR",
|
|
8
9
|
MEMBERSHIP_EDIT = "MEMBERSHIP_EDIT",
|
|
9
10
|
MEMBERSHIP_USE = "MEMBERSHIP_USE",
|
|
10
11
|
MODEL_ACCESS_REQUEST_VIEW = "MODEL_ACCESS_REQUEST_VIEW",
|
|
@@ -18,5 +19,7 @@ export declare enum AIPermissionsEnum {
|
|
|
18
19
|
* Create or edit Xperts in organization.
|
|
19
20
|
*/
|
|
20
21
|
XPERT_EDIT = "XPERT_EDIT",
|
|
21
|
-
CHAT_VIEW = "CHAT_VIEW"
|
|
22
|
+
CHAT_VIEW = "CHAT_VIEW",
|
|
23
|
+
EVOLUTION_VIEW = "EVOLUTION_VIEW",
|
|
24
|
+
EVOLUTION_MANAGE = "EVOLUTION_MANAGE"
|
|
22
25
|
}
|
|
@@ -4,6 +4,7 @@ import { IXpert, TXpertTeamNodeType } from './xpert.model';
|
|
|
4
4
|
import { IXpertAgent } from './xpert-agent.model';
|
|
5
5
|
import { TSensitiveOperation } from './chat.model';
|
|
6
6
|
import { WorkflowNodeTypeEnum } from './xpert-workflow.model';
|
|
7
|
+
import type { IModelUsageDetails } from './model-usage.model';
|
|
7
8
|
export type TXpertExecution = {
|
|
8
9
|
category?: TXpertTeamNodeType;
|
|
9
10
|
type?: WorkflowNodeTypeEnum | string;
|
|
@@ -68,6 +69,7 @@ export type TXpertAgentExecution = TXpertExecution & {
|
|
|
68
69
|
messages?: StoredMessage[];
|
|
69
70
|
agent?: IXpertAgent;
|
|
70
71
|
totalTokens?: number;
|
|
72
|
+
modelUsages?: IModelUsageDetails[];
|
|
71
73
|
/**
|
|
72
74
|
* Summary of conversation
|
|
73
75
|
*/
|
package/src/ai/xpert.model.d.ts
CHANGED
|
@@ -12,10 +12,11 @@ import { IXpertToolset } from './xpert-toolset.model';
|
|
|
12
12
|
import { IBasePerWorkspaceEntityModel } from './xpert-workspace.model';
|
|
13
13
|
import { IIntegration } from '../integration.model';
|
|
14
14
|
import { TChatFrom } from './chat.model';
|
|
15
|
-
import { IWorkflowNode, TVariableAssigner,
|
|
15
|
+
import { IWorkflowNode, TVariableAssigner, VariableOperationEnum } from './xpert-workflow.model';
|
|
16
16
|
import { IEnvironment } from './environment.model';
|
|
17
17
|
import { TXpertCommandProfile } from './prompt-workflow.model';
|
|
18
18
|
import type { TXpertMarketplaceProfile } from './xpert-marketplace.model';
|
|
19
|
+
import type { KnowledgeFilterNode } from './knowledge-filter.model';
|
|
19
20
|
export type ToolCall = LToolCall;
|
|
20
21
|
export declare enum XpertTypeEnum {
|
|
21
22
|
/**
|
|
@@ -235,12 +236,26 @@ export interface IXpertPrincipalReference {
|
|
|
235
236
|
tenantName?: string | null;
|
|
236
237
|
workspaceName?: string | null;
|
|
237
238
|
}
|
|
239
|
+
export declare enum XpertWorkbenchInitialLayoutEnum {
|
|
240
|
+
TwoColumns = "two-columns",
|
|
241
|
+
ChatkitMaximized = "chatkit-maximized",
|
|
242
|
+
WorkbenchMaximized = "workbench-maximized"
|
|
243
|
+
}
|
|
244
|
+
export type TXpertWorkbenchOptions = {
|
|
245
|
+
/**
|
|
246
|
+
* Initial layout used before this user has a saved Workbench layout preference.
|
|
247
|
+
*/
|
|
248
|
+
initialLayout?: XpertWorkbenchInitialLayoutEnum;
|
|
249
|
+
/** Public extension view key selected when the Workbench first loads. */
|
|
250
|
+
defaultViewKey?: string;
|
|
251
|
+
};
|
|
238
252
|
export type TXpertOptions = {
|
|
239
253
|
bootstrap?: {
|
|
240
254
|
source: 'template';
|
|
241
255
|
templateKey: string;
|
|
242
256
|
workspaceKind: 'org-default';
|
|
243
257
|
};
|
|
258
|
+
workbench?: TXpertWorkbenchOptions;
|
|
244
259
|
knowledge?: Record<string, {
|
|
245
260
|
position?: IPoint;
|
|
246
261
|
size?: ISize;
|
|
@@ -596,16 +611,13 @@ export type TKBRetrievalSettings = {
|
|
|
596
611
|
entityTopK?: number;
|
|
597
612
|
communityTopK?: number;
|
|
598
613
|
graphWeight?: number;
|
|
599
|
-
|
|
600
|
-
|
|
601
|
-
|
|
602
|
-
|
|
603
|
-
|
|
604
|
-
|
|
605
|
-
|
|
606
|
-
* Parameter fields (tool call) when mode is automatic
|
|
607
|
-
*/
|
|
608
|
-
fields?: Record<string, object>;
|
|
614
|
+
filtering?: {
|
|
615
|
+
/** Mandatory filter owned by the Agent/workflow to knowledgebase binding. */
|
|
616
|
+
fixed?: KnowledgeFilterNode;
|
|
617
|
+
/** Agent-authored filters can only narrow `fixed` filters. */
|
|
618
|
+
agent?: {
|
|
619
|
+
enabled: boolean;
|
|
620
|
+
};
|
|
609
621
|
};
|
|
610
622
|
};
|
|
611
623
|
export declare function isXpertNodeType<T extends TXpertTeamNodeType>(type: T): (node: TXpertTeamNode) => node is NodeOf<T>;
|
package/src/plugin.d.ts
CHANGED
|
@@ -61,6 +61,9 @@ export declare const PLUGIN_RESOURCE_INSTALLATION_STATUS: {
|
|
|
61
61
|
readonly BLOCKED: "blocked";
|
|
62
62
|
readonly FAILED: "failed";
|
|
63
63
|
};
|
|
64
|
+
export declare const PLUGIN_RESOURCE_ERROR_CODE: {
|
|
65
|
+
readonly NO_MATCHING_COMPONENTS: "PLUGIN_RESOURCE_NO_MATCHING_COMPONENTS";
|
|
66
|
+
};
|
|
64
67
|
/**
|
|
65
68
|
* Classifies plugin scope and governance.
|
|
66
69
|
* - `system`: built-in/platform-managed plugin that users cannot install/uninstall from org APIs.
|
|
@@ -77,6 +80,7 @@ export type PluginMarketplaceAuthenticationPolicy = (typeof PLUGIN_MARKETPLACE_A
|
|
|
77
80
|
export type PluginMcpToolApprovalMode = (typeof PLUGIN_MCP_TOOL_APPROVAL_MODE)[keyof typeof PLUGIN_MCP_TOOL_APPROVAL_MODE];
|
|
78
81
|
export type PluginResourceRuntimeType = (typeof PLUGIN_RESOURCE_RUNTIME_TYPE)[keyof typeof PLUGIN_RESOURCE_RUNTIME_TYPE];
|
|
79
82
|
export type PluginResourceInstallationStatus = (typeof PLUGIN_RESOURCE_INSTALLATION_STATUS)[keyof typeof PLUGIN_RESOURCE_INSTALLATION_STATUS];
|
|
83
|
+
export type PluginResourceErrorCode = (typeof PLUGIN_RESOURCE_ERROR_CODE)[keyof typeof PLUGIN_RESOURCE_ERROR_CODE];
|
|
80
84
|
export type PluginScopeRelation = 'none' | 'overrides-global' | 'shadowed-by-organization';
|
|
81
85
|
export type PluginTargetApp = 'xpert' | 'data-xpert' | (string & {});
|
|
82
86
|
export type PluginSdkCompatibilityWarningCode = 'plugin-sdk-peer-dependency-missing' | 'plugin-sdk-peer-range-invalid' | 'plugin-sdk-peer-range-incompatible' | 'plugin-sdk-peer-range-spans-major';
|
package/src/tenant.model.d.ts
CHANGED
|
@@ -35,7 +35,7 @@ export interface ITenantSetting extends S3FileStorageProviderConfig {
|
|
|
35
35
|
copilotCheckpointRetentionDays?: string | null;
|
|
36
36
|
modelGatewayCallRetentionEnabled?: string | null;
|
|
37
37
|
modelGatewayCallRetentionDays?: string | null;
|
|
38
|
-
|
|
38
|
+
membershipCnyPerPoint?: string | null;
|
|
39
39
|
modelGatewayRequestsPerMinute?: string | null;
|
|
40
40
|
modelGatewayMaxConcurrentRequests?: string | null;
|
|
41
41
|
tenant_title?: string;
|
|
@@ -254,6 +254,7 @@ export declare const WORKBENCH_FILE_OPEN_COMMAND = "workbench.file.open";
|
|
|
254
254
|
export declare const WORKBENCH_NAVIGATION_OPEN_COMMAND = "workbench.navigation.open";
|
|
255
255
|
export declare const WORKBENCH_KNOWLEDGEBASE_DOCUMENTS_TARGET = "knowledgebase.documents";
|
|
256
256
|
export declare const WORKBENCH_ASSISTANT_CONVERSATION_TARGET = "assistant.conversation";
|
|
257
|
+
export declare const WORKBENCH_EXTENSION_VIEW_TARGET = "workbench.view";
|
|
257
258
|
export declare const XPERT_REMOTE_COMPONENT_INVOKE_CLIENT_COMMAND_MESSAGE_TYPE = "invokeClientCommand";
|
|
258
259
|
export interface WorkbenchOpenFileEvidenceBox {
|
|
259
260
|
x: number;
|
|
@@ -291,19 +292,29 @@ export interface WorkbenchOpenFile {
|
|
|
291
292
|
previewUrl?: string;
|
|
292
293
|
evidence?: WorkbenchOpenFileEvidence;
|
|
293
294
|
}
|
|
294
|
-
export type WorkbenchNavigationOpenTarget = typeof WORKBENCH_KNOWLEDGEBASE_DOCUMENTS_TARGET | typeof WORKBENCH_ASSISTANT_CONVERSATION_TARGET;
|
|
295
|
+
export type WorkbenchNavigationOpenTarget = typeof WORKBENCH_KNOWLEDGEBASE_DOCUMENTS_TARGET | typeof WORKBENCH_ASSISTANT_CONVERSATION_TARGET | typeof WORKBENCH_EXTENSION_VIEW_TARGET;
|
|
295
296
|
export interface WorkbenchNavigationOpenPayload {
|
|
296
297
|
target: WorkbenchNavigationOpenTarget;
|
|
297
298
|
knowledgebaseId?: string;
|
|
299
|
+
documentId?: string;
|
|
300
|
+
parentId?: string;
|
|
298
301
|
conversationId?: string;
|
|
299
302
|
threadId?: string;
|
|
300
303
|
executionId?: string;
|
|
304
|
+
viewKey?: string;
|
|
305
|
+
selectionId?: string;
|
|
306
|
+
parameters?: Record<string, XpertViewScalar | XpertViewScalar[]>;
|
|
301
307
|
}
|
|
302
308
|
export interface WorkbenchAssistantConversationOpenRequest {
|
|
303
309
|
conversationId: string;
|
|
304
310
|
threadId?: string;
|
|
305
311
|
executionId?: string;
|
|
306
312
|
}
|
|
313
|
+
export interface WorkbenchExtensionViewOpenRequest {
|
|
314
|
+
viewKey: string;
|
|
315
|
+
selectionId?: string;
|
|
316
|
+
parameters?: Record<string, XpertViewScalar | XpertViewScalar[]>;
|
|
317
|
+
}
|
|
307
318
|
export interface XpertRemoteComponentInvokeClientCommandRequest {
|
|
308
319
|
type: typeof XPERT_REMOTE_COMPONENT_INVOKE_CLIENT_COMMAND_MESSAGE_TYPE;
|
|
309
320
|
requestId: string;
|