rivet-design 0.26.0 → 0.26.2

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 (96) hide show
  1. package/bin/rivet.js +13 -0
  2. package/dist/agent-variants/WorkerExecutorService.d.ts +0 -2
  3. package/dist/agent-variants/WorkerExecutorService.js +0 -18
  4. package/dist/agent-variants/WorktreeOrchestrator.testHelpers.js +0 -8
  5. package/dist/agent-variants/contracts.d.ts +1099 -4966
  6. package/dist/agent-variants/contracts.js +1 -121
  7. package/dist/agent-variants/index.d.ts +1 -1
  8. package/dist/agent-variants/variantsTelemetry.d.ts +0 -8
  9. package/dist/agent-variants/workItemInput.d.ts +464 -464
  10. package/dist/cli/commands/contextRequest.js +1 -1
  11. package/dist/cli/commands/guidanceReferences.d.ts +2 -2
  12. package/dist/cli/commands/guidanceVerifierPackage.d.ts +2 -2
  13. package/dist/cli/editorSession.d.ts +1 -13
  14. package/dist/cli/runtimeInterruption.d.ts +2 -16
  15. package/dist/config/pluginMetrics.js +0 -1
  16. package/dist/hosts/workerDefaults.d.ts +0 -11
  17. package/dist/hosts/workerDefaults.js +1 -30
  18. package/dist/index-core.d.ts +0 -1
  19. package/dist/index.js +1 -1
  20. package/dist/install/automaticCliUpdate.d.ts +1 -0
  21. package/dist/install/automaticCliUpdate.js +32 -22
  22. package/dist/install/channelCli.d.ts +1 -1
  23. package/dist/install/channelCli.js +11 -6
  24. package/dist/install/channelManager.d.ts +5 -2
  25. package/dist/install/globalBootstrap.d.ts +5 -3
  26. package/dist/install/globalBootstrap.js +21 -9
  27. package/dist/install/npmCommand.d.ts +15 -0
  28. package/dist/install/npmCommand.js +59 -0
  29. package/dist/routes/agentVariants.js +3 -14
  30. package/dist/routes/library/browserAccess.js +6 -2
  31. package/dist/routes/library/guidance.js +3 -1
  32. package/dist/routes/library/middleware.js +4 -4
  33. package/dist/routes/library/navigation.js +3 -1
  34. package/dist/routes/library/profiles.js +5 -5
  35. package/dist/routes/library/projects.js +17 -7
  36. package/dist/routes/library/referenceOnboarding.js +4 -2
  37. package/dist/routes/library/schemas.d.ts +2 -15
  38. package/dist/routes/telemetry.js +1 -1
  39. package/dist/routes/variantRequestSchema.d.ts +8 -8
  40. package/dist/routes/variantRequestSchema.js +7 -2
  41. package/dist/services/AuthService.d.ts +3 -56
  42. package/dist/services/AuthService.js +0 -28
  43. package/dist/services/ConfigManager.d.ts +0 -2
  44. package/dist/services/ConfigManager.js +0 -14
  45. package/dist/services/GuidanceVerifierRunner.js +13 -2
  46. package/dist/services/HubDiscovery.d.ts +1 -9
  47. package/dist/services/IntegrationsClient.d.ts +16 -16
  48. package/dist/services/MCPOnboardingTelemetry.d.ts +0 -14
  49. package/dist/services/MCPOnboardingTelemetry.js +0 -62
  50. package/dist/services/ProjectRegistry.d.ts +5 -24
  51. package/dist/services/TelemetryService.d.ts +1 -62
  52. package/dist/services/TelemetryService.js +0 -113
  53. package/dist/services/TreeStore.d.ts +0 -2
  54. package/dist/services/TreeStore.js +0 -24
  55. package/dist/services/profiles/DesignProfiles.d.ts +180 -125
  56. package/dist/services/profiles/ProfilePlanning.d.ts +38 -38
  57. package/dist/services/profiles/ReferenceReader.d.ts +14 -14
  58. package/dist/services/profiles/modelContract.js +4 -4
  59. package/dist/storage/library/ProjectPreviewCache.d.ts +1 -13
  60. package/dist/storage/profiles/ProfilePlans.d.ts +137 -137
  61. package/dist/storage/profiles/ProfileRecords.d.ts +62 -37
  62. package/dist/storage/profiles/planSchema.d.ts +40 -40
  63. package/dist/storage/profiles/schema.d.ts +16 -16
  64. package/dist/types/api-responses.d.ts +174 -0
  65. package/dist/types/api-responses.js +108 -0
  66. package/dist/types/cosmos-profile.d.ts +17 -105
  67. package/dist/types/cosmos.d.ts +48 -266
  68. package/dist/types/design-library.d.ts +230 -61
  69. package/dist/types/design-library.js +38 -1
  70. package/dist/types/design-profile.d.ts +220 -529
  71. package/dist/types/design-profile.js +5 -1
  72. package/dist/types/guidance-references.d.ts +68 -316
  73. package/dist/types/guidance-verifier.d.ts +103 -197
  74. package/dist/types/guidance-verifier.js +36 -13
  75. package/dist/types/guidance.d.ts +182 -1643
  76. package/dist/types/guidance.js +4 -1
  77. package/dist/types/project-library.d.ts +60 -30
  78. package/dist/types/project-library.js +32 -1
  79. package/dist/types/reference-connectors.d.ts +38 -162
  80. package/dist/types/reference-onboarding.d.ts +144 -878
  81. package/dist/types/reference-pages.d.ts +27 -139
  82. package/dist/types/x-bookmarks.d.ts +40 -296
  83. package/dist/utils/displayLocale.d.ts +0 -1
  84. package/dist/utils/displayLocale.js +1 -3
  85. package/dist/utils/skills/cli-guidance.d.ts +1 -1
  86. package/dist/utils/skills/cli-guidance.js +2 -2
  87. package/package.json +4 -4
  88. package/src/ui/dist/assets/LibraryEntry-92R_T-Xa.js +37 -0
  89. package/src/ui/dist/assets/main-D0UmAaUe.css +1 -0
  90. package/src/ui/dist/assets/main-DgEfJvYu.js +497 -0
  91. package/src/ui/dist/index.html +2 -2
  92. package/dist/types/change-types.d.ts +0 -66
  93. package/dist/types/change-types.js +0 -3
  94. package/src/ui/dist/assets/LibraryEntry-CFkd6v_O.js +0 -37
  95. package/src/ui/dist/assets/main-B_jie9r3.js +0 -439
  96. package/src/ui/dist/assets/main-W3oTuTTl.css +0 -1
@@ -1,130 +1,102 @@
1
1
  import { z } from 'zod';
2
2
  import type { GuidanceDocument } from './guidance';
3
- export declare const GuidanceVerifierPackageSchema: z.ZodEffects<z.ZodObject<{
3
+ export declare const GuidanceVerifierPackageSchema: z.ZodObject<{
4
4
  runtime: z.ZodLiteral<"node">;
5
- entrypoint: z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
6
- files: z.ZodEffects<z.ZodArray<z.ZodObject<{
7
- name: z.ZodEffects<z.ZodString, string, string>;
8
- content: z.ZodEffects<z.ZodString, string, string>;
9
- }, "strict", z.ZodTypeAny, {
10
- name: string;
11
- content: string;
12
- }, {
13
- name: string;
14
- content: string;
15
- }>, "many">, {
16
- name: string;
17
- content: string;
18
- }[], {
19
- name: string;
20
- content: string;
21
- }[]>;
22
- }, "strict", z.ZodTypeAny, {
23
- files: {
24
- name: string;
25
- content: string;
26
- }[];
27
- runtime: "node";
28
- entrypoint: string;
29
- }, {
30
- files: {
31
- name: string;
32
- content: string;
33
- }[];
34
- runtime: "node";
35
- entrypoint: string;
36
- }>, {
37
- files: {
38
- name: string;
39
- content: string;
40
- }[];
41
- runtime: "node";
42
- entrypoint: string;
43
- }, {
44
- files: {
45
- name: string;
46
- content: string;
47
- }[];
48
- runtime: "node";
49
- entrypoint: string;
50
- }>;
51
- export type GuidanceVerifierPackage = z.infer<typeof GuidanceVerifierPackageSchema>;
52
- export declare const GuidanceVerifierResultSchema: z.ZodEffects<z.ZodObject<{
53
- checks: z.ZodArray<z.ZodObject<{
5
+ entrypoint: z.ZodString;
6
+ files: z.ZodArray<z.ZodObject<{
7
+ name: z.ZodString;
8
+ content: z.ZodString;
9
+ }, z.core.$strict>>;
10
+ }, z.core.$strict>;
11
+ export declare const GuidanceVerifierResultSchema: z.ZodObject<{
12
+ checks: z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<{
54
13
  id: z.ZodString;
55
- category: z.ZodString;
56
- status: z.ZodEnum<["pass", "fail", "blocked"]>;
57
- rule: z.ZodString;
58
- target: z.ZodString;
59
- expected: z.ZodEffects<z.ZodType<unknown, z.ZodTypeDef, unknown>, unknown, unknown>;
60
- observed: z.ZodEffects<z.ZodType<unknown, z.ZodTypeDef, unknown>, unknown, unknown>;
61
- evidence: z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">>;
62
- }, "strict", z.ZodTypeAny, {
63
- status: "pass" | "fail" | "blocked";
64
- id: string;
65
- category: string;
66
- rule: string;
67
- target: string;
68
- expected?: unknown;
69
- observed?: unknown;
70
- evidence?: string[] | undefined;
71
- }, {
72
- status: "pass" | "fail" | "blocked";
73
- id: string;
74
- category: string;
75
- rule: string;
76
- target: string;
77
- expected?: unknown;
78
- observed?: unknown;
79
- evidence?: string[] | undefined;
80
- }>, "many">;
81
- }, "strict", z.ZodTypeAny, {
82
- checks: {
83
- status: "pass" | "fail" | "blocked";
84
- id: string;
85
- category: string;
86
- rule: string;
87
- target: string;
88
- expected?: unknown;
89
- observed?: unknown;
90
- evidence?: string[] | undefined;
91
- }[];
92
- }, {
93
- checks: {
94
- status: "pass" | "fail" | "blocked";
95
- id: string;
96
- category: string;
97
- rule: string;
98
- target: string;
99
- expected?: unknown;
100
- observed?: unknown;
101
- evidence?: string[] | undefined;
102
- }[];
103
- }>, {
104
- checks: {
105
- status: "pass" | "fail" | "blocked";
106
- id: string;
107
- category: string;
108
- rule: string;
109
- target: string;
110
- expected?: unknown;
111
- observed?: unknown;
112
- evidence?: string[] | undefined;
113
- }[];
114
- }, {
115
- checks: {
116
- status: "pass" | "fail" | "blocked";
117
- id: string;
118
- category: string;
119
- rule: string;
120
- target: string;
121
- expected?: unknown;
122
- observed?: unknown;
123
- evidence?: string[] | undefined;
124
- }[];
125
- }>;
14
+ priority: z.ZodNullable<z.ZodEnum<{
15
+ high: "high";
16
+ medium: "medium";
17
+ low: "low";
18
+ }>>;
19
+ currentState: z.ZodString;
20
+ proposedFix: z.ZodNullable<z.ZodString>;
21
+ evidence: z.ZodArray<z.ZodObject<{
22
+ path: z.ZodString;
23
+ mediaType: z.ZodString;
24
+ label: z.ZodString;
25
+ role: z.ZodEnum<{
26
+ reference: "reference";
27
+ observed: "observed";
28
+ }>;
29
+ }, z.core.$strict>>;
30
+ comparison: z.ZodOptional<z.ZodObject<{
31
+ expected: z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>;
32
+ observed: z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>;
33
+ unit: z.ZodNullable<z.ZodString>;
34
+ }, z.core.$strict>>;
35
+ location: z.ZodOptional<z.ZodString>;
36
+ status: z.ZodLiteral<"pass">;
37
+ problem: z.ZodNull;
38
+ }, z.core.$strict>, z.ZodObject<{
39
+ id: z.ZodString;
40
+ priority: z.ZodNullable<z.ZodEnum<{
41
+ high: "high";
42
+ medium: "medium";
43
+ low: "low";
44
+ }>>;
45
+ currentState: z.ZodString;
46
+ proposedFix: z.ZodNullable<z.ZodString>;
47
+ evidence: z.ZodArray<z.ZodObject<{
48
+ path: z.ZodString;
49
+ mediaType: z.ZodString;
50
+ label: z.ZodString;
51
+ role: z.ZodEnum<{
52
+ reference: "reference";
53
+ observed: "observed";
54
+ }>;
55
+ }, z.core.$strict>>;
56
+ comparison: z.ZodOptional<z.ZodObject<{
57
+ expected: z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>;
58
+ observed: z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>;
59
+ unit: z.ZodNullable<z.ZodString>;
60
+ }, z.core.$strict>>;
61
+ location: z.ZodOptional<z.ZodString>;
62
+ status: z.ZodLiteral<"fail">;
63
+ problem: z.ZodString;
64
+ }, z.core.$strict>, z.ZodObject<{
65
+ id: z.ZodString;
66
+ priority: z.ZodNullable<z.ZodEnum<{
67
+ high: "high";
68
+ medium: "medium";
69
+ low: "low";
70
+ }>>;
71
+ currentState: z.ZodString;
72
+ proposedFix: z.ZodNullable<z.ZodString>;
73
+ evidence: z.ZodArray<z.ZodObject<{
74
+ path: z.ZodString;
75
+ mediaType: z.ZodString;
76
+ label: z.ZodString;
77
+ role: z.ZodEnum<{
78
+ reference: "reference";
79
+ observed: "observed";
80
+ }>;
81
+ }, z.core.$strict>>;
82
+ comparison: z.ZodOptional<z.ZodObject<{
83
+ expected: z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>;
84
+ observed: z.ZodType<unknown, unknown, z.core.$ZodTypeInternals<unknown, unknown>>;
85
+ unit: z.ZodNullable<z.ZodString>;
86
+ }, z.core.$strict>>;
87
+ location: z.ZodOptional<z.ZodString>;
88
+ status: z.ZodLiteral<"blocked">;
89
+ problem: z.ZodString;
90
+ }, z.core.$strict>], "status">>;
91
+ }, z.core.$strict>;
126
92
  export type GuidanceVerifierResult = z.infer<typeof GuidanceVerifierResultSchema>;
127
93
  export type GuidanceVerifierRun = {
94
+ schemaVersion: 1;
95
+ verifier: {
96
+ contextId: string;
97
+ sourceDigest: string;
98
+ };
99
+ projectPath: string;
128
100
  runDirectory: string;
129
101
  durationMs: number;
130
102
  } & ({
@@ -145,86 +117,20 @@ export interface GuidanceVerifierInput {
145
117
  };
146
118
  }
147
119
  export declare const GuidanceVerifierSchema: z.ZodObject<{
148
- markdown: z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
149
- package: z.ZodOptional<z.ZodEffects<z.ZodObject<{
120
+ markdown: z.ZodString;
121
+ package: z.ZodOptional<z.ZodObject<{
150
122
  runtime: z.ZodLiteral<"node">;
151
- entrypoint: z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
152
- files: z.ZodEffects<z.ZodArray<z.ZodObject<{
153
- name: z.ZodEffects<z.ZodString, string, string>;
154
- content: z.ZodEffects<z.ZodString, string, string>;
155
- }, "strict", z.ZodTypeAny, {
156
- name: string;
157
- content: string;
158
- }, {
159
- name: string;
160
- content: string;
161
- }>, "many">, {
162
- name: string;
163
- content: string;
164
- }[], {
165
- name: string;
166
- content: string;
167
- }[]>;
168
- }, "strict", z.ZodTypeAny, {
169
- files: {
170
- name: string;
171
- content: string;
172
- }[];
173
- runtime: "node";
174
- entrypoint: string;
175
- }, {
176
- files: {
177
- name: string;
178
- content: string;
179
- }[];
180
- runtime: "node";
181
- entrypoint: string;
182
- }>, {
183
- files: {
184
- name: string;
185
- content: string;
186
- }[];
187
- runtime: "node";
188
- entrypoint: string;
189
- }, {
190
- files: {
191
- name: string;
192
- content: string;
193
- }[];
194
- runtime: "node";
195
- entrypoint: string;
196
- }>>;
123
+ entrypoint: z.ZodString;
124
+ files: z.ZodArray<z.ZodObject<{
125
+ name: z.ZodString;
126
+ content: z.ZodString;
127
+ }, z.core.$strict>>;
128
+ }, z.core.$strict>>;
197
129
  sourceDigest: z.ZodString;
198
- }, "strict", z.ZodTypeAny, {
199
- markdown: string;
200
- sourceDigest: string;
201
- package?: {
202
- files: {
203
- name: string;
204
- content: string;
205
- }[];
206
- runtime: "node";
207
- entrypoint: string;
208
- } | undefined;
209
- }, {
210
- markdown: string;
211
- sourceDigest: string;
212
- package?: {
213
- files: {
214
- name: string;
215
- content: string;
216
- }[];
217
- runtime: "node";
218
- entrypoint: string;
219
- } | undefined;
220
- }>;
130
+ }, z.core.$strict>;
221
131
  export declare const GuidanceVerifierSummarySchema: z.ZodObject<{
222
132
  isStale: z.ZodBoolean;
223
- }, "strict", z.ZodTypeAny, {
224
- isStale: boolean;
225
- }, {
226
- isStale: boolean;
227
- }>;
133
+ }, z.core.$strict>;
228
134
  export type GuidanceVerifier = z.infer<typeof GuidanceVerifierSchema>;
229
135
  interface GuidanceVerificationSource {
230
136
  source: GuidanceDocument;
@@ -20,29 +20,52 @@ const JsonValueSchema = zod_1.z.lazy(() => zod_1.z.union([
20
20
  zod_1.z.boolean(),
21
21
  zod_1.z.null(),
22
22
  zod_1.z.array(JsonValueSchema),
23
- zod_1.z.record(JsonValueSchema),
23
+ zod_1.z.record(zod_1.z.string(), JsonValueSchema),
24
24
  ]));
25
25
  const CheckValueSchema = JsonValueSchema.refine((value) => value !== undefined &&
26
26
  Buffer.byteLength(JSON.stringify(value)) <= VALUE_BYTES, 'Check values must be bounded JSON');
27
27
  const CheckTextSchema = zod_1.z.string().trim().min(1).max(CHECK_TEXT_LENGTH);
28
- exports.GuidanceVerifierResultSchema = zod_1.z
28
+ const CheckSchema = zod_1.z
29
29
  .object({
30
- checks: zod_1.z
30
+ id: CheckTextSchema,
31
+ priority: zod_1.z.enum(['high', 'medium', 'low']).nullable(),
32
+ currentState: CheckTextSchema,
33
+ proposedFix: CheckTextSchema.nullable(),
34
+ evidence: zod_1.z
31
35
  .array(zod_1.z
32
36
  .object({
33
- id: CheckTextSchema,
34
- category: CheckTextSchema,
35
- status: zod_1.z.enum(['pass', 'fail', 'blocked']),
36
- rule: CheckTextSchema,
37
- target: CheckTextSchema,
37
+ path: guidance_references_1.GuidanceReferenceNameSchema,
38
+ mediaType: CheckTextSchema.regex(/^[a-z0-9][a-z0-9!#$&^_.+-]*\/[a-z0-9][a-z0-9!#$&^_.+-]*$/i),
39
+ label: CheckTextSchema,
40
+ role: zod_1.z.enum(['observed', 'reference']),
41
+ })
42
+ .strict())
43
+ .max(CHECK_LIMIT),
44
+ comparison: zod_1.z
45
+ .object({
38
46
  expected: CheckValueSchema,
39
47
  observed: CheckValueSchema,
40
- evidence: zod_1.z
41
- .array(guidance_references_1.GuidanceReferenceNameSchema)
42
- .max(CHECK_LIMIT)
43
- .optional(),
48
+ unit: CheckTextSchema.nullable(),
44
49
  })
45
- .strict())
50
+ .strict()
51
+ .optional(),
52
+ location: CheckTextSchema.optional(),
53
+ })
54
+ .strict();
55
+ exports.GuidanceVerifierResultSchema = zod_1.z
56
+ .object({
57
+ checks: zod_1.z
58
+ .array(zod_1.z.discriminatedUnion('status', [
59
+ CheckSchema.extend({ status: zod_1.z.literal('pass'), problem: zod_1.z.null() }),
60
+ CheckSchema.extend({
61
+ status: zod_1.z.literal('fail'),
62
+ problem: CheckTextSchema,
63
+ }),
64
+ CheckSchema.extend({
65
+ status: zod_1.z.literal('blocked'),
66
+ problem: CheckTextSchema,
67
+ }),
68
+ ]))
46
69
  .min(1)
47
70
  .max(CHECK_LIMIT),
48
71
  })