@operato/ops-contract 0.9.37 → 0.9.38
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/epcis.d.ts +51 -2
- package/dist/epcis.js +57 -2
- package/dist/wms-profile.d.ts +20 -1
- package/dist/wms-profile.js +20 -1
- package/dist/yms-profile.d.ts +9 -1
- package/dist/yms-profile.js +10 -1
- package/dist-cjs/index.cjs +1236 -1183
- package/package.json +1 -1
package/dist/epcis.d.ts
CHANGED
|
@@ -38,6 +38,13 @@ export declare const DISP: {
|
|
|
38
38
|
* 준다(지어낸 값의 JSON-LD 가 실재 값과 바이트까지 같았다). 그 경로를 근거로 삼지 말 것.
|
|
39
39
|
*/
|
|
40
40
|
readonly expired: "urn:epcglobal:cbv:disp:expired";
|
|
41
|
+
/**
|
|
42
|
+
* **폐기됐다 — 남은 것이 없다.** CBV `destroyed` (CBV ontology, `Disp-destroyed`), with the step
|
|
43
|
+
* `CBV_BIZSTEP.destroying`. Ruled 2026-09-24, shape from plant: the disposition belongs to the quantity
|
|
44
|
+
* **observed**, which is what is left. A partial scrap leaves the rest `in_progress`; only the last of it —
|
|
45
|
+
* nothing left — is `destroyed`. Putting it on a remainder would say sound goods were thrown away.
|
|
46
|
+
*/
|
|
47
|
+
readonly destroyed: "urn:epcglobal:cbv:disp:destroyed";
|
|
41
48
|
/**
|
|
42
49
|
* **검사에 합격했다 / 불합격했다** — CBV `conformant` / `non_conformant`.
|
|
43
50
|
*
|
|
@@ -61,6 +68,42 @@ export declare const DISP: {
|
|
|
61
68
|
readonly conformant: "urn:epcglobal:cbv:disp:conformant";
|
|
62
69
|
readonly non_conformant: "urn:epcglobal:cbv:disp:non_conformant";
|
|
63
70
|
};
|
|
71
|
+
/**
|
|
72
|
+
* **The one namespace this contract's own vocabulary stands under** — for a term a standard does not have.
|
|
73
|
+
*
|
|
74
|
+
* EPCIS 2.0 lets a business step, a business transaction type or a disposition be any URI **its owner
|
|
75
|
+
* assigns**; only the `urn:epcglobal:cbv:` space is CBV's, and that space is a closed list (the closed-list
|
|
76
|
+
* tests hold it). This prefix is owned by hatiolab.com. It is an identifier, **not an address: it is not
|
|
77
|
+
* dereferenced**, and a 404 at it is not a defect.
|
|
78
|
+
*
|
|
79
|
+
* Every private term goes under this one constant (chief architect, 2026-09-24) — a second private
|
|
80
|
+
* vocabulary under a second prefix is what this is here to prevent.
|
|
81
|
+
*/
|
|
82
|
+
export declare const HATIOLAB_VOCABULARY = "https://hatiolab.com/voc/";
|
|
83
|
+
/**
|
|
84
|
+
* **Business steps CBV does not have** — kept apart from the CBV bundles on purpose. A private value inside
|
|
85
|
+
* `CBV_BIZSTEP` would be read by the next person as CBV's.
|
|
86
|
+
*
|
|
87
|
+
* `consuming` was `urn:epcglobal:cbv:bizstep:consuming` until 2026-09-24; CBV defines no such step (CBV
|
|
88
|
+
* ontology, 41 steps; ref.gs1.org), and none of its steps means "material went into a process". Readers do
|
|
89
|
+
* not branch on the value, and the journal keeps what it already wrote (ADR-0038).
|
|
90
|
+
*/
|
|
91
|
+
export declare const PRIVATE_BIZSTEP: {
|
|
92
|
+
/** 공정에 자재가 들어갔다 — ISA-95 `MaterialUse: Consumed`. */
|
|
93
|
+
readonly consuming: "https://hatiolab.com/voc/bizstep/consuming";
|
|
94
|
+
};
|
|
95
|
+
/**
|
|
96
|
+
* **A business step's short name** — the last segment of its URI, cut at the last `:` or `/`.
|
|
97
|
+
*
|
|
98
|
+
* A CBV step is a URN (`urn:epcglobal:cbv:bizstep:staging_outbound`), a private one is an http URI
|
|
99
|
+
* (`https://hatiolab.com/voc/bizstep/consuming`). Cutting at `:` alone gave `//hatiolab.com/voc/bizstep/consuming`
|
|
100
|
+
* for the second, so a journal index, a filter and a `twin.bizstep.*` label all missed. The short name drops the
|
|
101
|
+
* namespace, so no private short name may equal a CBV one — `cbv-bizstep-values-exist.test.ts` holds that.
|
|
102
|
+
*
|
|
103
|
+
* Only a URI is read here. An empty value, or one that ends in a separator, has no name and answers
|
|
104
|
+
* `undefined`; what to fall back on (an event type, say) is the caller's to decide. A bare word passes as itself.
|
|
105
|
+
*/
|
|
106
|
+
export declare function bizStepName(uri: string | null | undefined): string | undefined;
|
|
64
107
|
/**
|
|
65
108
|
* **자재 소비·산출의 CBV 단계** — 도메인 무관하게 코어가 쓴다.
|
|
66
109
|
*
|
|
@@ -68,8 +111,13 @@ export declare const DISP: {
|
|
|
68
111
|
* 코어에 있어야 한다. 프로파일 하나에 두면 다른 업종이 그것을 가져다 쓰면서 방언이 생긴다.
|
|
69
112
|
*/
|
|
70
113
|
export declare const CBV_BIZSTEP: {
|
|
71
|
-
/**
|
|
72
|
-
|
|
114
|
+
/**
|
|
115
|
+
* **폐기 — 물건이 끝났다.** CBV `destroying`: "Process of terminating an object. For an instance-level
|
|
116
|
+
* identifier, the object should not be the subject of subsequent events" (CBV ontology, `BizStep-destroying`).
|
|
117
|
+
* Ruled 2026-09-24 (chief architect) — plant wrote scrapping as `other`; the warehouse's disposal door uses the
|
|
118
|
+
* same step. Not a count, and not a correction: the goods are gone.
|
|
119
|
+
*/
|
|
120
|
+
readonly destroying: "urn:epcglobal:cbv:bizstep:destroying";
|
|
73
121
|
/** 새 물품이 생겨 계보가 시작된다 — ISA-95 `MaterialUse: Produced`. */
|
|
74
122
|
readonly commissioning: "urn:epcglobal:cbv:bizstep:commissioning";
|
|
75
123
|
/**
|
|
@@ -155,6 +203,7 @@ export interface QuantityElement {
|
|
|
155
203
|
export interface BizTransactionElement {
|
|
156
204
|
/**
|
|
157
205
|
* The kind of document — a CBV business transaction type, or a private URI for a kind CBV does not have.
|
|
206
|
+
* A private one stands under `HATIOLAB_VOCABULARY` (`…/voc/btt/<name>`), never under a prefix of its own.
|
|
158
207
|
*
|
|
159
208
|
* **Optional, as in EPCIS 2.0**: only `bizTransaction` is required. When CBV has no value for the
|
|
160
209
|
* document, leave this out — do not coin one under `urn:epcglobal:cbv:btt:`. That namespace is a
|
package/dist/epcis.js
CHANGED
|
@@ -47,6 +47,13 @@ export const DISP = {
|
|
|
47
47
|
* 준다(지어낸 값의 JSON-LD 가 실재 값과 바이트까지 같았다). 그 경로를 근거로 삼지 말 것.
|
|
48
48
|
*/
|
|
49
49
|
expired: 'urn:epcglobal:cbv:disp:expired',
|
|
50
|
+
/**
|
|
51
|
+
* **폐기됐다 — 남은 것이 없다.** CBV `destroyed` (CBV ontology, `Disp-destroyed`), with the step
|
|
52
|
+
* `CBV_BIZSTEP.destroying`. Ruled 2026-09-24, shape from plant: the disposition belongs to the quantity
|
|
53
|
+
* **observed**, which is what is left. A partial scrap leaves the rest `in_progress`; only the last of it —
|
|
54
|
+
* nothing left — is `destroyed`. Putting it on a remainder would say sound goods were thrown away.
|
|
55
|
+
*/
|
|
56
|
+
destroyed: 'urn:epcglobal:cbv:disp:destroyed',
|
|
50
57
|
/**
|
|
51
58
|
* **검사에 합격했다 / 불합격했다** — CBV `conformant` / `non_conformant`.
|
|
52
59
|
*
|
|
@@ -70,6 +77,48 @@ export const DISP = {
|
|
|
70
77
|
conformant: 'urn:epcglobal:cbv:disp:conformant',
|
|
71
78
|
non_conformant: 'urn:epcglobal:cbv:disp:non_conformant'
|
|
72
79
|
};
|
|
80
|
+
/**
|
|
81
|
+
* **The one namespace this contract's own vocabulary stands under** — for a term a standard does not have.
|
|
82
|
+
*
|
|
83
|
+
* EPCIS 2.0 lets a business step, a business transaction type or a disposition be any URI **its owner
|
|
84
|
+
* assigns**; only the `urn:epcglobal:cbv:` space is CBV's, and that space is a closed list (the closed-list
|
|
85
|
+
* tests hold it). This prefix is owned by hatiolab.com. It is an identifier, **not an address: it is not
|
|
86
|
+
* dereferenced**, and a 404 at it is not a defect.
|
|
87
|
+
*
|
|
88
|
+
* Every private term goes under this one constant (chief architect, 2026-09-24) — a second private
|
|
89
|
+
* vocabulary under a second prefix is what this is here to prevent.
|
|
90
|
+
*/
|
|
91
|
+
export const HATIOLAB_VOCABULARY = 'https://hatiolab.com/voc/';
|
|
92
|
+
/**
|
|
93
|
+
* **Business steps CBV does not have** — kept apart from the CBV bundles on purpose. A private value inside
|
|
94
|
+
* `CBV_BIZSTEP` would be read by the next person as CBV's.
|
|
95
|
+
*
|
|
96
|
+
* `consuming` was `urn:epcglobal:cbv:bizstep:consuming` until 2026-09-24; CBV defines no such step (CBV
|
|
97
|
+
* ontology, 41 steps; ref.gs1.org), and none of its steps means "material went into a process". Readers do
|
|
98
|
+
* not branch on the value, and the journal keeps what it already wrote (ADR-0038).
|
|
99
|
+
*/
|
|
100
|
+
export const PRIVATE_BIZSTEP = {
|
|
101
|
+
/** 공정에 자재가 들어갔다 — ISA-95 `MaterialUse: Consumed`. */
|
|
102
|
+
consuming: `${HATIOLAB_VOCABULARY}bizstep/consuming`
|
|
103
|
+
};
|
|
104
|
+
/**
|
|
105
|
+
* **A business step's short name** — the last segment of its URI, cut at the last `:` or `/`.
|
|
106
|
+
*
|
|
107
|
+
* A CBV step is a URN (`urn:epcglobal:cbv:bizstep:staging_outbound`), a private one is an http URI
|
|
108
|
+
* (`https://hatiolab.com/voc/bizstep/consuming`). Cutting at `:` alone gave `//hatiolab.com/voc/bizstep/consuming`
|
|
109
|
+
* for the second, so a journal index, a filter and a `twin.bizstep.*` label all missed. The short name drops the
|
|
110
|
+
* namespace, so no private short name may equal a CBV one — `cbv-bizstep-values-exist.test.ts` holds that.
|
|
111
|
+
*
|
|
112
|
+
* Only a URI is read here. An empty value, or one that ends in a separator, has no name and answers
|
|
113
|
+
* `undefined`; what to fall back on (an event type, say) is the caller's to decide. A bare word passes as itself.
|
|
114
|
+
*/
|
|
115
|
+
export function bizStepName(uri) {
|
|
116
|
+
const s = String(uri ?? '').trim();
|
|
117
|
+
if (!s)
|
|
118
|
+
return undefined;
|
|
119
|
+
const name = s.slice(Math.max(s.lastIndexOf(':'), s.lastIndexOf('/')) + 1);
|
|
120
|
+
return name || undefined;
|
|
121
|
+
}
|
|
73
122
|
/**
|
|
74
123
|
* **자재 소비·산출의 CBV 단계** — 도메인 무관하게 코어가 쓴다.
|
|
75
124
|
*
|
|
@@ -77,8 +126,14 @@ export const DISP = {
|
|
|
77
126
|
* 코어에 있어야 한다. 프로파일 하나에 두면 다른 업종이 그것을 가져다 쓰면서 방언이 생긴다.
|
|
78
127
|
*/
|
|
79
128
|
export const CBV_BIZSTEP = {
|
|
80
|
-
|
|
81
|
-
|
|
129
|
+
/* 소비(`consuming`)는 CBV 에 없어 `PRIVATE_BIZSTEP` 으로 갔다(2026-09-24). */
|
|
130
|
+
/**
|
|
131
|
+
* **폐기 — 물건이 끝났다.** CBV `destroying`: "Process of terminating an object. For an instance-level
|
|
132
|
+
* identifier, the object should not be the subject of subsequent events" (CBV ontology, `BizStep-destroying`).
|
|
133
|
+
* Ruled 2026-09-24 (chief architect) — plant wrote scrapping as `other`; the warehouse's disposal door uses the
|
|
134
|
+
* same step. Not a count, and not a correction: the goods are gone.
|
|
135
|
+
*/
|
|
136
|
+
destroying: 'urn:epcglobal:cbv:bizstep:destroying',
|
|
82
137
|
/** 새 물품이 생겨 계보가 시작된다 — ISA-95 `MaterialUse: Produced`. */
|
|
83
138
|
commissioning: 'urn:epcglobal:cbv:bizstep:commissioning',
|
|
84
139
|
/**
|
package/dist/wms-profile.d.ts
CHANGED
|
@@ -6,7 +6,26 @@ export declare const BIZSTEP: {
|
|
|
6
6
|
readonly packing: "urn:epcglobal:cbv:bizstep:packing";
|
|
7
7
|
readonly staging_outbound: "urn:epcglobal:cbv:bizstep:staging_outbound";
|
|
8
8
|
readonly shipping: "urn:epcglobal:cbv:bizstep:shipping";
|
|
9
|
-
|
|
9
|
+
/**
|
|
10
|
+
* **Replenishment** — moving goods to where they are picked from. CBV has no `replenishing`; this contract
|
|
11
|
+
* wrote one until 2026-09-24, and the closed-list test found it. CBV `stocking` is the step that means it:
|
|
12
|
+
* "…within a location to make an object available to the customer or for order fulfilment within a DC"
|
|
13
|
+
* (CBV ontology, `BizStep-stocking`). Ruled by the chief architect; no reader branches on the value, and
|
|
14
|
+
* the journal keeps what it already wrote (ADR-0038).
|
|
15
|
+
*/
|
|
16
|
+
readonly stocking: "urn:epcglobal:cbv:bizstep:stocking";
|
|
17
|
+
/**
|
|
18
|
+
* **Counted, and the book set to the count** — CBV `cycle_counting`. Primary source: the CBV ontology
|
|
19
|
+
* (gs1/EPCIS `Ontology/CBV.ttl`, `cbv:BizStep-cycle_counting`, also served at ref.gs1.org/cbv): "Process of
|
|
20
|
+
* counting objects within a location in order to obtain an accurate inventory for business needs other
|
|
21
|
+
* than accounting purposes (e.g., replenishment and allocation)."
|
|
22
|
+
*
|
|
23
|
+
* **Only for an event somebody actually counted** (chief architect, 2026-09-24). A person correcting the
|
|
24
|
+
* book without counting is `CBV_BIZSTEP.other` with the reason carried as a value — `epcis.ts` says why:
|
|
25
|
+
* writing that as `cycle_counting` records a count that never happened. A count for the accounts is a
|
|
26
|
+
* different CBV step (`stock_taking`) and is not this one.
|
|
27
|
+
*/
|
|
28
|
+
readonly cycle_counting: "urn:epcglobal:cbv:bizstep:cycle_counting";
|
|
10
29
|
};
|
|
11
30
|
export declare const BTT: {
|
|
12
31
|
/** Purchase Order — the document an inbound receipt is made against. */
|
package/dist/wms-profile.js
CHANGED
|
@@ -6,7 +6,26 @@ export const BIZSTEP = {
|
|
|
6
6
|
packing: 'urn:epcglobal:cbv:bizstep:packing',
|
|
7
7
|
staging_outbound: 'urn:epcglobal:cbv:bizstep:staging_outbound',
|
|
8
8
|
shipping: 'urn:epcglobal:cbv:bizstep:shipping',
|
|
9
|
-
|
|
9
|
+
/**
|
|
10
|
+
* **Replenishment** — moving goods to where they are picked from. CBV has no `replenishing`; this contract
|
|
11
|
+
* wrote one until 2026-09-24, and the closed-list test found it. CBV `stocking` is the step that means it:
|
|
12
|
+
* "…within a location to make an object available to the customer or for order fulfilment within a DC"
|
|
13
|
+
* (CBV ontology, `BizStep-stocking`). Ruled by the chief architect; no reader branches on the value, and
|
|
14
|
+
* the journal keeps what it already wrote (ADR-0038).
|
|
15
|
+
*/
|
|
16
|
+
stocking: 'urn:epcglobal:cbv:bizstep:stocking',
|
|
17
|
+
/**
|
|
18
|
+
* **Counted, and the book set to the count** — CBV `cycle_counting`. Primary source: the CBV ontology
|
|
19
|
+
* (gs1/EPCIS `Ontology/CBV.ttl`, `cbv:BizStep-cycle_counting`, also served at ref.gs1.org/cbv): "Process of
|
|
20
|
+
* counting objects within a location in order to obtain an accurate inventory for business needs other
|
|
21
|
+
* than accounting purposes (e.g., replenishment and allocation)."
|
|
22
|
+
*
|
|
23
|
+
* **Only for an event somebody actually counted** (chief architect, 2026-09-24). A person correcting the
|
|
24
|
+
* book without counting is `CBV_BIZSTEP.other` with the reason carried as a value — `epcis.ts` says why:
|
|
25
|
+
* writing that as `cycle_counting` records a count that never happened. A count for the accounts is a
|
|
26
|
+
* different CBV step (`stock_taking`) and is not this one.
|
|
27
|
+
*/
|
|
28
|
+
cycle_counting: 'urn:epcglobal:cbv:bizstep:cycle_counting'
|
|
10
29
|
};
|
|
11
30
|
/*
|
|
12
31
|
* Business transaction types — CBV btt. Every value here exists at ref.gs1.org/cbv (checked
|
package/dist/yms-profile.d.ts
CHANGED
|
@@ -1,11 +1,19 @@
|
|
|
1
1
|
import type { TwinTypeInfo } from './domain-catalog.ts';
|
|
2
2
|
export declare const YARD_BIZSTEP: {
|
|
3
3
|
readonly arriving: "urn:epcglobal:cbv:bizstep:arriving";
|
|
4
|
-
readonly staging: "urn:epcglobal:cbv:bizstep:staging";
|
|
5
4
|
readonly loading: "urn:epcglobal:cbv:bizstep:loading";
|
|
6
5
|
readonly unloading: "urn:epcglobal:cbv:bizstep:unloading";
|
|
7
6
|
readonly departing: "urn:epcglobal:cbv:bizstep:departing";
|
|
8
7
|
};
|
|
8
|
+
/**
|
|
9
|
+
* **Yard steps CBV does not have.** `staging` (a trailer parked in a yard slot, waiting) was
|
|
10
|
+
* `urn:epcglobal:cbv:bizstep:staging` until 2026-09-24 — CBV defines no such step; `staging_outbound` is a
|
|
11
|
+
* warehouse's move towards shipping, not a trailer waiting. Kept apart from `YARD_BIZSTEP` so a private value
|
|
12
|
+
* is never read as CBV's.
|
|
13
|
+
*/
|
|
14
|
+
export declare const YARD_PRIVATE_BIZSTEP: {
|
|
15
|
+
readonly staging: "https://hatiolab.com/voc/bizstep/staging";
|
|
16
|
+
};
|
|
9
17
|
/** 트레일러/컨테이너 = GRAI(Global Returnable Asset Identifier, 반납형 자산). */
|
|
10
18
|
export declare function graiUri(companyPrefix: string, assetType: string, serial: number): string;
|
|
11
19
|
/** YMS 자리 타입 카탈로그 — 커널이 키로 쓰는 야드 로케이션 타입(locationByType/slotViews/.type). 도메인 SSOT. */
|
package/dist/yms-profile.js
CHANGED
|
@@ -1,11 +1,20 @@
|
|
|
1
|
+
import { HATIOLAB_VOCABULARY } from "./epcis.js";
|
|
1
2
|
// 야드 bizStep — CBV (yms.md §11).
|
|
2
3
|
export const YARD_BIZSTEP = {
|
|
3
4
|
arriving: 'urn:epcglobal:cbv:bizstep:arriving', // 게이트-인
|
|
4
|
-
staging: 'urn:epcglobal:cbv:bizstep:staging', // 야드 슬롯 주차·대기
|
|
5
5
|
loading: 'urn:epcglobal:cbv:bizstep:loading', // 도크 작업(상차: 트레일러←화물)
|
|
6
6
|
unloading: 'urn:epcglobal:cbv:bizstep:unloading', // 도크 작업(하차: 트레일러→화물)
|
|
7
7
|
departing: 'urn:epcglobal:cbv:bizstep:departing' // 게이트-아웃
|
|
8
8
|
};
|
|
9
|
+
/**
|
|
10
|
+
* **Yard steps CBV does not have.** `staging` (a trailer parked in a yard slot, waiting) was
|
|
11
|
+
* `urn:epcglobal:cbv:bizstep:staging` until 2026-09-24 — CBV defines no such step; `staging_outbound` is a
|
|
12
|
+
* warehouse's move towards shipping, not a trailer waiting. Kept apart from `YARD_BIZSTEP` so a private value
|
|
13
|
+
* is never read as CBV's.
|
|
14
|
+
*/
|
|
15
|
+
export const YARD_PRIVATE_BIZSTEP = {
|
|
16
|
+
staging: `${HATIOLAB_VOCABULARY}bizstep/staging` // 야드 슬롯 주차·대기
|
|
17
|
+
};
|
|
9
18
|
/*
|
|
10
19
|
* A dock appointment has **no CBV business transaction type** — `btt:deliv`, which this file used to
|
|
11
20
|
* export, does not exist at ref.gs1.org/cbv. The kernel now links the appointment by its id alone
|