@vertesia/common 1.0.0-dev.20260128.144200 → 1.0.0-dev.20260225.024852Z
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/lib/cjs/apikey.js +1 -0
- package/lib/cjs/apikey.js.map +1 -1
- package/lib/cjs/apps.js.map +1 -1
- package/lib/cjs/audit-trail.js +3 -0
- package/lib/cjs/audit-trail.js.map +1 -0
- package/lib/cjs/index.js +1 -0
- package/lib/cjs/index.js.map +1 -1
- package/lib/cjs/integrations.js +2 -0
- package/lib/cjs/integrations.js.map +1 -1
- package/lib/cjs/interaction.js.map +1 -1
- package/lib/cjs/project.js +37 -1
- package/lib/cjs/project.js.map +1 -1
- package/lib/cjs/prompt.js.map +1 -1
- package/lib/cjs/store/dsl-workflow.js.map +1 -1
- package/lib/cjs/store/hive-memory.js +3 -0
- package/lib/cjs/store/hive-memory.js.map +1 -0
- package/lib/cjs/store/index.js +2 -0
- package/lib/cjs/store/index.js.map +1 -1
- package/lib/cjs/store/rendering.js +22 -0
- package/lib/cjs/store/rendering.js.map +1 -0
- package/lib/cjs/store/schedule.js.map +1 -1
- package/lib/cjs/store/store.js +15 -2
- package/lib/cjs/store/store.js.map +1 -1
- package/lib/cjs/store/workflow.js +44 -1
- package/lib/cjs/store/workflow.js.map +1 -1
- package/lib/cjs/user.js.map +1 -1
- package/lib/cjs/utils/schemas.js +26 -2
- package/lib/cjs/utils/schemas.js.map +1 -1
- package/lib/cjs/versions.js +1 -0
- package/lib/cjs/versions.js.map +1 -1
- package/lib/esm/apikey.js +1 -0
- package/lib/esm/apikey.js.map +1 -1
- package/lib/esm/apps.js.map +1 -1
- package/lib/esm/audit-trail.js +2 -0
- package/lib/esm/audit-trail.js.map +1 -0
- package/lib/esm/index.js +1 -0
- package/lib/esm/index.js.map +1 -1
- package/lib/esm/integrations.js +2 -0
- package/lib/esm/integrations.js.map +1 -1
- package/lib/esm/interaction.js.map +1 -1
- package/lib/esm/project.js +36 -0
- package/lib/esm/project.js.map +1 -1
- package/lib/esm/prompt.js.map +1 -1
- package/lib/esm/store/dsl-workflow.js.map +1 -1
- package/lib/esm/store/hive-memory.js +2 -0
- package/lib/esm/store/hive-memory.js.map +1 -0
- package/lib/esm/store/index.js +2 -0
- package/lib/esm/store/index.js.map +1 -1
- package/lib/esm/store/rendering.js +18 -0
- package/lib/esm/store/rendering.js.map +1 -0
- package/lib/esm/store/schedule.js.map +1 -1
- package/lib/esm/store/store.js +13 -2
- package/lib/esm/store/store.js.map +1 -1
- package/lib/esm/store/workflow.js +39 -1
- package/lib/esm/store/workflow.js.map +1 -1
- package/lib/esm/user.js.map +1 -1
- package/lib/esm/utils/schemas.js +24 -2
- package/lib/esm/utils/schemas.js.map +1 -1
- package/lib/esm/versions.js +1 -0
- package/lib/esm/versions.js.map +1 -1
- package/lib/tsconfig.tsbuildinfo +1 -1
- package/lib/types/apikey.d.ts +2 -1
- package/lib/types/apikey.d.ts.map +1 -1
- package/lib/types/apps.d.ts +220 -1
- package/lib/types/apps.d.ts.map +1 -1
- package/lib/types/audit-trail.d.ts +49 -0
- package/lib/types/audit-trail.d.ts.map +1 -0
- package/lib/types/index.d.ts +1 -0
- package/lib/types/index.d.ts.map +1 -1
- package/lib/types/integrations.d.ts +8 -0
- package/lib/types/integrations.d.ts.map +1 -1
- package/lib/types/interaction.d.ts +10 -11
- package/lib/types/interaction.d.ts.map +1 -1
- package/lib/types/project.d.ts +256 -1
- package/lib/types/project.d.ts.map +1 -1
- package/lib/types/prompt.d.ts +3 -4
- package/lib/types/prompt.d.ts.map +1 -1
- package/lib/types/skill.d.ts.map +1 -1
- package/lib/types/store/conversation-state.d.ts +7 -0
- package/lib/types/store/conversation-state.d.ts.map +1 -1
- package/lib/types/store/doc-analyzer.d.ts +1 -1
- package/lib/types/store/doc-analyzer.d.ts.map +1 -1
- package/lib/types/store/dsl-workflow.d.ts +28 -0
- package/lib/types/store/dsl-workflow.d.ts.map +1 -1
- package/lib/types/store/hive-memory.d.ts +116 -0
- package/lib/types/store/hive-memory.d.ts.map +1 -0
- package/lib/types/store/index.d.ts +2 -0
- package/lib/types/store/index.d.ts.map +1 -1
- package/lib/types/store/rendering.d.ts +193 -0
- package/lib/types/store/rendering.d.ts.map +1 -0
- package/lib/types/store/schedule.d.ts +2 -0
- package/lib/types/store/schedule.d.ts.map +1 -1
- package/lib/types/store/store.d.ts +31 -2
- package/lib/types/store/store.d.ts.map +1 -1
- package/lib/types/store/workflow.d.ts +145 -7
- package/lib/types/store/workflow.d.ts.map +1 -1
- package/lib/types/user.d.ts +9 -0
- package/lib/types/user.d.ts.map +1 -1
- package/lib/types/utils/schemas.d.ts +13 -4
- package/lib/types/utils/schemas.d.ts.map +1 -1
- package/lib/types/versions.d.ts +2 -1
- package/lib/types/versions.d.ts.map +1 -1
- package/lib/vertesia-common.js +1 -1
- package/lib/vertesia-common.js.map +1 -1
- package/package.json +2 -4
- package/src/apikey.ts +1 -0
- package/src/apps.ts +249 -1
- package/src/audit-trail.ts +61 -0
- package/src/index.ts +1 -0
- package/src/integrations.ts +10 -0
- package/src/interaction.ts +11 -12
- package/src/project.ts +309 -1
- package/src/prompt.ts +3 -4
- package/src/skill.ts +1 -0
- package/src/store/conversation-state.ts +9 -0
- package/src/store/doc-analyzer.ts +1 -1
- package/src/store/dsl-workflow.ts +26 -0
- package/src/store/hive-memory.ts +167 -0
- package/src/store/index.ts +2 -0
- package/src/store/rendering.ts +233 -0
- package/src/store/schedule.ts +3 -0
- package/src/store/store.ts +40 -4
- package/src/store/workflow.ts +191 -7
- package/src/user.ts +11 -0
- package/src/utils/schemas.ts +33 -11
- package/src/versions.ts +1 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vertesia/common",
|
|
3
|
-
"version": "1.0.0-dev.
|
|
3
|
+
"version": "1.0.0-dev.20260225.024852Z",
|
|
4
4
|
"license": "Apache-2.0",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"types": "./lib/types/index.d.ts",
|
|
@@ -18,7 +18,6 @@
|
|
|
18
18
|
"@rollup/plugin-commonjs": "^28.0.3",
|
|
19
19
|
"@rollup/plugin-node-resolve": "^16.0.1",
|
|
20
20
|
"@rollup/plugin-typescript": "^12.1.2",
|
|
21
|
-
"@types/json-schema": "^7.0.15",
|
|
22
21
|
"rollup": "^4.40.2",
|
|
23
22
|
"rollup-plugin-terser": "^7.0.2",
|
|
24
23
|
"ts-dual-module": "^0.6.3",
|
|
@@ -27,8 +26,7 @@
|
|
|
27
26
|
},
|
|
28
27
|
"dependencies": {
|
|
29
28
|
"ajv": "^8.17.1",
|
|
30
|
-
"
|
|
31
|
-
"@llumiverse/common": "1.0.0-dev.20260128.144200"
|
|
29
|
+
"@llumiverse/common": "1.0.0-dev.20260224.234313Z"
|
|
32
30
|
},
|
|
33
31
|
"repository": {
|
|
34
32
|
"type": "git",
|
package/src/apikey.ts
CHANGED
package/src/apps.ts
CHANGED
|
@@ -1,4 +1,20 @@
|
|
|
1
|
-
import { JSONSchema } from "@llumiverse/common";
|
|
1
|
+
import { JSONSchema, ToolDefinition } from "@llumiverse/common";
|
|
2
|
+
import { CatalogInteractionRef } from "./interaction.js";
|
|
3
|
+
import { InCodeTypeDefinition } from "./store/index.js";
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* Additional navigation item for an app's UI configuration.
|
|
7
|
+
* Used in AppUIConfig.navigation to define sidebar navigation entries in CompositeApp shell contexts.
|
|
8
|
+
* Icon values are Lucide icon component names or SVG content strings.
|
|
9
|
+
*/
|
|
10
|
+
export interface AppUINavItem {
|
|
11
|
+
/** Display label */
|
|
12
|
+
label: string;
|
|
13
|
+
/** Lucide icon name or SVG content string */
|
|
14
|
+
icon: string;
|
|
15
|
+
/** Route path relative to app base */
|
|
16
|
+
route: string;
|
|
17
|
+
}
|
|
2
18
|
|
|
3
19
|
export interface AppUIConfig {
|
|
4
20
|
/**
|
|
@@ -13,6 +29,18 @@ export interface AppUIConfig {
|
|
|
13
29
|
* - css - use CSS processing (like prefixing or other isolation techniques). Ligther but plugins may conflict with the host
|
|
14
30
|
*/
|
|
15
31
|
isolation?: "shadow" | "css";
|
|
32
|
+
/**
|
|
33
|
+
* Navigation items for the app's sidebar UI.
|
|
34
|
+
* Only applicable for apps with UI capability in shell contexts (ie. CompositeApp shell).
|
|
35
|
+
*/
|
|
36
|
+
navigation?: AppUINavItem[];
|
|
37
|
+
/**
|
|
38
|
+
* Where this app's UI can be displayed.
|
|
39
|
+
* - 'app_portal': Available in the main app portal (standalone)
|
|
40
|
+
* - 'composite_app': Available within a CompositeApp shell
|
|
41
|
+
* Defaults to ['app_portal', 'composite_app'] for new apps.
|
|
42
|
+
*/
|
|
43
|
+
available_in?: AppAvailableIn[];
|
|
16
44
|
}
|
|
17
45
|
|
|
18
46
|
/**
|
|
@@ -134,6 +162,36 @@ export function normalizeToolCollection(collection: ToolCollection): ToolCollect
|
|
|
134
162
|
return collection;
|
|
135
163
|
}
|
|
136
164
|
|
|
165
|
+
|
|
166
|
+
/**
|
|
167
|
+
* Tool definition with optional activation control for agent exposure.
|
|
168
|
+
*/
|
|
169
|
+
export interface AgentToolDefinition extends ToolDefinition {
|
|
170
|
+
/**
|
|
171
|
+
* The tool execution URL. It can be an absolute URL or a path in which case the URL is obtained
|
|
172
|
+
* using the base URL of the tool server API. Ex: http://tool-server.com/api/
|
|
173
|
+
* Example of relative URLs: "tools/my-tool-collection" or "/api/tools/my-tool-collection"
|
|
174
|
+
*/
|
|
175
|
+
url?: string;
|
|
176
|
+
/**
|
|
177
|
+
* The tool category if any - for UI purposes.
|
|
178
|
+
*/
|
|
179
|
+
category?: string;
|
|
180
|
+
/**
|
|
181
|
+
* Whether this tool is available by default.
|
|
182
|
+
* - true/undefined: Tool is always available to agents
|
|
183
|
+
* - false: Tool is only available when activated by a skill's related_tools
|
|
184
|
+
*/
|
|
185
|
+
default?: boolean;
|
|
186
|
+
/**
|
|
187
|
+
* For skill tools (learn_*): list of related tool names that become available
|
|
188
|
+
* when this skill is called. Used for dynamic tool discovery.
|
|
189
|
+
*/
|
|
190
|
+
related_tools?: string[];
|
|
191
|
+
}
|
|
192
|
+
|
|
193
|
+
export type AppCapabilities = 'ui' | 'tools' | 'interactions' | 'types';
|
|
194
|
+
export type AppAvailableIn = 'app_portal' | 'composite_app';
|
|
137
195
|
export interface AppManifestData {
|
|
138
196
|
/**
|
|
139
197
|
* The name of the app, used as the id in the system.
|
|
@@ -166,12 +224,17 @@ export interface AppManifestData {
|
|
|
166
224
|
|
|
167
225
|
status: "beta" | "stable" | "deprecated"
|
|
168
226
|
|
|
227
|
+
/**
|
|
228
|
+
* The UI configuration of the app. If not specified and the app "ui" is in the app capabilities
|
|
229
|
+
* then the ui configuration will be fetched from the endpoint property.
|
|
230
|
+
*/
|
|
169
231
|
ui?: AppUIConfig
|
|
170
232
|
|
|
171
233
|
/**
|
|
172
234
|
* A list of tool collections endpoints to be used by this app.
|
|
173
235
|
* A tools collection endpoint is an URL which may end with a `?import` query string.
|
|
174
236
|
* If the `?import` query string is used the tool will be imported as a javascript module and not executed through a POST on the collections endpoint.
|
|
237
|
+
* This feature is for advanced composition of tools. Prefer using endpoint.
|
|
175
238
|
*/
|
|
176
239
|
tool_collections?: ToolCollection[]
|
|
177
240
|
|
|
@@ -180,14 +243,81 @@ export interface AppManifestData {
|
|
|
180
243
|
* The URL must provide 2 endpoints:
|
|
181
244
|
* 1. GET URL - must return a JSON array with the list of interactions (as AppInteractionRef[])
|
|
182
245
|
* 2. GET URL/{interaction_name} - must return the full interaction definition for the specified interaction.
|
|
246
|
+
* This feature is for advanced composition of interactions. Prefer using endpoint.
|
|
183
247
|
*/
|
|
184
248
|
interactions?: string;
|
|
185
249
|
|
|
250
|
+
/**
|
|
251
|
+
* A JSON chema for the app installation settings.
|
|
252
|
+
* @deprecated Use endpoint to provide settings_schema instead
|
|
253
|
+
*/
|
|
254
|
+
settings_schema?: JSONSchema;
|
|
255
|
+
|
|
256
|
+
/** The following API is part of the second version of the manifest and deprectaes similar properties included directly in the manifest */
|
|
257
|
+
|
|
258
|
+
/**
|
|
259
|
+
* Describe the capabiltities of this app - which kind of contributions it provides.
|
|
260
|
+
*/
|
|
261
|
+
capabilities?: AppCapabilities[];
|
|
262
|
+
|
|
263
|
+
/**
|
|
264
|
+
* The app endpoint URL
|
|
265
|
+
* This URL should return a JSON object describing the contributions provided by the app.
|
|
266
|
+
* The object shape must satisfies AppPackage interface.
|
|
267
|
+
* The endpoint must support GET method and a `scope` parameter to filter which resources are included in the returned AppPackage:
|
|
268
|
+
* The supported scope values are:
|
|
269
|
+
* - ui
|
|
270
|
+
* - tools
|
|
271
|
+
* - interactions
|
|
272
|
+
* - types
|
|
273
|
+
* - settings
|
|
274
|
+
* - all (the default if no scope is provided)
|
|
275
|
+
* You can also use comma-separated values to combine scopes (e.g. "ui,tools").
|
|
276
|
+
*
|
|
277
|
+
* Example:
|
|
278
|
+
* - ?scope=ui,tools - returns only the UI configuration
|
|
279
|
+
*/
|
|
280
|
+
endpoint?: string;
|
|
281
|
+
}
|
|
282
|
+
export type AppPackageScope = 'ui' | 'tools' | 'interactions' | 'types' | 'settings' | 'widgets' | 'all';
|
|
283
|
+
export interface AppPackage {
|
|
284
|
+
/**
|
|
285
|
+
* The UI configuration of the app
|
|
286
|
+
*/
|
|
287
|
+
ui?: AppUIConfig
|
|
288
|
+
|
|
289
|
+
/**
|
|
290
|
+
* A list of tools exposed by the app.
|
|
291
|
+
*/
|
|
292
|
+
tools?: AgentToolDefinition[]
|
|
293
|
+
|
|
294
|
+
/**
|
|
295
|
+
* A list of interactions exposed by the app
|
|
296
|
+
*/
|
|
297
|
+
interactions?: CatalogInteractionRef[];
|
|
298
|
+
|
|
299
|
+
/**
|
|
300
|
+
* A list of types.
|
|
301
|
+
*/
|
|
302
|
+
types?: InCodeTypeDefinition[];
|
|
303
|
+
|
|
304
|
+
/**
|
|
305
|
+
* Widgets provided by the app.
|
|
306
|
+
*/
|
|
307
|
+
widgets?: Record<string, AppWidgetInfo>;
|
|
308
|
+
|
|
186
309
|
/**
|
|
187
310
|
* A JSON chema for the app installation settings.
|
|
188
311
|
*/
|
|
189
312
|
settings_schema?: JSONSchema;
|
|
190
313
|
}
|
|
314
|
+
|
|
315
|
+
export interface AppWidgetInfo {
|
|
316
|
+
collection: string;
|
|
317
|
+
skill: string;
|
|
318
|
+
url: string;
|
|
319
|
+
}
|
|
320
|
+
|
|
191
321
|
export interface AppManifest extends AppManifestData {
|
|
192
322
|
id: string;
|
|
193
323
|
account: string;
|
|
@@ -294,3 +424,121 @@ export interface OAuthMetadataResponse {
|
|
|
294
424
|
mcp_server_url: string;
|
|
295
425
|
metadata: any;
|
|
296
426
|
}
|
|
427
|
+
|
|
428
|
+
// ============================================================================
|
|
429
|
+
// CompositeApp Shell Configuration Types
|
|
430
|
+
// These types define the configuration for a CompositeApp shell that combines
|
|
431
|
+
// multiple apps into a unified experience with shared navigation and branding.
|
|
432
|
+
// ============================================================================
|
|
433
|
+
|
|
434
|
+
/**
|
|
435
|
+
* App navigation item display overrides.
|
|
436
|
+
* Allows customizing individual nav items for an app installation within the CompositeApp shell.
|
|
437
|
+
*/
|
|
438
|
+
export interface CompositeAppNavItemOverride {
|
|
439
|
+
/** Used as identifier to match the nav item to override -- does not change route path */
|
|
440
|
+
route: string;
|
|
441
|
+
/** Hide this nav item from the sidebar */
|
|
442
|
+
hidden?: boolean;
|
|
443
|
+
/** Override the displayed nav item label */
|
|
444
|
+
label?: string;
|
|
445
|
+
/** Override the displayed nav item icon (Lucide icon name or SVG content string) */
|
|
446
|
+
icon?: string;
|
|
447
|
+
//TODO: Set permissions for routes
|
|
448
|
+
}
|
|
449
|
+
|
|
450
|
+
/**
|
|
451
|
+
* Configuration entry for an individual app in the CompositeApp shell.
|
|
452
|
+
* References an app installation by name and allows customizing its appearance.
|
|
453
|
+
*/
|
|
454
|
+
export interface CompositeAppEntry {
|
|
455
|
+
/** App installation name (must match an installed app) */
|
|
456
|
+
appName: string;
|
|
457
|
+
/** Override the label displayed for the app */
|
|
458
|
+
labelOverride?: string;
|
|
459
|
+
/** Override the icon displayed for the app (Lucide icon name or SVG content string) */
|
|
460
|
+
iconOverride?: string;
|
|
461
|
+
/** Overrides for navigation items provided by the app */
|
|
462
|
+
navigationOverrides?: CompositeAppNavItemOverride[];
|
|
463
|
+
}
|
|
464
|
+
|
|
465
|
+
/**
|
|
466
|
+
* Logo overrides for the CompositeApp shell header.
|
|
467
|
+
* When provided, these URLs replace the default Vertesia logo.
|
|
468
|
+
*/
|
|
469
|
+
export interface CompositeAppLogoOverrides {
|
|
470
|
+
/** URL for light mode logo (overrides default Vertesia logo) */
|
|
471
|
+
lightModeUrl?: string;
|
|
472
|
+
/** URL for dark mode logo (overrides default Vertesia logo) */
|
|
473
|
+
darkModeUrl?: string;
|
|
474
|
+
}
|
|
475
|
+
|
|
476
|
+
|
|
477
|
+
/**
|
|
478
|
+
* Message banner overrides for the shell header.
|
|
479
|
+
*/
|
|
480
|
+
export type CompositeAppMessageStyle = 'foreground' | 'info' | 'success' | 'attention' | 'destructive';
|
|
481
|
+
export interface CompositeAppMessageOverrides {
|
|
482
|
+
/** Message text to display */
|
|
483
|
+
text?: string;
|
|
484
|
+
/** Whether the message is visible (defaults to true) */
|
|
485
|
+
visible?: boolean;
|
|
486
|
+
/** Text color style. Uses semantic colors */
|
|
487
|
+
style?: CompositeAppMessageStyle;
|
|
488
|
+
}
|
|
489
|
+
|
|
490
|
+
/**
|
|
491
|
+
* Switcher visibility overrides for the CompositeApp header.
|
|
492
|
+
*/
|
|
493
|
+
export interface CompositeAppSwitchersOverrides {
|
|
494
|
+
/** Whether to show the organization switcher (defaults to true) */
|
|
495
|
+
showOrganization?: boolean;
|
|
496
|
+
/** Whether to show the project switcher (defaults to true) */
|
|
497
|
+
showProject?: boolean;
|
|
498
|
+
}
|
|
499
|
+
|
|
500
|
+
/**
|
|
501
|
+
* Card display overrides for the CompositeApp in the App Portal.
|
|
502
|
+
* Similar to AppManifest display properties, but specific to the CompositeApp card.
|
|
503
|
+
* Allows customers to customize the app portal card (not otherwise possible if using a
|
|
504
|
+
* shared, Vertesia-managed manifest across accounts).
|
|
505
|
+
*/
|
|
506
|
+
export interface CompositeAppCardOverrides {
|
|
507
|
+
/** Whether to show the CompositeApp card in App Portal (default: false) */
|
|
508
|
+
visible?: boolean;
|
|
509
|
+
/** Override the card label (default: "Composite App") */
|
|
510
|
+
label?: string;
|
|
511
|
+
/** Override the card description */
|
|
512
|
+
description?: string;
|
|
513
|
+
/** Override the card icon (Lucide icon name or SVG content string) */
|
|
514
|
+
icon?: string;
|
|
515
|
+
/** Override the card color (e.g., "blue", "red", "purple") */
|
|
516
|
+
color?: string;
|
|
517
|
+
}
|
|
518
|
+
|
|
519
|
+
/**
|
|
520
|
+
* CompositeApp shell configuration.
|
|
521
|
+
* This is the main configuration interface for storing CompositeApp settings.
|
|
522
|
+
* Used as the MongoDB model for persisting CompositeApp configurations.
|
|
523
|
+
*/
|
|
524
|
+
export interface CompositeAppConfig {
|
|
525
|
+
/**
|
|
526
|
+
* The unique identifier for this CompositeApp configuration
|
|
527
|
+
* Undefined if the configuration doesn't exists yet.
|
|
528
|
+
*/
|
|
529
|
+
id?: string;
|
|
530
|
+
/** The project this CompositeApp belongs to */
|
|
531
|
+
project: string;
|
|
532
|
+
/** Card display overrides (includes visibility) */
|
|
533
|
+
card?: CompositeAppCardOverrides;
|
|
534
|
+
/** Optional logo overrides (replaces default Vertesia logo) */
|
|
535
|
+
logo?: CompositeAppLogoOverrides;
|
|
536
|
+
/** Optional message banner overrides */
|
|
537
|
+
message?: CompositeAppMessageOverrides;
|
|
538
|
+
/** Optional switcher visibility overrides */
|
|
539
|
+
switchers?: CompositeAppSwitchersOverrides;
|
|
540
|
+
/** List of apps to include in the CompositeApp */
|
|
541
|
+
apps: CompositeAppEntry[];
|
|
542
|
+
}
|
|
543
|
+
|
|
544
|
+
export type CompositeAppConfigPayload = Partial<Omit<CompositeAppConfig, 'id' | 'project'>>;
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
export type AuditAction =
|
|
2
|
+
| 'create'
|
|
3
|
+
| 'update'
|
|
4
|
+
| 'delete'
|
|
5
|
+
| 'bulk_update'
|
|
6
|
+
| 'bulk_delete'
|
|
7
|
+
| 'attach'
|
|
8
|
+
| 'detach'
|
|
9
|
+
| 'publish'
|
|
10
|
+
| 'unpublish';
|
|
11
|
+
|
|
12
|
+
export interface AuditTrailEvent {
|
|
13
|
+
event_type: 'audit';
|
|
14
|
+
action: AuditAction;
|
|
15
|
+
resource_type: string;
|
|
16
|
+
resource_id: string;
|
|
17
|
+
timestamp: string;
|
|
18
|
+
request_id: string;
|
|
19
|
+
status: number;
|
|
20
|
+
success: boolean;
|
|
21
|
+
principal_id: string | null;
|
|
22
|
+
principal_type: string | null;
|
|
23
|
+
principal_user_id: string | null;
|
|
24
|
+
roles: string[];
|
|
25
|
+
account_id: string | null;
|
|
26
|
+
project_id: string | null;
|
|
27
|
+
tenant_id: string | null;
|
|
28
|
+
account_name: string | null;
|
|
29
|
+
project_name: string | null;
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
export interface AuditTrailQuery {
|
|
33
|
+
/** Filter by action types */
|
|
34
|
+
actions?: AuditAction[];
|
|
35
|
+
/** Filter by resource types */
|
|
36
|
+
resourceTypes?: string[];
|
|
37
|
+
/** Filter by resource ID */
|
|
38
|
+
resourceId?: string;
|
|
39
|
+
/** Filter by principal ID (matches principal_id column — API keys, service accounts) */
|
|
40
|
+
principalId?: string;
|
|
41
|
+
/** Filter by principal user ID (matches principal_user_id column — human users) */
|
|
42
|
+
principalUserId?: string;
|
|
43
|
+
/** Filter by project ID */
|
|
44
|
+
projectId?: string;
|
|
45
|
+
/** Start time (ISO string) */
|
|
46
|
+
from?: string;
|
|
47
|
+
/** End time (ISO string) */
|
|
48
|
+
to?: string;
|
|
49
|
+
/** Pagination: number of items to return (default 50, max 200) */
|
|
50
|
+
limit?: number;
|
|
51
|
+
/** Pagination: offset */
|
|
52
|
+
offset?: number;
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
export interface AuditTrailResponse {
|
|
56
|
+
events: AuditTrailEvent[];
|
|
57
|
+
/** Whether there are more events after this page */
|
|
58
|
+
hasNext: boolean;
|
|
59
|
+
limit: number;
|
|
60
|
+
offset: number;
|
|
61
|
+
}
|
package/src/index.ts
CHANGED
package/src/integrations.ts
CHANGED
|
@@ -29,6 +29,14 @@ export interface SerperConfiguration extends IntegrationConfigurationBase {
|
|
|
29
29
|
url?: string;
|
|
30
30
|
}
|
|
31
31
|
|
|
32
|
+
export interface ExaConfiguration extends IntegrationConfigurationBase {
|
|
33
|
+
api_key: string;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
export interface LinkupConfiguration extends IntegrationConfigurationBase {
|
|
37
|
+
api_key: string;
|
|
38
|
+
}
|
|
39
|
+
|
|
32
40
|
export interface ResendConfiguration extends IntegrationConfigurationBase {
|
|
33
41
|
/** Resend API key for sending emails */
|
|
34
42
|
api_key: string;
|
|
@@ -67,6 +75,8 @@ export enum SupportedIntegrations {
|
|
|
67
75
|
aws = "aws",
|
|
68
76
|
magic_pdf = "magic_pdf",
|
|
69
77
|
serper = "serper",
|
|
78
|
+
exa = "exa",
|
|
79
|
+
linkup = "linkup",
|
|
70
80
|
resend = "resend",
|
|
71
81
|
ask_user_webhook = "ask_user_webhook",
|
|
72
82
|
}
|
package/src/interaction.ts
CHANGED
|
@@ -9,7 +9,6 @@ import type {
|
|
|
9
9
|
ToolDefinition,
|
|
10
10
|
ToolUse,
|
|
11
11
|
} from "@llumiverse/common";
|
|
12
|
-
import type { JSONSchema4 } from "json-schema";
|
|
13
12
|
|
|
14
13
|
import { ExecutionTokenUsage } from "@llumiverse/common";
|
|
15
14
|
|
|
@@ -41,8 +40,8 @@ export interface InteractionExecutionError {
|
|
|
41
40
|
export interface ConversationStripOptions {
|
|
42
41
|
/**
|
|
43
42
|
* Number of turns to keep images before stripping them.
|
|
44
|
-
* - 0: Strip images immediately after each turn
|
|
45
|
-
* - N > 0: Keep images for N turns before stripping
|
|
43
|
+
* - 0: Strip images immediately after each turn
|
|
44
|
+
* - N > 0: Keep images for N turns before stripping (default: 5)
|
|
46
45
|
* - Infinity: Never strip images
|
|
47
46
|
*/
|
|
48
47
|
images_after_turns?: number;
|
|
@@ -328,7 +327,7 @@ export const InteractionRefWithSchemaPopulate =
|
|
|
328
327
|
`${InteractionRefPopulate} result_schema`;
|
|
329
328
|
|
|
330
329
|
export interface InteractionRefWithSchema extends Omit<InteractionRef, "prompts"> {
|
|
331
|
-
result_schema?:
|
|
330
|
+
result_schema?: JSONSchema;
|
|
332
331
|
prompts?: PromptSegmentDef<PromptTemplateRefWithSchema>[];
|
|
333
332
|
}
|
|
334
333
|
|
|
@@ -401,7 +400,7 @@ export interface InteractionData {
|
|
|
401
400
|
project: string | ProjectRef;
|
|
402
401
|
tags: string[];
|
|
403
402
|
agent_runner_options?: AgentRunnerOptions;
|
|
404
|
-
result_schema?:
|
|
403
|
+
result_schema?: JSONSchema | SchemaRef;
|
|
405
404
|
environment?: string | ExecutionEnvironmentRef;
|
|
406
405
|
model?: string;
|
|
407
406
|
model_options?: ModelOptions;
|
|
@@ -418,7 +417,7 @@ export interface Interaction extends InteractionData {
|
|
|
418
417
|
visibility: InteractionVisibility;
|
|
419
418
|
version: number;
|
|
420
419
|
test_data?: JSONObject;
|
|
421
|
-
interaction_schema?:
|
|
420
|
+
interaction_schema?: JSONSchema | SchemaRef;
|
|
422
421
|
cache_policy?: CachePolicy;
|
|
423
422
|
prompts: PromptSegmentDef[];
|
|
424
423
|
// only for drafts - when it was last published
|
|
@@ -468,7 +467,7 @@ export interface InteractionUpdatePayload
|
|
|
468
467
|
"result_schema" | "id" | "created_at" | "updated_at" | "created_by" | "updated_by" | "project"
|
|
469
468
|
>
|
|
470
469
|
> {
|
|
471
|
-
result_schema?:
|
|
470
|
+
result_schema?: JSONSchema | null;
|
|
472
471
|
}
|
|
473
472
|
|
|
474
473
|
export interface InteractionPublishPayload {
|
|
@@ -490,7 +489,7 @@ export interface InteractionExecutionPayload {
|
|
|
490
489
|
data?: Record<string, any> | `memory:${string}`;
|
|
491
490
|
config?: InteractionExecutionConfiguration;
|
|
492
491
|
//Use null to explicitly state no schema, will not fallback to interaction schema
|
|
493
|
-
result_schema?:
|
|
492
|
+
result_schema?: JSONSchema | null;
|
|
494
493
|
stream?: boolean;
|
|
495
494
|
do_validate?: boolean;
|
|
496
495
|
tags?: string | string[]; // tags to be added to the execution run
|
|
@@ -705,7 +704,7 @@ export interface AsyncConversationExecutionPayload extends AsyncExecutionPayload
|
|
|
705
704
|
/**
|
|
706
705
|
* The token threshold in thousands (K) for creating checkpoints.
|
|
707
706
|
* If total tokens exceed this value, a checkpoint will be created.
|
|
708
|
-
* If not specified, default
|
|
707
|
+
* If not specified, the default is computed from the selected model context window (75%).
|
|
709
708
|
*/
|
|
710
709
|
checkpoint_tokens?: number;
|
|
711
710
|
|
|
@@ -926,8 +925,8 @@ export interface BaseExecutionRun<P = any> {
|
|
|
926
925
|
interaction_code?: string; // Interaction code name in case of in-code interaction (not stored in the DB as an Interaction document)
|
|
927
926
|
/** Environment reference - populated with full object in API responses */
|
|
928
927
|
environment: ExecutionEnvironmentRef;
|
|
929
|
-
modelId
|
|
930
|
-
result_schema:
|
|
928
|
+
modelId?: string; //Can be undefined for virtual environments. In most cases should be defined.
|
|
929
|
+
result_schema: JSONSchema;
|
|
931
930
|
ttl: number;
|
|
932
931
|
status: ExecutionRunStatus;
|
|
933
932
|
finish_reason?: string;
|
|
@@ -1186,4 +1185,4 @@ export interface BuiltinToolsCatalogResponse {
|
|
|
1186
1185
|
* Total number of tools in the catalog
|
|
1187
1186
|
*/
|
|
1188
1187
|
total_tools: number;
|
|
1189
|
-
}
|
|
1188
|
+
}
|