@finos/legend-application-marketplace 0.2.26 → 0.2.28
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/__lib__/LegendMarketplaceNavigation.d.ts +4 -0
- package/lib/__lib__/LegendMarketplaceNavigation.d.ts.map +1 -1
- package/lib/__lib__/LegendMarketplaceNavigation.js +4 -0
- package/lib/__lib__/LegendMarketplaceNavigation.js.map +1 -1
- package/lib/__lib__/LegendMarketplaceTelemetryHelper.d.ts +2 -2
- package/lib/__lib__/LegendMarketplaceTelemetryHelper.d.ts.map +1 -1
- package/lib/__lib__/LegendMarketplaceTelemetryHelper.js +2 -2
- package/lib/__lib__/LegendMarketplaceTelemetryHelper.js.map +1 -1
- package/lib/application/LegendMarketplaceApplicationConfig.d.ts +2 -0
- package/lib/application/LegendMarketplaceApplicationConfig.d.ts.map +1 -1
- package/lib/application/LegendMarketplaceApplicationConfig.js +4 -0
- package/lib/application/LegendMarketplaceApplicationConfig.js.map +1 -1
- package/lib/components/__test-utils__/LegendMarketplaceStoreTestUtils.d.ts.map +1 -1
- package/lib/components/__test-utils__/LegendMarketplaceStoreTestUtils.js +11 -6
- package/lib/components/__test-utils__/LegendMarketplaceStoreTestUtils.js.map +1 -1
- package/lib/index.css +2 -2
- package/lib/index.css.map +1 -1
- package/lib/package.json +1 -1
- package/lib/pages/Lakehouse/entitlements/EntitlementsClosedContractsDashboard.d.ts.map +1 -1
- package/lib/pages/Lakehouse/entitlements/EntitlementsClosedContractsDashboard.js +10 -7
- package/lib/pages/Lakehouse/entitlements/EntitlementsClosedContractsDashboard.js.map +1 -1
- package/lib/pages/Lakehouse/entitlements/EntitlementsPendingContractsDashboard.d.ts.map +1 -1
- package/lib/pages/Lakehouse/entitlements/EntitlementsPendingContractsDashboard.js +3 -2
- package/lib/pages/Lakehouse/entitlements/EntitlementsPendingContractsDashboard.js.map +1 -1
- package/lib/pages/Lakehouse/entitlements/EntitlementsPendingTasksDashboard.d.ts +1 -1
- package/lib/pages/Lakehouse/entitlements/EntitlementsPendingTasksDashboard.d.ts.map +1 -1
- package/lib/pages/Lakehouse/entitlements/EntitlementsPendingTasksDashboard.js +67 -38
- package/lib/pages/Lakehouse/entitlements/EntitlementsPendingTasksDashboard.js.map +1 -1
- package/lib/stores/LegendMarketplaceBaseStore.d.ts.map +1 -1
- package/lib/stores/LegendMarketplaceBaseStore.js +1 -0
- package/lib/stores/LegendMarketplaceBaseStore.js.map +1 -1
- package/lib/stores/ai/LegendMarketplaceAIChatStore.d.ts +1 -2
- package/lib/stores/ai/LegendMarketplaceAIChatStore.d.ts.map +1 -1
- package/lib/stores/ai/LegendMarketplaceAIChatStore.js +12 -8
- package/lib/stores/ai/LegendMarketplaceAIChatStore.js.map +1 -1
- package/lib/stores/lakehouse/LegendMarketplaceProductViewerStore.d.ts.map +1 -1
- package/lib/stores/lakehouse/LegendMarketplaceProductViewerStore.js +11 -1
- package/lib/stores/lakehouse/LegendMarketplaceProductViewerStore.js.map +1 -1
- package/lib/stores/lakehouse/entitlements/EntitlementsDashboardState.d.ts +39 -15
- package/lib/stores/lakehouse/entitlements/EntitlementsDashboardState.d.ts.map +1 -1
- package/lib/stores/lakehouse/entitlements/EntitlementsDashboardState.js +324 -39
- package/lib/stores/lakehouse/entitlements/EntitlementsDashboardState.js.map +1 -1
- package/lib/utils/EntitlementsUtils.d.ts +2 -2
- package/lib/utils/EntitlementsUtils.d.ts.map +1 -1
- package/lib/utils/EntitlementsUtils.js +11 -2
- package/lib/utils/EntitlementsUtils.js.map +1 -1
- package/lib/utils/LakehouseUtils.d.ts +2 -1
- package/lib/utils/LakehouseUtils.d.ts.map +1 -1
- package/lib/utils/LakehouseUtils.js +31 -2
- package/lib/utils/LakehouseUtils.js.map +1 -1
- package/package.json +12 -12
- package/src/__lib__/LegendMarketplaceNavigation.ts +17 -0
- package/src/__lib__/LegendMarketplaceTelemetryHelper.ts +6 -6
- package/src/application/LegendMarketplaceApplicationConfig.ts +7 -0
- package/src/components/__test-utils__/LegendMarketplaceStoreTestUtils.tsx +20 -8
- package/src/pages/Lakehouse/entitlements/EntitlementsClosedContractsDashboard.tsx +13 -5
- package/src/pages/Lakehouse/entitlements/EntitlementsPendingContractsDashboard.tsx +5 -1
- package/src/pages/Lakehouse/entitlements/EntitlementsPendingTasksDashboard.tsx +306 -299
- package/src/stores/LegendMarketplaceBaseStore.ts +1 -0
- package/src/stores/ai/LegendMarketplaceAIChatStore.ts +14 -9
- package/src/stores/lakehouse/LegendMarketplaceProductViewerStore.ts +38 -0
- package/src/stores/lakehouse/entitlements/EntitlementsDashboardState.ts +538 -91
- package/src/utils/EntitlementsUtils.tsx +13 -2
- package/src/utils/LakehouseUtils.tsx +80 -1
|
@@ -211,6 +211,7 @@ export class LegendMarketplaceBaseStore {
|
|
|
211
211
|
);
|
|
212
212
|
this.engineServerClient = this.remoteEngine.getEngineServerClient();
|
|
213
213
|
this.engineServerClient.setTracerService(applicationStore.tracerService);
|
|
214
|
+
this.engineServerClient.setZipkinUrl(applicationStore.config.zipkinUrl);
|
|
214
215
|
|
|
215
216
|
// User search
|
|
216
217
|
if (this.pluginManager.getUserPlugins().length > 0) {
|
|
@@ -25,7 +25,6 @@ import {
|
|
|
25
25
|
import {
|
|
26
26
|
type GeneratorFn,
|
|
27
27
|
type PlainObject,
|
|
28
|
-
ActionState,
|
|
29
28
|
assertErrorThrown,
|
|
30
29
|
guaranteeNonNullable,
|
|
31
30
|
} from '@finos/legend-shared';
|
|
@@ -196,8 +195,6 @@ export class LegendMarketplaceAIChatStore {
|
|
|
196
195
|
}[] = [];
|
|
197
196
|
selectedDataProductId: string | undefined = undefined;
|
|
198
197
|
|
|
199
|
-
readonly searchState = ActionState.create();
|
|
200
|
-
|
|
201
198
|
constructor(baseStore: LegendMarketplaceBaseStore) {
|
|
202
199
|
makeObservable(this, {
|
|
203
200
|
stage: observable,
|
|
@@ -751,6 +748,7 @@ export class LegendMarketplaceAIChatStore {
|
|
|
751
748
|
this.messages = [...this.messages, ...createMessagePair(trimmed)];
|
|
752
749
|
|
|
753
750
|
const setMessages = this.createMessageSetter();
|
|
751
|
+
const startTime = Date.now();
|
|
754
752
|
|
|
755
753
|
try {
|
|
756
754
|
if (this.selectedProductCoordinates) {
|
|
@@ -823,7 +821,7 @@ export class LegendMarketplaceAIChatStore {
|
|
|
823
821
|
finishWithThinkingError(
|
|
824
822
|
setMessages,
|
|
825
823
|
error.message,
|
|
826
|
-
|
|
824
|
+
startTime,
|
|
827
825
|
classifyError(error),
|
|
828
826
|
);
|
|
829
827
|
this.stage = MarketplaceAIChatStage.IDLE;
|
|
@@ -1046,6 +1044,7 @@ export class LegendMarketplaceAIChatStore {
|
|
|
1046
1044
|
this.messages = [...this.messages, ...createMessagePair(trimmed)];
|
|
1047
1045
|
|
|
1048
1046
|
const setMessages = this.createMessageSetter();
|
|
1047
|
+
const startTime = Date.now();
|
|
1049
1048
|
|
|
1050
1049
|
try {
|
|
1051
1050
|
this.stage = MarketplaceAIChatStage.QUERYING;
|
|
@@ -1060,7 +1059,7 @@ export class LegendMarketplaceAIChatStore {
|
|
|
1060
1059
|
finishWithThinkingError(
|
|
1061
1060
|
setMessages,
|
|
1062
1061
|
error.message,
|
|
1063
|
-
|
|
1062
|
+
startTime,
|
|
1064
1063
|
classifyError(error),
|
|
1065
1064
|
);
|
|
1066
1065
|
} finally {
|
|
@@ -1453,7 +1452,8 @@ export class LegendMarketplaceAIChatStore {
|
|
|
1453
1452
|
? this.buildContextPromise(question, metadata, setMessages)
|
|
1454
1453
|
: Promise.resolve();
|
|
1455
1454
|
|
|
1456
|
-
const
|
|
1455
|
+
const entityNames = [metadata.name, ...services.map((s) => s.title)];
|
|
1456
|
+
const fastIntent = classifyQuestionIntentFast(question, true, entityNames);
|
|
1457
1457
|
|
|
1458
1458
|
// ── Pure METADATA: fast classifier is confident, no data signals ──
|
|
1459
1459
|
if (
|
|
@@ -1783,6 +1783,7 @@ export class LegendMarketplaceAIChatStore {
|
|
|
1783
1783
|
if (!prompt) {
|
|
1784
1784
|
return undefined;
|
|
1785
1785
|
}
|
|
1786
|
+
const correctionStart = Date.now();
|
|
1786
1787
|
try {
|
|
1787
1788
|
const raw = await plugin.callLLM(prompt, config);
|
|
1788
1789
|
const trimmed = cleanLlmSqlResponse(raw);
|
|
@@ -1797,7 +1798,7 @@ export class LegendMarketplaceAIChatStore {
|
|
|
1797
1798
|
config,
|
|
1798
1799
|
);
|
|
1799
1800
|
if (retryResult.rows.length > 0) {
|
|
1800
|
-
const sqlGenTime = elapsedSeconds(
|
|
1801
|
+
const sqlGenTime = elapsedSeconds(correctionStart, 2);
|
|
1801
1802
|
completeThinkingSteps(setMessages);
|
|
1802
1803
|
updateLastAssistant(setMessages, () => ({
|
|
1803
1804
|
sql: trimmed,
|
|
@@ -1806,8 +1807,12 @@ export class LegendMarketplaceAIChatStore {
|
|
|
1806
1807
|
}));
|
|
1807
1808
|
return { sql: trimmed, result: retryResult };
|
|
1808
1809
|
}
|
|
1809
|
-
} catch {
|
|
1810
|
-
|
|
1810
|
+
} catch (correctionError) {
|
|
1811
|
+
assertErrorThrown(correctionError);
|
|
1812
|
+
addThinkingStep(
|
|
1813
|
+
setMessages,
|
|
1814
|
+
`Filter correction failed: ${correctionError.message.slice(0, 120)}`,
|
|
1815
|
+
);
|
|
1811
1816
|
}
|
|
1812
1817
|
return undefined;
|
|
1813
1818
|
}
|
|
@@ -62,6 +62,7 @@ import {
|
|
|
62
62
|
import { buildGraphForDataProduct } from '../../utils/LakehouseUtils.js';
|
|
63
63
|
import {
|
|
64
64
|
type Entity,
|
|
65
|
+
type ProjectGAVCoordinates,
|
|
65
66
|
type StoredFileGeneration,
|
|
66
67
|
parseGAVCoordinates,
|
|
67
68
|
parseProjectIdentifier,
|
|
@@ -70,6 +71,7 @@ import { deserialize } from 'serializr';
|
|
|
70
71
|
import {
|
|
71
72
|
EXTERNAL_APPLICATION_NAVIGATION__generateDataProductModelQueryUrl,
|
|
72
73
|
EXTERNAL_APPLICATION_NAVIGATION__generateDataProductSampleQueryUrl,
|
|
74
|
+
EXTERNAL_APPLICATION_NAVIGATION__generateIngestQueryUrl,
|
|
73
75
|
EXTERNAL_APPLICATION_NAVIGATION__generateDataSpaceQueryEditorUrl,
|
|
74
76
|
EXTERNAL_APPLICATION_NAVIGATION__generateStudioSDLCProjectViewUrl,
|
|
75
77
|
generateLakehouseDataProductPath,
|
|
@@ -423,6 +425,25 @@ export class LegendMarketplaceProductViewerStore {
|
|
|
423
425
|
);
|
|
424
426
|
}
|
|
425
427
|
: undefined,
|
|
428
|
+
openIngestQuery: projectGAV
|
|
429
|
+
? (
|
|
430
|
+
gav: ProjectGAVCoordinates,
|
|
431
|
+
ingestDefinitionPath: string,
|
|
432
|
+
dataSet: string,
|
|
433
|
+
): void => {
|
|
434
|
+
this.marketplaceBaseStore.applicationStore.navigationService.navigator.visitAddress(
|
|
435
|
+
EXTERNAL_APPLICATION_NAVIGATION__generateIngestQueryUrl(
|
|
436
|
+
this.marketplaceBaseStore.applicationStore.config
|
|
437
|
+
.queryApplicationUrl,
|
|
438
|
+
gav.groupId,
|
|
439
|
+
gav.artifactId,
|
|
440
|
+
gav.versionId,
|
|
441
|
+
ingestDefinitionPath,
|
|
442
|
+
dataSet,
|
|
443
|
+
),
|
|
444
|
+
);
|
|
445
|
+
}
|
|
446
|
+
: undefined,
|
|
426
447
|
},
|
|
427
448
|
this.marketplaceBaseStore.registryServerClient,
|
|
428
449
|
);
|
|
@@ -662,6 +683,23 @@ export class LegendMarketplaceProductViewerStore {
|
|
|
662
683
|
),
|
|
663
684
|
);
|
|
664
685
|
},
|
|
686
|
+
openIngestQuery: (
|
|
687
|
+
_gav: ProjectGAVCoordinates,
|
|
688
|
+
ingestDefinitionPath: string,
|
|
689
|
+
dataSet: string,
|
|
690
|
+
): void => {
|
|
691
|
+
this.marketplaceBaseStore.applicationStore.navigationService.navigator.visitAddress(
|
|
692
|
+
EXTERNAL_APPLICATION_NAVIGATION__generateIngestQueryUrl(
|
|
693
|
+
this.marketplaceBaseStore.applicationStore.config
|
|
694
|
+
.queryApplicationUrl,
|
|
695
|
+
_gav.groupId,
|
|
696
|
+
_gav.artifactId,
|
|
697
|
+
_gav.versionId,
|
|
698
|
+
ingestDefinitionPath,
|
|
699
|
+
dataSet,
|
|
700
|
+
),
|
|
701
|
+
);
|
|
702
|
+
},
|
|
665
703
|
},
|
|
666
704
|
this.marketplaceBaseStore.registryServerClient,
|
|
667
705
|
);
|