@eir-labs/coltrane 0.6.2 → 0.7.3

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 (106) hide show
  1. package/README.md +23 -0
  2. package/agents/bill.json +59 -0
  3. package/agents/deploy-agent.json +68 -0
  4. package/agents/deploy-scout.json +40 -0
  5. package/agents/john.json +42 -0
  6. package/agents/lineage-scout-external.json +25 -0
  7. package/agents/lineage-scout-internal.json +32 -0
  8. package/agents/lineage-scribe.json +21 -0
  9. package/agents/lineage-weaver.json +23 -0
  10. package/agents/miles.json +44 -0
  11. package/charts/software-delivery-v1.json +9 -0
  12. package/charts/software-delivery-v2.json +39 -0
  13. package/dist/src/canonical_form.d.ts +23 -0
  14. package/dist/src/canonical_form.js +53 -0
  15. package/dist/src/canonical_form.js.map +1 -1
  16. package/dist/src/chart.d.ts +254 -0
  17. package/dist/src/chart.js +897 -0
  18. package/dist/src/chart.js.map +1 -0
  19. package/dist/src/cli.d.ts +19 -4
  20. package/dist/src/cli.js +132 -9
  21. package/dist/src/cli.js.map +1 -1
  22. package/dist/src/composition.d.ts +24 -0
  23. package/dist/src/composition.js +50 -5
  24. package/dist/src/composition.js.map +1 -1
  25. package/dist/src/genome_schema.d.ts +1203 -166
  26. package/dist/src/genome_schema.js +344 -34
  27. package/dist/src/genome_schema.js.map +1 -1
  28. package/dist/src/genome_store.d.ts +53 -3
  29. package/dist/src/genome_store.js +316 -139
  30. package/dist/src/genome_store.js.map +1 -1
  31. package/dist/src/gig_tracker.d.ts +11 -1
  32. package/dist/src/gig_tracker.js +5 -0
  33. package/dist/src/gig_tracker.js.map +1 -1
  34. package/dist/src/index.d.ts +1 -0
  35. package/dist/src/index.js +1 -0
  36. package/dist/src/index.js.map +1 -1
  37. package/dist/src/ledger.d.ts +22 -0
  38. package/dist/src/ledger.js +4 -0
  39. package/dist/src/ledger.js.map +1 -1
  40. package/dist/src/loader.d.ts +9 -1
  41. package/dist/src/loader.js +105 -5
  42. package/dist/src/loader.js.map +1 -1
  43. package/dist/src/mcp.js +54 -4
  44. package/dist/src/mcp.js.map +1 -1
  45. package/dist/src/output_mirror.d.ts +1 -1
  46. package/dist/src/outputs.d.ts +75 -1
  47. package/dist/src/outputs.js +142 -28
  48. package/dist/src/outputs.js.map +1 -1
  49. package/dist/src/reuse.d.ts +71 -0
  50. package/dist/src/reuse.js +0 -0
  51. package/dist/src/reuse.js.map +1 -1
  52. package/dist/src/runtime.d.ts +91 -2
  53. package/dist/src/runtime.js +236 -18
  54. package/dist/src/runtime.js.map +1 -1
  55. package/dist/src/server.d.ts +16 -0
  56. package/dist/src/server.js +600 -64
  57. package/dist/src/server.js.map +1 -1
  58. package/dist/src/version.d.ts +1 -1
  59. package/dist/src/version.js +1 -1
  60. package/dist/src/worker.d.ts +228 -0
  61. package/dist/src/worker.js +737 -0
  62. package/dist/src/worker.js.map +1 -0
  63. package/domain_types/alignment-plan.json +16 -0
  64. package/domain_types/branch-state.json +21 -0
  65. package/domain_types/change-context.json +39 -0
  66. package/domain_types/change-decision.json +36 -0
  67. package/domain_types/change-plan.json +47 -0
  68. package/domain_types/change-request.json +24 -0
  69. package/domain_types/change-set.json +46 -0
  70. package/domain_types/change-verdict.json +26 -0
  71. package/domain_types/deploy-verdict.json +23 -0
  72. package/domain_types/design-brief.json +37 -0
  73. package/domain_types/design-concept.json +36 -0
  74. package/domain_types/design-definition.json +37 -0
  75. package/domain_types/design-question.json +23 -0
  76. package/domain_types/design-verdict.json +27 -0
  77. package/domain_types/internal-inventory.json +26 -0
  78. package/domain_types/lineage-hit.json +19 -0
  79. package/domain_types/lineage-map.json +32 -0
  80. package/domain_types/lineage-question.json +17 -0
  81. package/domain_types/lineage-record.json +19 -0
  82. package/domain_types/lineage-verdict.json +16 -0
  83. package/domain_types/preview-deployment.json +32 -0
  84. package/institutions/quartet.json +344 -0
  85. package/package.json +4 -1
  86. package/skills/vercel-api/fixtures/error.json +10 -0
  87. package/skills/vercel-api/fixtures/ready.json +10 -0
  88. package/skills/vercel-api/fixtures/unsettled.json +10 -0
  89. package/skills/vercel-api/meta.json +10 -0
  90. package/skills/vercel-api/skill.mjs +63 -0
  91. package/standards/lineage-pass-v1.json +96 -0
  92. package/standards/preview-deploy-v1.json +89 -0
  93. package/standards/product-design-v1.json +122 -0
  94. package/standards/promote-v1.json +41 -0
  95. package/standards/software-change-v1.json +147 -0
  96. package/venues/ci-deploy-room-v1.json +28 -0
  97. package/venues/empty-room-v1.json +19 -0
  98. package/dist/src/conduct_daemon.d.ts +0 -59
  99. package/dist/src/conduct_daemon.js +0 -178
  100. package/dist/src/conduct_daemon.js.map +0 -1
  101. package/dist/src/play_worker.d.ts +0 -24
  102. package/dist/src/play_worker.js +0 -49
  103. package/dist/src/play_worker.js.map +0 -1
  104. package/dist/src/supabase_genome.d.ts +0 -28
  105. package/dist/src/supabase_genome.js +0 -49
  106. package/dist/src/supabase_genome.js.map +0 -1
@@ -21,6 +21,67 @@ export const BrowserGrantSchema = z.object({
21
21
  isolated: z.boolean().optional(),
22
22
  headless: z.boolean().optional(),
23
23
  });
24
+ // ── Skill — the package shape. Reconciles the two current shapes (SkillMeta typed + SkillRecord
25
+ // {slug;[k]:unknown} bag) into one. SHAPE-aligned only: determinism_ratio + fixtures are
26
+ // fields/artifacts the schema knows, but the OG rigid "fixtures pass ≥ threshold to PROMOTE"
27
+ // ceremony is deliberately NOT a schema invariant — promotion strictness is a separate, tunable
28
+ // policy. The fixture/determinism runner still enforces "fixtures pass + deterministic" in CI.
29
+ //
30
+ // Declared ABOVE the agent because an agent CARRIES skills (AgentSchema.skills below): the
31
+ // package shape has to exist before the record that embeds it. ──
32
+ export const NetworkGrantSchema = z.object({
33
+ allow: z.array(z.string()).default([]),
34
+ methods: z.array(z.string()).optional(),
35
+ max_requests: z.number().optional(),
36
+ max_bytes: z.number().optional(),
37
+ });
38
+ export const SkillPermissionSchema = z.object({
39
+ tier: z.number().optional(),
40
+ network: NetworkGrantSchema.optional(),
41
+ });
42
+ /**
43
+ * A HYDRATION SLOT — a named hole in a skill's method that something outside the agent fills.
44
+ *
45
+ * The seam this draws is the whole point of a carried skill: the METHOD is the agent's (portable,
46
+ * it travels into any institution that seats the player), while the DATA the method operates on is
47
+ * the institution's. A skill that hard-codes one house's constraints is not portable; a skill that
48
+ * declares the slot and receives the constraints is.
49
+ *
50
+ * `binding` says WHEN the slot is filled, and the two times are not interchangeable:
51
+ * - "institution" (the default when omitted) — filled at SEAT time from the chair's `supplies`.
52
+ * Known before any run exists, so a `required` slot nothing supplies is a DEAD SLOT and
53
+ * composition refuses it, exactly as an unresolvable tool grant is refused.
54
+ * - "gig" — filled at DISPATCH time from the gig payload. These are the chair contract's formal
55
+ * parameters and the dispatch input is the argument list, so compose time cannot demand them:
56
+ * it knows nothing about the arguments of a run that has not been asked for yet. Their floor
57
+ * belongs to the runtime pre-flight at t=0.
58
+ */
59
+ export const HydrationSlotSchema = z.object({
60
+ type: z.string(),
61
+ description: z.string().optional(),
62
+ required: z.boolean().optional(),
63
+ binding: z.enum(["institution", "gig"]).optional(),
64
+ });
65
+ export const SkillSchema = z.object({
66
+ slug: z.string(),
67
+ version: z.number().optional(),
68
+ skill_type: z.string().optional(),
69
+ input_type: z.string().optional(),
70
+ output_type: z.string().optional(),
71
+ corpus: z.string().optional(),
72
+ determinism_ratio: z.number().optional(),
73
+ permission: SkillPermissionSchema.optional(),
74
+ description: z.string().optional(),
75
+ timeout_ms: z.number().optional(),
76
+ /** Slot name → the declared shape of what fills it. See HydrationSlotSchema: the method is the
77
+ * agent's, the slot data is the institution's (or the gig's). */
78
+ hydration: z.record(HydrationSlotSchema).optional(),
79
+ // a package declares fixtures (test suite + determinism meter) + its code. Present so skill_define
80
+ // is package-aware (meta + fixtures + code), not the retired flat {slug, domain, md}.
81
+ fixtures: z.array(z.unknown()).optional(),
82
+ code: z.string().optional(),
83
+ md: z.string().optional(),
84
+ });
24
85
  // ── Agent — the template class, migrated end-to-end. z.input = AgentDef (what you author,
25
86
  // optionals allowed); z.output = Agent (defaults applied). One definition, both types. ──
26
87
  export const AgentSchema = z.object({
@@ -37,7 +98,22 @@ export const AgentSchema = z.object({
37
98
  // the ~50 call-sites that build Agent objects don't all break. defineAgent applies the [] default.
38
99
  allowed_tools: z.array(z.string()).readonly().optional(),
39
100
  disallowed_tools: z.array(z.string()).readonly().optional(),
101
+ /** REFERENCES into the shared repertoire (`skills/<slug>/`): the off-the-shelf method, bound by
102
+ * name, resolved against the genome's skills map at run time. A slug that resolves to no
103
+ * package is a dangling binding (loader) and a dead name when a chair requires it (runtime). */
40
104
  skill_slugs: z.array(z.string()).readonly().optional(),
105
+ /** The agent's OWN skills, carried on its record rather than referenced by name.
106
+ *
107
+ * An agent is the thing closest to its own work, so it is the agent that grows technique — and
108
+ * grown technique has to be portable: the same player seated in a second institution brings its
109
+ * method along instead of waiting for that institution's repertoire to contain it. Institution
110
+ * data never rides along; a carried skill declares `hydration` slots and the seating fills them.
111
+ *
112
+ * Relationship to `skill_slugs`: slugs name the SHARED repertoire, `skills` are the agent's own.
113
+ * Resolution unions the two, carried-first, so a carried definition SHADOWS a same-slug
114
+ * repertoire package (the player's own technique is the one that plays) and a slug covered by a
115
+ * carried definition is not a dangling binding. */
116
+ skills: z.array(SkillSchema).readonly().optional(),
41
117
  model_tier: ModelTierSchema.optional(),
42
118
  max_tool_calls: z.number().optional(),
43
119
  max_token_budget: z.number().optional(),
@@ -51,13 +127,29 @@ export const ChairSchema = z.object({
51
127
  role: z.string(),
52
128
  agent_slug: z.string().optional(),
53
129
  skill_slug: z.string().optional(),
130
+ /** The human seat: the chair is an approval office held by a person. No agent, no skill —
131
+ * the incumbent's sealed verdict is the chair's output, and a gig that reaches this chair
132
+ * unapproved PARKS (awaiting_approval) rather than confabulating a yes. */
133
+ human: z.boolean().optional(),
54
134
  depends_on: z.array(z.string()).default([]),
55
135
  input_contract: z.array(z.string()).default([]),
56
136
  output_contract: z.array(z.string()).default([]),
57
137
  // #243 — which promised outputs may legitimately be absent. Deny-by-default: omitted
58
138
  // means every promised type is required. Subset of output_contract, checked at compose.
59
139
  optional_outputs: z.array(z.string()).default([]),
140
+ /** The FLOOR. A skill named here must be held by whoever is seated — bound by slug or carried on
141
+ * the record — or the seating is refused at compose and the chair fails closed at run. */
60
142
  required_skills: z.array(z.string()).default([]),
143
+ /** The PREFERENCE. Technique this chair would rather its incumbent hold, stated without refusing
144
+ * the ones who do not: the roster of available agents is a fact about the world, not a defect,
145
+ * and a preference that refused a seating would be a second floor under another name. Nothing
146
+ * checks it at compose time — deliberately, including its names, since a chair may legitimately
147
+ * prefer a technique no agent in the genome has grown yet. */
148
+ preferred_skills: z.array(z.string()).default([]),
149
+ /** The institution's side of a hydration contract, at the phase-chair level: slot name → the
150
+ * value that fills it. An institution-bound `required` slot on a skill the seated agent holds
151
+ * and nothing here (or on the institutional chair) fills is refused at compose. */
152
+ supplies: z.record(z.unknown()).optional(),
61
153
  });
62
154
  export const PhaseSchema = z.object({ name: z.string(), chairs: z.array(ChairSchema) });
63
155
  /** Lifecycle status, shared by domain types and standards (#203). */
@@ -87,38 +179,6 @@ export const StandardSchema = z.object({
87
179
  max_examine_rounds: z.number().optional(),
88
180
  description: z.string().optional(),
89
181
  });
90
- // ── Skill — the package shape. Reconciles the two current shapes (SkillMeta typed + SkillRecord
91
- // {slug;[k]:unknown} bag) into one. SHAPE-aligned only: determinism_ratio + fixtures are
92
- // fields/artifacts the schema knows, but the OG rigid "fixtures pass ≥ threshold to PROMOTE"
93
- // ceremony is deliberately NOT a schema invariant — promotion strictness is a separate, tunable
94
- // policy. The fixture/determinism runner still enforces "fixtures pass + deterministic" in CI. ──
95
- export const NetworkGrantSchema = z.object({
96
- allow: z.array(z.string()).default([]),
97
- methods: z.array(z.string()).optional(),
98
- max_requests: z.number().optional(),
99
- max_bytes: z.number().optional(),
100
- });
101
- export const SkillPermissionSchema = z.object({
102
- tier: z.number().optional(),
103
- network: NetworkGrantSchema.optional(),
104
- });
105
- export const SkillSchema = z.object({
106
- slug: z.string(),
107
- version: z.number().optional(),
108
- skill_type: z.string().optional(),
109
- input_type: z.string().optional(),
110
- output_type: z.string().optional(),
111
- corpus: z.string().optional(),
112
- determinism_ratio: z.number().optional(),
113
- permission: SkillPermissionSchema.optional(),
114
- description: z.string().optional(),
115
- timeout_ms: z.number().optional(),
116
- // a package declares fixtures (test suite + determinism meter) + its code. Present so skill_define
117
- // is package-aware (meta + fixtures + code), not the retired flat {slug, domain, md}.
118
- fixtures: z.array(z.unknown()).optional(),
119
- code: z.string().optional(),
120
- md: z.string().optional(),
121
- });
122
182
  // ── Eval — retire the {slug;[k]:unknown} bag; the loader validates eval files against this. ──
123
183
  export const EvalSchema = z.object({
124
184
  slug: z.string(),
@@ -158,6 +218,22 @@ export const DomainTypeSchema = z.object({
158
218
  // required_skills, caps, obligations); agents are the few named players who swap into them. ──
159
219
  /** The typed lineage-edge vocabulary. Caps grant these; lineage edges are made of them. */
160
220
  export const LineageEdgeTypeSchema = z.enum(["anchored-in", "produced-by", "evolved-from", "descends-from"]);
221
+ /** A reference from an institution to a published lineage-record that grounds it. The record
222
+ * itself is sealed content-addressed in the ledger; the institution carries the REFERENCE, so an
223
+ * APPROVED lineage (the lineage-pass standard's `approve` chair sealed a passing lineage-verdict)
224
+ * becomes first-class institutional grounding — see `institutionLineageGrounding` below. `record_ref`
225
+ * is the only non-optional field: a lineage reference that names no record references nothing.
226
+ * Store-side home is `coltrane_institution_lineage` (follow-up; not built here). */
227
+ export const LineageRecordRefSchema = z.object({
228
+ /** content_sha (or slug) of the sealed lineage-record this institution is grounded in. */
229
+ record_ref: z.string(),
230
+ /** the lineage-question the record answered, for display without dereferencing the record. */
231
+ question: z.string().optional(),
232
+ /** the human seal: filled from the approve chair's verdict when the lineage is adopted. Null
233
+ * until then — an institution never grounds itself on an unapproved lineage. */
234
+ approved_by: z.string().nullable().default(null),
235
+ sealed_at: z.string().optional(),
236
+ });
161
237
  // Slugs NAME identities; LOOKUPS go by id. The instance store assigns each institutional
162
238
  // identity a stable uuid; references and RLS key on the id, never the slug.
163
239
  export const InstitutionSchema = z.object({
@@ -168,6 +244,12 @@ export const InstitutionSchema = z.object({
168
244
  laws: z.array(z.string()).default([]),
169
245
  wiki_space: z.string().optional(),
170
246
  sovereign: z.boolean().default(false),
247
+ /** First-class lineage: references to approved lineage-records that ground this institution.
248
+ * Additive and defaulted, so an institution declared without it simply has no adopted lineage
249
+ * yet. A record lands here only after the lineage-pass `approve` chair seals it; every agent
250
+ * seated in the institution then inherits these as formal grounding (see the surfacing seam in
251
+ * `institutionLineageGrounding`). */
252
+ lineage: z.array(LineageRecordRefSchema).default([]),
171
253
  });
172
254
  export const OrganizationSchema = z.object({
173
255
  id: z.string().optional(),
@@ -196,29 +278,62 @@ export const AgentRecordSchema = z.object({
196
278
  export const OrgMemberSchema = z.object({ org_slug: z.string(), agent_slug: z.string() });
197
279
  export const OrgInstitutionSchema = z.object({ org_slug: z.string(), institution_slug: z.string() });
198
280
  /** A capability grant: a typed lineage-edge scope, optionally expiring. The grant IS the policy. */
199
- export const CapGrantSchema = z.object({
281
+ export const EdgeCapGrantSchema = z.object({
200
282
  edge_type: LineageEdgeTypeSchema,
201
283
  scope: z.record(z.unknown()),
202
284
  expires: z.string().nullable().default(null),
203
285
  });
286
+ /** The chair-contract dispatch grant — the office names which standards its incumbent may
287
+ * run. Authority sits on the chair; a credential presented by the incumbent may only
288
+ * narrow it, never widen it. (This is the shape the store's authorization function reads:
289
+ * a flat cap, not a scope smuggled inside a lineage edge.) */
290
+ export const DispatchCapGrantSchema = z.object({
291
+ grant: z.literal("dispatch"),
292
+ standards: z.array(z.string()).readonly(),
293
+ expires: z.string().nullable().default(null),
294
+ });
295
+ /** A chair cap is a lineage-edge grant or a dispatch grant. One union, one Zod source. */
296
+ export const CapGrantSchema = z.union([EdgeCapGrantSchema, DispatchCapGrantSchema]);
204
297
  /** The chair is the thing: the seat's configuration, not a person. */
205
298
  export const InstitutionalChairSchema = z.object({
206
299
  id: z.string().optional(),
207
300
  institution_slug: z.string(),
208
301
  role: z.string(),
302
+ /** The human office: this chair is held by a person, never a model agent. */
303
+ human: z.boolean().optional(),
209
304
  function: PrimitiveSchema,
210
305
  mission: z.string(),
306
+ /** The floor: skills the office requires of whoever holds it. */
211
307
  required_skills: z.array(z.string()).default([]),
308
+ /** The preference: technique the office would rather its incumbent hold, stated without refusing
309
+ * the agents who do not hold it. Same two-tier reading as the phase chair's. */
310
+ preferred_skills: z.array(z.string()).default([]),
311
+ /** The institution's data, delivered through the office: hydration slot name → the value that
312
+ * fills it. This is where institution-specific content belongs — NOT inside the carried skill,
313
+ * which is why the skill stays portable across institutions. */
314
+ supplies: z.record(z.unknown()).optional(),
212
315
  caps: z.array(CapGrantSchema).default([]),
213
316
  obligations: z.array(z.string()).default([]),
214
317
  });
215
- /** A seat: a named agent bound into a chair for an org, witnessed. */
318
+ /** What a seating cited: a source and the claim read from it. Both required a source with no
319
+ * claim cites nothing in particular, and a claim with no source is a recollection. */
320
+ export const TechniqueEvidenceSchema = z.object({
321
+ source: z.string(),
322
+ claim: z.string(),
323
+ });
324
+ /** A seat: a named agent bound into a chair for an org, witnessed.
325
+ *
326
+ * Seating is a JUDGEMENT — this player, this office — and `technique_evidence` makes it a recorded
327
+ * one: the ledger queries, improvement reports, prior gig fingerprints or deterministic suite
328
+ * results the decision weighed. Optional, because a seating may be made on no evidence at all;
329
+ * what is not optional is the difference between the two, which is exactly what the field records. */
216
330
  export const ChairAssignmentSchema = z.object({
217
331
  id: z.string().optional(),
218
332
  chair_id: z.string(),
219
333
  agent_slug: z.string(),
220
334
  org_slug: z.string(),
221
335
  contract_caps: z.array(CapGrantSchema).default([]),
336
+ technique_evidence: z.array(TechniqueEvidenceSchema).optional(),
222
337
  witnessed_by: z.string().nullable().default(null),
223
338
  });
224
339
  /** Cross-institution exposure happens only by contract across the wall. */
@@ -273,6 +388,201 @@ export const OrgServiceKeySchema = z
273
388
  status: z.enum(["active", "revoked"]).default("active"),
274
389
  })
275
390
  .strict();
391
+ /** The institution-lineage SURFACING SEAM. When a seat renders a player into a Claude Code
392
+ * subagent (`src/player_to_claude_code.ts`, the seat→prompt transform), the institution's approved
393
+ * lineage-records are read through here and folded into the agent's formal grounding — the same
394
+ * seam a future institutional-northstars / forebears surface would use. Today it returns the refs
395
+ * themselves (the institution definition carries them); the STORE-BACKED path (dereferencing each
396
+ * `record_ref` to its sealed lineage-record via `coltrane_institution_lineage`) is the follow-up
397
+ * the instance layer fills. Named here, additively, so the seam has one home rather than being
398
+ * reinvented at the render call site. */
399
+ export function institutionLineageGrounding(inst) {
400
+ return inst.lineage;
401
+ }
402
+ // ── Chart — the ARRANGEMENT: one gig as a performance of many standards ───────────────────────
403
+ //
404
+ // A standard is a phase graph over chairs. A CHART is the same idea one level up: a typed DAG
405
+ // over STANDARDS. Each MOVEMENT names a standard; each EDGE asserts that a type SEALED by the
406
+ // source movement seeds an entry chair of the sink movement (the entry-chair-seed rule, promoted);
407
+ // each APPROVAL GATE is a human seat at the arrangement level, keyed by `gate_id` so it cannot
408
+ // collide with a within-movement human chair that happens to share a role name; the BUDGET
409
+ // ENVELOPE bounds the whole performance rather than one movement of it.
410
+ //
411
+ // The single-standard gig is the DEGENERATE chart: one movement, no edges, no gates, whose
412
+ // `chart_hash` short-circuits byte-for-byte to `genomeHash` of that standard (src/chart.ts), so an
413
+ // existing run's `run_fingerprint` does not move. `venue` is deliberately opaque here — its
414
+ // infrastructure meaning belongs to the runtime layer, and speculating it into the schema would
415
+ // bind a decision this shape does not need.
416
+ //
417
+ // Nothing else in this file changes: every cross-reference below is a slug by `z.string()`, never
418
+ // a Zod ref, so a chart names standards and agents without the chart schema depending on theirs.
419
+ /** One typed edge: a type the source movement seals, consumed by the sink movement's entry chairs. */
420
+ export const ChartEdgeSchema = z
421
+ .object({
422
+ from_movement: z.string(),
423
+ to_movement: z.string(),
424
+ output_type: z.string(),
425
+ /** true = a CONDITIONAL edge: the type lives only in a terminal chair's `optional_outputs`,
426
+ * so the flow may legitimately carry nothing. Compose classifies it; it cannot prove the
427
+ * optional output will be produced, which is why a conditional edge never satisfies a
428
+ * REQUIRED entry slot (src/chart.ts R6/R7). */
429
+ optional: z.boolean().default(false),
430
+ })
431
+ .strict();
432
+ /** Who plays which chair for this movement — a recorded act, optionally with its evidence. */
433
+ export const ChartSeatingSchema = z
434
+ .object({
435
+ chair: z.string(),
436
+ agent_slug: z.string(),
437
+ technique_evidence: z.array(TechniqueEvidenceSchema).optional(),
438
+ })
439
+ .strict();
440
+ /** One movement: a standard, its gig-bound hydration arguments, and its seatings.
441
+ *
442
+ * `movement_id` — NOT `standard_slug` — is the identity everything keys on: the checkpoint
443
+ * namespace, the reuse-cache namespace, the edge endpoints. That is what lets one standard
444
+ * appear twice in a chart without the two instances sharing cached results. */
445
+ export const ChartMovementSchema = z
446
+ .object({
447
+ movement_id: z.string(),
448
+ standard_slug: z.string(),
449
+ runtime_fills: z.record(z.string(), z.unknown()).default({}),
450
+ seatings: z.array(ChartSeatingSchema).default([]),
451
+ })
452
+ .strict();
453
+ /** A human seat between movements. Parks on `deps.approvals[gate_id]`. */
454
+ export const ChartApprovalGateSchema = z
455
+ .object({
456
+ gate_id: z.string(),
457
+ after_movement: z.string(),
458
+ before_movement: z.string(),
459
+ chair: z.string(),
460
+ prompt: z.string().optional(),
461
+ })
462
+ .strict();
463
+ /** The ceiling for the whole performance, in real money. */
464
+ export const ChartBudgetEnvelopeSchema = z.object({ total_usd: z.number().positive() }).strict();
465
+ export const ChartSchema = z
466
+ .object({
467
+ slug: z.string(),
468
+ movements: z.array(ChartMovementSchema).min(1),
469
+ edges: z.array(ChartEdgeSchema).default([]),
470
+ approval_gates: z.array(ChartApprovalGateSchema).default([]),
471
+ budget_envelope: ChartBudgetEnvelopeSchema.optional(),
472
+ /** The VENUE this performance is held in, by slug — a `VenueSchema` in the genome (below).
473
+ *
474
+ * A slug, never an inline room: the venue is an institution-level object shared by whichever
475
+ * arrangement is fit for it, so it is named here and defined once there. A slug that resolves
476
+ * to no venue is a dead name and `composeChart` refuses the chart (R10), exactly as an
477
+ * unresolvable tool grant refuses a dispatch.
478
+ *
479
+ * Deliberately NOT folded into `chart_hash`: a room is environment, not structure. Two runs of
480
+ * the same arrangement in differently-configured rooms share an arrangement identity; what
481
+ * distinguishes them belongs to the run's own record, not the chart's. */
482
+ venue: z.string().optional(),
483
+ })
484
+ .strict();
485
+ // ── Venue — the institution's configured performance space ────────────────────────────────────
486
+ //
487
+ // A venue states what EXISTS to be acted with when a gig runs: which tools resolve, which doors
488
+ // open inward and outward, what is installed, and which classes of credential may legitimately be
489
+ // present. It is an institution-level object (one institution owns it; an institution may operate
490
+ // several) and it is a CEILING, never a grant: the authority a seated agent actually holds is its
491
+ // own `allowed_tools` INTERSECTED with `equipment.tools`, so a room can only ever narrow a player.
492
+ // `composeChart` enforces that where a chart names a venue (src/chart.ts R10).
493
+ //
494
+ // The contract is deliberately a narrow waist. Nothing here is a harness escape hatch — no image
495
+ // reference, no command string, no provisioning block — because a field that can express arbitrary
496
+ // harness behaviour destroys the separation between what is declared and what realizes it. What
497
+ // this shape covers is the STATICALLY CHECKABLE half of the design: the fields an engine can
498
+ // enforce before anything runs. Realization (building the room from the contract) and verification
499
+ // by behavioural probe are a lower layer and are not modelled here.
500
+ //
501
+ // Two asymmetries are load-bearing and stated in the shape rather than in prose:
502
+ // - `doors` separates ingress from egress, because what may reach the room and what may leave it
503
+ // are different questions with different threat models.
504
+ // - `installs` carries DIGESTS, not version ranges: an unpinned install names a family of rooms,
505
+ // which would make a room's identity meaningless.
506
+ /** The room's equipment: a deny-by-default allowlist of tool grants, in the same vocabulary as an
507
+ * agent's `allowed_tools`. A venue with no tools holds nothing — not "read-only tools", nothing. */
508
+ export const VenueEquipmentSchema = z
509
+ .object({
510
+ tools: z.array(z.string()).default([]),
511
+ })
512
+ .strict();
513
+ /** A host allowlist per direction. Deny-by-default: absent doors reach nothing and are reached by
514
+ * nothing. `*` is refused — a wildcard door is not a door, it is the absence of one. */
515
+ const HostSchema = z
516
+ .string()
517
+ .refine((h) => h.trim() !== "*", { message: `a door names hosts, never "*" — a wildcard door is not a door` });
518
+ export const VenueDoorsSchema = z
519
+ .object({
520
+ ingress: z.array(HostSchema).default([]),
521
+ egress: z.array(HostSchema).default([]),
522
+ })
523
+ .strict();
524
+ /** Lifecycle. Ephemeral is the default: the contract is the durable object and the realization is
525
+ * disposable, because everything a standing room accumulates — drift, residue from prior gigs,
526
+ * standing credentials, warm state — is exactly the class of thing no output's `input_shas` can
527
+ * cover. `standing` is permitted as a named exception and owes a rebuild cadence (venueDefect). */
528
+ export const VenueLifecycleSchema = z
529
+ .object({
530
+ policy: z.enum(["ephemeral", "standing"]).default("ephemeral"),
531
+ /** ISO-8601 duration or cron-shaped cadence — read by the responsible office, not the engine. */
532
+ rebuild_cadence: z.string().optional(),
533
+ })
534
+ .strict();
535
+ /** An install must carry the digest of what will actually be present. */
536
+ const InstallPinSchema = z.string().regex(/sha256:[0-9a-f]{64}/, "an install must be digest-pinned (…sha256:<64 hex>): a version range names a family of rooms, not one room, so an unpinned install makes the venue's identity meaningless");
537
+ export const VenueSchema = z
538
+ .object({
539
+ slug: z.string(),
540
+ /** Exactly one owning institution. The institution is the duty holder; the office below is the
541
+ * appointed accountable individual. */
542
+ institution_slug: z.string(),
543
+ /** Why this room is shaped the way it is — read at review, never at runtime. */
544
+ description: z.string().optional(),
545
+ /** The base kind of room (e.g. "ingest-empty", "code-work"). A label for humans and for
546
+ * "which room does this work want", not a resolvable reference. */
547
+ flavor: z.string().optional(),
548
+ /** Defaulted, not required, and the default is the EMPTY room. Every access-shaped field here
549
+ * leans the same way: absent doors reach nothing, absent installs install nothing, an absent
550
+ * credential surface permits nothing. A venue that forgot to state its equipment must hold
551
+ * nothing rather than hold whatever the reader assumed — and both doors into this class (the
552
+ * loader and venue_define) get that from the one schema rather than from two agreeing habits. */
553
+ equipment: VenueEquipmentSchema.default({}),
554
+ doors: VenueDoorsSchema.optional(),
555
+ /** Digest-pinned software the room contains. */
556
+ installs: z.array(InstallPinSchema).default([]),
557
+ /** Which CLASSES of credential may legitimately be present, by name. Never material, and never
558
+ * a field material could occupy: a room that declares nothing here is a room where finding a
559
+ * credential is a breach rather than a configuration difference. */
560
+ credential_surface: z.array(z.string()).default([]),
561
+ lifecycle: VenueLifecycleSchema.default({}),
562
+ /** The accountable office: an institutional chair id (the office, not its incumbent). One named
563
+ * duty-holder answers for the room and for what it permits. */
564
+ responsible_chair: z.string().optional(),
565
+ })
566
+ .strict();
567
+ /**
568
+ * Cross-field venue rules — the ones a single field cannot state.
569
+ *
570
+ * A separate function rather than a `.superRefine`, on purpose and by the existing idiom
571
+ * (`domainTypeDefect` in src/registry.ts): the MCP write-surface is generated from
572
+ * `zodToMcpProps(VenueSchema)`, which needs a plain `ZodObject` with a `.shape`, and a refined
573
+ * schema is a `ZodEffects` that has neither. So both doors — the loader and `venue_define` — call
574
+ * `VenueSchema.safeParse` and then this, and a rule enforced at one door is enforced at both.
575
+ *
576
+ * Returns the teaching message, or null when the venue is sound.
577
+ */
578
+ export function venueDefect(venue) {
579
+ if (venue.lifecycle.policy === "standing" && !venue.lifecycle.rebuild_cadence?.trim()) {
580
+ return (`venue "${venue.slug}" is standing with no lifecycle.rebuild_cadence — that is a snowflake, not a venue. ` +
581
+ `A standing room accumulates drift, residue from prior gigs and warm state that no output's input_shas can cover, ` +
582
+ `so a standing exception owes a rebuild cadence: a phoenix on a slower clock. State one, or make it ephemeral.`);
583
+ }
584
+ return null;
585
+ }
276
586
  function jsonTypeOf(schema) {
277
587
  let s = schema;
278
588
  // Unwrap the WRAPPER types (optional/default/nullable/readonly via `innerType`, effects via
@@ -1 +1 @@
1
- {"version":3,"file":"genome_schema.js","sourceRoot":"","sources":["../../src/genome_schema.ts"],"names":[],"mappings":"AAAA,gGAAgG;AAChG,gGAAgG;AAChG,oGAAoG;AACpG,kGAAkG;AAClG,iGAAiG;AACjG,kGAAkG;AAClG,uDAAuD;AACvD,OAAO,E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@@
1
1
  import { type LoadedGenome } from "./loader.js";
2
- /** The genome classes a store can persist. (Core types are engine-owned and immutable.) */
3
- export type GenomeClass = "agent" | "standard" | "skill" | "domain_type";
2
+ /** The genome classes a store can persist. (Core types are engine-owned and immutable.)
3
+ *
4
+ * `chart` and `venue` are here because the ENGINE now authors them — the file backing writes
5
+ * charts/<slug>.json and venues/<slug>.json, and the class rides through the PostgREST upsert
6
+ * unchanged. The STORE side is not yet built: `coltrane_genome_upsert` has no branch for either
7
+ * class and there are no chart/venue tables, so a hosted venue_define reaches the RPC and is
8
+ * refused BY THE STORE, loudly, with the store's own message. That refusal is the honest state —
9
+ * the class passes through the port it is supposed to pass through and the missing half says so
10
+ * itself, rather than the engine pretending the class does not exist. */
11
+ export type GenomeClass = "agent" | "standard" | "skill" | "domain_type" | "chart" | "venue";
4
12
  /** Where definitions live. load() yields the loader's genome shape; upsert() persists one
5
13
  * definition of a class. The file impl writes genome files; the PostgREST impl rides the
6
14
  * governed upsert RPC as the caller. */
7
15
  export interface GenomeStore {
8
16
  load(): Promise<LoadedGenome>;
9
- upsert(cls: GenomeClass, payload: Record<string, unknown>): Promise<void>;
17
+ /** org_slug is an OPTIONAL override — the store resolves the caller's working org
18
+ * (set once via org_use) when absent, so callers never track the org per call. */
19
+ upsert(cls: GenomeClass, payload: Record<string, unknown>, org_slug?: string): Promise<void>;
10
20
  }
11
21
  /** The store connection a hosted caller carries — same shape as HostedToolContext:
12
22
  * where the org store is, its public anon key, and WHO is calling (bearer). */
@@ -20,10 +30,50 @@ export interface PostgrestContext {
20
30
  * file via the versioned writer (prior bytes snapshotted, atomic replace). Ledger sealing
21
31
  * stays where it lives today — in the MCP tools (sealDefinition / sealAgentDefinition). */
22
32
  export declare function fileGenomeStore(root: string): GenomeStore;
33
+ type Row = Record<string, unknown>;
34
+ /** The row bundle both store backings feed the reconstruction: the five genome tables,
35
+ * however they were fetched (PostgREST GETs under a JWT, or the coltrane_mcp_genome RPC
36
+ * under an agent token). */
37
+ export interface GenomeRows {
38
+ core_types: Row[];
39
+ domain_types: Row[];
40
+ agents: Row[];
41
+ standards: Row[];
42
+ skills: Row[];
43
+ /** Rows of {slug, definition} — the definition jsonb IS the file shape, validated through
44
+ * the same gates the loader runs (ChartSchema+composeChart / VenueSchema+venueDefect). */
45
+ charts?: Row[];
46
+ venues?: Row[];
47
+ }
48
+ /** Reconstruct the loader's in-memory genome shape from store rows — ONE reconstruction,
49
+ * shared by every backing, so a JWT-loaded genome and a ctk-loaded genome cannot drift. */
50
+ export declare function reconstructGenome(rows: GenomeRows): LoadedGenome;
23
51
  /** Hosted backing: load the genome from the store's five tables and reconstruct the SAME
24
52
  * in-memory shape the file loader produces; upsert through the governed RPC. */
25
53
  export declare function postgrestGenomeStore(ctx: PostgrestContext): GenomeStore;
54
+ /** Agent-token backing: the org genome through coltrane_mcp_genome. PostgREST verifies only
55
+ * JWTs, so a ctk_ bearer cannot ride the REST tables — the definer RPC resolves the token's
56
+ * hash inside the store and returns the org's rows. Same reconstruction as every backing.
57
+ * Read-only by design: an agent token does not author genome (authoring is a member act,
58
+ * governed by the upsert RPC as auth.uid()). */
59
+ export declare function rpcGenomeStore(ctx: {
60
+ baseUrl: string;
61
+ anonKey: string;
62
+ agentToken: string;
63
+ }): GenomeStore;
64
+ /** Set the caller's working organization — the formal switch, recorded in the store as a
65
+ * member act. After this, every member write resolves the org without being told. */
66
+ export declare function postgrestOrgUse(ctx: PostgrestContext): (org_slug: string) => Promise<string>;
67
+ /** The agent-token gig-queue seam: queue one run through coltrane_mcp_dispatch, where the
68
+ * chair contract authorizes (the seat grants the standard; the token may only narrow).
69
+ * Same return shape as postgrestQueueGig so a host can swap them by bearer class. */
70
+ export declare function rpcQueueGig(ctx: {
71
+ baseUrl: string;
72
+ anonKey: string;
73
+ agentToken: string;
74
+ }): (args: Record<string, unknown>) => Promise<Record<string, unknown>>;
26
75
  /** The hosted gig-queue seam for createToolSurface: queue one run through the governor-gated
27
76
  * dispatch RPC AS THE CALLER (member JWT — RLS + the governor gate decide). Queuing only;
28
77
  * a drain worker claims and runs it. Shape mirrors hosted_tools' member dispatch path. */
29
78
  export declare function postgrestQueueGig(ctx: PostgrestContext): (args: Record<string, unknown>) => Promise<Record<string, unknown>>;
79
+ export {};