@xpert-ai/contracts 3.23.0 → 3.26.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 +5295 -368
- package/index.esm.js +5184 -369
- package/package.json +2 -2
- package/src/ai/agent-output-delivery.model.d.ts +10 -10
- package/src/ai/agent-runtime.model.d.ts +24 -24
- package/src/ai/assistant-model.model.d.ts +8 -0
- package/src/ai/assistant-template-dependencies.model.d.ts +1 -1
- package/src/ai/chat.model.d.ts +3 -1
- package/src/ai/index.d.ts +2 -0
- package/src/ai/mcp-publication.model.d.ts +20 -0
- package/src/ai/model-discovery.model.d.ts +2 -0
- package/src/ai/project-pipeline/analytics.d.ts +1685 -0
- package/src/ai/project-pipeline/budget.schema.d.ts +78 -0
- package/src/ai/project-pipeline/catalog.schema.d.ts +188 -0
- package/src/ai/project-pipeline/catalog.validation.d.ts +4 -0
- package/src/ai/project-pipeline/commands.schema.d.ts +4381 -0
- package/src/ai/project-pipeline/compatibility.d.ts +5 -0
- package/src/ai/project-pipeline/compatibility.schema.d.ts +29 -0
- package/src/ai/project-pipeline/configuration-form.d.ts +17374 -0
- package/src/ai/project-pipeline/configuration.schema.d.ts +3774 -0
- package/src/ai/project-pipeline/contribution.schema.d.ts +6721 -0
- package/src/ai/project-pipeline/dataflow.validation.d.ts +6 -0
- package/src/ai/project-pipeline/definition.schema.d.ts +3808 -0
- package/src/ai/project-pipeline/definition.validation.d.ts +7 -0
- package/src/ai/project-pipeline/execution-statistics.d.ts +267 -0
- package/src/ai/project-pipeline/graph.model.d.ts +89 -0
- package/src/ai/project-pipeline/human-wait-statistics.d.ts +70 -0
- package/src/ai/project-pipeline/human-wait.schema.d.ts +26 -0
- package/src/ai/project-pipeline/index.d.ts +28 -0
- package/src/ai/project-pipeline/model-usage-statistics.d.ts +143 -0
- package/src/ai/project-pipeline/native-source.schema.d.ts +40 -0
- package/src/ai/project-pipeline/node.schema.d.ts +839 -0
- package/src/ai/project-pipeline/operation.schema.d.ts +800 -0
- package/src/ai/project-pipeline/portfolio.schema.d.ts +3817 -0
- package/src/ai/project-pipeline/primitives.schema.d.ts +138 -0
- package/src/ai/project-pipeline/projection.schema.d.ts +4715 -0
- package/src/ai/project-pipeline/provider-actions.schema.d.ts +2030 -0
- package/src/ai/project-pipeline/queue-statistics.d.ts +326 -0
- package/src/ai/project-pipeline/resources.schema.d.ts +73 -0
- package/src/ai/project-pipeline/runtime.schema.d.ts +934 -0
- package/src/ai/project-pipeline/statistics.d.ts +811 -0
- package/src/ai/project-task-graph.model.d.ts +18 -2
- package/src/ai/project-task-runtime.model.d.ts +924 -924
- package/src/ai/provider-credential-validation.model.d.ts +63 -0
- package/src/ai/template-installation.model.d.ts +29 -0
- package/src/ai/types.d.ts +6 -4
- package/src/ai/xpert-project-type.model.d.ts +15 -4
- package/src/ai/xpert-project.model.d.ts +9 -2
- package/src/ai/xpert-template.model.d.ts +1 -1
- package/src/analytics-query.model.d.ts +5 -0
- package/src/artifact-presentation.model.d.ts +28 -0
- package/src/index.d.ts +1 -0
- package/src/view-extension/model.d.ts +10 -1
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { AiModelTypeEnum } from '../agent/ai-model';
|
|
3
|
+
import type { DiscoveredModel } from './model-discovery.model';
|
|
4
|
+
export declare const providerCredentialValidationTargetSchema: z.ZodObject<{
|
|
5
|
+
modelType: z.ZodNativeEnum<typeof AiModelTypeEnum>;
|
|
6
|
+
model: z.ZodString;
|
|
7
|
+
}, "strict", z.ZodTypeAny, {
|
|
8
|
+
modelType?: AiModelTypeEnum;
|
|
9
|
+
model?: string;
|
|
10
|
+
}, {
|
|
11
|
+
modelType?: AiModelTypeEnum;
|
|
12
|
+
model?: string;
|
|
13
|
+
}>;
|
|
14
|
+
export type ProviderCredentialValidationTarget = z.infer<typeof providerCredentialValidationTargetSchema>;
|
|
15
|
+
export declare const providerCredentialCheckSchema: z.ZodObject<{
|
|
16
|
+
credentials: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
17
|
+
validationTarget: z.ZodOptional<z.ZodObject<{
|
|
18
|
+
modelType: z.ZodNativeEnum<typeof AiModelTypeEnum>;
|
|
19
|
+
model: z.ZodString;
|
|
20
|
+
}, "strict", z.ZodTypeAny, {
|
|
21
|
+
modelType?: AiModelTypeEnum;
|
|
22
|
+
model?: string;
|
|
23
|
+
}, {
|
|
24
|
+
modelType?: AiModelTypeEnum;
|
|
25
|
+
model?: string;
|
|
26
|
+
}>>;
|
|
27
|
+
}, "strict", z.ZodTypeAny, {
|
|
28
|
+
credentials?: Record<string, unknown>;
|
|
29
|
+
validationTarget?: {
|
|
30
|
+
modelType?: AiModelTypeEnum;
|
|
31
|
+
model?: string;
|
|
32
|
+
};
|
|
33
|
+
}, {
|
|
34
|
+
credentials?: Record<string, unknown>;
|
|
35
|
+
validationTarget?: {
|
|
36
|
+
modelType?: AiModelTypeEnum;
|
|
37
|
+
model?: string;
|
|
38
|
+
};
|
|
39
|
+
}>;
|
|
40
|
+
export type ProviderCredentialCheckInput = z.infer<typeof providerCredentialCheckSchema>;
|
|
41
|
+
/** Providers opt in when credential checks require a user-selected inference target. */
|
|
42
|
+
export interface ProviderCredentialValidationPolicy {
|
|
43
|
+
mode: 'model';
|
|
44
|
+
modelTypes: AiModelTypeEnum[];
|
|
45
|
+
}
|
|
46
|
+
export type ProviderCredentialValidationCapabilities = {
|
|
47
|
+
method: 'discovery';
|
|
48
|
+
} | {
|
|
49
|
+
method: 'model';
|
|
50
|
+
modelTypes: AiModelTypeEnum[];
|
|
51
|
+
models: ProviderCredentialValidationTarget[];
|
|
52
|
+
} | {
|
|
53
|
+
method: 'provider';
|
|
54
|
+
};
|
|
55
|
+
export type ProviderCredentialValidationResult = {
|
|
56
|
+
method: 'discovery';
|
|
57
|
+
models: DiscoveredModel[];
|
|
58
|
+
} | {
|
|
59
|
+
method: 'model';
|
|
60
|
+
target: ProviderCredentialValidationTarget;
|
|
61
|
+
} | {
|
|
62
|
+
method: 'provider';
|
|
63
|
+
};
|
|
@@ -33,6 +33,8 @@ export interface TemplateInstallation {
|
|
|
33
33
|
stage: TemplateInstallationStage;
|
|
34
34
|
attempt: number;
|
|
35
35
|
assistantId: string | null;
|
|
36
|
+
/** Current authoring access to the target, independent of the historical installation result. Absent on older servers. */
|
|
37
|
+
assistantAvailability?: 'available' | 'unavailable';
|
|
36
38
|
publish: boolean;
|
|
37
39
|
retryable: boolean;
|
|
38
40
|
error: {
|
|
@@ -44,9 +46,21 @@ export interface TemplateInstallation {
|
|
|
44
46
|
createdAt: string;
|
|
45
47
|
updatedAt: string;
|
|
46
48
|
}
|
|
49
|
+
export declare const templateDependencyVersionsSchema: z.ZodArray<z.ZodObject<{
|
|
50
|
+
pluginName: z.ZodString;
|
|
51
|
+
version: z.ZodString;
|
|
52
|
+
}, "strict", z.ZodTypeAny, {
|
|
53
|
+
version?: string;
|
|
54
|
+
pluginName?: string;
|
|
55
|
+
}, {
|
|
56
|
+
version?: string;
|
|
57
|
+
pluginName?: string;
|
|
58
|
+
}>, "many">;
|
|
47
59
|
export declare const templateDependencyLocksSchema: z.ZodArray<z.ZodObject<{
|
|
48
60
|
pluginName: z.ZodString;
|
|
49
61
|
version: z.ZodString;
|
|
62
|
+
/** Explicit template requirement, distinct from the automatically recorded installation version. */
|
|
63
|
+
requiredVersion: z.ZodOptional<z.ZodString>;
|
|
50
64
|
source: z.ZodOptional<z.ZodObject<{
|
|
51
65
|
kind: z.ZodLiteral<"agent-plugin">;
|
|
52
66
|
name: z.ZodString;
|
|
@@ -104,6 +118,7 @@ export declare const templateDependencyLocksSchema: z.ZodArray<z.ZodObject<{
|
|
|
104
118
|
bindingVersion?: string;
|
|
105
119
|
};
|
|
106
120
|
pluginName?: string;
|
|
121
|
+
requiredVersion?: string;
|
|
107
122
|
providers?: {
|
|
108
123
|
key?: string;
|
|
109
124
|
kind?: "middleware" | "toolset" | "sandbox";
|
|
@@ -123,9 +138,23 @@ export declare const templateDependencyLocksSchema: z.ZodArray<z.ZodObject<{
|
|
|
123
138
|
bindingVersion?: string;
|
|
124
139
|
};
|
|
125
140
|
pluginName?: string;
|
|
141
|
+
requiredVersion?: string;
|
|
126
142
|
providers?: {
|
|
127
143
|
key?: string;
|
|
128
144
|
kind?: "middleware" | "toolset" | "sandbox";
|
|
129
145
|
}[];
|
|
130
146
|
}>, "many">;
|
|
131
147
|
export type TemplateDependencyLock = z.output<typeof templateDependencyLocksSchema>[number];
|
|
148
|
+
/** Advisory drift in an available runtime dependency; never a compatibility guarantee. */
|
|
149
|
+
export interface TemplateDependencyUpdate {
|
|
150
|
+
pluginName: string;
|
|
151
|
+
installedVersion: string;
|
|
152
|
+
currentVersion: string;
|
|
153
|
+
changedComponents: {
|
|
154
|
+
type: TemplateDependencyLock['components'][number]['type'];
|
|
155
|
+
key: string;
|
|
156
|
+
}[];
|
|
157
|
+
}
|
|
158
|
+
export interface TemplateRuntimeDependencyReport {
|
|
159
|
+
updates: TemplateDependencyUpdate[];
|
|
160
|
+
}
|
package/src/ai/types.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { JsonSchema7TypeUnion } from
|
|
2
|
-
import { I18nObject, TSelectOption } from
|
|
3
|
-
import { TXpertAttachmentType, XpertParameterTypeEnum } from
|
|
1
|
+
import { JsonSchema7TypeUnion } from 'zod-to-json-schema';
|
|
2
|
+
import { I18nObject, TSelectOption } from '../types';
|
|
3
|
+
import { TXpertAttachmentType, XpertParameterTypeEnum } from './xpert.model';
|
|
4
4
|
export type TErrorHandling = {
|
|
5
5
|
type?: null | 'defaultValue' | 'failBranch';
|
|
6
6
|
defaultValue?: {
|
|
@@ -115,7 +115,9 @@ type JsonSchema7Meta = {
|
|
|
115
115
|
'x-ui'?: JsonSchemaUIExtensions;
|
|
116
116
|
};
|
|
117
117
|
export type JsonSchemaObjectType = {
|
|
118
|
-
type:
|
|
118
|
+
type: 'object';
|
|
119
|
+
/** Display title for a configuration form, including a plugin MCP configuration tab. */
|
|
120
|
+
title?: I18nObject;
|
|
119
121
|
properties: Record<string, JsonSchema7Type>;
|
|
120
122
|
additionalProperties?: boolean | JsonSchema7Type;
|
|
121
123
|
required?: string[];
|
|
@@ -1,14 +1,26 @@
|
|
|
1
1
|
import type { I18nObject, IconDefinition } from '../types';
|
|
2
|
+
import type { XpertViewScalar } from '../view-extension/model';
|
|
3
|
+
export interface XpertProjectViewSelection {
|
|
4
|
+
viewKey: string;
|
|
5
|
+
selectionId?: string;
|
|
6
|
+
parameters?: Record<string, XpertViewScalar | XpertViewScalar[]>;
|
|
7
|
+
}
|
|
2
8
|
/** Stable identity, independent of installation ids, labels and plugin versions. */
|
|
3
9
|
export interface XpertProjectTypeRef {
|
|
4
10
|
applicationKey: string;
|
|
5
11
|
projectTypeKey: string;
|
|
6
12
|
}
|
|
7
13
|
export declare const GENERAL_PROJECT_TYPE: XpertProjectTypeRef;
|
|
14
|
+
/** Business-task capacity owned by the Project type's dispatcher, never the Agent runtime. */
|
|
15
|
+
export interface XpertProjectTaskConcurrency {
|
|
16
|
+
maxConcurrentTasks: number;
|
|
17
|
+
}
|
|
8
18
|
export interface XpertProjectTypeDefinition {
|
|
9
19
|
key: string;
|
|
10
20
|
title: string | I18nObject;
|
|
11
21
|
icon?: IconDefinition;
|
|
22
|
+
/** Entity-backed applications enforce this policy in their business preparation/claim services. */
|
|
23
|
+
taskConcurrency?: XpertProjectTaskConcurrency;
|
|
12
24
|
/** Entity types delegate creation and lifecycle to their registered provider. */
|
|
13
25
|
binding: {
|
|
14
26
|
kind: 'project';
|
|
@@ -22,6 +34,7 @@ export interface XpertProjectTypeSummary extends XpertProjectTypeRef {
|
|
|
22
34
|
title: string | I18nObject;
|
|
23
35
|
icon?: IconDefinition;
|
|
24
36
|
binding: XpertProjectTypeDefinition['binding'];
|
|
37
|
+
taskConcurrency?: XpertProjectTaskConcurrency;
|
|
25
38
|
available: boolean;
|
|
26
39
|
}
|
|
27
40
|
export interface XpertProjectClassification {
|
|
@@ -42,14 +55,12 @@ export type XpertProjectEntry = {
|
|
|
42
55
|
kind: 'project';
|
|
43
56
|
projectId?: string;
|
|
44
57
|
projectType: XpertProjectTypeRef;
|
|
45
|
-
} | {
|
|
58
|
+
} | ({
|
|
46
59
|
kind: 'assistant';
|
|
47
60
|
xpertId: string;
|
|
48
61
|
slug: string;
|
|
49
62
|
projectId?: string;
|
|
50
|
-
|
|
51
|
-
selectionId?: string;
|
|
52
|
-
};
|
|
63
|
+
} & XpertProjectViewSelection);
|
|
53
64
|
export interface XpertProjectTypeCatalog {
|
|
54
65
|
items: XpertProjectTypeSummary[];
|
|
55
66
|
defaultProjectType?: XpertProjectTypeRef;
|
|
@@ -221,6 +221,9 @@ export interface IBasePerXpertProjectEntityModel extends IBasePerTenantAndOrgani
|
|
|
221
221
|
project?: IXpertProject;
|
|
222
222
|
}
|
|
223
223
|
export interface IXpertProjectTask extends IBasePerXpertProjectEntityModel {
|
|
224
|
+
controlKind?: 'ordinary' | 'provider' | 'pipeline';
|
|
225
|
+
pipelineInstanceId?: string | null;
|
|
226
|
+
pipelineDisposition?: 'active' | 'removed' | 'excluded' | 'superseded' | null;
|
|
224
227
|
decisions?: ProjectTaskDecision[];
|
|
225
228
|
/** Measured completion percentage (0–100); null/omitted means unknown. */
|
|
226
229
|
progress?: number | null;
|
|
@@ -279,10 +282,14 @@ export interface IXpertProjectTaskExecution extends IBasePerXpertProjectEntityMo
|
|
|
279
282
|
/** Observed runtime status, independent from the business task acceptance status. */
|
|
280
283
|
runtimeStartedAt?: string | null;
|
|
281
284
|
runtimeCompletedAt?: string | null;
|
|
282
|
-
/** Authorized
|
|
285
|
+
/** Authorized runtime presentation, not persisted task state. */
|
|
283
286
|
runtimeProvider?: string;
|
|
284
287
|
runtimeToolId?: string;
|
|
285
|
-
|
|
288
|
+
/** Exact registered handler from a persisted Pipeline service operation. */
|
|
289
|
+
runtimeServiceRef?: string;
|
|
290
|
+
/** Classified from the exact persisted managed Pipeline operation, never from task attempt count. */
|
|
291
|
+
pipelineAttemptKind?: 'initial' | 'technical_retry';
|
|
292
|
+
runtimeStatus?: 'running' | 'success' | 'error' | 'pending' | 'timeout' | 'interrupted' | 'unknown' | 'queued' | 'succeeded' | 'failed' | 'cancelled';
|
|
286
293
|
sourceKey?: string | null;
|
|
287
294
|
taskId: string;
|
|
288
295
|
conversationId?: string;
|
|
@@ -136,7 +136,7 @@ export interface XpertTemplateModelOption extends ModelSelectionMetadata {
|
|
|
136
136
|
}
|
|
137
137
|
export interface XpertTemplateSetup {
|
|
138
138
|
readiness?: TemplateReadiness;
|
|
139
|
-
/** ID of
|
|
139
|
+
/** ID of an eligible existing binding or organization/tenant default in `models`; absent if none qualifies. */
|
|
140
140
|
defaultModelId?: string;
|
|
141
141
|
realtimeModels?: import('./realtime-voice.model').RealtimeModelOption[];
|
|
142
142
|
requiresModel?: boolean;
|
|
@@ -126,6 +126,11 @@ export interface AnalyticsProviderDescriptor {
|
|
|
126
126
|
contractVersion: number;
|
|
127
127
|
readOnly: true;
|
|
128
128
|
}>;
|
|
129
|
+
/** Declares a provider-wide collaboration constraint; does not grant source or file access. */
|
|
130
|
+
sharing?: {
|
|
131
|
+
mode: 'viewer_permissions' | 'owner_only';
|
|
132
|
+
reasonCode?: string;
|
|
133
|
+
};
|
|
129
134
|
/** Optional new source type and configuration schema, never connection values; omit for existing types. */
|
|
130
135
|
connectionType?: {
|
|
131
136
|
type: string;
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
/** Host-owned opening avoids inheriting a remote component's iframe sandbox. */
|
|
2
|
+
export declare const ARTIFACT_PRESENTATION_OPEN_COMMAND = "artifact.presentation.open";
|
|
3
|
+
export interface ArtifactPresentationOpenRequest {
|
|
4
|
+
url: string;
|
|
5
|
+
}
|
|
6
|
+
/** A viewer always operates on one published, immutable version. Drafts are not share targets. */
|
|
7
|
+
export interface ArtifactPresentationTarget {
|
|
8
|
+
artifactId: string;
|
|
9
|
+
versionId: string;
|
|
10
|
+
}
|
|
11
|
+
/** Platform-owned envelope; data is parsed by the registered presentation provider. */
|
|
12
|
+
export interface ArtifactPresentation {
|
|
13
|
+
schemaVersion: 1;
|
|
14
|
+
target: ArtifactPresentationTarget;
|
|
15
|
+
title: string;
|
|
16
|
+
versionNumber: number;
|
|
17
|
+
readOnly: true;
|
|
18
|
+
entry: {
|
|
19
|
+
html: string;
|
|
20
|
+
};
|
|
21
|
+
data: object;
|
|
22
|
+
operations: string[];
|
|
23
|
+
}
|
|
24
|
+
export interface ArtifactPresentationQuery {
|
|
25
|
+
target: ArtifactPresentationTarget;
|
|
26
|
+
operation: string;
|
|
27
|
+
input: object;
|
|
28
|
+
}
|
package/src/index.d.ts
CHANGED
|
@@ -349,6 +349,10 @@ export declare const WORKBENCH_ASSISTANT_EXECUTION_TARGET = "assistant.execution
|
|
|
349
349
|
/** Opens the current Assistant inside a Project-scoped workbench route. */
|
|
350
350
|
export declare const WORKBENCH_ASSISTANT_PROJECT_TARGET = "assistant.project";
|
|
351
351
|
export declare const WORKBENCH_EXTENSION_VIEW_TARGET = "workbench.view";
|
|
352
|
+
/** Resolve the Project's application entry through its registered type and current access checks. */
|
|
353
|
+
export declare const WORKBENCH_PROJECT_APPLICATION_TARGET = "project.application";
|
|
354
|
+
/** Open full Project pipeline management in the configured platform. */
|
|
355
|
+
export declare const WORKBENCH_PROJECT_PIPELINES_TARGET = "project.pipelines";
|
|
352
356
|
export declare const XPERT_REMOTE_COMPONENT_INVOKE_CLIENT_COMMAND_MESSAGE_TYPE = "invokeClientCommand";
|
|
353
357
|
export interface WorkbenchOpenFileEvidenceBox {
|
|
354
358
|
x: number;
|
|
@@ -386,7 +390,7 @@ export interface WorkbenchOpenFile {
|
|
|
386
390
|
previewUrl?: string;
|
|
387
391
|
evidence?: WorkbenchOpenFileEvidence;
|
|
388
392
|
}
|
|
389
|
-
export type WorkbenchNavigationOpenTarget = typeof WORKBENCH_AGENT_EVOLUTION_TARGET | typeof WORKBENCH_AGENT_EVOLUTION_CHANGE_TARGET | typeof WORKBENCH_KNOWLEDGEBASE_DOCUMENTS_TARGET | typeof WORKBENCH_ASSISTANT_CONVERSATION_TARGET | typeof WORKBENCH_ASSISTANT_EXECUTION_TARGET | typeof WORKBENCH_ASSISTANT_PROJECT_TARGET | typeof WORKBENCH_EXTENSION_VIEW_TARGET;
|
|
393
|
+
export type WorkbenchNavigationOpenTarget = typeof WORKBENCH_AGENT_EVOLUTION_TARGET | typeof WORKBENCH_AGENT_EVOLUTION_CHANGE_TARGET | typeof WORKBENCH_KNOWLEDGEBASE_DOCUMENTS_TARGET | typeof WORKBENCH_ASSISTANT_CONVERSATION_TARGET | typeof WORKBENCH_ASSISTANT_EXECUTION_TARGET | typeof WORKBENCH_ASSISTANT_PROJECT_TARGET | typeof WORKBENCH_EXTENSION_VIEW_TARGET | typeof WORKBENCH_PROJECT_APPLICATION_TARGET | typeof WORKBENCH_PROJECT_PIPELINES_TARGET;
|
|
390
394
|
export interface WorkbenchNavigationOpenPayload {
|
|
391
395
|
target: WorkbenchNavigationOpenTarget;
|
|
392
396
|
targetId?: string;
|
|
@@ -410,6 +414,11 @@ export interface WorkbenchNavigationOpenPayload {
|
|
|
410
414
|
xpertId?: string;
|
|
411
415
|
/** Platform Chat Project selected for Project-scoped Assistant navigation. */
|
|
412
416
|
projectId?: string;
|
|
417
|
+
/** Untrusted identity hint; Project application entry reauthorizes the current persisted node. */
|
|
418
|
+
pipelineNodeId?: string;
|
|
419
|
+
/** Read-only Project pipeline return focus, rechecked when the graph is read. */
|
|
420
|
+
pipelineInstanceId?: string;
|
|
421
|
+
pipelineRoundId?: string;
|
|
413
422
|
viewKey?: string;
|
|
414
423
|
selectionId?: string;
|
|
415
424
|
parameters?: Record<string, XpertViewScalar | XpertViewScalar[]>;
|