bruce-models 7.1.33 → 7.1.34
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/dist/bruce-models.es5.js +108 -2
- package/dist/bruce-models.es5.js.map +1 -1
- package/dist/bruce-models.umd.js +103 -1
- package/dist/bruce-models.umd.js.map +1 -1
- package/dist/lib/bruce-models.js +2 -1
- package/dist/lib/bruce-models.js.map +1 -1
- package/dist/lib/data-transform/data-transform.js +120 -0
- package/dist/lib/data-transform/data-transform.js.map +1 -0
- package/dist/types/bruce-models.d.ts +2 -1
- package/dist/types/data-transform/data-transform.d.ts +133 -0
- package/package.json +1 -1
package/dist/bruce-models.es5.js
CHANGED
|
@@ -15939,6 +15939,112 @@ var DataLab;
|
|
|
15939
15939
|
DataLab.Run = Run;
|
|
15940
15940
|
})(DataLab || (DataLab = {}));
|
|
15941
15941
|
|
|
15942
|
+
/**
|
|
15943
|
+
* Describes the "Data Transform" concept within Nextspace.
|
|
15944
|
+
*/
|
|
15945
|
+
var DataTransform;
|
|
15946
|
+
(function (DataTransform) {
|
|
15947
|
+
/**
|
|
15948
|
+
* Supported Logic Flow diagram item types.
|
|
15949
|
+
*/
|
|
15950
|
+
let ELogicFlowDiagramItemType;
|
|
15951
|
+
(function (ELogicFlowDiagramItemType) {
|
|
15952
|
+
ELogicFlowDiagramItemType["InputValue"] = "input-value";
|
|
15953
|
+
ELogicFlowDiagramItemType["OutputValue"] = "output-value";
|
|
15954
|
+
ELogicFlowDiagramItemType["If"] = "if";
|
|
15955
|
+
ELogicFlowDiagramItemType["Formula"] = "formula";
|
|
15956
|
+
ELogicFlowDiagramItemType["Switch"] = "switch";
|
|
15957
|
+
})(ELogicFlowDiagramItemType = DataTransform.ELogicFlowDiagramItemType || (DataTransform.ELogicFlowDiagramItemType = {}));
|
|
15958
|
+
/**
|
|
15959
|
+
* Supported Logic Flow connection point types.
|
|
15960
|
+
*/
|
|
15961
|
+
let ELogicFlowConnectionPointType;
|
|
15962
|
+
(function (ELogicFlowConnectionPointType) {
|
|
15963
|
+
ELogicFlowConnectionPointType["Input"] = "input";
|
|
15964
|
+
ELogicFlowConnectionPointType["Output"] = "output";
|
|
15965
|
+
})(ELogicFlowConnectionPointType = DataTransform.ELogicFlowConnectionPointType || (DataTransform.ELogicFlowConnectionPointType = {}));
|
|
15966
|
+
/**
|
|
15967
|
+
* Supported Logic Flow connection end roles.
|
|
15968
|
+
*/
|
|
15969
|
+
let ELogicFlowConnectionEndRole;
|
|
15970
|
+
(function (ELogicFlowConnectionEndRole) {
|
|
15971
|
+
ELogicFlowConnectionEndRole["From"] = "from";
|
|
15972
|
+
ELogicFlowConnectionEndRole["To"] = "to";
|
|
15973
|
+
})(ELogicFlowConnectionEndRole = DataTransform.ELogicFlowConnectionEndRole || (DataTransform.ELogicFlowConnectionEndRole = {}));
|
|
15974
|
+
/**
|
|
15975
|
+
* Requests a suggested Logic Flow diagram from a natural-language prompt.
|
|
15976
|
+
* Route: POST v1/entityType/{entityType_id}/DataTransform/SuggestLogicFlowDiagram
|
|
15977
|
+
*/
|
|
15978
|
+
function SuggestLogicFlowDiagramByPrompt(params) {
|
|
15979
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
15980
|
+
let { api, entityTypeId, prompt, model, maxNodes, dataTransformId, dataTransform, dataTransformContext, sourceDataSchema, destinationDataSchema, inputAttributes, outputAttributes, req: reqParams } = params;
|
|
15981
|
+
if (!entityTypeId) {
|
|
15982
|
+
throw ("Entity Type ID is required.");
|
|
15983
|
+
}
|
|
15984
|
+
prompt = prompt === null || prompt === void 0 ? void 0 : prompt.trim();
|
|
15985
|
+
if (!prompt) {
|
|
15986
|
+
throw ("Prompt is required.");
|
|
15987
|
+
}
|
|
15988
|
+
if (!api) {
|
|
15989
|
+
api = ENVIRONMENT.Api().GetBruceApi();
|
|
15990
|
+
}
|
|
15991
|
+
const body = {
|
|
15992
|
+
Prompt: prompt
|
|
15993
|
+
};
|
|
15994
|
+
if (model) {
|
|
15995
|
+
body.Model = model;
|
|
15996
|
+
}
|
|
15997
|
+
if (typeof maxNodes == "number" && !isNaN(maxNodes)) {
|
|
15998
|
+
body.MaxNodes = maxNodes;
|
|
15999
|
+
}
|
|
16000
|
+
if (typeof dataTransformId == "number" && dataTransformId > 0) {
|
|
16001
|
+
body["DataTransform.ID"] = dataTransformId;
|
|
16002
|
+
}
|
|
16003
|
+
if (dataTransform != null) {
|
|
16004
|
+
body.DataTransform = dataTransform;
|
|
16005
|
+
}
|
|
16006
|
+
if (dataTransformContext != null) {
|
|
16007
|
+
body.DataTransformContext = dataTransformContext;
|
|
16008
|
+
}
|
|
16009
|
+
if (sourceDataSchema != null) {
|
|
16010
|
+
body.SourceDataSchema = sourceDataSchema;
|
|
16011
|
+
}
|
|
16012
|
+
if (destinationDataSchema != null) {
|
|
16013
|
+
body.DestinationDataSchema = destinationDataSchema;
|
|
16014
|
+
}
|
|
16015
|
+
if (inputAttributes === null || inputAttributes === void 0 ? void 0 : inputAttributes.length) {
|
|
16016
|
+
body.InputAttributes = inputAttributes;
|
|
16017
|
+
}
|
|
16018
|
+
if (outputAttributes === null || outputAttributes === void 0 ? void 0 : outputAttributes.length) {
|
|
16019
|
+
body.OutputAttributes = outputAttributes;
|
|
16020
|
+
}
|
|
16021
|
+
const route = `v1/entityType/${Api.Encode(entityTypeId)}/DataTransform/SuggestLogicFlowDiagram`;
|
|
16022
|
+
const response = yield api.POST(route, body, Api.PrepReqParams(reqParams));
|
|
16023
|
+
let diagram = (response === null || response === void 0 ? void 0 : response.diagram)
|
|
16024
|
+
|| (response === null || response === void 0 ? void 0 : response.Diagram)
|
|
16025
|
+
|| (response === null || response === void 0 ? void 0 : response.LogicFlowDiagram)
|
|
16026
|
+
|| (response === null || response === void 0 ? void 0 : response.result)
|
|
16027
|
+
|| (response === null || response === void 0 ? void 0 : response.Result)
|
|
16028
|
+
|| response;
|
|
16029
|
+
if (typeof diagram == "string") {
|
|
16030
|
+
try {
|
|
16031
|
+
diagram = JSON.parse(diagram);
|
|
16032
|
+
}
|
|
16033
|
+
catch (e) {
|
|
16034
|
+
// Keep original shape if parse fails.
|
|
16035
|
+
}
|
|
16036
|
+
}
|
|
16037
|
+
if (!diagram || typeof diagram != "object") {
|
|
16038
|
+
throw ("No Logic Flow Diagram was returned by the suggestion API.");
|
|
16039
|
+
}
|
|
16040
|
+
return {
|
|
16041
|
+
diagram: diagram
|
|
16042
|
+
};
|
|
16043
|
+
});
|
|
16044
|
+
}
|
|
16045
|
+
DataTransform.SuggestLogicFlowDiagramByPrompt = SuggestLogicFlowDiagramByPrompt;
|
|
16046
|
+
})(DataTransform || (DataTransform = {}));
|
|
16047
|
+
|
|
15942
16048
|
var DataLabGroup;
|
|
15943
16049
|
(function (DataLabGroup) {
|
|
15944
16050
|
/**
|
|
@@ -18111,7 +18217,7 @@ var ChangeSet;
|
|
|
18111
18217
|
})(ChangeSet || (ChangeSet = {}));
|
|
18112
18218
|
|
|
18113
18219
|
// This is updated with the package.json version on build.
|
|
18114
|
-
const VERSION = "7.1.
|
|
18220
|
+
const VERSION = "7.1.34";
|
|
18115
18221
|
|
|
18116
|
-
export { VERSION, Assembly, AnnDocument, CustomForm, AbstractApi, Api, BruceApi, GlobalApi, GuardianApi, ApiGetters, Calculator, Bounds, BruceEvent, CacheControl, Camera, Cartes, Carto, Color, DelayQueue, Geometry, UTC, BruceVariable, LRUCache, GeoJson, EntityAttachmentType, EntityAttachment, EntityComment, EntityLink, EntityLod, EntityLodCategory, EntityRelationType, EntityRelation, EntitySource, EntityTag, EntityTypeTrigger, EntityType, Entity, EntityCoords, EntityAttribute, EntityHistoricData, EntityTableView, DashboardView, Comment, ClientFile, ProgramKey, ZoomControl, MenuItem, ProjectViewBookmark, ProjectView, ProjectViewLegacyTile, ProjectViewTile, ProjectViewLegacy, ProjectViewLegacyBookmark, ProjectViewBookmarkGroup, PendingAction, MessageBroker, HostingLocation, Style, Tileset, Permission, Session, UserGroup, User, UserMfaMethod, Account, AccountInvite, AccountFeatures, AccountLimits, AccountTemplate, AccountType, EncryptUtils, MathUtils, ObjectUtils, PathUtils, UrlUtils, DataLab, DataLabGroup, DataFeed, ImportAssembly, ImportCad, ImportCsv, ImportJson, ImportGeoJson, ImportKml, ImportLcc, ImportedFile, ExportBrz, ExportUsd, Markup, Uploader, Plugin, ENVIRONMENT, DataSource, Scenario, Tracking, NAVIGATOR_CHAT_EVENT_ENTITY_HIGHLIGHT_APPLIED, NAVIGATOR_CHAT_EVENT_SCENE_CONTEXT_PREFETCHED, NavigatorChatClient, NavigatorMcpWebSocketClient, ChangeSet };
|
|
18222
|
+
export { VERSION, Assembly, AnnDocument, CustomForm, AbstractApi, Api, BruceApi, GlobalApi, GuardianApi, ApiGetters, Calculator, Bounds, BruceEvent, CacheControl, Camera, Cartes, Carto, Color, DelayQueue, Geometry, UTC, BruceVariable, LRUCache, GeoJson, EntityAttachmentType, EntityAttachment, EntityComment, EntityLink, EntityLod, EntityLodCategory, EntityRelationType, EntityRelation, EntitySource, EntityTag, EntityTypeTrigger, EntityType, Entity, EntityCoords, EntityAttribute, EntityHistoricData, EntityTableView, DashboardView, Comment, ClientFile, ProgramKey, ZoomControl, MenuItem, ProjectViewBookmark, ProjectView, ProjectViewLegacyTile, ProjectViewTile, ProjectViewLegacy, ProjectViewLegacyBookmark, ProjectViewBookmarkGroup, PendingAction, MessageBroker, HostingLocation, Style, Tileset, Permission, Session, UserGroup, User, UserMfaMethod, Account, AccountInvite, AccountFeatures, AccountLimits, AccountTemplate, AccountType, EncryptUtils, MathUtils, ObjectUtils, PathUtils, UrlUtils, DataLab, DataTransform, DataLabGroup, DataFeed, ImportAssembly, ImportCad, ImportCsv, ImportJson, ImportGeoJson, ImportKml, ImportLcc, ImportedFile, ExportBrz, ExportUsd, Markup, Uploader, Plugin, ENVIRONMENT, DataSource, Scenario, Tracking, NAVIGATOR_CHAT_EVENT_ENTITY_HIGHLIGHT_APPLIED, NAVIGATOR_CHAT_EVENT_SCENE_CONTEXT_PREFETCHED, NavigatorChatClient, NavigatorMcpWebSocketClient, ChangeSet };
|
|
18117
18223
|
//# sourceMappingURL=bruce-models.es5.js.map
|