@kortexya/reasoninglayer 6.2.0 → 7.1.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/README.md +1 -1
- package/dist/index.cjs +3107 -49
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +5854 -138
- package/dist/index.d.ts +5854 -138
- package/dist/index.js +3107 -49
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -7,7 +7,7 @@ var __export = (target, all) => {
|
|
|
7
7
|
};
|
|
8
8
|
|
|
9
9
|
// src/config.ts
|
|
10
|
-
var SDK_VERSION = "
|
|
10
|
+
var SDK_VERSION = "7.1.0";
|
|
11
11
|
function resolveConfig(config) {
|
|
12
12
|
if (!config.baseUrl) {
|
|
13
13
|
throw new Error("ClientConfig.baseUrl is required");
|
|
@@ -1044,6 +1044,7 @@ var REQUEST_BUDGET_HEADER = "X-RL-Request-Budget";
|
|
|
1044
1044
|
function toRequestParams(options, budgetOverrides) {
|
|
1045
1045
|
if (options === void 0 && budgetOverrides === void 0) return {};
|
|
1046
1046
|
const headers = {};
|
|
1047
|
+
if (options?.cacheControl !== void 0) headers["Cache-Control"] = options.cacheControl;
|
|
1047
1048
|
if (options?.userId !== void 0) headers["X-User-Id"] = options.userId;
|
|
1048
1049
|
if (options?.namespaceId !== void 0) headers["X-Namespace-Id"] = options.namespaceId;
|
|
1049
1050
|
if (options?.causal !== void 0) Object.assign(headers, causalRequestHeaders(options.causal));
|
|
@@ -1501,6 +1502,22 @@ var Sorts = class {
|
|
|
1501
1502
|
format: "json",
|
|
1502
1503
|
...params
|
|
1503
1504
|
});
|
|
1505
|
+
/**
|
|
1506
|
+
* @description ⭐ `POST /api/v1/sorts/subsumption/get` answers one pair per request, and `/sorts/compare/batch` does not close the gap: it carries an operator and a `bool`, a crisp verdict, never a degree (`docs/OPEN_DEFECTS.md` #100). ⛔ A batch is N singles and nothing else, which is why a pair naming a sort outside the caller's view refuses the WHOLE request with 404, exactly as the single route would for that pair. One HTTP response cannot carry N statuses, and answering `0.0` where the single route answers 404 would make this a different question. A caller must therefore not mix views in one batch.
|
|
1507
|
+
*
|
|
1508
|
+
* @tags sorts
|
|
1509
|
+
* @name BatchGetSubsumptions
|
|
1510
|
+
* @summary Read many `⊑·` degrees in one request, aligned with the pairs asked.
|
|
1511
|
+
* @request POST:/api/v1/sorts/subsumption/get/batch
|
|
1512
|
+
*/
|
|
1513
|
+
batchGetSubsumptions = (data, params = {}) => this.http.request({
|
|
1514
|
+
path: `/api/v1/sorts/subsumption/get/batch`,
|
|
1515
|
+
method: "POST",
|
|
1516
|
+
body: data,
|
|
1517
|
+
type: "application/json",
|
|
1518
|
+
format: "json",
|
|
1519
|
+
...params
|
|
1520
|
+
});
|
|
1504
1521
|
/**
|
|
1505
1522
|
* @description POST /api/v1/sorts/bulk Creates multiple sorts in a single request, automatically resolving parent references by name. Sorts are topologically sorted to ensure parents are created before children. This is much faster than individual requests for large hierarchies. # Authorization Requires X-Tenant-Id header. The tenant_id field in the request body is ignored.
|
|
1506
1523
|
*
|
|
@@ -1535,6 +1552,22 @@ var Sorts = class {
|
|
|
1535
1552
|
format: "json",
|
|
1536
1553
|
...params
|
|
1537
1554
|
});
|
|
1555
|
+
/**
|
|
1556
|
+
* @description ⭐ `POST /api/v1/sorts/subsumption` writes one pair per request. Measured on a 13 199-pair graded campaign: 52 796 requests, and a 500-pair slice spent 1 200 s without finishing its sort creations (`docs/OPEN_DEFECTS.md` #100). ⛔ **Per-entry outcomes, unlike `bulk_set_similarities`** — but the two kinds of refusal differ, and conflating them would be a false promise: * a **visibility** refusal is attributed to its entry and the rest of the declaration proceeds, because that rule is this handler's and is checked per entry; * a **relation-law** refusal (a degree out of range, a disjoint facet, a max–min transitivity or antisymmetry violation) rolls the WHOLE declaration back and marks every admitted entry with one shared reason, because the kernel validates the relation once and names the violation without naming the edge. `set_count` is then 0 and nothing was written. Either way every requested entry answers for itself in the order asked, so a caller never has to re-read the batch pair by pair to learn what the engine holds — which is what `AGENTS.md` means by keeping failed evidence distinct from absent evidence. ⚠️ The discipline of the similarity route is kept exactly: both endpoints of every entry must be writable by the caller, the whole accepted batch is validated on a staging fork **before** recovery is armed or any durable prefix is written, and every written edge is mirrored into the tenant lattice every graded route reads (#113) — a bulk write that skipped the mirror would be a quieter version of that same defect.
|
|
1557
|
+
*
|
|
1558
|
+
* @tags sorts
|
|
1559
|
+
* @name BulkSetSubsumptions
|
|
1560
|
+
* @summary Declare many `⊑·` degrees in one request, answering for EVERY entry.
|
|
1561
|
+
* @request POST:/api/v1/sorts/subsumption/bulk
|
|
1562
|
+
*/
|
|
1563
|
+
bulkSetSubsumptions = (data, params = {}) => this.http.request({
|
|
1564
|
+
path: `/api/v1/sorts/subsumption/bulk`,
|
|
1565
|
+
method: "POST",
|
|
1566
|
+
body: data,
|
|
1567
|
+
type: "application/json",
|
|
1568
|
+
format: "json",
|
|
1569
|
+
...params
|
|
1570
|
+
});
|
|
1538
1571
|
/**
|
|
1539
1572
|
* @description A unique declared minimal common supersort is answered as is. Otherwise the engine declares the synthetic join `⊔(…)` over the minimal upper bounds and places it above both operands.
|
|
1540
1573
|
*
|
|
@@ -1599,6 +1632,22 @@ var Sorts = class {
|
|
|
1599
1632
|
format: "json",
|
|
1600
1633
|
...params
|
|
1601
1634
|
});
|
|
1635
|
+
/**
|
|
1636
|
+
* @description ⭐ One request where the pairwise route needs one per candidate: the graded relation carries a reverse adjacency, so this costs the in-degree of the concept rather than a scan of every pair. ⚠️ **Declared `⊑·` edges only** — the crisp order is not composed in, so this is not `/api/v1/sorts/subsumption/get` lifted to a set. `alpha` is a declared query parameter; the kernel refuses it outside `[0, 1]` and that refusal surfaces as `400`. ⛔ Every member is filtered against the caller's view before it is returned. The in-memory adapter already fails closed; the hot-lattice adapter cannot (absence there is not evidence of another tenant's ownership), so the filter here is what makes the route safe on both.
|
|
1637
|
+
*
|
|
1638
|
+
* @tags sorts
|
|
1639
|
+
* @name DeclaredAlphaCutBelow
|
|
1640
|
+
* @summary The α-cut of the declared graded cone below a concept, strongest first.
|
|
1641
|
+
* @request POST:/api/v1/sorts/subsumption/alpha-cut
|
|
1642
|
+
*/
|
|
1643
|
+
declaredAlphaCutBelow = (data, params = {}) => this.http.request({
|
|
1644
|
+
path: `/api/v1/sorts/subsumption/alpha-cut`,
|
|
1645
|
+
method: "POST",
|
|
1646
|
+
body: data,
|
|
1647
|
+
type: "application/json",
|
|
1648
|
+
format: "json",
|
|
1649
|
+
...params
|
|
1650
|
+
});
|
|
1602
1651
|
/**
|
|
1603
1652
|
* @description Computes the bit-vector intersection (GLB) and decodes it into a human-readable type disjunction. This is Life1.0's decode() function. A read (#522): a pair with no declared common subsort decodes to ⊥. # Returns - `sort_ids`: List of sort IDs in the disjunction - `sort_names`: List of sort names in the disjunction - `formatted`: Human-readable format (e.g., "int | real") - `is_bottom`: True if the GLB is empty (incompatible sorts)
|
|
1604
1653
|
*
|
|
@@ -1669,11 +1718,11 @@ var Sorts = class {
|
|
|
1669
1718
|
...params
|
|
1670
1719
|
});
|
|
1671
1720
|
/**
|
|
1672
|
-
* @description
|
|
1721
|
+
* @description Never writes. Search exhaustion concerns the stated tenant/policy cohort; presentation can truncate independently. Accepting a candidate still requires the existing governed declaration and reparenting operations. Neither this report nor its digest is an admission seal.
|
|
1673
1722
|
*
|
|
1674
1723
|
* @tags sorts
|
|
1675
1724
|
* @name FactorSortShapes
|
|
1676
|
-
* @summary Propose mixin parents
|
|
1725
|
+
* @summary Propose mixin parents using checked native FCA over whole declarations.
|
|
1677
1726
|
* @request POST:/api/v1/sorts/discovery/factor
|
|
1678
1727
|
* @secure
|
|
1679
1728
|
*/
|
|
@@ -8511,6 +8560,24 @@ var Constraints = class {
|
|
|
8511
8560
|
format: "json",
|
|
8512
8561
|
...params
|
|
8513
8562
|
});
|
|
8563
|
+
/**
|
|
8564
|
+
* @description Unlike `POST /api/v1/constraints/solve`, which propagates and suspends, this route **searches**: it branches over the declared domains with propagation at every node, so a satisfiable problem yields assignments rather than a list of suspended constraints. An unsatisfiable problem answers `200` with `satisfiable: false` and no solutions; that is an answer, not a bad request.
|
|
8565
|
+
*
|
|
8566
|
+
* @tags constraints
|
|
8567
|
+
* @name SolveCsp
|
|
8568
|
+
* @summary Label a finite-domain constraint problem, returning complete assignments.
|
|
8569
|
+
* @request POST:/api/v1/csp/solve
|
|
8570
|
+
* @secure
|
|
8571
|
+
*/
|
|
8572
|
+
solveCsp = (data, params = {}) => this.http.request({
|
|
8573
|
+
path: `/api/v1/csp/solve`,
|
|
8574
|
+
method: "POST",
|
|
8575
|
+
body: data,
|
|
8576
|
+
secure: true,
|
|
8577
|
+
type: "application/json",
|
|
8578
|
+
format: "json",
|
|
8579
|
+
...params
|
|
8580
|
+
});
|
|
8514
8581
|
};
|
|
8515
8582
|
|
|
8516
8583
|
// src/api-spec/generated/Reasoning.ts
|
|
@@ -9408,6 +9475,36 @@ var Namespaces = class {
|
|
|
9408
9475
|
format: "json",
|
|
9409
9476
|
...params
|
|
9410
9477
|
});
|
|
9478
|
+
/**
|
|
9479
|
+
* No description
|
|
9480
|
+
*
|
|
9481
|
+
* @tags namespaces
|
|
9482
|
+
* @name GetNamespaceAnswerCachePolicy
|
|
9483
|
+
* @request GET:/api/v1/namespaces/{id}/answer-cache-policy
|
|
9484
|
+
* @secure
|
|
9485
|
+
*/
|
|
9486
|
+
getNamespaceAnswerCachePolicy = (id, params = {}) => this.http.request({
|
|
9487
|
+
path: `/api/v1/namespaces/${id}/answer-cache-policy`,
|
|
9488
|
+
method: "GET",
|
|
9489
|
+
secure: true,
|
|
9490
|
+
format: "json",
|
|
9491
|
+
...params
|
|
9492
|
+
});
|
|
9493
|
+
/**
|
|
9494
|
+
* No description
|
|
9495
|
+
*
|
|
9496
|
+
* @tags namespaces
|
|
9497
|
+
* @name GetNamespaceAnswerCacheSavings
|
|
9498
|
+
* @request GET:/api/v1/namespaces/{id}/answer-cache-savings
|
|
9499
|
+
* @secure
|
|
9500
|
+
*/
|
|
9501
|
+
getNamespaceAnswerCacheSavings = (id, params = {}) => this.http.request({
|
|
9502
|
+
path: `/api/v1/namespaces/${id}/answer-cache-savings`,
|
|
9503
|
+
method: "GET",
|
|
9504
|
+
secure: true,
|
|
9505
|
+
format: "json",
|
|
9506
|
+
...params
|
|
9507
|
+
});
|
|
9411
9508
|
/**
|
|
9412
9509
|
* No description
|
|
9413
9510
|
*
|
|
@@ -9456,6 +9553,23 @@ var Namespaces = class {
|
|
|
9456
9553
|
format: "json",
|
|
9457
9554
|
...params
|
|
9458
9555
|
});
|
|
9556
|
+
/**
|
|
9557
|
+
* No description
|
|
9558
|
+
*
|
|
9559
|
+
* @tags namespaces
|
|
9560
|
+
* @name UpdateNamespaceAnswerCachePolicy
|
|
9561
|
+
* @request PUT:/api/v1/namespaces/{id}/answer-cache-policy
|
|
9562
|
+
* @secure
|
|
9563
|
+
*/
|
|
9564
|
+
updateNamespaceAnswerCachePolicy = (id, data, params = {}) => this.http.request({
|
|
9565
|
+
path: `/api/v1/namespaces/${id}/answer-cache-policy`,
|
|
9566
|
+
method: "PUT",
|
|
9567
|
+
body: data,
|
|
9568
|
+
secure: true,
|
|
9569
|
+
type: "application/json",
|
|
9570
|
+
format: "json",
|
|
9571
|
+
...params
|
|
9572
|
+
});
|
|
9459
9573
|
/**
|
|
9460
9574
|
* No description
|
|
9461
9575
|
*
|
|
@@ -10033,6 +10147,21 @@ var Analysis = class {
|
|
|
10033
10147
|
format: "json",
|
|
10034
10148
|
...params
|
|
10035
10149
|
});
|
|
10150
|
+
/**
|
|
10151
|
+
* @description The first line names the objects (source term identities) and attributes (feature names); each concept line gives its extent and intent as indices into them; the last line gives the counters, whether the stream is complete and, when it stopped early, the continuation that resumes it.
|
|
10152
|
+
*
|
|
10153
|
+
* @tags analysis
|
|
10154
|
+
* @name StreamFcaConcepts
|
|
10155
|
+
* @summary Stream the formal concepts of a visible scope as NDJSON.
|
|
10156
|
+
* @request POST:/api/v1/analysis/fca-concepts/stream
|
|
10157
|
+
*/
|
|
10158
|
+
streamFcaConcepts = (data, params = {}) => this.http.request({
|
|
10159
|
+
path: `/api/v1/analysis/fca-concepts/stream`,
|
|
10160
|
+
method: "POST",
|
|
10161
|
+
body: data,
|
|
10162
|
+
type: "application/json",
|
|
10163
|
+
...params
|
|
10164
|
+
});
|
|
10036
10165
|
/**
|
|
10037
10166
|
* No description
|
|
10038
10167
|
*
|
|
@@ -11429,7 +11558,7 @@ var Ontology = class {
|
|
|
11429
11558
|
...params
|
|
11430
11559
|
});
|
|
11431
11560
|
/**
|
|
11432
|
-
* @description Every metric is derived from the tenant's live lattice and term store. The state of a stage comes from a scoped assessment only; no stage is accepted because of its counts. The vocabulary
|
|
11561
|
+
* @description Every metric is derived from the tenant's live lattice and term store, or from the active governed vocabulary release when that release is the stage's basis. The state of a stage comes from a scoped assessment only; no stage is accepted because of its counts. The evidence of the vocabulary, taxonomy and thesaurus stages is the governed vocabulary store: the active release and the criteria results of the assessment it cites. When that store cannot be read, the whole status is refused (`503`) rather than served with the stages degraded: reporting `not_assessed` for a tenant that may hold an active release would state something the engine does not know.
|
|
11433
11562
|
*
|
|
11434
11563
|
* @tags ontology
|
|
11435
11564
|
* @name OntologyPipelineStatus
|
|
@@ -16363,6 +16492,24 @@ var Vocabulary = class {
|
|
|
16363
16492
|
format: "json",
|
|
16364
16493
|
...params
|
|
16365
16494
|
});
|
|
16495
|
+
/**
|
|
16496
|
+
* No description
|
|
16497
|
+
*
|
|
16498
|
+
* @tags vocabulary
|
|
16499
|
+
* @name ApplyMigrationPlan
|
|
16500
|
+
* @summary `POST /api/v1/vocabulary/migration/plans/{plan_id}/apply` — apply a plan as a new candidate on the active release; `409 migration_plan_stale` when the legacy inventory changed since the plan.
|
|
16501
|
+
* @request POST:/api/v1/vocabulary/migration/plans/{plan_id}/apply
|
|
16502
|
+
* @secure
|
|
16503
|
+
*/
|
|
16504
|
+
applyMigrationPlan = (planId, data, params = {}) => this.http.request({
|
|
16505
|
+
path: `/api/v1/vocabulary/migration/plans/${planId}/apply`,
|
|
16506
|
+
method: "POST",
|
|
16507
|
+
body: data,
|
|
16508
|
+
secure: true,
|
|
16509
|
+
type: "application/json",
|
|
16510
|
+
format: "json",
|
|
16511
|
+
...params
|
|
16512
|
+
});
|
|
16366
16513
|
/**
|
|
16367
16514
|
* No description
|
|
16368
16515
|
*
|
|
@@ -16399,6 +16546,41 @@ var Vocabulary = class {
|
|
|
16399
16546
|
format: "json",
|
|
16400
16547
|
...params
|
|
16401
16548
|
});
|
|
16549
|
+
/**
|
|
16550
|
+
* No description
|
|
16551
|
+
*
|
|
16552
|
+
* @tags vocabulary
|
|
16553
|
+
* @name CommitImport
|
|
16554
|
+
* @summary `POST /api/v1/vocabulary/imports/{import_id}/commit` — apply the reviewer's decisions and write one candidate revision: a new candidate, or revision n+1 of `candidate_id` (with `If-Match`).
|
|
16555
|
+
* @request POST:/api/v1/vocabulary/imports/{import_id}/commit
|
|
16556
|
+
* @secure
|
|
16557
|
+
*/
|
|
16558
|
+
commitImport = (importId, data, params = {}) => this.http.request({
|
|
16559
|
+
path: `/api/v1/vocabulary/imports/${importId}/commit`,
|
|
16560
|
+
method: "POST",
|
|
16561
|
+
body: data,
|
|
16562
|
+
secure: true,
|
|
16563
|
+
type: "application/json",
|
|
16564
|
+
format: "json",
|
|
16565
|
+
...params
|
|
16566
|
+
});
|
|
16567
|
+
/**
|
|
16568
|
+
* No description
|
|
16569
|
+
*
|
|
16570
|
+
* @tags vocabulary
|
|
16571
|
+
* @name ConceptExpansion
|
|
16572
|
+
* @summary `GET /api/v1/vocabulary/concepts/{concept_id}/expansion` — the concepts a query on one concept may be expanded to, each with its support.
|
|
16573
|
+
* @request GET:/api/v1/vocabulary/concepts/{concept_id}/expansion
|
|
16574
|
+
* @secure
|
|
16575
|
+
*/
|
|
16576
|
+
conceptExpansion = (conceptId, query, params = {}) => this.http.request({
|
|
16577
|
+
path: `/api/v1/vocabulary/concepts/${conceptId}/expansion`,
|
|
16578
|
+
method: "GET",
|
|
16579
|
+
query,
|
|
16580
|
+
secure: true,
|
|
16581
|
+
format: "json",
|
|
16582
|
+
...params
|
|
16583
|
+
});
|
|
16402
16584
|
/**
|
|
16403
16585
|
* No description
|
|
16404
16586
|
*
|
|
@@ -16415,6 +16597,23 @@ var Vocabulary = class {
|
|
|
16415
16597
|
format: "json",
|
|
16416
16598
|
...params
|
|
16417
16599
|
});
|
|
16600
|
+
/**
|
|
16601
|
+
* No description
|
|
16602
|
+
*
|
|
16603
|
+
* @tags vocabulary
|
|
16604
|
+
* @name ConceptRelations
|
|
16605
|
+
* @summary `GET /api/v1/vocabulary/concepts/{concept_id}/relations` — the direct relations of one kind of a concept in one scheme, of every status.
|
|
16606
|
+
* @request GET:/api/v1/vocabulary/concepts/{concept_id}/relations
|
|
16607
|
+
* @secure
|
|
16608
|
+
*/
|
|
16609
|
+
conceptRelations = (conceptId, query, params = {}) => this.http.request({
|
|
16610
|
+
path: `/api/v1/vocabulary/concepts/${conceptId}/relations`,
|
|
16611
|
+
method: "GET",
|
|
16612
|
+
query,
|
|
16613
|
+
secure: true,
|
|
16614
|
+
format: "json",
|
|
16615
|
+
...params
|
|
16616
|
+
});
|
|
16418
16617
|
/**
|
|
16419
16618
|
* No description
|
|
16420
16619
|
*
|
|
@@ -16433,6 +16632,76 @@ var Vocabulary = class {
|
|
|
16433
16632
|
format: "json",
|
|
16434
16633
|
...params
|
|
16435
16634
|
});
|
|
16635
|
+
/**
|
|
16636
|
+
* No description
|
|
16637
|
+
*
|
|
16638
|
+
* @tags vocabulary
|
|
16639
|
+
* @name CreateImport
|
|
16640
|
+
* @summary `POST /api/v1/vocabulary/imports` — parse an uploaded source file and store its proposal. Writes no vocabulary record.
|
|
16641
|
+
* @request POST:/api/v1/vocabulary/imports
|
|
16642
|
+
* @secure
|
|
16643
|
+
*/
|
|
16644
|
+
createImport = (data, params = {}) => this.http.request({
|
|
16645
|
+
path: `/api/v1/vocabulary/imports`,
|
|
16646
|
+
method: "POST",
|
|
16647
|
+
body: data,
|
|
16648
|
+
secure: true,
|
|
16649
|
+
type: "application/json",
|
|
16650
|
+
format: "json",
|
|
16651
|
+
...params
|
|
16652
|
+
});
|
|
16653
|
+
/**
|
|
16654
|
+
* No description
|
|
16655
|
+
*
|
|
16656
|
+
* @tags vocabulary
|
|
16657
|
+
* @name CreateMigrationPlan
|
|
16658
|
+
* @summary `POST /api/v1/vocabulary/migration/plans` — store the reviewer's dispositions of legacy sorts over the current legacy inventory.
|
|
16659
|
+
* @request POST:/api/v1/vocabulary/migration/plans
|
|
16660
|
+
* @secure
|
|
16661
|
+
*/
|
|
16662
|
+
createMigrationPlan = (data, params = {}) => this.http.request({
|
|
16663
|
+
path: `/api/v1/vocabulary/migration/plans`,
|
|
16664
|
+
method: "POST",
|
|
16665
|
+
body: data,
|
|
16666
|
+
secure: true,
|
|
16667
|
+
type: "application/json",
|
|
16668
|
+
format: "json",
|
|
16669
|
+
...params
|
|
16670
|
+
});
|
|
16671
|
+
/**
|
|
16672
|
+
* No description
|
|
16673
|
+
*
|
|
16674
|
+
* @tags vocabulary
|
|
16675
|
+
* @name ExportNative
|
|
16676
|
+
* @summary `GET /api/v1/vocabulary/exports/native` — the view's records as `kos-json/v1`.
|
|
16677
|
+
* @request GET:/api/v1/vocabulary/exports/native
|
|
16678
|
+
* @secure
|
|
16679
|
+
*/
|
|
16680
|
+
exportNative = (query, params = {}) => this.http.request({
|
|
16681
|
+
path: `/api/v1/vocabulary/exports/native`,
|
|
16682
|
+
method: "GET",
|
|
16683
|
+
query,
|
|
16684
|
+
secure: true,
|
|
16685
|
+
format: "json",
|
|
16686
|
+
...params
|
|
16687
|
+
});
|
|
16688
|
+
/**
|
|
16689
|
+
* No description
|
|
16690
|
+
*
|
|
16691
|
+
* @tags vocabulary
|
|
16692
|
+
* @name ExportSkos
|
|
16693
|
+
* @summary `GET /api/v1/vocabulary/exports/skos` — the SKOS projection of one scheme as Turtle or RDF/XML, with its manifest.
|
|
16694
|
+
* @request GET:/api/v1/vocabulary/exports/skos
|
|
16695
|
+
* @secure
|
|
16696
|
+
*/
|
|
16697
|
+
exportSkos = (query, params = {}) => this.http.request({
|
|
16698
|
+
path: `/api/v1/vocabulary/exports/skos`,
|
|
16699
|
+
method: "GET",
|
|
16700
|
+
query,
|
|
16701
|
+
secure: true,
|
|
16702
|
+
format: "json",
|
|
16703
|
+
...params
|
|
16704
|
+
});
|
|
16436
16705
|
/**
|
|
16437
16706
|
* No description
|
|
16438
16707
|
*
|
|
@@ -16498,6 +16767,38 @@ var Vocabulary = class {
|
|
|
16498
16767
|
format: "json",
|
|
16499
16768
|
...params
|
|
16500
16769
|
});
|
|
16770
|
+
/**
|
|
16771
|
+
* No description
|
|
16772
|
+
*
|
|
16773
|
+
* @tags vocabulary
|
|
16774
|
+
* @name GetImport
|
|
16775
|
+
* @summary `GET /api/v1/vocabulary/imports/{import_id}` — an import.
|
|
16776
|
+
* @request GET:/api/v1/vocabulary/imports/{import_id}
|
|
16777
|
+
* @secure
|
|
16778
|
+
*/
|
|
16779
|
+
getImport = (importId, params = {}) => this.http.request({
|
|
16780
|
+
path: `/api/v1/vocabulary/imports/${importId}`,
|
|
16781
|
+
method: "GET",
|
|
16782
|
+
secure: true,
|
|
16783
|
+
format: "json",
|
|
16784
|
+
...params
|
|
16785
|
+
});
|
|
16786
|
+
/**
|
|
16787
|
+
* No description
|
|
16788
|
+
*
|
|
16789
|
+
* @tags vocabulary
|
|
16790
|
+
* @name GetMigrationPlan
|
|
16791
|
+
* @summary `GET /api/v1/vocabulary/migration/plans/{plan_id}` — a plan.
|
|
16792
|
+
* @request GET:/api/v1/vocabulary/migration/plans/{plan_id}
|
|
16793
|
+
* @secure
|
|
16794
|
+
*/
|
|
16795
|
+
getMigrationPlan = (planId, params = {}) => this.http.request({
|
|
16796
|
+
path: `/api/v1/vocabulary/migration/plans/${planId}`,
|
|
16797
|
+
method: "GET",
|
|
16798
|
+
secure: true,
|
|
16799
|
+
format: "json",
|
|
16800
|
+
...params
|
|
16801
|
+
});
|
|
16501
16802
|
/**
|
|
16502
16803
|
* No description
|
|
16503
16804
|
*
|
|
@@ -16530,6 +16831,40 @@ var Vocabulary = class {
|
|
|
16530
16831
|
format: "json",
|
|
16531
16832
|
...params
|
|
16532
16833
|
});
|
|
16834
|
+
/**
|
|
16835
|
+
* No description
|
|
16836
|
+
*
|
|
16837
|
+
* @tags vocabulary
|
|
16838
|
+
* @name GetVocabularyCollection
|
|
16839
|
+
* @summary `GET /api/v1/vocabulary/collections/{collection_id}` — one collection with its labels, its member occurrences, its nested collections and its documentation notes.
|
|
16840
|
+
* @request GET:/api/v1/vocabulary/collections/{collection_id}
|
|
16841
|
+
* @secure
|
|
16842
|
+
*/
|
|
16843
|
+
getVocabularyCollection = (collectionId, query, params = {}) => this.http.request({
|
|
16844
|
+
path: `/api/v1/vocabulary/collections/${collectionId}`,
|
|
16845
|
+
method: "GET",
|
|
16846
|
+
query,
|
|
16847
|
+
secure: true,
|
|
16848
|
+
format: "json",
|
|
16849
|
+
...params
|
|
16850
|
+
});
|
|
16851
|
+
/**
|
|
16852
|
+
* No description
|
|
16853
|
+
*
|
|
16854
|
+
* @tags vocabulary
|
|
16855
|
+
* @name ImportItems
|
|
16856
|
+
* @summary `GET /api/v1/vocabulary/imports/{import_id}/items` — the items of an import by ordinal, each with its coordinates, disposition, reason and target.
|
|
16857
|
+
* @request GET:/api/v1/vocabulary/imports/{import_id}/items
|
|
16858
|
+
* @secure
|
|
16859
|
+
*/
|
|
16860
|
+
importItems = (importId, query, params = {}) => this.http.request({
|
|
16861
|
+
path: `/api/v1/vocabulary/imports/${importId}/items`,
|
|
16862
|
+
method: "GET",
|
|
16863
|
+
query,
|
|
16864
|
+
secure: true,
|
|
16865
|
+
format: "json",
|
|
16866
|
+
...params
|
|
16867
|
+
});
|
|
16533
16868
|
/**
|
|
16534
16869
|
* No description
|
|
16535
16870
|
*
|
|
@@ -16604,7 +16939,7 @@ var Vocabulary = class {
|
|
|
16604
16939
|
*
|
|
16605
16940
|
* @tags vocabulary
|
|
16606
16941
|
* @name ListSchemes
|
|
16607
|
-
* @summary `GET /api/v1/vocabulary/schemes` — the schemes of a view.
|
|
16942
|
+
* @summary `GET /api/v1/vocabulary/schemes` — the schemes of a view, each with its languages and its documentation notes.
|
|
16608
16943
|
* @request GET:/api/v1/vocabulary/schemes
|
|
16609
16944
|
* @secure
|
|
16610
16945
|
*/
|
|
@@ -16616,6 +16951,23 @@ var Vocabulary = class {
|
|
|
16616
16951
|
format: "json",
|
|
16617
16952
|
...params
|
|
16618
16953
|
});
|
|
16954
|
+
/**
|
|
16955
|
+
* No description
|
|
16956
|
+
*
|
|
16957
|
+
* @tags vocabulary
|
|
16958
|
+
* @name ListVocabularyCollections
|
|
16959
|
+
* @summary `GET /api/v1/vocabulary/collections` — the collections of one scheme.
|
|
16960
|
+
* @request GET:/api/v1/vocabulary/collections
|
|
16961
|
+
* @secure
|
|
16962
|
+
*/
|
|
16963
|
+
listVocabularyCollections = (query, params = {}) => this.http.request({
|
|
16964
|
+
path: `/api/v1/vocabulary/collections`,
|
|
16965
|
+
method: "GET",
|
|
16966
|
+
query,
|
|
16967
|
+
secure: true,
|
|
16968
|
+
format: "json",
|
|
16969
|
+
...params
|
|
16970
|
+
});
|
|
16619
16971
|
/**
|
|
16620
16972
|
* No description
|
|
16621
16973
|
*
|
|
@@ -16772,6 +17124,91 @@ var Vocabulary = class {
|
|
|
16772
17124
|
format: "json",
|
|
16773
17125
|
...params
|
|
16774
17126
|
});
|
|
17127
|
+
/**
|
|
17128
|
+
* No description
|
|
17129
|
+
*
|
|
17130
|
+
* @tags vocabulary
|
|
17131
|
+
* @name SchemeHierarchy
|
|
17132
|
+
* @summary `GET /api/v1/vocabulary/schemes/{scheme_id}/hierarchy` — the `broader` links of one scheme around a concept, or below its top concepts.
|
|
17133
|
+
* @request GET:/api/v1/vocabulary/schemes/{scheme_id}/hierarchy
|
|
17134
|
+
* @secure
|
|
17135
|
+
*/
|
|
17136
|
+
schemeHierarchy = (schemeId, query, params = {}) => this.http.request({
|
|
17137
|
+
path: `/api/v1/vocabulary/schemes/${schemeId}/hierarchy`,
|
|
17138
|
+
method: "GET",
|
|
17139
|
+
query,
|
|
17140
|
+
secure: true,
|
|
17141
|
+
format: "json",
|
|
17142
|
+
...params
|
|
17143
|
+
});
|
|
17144
|
+
/**
|
|
17145
|
+
* No description
|
|
17146
|
+
*
|
|
17147
|
+
* @tags vocabulary
|
|
17148
|
+
* @name SchemePaths
|
|
17149
|
+
* @summary `GET /api/v1/vocabulary/schemes/{scheme_id}/paths` — the simple paths of accepted `broader` links from a narrower concept up to a broader one.
|
|
17150
|
+
* @request GET:/api/v1/vocabulary/schemes/{scheme_id}/paths
|
|
17151
|
+
* @secure
|
|
17152
|
+
*/
|
|
17153
|
+
schemePaths = (schemeId, query, params = {}) => this.http.request({
|
|
17154
|
+
path: `/api/v1/vocabulary/schemes/${schemeId}/paths`,
|
|
17155
|
+
method: "GET",
|
|
17156
|
+
query,
|
|
17157
|
+
secure: true,
|
|
17158
|
+
format: "json",
|
|
17159
|
+
...params
|
|
17160
|
+
});
|
|
17161
|
+
/**
|
|
17162
|
+
* No description
|
|
17163
|
+
*
|
|
17164
|
+
* @tags vocabulary
|
|
17165
|
+
* @name SchemePicklist
|
|
17166
|
+
* @summary `GET /api/v1/vocabulary/schemes/{scheme_id}/picklist` — the scheme's concepts depth first, for a form control.
|
|
17167
|
+
* @request GET:/api/v1/vocabulary/schemes/{scheme_id}/picklist
|
|
17168
|
+
* @secure
|
|
17169
|
+
*/
|
|
17170
|
+
schemePicklist = (schemeId, query, params = {}) => this.http.request({
|
|
17171
|
+
path: `/api/v1/vocabulary/schemes/${schemeId}/picklist`,
|
|
17172
|
+
method: "GET",
|
|
17173
|
+
query,
|
|
17174
|
+
secure: true,
|
|
17175
|
+
format: "json",
|
|
17176
|
+
...params
|
|
17177
|
+
});
|
|
17178
|
+
/**
|
|
17179
|
+
* No description
|
|
17180
|
+
*
|
|
17181
|
+
* @tags vocabulary
|
|
17182
|
+
* @name SchemePolicy
|
|
17183
|
+
* @summary `GET /api/v1/vocabulary/schemes/{scheme_id}/policy` — the scheme's taxonomy policy, or the `taxonomy-policy/v1` defaults (#611 P3-D04) with `declared: false`.
|
|
17184
|
+
* @request GET:/api/v1/vocabulary/schemes/{scheme_id}/policy
|
|
17185
|
+
* @secure
|
|
17186
|
+
*/
|
|
17187
|
+
schemePolicy = (schemeId, query, params = {}) => this.http.request({
|
|
17188
|
+
path: `/api/v1/vocabulary/schemes/${schemeId}/policy`,
|
|
17189
|
+
method: "GET",
|
|
17190
|
+
query,
|
|
17191
|
+
secure: true,
|
|
17192
|
+
format: "json",
|
|
17193
|
+
...params
|
|
17194
|
+
});
|
|
17195
|
+
/**
|
|
17196
|
+
* No description
|
|
17197
|
+
*
|
|
17198
|
+
* @tags vocabulary
|
|
17199
|
+
* @name SchemeTopConcepts
|
|
17200
|
+
* @summary `GET /api/v1/vocabulary/schemes/{scheme_id}/top-concepts` — the concepts with an accepted membership in the scheme marked `top_concept`.
|
|
17201
|
+
* @request GET:/api/v1/vocabulary/schemes/{scheme_id}/top-concepts
|
|
17202
|
+
* @secure
|
|
17203
|
+
*/
|
|
17204
|
+
schemeTopConcepts = (schemeId, query, params = {}) => this.http.request({
|
|
17205
|
+
path: `/api/v1/vocabulary/schemes/${schemeId}/top-concepts`,
|
|
17206
|
+
method: "GET",
|
|
17207
|
+
query,
|
|
17208
|
+
secure: true,
|
|
17209
|
+
format: "json",
|
|
17210
|
+
...params
|
|
17211
|
+
});
|
|
16775
17212
|
/**
|
|
16776
17213
|
* No description
|
|
16777
17214
|
*
|
|
@@ -16789,6 +17226,24 @@ var Vocabulary = class {
|
|
|
16789
17226
|
format: "json",
|
|
16790
17227
|
...params
|
|
16791
17228
|
});
|
|
17229
|
+
/**
|
|
17230
|
+
* No description
|
|
17231
|
+
*
|
|
17232
|
+
* @tags vocabulary
|
|
17233
|
+
* @name SparqlQuery
|
|
17234
|
+
* @summary `POST /api/v1/vocabulary/sparql` — one read-only SPARQL query over the SKOS projection of one scheme of one view.
|
|
17235
|
+
* @request POST:/api/v1/vocabulary/sparql
|
|
17236
|
+
* @secure
|
|
17237
|
+
*/
|
|
17238
|
+
sparqlQuery = (data, params = {}) => this.http.request({
|
|
17239
|
+
path: `/api/v1/vocabulary/sparql`,
|
|
17240
|
+
method: "POST",
|
|
17241
|
+
body: data,
|
|
17242
|
+
secure: true,
|
|
17243
|
+
type: "application/json",
|
|
17244
|
+
format: "json",
|
|
17245
|
+
...params
|
|
17246
|
+
});
|
|
16792
17247
|
/**
|
|
16793
17248
|
* No description
|
|
16794
17249
|
*
|
|
@@ -17574,7 +18029,8 @@ function SortListResponseFromApiToFront(dto) {
|
|
|
17574
18029
|
sorts: dto.sorts.map(SortDtoFromApiToFront),
|
|
17575
18030
|
count: dto.count,
|
|
17576
18031
|
total: dto.total,
|
|
17577
|
-
offset: dto.offset
|
|
18032
|
+
offset: dto.offset,
|
|
18033
|
+
ontologyRevision: dto.ontology_revision
|
|
17578
18034
|
};
|
|
17579
18035
|
}
|
|
17580
18036
|
function ListSortsQueryFromFrontToApi(query) {
|
|
@@ -17921,27 +18377,150 @@ function DeprecateSortRequestFromFrontToApi(model) {
|
|
|
17921
18377
|
if (model.replacement !== void 0) out.replacement = model.replacement;
|
|
17922
18378
|
return out;
|
|
17923
18379
|
}
|
|
18380
|
+
function FactorLimitsFromFrontToApi(model) {
|
|
18381
|
+
const out = {};
|
|
18382
|
+
if (model.maxSorts !== void 0) out.max_sorts = model.maxSorts;
|
|
18383
|
+
if (model.maxContextSorts !== void 0) out.max_context_sorts = model.maxContextSorts;
|
|
18384
|
+
if (model.maxParentEdges !== void 0) out.max_parent_edges = model.maxParentEdges;
|
|
18385
|
+
if (model.maxDeclarations !== void 0) out.max_declarations = model.maxDeclarations;
|
|
18386
|
+
if (model.maxAttributes !== void 0) out.max_attributes = model.maxAttributes;
|
|
18387
|
+
if (model.maxInputBytes !== void 0) out.max_input_bytes = model.maxInputBytes;
|
|
18388
|
+
if (model.maxConcepts !== void 0) out.max_concepts = model.maxConcepts;
|
|
18389
|
+
if (model.maxVisitedConcepts !== void 0) out.max_visited_concepts = model.maxVisitedConcepts;
|
|
18390
|
+
if (model.maxWork !== void 0) out.max_work = model.maxWork;
|
|
18391
|
+
if (model.maxProposals !== void 0) out.max_proposals = model.maxProposals;
|
|
18392
|
+
if (model.maxOutputBytes !== void 0) out.max_output_bytes = model.maxOutputBytes;
|
|
18393
|
+
return out;
|
|
18394
|
+
}
|
|
17924
18395
|
function FactorSortsRequestFromFrontToApi(model) {
|
|
17925
18396
|
const out = {};
|
|
17926
18397
|
if (model.sortIds !== void 0) out.sort_ids = model.sortIds;
|
|
17927
18398
|
if (model.minSorts !== void 0) out.min_sorts = model.minSorts;
|
|
18399
|
+
if (model.limits !== void 0) {
|
|
18400
|
+
out.limits = model.limits === null ? null : FactorLimitsFromFrontToApi(model.limits);
|
|
18401
|
+
}
|
|
17928
18402
|
return out;
|
|
17929
18403
|
}
|
|
17930
|
-
function
|
|
17931
|
-
const out = {
|
|
17932
|
-
if (dto.
|
|
17933
|
-
if (dto.
|
|
17934
|
-
if (dto.
|
|
18404
|
+
function FactorLimitsFromApiToFront(dto) {
|
|
18405
|
+
const out = {};
|
|
18406
|
+
if (dto.max_sorts != null) out.maxSorts = dto.max_sorts;
|
|
18407
|
+
if (dto.max_context_sorts != null) out.maxContextSorts = dto.max_context_sorts;
|
|
18408
|
+
if (dto.max_parent_edges != null) out.maxParentEdges = dto.max_parent_edges;
|
|
18409
|
+
if (dto.max_declarations != null) out.maxDeclarations = dto.max_declarations;
|
|
18410
|
+
if (dto.max_attributes != null) out.maxAttributes = dto.max_attributes;
|
|
18411
|
+
if (dto.max_input_bytes != null) out.maxInputBytes = dto.max_input_bytes;
|
|
18412
|
+
if (dto.max_concepts != null) out.maxConcepts = dto.max_concepts;
|
|
18413
|
+
if (dto.max_visited_concepts != null) out.maxVisitedConcepts = dto.max_visited_concepts;
|
|
18414
|
+
if (dto.max_work != null) out.maxWork = dto.max_work;
|
|
18415
|
+
if (dto.max_proposals != null) out.maxProposals = dto.max_proposals;
|
|
18416
|
+
if (dto.max_output_bytes != null) out.maxOutputBytes = dto.max_output_bytes;
|
|
17935
18417
|
return out;
|
|
17936
18418
|
}
|
|
17937
|
-
function
|
|
18419
|
+
function FactorSharedFeatureFromApiToFront(dto) {
|
|
17938
18420
|
return {
|
|
18421
|
+
...FeatureDescriptorDtoFromApiToFront(dto),
|
|
18422
|
+
signature: dto.signature,
|
|
18423
|
+
declaredBy: dto.declared_by
|
|
18424
|
+
};
|
|
18425
|
+
}
|
|
18426
|
+
function isJsonValue2(value) {
|
|
18427
|
+
return typeof value === "string" || typeof value === "number" || typeof value === "boolean" || typeof value === "object";
|
|
18428
|
+
}
|
|
18429
|
+
function isFactorRecord(value) {
|
|
18430
|
+
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
18431
|
+
}
|
|
18432
|
+
function factorStringList(value, field) {
|
|
18433
|
+
if (!Array.isArray(value)) throw new TypeError(`factor context: ${field} is not an array`);
|
|
18434
|
+
const items = value;
|
|
18435
|
+
return items.map((item) => {
|
|
18436
|
+
if (typeof item !== "string")
|
|
18437
|
+
throw new TypeError(`factor context: ${field} holds a non-string`);
|
|
18438
|
+
return item;
|
|
18439
|
+
});
|
|
18440
|
+
}
|
|
18441
|
+
function factorNumberList(value, field) {
|
|
18442
|
+
if (!Array.isArray(value)) throw new TypeError(`factor context: ${field} is not an array`);
|
|
18443
|
+
const items = value;
|
|
18444
|
+
return items.map((item) => {
|
|
18445
|
+
if (typeof item !== "number")
|
|
18446
|
+
throw new TypeError(`factor context: ${field} holds a non-number`);
|
|
18447
|
+
return item;
|
|
18448
|
+
});
|
|
18449
|
+
}
|
|
18450
|
+
function factorString(record, key, field) {
|
|
18451
|
+
const value = Reflect.get(record, key);
|
|
18452
|
+
if (typeof value !== "string")
|
|
18453
|
+
throw new TypeError(`factor context: ${field}.${key} is not a string`);
|
|
18454
|
+
return value;
|
|
18455
|
+
}
|
|
18456
|
+
function FactorContextFromApiToFront(value) {
|
|
18457
|
+
if (!isFactorRecord(value)) throw new TypeError("factor context is not an object");
|
|
18458
|
+
const sorts = Reflect.get(value, "sorts");
|
|
18459
|
+
if (!Array.isArray(sorts)) throw new TypeError("factor context: sorts is not an array");
|
|
18460
|
+
const snapshot = Reflect.get(value, "incidence");
|
|
18461
|
+
if (!isFactorRecord(snapshot)) throw new TypeError("factor context: incidence is not an object");
|
|
18462
|
+
const version = Reflect.get(snapshot, "version");
|
|
18463
|
+
if (typeof version !== "number") {
|
|
18464
|
+
throw new TypeError("factor context: incidence.version is not a number");
|
|
18465
|
+
}
|
|
18466
|
+
const rows = Reflect.get(snapshot, "incidence");
|
|
18467
|
+
if (!Array.isArray(rows))
|
|
18468
|
+
throw new TypeError("factor context: incidence.incidence is not an array");
|
|
18469
|
+
const rowList = rows;
|
|
18470
|
+
const sortList = sorts;
|
|
18471
|
+
return {
|
|
18472
|
+
version: factorString(value, "version", "context"),
|
|
18473
|
+
tenant: factorString(value, "tenant", "context"),
|
|
18474
|
+
policySha256: factorString(value, "policy_sha256", "context"),
|
|
18475
|
+
sorts: sortList.map((sort) => {
|
|
18476
|
+
if (!isJsonValue2(sort)) throw new TypeError("factor context: sorts holds a non-JSON value");
|
|
18477
|
+
return sort;
|
|
18478
|
+
}),
|
|
18479
|
+
incidence: {
|
|
18480
|
+
version,
|
|
18481
|
+
objects: factorStringList(Reflect.get(snapshot, "objects"), "incidence.objects"),
|
|
18482
|
+
attributes: factorStringList(Reflect.get(snapshot, "attributes"), "incidence.attributes"),
|
|
18483
|
+
incidence: rowList.map((row) => factorNumberList(row, "incidence.incidence"))
|
|
18484
|
+
}
|
|
18485
|
+
};
|
|
18486
|
+
}
|
|
18487
|
+
function FactorSortsResponseFromApiToFront(dto) {
|
|
18488
|
+
const out = {
|
|
18489
|
+
version: dto.version,
|
|
17939
18490
|
proposals: dto.proposals.map((p) => ({
|
|
17940
18491
|
memberSorts: p.member_sorts.map((m) => ({ id: m.id, name: m.name })),
|
|
17941
18492
|
sharedFeatures: p.shared_features.map(FactorSharedFeatureFromApiToFront),
|
|
17942
|
-
suggestedName: p.suggested_name
|
|
17943
|
-
|
|
18493
|
+
suggestedName: p.suggested_name,
|
|
18494
|
+
extent: p.extent,
|
|
18495
|
+
intent: p.intent
|
|
18496
|
+
})),
|
|
18497
|
+
inputComplete: dto.input_complete,
|
|
18498
|
+
limits: FactorLimitsFromApiToFront(dto.limits),
|
|
18499
|
+
minSorts: dto.min_sorts,
|
|
18500
|
+
nativeAdmission: dto.native_admission
|
|
17944
18501
|
};
|
|
18502
|
+
if (dto.input_stop != null) {
|
|
18503
|
+
out.inputStop = {
|
|
18504
|
+
reason: dto.input_stop.reason,
|
|
18505
|
+
resource: dto.input_stop.resource,
|
|
18506
|
+
limit: dto.input_stop.limit
|
|
18507
|
+
};
|
|
18508
|
+
}
|
|
18509
|
+
if (dto.search != null) {
|
|
18510
|
+
out.search = {
|
|
18511
|
+
complete: dto.search.complete,
|
|
18512
|
+
stopReason: dto.search.stop_reason,
|
|
18513
|
+
visitedConcepts: dto.search.visited_concepts,
|
|
18514
|
+
work: dto.search.work,
|
|
18515
|
+
emittedConcepts: dto.search.emitted_concepts
|
|
18516
|
+
};
|
|
18517
|
+
}
|
|
18518
|
+
if (dto.presentation_stop_reason != null) {
|
|
18519
|
+
out.presentationStopReason = dto.presentation_stop_reason;
|
|
18520
|
+
}
|
|
18521
|
+
if (dto.context_sha256 != null) out.contextSha256 = dto.context_sha256;
|
|
18522
|
+
if (dto.context != null) out.context = FactorContextFromApiToFront(dto.context);
|
|
18523
|
+
return out;
|
|
17945
18524
|
}
|
|
17946
18525
|
function PatchSortRequestFromFrontToApi(model) {
|
|
17947
18526
|
const out = {};
|
|
@@ -18732,6 +19311,9 @@ var RESPONSE_COMPONENTS = {
|
|
|
18732
19311
|
},
|
|
18733
19312
|
BaselineDto: { object: { snapshot_hash: [1, 0], stale: [1, 0] } },
|
|
18734
19313
|
BatchCopyResponse: { object: { copies: [1, { array: "CopyResultDto" }] } },
|
|
19314
|
+
BatchGetSubsumptionsResponse: {
|
|
19315
|
+
object: { degrees: [1, { array: "GetFuzzySubsumptionResponse" }] }
|
|
19316
|
+
},
|
|
18735
19317
|
BatchOperationResultDto: { object: { duration_ms: [1, 0], index: [1, 0], success: [1, 0] } },
|
|
18736
19318
|
BatchResponse: {
|
|
18737
19319
|
object: {
|
|
@@ -18925,7 +19507,11 @@ var RESPONSE_COMPONENTS = {
|
|
|
18925
19507
|
},
|
|
18926
19508
|
BulkRowRefusalDto: { object: { index: [1, 0], message: [1, 0] } },
|
|
18927
19509
|
BulkSetSimilaritiesResponse: { object: { errors: [0, { array: 0 }], set_count: [1, 0] } },
|
|
19510
|
+
BulkSetSubsumptionsResponse: {
|
|
19511
|
+
object: { outcomes: [1, { array: "BulkSubsumptionOutcome" }], set_count: [1, 0] }
|
|
19512
|
+
},
|
|
18928
19513
|
BulkSortError: { object: { error: [1, 0], kind: [1, 0], name: [1, 0], sort_created: [1, 0] } },
|
|
19514
|
+
BulkSubsumptionOutcome: { object: { sub_sort_id: [1, 0], sup_sort_id: [1, 0], written: [1, 0] } },
|
|
18929
19515
|
BundleBelief: {
|
|
18930
19516
|
object: { confidence: [1, 0], features: [0, { object: {} }], sort: [1, 0], source: [1, 0] }
|
|
18931
19517
|
},
|
|
@@ -19481,6 +20067,17 @@ var RESPONSE_COMPONENTS = {
|
|
|
19481
20067
|
verdicts: [1, { array: 0 }]
|
|
19482
20068
|
}
|
|
19483
20069
|
},
|
|
20070
|
+
CollectionDetailResponse: {
|
|
20071
|
+
object: {
|
|
20072
|
+
collection: [1, "CollectionRecordDto"],
|
|
20073
|
+
context: [2, "ContextRefDto"],
|
|
20074
|
+
documentation: [1, { array: "DocumentationRecordDto" }],
|
|
20075
|
+
labels: [1, { array: "CollectionLabelViewDto" }],
|
|
20076
|
+
members: [1, { array: "CollectionMemberViewDto" }],
|
|
20077
|
+
nested_collections: [1, { array: 0 }],
|
|
20078
|
+
view: [1, "ViewRefDto"]
|
|
20079
|
+
}
|
|
20080
|
+
},
|
|
19484
20081
|
CollectionDto: {
|
|
19485
20082
|
object: {
|
|
19486
20083
|
depth: [1, 0],
|
|
@@ -19490,10 +20087,42 @@ var RESPONSE_COMPONENTS = {
|
|
|
19490
20087
|
tags: [1, { array: 0 }]
|
|
19491
20088
|
}
|
|
19492
20089
|
},
|
|
20090
|
+
CollectionLabelViewDto: {
|
|
20091
|
+
object: { collection_label_id: [1, 0], label_id: [1, 0], role: [1, 0] }
|
|
20092
|
+
},
|
|
19493
20093
|
CollectionListResponse: {
|
|
19494
20094
|
object: { collections: [1, { array: "CollectionDto" }], count: [1, 0] }
|
|
19495
20095
|
},
|
|
20096
|
+
CollectionMemberViewDto: {
|
|
20097
|
+
object: { display_label: [2, "DisplayLabelDto"], occurrence_id: [1, 0] }
|
|
20098
|
+
},
|
|
20099
|
+
CollectionPageResponse: {
|
|
20100
|
+
object: {
|
|
20101
|
+
complete: [1, 0],
|
|
20102
|
+
context: [2, "ContextRefDto"],
|
|
20103
|
+
items: [1, { array: "CollectionSummaryDto" }],
|
|
20104
|
+
scheme_id: [1, 0],
|
|
20105
|
+
view: [1, "ViewRefDto"]
|
|
20106
|
+
}
|
|
20107
|
+
},
|
|
20108
|
+
CollectionRecordDto: {
|
|
20109
|
+
object: {
|
|
20110
|
+
change_reason: [1, 0],
|
|
20111
|
+
ordered: [1, 0],
|
|
20112
|
+
record_id: [1, 0],
|
|
20113
|
+
revision: [1, 0],
|
|
20114
|
+
scheme: [1, 0],
|
|
20115
|
+
status: [1, 0]
|
|
20116
|
+
}
|
|
20117
|
+
},
|
|
19496
20118
|
CollectionResponse: { object: { collection: [1, "CollectionDto"] } },
|
|
20119
|
+
CollectionSummaryDto: {
|
|
20120
|
+
object: {
|
|
20121
|
+
collection: [1, "CollectionRecordDto"],
|
|
20122
|
+
labels: [1, { array: "CollectionLabelViewDto" }],
|
|
20123
|
+
member_count: [1, 0]
|
|
20124
|
+
}
|
|
20125
|
+
},
|
|
19497
20126
|
CommunitiesResponseDto: {
|
|
19498
20127
|
object: {
|
|
19499
20128
|
communities: [1, { array: 0 }],
|
|
@@ -19635,6 +20264,18 @@ var RESPONSE_COMPONENTS = {
|
|
|
19635
20264
|
term_versions: [1, { array: "TermVersionEntryDto" }]
|
|
19636
20265
|
}
|
|
19637
20266
|
},
|
|
20267
|
+
ConceptMappingViewDto: {
|
|
20268
|
+
object: {
|
|
20269
|
+
change_reason: [1, 0],
|
|
20270
|
+
mapping_kind: [1, 0],
|
|
20271
|
+
record_id: [1, 0],
|
|
20272
|
+
revision: [1, 0],
|
|
20273
|
+
status: [1, 0],
|
|
20274
|
+
subject: [1, 0],
|
|
20275
|
+
target_display_label: [2, "DisplayLabelDto"],
|
|
20276
|
+
target_external_concept: [2, "ExternalConceptRecordDto"]
|
|
20277
|
+
}
|
|
20278
|
+
},
|
|
19638
20279
|
ConceptMatchDto: {
|
|
19639
20280
|
object: {
|
|
19640
20281
|
canonical_name: [1, 0],
|
|
@@ -19657,6 +20298,37 @@ var RESPONSE_COMPONENTS = {
|
|
|
19657
20298
|
ConceptRecordDto: {
|
|
19658
20299
|
object: { change_reason: [1, 0], record_id: [1, 0], revision: [1, 0], status: [1, 0] }
|
|
19659
20300
|
},
|
|
20301
|
+
ConceptRelationEntryDto: {
|
|
20302
|
+
object: {
|
|
20303
|
+
concept_id: [1, 0],
|
|
20304
|
+
display_label: [2, "DisplayLabelDto"],
|
|
20305
|
+
relation: [1, 0],
|
|
20306
|
+
relation_id: [1, 0],
|
|
20307
|
+
status: [1, 0]
|
|
20308
|
+
}
|
|
20309
|
+
},
|
|
20310
|
+
ConceptRelationRecordDto: {
|
|
20311
|
+
object: {
|
|
20312
|
+
change_reason: [1, 0],
|
|
20313
|
+
object: [1, 0],
|
|
20314
|
+
record_id: [1, 0],
|
|
20315
|
+
relation: [1, 0],
|
|
20316
|
+
revision: [1, 0],
|
|
20317
|
+
scheme: [1, 0],
|
|
20318
|
+
status: [1, 0],
|
|
20319
|
+
subject: [1, 0]
|
|
20320
|
+
}
|
|
20321
|
+
},
|
|
20322
|
+
ConceptRelationsResponse: {
|
|
20323
|
+
object: {
|
|
20324
|
+
concept_id: [1, 0],
|
|
20325
|
+
context: [2, "ContextRefDto"],
|
|
20326
|
+
relation: [1, 0],
|
|
20327
|
+
relations: [1, { array: "ConceptRelationEntryDto" }],
|
|
20328
|
+
scheme_id: [1, 0],
|
|
20329
|
+
view: [1, "ViewRefDto"]
|
|
20330
|
+
}
|
|
20331
|
+
},
|
|
19660
20332
|
ConceptReleaseDto: {
|
|
19661
20333
|
object: { record_etag: [1, 0], release_id: [1, 0], release_number: [1, 0] }
|
|
19662
20334
|
},
|
|
@@ -19707,14 +20379,21 @@ var RESPONSE_COMPONENTS = {
|
|
|
19707
20379
|
object: {
|
|
19708
20380
|
aboutness: [1, { array: "AboutnessRecordDto" }],
|
|
19709
20381
|
authority_references: [1, { array: "AuthorityReferenceRecordDto" }],
|
|
20382
|
+
collections: [1, { array: 0 }],
|
|
19710
20383
|
concept: [1, "ConceptRecordDto"],
|
|
19711
20384
|
definition_guidance: [1, "DefinitionGuidanceDto"],
|
|
19712
20385
|
definitions: [1, { array: "DefinitionRecordDto" }],
|
|
19713
20386
|
display_label: [2, "DisplayLabelDto"],
|
|
20387
|
+
documentation: [1, { array: "DocumentationRecordDto" }],
|
|
19714
20388
|
evidence: [1, { array: "EvidenceViewDto" }],
|
|
19715
20389
|
identity_decisions: [1, { array: "IdentityDecisionRecordDto" }],
|
|
19716
20390
|
labels: [1, { array: "LabelUseViewDto" }],
|
|
19717
|
-
|
|
20391
|
+
mappings: [1, { array: "ConceptMappingViewDto" }],
|
|
20392
|
+
memberships: [1, { array: "MembershipViewDto" }],
|
|
20393
|
+
notations: [1, { array: "NotationRecordDto" }],
|
|
20394
|
+
relations: [1, { array: "ConceptRelationRecordDto" }],
|
|
20395
|
+
source_associations: [1, { array: "SourceAssociationRecordDto" }],
|
|
20396
|
+
xl_labels: [1, { array: "XlLabelViewDto" }]
|
|
19718
20397
|
}
|
|
19719
20398
|
},
|
|
19720
20399
|
ConditionalIndependenceResponse: { object: { explanation: [1, 0], independent: [1, 0] } },
|
|
@@ -20090,6 +20769,19 @@ var RESPONSE_COMPONENTS = {
|
|
|
20090
20769
|
CronJobRunDto: { object: { origin: [1, 0], run_id: [1, 0], started_at: [1, 0], status: [1, 0] } },
|
|
20091
20770
|
CronScheduleDto: { object: { schedule_type: [1, 0], value: [1, 0] } },
|
|
20092
20771
|
CrossCuttingResponseDto: { object: { items: [1, { array: 0 }], scope_truncated: [1, 0] } },
|
|
20772
|
+
CspSolveResponse: {
|
|
20773
|
+
object: {
|
|
20774
|
+
backtracks: [1, 0],
|
|
20775
|
+
nodes_explored: [1, 0],
|
|
20776
|
+
propagations: [1, 0],
|
|
20777
|
+
propagator_invocations: [1, 0],
|
|
20778
|
+
satisfiable: [1, 0],
|
|
20779
|
+
search_exhausted: [1, 0],
|
|
20780
|
+
solutions: [1, { array: { object: {} } }],
|
|
20781
|
+
solve_time_ms: [1, 0],
|
|
20782
|
+
total_found: [1, 0]
|
|
20783
|
+
}
|
|
20784
|
+
},
|
|
20093
20785
|
CuriosityTargetDto: {
|
|
20094
20786
|
object: { exploration_priority: [1, 0], novelty: [1, 0], target_id: [1, 0] }
|
|
20095
20787
|
},
|
|
@@ -20132,6 +20824,7 @@ var RESPONSE_COMPONENTS = {
|
|
|
20132
20824
|
object: {
|
|
20133
20825
|
actions_executed: [1, { array: 0 }],
|
|
20134
20826
|
goals_achieved: [1, { array: 0 }],
|
|
20827
|
+
goals_deferred: [0, { array: 0 }],
|
|
20135
20828
|
goals_failed: [1, { array: 0 }],
|
|
20136
20829
|
goals_pursued: [1, { array: 0 }],
|
|
20137
20830
|
new_beliefs: [1, { array: 0 }],
|
|
@@ -20216,6 +20909,15 @@ var RESPONSE_COMPONENTS = {
|
|
|
20216
20909
|
}
|
|
20217
20910
|
},
|
|
20218
20911
|
DeclareLatentVariableResponse: { object: { declared: [1, 0], variable: [1, 0] } },
|
|
20912
|
+
DeclaredAlphaCutMember: { object: { degree: [1, 0], sort_id: [1, 0] } },
|
|
20913
|
+
DeclaredAlphaCutResponse: {
|
|
20914
|
+
object: {
|
|
20915
|
+
alpha: [1, 0],
|
|
20916
|
+
concept_sort_id: [1, 0],
|
|
20917
|
+
members: [1, { array: "DeclaredAlphaCutMember" }],
|
|
20918
|
+
strict: [1, 0]
|
|
20919
|
+
}
|
|
20920
|
+
},
|
|
20219
20921
|
DeclaredEgress: { object: { host: [1, 0], purpose: [1, 0] } },
|
|
20220
20922
|
DecodeGlbResponse: {
|
|
20221
20923
|
object: {
|
|
@@ -20782,6 +21484,9 @@ var RESPONSE_COMPONENTS = {
|
|
|
20782
21484
|
DocumentVersionsResponse: {
|
|
20783
21485
|
object: { family_id: [1, 0], versions: [1, { array: "DocumentDto" }] }
|
|
20784
21486
|
},
|
|
21487
|
+
DocumentationRecordDto: {
|
|
21488
|
+
object: { change_reason: [1, 0], note_kind: [1, 0], record_id: [1, 0], revision: [1, 0] }
|
|
21489
|
+
},
|
|
20785
21490
|
DonorWeightDto: { object: { name: [1, 0], weight: [1, 0] } },
|
|
20786
21491
|
DoseResponseResponse: {
|
|
20787
21492
|
object: {
|
|
@@ -21128,6 +21833,30 @@ var RESPONSE_COMPONENTS = {
|
|
|
21128
21833
|
ExecutionSessionStatsResponse: {
|
|
21129
21834
|
object: { curried_function_count: [1, 0], db_available: [1, 0], memory_session_count: [1, 0] }
|
|
21130
21835
|
},
|
|
21836
|
+
ExpandedConceptDto: {
|
|
21837
|
+
object: {
|
|
21838
|
+
concept_id: [1, 0],
|
|
21839
|
+
display_label: [2, "DisplayLabelDto"],
|
|
21840
|
+
support: [1, { array: 0 }]
|
|
21841
|
+
}
|
|
21842
|
+
},
|
|
21843
|
+
ExpandedExternalDto: {
|
|
21844
|
+
object: { external_concept_id: [1, 0], iri: [1, 0], support: [1, { array: 0 }] }
|
|
21845
|
+
},
|
|
21846
|
+
ExpansionResponse: {
|
|
21847
|
+
object: {
|
|
21848
|
+
complete: [1, 0],
|
|
21849
|
+
concept_id: [1, 0],
|
|
21850
|
+
concepts: [1, { array: "ExpandedConceptDto" }],
|
|
21851
|
+
context: [2, "ContextRefDto"],
|
|
21852
|
+
direction: [1, 0],
|
|
21853
|
+
external_concepts: [1, { array: "ExpandedExternalDto" }],
|
|
21854
|
+
scheme_id: [1, 0],
|
|
21855
|
+
transitive: [1, 0],
|
|
21856
|
+
view: [1, "ViewRefDto"],
|
|
21857
|
+
withheld_relation_ids: [1, { array: 0 }]
|
|
21858
|
+
}
|
|
21859
|
+
},
|
|
21131
21860
|
ExpireReviewsResponse: { object: { escalated: [1, { array: 0 }], timed_out: [1, { array: 0 }] } },
|
|
21132
21861
|
ExplorationCompleteResponseDto: {
|
|
21133
21862
|
object: {
|
|
@@ -21207,6 +21936,17 @@ var RESPONSE_COMPONENTS = {
|
|
|
21207
21936
|
webhook_url: [1, 0]
|
|
21208
21937
|
}
|
|
21209
21938
|
},
|
|
21939
|
+
ExternalConceptRecordDto: {
|
|
21940
|
+
object: {
|
|
21941
|
+
authority: [1, 0],
|
|
21942
|
+
change_reason: [1, 0],
|
|
21943
|
+
dataset_version: [1, 0],
|
|
21944
|
+
iri: [1, 0],
|
|
21945
|
+
record_id: [1, 0],
|
|
21946
|
+
resolution: [1, 0],
|
|
21947
|
+
revision: [1, 0]
|
|
21948
|
+
}
|
|
21949
|
+
},
|
|
21210
21950
|
ExternalMatchDto: { object: { match_type: [1, 0], ontology_id: [1, 0], source: [1, 0] } },
|
|
21211
21951
|
ExternalMatchProposalDto: {
|
|
21212
21952
|
object: {
|
|
@@ -21306,16 +22046,47 @@ var RESPONSE_COMPONENTS = {
|
|
|
21306
22046
|
present: [1, 0]
|
|
21307
22047
|
}
|
|
21308
22048
|
},
|
|
22049
|
+
FactorInputStopDto: { object: { reason: [1, 0] } },
|
|
22050
|
+
FactorLimitsDto: { object: {} },
|
|
21309
22051
|
FactorMemberSortDto: { object: { id: [1, 0], name: [1, 0] } },
|
|
21310
22052
|
FactorProposalDto: {
|
|
21311
22053
|
object: {
|
|
22054
|
+
extent: [1, { array: 0 }],
|
|
22055
|
+
intent: [1, { array: 0 }],
|
|
21312
22056
|
member_sorts: [1, { array: "FactorMemberSortDto" }],
|
|
21313
22057
|
shared_features: [1, { array: "FactorSharedFeatureDto" }],
|
|
21314
22058
|
suggested_name: [1, 0]
|
|
21315
22059
|
}
|
|
21316
22060
|
},
|
|
21317
|
-
|
|
21318
|
-
|
|
22061
|
+
FactorSearchDto: {
|
|
22062
|
+
object: {
|
|
22063
|
+
complete: [1, 0],
|
|
22064
|
+
emitted_concepts: [1, 0],
|
|
22065
|
+
stop_reason: [1, 0],
|
|
22066
|
+
visited_concepts: [1, 0],
|
|
22067
|
+
work: [1, 0]
|
|
22068
|
+
}
|
|
22069
|
+
},
|
|
22070
|
+
FactorSharedFeatureDto: {
|
|
22071
|
+
object: {
|
|
22072
|
+
annotations: [0, { object: {} }],
|
|
22073
|
+
name: [1, 0],
|
|
22074
|
+
declared_by: [1, { array: 0 }],
|
|
22075
|
+
signature: [1, 0]
|
|
22076
|
+
}
|
|
22077
|
+
},
|
|
22078
|
+
FactorSortsResponse: {
|
|
22079
|
+
object: {
|
|
22080
|
+
input_complete: [1, 0],
|
|
22081
|
+
input_stop: [2, "FactorInputStopDto"],
|
|
22082
|
+
limits: [1, "FactorLimitsDto"],
|
|
22083
|
+
min_sorts: [1, 0],
|
|
22084
|
+
native_admission: [1, 0],
|
|
22085
|
+
proposals: [1, { array: "FactorProposalDto" }],
|
|
22086
|
+
search: [2, "FactorSearchDto"],
|
|
22087
|
+
version: [1, 0]
|
|
22088
|
+
}
|
|
22089
|
+
},
|
|
21319
22090
|
FactoryResetResponse: {
|
|
21320
22091
|
object: {
|
|
21321
22092
|
cache_cleared: [1, 0],
|
|
@@ -21334,17 +22105,17 @@ var RESPONSE_COMPONENTS = {
|
|
|
21334
22105
|
object: {
|
|
21335
22106
|
complete: [1, 0],
|
|
21336
22107
|
implications: [1, { array: "FcaImplicationRecordDto" }],
|
|
21337
|
-
max_candidates: [
|
|
21338
|
-
max_work: [
|
|
22108
|
+
max_candidates: [3, 0],
|
|
22109
|
+
max_work: [3, 0]
|
|
21339
22110
|
}
|
|
21340
22111
|
},
|
|
21341
22112
|
FcaConceptClaimDto: {
|
|
21342
22113
|
object: {
|
|
21343
22114
|
complete: [1, 0],
|
|
21344
22115
|
concepts: [1, { array: "FcaConceptRecordDto" }],
|
|
21345
|
-
max_concepts: [
|
|
21346
|
-
max_visited_concepts: [
|
|
21347
|
-
max_work: [
|
|
22116
|
+
max_concepts: [3, 0],
|
|
22117
|
+
max_visited_concepts: [3, 0],
|
|
22118
|
+
max_work: [3, 0],
|
|
21348
22119
|
min_extent_size: [1, 0],
|
|
21349
22120
|
min_intent_size: [1, 0]
|
|
21350
22121
|
}
|
|
@@ -21917,6 +22688,40 @@ var RESPONSE_COMPONENTS = {
|
|
|
21917
22688
|
HiddenToolDto: {
|
|
21918
22689
|
object: { name: [1, 0], quality: [1, 0], reason: [1, 0], required_quality: [1, 0] }
|
|
21919
22690
|
},
|
|
22691
|
+
HierarchyEdgeDto: {
|
|
22692
|
+
object: { object: [1, 0], relation_id: [1, 0], status: [1, 0], subject: [1, 0] }
|
|
22693
|
+
},
|
|
22694
|
+
HierarchyNodeDto: {
|
|
22695
|
+
object: {
|
|
22696
|
+
concept_id: [1, 0],
|
|
22697
|
+
depth: [1, 0],
|
|
22698
|
+
display_label: [2, "DisplayLabelDto"],
|
|
22699
|
+
via: [1, { array: 0 }]
|
|
22700
|
+
}
|
|
22701
|
+
},
|
|
22702
|
+
HierarchyPathsResponse: {
|
|
22703
|
+
object: {
|
|
22704
|
+
complete: [1, 0],
|
|
22705
|
+
context: [2, "ContextRefDto"],
|
|
22706
|
+
from: [1, 0],
|
|
22707
|
+
paths: [1, { array: { array: 0 } }],
|
|
22708
|
+
scheme_id: [1, 0],
|
|
22709
|
+
to: [1, 0],
|
|
22710
|
+
view: [1, "ViewRefDto"]
|
|
22711
|
+
}
|
|
22712
|
+
},
|
|
22713
|
+
HierarchyResponse: {
|
|
22714
|
+
object: {
|
|
22715
|
+
complete: [1, 0],
|
|
22716
|
+
context: [2, "ContextRefDto"],
|
|
22717
|
+
direction: [1, 0],
|
|
22718
|
+
edges: [1, { array: "HierarchyEdgeDto" }],
|
|
22719
|
+
nodes: [1, { array: "HierarchyNodeDto" }],
|
|
22720
|
+
scheme_id: [1, 0],
|
|
22721
|
+
transitive: [1, 0],
|
|
22722
|
+
view: [1, "ViewRefDto"]
|
|
22723
|
+
}
|
|
22724
|
+
},
|
|
21920
22725
|
HoldoutCertifiedDto: {
|
|
21921
22726
|
object: {
|
|
21922
22727
|
certified: [1, 0],
|
|
@@ -22065,6 +22870,7 @@ var RESPONSE_COMPONENTS = {
|
|
|
22065
22870
|
sorts_created: [1, 0]
|
|
22066
22871
|
}
|
|
22067
22872
|
},
|
|
22873
|
+
ImportCellNoteDto: { object: { column: [1, 0], disposition: [1, 0], reason: [1, 0] } },
|
|
22068
22874
|
ImportFoundryResponse: {
|
|
22069
22875
|
object: {
|
|
22070
22876
|
mapped_interface_types: [1, 0],
|
|
@@ -22083,9 +22889,11 @@ var RESPONSE_COMPONENTS = {
|
|
|
22083
22889
|
object: {
|
|
22084
22890
|
reified_sorts_created: [1, { array: 0 }],
|
|
22085
22891
|
relations_discovered: [1, 0],
|
|
22086
|
-
sorts_created: [1, { array: 0 }]
|
|
22892
|
+
sorts_created: [1, { array: 0 }],
|
|
22893
|
+
sorts_refused: [0, { array: "ImportRefusedSortDto" }]
|
|
22087
22894
|
}
|
|
22088
22895
|
},
|
|
22896
|
+
ImportRefusedSortDto: { object: { name: [1, 0], reason: [1, 0] } },
|
|
22089
22897
|
InboxItemDto: {
|
|
22090
22898
|
object: {
|
|
22091
22899
|
body: [1, 0],
|
|
@@ -22301,7 +23109,16 @@ var RESPONSE_COMPONENTS = {
|
|
|
22301
23109
|
sorts_reused: [1, 0],
|
|
22302
23110
|
sota_extraction_gate: [0, "SotaExtractionGateStatsDto"],
|
|
22303
23111
|
term_ids: [1, { array: 0 }],
|
|
22304
|
-
token_usage: [0, "TokenUsageDto"]
|
|
23112
|
+
token_usage: [0, "TokenUsageDto"],
|
|
23113
|
+
work_cache: [0, "IngestionWorkCacheDto"]
|
|
23114
|
+
}
|
|
23115
|
+
},
|
|
23116
|
+
IngestionWorkCacheDto: {
|
|
23117
|
+
object: {
|
|
23118
|
+
model_calls: [1, 0],
|
|
23119
|
+
reused_model_calls: [1, 0],
|
|
23120
|
+
reused_recorded_token_usage: [1, "TokenUsageDto"],
|
|
23121
|
+
unkeyed_model_calls: [1, 0]
|
|
22305
23122
|
}
|
|
22306
23123
|
},
|
|
22307
23124
|
InheritedFeatureChangeDto: {
|
|
@@ -22459,6 +23276,15 @@ var RESPONSE_COMPONENTS = {
|
|
|
22459
23276
|
term_id: [1, 0]
|
|
22460
23277
|
}
|
|
22461
23278
|
},
|
|
23279
|
+
IriChoiceDto: {
|
|
23280
|
+
object: {
|
|
23281
|
+
iri: [1, 0],
|
|
23282
|
+
kind: [1, 0],
|
|
23283
|
+
record_id: [1, 0],
|
|
23284
|
+
rule: [1, 0],
|
|
23285
|
+
source_associations: [1, { array: 0 }]
|
|
23286
|
+
}
|
|
23287
|
+
},
|
|
22462
23288
|
IriRepairDto: { object: { original: [1, 0], repaired: [1, 0] } },
|
|
22463
23289
|
IsSubtypeResponse: { object: { is_subtype: [1, 0] } },
|
|
22464
23290
|
IterationMetricDto: {
|
|
@@ -22484,6 +23310,15 @@ var RESPONSE_COMPONENTS = {
|
|
|
22484
23310
|
wake_trigger: [1, 0]
|
|
22485
23311
|
}
|
|
22486
23312
|
},
|
|
23313
|
+
LabelRelationViewDto: {
|
|
23314
|
+
object: {
|
|
23315
|
+
object: [1, 0],
|
|
23316
|
+
record_id: [1, 0],
|
|
23317
|
+
relation: [1, 0],
|
|
23318
|
+
subject: [1, 0],
|
|
23319
|
+
other_xl_label_id: [1, 0]
|
|
23320
|
+
}
|
|
23321
|
+
},
|
|
22487
23322
|
LabelSearchHitDto: {
|
|
22488
23323
|
object: {
|
|
22489
23324
|
concept_id: [1, 0],
|
|
@@ -22707,6 +23542,19 @@ var RESPONSE_COMPONENTS = {
|
|
|
22707
23542
|
LedgerInfoDto: {
|
|
22708
23543
|
object: { backend: [1, 0], durability: [1, 0], n_records: [1, 0], survives_restart: [1, 0] }
|
|
22709
23544
|
},
|
|
23545
|
+
LegacySortInventoryDto: {
|
|
23546
|
+
object: {
|
|
23547
|
+
bound_constraint_count: [1, 0],
|
|
23548
|
+
classification: [1, 0],
|
|
23549
|
+
feature_count: [1, 0],
|
|
23550
|
+
features_ranging_over: [1, 0],
|
|
23551
|
+
instances: [1, 0],
|
|
23552
|
+
parents: [1, { array: 0 }],
|
|
23553
|
+
rules_referencing: [1, 0],
|
|
23554
|
+
sort_id: [1, 0],
|
|
23555
|
+
sort_name: [1, 0]
|
|
23556
|
+
}
|
|
23557
|
+
},
|
|
22710
23558
|
LggClassResponseDto: {
|
|
22711
23559
|
object: {
|
|
22712
23560
|
absent_from_store: [1, 0],
|
|
@@ -23297,6 +24145,18 @@ var RESPONSE_COMPONENTS = {
|
|
|
23297
24145
|
}
|
|
23298
24146
|
},
|
|
23299
24147
|
MeterDto: { object: { used: [1, 0] } },
|
|
24148
|
+
MigrationPlanResponse: {
|
|
24149
|
+
object: {
|
|
24150
|
+
byte_size: [1, 0],
|
|
24151
|
+
created_at: [1, 0],
|
|
24152
|
+
created_by: [1, 0],
|
|
24153
|
+
dispositions: [1, { array: "PlannedDispositionDto" }],
|
|
24154
|
+
fingerprint: [1, 0],
|
|
24155
|
+
inventory: [1, { array: "LegacySortInventoryDto" }],
|
|
24156
|
+
plan_id: [1, 0],
|
|
24157
|
+
replayed: [1, 0]
|
|
24158
|
+
}
|
|
24159
|
+
},
|
|
23300
24160
|
MigrationPreviewEntryDto: {
|
|
23301
24161
|
object: {
|
|
23302
24162
|
classification: [1, 0],
|
|
@@ -23385,11 +24245,45 @@ var RESPONSE_COMPONENTS = {
|
|
|
23385
24245
|
variable: [1, 0]
|
|
23386
24246
|
}
|
|
23387
24247
|
},
|
|
24248
|
+
NamespaceAnswerCachePolicyDto: {
|
|
24249
|
+
object: { enabled: [1, 0], revision: [1, 0], ttl_seconds: [1, 0] }
|
|
24250
|
+
},
|
|
24251
|
+
NamespaceAnswerCacheSavingsDto: {
|
|
24252
|
+
object: {
|
|
24253
|
+
bypassed: [1, 0],
|
|
24254
|
+
counted_since: [1, 0],
|
|
24255
|
+
disabled: [1, 0],
|
|
24256
|
+
fresh_model_calls: [1, 0],
|
|
24257
|
+
reused_model_calls: [1, 0],
|
|
24258
|
+
token_usage_measured: [1, 0],
|
|
24259
|
+
unavailable: [1, 0],
|
|
24260
|
+
unqualified: [1, 0]
|
|
24261
|
+
}
|
|
24262
|
+
},
|
|
23388
24263
|
NamespaceDto: {
|
|
23389
24264
|
object: { id: [1, 0], name: [1, 0], path: [1, 0], tags: [1, { array: 0 }], visibility: [1, 0] }
|
|
23390
24265
|
},
|
|
23391
24266
|
NamespaceListResponse: { object: { count: [1, 0], namespaces: [1, { array: "NamespaceDto" }] } },
|
|
23392
24267
|
NamespaceResponse: { object: { namespace: [1, "NamespaceDto"] } },
|
|
24268
|
+
NativeExportManifestDto: {
|
|
24269
|
+
object: {
|
|
24270
|
+
context_manifest: [2, "ContextManifestDto"],
|
|
24271
|
+
counts_by_kind: [1, { object: {} }],
|
|
24272
|
+
record_count: [1, 0],
|
|
24273
|
+
records_sha256: [1, 0],
|
|
24274
|
+
unreadable: [1, { array: "UnreadableRecordDto" }]
|
|
24275
|
+
}
|
|
24276
|
+
},
|
|
24277
|
+
NativeExportResponse: {
|
|
24278
|
+
object: {
|
|
24279
|
+
artifacts: [1, { array: "SourceArtifactRecordDto" }],
|
|
24280
|
+
context: [2, "ContextRefDto"],
|
|
24281
|
+
format: [1, 0],
|
|
24282
|
+
manifest: [1, "NativeExportManifestDto"],
|
|
24283
|
+
records: [1, { array: 0 }],
|
|
24284
|
+
view: [1, "ViewRefDto"]
|
|
24285
|
+
}
|
|
24286
|
+
},
|
|
23393
24287
|
NearMiss: {
|
|
23394
24288
|
object: {
|
|
23395
24289
|
byte_end: [1, 0],
|
|
@@ -23428,6 +24322,9 @@ var RESPONSE_COMPONENTS = {
|
|
|
23428
24322
|
},
|
|
23429
24323
|
NlQueryResultItem: { object: { features: [1, { object: {} }], id: [1, 0], sort_name: [1, 0] } },
|
|
23430
24324
|
NodeScoreDto: { object: { node_id: [1, 0], score: [1, 0] } },
|
|
24325
|
+
NotationRecordDto: {
|
|
24326
|
+
object: { concept: [1, 0], record_id: [1, 0], scheme: [1, 0], value: [1, 0] }
|
|
24327
|
+
},
|
|
23431
24328
|
NumberToStringResponse: { object: { result: [1, 0] } },
|
|
23432
24329
|
OAuthStartResponse: { object: { auth_url: [1, 0] } },
|
|
23433
24330
|
ObjectTypeDto: {
|
|
@@ -23921,6 +24818,25 @@ var RESPONSE_COMPONENTS = {
|
|
|
23921
24818
|
}
|
|
23922
24819
|
},
|
|
23923
24820
|
PersonalityTrait: { object: { description: [1, 0], name: [1, 0], strength: [1, 0] } },
|
|
24821
|
+
PicklistEntryDto: {
|
|
24822
|
+
object: {
|
|
24823
|
+
concept_id: [1, 0],
|
|
24824
|
+
depth: [1, 0],
|
|
24825
|
+
display_label: [2, "DisplayLabelDto"],
|
|
24826
|
+
other_parent_relation_ids: [1, { array: 0 }]
|
|
24827
|
+
}
|
|
24828
|
+
},
|
|
24829
|
+
PicklistResponse: {
|
|
24830
|
+
object: {
|
|
24831
|
+
complete: [1, 0],
|
|
24832
|
+
context: [2, "ContextRefDto"],
|
|
24833
|
+
entries: [1, { array: "PicklistEntryDto" }],
|
|
24834
|
+
roots: [1, { array: 0 }],
|
|
24835
|
+
roots_from: [1, 0],
|
|
24836
|
+
scheme_id: [1, 0],
|
|
24837
|
+
view: [1, "ViewRefDto"]
|
|
24838
|
+
}
|
|
24839
|
+
},
|
|
23924
24840
|
PipelineQualityStatsDto: {
|
|
23925
24841
|
object: {
|
|
23926
24842
|
axioms_deduplicated: [1, 0],
|
|
@@ -23974,6 +24890,7 @@ var RESPONSE_COMPONENTS = {
|
|
|
23974
24890
|
total_requested: [1, 0]
|
|
23975
24891
|
}
|
|
23976
24892
|
},
|
|
24893
|
+
PlannedDispositionDto: { object: { disposition: [1, 0], rationale: [1, 0], sort_id: [1, 0] } },
|
|
23977
24894
|
PlannedStrategyDto: { object: { allocated: [1, 0], name: [1, 0], weight: [1, 0] } },
|
|
23978
24895
|
PluginBindingDto: {
|
|
23979
24896
|
object: {
|
|
@@ -24104,6 +25021,7 @@ var RESPONSE_COMPONENTS = {
|
|
|
24104
25021
|
total_profit: [1, 0]
|
|
24105
25022
|
}
|
|
24106
25023
|
},
|
|
25024
|
+
ProjectionLossDto: { object: { kind: [1, 0], reason: [1, 0], record_ids: [1, { array: 0 }] } },
|
|
24107
25025
|
PromptTraceDto: { object: { llm_context: [1, "LlmContextTraceDto"], system_prompt: [1, 0] } },
|
|
24108
25026
|
ProofConclusionDto: { object: { features: [1, { object: {} }], sort_id: [1, 0] } },
|
|
24109
25027
|
ProofDto: {
|
|
@@ -24403,6 +25321,7 @@ var RESPONSE_COMPONENTS = {
|
|
|
24403
25321
|
timestamp: [1, 0]
|
|
24404
25322
|
}
|
|
24405
25323
|
},
|
|
25324
|
+
ReconciliationEntryDto: { object: { kind: [1, 0], proposal: [1, 0], source_key: [1, 0] } },
|
|
24406
25325
|
RecordChangeDto: {
|
|
24407
25326
|
object: { feature_changes: [1, { array: "RecordFeatureChangeDto" }], record_id: [1, 0] }
|
|
24408
25327
|
},
|
|
@@ -25125,6 +26044,7 @@ var RESPONSE_COMPONENTS = {
|
|
|
25125
26044
|
SchemeViewDto: {
|
|
25126
26045
|
object: {
|
|
25127
26046
|
display_name: [1, 0],
|
|
26047
|
+
documentation: [1, { array: "DocumentationRecordDto" }],
|
|
25128
26048
|
languages: [1, { array: "SchemeLanguageViewDto" }],
|
|
25129
26049
|
purpose: [1, 0],
|
|
25130
26050
|
revision: [1, 0],
|
|
@@ -25310,6 +26230,26 @@ var RESPONSE_COMPONENTS = {
|
|
|
25310
26230
|
}
|
|
25311
26231
|
},
|
|
25312
26232
|
SkippedWebPageDto: { object: { depth: [1, 0], message: [1, 0], reason: [1, 0], url: [1, 0] } },
|
|
26233
|
+
SkosExportResponse: {
|
|
26234
|
+
object: {
|
|
26235
|
+
content: [1, 0],
|
|
26236
|
+
manifest: [1, "SkosManifestDto"],
|
|
26237
|
+
media_type: [1, 0],
|
|
26238
|
+
sha256: [1, 0]
|
|
26239
|
+
}
|
|
26240
|
+
},
|
|
26241
|
+
SkosManifestDto: {
|
|
26242
|
+
object: {
|
|
26243
|
+
include_provenance: [1, 0],
|
|
26244
|
+
iri_policy: [1, 0],
|
|
26245
|
+
iris: [1, { array: "IriChoiceDto" }],
|
|
26246
|
+
losses: [1, { array: "ProjectionLossDto" }],
|
|
26247
|
+
projection: [1, 0],
|
|
26248
|
+
scheme_id: [1, 0],
|
|
26249
|
+
triple_count: [1, 0],
|
|
26250
|
+
view: [1, "ViewRefDto"]
|
|
26251
|
+
}
|
|
26252
|
+
},
|
|
25313
26253
|
SmoothingParametersDto: { object: { alpha: [1, 0] } },
|
|
25314
26254
|
SmtCheckResponse: { object: { assignments: [2, { object: {} }], result: [1, 0] } },
|
|
25315
26255
|
SnapshotFilter: { object: { request_path_pattern: [1, 0] } },
|
|
@@ -25578,6 +26518,25 @@ var RESPONSE_COMPONENTS = {
|
|
|
25578
26518
|
schema_rejected_missing_source_span: [1, 0]
|
|
25579
26519
|
}
|
|
25580
26520
|
},
|
|
26521
|
+
SourceArtifactRecordDto: {
|
|
26522
|
+
object: {
|
|
26523
|
+
byte_size: [1, 0],
|
|
26524
|
+
dataset: [1, 0],
|
|
26525
|
+
format: [1, 0],
|
|
26526
|
+
record_id: [1, 0],
|
|
26527
|
+
retained_locator: [1, 0],
|
|
26528
|
+
sha256: [1, 0]
|
|
26529
|
+
}
|
|
26530
|
+
},
|
|
26531
|
+
SourceAssociationRecordDto: {
|
|
26532
|
+
object: {
|
|
26533
|
+
artifact: [1, 0],
|
|
26534
|
+
change_reason: [1, 0],
|
|
26535
|
+
record_id: [1, 0],
|
|
26536
|
+
revision: [1, 0],
|
|
26537
|
+
source_key: [1, 0]
|
|
26538
|
+
}
|
|
26539
|
+
},
|
|
25581
26540
|
SourceDetailResponse: {
|
|
25582
26541
|
object: {
|
|
25583
26542
|
available: [1, 0],
|
|
@@ -25623,6 +26582,14 @@ var RESPONSE_COMPONENTS = {
|
|
|
25623
26582
|
}
|
|
25624
26583
|
},
|
|
25625
26584
|
SpaceResponse: { object: { constraint_count: [1, 0], id: [1, 0], status: [1, 0] } },
|
|
26585
|
+
SparqlDatasetDto: {
|
|
26586
|
+
object: {
|
|
26587
|
+
projection: [1, 0],
|
|
26588
|
+
scheme_id: [1, 0],
|
|
26589
|
+
triple_count: [1, 0],
|
|
26590
|
+
view: [1, "ViewRefDto"]
|
|
26591
|
+
}
|
|
26592
|
+
},
|
|
25626
26593
|
SparqlExplainDto: {
|
|
25627
26594
|
object: {
|
|
25628
26595
|
complete: [1, 0],
|
|
@@ -25645,6 +26612,14 @@ var RESPONSE_COMPONENTS = {
|
|
|
25645
26612
|
sorts: [0, { array: 0 }]
|
|
25646
26613
|
}
|
|
25647
26614
|
},
|
|
26615
|
+
SparqlResponse: {
|
|
26616
|
+
object: {
|
|
26617
|
+
complete: [1, 0],
|
|
26618
|
+
dataset: [1, "SparqlDatasetDto"],
|
|
26619
|
+
form: [1, 0],
|
|
26620
|
+
results: [1, { object: {} }]
|
|
26621
|
+
}
|
|
26622
|
+
},
|
|
25648
26623
|
SparqlUpdateExplainDto: { object: { osfql: [1, { array: 0 }] } },
|
|
25649
26624
|
SpeakerDetectionDto: {
|
|
25650
26625
|
object: {
|
|
@@ -25907,6 +26882,18 @@ var RESPONSE_COMPONENTS = {
|
|
|
25907
26882
|
}
|
|
25908
26883
|
},
|
|
25909
26884
|
TaskDto: { object: { is_primitive: [1, 0], subtasks: [1, { array: 0 }], task_id: [1, 0] } },
|
|
26885
|
+
TaxonomyPolicyResponse: {
|
|
26886
|
+
object: {
|
|
26887
|
+
acyclic: [1, 0],
|
|
26888
|
+
context: [2, "ContextRefDto"],
|
|
26889
|
+
declared: [1, 0],
|
|
26890
|
+
policy: [1, 0],
|
|
26891
|
+
require_placement: [1, 0],
|
|
26892
|
+
scheme_id: [1, 0],
|
|
26893
|
+
top_concepts: [1, 0],
|
|
26894
|
+
view: [1, "ViewRefDto"]
|
|
26895
|
+
}
|
|
26896
|
+
},
|
|
25910
26897
|
TemporalModelCheckResponse: {
|
|
25911
26898
|
object: {
|
|
25912
26899
|
counterexample: [2, "CounterExampleDto"],
|
|
@@ -26050,6 +27037,14 @@ var RESPONSE_COMPONENTS = {
|
|
|
26050
27037
|
}
|
|
26051
27038
|
},
|
|
26052
27039
|
ToolCallInfo: { object: { arguments: [1, 0], confidence: [1, 0], name: [1, 0] } },
|
|
27040
|
+
TopConceptsResponse: {
|
|
27041
|
+
object: {
|
|
27042
|
+
concepts: [1, { array: "ConceptSummaryDto" }],
|
|
27043
|
+
context: [2, "ContextRefDto"],
|
|
27044
|
+
scheme_id: [1, 0],
|
|
27045
|
+
view: [1, "ViewRefDto"]
|
|
27046
|
+
}
|
|
27047
|
+
},
|
|
26053
27048
|
TraceStepDto: {
|
|
26054
27049
|
object: {
|
|
26055
27050
|
entropy: [1, 0],
|
|
@@ -26256,6 +27251,7 @@ var RESPONSE_COMPONENTS = {
|
|
|
26256
27251
|
UnknownClusterDto: {
|
|
26257
27252
|
object: { cluster: [1, 0], spans: [1, { array: "SpeechSpanDto" }], speech_secs: [1, 0] }
|
|
26258
27253
|
},
|
|
27254
|
+
UnreadableRecordDto: { object: { reason: [1, 0], record_id: [1, 0] } },
|
|
26259
27255
|
UnsatisfiableClassDto: { object: { class: [1, 0], disjoint_pair: [1, { array: 0 }] } },
|
|
26260
27256
|
UnsatisfiableSortDto: { object: { disjoint_pair: [1, { array: 0 }], sort: [1, 0] } },
|
|
26261
27257
|
UpdateAgentResponse: {
|
|
@@ -26492,6 +27488,40 @@ var RESPONSE_COMPONENTS = {
|
|
|
26492
27488
|
subjects: [1, { array: 0 }]
|
|
26493
27489
|
}
|
|
26494
27490
|
},
|
|
27491
|
+
VocabularyImportArtifactDto: {
|
|
27492
|
+
object: { byte_size: [1, 0], format: [1, 0], sha256: [1, 0], source_file_id: [1, 0] }
|
|
27493
|
+
},
|
|
27494
|
+
VocabularyImportItemDto: {
|
|
27495
|
+
object: {
|
|
27496
|
+
coordinates: [1, { object: {} }],
|
|
27497
|
+
disposition: [1, 0],
|
|
27498
|
+
item: [1, { object: {} }],
|
|
27499
|
+
notes: [1, { array: "ImportCellNoteDto" }],
|
|
27500
|
+
ordinal: [1, 0],
|
|
27501
|
+
resource_keys: [1, { array: 0 }]
|
|
27502
|
+
}
|
|
27503
|
+
},
|
|
27504
|
+
VocabularyImportItemsResponse: {
|
|
27505
|
+
object: {
|
|
27506
|
+
complete: [1, 0],
|
|
27507
|
+
import_id: [1, 0],
|
|
27508
|
+
items: [1, { array: "VocabularyImportItemDto" }]
|
|
27509
|
+
}
|
|
27510
|
+
},
|
|
27511
|
+
VocabularyImportResponse: {
|
|
27512
|
+
object: {
|
|
27513
|
+
artifact: [1, "VocabularyImportArtifactDto"],
|
|
27514
|
+
complete: [1, 0],
|
|
27515
|
+
counts: [1, { object: {} }],
|
|
27516
|
+
created_at: [1, 0],
|
|
27517
|
+
created_by: [1, 0],
|
|
27518
|
+
dataset: [1, 0],
|
|
27519
|
+
import_id: [1, 0],
|
|
27520
|
+
proposed_record_counts: [1, { object: {} }],
|
|
27521
|
+
reconciliation: [1, { array: "ReconciliationEntryDto" }],
|
|
27522
|
+
replayed: [1, 0]
|
|
27523
|
+
}
|
|
27524
|
+
},
|
|
26495
27525
|
VocabularyMatch: {
|
|
26496
27526
|
object: {
|
|
26497
27527
|
canonical: [1, 0],
|
|
@@ -26590,7 +27620,8 @@ var RESPONSE_COMPONENTS = {
|
|
|
26590
27620
|
blocked_by: [1, { array: "WhyNotPremiseDto" }],
|
|
26591
27621
|
head_sort: [1, 0],
|
|
26592
27622
|
jointly_unsatisfied: [1, 0],
|
|
26593
|
-
rule_id: [1, 0]
|
|
27623
|
+
rule_id: [1, 0],
|
|
27624
|
+
undetermined: [0, { array: "WhyNotPremiseDto" }]
|
|
26594
27625
|
}
|
|
26595
27626
|
},
|
|
26596
27627
|
WithOriginals_AsyncBatchIngestionResponse: {
|
|
@@ -26671,6 +27702,20 @@ var RESPONSE_COMPONENTS = {
|
|
|
26671
27702
|
}
|
|
26672
27703
|
},
|
|
26673
27704
|
WorldModelTransitionDto: { object: { probability: [1, 0] } },
|
|
27705
|
+
XlLabelViewDto: {
|
|
27706
|
+
object: {
|
|
27707
|
+
change_reason: [1, 0],
|
|
27708
|
+
concept: [1, 0],
|
|
27709
|
+
label: [1, 0],
|
|
27710
|
+
record_id: [1, 0],
|
|
27711
|
+
resource_key: [1, 0],
|
|
27712
|
+
revision: [1, 0],
|
|
27713
|
+
role: [1, 0],
|
|
27714
|
+
scheme: [1, 0],
|
|
27715
|
+
incoming_relations: [1, { array: "LabelRelationViewDto" }],
|
|
27716
|
+
outgoing_relations: [1, { array: "LabelRelationViewDto" }]
|
|
27717
|
+
}
|
|
27718
|
+
},
|
|
26674
27719
|
YankResponse: { object: { plugin_id: [1, 0], yanked: [1, 0] } }
|
|
26675
27720
|
};
|
|
26676
27721
|
var RESPONSE_OPERATIONS = {
|
|
@@ -26860,6 +27905,11 @@ var RESPONSE_OPERATIONS = {
|
|
|
26860
27905
|
path: "/api/v1/causal/intervention",
|
|
26861
27906
|
responses: { 200: "InterventionResponse" }
|
|
26862
27907
|
},
|
|
27908
|
+
applyMigrationPlan: {
|
|
27909
|
+
method: "POST",
|
|
27910
|
+
path: "/api/v1/vocabulary/migration/plans/{plan_id}/apply",
|
|
27911
|
+
responses: { 201: "CandidateRevisionResponse" }
|
|
27912
|
+
},
|
|
26863
27913
|
applySnapshot: {
|
|
26864
27914
|
method: "POST",
|
|
26865
27915
|
path: "/api/v1/admin/snapshots/{snapshot_id}/apply/{target_tenant_id}",
|
|
@@ -26955,6 +28005,11 @@ var RESPONSE_OPERATIONS = {
|
|
|
26955
28005
|
path: "/api/v1/copy/batch",
|
|
26956
28006
|
responses: { 200: "BatchCopyResponse" }
|
|
26957
28007
|
},
|
|
28008
|
+
batchGetSubsumptions: {
|
|
28009
|
+
method: "POST",
|
|
28010
|
+
path: "/api/v1/sorts/subsumption/get/batch",
|
|
28011
|
+
responses: { 200: "BatchGetSubsumptionsResponse" }
|
|
28012
|
+
},
|
|
26958
28013
|
bayesianPredict: {
|
|
26959
28014
|
method: "POST",
|
|
26960
28015
|
path: "/api/v1/inference/bayesian-predict",
|
|
@@ -27070,6 +28125,11 @@ var RESPONSE_OPERATIONS = {
|
|
|
27070
28125
|
path: "/api/v1/sorts/similarity/bulk",
|
|
27071
28126
|
responses: { 200: "BulkSetSimilaritiesResponse" }
|
|
27072
28127
|
},
|
|
28128
|
+
bulkSetSubsumptions: {
|
|
28129
|
+
method: "POST",
|
|
28130
|
+
path: "/api/v1/sorts/subsumption/bulk",
|
|
28131
|
+
responses: { 200: "BulkSetSubsumptionsResponse" }
|
|
28132
|
+
},
|
|
27073
28133
|
calibrateConformal: {
|
|
27074
28134
|
method: "POST",
|
|
27075
28135
|
path: "/api/v1/conformal/calibrate",
|
|
@@ -27234,6 +28294,11 @@ var RESPONSE_OPERATIONS = {
|
|
|
27234
28294
|
path: "/api/v1/flow-networks/{network_id}/commit",
|
|
27235
28295
|
responses: { 200: "FlowNetworkResponse" }
|
|
27236
28296
|
},
|
|
28297
|
+
commitImport: {
|
|
28298
|
+
method: "POST",
|
|
28299
|
+
path: "/api/v1/vocabulary/imports/{import_id}/commit",
|
|
28300
|
+
responses: { 201: "CandidateRevisionResponse" }
|
|
28301
|
+
},
|
|
27237
28302
|
commitSpace: {
|
|
27238
28303
|
method: "POST",
|
|
27239
28304
|
path: "/api/v1/spaces/{space_id}/commit",
|
|
@@ -27318,11 +28383,21 @@ var RESPONSE_OPERATIONS = {
|
|
|
27318
28383
|
path: "/api/v1/analysis/path",
|
|
27319
28384
|
responses: { 200: "PathResponse" }
|
|
27320
28385
|
},
|
|
28386
|
+
conceptExpansion: {
|
|
28387
|
+
method: "GET",
|
|
28388
|
+
path: "/api/v1/vocabulary/concepts/{concept_id}/expansion",
|
|
28389
|
+
responses: { 200: "ExpansionResponse" }
|
|
28390
|
+
},
|
|
27321
28391
|
conceptHistory: {
|
|
27322
28392
|
method: "GET",
|
|
27323
28393
|
path: "/api/v1/vocabulary/concepts/{concept_id}/history",
|
|
27324
28394
|
responses: { 200: "ConceptHistoryResponse" }
|
|
27325
28395
|
},
|
|
28396
|
+
conceptRelations: {
|
|
28397
|
+
method: "GET",
|
|
28398
|
+
path: "/api/v1/vocabulary/concepts/{concept_id}/relations",
|
|
28399
|
+
responses: { 200: "ConceptRelationsResponse" }
|
|
28400
|
+
},
|
|
27326
28401
|
configureOrchestrator: {
|
|
27327
28402
|
method: "POST",
|
|
27328
28403
|
path: "/api/v1/inference/orchestrator/configure",
|
|
@@ -27441,11 +28516,21 @@ var RESPONSE_OPERATIONS = {
|
|
|
27441
28516
|
path: "/api/v1/inference/goals",
|
|
27442
28517
|
responses: { 201: "CreateGoalResponse" }
|
|
27443
28518
|
},
|
|
28519
|
+
createImport: {
|
|
28520
|
+
method: "POST",
|
|
28521
|
+
path: "/api/v1/vocabulary/imports",
|
|
28522
|
+
responses: { 201: "VocabularyImportResponse" }
|
|
28523
|
+
},
|
|
27444
28524
|
createIngestSource: {
|
|
27445
28525
|
method: "POST",
|
|
27446
28526
|
path: "/api/v1/ingest/sources",
|
|
27447
28527
|
responses: { 201: "SourceDto" }
|
|
27448
28528
|
},
|
|
28529
|
+
createMigrationPlan: {
|
|
28530
|
+
method: "POST",
|
|
28531
|
+
path: "/api/v1/vocabulary/migration/plans",
|
|
28532
|
+
responses: { 201: "MigrationPlanResponse" }
|
|
28533
|
+
},
|
|
27449
28534
|
createModule: {
|
|
27450
28535
|
method: "POST",
|
|
27451
28536
|
path: "/api/v1/modules",
|
|
@@ -27529,6 +28614,11 @@ var RESPONSE_OPERATIONS = {
|
|
|
27529
28614
|
path: "/api/v1/causal/latent-variables",
|
|
27530
28615
|
responses: { 201: "DeclareLatentVariableResponse" }
|
|
27531
28616
|
},
|
|
28617
|
+
declaredAlphaCutBelow: {
|
|
28618
|
+
method: "POST",
|
|
28619
|
+
path: "/api/v1/sorts/subsumption/alpha-cut",
|
|
28620
|
+
responses: { 200: "DeclaredAlphaCutResponse" }
|
|
28621
|
+
},
|
|
27532
28622
|
decodeGlb: {
|
|
27533
28623
|
method: "POST",
|
|
27534
28624
|
path: "/api/v1/sorts/glb/decode",
|
|
@@ -27952,6 +29042,11 @@ var RESPONSE_OPERATIONS = {
|
|
|
27952
29042
|
path: "/api/v1/synthetic/export-jsonl",
|
|
27953
29043
|
responses: { 200: "ExportJsonlResponse" }
|
|
27954
29044
|
},
|
|
29045
|
+
exportNative: {
|
|
29046
|
+
method: "GET",
|
|
29047
|
+
path: "/api/v1/vocabulary/exports/native",
|
|
29048
|
+
responses: { 200: "NativeExportResponse" }
|
|
29049
|
+
},
|
|
27955
29050
|
exportPatternContext: {
|
|
27956
29051
|
method: "POST",
|
|
27957
29052
|
path: "/api/v1/analysis/pattern-proposals/context",
|
|
@@ -27962,6 +29057,11 @@ var RESPONSE_OPERATIONS = {
|
|
|
27962
29057
|
path: "/api/v1/proof/export",
|
|
27963
29058
|
responses: { 200: "ProofExportResponse" }
|
|
27964
29059
|
},
|
|
29060
|
+
exportSkos: {
|
|
29061
|
+
method: "GET",
|
|
29062
|
+
path: "/api/v1/vocabulary/exports/skos",
|
|
29063
|
+
responses: { 200: "SkosExportResponse" }
|
|
29064
|
+
},
|
|
27965
29065
|
extendDsr: {
|
|
27966
29066
|
method: "POST",
|
|
27967
29067
|
path: "/api/v1/dsr/{id}/extend",
|
|
@@ -28428,6 +29528,11 @@ var RESPONSE_OPERATIONS = {
|
|
|
28428
29528
|
path: "/api/v1/visualization/hypergraph",
|
|
28429
29529
|
responses: { 200: "HypergraphResponse" }
|
|
28430
29530
|
},
|
|
29531
|
+
getImport: {
|
|
29532
|
+
method: "GET",
|
|
29533
|
+
path: "/api/v1/vocabulary/imports/{import_id}",
|
|
29534
|
+
responses: { 200: "VocabularyImportResponse" }
|
|
29535
|
+
},
|
|
28431
29536
|
getInbox: { method: "GET", path: "/api/v1/inbox", responses: { 200: "InboxResponse" } },
|
|
28432
29537
|
getInferenceJob: {
|
|
28433
29538
|
method: "GET",
|
|
@@ -28484,6 +29589,11 @@ var RESPONSE_OPERATIONS = {
|
|
|
28484
29589
|
path: "/api/v1/inference/meta-sorts",
|
|
28485
29590
|
responses: { 200: "MetaSortsResponse" }
|
|
28486
29591
|
},
|
|
29592
|
+
getMigrationPlan: {
|
|
29593
|
+
method: "GET",
|
|
29594
|
+
path: "/api/v1/vocabulary/migration/plans/{plan_id}",
|
|
29595
|
+
responses: { 200: "MigrationPlanResponse" }
|
|
29596
|
+
},
|
|
28487
29597
|
getMyTenant: {
|
|
28488
29598
|
method: "GET",
|
|
28489
29599
|
path: "/api/v1/tenants/me",
|
|
@@ -28499,6 +29609,16 @@ var RESPONSE_OPERATIONS = {
|
|
|
28499
29609
|
path: "/api/v1/namespaces/{id}/ancestors",
|
|
28500
29610
|
responses: { 200: "NamespaceListResponse" }
|
|
28501
29611
|
},
|
|
29612
|
+
getNamespaceAnswerCachePolicy: {
|
|
29613
|
+
method: "GET",
|
|
29614
|
+
path: "/api/v1/namespaces/{id}/answer-cache-policy",
|
|
29615
|
+
responses: { 200: "NamespaceAnswerCachePolicyDto" }
|
|
29616
|
+
},
|
|
29617
|
+
getNamespaceAnswerCacheSavings: {
|
|
29618
|
+
method: "GET",
|
|
29619
|
+
path: "/api/v1/namespaces/{id}/answer-cache-savings",
|
|
29620
|
+
responses: { 200: "NamespaceAnswerCacheSavingsDto" }
|
|
29621
|
+
},
|
|
28502
29622
|
getNamespaceByPath: {
|
|
28503
29623
|
method: "GET",
|
|
28504
29624
|
path: "/api/v1/namespaces/path/{tenant_id}/{path}",
|
|
@@ -28722,6 +29842,11 @@ var RESPONSE_OPERATIONS = {
|
|
|
28722
29842
|
path: "/api/v1/verification/certificates/{id}",
|
|
28723
29843
|
responses: { 200: "VerificationCertificateResponse" }
|
|
28724
29844
|
},
|
|
29845
|
+
getVocabularyCollection: {
|
|
29846
|
+
method: "GET",
|
|
29847
|
+
path: "/api/v1/vocabulary/collections/{collection_id}",
|
|
29848
|
+
responses: { 200: "CollectionDetailResponse" }
|
|
29849
|
+
},
|
|
28725
29850
|
getWorkflow: { method: "GET", path: "/api/v1/workflows/{id}", responses: { 200: "WorkflowDto" } },
|
|
28726
29851
|
getWorkflowRun: {
|
|
28727
29852
|
method: "GET",
|
|
@@ -28794,6 +29919,11 @@ var RESPONSE_OPERATIONS = {
|
|
|
28794
29919
|
path: "/api/v1/ontology/import-foundry",
|
|
28795
29920
|
responses: { 201: "ImportFoundryResponse" }
|
|
28796
29921
|
},
|
|
29922
|
+
importItems: {
|
|
29923
|
+
method: "GET",
|
|
29924
|
+
path: "/api/v1/vocabulary/imports/{import_id}/items",
|
|
29925
|
+
responses: { 200: "VocabularyImportItemsResponse" }
|
|
29926
|
+
},
|
|
28797
29927
|
importKappa: {
|
|
28798
29928
|
method: "POST",
|
|
28799
29929
|
path: "/api/v1/injection/kappa",
|
|
@@ -29398,6 +30528,11 @@ var RESPONSE_OPERATIONS = {
|
|
|
29398
30528
|
path: "/api/v1/namespaces/{namespace_id}/visible-terms",
|
|
29399
30529
|
responses: { 200: "TermListResponse" }
|
|
29400
30530
|
},
|
|
30531
|
+
listVocabularyCollections: {
|
|
30532
|
+
method: "GET",
|
|
30533
|
+
path: "/api/v1/vocabulary/collections",
|
|
30534
|
+
responses: { 200: "CollectionPageResponse" }
|
|
30535
|
+
},
|
|
29401
30536
|
listVoices: {
|
|
29402
30537
|
method: "GET",
|
|
29403
30538
|
path: "/api/v1/speech/voices",
|
|
@@ -30212,6 +31347,31 @@ var RESPONSE_OPERATIONS = {
|
|
|
30212
31347
|
path: "/api/v1/vocabulary/candidates/{candidate_id}/revisions",
|
|
30213
31348
|
responses: { 201: "CandidateRevisionResponse" }
|
|
30214
31349
|
},
|
|
31350
|
+
schemeHierarchy: {
|
|
31351
|
+
method: "GET",
|
|
31352
|
+
path: "/api/v1/vocabulary/schemes/{scheme_id}/hierarchy",
|
|
31353
|
+
responses: { 200: "HierarchyResponse" }
|
|
31354
|
+
},
|
|
31355
|
+
schemePaths: {
|
|
31356
|
+
method: "GET",
|
|
31357
|
+
path: "/api/v1/vocabulary/schemes/{scheme_id}/paths",
|
|
31358
|
+
responses: { 200: "HierarchyPathsResponse" }
|
|
31359
|
+
},
|
|
31360
|
+
schemePicklist: {
|
|
31361
|
+
method: "GET",
|
|
31362
|
+
path: "/api/v1/vocabulary/schemes/{scheme_id}/picklist",
|
|
31363
|
+
responses: { 200: "PicklistResponse" }
|
|
31364
|
+
},
|
|
31365
|
+
schemePolicy: {
|
|
31366
|
+
method: "GET",
|
|
31367
|
+
path: "/api/v1/vocabulary/schemes/{scheme_id}/policy",
|
|
31368
|
+
responses: { 200: "TaxonomyPolicyResponse" }
|
|
31369
|
+
},
|
|
31370
|
+
schemeTopConcepts: {
|
|
31371
|
+
method: "GET",
|
|
31372
|
+
path: "/api/v1/vocabulary/schemes/{scheme_id}/top-concepts",
|
|
31373
|
+
responses: { 200: "TopConceptsResponse" }
|
|
31374
|
+
},
|
|
30215
31375
|
scmCounterfactual: {
|
|
30216
31376
|
method: "POST",
|
|
30217
31377
|
path: "/api/v1/causal/counterfactual/scm",
|
|
@@ -30352,6 +31512,7 @@ var RESPONSE_OPERATIONS = {
|
|
|
30352
31512
|
path: "/api/v1/constraints/solve",
|
|
30353
31513
|
responses: { 200: "SolveConstraintResponse" }
|
|
30354
31514
|
},
|
|
31515
|
+
solveCsp: { method: "POST", path: "/api/v1/csp/solve", responses: { 200: "CspSolveResponse" } },
|
|
30355
31516
|
solveFlowNetwork: {
|
|
30356
31517
|
method: "POST",
|
|
30357
31518
|
path: "/api/v1/flow-networks/{network_id}/solve",
|
|
@@ -30379,6 +31540,11 @@ var RESPONSE_OPERATIONS = {
|
|
|
30379
31540
|
path: "/api/v1/sorts/index/status",
|
|
30380
31541
|
responses: { 200: "SortIndexStatusResponse" }
|
|
30381
31542
|
},
|
|
31543
|
+
sparqlQuery: {
|
|
31544
|
+
method: "POST",
|
|
31545
|
+
path: "/api/v1/vocabulary/sparql",
|
|
31546
|
+
responses: { 200: "SparqlResponse" }
|
|
31547
|
+
},
|
|
30382
31548
|
startExploration: {
|
|
30383
31549
|
method: "POST",
|
|
30384
31550
|
path: "/api/v1/analysis/attribute-exploration/start",
|
|
@@ -30619,6 +31785,11 @@ var RESPONSE_OPERATIONS = {
|
|
|
30619
31785
|
path: "/api/v1/cognitive/agents/{agent_id}",
|
|
30620
31786
|
responses: { 200: "UpdateAgentResponse" }
|
|
30621
31787
|
},
|
|
31788
|
+
updateNamespaceAnswerCachePolicy: {
|
|
31789
|
+
method: "PUT",
|
|
31790
|
+
path: "/api/v1/namespaces/{id}/answer-cache-policy",
|
|
31791
|
+
responses: { 200: "NamespaceAnswerCachePolicyDto" }
|
|
31792
|
+
},
|
|
30622
31793
|
updatePlanStats: {
|
|
30623
31794
|
method: "POST",
|
|
30624
31795
|
path: "/api/v1/cognitive/agents/plans/stats",
|
|
@@ -31086,19 +32257,42 @@ var SortsClient = class {
|
|
|
31086
32257
|
/**
|
|
31087
32258
|
* Propose mixin parents for feature shapes several sorts repeat unchanged.
|
|
31088
32259
|
*
|
|
31089
|
-
* @param request - Which sorts to analyse (default: all),
|
|
31090
|
-
*
|
|
31091
|
-
*
|
|
31092
|
-
* @
|
|
32260
|
+
* @param request - Which sorts to analyse (default: all), the least number of
|
|
32261
|
+
* sorts a proposal must cover (default and floor: 2), and optional lower
|
|
32262
|
+
* budgets in `limits`.
|
|
32263
|
+
* @returns Candidate parents, most shared declarations first, with the input,
|
|
32264
|
+
* search and presentation coverage of the run.
|
|
32265
|
+
* @throws {ApiError} If the request fails: `400` for an invalid selection or a
|
|
32266
|
+
* limit above the native ceiling, `403` when a source or ancestor schema is
|
|
32267
|
+
* not readable, `422` when a declaration cannot be represented losslessly.
|
|
31093
32268
|
*
|
|
31094
32269
|
* @remarks
|
|
31095
|
-
*
|
|
31096
|
-
*
|
|
31097
|
-
* before creating the parent.
|
|
32270
|
+
* Never writes. The analysis runs native formal concept analysis over whole
|
|
32271
|
+
* feature declarations and checks each concept. `suggestedName` is a
|
|
32272
|
+
* placeholder to rename before creating the parent.
|
|
32273
|
+
*
|
|
32274
|
+
* Coverage has three independent parts. Read all three before you claim
|
|
32275
|
+
* coverage. `inputComplete` says whether the whole cohort was read within the
|
|
32276
|
+
* limits; when it is `false`, `inputStop` names the stop and no search ran.
|
|
32277
|
+
* `search.complete` says whether the enumeration was exhausted. That
|
|
32278
|
+
* exhaustion concerns the stated tenant and policy cohort only. Presentation
|
|
32279
|
+
* can truncate independently: `presentationStopReason` is set when the list
|
|
32280
|
+
* is shorter than the search result.
|
|
32281
|
+
*
|
|
32282
|
+
* A proposal is a candidate, not an admission. `nativeAdmission` is always
|
|
32283
|
+
* `false`. Neither the report nor its digest `contextSha256` is an admission
|
|
32284
|
+
* seal. To accept a candidate, use the existing governed declaration and
|
|
32285
|
+
* reparenting operations.
|
|
32286
|
+
*
|
|
32287
|
+
* Serialization: the request `limits` keys are sent as snake_case `max_*`.
|
|
32288
|
+
* An absent budget is omitted, never sent as `null`.
|
|
31098
32289
|
*
|
|
31099
32290
|
* @example
|
|
31100
32291
|
* ```typescript
|
|
31101
|
-
* const
|
|
32292
|
+
* const report = await client.sorts.factorSorts({ minSorts: 3, limits: { maxProposals: 50 } });
|
|
32293
|
+
* if (report.inputComplete && report.search?.complete && report.presentationStopReason == null) {
|
|
32294
|
+
* console.log(report.proposals.length);
|
|
32295
|
+
* }
|
|
31102
32296
|
* ```
|
|
31103
32297
|
*/
|
|
31104
32298
|
async factorSorts(request = {}, requestOptions) {
|
|
@@ -33259,6 +34453,17 @@ function SolutionDtoFromApiToFront(dto) {
|
|
|
33259
34453
|
}
|
|
33260
34454
|
return solution;
|
|
33261
34455
|
}
|
|
34456
|
+
function WhyNotPremiseFromApiToFront(dto) {
|
|
34457
|
+
return {
|
|
34458
|
+
sort: dto.sort,
|
|
34459
|
+
// Premise feature names are user data: kept as written.
|
|
34460
|
+
features: Object.fromEntries(
|
|
34461
|
+
Object.entries(dto.features).filter(
|
|
34462
|
+
(entry) => entry[1] !== void 0
|
|
34463
|
+
)
|
|
34464
|
+
)
|
|
34465
|
+
};
|
|
34466
|
+
}
|
|
33262
34467
|
function WhyNotFromApiToFront(dto) {
|
|
33263
34468
|
return {
|
|
33264
34469
|
goalSort: dto.goal_sort,
|
|
@@ -33276,14 +34481,9 @@ function WhyNotFromApiToFront(dto) {
|
|
|
33276
34481
|
rules: dto.rules.map((r) => ({
|
|
33277
34482
|
ruleId: r.rule_id,
|
|
33278
34483
|
headSort: r.head_sort,
|
|
33279
|
-
blockedBy: r.blocked_by.map(
|
|
33280
|
-
|
|
33281
|
-
|
|
33282
|
-
Object.entries(p.features).filter(
|
|
33283
|
-
(entry) => entry[1] !== void 0
|
|
33284
|
-
)
|
|
33285
|
-
)
|
|
33286
|
-
})),
|
|
34484
|
+
blockedBy: r.blocked_by.map(WhyNotPremiseFromApiToFront),
|
|
34485
|
+
// Always sent by the engine; an engine that predates it sends none.
|
|
34486
|
+
undetermined: (r.undetermined ?? []).map(WhyNotPremiseFromApiToFront),
|
|
33287
34487
|
jointlyUnsatisfied: r.jointly_unsatisfied
|
|
33288
34488
|
}))
|
|
33289
34489
|
};
|
|
@@ -34978,6 +36178,7 @@ function UnifiableQueryRequestFromFrontToApi(model) {
|
|
|
34978
36178
|
}
|
|
34979
36179
|
function FindBySortRequestFromFrontToApi(model) {
|
|
34980
36180
|
return {
|
|
36181
|
+
fields: model.fields ?? void 0,
|
|
34981
36182
|
sort_id: model.sortId ?? void 0,
|
|
34982
36183
|
sort_name: model.sortName ?? void 0,
|
|
34983
36184
|
filter: model.filter ?? void 0,
|
|
@@ -35076,6 +36277,7 @@ function ToolCallInfoFromApiToFront(dto) {
|
|
|
35076
36277
|
function NlQueryRequestFromFrontToApi(model) {
|
|
35077
36278
|
return {
|
|
35078
36279
|
query: model.query,
|
|
36280
|
+
fresh: model.fresh,
|
|
35079
36281
|
mode: model.mode,
|
|
35080
36282
|
tenant_id: model.tenantId,
|
|
35081
36283
|
conversation_history: model.conversationHistory ?? void 0,
|
|
@@ -35665,6 +36867,7 @@ function CycleOutcomeDtoFromApiToFront(dto) {
|
|
|
35665
36867
|
goalsPursued: dto.goals_pursued,
|
|
35666
36868
|
goalsAchieved: dto.goals_achieved,
|
|
35667
36869
|
goalsFailed: dto.goals_failed,
|
|
36870
|
+
goalsDeferred: dto.goals_deferred ?? [],
|
|
35668
36871
|
actionsExecuted: dto.actions_executed,
|
|
35669
36872
|
newBeliefs: dto.new_beliefs,
|
|
35670
36873
|
updatedBeliefs: dto.updated_beliefs,
|
|
@@ -37984,6 +39187,30 @@ function NamespaceListResponseFromApiToFront(dto) {
|
|
|
37984
39187
|
count: dto.count
|
|
37985
39188
|
};
|
|
37986
39189
|
}
|
|
39190
|
+
function UpdateNamespaceAnswerCachePolicyRequestFromFrontToApi(model) {
|
|
39191
|
+
return { enabled: model.enabled, ttl_seconds: model.ttlSeconds };
|
|
39192
|
+
}
|
|
39193
|
+
function NamespaceAnswerCacheSavingsDtoFromApiToFront(dto) {
|
|
39194
|
+
return {
|
|
39195
|
+
countedSince: dto.counted_since,
|
|
39196
|
+
freshModelCalls: dto.fresh_model_calls,
|
|
39197
|
+
reusedModelCalls: dto.reused_model_calls,
|
|
39198
|
+
bypassed: dto.bypassed,
|
|
39199
|
+
disabled: dto.disabled,
|
|
39200
|
+
unavailable: dto.unavailable,
|
|
39201
|
+
unqualified: dto.unqualified,
|
|
39202
|
+
tokenUsageMeasured: dto.token_usage_measured
|
|
39203
|
+
};
|
|
39204
|
+
}
|
|
39205
|
+
function NamespaceAnswerCachePolicyDtoFromApiToFront(dto) {
|
|
39206
|
+
return {
|
|
39207
|
+
enabled: dto.enabled,
|
|
39208
|
+
ttlSeconds: dto.ttl_seconds,
|
|
39209
|
+
revision: dto.revision,
|
|
39210
|
+
updatedBy: dto.updated_by,
|
|
39211
|
+
updatedAt: dto.updated_at
|
|
39212
|
+
};
|
|
39213
|
+
}
|
|
37987
39214
|
|
|
37988
39215
|
// src/resources/namespaces.ts
|
|
37989
39216
|
var NamespacesClient = class {
|
|
@@ -38035,6 +39262,51 @@ var NamespacesClient = class {
|
|
|
38035
39262
|
const response = await this.api.getNamespace(namespaceId, toRequestParams(requestOptions));
|
|
38036
39263
|
return decodeResponse(response, (dto) => NamespaceDtoFromApiToFront(dto.namespace));
|
|
38037
39264
|
}
|
|
39265
|
+
/** Read durable answer-cache settings. OSFKB checks the native namespace grant. */
|
|
39266
|
+
async getAnswerCachePolicy(namespaceId, requestOptions) {
|
|
39267
|
+
const response = await this.api.getNamespaceAnswerCachePolicy(
|
|
39268
|
+
namespaceId,
|
|
39269
|
+
toRequestParams(requestOptions)
|
|
39270
|
+
);
|
|
39271
|
+
return decodeResponse(response, NamespaceAnswerCachePolicyDtoFromApiToFront);
|
|
39272
|
+
}
|
|
39273
|
+
/**
|
|
39274
|
+
* Read the answer-cache outcomes the engine counted for a namespace.
|
|
39275
|
+
*
|
|
39276
|
+
* @param namespaceId - Namespace UUID.
|
|
39277
|
+
* @param requestOptions - Per-call options (timeout, retries, signal, headers).
|
|
39278
|
+
* @returns The counters of this engine process since `countedSince`.
|
|
39279
|
+
* @throws {ForbiddenError} 403 without a native `manage_answer_cache` grant.
|
|
39280
|
+
* @throws {NotFoundError} 404 for a namespace not in this tenant.
|
|
39281
|
+
* @throws {ServiceUnavailableError} 503 when the namespace state or authority is unavailable.
|
|
39282
|
+
*
|
|
39283
|
+
* @remarks
|
|
39284
|
+
* `GET /api/v1/namespaces/{id}/answer-cache-savings`. The counters are
|
|
39285
|
+
* process-local and not durable; token savings are not measured
|
|
39286
|
+
* (`tokenUsageMeasured: false`). Response mapped from snake_case.
|
|
39287
|
+
*
|
|
39288
|
+
* @example
|
|
39289
|
+
* ```typescript
|
|
39290
|
+
* const savings = await client.namespaces.getAnswerCacheSavings(namespaceId);
|
|
39291
|
+
* console.log(savings.reusedModelCalls, 'of', savings.freshModelCalls + savings.reusedModelCalls);
|
|
39292
|
+
* ```
|
|
39293
|
+
*/
|
|
39294
|
+
async getAnswerCacheSavings(namespaceId, requestOptions) {
|
|
39295
|
+
const response = await this.api.getNamespaceAnswerCacheSavings(
|
|
39296
|
+
namespaceId,
|
|
39297
|
+
toRequestParams(requestOptions)
|
|
39298
|
+
);
|
|
39299
|
+
return decodeResponse(response, NamespaceAnswerCacheSavingsDtoFromApiToFront);
|
|
39300
|
+
}
|
|
39301
|
+
/** Save settings in OSFKB; policy validation and cache admission stay in the engine. */
|
|
39302
|
+
async updateAnswerCachePolicy(namespaceId, request, requestOptions) {
|
|
39303
|
+
const response = await this.api.updateNamespaceAnswerCachePolicy(
|
|
39304
|
+
namespaceId,
|
|
39305
|
+
UpdateNamespaceAnswerCachePolicyRequestFromFrontToApi(request),
|
|
39306
|
+
toRequestParams(requestOptions)
|
|
39307
|
+
);
|
|
39308
|
+
return decodeResponse(response, NamespaceAnswerCachePolicyDtoFromApiToFront);
|
|
39309
|
+
}
|
|
38038
39310
|
/**
|
|
38039
39311
|
* Delete a namespace.
|
|
38040
39312
|
*
|
|
@@ -40940,6 +42212,14 @@ function TokenUsageDtoFromApiToFront(dto) {
|
|
|
40940
42212
|
totalTokens: dto.total_tokens
|
|
40941
42213
|
};
|
|
40942
42214
|
}
|
|
42215
|
+
function IngestionWorkCacheDtoFromApiToFront(dto) {
|
|
42216
|
+
return {
|
|
42217
|
+
modelCalls: dto.model_calls,
|
|
42218
|
+
reusedModelCalls: dto.reused_model_calls,
|
|
42219
|
+
unkeyedModelCalls: dto.unkeyed_model_calls,
|
|
42220
|
+
reusedRecordedTokenUsage: TokenUsageDtoFromApiToFront(dto.reused_recorded_token_usage)
|
|
42221
|
+
};
|
|
42222
|
+
}
|
|
40943
42223
|
function AlignmentStatsDtoFromApiToFront(dto) {
|
|
40944
42224
|
return {
|
|
40945
42225
|
avgFuzzyRatio: dto.avg_fuzzy_ratio,
|
|
@@ -41037,6 +42317,7 @@ function IngestionStatsDtoFromApiToFront(dto) {
|
|
|
41037
42317
|
sotaExtractionGate: dto.sota_extraction_gate ? SotaExtractionGateStatsDtoFromApiToFront(dto.sota_extraction_gate) : void 0,
|
|
41038
42318
|
termIds: dto.term_ids,
|
|
41039
42319
|
tokenUsage: dto.token_usage ? TokenUsageDtoFromApiToFront(dto.token_usage) : void 0,
|
|
42320
|
+
workCache: dto.work_cache ? IngestionWorkCacheDtoFromApiToFront(dto.work_cache) : void 0,
|
|
41040
42321
|
fcaDiscovery: dto.fca_discovery ? FcaIngestionReportFromApiToFront(dto.fca_discovery) : void 0
|
|
41041
42322
|
};
|
|
41042
42323
|
}
|
|
@@ -41236,6 +42517,7 @@ function TranslateRdfResponseFromApiToFront(dto) {
|
|
|
41236
42517
|
prefixes: definedRecordOrNullish(dto.prefixes),
|
|
41237
42518
|
repairedIriCount: dto.repaired_iri_count ?? 0,
|
|
41238
42519
|
repairedIris: (dto.repaired_iris ?? []).map(IriRepairFromApiToFront),
|
|
42520
|
+
routedToVocabularyImport: dto.routed_to_vocabulary_import ?? 0,
|
|
41239
42521
|
sortPreviews: (dto.sort_previews ?? []).map(SortPreviewFromApiToFront),
|
|
41240
42522
|
sorts: dto.sorts,
|
|
41241
42523
|
termCount: dto.term_count,
|
|
@@ -41290,6 +42572,7 @@ function IngestRdfResponseFromApiToFront(dto) {
|
|
|
41290
42572
|
return {
|
|
41291
42573
|
repairedIriCount: dto.repaired_iri_count ?? 0,
|
|
41292
42574
|
repairedIris: (dto.repaired_iris ?? []).map(IriRepairFromApiToFront),
|
|
42575
|
+
routedToVocabularyImport: dto.routed_to_vocabulary_import ?? 0,
|
|
41293
42576
|
shapesParsed: dto.shapes_parsed,
|
|
41294
42577
|
sortNames: dto.sort_names,
|
|
41295
42578
|
sortsCreated: dto.sorts_created,
|
|
@@ -41311,6 +42594,7 @@ function RdfImportReceiptFromApiToFront(dto) {
|
|
|
41311
42594
|
return {
|
|
41312
42595
|
repairedIriCount: dto.repaired_iri_count,
|
|
41313
42596
|
repairedIris: dto.repaired_iris.map(IriRepairFromApiToFront),
|
|
42597
|
+
routedToVocabularyImport: dto.routed_to_vocabulary_import,
|
|
41314
42598
|
shapesParsed: dto.shapes_parsed,
|
|
41315
42599
|
sortsCreated: dto.sorts_created,
|
|
41316
42600
|
termsCreated: dto.terms_created
|
|
@@ -41828,6 +43112,7 @@ function RdfUploadFromApiToFront(dto) {
|
|
|
41828
43112
|
prefixBindings: definedRecord(dto.prefix_bindings ?? {}),
|
|
41829
43113
|
quadsCommitted: dto.quads_committed,
|
|
41830
43114
|
batchesCommitted: dto.batches_committed,
|
|
43115
|
+
routedToVocabularyImport: dto.routed_to_vocabulary_import ?? 0,
|
|
41831
43116
|
resourcesCreated: dto.resources_created,
|
|
41832
43117
|
sortsCreated: dto.sorts_created,
|
|
41833
43118
|
error: dto.error,
|
|
@@ -53117,7 +54402,23 @@ var VOCABULARY_REFUSAL_CODES = members({
|
|
|
53117
54402
|
vocabulary_outcome_unconfirmed: true,
|
|
53118
54403
|
no_committed_outcome: true,
|
|
53119
54404
|
governed_sort_write_refused: true,
|
|
53120
|
-
read_budget_exceeded: true
|
|
54405
|
+
read_budget_exceeded: true,
|
|
54406
|
+
cursor_mismatch: true,
|
|
54407
|
+
format_unsupported: true,
|
|
54408
|
+
source_too_large: true,
|
|
54409
|
+
source_file_not_found: true,
|
|
54410
|
+
import_incomplete: true,
|
|
54411
|
+
import_too_large: true,
|
|
54412
|
+
import_already_committed: true,
|
|
54413
|
+
import_baseline_stale: true,
|
|
54414
|
+
reconciliation_undecided: true,
|
|
54415
|
+
invalid_decision: true,
|
|
54416
|
+
migration_plan_stale: true,
|
|
54417
|
+
invalid_disposition: true,
|
|
54418
|
+
sparql_unsupported: true,
|
|
54419
|
+
vocabulary_sparql_unavailable: true,
|
|
54420
|
+
sparql_deadline: true,
|
|
54421
|
+
export_unrepresentable: true
|
|
53121
54422
|
});
|
|
53122
54423
|
var VOCABULARY_FINDING_CODES = members({
|
|
53123
54424
|
declaration_violation: true,
|
|
@@ -53138,7 +54439,24 @@ var VOCABULARY_FINDING_CODES = members({
|
|
|
53138
54439
|
evidence_provenance_unknown: true,
|
|
53139
54440
|
stale_baseline: true,
|
|
53140
54441
|
plugin_context_changed: true,
|
|
53141
|
-
language_unknown: true
|
|
54442
|
+
language_unknown: true,
|
|
54443
|
+
hierarchy_self_link: true,
|
|
54444
|
+
hierarchy_cycle: true,
|
|
54445
|
+
hierarchy_depth_exceeded: true,
|
|
54446
|
+
partitive_interpretation_unresolved: true,
|
|
54447
|
+
relation_outside_scheme: true,
|
|
54448
|
+
related_also_hierarchical: true,
|
|
54449
|
+
top_concept_has_broader: true,
|
|
54450
|
+
missing_top_concept: true,
|
|
54451
|
+
unplaced_concept: true,
|
|
54452
|
+
mapping_conflict: true,
|
|
54453
|
+
mapping_target_unavailable: true,
|
|
54454
|
+
notation_duplicate: true,
|
|
54455
|
+
collection_member_dangling: true,
|
|
54456
|
+
collection_cycle: true,
|
|
54457
|
+
collection_position_duplicate: true,
|
|
54458
|
+
collection_position_missing: true,
|
|
54459
|
+
xl_label_without_label_use: true
|
|
53142
54460
|
});
|
|
53143
54461
|
var VOCABULARY_FINDING_SEVERITIES = members({
|
|
53144
54462
|
blocking: true,
|
|
@@ -53186,7 +54504,11 @@ var VOCABULARY_OPERATIONS = members({
|
|
|
53186
54504
|
reject: true,
|
|
53187
54505
|
withdraw: true,
|
|
53188
54506
|
release: true,
|
|
53189
|
-
activate: true
|
|
54507
|
+
activate: true,
|
|
54508
|
+
create_import: true,
|
|
54509
|
+
commit_import: true,
|
|
54510
|
+
create_migration_plan: true,
|
|
54511
|
+
apply_migration_plan: true
|
|
53190
54512
|
});
|
|
53191
54513
|
|
|
53192
54514
|
// src/utils/vocabulary-refusal.ts
|
|
@@ -53332,7 +54654,9 @@ function readRefusal(body) {
|
|
|
53332
54654
|
findingIds: optionalStrings(wire.finding_ids, "finding_ids"),
|
|
53333
54655
|
conflicts: optionalList(wire.conflicts, "conflicts", readConflict),
|
|
53334
54656
|
recordErrors: optionalList(wire.record_errors, "record_errors", readRecordError),
|
|
53335
|
-
missingRelations: optionalStrings(wire.missing_relations, "missing_relations")
|
|
54657
|
+
missingRelations: optionalStrings(wire.missing_relations, "missing_relations"),
|
|
54658
|
+
undecidedSourceKeys: optionalStrings(wire.undecided_source_keys, "undecided_source_keys"),
|
|
54659
|
+
changedSorts: optionalStrings(wire.changed_sorts, "changed_sorts")
|
|
53336
54660
|
};
|
|
53337
54661
|
if (!isAbsent(wire.current)) out.current = readCurrent(wire.current, "current");
|
|
53338
54662
|
if (!isAbsent(wire.authority)) out.authority = readAuthority(wire.authority, "authority");
|
|
@@ -61676,7 +63000,11 @@ function ImportOwlResponseFromApiToFront(dto) {
|
|
|
61676
63000
|
return {
|
|
61677
63001
|
reifiedSortsCreated: dto.reified_sorts_created,
|
|
61678
63002
|
relationsDiscovered: dto.relations_discovered,
|
|
61679
|
-
sortsCreated: dto.sorts_created
|
|
63003
|
+
sortsCreated: dto.sorts_created,
|
|
63004
|
+
sortsRefused: (dto.sorts_refused ?? []).map((sort) => ({
|
|
63005
|
+
name: sort.name,
|
|
63006
|
+
reason: sort.reason
|
|
63007
|
+
}))
|
|
61680
63008
|
};
|
|
61681
63009
|
}
|
|
61682
63010
|
function ExecuteTranspiledRequestFromFrontToApi(model) {
|
|
@@ -69295,6 +70623,99 @@ function AboutnessInputFromFrontToApi(record) {
|
|
|
69295
70623
|
}
|
|
69296
70624
|
return out;
|
|
69297
70625
|
}
|
|
70626
|
+
function ConceptRelationInputFromFrontToApi(record) {
|
|
70627
|
+
const out = {
|
|
70628
|
+
scheme: VocabularyRecordRefFromFrontToApi(record.scheme),
|
|
70629
|
+
subject: VocabularyRecordRefFromFrontToApi(record.subject),
|
|
70630
|
+
object: VocabularyRecordRefFromFrontToApi(record.object),
|
|
70631
|
+
relation: record.relation,
|
|
70632
|
+
status: record.status
|
|
70633
|
+
};
|
|
70634
|
+
if (record.hierarchyKind !== void 0) out.hierarchy_kind = record.hierarchyKind;
|
|
70635
|
+
if (record.evidence !== void 0) {
|
|
70636
|
+
out.evidence = VocabularyRecordRefFromFrontToApi(record.evidence);
|
|
70637
|
+
}
|
|
70638
|
+
return out;
|
|
70639
|
+
}
|
|
70640
|
+
function TaxonomyPolicyInputFromFrontToApi(record) {
|
|
70641
|
+
const out = {
|
|
70642
|
+
scheme: VocabularyRecordRefFromFrontToApi(record.scheme),
|
|
70643
|
+
acyclic: record.acyclic,
|
|
70644
|
+
require_placement: record.requirePlacement,
|
|
70645
|
+
top_concepts: record.topConcepts
|
|
70646
|
+
};
|
|
70647
|
+
if (record.maxDepth !== void 0) out.max_depth = record.maxDepth;
|
|
70648
|
+
if (record.partitiveTransitive !== void 0) {
|
|
70649
|
+
out.partitive_transitive = record.partitiveTransitive;
|
|
70650
|
+
}
|
|
70651
|
+
return out;
|
|
70652
|
+
}
|
|
70653
|
+
function ExternalConceptInputFromFrontToApi(record) {
|
|
70654
|
+
const out = {
|
|
70655
|
+
authority: record.authority,
|
|
70656
|
+
dataset_version: record.datasetVersion,
|
|
70657
|
+
iri: record.iri,
|
|
70658
|
+
resolution: record.resolution
|
|
70659
|
+
};
|
|
70660
|
+
if (record.recordId !== void 0) out.record_id = record.recordId;
|
|
70661
|
+
if (record.clientRef !== void 0) out.client_ref = record.clientRef;
|
|
70662
|
+
if (record.labelText !== void 0) out.label_text = record.labelText;
|
|
70663
|
+
if (record.labelLanguage !== void 0) out.label_language = record.labelLanguage;
|
|
70664
|
+
if (record.evidence !== void 0) {
|
|
70665
|
+
out.evidence = VocabularyRecordRefFromFrontToApi(record.evidence);
|
|
70666
|
+
}
|
|
70667
|
+
return out;
|
|
70668
|
+
}
|
|
70669
|
+
function MappingTargetFromFrontToApi(target) {
|
|
70670
|
+
return "concept" in target ? { concept: VocabularyRecordRefFromFrontToApi(target.concept) } : { external: VocabularyRecordRefFromFrontToApi(target.external) };
|
|
70671
|
+
}
|
|
70672
|
+
function ConceptMappingInputFromFrontToApi(record) {
|
|
70673
|
+
const out = {
|
|
70674
|
+
subject: VocabularyRecordRefFromFrontToApi(record.subject),
|
|
70675
|
+
target: MappingTargetFromFrontToApi(record.target),
|
|
70676
|
+
mapping_kind: record.mappingKind,
|
|
70677
|
+
status: record.status
|
|
70678
|
+
};
|
|
70679
|
+
if (record.evidence !== void 0) {
|
|
70680
|
+
out.evidence = VocabularyRecordRefFromFrontToApi(record.evidence);
|
|
70681
|
+
}
|
|
70682
|
+
return out;
|
|
70683
|
+
}
|
|
70684
|
+
function DocumentationInputFromFrontToApi(record) {
|
|
70685
|
+
const out = {
|
|
70686
|
+
subject: VocabularyRecordRefFromFrontToApi(record.subject),
|
|
70687
|
+
note_kind: record.noteKind
|
|
70688
|
+
};
|
|
70689
|
+
if (record.recordId !== void 0) out.record_id = record.recordId;
|
|
70690
|
+
if (record.clientRef !== void 0) out.client_ref = record.clientRef;
|
|
70691
|
+
if (record.text !== void 0) out.text = record.text;
|
|
70692
|
+
if (record.resourceLocator !== void 0) out.resource_locator = record.resourceLocator;
|
|
70693
|
+
if (record.language !== void 0) out.language = record.language;
|
|
70694
|
+
if (record.evidence !== void 0) {
|
|
70695
|
+
out.evidence = VocabularyRecordRefFromFrontToApi(record.evidence);
|
|
70696
|
+
}
|
|
70697
|
+
return out;
|
|
70698
|
+
}
|
|
70699
|
+
function CollectionInputFromFrontToApi(record) {
|
|
70700
|
+
const out = {
|
|
70701
|
+
scheme: VocabularyRecordRefFromFrontToApi(record.scheme),
|
|
70702
|
+
ordered: record.ordered,
|
|
70703
|
+
status: record.status
|
|
70704
|
+
};
|
|
70705
|
+
if (record.recordId !== void 0) out.record_id = record.recordId;
|
|
70706
|
+
if (record.clientRef !== void 0) out.client_ref = record.clientRef;
|
|
70707
|
+
return out;
|
|
70708
|
+
}
|
|
70709
|
+
function CollectionMemberInputFromFrontToApi(record) {
|
|
70710
|
+
const out = {
|
|
70711
|
+
collection: VocabularyRecordRefFromFrontToApi(record.collection),
|
|
70712
|
+
member: VocabularyRecordRefFromFrontToApi(record.member)
|
|
70713
|
+
};
|
|
70714
|
+
if (record.recordId !== void 0) out.record_id = record.recordId;
|
|
70715
|
+
if (record.clientRef !== void 0) out.client_ref = record.clientRef;
|
|
70716
|
+
if (record.position !== void 0) out.position = record.position;
|
|
70717
|
+
return out;
|
|
70718
|
+
}
|
|
69298
70719
|
function VocabularyRecordInputFromFrontToApi(record) {
|
|
69299
70720
|
switch (record.kind) {
|
|
69300
70721
|
case "scheme":
|
|
@@ -69338,6 +70759,55 @@ function VocabularyRecordInputFromFrontToApi(record) {
|
|
|
69338
70759
|
return { kind: "identity_decision", ...IdentityDecisionInputFromFrontToApi(record) };
|
|
69339
70760
|
case "aboutness":
|
|
69340
70761
|
return { kind: "aboutness", ...AboutnessInputFromFrontToApi(record) };
|
|
70762
|
+
case "concept_relation":
|
|
70763
|
+
return { kind: "concept_relation", ...ConceptRelationInputFromFrontToApi(record) };
|
|
70764
|
+
case "taxonomy_policy":
|
|
70765
|
+
return { kind: "taxonomy_policy", ...TaxonomyPolicyInputFromFrontToApi(record) };
|
|
70766
|
+
case "external_concept":
|
|
70767
|
+
return { kind: "external_concept", ...ExternalConceptInputFromFrontToApi(record) };
|
|
70768
|
+
case "concept_mapping":
|
|
70769
|
+
return { kind: "concept_mapping", ...ConceptMappingInputFromFrontToApi(record) };
|
|
70770
|
+
case "documentation":
|
|
70771
|
+
return { kind: "documentation", ...DocumentationInputFromFrontToApi(record) };
|
|
70772
|
+
case "notation": {
|
|
70773
|
+
const out = {
|
|
70774
|
+
kind: "notation",
|
|
70775
|
+
concept: VocabularyRecordRefFromFrontToApi(record.concept),
|
|
70776
|
+
scheme: VocabularyRecordRefFromFrontToApi(record.scheme),
|
|
70777
|
+
value: record.value
|
|
70778
|
+
};
|
|
70779
|
+
if (record.datatype !== void 0) out.datatype = record.datatype;
|
|
70780
|
+
return out;
|
|
70781
|
+
}
|
|
70782
|
+
case "xl_label":
|
|
70783
|
+
return {
|
|
70784
|
+
kind: "xl_label",
|
|
70785
|
+
concept: VocabularyRecordRefFromFrontToApi(record.concept),
|
|
70786
|
+
scheme: VocabularyRecordRefFromFrontToApi(record.scheme),
|
|
70787
|
+
resource_key: record.resourceKey,
|
|
70788
|
+
text: record.text,
|
|
70789
|
+
language: record.language,
|
|
70790
|
+
role: record.role
|
|
70791
|
+
};
|
|
70792
|
+
case "label_relation":
|
|
70793
|
+
return {
|
|
70794
|
+
kind: "label_relation",
|
|
70795
|
+
subject: VocabularyRecordRefFromFrontToApi(record.subject),
|
|
70796
|
+
object: VocabularyRecordRefFromFrontToApi(record.object),
|
|
70797
|
+
relation: record.relation
|
|
70798
|
+
};
|
|
70799
|
+
case "collection":
|
|
70800
|
+
return { kind: "collection", ...CollectionInputFromFrontToApi(record) };
|
|
70801
|
+
case "collection_label":
|
|
70802
|
+
return {
|
|
70803
|
+
kind: "collection_label",
|
|
70804
|
+
collection: VocabularyRecordRefFromFrontToApi(record.collection),
|
|
70805
|
+
text: record.text,
|
|
70806
|
+
language: record.language,
|
|
70807
|
+
role: record.role
|
|
70808
|
+
};
|
|
70809
|
+
case "collection_member":
|
|
70810
|
+
return { kind: "collection_member", ...CollectionMemberInputFromFrontToApi(record) };
|
|
69341
70811
|
}
|
|
69342
70812
|
}
|
|
69343
70813
|
function VocabularyRecordOperationFromFrontToApi(operation) {
|
|
@@ -69445,6 +70915,79 @@ function ActivateVocabularyReleaseRequestFromFrontToApi(request) {
|
|
|
69445
70915
|
if (request.rationale !== void 0) out.rationale = request.rationale;
|
|
69446
70916
|
return out;
|
|
69447
70917
|
}
|
|
70918
|
+
function VocabularyImportTargetSchemeFromFrontToApi(target) {
|
|
70919
|
+
return "existing" in target ? { existing: { scheme_id: target.existing.schemeId } } : { new: { scheme: SchemeInputFromFrontToApi(target.new.scheme) } };
|
|
70920
|
+
}
|
|
70921
|
+
function ExternalAuthorityFromFrontToApi(authority) {
|
|
70922
|
+
return {
|
|
70923
|
+
iri_prefix: authority.iriPrefix,
|
|
70924
|
+
authority: authority.authority,
|
|
70925
|
+
dataset_version: authority.datasetVersion
|
|
70926
|
+
};
|
|
70927
|
+
}
|
|
70928
|
+
function CreateVocabularyImportRequestFromFrontToApi(request) {
|
|
70929
|
+
const out = {
|
|
70930
|
+
source_file_id: request.sourceFileId,
|
|
70931
|
+
format: request.format,
|
|
70932
|
+
dataset: request.dataset,
|
|
70933
|
+
target_scheme: VocabularyImportTargetSchemeFromFrontToApi(request.targetScheme)
|
|
70934
|
+
};
|
|
70935
|
+
if (request.schemeMap !== void 0) out.scheme_map = request.schemeMap;
|
|
70936
|
+
if (request.defaultLanguage !== void 0) out.default_language = request.defaultLanguage;
|
|
70937
|
+
if (request.externalAuthorities !== void 0) {
|
|
70938
|
+
out.external_authorities = request.externalAuthorities.map(ExternalAuthorityFromFrontToApi);
|
|
70939
|
+
}
|
|
70940
|
+
if (request.attribution !== void 0) out.attribution = request.attribution;
|
|
70941
|
+
if (request.license !== void 0) out.license = request.license;
|
|
70942
|
+
return out;
|
|
70943
|
+
}
|
|
70944
|
+
function ResourceDecisionFromFrontToApi(decision) {
|
|
70945
|
+
const out = {
|
|
70946
|
+
source_key: decision.sourceKey,
|
|
70947
|
+
decision: decision.decision
|
|
70948
|
+
};
|
|
70949
|
+
if (decision.conceptId !== void 0) out.concept_id = decision.conceptId;
|
|
70950
|
+
if (decision.rationale !== void 0) out.rationale = decision.rationale;
|
|
70951
|
+
return out;
|
|
70952
|
+
}
|
|
70953
|
+
function CommitVocabularyImportRequestFromFrontToApi(request) {
|
|
70954
|
+
const out = { change_reason: request.changeReason };
|
|
70955
|
+
if (request.title !== void 0) out.title = request.title;
|
|
70956
|
+
if (request.candidateId !== void 0) out.candidate_id = request.candidateId;
|
|
70957
|
+
if (request.decisions !== void 0) {
|
|
70958
|
+
out.decisions = request.decisions.map(ResourceDecisionFromFrontToApi);
|
|
70959
|
+
}
|
|
70960
|
+
return out;
|
|
70961
|
+
}
|
|
70962
|
+
function PlannedDispositionFromFrontToApi(disposition) {
|
|
70963
|
+
return {
|
|
70964
|
+
sort_id: disposition.sortId,
|
|
70965
|
+
disposition: disposition.disposition,
|
|
70966
|
+
rationale: disposition.rationale
|
|
70967
|
+
};
|
|
70968
|
+
}
|
|
70969
|
+
function CreateVocabularyMigrationPlanRequestFromFrontToApi(request) {
|
|
70970
|
+
return { dispositions: request.dispositions.map(PlannedDispositionFromFrontToApi) };
|
|
70971
|
+
}
|
|
70972
|
+
function ApplyVocabularyMigrationPlanRequestFromFrontToApi(request) {
|
|
70973
|
+
const out = {
|
|
70974
|
+
title: request.title,
|
|
70975
|
+
change_reason: request.changeReason,
|
|
70976
|
+
scheme: VocabularyImportTargetSchemeFromFrontToApi(request.scheme)
|
|
70977
|
+
};
|
|
70978
|
+
if (request.defaultLanguage !== void 0) out.default_language = request.defaultLanguage;
|
|
70979
|
+
return out;
|
|
70980
|
+
}
|
|
70981
|
+
function VocabularySparqlRequestFromFrontToApi(request) {
|
|
70982
|
+
const out = { query: request.query, scheme_id: request.schemeId };
|
|
70983
|
+
if (request.view !== void 0) {
|
|
70984
|
+
out.view = request.view.view;
|
|
70985
|
+
if (request.view.view === "release") out.release_id = request.view.releaseId;
|
|
70986
|
+
if (request.view.view === "candidate") out.revision_id = request.view.revisionId;
|
|
70987
|
+
}
|
|
70988
|
+
if (request.maxResults !== void 0) out.max_results = request.maxResults;
|
|
70989
|
+
return out;
|
|
70990
|
+
}
|
|
69448
70991
|
function VocabularySchemeRecordFromApiToFront(dto) {
|
|
69449
70992
|
const out = {
|
|
69450
70993
|
recordId: dto.record_id,
|
|
@@ -69600,6 +71143,186 @@ function VocabularyAboutnessRecordFromApiToFront(dto) {
|
|
|
69600
71143
|
if (present(dto.evidence)) out.evidence = dto.evidence;
|
|
69601
71144
|
return out;
|
|
69602
71145
|
}
|
|
71146
|
+
function VocabularyConceptRelationRecordFromApiToFront(dto) {
|
|
71147
|
+
const out = {
|
|
71148
|
+
recordId: dto.record_id,
|
|
71149
|
+
revision: dto.revision,
|
|
71150
|
+
changeReason: dto.change_reason,
|
|
71151
|
+
scheme: dto.scheme,
|
|
71152
|
+
subject: dto.subject,
|
|
71153
|
+
object: dto.object,
|
|
71154
|
+
relation: dto.relation,
|
|
71155
|
+
status: dto.status
|
|
71156
|
+
};
|
|
71157
|
+
if (present(dto.hierarchy_kind)) out.hierarchyKind = dto.hierarchy_kind;
|
|
71158
|
+
if (present(dto.evidence)) out.evidence = dto.evidence;
|
|
71159
|
+
return out;
|
|
71160
|
+
}
|
|
71161
|
+
function VocabularyTaxonomyPolicyRecordFromApiToFront(dto) {
|
|
71162
|
+
const out = {
|
|
71163
|
+
recordId: dto.record_id,
|
|
71164
|
+
revision: dto.revision,
|
|
71165
|
+
changeReason: dto.change_reason,
|
|
71166
|
+
scheme: dto.scheme,
|
|
71167
|
+
policy: dto.policy,
|
|
71168
|
+
acyclic: dto.acyclic,
|
|
71169
|
+
requirePlacement: dto.require_placement,
|
|
71170
|
+
topConcepts: dto.top_concepts
|
|
71171
|
+
};
|
|
71172
|
+
if (present(dto.max_depth)) out.maxDepth = dto.max_depth;
|
|
71173
|
+
if (present(dto.partitive_transitive)) out.partitiveTransitive = dto.partitive_transitive;
|
|
71174
|
+
return out;
|
|
71175
|
+
}
|
|
71176
|
+
function VocabularyExternalConceptRecordFromApiToFront(dto) {
|
|
71177
|
+
const out = {
|
|
71178
|
+
recordId: dto.record_id,
|
|
71179
|
+
revision: dto.revision,
|
|
71180
|
+
changeReason: dto.change_reason,
|
|
71181
|
+
authority: dto.authority,
|
|
71182
|
+
datasetVersion: dto.dataset_version,
|
|
71183
|
+
iri: dto.iri,
|
|
71184
|
+
resolution: dto.resolution
|
|
71185
|
+
};
|
|
71186
|
+
if (present(dto.label_text)) out.labelText = dto.label_text;
|
|
71187
|
+
if (present(dto.label_language)) out.labelLanguage = dto.label_language;
|
|
71188
|
+
if (present(dto.evidence)) out.evidence = dto.evidence;
|
|
71189
|
+
return out;
|
|
71190
|
+
}
|
|
71191
|
+
function VocabularyConceptMappingRecordFromApiToFront(dto) {
|
|
71192
|
+
const out = {
|
|
71193
|
+
recordId: dto.record_id,
|
|
71194
|
+
revision: dto.revision,
|
|
71195
|
+
changeReason: dto.change_reason,
|
|
71196
|
+
subject: dto.subject,
|
|
71197
|
+
mappingKind: dto.mapping_kind,
|
|
71198
|
+
status: dto.status
|
|
71199
|
+
};
|
|
71200
|
+
if (present(dto.target_concept)) out.targetConcept = dto.target_concept;
|
|
71201
|
+
if (present(dto.target_external)) out.targetExternal = dto.target_external;
|
|
71202
|
+
if (present(dto.evidence)) out.evidence = dto.evidence;
|
|
71203
|
+
return out;
|
|
71204
|
+
}
|
|
71205
|
+
function VocabularyDocumentationRecordFromApiToFront(dto) {
|
|
71206
|
+
const out = {
|
|
71207
|
+
recordId: dto.record_id,
|
|
71208
|
+
revision: dto.revision,
|
|
71209
|
+
changeReason: dto.change_reason,
|
|
71210
|
+
noteKind: dto.note_kind
|
|
71211
|
+
};
|
|
71212
|
+
if (present(dto.concept)) out.concept = dto.concept;
|
|
71213
|
+
if (present(dto.scheme)) out.scheme = dto.scheme;
|
|
71214
|
+
if (present(dto.collection)) out.collection = dto.collection;
|
|
71215
|
+
if (present(dto.text)) out.text = dto.text;
|
|
71216
|
+
if (present(dto.resource_locator)) out.resourceLocator = dto.resource_locator;
|
|
71217
|
+
if (present(dto.language)) out.language = dto.language;
|
|
71218
|
+
if (present(dto.language_as_submitted)) out.languageAsSubmitted = dto.language_as_submitted;
|
|
71219
|
+
if (present(dto.evidence)) out.evidence = dto.evidence;
|
|
71220
|
+
return out;
|
|
71221
|
+
}
|
|
71222
|
+
function VocabularyNotationRecordFromApiToFront(dto) {
|
|
71223
|
+
const out = {
|
|
71224
|
+
recordId: dto.record_id,
|
|
71225
|
+
concept: dto.concept,
|
|
71226
|
+
scheme: dto.scheme,
|
|
71227
|
+
value: dto.value
|
|
71228
|
+
};
|
|
71229
|
+
if (present(dto.datatype)) out.datatype = dto.datatype;
|
|
71230
|
+
return out;
|
|
71231
|
+
}
|
|
71232
|
+
function VocabularyXlLabelRecordFromApiToFront(dto) {
|
|
71233
|
+
return {
|
|
71234
|
+
recordId: dto.record_id,
|
|
71235
|
+
revision: dto.revision,
|
|
71236
|
+
changeReason: dto.change_reason,
|
|
71237
|
+
concept: dto.concept,
|
|
71238
|
+
scheme: dto.scheme,
|
|
71239
|
+
resourceKey: dto.resource_key,
|
|
71240
|
+
label: dto.label,
|
|
71241
|
+
role: dto.role
|
|
71242
|
+
};
|
|
71243
|
+
}
|
|
71244
|
+
function VocabularyLabelRelationRecordFromApiToFront(dto) {
|
|
71245
|
+
return {
|
|
71246
|
+
recordId: dto.record_id,
|
|
71247
|
+
subject: dto.subject,
|
|
71248
|
+
object: dto.object,
|
|
71249
|
+
relation: dto.relation
|
|
71250
|
+
};
|
|
71251
|
+
}
|
|
71252
|
+
function VocabularyCollectionRecordFromApiToFront(dto) {
|
|
71253
|
+
return {
|
|
71254
|
+
recordId: dto.record_id,
|
|
71255
|
+
revision: dto.revision,
|
|
71256
|
+
changeReason: dto.change_reason,
|
|
71257
|
+
scheme: dto.scheme,
|
|
71258
|
+
ordered: dto.ordered,
|
|
71259
|
+
status: dto.status
|
|
71260
|
+
};
|
|
71261
|
+
}
|
|
71262
|
+
function VocabularyCollectionLabelRecordFromApiToFront(dto) {
|
|
71263
|
+
return {
|
|
71264
|
+
recordId: dto.record_id,
|
|
71265
|
+
collection: dto.collection,
|
|
71266
|
+
label: dto.label,
|
|
71267
|
+
role: dto.role
|
|
71268
|
+
};
|
|
71269
|
+
}
|
|
71270
|
+
function VocabularyCollectionMemberRecordFromApiToFront(dto) {
|
|
71271
|
+
const out = {
|
|
71272
|
+
recordId: dto.record_id,
|
|
71273
|
+
revision: dto.revision,
|
|
71274
|
+
changeReason: dto.change_reason,
|
|
71275
|
+
collection: dto.collection
|
|
71276
|
+
};
|
|
71277
|
+
if (present(dto.member_concept)) out.memberConcept = dto.member_concept;
|
|
71278
|
+
if (present(dto.member_collection)) out.memberCollection = dto.member_collection;
|
|
71279
|
+
if (present(dto.position)) out.position = dto.position;
|
|
71280
|
+
return out;
|
|
71281
|
+
}
|
|
71282
|
+
function VocabularySourceArtifactRecordFromApiToFront(dto) {
|
|
71283
|
+
const out = {
|
|
71284
|
+
recordId: dto.record_id,
|
|
71285
|
+
sha256: dto.sha256,
|
|
71286
|
+
byteSize: dto.byte_size,
|
|
71287
|
+
format: dto.format,
|
|
71288
|
+
dataset: dto.dataset,
|
|
71289
|
+
retainedLocator: dto.retained_locator
|
|
71290
|
+
};
|
|
71291
|
+
if (present(dto.file_name)) out.fileName = dto.file_name;
|
|
71292
|
+
if (present(dto.media_type)) out.mediaType = dto.media_type;
|
|
71293
|
+
if (present(dto.attribution)) out.attribution = dto.attribution;
|
|
71294
|
+
if (present(dto.license)) out.license = dto.license;
|
|
71295
|
+
if (present(dto.retrieval_context)) out.retrievalContext = dto.retrieval_context;
|
|
71296
|
+
return out;
|
|
71297
|
+
}
|
|
71298
|
+
function VocabularySourceAssociationRecordFromApiToFront(dto) {
|
|
71299
|
+
const out = {
|
|
71300
|
+
recordId: dto.record_id,
|
|
71301
|
+
revision: dto.revision,
|
|
71302
|
+
changeReason: dto.change_reason,
|
|
71303
|
+
artifact: dto.artifact,
|
|
71304
|
+
sourceKey: dto.source_key
|
|
71305
|
+
};
|
|
71306
|
+
if (present(dto.concept)) out.concept = dto.concept;
|
|
71307
|
+
if (present(dto.collection)) out.collection = dto.collection;
|
|
71308
|
+
if (present(dto.external_concept)) out.externalConcept = dto.external_concept;
|
|
71309
|
+
return out;
|
|
71310
|
+
}
|
|
71311
|
+
function VocabularyMigrationDecisionRecordFromApiToFront(dto) {
|
|
71312
|
+
const out = {
|
|
71313
|
+
recordId: dto.record_id,
|
|
71314
|
+
revision: dto.revision,
|
|
71315
|
+
changeReason: dto.change_reason,
|
|
71316
|
+
plan: dto.plan,
|
|
71317
|
+
legacySort: dto.legacy_sort,
|
|
71318
|
+
legacySortName: dto.legacy_sort_name,
|
|
71319
|
+
fingerprint: dto.fingerprint,
|
|
71320
|
+
disposition: dto.disposition,
|
|
71321
|
+
rationale: dto.rationale
|
|
71322
|
+
};
|
|
71323
|
+
if (present(dto.concept)) out.concept = dto.concept;
|
|
71324
|
+
return out;
|
|
71325
|
+
}
|
|
69603
71326
|
function VocabularyRecordViewFromApiToFront(dto) {
|
|
69604
71327
|
switch (dto.kind) {
|
|
69605
71328
|
case "scheme":
|
|
@@ -69634,6 +71357,40 @@ function VocabularyRecordViewFromApiToFront(dto) {
|
|
|
69634
71357
|
};
|
|
69635
71358
|
case "aboutness":
|
|
69636
71359
|
return { kind: "aboutness", ...VocabularyAboutnessRecordFromApiToFront(dto) };
|
|
71360
|
+
case "concept_relation":
|
|
71361
|
+
return { kind: "concept_relation", ...VocabularyConceptRelationRecordFromApiToFront(dto) };
|
|
71362
|
+
case "taxonomy_policy":
|
|
71363
|
+
return { kind: "taxonomy_policy", ...VocabularyTaxonomyPolicyRecordFromApiToFront(dto) };
|
|
71364
|
+
case "external_concept":
|
|
71365
|
+
return { kind: "external_concept", ...VocabularyExternalConceptRecordFromApiToFront(dto) };
|
|
71366
|
+
case "concept_mapping":
|
|
71367
|
+
return { kind: "concept_mapping", ...VocabularyConceptMappingRecordFromApiToFront(dto) };
|
|
71368
|
+
case "documentation":
|
|
71369
|
+
return { kind: "documentation", ...VocabularyDocumentationRecordFromApiToFront(dto) };
|
|
71370
|
+
case "notation":
|
|
71371
|
+
return { kind: "notation", ...VocabularyNotationRecordFromApiToFront(dto) };
|
|
71372
|
+
case "xl_label":
|
|
71373
|
+
return { kind: "xl_label", ...VocabularyXlLabelRecordFromApiToFront(dto) };
|
|
71374
|
+
case "label_relation":
|
|
71375
|
+
return { kind: "label_relation", ...VocabularyLabelRelationRecordFromApiToFront(dto) };
|
|
71376
|
+
case "collection":
|
|
71377
|
+
return { kind: "collection", ...VocabularyCollectionRecordFromApiToFront(dto) };
|
|
71378
|
+
case "collection_label":
|
|
71379
|
+
return { kind: "collection_label", ...VocabularyCollectionLabelRecordFromApiToFront(dto) };
|
|
71380
|
+
case "collection_member":
|
|
71381
|
+
return { kind: "collection_member", ...VocabularyCollectionMemberRecordFromApiToFront(dto) };
|
|
71382
|
+
case "source_artifact":
|
|
71383
|
+
return { kind: "source_artifact", ...VocabularySourceArtifactRecordFromApiToFront(dto) };
|
|
71384
|
+
case "source_association":
|
|
71385
|
+
return {
|
|
71386
|
+
kind: "source_association",
|
|
71387
|
+
...VocabularySourceAssociationRecordFromApiToFront(dto)
|
|
71388
|
+
};
|
|
71389
|
+
case "migration_decision":
|
|
71390
|
+
return {
|
|
71391
|
+
kind: "migration_decision",
|
|
71392
|
+
...VocabularyMigrationDecisionRecordFromApiToFront(dto)
|
|
71393
|
+
};
|
|
69637
71394
|
}
|
|
69638
71395
|
}
|
|
69639
71396
|
function FindingContextFromApiToFront(dto) {
|
|
@@ -69765,7 +71522,8 @@ function SchemeViewFromApiToFront(dto) {
|
|
|
69765
71522
|
revision: dto.revision,
|
|
69766
71523
|
displayName: dto.display_name,
|
|
69767
71524
|
purpose: dto.purpose,
|
|
69768
|
-
languages: dto.languages.map(SchemeLanguageViewFromApiToFront)
|
|
71525
|
+
languages: dto.languages.map(SchemeLanguageViewFromApiToFront),
|
|
71526
|
+
documentation: dto.documentation.map(VocabularyDocumentationRecordFromApiToFront)
|
|
69769
71527
|
};
|
|
69770
71528
|
if (present(dto.scope_note)) out.scopeNote = dto.scope_note;
|
|
69771
71529
|
if (present(dto.exclusions)) out.exclusions = dto.exclusions;
|
|
@@ -69850,6 +71608,38 @@ function DefinitionGuidanceFromApiToFront(dto) {
|
|
|
69850
71608
|
parentEdgeCreated: dto.parent_edge_created
|
|
69851
71609
|
};
|
|
69852
71610
|
}
|
|
71611
|
+
function LabelRelationViewFromApiToFront(dto) {
|
|
71612
|
+
const out = {
|
|
71613
|
+
...VocabularyLabelRelationRecordFromApiToFront(dto),
|
|
71614
|
+
otherXlLabelId: dto.other_xl_label_id
|
|
71615
|
+
};
|
|
71616
|
+
if (present(dto.other_resource_key)) out.otherResourceKey = dto.other_resource_key;
|
|
71617
|
+
if (present(dto.other_text)) out.otherText = dto.other_text;
|
|
71618
|
+
if (present(dto.other_language)) out.otherLanguage = dto.other_language;
|
|
71619
|
+
return out;
|
|
71620
|
+
}
|
|
71621
|
+
function XlLabelViewFromApiToFront(dto) {
|
|
71622
|
+
const out = {
|
|
71623
|
+
...VocabularyXlLabelRecordFromApiToFront(dto),
|
|
71624
|
+
outgoingRelations: dto.outgoing_relations.map(LabelRelationViewFromApiToFront),
|
|
71625
|
+
incomingRelations: dto.incoming_relations.map(LabelRelationViewFromApiToFront)
|
|
71626
|
+
};
|
|
71627
|
+
if (present(dto.text)) out.text = dto.text;
|
|
71628
|
+
if (present(dto.language)) out.language = dto.language;
|
|
71629
|
+
return out;
|
|
71630
|
+
}
|
|
71631
|
+
function ConceptMappingViewFromApiToFront(dto) {
|
|
71632
|
+
const out = VocabularyConceptMappingRecordFromApiToFront(dto);
|
|
71633
|
+
if (present(dto.target_external_concept)) {
|
|
71634
|
+
out.targetExternalConcept = VocabularyExternalConceptRecordFromApiToFront(
|
|
71635
|
+
dto.target_external_concept
|
|
71636
|
+
);
|
|
71637
|
+
}
|
|
71638
|
+
if (present(dto.target_display_label)) {
|
|
71639
|
+
out.targetDisplayLabel = VocabularyDisplayLabelFromApiToFront(dto.target_display_label);
|
|
71640
|
+
}
|
|
71641
|
+
return out;
|
|
71642
|
+
}
|
|
69853
71643
|
function ConceptViewFromApiToFront(dto) {
|
|
69854
71644
|
const out = {
|
|
69855
71645
|
concept: VocabularyConceptRecordFromApiToFront(dto.concept),
|
|
@@ -69862,7 +71652,16 @@ function ConceptViewFromApiToFront(dto) {
|
|
|
69862
71652
|
authorityReferences: dto.authority_references.map(
|
|
69863
71653
|
VocabularyAuthorityReferenceRecordFromApiToFront
|
|
69864
71654
|
),
|
|
69865
|
-
aboutness: dto.aboutness.map(VocabularyAboutnessRecordFromApiToFront)
|
|
71655
|
+
aboutness: dto.aboutness.map(VocabularyAboutnessRecordFromApiToFront),
|
|
71656
|
+
relations: dto.relations.map(VocabularyConceptRelationRecordFromApiToFront),
|
|
71657
|
+
mappings: dto.mappings.map(ConceptMappingViewFromApiToFront),
|
|
71658
|
+
documentation: dto.documentation.map(VocabularyDocumentationRecordFromApiToFront),
|
|
71659
|
+
notations: dto.notations.map(VocabularyNotationRecordFromApiToFront),
|
|
71660
|
+
xlLabels: dto.xl_labels.map(XlLabelViewFromApiToFront),
|
|
71661
|
+
collections: dto.collections,
|
|
71662
|
+
sourceAssociations: dto.source_associations.map(
|
|
71663
|
+
VocabularySourceAssociationRecordFromApiToFront
|
|
71664
|
+
)
|
|
69866
71665
|
};
|
|
69867
71666
|
if (present(dto.display_label)) {
|
|
69868
71667
|
out.displayLabel = VocabularyDisplayLabelFromApiToFront(dto.display_label);
|
|
@@ -70170,6 +71969,12 @@ function isReleaseBody(value) {
|
|
|
70170
71969
|
function isActivationBody(value) {
|
|
70171
71970
|
return componentFault(value, "ActivationResponse", "body") === void 0;
|
|
70172
71971
|
}
|
|
71972
|
+
function isImportBody(value) {
|
|
71973
|
+
return componentFault(value, "VocabularyImportResponse", "body") === void 0;
|
|
71974
|
+
}
|
|
71975
|
+
function isMigrationPlanBody(value) {
|
|
71976
|
+
return componentFault(value, "MigrationPlanResponse", "body") === void 0;
|
|
71977
|
+
}
|
|
70173
71978
|
var COMMITTED_COMPONENT = {
|
|
70174
71979
|
create_candidate: "CandidateRevisionResponse",
|
|
70175
71980
|
save_revision: "CandidateRevisionResponse",
|
|
@@ -70181,13 +71986,19 @@ var COMMITTED_COMPONENT = {
|
|
|
70181
71986
|
reject: "DecisionResponse",
|
|
70182
71987
|
withdraw: "DecisionResponse",
|
|
70183
71988
|
release: "ReleaseResponse",
|
|
70184
|
-
activate: "ActivationResponse"
|
|
71989
|
+
activate: "ActivationResponse",
|
|
71990
|
+
create_import: "VocabularyImportResponse",
|
|
71991
|
+
commit_import: "CandidateRevisionResponse",
|
|
71992
|
+
create_migration_plan: "MigrationPlanResponse",
|
|
71993
|
+
apply_migration_plan: "CandidateRevisionResponse"
|
|
70185
71994
|
};
|
|
70186
71995
|
function CommittedResultFromApiToFront(operation, body) {
|
|
70187
71996
|
switch (operation) {
|
|
70188
71997
|
case "create_candidate":
|
|
70189
71998
|
case "save_revision":
|
|
70190
71999
|
case "rebase":
|
|
72000
|
+
case "commit_import":
|
|
72001
|
+
case "apply_migration_plan":
|
|
70191
72002
|
if (isCandidateRevisionBody(body)) {
|
|
70192
72003
|
return { operation, body: VocabularyCandidateRevisionFromApiToFront(body) };
|
|
70193
72004
|
}
|
|
@@ -70216,6 +72027,16 @@ function CommittedResultFromApiToFront(operation, body) {
|
|
|
70216
72027
|
return { operation, body: VocabularyActivationResultFromApiToFront(body) };
|
|
70217
72028
|
}
|
|
70218
72029
|
break;
|
|
72030
|
+
case "create_import":
|
|
72031
|
+
if (isImportBody(body)) {
|
|
72032
|
+
return { operation, body: VocabularyImportFromApiToFront(body) };
|
|
72033
|
+
}
|
|
72034
|
+
break;
|
|
72035
|
+
case "create_migration_plan":
|
|
72036
|
+
if (isMigrationPlanBody(body)) {
|
|
72037
|
+
return { operation, body: VocabularyMigrationPlanFromApiToFront(body) };
|
|
72038
|
+
}
|
|
72039
|
+
break;
|
|
70219
72040
|
}
|
|
70220
72041
|
throw new TypeError(
|
|
70221
72042
|
componentFault(body, COMMITTED_COMPONENT[operation], "body") ?? `body is not a ${COMMITTED_COMPONENT[operation]}`
|
|
@@ -70298,6 +72119,568 @@ function VocabularyMigrationPreviewFromApiToFront(dto) {
|
|
|
70298
72119
|
if (present(dto.next_cursor)) out.nextCursor = dto.next_cursor;
|
|
70299
72120
|
return out;
|
|
70300
72121
|
}
|
|
72122
|
+
function HierarchyNodeFromApiToFront(dto) {
|
|
72123
|
+
const out = {
|
|
72124
|
+
conceptId: dto.concept_id,
|
|
72125
|
+
depth: dto.depth,
|
|
72126
|
+
via: dto.via
|
|
72127
|
+
};
|
|
72128
|
+
if (present(dto.display_label)) {
|
|
72129
|
+
out.displayLabel = VocabularyDisplayLabelFromApiToFront(dto.display_label);
|
|
72130
|
+
}
|
|
72131
|
+
return out;
|
|
72132
|
+
}
|
|
72133
|
+
function HierarchyEdgeFromApiToFront(dto) {
|
|
72134
|
+
const out = {
|
|
72135
|
+
relationId: dto.relation_id,
|
|
72136
|
+
subject: dto.subject,
|
|
72137
|
+
object: dto.object,
|
|
72138
|
+
status: dto.status
|
|
72139
|
+
};
|
|
72140
|
+
if (present(dto.hierarchy_kind)) out.hierarchyKind = dto.hierarchy_kind;
|
|
72141
|
+
return out;
|
|
72142
|
+
}
|
|
72143
|
+
function VocabularyHierarchyFromApiToFront(dto) {
|
|
72144
|
+
const out = {
|
|
72145
|
+
view: ViewRefFromApiToFront(dto.view),
|
|
72146
|
+
schemeId: dto.scheme_id,
|
|
72147
|
+
direction: dto.direction,
|
|
72148
|
+
transitive: dto.transitive,
|
|
72149
|
+
nodes: dto.nodes.map(HierarchyNodeFromApiToFront),
|
|
72150
|
+
edges: dto.edges.map(HierarchyEdgeFromApiToFront),
|
|
72151
|
+
complete: dto.complete
|
|
72152
|
+
};
|
|
72153
|
+
if (present(dto.context)) out.context = VocabularyContextRefFromApiToFront(dto.context);
|
|
72154
|
+
if (present(dto.root)) out.root = dto.root;
|
|
72155
|
+
if (present(dto.stop_reason)) out.stopReason = dto.stop_reason;
|
|
72156
|
+
return out;
|
|
72157
|
+
}
|
|
72158
|
+
function VocabularyHierarchyPathsFromApiToFront(dto) {
|
|
72159
|
+
const out = {
|
|
72160
|
+
view: ViewRefFromApiToFront(dto.view),
|
|
72161
|
+
schemeId: dto.scheme_id,
|
|
72162
|
+
from: dto.from,
|
|
72163
|
+
to: dto.to,
|
|
72164
|
+
paths: dto.paths,
|
|
72165
|
+
complete: dto.complete
|
|
72166
|
+
};
|
|
72167
|
+
if (present(dto.context)) out.context = VocabularyContextRefFromApiToFront(dto.context);
|
|
72168
|
+
if (present(dto.stop_reason)) out.stopReason = dto.stop_reason;
|
|
72169
|
+
return out;
|
|
72170
|
+
}
|
|
72171
|
+
function VocabularyTopConceptsFromApiToFront(dto) {
|
|
72172
|
+
const out = {
|
|
72173
|
+
view: ViewRefFromApiToFront(dto.view),
|
|
72174
|
+
schemeId: dto.scheme_id,
|
|
72175
|
+
concepts: dto.concepts.map(ConceptSummaryFromApiToFront)
|
|
72176
|
+
};
|
|
72177
|
+
if (present(dto.context)) out.context = VocabularyContextRefFromApiToFront(dto.context);
|
|
72178
|
+
return out;
|
|
72179
|
+
}
|
|
72180
|
+
function VocabularyTaxonomyPolicyFromApiToFront(dto) {
|
|
72181
|
+
const out = {
|
|
72182
|
+
view: ViewRefFromApiToFront(dto.view),
|
|
72183
|
+
schemeId: dto.scheme_id,
|
|
72184
|
+
declared: dto.declared,
|
|
72185
|
+
policy: dto.policy,
|
|
72186
|
+
acyclic: dto.acyclic,
|
|
72187
|
+
requirePlacement: dto.require_placement,
|
|
72188
|
+
topConcepts: dto.top_concepts
|
|
72189
|
+
};
|
|
72190
|
+
if (present(dto.context)) out.context = VocabularyContextRefFromApiToFront(dto.context);
|
|
72191
|
+
if (present(dto.record_id)) out.recordId = dto.record_id;
|
|
72192
|
+
if (present(dto.revision)) out.revision = dto.revision;
|
|
72193
|
+
if (present(dto.change_reason)) out.changeReason = dto.change_reason;
|
|
72194
|
+
if (present(dto.max_depth)) out.maxDepth = dto.max_depth;
|
|
72195
|
+
if (present(dto.partitive_transitive)) out.partitiveTransitive = dto.partitive_transitive;
|
|
72196
|
+
return out;
|
|
72197
|
+
}
|
|
72198
|
+
function ConceptRelationEntryFromApiToFront(dto) {
|
|
72199
|
+
const out = {
|
|
72200
|
+
relationId: dto.relation_id,
|
|
72201
|
+
relation: dto.relation,
|
|
72202
|
+
conceptId: dto.concept_id,
|
|
72203
|
+
status: dto.status
|
|
72204
|
+
};
|
|
72205
|
+
if (present(dto.display_label)) {
|
|
72206
|
+
out.displayLabel = VocabularyDisplayLabelFromApiToFront(dto.display_label);
|
|
72207
|
+
}
|
|
72208
|
+
if (present(dto.hierarchy_kind)) out.hierarchyKind = dto.hierarchy_kind;
|
|
72209
|
+
if (present(dto.evidence)) out.evidence = dto.evidence;
|
|
72210
|
+
return out;
|
|
72211
|
+
}
|
|
72212
|
+
function VocabularyConceptRelationsFromApiToFront(dto) {
|
|
72213
|
+
const out = {
|
|
72214
|
+
view: ViewRefFromApiToFront(dto.view),
|
|
72215
|
+
conceptId: dto.concept_id,
|
|
72216
|
+
schemeId: dto.scheme_id,
|
|
72217
|
+
relation: dto.relation,
|
|
72218
|
+
relations: dto.relations.map(ConceptRelationEntryFromApiToFront)
|
|
72219
|
+
};
|
|
72220
|
+
if (present(dto.context)) out.context = VocabularyContextRefFromApiToFront(dto.context);
|
|
72221
|
+
return out;
|
|
72222
|
+
}
|
|
72223
|
+
function CollectionLabelViewFromApiToFront(dto) {
|
|
72224
|
+
const out = {
|
|
72225
|
+
collectionLabelId: dto.collection_label_id,
|
|
72226
|
+
labelId: dto.label_id,
|
|
72227
|
+
role: dto.role
|
|
72228
|
+
};
|
|
72229
|
+
if (present(dto.text)) out.text = dto.text;
|
|
72230
|
+
if (present(dto.language)) out.language = dto.language;
|
|
72231
|
+
return out;
|
|
72232
|
+
}
|
|
72233
|
+
function CollectionSummaryFromApiToFront(dto) {
|
|
72234
|
+
return {
|
|
72235
|
+
collection: VocabularyCollectionRecordFromApiToFront(dto.collection),
|
|
72236
|
+
labels: dto.labels.map(CollectionLabelViewFromApiToFront),
|
|
72237
|
+
memberCount: dto.member_count
|
|
72238
|
+
};
|
|
72239
|
+
}
|
|
72240
|
+
function VocabularyCollectionPageFromApiToFront(dto) {
|
|
72241
|
+
const out = {
|
|
72242
|
+
view: ViewRefFromApiToFront(dto.view),
|
|
72243
|
+
schemeId: dto.scheme_id,
|
|
72244
|
+
items: dto.items.map(CollectionSummaryFromApiToFront),
|
|
72245
|
+
complete: dto.complete
|
|
72246
|
+
};
|
|
72247
|
+
if (present(dto.context)) out.context = VocabularyContextRefFromApiToFront(dto.context);
|
|
72248
|
+
if (present(dto.next_cursor)) out.nextCursor = dto.next_cursor;
|
|
72249
|
+
return out;
|
|
72250
|
+
}
|
|
72251
|
+
function CollectionMemberViewFromApiToFront(dto) {
|
|
72252
|
+
const out = { occurrenceId: dto.occurrence_id };
|
|
72253
|
+
if (present(dto.member_concept)) out.memberConcept = dto.member_concept;
|
|
72254
|
+
if (present(dto.member_collection)) out.memberCollection = dto.member_collection;
|
|
72255
|
+
if (present(dto.position)) out.position = dto.position;
|
|
72256
|
+
if (present(dto.display_label)) {
|
|
72257
|
+
out.displayLabel = VocabularyDisplayLabelFromApiToFront(dto.display_label);
|
|
72258
|
+
}
|
|
72259
|
+
return out;
|
|
72260
|
+
}
|
|
72261
|
+
function VocabularyCollectionDetailFromApiToFront(dto) {
|
|
72262
|
+
const out = {
|
|
72263
|
+
view: ViewRefFromApiToFront(dto.view),
|
|
72264
|
+
collection: VocabularyCollectionRecordFromApiToFront(dto.collection),
|
|
72265
|
+
labels: dto.labels.map(CollectionLabelViewFromApiToFront),
|
|
72266
|
+
members: dto.members.map(CollectionMemberViewFromApiToFront),
|
|
72267
|
+
nestedCollections: dto.nested_collections,
|
|
72268
|
+
documentation: dto.documentation.map(VocabularyDocumentationRecordFromApiToFront)
|
|
72269
|
+
};
|
|
72270
|
+
if (present(dto.context)) out.context = VocabularyContextRefFromApiToFront(dto.context);
|
|
72271
|
+
return out;
|
|
72272
|
+
}
|
|
72273
|
+
function PicklistEntryFromApiToFront(dto) {
|
|
72274
|
+
const out = {
|
|
72275
|
+
conceptId: dto.concept_id,
|
|
72276
|
+
depth: dto.depth,
|
|
72277
|
+
otherParentRelationIds: dto.other_parent_relation_ids
|
|
72278
|
+
};
|
|
72279
|
+
if (present(dto.display_label)) {
|
|
72280
|
+
out.displayLabel = VocabularyDisplayLabelFromApiToFront(dto.display_label);
|
|
72281
|
+
}
|
|
72282
|
+
if (present(dto.parent_relation_id)) out.parentRelationId = dto.parent_relation_id;
|
|
72283
|
+
return out;
|
|
72284
|
+
}
|
|
72285
|
+
function VocabularyPicklistFromApiToFront(dto) {
|
|
72286
|
+
const out = {
|
|
72287
|
+
view: ViewRefFromApiToFront(dto.view),
|
|
72288
|
+
schemeId: dto.scheme_id,
|
|
72289
|
+
rootsFrom: dto.roots_from,
|
|
72290
|
+
roots: dto.roots,
|
|
72291
|
+
entries: dto.entries.map(PicklistEntryFromApiToFront),
|
|
72292
|
+
complete: dto.complete
|
|
72293
|
+
};
|
|
72294
|
+
if (present(dto.context)) out.context = VocabularyContextRefFromApiToFront(dto.context);
|
|
72295
|
+
if (present(dto.root)) out.root = dto.root;
|
|
72296
|
+
if (present(dto.next_cursor)) out.nextCursor = dto.next_cursor;
|
|
72297
|
+
if (present(dto.stop_reason)) out.stopReason = dto.stop_reason;
|
|
72298
|
+
return out;
|
|
72299
|
+
}
|
|
72300
|
+
function ExpandedConceptFromApiToFront(dto) {
|
|
72301
|
+
const out = { conceptId: dto.concept_id, support: dto.support };
|
|
72302
|
+
if (present(dto.depth)) out.depth = dto.depth;
|
|
72303
|
+
if (present(dto.display_label)) {
|
|
72304
|
+
out.displayLabel = VocabularyDisplayLabelFromApiToFront(dto.display_label);
|
|
72305
|
+
}
|
|
72306
|
+
return out;
|
|
72307
|
+
}
|
|
72308
|
+
function VocabularyExpansionFromApiToFront(dto) {
|
|
72309
|
+
const out = {
|
|
72310
|
+
view: ViewRefFromApiToFront(dto.view),
|
|
72311
|
+
conceptId: dto.concept_id,
|
|
72312
|
+
schemeId: dto.scheme_id,
|
|
72313
|
+
direction: dto.direction,
|
|
72314
|
+
transitive: dto.transitive,
|
|
72315
|
+
concepts: dto.concepts.map(ExpandedConceptFromApiToFront),
|
|
72316
|
+
externalConcepts: dto.external_concepts.map(
|
|
72317
|
+
(external) => ({
|
|
72318
|
+
externalConceptId: external.external_concept_id,
|
|
72319
|
+
iri: external.iri,
|
|
72320
|
+
support: external.support
|
|
72321
|
+
})
|
|
72322
|
+
),
|
|
72323
|
+
withheldRelationIds: dto.withheld_relation_ids,
|
|
72324
|
+
complete: dto.complete
|
|
72325
|
+
};
|
|
72326
|
+
if (present(dto.context)) out.context = VocabularyContextRefFromApiToFront(dto.context);
|
|
72327
|
+
if (present(dto.stop_reason)) out.stopReason = dto.stop_reason;
|
|
72328
|
+
return out;
|
|
72329
|
+
}
|
|
72330
|
+
function ReconciliationProposalFromApiToFront(dto) {
|
|
72331
|
+
switch (dto.proposal) {
|
|
72332
|
+
case "exact_source_match":
|
|
72333
|
+
return { proposal: "exact_source_match", target: dto.target };
|
|
72334
|
+
case "ambiguous":
|
|
72335
|
+
return { proposal: "ambiguous", candidates: dto.candidates };
|
|
72336
|
+
case "new":
|
|
72337
|
+
return { proposal: "new" };
|
|
72338
|
+
}
|
|
72339
|
+
}
|
|
72340
|
+
function ReconciliationEntryFromApiToFront(dto) {
|
|
72341
|
+
return {
|
|
72342
|
+
sourceKey: dto.source_key,
|
|
72343
|
+
kind: dto.kind,
|
|
72344
|
+
proposal: ReconciliationProposalFromApiToFront(dto.proposal)
|
|
72345
|
+
};
|
|
72346
|
+
}
|
|
72347
|
+
function VocabularyImportFromApiToFront(dto) {
|
|
72348
|
+
const out = {
|
|
72349
|
+
importId: dto.import_id,
|
|
72350
|
+
artifact: {
|
|
72351
|
+
sourceFileId: dto.artifact.source_file_id,
|
|
72352
|
+
sha256: dto.artifact.sha256,
|
|
72353
|
+
byteSize: dto.artifact.byte_size,
|
|
72354
|
+
format: dto.artifact.format
|
|
72355
|
+
},
|
|
72356
|
+
dataset: dto.dataset,
|
|
72357
|
+
complete: dto.complete,
|
|
72358
|
+
counts: dataMap(dto.counts),
|
|
72359
|
+
proposedRecordCounts: dataMap(dto.proposed_record_counts),
|
|
72360
|
+
reconciliation: dto.reconciliation.map(ReconciliationEntryFromApiToFront),
|
|
72361
|
+
createdBy: dto.created_by,
|
|
72362
|
+
createdAt: dto.created_at,
|
|
72363
|
+
replayed: dto.replayed
|
|
72364
|
+
};
|
|
72365
|
+
if (present(dto.stop_reason)) out.stopReason = dto.stop_reason;
|
|
72366
|
+
if (present(dto.baseline_release_id)) out.baselineReleaseId = dto.baseline_release_id;
|
|
72367
|
+
if (present(dto.committed_revision_id)) out.committedRevisionId = dto.committed_revision_id;
|
|
72368
|
+
if (present(dto.committed_at)) out.committedAt = dto.committed_at;
|
|
72369
|
+
return out;
|
|
72370
|
+
}
|
|
72371
|
+
function externalVariant(value, path) {
|
|
72372
|
+
const wire = wireObject(value, path);
|
|
72373
|
+
const entries = Object.entries(wire);
|
|
72374
|
+
const first = entries[0];
|
|
72375
|
+
if (entries.length !== 1 || first === void 0) {
|
|
72376
|
+
throw new TypeError(`${path} is not a single-variant object`);
|
|
72377
|
+
}
|
|
72378
|
+
return first;
|
|
72379
|
+
}
|
|
72380
|
+
function ImportCoordinatesFromWire(value, path) {
|
|
72381
|
+
const [variant, body] = externalVariant(value, path);
|
|
72382
|
+
const at = `${path}.${variant}`;
|
|
72383
|
+
switch (variant) {
|
|
72384
|
+
case "triple": {
|
|
72385
|
+
const wire = wireObject(body, at);
|
|
72386
|
+
return { triple: { index: wireNumber(wire.index, `${at}.index`) } };
|
|
72387
|
+
}
|
|
72388
|
+
case "text": {
|
|
72389
|
+
const wire = wireObject(body, at);
|
|
72390
|
+
return {
|
|
72391
|
+
text: {
|
|
72392
|
+
line: wireNumber(wire.line, `${at}.line`),
|
|
72393
|
+
column: wireNumber(wire.column, `${at}.column`),
|
|
72394
|
+
offset: wireNumber(wire.offset, `${at}.offset`)
|
|
72395
|
+
}
|
|
72396
|
+
};
|
|
72397
|
+
}
|
|
72398
|
+
case "row": {
|
|
72399
|
+
const wire = wireObject(body, at);
|
|
72400
|
+
const row = { row: wireNumber(wire.row, `${at}.row`) };
|
|
72401
|
+
if (present(wire.sheet)) row.sheet = wireString(wire.sheet, `${at}.sheet`);
|
|
72402
|
+
return { row };
|
|
72403
|
+
}
|
|
72404
|
+
case "cell": {
|
|
72405
|
+
const wire = wireObject(body, at);
|
|
72406
|
+
return {
|
|
72407
|
+
cell: {
|
|
72408
|
+
sheet: wireString(wire.sheet, `${at}.sheet`),
|
|
72409
|
+
cell: wireString(wire.cell, `${at}.cell`)
|
|
72410
|
+
}
|
|
72411
|
+
};
|
|
72412
|
+
}
|
|
72413
|
+
case "part": {
|
|
72414
|
+
const wire = wireObject(body, at);
|
|
72415
|
+
return { part: { name: wireString(wire.name, `${at}.name`) } };
|
|
72416
|
+
}
|
|
72417
|
+
case "legacy_sort": {
|
|
72418
|
+
const wire = wireObject(body, at);
|
|
72419
|
+
return { legacySort: { sortId: wireString(wire.sort_id, `${at}.sort_id`) } };
|
|
72420
|
+
}
|
|
72421
|
+
case "json_pointer": {
|
|
72422
|
+
const wire = wireObject(body, at);
|
|
72423
|
+
return { jsonPointer: { pointer: wireString(wire.pointer, `${at}.pointer`) } };
|
|
72424
|
+
}
|
|
72425
|
+
}
|
|
72426
|
+
throw new TypeError(`${path} has the unknown variant ${variant}`);
|
|
72427
|
+
}
|
|
72428
|
+
function SourceTermFromWire(value, path) {
|
|
72429
|
+
const [variant, body] = externalVariant(value, path);
|
|
72430
|
+
const at = `${path}.${variant}`;
|
|
72431
|
+
switch (variant) {
|
|
72432
|
+
case "iri":
|
|
72433
|
+
return { iri: wireString(body, at) };
|
|
72434
|
+
case "blank":
|
|
72435
|
+
return { blank: wireString(body, at) };
|
|
72436
|
+
case "literal": {
|
|
72437
|
+
const wire = wireObject(body, at);
|
|
72438
|
+
const literal = {
|
|
72439
|
+
value: wireString(wire.value, `${at}.value`),
|
|
72440
|
+
datatype: wireString(wire.datatype, `${at}.datatype`)
|
|
72441
|
+
};
|
|
72442
|
+
if (present(wire.language)) literal.language = wireString(wire.language, `${at}.language`);
|
|
72443
|
+
return { literal };
|
|
72444
|
+
}
|
|
72445
|
+
}
|
|
72446
|
+
throw new TypeError(`${path} has the unknown variant ${variant}`);
|
|
72447
|
+
}
|
|
72448
|
+
var SOURCE_ITEM_KINDS = ["statement", "row", "record", "rejected"];
|
|
72449
|
+
function SourceItemFromWire(value, path) {
|
|
72450
|
+
const wire = wireObject(value, path);
|
|
72451
|
+
const coordinates = ImportCoordinatesFromWire(wire.coordinates, `${path}.coordinates`);
|
|
72452
|
+
const kind = wireLiteral(wire.item, SOURCE_ITEM_KINDS, `${path}.item`);
|
|
72453
|
+
switch (kind) {
|
|
72454
|
+
case "statement":
|
|
72455
|
+
return {
|
|
72456
|
+
item: "statement",
|
|
72457
|
+
coordinates,
|
|
72458
|
+
subject: SourceTermFromWire(wire.subject, `${path}.subject`),
|
|
72459
|
+
predicate: wireString(wire.predicate, `${path}.predicate`),
|
|
72460
|
+
object: SourceTermFromWire(wire.object, `${path}.object`)
|
|
72461
|
+
};
|
|
72462
|
+
case "row": {
|
|
72463
|
+
const cells = {};
|
|
72464
|
+
for (const [column, text] of Object.entries(wireObject(wire.cells, `${path}.cells`))) {
|
|
72465
|
+
cells[column] = wireString(text, `${path}.cells.${column}`);
|
|
72466
|
+
}
|
|
72467
|
+
return {
|
|
72468
|
+
item: "row",
|
|
72469
|
+
coordinates,
|
|
72470
|
+
cells,
|
|
72471
|
+
formulas: wireStringArray(wire.formulas, `${path}.formulas`)
|
|
72472
|
+
};
|
|
72473
|
+
}
|
|
72474
|
+
case "record": {
|
|
72475
|
+
const record = wire.record;
|
|
72476
|
+
if (!isJsonValue(record)) throw new TypeError(`${path}.record is missing`);
|
|
72477
|
+
return { item: "record", coordinates, record };
|
|
72478
|
+
}
|
|
72479
|
+
case "rejected":
|
|
72480
|
+
return {
|
|
72481
|
+
item: "rejected",
|
|
72482
|
+
coordinates,
|
|
72483
|
+
reason: wireString(wire.reason, `${path}.reason`),
|
|
72484
|
+
message: wireString(wire.message, `${path}.message`)
|
|
72485
|
+
};
|
|
72486
|
+
}
|
|
72487
|
+
}
|
|
72488
|
+
function ImportCellNoteFromApiToFront(dto) {
|
|
72489
|
+
const out = {
|
|
72490
|
+
column: dto.column,
|
|
72491
|
+
disposition: dto.disposition,
|
|
72492
|
+
reason: dto.reason
|
|
72493
|
+
};
|
|
72494
|
+
if (present(dto.resource_key)) out.resourceKey = dto.resource_key;
|
|
72495
|
+
return out;
|
|
72496
|
+
}
|
|
72497
|
+
function ImportItemFromApiToFront(dto) {
|
|
72498
|
+
const out = {
|
|
72499
|
+
ordinal: dto.ordinal,
|
|
72500
|
+
coordinates: ImportCoordinatesFromWire(dto.coordinates, "coordinates"),
|
|
72501
|
+
item: SourceItemFromWire(dto.item, "item"),
|
|
72502
|
+
disposition: dto.disposition,
|
|
72503
|
+
resourceKeys: dto.resource_keys,
|
|
72504
|
+
notes: dto.notes.map(ImportCellNoteFromApiToFront)
|
|
72505
|
+
};
|
|
72506
|
+
if (present(dto.reason)) out.reason = dto.reason;
|
|
72507
|
+
if (present(dto.target_record_id)) out.targetRecordId = dto.target_record_id;
|
|
72508
|
+
return out;
|
|
72509
|
+
}
|
|
72510
|
+
function VocabularyImportItemPageFromApiToFront(dto) {
|
|
72511
|
+
const out = {
|
|
72512
|
+
importId: dto.import_id,
|
|
72513
|
+
items: dto.items.map(ImportItemFromApiToFront),
|
|
72514
|
+
complete: dto.complete
|
|
72515
|
+
};
|
|
72516
|
+
if (present(dto.next_cursor)) out.nextCursor = dto.next_cursor;
|
|
72517
|
+
return out;
|
|
72518
|
+
}
|
|
72519
|
+
function LegacySortInventoryFromApiToFront(dto) {
|
|
72520
|
+
return {
|
|
72521
|
+
sortId: dto.sort_id,
|
|
72522
|
+
sortName: dto.sort_name,
|
|
72523
|
+
classification: dto.classification,
|
|
72524
|
+
parents: dto.parents,
|
|
72525
|
+
featureCount: dto.feature_count,
|
|
72526
|
+
boundConstraintCount: dto.bound_constraint_count,
|
|
72527
|
+
instances: dto.instances,
|
|
72528
|
+
rulesReferencing: dto.rules_referencing,
|
|
72529
|
+
featuresRangingOver: dto.features_ranging_over
|
|
72530
|
+
};
|
|
72531
|
+
}
|
|
72532
|
+
function VocabularyMigrationPlanFromApiToFront(dto) {
|
|
72533
|
+
return {
|
|
72534
|
+
planId: dto.plan_id,
|
|
72535
|
+
fingerprint: dto.fingerprint,
|
|
72536
|
+
byteSize: dto.byte_size,
|
|
72537
|
+
inventory: dto.inventory.map(LegacySortInventoryFromApiToFront),
|
|
72538
|
+
dispositions: dto.dispositions.map(
|
|
72539
|
+
(planned) => ({
|
|
72540
|
+
sortId: planned.sort_id,
|
|
72541
|
+
disposition: planned.disposition,
|
|
72542
|
+
rationale: planned.rationale
|
|
72543
|
+
})
|
|
72544
|
+
),
|
|
72545
|
+
createdBy: dto.created_by,
|
|
72546
|
+
createdAt: dto.created_at,
|
|
72547
|
+
replayed: dto.replayed
|
|
72548
|
+
};
|
|
72549
|
+
}
|
|
72550
|
+
function NativeExportManifestFromApiToFront(dto) {
|
|
72551
|
+
const out = {
|
|
72552
|
+
recordCount: dto.record_count,
|
|
72553
|
+
countsByKind: dataMap(dto.counts_by_kind),
|
|
72554
|
+
recordsSha256: dto.records_sha256,
|
|
72555
|
+
unreadable: dto.unreadable.map((record) => ({
|
|
72556
|
+
recordId: record.record_id,
|
|
72557
|
+
reason: record.reason
|
|
72558
|
+
}))
|
|
72559
|
+
};
|
|
72560
|
+
if (present(dto.context_manifest)) {
|
|
72561
|
+
out.contextManifest = ContextManifestFromApiToFront(dto.context_manifest);
|
|
72562
|
+
}
|
|
72563
|
+
return out;
|
|
72564
|
+
}
|
|
72565
|
+
function VocabularyNativeExportFromApiToFront(dto) {
|
|
72566
|
+
const out = {
|
|
72567
|
+
format: dto.format,
|
|
72568
|
+
view: ViewRefFromApiToFront(dto.view),
|
|
72569
|
+
records: dto.records.map(VocabularyRecordViewFromApiToFront),
|
|
72570
|
+
artifacts: dto.artifacts.map(VocabularySourceArtifactRecordFromApiToFront),
|
|
72571
|
+
manifest: NativeExportManifestFromApiToFront(dto.manifest)
|
|
72572
|
+
};
|
|
72573
|
+
if (present(dto.context)) out.context = VocabularyContextRefFromApiToFront(dto.context);
|
|
72574
|
+
return out;
|
|
72575
|
+
}
|
|
72576
|
+
function IriChoiceFromApiToFront(dto) {
|
|
72577
|
+
return {
|
|
72578
|
+
recordId: dto.record_id,
|
|
72579
|
+
kind: dto.kind,
|
|
72580
|
+
iri: dto.iri,
|
|
72581
|
+
rule: dto.rule,
|
|
72582
|
+
sourceAssociations: dto.source_associations
|
|
72583
|
+
};
|
|
72584
|
+
}
|
|
72585
|
+
function ProjectionLossFromApiToFront(dto) {
|
|
72586
|
+
return { kind: dto.kind, reason: dto.reason, recordIds: dto.record_ids };
|
|
72587
|
+
}
|
|
72588
|
+
function SkosManifestFromApiToFront(dto) {
|
|
72589
|
+
const out = {
|
|
72590
|
+
projection: dto.projection,
|
|
72591
|
+
iriPolicy: dto.iri_policy,
|
|
72592
|
+
view: ViewRefFromApiToFront(dto.view),
|
|
72593
|
+
schemeId: dto.scheme_id,
|
|
72594
|
+
includeProvenance: dto.include_provenance,
|
|
72595
|
+
tripleCount: dto.triple_count,
|
|
72596
|
+
iris: dto.iris.map(IriChoiceFromApiToFront),
|
|
72597
|
+
losses: dto.losses.map(ProjectionLossFromApiToFront)
|
|
72598
|
+
};
|
|
72599
|
+
if (present(dto.context_id)) out.contextId = dto.context_id;
|
|
72600
|
+
return out;
|
|
72601
|
+
}
|
|
72602
|
+
function VocabularySkosExportFromApiToFront(dto) {
|
|
72603
|
+
return {
|
|
72604
|
+
mediaType: dto.media_type,
|
|
72605
|
+
content: dto.content,
|
|
72606
|
+
sha256: dto.sha256,
|
|
72607
|
+
manifest: SkosManifestFromApiToFront(dto.manifest)
|
|
72608
|
+
};
|
|
72609
|
+
}
|
|
72610
|
+
function SparqlDatasetFromApiToFront(dto) {
|
|
72611
|
+
const out = {
|
|
72612
|
+
view: ViewRefFromApiToFront(dto.view),
|
|
72613
|
+
schemeId: dto.scheme_id,
|
|
72614
|
+
projection: dto.projection,
|
|
72615
|
+
tripleCount: dto.triple_count
|
|
72616
|
+
};
|
|
72617
|
+
if (present(dto.context_id)) out.contextId = dto.context_id;
|
|
72618
|
+
return out;
|
|
72619
|
+
}
|
|
72620
|
+
var SPARQL_TERM_TYPES = ["uri", "bnode", "literal"];
|
|
72621
|
+
function SparqlTermFromWire(value, path) {
|
|
72622
|
+
const wire = wireObject(value, path);
|
|
72623
|
+
const type = wireLiteral(wire.type, SPARQL_TERM_TYPES, `${path}.type`);
|
|
72624
|
+
const lexical = wireString(wire.value, `${path}.value`);
|
|
72625
|
+
switch (type) {
|
|
72626
|
+
case "uri":
|
|
72627
|
+
return { type: "uri", value: lexical };
|
|
72628
|
+
case "bnode":
|
|
72629
|
+
return { type: "bnode", value: lexical };
|
|
72630
|
+
case "literal": {
|
|
72631
|
+
const term = {
|
|
72632
|
+
type: "literal",
|
|
72633
|
+
value: lexical
|
|
72634
|
+
};
|
|
72635
|
+
const language = wire["xml:lang"];
|
|
72636
|
+
if (present(language)) term["xml:lang"] = wireString(language, `${path}.xml:lang`);
|
|
72637
|
+
if (present(wire.datatype)) term.datatype = wireString(wire.datatype, `${path}.datatype`);
|
|
72638
|
+
return term;
|
|
72639
|
+
}
|
|
72640
|
+
}
|
|
72641
|
+
}
|
|
72642
|
+
function SparqlSelectDocumentFromWire(value) {
|
|
72643
|
+
const wire = wireObject(value, "results");
|
|
72644
|
+
const head = wireObject(wire.head, "results.head");
|
|
72645
|
+
const results = wireObject(wire.results, "results.results");
|
|
72646
|
+
return {
|
|
72647
|
+
head: { vars: wireStringArray(head.vars, "results.head.vars") },
|
|
72648
|
+
results: {
|
|
72649
|
+
bindings: wireArray(results.bindings, "results.results.bindings").map((solution, index) => {
|
|
72650
|
+
const path = `results.results.bindings[${index}]`;
|
|
72651
|
+
const binding = {};
|
|
72652
|
+
for (const [variable, term] of Object.entries(wireObject(solution, path))) {
|
|
72653
|
+
binding[variable] = SparqlTermFromWire(term, `${path}.${variable}`);
|
|
72654
|
+
}
|
|
72655
|
+
return binding;
|
|
72656
|
+
})
|
|
72657
|
+
}
|
|
72658
|
+
};
|
|
72659
|
+
}
|
|
72660
|
+
function SparqlAskDocumentFromWire(value) {
|
|
72661
|
+
const wire = wireObject(value, "results");
|
|
72662
|
+
wireObject(wire.head, "results.head");
|
|
72663
|
+
return { head: {}, boolean: wireBoolean(wire.boolean, "results.boolean") };
|
|
72664
|
+
}
|
|
72665
|
+
function VocabularySparqlResultFromApiToFront(dto) {
|
|
72666
|
+
const base = {
|
|
72667
|
+
dataset: SparqlDatasetFromApiToFront(dto.dataset),
|
|
72668
|
+
complete: dto.complete
|
|
72669
|
+
};
|
|
72670
|
+
if (present(dto.stop_reason)) base.stopReason = dto.stop_reason;
|
|
72671
|
+
switch (dto.form) {
|
|
72672
|
+
case "select":
|
|
72673
|
+
return { ...base, form: "select", results: SparqlSelectDocumentFromWire(dto.results) };
|
|
72674
|
+
case "ask":
|
|
72675
|
+
return { ...base, form: "ask", results: SparqlAskDocumentFromWire(dto.results) };
|
|
72676
|
+
case "construct":
|
|
72677
|
+
case "describe": {
|
|
72678
|
+
const nTriples = dto.n_triples;
|
|
72679
|
+
if (!present(nTriples)) throw new TypeError("n_triples is missing from a graph answer");
|
|
72680
|
+
return { ...base, form: dto.form, nTriples };
|
|
72681
|
+
}
|
|
72682
|
+
}
|
|
72683
|
+
}
|
|
70301
72684
|
|
|
70302
72685
|
// src/resources/vocabulary.ts
|
|
70303
72686
|
function viewQuery(selector) {
|
|
@@ -71268,6 +73651,681 @@ var VocabularyClient = class {
|
|
|
71268
73651
|
const response = await this.api.migrationPreview(pageQuery(query), toRequestParams(requestOptions)).catch(rethrowVocabularyRefusal);
|
|
71269
73652
|
return decodeResponse(response, VocabularyMigrationPreviewFromApiToFront);
|
|
71270
73653
|
}
|
|
73654
|
+
// ---------------------------------------------------------------------------
|
|
73655
|
+
// Taxonomy and thesaurus reads
|
|
73656
|
+
// ---------------------------------------------------------------------------
|
|
73657
|
+
/**
|
|
73658
|
+
* The `broader` links of one scheme around a concept, or below its top
|
|
73659
|
+
* concepts: a DAG of concepts and the stored relations that witness them.
|
|
73660
|
+
*
|
|
73661
|
+
* @param schemeId - The scheme (UUID); only its relations are followed.
|
|
73662
|
+
* @param query - The view, a start concept, the direction, transitivity,
|
|
73663
|
+
* hierarchy kinds, a status, `maxNodes` (1 to 100000) and a display language.
|
|
73664
|
+
* @param requestOptions - Per-call options (timeout, retries, signal, headers).
|
|
73665
|
+
* @returns The nodes (each once, with every relation that reaches it in
|
|
73666
|
+
* `via`), the edges, and `complete` / `stopReason`.
|
|
73667
|
+
* @throws {@link NotFoundError} 404 for an unknown scheme, concept, release or revision.
|
|
73668
|
+
* @throws {@link VocabularyRefusedError} 400 `invalid_request`; 409
|
|
73669
|
+
* `vocabulary_plugin_unavailable`.
|
|
73670
|
+
*
|
|
73671
|
+
* @remarks
|
|
73672
|
+
* `GET /api/v1/vocabulary/schemes/{scheme_id}/hierarchy`. `hierarchyKinds`
|
|
73673
|
+
* is sent as one comma-separated parameter. A traversal that reaches
|
|
73674
|
+
* `maxNodes` or the deadline answers `complete: false` with its
|
|
73675
|
+
* `stopReason`: a partial answer, not an error. Read `complete` before
|
|
73676
|
+
* concluding that a concept is absent. Mappings are never followed.
|
|
73677
|
+
*
|
|
73678
|
+
* @example
|
|
73679
|
+
* ```typescript
|
|
73680
|
+
* const tree = await client.vocabulary.schemeHierarchy(schemeId, { transitive: true });
|
|
73681
|
+
* if (!tree.complete) console.log('partial:', tree.stopReason);
|
|
73682
|
+
* for (const node of tree.nodes) console.log(node.depth, node.displayLabel?.text, node.via);
|
|
73683
|
+
* ```
|
|
73684
|
+
*/
|
|
73685
|
+
async schemeHierarchy(schemeId, query, requestOptions) {
|
|
73686
|
+
const wire = viewQuery(query?.view);
|
|
73687
|
+
if (query?.conceptId !== void 0) wire.concept_id = query.conceptId;
|
|
73688
|
+
if (query?.direction !== void 0) wire.direction = query.direction;
|
|
73689
|
+
if (query?.transitive !== void 0) wire.transitive = query.transitive;
|
|
73690
|
+
if (query?.hierarchyKinds !== void 0) wire.hierarchy_kinds = query.hierarchyKinds.join(",");
|
|
73691
|
+
if (query?.status !== void 0) wire.status = query.status;
|
|
73692
|
+
if (query?.maxNodes !== void 0) wire.max_nodes = query.maxNodes;
|
|
73693
|
+
if (query?.language !== void 0) wire.language = query.language;
|
|
73694
|
+
const response = await this.api.schemeHierarchy(schemeId, wire, toRequestParams(requestOptions)).catch(rethrowVocabularyRefusal);
|
|
73695
|
+
return decodeResponse(response, VocabularyHierarchyFromApiToFront);
|
|
73696
|
+
}
|
|
73697
|
+
/**
|
|
73698
|
+
* The simple paths of accepted `broader` links from a narrower concept up
|
|
73699
|
+
* to a broader one.
|
|
73700
|
+
*
|
|
73701
|
+
* @param schemeId - The scheme (UUID).
|
|
73702
|
+
* @param query - The view, `from` and `to` (UUIDs), hierarchy kinds,
|
|
73703
|
+
* `maxNodes` (1 to 100000) and `maxPaths` (1 to 1024).
|
|
73704
|
+
* @param requestOptions - Per-call options (timeout, retries, signal, headers).
|
|
73705
|
+
* @returns Each path as a sequence of relation ids, shortest first, and
|
|
73706
|
+
* `complete` / `stopReason`.
|
|
73707
|
+
* @throws {@link NotFoundError} 404 for an unknown scheme, concept, release or revision.
|
|
73708
|
+
* @throws {@link VocabularyRefusedError} 400 `invalid_request`; 409
|
|
73709
|
+
* `vocabulary_plugin_unavailable`.
|
|
73710
|
+
*
|
|
73711
|
+
* @remarks
|
|
73712
|
+
* `GET /api/v1/vocabulary/schemes/{scheme_id}/paths`. An empty `paths`
|
|
73713
|
+
* with `complete: true` means no path exists; with `complete: false` it
|
|
73714
|
+
* means the search stopped (`path_limit`, `node_limit` or `deadline`).
|
|
73715
|
+
*
|
|
73716
|
+
* @example
|
|
73717
|
+
* ```typescript
|
|
73718
|
+
* const { paths, complete } = await client.vocabulary.schemePaths(schemeId, {
|
|
73719
|
+
* from: narrowerId,
|
|
73720
|
+
* to: broaderId,
|
|
73721
|
+
* });
|
|
73722
|
+
* ```
|
|
73723
|
+
*/
|
|
73724
|
+
async schemePaths(schemeId, query, requestOptions) {
|
|
73725
|
+
const wire = {
|
|
73726
|
+
...viewQuery(query.view),
|
|
73727
|
+
from: query.from,
|
|
73728
|
+
to: query.to
|
|
73729
|
+
};
|
|
73730
|
+
if (query.hierarchyKinds !== void 0) wire.hierarchy_kinds = query.hierarchyKinds.join(",");
|
|
73731
|
+
if (query.maxNodes !== void 0) wire.max_nodes = query.maxNodes;
|
|
73732
|
+
if (query.maxPaths !== void 0) wire.max_paths = query.maxPaths;
|
|
73733
|
+
const response = await this.api.schemePaths(schemeId, wire, toRequestParams(requestOptions)).catch(rethrowVocabularyRefusal);
|
|
73734
|
+
return decodeResponse(response, VocabularyHierarchyPathsFromApiToFront);
|
|
73735
|
+
}
|
|
73736
|
+
/**
|
|
73737
|
+
* The top concepts of a scheme: the concepts with an accepted membership
|
|
73738
|
+
* marked `topConcept`.
|
|
73739
|
+
*
|
|
73740
|
+
* @param schemeId - The scheme (UUID).
|
|
73741
|
+
* @param query - The view and a display language.
|
|
73742
|
+
* @param requestOptions - Per-call options (timeout, retries, signal, headers).
|
|
73743
|
+
* @returns The concepts, by id.
|
|
73744
|
+
* @throws {@link NotFoundError} 404 for an unknown scheme, release or revision.
|
|
73745
|
+
* @throws {@link VocabularyRefusedError} 400 `invalid_request`; 409
|
|
73746
|
+
* `vocabulary_plugin_unavailable`.
|
|
73747
|
+
*
|
|
73748
|
+
* @remarks
|
|
73749
|
+
* `GET /api/v1/vocabulary/schemes/{scheme_id}/top-concepts`.
|
|
73750
|
+
*
|
|
73751
|
+
* @example
|
|
73752
|
+
* ```typescript
|
|
73753
|
+
* const { concepts } = await client.vocabulary.topConcepts(schemeId, { language: 'en' });
|
|
73754
|
+
* ```
|
|
73755
|
+
*/
|
|
73756
|
+
async topConcepts(schemeId, query, requestOptions) {
|
|
73757
|
+
const wire = viewQuery(query?.view);
|
|
73758
|
+
if (query?.language !== void 0) wire.language = query.language;
|
|
73759
|
+
const response = await this.api.schemeTopConcepts(schemeId, wire, toRequestParams(requestOptions)).catch(rethrowVocabularyRefusal);
|
|
73760
|
+
return decodeResponse(response, VocabularyTopConceptsFromApiToFront);
|
|
73761
|
+
}
|
|
73762
|
+
/**
|
|
73763
|
+
* The taxonomy policy of a scheme, or the `taxonomy-policy/v1` defaults
|
|
73764
|
+
* with `declared: false`.
|
|
73765
|
+
*
|
|
73766
|
+
* @param schemeId - The scheme (UUID).
|
|
73767
|
+
* @param query - The view.
|
|
73768
|
+
* @param requestOptions - Per-call options (timeout, retries, signal, headers).
|
|
73769
|
+
* @returns The policy in force for the scheme in that view.
|
|
73770
|
+
* @throws {@link NotFoundError} 404 for an unknown scheme, release or revision.
|
|
73771
|
+
* @throws {@link VocabularyRefusedError} 400 `invalid_request`; 409
|
|
73772
|
+
* `vocabulary_plugin_unavailable`.
|
|
73773
|
+
*
|
|
73774
|
+
* @remarks
|
|
73775
|
+
* `GET /api/v1/vocabulary/schemes/{scheme_id}/policy`. An absent
|
|
73776
|
+
* `partitiveTransitive` is unstated: a partitive path of two or more links
|
|
73777
|
+
* is reported, never derived.
|
|
73778
|
+
*
|
|
73779
|
+
* @example
|
|
73780
|
+
* ```typescript
|
|
73781
|
+
* const policy = await client.vocabulary.schemePolicy(schemeId);
|
|
73782
|
+
* if (!policy.declared) console.log('defaults', policy.policy);
|
|
73783
|
+
* ```
|
|
73784
|
+
*/
|
|
73785
|
+
async schemePolicy(schemeId, query, requestOptions) {
|
|
73786
|
+
const response = await this.api.schemePolicy(schemeId, viewQuery(query?.view), toRequestParams(requestOptions)).catch(rethrowVocabularyRefusal);
|
|
73787
|
+
return decodeResponse(response, VocabularyTaxonomyPolicyFromApiToFront);
|
|
73788
|
+
}
|
|
73789
|
+
/**
|
|
73790
|
+
* The direct relations of one kind of a concept in one scheme, of every
|
|
73791
|
+
* status.
|
|
73792
|
+
*
|
|
73793
|
+
* @param conceptId - The concept (UUID).
|
|
73794
|
+
* @param query - The view, the scheme, `relation` (`related`, `broader` or
|
|
73795
|
+
* `narrower`) and a display language.
|
|
73796
|
+
* @param requestOptions - Per-call options (timeout, retries, signal, headers).
|
|
73797
|
+
* @returns The relations, by relation id, each with the concept at the other end.
|
|
73798
|
+
* @throws {@link NotFoundError} 404 for an unknown concept, scheme, release or revision.
|
|
73799
|
+
* @throws {@link VocabularyRefusedError} 400 `invalid_request`; 409
|
|
73800
|
+
* `vocabulary_plugin_unavailable`.
|
|
73801
|
+
*
|
|
73802
|
+
* @remarks
|
|
73803
|
+
* `GET /api/v1/vocabulary/concepts/{concept_id}/relations`. `narrower` is
|
|
73804
|
+
* the inverse read of the stored `broader` links; nothing derived is listed.
|
|
73805
|
+
*
|
|
73806
|
+
* @example
|
|
73807
|
+
* ```typescript
|
|
73808
|
+
* const { relations } = await client.vocabulary.conceptRelations(conceptId, {
|
|
73809
|
+
* schemeId,
|
|
73810
|
+
* relation: 'narrower',
|
|
73811
|
+
* });
|
|
73812
|
+
* ```
|
|
73813
|
+
*/
|
|
73814
|
+
async conceptRelations(conceptId, query, requestOptions) {
|
|
73815
|
+
const wire = {
|
|
73816
|
+
...viewQuery(query.view),
|
|
73817
|
+
scheme_id: query.schemeId,
|
|
73818
|
+
relation: query.relation
|
|
73819
|
+
};
|
|
73820
|
+
if (query.language !== void 0) wire.language = query.language;
|
|
73821
|
+
const response = await this.api.conceptRelations(conceptId, wire, toRequestParams(requestOptions)).catch(rethrowVocabularyRefusal);
|
|
73822
|
+
return decodeResponse(response, VocabularyConceptRelationsFromApiToFront);
|
|
73823
|
+
}
|
|
73824
|
+
/**
|
|
73825
|
+
* One page of the collections of one scheme.
|
|
73826
|
+
*
|
|
73827
|
+
* @param query - The view, the scheme and cursor paging (`limit` 1 to 200).
|
|
73828
|
+
* @param requestOptions - Per-call options (timeout, retries, signal, headers).
|
|
73829
|
+
* @returns The collections with their labels and member counts, the next
|
|
73830
|
+
* cursor and `complete`.
|
|
73831
|
+
* @throws {@link NotFoundError} 404 for an unknown scheme, release or revision.
|
|
73832
|
+
* @throws {@link VocabularyRefusedError} 400 `invalid_request`,
|
|
73833
|
+
* `cursor_mismatch` (a cursor read with another view or scheme); 409
|
|
73834
|
+
* `vocabulary_plugin_unavailable`.
|
|
73835
|
+
*
|
|
73836
|
+
* @remarks
|
|
73837
|
+
* `GET /api/v1/vocabulary/collections?scheme_id&cursor&limit`. A cursor is
|
|
73838
|
+
* bound to the tenant, the view and the scheme.
|
|
73839
|
+
*
|
|
73840
|
+
* @example
|
|
73841
|
+
* ```typescript
|
|
73842
|
+
* const page = await client.vocabulary.listCollections({ schemeId, limit: 50 });
|
|
73843
|
+
* ```
|
|
73844
|
+
*/
|
|
73845
|
+
async listCollections(query, requestOptions) {
|
|
73846
|
+
const wire = {
|
|
73847
|
+
...viewQuery(query.view),
|
|
73848
|
+
...pageQuery(query),
|
|
73849
|
+
scheme_id: query.schemeId
|
|
73850
|
+
};
|
|
73851
|
+
const response = await this.api.listVocabularyCollections(wire, toRequestParams(requestOptions)).catch(rethrowVocabularyRefusal);
|
|
73852
|
+
return decodeResponse(response, VocabularyCollectionPageFromApiToFront);
|
|
73853
|
+
}
|
|
73854
|
+
/**
|
|
73855
|
+
* One collection with its labels, its member occurrences and its nested
|
|
73856
|
+
* collections.
|
|
73857
|
+
*
|
|
73858
|
+
* @param collectionId - The collection (UUID).
|
|
73859
|
+
* @param query - The view and a display language for member concepts.
|
|
73860
|
+
* @param requestOptions - Per-call options (timeout, retries, signal, headers).
|
|
73861
|
+
* @returns The collection detail. Member occurrences keep their positions.
|
|
73862
|
+
* @throws {@link NotFoundError} 404 when the view does not hold the collection.
|
|
73863
|
+
* @throws {@link VocabularyRefusedError} 400 `invalid_request`; 409
|
|
73864
|
+
* `vocabulary_plugin_unavailable`.
|
|
73865
|
+
*
|
|
73866
|
+
* @remarks
|
|
73867
|
+
* `GET /api/v1/vocabulary/collections/{collection_id}`. Members are listed
|
|
73868
|
+
* by position (absent first), then by occurrence id; a member that occurs
|
|
73869
|
+
* twice is listed twice.
|
|
73870
|
+
*
|
|
73871
|
+
* @example
|
|
73872
|
+
* ```typescript
|
|
73873
|
+
* const detail = await client.vocabulary.getCollection(collectionId, { language: 'en' });
|
|
73874
|
+
* for (const member of detail.members) console.log(member.position, member.memberConcept);
|
|
73875
|
+
* ```
|
|
73876
|
+
*/
|
|
73877
|
+
async getCollection(collectionId, query, requestOptions) {
|
|
73878
|
+
const wire = viewQuery(
|
|
73879
|
+
query?.view
|
|
73880
|
+
);
|
|
73881
|
+
if (query?.language !== void 0) wire.language = query.language;
|
|
73882
|
+
const response = await this.api.getVocabularyCollection(collectionId, wire, toRequestParams(requestOptions)).catch(rethrowVocabularyRefusal);
|
|
73883
|
+
return decodeResponse(response, VocabularyCollectionDetailFromApiToFront);
|
|
73884
|
+
}
|
|
73885
|
+
/**
|
|
73886
|
+
* One page of the depth-first list of a scheme's concepts, for a form
|
|
73887
|
+
* control. A concept with several parents is listed once.
|
|
73888
|
+
*
|
|
73889
|
+
* @param schemeId - The scheme (UUID).
|
|
73890
|
+
* @param query - The view, a root, `maxDepth`, `maxNodes` (1 to 100000),
|
|
73891
|
+
* a display language and cursor paging (`limit` 1 to 500).
|
|
73892
|
+
* @param requestOptions - Per-call options (timeout, retries, signal, headers).
|
|
73893
|
+
* @returns The entries of this page, the roots, the next cursor,
|
|
73894
|
+
* `complete` and `stopReason`.
|
|
73895
|
+
* @throws {@link NotFoundError} 404 for an unknown scheme, root, release or revision.
|
|
73896
|
+
* @throws {@link VocabularyRefusedError} 400 `invalid_request`,
|
|
73897
|
+
* `cursor_mismatch`; 409 `vocabulary_plugin_unavailable`.
|
|
73898
|
+
*
|
|
73899
|
+
* @remarks
|
|
73900
|
+
* `GET /api/v1/vocabulary/schemes/{scheme_id}/picklist`. Only accepted
|
|
73901
|
+
* `broader` relations are followed. `complete` is `true` only on the last
|
|
73902
|
+
* page of a list that `maxNodes` did not cut.
|
|
73903
|
+
*
|
|
73904
|
+
* @example
|
|
73905
|
+
* ```typescript
|
|
73906
|
+
* let page = await client.vocabulary.picklist(schemeId, { limit: 100 });
|
|
73907
|
+
* while (page.nextCursor !== undefined) {
|
|
73908
|
+
* page = await client.vocabulary.picklist(schemeId, { cursor: page.nextCursor });
|
|
73909
|
+
* }
|
|
73910
|
+
* ```
|
|
73911
|
+
*/
|
|
73912
|
+
async picklist(schemeId, query, requestOptions) {
|
|
73913
|
+
const wire = {
|
|
73914
|
+
...viewQuery(query?.view),
|
|
73915
|
+
...pageQuery(query)
|
|
73916
|
+
};
|
|
73917
|
+
if (query?.root !== void 0) wire.root = query.root;
|
|
73918
|
+
if (query?.maxDepth !== void 0) wire.max_depth = query.maxDepth;
|
|
73919
|
+
if (query?.maxNodes !== void 0) wire.max_nodes = query.maxNodes;
|
|
73920
|
+
if (query?.language !== void 0) wire.language = query.language;
|
|
73921
|
+
const response = await this.api.schemePicklist(schemeId, wire, toRequestParams(requestOptions)).catch(rethrowVocabularyRefusal);
|
|
73922
|
+
return decodeResponse(response, VocabularyPicklistFromApiToFront);
|
|
73923
|
+
}
|
|
73924
|
+
/**
|
|
73925
|
+
* The concepts a query on one concept may be expanded to, each with the
|
|
73926
|
+
* relation and mapping ids that support it.
|
|
73927
|
+
*
|
|
73928
|
+
* @param conceptId - The concept to expand (UUID).
|
|
73929
|
+
* @param query - The view, the scheme, the direction, transitivity,
|
|
73930
|
+
* hierarchy kinds, related links, mapping kinds, `maxNodes` and a display
|
|
73931
|
+
* language.
|
|
73932
|
+
* @param requestOptions - Per-call options (timeout, retries, signal, headers).
|
|
73933
|
+
* @returns The concepts and external concepts with their support, the
|
|
73934
|
+
* withheld relations and `complete` / `stopReason`.
|
|
73935
|
+
* @throws {@link NotFoundError} 404 for an unknown concept, scheme, release or revision.
|
|
73936
|
+
* @throws {@link VocabularyRefusedError} 400 `invalid_request`; 409
|
|
73937
|
+
* `vocabulary_plugin_unavailable`.
|
|
73938
|
+
*
|
|
73939
|
+
* @remarks
|
|
73940
|
+
* `GET /api/v1/vocabulary/concepts/{concept_id}/expansion`.
|
|
73941
|
+
* `hierarchyKinds` and `mappingKinds` are sent comma-separated. A
|
|
73942
|
+
* partitive link that would end a transitive path is not followed unless
|
|
73943
|
+
* the scheme's policy states `partitiveTransitive: true`; it is listed in
|
|
73944
|
+
* `withheldRelationIds`.
|
|
73945
|
+
*
|
|
73946
|
+
* @example
|
|
73947
|
+
* ```typescript
|
|
73948
|
+
* const expansion = await client.vocabulary.expandConcept(conceptId, {
|
|
73949
|
+
* schemeId,
|
|
73950
|
+
* transitive: true,
|
|
73951
|
+
* mappingKinds: ['exact', 'close'],
|
|
73952
|
+
* });
|
|
73953
|
+
* ```
|
|
73954
|
+
*/
|
|
73955
|
+
async expandConcept(conceptId, query, requestOptions) {
|
|
73956
|
+
const wire = {
|
|
73957
|
+
...viewQuery(query.view),
|
|
73958
|
+
scheme_id: query.schemeId
|
|
73959
|
+
};
|
|
73960
|
+
if (query.direction !== void 0) wire.direction = query.direction;
|
|
73961
|
+
if (query.transitive !== void 0) wire.transitive = query.transitive;
|
|
73962
|
+
if (query.hierarchyKinds !== void 0) wire.hierarchy_kinds = query.hierarchyKinds.join(",");
|
|
73963
|
+
if (query.includeRelated !== void 0) wire.include_related = query.includeRelated;
|
|
73964
|
+
if (query.mappingKinds !== void 0) wire.mapping_kinds = query.mappingKinds.join(",");
|
|
73965
|
+
if (query.maxNodes !== void 0) wire.max_nodes = query.maxNodes;
|
|
73966
|
+
if (query.language !== void 0) wire.language = query.language;
|
|
73967
|
+
const response = await this.api.conceptExpansion(conceptId, wire, toRequestParams(requestOptions)).catch(rethrowVocabularyRefusal);
|
|
73968
|
+
return decodeResponse(response, VocabularyExpansionFromApiToFront);
|
|
73969
|
+
}
|
|
73970
|
+
// ---------------------------------------------------------------------------
|
|
73971
|
+
// Imports
|
|
73972
|
+
// ---------------------------------------------------------------------------
|
|
73973
|
+
/**
|
|
73974
|
+
* Parse an uploaded source file and store its import proposal. Writes no
|
|
73975
|
+
* vocabulary record.
|
|
73976
|
+
*
|
|
73977
|
+
* @param request - The uploaded file, its format, the declared dataset, the
|
|
73978
|
+
* target scheme and the RDF options.
|
|
73979
|
+
* @param requestOptions - The required `idempotencyKey` and per-call options.
|
|
73980
|
+
* @returns The import: artefact identity, completeness, item counts by
|
|
73981
|
+
* disposition, reconciliation entries and proposed record counts.
|
|
73982
|
+
* @throws {@link VocabularyRefusedError} 403 `vocabulary_actor_required`,
|
|
73983
|
+
* `vocabulary_authority_denied`, `vocabulary_authority_undetermined`; 404
|
|
73984
|
+
* `source_file_not_found`; 409 `vocabulary_plugin_unavailable`; 413
|
|
73985
|
+
* `source_too_large` (over 20 MiB); 422 `format_unsupported`,
|
|
73986
|
+
* `invalid_request`.
|
|
73987
|
+
* @throws {@link IdempotencyKeyReusedError} 422 when the key committed a different request.
|
|
73988
|
+
* @throws {@link MutationOutcomeUnconfirmedError} 503 when the commit outcome is unknown.
|
|
73989
|
+
*
|
|
73990
|
+
* @remarks
|
|
73991
|
+
* `POST /api/v1/vocabulary/imports` with `Idempotency-Key`. Upload the file
|
|
73992
|
+
* first with `client.sources.uploadFile` and pass its id. Permission
|
|
73993
|
+
* `author_vocabulary` on the tenant. An incomplete parse
|
|
73994
|
+
* (`complete: false`) can be read and paged, never committed. Recover an
|
|
73995
|
+
* unknown outcome with {@link VocabularyClient.getRequestOutcome}
|
|
73996
|
+
* (`'create_import'`).
|
|
73997
|
+
*
|
|
73998
|
+
* @example
|
|
73999
|
+
* ```typescript
|
|
74000
|
+
* const key = crypto.randomUUID(); // bind once; pass the same key on every retry
|
|
74001
|
+
* const file = await client.sources.uploadFile(new Blob([turtle]), 'scheme.ttl');
|
|
74002
|
+
* const proposal = await client.vocabulary.createImport(
|
|
74003
|
+
* {
|
|
74004
|
+
* sourceFileId: file.id,
|
|
74005
|
+
* format: 'turtle',
|
|
74006
|
+
* dataset: 'https://example.org/scheme',
|
|
74007
|
+
* targetScheme: { existing: { schemeId } },
|
|
74008
|
+
* },
|
|
74009
|
+
* { idempotencyKey: key },
|
|
74010
|
+
* );
|
|
74011
|
+
* ```
|
|
74012
|
+
*/
|
|
74013
|
+
async createImport(request, requestOptions) {
|
|
74014
|
+
const response = await this.api.createImport(
|
|
74015
|
+
CreateVocabularyImportRequestFromFrontToApi(request),
|
|
74016
|
+
idempotencyParams(requestOptions.idempotencyKey, requestOptions)
|
|
74017
|
+
).catch(rethrowVocabularyRefusal);
|
|
74018
|
+
return decodeResponse(response, VocabularyImportFromApiToFront);
|
|
74019
|
+
}
|
|
74020
|
+
/**
|
|
74021
|
+
* One import proposal.
|
|
74022
|
+
*
|
|
74023
|
+
* @param importId - The import (UUID).
|
|
74024
|
+
* @param requestOptions - Per-call options (timeout, retries, signal, headers).
|
|
74025
|
+
* @returns The import, with `committedRevisionId` once committed.
|
|
74026
|
+
* @throws {@link NotFoundError} 404 for an unknown import.
|
|
74027
|
+
* @throws {@link VocabularyRefusedError} 409 `vocabulary_plugin_unavailable`.
|
|
74028
|
+
*
|
|
74029
|
+
* @remarks
|
|
74030
|
+
* `GET /api/v1/vocabulary/imports/{import_id}`.
|
|
74031
|
+
*
|
|
74032
|
+
* @example
|
|
74033
|
+
* ```typescript
|
|
74034
|
+
* const proposal = await client.vocabulary.getImport(importId);
|
|
74035
|
+
* ```
|
|
74036
|
+
*/
|
|
74037
|
+
async getImport(importId, requestOptions) {
|
|
74038
|
+
const response = await this.api.getImport(importId, toRequestParams(requestOptions)).catch(rethrowVocabularyRefusal);
|
|
74039
|
+
return decodeResponse(response, VocabularyImportFromApiToFront);
|
|
74040
|
+
}
|
|
74041
|
+
/**
|
|
74042
|
+
* One page of an import's source items, by ordinal: what was read, where,
|
|
74043
|
+
* and what became of it.
|
|
74044
|
+
*
|
|
74045
|
+
* @param importId - The import (UUID).
|
|
74046
|
+
* @param query - A disposition filter and cursor paging (`limit` 1 to 500).
|
|
74047
|
+
* @param requestOptions - Per-call options (timeout, retries, signal, headers).
|
|
74048
|
+
* @returns The items, the next cursor and `complete`.
|
|
74049
|
+
* @throws {@link NotFoundError} 404 for an unknown import.
|
|
74050
|
+
* @throws {@link VocabularyRefusedError} 400 `invalid_request` (a malformed
|
|
74051
|
+
* cursor or limit); 409 `vocabulary_plugin_unavailable`.
|
|
74052
|
+
*
|
|
74053
|
+
* @remarks
|
|
74054
|
+
* `GET /api/v1/vocabulary/imports/{import_id}/items`. Nothing read is
|
|
74055
|
+
* dropped: a malformed part is a `rejected` item with its coordinates.
|
|
74056
|
+
*
|
|
74057
|
+
* @example
|
|
74058
|
+
* ```typescript
|
|
74059
|
+
* const rejected = await client.vocabulary.listImportItems(importId, {
|
|
74060
|
+
* disposition: 'rejected',
|
|
74061
|
+
* });
|
|
74062
|
+
* ```
|
|
74063
|
+
*/
|
|
74064
|
+
async listImportItems(importId, query, requestOptions) {
|
|
74065
|
+
const wire = pageQuery(query);
|
|
74066
|
+
if (query?.disposition !== void 0) wire.disposition = query.disposition;
|
|
74067
|
+
const response = await this.api.importItems(importId, wire, toRequestParams(requestOptions)).catch(rethrowVocabularyRefusal);
|
|
74068
|
+
return decodeResponse(response, VocabularyImportItemPageFromApiToFront);
|
|
74069
|
+
}
|
|
74070
|
+
/**
|
|
74071
|
+
* Commit an import proposal with the reviewer's decisions as one candidate
|
|
74072
|
+
* revision: a new candidate, or the next revision of `candidateId`.
|
|
74073
|
+
*
|
|
74074
|
+
* @param importId - The import (UUID).
|
|
74075
|
+
* @param request - The change reason, a title (new candidate) or a
|
|
74076
|
+
* `candidateId`, and one decision per reconciliation entry.
|
|
74077
|
+
* @param requestOptions - The required `idempotencyKey`, `ifMatch` when
|
|
74078
|
+
* `candidateId` is given, and per-call options.
|
|
74079
|
+
* @returns The candidate revision the import became.
|
|
74080
|
+
* @throws {@link PreconditionFailedError} 412 when `ifMatch` is not the head.
|
|
74081
|
+
* @throws {@link NotFoundError} 404 for an unknown import or candidate.
|
|
74082
|
+
* @throws {@link VocabularyRefusedError} 409 `import_incomplete`,
|
|
74083
|
+
* `import_already_committed`, `import_baseline_stale`,
|
|
74084
|
+
* `active_release_changed`, `candidate_closed`; 422
|
|
74085
|
+
* `reconciliation_undecided` (see `refusal.undecidedSourceKeys`),
|
|
74086
|
+
* `invalid_decision`, `import_too_large`, `invalid_records`; 428
|
|
74087
|
+
* `if_match_required`; 403 authority.
|
|
74088
|
+
* @throws {@link IdempotencyKeyReusedError} 422.
|
|
74089
|
+
* @throws {@link MutationOutcomeUnconfirmedError} 503.
|
|
74090
|
+
*
|
|
74091
|
+
* @remarks
|
|
74092
|
+
* `POST /api/v1/vocabulary/imports/{import_id}/commit` with
|
|
74093
|
+
* `Idempotency-Key` (and `If-Match` with `candidateId`). Source keys travel
|
|
74094
|
+
* as values, verbatim. The revision is a candidate: steward review,
|
|
74095
|
+
* approval, release and activation still apply. Recover an unknown outcome
|
|
74096
|
+
* with {@link VocabularyClient.getRequestOutcome} (`'commit_import'`).
|
|
74097
|
+
*
|
|
74098
|
+
* @example
|
|
74099
|
+
* ```typescript
|
|
74100
|
+
* const key = crypto.randomUUID(); // bind once; pass the same key on every retry
|
|
74101
|
+
* const revision = await client.vocabulary.commitImport(
|
|
74102
|
+
* importId,
|
|
74103
|
+
* {
|
|
74104
|
+
* title: 'Import the manufacturing scheme',
|
|
74105
|
+
* changeReason: 'Adopt the reviewed source',
|
|
74106
|
+
* decisions: proposal.reconciliation.map((entry) => ({
|
|
74107
|
+
* sourceKey: entry.sourceKey,
|
|
74108
|
+
* decision: 'create_new',
|
|
74109
|
+
* })),
|
|
74110
|
+
* },
|
|
74111
|
+
* { idempotencyKey: key },
|
|
74112
|
+
* );
|
|
74113
|
+
* ```
|
|
74114
|
+
*/
|
|
74115
|
+
async commitImport(importId, request, requestOptions) {
|
|
74116
|
+
const response = await this.api.commitImport(
|
|
74117
|
+
importId,
|
|
74118
|
+
CommitVocabularyImportRequestFromFrontToApi(request),
|
|
74119
|
+
idempotencyParams(requestOptions.idempotencyKey, requestOptions, requestOptions.ifMatch)
|
|
74120
|
+
).catch(rethrowVocabularyRefusal);
|
|
74121
|
+
return decodeResponse(response, VocabularyCandidateRevisionFromApiToFront);
|
|
74122
|
+
}
|
|
74123
|
+
// ---------------------------------------------------------------------------
|
|
74124
|
+
// Migration plans
|
|
74125
|
+
// ---------------------------------------------------------------------------
|
|
74126
|
+
/**
|
|
74127
|
+
* Store the reviewer's dispositions of legacy sorts over the current legacy
|
|
74128
|
+
* inventory. Converts nothing.
|
|
74129
|
+
*
|
|
74130
|
+
* @param request - One disposition per planned sort.
|
|
74131
|
+
* @param requestOptions - The required `idempotencyKey` and per-call options.
|
|
74132
|
+
* @returns The plan, with the fingerprint and per-sort usage of the inventory it binds.
|
|
74133
|
+
* @throws {@link VocabularyRefusedError} 422 `invalid_disposition` (a
|
|
74134
|
+
* `formal_in_use` sort planned `convert_lexical`), `invalid_request`; 400
|
|
74135
|
+
* `read_budget_exceeded`; 403 authority; 409 `vocabulary_plugin_unavailable`.
|
|
74136
|
+
* @throws {@link IdempotencyKeyReusedError} 422.
|
|
74137
|
+
* @throws {@link MutationOutcomeUnconfirmedError} 503.
|
|
74138
|
+
*
|
|
74139
|
+
* @remarks
|
|
74140
|
+
* `POST /api/v1/vocabulary/migration/plans` with `Idempotency-Key`. Read the
|
|
74141
|
+
* inventory first with {@link VocabularyClient.migrationPreview}. Recover an
|
|
74142
|
+
* unknown outcome with {@link VocabularyClient.getRequestOutcome}
|
|
74143
|
+
* (`'create_migration_plan'`).
|
|
74144
|
+
*
|
|
74145
|
+
* @example
|
|
74146
|
+
* ```typescript
|
|
74147
|
+
* const key = crypto.randomUUID(); // bind once; pass the same key on every retry
|
|
74148
|
+
* const plan = await client.vocabulary.createMigrationPlan(
|
|
74149
|
+
* { dispositions: [{ sortId, disposition: 'convert_lexical', rationale: 'Labels only' }] },
|
|
74150
|
+
* { idempotencyKey: key },
|
|
74151
|
+
* );
|
|
74152
|
+
* ```
|
|
74153
|
+
*/
|
|
74154
|
+
async createMigrationPlan(request, requestOptions) {
|
|
74155
|
+
const response = await this.api.createMigrationPlan(
|
|
74156
|
+
CreateVocabularyMigrationPlanRequestFromFrontToApi(request),
|
|
74157
|
+
idempotencyParams(requestOptions.idempotencyKey, requestOptions)
|
|
74158
|
+
).catch(rethrowVocabularyRefusal);
|
|
74159
|
+
return decodeResponse(response, VocabularyMigrationPlanFromApiToFront);
|
|
74160
|
+
}
|
|
74161
|
+
/**
|
|
74162
|
+
* One migration plan.
|
|
74163
|
+
*
|
|
74164
|
+
* @param planId - The plan (UUID).
|
|
74165
|
+
* @param requestOptions - Per-call options (timeout, retries, signal, headers).
|
|
74166
|
+
* @returns The plan.
|
|
74167
|
+
* @throws {@link NotFoundError} 404 for an unknown plan.
|
|
74168
|
+
* @throws {@link VocabularyRefusedError} 409 `vocabulary_plugin_unavailable`.
|
|
74169
|
+
*
|
|
74170
|
+
* @remarks
|
|
74171
|
+
* `GET /api/v1/vocabulary/migration/plans/{plan_id}`.
|
|
74172
|
+
*
|
|
74173
|
+
* @example
|
|
74174
|
+
* ```typescript
|
|
74175
|
+
* const plan = await client.vocabulary.getMigrationPlan(planId);
|
|
74176
|
+
* ```
|
|
74177
|
+
*/
|
|
74178
|
+
async getMigrationPlan(planId, requestOptions) {
|
|
74179
|
+
const response = await this.api.getMigrationPlan(planId, toRequestParams(requestOptions)).catch(rethrowVocabularyRefusal);
|
|
74180
|
+
return decodeResponse(response, VocabularyMigrationPlanFromApiToFront);
|
|
74181
|
+
}
|
|
74182
|
+
/**
|
|
74183
|
+
* Apply a migration plan as a new candidate on the active release.
|
|
74184
|
+
*
|
|
74185
|
+
* @param planId - The plan (UUID).
|
|
74186
|
+
* @param request - The title, the change reason, the target scheme and the
|
|
74187
|
+
* language of the legacy labels.
|
|
74188
|
+
* @param requestOptions - The required `idempotencyKey` and per-call options.
|
|
74189
|
+
* @returns The candidate revision: concepts, the `legacy_theory` artefact,
|
|
74190
|
+
* source associations and one `migration_decision` per planned sort.
|
|
74191
|
+
* @throws {@link NotFoundError} 404 for an unknown plan.
|
|
74192
|
+
* @throws {@link VocabularyRefusedError} 409 `migration_plan_stale` (the
|
|
74193
|
+
* legacy inventory changed; see `refusal.changedSorts`),
|
|
74194
|
+
* `active_release_changed`; 422 `invalid_records`, `import_too_large`;
|
|
74195
|
+
* 403 authority.
|
|
74196
|
+
* @throws {@link IdempotencyKeyReusedError} 422.
|
|
74197
|
+
* @throws {@link MutationOutcomeUnconfirmedError} 503.
|
|
74198
|
+
*
|
|
74199
|
+
* @remarks
|
|
74200
|
+
* `POST /api/v1/vocabulary/migration/plans/{plan_id}/apply` with
|
|
74201
|
+
* `Idempotency-Key`. No sort is converted, removed or reparented: the
|
|
74202
|
+
* candidate holds governed records only, and it still needs review,
|
|
74203
|
+
* approval, release and activation. Without `defaultLanguage` no label is
|
|
74204
|
+
* written. Recover an unknown outcome with
|
|
74205
|
+
* {@link VocabularyClient.getRequestOutcome} (`'apply_migration_plan'`).
|
|
74206
|
+
*
|
|
74207
|
+
* @example
|
|
74208
|
+
* ```typescript
|
|
74209
|
+
* const key = crypto.randomUUID(); // bind once; pass the same key on every retry
|
|
74210
|
+
* const revision = await client.vocabulary.applyMigrationPlan(
|
|
74211
|
+
* plan.planId,
|
|
74212
|
+
* {
|
|
74213
|
+
* title: 'Migrate the legacy vocabulary',
|
|
74214
|
+
* changeReason: 'Plan reviewed',
|
|
74215
|
+
* scheme: { existing: { schemeId } },
|
|
74216
|
+
* defaultLanguage: 'en',
|
|
74217
|
+
* },
|
|
74218
|
+
* { idempotencyKey: key },
|
|
74219
|
+
* );
|
|
74220
|
+
* ```
|
|
74221
|
+
*/
|
|
74222
|
+
async applyMigrationPlan(planId, request, requestOptions) {
|
|
74223
|
+
const response = await this.api.applyMigrationPlan(
|
|
74224
|
+
planId,
|
|
74225
|
+
ApplyVocabularyMigrationPlanRequestFromFrontToApi(request),
|
|
74226
|
+
idempotencyParams(requestOptions.idempotencyKey, requestOptions)
|
|
74227
|
+
).catch(rethrowVocabularyRefusal);
|
|
74228
|
+
return decodeResponse(response, VocabularyCandidateRevisionFromApiToFront);
|
|
74229
|
+
}
|
|
74230
|
+
// ---------------------------------------------------------------------------
|
|
74231
|
+
// Exports and SPARQL
|
|
74232
|
+
// ---------------------------------------------------------------------------
|
|
74233
|
+
/**
|
|
74234
|
+
* The records of a view as `kos-json/v1`, with the source preservation
|
|
74235
|
+
* inventory and a manifest.
|
|
74236
|
+
*
|
|
74237
|
+
* @param query - The view; the active release when absent.
|
|
74238
|
+
* @param requestOptions - Per-call options (timeout, retries, signal, headers).
|
|
74239
|
+
* @returns Every readable record by id, every `source_artifact` record, and
|
|
74240
|
+
* the manifest (record count, counts by kind, records digest, the records
|
|
74241
|
+
* that could not be read, the stored context manifest).
|
|
74242
|
+
* @throws {@link NotFoundError} 404 for an unknown release or revision.
|
|
74243
|
+
* @throws {@link VocabularyRefusedError} 400 `invalid_request`; 409
|
|
74244
|
+
* `vocabulary_plugin_unavailable`.
|
|
74245
|
+
*
|
|
74246
|
+
* @remarks
|
|
74247
|
+
* `GET /api/v1/vocabulary/exports/native`. A record that does not parse as
|
|
74248
|
+
* its kind is listed in `manifest.unreadable`, never dropped silently.
|
|
74249
|
+
*
|
|
74250
|
+
* @example
|
|
74251
|
+
* ```typescript
|
|
74252
|
+
* const exported = await client.vocabulary.exportNative();
|
|
74253
|
+
* console.log(exported.manifest.recordCount, exported.manifest.unreadable.length);
|
|
74254
|
+
* ```
|
|
74255
|
+
*/
|
|
74256
|
+
async exportNative(query, requestOptions) {
|
|
74257
|
+
const response = await this.api.exportNative(viewQuery(query?.view), toRequestParams(requestOptions)).catch(rethrowVocabularyRefusal);
|
|
74258
|
+
return decodeResponse(response, VocabularyNativeExportFromApiToFront);
|
|
74259
|
+
}
|
|
74260
|
+
/**
|
|
74261
|
+
* The SKOS projection of one scheme as Turtle or RDF/XML, with its
|
|
74262
|
+
* manifest: the IRI of every published record and what the projection does
|
|
74263
|
+
* not express.
|
|
74264
|
+
*
|
|
74265
|
+
* @param query - The view, the scheme, the RDF syntax and `includeProvenance`.
|
|
74266
|
+
* @param requestOptions - Per-call options (timeout, retries, signal, headers).
|
|
74267
|
+
* @returns The content, its media type, its SHA-256 and the manifest.
|
|
74268
|
+
* @throws {@link NotFoundError} 404 for an unknown scheme, release or revision.
|
|
74269
|
+
* @throws {@link VocabularyRefusedError} 400 `invalid_request`; 409
|
|
74270
|
+
* `vocabulary_plugin_unavailable`; 422 `export_unrepresentable`.
|
|
74271
|
+
*
|
|
74272
|
+
* @remarks
|
|
74273
|
+
* `GET /api/v1/vocabulary/exports/skos` (`skos-projection/v1`,
|
|
74274
|
+
* `concept-iri/v1`). Read `manifest.losses` before treating the content as
|
|
74275
|
+
* the whole vocabulary: governance records, evidence and other schemes are
|
|
74276
|
+
* not projected.
|
|
74277
|
+
*
|
|
74278
|
+
* @example
|
|
74279
|
+
* ```typescript
|
|
74280
|
+
* const skos = await client.vocabulary.exportSkos({ schemeId, format: 'turtle' });
|
|
74281
|
+
* for (const loss of skos.manifest.losses) console.log(loss.kind, loss.recordIds.length);
|
|
74282
|
+
* ```
|
|
74283
|
+
*/
|
|
74284
|
+
async exportSkos(query, requestOptions) {
|
|
74285
|
+
const wire = {
|
|
74286
|
+
...viewQuery(query.view),
|
|
74287
|
+
scheme_id: query.schemeId
|
|
74288
|
+
};
|
|
74289
|
+
if (query.format !== void 0) wire.format = query.format;
|
|
74290
|
+
if (query.includeProvenance !== void 0) wire.include_provenance = query.includeProvenance;
|
|
74291
|
+
const response = await this.api.exportSkos(wire, toRequestParams(requestOptions)).catch(rethrowVocabularyRefusal);
|
|
74292
|
+
return decodeResponse(response, VocabularySkosExportFromApiToFront);
|
|
74293
|
+
}
|
|
74294
|
+
/**
|
|
74295
|
+
* One read-only SPARQL query over the SKOS projection of one scheme of one
|
|
74296
|
+
* view.
|
|
74297
|
+
*
|
|
74298
|
+
* @param request - The query, the scheme, the view and `maxResults` (1 to 100000).
|
|
74299
|
+
* @param requestOptions - Per-call options (timeout, retries, signal, headers).
|
|
74300
|
+
* @returns The answer, discriminated by `form`: the W3C results document
|
|
74301
|
+
* for `select` and `ask`, N-Triples for `construct` and `describe`; the
|
|
74302
|
+
* dataset it was computed over; `complete` and `stopReason`.
|
|
74303
|
+
* @throws {@link VocabularyRefusedError} 400 `sparql_unsupported` (an
|
|
74304
|
+
* update, a `SERVICE` clause or a `FROM`/`FROM NAMED` clause),
|
|
74305
|
+
* `invalid_request` (a query that does not parse); 422
|
|
74306
|
+
* `export_unrepresentable` (the projection holds a value the dataset
|
|
74307
|
+
* cannot load); 503 `vocabulary_sparql_unavailable`, `sparql_deadline`
|
|
74308
|
+
* (no answer before the deadline); 409 `vocabulary_plugin_unavailable`.
|
|
74309
|
+
* @throws {@link NotFoundError} 404 for an unknown scheme, release or revision.
|
|
74310
|
+
*
|
|
74311
|
+
* @remarks
|
|
74312
|
+
* `POST /api/v1/vocabulary/sparql`. The query is a string value: the body
|
|
74313
|
+
* transform never changes it. A reached `maxResults` or deadline answers
|
|
74314
|
+
* `complete: false` with `stopReason`.
|
|
74315
|
+
*
|
|
74316
|
+
* @example
|
|
74317
|
+
* ```typescript
|
|
74318
|
+
* const answer = await client.vocabulary.sparql({
|
|
74319
|
+
* schemeId,
|
|
74320
|
+
* query: 'SELECT ?c WHERE { ?c a <http://www.w3.org/2004/02/skos/core#Concept> }',
|
|
74321
|
+
* });
|
|
74322
|
+
* if (answer.form === 'select') console.log(answer.results.results.bindings.length);
|
|
74323
|
+
* ```
|
|
74324
|
+
*/
|
|
74325
|
+
async sparql(request, requestOptions) {
|
|
74326
|
+
const response = await this.api.sparqlQuery(VocabularySparqlRequestFromFrontToApi(request), toRequestParams(requestOptions)).catch(rethrowVocabularyRefusal);
|
|
74327
|
+
return decodeResponse(response, VocabularySparqlResultFromApiToFront);
|
|
74328
|
+
}
|
|
71271
74329
|
};
|
|
71272
74330
|
|
|
71273
74331
|
// src/normalizers/plugins.ts
|