@yuku123/z-cognition-component 2.0.0 → 2.0.1
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-lib/ApartmentOutlined-M6qSurnE.js +12 -0
- package/dist-lib/ArrowLeftOutlined-DowsrSUj.js +12 -0
- package/dist-lib/{ConceptsPage-DOf_CJlz.js → ConceptsPage-BOeKdDKI.js} +16 -13
- package/dist-lib/{DocsPage-CiC7TU96.js → DocsPage-BZOBFp3c.js} +4 -4
- package/dist-lib/EvidenceFormList-DXqqSpPV.js +91 -0
- package/dist-lib/{EyeOutlined-CH-5UdnC.js → EyeOutlined-DGSrX-0M.js} +1 -1
- package/dist-lib/ImpactPage-DyhUR6fT.js +71 -0
- package/dist-lib/{LeftOutlined-DQTflZ6D.js → LeftOutlined-Cgo6Izj-.js} +1 -1
- package/dist-lib/{OntologyDetailPage-mgK_NQxP.js → OntologyDetailPage-B8DyU8WW.js} +93 -99
- package/dist-lib/{OntologyInferPage-NUaoaQpN.js → OntologyInferPage-CvcjxpBB.js} +40 -38
- package/dist-lib/{OntologyListPage-C9wH01y0.js → OntologyListPage-Cb0XfpWE.js} +49 -47
- package/dist-lib/OntologyMaterializePage-B0f9TnJa.js +136 -0
- package/dist-lib/OntologyNodesPage-D4MWlm6q.js +1268 -0
- package/dist-lib/{OntologyValidatePage-DtkYK_l4.js → OntologyValidatePage-abQVJwzV.js} +52 -49
- package/dist-lib/{Pagination-Ds8VKQIT.js → Pagination-Dxslodkq.js} +258 -260
- package/dist-lib/PlusOutlined-B_dXo_97.js +12 -0
- package/dist-lib/{ReloadOutlined-B26pDoyV.js → ReloadOutlined-CS-e-TmN.js} +10 -19
- package/dist-lib/{ResolvePage-Cz9HORZ3.js → ResolvePage-rbQ-8nNZ.js} +33 -31
- package/dist-lib/{RotateRightOutlined-B575hEBK.js → RotateRightOutlined-q7zp2e47.js} +1 -1
- package/dist-lib/SearchOutlined-puH6bCY6.js +979 -0
- package/dist-lib/Skeleton-DXcERb5r.js +557 -0
- package/dist-lib/{Table-D8pPXolZ.js → Table-CDagah-g.js} +452 -450
- package/dist-lib/TagsOutlined-B4_qkn6-.js +20 -0
- package/dist-lib/TermDetailPage-CP0D6OvA.js +242 -0
- package/dist-lib/{TermsPage-BuzCMYov.js → TermsPage-CuufAyuL.js} +31 -28
- package/dist-lib/TextArea-DTpTS5HL.js +1897 -0
- package/dist-lib/ThunderboltOutlined-Bf54AaFE.js +20 -0
- package/dist-lib/{agents-DS0rPJGV.js → agents-mAJW3cEN.js} +46 -46
- package/dist-lib/{ai-CQ67aRC4.js → ai-BcYmZiRo.js} +30 -30
- package/dist-lib/{ai-chat-share-AOB7rEOb.js → ai-chat-share-DO7GXjG4.js} +14 -13
- package/dist-lib/{approval-LLVR3fMa.js → approval-RPDUKg9-.js} +26 -25
- package/dist-lib/{approvals-D1DSA-Mw.js → approvals-CNjxJUpR.js} +43 -42
- package/dist-lib/{assistant-DpabpWKV.js → assistant-FIQQziCn.js} +50 -49
- package/dist-lib/{assistant-history-ChvhtZwX.js → assistant-history-DsEGBJnq.js} +5 -5
- package/dist-lib/{assistant-summary-B0ksF8CX.js → assistant-summary-B-f3k55y.js} +1 -1
- package/dist-lib/{audit-DeU1XEgQ.js → audit-NwnH1hm5.js} +1 -1
- package/dist-lib/{bios-Bk36bVhw.js → bios-CRwKtcit.js} +130 -125
- package/dist-lib/callSuper-DZEfdkXG.js +7 -0
- package/dist-lib/{changelog-CCMDMI4R.js → changelog-Dj_Pv2nc.js} +1 -1
- package/dist-lib/{changelog-xEt2qnho.js → changelog-DlL5u9o4.js} +2 -2
- package/dist-lib/chunk-YDNE64FV-DGyyfCo0.js +2004 -0
- package/dist-lib/colors-sdAcAcU3.js +24 -0
- package/dist-lib/context-Buz0ggsK.js +710 -0
- package/dist-lib/context-DpmyNOn3.js +21 -0
- package/dist-lib/createForOfIteratorHelper-DEx_aTey.js +51 -0
- package/dist-lib/d3-force-CZK-Rgd6.js +598 -0
- package/dist-lib/{dayjs.min-DoEf5yCX.js → dayjs.min-BauDENhn.js} +1 -1
- package/dist-lib/{detail-Xtof0GoK.js → detail-Cfb-zdr9.js} +50 -49
- package/dist-lib/{detail-BW6dD_YP.js → detail-Dcfg3W8B.js} +89 -88
- package/dist-lib/{docx-preview-D4v2g8Yg.js → docx-preview-B5nQuTwk.js} +1 -1
- package/dist-lib/{downloads-Dj4DgBSS.js → downloads-MkyxiHxi.js} +4 -3
- package/dist-lib/{edit-nZ7siGuW.js → edit-DLGAM-Vo.js} +265 -259
- package/dist-lib/{editor-BuhZwEsv.js → editor-BtiheUpe.js} +21 -20
- package/dist-lib/embed-DwLg9RDW.js +31148 -0
- package/dist-lib/{evaluation-B-igEqQ9.js → evaluation-Dz9bUuhS.js} +15 -14
- package/dist-lib/{focus-set-DfRWcq91.js → focus-set-h0YtOUB2.js} +34 -33
- package/dist-lib/{format-CWI99NCN.js → format-UGmYKemG.js} +1 -1
- package/dist-lib/index-9aQ4BzIK.js +500 -0
- package/dist-lib/index-B57Fj7Y0.js +1169 -0
- package/dist-lib/{index-D_-8dmug.js → index-BEjXaDfk.js} +23 -22
- package/dist-lib/{index-BJ2Gpcbi.js → index-BGB6NawZ.js} +2 -2
- package/dist-lib/index-Bc-Vin3j.js +256 -0
- package/dist-lib/{index-g9uC_rON.js → index-BwVZgt5s.js} +129 -146
- package/dist-lib/{index-CZipVp1G.js → index-C3AMwzIi.js} +1 -1
- package/dist-lib/{index-SAPKyv8e.js → index-CJSTTgTM.js} +10 -10
- package/dist-lib/{index-CnLkqTRm.js → index-CaXylbQR.js} +175 -173
- package/dist-lib/index-Cfu1W1H6.js +535 -0
- package/dist-lib/index-CrMcNEAZ.js +9656 -0
- package/dist-lib/index-Cy9i4Kx7.js +699 -0
- package/dist-lib/index-CyKWCYMK.js +218 -0
- package/dist-lib/{index-CjwzwBTy.js → index-D3GHtSlM.js} +94 -93
- package/dist-lib/{index-B8l4PAGJ.js → index-DBlG9uXV.js} +112 -108
- package/dist-lib/index-DBtGE89a.js +168 -0
- package/dist-lib/{index-CS5YTpdI.js → index-DMTPsTna.js} +4 -3
- package/dist-lib/{index-rtSfQuYs.js → index-D_Qey9G8.js} +12 -12
- package/dist-lib/index-DjFPRXl5.js +1484 -0
- package/dist-lib/{index-Bu6udiyN.js → index-DsuUGhTA.js} +123 -121
- package/dist-lib/{index-B5jr3A7f.js → index-DuI4K5e1.js} +19 -19
- package/dist-lib/index-DvWHYX81.js +450 -0
- package/dist-lib/{index-D5V4bZ4e.js → index-HieOUSwH.js} +8 -8
- package/dist-lib/index-Vu6sPBci.js +1884 -0
- package/dist-lib/index-bOY1cBol.js +4890 -0
- package/dist-lib/{index-DzrH4RQ7.js → index-c2HokEFp.js} +11 -10
- package/dist-lib/{index-BFRg0cn3.js → index-g16g7A4k.js} +6 -6
- package/dist-lib/index-nQSVLWfW.js +356 -0
- package/dist-lib/{index-pcUZcUIA.js → index-o65vKUwa.js} +48 -47
- package/dist-lib/{index-K7z38Ybg.js → index-ounfql2z.js} +33 -31
- package/dist-lib/{index-B1rpIXU7.js → index-y7jVGGI0.js} +23 -21
- package/dist-lib/index.js +3 -1
- package/dist-lib/{jszip.min-dcaDnWUw.js → jszip.min-DcEHhn-b.js} +1 -1
- package/dist-lib/{kb-form-modal-9L0AUHVG.js → kb-form-modal-BNoIhw6B.js} +71 -71
- package/dist-lib/{kbTeam-BECePvJe.js → kbTeam-EgcbWseM.js} +3 -3
- package/dist-lib/{knowledge-base-C8gHP0dj.js → knowledge-base-C023dnJ-.js} +104 -103
- package/dist-lib/{knowledge-hub-C9KkDv1A.js → knowledge-hub-B4fGCn8m.js} +52 -51
- package/dist-lib/{markdown-lite-BABX4bcl.js → markdown-lite-EvJ9Fw7X.js} +181 -177
- package/dist-lib/{material-preview-docx-lp_xPipj.js → material-preview-docx-CH-09KeC.js} +1 -1
- package/dist-lib/{material-preview-pptx-6Byitp0J.js → material-preview-pptx-D8XGDF-u.js} +1 -1
- package/dist-lib/{member-B5WF3FCj.js → member-BUg2QYlE.js} +1 -1
- package/dist-lib/{message-kHyjuooj.js → message-Cwj8dO78.js} +25 -24
- package/dist-lib/{message-D2MSaOMq.js → message-GF-w8HuR.js} +1 -1
- package/dist-lib/{messages-D_VDuKK7.js → messages-JID13L8-.js} +16 -15
- package/dist-lib/{meta-CEf_DYcU.js → meta-DPp5L3Uc.js} +1 -1
- package/dist-lib/{metrics-hONGW0KG.js → metrics-CT4eLzrq.js} +2 -2
- package/dist-lib/{monitor-DFmEu6rH.js → monitor-Bs9BfJOj.js} +4 -4
- package/dist-lib/{monitor-DF3WVsVV.js → monitor-CmS65YSu.js} +8 -8
- package/dist-lib/{my-access-j53lA6T6.js → my-access-1Yj7UloI.js} +3 -3
- package/dist-lib/{my-permissions-C5L8ZN2d.js → my-permissions-yQDHPLYI.js} +23 -22
- package/dist-lib/{new-DfZ61nMQ.js → new-BgkoBnZV.js} +14 -12
- package/dist-lib/{ontology-CUH5qslO.js → ontology-BPrbXPor.js} +145 -142
- package/dist-lib/{ontology-domains-CRC1ZRit.js → ontology-domains-Cbqnm-po.js} +88 -84
- package/dist-lib/{ontology-modeling-DaSk5fsh.js → ontology-modeling-6k-m8fzr.js} +2125 -2117
- package/dist-lib/ontology-modeling-BT-EuDCs.js +1039 -0
- package/dist-lib/{ontology-scenarios-DAbyoKV6.js → ontology-scenarios-D3xy6IZL.js} +703 -712
- package/dist-lib/ontology-scenarios-DWYC2yxd.js +660 -0
- package/dist-lib/pages-CsexFuEz.js +73 -0
- package/dist-lib/pages.js +3 -3
- package/dist-lib/{permission-CklDU2kO.js → permission-fTfxpEhV.js} +31 -31
- package/dist-lib/{pptx-preview.es-D4ODiBv2.js → pptx-preview.es-AUrdYKu3.js} +2 -2
- package/dist-lib/{preset-Bp_mvsJm.js → preset-gh5SGoYT.js} +9810 -10199
- package/dist-lib/{quota-DLe9so2b.js → quota-BlHnhkAT.js} +4 -4
- package/dist-lib/{row-CE051ClO.js → row-B5MnGm9M.js} +63 -61
- package/dist-lib/{save-blob-qKrc8-z6.js → save-blob-B-pzX8eT.js} +2 -2
- package/dist-lib/{scenario-mapping-preview-CSDqIN3R.js → scenario-mapping-preview-DByQXh0y.js} +48 -46
- package/dist-lib/{scenario-simple-form-CAkhVgeV.js → scenario-simple-form-Bw-6n9Kh.js} +425 -423
- package/dist-lib/{schedule-B_ujtL3h.js → schedule-H4_9KnRj.js} +8 -8
- package/dist-lib/{settings-BIkKTQjc.js → settings-C3PI8KYa.js} +147 -146
- package/dist-lib/{shared-Dfz1X4Mq.js → shared-DqeN-Wbb.js} +1 -1
- package/dist-lib/{shared-utils-BeRiAkbe.js → shared-utils-DN3zT9P-.js} +2 -2
- package/dist-lib/{skills-BzpcX5fN.js → skills-eGlCExr0.js} +40 -39
- package/dist-lib/{source-selection-DOL5LBrV.js → source-selection-BCvClzc-.js} +16 -16
- package/dist-lib/{task-config-D0a7TOYt.js → task-config-DEJVJ7zK.js} +4 -4
- package/dist-lib/{tech-CH01ekZ5.js → tech-C-4uM9bS.js} +4 -3
- package/dist-lib/{tools-YnTN61uE.js → tools-le6miafZ.js} +14 -14
- package/dist-lib/{use-domain-access-CXx1YzE5.js → use-domain-access-B3pDp3s5.js} +13 -13
- package/dist-lib/use-g6-graph-WLX0PweO.js +1119 -0
- package/dist-lib/{use-graph-layers-CowyyYcb.js → use-graph-layers-Dmp7uMHO.js} +50 -48
- package/dist-lib/useClosable-BY7FgWKy.js +59 -0
- package/dist-lib/useForm-Byp1LopG.js +145 -0
- package/dist-lib/{version-control-panel-CLy2ZXI_.js → version-control-panel-WT1PobuV.js} +27 -26
- package/dist-lib/{version-management-C_v8w1E4.js → version-management-DC0k1DRg.js} +7 -6
- package/dist-lib/{welcome-ChEcA4Ej.js → welcome-VyWLrbth.js} +4 -3
- package/package.json +2 -3
- package/dist-lib/EvidenceFormList-CrE2FzHk.js +0 -90
- package/dist-lib/ImpactPage-CYiuqy0S.js +0 -68
- package/dist-lib/OntologyMaterializePage-D_fDqYHY.js +0 -134
- package/dist-lib/OntologyNodesPage-5kH7RHwE.js +0 -2844
- package/dist-lib/PlusOutlined-BSTPGLOH.js +0 -21
- package/dist-lib/Skeleton-CxFsInYI.js +0 -671
- package/dist-lib/Table-Civ838nE.js +0 -20514
- package/dist-lib/TermDetailPage-BtkOpbPT.js +0 -263
- package/dist-lib/_commonjsHelpers-DaMA6jEr.js +0 -8
- package/dist-lib/callSuper-CwIeyYoc.js +0 -7
- package/dist-lib/chunk-6KYCQHYJ-DcgZQlO5.js +0 -1627
- package/dist-lib/context-T27uno74.js +0 -54
- package/dist-lib/d3-force-Cr_oBTiR.js +0 -647
- package/dist-lib/embed-Bs3Hmsyy.js +0 -51377
- package/dist-lib/index-0TvzCTD7.js +0 -2336
- package/dist-lib/index-4tbtbcAt.js +0 -550
- package/dist-lib/index-B1wh6i1C.js +0 -1308
- package/dist-lib/index-BVgdmf6r.js +0 -2487
- package/dist-lib/index-CSnvcFg-.js +0 -543
- package/dist-lib/index-D35Ry0PG.js +0 -1162
- package/dist-lib/index-DC57_dnh.js +0 -604
- package/dist-lib/index-DQ16Zb7x.js +0 -546
- package/dist-lib/index-DRcTwC17.js +0 -418
- package/dist-lib/index-Dd9pPAT3.js +0 -2192
- package/dist-lib/index-DxzorPvG.js +0 -13960
- package/dist-lib/index-If4xc1-H.js +0 -559
- package/dist-lib/index-R71k3nB_.js +0 -710
- package/dist-lib/index-mUlorJxp.js +0 -3279
- package/dist-lib/ontology-modeling-CvJIImxt.js +0 -3612
- package/dist-lib/ontology-scenarios-BRDkk3uA.js +0 -675
- package/dist-lib/pages-CticGC6S.js +0 -512
- package/dist-lib/use-g6-graph-SwJtPLce.js +0 -57552
|
@@ -1,28 +1,30 @@
|
|
|
1
|
-
import { jsx as e, jsxs as
|
|
1
|
+
import { jsx as e, jsxs as r, Fragment as I } from "react/jsx-runtime";
|
|
2
2
|
import { useState as o } from "react";
|
|
3
|
-
import { f as
|
|
4
|
-
import { parseSnapshot as T } from "./OntologyValidatePage-
|
|
5
|
-
import {
|
|
6
|
-
import { A as v } from "./index-
|
|
7
|
-
import {
|
|
8
|
-
import { C as l } from "./index-
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
3
|
+
import { f as a, o as S } from "./api-BVrIcAFp.js";
|
|
4
|
+
import { parseSnapshot as T } from "./OntologyValidatePage-abQVJwzV.js";
|
|
5
|
+
import { b as j } from "./chunk-YDNE64FV-DGyyfCo0.js";
|
|
6
|
+
import { A as v } from "./index-nQSVLWfW.js";
|
|
7
|
+
import { S as z, B as C } from "./index-CrMcNEAZ.js";
|
|
8
|
+
import { C as l } from "./index-Cfu1W1H6.js";
|
|
9
|
+
import { S as d } from "./index-CaXylbQR.js";
|
|
10
|
+
import { I as $ } from "./index-DvWHYX81.js";
|
|
11
|
+
import { a as B } from "./ThunderboltOutlined-Bf54AaFE.js";
|
|
12
|
+
import { F as y } from "./Table-CDagah-g.js";
|
|
13
|
+
import { s as A } from "./index-DBtGE89a.js";
|
|
14
|
+
import { T as s } from "./index-Bc-Vin3j.js";
|
|
13
15
|
const { TextArea: F } = $;
|
|
14
|
-
function
|
|
16
|
+
function Q() {
|
|
15
17
|
const [f] = j(), c = f.get("id") || "", [m, g] = o(
|
|
16
18
|
`{
|
|
17
19
|
"individuals": [],
|
|
18
20
|
"statements": []
|
|
19
21
|
}`
|
|
20
|
-
), [
|
|
22
|
+
), [i, p] = o(null), [x, h] = o(!1), w = async () => {
|
|
21
23
|
h(!0), p(null);
|
|
22
24
|
try {
|
|
23
25
|
p(await S.infer(c, T(m)));
|
|
24
26
|
} catch (t) {
|
|
25
|
-
|
|
27
|
+
A.error(t.message);
|
|
26
28
|
} finally {
|
|
27
29
|
h(!1);
|
|
28
30
|
}
|
|
@@ -37,9 +39,9 @@ function J() {
|
|
|
37
39
|
title: "性质",
|
|
38
40
|
key: "nature",
|
|
39
41
|
width: 140,
|
|
40
|
-
render: (t,
|
|
41
|
-
|
|
42
|
-
|
|
42
|
+
render: (t, n) => /* @__PURE__ */ r(d, { size: 4, children: [
|
|
43
|
+
n.inferred ? /* @__PURE__ */ e(s, { color: "blue", children: "推理" }) : /* @__PURE__ */ e(s, { children: "显式" }),
|
|
44
|
+
n.literal ? /* @__PURE__ */ e(s, { color: "orange", children: "字面量" }) : null
|
|
43
45
|
] })
|
|
44
46
|
}
|
|
45
47
|
], k = [
|
|
@@ -50,17 +52,17 @@ function J() {
|
|
|
50
52
|
dataIndex: "types",
|
|
51
53
|
key: "types",
|
|
52
54
|
width: 200,
|
|
53
|
-
render: (t) => (t || []).map((
|
|
55
|
+
render: (t) => (t || []).map((n) => /* @__PURE__ */ e(s, { children: n }, n))
|
|
54
56
|
},
|
|
55
57
|
{
|
|
56
58
|
title: "推理类型",
|
|
57
59
|
dataIndex: "inferredTypes",
|
|
58
60
|
key: "inferredTypes",
|
|
59
|
-
render: (t,
|
|
61
|
+
render: (t, n) => (a(n, "inferredTypes") || []).map((u) => /* @__PURE__ */ e(s, { color: "blue", children: u }, u))
|
|
60
62
|
}
|
|
61
63
|
];
|
|
62
|
-
return /* @__PURE__ */
|
|
63
|
-
/* @__PURE__ */ e(l, { size: "small", title: "推理输入(OntologySnapshot)", style: { marginBottom: 16 }, children: /* @__PURE__ */
|
|
64
|
+
return /* @__PURE__ */ r(z, { spinning: x, children: [
|
|
65
|
+
/* @__PURE__ */ e(l, { size: "small", title: "推理输入(OntologySnapshot)", style: { marginBottom: 16 }, children: /* @__PURE__ */ r(d, { direction: "vertical", style: { width: "100%" }, children: [
|
|
64
66
|
/* @__PURE__ */ e(
|
|
65
67
|
F,
|
|
66
68
|
{
|
|
@@ -70,44 +72,44 @@ function J() {
|
|
|
70
72
|
placeholder: '{"individuals": [], "statements": []}'
|
|
71
73
|
}
|
|
72
74
|
),
|
|
73
|
-
/* @__PURE__ */ e(C, { type: "primary", icon: /* @__PURE__ */ e(
|
|
75
|
+
/* @__PURE__ */ e(C, { type: "primary", icon: /* @__PURE__ */ e(B, {}), onClick: w, children: "开始推理" })
|
|
74
76
|
] }) }),
|
|
75
|
-
|
|
76
|
-
/* @__PURE__ */ e(l, { size: "small", title: "推理概览", style: { marginBottom: 16 }, children: /* @__PURE__ */
|
|
77
|
-
/* @__PURE__ */
|
|
77
|
+
i ? /* @__PURE__ */ r(I, { children: [
|
|
78
|
+
/* @__PURE__ */ e(l, { size: "small", title: "推理概览", style: { marginBottom: 16 }, children: /* @__PURE__ */ r(d, { size: "large", wrap: !0, children: [
|
|
79
|
+
/* @__PURE__ */ r("span", { children: [
|
|
78
80
|
"显式陈述 ",
|
|
79
|
-
/* @__PURE__ */ e("b", { children:
|
|
81
|
+
/* @__PURE__ */ e("b", { children: a(i, "explicitStatements") })
|
|
80
82
|
] }),
|
|
81
|
-
/* @__PURE__ */
|
|
83
|
+
/* @__PURE__ */ r("span", { children: [
|
|
82
84
|
"推理陈述 ",
|
|
83
|
-
/* @__PURE__ */ e("b", { children:
|
|
85
|
+
/* @__PURE__ */ e("b", { children: a(i, "inferredStatements") })
|
|
84
86
|
] }),
|
|
85
|
-
/* @__PURE__ */
|
|
87
|
+
/* @__PURE__ */ r("span", { children: [
|
|
86
88
|
"显式类型 ",
|
|
87
|
-
/* @__PURE__ */ e("b", { children:
|
|
89
|
+
/* @__PURE__ */ e("b", { children: a(i, "explicitTypes") })
|
|
88
90
|
] }),
|
|
89
|
-
/* @__PURE__ */
|
|
91
|
+
/* @__PURE__ */ r("span", { children: [
|
|
90
92
|
"推理类型 ",
|
|
91
|
-
/* @__PURE__ */ e("b", { children:
|
|
93
|
+
/* @__PURE__ */ e("b", { children: a(i, "inferredTypes") })
|
|
92
94
|
] })
|
|
93
95
|
] }) }),
|
|
94
|
-
/* @__PURE__ */ e(l, { size: "small", title: `个体(${(
|
|
96
|
+
/* @__PURE__ */ e(l, { size: "small", title: `个体(${(i.individuals || []).length})`, style: { marginBottom: 16 }, children: /* @__PURE__ */ e(
|
|
95
97
|
y,
|
|
96
98
|
{
|
|
97
99
|
rowKey: "key",
|
|
98
100
|
size: "small",
|
|
99
101
|
columns: k,
|
|
100
|
-
dataSource:
|
|
102
|
+
dataSource: i.individuals || [],
|
|
101
103
|
pagination: !1
|
|
102
104
|
}
|
|
103
105
|
) }),
|
|
104
|
-
/* @__PURE__ */ e(l, { size: "small", title: `陈述(${(
|
|
106
|
+
/* @__PURE__ */ e(l, { size: "small", title: `陈述(${(i.statements || []).length})`, children: /* @__PURE__ */ e(
|
|
105
107
|
y,
|
|
106
108
|
{
|
|
107
|
-
rowKey: (t,
|
|
109
|
+
rowKey: (t, n) => `${t.subject}-${t.predicate}-${t.object}-${n}`,
|
|
108
110
|
size: "small",
|
|
109
111
|
columns: b,
|
|
110
|
-
dataSource:
|
|
112
|
+
dataSource: i.statements || [],
|
|
111
113
|
pagination: !1
|
|
112
114
|
}
|
|
113
115
|
) })
|
|
@@ -115,5 +117,5 @@ function J() {
|
|
|
115
117
|
] });
|
|
116
118
|
}
|
|
117
119
|
export {
|
|
118
|
-
|
|
120
|
+
Q as default
|
|
119
121
|
};
|
|
@@ -1,23 +1,25 @@
|
|
|
1
1
|
import { jsxs as i, jsx as e } from "react/jsx-runtime";
|
|
2
2
|
import { useState as m, useEffect as $ } from "react";
|
|
3
3
|
import { o as u } from "./api-BVrIcAFp.js";
|
|
4
|
-
import { u as F } from "./chunk-
|
|
5
|
-
import { F as
|
|
6
|
-
import { S as k
|
|
7
|
-
import {
|
|
8
|
-
import { R
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
4
|
+
import { u as F } from "./chunk-YDNE64FV-DGyyfCo0.js";
|
|
5
|
+
import { F as s, M as J } from "./index-DBlG9uXV.js";
|
|
6
|
+
import { S as k } from "./index-CaXylbQR.js";
|
|
7
|
+
import { B as o } from "./index-CrMcNEAZ.js";
|
|
8
|
+
import { R } from "./PlusOutlined-B_dXo_97.js";
|
|
9
|
+
import { R as z } from "./ReloadOutlined-CS-e-TmN.js";
|
|
10
|
+
import { F as N } from "./Table-CDagah-g.js";
|
|
11
|
+
import { I as n } from "./index-DvWHYX81.js";
|
|
12
|
+
import { s as a } from "./index-DBtGE89a.js";
|
|
13
|
+
import { T } from "./index-Bc-Vin3j.js";
|
|
14
|
+
import { P as B } from "./index-CyKWCYMK.js";
|
|
13
15
|
const { TextArea: y } = n;
|
|
14
|
-
function
|
|
15
|
-
const l = F(), [c, p] = m([]), [v, w] = m(!1), [S, h] = m(!1), [x, I] = m(!1), [f] =
|
|
16
|
+
function Q() {
|
|
17
|
+
const l = F(), [c, p] = m([]), [v, w] = m(!1), [S, h] = m(!1), [x, I] = m(!1), [f] = s.useForm(), d = async () => {
|
|
16
18
|
w(!0);
|
|
17
19
|
try {
|
|
18
20
|
p(await u.listSchemas());
|
|
19
|
-
} catch (
|
|
20
|
-
|
|
21
|
+
} catch (r) {
|
|
22
|
+
a.error(r.message);
|
|
21
23
|
} finally {
|
|
22
24
|
w(!1);
|
|
23
25
|
}
|
|
@@ -26,52 +28,52 @@ function G() {
|
|
|
26
28
|
d();
|
|
27
29
|
}, []);
|
|
28
30
|
const b = async () => {
|
|
29
|
-
const
|
|
31
|
+
const r = await f.validateFields();
|
|
30
32
|
I(!0);
|
|
31
33
|
try {
|
|
32
|
-
const
|
|
33
|
-
id:
|
|
34
|
-
name:
|
|
35
|
-
version:
|
|
36
|
-
description:
|
|
37
|
-
prefixes:
|
|
38
|
-
classes:
|
|
39
|
-
properties:
|
|
34
|
+
const t = {
|
|
35
|
+
id: r.id,
|
|
36
|
+
name: r.name,
|
|
37
|
+
version: r.version || "1.0.0",
|
|
38
|
+
description: r.description || "",
|
|
39
|
+
prefixes: r.prefixes ? g(r.prefixes, "前缀") : {},
|
|
40
|
+
classes: r.classes ? g(r.classes, "类定义") : [],
|
|
41
|
+
properties: r.properties ? g(r.properties, "属性定义") : []
|
|
40
42
|
};
|
|
41
|
-
await u.registerSchema(
|
|
42
|
-
} catch (
|
|
43
|
-
|
|
43
|
+
await u.registerSchema(t), a.success(`本体 ${t.id} 已登记`), h(!1), f.resetFields(), await d();
|
|
44
|
+
} catch (t) {
|
|
45
|
+
a.error(t.message);
|
|
44
46
|
} finally {
|
|
45
47
|
I(!1);
|
|
46
48
|
}
|
|
47
|
-
}, C = async (
|
|
49
|
+
}, C = async (r) => {
|
|
48
50
|
try {
|
|
49
|
-
await u.deleteSchema(
|
|
50
|
-
} catch (
|
|
51
|
-
|
|
51
|
+
await u.deleteSchema(r), a.success(`本体 ${r} 已删除`), await d();
|
|
52
|
+
} catch (t) {
|
|
53
|
+
a.error(t.message);
|
|
52
54
|
}
|
|
53
55
|
}, O = [
|
|
54
56
|
{ title: "本体 ID", dataIndex: "id", key: "id", width: 180 },
|
|
55
57
|
{ title: "名称", dataIndex: "name", key: "name", width: 160 },
|
|
56
|
-
{ title: "版本", dataIndex: "version", key: "version", width: 90, render: (
|
|
57
|
-
{ title: "类数", key: "classes", width: 80, render: (
|
|
58
|
-
{ title: "属性数", key: "properties", width: 80, render: (
|
|
58
|
+
{ title: "版本", dataIndex: "version", key: "version", width: 90, render: (r) => /* @__PURE__ */ e(T, { children: r }) },
|
|
59
|
+
{ title: "类数", key: "classes", width: 80, render: (r, t) => (t.classes || []).length },
|
|
60
|
+
{ title: "属性数", key: "properties", width: 80, render: (r, t) => (t.properties || []).length },
|
|
59
61
|
{ title: "描述", dataIndex: "description", key: "description", ellipsis: !0 },
|
|
60
62
|
{
|
|
61
63
|
title: "操作",
|
|
62
64
|
key: "op",
|
|
63
65
|
width: 170,
|
|
64
|
-
render: (
|
|
65
|
-
/* @__PURE__ */ e(
|
|
66
|
-
/* @__PURE__ */ e(
|
|
67
|
-
/* @__PURE__ */ e(B, { title: `删除本体 ${
|
|
66
|
+
render: (r, t) => /* @__PURE__ */ i(k, { size: "small", children: [
|
|
67
|
+
/* @__PURE__ */ e(o, { size: "small", type: "link", onClick: () => l(`/ontology/detail?id=${encodeURIComponent(t.id)}`), children: "详情" }),
|
|
68
|
+
/* @__PURE__ */ e(o, { size: "small", type: "link", onClick: () => l(`/ontology/nodes?id=${encodeURIComponent(t.id)}`), children: "图谱" }),
|
|
69
|
+
/* @__PURE__ */ e(B, { title: `删除本体 ${t.id}?`, onConfirm: () => C(t.id), children: /* @__PURE__ */ e(o, { size: "small", type: "link", danger: !0, children: "删除" }) })
|
|
68
70
|
] })
|
|
69
71
|
}
|
|
70
72
|
];
|
|
71
73
|
return /* @__PURE__ */ i("div", { children: [
|
|
72
74
|
/* @__PURE__ */ i(k, { style: { marginBottom: 12 }, children: [
|
|
73
|
-
/* @__PURE__ */ e(
|
|
74
|
-
/* @__PURE__ */ e(
|
|
75
|
+
/* @__PURE__ */ e(o, { type: "primary", icon: /* @__PURE__ */ e(R, {}), onClick: () => h(!0), children: "登记本体" }),
|
|
76
|
+
/* @__PURE__ */ e(o, { icon: /* @__PURE__ */ e(z, {}), onClick: d, children: "刷新" }),
|
|
75
77
|
/* @__PURE__ */ i("span", { style: { color: "#999", fontSize: 12 }, children: [
|
|
76
78
|
"共 ",
|
|
77
79
|
c.length,
|
|
@@ -99,14 +101,14 @@ function G() {
|
|
|
99
101
|
confirmLoading: x,
|
|
100
102
|
width: 720,
|
|
101
103
|
destroyOnClose: !0,
|
|
102
|
-
children: /* @__PURE__ */ i(
|
|
103
|
-
/* @__PURE__ */ e(
|
|
104
|
-
/* @__PURE__ */ e(
|
|
105
|
-
/* @__PURE__ */ e(
|
|
106
|
-
/* @__PURE__ */ e(
|
|
107
|
-
/* @__PURE__ */ e(
|
|
108
|
-
/* @__PURE__ */ e(
|
|
109
|
-
/* @__PURE__ */ e(
|
|
104
|
+
children: /* @__PURE__ */ i(s, { form: f, layout: "vertical", initialValues: { version: "1.0.0" }, children: [
|
|
105
|
+
/* @__PURE__ */ e(s.Item, { name: "id", label: "本体 ID", rules: [{ required: !0, message: "必填" }], children: /* @__PURE__ */ e(n, { placeholder: "如 core-ontology" }) }),
|
|
106
|
+
/* @__PURE__ */ e(s.Item, { name: "name", label: "名称", rules: [{ required: !0, message: "必填" }], children: /* @__PURE__ */ e(n, { placeholder: "如 核心本体" }) }),
|
|
107
|
+
/* @__PURE__ */ e(s.Item, { name: "version", label: "版本", children: /* @__PURE__ */ e(n, { placeholder: "1.0.0" }) }),
|
|
108
|
+
/* @__PURE__ */ e(s.Item, { name: "description", label: "描述", children: /* @__PURE__ */ e(n, { placeholder: "这个本体管什么" }) }),
|
|
109
|
+
/* @__PURE__ */ e(s.Item, { name: "prefixes", label: "前缀映射(JSON)", children: /* @__PURE__ */ e(y, { rows: 2, placeholder: '{"ex": "http://example.org/"}' }) }),
|
|
110
|
+
/* @__PURE__ */ e(s.Item, { name: "classes", label: "类定义(JSON 数组)", children: /* @__PURE__ */ e(y, { rows: 4, placeholder: '[{"name":"Person","label":"人"}]' }) }),
|
|
111
|
+
/* @__PURE__ */ e(s.Item, { name: "properties", label: "属性定义(JSON 数组)", children: /* @__PURE__ */ e(y, { rows: 4, placeholder: '[{"name":"knows","kind":"OBJECT"}]' }) })
|
|
110
112
|
] })
|
|
111
113
|
}
|
|
112
114
|
)
|
|
@@ -120,5 +122,5 @@ function g(l, c) {
|
|
|
120
122
|
}
|
|
121
123
|
}
|
|
122
124
|
export {
|
|
123
|
-
|
|
125
|
+
Q as default
|
|
124
126
|
};
|
|
@@ -0,0 +1,136 @@
|
|
|
1
|
+
import { jsx as e, jsxs as o } from "react/jsx-runtime";
|
|
2
|
+
import { useState as i, useEffect as j } from "react";
|
|
3
|
+
import { o as u, f as l } from "./api-BVrIcAFp.js";
|
|
4
|
+
import { parseSnapshot as E } from "./OntologyValidatePage-abQVJwzV.js";
|
|
5
|
+
import { b as N } from "./chunk-YDNE64FV-DGyyfCo0.js";
|
|
6
|
+
import { A as O } from "./index-nQSVLWfW.js";
|
|
7
|
+
import { S as P, B as $ } from "./index-CrMcNEAZ.js";
|
|
8
|
+
import { C as b } from "./index-Cfu1W1H6.js";
|
|
9
|
+
import { S as h } from "./index-CaXylbQR.js";
|
|
10
|
+
import { S as w } from "./index-bOY1cBol.js";
|
|
11
|
+
import { I as p } from "./index-DvWHYX81.js";
|
|
12
|
+
import { R as F } from "./pages-CsexFuEz.js";
|
|
13
|
+
import { D as a } from "./index-9aQ4BzIK.js";
|
|
14
|
+
import { T as z } from "./index-Bc-Vin3j.js";
|
|
15
|
+
import { s as C } from "./index-DBtGE89a.js";
|
|
16
|
+
const { TextArea: L } = p;
|
|
17
|
+
function re() {
|
|
18
|
+
var S;
|
|
19
|
+
const [x] = N(), n = x.get("id") || "", [s, R] = i("source"), [d, A] = i("default"), [c, f] = i(""), [g, B] = i(`{
|
|
20
|
+
"individuals": [],
|
|
21
|
+
"statements": []
|
|
22
|
+
}`), [k, v] = i([]), [r, m] = i(null), [D, y] = i(!1);
|
|
23
|
+
j(() => {
|
|
24
|
+
n && u.listSources().then(v).catch(() => v([]));
|
|
25
|
+
}, [n]);
|
|
26
|
+
const M = async () => {
|
|
27
|
+
y(!0), m(null);
|
|
28
|
+
try {
|
|
29
|
+
if (s === "source") {
|
|
30
|
+
if (!c.trim()) {
|
|
31
|
+
C.warning("按来源物化需要指定 source");
|
|
32
|
+
return;
|
|
33
|
+
}
|
|
34
|
+
m(await u.materialize(n, c.trim(), d));
|
|
35
|
+
} else
|
|
36
|
+
m(await u.materializeInline(n, E(g), d));
|
|
37
|
+
} catch (t) {
|
|
38
|
+
C.error(t.message);
|
|
39
|
+
} finally {
|
|
40
|
+
y(!1);
|
|
41
|
+
}
|
|
42
|
+
};
|
|
43
|
+
if (!n)
|
|
44
|
+
return /* @__PURE__ */ e(O, { type: "warning", message: "缺少本体 ID(?id=xxx)" });
|
|
45
|
+
const I = ((S = r == null ? void 0 : r.validation) == null ? void 0 : S.issues) || [];
|
|
46
|
+
return /* @__PURE__ */ o(P, { spinning: D, children: [
|
|
47
|
+
/* @__PURE__ */ e(b, { size: "small", title: "物化输入", style: { marginBottom: 16 }, children: /* @__PURE__ */ o(h, { direction: "vertical", style: { width: "100%" }, size: 12, children: [
|
|
48
|
+
/* @__PURE__ */ o(h, { wrap: !0, children: [
|
|
49
|
+
/* @__PURE__ */ e(
|
|
50
|
+
w,
|
|
51
|
+
{
|
|
52
|
+
style: { width: 200 },
|
|
53
|
+
value: s,
|
|
54
|
+
onChange: R,
|
|
55
|
+
options: [
|
|
56
|
+
{ value: "source", label: "按来源物化" },
|
|
57
|
+
{ value: "inline", label: "内联快照物化" }
|
|
58
|
+
]
|
|
59
|
+
}
|
|
60
|
+
),
|
|
61
|
+
/* @__PURE__ */ e(
|
|
62
|
+
p,
|
|
63
|
+
{
|
|
64
|
+
style: { width: 220 },
|
|
65
|
+
placeholder: "工作空间",
|
|
66
|
+
value: d,
|
|
67
|
+
onChange: (t) => A(t.target.value)
|
|
68
|
+
}
|
|
69
|
+
),
|
|
70
|
+
s === "source" ? /* @__PURE__ */ e(
|
|
71
|
+
w,
|
|
72
|
+
{
|
|
73
|
+
style: { width: 280 },
|
|
74
|
+
placeholder: "选择数据源",
|
|
75
|
+
value: c || void 0,
|
|
76
|
+
onChange: f,
|
|
77
|
+
showSearch: !0,
|
|
78
|
+
options: k.map((t) => ({ value: t.id, label: t.description ? `${t.id} — ${t.description}` : t.id })),
|
|
79
|
+
notFoundContent: null
|
|
80
|
+
}
|
|
81
|
+
) : null,
|
|
82
|
+
/* @__PURE__ */ e($, { type: "primary", icon: /* @__PURE__ */ e(F, {}), onClick: M, children: "执行物化" })
|
|
83
|
+
] }),
|
|
84
|
+
s === "source" ? /* @__PURE__ */ e(
|
|
85
|
+
p,
|
|
86
|
+
{
|
|
87
|
+
style: { width: 420 },
|
|
88
|
+
placeholder: "source ID(可直接输入)",
|
|
89
|
+
value: c,
|
|
90
|
+
onChange: (t) => f(t.target.value)
|
|
91
|
+
}
|
|
92
|
+
) : /* @__PURE__ */ e(
|
|
93
|
+
L,
|
|
94
|
+
{
|
|
95
|
+
rows: 10,
|
|
96
|
+
value: g,
|
|
97
|
+
onChange: (t) => B(t.target.value),
|
|
98
|
+
placeholder: '{"individuals": [], "statements": []}'
|
|
99
|
+
}
|
|
100
|
+
)
|
|
101
|
+
] }) }),
|
|
102
|
+
r ? /* @__PURE__ */ o(b, { size: "small", title: "物化报告", children: [
|
|
103
|
+
/* @__PURE__ */ o(a, { bordered: !0, size: "small", column: 2, style: { marginBottom: 12 }, children: [
|
|
104
|
+
/* @__PURE__ */ e(a.Item, { label: "本体", children: l(r, "ontologyId") }),
|
|
105
|
+
/* @__PURE__ */ e(a.Item, { label: "工作空间", children: l(r, "workspace") }),
|
|
106
|
+
/* @__PURE__ */ e(a.Item, { label: "来源", children: l(r, "sourceId") || "(内联)" }),
|
|
107
|
+
/* @__PURE__ */ o(a.Item, { label: "耗时", children: [
|
|
108
|
+
l(r, "durationMs"),
|
|
109
|
+
" ms"
|
|
110
|
+
] }),
|
|
111
|
+
/* @__PURE__ */ e(a.Item, { label: "类节点", children: l(r, "classNodes") }),
|
|
112
|
+
/* @__PURE__ */ e(a.Item, { label: "实例节点", children: l(r, "individualNodes") }),
|
|
113
|
+
/* @__PURE__ */ e(a.Item, { label: "边", children: l(r, "edges") }),
|
|
114
|
+
/* @__PURE__ */ e(a.Item, { label: "物化时间", children: l(r, "materializedAt") || "—" })
|
|
115
|
+
] }),
|
|
116
|
+
/* @__PURE__ */ o(h, { size: "large", wrap: !0, style: { marginBottom: 8 }, children: [
|
|
117
|
+
/* @__PURE__ */ o("span", { children: [
|
|
118
|
+
"显式陈述 ",
|
|
119
|
+
/* @__PURE__ */ e("b", { children: l(r, "explicitStatements") })
|
|
120
|
+
] }),
|
|
121
|
+
/* @__PURE__ */ o("span", { children: [
|
|
122
|
+
"推理陈述 ",
|
|
123
|
+
/* @__PURE__ */ e("b", { children: l(r, "inferredStatements") })
|
|
124
|
+
] })
|
|
125
|
+
] }),
|
|
126
|
+
I.length ? /* @__PURE__ */ e("div", { children: I.map((t, T) => /* @__PURE__ */ o(z, { color: t.severity === "ERROR" ? "red" : "orange", children: [
|
|
127
|
+
t.code,
|
|
128
|
+
" ",
|
|
129
|
+
t.message
|
|
130
|
+
] }, T)) }) : /* @__PURE__ */ e(z, { color: "green", children: "物化通过,无校验问题" })
|
|
131
|
+
] }) : null
|
|
132
|
+
] });
|
|
133
|
+
}
|
|
134
|
+
export {
|
|
135
|
+
re as default
|
|
136
|
+
};
|