@loxtep/sdk 0.9.17 → 0.9.19

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.
Files changed (44) hide show
  1. package/CHANGELOG.md +24 -0
  2. package/dist/cli/commands/define-cmd.d.ts +51 -0
  3. package/dist/cli/commands/define-cmd.d.ts.map +1 -0
  4. package/dist/cli/commands/define-cmd.js +244 -0
  5. package/dist/cli/commands/define-cmd.js.map +1 -0
  6. package/dist/cli/help.d.ts.map +1 -1
  7. package/dist/cli/help.js +9 -0
  8. package/dist/cli/help.js.map +1 -1
  9. package/dist/cli/index.d.ts.map +1 -1
  10. package/dist/cli/index.js +68 -0
  11. package/dist/cli/index.js.map +1 -1
  12. package/dist/client/bundles-types.d.ts +11 -3
  13. package/dist/client/bundles-types.d.ts.map +1 -1
  14. package/dist/client/bundles.d.ts.map +1 -1
  15. package/dist/client/bundles.js +5 -2
  16. package/dist/client/bundles.js.map +1 -1
  17. package/dist/client/define.d.ts +4 -1
  18. package/dist/client/define.d.ts.map +1 -1
  19. package/dist/client/define.js +2 -1
  20. package/dist/client/define.js.map +1 -1
  21. package/dist/client/index.d.ts +3 -1
  22. package/dist/client/index.d.ts.map +1 -1
  23. package/dist/client/index.js.map +1 -1
  24. package/dist/client/loxtep-client.d.ts.map +1 -1
  25. package/dist/client/loxtep-client.js +2 -0
  26. package/dist/client/loxtep-client.js.map +1 -1
  27. package/dist/client/ontology-types.d.ts +38 -0
  28. package/dist/client/ontology-types.d.ts.map +1 -1
  29. package/dist/client/ontology.d.ts +6 -1
  30. package/dist/client/ontology.d.ts.map +1 -1
  31. package/dist/client/ontology.js +15 -0
  32. package/dist/client/ontology.js.map +1 -1
  33. package/dist/client/product-definition-types.d.ts +53 -0
  34. package/dist/client/product-definition-types.d.ts.map +1 -0
  35. package/dist/client/product-definition-types.js +6 -0
  36. package/dist/client/product-definition-types.js.map +1 -0
  37. package/dist/client/product-definition.d.ts +30 -0
  38. package/dist/client/product-definition.d.ts.map +1 -0
  39. package/dist/client/product-definition.js +137 -0
  40. package/dist/client/product-definition.js.map +1 -0
  41. package/dist/client/thesaurus-types.d.ts +2 -0
  42. package/dist/client/thesaurus-types.d.ts.map +1 -1
  43. package/docs/sdk-mcp-mapping.md +39 -1
  44. package/package.json +1 -1
package/CHANGELOG.md CHANGED
@@ -8,6 +8,30 @@ and this project adheres to
8
8
 
9
9
  ## [Unreleased]
10
10
 
11
+ ## [0.9.19] - 2026-10-01
12
+
13
+ ### Added
14
+
15
+ - **Product definition proposals** (`client.define.product_definition`)
16
+ - MCP `loxtep_define` ops: evidence, submit/revise/list shape + semantic
17
+ bindings, skill, batch, start procedure.
18
+ - Thin REST: status, approve, apply, withdraw
19
+ (`/semantic-layer/product-definition`).
20
+ - CLI: `loxtep define status|evidence|list|get|submit-shape|submit-semantic|
21
+ approve|apply|withdraw|skill|start-procedure|batch`.
22
+ - Docs: `docs/sdk-mcp-mapping.md` product-definition section.
23
+
24
+ ## [0.9.18] - 2026-09-28
25
+
26
+ ### Added
27
+
28
+ - **Authored concept registration parity**
29
+ - `create_concept` accepts optional `canonical_key` and `aliases`.
30
+ - `client.meaning.ontology.repair_vocabulary` →
31
+ `POST /semantic-layer/migrations/ontology-vocabulary-repair` (dry-run default).
32
+ - Thesaurus term type includes `concept_uri`.
33
+ - Bundle import result surfaces `loss_report` (Python `import_` too).
34
+
11
35
  ## [0.9.17] - 2026-09-28
12
36
 
13
37
  ### Added
@@ -0,0 +1,51 @@
1
+ /**
2
+ * CLI: loxtep define …
3
+ *
4
+ * Mirrors MCP `loxtep_define` product-definition ops + thin REST status/actions.
5
+ *
6
+ * loxtep define status <data_product_id>
7
+ * loxtep define evidence <data_product_id>
8
+ * loxtep define list [--data-product-id <id>] [--disposition <val>] [--proposal-type product_shape|product_semantic_bindings]
9
+ * loxtep define get <semantic_proposal_id>
10
+ * loxtep define submit-shape <data_product_id> --definition <json> [--rationale …] [--base-revision …] [--evidence-refs <csv>]
11
+ * loxtep define submit-semantic <data_product_id> [--definition <json>] [--rationale …]
12
+ * loxtep define approve|apply|withdraw <semantic_proposal_id>
13
+ * loxtep define skill
14
+ * loxtep define start-procedure <data_product_id>
15
+ * loxtep define batch --data-product-ids <id,id> [--action status|evidence]
16
+ */
17
+ import type { LoxtepClient } from '../../client/loxtep-client.js';
18
+ import type { CliResult } from '../project-context.js';
19
+ export declare function runDefineStatusCommand(client: LoxtepClient, data_product_id: string): Promise<CliResult>;
20
+ export declare function runDefineEvidenceCommand(client: LoxtepClient, data_product_id: string): Promise<CliResult>;
21
+ export interface DefineListOptions {
22
+ data_product_id?: string;
23
+ disposition?: string;
24
+ proposal_type?: string;
25
+ }
26
+ export declare function runDefineListCommand(client: LoxtepClient, options?: DefineListOptions): Promise<CliResult>;
27
+ export declare function runDefineGetCommand(client: LoxtepClient, semantic_proposal_id: string): Promise<CliResult>;
28
+ export interface DefineSubmitShapeOptions {
29
+ definition_json?: string;
30
+ rationale?: string;
31
+ base_revision?: string;
32
+ evidence_refs?: string;
33
+ }
34
+ export declare function runDefineSubmitShapeCommand(client: LoxtepClient, data_product_id: string, options?: DefineSubmitShapeOptions): Promise<CliResult>;
35
+ export interface DefineSubmitSemanticOptions {
36
+ definition_json?: string;
37
+ rationale?: string;
38
+ }
39
+ export declare function runDefineSubmitSemanticCommand(client: LoxtepClient, data_product_id: string, options?: DefineSubmitSemanticOptions): Promise<CliResult>;
40
+ export declare function runDefineApproveCommand(client: LoxtepClient, semantic_proposal_id: string): Promise<CliResult>;
41
+ export declare function runDefineApplyCommand(client: LoxtepClient, semantic_proposal_id: string): Promise<CliResult>;
42
+ export declare function runDefineWithdrawCommand(client: LoxtepClient, semantic_proposal_id: string): Promise<CliResult>;
43
+ export declare function runDefineSkillCommand(client: LoxtepClient): Promise<CliResult>;
44
+ export declare function runDefineStartProcedureCommand(client: LoxtepClient, data_product_id: string): Promise<CliResult>;
45
+ export interface DefineBatchOptions {
46
+ data_product_ids?: string;
47
+ action?: string;
48
+ }
49
+ export declare function runDefineBatchCommand(client: LoxtepClient, options?: DefineBatchOptions): Promise<CliResult>;
50
+ export declare const DEFINE_USAGE: string;
51
+ //# sourceMappingURL=define-cmd.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"define-cmd.d.ts","sourceRoot":"","sources":["../../../src/cli/commands/define-cmd.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AAEH,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,+BAA+B,CAAC;AAClE,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,uBAAuB,CAAC;AAiCvD,wBAAsB,sBAAsB,CAC1C,MAAM,EAAE,YAAY,EACpB,eAAe,EAAE,MAAM,GACtB,OAAO,CAAC,SAAS,CAAC,CASpB;AAED,wBAAsB,wBAAwB,CAC5C,MAAM,EAAE,YAAY,EACpB,eAAe,EAAE,MAAM,GACtB,OAAO,CAAC,SAAS,CAAC,CAapB;AAED,MAAM,WAAW,iBAAiB;IAChC,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,aAAa,CAAC,EAAE,MAAM,CAAC;CACxB;AAED,wBAAsB,oBAAoB,CACxC,MAAM,EAAE,YAAY,EACpB,OAAO,CAAC,EAAE,iBAAiB,GAC1B,OAAO,CAAC,SAAS,CAAC,CAoBpB;AAED,wBAAsB,mBAAmB,CACvC,MAAM,EAAE,YAAY,EACpB,oBAAoB,EAAE,MAAM,GAC3B,OAAO,CAAC,SAAS,CAAC,CAapB;AAED,MAAM,WAAW,wBAAwB;IACvC,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,aAAa,CAAC,EAAE,MAAM,CAAC;CACxB;AAED,wBAAsB,2BAA2B,CAC/C,MAAM,EAAE,YAAY,EACpB,eAAe,EAAE,MAAM,EACvB,OAAO,CAAC,EAAE,wBAAwB,GACjC,OAAO,CAAC,SAAS,CAAC,CA6BpB;AAED,MAAM,WAAW,2BAA2B;IAC1C,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,wBAAsB,8BAA8B,CAClD,MAAM,EAAE,YAAY,EACpB,eAAe,EAAE,MAAM,EACvB,OAAO,CAAC,EAAE,2BAA2B,GACpC,OAAO,CAAC,SAAS,CAAC,CAgDpB;AAED,wBAAsB,uBAAuB,CAC3C,MAAM,EAAE,YAAY,EACpB,oBAAoB,EAAE,MAAM,GAC3B,OAAO,CAAC,SAAS,CAAC,CAepB;AAED,wBAAsB,qBAAqB,CACzC,MAAM,EAAE,YAAY,EACpB,oBAAoB,EAAE,MAAM,GAC3B,OAAO,CAAC,SAAS,CAAC,CAepB;AAED,wBAAsB,wBAAwB,CAC5C,MAAM,EAAE,YAAY,EACpB,oBAAoB,EAAE,MAAM,GAC3B,OAAO,CAAC,SAAS,CAAC,CAepB;AAED,wBAAsB,qBAAqB,CAAC,MAAM,EAAE,YAAY,GAAG,OAAO,CAAC,SAAS,CAAC,CAQpF;AAED,wBAAsB,8BAA8B,CAClD,MAAM,EAAE,YAAY,EACpB,eAAe,EAAE,MAAM,GACtB,OAAO,CAAC,SAAS,CAAC,CAepB;AAED,MAAM,WAAW,kBAAkB;IACjC,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED,wBAAsB,qBAAqB,CACzC,MAAM,EAAE,YAAY,EACpB,OAAO,CAAC,EAAE,kBAAkB,GAC3B,OAAO,CAAC,SAAS,CAAC,CA2BpB;AAED,eAAO,MAAM,YAAY,QAU2D,CAAC"}
@@ -0,0 +1,244 @@
1
+ /**
2
+ * CLI: loxtep define …
3
+ *
4
+ * Mirrors MCP `loxtep_define` product-definition ops + thin REST status/actions.
5
+ *
6
+ * loxtep define status <data_product_id>
7
+ * loxtep define evidence <data_product_id>
8
+ * loxtep define list [--data-product-id <id>] [--disposition <val>] [--proposal-type product_shape|product_semantic_bindings]
9
+ * loxtep define get <semantic_proposal_id>
10
+ * loxtep define submit-shape <data_product_id> --definition <json> [--rationale …] [--base-revision …] [--evidence-refs <csv>]
11
+ * loxtep define submit-semantic <data_product_id> [--definition <json>] [--rationale …]
12
+ * loxtep define approve|apply|withdraw <semantic_proposal_id>
13
+ * loxtep define skill
14
+ * loxtep define start-procedure <data_product_id>
15
+ * loxtep define batch --data-product-ids <id,id> [--action status|evidence]
16
+ */
17
+ function okJson(value) {
18
+ return { exitCode: 0, stdout: [JSON.stringify(value, null, 2)], stderr: [] };
19
+ }
20
+ function fail(message) {
21
+ return { exitCode: 1, stdout: [], stderr: [message] };
22
+ }
23
+ function parseJsonObject(raw, flag) {
24
+ if (raw == null || raw === '') {
25
+ return { ok: false, error: `${flag} is required and must be a JSON object.` };
26
+ }
27
+ try {
28
+ const parsed = JSON.parse(raw);
29
+ if (parsed === null || typeof parsed !== 'object' || Array.isArray(parsed)) {
30
+ return { ok: false, error: `Invalid ${flag}: must be a JSON object.` };
31
+ }
32
+ return { ok: true, value: parsed };
33
+ }
34
+ catch {
35
+ return { ok: false, error: `Invalid ${flag}: must be valid JSON.` };
36
+ }
37
+ }
38
+ export async function runDefineStatusCommand(client, data_product_id) {
39
+ if (!data_product_id) {
40
+ return fail('data_product_id is required. Usage: loxtep define status <data_product_id>');
41
+ }
42
+ try {
43
+ return okJson(await client.define.product_definition.get_definition_status(data_product_id));
44
+ }
45
+ catch (err) {
46
+ return fail(`Failed to get definition status: ${err instanceof Error ? err.message : String(err)}`);
47
+ }
48
+ }
49
+ export async function runDefineEvidenceCommand(client, data_product_id) {
50
+ if (!data_product_id) {
51
+ return fail('data_product_id is required. Usage: loxtep define evidence <data_product_id>');
52
+ }
53
+ try {
54
+ return okJson(await client.define.product_definition.get_definition_evidence(data_product_id));
55
+ }
56
+ catch (err) {
57
+ return fail(`Failed to gather definition evidence: ${err instanceof Error ? err.message : String(err)}`);
58
+ }
59
+ }
60
+ export async function runDefineListCommand(client, options) {
61
+ const filters = {};
62
+ if (options?.data_product_id)
63
+ filters.data_product_id = options.data_product_id;
64
+ if (options?.disposition)
65
+ filters.disposition = options.disposition;
66
+ if (options?.proposal_type) {
67
+ const t = options.proposal_type;
68
+ if (t !== 'product_shape' && t !== 'product_semantic_bindings') {
69
+ return fail(`Invalid --proposal-type: '${t}'. Must be product_shape or product_semantic_bindings.`);
70
+ }
71
+ filters.proposal_type = t;
72
+ }
73
+ try {
74
+ return okJson(await client.define.product_definition.list_definition_proposals(filters));
75
+ }
76
+ catch (err) {
77
+ return fail(`Failed to list definition proposals: ${err instanceof Error ? err.message : String(err)}`);
78
+ }
79
+ }
80
+ export async function runDefineGetCommand(client, semantic_proposal_id) {
81
+ if (!semantic_proposal_id) {
82
+ return fail('semantic_proposal_id is required. Usage: loxtep define get <semantic_proposal_id>');
83
+ }
84
+ try {
85
+ return okJson(await client.define.product_definition.get_definition_proposal(semantic_proposal_id));
86
+ }
87
+ catch (err) {
88
+ return fail(`Failed to get definition proposal: ${err instanceof Error ? err.message : String(err)}`);
89
+ }
90
+ }
91
+ export async function runDefineSubmitShapeCommand(client, data_product_id, options) {
92
+ if (!data_product_id) {
93
+ return fail('data_product_id is required. Usage: loxtep define submit-shape <data_product_id> --definition <json>');
94
+ }
95
+ const def = parseJsonObject(options?.definition_json, '--definition');
96
+ if (!def.ok)
97
+ return fail(def.error);
98
+ try {
99
+ const evidence_refs = options?.evidence_refs
100
+ ? options.evidence_refs
101
+ .split(',')
102
+ .map((s) => s.trim())
103
+ .filter(Boolean)
104
+ : undefined;
105
+ return okJson(await client.define.product_definition.submit_shape_proposal({
106
+ data_product_id,
107
+ proposed_definition: def.value,
108
+ rationale: options?.rationale,
109
+ base_definition_revision: options?.base_revision,
110
+ evidence_refs,
111
+ }));
112
+ }
113
+ catch (err) {
114
+ return fail(`Failed to submit shape proposal: ${err instanceof Error ? err.message : String(err)}`);
115
+ }
116
+ }
117
+ export async function runDefineSubmitSemanticCommand(client, data_product_id, options) {
118
+ if (!data_product_id) {
119
+ return fail('data_product_id is required. Usage: loxtep define submit-semantic <data_product_id> [--definition <json>]');
120
+ }
121
+ let body = {};
122
+ if (options?.definition_json) {
123
+ const def = parseJsonObject(options.definition_json, '--definition');
124
+ if (!def.ok)
125
+ return fail(def.error);
126
+ body = def.value;
127
+ }
128
+ try {
129
+ return okJson(await client.define.product_definition.submit_semantic_bindings_proposal({
130
+ data_product_id,
131
+ rationale: options?.rationale,
132
+ canonical_targets: Array.isArray(body.canonical_targets)
133
+ ? body.canonical_targets
134
+ : [],
135
+ field_mappings: Array.isArray(body.field_mappings)
136
+ ? body.field_mappings
137
+ : [],
138
+ concept_alignments: Array.isArray(body.concept_alignments)
139
+ ? body.concept_alignments
140
+ : [],
141
+ relationship_types: Array.isArray(body.relationship_types)
142
+ ? body.relationship_types
143
+ : [],
144
+ unresolved_gaps: Array.isArray(body.unresolved_gaps)
145
+ ? body.unresolved_gaps
146
+ : undefined,
147
+ evidence_refs: Array.isArray(body.evidence_refs)
148
+ ? body.evidence_refs
149
+ : undefined,
150
+ base_definition_revision: typeof body.base_definition_revision === 'string'
151
+ ? body.base_definition_revision
152
+ : undefined,
153
+ }));
154
+ }
155
+ catch (err) {
156
+ return fail(`Failed to submit semantic bindings proposal: ${err instanceof Error ? err.message : String(err)}`);
157
+ }
158
+ }
159
+ export async function runDefineApproveCommand(client, semantic_proposal_id) {
160
+ if (!semantic_proposal_id) {
161
+ return fail('semantic_proposal_id is required. Usage: loxtep define approve <semantic_proposal_id>');
162
+ }
163
+ try {
164
+ return okJson(await client.define.product_definition.approve_definition_proposal(semantic_proposal_id));
165
+ }
166
+ catch (err) {
167
+ return fail(`Failed to approve definition proposal: ${err instanceof Error ? err.message : String(err)}`);
168
+ }
169
+ }
170
+ export async function runDefineApplyCommand(client, semantic_proposal_id) {
171
+ if (!semantic_proposal_id) {
172
+ return fail('semantic_proposal_id is required. Usage: loxtep define apply <semantic_proposal_id>');
173
+ }
174
+ try {
175
+ return okJson(await client.define.product_definition.apply_definition_proposal(semantic_proposal_id));
176
+ }
177
+ catch (err) {
178
+ return fail(`Failed to apply definition proposal: ${err instanceof Error ? err.message : String(err)}`);
179
+ }
180
+ }
181
+ export async function runDefineWithdrawCommand(client, semantic_proposal_id) {
182
+ if (!semantic_proposal_id) {
183
+ return fail('semantic_proposal_id is required. Usage: loxtep define withdraw <semantic_proposal_id>');
184
+ }
185
+ try {
186
+ return okJson(await client.define.product_definition.withdraw_definition_proposal(semantic_proposal_id));
187
+ }
188
+ catch (err) {
189
+ return fail(`Failed to withdraw definition proposal: ${err instanceof Error ? err.message : String(err)}`);
190
+ }
191
+ }
192
+ export async function runDefineSkillCommand(client) {
193
+ try {
194
+ return okJson(await client.define.product_definition.get_definition_skill());
195
+ }
196
+ catch (err) {
197
+ return fail(`Failed to load definition skill: ${err instanceof Error ? err.message : String(err)}`);
198
+ }
199
+ }
200
+ export async function runDefineStartProcedureCommand(client, data_product_id) {
201
+ if (!data_product_id) {
202
+ return fail('data_product_id is required. Usage: loxtep define start-procedure <data_product_id>');
203
+ }
204
+ try {
205
+ return okJson(await client.define.product_definition.start_definition_procedure_run(data_product_id));
206
+ }
207
+ catch (err) {
208
+ return fail(`Failed to start definition procedure: ${err instanceof Error ? err.message : String(err)}`);
209
+ }
210
+ }
211
+ export async function runDefineBatchCommand(client, options) {
212
+ const raw = options?.data_product_ids ?? '';
213
+ const ids = raw
214
+ .split(',')
215
+ .map((s) => s.trim())
216
+ .filter(Boolean);
217
+ if (ids.length === 0) {
218
+ return fail('--data-product-ids is required. Usage: loxtep define batch --data-product-ids <id,id> [--action status|evidence]');
219
+ }
220
+ const action = options?.action ?? 'status';
221
+ if (action !== 'status' && action !== 'evidence') {
222
+ return fail(`Invalid --action: '${action}'. Must be status or evidence.`);
223
+ }
224
+ try {
225
+ return okJson(await client.define.product_definition.run_definition_batch({
226
+ data_product_ids: ids,
227
+ action: action,
228
+ }));
229
+ }
230
+ catch (err) {
231
+ return fail(`Failed to run definition batch: ${err instanceof Error ? err.message : String(err)}`);
232
+ }
233
+ }
234
+ export const DEFINE_USAGE = 'Usage: loxtep define status <data_product_id>\n' +
235
+ ' loxtep define evidence <data_product_id>\n' +
236
+ ' loxtep define list [--data-product-id <id>] [--disposition <val>] [--proposal-type product_shape|product_semantic_bindings]\n' +
237
+ ' loxtep define get <semantic_proposal_id>\n' +
238
+ ' loxtep define submit-shape <data_product_id> --definition <json> [--rationale <text>] [--base-revision <rev>] [--evidence-refs <csv>]\n' +
239
+ ' loxtep define submit-semantic <data_product_id> [--definition <json>] [--rationale <text>]\n' +
240
+ ' loxtep define approve|apply|withdraw <semantic_proposal_id>\n' +
241
+ ' loxtep define skill\n' +
242
+ ' loxtep define start-procedure <data_product_id>\n' +
243
+ ' loxtep define batch --data-product-ids <id,id> [--action status|evidence]';
244
+ //# sourceMappingURL=define-cmd.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"define-cmd.js","sourceRoot":"","sources":["../../../src/cli/commands/define-cmd.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AAUH,SAAS,MAAM,CAAC,KAAc;IAC5B,OAAO,EAAE,QAAQ,EAAE,CAAC,EAAE,MAAM,EAAE,CAAC,IAAI,CAAC,SAAS,CAAC,KAAK,EAAE,IAAI,EAAE,CAAC,CAAC,CAAC,EAAE,MAAM,EAAE,EAAE,EAAE,CAAC;AAC/E,CAAC;AAED,SAAS,IAAI,CAAC,OAAe;IAC3B,OAAO,EAAE,QAAQ,EAAE,CAAC,EAAE,MAAM,EAAE,EAAE,EAAE,MAAM,EAAE,CAAC,OAAO,CAAC,EAAE,CAAC;AACxD,CAAC;AAED,SAAS,eAAe,CACtB,GAAuB,EACvB,IAAY;IAEZ,IAAI,GAAG,IAAI,IAAI,IAAI,GAAG,KAAK,EAAE,EAAE,CAAC;QAC9B,OAAO,EAAE,EAAE,EAAE,KAAK,EAAE,KAAK,EAAE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I,MAAM,KAAK,UAAU,EAAE,CAAC;QACjD,OAAO,IAAI,CAAC,sBAAsB,MAAM,gCAAgC,CAAC,CAAC;IAC5E,CAAC;IACD,IAAI,CAAC;QACH,OAAO,MAAM,CACX,MAAM,MAAM,CAAC,MAAM,CAAC,kBAAkB,CAAC,oBAAoB,CAAC;YAC1D,gBAAgB,EAAE,GAAG;YACrB,MAAM,EAAE,MAA+B;SACxC,CAAC,CACH,CAAC;IACJ,CAAC;IAAC,OAAO,GAAY,EAAE,CAAC;QACtB,OAAO,IAAI,CACT,mCAAmC,GAAG,YAAY,KAAK,CAAC,CAAC,CAAC,GAAG,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,GAAG,CAAC,EAAE,CACtF,CAAC;IACJ,CAAC;AACH,CAAC;AAED,MAAM,CAAC,MAAM,YAAY,GACvB,iDAAiD;IACjD,mDAAmD;IACnD,sIAAsI;IACtI,mDAAmD;IACnD,gJAAgJ;IAChJ,qGAAqG;IACrG,sEAAsE;IACtE,8BAA8B;IAC9B,0DAA0D;IAC1D,kFAAkF,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"help.d.ts","sourceRoot":"","sources":["../../src/cli/help.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,eAAO,MAAM,QAAQ,QAgJV,CAAC;AAEZ,wBAAgB,YAAY,IAAI,IAAI,CAEnC"}
1
+ {"version":3,"file":"help.d.ts","sourceRoot":"","sources":["../../src/cli/help.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,eAAO,MAAM,QAAQ,QAyJV,CAAC;AAEZ,wBAAgB,YAAY,IAAI,IAAI,CAEnC"}
package/dist/cli/help.js CHANGED
@@ -71,6 +71,15 @@ Governance
71
71
  domains list | get <id>
72
72
  standards list | get <id> Standards (policies)
73
73
  data-contracts list | get <id> | create …
74
+ define status <data_product_id>
75
+ Definition readiness / blockers (approve ≠ apply)
76
+ define evidence <data_product_id>
77
+ define list | get <semantic_proposal_id>
78
+ define submit-shape <data_product_id> --definition <json>
79
+ define submit-semantic <data_product_id> [--definition <json>]
80
+ define approve|apply|withdraw <semantic_proposal_id>
81
+ define skill | start-procedure <data_product_id>
82
+ define batch --data-product-ids <id,id> [--action status|evidence]
74
83
 
75
84
  Review
76
85
  approvals list [--status …] [--page N] [--page-size N] [--organization-id <id>]
@@ -1 +1 @@
1
- {"version":3,"file":"help.js","sourceRoot":"","sources":["../../src/cli/help.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,MAAM,CAAC,MAAM,QAAQ,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAgJvB,CAAC,OAAO,EAAE,CAAC;AAEZ,MAAM,UAAU,YAAY;IAC1B,OAAO,CAAC,GAAG,CAAC,QAAQ,CAAC,CAAC;AACxB,CAAC"}
1
+ {"version":3,"file":"help.js","sourceRoot":"","sources":["../../src/cli/help.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,MAAM,CAAC,MAAM,QAAQ,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAyJvB,CAAC,OAAO,EAAE,CAAC;AAEZ,MAAM,UAAU,YAAY;IAC1B,OAAO,CAAC,GAAG,CAAC,QAAQ,CAAC,CAAC;AACxB,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/cli/index.ts"],"names":[],"mappings":";AACA;;;;;;;GAOG;AAsIH;;;GAGG;AACH,wBAAsB,MAAM,CAAC,IAAI,EAAE,MAAM,EAAE,GAAG,OAAO,CAAC,IAAI,CAAC,CAy6B1D"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/cli/index.ts"],"names":[],"mappings":";AACA;;;;;;;GAOG;AAqJH;;;GAGG;AACH,wBAAsB,MAAM,CAAC,IAAI,EAAE,MAAM,EAAE,GAAG,OAAO,CAAC,IAAI,CAAC,CAq+B1D"}
package/dist/cli/index.js CHANGED
@@ -40,6 +40,7 @@ import { runApprovalsListCommand, runApprovalsApproveCommand, runApprovalsReject
40
40
  import { runCdlcTransitionCommand, runCdlcReviewQueueCommand, } from './commands/cdlc-cmd.js';
41
41
  import { runCandidatesListCommand, runCandidatesActCommand, } from './commands/candidates-cmd.js';
42
42
  import { runPacksListCommand, runPacksActivateCommand, runPacksStatusCommand, } from './commands/packs-cmd.js';
43
+ import { DEFINE_USAGE, runDefineStatusCommand, runDefineEvidenceCommand, runDefineListCommand, runDefineGetCommand, runDefineSubmitShapeCommand, runDefineSubmitSemanticCommand, runDefineApproveCommand, runDefineApplyCommand, runDefineWithdrawCommand, runDefineSkillCommand, runDefineStartProcedureCommand, runDefineBatchCommand, } from './commands/define-cmd.js';
43
44
  import { runDeploymentsListCommand, runDeploymentsGetCommand, } from './commands/deployments-cmd.js';
44
45
  import { runActivityListCommand } from './commands/activity-cmd.js';
45
46
  import { runInstancesList, runInstancesGet, runInstancesStreamConfig, runInstancesCreate, runInstancesUpdate, runInstancesRedeployRuntimes, runInstancesDeploymentUrls, runInstancesRegistration, runInstancesRegister, parseCreateInstanceArgs, parseUpdateInstanceArgs, } from './commands/instances-cmd.js';
@@ -856,6 +857,73 @@ export async function runCli(argv) {
856
857
  }
857
858
  break;
858
859
  }
860
+ case 'define': {
861
+ const authResult = await requireCliClient();
862
+ const printResult = (result) => {
863
+ for (const line of result.stdout)
864
+ console.log(line);
865
+ for (const line of result.stderr)
866
+ console.error(line);
867
+ if (result.exitCode !== 0)
868
+ process.exitCode = result.exitCode;
869
+ };
870
+ if (sub === 'status' && args[2]) {
871
+ printResult(await runDefineStatusCommand(authResult.client, args[2]));
872
+ }
873
+ else if (sub === 'evidence' && args[2]) {
874
+ printResult(await runDefineEvidenceCommand(authResult.client, args[2]));
875
+ }
876
+ else if (sub === 'list') {
877
+ printResult(await runDefineListCommand(authResult.client, {
878
+ data_product_id: getArg('--data-product-id'),
879
+ disposition: getArg('--disposition'),
880
+ proposal_type: getArg('--proposal-type'),
881
+ }));
882
+ }
883
+ else if (sub === 'get' && args[2]) {
884
+ printResult(await runDefineGetCommand(authResult.client, args[2]));
885
+ }
886
+ else if (sub === 'submit-shape' && args[2]) {
887
+ printResult(await runDefineSubmitShapeCommand(authResult.client, args[2], {
888
+ definition_json: getArg('--definition'),
889
+ rationale: getArg('--rationale'),
890
+ base_revision: getArg('--base-revision'),
891
+ evidence_refs: getArg('--evidence-refs'),
892
+ }));
893
+ }
894
+ else if (sub === 'submit-semantic' && args[2]) {
895
+ printResult(await runDefineSubmitSemanticCommand(authResult.client, args[2], {
896
+ definition_json: getArg('--definition'),
897
+ rationale: getArg('--rationale'),
898
+ }));
899
+ }
900
+ else if (sub === 'approve' && args[2]) {
901
+ printResult(await runDefineApproveCommand(authResult.client, args[2]));
902
+ }
903
+ else if (sub === 'apply' && args[2]) {
904
+ printResult(await runDefineApplyCommand(authResult.client, args[2]));
905
+ }
906
+ else if (sub === 'withdraw' && args[2]) {
907
+ printResult(await runDefineWithdrawCommand(authResult.client, args[2]));
908
+ }
909
+ else if (sub === 'skill') {
910
+ printResult(await runDefineSkillCommand(authResult.client));
911
+ }
912
+ else if (sub === 'start-procedure' && args[2]) {
913
+ printResult(await runDefineStartProcedureCommand(authResult.client, args[2]));
914
+ }
915
+ else if (sub === 'batch') {
916
+ printResult(await runDefineBatchCommand(authResult.client, {
917
+ data_product_ids: getArg('--data-product-ids'),
918
+ action: getArg('--action'),
919
+ }));
920
+ }
921
+ else {
922
+ console.error(DEFINE_USAGE);
923
+ process.exitCode = 1;
924
+ }
925
+ break;
926
+ }
859
927
  case 'cdlc': {
860
928
  const authResult = await requireCliClient();
861
929
  const orgId = getArg('--organization-id');