@sequenceholdings/pipeline-spec 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (126) hide show
  1. package/README.md +114 -0
  2. package/dist/authoring/per-table-ingestion.d.ts +74 -0
  3. package/dist/authoring/per-table-ingestion.d.ts.map +1 -0
  4. package/dist/authoring/per-table-ingestion.js +122 -0
  5. package/dist/authoring/per-table-ingestion.js.map +1 -0
  6. package/dist/authoring/yaml.d.ts +6 -0
  7. package/dist/authoring/yaml.d.ts.map +1 -0
  8. package/dist/authoring/yaml.js +15 -0
  9. package/dist/authoring/yaml.js.map +1 -0
  10. package/dist/binding-gaps.d.ts +21 -0
  11. package/dist/binding-gaps.d.ts.map +1 -0
  12. package/dist/binding-gaps.js +74 -0
  13. package/dist/binding-gaps.js.map +1 -0
  14. package/dist/bodies/ingestion.d.ts +359 -0
  15. package/dist/bodies/ingestion.d.ts.map +1 -0
  16. package/dist/bodies/ingestion.js +446 -0
  17. package/dist/bodies/ingestion.js.map +1 -0
  18. package/dist/bodies/serving.d.ts +316 -0
  19. package/dist/bodies/serving.d.ts.map +1 -0
  20. package/dist/bodies/serving.js +290 -0
  21. package/dist/bodies/serving.js.map +1 -0
  22. package/dist/bodies/transformation.d.ts +397 -0
  23. package/dist/bodies/transformation.d.ts.map +1 -0
  24. package/dist/bodies/transformation.js +278 -0
  25. package/dist/bodies/transformation.js.map +1 -0
  26. package/dist/catalog-binding.d.ts +15 -0
  27. package/dist/catalog-binding.d.ts.map +1 -0
  28. package/dist/catalog-binding.js +15 -0
  29. package/dist/catalog-binding.js.map +1 -0
  30. package/dist/columns.d.ts +177 -0
  31. package/dist/columns.d.ts.map +1 -0
  32. package/dist/columns.js +89 -0
  33. package/dist/columns.js.map +1 -0
  34. package/dist/compatibility.d.ts +25 -0
  35. package/dist/compatibility.d.ts.map +1 -0
  36. package/dist/compatibility.js +108 -0
  37. package/dist/compatibility.js.map +1 -0
  38. package/dist/constants.d.ts +95 -0
  39. package/dist/constants.d.ts.map +1 -0
  40. package/dist/constants.js +105 -0
  41. package/dist/constants.js.map +1 -0
  42. package/dist/diff.d.ts +36 -0
  43. package/dist/diff.d.ts.map +1 -0
  44. package/dist/diff.js +300 -0
  45. package/dist/diff.js.map +1 -0
  46. package/dist/documentation.d.ts +22 -0
  47. package/dist/documentation.d.ts.map +1 -0
  48. package/dist/documentation.js +43 -0
  49. package/dist/documentation.js.map +1 -0
  50. package/dist/envelope.d.ts +1241 -0
  51. package/dist/envelope.d.ts.map +1 -0
  52. package/dist/envelope.js +163 -0
  53. package/dist/envelope.js.map +1 -0
  54. package/dist/errors.d.ts +30 -0
  55. package/dist/errors.d.ts.map +1 -0
  56. package/dist/errors.js +47 -0
  57. package/dist/errors.js.map +1 -0
  58. package/dist/graph-references.d.ts +34 -0
  59. package/dist/graph-references.d.ts.map +1 -0
  60. package/dist/graph-references.js +81 -0
  61. package/dist/graph-references.js.map +1 -0
  62. package/dist/graph.d.ts +112 -0
  63. package/dist/graph.d.ts.map +1 -0
  64. package/dist/graph.js +546 -0
  65. package/dist/graph.js.map +1 -0
  66. package/dist/hash.d.ts +28 -0
  67. package/dist/hash.d.ts.map +1 -0
  68. package/dist/hash.js +91 -0
  69. package/dist/hash.js.map +1 -0
  70. package/dist/index.d.ts +27 -0
  71. package/dist/index.d.ts.map +1 -0
  72. package/dist/index.js +27 -0
  73. package/dist/index.js.map +1 -0
  74. package/dist/issues.d.ts +14 -0
  75. package/dist/issues.d.ts.map +1 -0
  76. package/dist/issues.js +27 -0
  77. package/dist/issues.js.map +1 -0
  78. package/dist/loader.d.ts +50 -0
  79. package/dist/loader.d.ts.map +1 -0
  80. package/dist/loader.js +241 -0
  81. package/dist/loader.js.map +1 -0
  82. package/dist/migrations/contracts.d.ts +38 -0
  83. package/dist/migrations/contracts.d.ts.map +1 -0
  84. package/dist/migrations/contracts.js +175 -0
  85. package/dist/migrations/contracts.js.map +1 -0
  86. package/dist/migrations/manifest.d.ts +137 -0
  87. package/dist/migrations/manifest.d.ts.map +1 -0
  88. package/dist/migrations/manifest.js +137 -0
  89. package/dist/migrations/manifest.js.map +1 -0
  90. package/dist/operations.d.ts +214 -0
  91. package/dist/operations.d.ts.map +1 -0
  92. package/dist/operations.js +275 -0
  93. package/dist/operations.js.map +1 -0
  94. package/dist/orm-satisfies.d.ts +132 -0
  95. package/dist/orm-satisfies.d.ts.map +1 -0
  96. package/dist/orm-satisfies.js +119 -0
  97. package/dist/orm-satisfies.js.map +1 -0
  98. package/dist/primitives.d.ts +11 -0
  99. package/dist/primitives.d.ts.map +1 -0
  100. package/dist/primitives.js +20 -0
  101. package/dist/primitives.js.map +1 -0
  102. package/dist/resolve.d.ts +124 -0
  103. package/dist/resolve.d.ts.map +1 -0
  104. package/dist/resolve.js +194 -0
  105. package/dist/resolve.js.map +1 -0
  106. package/dist/secret-scan.d.ts +34 -0
  107. package/dist/secret-scan.d.ts.map +1 -0
  108. package/dist/secret-scan.js +98 -0
  109. package/dist/secret-scan.js.map +1 -0
  110. package/dist/serving-compatibility.d.ts +14 -0
  111. package/dist/serving-compatibility.d.ts.map +1 -0
  112. package/dist/serving-compatibility.js +19 -0
  113. package/dist/serving-compatibility.js.map +1 -0
  114. package/dist/snapshot-transport.d.ts +83 -0
  115. package/dist/snapshot-transport.d.ts.map +1 -0
  116. package/dist/snapshot-transport.js +42 -0
  117. package/dist/snapshot-transport.js.map +1 -0
  118. package/dist/suggestions.d.ts +3 -0
  119. package/dist/suggestions.d.ts.map +1 -0
  120. package/dist/suggestions.js +26 -0
  121. package/dist/suggestions.js.map +1 -0
  122. package/dist/types.d.ts +72 -0
  123. package/dist/types.d.ts.map +1 -0
  124. package/dist/types.js +119 -0
  125. package/dist/types.js.map +1 -0
  126. package/package.json +52 -0
@@ -0,0 +1,14 @@
1
+ import type { ColumnMap } from './columns.js';
2
+ import { type CompatibilityFinding } from './compatibility.js';
3
+ /**
4
+ * Lakebase sync materializes native ARRAY/MAP/STRUCT columns as JSONB. An
5
+ * explicitly authored `json` serving projection opts into that transport;
6
+ * generic transformation compatibility must not infer the same conversion.
7
+ * This checks types only: source values still need successful sync/readback.
8
+ * https://docs.databricks.com/aws/en/oltp/projects/sync-tables
9
+ */
10
+ export declare function checkServingProjectionCompatibility({ producer, projection, }: {
11
+ producer: ColumnMap;
12
+ projection: ColumnMap;
13
+ }): CompatibilityFinding[];
14
+ //# sourceMappingURL=serving-compatibility.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"serving-compatibility.d.ts","sourceRoot":"","sources":["../src/serving-compatibility.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,cAAc,CAAA;AAC7C,OAAO,EAAsB,KAAK,oBAAoB,EAAE,MAAM,oBAAoB,CAAA;AAIlF;;;;;;GAMG;AACH,wBAAgB,mCAAmC,CAAC,EAClD,QAAQ,EACR,UAAU,GACX,EAAE;IACD,QAAQ,EAAE,SAAS,CAAA;IACnB,UAAU,EAAE,SAAS,CAAA;CACtB,GAAG,oBAAoB,EAAE,CAQzB"}
@@ -0,0 +1,19 @@
1
+ import { checkCompatibility } from './compatibility.js';
2
+ const NATIVE_JSON_TYPES = new Set(['array', 'map', 'struct']);
3
+ /**
4
+ * Lakebase sync materializes native ARRAY/MAP/STRUCT columns as JSONB. An
5
+ * explicitly authored `json` serving projection opts into that transport;
6
+ * generic transformation compatibility must not infer the same conversion.
7
+ * This checks types only: source values still need successful sync/readback.
8
+ * https://docs.databricks.com/aws/en/oltp/projects/sync-tables
9
+ */
10
+ export function checkServingProjectionCompatibility({ producer, projection, }) {
11
+ const servedColumns = {};
12
+ for (const [name, column] of Object.entries(producer)) {
13
+ servedColumns[name] = projection[name]?.type === 'json' && NATIVE_JSON_TYPES.has(column.type)
14
+ ? { ...column, type: 'json' }
15
+ : column;
16
+ }
17
+ return checkCompatibility(servedColumns, projection);
18
+ }
19
+ //# sourceMappingURL=serving-compatibility.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"serving-compatibility.js","sourceRoot":"","sources":["../src/serving-compatibility.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,kBAAkB,EAA6B,MAAM,oBAAoB,CAAA;AAElF,MAAM,iBAAiB,GAAG,IAAI,GAAG,CAAC,CAAC,OAAO,EAAE,KAAK,EAAE,QAAQ,CAAC,CAAC,CAAA;AAE7D;;;;;;GAMG;AACH,MAAM,UAAU,mCAAmC,CAAC,EAClD,QAAQ,EACR,UAAU,GAIX;IACC,MAAM,aAAa,GAAc,EAAE,CAAA;IACnC,KAAK,MAAM,CAAC,IAAI,EAAE,MAAM,CAAC,IAAI,MAAM,CAAC,OAAO,CAAC,QAAQ,CAAC,EAAE,CAAC;QACtD,aAAa,CAAC,IAAI,CAAC,GAAG,UAAU,CAAC,IAAI,CAAC,EAAE,IAAI,KAAK,MAAM,IAAI,iBAAiB,CAAC,GAAG,CAAC,MAAM,CAAC,IAAI,CAAC;YAC3F,CAAC,CAAC,EAAE,GAAG,MAAM,EAAE,IAAI,EAAE,MAAM,EAAE;YAC7B,CAAC,CAAC,MAAM,CAAA;IACZ,CAAC;IACD,OAAO,kBAAkB,CAAC,aAAa,EAAE,UAAU,CAAC,CAAA;AACtD,CAAC"}
@@ -0,0 +1,83 @@
1
+ import { z } from 'zod';
2
+ import { type ColumnMap } from './columns.js';
3
+ export declare const postgresRelationSchema: z.ZodObject<{
4
+ schema: z.ZodString;
5
+ relation: z.ZodString;
6
+ }, z.core.$strict>;
7
+ /** Nonsecret deployment identity. Alias keys are resolved to bindingId before ownership checks. */
8
+ export declare const postgresSnapshotBindingSchema: z.ZodObject<{
9
+ bindingId: z.ZodString;
10
+ database: z.ZodString;
11
+ bindingHash: z.ZodString;
12
+ installationId: z.ZodString;
13
+ }, z.core.$strict>;
14
+ export declare const postgresSnapshotBindingsSchema: z.ZodRecord<z.ZodString, z.ZodObject<{
15
+ bindingId: z.ZodString;
16
+ database: z.ZodString;
17
+ bindingHash: z.ZodString;
18
+ installationId: z.ZodString;
19
+ }, z.core.$strict>>;
20
+ export type PostgresSnapshotBinding = z.infer<typeof postgresSnapshotBindingSchema>;
21
+ export type PostgresSnapshotBindings = Readonly<Record<string, Pick<PostgresSnapshotBinding, 'bindingId' | 'database'>>>;
22
+ export declare const servingTransportSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
23
+ kind: z.ZodLiteral<"native_lakebase_sync_v1">;
24
+ }, z.core.$strict>, z.ZodObject<{
25
+ kind: z.ZodLiteral<"postgres_snapshot_landing_v1">;
26
+ binding: z.ZodString;
27
+ database: z.ZodString;
28
+ entity: z.ZodString;
29
+ landing: z.ZodObject<{
30
+ schema: z.ZodString;
31
+ relation: z.ZodString;
32
+ }, z.core.$strict>;
33
+ buffer: z.ZodObject<{
34
+ schema: z.ZodString;
35
+ relation: z.ZodString;
36
+ }, z.core.$strict>;
37
+ full_source_columns: z.ZodRecord<z.ZodString, z.ZodObject<{
38
+ type: z.ZodUnion<readonly [z.ZodEnum<{
39
+ string: "string";
40
+ boolean: "boolean";
41
+ uuid: "uuid";
42
+ int: "int";
43
+ long: "long";
44
+ numeric: "numeric";
45
+ double: "double";
46
+ timestamp: "timestamp";
47
+ date: "date";
48
+ json: "json";
49
+ }>, z.ZodEnum<{
50
+ float: "float";
51
+ timestamp_ntz: "timestamp_ntz";
52
+ array: "array";
53
+ map: "map";
54
+ struct: "struct";
55
+ binary: "binary";
56
+ }>, z.ZodString]>;
57
+ nullable: z.ZodDefault<z.ZodBoolean>;
58
+ key: z.ZodDefault<z.ZodBoolean>;
59
+ domain: z.ZodOptional<z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean]>>>;
60
+ description: z.ZodOptional<z.ZodString>;
61
+ on_violation: z.ZodDefault<z.ZodEnum<{
62
+ fail: "fail";
63
+ quarantine: "quarantine";
64
+ warn: "warn";
65
+ }>>;
66
+ }, z.core.$strict>>;
67
+ }, z.core.$strict>], "kind">;
68
+ export type ServingTransport = z.infer<typeof servingTransportSchema>;
69
+ export type SnapshotTransport = Extract<ServingTransport, {
70
+ kind: 'postgres_snapshot_landing_v1';
71
+ }>;
72
+ export declare function postgresDestinationKey({ bindingId, database, schema, relation }: {
73
+ bindingId: string;
74
+ database: string;
75
+ schema: string;
76
+ relation: string;
77
+ }): string;
78
+ /** Equality of every type/nullability descriptor; projection-subset checks are separate. */
79
+ export declare function fullSourceShapeEqual({ actual, expected }: {
80
+ actual: ColumnMap;
81
+ expected: ColumnMap;
82
+ }): boolean;
83
+ //# sourceMappingURL=snapshot-transport.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"snapshot-transport.d.ts","sourceRoot":"","sources":["../src/snapshot-transport.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AACvB,OAAO,EAAqC,KAAK,SAAS,EAAE,MAAM,cAAc,CAAA;AAGhF,eAAO,MAAM,sBAAsB;;;kBAA2E,CAAA;AAC9G,mGAAmG;AACnG,eAAO,MAAM,6BAA6B;;;;;kBAKxC,CAAA;AACF,eAAO,MAAM,8BAA8B;;;;;mBAOzC,CAAA;AACF,MAAM,MAAM,uBAAuB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,6BAA6B,CAAC,CAAA;AACnF,MAAM,MAAM,wBAAwB,GAAG,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,IAAI,CAAC,uBAAuB,EAAE,WAAW,GAAG,UAAU,CAAC,CAAC,CAAC,CAAA;AAExH,eAAO,MAAM,sBAAsB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;4BAYjC,CAAA;AACF,MAAM,MAAM,gBAAgB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,sBAAsB,CAAC,CAAA;AACrE,MAAM,MAAM,iBAAiB,GAAG,OAAO,CAAC,gBAAgB,EAAE;IAAE,IAAI,EAAE,8BAA8B,CAAA;CAAE,CAAC,CAAA;AAEnG,wBAAgB,sBAAsB,CAAC,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,EAAE,QAAQ,EAAE,EAAE;IAChF,SAAS,EAAE,MAAM,CAAC;IAAC,QAAQ,EAAE,MAAM,CAAC;IAAC,MAAM,EAAE,MAAM,CAAC;IAAC,QAAQ,EAAE,MAAM,CAAA;CACtE,GAAG,MAAM,CAGT;AAED,4FAA4F;AAC5F,wBAAgB,oBAAoB,CAAC,EAAE,MAAM,EAAE,QAAQ,EAAE,EAAE;IAAE,MAAM,EAAE,SAAS,CAAC;IAAC,QAAQ,EAAE,SAAS,CAAA;CAAE,GAAG,OAAO,CAI9G"}
@@ -0,0 +1,42 @@
1
+ import { z } from 'zod';
2
+ import { columnMapSchema, identifierSchema } from './columns.js';
3
+ import { canonicalJson } from './hash.js';
4
+ export const postgresRelationSchema = z.strictObject({ schema: identifierSchema, relation: identifierSchema });
5
+ /** Nonsecret deployment identity. Alias keys are resolved to bindingId before ownership checks. */
6
+ export const postgresSnapshotBindingSchema = z.strictObject({
7
+ bindingId: z.string().regex(/^[a-z][a-z0-9_-]{0,127}$/),
8
+ database: identifierSchema,
9
+ bindingHash: z.string().regex(/^[a-f0-9]{64}$/),
10
+ installationId: z.string().min(1).max(128),
11
+ });
12
+ export const postgresSnapshotBindingsSchema = z.record(z.string(), postgresSnapshotBindingSchema).superRefine((bindings, ctx) => {
13
+ for (const binding of Object.values(bindings)) {
14
+ const shadow = bindings[binding.bindingId];
15
+ if (shadow && (shadow.bindingId !== binding.bindingId || shadow.database !== binding.database)) {
16
+ ctx.addIssue({ code: 'custom', path: [binding.bindingId], message: 'snapshot alias cannot shadow a canonical binding identity' });
17
+ }
18
+ }
19
+ });
20
+ export const servingTransportSchema = z.discriminatedUnion('kind', [
21
+ z.strictObject({ kind: z.literal('native_lakebase_sync_v1') }),
22
+ z.strictObject({
23
+ kind: z.literal('postgres_snapshot_landing_v1'),
24
+ binding: z.string().regex(/^[a-z][a-z0-9_-]{0,127}$/),
25
+ database: identifierSchema,
26
+ entity: identifierSchema,
27
+ landing: postgresRelationSchema,
28
+ buffer: postgresRelationSchema,
29
+ /** Complete raw output, including columns omitted by the policy projection. */
30
+ full_source_columns: columnMapSchema,
31
+ }),
32
+ ]);
33
+ export function postgresDestinationKey({ bindingId, database, schema, relation }) {
34
+ // Strict unquoted lowercase identifiers exclude PostgreSQL case/truncation aliases.
35
+ return `postgres:${canonicalJson([bindingId, database, schema, relation])}`;
36
+ }
37
+ /** Equality of every type/nullability descriptor; projection-subset checks are separate. */
38
+ export function fullSourceShapeEqual({ actual, expected }) {
39
+ const shape = (columns) => Object.fromEntries(Object.entries(columns).map(([name, column]) => [name, { type: column.type, nullable: column.nullable }]));
40
+ return canonicalJson(shape(actual)) === canonicalJson(shape(expected));
41
+ }
42
+ //# sourceMappingURL=snapshot-transport.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"snapshot-transport.js","sourceRoot":"","sources":["../src/snapshot-transport.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AACvB,OAAO,EAAE,eAAe,EAAE,gBAAgB,EAAkB,MAAM,cAAc,CAAA;AAChF,OAAO,EAAE,aAAa,EAAE,MAAM,WAAW,CAAA;AAEzC,MAAM,CAAC,MAAM,sBAAsB,GAAG,CAAC,CAAC,YAAY,CAAC,EAAE,MAAM,EAAE,gBAAgB,EAAE,QAAQ,EAAE,gBAAgB,EAAE,CAAC,CAAA;AAC9G,mGAAmG;AACnG,MAAM,CAAC,MAAM,6BAA6B,GAAG,CAAC,CAAC,YAAY,CAAC;IAC1D,SAAS,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,KAAK,CAAC,0BAA0B,CAAC;IACvD,QAAQ,EAAE,gBAAgB;IAC1B,WAAW,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,KAAK,CAAC,gBAAgB,CAAC;IAC/C,cAAc,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GA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sB,CAAC,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,EAAE,QAAQ,EAE7E;IACC,oFAAoF;IACpF,OAAO,YAAY,aAAa,CAAC,CAAC,SAAS,EAAE,QAAQ,EAAE,MAAM,EAAE,QAAQ,CAAC,CAAC,EAAE,CAAA;AAC7E,CAAC;AAED,4FAA4F;AAC5F,MAAM,UAAU,oBAAoB,CAAC,EAAE,MAAM,EAAE,QAAQ,EAA8C;IACnG,MAAM,KAAK,GAAG,CAAC,OAAkB,EAAE,EAAE,CAAC,MAAM,CAAC,WAAW,CAAC,MAAM,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,IAAI,EAAE,MAAM,CAAC,EAAE,EAAE,CACtG,CAAC,IAAI,EAAE,EAAE,IAAI,EAAE,MAAM,CAAC,IAAI,EAAE,QAAQ,EAAE,MAAM,CAAC,QAAQ,EAAE,CAAC,CAAC,CAAC,CAAA;IAC5D,OAAO,aAAa,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC,KAAK,aAAa,CAAC,KAAK,CAAC,QAAQ,CAAC,CAAC,CAAA;AACxE,CAAC"}
@@ -0,0 +1,3 @@
1
+ /** Up to three candidates within a length-scaled edit distance of `reference`. */
2
+ export declare function nearMisses(reference: string, candidates: Iterable<string>): string[];
3
+ //# sourceMappingURL=suggestions.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"suggestions.d.ts","sourceRoot":"","sources":["../src/suggestions.ts"],"names":[],"mappings":"AAoBA,kFAAkF;AAClF,wBAAgB,UAAU,CAAC,SAAS,EAAE,MAAM,EAAE,UAAU,EAAE,QAAQ,CAAC,MAAM,CAAC,GAAG,MAAM,EAAE,CAMpF"}
@@ -0,0 +1,26 @@
1
+ /** Bounded Levenshtein distance for near-miss suggestions in findings. */
2
+ function editDistance(a, b) {
3
+ const rows = a.length + 1;
4
+ const cols = b.length + 1;
5
+ const distance = Array.from({ length: rows * cols }, () => 0);
6
+ for (let i = 0; i < rows; i++)
7
+ distance[i * cols] = i;
8
+ for (let j = 0; j < cols; j++)
9
+ distance[j] = j;
10
+ for (let i = 1; i < rows; i++) {
11
+ for (let j = 1; j < cols; j++) {
12
+ const substitution = a[i - 1] === b[j - 1] ? 0 : 1;
13
+ distance[i * cols + j] = Math.min((distance[(i - 1) * cols + j] ?? 0) + 1, (distance[i * cols + j - 1] ?? 0) + 1, (distance[(i - 1) * cols + j - 1] ?? 0) + substitution);
14
+ }
15
+ }
16
+ return distance[rows * cols - 1] ?? 0;
17
+ }
18
+ /** Up to three candidates within a length-scaled edit distance of `reference`. */
19
+ export function nearMisses(reference, candidates) {
20
+ const scored = [...candidates]
21
+ .map((candidate) => ({ candidate, distance: editDistance(reference, candidate) }))
22
+ .filter(({ candidate, distance }) => distance <= Math.max(2, Math.floor(candidate.length / 4)))
23
+ .sort((a, b) => a.distance - b.distance);
24
+ return scored.slice(0, 3).map(({ candidate }) => candidate);
25
+ }
26
+ //# sourceMappingURL=suggestions.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"suggestions.js","sourceRoot":"","sources":["../src/suggestions.ts"],"names":[],"mappings":"AAAA,0EAA0E;AAC1E,SAAS,YAAY,CAAC,CAAS,EAAE,CAAS;IACxC,MAAM,IAAI,GAAG,CAAC,CAAC,MAAM,GAAG,CAAC,CAAA;IACzB,MAAM,IAAI,GAAG,CAAC,CAAC,MAAM,GAAG,CAAC,CAAA;IACzB,MAAM,QAAQ,GAAa,KAAK,CAAC,IAAI,CAAC,EAAE,MAAM,EAAE,IAAI,GAAG,IAAI,EAAE,EAAE,GAAG,EAAE,CAAC,CAAC,CAAC,CAAA;IACvE,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,IAAI,EAAE,CAAC,EAAE;QAAE,QAAQ,CAAC,CAAC,GAAG,IAAI,CAAC,GAAG,CAAC,CAAA;IACrD,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,IAAI,EAAE,CAAC,EA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,EAAE,QAAQ,EAAE,EAAE,EAAE,CAAC,QAAQ,IAAI,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,IAAI,CAAC,KAAK,CAAC,SAAS,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC,CAAC;SAC9F,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,QAAQ,GAAG,CAAC,CAAC,QAAQ,CAAC,CAAA;IAC1C,OAAO,MAAM,CAAC,KAAK,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,EAAE,SAAS,EAAE,EAAE,EAAE,CAAC,SAAS,CAAC,CAAA;AAC7D,CAAC"}
@@ -0,0 +1,72 @@
1
+ import { z } from 'zod';
2
+ /**
3
+ * The one column type vocabulary the whole Data Pipelines platform speaks —
4
+ * a superset of the Sequence ORM's ten column types so tight ORM coupling
5
+ * (`orm_binding.mode: managed`, `satisfies:`) can be turned on later without
6
+ * a type-system migration.
7
+ *
8
+ * The ten named ORM-mappable scalars map 1:1 (see `PIPELINE_TO_ORM_TYPE`);
9
+ * bounded decimals map to ORM numeric without losing their physical declaration. The
10
+ * Delta-only types exist in transformation land but can never cross an
11
+ * `orm_binding` boundary implicitly.
12
+ */
13
+ export declare const ORM_MAPPABLE_TYPES: readonly ["uuid", "string", "int", "long", "numeric", "double", "boolean", "timestamp", "date", "json"];
14
+ export type OrmMappableType = (typeof ORM_MAPPABLE_TYPES)[number];
15
+ /**
16
+ * Delta-only types — usable in transformation outputs and inputs, never in an
17
+ * ORM-bound serving projection. Parameterized decimal is handled separately.
18
+ */
19
+ export declare const DELTA_ONLY_TYPES: readonly ["float", "timestamp_ntz", "array", "map", "struct", "binary"];
20
+ export type DeltaOnlyType = (typeof DELTA_ONLY_TYPES)[number];
21
+ /** `decimal(38,9)`-style parameterized Delta decimal. */
22
+ export declare const DECIMAL_TYPE_PATTERN: RegExp;
23
+ /**
24
+ * The ORM's column types, mirrored from
25
+ * `shared/services/orm/src/schema/columns.ts` (`COLUMN_TYPES`). Kept as a
26
+ * local constant (not an import) so the SDK has no runtime coupling to the
27
+ * ORM package; a parity test reads the ORM source and fails on drift.
28
+ */
29
+ export declare const ORM_COLUMN_TYPES: readonly ["uuid", "text", "integer", "bigint", "numeric", "double", "boolean", "timestamptz", "date", "jsonb"];
30
+ export type OrmColumnType = (typeof ORM_COLUMN_TYPES)[number];
31
+ /**
32
+ * The explicit pipeline→ORM mapping table. Every ORM column type has exactly
33
+ * one pipeline-type preimage (bijection — proven by test), so an ORM-bound
34
+ * projection can be compiled to an ORM table definition losslessly.
35
+ *
36
+ * Complex data (`array`/`map`/`struct`) maps to `jsonb` ONLY by the author
37
+ * explicitly declaring the column as `json` — never implicitly.
38
+ */
39
+ export declare const PIPELINE_TO_ORM_TYPE: Readonly<Record<OrmMappableType, OrmColumnType>>;
40
+ /** Map a physical pipeline declaration to the ORM's logical scalar vocabulary.
41
+ * Decimal precision remains in the pipeline schema; ORM numeric is unbounded.
42
+ */
43
+ export declare function pipelineToOrmType(type: string): OrmColumnType | undefined;
44
+ /** True when `type` may appear in an ORM-bound serving projection. */
45
+ export declare function ormMappable(type: string): boolean;
46
+ /**
47
+ * Suggested remediation for a non-ORM-mappable column type, used to build
48
+ * actionable validation errors (names the mapping the author must opt into).
49
+ */
50
+ export declare function ormMappingSuggestion(type: string): string;
51
+ /** Every legal column `type` value: the mappable scalars, Delta-only names, or a `decimal(p,s)`. */
52
+ export declare const pipelineTypeSchema: z.ZodUnion<readonly [z.ZodEnum<{
53
+ string: "string";
54
+ boolean: "boolean";
55
+ uuid: "uuid";
56
+ int: "int";
57
+ long: "long";
58
+ numeric: "numeric";
59
+ double: "double";
60
+ timestamp: "timestamp";
61
+ date: "date";
62
+ json: "json";
63
+ }>, z.ZodEnum<{
64
+ float: "float";
65
+ timestamp_ntz: "timestamp_ntz";
66
+ array: "array";
67
+ map: "map";
68
+ struct: "struct";
69
+ binary: "binary";
70
+ }>, z.ZodString]>;
71
+ export type PipelineType = z.infer<typeof pipelineTypeSchema>;
72
+ //# sourceMappingURL=types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAEvB;;;;;;;;;;GAUG;AACH,eAAO,MAAM,kBAAkB,yGAWrB,CAAA;AAEV,MAAM,MAAM,eAAe,GAAG,CAAC,OAAO,kBAAkB,CAAC,CAAC,MAAM,CAAC,CAAA;AAEjE;;;GAGG;AACH,eAAO,MAAM,gBAAgB,yEAA0E,CAAA;AAEvG,MAAM,MAAM,aAAa,GAAG,CAAC,OAAO,gBAAgB,CAAC,CAAC,MAAM,CAAC,CAAA;AAE7D,yDAAyD;AACzD,eAAO,MAAM,oBAAoB,QAAwC,CAAA;AAEzE;;;;;GAKG;AACH,eAAO,MAAM,gBAAgB,gHAWnB,CAAA;AAEV,MAAM,MAAM,aAAa,GAAG,CAAC,OAAO,gBAAgB,CAAC,CAAC,MAAM,CAAC,CAAA;AAE7D;;;;;;;GAOG;AACH,eAAO,MAAM,oBAAoB,EAAE,QAAQ,CAAC,MAAM,CAAC,eAAe,EAAE,aAAa,CAAC,CAWjF,CAAA;AAID;;GAEG;AACH,wBAAgB,iBAAiB,CAAC,IAAI,EAAE,MAAM,GAAG,aAAa,GAAG,SAAS,CAIzE;AAED,sEAAsE;AACtE,wBAAgB,WAAW,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAEjD;AAED;;;GAGG;AACH,wBAAgB,oBAAoB,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CASzD;AAED,oGAAoG;AACpG,eAAO,MAAM,kBAAkB;;;;;;;;;;;;;;;;;;iBAa7B,CAAA;AAEF,MAAM,MAAM,YAAY,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,kBAAkB,CAAC,CAAA"}
package/dist/types.js ADDED
@@ -0,0 +1,119 @@
1
+ import { z } from 'zod';
2
+ /**
3
+ * The one column type vocabulary the whole Data Pipelines platform speaks —
4
+ * a superset of the Sequence ORM's ten column types so tight ORM coupling
5
+ * (`orm_binding.mode: managed`, `satisfies:`) can be turned on later without
6
+ * a type-system migration.
7
+ *
8
+ * The ten named ORM-mappable scalars map 1:1 (see `PIPELINE_TO_ORM_TYPE`);
9
+ * bounded decimals map to ORM numeric without losing their physical declaration. The
10
+ * Delta-only types exist in transformation land but can never cross an
11
+ * `orm_binding` boundary implicitly.
12
+ */
13
+ export const ORM_MAPPABLE_TYPES = [
14
+ 'uuid',
15
+ 'string',
16
+ 'int',
17
+ 'long',
18
+ 'numeric',
19
+ 'double',
20
+ 'boolean',
21
+ 'timestamp',
22
+ 'date',
23
+ 'json',
24
+ ];
25
+ /**
26
+ * Delta-only types — usable in transformation outputs and inputs, never in an
27
+ * ORM-bound serving projection. Parameterized decimal is handled separately.
28
+ */
29
+ export const DELTA_ONLY_TYPES = ['float', 'timestamp_ntz', 'array', 'map', 'struct', 'binary'];
30
+ /** `decimal(38,9)`-style parameterized Delta decimal. */
31
+ export const DECIMAL_TYPE_PATTERN = /^decimal\((\d{1,2}),\s*(\d{1,2})\)$/;
32
+ /**
33
+ * The ORM's column types, mirrored from
34
+ * `shared/services/orm/src/schema/columns.ts` (`COLUMN_TYPES`). Kept as a
35
+ * local constant (not an import) so the SDK has no runtime coupling to the
36
+ * ORM package; a parity test reads the ORM source and fails on drift.
37
+ */
38
+ export const ORM_COLUMN_TYPES = [
39
+ 'uuid',
40
+ 'text',
41
+ 'integer',
42
+ 'bigint',
43
+ 'numeric',
44
+ 'double',
45
+ 'boolean',
46
+ 'timestamptz',
47
+ 'date',
48
+ 'jsonb',
49
+ ];
50
+ /**
51
+ * The explicit pipeline→ORM mapping table. Every ORM column type has exactly
52
+ * one pipeline-type preimage (bijection — proven by test), so an ORM-bound
53
+ * projection can be compiled to an ORM table definition losslessly.
54
+ *
55
+ * Complex data (`array`/`map`/`struct`) maps to `jsonb` ONLY by the author
56
+ * explicitly declaring the column as `json` — never implicitly.
57
+ */
58
+ export const PIPELINE_TO_ORM_TYPE = {
59
+ uuid: 'uuid',
60
+ string: 'text',
61
+ int: 'integer',
62
+ long: 'bigint',
63
+ numeric: 'numeric',
64
+ double: 'double',
65
+ boolean: 'boolean',
66
+ timestamp: 'timestamptz',
67
+ date: 'date',
68
+ json: 'jsonb',
69
+ };
70
+ const ORM_MAPPABLE_SET = new Set(ORM_MAPPABLE_TYPES);
71
+ /** Map a physical pipeline declaration to the ORM's logical scalar vocabulary.
72
+ * Decimal precision remains in the pipeline schema; ORM numeric is unbounded.
73
+ */
74
+ export function pipelineToOrmType(type) {
75
+ if (ORM_MAPPABLE_SET.has(type))
76
+ return PIPELINE_TO_ORM_TYPE[type];
77
+ if (DECIMAL_TYPE_PATTERN.test(type) && pipelineTypeSchema.safeParse(type).success)
78
+ return 'numeric';
79
+ return undefined;
80
+ }
81
+ /** True when `type` may appear in an ORM-bound serving projection. */
82
+ export function ormMappable(type) {
83
+ return pipelineToOrmType(type) !== undefined;
84
+ }
85
+ /**
86
+ * Suggested remediation for a non-ORM-mappable column type, used to build
87
+ * actionable validation errors (names the mapping the author must opt into).
88
+ */
89
+ export function ormMappingSuggestion(type) {
90
+ if (type === 'float')
91
+ return "declare it 'double' (maps to double)";
92
+ if (type === 'timestamp_ntz')
93
+ return "declare it 'timestamp' (maps to timestamptz)";
94
+ if (DECIMAL_TYPE_PATTERN.test(type))
95
+ return "declare it 'numeric' (maps to numeric)";
96
+ if (type === 'array' || type === 'map' || type === 'struct') {
97
+ return `declare it 'json' (maps to jsonb) if serving ${type} data as JSON is intended`;
98
+ }
99
+ if (type === 'binary')
100
+ return 'binary has no ORM mapping — exclude it from the projection';
101
+ return "use one of the ORM-mappable types (see PIPELINE_TO_ORM_TYPE)";
102
+ }
103
+ /** Every legal column `type` value: the mappable scalars, Delta-only names, or a `decimal(p,s)`. */
104
+ export const pipelineTypeSchema = z.union([
105
+ z.enum(ORM_MAPPABLE_TYPES),
106
+ z.enum(DELTA_ONLY_TYPES),
107
+ z
108
+ .string()
109
+ .regex(DECIMAL_TYPE_PATTERN, "must be 'decimal(p,s)' with numeric precision and scale")
110
+ .refine((value) => {
111
+ const match = DECIMAL_TYPE_PATTERN.exec(value);
112
+ if (!match)
113
+ return false;
114
+ const precision = Number(match[1]);
115
+ const scale = Number(match[2]);
116
+ return precision >= 1 && precision <= 38 && scale <= precision;
117
+ }, 'decimal precision must be 1–38 and scale must not exceed precision'),
118
+ ]);
119
+ //# sourceMappingURL=types.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.js","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAEvB;;;;;;;;;;GAUG;AACH,MAAM,CAAC,MAAM,kBAAkB,GAAG;IAChC,MAAM;IACN,QAAQ;IACR,KAAK;IACL,MAAM;IACN,SAAS;IACT,QAAQ;IACR,SAAS;IACT,WAAW;IACX,MAAM;IACN,MAAM;CACE,CAAA;AAIV;;;GAGG;AACH,MAAM,CAAC,MAAM,gBAAgB,GAAG,CAAC,OAAO,EAAE,eAAe,EAAE,OAAO,EAAE,KAAK,EAAE,QAAQ,EAAE,QAAQ,CAAU,CAAA;AAIvG,yDAAyD;AACzD,MAAM,CAAC,MAAM,oBAAoB,GAAG,qCAAqC,CAAA;AAEzE;;;;;GAKG;AACH,MAAM,CAAC,MAAM,gBAAgB,GAAG;IAC9B,MAAM;IACN,MAAM;IACN,SAAS;IACT,QAAQ;IACR,SAAS;IACT,QAAQ;IACR,SAAS;IACT,aAAa;IACb,MAAM;IACN,OAAO;CACC,CAAA;AAIV;;;;;;;GAOG;AACH,MAAM,CAAC,MAAM,oBAAoB,GAAqD;IACpF,IAAI,EAAE,MAAM;IACZ,MAAM,EAAE,MAAM;IACd,GAAG,EAAE,SAAS;IACd,IAAI,EAAE,QAAQ;IACd,OAAO,EAAE,SAAS;IAClB,MAAM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,CAAC,CAAC,IAAI,CAAC,gBAAgB,CAAC;IACxB,CAAC;SACE,MAAM,EAAE;SACR,KAAK,CAAC,oBAAoB,EAAE,yDAAyD,CAAC;SACtF,MAAM,CAAC,CAAC,KAAK,EAAE,EAAE;QAChB,MAAM,KAAK,GAAG,oBAAoB,CAAC,IAAI,CAAC,KAAK,CAAC,CAAA;QAC9C,IAAI,CAAC,KAAK;YAAE,OAAO,KAAK,CAAA;QACxB,MAAM,SAAS,GAAG,MAAM,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,CAAA;QAClC,MAAM,KAAK,GAAG,MAAM,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,CAAA;QAC9B,OAAO,SAAS,IAAI,CAAC,IAAI,SAAS,IAAI,EAAE,IAAI,KAAK,IAAI,SAAS,CAAA;IAChE,CAAC,EAAE,oEAAoE,CAAC;CAC3E,CAAC,CAAA"}
package/package.json ADDED
@@ -0,0 +1,52 @@
1
+ {
2
+ "name": "@sequenceholdings/pipeline-spec",
3
+ "version": "0.1.0",
4
+ "description": "Data Pipelines spec SDK — typed stage specs (ingestion/transformation/serving), directory loader, target resolution with deterministic hashing, and offline graph validation",
5
+ "license": "UNLICENSED",
6
+ "publishConfig": {
7
+ "access": "public"
8
+ },
9
+ "repository": {
10
+ "type": "git",
11
+ "url": "https://github.com/sequenceholdings/studio.git",
12
+ "directory": "shared/services/pipeline-spec"
13
+ },
14
+ "type": "module",
15
+ "main": "./dist/index.js",
16
+ "types": "./dist/index.d.ts",
17
+ "exports": {
18
+ ".": {
19
+ "types": "./dist/index.d.ts",
20
+ "import": "./dist/index.js"
21
+ }
22
+ },
23
+ "files": [
24
+ "dist",
25
+ "README.md"
26
+ ],
27
+ "dependencies": {
28
+ "js-yaml": "^4.3.2",
29
+ "zod": "^4.1.13"
30
+ },
31
+ "devDependencies": {
32
+ "@types/js-yaml": "^4.0.9",
33
+ "@types/node": "^22.0.0",
34
+ "typescript": "^5.6.0",
35
+ "vitest": "^4.1.11"
36
+ },
37
+ "engines": {
38
+ "node": ">=20"
39
+ },
40
+ "keywords": [
41
+ "data-pipelines",
42
+ "spec",
43
+ "zod",
44
+ "databricks"
45
+ ],
46
+ "scripts": {
47
+ "build": "rm -rf dist && tsc",
48
+ "type-check": "tsc --noEmit",
49
+ "test": "vitest run",
50
+ "test:watch": "vitest"
51
+ }
52
+ }