@swiss-ai-hub/web 0.319.0 → 0.321.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/{pages/auth/login.vue → components/Auth/LoginPanel.vue} +3 -33
- package/components/FormKit/AgentSelector.vue +20 -7
- package/components/FormKit/CronInput.vue +208 -0
- package/components/FormKit/Repeater.vue +1 -4
- package/components/FormKit/VectorStoreInput.vue +43 -6
- package/components/Knowledge/Database/CreateModal.vue +315 -0
- package/components/Knowledge/Database/EmptyCard.vue +34 -0
- package/components/Knowledge/DeleteConfirmModal.vue +87 -0
- package/components/Knowledge/Document/List.vue +20 -9
- package/components/Knowledge/Namespace/Card.vue +18 -0
- package/components/Knowledge/Namespace/CreateModal.vue +11 -3
- package/components/Role/AccessCapabilities.vue +4 -4
- package/components/Role/AccessCapabilityGroup.vue +22 -6
- package/components/Role/AccessRulesEditor.vue +15 -12
- package/composables/app/useAppVersion.ts +37 -20
- package/composables/auth/useAuth.ts +3 -11
- package/composables/document/useCreateDatabase.ts +21 -0
- package/composables/document/useDeleteDatabase.ts +29 -0
- package/composables/document/useDeleteDocument.ts +1 -1
- package/composables/document/useDeleteDocuments.ts +1 -1
- package/composables/document/useDeleteNamespace.ts +30 -0
- package/composables/document/useIngestors.ts +23 -0
- package/composables/document/useScheduledDeletions.ts +16 -8
- package/composables/form/useCreateInstanceForm.ts +2 -2
- package/composables/form/useFormKitTransform.ts +44 -15
- package/formkit.config.ts +57 -3
- package/i18n/locales/de.yaml +84 -5
- package/i18n/locales/en.yaml +80 -3
- package/i18n/locales/fr.yaml +82 -3
- package/i18n/locales/it.yaml +84 -3
- package/middleware/agent-admin.ts +31 -0
- package/middleware/auth.global.ts +34 -16
- package/package.json +1 -1
- package/pages/[tenant]/service/agents.vue +3 -0
- package/pages/[tenant]/service/knowledge/[db]/[namespace]/[document_id].vue +12 -5
- package/pages/[tenant]/service/knowledge.vue +138 -0
- package/pages/auth/login/[idp].vue +57 -0
- package/pages/auth/login/index.vue +46 -0
- package/plugins/0.runtime-config.client.ts +5 -0
- package/plugins/oidc-client.ts +1 -1
- package/sdk/client/client/client.gen.ts +1 -3
- package/sdk/client/client/types.gen.ts +7 -13
- package/sdk/client/client/utils.gen.ts +1 -2
- package/sdk/client/core/queryKeySerializer.gen.ts +1 -6
- package/sdk/client/core/types.gen.ts +5 -3
- package/sdk/client/index.ts +47 -4
- package/sdk/client/schemas.gen.ts +1787 -780
- package/sdk/client/sdk.gen.ts +231 -1
- package/sdk/client/types.gen.ts +1103 -226
- package/plugins/keycloak-client.ts +0 -41
package/sdk/client/sdk.gen.ts
CHANGED
|
@@ -40,6 +40,9 @@ import type {
|
|
|
40
40
|
CreateAgentInstanceData,
|
|
41
41
|
CreateAgentInstanceError,
|
|
42
42
|
CreateAgentInstanceResponse,
|
|
43
|
+
CreateDatabaseData,
|
|
44
|
+
CreateDatabaseError,
|
|
45
|
+
CreateDatabaseResponse,
|
|
43
46
|
CreateDatasetData,
|
|
44
47
|
CreateDatasetError,
|
|
45
48
|
CreateDatasetResponse,
|
|
@@ -70,8 +73,12 @@ import type {
|
|
|
70
73
|
DeleteAllOrganizationMemoriesResponse,
|
|
71
74
|
DeleteAllUserMemoriesData,
|
|
72
75
|
DeleteAllUserMemoriesResponse,
|
|
76
|
+
DeleteDatabaseData,
|
|
77
|
+
DeleteDatabaseError,
|
|
73
78
|
DeleteDocumentData,
|
|
74
79
|
DeleteDocumentError,
|
|
80
|
+
DeleteNamespaceData,
|
|
81
|
+
DeleteNamespaceError,
|
|
75
82
|
DeleteOrganizationMemoryData,
|
|
76
83
|
DeleteOrganizationMemoryError,
|
|
77
84
|
DeleteOrganizationMemoryResponse,
|
|
@@ -132,6 +139,8 @@ import type {
|
|
|
132
139
|
GetDatasetResponse,
|
|
133
140
|
GetDatasetsData,
|
|
134
141
|
GetDatasetsResponse,
|
|
142
|
+
GetDefaultTenantRulesData,
|
|
143
|
+
GetDefaultTenantRulesResponse,
|
|
135
144
|
GetDocumentByIdData,
|
|
136
145
|
GetDocumentByIdError,
|
|
137
146
|
GetDocumentByIdResponse,
|
|
@@ -149,6 +158,8 @@ import type {
|
|
|
149
158
|
GetFileUrlResponse,
|
|
150
159
|
GetHealthData,
|
|
151
160
|
GetHealthResponse,
|
|
161
|
+
GetIngestorsData,
|
|
162
|
+
GetIngestorsResponse,
|
|
152
163
|
GetLitellmModelData,
|
|
153
164
|
GetLitellmModelError,
|
|
154
165
|
GetLitellmModelResponse,
|
|
@@ -157,6 +168,12 @@ import type {
|
|
|
157
168
|
GetLitellmModelsByModeResponse,
|
|
158
169
|
GetLitellmModelsData,
|
|
159
170
|
GetLitellmModelsResponse,
|
|
171
|
+
GetLlmSpendByTenantData,
|
|
172
|
+
GetLlmSpendByTenantError,
|
|
173
|
+
GetLlmSpendByTenantResponse,
|
|
174
|
+
GetLlmSpendByUserData,
|
|
175
|
+
GetLlmSpendByUserError,
|
|
176
|
+
GetLlmSpendByUserResponse,
|
|
160
177
|
GetLocaleData,
|
|
161
178
|
GetLocaleResponse,
|
|
162
179
|
GetModelsData,
|
|
@@ -875,6 +892,72 @@ export const getAgentEventTimeseries = <
|
|
|
875
892
|
...options,
|
|
876
893
|
});
|
|
877
894
|
|
|
895
|
+
/**
|
|
896
|
+
* Get Llm Spend By User
|
|
897
|
+
*
|
|
898
|
+
* LLM spend per user, from the platform's own cost events.
|
|
899
|
+
*
|
|
900
|
+
* Scoped to the caller's acting tenant: spend reveals who used which agents and how much,
|
|
901
|
+
* so a tenant admin must not see other tenants' users. Only a sysadmin, who acts outside
|
|
902
|
+
* any single tenant, sees the whole platform.
|
|
903
|
+
*/
|
|
904
|
+
export const getLlmSpendByUser = <
|
|
905
|
+
TComposable extends Composable = "$fetch",
|
|
906
|
+
DefaultT extends GetLlmSpendByUserResponse = GetLlmSpendByUserResponse,
|
|
907
|
+
>(
|
|
908
|
+
options: Options<
|
|
909
|
+
TComposable,
|
|
910
|
+
GetLlmSpendByUserData,
|
|
911
|
+
GetLlmSpendByUserResponse,
|
|
912
|
+
DefaultT
|
|
913
|
+
>,
|
|
914
|
+
) =>
|
|
915
|
+
(options.client ?? client).get<
|
|
916
|
+
TComposable,
|
|
917
|
+
GetLlmSpendByUserResponse | DefaultT,
|
|
918
|
+
GetLlmSpendByUserError,
|
|
919
|
+
DefaultT
|
|
920
|
+
>({
|
|
921
|
+
security: [
|
|
922
|
+
{ scheme: "bearer", type: "http" },
|
|
923
|
+
{ scheme: "bearer", type: "http" },
|
|
924
|
+
],
|
|
925
|
+
url: "/{tenant_id}/events/spend/users",
|
|
926
|
+
...options,
|
|
927
|
+
});
|
|
928
|
+
|
|
929
|
+
/**
|
|
930
|
+
* Get Llm Spend By Tenant
|
|
931
|
+
*
|
|
932
|
+
* LLM spend per tenant across the whole platform.
|
|
933
|
+
*
|
|
934
|
+
* Sysadmin-only: a cross-tenant total is exactly the view a single tenant must not have.
|
|
935
|
+
*/
|
|
936
|
+
export const getLlmSpendByTenant = <
|
|
937
|
+
TComposable extends Composable = "$fetch",
|
|
938
|
+
DefaultT extends GetLlmSpendByTenantResponse = GetLlmSpendByTenantResponse,
|
|
939
|
+
>(
|
|
940
|
+
options: Options<
|
|
941
|
+
TComposable,
|
|
942
|
+
GetLlmSpendByTenantData,
|
|
943
|
+
GetLlmSpendByTenantResponse,
|
|
944
|
+
DefaultT
|
|
945
|
+
>,
|
|
946
|
+
) =>
|
|
947
|
+
(options.client ?? client).get<
|
|
948
|
+
TComposable,
|
|
949
|
+
GetLlmSpendByTenantResponse | DefaultT,
|
|
950
|
+
GetLlmSpendByTenantError,
|
|
951
|
+
DefaultT
|
|
952
|
+
>({
|
|
953
|
+
security: [
|
|
954
|
+
{ scheme: "bearer", type: "http" },
|
|
955
|
+
{ scheme: "bearer", type: "http" },
|
|
956
|
+
],
|
|
957
|
+
url: "/{tenant_id}/events/spend/tenants",
|
|
958
|
+
...options,
|
|
959
|
+
});
|
|
960
|
+
|
|
878
961
|
/**
|
|
879
962
|
* Get Litellm Models
|
|
880
963
|
*
|
|
@@ -1222,7 +1305,7 @@ export const getOpenChatHitl = <
|
|
|
1222
1305
|
/**
|
|
1223
1306
|
* Get Agent Classes
|
|
1224
1307
|
*
|
|
1225
|
-
* Retrieve
|
|
1308
|
+
* Retrieve the agent classes this caller may reach.
|
|
1226
1309
|
* Use `?online=true` for online classes only, `?online=false` for offline only.
|
|
1227
1310
|
*/
|
|
1228
1311
|
export const getAgentClasses = <
|
|
@@ -2279,6 +2362,37 @@ export const getAccessPresets = <
|
|
|
2279
2362
|
...options,
|
|
2280
2363
|
});
|
|
2281
2364
|
|
|
2365
|
+
/**
|
|
2366
|
+
* Derive Default Tenant Access Rules
|
|
2367
|
+
*
|
|
2368
|
+
* Returns the access ceiling a newly created tenant should start with, derived from the models this instance actually serves minus the configured exclusions.
|
|
2369
|
+
*/
|
|
2370
|
+
export const getDefaultTenantRules = <
|
|
2371
|
+
TComposable extends Composable = "$fetch",
|
|
2372
|
+
DefaultT extends GetDefaultTenantRulesResponse =
|
|
2373
|
+
GetDefaultTenantRulesResponse,
|
|
2374
|
+
>(
|
|
2375
|
+
options: Options<
|
|
2376
|
+
TComposable,
|
|
2377
|
+
GetDefaultTenantRulesData,
|
|
2378
|
+
GetDefaultTenantRulesResponse,
|
|
2379
|
+
DefaultT
|
|
2380
|
+
>,
|
|
2381
|
+
) =>
|
|
2382
|
+
(options.client ?? client).get<
|
|
2383
|
+
TComposable,
|
|
2384
|
+
GetDefaultTenantRulesResponse | DefaultT,
|
|
2385
|
+
unknown,
|
|
2386
|
+
DefaultT
|
|
2387
|
+
>({
|
|
2388
|
+
security: [
|
|
2389
|
+
{ scheme: "bearer", type: "http" },
|
|
2390
|
+
{ scheme: "bearer", type: "http" },
|
|
2391
|
+
],
|
|
2392
|
+
url: "/{tenant_id}/access/default-tenant-rules",
|
|
2393
|
+
...options,
|
|
2394
|
+
});
|
|
2395
|
+
|
|
2282
2396
|
/**
|
|
2283
2397
|
* List Models
|
|
2284
2398
|
*
|
|
@@ -2624,6 +2738,122 @@ export const updateDataset = <
|
|
|
2624
2738
|
},
|
|
2625
2739
|
});
|
|
2626
2740
|
|
|
2741
|
+
/**
|
|
2742
|
+
* Get selectable ingestion pipelines
|
|
2743
|
+
*
|
|
2744
|
+
* Returns the ingestion pipelines that can be assigned to a new knowledge database.
|
|
2745
|
+
*/
|
|
2746
|
+
export const getIngestors = <
|
|
2747
|
+
TComposable extends Composable = "$fetch",
|
|
2748
|
+
DefaultT extends GetIngestorsResponse = GetIngestorsResponse,
|
|
2749
|
+
>(
|
|
2750
|
+
options: Options<
|
|
2751
|
+
TComposable,
|
|
2752
|
+
GetIngestorsData,
|
|
2753
|
+
GetIngestorsResponse,
|
|
2754
|
+
DefaultT
|
|
2755
|
+
>,
|
|
2756
|
+
) =>
|
|
2757
|
+
(options.client ?? client).get<
|
|
2758
|
+
TComposable,
|
|
2759
|
+
GetIngestorsResponse | DefaultT,
|
|
2760
|
+
unknown,
|
|
2761
|
+
DefaultT
|
|
2762
|
+
>({
|
|
2763
|
+
security: [
|
|
2764
|
+
{ scheme: "bearer", type: "http" },
|
|
2765
|
+
{ scheme: "bearer", type: "http" },
|
|
2766
|
+
],
|
|
2767
|
+
url: "/{tenant_id}/knowledge/ingestors",
|
|
2768
|
+
...options,
|
|
2769
|
+
});
|
|
2770
|
+
|
|
2771
|
+
/**
|
|
2772
|
+
* Delete a knowledge database
|
|
2773
|
+
*
|
|
2774
|
+
* Schedules asynchronous teardown of a whole knowledge database — its Milvus collection, doc-store
|
|
2775
|
+
* database and S3 bucket — via the pipeline's Dagster teardown job. Returns immediately with 202.
|
|
2776
|
+
*/
|
|
2777
|
+
export const deleteDatabase = <
|
|
2778
|
+
TComposable extends Composable = "$fetch",
|
|
2779
|
+
DefaultT = undefined,
|
|
2780
|
+
>(
|
|
2781
|
+
options: Options<TComposable, DeleteDatabaseData, unknown, DefaultT>,
|
|
2782
|
+
) =>
|
|
2783
|
+
(options.client ?? client).delete<
|
|
2784
|
+
TComposable,
|
|
2785
|
+
unknown | DefaultT,
|
|
2786
|
+
DeleteDatabaseError,
|
|
2787
|
+
DefaultT
|
|
2788
|
+
>({
|
|
2789
|
+
security: [
|
|
2790
|
+
{ scheme: "bearer", type: "http" },
|
|
2791
|
+
{ scheme: "bearer", type: "http" },
|
|
2792
|
+
],
|
|
2793
|
+
url: "/{tenant_id}/knowledge/databases/{database}",
|
|
2794
|
+
...options,
|
|
2795
|
+
});
|
|
2796
|
+
|
|
2797
|
+
/**
|
|
2798
|
+
* Create Database
|
|
2799
|
+
*
|
|
2800
|
+
* Creates a new self-service knowledge database (bucket) ingested by the document ingestion pipeline.
|
|
2801
|
+
*/
|
|
2802
|
+
export const createDatabase = <
|
|
2803
|
+
TComposable extends Composable = "$fetch",
|
|
2804
|
+
DefaultT extends CreateDatabaseResponse = CreateDatabaseResponse,
|
|
2805
|
+
>(
|
|
2806
|
+
options: Options<
|
|
2807
|
+
TComposable,
|
|
2808
|
+
CreateDatabaseData,
|
|
2809
|
+
CreateDatabaseResponse,
|
|
2810
|
+
DefaultT
|
|
2811
|
+
>,
|
|
2812
|
+
) =>
|
|
2813
|
+
(options.client ?? client).post<
|
|
2814
|
+
TComposable,
|
|
2815
|
+
CreateDatabaseResponse | DefaultT,
|
|
2816
|
+
CreateDatabaseError,
|
|
2817
|
+
DefaultT
|
|
2818
|
+
>({
|
|
2819
|
+
security: [
|
|
2820
|
+
{ scheme: "bearer", type: "http" },
|
|
2821
|
+
{ scheme: "bearer", type: "http" },
|
|
2822
|
+
],
|
|
2823
|
+
url: "/{tenant_id}/knowledge/databases/{database}",
|
|
2824
|
+
...options,
|
|
2825
|
+
headers: {
|
|
2826
|
+
"Content-Type": "application/json",
|
|
2827
|
+
...options.headers,
|
|
2828
|
+
},
|
|
2829
|
+
});
|
|
2830
|
+
|
|
2831
|
+
/**
|
|
2832
|
+
* Delete a namespace
|
|
2833
|
+
*
|
|
2834
|
+
* Schedules asynchronous teardown of one namespace — its S3 folder, doc-store rows and Milvus
|
|
2835
|
+
* vectors (deleted by metadata filter, never a partition drop). Returns immediately with 202.
|
|
2836
|
+
*/
|
|
2837
|
+
export const deleteNamespace = <
|
|
2838
|
+
TComposable extends Composable = "$fetch",
|
|
2839
|
+
DefaultT = undefined,
|
|
2840
|
+
>(
|
|
2841
|
+
options: Options<TComposable, DeleteNamespaceData, unknown, DefaultT>,
|
|
2842
|
+
) =>
|
|
2843
|
+
(options.client ?? client).delete<
|
|
2844
|
+
TComposable,
|
|
2845
|
+
unknown | DefaultT,
|
|
2846
|
+
DeleteNamespaceError,
|
|
2847
|
+
DefaultT
|
|
2848
|
+
>({
|
|
2849
|
+
security: [
|
|
2850
|
+
{ scheme: "bearer", type: "http" },
|
|
2851
|
+
{ scheme: "bearer", type: "http" },
|
|
2852
|
+
],
|
|
2853
|
+
url: "/{tenant_id}/knowledge/databases/{database}/namespaces/{namespace}",
|
|
2854
|
+
...options,
|
|
2855
|
+
});
|
|
2856
|
+
|
|
2627
2857
|
/**
|
|
2628
2858
|
* Create Namespace
|
|
2629
2859
|
*
|