@openspecui/core 9.0.3 → 10.0.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/dist/{active-root-config-CDH9K5lV.d.mts → active-root-config-N3lOotoq.d.mts} +15 -15
- package/dist/active-root-config.d.mts +5 -5
- package/dist/app-daemon-control.d.mts +16 -16
- package/dist/{cli-projection-C1ZYzYMm.d.mts → cli-projection-bB650ru4.d.mts} +1 -1
- package/dist/cli-projection.d.mts +5 -5
- package/dist/{workflow-CmQ4pFYC.mjs → command-result-DWMmDl6I.mjs} +91 -80
- package/dist/{dashboard-summary-transport-Bys0g-UT.d.mts → dashboard-summary-transport-DcyVID8z.d.mts} +3045 -2948
- package/dist/dashboard-summary-transport.d.mts +17 -17
- package/dist/{document-translation-CBqubtWC.d.mts → document-translation-DM2eydNr.d.mts} +2 -2
- package/dist/document-translation.d.mts +1 -1
- package/dist/hosted-app.d.mts +17 -17
- package/dist/hosted-contract.d.mts +17 -17
- package/dist/{index-C7jJcSdH.d.mts → index-CW5hcqKC.d.mts} +12277 -7316
- package/dist/index.d.mts +18 -18
- package/dist/index.mjs +385 -138
- package/dist/{local-download-profiles-CyAhZwxA.d.mts → local-download-profiles-DXmw0Zs3.d.mts} +1 -1
- package/dist/local-download-profiles.d.mts +2 -2
- package/dist/{notifications-Be5ltQeN.d.mts → notifications-BQhnmovr.d.mts} +17 -17
- package/dist/notifications.d.mts +2 -2
- package/dist/{openspec-compat-DidEO359.mjs → openspec-compat-DctIDxRM.mjs} +23 -17
- package/dist/openspec-compat.d.mts +4 -76
- package/dist/openspec-compat.mjs +2 -2
- package/dist/{openspec-projection-Bymnjuf9.d.mts → openspec-projection-FKuNsfBp.d.mts} +1 -1
- package/dist/openspec-projection.d.mts +2 -2
- package/dist/{opsx-entity-NFWGsreJ.d.mts → opsx-entity-CulylXeK.d.mts} +2 -2
- package/dist/opsx-entity.d.mts +7 -7
- package/dist/{opsx-schema-detail-ChaSoC8S.d.mts → opsx-schema-detail-C9kNWQmO.d.mts} +2 -2
- package/dist/opsx-schema-detail.d.mts +8 -8
- package/dist/{opsx-types-C2lUEACZ.d.mts → opsx-types-BeQJ4Le_.d.mts} +124 -124
- package/dist/{planning-cli-projection-BTkiQ7PG.mjs → planning-cli-projection-pq8vZC1r.mjs} +2 -2
- package/dist/planning-cli-projection.d.mts +17 -17
- package/dist/planning-cli-projection.mjs +3 -3
- package/dist/{schemas-BG7Tcs8J.d.mts → schemas-BIaPbul1.d.mts} +117 -117
- package/dist/{sounds-DdPTMYMa.d.mts → sounds-CxSkCgKh.d.mts} +8 -8
- package/dist/sounds.d.mts +1 -1
- package/dist/{spec-catalog-Ce3uSLSc.mjs → spec-catalog-BkX0tZp9.mjs} +149 -2
- package/dist/spec-catalog.d.mts +17 -17
- package/dist/spec-catalog.mjs +2 -2
- package/dist/{store-types-X35XKl10.d.mts → store-types-TDbmbvPx.d.mts} +1 -1
- package/dist/store-types.d.mts +5 -5
- package/dist/task-progress.d.mts +6 -6
- package/dist/{terminal-audio-Csuw114f.d.mts → terminal-audio-R-3VBy0x.d.mts} +1 -1
- package/dist/terminal-audio.d.mts +2 -2
- package/dist/terminal-control.d.mts +2 -2
- package/dist/{terminal-invocation-C5AN93a9.d.mts → terminal-invocation-C8mSioBZ.d.mts} +93 -93
- package/dist/terminal-invocation.d.mts +1 -1
- package/dist/{translator-4wvacuAX.d.mts → translator-CVkc7MHh.d.mts} +31 -31
- package/dist/translator.d.mts +1 -1
- package/dist/workspace-directory-catalog.d.mts +2 -2
- package/package.json +3 -2
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { At as CliRootSource, Mt as CliExecutor, Nt as CliResult, bt as CliDiagnostic, f as CliDoctor, gt as CliCommandResult, l as OpenSpecCliContractExecutor, n as CliRootSelector, u as CliContext, vt as CliJsonValue, wt as CliDoctorReferenceEntry } from "./index-CW5hcqKC.mjs";
|
|
2
2
|
import { z } from "zod";
|
|
3
3
|
|
|
4
4
|
//#region src/open-spec-data-scope.d.ts
|
|
@@ -393,8 +393,8 @@ declare const ActiveRootOfficialConfigSchema: z.ZodObject<{
|
|
|
393
393
|
} | undefined;
|
|
394
394
|
}>>;
|
|
395
395
|
}, "strict", z.ZodTypeAny, {
|
|
396
|
-
context: string | null;
|
|
397
396
|
schema: string | null;
|
|
397
|
+
context: string | null;
|
|
398
398
|
rules: Record<string, string[]> | null;
|
|
399
399
|
operations: {
|
|
400
400
|
apply?: {
|
|
@@ -405,8 +405,8 @@ declare const ActiveRootOfficialConfigSchema: z.ZodObject<{
|
|
|
405
405
|
} | undefined;
|
|
406
406
|
} | null;
|
|
407
407
|
}, {
|
|
408
|
-
context: string | null;
|
|
409
408
|
schema: string | null;
|
|
409
|
+
context: string | null;
|
|
410
410
|
rules: Record<string, string[]> | null;
|
|
411
411
|
operations: {
|
|
412
412
|
apply?: {
|
|
@@ -455,8 +455,8 @@ declare const ActiveRootStructuredUpdateSchema: z.ZodObject<{
|
|
|
455
455
|
} | null;
|
|
456
456
|
}>>;
|
|
457
457
|
}, "strict", z.ZodTypeAny, {
|
|
458
|
-
context: string | null;
|
|
459
458
|
schema: string;
|
|
459
|
+
context: string | null;
|
|
460
460
|
rules: Record<string, string[]> | null;
|
|
461
461
|
operations: {
|
|
462
462
|
apply: {
|
|
@@ -467,8 +467,8 @@ declare const ActiveRootStructuredUpdateSchema: z.ZodObject<{
|
|
|
467
467
|
} | null;
|
|
468
468
|
} | null;
|
|
469
469
|
}, {
|
|
470
|
-
context: string | null;
|
|
471
470
|
schema: string;
|
|
471
|
+
context: string | null;
|
|
472
472
|
rules: Record<string, string[]> | null;
|
|
473
473
|
operations: {
|
|
474
474
|
apply: {
|
|
@@ -523,8 +523,8 @@ declare const ActiveRootMutationSchema: z.ZodDiscriminatedUnion<"mode", [z.ZodOb
|
|
|
523
523
|
} | null;
|
|
524
524
|
}>>;
|
|
525
525
|
}, "strict", z.ZodTypeAny, {
|
|
526
|
-
context: string | null;
|
|
527
526
|
schema: string;
|
|
527
|
+
context: string | null;
|
|
528
528
|
rules: Record<string, string[]> | null;
|
|
529
529
|
operations: {
|
|
530
530
|
apply: {
|
|
@@ -535,8 +535,8 @@ declare const ActiveRootMutationSchema: z.ZodDiscriminatedUnion<"mode", [z.ZodOb
|
|
|
535
535
|
} | null;
|
|
536
536
|
} | null;
|
|
537
537
|
}, {
|
|
538
|
-
context: string | null;
|
|
539
538
|
schema: string;
|
|
539
|
+
context: string | null;
|
|
540
540
|
rules: Record<string, string[]> | null;
|
|
541
541
|
operations: {
|
|
542
542
|
apply: {
|
|
@@ -552,9 +552,10 @@ declare const ActiveRootMutationSchema: z.ZodDiscriminatedUnion<"mode", [z.ZodOb
|
|
|
552
552
|
revision: z.ZodString;
|
|
553
553
|
}, "strict", z.ZodTypeAny, {
|
|
554
554
|
revision: string;
|
|
555
|
+
mode: "structured";
|
|
555
556
|
update: {
|
|
556
|
-
context: string | null;
|
|
557
557
|
schema: string;
|
|
558
|
+
context: string | null;
|
|
558
559
|
rules: Record<string, string[]> | null;
|
|
559
560
|
operations: {
|
|
560
561
|
apply: {
|
|
@@ -565,14 +566,14 @@ declare const ActiveRootMutationSchema: z.ZodDiscriminatedUnion<"mode", [z.ZodOb
|
|
|
565
566
|
} | null;
|
|
566
567
|
} | null;
|
|
567
568
|
};
|
|
568
|
-
filePath: string;
|
|
569
|
-
mode: "structured";
|
|
570
569
|
ownerPath: string;
|
|
570
|
+
filePath: string;
|
|
571
571
|
}, {
|
|
572
572
|
revision: string;
|
|
573
|
+
mode: "structured";
|
|
573
574
|
update: {
|
|
574
|
-
context: string | null;
|
|
575
575
|
schema: string;
|
|
576
|
+
context: string | null;
|
|
576
577
|
rules: Record<string, string[]> | null;
|
|
577
578
|
operations: {
|
|
578
579
|
apply: {
|
|
@@ -583,9 +584,8 @@ declare const ActiveRootMutationSchema: z.ZodDiscriminatedUnion<"mode", [z.ZodOb
|
|
|
583
584
|
} | null;
|
|
584
585
|
} | null;
|
|
585
586
|
};
|
|
586
|
-
filePath: string;
|
|
587
|
-
mode: "structured";
|
|
588
587
|
ownerPath: string;
|
|
588
|
+
filePath: string;
|
|
589
589
|
}>, z.ZodObject<{
|
|
590
590
|
mode: z.ZodLiteral<"raw">;
|
|
591
591
|
content: z.ZodString;
|
|
@@ -594,16 +594,16 @@ declare const ActiveRootMutationSchema: z.ZodDiscriminatedUnion<"mode", [z.ZodOb
|
|
|
594
594
|
revision: z.ZodString;
|
|
595
595
|
}, "strict", z.ZodTypeAny, {
|
|
596
596
|
revision: string;
|
|
597
|
-
filePath: string;
|
|
598
597
|
mode: "raw";
|
|
599
598
|
content: string;
|
|
600
599
|
ownerPath: string;
|
|
600
|
+
filePath: string;
|
|
601
601
|
}, {
|
|
602
602
|
revision: string;
|
|
603
|
-
filePath: string;
|
|
604
603
|
mode: "raw";
|
|
605
604
|
content: string;
|
|
606
605
|
ownerPath: string;
|
|
606
|
+
filePath: string;
|
|
607
607
|
}>]>;
|
|
608
608
|
/** Revision-aware Active Root mutation request. */
|
|
609
609
|
type ActiveRootMutation = z.infer<typeof ActiveRootMutationSchema>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import "./
|
|
2
|
-
import "./
|
|
3
|
-
import "./
|
|
4
|
-
import "./
|
|
5
|
-
import { _ as ActiveRootStructuredUpdateSchema, a as ActiveRootConfigDiagnostic, c as ActiveRootMutation, d as ActiveRootOfficialConfig, f as ActiveRootOfficialConfigSchema, g as ActiveRootStructuredUpdate, h as ActiveRootRevisionSchema, i as ActiveRootConfig, l as ActiveRootMutationResult, m as ActiveRootRevision, n as patchActiveRootOfficialFields, o as ActiveRootConfigFile, p as ActiveRootRawValidation, r as validateActiveRootRawYaml, s as ActiveRootConfigInspection, t as inspectActiveRootOfficialConfig, u as ActiveRootMutationSchema, v as MAX_ACTIVE_ROOT_CONTEXT_BYTES } from "./active-root-config-
|
|
1
|
+
import "./index-CW5hcqKC.mjs";
|
|
2
|
+
import "./document-translation-DM2eydNr.mjs";
|
|
3
|
+
import "./sounds-CxSkCgKh.mjs";
|
|
4
|
+
import "./notifications-BQhnmovr.mjs";
|
|
5
|
+
import { _ as ActiveRootStructuredUpdateSchema, a as ActiveRootConfigDiagnostic, c as ActiveRootMutation, d as ActiveRootOfficialConfig, f as ActiveRootOfficialConfigSchema, g as ActiveRootStructuredUpdate, h as ActiveRootRevisionSchema, i as ActiveRootConfig, l as ActiveRootMutationResult, m as ActiveRootRevision, n as patchActiveRootOfficialFields, o as ActiveRootConfigFile, p as ActiveRootRawValidation, r as validateActiveRootRawYaml, s as ActiveRootConfigInspection, t as inspectActiveRootOfficialConfig, u as ActiveRootMutationSchema, v as MAX_ACTIVE_ROOT_CONTEXT_BYTES } from "./active-root-config-N3lOotoq.mjs";
|
|
6
6
|
export { ActiveRootConfig, ActiveRootConfigDiagnostic, ActiveRootConfigFile, ActiveRootConfigInspection, ActiveRootMutation, ActiveRootMutationResult, ActiveRootMutationSchema, ActiveRootOfficialConfig, ActiveRootOfficialConfigSchema, ActiveRootRawValidation, ActiveRootRevision, ActiveRootRevisionSchema, ActiveRootStructuredUpdate, ActiveRootStructuredUpdateSchema, MAX_ACTIVE_ROOT_CONTEXT_BYTES, inspectActiveRootOfficialConfig, patchActiveRootOfficialFields, validateActiveRootRawYaml };
|
|
@@ -26,9 +26,9 @@ declare const AppDaemonWorkspaceBindingSchema: z.ZodObject<{
|
|
|
26
26
|
githubSlug: string | null;
|
|
27
27
|
}>>;
|
|
28
28
|
}, "strip", z.ZodTypeAny, {
|
|
29
|
-
credential: string | null;
|
|
30
29
|
id: string;
|
|
31
30
|
backendUrl: string;
|
|
31
|
+
credential: string | null;
|
|
32
32
|
projectDir: string;
|
|
33
33
|
ownership: "daemon-managed" | "external";
|
|
34
34
|
registeredAt: number;
|
|
@@ -40,9 +40,9 @@ declare const AppDaemonWorkspaceBindingSchema: z.ZodObject<{
|
|
|
40
40
|
githubSlug: string | null;
|
|
41
41
|
} | null;
|
|
42
42
|
}, {
|
|
43
|
-
credential: string | null;
|
|
44
43
|
id: string;
|
|
45
44
|
backendUrl: string;
|
|
45
|
+
credential: string | null;
|
|
46
46
|
projectDir: string;
|
|
47
47
|
ownership: "daemon-managed" | "external";
|
|
48
48
|
registeredAt: number;
|
|
@@ -81,9 +81,9 @@ declare const AppDaemonWorkspaceSnapshotSchema: z.ZodObject<{
|
|
|
81
81
|
githubSlug: string | null;
|
|
82
82
|
}>>;
|
|
83
83
|
}, "strip", z.ZodTypeAny, {
|
|
84
|
-
credential: string | null;
|
|
85
84
|
id: string;
|
|
86
85
|
backendUrl: string;
|
|
86
|
+
credential: string | null;
|
|
87
87
|
projectDir: string;
|
|
88
88
|
ownership: "daemon-managed" | "external";
|
|
89
89
|
registeredAt: number;
|
|
@@ -95,9 +95,9 @@ declare const AppDaemonWorkspaceSnapshotSchema: z.ZodObject<{
|
|
|
95
95
|
githubSlug: string | null;
|
|
96
96
|
} | null;
|
|
97
97
|
}, {
|
|
98
|
-
credential: string | null;
|
|
99
98
|
id: string;
|
|
100
99
|
backendUrl: string;
|
|
100
|
+
credential: string | null;
|
|
101
101
|
projectDir: string;
|
|
102
102
|
ownership: "daemon-managed" | "external";
|
|
103
103
|
registeredAt: number;
|
|
@@ -112,9 +112,9 @@ declare const AppDaemonWorkspaceSnapshotSchema: z.ZodObject<{
|
|
|
112
112
|
}, "strip", z.ZodTypeAny, {
|
|
113
113
|
revision: number;
|
|
114
114
|
workspaces: {
|
|
115
|
-
credential: string | null;
|
|
116
115
|
id: string;
|
|
117
116
|
backendUrl: string;
|
|
117
|
+
credential: string | null;
|
|
118
118
|
projectDir: string;
|
|
119
119
|
ownership: "daemon-managed" | "external";
|
|
120
120
|
registeredAt: number;
|
|
@@ -129,9 +129,9 @@ declare const AppDaemonWorkspaceSnapshotSchema: z.ZodObject<{
|
|
|
129
129
|
}, {
|
|
130
130
|
revision: number;
|
|
131
131
|
workspaces: {
|
|
132
|
-
credential: string | null;
|
|
133
132
|
id: string;
|
|
134
133
|
backendUrl: string;
|
|
134
|
+
credential: string | null;
|
|
135
135
|
projectDir: string;
|
|
136
136
|
ownership: "daemon-managed" | "external";
|
|
137
137
|
registeredAt: number;
|
|
@@ -174,17 +174,17 @@ declare const AppDaemonOpenWorkspaceResponseSchema: z.ZodDiscriminatedUnion<"ok"
|
|
|
174
174
|
message: string;
|
|
175
175
|
}>;
|
|
176
176
|
}, "strip", z.ZodTypeAny, {
|
|
177
|
+
ok: false;
|
|
177
178
|
error: {
|
|
178
179
|
code: "NOT_FOUND" | "PRESENTATION_FAILED";
|
|
179
180
|
message: string;
|
|
180
181
|
};
|
|
181
|
-
ok: false;
|
|
182
182
|
}, {
|
|
183
|
+
ok: false;
|
|
183
184
|
error: {
|
|
184
185
|
code: "NOT_FOUND" | "PRESENTATION_FAILED";
|
|
185
186
|
message: string;
|
|
186
187
|
};
|
|
187
|
-
ok: false;
|
|
188
188
|
}>]>;
|
|
189
189
|
type AppDaemonOpenWorkspaceResponse = z.infer<typeof AppDaemonOpenWorkspaceResponseSchema>;
|
|
190
190
|
/** Same-origin request body for starting one daemon-managed project from a local directory. */
|
|
@@ -231,9 +231,9 @@ declare const AppDaemonStartManagedProjectResponseSchema: z.ZodDiscriminatedUnio
|
|
|
231
231
|
githubSlug: string | null;
|
|
232
232
|
}>>;
|
|
233
233
|
}, "strip", z.ZodTypeAny, {
|
|
234
|
-
credential: string | null;
|
|
235
234
|
id: string;
|
|
236
235
|
backendUrl: string;
|
|
236
|
+
credential: string | null;
|
|
237
237
|
projectDir: string;
|
|
238
238
|
ownership: "daemon-managed" | "external";
|
|
239
239
|
registeredAt: number;
|
|
@@ -245,9 +245,9 @@ declare const AppDaemonStartManagedProjectResponseSchema: z.ZodDiscriminatedUnio
|
|
|
245
245
|
githubSlug: string | null;
|
|
246
246
|
} | null;
|
|
247
247
|
}, {
|
|
248
|
-
credential: string | null;
|
|
249
248
|
id: string;
|
|
250
249
|
backendUrl: string;
|
|
250
|
+
credential: string | null;
|
|
251
251
|
projectDir: string;
|
|
252
252
|
ownership: "daemon-managed" | "external";
|
|
253
253
|
registeredAt: number;
|
|
@@ -263,9 +263,9 @@ declare const AppDaemonStartManagedProjectResponseSchema: z.ZodDiscriminatedUnio
|
|
|
263
263
|
}, "strip", z.ZodTypeAny, {
|
|
264
264
|
ok: true;
|
|
265
265
|
workspace: {
|
|
266
|
-
credential: string | null;
|
|
267
266
|
id: string;
|
|
268
267
|
backendUrl: string;
|
|
268
|
+
credential: string | null;
|
|
269
269
|
projectDir: string;
|
|
270
270
|
ownership: "daemon-managed" | "external";
|
|
271
271
|
registeredAt: number;
|
|
@@ -281,9 +281,9 @@ declare const AppDaemonStartManagedProjectResponseSchema: z.ZodDiscriminatedUnio
|
|
|
281
281
|
}, {
|
|
282
282
|
ok: true;
|
|
283
283
|
workspace: {
|
|
284
|
-
credential: string | null;
|
|
285
284
|
id: string;
|
|
286
285
|
backendUrl: string;
|
|
286
|
+
credential: string | null;
|
|
287
287
|
projectDir: string;
|
|
288
288
|
ownership: "daemon-managed" | "external";
|
|
289
289
|
registeredAt: number;
|
|
@@ -309,17 +309,17 @@ declare const AppDaemonStartManagedProjectResponseSchema: z.ZodDiscriminatedUnio
|
|
|
309
309
|
message: string;
|
|
310
310
|
}>;
|
|
311
311
|
}, "strip", z.ZodTypeAny, {
|
|
312
|
+
ok: false;
|
|
312
313
|
error: {
|
|
313
314
|
code: "UNSUPPORTED" | "INVALID_DIRECTORY" | "SPAWN_FAILED" | "GENERATION_MISMATCH" | "INVALID_REQUEST";
|
|
314
315
|
message: string;
|
|
315
316
|
};
|
|
316
|
-
ok: false;
|
|
317
317
|
}, {
|
|
318
|
+
ok: false;
|
|
318
319
|
error: {
|
|
319
320
|
code: "UNSUPPORTED" | "INVALID_DIRECTORY" | "SPAWN_FAILED" | "GENERATION_MISMATCH" | "INVALID_REQUEST";
|
|
320
321
|
message: string;
|
|
321
322
|
};
|
|
322
|
-
ok: false;
|
|
323
323
|
}>]>;
|
|
324
324
|
type AppDaemonStartManagedProjectResponse = z.infer<typeof AppDaemonStartManagedProjectResponseSchema>;
|
|
325
325
|
/** Settled same-origin exact-generation Stop response. */
|
|
@@ -345,17 +345,17 @@ declare const AppDaemonStopManagedProjectResponseSchema: z.ZodDiscriminatedUnion
|
|
|
345
345
|
message: string;
|
|
346
346
|
}>;
|
|
347
347
|
}, "strip", z.ZodTypeAny, {
|
|
348
|
+
ok: false;
|
|
348
349
|
error: {
|
|
349
350
|
code: "UNSUPPORTED" | "INVALID_DIRECTORY" | "SPAWN_FAILED" | "GENERATION_MISMATCH" | "INVALID_REQUEST";
|
|
350
351
|
message: string;
|
|
351
352
|
};
|
|
352
|
-
ok: false;
|
|
353
353
|
}, {
|
|
354
|
+
ok: false;
|
|
354
355
|
error: {
|
|
355
356
|
code: "UNSUPPORTED" | "INVALID_DIRECTORY" | "SPAWN_FAILED" | "GENERATION_MISMATCH" | "INVALID_REQUEST";
|
|
356
357
|
message: string;
|
|
357
358
|
};
|
|
358
|
-
ok: false;
|
|
359
359
|
}>]>;
|
|
360
360
|
type AppDaemonStopManagedProjectResponse = z.infer<typeof AppDaemonStopManagedProjectResponseSchema>;
|
|
361
361
|
//#endregion
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import "./
|
|
2
|
-
import "./
|
|
3
|
-
import "./
|
|
4
|
-
import "./
|
|
5
|
-
import { _ as toCliProjectionCommandEvidence, a as CliProjectionFailure, c as CliProjectionInvalidationCauseSchema, d as CliProjectionState, f as CliProjectionStateName, g as createCliProjectionStateSchema, h as cliProjectionStates, i as CliProjectionCommandEvidenceSchema, l as CliProjectionNotice, m as cliProjectionInvalidationCauses, n as CliProjectionCommandError, o as CliProjectionFailureSchema, p as CliProjectionStateNameSchema, r as CliProjectionCommandEvidence, s as CliProjectionInvalidationCause, t as CliJsonValueSchema, u as CliProjectionNoticeSchema, v as toCliProjectionFailure, y as toCliProjectionNotice } from "./cli-projection-
|
|
1
|
+
import "./index-CW5hcqKC.mjs";
|
|
2
|
+
import "./document-translation-DM2eydNr.mjs";
|
|
3
|
+
import "./sounds-CxSkCgKh.mjs";
|
|
4
|
+
import "./notifications-BQhnmovr.mjs";
|
|
5
|
+
import { _ as toCliProjectionCommandEvidence, a as CliProjectionFailure, c as CliProjectionInvalidationCauseSchema, d as CliProjectionState, f as CliProjectionStateName, g as createCliProjectionStateSchema, h as cliProjectionStates, i as CliProjectionCommandEvidenceSchema, l as CliProjectionNotice, m as cliProjectionInvalidationCauses, n as CliProjectionCommandError, o as CliProjectionFailureSchema, p as CliProjectionStateNameSchema, r as CliProjectionCommandEvidence, s as CliProjectionInvalidationCause, t as CliJsonValueSchema, u as CliProjectionNoticeSchema, v as toCliProjectionFailure, y as toCliProjectionNotice } from "./cli-projection-bB650ru4.mjs";
|
|
6
6
|
export { CliJsonValueSchema, CliProjectionCommandError, CliProjectionCommandEvidence, CliProjectionCommandEvidenceSchema, CliProjectionFailure, CliProjectionFailureSchema, CliProjectionInvalidationCause, CliProjectionInvalidationCauseSchema, CliProjectionNotice, CliProjectionNoticeSchema, CliProjectionState, CliProjectionStateName, CliProjectionStateNameSchema, cliProjectionInvalidationCauses, cliProjectionStates, createCliProjectionStateSchema, toCliProjectionCommandEvidence, toCliProjectionFailure, toCliProjectionNotice };
|
|
@@ -1,91 +1,21 @@
|
|
|
1
1
|
import { a as CliRootSchema, i as CliReferenceIndexEntrySchema, n as CliDiagnosticSchema, t as CliDiagnosticFailureSchema } from "./common-BRL_34xt.mjs";
|
|
2
2
|
import { z } from "zod";
|
|
3
3
|
|
|
4
|
-
//#region src/cli-contracts/command-result.ts
|
|
5
|
-
/**
|
|
6
|
-
* Orthogonal intents (updated 2026-08-15 Asia/Shanghai):
|
|
7
|
-
* 1. Preserve every process-level fact from an OpenSpec CLI invocation.
|
|
8
|
-
* 2. Validate command payloads without discarding the raw JSON document.
|
|
9
|
-
* 3. Surface contract drift separately from CLI command failure.
|
|
10
|
-
* 4. Provide the runtime transport-envelope schema for browser evidence boundaries.
|
|
11
|
-
*
|
|
12
|
-
* Original request (2026-07-15): "对新增字段保持可扩展,对必需语义严格验证。"
|
|
13
|
-
* Original request (2026-08-15): "v9的适配需要同时适配 1.8和1.9。"
|
|
14
|
-
*/
|
|
15
|
-
/** Runtime schema for one JSON value retained verbatim from CLI stdout. */
|
|
16
|
-
const CliJsonValueSchema = z.lazy(() => z.union([
|
|
17
|
-
z.string(),
|
|
18
|
-
z.number(),
|
|
19
|
-
z.boolean(),
|
|
20
|
-
z.null(),
|
|
21
|
-
z.array(CliJsonValueSchema),
|
|
22
|
-
z.record(z.string(), CliJsonValueSchema)
|
|
23
|
-
]));
|
|
24
|
-
/** Runtime transport envelope for one CLI command result. */
|
|
25
|
-
const CliCommandTransportSchema = z.object({
|
|
26
|
-
success: z.boolean(),
|
|
27
|
-
stdout: z.string(),
|
|
28
|
-
stderr: z.string(),
|
|
29
|
-
exitCode: z.number().int().nullable(),
|
|
30
|
-
data: CliJsonValueSchema.nullable(),
|
|
31
|
-
payload: CliJsonValueSchema.nullable(),
|
|
32
|
-
diagnostics: z.array(CliDiagnosticSchema),
|
|
33
|
-
contractError: z.string().optional()
|
|
34
|
-
});
|
|
35
|
-
function formatContractError(error) {
|
|
36
|
-
return error.issues.map((issue) => {
|
|
37
|
-
return `${issue.path.length > 0 ? issue.path.join(".") : "<root>"}: ${issue.message}`;
|
|
38
|
-
}).join("; ");
|
|
39
|
-
}
|
|
40
|
-
function extractDiagnostics(payload) {
|
|
41
|
-
if (typeof payload !== "object" || payload === null || !("status" in payload)) return [];
|
|
42
|
-
const parsed = z.array(CliDiagnosticSchema).safeParse(payload.status);
|
|
43
|
-
return parsed.success ? parsed.data : [];
|
|
44
|
-
}
|
|
45
|
-
/** Parse one CLI JSON document while retaining all process and raw-payload evidence. */
|
|
46
|
-
function parseCliCommandResult(result, schema) {
|
|
47
|
-
let payload;
|
|
48
|
-
try {
|
|
49
|
-
payload = JSON.parse(result.stdout);
|
|
50
|
-
} catch (error) {
|
|
51
|
-
const message = error instanceof Error ? error.message : String(error);
|
|
52
|
-
return {
|
|
53
|
-
...result,
|
|
54
|
-
data: null,
|
|
55
|
-
payload: null,
|
|
56
|
-
diagnostics: [],
|
|
57
|
-
contractError: `OpenSpec CLI stdout is not one JSON document: ${message}`
|
|
58
|
-
};
|
|
59
|
-
}
|
|
60
|
-
const parsed = schema.safeParse(payload);
|
|
61
|
-
if (!parsed.success) return {
|
|
62
|
-
...result,
|
|
63
|
-
data: null,
|
|
64
|
-
payload,
|
|
65
|
-
diagnostics: extractDiagnostics(payload),
|
|
66
|
-
contractError: formatContractError(parsed.error)
|
|
67
|
-
};
|
|
68
|
-
return {
|
|
69
|
-
...result,
|
|
70
|
-
data: parsed.data,
|
|
71
|
-
payload,
|
|
72
|
-
diagnostics: extractDiagnostics(parsed.data)
|
|
73
|
-
};
|
|
74
|
-
}
|
|
75
|
-
|
|
76
|
-
//#endregion
|
|
77
4
|
//#region src/cli-contracts/workflow.ts
|
|
78
5
|
/**
|
|
79
|
-
* Orthogonal intents (updated 2026-08-
|
|
6
|
+
* Orthogonal intents (updated 2026-08-28 Asia/Shanghai):
|
|
80
7
|
* 1. Model camelCase workflow JSON independently from Store-family JSON.
|
|
81
8
|
* 2. Preserve strict, archived, and bulk Validate plus Archive outcomes, including failure payloads.
|
|
82
9
|
* 3. Preserve multiline requirement bodies from `show --json`.
|
|
83
|
-
* 4. Preserve complete
|
|
10
|
+
* 4. Preserve complete admitted-line (1.10/1.11) Status and operation-Instruction contracts as CLI facts.
|
|
84
11
|
* 5. Export the successful Spec-document schema for browser-safe projection validation.
|
|
12
|
+
* 6. Export the root-less Status payload fields and Requirement shape shared with the
|
|
13
|
+
* OpenSpec 1.11 batch Status and show --diff contracts.
|
|
85
14
|
*
|
|
86
15
|
* Original request (2026-07-15): "为不同命令建立强类型适配器,不实现平行解析规则。"
|
|
87
16
|
* Original request (2026-07-26): "展开全面的接口升级和内核升级和测试升级。"
|
|
88
17
|
* Original request (2026-08-15): "v9的适配需要同时适配 1.8和1.9。"
|
|
18
|
+
* Original request (2026-08-28): "直接将 0.10.0 和 0.11.0 一起适配,然后发布 v11。"
|
|
89
19
|
*/
|
|
90
20
|
const CliChangeListEntrySchema = z.object({
|
|
91
21
|
name: z.string(),
|
|
@@ -145,6 +75,7 @@ const CliTemplateEntrySchema = z.object({
|
|
|
145
75
|
])
|
|
146
76
|
}).passthrough();
|
|
147
77
|
const CliTemplatesSchema = z.record(CliTemplateEntrySchema);
|
|
78
|
+
/** One requirement body shared by Spec documents and Change deltas. */
|
|
148
79
|
const CliSpecRequirementSchema = z.object({
|
|
149
80
|
text: z.string(),
|
|
150
81
|
scenarios: z.array(z.object({ rawText: z.string() }).passthrough())
|
|
@@ -200,8 +131,14 @@ const CliStatusArtifactSchema = z.object({
|
|
|
200
131
|
requires: z.array(z.string()),
|
|
201
132
|
missingDeps: z.array(z.string()).optional()
|
|
202
133
|
}).passthrough();
|
|
203
|
-
/**
|
|
204
|
-
|
|
134
|
+
/**
|
|
135
|
+
* Root-less Status payload fields for one OpenSpec change.
|
|
136
|
+
*
|
|
137
|
+
* The single-change command attaches `root` itself; the OpenSpec 1.11 batch
|
|
138
|
+
* envelope (`status --all --json`) reuses exactly these fields per entry while
|
|
139
|
+
* the envelope owns the single root.
|
|
140
|
+
*/
|
|
141
|
+
const CliWorkflowStatusFieldsSchema = z.object({
|
|
205
142
|
changeName: z.string(),
|
|
206
143
|
schemaName: z.string(),
|
|
207
144
|
planningHome: CliPlanningHomeSchema,
|
|
@@ -212,9 +149,10 @@ const CliWorkflowStatusSuccessSchema = z.object({
|
|
|
212
149
|
applyRequires: z.array(z.string()),
|
|
213
150
|
nextSteps: z.array(z.string()),
|
|
214
151
|
actionContext: CliActionContextSchema,
|
|
215
|
-
artifacts: z.array(CliStatusArtifactSchema)
|
|
216
|
-
root: CliRootSchema
|
|
152
|
+
artifacts: z.array(CliStatusArtifactSchema)
|
|
217
153
|
}).passthrough();
|
|
154
|
+
/** Complete successful Status payload for one OpenSpec change. */
|
|
155
|
+
const CliWorkflowStatusSuccessSchema = CliWorkflowStatusFieldsSchema.extend({ root: CliRootSchema }).passthrough();
|
|
218
156
|
/** Typed success or diagnostic failure result of the CLI Status JSON command. */
|
|
219
157
|
const CliWorkflowStatusSchema = z.union([CliWorkflowStatusSuccessSchema, CliDiagnosticFailureSchema]);
|
|
220
158
|
const CliInstructionDependencySchema = z.object({
|
|
@@ -341,4 +279,77 @@ const CliArchiveSchema = z.object({
|
|
|
341
279
|
}).passthrough();
|
|
342
280
|
|
|
343
281
|
//#endregion
|
|
344
|
-
|
|
282
|
+
//#region src/cli-contracts/command-result.ts
|
|
283
|
+
/**
|
|
284
|
+
* Orthogonal intents (updated 2026-08-15 Asia/Shanghai):
|
|
285
|
+
* 1. Preserve every process-level fact from an OpenSpec CLI invocation.
|
|
286
|
+
* 2. Validate command payloads without discarding the raw JSON document.
|
|
287
|
+
* 3. Surface contract drift separately from CLI command failure.
|
|
288
|
+
* 4. Provide the runtime transport-envelope schema for browser evidence boundaries.
|
|
289
|
+
*
|
|
290
|
+
* Original request (2026-07-15): "对新增字段保持可扩展,对必需语义严格验证。"
|
|
291
|
+
* Original request (2026-08-15): "v9的适配需要同时适配 1.8和1.9。"
|
|
292
|
+
*/
|
|
293
|
+
/** Runtime schema for one JSON value retained verbatim from CLI stdout. */
|
|
294
|
+
const CliJsonValueSchema = z.lazy(() => z.union([
|
|
295
|
+
z.string(),
|
|
296
|
+
z.number(),
|
|
297
|
+
z.boolean(),
|
|
298
|
+
z.null(),
|
|
299
|
+
z.array(CliJsonValueSchema),
|
|
300
|
+
z.record(z.string(), CliJsonValueSchema)
|
|
301
|
+
]));
|
|
302
|
+
/** Runtime transport envelope for one CLI command result. */
|
|
303
|
+
const CliCommandTransportSchema = z.object({
|
|
304
|
+
success: z.boolean(),
|
|
305
|
+
stdout: z.string(),
|
|
306
|
+
stderr: z.string(),
|
|
307
|
+
exitCode: z.number().int().nullable(),
|
|
308
|
+
data: CliJsonValueSchema.nullable(),
|
|
309
|
+
payload: CliJsonValueSchema.nullable(),
|
|
310
|
+
diagnostics: z.array(CliDiagnosticSchema),
|
|
311
|
+
contractError: z.string().optional()
|
|
312
|
+
});
|
|
313
|
+
function formatContractError(error) {
|
|
314
|
+
return error.issues.map((issue) => {
|
|
315
|
+
return `${issue.path.length > 0 ? issue.path.join(".") : "<root>"}: ${issue.message}`;
|
|
316
|
+
}).join("; ");
|
|
317
|
+
}
|
|
318
|
+
function extractDiagnostics(payload) {
|
|
319
|
+
if (typeof payload !== "object" || payload === null || !("status" in payload)) return [];
|
|
320
|
+
const parsed = z.array(CliDiagnosticSchema).safeParse(payload.status);
|
|
321
|
+
return parsed.success ? parsed.data : [];
|
|
322
|
+
}
|
|
323
|
+
/** Parse one CLI JSON document while retaining all process and raw-payload evidence. */
|
|
324
|
+
function parseCliCommandResult(result, schema) {
|
|
325
|
+
let payload;
|
|
326
|
+
try {
|
|
327
|
+
payload = JSON.parse(result.stdout);
|
|
328
|
+
} catch (error) {
|
|
329
|
+
const message = error instanceof Error ? error.message : String(error);
|
|
330
|
+
return {
|
|
331
|
+
...result,
|
|
332
|
+
data: null,
|
|
333
|
+
payload: null,
|
|
334
|
+
diagnostics: [],
|
|
335
|
+
contractError: `OpenSpec CLI stdout is not one JSON document: ${message}`
|
|
336
|
+
};
|
|
337
|
+
}
|
|
338
|
+
const parsed = schema.safeParse(payload);
|
|
339
|
+
if (!parsed.success) return {
|
|
340
|
+
...result,
|
|
341
|
+
data: null,
|
|
342
|
+
payload,
|
|
343
|
+
diagnostics: extractDiagnostics(payload),
|
|
344
|
+
contractError: formatContractError(parsed.error)
|
|
345
|
+
};
|
|
346
|
+
return {
|
|
347
|
+
...result,
|
|
348
|
+
data: parsed.data,
|
|
349
|
+
payload,
|
|
350
|
+
diagnostics: extractDiagnostics(parsed.data)
|
|
351
|
+
};
|
|
352
|
+
}
|
|
353
|
+
|
|
354
|
+
//#endregion
|
|
355
|
+
export { CliValidateReportSchema as C, CliWorkflowStatusSuccessSchema as D, CliWorkflowStatusSchema as E, CliTemplatesSchema as S, CliWorkflowStatusFieldsSchema as T, CliShowSpecDocumentSchema as _, CliApplyInstructionsSuccessSchema as a, CliSpecRequirementSchema as b, CliArchiveSchema as c, CliArtifactPathSchema as d, CliChangeListSchema as f, CliSchemaWhichSchema as g, CliSchemaShadowSchema as h, CliApplyInstructionsSchema as i, CliArtifactInstructionsSchema as l, CliSchemaResolutionSchema as m, parseCliCommandResult as n, CliArchiveInstructionsSchema as o, CliPlanningHomeSchema as p, CliActionContextSchema as r, CliArchiveInstructionsSuccessSchema as s, CliCommandTransportSchema as t, CliArtifactInstructionsSuccessSchema as u, CliShowSpecSchema as v, CliValidateSchema as w, CliTemplateEntrySchema as x, CliSpecListSchema as y };
|