@kindgi/types 0.1.3 → 0.1.4-rc.1

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/version.d.ts CHANGED
@@ -33,4 +33,29 @@ export interface VersionedRef<Id extends string> {
33
33
  readonly id: Id;
34
34
  readonly version: Semver;
35
35
  }
36
+ /**
37
+ * Why the runtime registered a version of an agent or flow under another
38
+ * number than its definition names. Versions never change, so a deploy
39
+ * whose definition's version is registered already with other content
40
+ * registers the next free version in its line instead:
41
+ *
42
+ * - `pins-changed`: the definition's version is registered with other
43
+ * pins (a block it uses has a new version);
44
+ * - `unpinned`: the definition's version was published before pins
45
+ * existed, so it has none;
46
+ * - `version-taken`: the definition's version holds another definition;
47
+ * - `edited`: derived from an existing version with some data-block pins
48
+ * swapped (an expert's edit), not from a definition at all.
49
+ */
50
+ export type VersionDerivationReason = 'pins-changed' | 'unpinned' | 'version-taken' | 'edited';
51
+ /** The version a version was registered in place of (or derived from), and why. */
52
+ export interface VersionDerivation {
53
+ /** The version the definition names, or the one an edit derived from. */
54
+ readonly version: string;
55
+ readonly reason: VersionDerivationReason;
56
+ /** For an edit: a short label for the version (e.g. "warmer tone"). */
57
+ readonly label?: string;
58
+ /** For an edit: who made it (`user:<id>`, or the token for a key). */
59
+ readonly by?: string;
60
+ }
36
61
  //# sourceMappingURL=version.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"version.d.ts","sourceRoot":"","sources":["../src/version.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,UAAU,CAAC;AAEtC;;;;;;;;;;;GAWG;AACH,MAAM,MAAM,MAAM,GAAG,KAAK,CAAC,MAAM,EAAE,QAAQ,CAAC,CAAC;AAE7C;;;;;GAKG;AACH,MAAM,MAAM,WAAW,GAAG,KAAK,CAAC,MAAM,EAAE,aAAa,CAAC,CAAC;AAEvD;;;;;;;;;GASG;AACH,MAAM,WAAW,YAAY,CAAC,EAAE,SAAS,MAAM;IAC7C,QAAQ,CAAC,EAAE,EAAE,EAAE,CAAC;IAChB,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;CAC1B"}
1
+ {"version":3,"file":"version.d.ts","sourceRoot":"","sources":["../src/version.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,UAAU,CAAC;AAEtC;;;;;;;;;;;GAWG;AACH,MAAM,MAAM,MAAM,GAAG,KAAK,CAAC,MAAM,EAAE,QAAQ,CAAC,CAAC;AAE7C;;;;;GAKG;AACH,MAAM,MAAM,WAAW,GAAG,KAAK,CAAC,MAAM,EAAE,aAAa,CAAC,CAAC;AAEvD;;;;;;;;;GASG;AACH,MAAM,WAAW,YAAY,CAAC,EAAE,SAAS,MAAM;IAC7C,QAAQ,CAAC,EAAE,EAAE,EAAE,CAAC;IAChB,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;CAC1B;AAED;;;;;;;;;;;;;GAaG;AACH,MAAM,MAAM,uBAAuB,GAAG,cAAc,GAAG,UAAU,GAAG,eAAe,GAAG,QAAQ,CAAC;AAE/F,mFAAmF;AACnF,MAAM,WAAW,iBAAiB;IAChC,yEAAyE;IACzE,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IACzB,QAAQ,CAAC,MAAM,EAAE,uBAAuB,CAAC;IACzC,uEAAuE;IACvE,QAAQ,CAAC,KAAK,CAAC,EAAE,MAAM,CAAC;IACxB,sEAAsE;IACtE,QAAQ,CAAC,EAAE,CAAC,EAAE,MAAM,CAAC;CACtB"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kindgi/types",
3
- "version": "0.1.3",
3
+ "version": "0.1.4-rc.1",
4
4
  "description": "Foundational TypeScript types shared across Kindgi. Branded IDs, timestamps, hashes, refs, Result, list filter / page shapes. Zero runtime dependencies; the only runtime export is the makeEnvName validator.",
5
5
  "license": "Apache-2.0",
6
6
  "repository": {
package/src/version.ts CHANGED
@@ -39,3 +39,30 @@ export interface VersionedRef<Id extends string> {
39
39
  readonly id: Id;
40
40
  readonly version: Semver;
41
41
  }
42
+
43
+ /**
44
+ * Why the runtime registered a version of an agent or flow under another
45
+ * number than its definition names. Versions never change, so a deploy
46
+ * whose definition's version is registered already with other content
47
+ * registers the next free version in its line instead:
48
+ *
49
+ * - `pins-changed`: the definition's version is registered with other
50
+ * pins (a block it uses has a new version);
51
+ * - `unpinned`: the definition's version was published before pins
52
+ * existed, so it has none;
53
+ * - `version-taken`: the definition's version holds another definition;
54
+ * - `edited`: derived from an existing version with some data-block pins
55
+ * swapped (an expert's edit), not from a definition at all.
56
+ */
57
+ export type VersionDerivationReason = 'pins-changed' | 'unpinned' | 'version-taken' | 'edited';
58
+
59
+ /** The version a version was registered in place of (or derived from), and why. */
60
+ export interface VersionDerivation {
61
+ /** The version the definition names, or the one an edit derived from. */
62
+ readonly version: string;
63
+ readonly reason: VersionDerivationReason;
64
+ /** For an edit: a short label for the version (e.g. "warmer tone"). */
65
+ readonly label?: string;
66
+ /** For an edit: who made it (`user:<id>`, or the token for a key). */
67
+ readonly by?: string;
68
+ }