@manehorizons/cadence-types 1.1.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.
Files changed (47) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +5 -0
  3. package/dist/anomaly.d.ts +42 -0
  4. package/dist/anomaly.d.ts.map +1 -0
  5. package/dist/anomaly.js +42 -0
  6. package/dist/anomaly.js.map +1 -0
  7. package/dist/config.d.ts +825 -0
  8. package/dist/config.d.ts.map +1 -0
  9. package/dist/config.js +234 -0
  10. package/dist/config.js.map +1 -0
  11. package/dist/events.d.ts +30 -0
  12. package/dist/events.d.ts.map +1 -0
  13. package/dist/events.js +20 -0
  14. package/dist/events.js.map +1 -0
  15. package/dist/host.d.ts +10 -0
  16. package/dist/host.d.ts.map +1 -0
  17. package/dist/host.js +2 -0
  18. package/dist/host.js.map +1 -0
  19. package/dist/index.d.ts +11 -0
  20. package/dist/index.d.ts.map +1 -0
  21. package/dist/index.js +11 -0
  22. package/dist/index.js.map +1 -0
  23. package/dist/intelligence.d.ts +1876 -0
  24. package/dist/intelligence.d.ts.map +1 -0
  25. package/dist/intelligence.js +321 -0
  26. package/dist/intelligence.js.map +1 -0
  27. package/dist/plan.d.ts +168 -0
  28. package/dist/plan.d.ts.map +1 -0
  29. package/dist/plan.js +36 -0
  30. package/dist/plan.js.map +1 -0
  31. package/dist/profile.d.ts +23 -0
  32. package/dist/profile.d.ts.map +1 -0
  33. package/dist/profile.js +32 -0
  34. package/dist/profile.js.map +1 -0
  35. package/dist/spec.d.ts +67 -0
  36. package/dist/spec.d.ts.map +1 -0
  37. package/dist/spec.js +19 -0
  38. package/dist/spec.js.map +1 -0
  39. package/dist/state.d.ts +256 -0
  40. package/dist/state.d.ts.map +1 -0
  41. package/dist/state.js +81 -0
  42. package/dist/state.js.map +1 -0
  43. package/dist/summary.d.ts +283 -0
  44. package/dist/summary.d.ts.map +1 -0
  45. package/dist/summary.js +42 -0
  46. package/dist/summary.js.map +1 -0
  47. package/package.json +46 -0
package/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 Thomas Powers
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md ADDED
@@ -0,0 +1,5 @@
1
+ # @manehorizons/cadence-types
2
+
3
+ Shared Zod schemas and TypeScript types for CADENCE (config, state, anomalies, summaries).
4
+
5
+ Part of the [CADENCE](https://github.com/manehorizons/cadence) monorepo. MIT licensed.
@@ -0,0 +1,42 @@
1
+ import { z } from 'zod';
2
+ /**
3
+ * Anomaly event types. Phase 17 introduced the first six; Phase 23.2 adds
4
+ * `coherence-warn` (emitted from `cadence draft check`/`draft approve` per
5
+ * warn issue). DESIGN.md §3.3 is the canonical list.
6
+ *
7
+ * Fired when the `'anomaly-notify'` gate is in the effective gate set
8
+ * (auto + standard×{standard,complex} cells). Informational only —
9
+ * never block the emitting command.
10
+ */
11
+ export declare const AnomalyTypeZ: z.ZodEnum<["ac-blocked", "ac-needs-context", "coverage-bypassed", "files-outside-boundary", "verifier-failure", "force-used", "coherence-warn", "loop-violation", "per-task-fail", "code-review-high", "skill-audit-miss", "plan-review-unconverged", "spec-review-unconverged", "code-review-unconverged"]>;
12
+ export type AnomalyType = z.infer<typeof AnomalyTypeZ>;
13
+ export declare const AnomalySeverityZ: z.ZodEnum<["info", "warn", "error"]>;
14
+ export type AnomalySeverity = z.infer<typeof AnomalySeverityZ>;
15
+ export declare const AnomalyEventZ: z.ZodObject<{
16
+ type: z.ZodEnum<["ac-blocked", "ac-needs-context", "coverage-bypassed", "files-outside-boundary", "verifier-failure", "force-used", "coherence-warn", "loop-violation", "per-task-fail", "code-review-high", "skill-audit-miss", "plan-review-unconverged", "spec-review-unconverged", "code-review-unconverged"]>;
17
+ severity: z.ZodEnum<["info", "warn", "error"]>;
18
+ /** One-line human-readable description. */
19
+ message: z.ZodString;
20
+ /** Type-specific free-form payload. */
21
+ context: z.ZodRecord<z.ZodString, z.ZodUnknown>;
22
+ /**
23
+ * Wall-clock when the event was constructed. ISO8601 with offset
24
+ * (e.g., `"2026-05-14T22:30:00.000Z"`). Emitters stamp via
25
+ * `new Date().toISOString()`. Phase 17.3.
26
+ */
27
+ ts: z.ZodString;
28
+ }, "strip", z.ZodTypeAny, {
29
+ message: string;
30
+ type: "ac-blocked" | "ac-needs-context" | "coverage-bypassed" | "files-outside-boundary" | "verifier-failure" | "force-used" | "coherence-warn" | "loop-violation" | "per-task-fail" | "code-review-high" | "skill-audit-miss" | "plan-review-unconverged" | "spec-review-unconverged" | "code-review-unconverged";
31
+ severity: "info" | "warn" | "error";
32
+ context: Record<string, unknown>;
33
+ ts: string;
34
+ }, {
35
+ message: string;
36
+ type: "ac-blocked" | "ac-needs-context" | "coverage-bypassed" | "files-outside-boundary" | "verifier-failure" | "force-used" | "coherence-warn" | "loop-violation" | "per-task-fail" | "code-review-high" | "skill-audit-miss" | "plan-review-unconverged" | "spec-review-unconverged" | "code-review-unconverged";
37
+ severity: "info" | "warn" | "error";
38
+ context: Record<string, unknown>;
39
+ ts: string;
40
+ }>;
41
+ export type AnomalyEvent = z.infer<typeof AnomalyEventZ>;
42
+ //# sourceMappingURL=anomaly.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"anomaly.d.ts","sourceRoot":"","sources":["../src/anomaly.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB;;;;;;;;GAQG;AACH,eAAO,MAAM,YAAY,8SAevB,CAAC;AACH,MAAM,MAAM,WAAW,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,YAAY,CAAC,CAAC;AAEvD,eAAO,MAAM,gBAAgB,sCAAoC,CAAC;AAClE,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,gBAAgB,CAAC,CAAC;AAE/D,eAAO,MAAM,aAAa;;;IAGxB,2CAA2C;;IAE3C,uCAAuC;;IAEvC;;;;OAIG;;;;;;;;;;;;;;EAEH,CAAC;AACH,MAAM,MAAM,YAAY,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,aAAa,CAAC,CAAC"}
@@ -0,0 +1,42 @@
1
+ import { z } from 'zod';
2
+ /**
3
+ * Anomaly event types. Phase 17 introduced the first six; Phase 23.2 adds
4
+ * `coherence-warn` (emitted from `cadence draft check`/`draft approve` per
5
+ * warn issue). DESIGN.md §3.3 is the canonical list.
6
+ *
7
+ * Fired when the `'anomaly-notify'` gate is in the effective gate set
8
+ * (auto + standard×{standard,complex} cells). Informational only —
9
+ * never block the emitting command.
10
+ */
11
+ export const AnomalyTypeZ = z.enum([
12
+ 'ac-blocked',
13
+ 'ac-needs-context',
14
+ 'coverage-bypassed',
15
+ 'files-outside-boundary',
16
+ 'verifier-failure',
17
+ 'force-used',
18
+ 'coherence-warn',
19
+ 'loop-violation',
20
+ 'per-task-fail',
21
+ 'code-review-high',
22
+ 'skill-audit-miss',
23
+ 'plan-review-unconverged',
24
+ 'spec-review-unconverged',
25
+ 'code-review-unconverged',
26
+ ]);
27
+ export const AnomalySeverityZ = z.enum(['info', 'warn', 'error']);
28
+ export const AnomalyEventZ = z.object({
29
+ type: AnomalyTypeZ,
30
+ severity: AnomalySeverityZ,
31
+ /** One-line human-readable description. */
32
+ message: z.string(),
33
+ /** Type-specific free-form payload. */
34
+ context: z.record(z.unknown()),
35
+ /**
36
+ * Wall-clock when the event was constructed. ISO8601 with offset
37
+ * (e.g., `"2026-05-14T22:30:00.000Z"`). Emitters stamp via
38
+ * `new Date().toISOString()`. Phase 17.3.
39
+ */
40
+ ts: z.string().datetime({ offset: true }),
41
+ });
42
+ //# sourceMappingURL=anomaly.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"anomaly.js","sourceRoot":"","sources":["../src/anomaly.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB;;;;;;;;GAQG;AACH,MAAM,CAAC,MAAM,YAAY,GAAG,CAAC,CAAC,IAAI,CAAC;IACjC,YAAY;IACZ,kBAAkB;IAClB,mBAAmB;IACnB,wBAAwB;IACxB,kBAAkB;IAClB,YAAY;IACZ,gBAAgB;IAChB,gBAAgB;IAChB,eAAe;IACf,kBAAkB;IAClB,kBAAkB;IAClB,yBAAyB;IACzB,yBAAyB;IACzB,yBAAyB;CAC1B,CAAC,CAAC;AAGH,MAAM,CAAC,MAAM,gBAAgB,GAAG,CAAC,CAAC,IAAI,CAAC,CAAC,MAAM,EAAE,MAAM,EAAE,OAAO,CAAC,CAAC,CAAC;AAGlE,MAAM,CAAC,MAAM,aAAa,GAAG,CAAC,CAAC,MAAM,CAAC;IACpC,IAAI,EAAE,YAAY;IAClB,QAAQ,EAAE,gBAAgB;IAC1B,2CAA2C;IAC3C,OAAO,EAAE,CAAC,CAAC,MAAM,EAAE;IACnB,uCAAuC;IACvC,OAAO,EAAE,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,OAAO,EAAE,CAAC;IAC9B;;;;OAIG;IACH,EAAE,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,EAAE,MAAM,EAAE,IAAI,EAAE,CAAC;CAC1C,CAAC,CAAC"}