trantor 0.18.148 → 0.18.152
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/.claude-plugin/marketplace.json +2 -2
- package/.claude-plugin/plugin.json +1 -1
- package/bin/advise.mjs +11 -8
- package/bin/cli.mjs +1 -1
- package/bin/connect.mjs +10 -1
- package/bin/crew/state.mjs +1 -1
- package/bin/crew-runner.mjs +9 -6
- package/bin/docker-seat.mjs +33 -0
- package/bin/heavy-gate-shim/docker +2 -0
- package/bin/integrate.mjs +38 -9
- package/bin/migrate-dispatcher.mjs +50 -0
- package/bin/turn-watchdog.mjs +15 -1
- package/deploy/restart-hub.sh +2 -0
- package/docs/FEATURES.md +4 -1
- package/hooks/sessionstart.mjs +6 -1
- package/hub/auth.mjs +8 -3
- package/hub/routes/cards.mjs +13 -1
- package/hub/routes/dispatcher-operations.mjs +134 -0
- package/hub/routes/dispatcher.mjs +18 -9
- package/hub/routes/git-policy.mjs +35 -0
- package/hub/startup-config.mjs +14 -0
- package/hub/store.mjs +49 -0
- package/hub.mjs +19 -2
- package/kimi.plugin.json +1 -1
- package/lib/canary/canary.mjs +2 -0
- package/lib/canary/probes.mjs +62 -0
- package/lib/dispatcher/admission.mjs +16 -3
- package/lib/dispatcher/board-bridge.mjs +82 -0
- package/lib/dispatcher/evidence-bridge.mjs +283 -0
- package/lib/dispatcher/operations.mjs +527 -0
- package/lib/dispatcher/planner.mjs +4 -2
- package/lib/dispatcher/preflight.mjs +44 -7
- package/lib/dispatcher/rollout.mjs +357 -0
- package/lib/dispatcher/schemas.mjs +1 -0
- package/lib/dispatcher/snapshot.mjs +76 -1
- package/lib/dispatcher/store.mjs +15 -0
- package/lib/dispatcher/verifier.mjs +246 -0
- package/lib/docker-janitor.mjs +24 -14
- package/lib/git-guard.mjs +181 -0
- package/lib/integrate.mjs +10 -2
- package/lib/store-contract.mjs +63 -0
- package/lib/store-pg.mjs +38 -3
- package/mcp.mjs +4 -5
- package/package.json +3 -3
|
@@ -0,0 +1,283 @@
|
|
|
1
|
+
import { bindAccounts } from './accounts.mjs';
|
|
2
|
+
import { heldLiability } from './spend.mjs';
|
|
3
|
+
import { DEFAULT_POLICY } from './policy.mjs';
|
|
4
|
+
import { loadCatalog, lookup } from '../model-catalog.mjs';
|
|
5
|
+
|
|
6
|
+
const text = (value, max = 8192) => String(value ?? '').slice(0, max);
|
|
7
|
+
const numberOrNull = value => value == null || value === '' || !Number.isFinite(Number(value)) ? null : Number(value);
|
|
8
|
+
const integerOrNull = value => {
|
|
9
|
+
const number = numberOrNull(value);
|
|
10
|
+
return number == null || number < 0 ? null : Math.round(number);
|
|
11
|
+
};
|
|
12
|
+
const timestamp = value => Number.isSafeInteger(value) && value >= 0 ? value : null;
|
|
13
|
+
const fresh = (observedAtMs, nowMs, ttlMs) => observedAtMs != null && observedAtMs <= nowMs && observedAtMs + ttlMs > nowMs;
|
|
14
|
+
const sourceName = value => text(value || 'unknown', 200);
|
|
15
|
+
|
|
16
|
+
function observation({ value = null, observedAtMs = null, receivedAtMs, source, status = 'unknown', reason = null, sourceRevision = null }) {
|
|
17
|
+
return { value, observedAtMs, receivedAtMs, source: sourceName(source), status,
|
|
18
|
+
reason: reason == null ? null : text(reason, 500), sourceRevision: sourceRevision == null ? null : text(sourceRevision, 200) };
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
function windowRecord({ accountId, id, kind, unit, value, observedAtMs, receivedAtMs, source, sourceRevision, resetsAtMs = null, reason = null }) {
|
|
22
|
+
const known = value != null;
|
|
23
|
+
return {
|
|
24
|
+
id: text(id), accountId, kind, unit, startsAtMs: null,
|
|
25
|
+
resetsAtMs: integerOrNull(resetsAtMs), capacity: unit === 'quotaMillionths' && known ? 1_000_000 : null,
|
|
26
|
+
remaining: observation({ value, observedAtMs, receivedAtMs, source, sourceRevision,
|
|
27
|
+
status: known ? 'ok' : 'unknown', reason }),
|
|
28
|
+
accountedThroughEvent: null, reserve: 0, heldLiability: heldLiability(0), dailyTimeZone: null,
|
|
29
|
+
};
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
function entryWindows({ accountId, entry, snapshot, nowMs }) {
|
|
33
|
+
const observedAtMs = timestamp(snapshot.ts);
|
|
34
|
+
const receivedAtMs = nowMs;
|
|
35
|
+
const source = `balances:${text(snapshot.machine || 'legacy', 60)}`;
|
|
36
|
+
const sourceRevision = text(snapshot.ts, 200);
|
|
37
|
+
const windows = [];
|
|
38
|
+
if (entry.kind === 'prepaid') {
|
|
39
|
+
const amount = numberOrNull(entry.remaining);
|
|
40
|
+
const supported = entry.currency === 'USD' && !entry.unlimited;
|
|
41
|
+
windows.push(windowRecord({ accountId, id: 'prepaid:USD', kind: 'prepaid', unit: 'usdMicros',
|
|
42
|
+
value: supported && amount != null && amount >= 0 ? Math.round(amount * 1_000_000) : null,
|
|
43
|
+
observedAtMs, receivedAtMs, source, sourceRevision,
|
|
44
|
+
reason: supported ? entry.error || null : 'only observed USD prepaid balances have a canonical microdollar unit' }));
|
|
45
|
+
}
|
|
46
|
+
if (entry.kind === 'quota') {
|
|
47
|
+
const percentage = numberOrNull(entry.remainingPct);
|
|
48
|
+
windows.push(windowRecord({ accountId, id: 'quota:default', kind: 'quota', unit: 'quotaMillionths',
|
|
49
|
+
value: percentage != null && percentage >= 0 && percentage <= 100 ? Math.round(percentage * 10_000) : null,
|
|
50
|
+
observedAtMs, receivedAtMs, source, sourceRevision, resetsAtMs: entry.resetTime,
|
|
51
|
+
reason: entry.error || entry.detail || null }));
|
|
52
|
+
}
|
|
53
|
+
if (entry.kind === 'windows') {
|
|
54
|
+
for (const row of Array.isArray(entry.windows) ? entry.windows : []) {
|
|
55
|
+
const name = text(row?.name, 200);
|
|
56
|
+
if (!name) continue;
|
|
57
|
+
const used = numberOrNull(row.usedPct);
|
|
58
|
+
windows.push(windowRecord({ accountId, id: `quota:${name}`, kind: 'quota', unit: 'quotaMillionths',
|
|
59
|
+
value: used != null && used >= 0 && used <= 100 ? Math.round((100 - used) * 10_000) : null,
|
|
60
|
+
observedAtMs, receivedAtMs, source, sourceRevision, resetsAtMs: row.resetsAt,
|
|
61
|
+
reason: row.locked ? text(row.locked, 500) : null }));
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
return windows;
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
function balanceEvidence({ snapshots, orgId, nowMs, policy }) {
|
|
68
|
+
const freshRows = [];
|
|
69
|
+
for (const snapshot of Array.isArray(snapshots) ? snapshots : []) {
|
|
70
|
+
const observedAtMs = timestamp(snapshot?.ts);
|
|
71
|
+
if (!fresh(observedAtMs, nowMs, policy.balanceTtlMs)) continue;
|
|
72
|
+
for (const entry of Array.isArray(snapshot.entries) ? snapshot.entries : []) {
|
|
73
|
+
const provider = text(entry?.provider, 200);
|
|
74
|
+
if (!provider) continue;
|
|
75
|
+
freshRows.push({ snapshot, entry, provider, observedAtMs });
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
const bindings = freshRows.map(({ snapshot, entry, provider, observedAtMs }) => ({
|
|
79
|
+
provider, machine: text(snapshot.machine || 'legacy', 60), subject: entry.subject ?? entry.billingSubject ?? null,
|
|
80
|
+
bindingRevision: text(observedAtMs, 200),
|
|
81
|
+
}));
|
|
82
|
+
const bound = bindAccounts({ org: orgId, bindings });
|
|
83
|
+
const evidence = [];
|
|
84
|
+
for (const account of [...bound.accounts, ...bound.unmapped]) {
|
|
85
|
+
const matching = freshRows.filter(({ entry, provider }) => provider === account.provider
|
|
86
|
+
&& (account.status !== 'verified' || (entry.subject ?? entry.billingSubject) === account.subject));
|
|
87
|
+
const observedAtMs = Math.max(...matching.map(row => row.observedAtMs));
|
|
88
|
+
const windows = account.status === 'verified' ? matching.flatMap(({ entry, snapshot }) =>
|
|
89
|
+
entryWindows({ accountId: account.id, entry, snapshot, nowMs })) : [];
|
|
90
|
+
windows.sort((a, b) => a.id.localeCompare(b.id));
|
|
91
|
+
const record = { id: account.id, provider: account.provider, bindingRevision: account.bindingRevision,
|
|
92
|
+
status: account.status, orchestratorCount: 0, windows };
|
|
93
|
+
evidence.push({ kind: 'account', id: account.id, source: 'balances',
|
|
94
|
+
sourceRef: `balances:${account.provider}:${observedAtMs}`, observedAtMs,
|
|
95
|
+
expiresAtMs: observedAtMs + policy.balanceTtlMs, record });
|
|
96
|
+
for (const window of windows) {
|
|
97
|
+
evidence.push({ kind: 'ledger', id: `${account.id}:${window.id}`, source: 'balances',
|
|
98
|
+
sourceRef: `balances:${account.id}:${window.id}:${observedAtMs}`, observedAtMs,
|
|
99
|
+
expiresAtMs: observedAtMs + policy.balanceTtlMs,
|
|
100
|
+
record: { accountId: account.id, windowId: window.id, unit: window.unit,
|
|
101
|
+
availableBeforeReserve: null, externalHold: 0, reflection: [], evidenceId: account.id } });
|
|
102
|
+
}
|
|
103
|
+
}
|
|
104
|
+
return evidence;
|
|
105
|
+
}
|
|
106
|
+
|
|
107
|
+
function presenceMachines({ rows, seats }) {
|
|
108
|
+
const display = new Map();
|
|
109
|
+
const learn = value => {
|
|
110
|
+
const name = text(value, 60).trim();
|
|
111
|
+
if (!name) return;
|
|
112
|
+
const key = name.toLowerCase();
|
|
113
|
+
const current = display.get(key);
|
|
114
|
+
if (current == null || (current === current.toLowerCase() && name !== name.toLowerCase())) display.set(key, name);
|
|
115
|
+
};
|
|
116
|
+
for (const row of Array.isArray(rows) ? rows : []) learn(row?.machine);
|
|
117
|
+
for (const seat of Array.isArray(seats) ? seats : []) learn(seat?.machine);
|
|
118
|
+
for (const seat of Array.isArray(seats) ? seats : []) {
|
|
119
|
+
if (text(seat?.machine, 60).trim()) continue;
|
|
120
|
+
const session = text(seat?.session, 200);
|
|
121
|
+
const host = session.includes(':') ? session.slice(0, session.indexOf(':')) : '';
|
|
122
|
+
if (display.has(host.toLowerCase())) learn(host);
|
|
123
|
+
}
|
|
124
|
+
return (Array.isArray(seats) ? seats : []).map(seat => {
|
|
125
|
+
const label = text(seat?.machine, 60).trim();
|
|
126
|
+
if (label) return { ...seat, machine: display.get(label.toLowerCase()) || label };
|
|
127
|
+
const session = text(seat?.session, 200);
|
|
128
|
+
const host = session.includes(':') ? session.slice(0, session.indexOf(':')) : '';
|
|
129
|
+
const machine = display.get(host.toLowerCase()) || '';
|
|
130
|
+
return machine ? { ...seat, machine } : seat;
|
|
131
|
+
});
|
|
132
|
+
}
|
|
133
|
+
|
|
134
|
+
function activeSeats(seats, id) {
|
|
135
|
+
return seats.filter(seat => seat?.online && text(seat.machine, 60).toLowerCase() === id.toLowerCase()).length;
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
function machineEvidence({ rows, seats, nowMs, policy }) {
|
|
139
|
+
const evidence = [];
|
|
140
|
+
const emitted = new Set();
|
|
141
|
+
for (const row of Array.isArray(rows) ? rows : []) {
|
|
142
|
+
const id = text(row?.machine, 60);
|
|
143
|
+
const observedAtMs = timestamp(row?.ts);
|
|
144
|
+
if (!id || !fresh(observedAtMs, nowMs, policy.machineTtlMs)) continue;
|
|
145
|
+
const key = id.toLowerCase();
|
|
146
|
+
if (emitted.has(key)) continue;
|
|
147
|
+
emitted.add(key);
|
|
148
|
+
const seatCount = activeSeats(seats, id);
|
|
149
|
+
const cpu = numberOrNull(row.cpuPct);
|
|
150
|
+
const health = {
|
|
151
|
+
cores: integerOrNull(row.cores), cpuPct: cpu != null && cpu >= 0 && cpu <= 100 ? Math.round(cpu) : null,
|
|
152
|
+
memUsed: integerOrNull(row.memUsed), memTotal: integerOrNull(row.memTotal),
|
|
153
|
+
memPressurePct: integerOrNull(row.memPressurePct), swapUsed: integerOrNull(row.swapUsed),
|
|
154
|
+
swapTotal: integerOrNull(row.swapTotal), diskFree: integerOrNull(row.diskFree),
|
|
155
|
+
diskTotal: integerOrNull(row.diskTotal), seatsRunning: seatCount,
|
|
156
|
+
};
|
|
157
|
+
evidence.push({ kind: 'machine', id, source: 'machine-beats', sourceRef: `machine-beats:${id}:${observedAtMs}`,
|
|
158
|
+
observedAtMs, expiresAtMs: observedAtMs + policy.machineTtlMs,
|
|
159
|
+
record: { id, health: observation({ value: health, observedAtMs, receivedAtMs: nowMs,
|
|
160
|
+
source: 'machine-beats', status: 'ok', sourceRevision: observedAtMs }),
|
|
161
|
+
tools: [], credentialBindings: [], maxSeats: 0, activeSeats: seatCount, adapterVersions: [] } });
|
|
162
|
+
}
|
|
163
|
+
for (const seat of seats) {
|
|
164
|
+
const id = text(seat?.machine, 60);
|
|
165
|
+
const observedAtMs = timestamp(seat?.lastSeen);
|
|
166
|
+
const key = id.toLowerCase();
|
|
167
|
+
if (!id || emitted.has(key) || !fresh(observedAtMs, nowMs, policy.machineTtlMs)) continue;
|
|
168
|
+
emitted.add(key);
|
|
169
|
+
const seatCount = activeSeats(seats, id);
|
|
170
|
+
evidence.push({ kind: 'machine', id, source: 'machine-beats', sourceRef: `presence:${id}:${observedAtMs}`,
|
|
171
|
+
observedAtMs, expiresAtMs: observedAtMs + policy.machineTtlMs,
|
|
172
|
+
record: { id, health: observation({ value: null, observedAtMs, receivedAtMs: nowMs,
|
|
173
|
+
source: 'presence', status: 'unknown', reason: 'no fresh machine health beat', sourceRevision: observedAtMs }),
|
|
174
|
+
tools: [], credentialBindings: [], maxSeats: 0, activeSeats: seatCount, adapterVersions: [] } });
|
|
175
|
+
}
|
|
176
|
+
return evidence;
|
|
177
|
+
}
|
|
178
|
+
|
|
179
|
+
function seatEvidence({ rows, nowMs, policy }) {
|
|
180
|
+
const evidence = [];
|
|
181
|
+
for (const row of Array.isArray(rows) ? rows : []) {
|
|
182
|
+
const id = text(row?.session, 200);
|
|
183
|
+
const machine = text(row?.machine, 60);
|
|
184
|
+
const harness = text(row?.llm, 200);
|
|
185
|
+
const observedAtMs = timestamp(row?.lastSeen);
|
|
186
|
+
if (!id || !machine || !harness || !fresh(observedAtMs, nowMs, policy.machineTtlMs)) continue;
|
|
187
|
+
const lastTurnMs = timestamp(row?.lastTurn?.ts);
|
|
188
|
+
evidence.push({ kind: 'seat', id, source: 'presence', sourceRef: `presence:${id}:${observedAtMs}`,
|
|
189
|
+
observedAtMs, expiresAtMs: observedAtMs + policy.machineTtlMs,
|
|
190
|
+
record: { id, machine, accountId: null, harness, model: text(row.model, 512) || null,
|
|
191
|
+
busy: row.online === true && /^(working|busy)$/i.test(text(row.status, 100)),
|
|
192
|
+
lastBeatMs: observedAtMs, lastTurnMs } });
|
|
193
|
+
}
|
|
194
|
+
return evidence;
|
|
195
|
+
}
|
|
196
|
+
|
|
197
|
+
function modelEnvelope({ provider, model, observedAtMs, expiresAtMs, nowMs, catalog }) {
|
|
198
|
+
const details = model ? lookup(model, catalog) : null;
|
|
199
|
+
const source = `discovery:${provider}`;
|
|
200
|
+
const unknown = (field, value = null) => observation({ value, observedAtMs: null, receivedAtMs: nowMs,
|
|
201
|
+
source, status: 'unknown', reason: `no fresh ${field} observation` });
|
|
202
|
+
return { kind: 'model', id: `model:${provider}:${model || 'unknown'}`, source: 'discovery-catalog',
|
|
203
|
+
sourceRef: `discovery:${provider}:${model || 'unknown'}:${observedAtMs}`, observedAtMs, expiresAtMs,
|
|
204
|
+
record: { provider, model, accountId: null, catalog: unknown('catalog'),
|
|
205
|
+
entitlement: unknown('entitlement'), invocation: unknown('invocation'), liveUse: null,
|
|
206
|
+
capabilities: details?.found && Array.isArray(details.modalities) ? details.modalities.map(value => text(value, 100)) : [],
|
|
207
|
+
efforts: details?.found && details.effort ? Object.keys(details.effort).sort() : [], breakerId: null } };
|
|
208
|
+
}
|
|
209
|
+
|
|
210
|
+
function modelEvidence({ rows, seats, nowMs, policy, catalog }) {
|
|
211
|
+
const models = new Map();
|
|
212
|
+
for (const row of Array.isArray(rows) ? rows : []) {
|
|
213
|
+
const provider = text(row?.provider, 200);
|
|
214
|
+
if (!provider) continue;
|
|
215
|
+
for (const item of Array.isArray(row.models) ? row.models : []) {
|
|
216
|
+
const observedAtMs = timestamp(Date.parse(item?.checkedAt));
|
|
217
|
+
const model = item?.id == null ? null : text(item.id, 512) || null;
|
|
218
|
+
if (!fresh(observedAtMs, nowMs, policy.discoveryTtlMs)) continue;
|
|
219
|
+
const key = `${provider}\0${model || ''}`;
|
|
220
|
+
const envelope = modelEnvelope({ provider, model, observedAtMs,
|
|
221
|
+
expiresAtMs: observedAtMs + policy.discoveryTtlMs, nowMs, catalog });
|
|
222
|
+
const known = ['listed', 'entitled', 'callable'].includes(item.state);
|
|
223
|
+
envelope.record.catalog = observation({ value: known ? true : null, observedAtMs, receivedAtMs: nowMs,
|
|
224
|
+
source: item.source, status: known ? 'ok' : 'unknown', reason: item.reason, sourceRevision: item.checkedAt });
|
|
225
|
+
if (['entitled', 'callable'].includes(item.state)) {
|
|
226
|
+
envelope.record.entitlement = observation({ value: true, observedAtMs, receivedAtMs: nowMs,
|
|
227
|
+
source: item.source, status: 'ok', reason: item.reason, sourceRevision: item.checkedAt });
|
|
228
|
+
}
|
|
229
|
+
models.set(key, envelope);
|
|
230
|
+
}
|
|
231
|
+
}
|
|
232
|
+
for (const seat of Array.isArray(seats) ? seats : []) {
|
|
233
|
+
const model = text(seat?.lastTurn?.model, 512);
|
|
234
|
+
const seatId = text(seat?.session, 200);
|
|
235
|
+
const harness = text(seat?.llm, 200);
|
|
236
|
+
const observedAtMs = timestamp(seat?.lastTurn?.ts);
|
|
237
|
+
if (!model || !seatId || !harness || !fresh(observedAtMs, nowMs, policy.invocationTtlMs)) continue;
|
|
238
|
+
const provider = model.includes('/') ? text(model.split('/')[0], 200) : harness;
|
|
239
|
+
const key = `${provider}\0${model}`;
|
|
240
|
+
const envelope = models.get(key) || modelEnvelope({ provider, model, observedAtMs,
|
|
241
|
+
expiresAtMs: observedAtMs + policy.invocationTtlMs, nowMs, catalog });
|
|
242
|
+
envelope.record.invocation = observation({ value: { model, seatId, harness }, observedAtMs,
|
|
243
|
+
receivedAtMs: nowMs, source: 'presence:last-turn', status: 'ok', sourceRevision: observedAtMs });
|
|
244
|
+
envelope.observedAtMs = Math.max(envelope.observedAtMs, observedAtMs);
|
|
245
|
+
envelope.expiresAtMs = Math.max(envelope.expiresAtMs, observedAtMs + policy.invocationTtlMs);
|
|
246
|
+
envelope.sourceRef = `presence:${seatId}:${observedAtMs}`;
|
|
247
|
+
models.set(key, envelope);
|
|
248
|
+
}
|
|
249
|
+
return [...models.values()];
|
|
250
|
+
}
|
|
251
|
+
|
|
252
|
+
export function buildEvidence({ balances = [], machines = [], seats = [], discovery = [], orgId, nowMs,
|
|
253
|
+
policy = DEFAULT_POLICY, catalog = loadCatalog() }) {
|
|
254
|
+
const presentSeats = presenceMachines({ rows: machines, seats });
|
|
255
|
+
return [
|
|
256
|
+
...balanceEvidence({ snapshots: balances, orgId, nowMs, policy }),
|
|
257
|
+
...machineEvidence({ rows: machines, seats: presentSeats, nowMs, policy }),
|
|
258
|
+
...seatEvidence({ rows: presentSeats, nowMs, policy }),
|
|
259
|
+
...modelEvidence({ rows: discovery, seats: presentSeats, nowMs, policy, catalog }),
|
|
260
|
+
];
|
|
261
|
+
}
|
|
262
|
+
|
|
263
|
+
export function createEvidenceBridge({ service, orgId, grant: grantId, sources,
|
|
264
|
+
clock = Date.now, policy = DEFAULT_POLICY, catalog = loadCatalog() }) {
|
|
265
|
+
if (!service || !orgId || !grantId || !sources) {
|
|
266
|
+
throw new TypeError('evidence bridge requires service, orgId, grant and sources');
|
|
267
|
+
}
|
|
268
|
+
async function tick() {
|
|
269
|
+
const nowMs = clock();
|
|
270
|
+
const [balances, machines, seats, discovery] = await Promise.all([
|
|
271
|
+
sources.balances(), sources.machines(), sources.seats(), sources.discovery(),
|
|
272
|
+
]);
|
|
273
|
+
const pending = buildEvidence({ balances, machines, seats, discovery, orgId, nowMs, policy, catalog })
|
|
274
|
+
.filter(envelope => envelope.expiresAtMs > clock());
|
|
275
|
+
let written = 0;
|
|
276
|
+
for (const envelope of pending) {
|
|
277
|
+
const result = await service.registerEvidence(orgId, envelope, { grant: grantId });
|
|
278
|
+
if (!result.replayed) written++;
|
|
279
|
+
}
|
|
280
|
+
return { observed: pending.length, written, skipped: pending.length - written };
|
|
281
|
+
}
|
|
282
|
+
return { tick, build: input => buildEvidence({ ...input, orgId, nowMs: clock(), policy, catalog }) };
|
|
283
|
+
}
|