@tangle-network/agent-interface 5.10.22 → 5.10.24
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/README.md +20 -0
- package/dist/agent-candidate-code-schema.d.ts +1 -0
- package/dist/agent-candidate-execution-plan-schema.d.ts +8 -6
- package/dist/agent-candidate-profile-schema.d.ts +1 -0
- package/dist/agent-candidate-promotion-schema.d.ts +112 -20
- package/dist/agent-candidate-receipt-schema.d.ts +5 -4
- package/dist/agent-candidate-schema.d.ts +2 -0
- package/dist/agent-execution-preparation-receipt.d.ts +1 -0
- package/dist/agent-profile-improvement-schema.d.ts +469 -0
- package/dist/agent-profile-improvement-schema.js +116 -16
- package/dist/agent-profile-improvement.d.ts +34 -6
- package/dist/environment-interactive-control.d.ts +10 -0
- package/dist/environment-interactive-start.d.ts +2 -0
- package/dist/environment-runtime.d.ts +6 -0
- package/dist/harness.d.ts +1 -0
- package/dist/harness.js +1 -0
- package/dist/learning-state.d.ts +13 -0
- package/dist/portable-context-transfer.d.ts +2 -0
- package/dist/profile-schema.d.ts +3 -0
- package/package.json +1 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
|
-
import { changedAgentProfileAxes } from "./profile-diff.js";
|
|
2
|
+
import { applyAgentProfileDiff, changedAgentProfileAxes } from "./profile-diff.js";
|
|
3
3
|
import { agentCandidateLineageSchema, isGeneratedCandidateSource, } from "./agent-candidate-lineage-schema.js";
|
|
4
4
|
import { canonicalCandidateDigest, isCanonicalJsonValue, omitTopLevelDigest, sha256DigestSchema, } from "./agent-candidate-schema-common.js";
|
|
5
5
|
import { refineAgentExecutionWithinLimits } from "./agent-execution-limits.js";
|
|
@@ -8,7 +8,7 @@ import { agentCandidateBenchmarkDimensionSchema, agentCandidateFixedSpendSchema,
|
|
|
8
8
|
import { agentCandidateEvaluationPolicySchema, createMeasuredComparisonIdentityRegistry, measuredComparisonCommonShape, refineMeasuredComparisonSummary, } from "./agent-improvement-measurement-schema.js";
|
|
9
9
|
import { agentImprovementSourceSchema } from "./agent-improvement-source.js";
|
|
10
10
|
import { numbersApproximatelyEqual } from "./number-validation.js";
|
|
11
|
-
import { agentProfileDiffSchema } from "./profile-schema.js";
|
|
11
|
+
import { agentProfileDiffSchema, agentProfileModelHintsSchema } from "./profile-schema.js";
|
|
12
12
|
const profileImprovementScenarioSchema = z
|
|
13
13
|
.object({
|
|
14
14
|
id: z.string().min(1).max(500),
|
|
@@ -158,6 +158,54 @@ export const agentProfileImprovementChangeSchema = z
|
|
|
158
158
|
});
|
|
159
159
|
}
|
|
160
160
|
});
|
|
161
|
+
const profileModelBindingArmSchema = z.strictObject({
|
|
162
|
+
authored: agentProfileModelHintsSchema,
|
|
163
|
+
resolved: agentCandidateResolvedModelSchema,
|
|
164
|
+
});
|
|
165
|
+
export const agentProfileImprovementModelBindingSchema = z.discriminatedUnion("kind", [
|
|
166
|
+
z.strictObject({ kind: z.literal("fixed-task") }),
|
|
167
|
+
z.strictObject({
|
|
168
|
+
kind: z.literal("profile-default"),
|
|
169
|
+
baseline: profileModelBindingArmSchema,
|
|
170
|
+
candidate: profileModelBindingArmSchema,
|
|
171
|
+
}),
|
|
172
|
+
]);
|
|
173
|
+
/** One model-policy interpretation for schema, measurement and the source-owning executor.
|
|
174
|
+
* Pass the actual profile when sealing/executing to prove its authored default matches the binding.
|
|
175
|
+
* The host must independently observe the exact returned model and snapshot for each run. */
|
|
176
|
+
export function agentProfileImprovementExpectedModel(experiment, task, arm, profile) {
|
|
177
|
+
const policy = agentProfileImprovementModelBindingSchema.parse(experiment.modelBinding ?? { kind: "fixed-task" });
|
|
178
|
+
if (policy.kind === "fixed-task")
|
|
179
|
+
return agentCandidateResolvedModelSchema.parse(task.model);
|
|
180
|
+
for (const binding of [policy.baseline, policy.candidate]) {
|
|
181
|
+
const { authored, resolved } = binding;
|
|
182
|
+
const { default: requested, provider, reasoningEffort } = authored;
|
|
183
|
+
const concrete = (value) => value !== undefined && /^[A-Za-z0-9][A-Za-z0-9._:/@+-]*$/.test(value);
|
|
184
|
+
if (!concrete(requested) || !concrete(provider) || reasoningEffort === undefined ||
|
|
185
|
+
authored.small !== undefined || authored.metadata !== undefined)
|
|
186
|
+
throw new Error("profile model binding requires an exact static default/provider/effort without fallback or metadata routing");
|
|
187
|
+
const model = requested.startsWith(`${provider}/`)
|
|
188
|
+
? requested.slice(provider.length + 1) : requested;
|
|
189
|
+
if (resolved.requested !== requested || resolved.provider !== provider ||
|
|
190
|
+
resolved.reasoningEffort !== reasoningEffort || resolved.model !== model ||
|
|
191
|
+
!concrete(resolved.snapshot))
|
|
192
|
+
throw new Error("profile model binding contradicts its authored default or exact resolved identity");
|
|
193
|
+
}
|
|
194
|
+
if (canonicalCandidateDigest(task.model) !== canonicalCandidateDigest(policy.baseline.resolved))
|
|
195
|
+
throw new Error("profile model treatment task.model must equal the exact baseline model");
|
|
196
|
+
const changed = experiment.change.reduce((value, diff) => applyAgentProfileDiff(value, diff), { model: policy.baseline.authored });
|
|
197
|
+
if (changed.seats?.length || Object.values(changed.modes ?? {}).some(value => value.model !== undefined) || Object.values(changed.subagents ?? {}).some(value => value.model !== undefined))
|
|
198
|
+
throw new Error("profile model binding does not permit fallback or alternate model routes");
|
|
199
|
+
if (canonicalCandidateDigest(changed.model) !== canonicalCandidateDigest(policy.candidate.authored))
|
|
200
|
+
throw new Error("profile model binding contradicts the measured profile changes");
|
|
201
|
+
const expected = policy[arm];
|
|
202
|
+
if (profile && (canonicalCandidateDigest(profile.model) !== canonicalCandidateDigest(expected.authored) ||
|
|
203
|
+
profile.seats?.length ||
|
|
204
|
+
Object.values(profile.modes ?? {}).some(value => value.model !== undefined) ||
|
|
205
|
+
Object.values(profile.subagents ?? {}).some(value => value.model !== undefined)))
|
|
206
|
+
throw new Error("profile model binding does not describe the exact static single-model profile");
|
|
207
|
+
return expected.resolved;
|
|
208
|
+
}
|
|
161
209
|
export const agentProfileImprovementExperimentSchema = z
|
|
162
210
|
.object({
|
|
163
211
|
kind: z.literal("agent-profile-improvement-experiment"),
|
|
@@ -167,6 +215,7 @@ export const agentProfileImprovementExperimentSchema = z
|
|
|
167
215
|
baseline: agentProfileImprovementArmSchema,
|
|
168
216
|
candidate: agentProfileImprovementArmSchema,
|
|
169
217
|
change: agentProfileImprovementChangeSchema,
|
|
218
|
+
modelBinding: agentProfileImprovementModelBindingSchema.optional(),
|
|
170
219
|
candidateLineage: agentCandidateLineageSchema,
|
|
171
220
|
benchmark: agentProfileImprovementSuiteInputsSchema,
|
|
172
221
|
policy: agentCandidateEvaluationPolicySchema,
|
|
@@ -174,6 +223,14 @@ export const agentProfileImprovementExperimentSchema = z
|
|
|
174
223
|
})
|
|
175
224
|
.strict()
|
|
176
225
|
.superRefine((experiment, ctx) => {
|
|
226
|
+
try {
|
|
227
|
+
for (const task of experiment.benchmark.tasks)
|
|
228
|
+
for (const arm of ["baseline", "candidate"])
|
|
229
|
+
agentProfileImprovementExpectedModel(experiment, task, arm);
|
|
230
|
+
}
|
|
231
|
+
catch (error) {
|
|
232
|
+
ctx.addIssue({ code: "custom", path: ["modelBinding"], message: error instanceof Error ? error.message : "Invalid profile model binding" });
|
|
233
|
+
}
|
|
177
234
|
if (experiment.baseline.stateDigest !== experiment.source.sourceDigest) {
|
|
178
235
|
ctx.addIssue({
|
|
179
236
|
code: "custom",
|
|
@@ -260,8 +317,7 @@ const timingSchema = z
|
|
|
260
317
|
});
|
|
261
318
|
}
|
|
262
319
|
});
|
|
263
|
-
const
|
|
264
|
-
.object({
|
|
320
|
+
const profileGradingShape = {
|
|
265
321
|
grader: agentCandidateBenchmarkGraderIdentitySchema,
|
|
266
322
|
evidence: profileImprovementEvidenceSchema,
|
|
267
323
|
timing: timingSchema,
|
|
@@ -269,9 +325,8 @@ const agentProfileImprovementGradingSchema = z
|
|
|
269
325
|
score: z.number().finite(),
|
|
270
326
|
passed: z.boolean(),
|
|
271
327
|
dimensions: z.array(agentCandidateBenchmarkDimensionSchema),
|
|
272
|
-
}
|
|
273
|
-
|
|
274
|
-
.superRefine((grading, ctx) => {
|
|
328
|
+
};
|
|
329
|
+
function refineProfileGrading(grading, ctx) {
|
|
275
330
|
const names = grading.dimensions.map((dimension) => dimension.name);
|
|
276
331
|
if (new Set(names).size !== names.length) {
|
|
277
332
|
ctx.addIssue({
|
|
@@ -287,9 +342,31 @@ const agentProfileImprovementGradingSchema = z
|
|
|
287
342
|
message: "profile improvement grading evidence must be distinct from its grader",
|
|
288
343
|
});
|
|
289
344
|
}
|
|
345
|
+
}
|
|
346
|
+
const agentProfileImprovementGradingSchema = z.strictObject(profileGradingShape).superRefine(refineProfileGrading);
|
|
347
|
+
export const agentProfileImprovementUnavailableAccountingSchema = z.strictObject({
|
|
348
|
+
availability: z.literal("unavailable"),
|
|
349
|
+
reason: z.string().min(1).max(4000),
|
|
350
|
+
facts: z.strictObject({
|
|
351
|
+
inputTokens: agentCandidateFixedSpendSchema.shape.inputTokens.nullable(),
|
|
352
|
+
outputTokens: agentCandidateFixedSpendSchema.shape.outputTokens.nullable(),
|
|
353
|
+
cachedInputTokens: agentCandidateFixedSpendSchema.shape.cachedInputTokens.nullable(),
|
|
354
|
+
reasoningTokens: agentCandidateFixedSpendSchema.shape.reasoningTokens.nullable(),
|
|
355
|
+
modelCalls: agentCandidateFixedSpendSchema.shape.modelCalls.nullable(),
|
|
356
|
+
costUsdNanos: agentCandidateFixedSpendSchema.shape.costUsdNanos.nullable(),
|
|
357
|
+
costProvenance: agentCandidateFixedSpendSchema.shape.costProvenance.nullable(),
|
|
358
|
+
}),
|
|
359
|
+
}).superRefine((accounting, ctx) => {
|
|
360
|
+
if (!Object.values(accounting.facts).includes(null))
|
|
361
|
+
ctx.addIssue({ code: "custom", path: ["facts"], message: "complete accounting must use the fixed-spend contract" });
|
|
362
|
+
if ((accounting.facts.costUsdNanos === null) !== (accounting.facts.costProvenance === null))
|
|
363
|
+
ctx.addIssue({ code: "custom", path: ["facts", "costProvenance"], message: "known cost and provenance must be retained together" });
|
|
290
364
|
});
|
|
291
|
-
export const
|
|
292
|
-
|
|
365
|
+
export const agentProfileImprovementAccountingSchema = z.union([agentCandidateFixedSpendSchema, agentProfileImprovementUnavailableAccountingSchema]);
|
|
366
|
+
export function isAgentProfileImprovementAccountingUnavailable(accounting) {
|
|
367
|
+
return "availability" in accounting;
|
|
368
|
+
}
|
|
369
|
+
const profileRunReceiptShape = {
|
|
293
370
|
kind: z.literal("agent-profile-improvement-run"),
|
|
294
371
|
digestAlgorithm: z.literal("rfc8785-sha256"),
|
|
295
372
|
executionId: z.string().min(1).max(500),
|
|
@@ -324,9 +401,8 @@ export const agentProfileImprovementRunReceiptSchema = z
|
|
|
324
401
|
]),
|
|
325
402
|
grading: agentProfileImprovementGradingSchema,
|
|
326
403
|
digest: sha256DigestSchema,
|
|
327
|
-
}
|
|
328
|
-
|
|
329
|
-
.superRefine((receipt, ctx) => {
|
|
404
|
+
};
|
|
405
|
+
function refineProfileRunReceipt(receipt, ctx) {
|
|
330
406
|
if (evidenceKey(receipt.output) === evidenceKey(receipt.grading.evidence)) {
|
|
331
407
|
ctx.addIssue({
|
|
332
408
|
code: "custom",
|
|
@@ -334,7 +410,8 @@ export const agentProfileImprovementRunReceiptSchema = z
|
|
|
334
410
|
message: "profile improvement grading evidence must be distinct from the agent output",
|
|
335
411
|
});
|
|
336
412
|
}
|
|
337
|
-
|
|
413
|
+
const executionUsage = isAgentProfileImprovementAccountingUnavailable(receipt.usage) ? receipt.usage.facts : receipt.usage;
|
|
414
|
+
if (executionUsage.modelCalls !== null && receipt.trace.modelCallCount !== executionUsage.modelCalls) {
|
|
338
415
|
ctx.addIssue({
|
|
339
416
|
code: "custom",
|
|
340
417
|
path: ["trace", "modelCallCount"],
|
|
@@ -348,10 +425,18 @@ export const agentProfileImprovementRunReceiptSchema = z
|
|
|
348
425
|
message: "profile trace must retain at least one event for every model call",
|
|
349
426
|
});
|
|
350
427
|
}
|
|
428
|
+
// Missing nonnegative counters supply only lower bounds for refusing known limit violations.
|
|
429
|
+
// These values are never persisted as measured usage or admitted to a comparison.
|
|
430
|
+
const lowerBound = (usage) => {
|
|
431
|
+
if (!isAgentProfileImprovementAccountingUnavailable(usage))
|
|
432
|
+
return usage;
|
|
433
|
+
const { facts } = usage;
|
|
434
|
+
return { inputTokens: facts.inputTokens ?? 0, outputTokens: facts.outputTokens ?? 0, cachedInputTokens: facts.cachedInputTokens ?? 0, reasoningTokens: facts.reasoningTokens ?? 0, modelCalls: facts.modelCalls ?? 0, costUsdNanos: facts.costUsdNanos ?? 0, costProvenance: facts.costProvenance ?? "estimated" };
|
|
435
|
+
};
|
|
351
436
|
refineAgentExecutionWithinLimits(receipt.limits, {
|
|
352
437
|
durationMs: receipt.timing.durationMs,
|
|
353
438
|
steps: receipt.steps,
|
|
354
|
-
usage: combinedProfileUsage(receipt.usage, receipt.grading.usage),
|
|
439
|
+
usage: combinedProfileUsage(lowerBound(receipt.usage), lowerBound(receipt.grading.usage)),
|
|
355
440
|
}, ctx);
|
|
356
441
|
const billing = receipt.billing.map(evidenceKey);
|
|
357
442
|
if (new Set(billing).size !== billing.length) {
|
|
@@ -368,7 +453,14 @@ export const agentProfileImprovementRunReceiptSchema = z
|
|
|
368
453
|
message: "profile improvement run receipt digest is invalid",
|
|
369
454
|
});
|
|
370
455
|
}
|
|
371
|
-
}
|
|
456
|
+
}
|
|
457
|
+
export const agentProfileImprovementRunReceiptSchema = z.strictObject(profileRunReceiptShape).superRefine(refineProfileRunReceipt);
|
|
458
|
+
/** Opt-in recording preserves gaps; the publishable comparison still accepts only complete receipts. */
|
|
459
|
+
export const agentProfileImprovementRecordedRunReceiptSchema = z.strictObject({
|
|
460
|
+
...profileRunReceiptShape,
|
|
461
|
+
usage: agentProfileImprovementAccountingSchema,
|
|
462
|
+
grading: z.strictObject({ ...profileGradingShape, usage: agentProfileImprovementAccountingSchema }).superRefine(refineProfileGrading),
|
|
463
|
+
}).superRefine(refineProfileRunReceipt);
|
|
372
464
|
function combinedProfileUsage(execution, grading) {
|
|
373
465
|
return {
|
|
374
466
|
inputTokens: execution.inputTokens + grading.inputTokens,
|
|
@@ -507,6 +599,14 @@ function refineProfileImprovementComparison(comparison, ctx) {
|
|
|
507
599
|
const cell = receipt.runCell;
|
|
508
600
|
const profile = comparison.experiment[arm];
|
|
509
601
|
const armPath = ["measurements", index, arm];
|
|
602
|
+
let expectedModel;
|
|
603
|
+
try {
|
|
604
|
+
expectedModel = agentProfileImprovementExpectedModel(comparison.experiment, task, arm);
|
|
605
|
+
}
|
|
606
|
+
catch (error) {
|
|
607
|
+
ctx.addIssue({ code: "custom", path: ["experiment", "modelBinding"], message: error instanceof Error ? error.message : "Invalid profile model binding" });
|
|
608
|
+
continue;
|
|
609
|
+
}
|
|
510
610
|
const checks = [
|
|
511
611
|
[
|
|
512
612
|
cell.experimentDigest === comparison.experiment.digest,
|
|
@@ -544,7 +644,7 @@ function refineProfileImprovementComparison(comparison, ctx) {
|
|
|
544
644
|
"profile run receipt must bind the signed evaluator",
|
|
545
645
|
],
|
|
546
646
|
[
|
|
547
|
-
|
|
647
|
+
canonicalCandidateDigest(receipt.resolvedModel) === canonicalCandidateDigest(expectedModel),
|
|
548
648
|
[...armPath, "resolvedModel"],
|
|
549
649
|
"profile run receipt must bind the signed model snapshot",
|
|
550
650
|
],
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import type { AgentCandidateBenchmarkDimension, AgentCandidateBenchmarkGraderIdentity, AgentCandidateDigestAlgorithm, AgentCandidateEvaluationPolicy, AgentCandidateExecutionLimits, AgentCandidateFixedSpend, AgentCandidateLineage, AgentCandidateResolvedModel, AgentImprovementMeasuredComparisonBase, Sha256Digest } from "./agent-candidate.js";
|
|
2
2
|
import type { AgentImprovementSource } from "./agent-improvement-source.js";
|
|
3
|
+
import type { AgentProfileModelHints } from "./agent-profile.js";
|
|
3
4
|
import type { AgentProfileDiff } from "./profile-diff.js";
|
|
4
5
|
/** An access-controlled evidence record emitted by a host-owned profile run. */
|
|
5
6
|
export interface AgentProfileImprovementEvidence {
|
|
@@ -57,6 +58,20 @@ export interface AgentProfileImprovementExecutionRef extends AgentProfileImprove
|
|
|
57
58
|
* control and redaction.
|
|
58
59
|
*/
|
|
59
60
|
export type AgentProfileImprovementChange = [AgentProfileDiff, ...AgentProfileDiff[]];
|
|
61
|
+
/** Fixed-task is the historical default. Profile-default explicitly treats model selection. */
|
|
62
|
+
export type AgentProfileImprovementModelBinding = {
|
|
63
|
+
kind: "fixed-task";
|
|
64
|
+
} | {
|
|
65
|
+
kind: "profile-default";
|
|
66
|
+
baseline: {
|
|
67
|
+
authored: AgentProfileModelHints;
|
|
68
|
+
resolved: AgentCandidateResolvedModel;
|
|
69
|
+
};
|
|
70
|
+
candidate: {
|
|
71
|
+
authored: AgentProfileModelHints;
|
|
72
|
+
resolved: AgentCandidateResolvedModel;
|
|
73
|
+
};
|
|
74
|
+
};
|
|
60
75
|
/** A measured comparison of two states of one host-owned agent profile. */
|
|
61
76
|
export interface AgentProfileImprovementExperimentMaterial {
|
|
62
77
|
kind: "agent-profile-improvement-experiment";
|
|
@@ -66,6 +81,7 @@ export interface AgentProfileImprovementExperimentMaterial {
|
|
|
66
81
|
baseline: AgentProfileImprovementArm;
|
|
67
82
|
candidate: AgentProfileImprovementArm;
|
|
68
83
|
change: AgentProfileImprovementChange;
|
|
84
|
+
modelBinding?: AgentProfileImprovementModelBinding;
|
|
69
85
|
candidateLineage: AgentCandidateLineage;
|
|
70
86
|
benchmark: AgentProfileImprovementSuiteInputs;
|
|
71
87
|
policy: AgentCandidateEvaluationPolicy;
|
|
@@ -89,8 +105,17 @@ export interface AgentProfileImprovementRunCellMaterial {
|
|
|
89
105
|
export interface AgentProfileImprovementRunCell extends AgentProfileImprovementRunCellMaterial {
|
|
90
106
|
digest: Sha256Digest;
|
|
91
107
|
}
|
|
108
|
+
/** Missing profile-run facts remain explicit; this branch cannot support promotion. */
|
|
109
|
+
export interface AgentProfileImprovementUnavailableAccounting {
|
|
110
|
+
availability: "unavailable";
|
|
111
|
+
reason: string;
|
|
112
|
+
facts: {
|
|
113
|
+
[K in keyof AgentCandidateFixedSpend]: AgentCandidateFixedSpend[K] | null;
|
|
114
|
+
};
|
|
115
|
+
}
|
|
116
|
+
export type AgentProfileImprovementAccounting = AgentCandidateFixedSpend | AgentProfileImprovementUnavailableAccounting;
|
|
92
117
|
/** Verifiable output from one profile execution and its frozen evaluator. */
|
|
93
|
-
export interface AgentProfileImprovementRunReceipt {
|
|
118
|
+
export interface AgentProfileImprovementRunReceipt<TAccounting extends AgentProfileImprovementAccounting = AgentCandidateFixedSpend> {
|
|
94
119
|
kind: "agent-profile-improvement-run";
|
|
95
120
|
digestAlgorithm: AgentCandidateDigestAlgorithm;
|
|
96
121
|
executionId: string;
|
|
@@ -106,7 +131,7 @@ export interface AgentProfileImprovementRunReceipt {
|
|
|
106
131
|
steps: number;
|
|
107
132
|
resolvedModel: AgentCandidateResolvedModel;
|
|
108
133
|
limits: AgentCandidateExecutionLimits;
|
|
109
|
-
usage:
|
|
134
|
+
usage: TAccounting;
|
|
110
135
|
trace: {
|
|
111
136
|
evidence: AgentProfileImprovementEvidence;
|
|
112
137
|
eventCount: number;
|
|
@@ -128,7 +153,7 @@ export interface AgentProfileImprovementRunReceipt {
|
|
|
128
153
|
endedAtMs: number;
|
|
129
154
|
durationMs: number;
|
|
130
155
|
};
|
|
131
|
-
usage:
|
|
156
|
+
usage: TAccounting;
|
|
132
157
|
score: number;
|
|
133
158
|
passed: boolean;
|
|
134
159
|
dimensions: AgentCandidateBenchmarkDimension[];
|
|
@@ -136,10 +161,13 @@ export interface AgentProfileImprovementRunReceipt {
|
|
|
136
161
|
digest: Sha256Digest;
|
|
137
162
|
}
|
|
138
163
|
/** One paired result from the exact same task, seed, and evaluator. */
|
|
139
|
-
export interface AgentProfileImprovementMeasurement {
|
|
140
|
-
baseline: AgentProfileImprovementRunReceipt
|
|
141
|
-
candidate: AgentProfileImprovementRunReceipt
|
|
164
|
+
export interface AgentProfileImprovementMeasurement<TAccounting extends AgentProfileImprovementAccounting = AgentCandidateFixedSpend> {
|
|
165
|
+
baseline: AgentProfileImprovementRunReceipt<TAccounting>;
|
|
166
|
+
candidate: AgentProfileImprovementRunReceipt<TAccounting>;
|
|
142
167
|
}
|
|
168
|
+
/** Opt-in retained records can include accounting gaps; complete legacy types stay complete. */
|
|
169
|
+
export type AgentProfileImprovementRecordedRunReceipt = AgentProfileImprovementRunReceipt<AgentProfileImprovementAccounting>;
|
|
170
|
+
export type AgentProfileImprovementRecordedMeasurement = AgentProfileImprovementMeasurement<AgentProfileImprovementAccounting>;
|
|
143
171
|
/** Portable paired comparison from ordinary profile executions. */
|
|
144
172
|
export interface AgentProfileImprovementMeasuredComparison extends AgentImprovementMeasuredComparisonBase<AgentProfileImprovementExperiment, AgentProfileImprovementMeasurement, "agent-profile-improvement-measured-comparison"> {
|
|
145
173
|
kind: "agent-profile-improvement-measured-comparison";
|
|
@@ -40,6 +40,7 @@ export declare const AgentInteractiveSessionRefSchema: z.ZodObject<{
|
|
|
40
40
|
cursor: "cursor";
|
|
41
41
|
grok: "grok";
|
|
42
42
|
nanocode: "nanocode";
|
|
43
|
+
exo: "exo";
|
|
43
44
|
acp: "acp";
|
|
44
45
|
"cli-base": "cli-base";
|
|
45
46
|
}>;
|
|
@@ -221,6 +222,7 @@ export declare const AgentInteractiveSessionControlClaimRequestSchema: z.ZodObje
|
|
|
221
222
|
cursor: "cursor";
|
|
222
223
|
grok: "grok";
|
|
223
224
|
nanocode: "nanocode";
|
|
225
|
+
exo: "exo";
|
|
224
226
|
acp: "acp";
|
|
225
227
|
"cli-base": "cli-base";
|
|
226
228
|
}>;
|
|
@@ -393,6 +395,7 @@ export declare const AgentInteractiveSessionControlClaimAcknowledgementSchema: z
|
|
|
393
395
|
cursor: "cursor";
|
|
394
396
|
grok: "grok";
|
|
395
397
|
nanocode: "nanocode";
|
|
398
|
+
exo: "exo";
|
|
396
399
|
acp: "acp";
|
|
397
400
|
"cli-base": "cli-base";
|
|
398
401
|
}>;
|
|
@@ -587,6 +590,7 @@ export declare const AgentInteractiveSessionStatusSchema: z.ZodDiscriminatedUnio
|
|
|
587
590
|
cursor: "cursor";
|
|
588
591
|
grok: "grok";
|
|
589
592
|
nanocode: "nanocode";
|
|
593
|
+
exo: "exo";
|
|
590
594
|
acp: "acp";
|
|
591
595
|
"cli-base": "cli-base";
|
|
592
596
|
}>;
|
|
@@ -740,6 +744,7 @@ export declare const AgentInteractiveSessionStatusSchema: z.ZodDiscriminatedUnio
|
|
|
740
744
|
cursor: "cursor";
|
|
741
745
|
grok: "grok";
|
|
742
746
|
nanocode: "nanocode";
|
|
747
|
+
exo: "exo";
|
|
743
748
|
acp: "acp";
|
|
744
749
|
"cli-base": "cli-base";
|
|
745
750
|
}>;
|
|
@@ -901,6 +906,7 @@ export declare const AgentInteractiveSessionStatusSchema: z.ZodDiscriminatedUnio
|
|
|
901
906
|
cursor: "cursor";
|
|
902
907
|
grok: "grok";
|
|
903
908
|
nanocode: "nanocode";
|
|
909
|
+
exo: "exo";
|
|
904
910
|
acp: "acp";
|
|
905
911
|
"cli-base": "cli-base";
|
|
906
912
|
}>;
|
|
@@ -1068,6 +1074,7 @@ export declare const AgentInteractiveSessionStopCommandSchema: z.ZodObject<{
|
|
|
1068
1074
|
cursor: "cursor";
|
|
1069
1075
|
grok: "grok";
|
|
1070
1076
|
nanocode: "nanocode";
|
|
1077
|
+
exo: "exo";
|
|
1071
1078
|
acp: "acp";
|
|
1072
1079
|
"cli-base": "cli-base";
|
|
1073
1080
|
}>;
|
|
@@ -1242,6 +1249,7 @@ export declare const AgentInteractiveSessionStopAcknowledgementSchema: z.ZodObje
|
|
|
1242
1249
|
cursor: "cursor";
|
|
1243
1250
|
grok: "grok";
|
|
1244
1251
|
nanocode: "nanocode";
|
|
1252
|
+
exo: "exo";
|
|
1245
1253
|
acp: "acp";
|
|
1246
1254
|
"cli-base": "cli-base";
|
|
1247
1255
|
}>;
|
|
@@ -1434,6 +1442,7 @@ export declare const AgentInteractiveSessionPromptCommandSchema: z.ZodObject<{
|
|
|
1434
1442
|
cursor: "cursor";
|
|
1435
1443
|
grok: "grok";
|
|
1436
1444
|
nanocode: "nanocode";
|
|
1445
|
+
exo: "exo";
|
|
1437
1446
|
acp: "acp";
|
|
1438
1447
|
"cli-base": "cli-base";
|
|
1439
1448
|
}>;
|
|
@@ -1607,6 +1616,7 @@ export declare const AgentInteractiveSessionPromptAcknowledgementSchema: z.ZodOb
|
|
|
1607
1616
|
cursor: "cursor";
|
|
1608
1617
|
grok: "grok";
|
|
1609
1618
|
nanocode: "nanocode";
|
|
1619
|
+
exo: "exo";
|
|
1610
1620
|
acp: "acp";
|
|
1611
1621
|
"cli-base": "cli-base";
|
|
1612
1622
|
}>;
|
|
@@ -69,6 +69,7 @@ export declare const AgentInteractiveSessionStartSchema: z.ZodObject<{
|
|
|
69
69
|
cursor: "cursor";
|
|
70
70
|
grok: "grok";
|
|
71
71
|
nanocode: "nanocode";
|
|
72
|
+
exo: "exo";
|
|
72
73
|
acp: "acp";
|
|
73
74
|
"cli-base": "cli-base";
|
|
74
75
|
}>>;
|
|
@@ -90,6 +91,7 @@ export declare const AgentInteractiveSessionStartSchema: z.ZodObject<{
|
|
|
90
91
|
cursor: "cursor";
|
|
91
92
|
grok: "grok";
|
|
92
93
|
nanocode: "nanocode";
|
|
94
|
+
exo: "exo";
|
|
93
95
|
acp: "acp";
|
|
94
96
|
"cli-base": "cli-base";
|
|
95
97
|
}>;
|
|
@@ -95,6 +95,7 @@ export declare const AgentTurnInputSchema: z.ZodObject<{
|
|
|
95
95
|
cursor: "cursor";
|
|
96
96
|
grok: "grok";
|
|
97
97
|
nanocode: "nanocode";
|
|
98
|
+
exo: "exo";
|
|
98
99
|
acp: "acp";
|
|
99
100
|
"cli-base": "cli-base";
|
|
100
101
|
}>>;
|
|
@@ -116,6 +117,7 @@ export declare const AgentTurnInputSchema: z.ZodObject<{
|
|
|
116
117
|
cursor: "cursor";
|
|
117
118
|
grok: "grok";
|
|
118
119
|
nanocode: "nanocode";
|
|
120
|
+
exo: "exo";
|
|
119
121
|
acp: "acp";
|
|
120
122
|
"cli-base": "cli-base";
|
|
121
123
|
}>;
|
|
@@ -512,6 +514,7 @@ export declare const AgentTurnInputSchema: z.ZodObject<{
|
|
|
512
514
|
cursor: "cursor";
|
|
513
515
|
grok: "grok";
|
|
514
516
|
nanocode: "nanocode";
|
|
517
|
+
exo: "exo";
|
|
515
518
|
acp: "acp";
|
|
516
519
|
"cli-base": "cli-base";
|
|
517
520
|
}>>;
|
|
@@ -533,6 +536,7 @@ export declare const AgentTurnInputSchema: z.ZodObject<{
|
|
|
533
536
|
cursor: "cursor";
|
|
534
537
|
grok: "grok";
|
|
535
538
|
nanocode: "nanocode";
|
|
539
|
+
exo: "exo";
|
|
536
540
|
acp: "acp";
|
|
537
541
|
"cli-base": "cli-base";
|
|
538
542
|
}>;
|
|
@@ -1996,6 +2000,7 @@ export declare const AgentEnvironmentGetOptionsSchema: z.ZodObject<{
|
|
|
1996
2000
|
cursor: "cursor";
|
|
1997
2001
|
grok: "grok";
|
|
1998
2002
|
nanocode: "nanocode";
|
|
2003
|
+
exo: "exo";
|
|
1999
2004
|
acp: "acp";
|
|
2000
2005
|
"cli-base": "cli-base";
|
|
2001
2006
|
}>>;
|
|
@@ -2017,6 +2022,7 @@ export declare const AgentEnvironmentGetOptionsSchema: z.ZodObject<{
|
|
|
2017
2022
|
cursor: "cursor";
|
|
2018
2023
|
grok: "grok";
|
|
2019
2024
|
nanocode: "nanocode";
|
|
2025
|
+
exo: "exo";
|
|
2020
2026
|
acp: "acp";
|
|
2021
2027
|
"cli-base": "cli-base";
|
|
2022
2028
|
}>;
|
package/dist/harness.d.ts
CHANGED
package/dist/harness.js
CHANGED
package/dist/learning-state.d.ts
CHANGED
|
@@ -49,6 +49,7 @@ export declare const AgentLearningFileSchema: z.ZodObject<{
|
|
|
49
49
|
cursor: "cursor";
|
|
50
50
|
grok: "grok";
|
|
51
51
|
nanocode: "nanocode";
|
|
52
|
+
exo: "exo";
|
|
52
53
|
acp: "acp";
|
|
53
54
|
"cli-base": "cli-base";
|
|
54
55
|
}>;
|
|
@@ -75,6 +76,7 @@ export declare const AgentLearningNativeRefSchema: z.ZodObject<{
|
|
|
75
76
|
cursor: "cursor";
|
|
76
77
|
grok: "grok";
|
|
77
78
|
nanocode: "nanocode";
|
|
79
|
+
exo: "exo";
|
|
78
80
|
acp: "acp";
|
|
79
81
|
"cli-base": "cli-base";
|
|
80
82
|
}>;
|
|
@@ -126,6 +128,7 @@ declare const materialSchema: z.ZodObject<{
|
|
|
126
128
|
cursor: "cursor";
|
|
127
129
|
grok: "grok";
|
|
128
130
|
nanocode: "nanocode";
|
|
131
|
+
exo: "exo";
|
|
129
132
|
acp: "acp";
|
|
130
133
|
"cli-base": "cli-base";
|
|
131
134
|
}>;
|
|
@@ -151,6 +154,7 @@ declare const materialSchema: z.ZodObject<{
|
|
|
151
154
|
cursor: "cursor";
|
|
152
155
|
grok: "grok";
|
|
153
156
|
nanocode: "nanocode";
|
|
157
|
+
exo: "exo";
|
|
154
158
|
acp: "acp";
|
|
155
159
|
"cli-base": "cli-base";
|
|
156
160
|
}>;
|
|
@@ -206,6 +210,7 @@ export declare const AgentLearningManifestSchema: z.ZodObject<{
|
|
|
206
210
|
cursor: "cursor";
|
|
207
211
|
grok: "grok";
|
|
208
212
|
nanocode: "nanocode";
|
|
213
|
+
exo: "exo";
|
|
209
214
|
acp: "acp";
|
|
210
215
|
"cli-base": "cli-base";
|
|
211
216
|
}>;
|
|
@@ -231,6 +236,7 @@ export declare const AgentLearningManifestSchema: z.ZodObject<{
|
|
|
231
236
|
cursor: "cursor";
|
|
232
237
|
grok: "grok";
|
|
233
238
|
nanocode: "nanocode";
|
|
239
|
+
exo: "exo";
|
|
234
240
|
acp: "acp";
|
|
235
241
|
"cli-base": "cli-base";
|
|
236
242
|
}>;
|
|
@@ -278,6 +284,7 @@ declare const exportMaterialSchema: z.ZodObject<{
|
|
|
278
284
|
cursor: "cursor";
|
|
279
285
|
grok: "grok";
|
|
280
286
|
nanocode: "nanocode";
|
|
287
|
+
exo: "exo";
|
|
281
288
|
acp: "acp";
|
|
282
289
|
"cli-base": "cli-base";
|
|
283
290
|
}>;
|
|
@@ -312,6 +319,7 @@ declare const exportMaterialSchema: z.ZodObject<{
|
|
|
312
319
|
cursor: "cursor";
|
|
313
320
|
grok: "grok";
|
|
314
321
|
nanocode: "nanocode";
|
|
322
|
+
exo: "exo";
|
|
315
323
|
acp: "acp";
|
|
316
324
|
"cli-base": "cli-base";
|
|
317
325
|
}>;
|
|
@@ -337,6 +345,7 @@ declare const exportMaterialSchema: z.ZodObject<{
|
|
|
337
345
|
cursor: "cursor";
|
|
338
346
|
grok: "grok";
|
|
339
347
|
nanocode: "nanocode";
|
|
348
|
+
exo: "exo";
|
|
340
349
|
acp: "acp";
|
|
341
350
|
"cli-base": "cli-base";
|
|
342
351
|
}>;
|
|
@@ -382,6 +391,7 @@ export declare const AgentLearningExportSchema: z.ZodObject<{
|
|
|
382
391
|
cursor: "cursor";
|
|
383
392
|
grok: "grok";
|
|
384
393
|
nanocode: "nanocode";
|
|
394
|
+
exo: "exo";
|
|
385
395
|
acp: "acp";
|
|
386
396
|
"cli-base": "cli-base";
|
|
387
397
|
}>;
|
|
@@ -416,6 +426,7 @@ export declare const AgentLearningExportSchema: z.ZodObject<{
|
|
|
416
426
|
cursor: "cursor";
|
|
417
427
|
grok: "grok";
|
|
418
428
|
nanocode: "nanocode";
|
|
429
|
+
exo: "exo";
|
|
419
430
|
acp: "acp";
|
|
420
431
|
"cli-base": "cli-base";
|
|
421
432
|
}>;
|
|
@@ -441,6 +452,7 @@ export declare const AgentLearningExportSchema: z.ZodObject<{
|
|
|
441
452
|
cursor: "cursor";
|
|
442
453
|
grok: "grok";
|
|
443
454
|
nanocode: "nanocode";
|
|
455
|
+
exo: "exo";
|
|
444
456
|
acp: "acp";
|
|
445
457
|
"cli-base": "cli-base";
|
|
446
458
|
}>;
|
|
@@ -472,6 +484,7 @@ export declare const AgentLearningCapabilitiesSchema: z.ZodObject<{
|
|
|
472
484
|
cursor: "cursor";
|
|
473
485
|
grok: "grok";
|
|
474
486
|
nanocode: "nanocode";
|
|
487
|
+
exo: "exo";
|
|
475
488
|
acp: "acp";
|
|
476
489
|
"cli-base": "cli-base";
|
|
477
490
|
}>;
|
|
@@ -179,6 +179,7 @@ export declare const ContextTransferRequestSchema: z.ZodObject<{
|
|
|
179
179
|
cursor: "cursor";
|
|
180
180
|
grok: "grok";
|
|
181
181
|
nanocode: "nanocode";
|
|
182
|
+
exo: "exo";
|
|
182
183
|
acp: "acp";
|
|
183
184
|
"cli-base": "cli-base";
|
|
184
185
|
}>>;
|
|
@@ -200,6 +201,7 @@ export declare const ContextTransferRequestSchema: z.ZodObject<{
|
|
|
200
201
|
cursor: "cursor";
|
|
201
202
|
grok: "grok";
|
|
202
203
|
nanocode: "nanocode";
|
|
204
|
+
exo: "exo";
|
|
203
205
|
acp: "acp";
|
|
204
206
|
"cli-base": "cli-base";
|
|
205
207
|
}>;
|
package/dist/profile-schema.d.ts
CHANGED
|
@@ -190,6 +190,7 @@ export declare const agentProfileSeatSchema: z.ZodObject<{
|
|
|
190
190
|
cursor: "cursor";
|
|
191
191
|
grok: "grok";
|
|
192
192
|
nanocode: "nanocode";
|
|
193
|
+
exo: "exo";
|
|
193
194
|
acp: "acp";
|
|
194
195
|
"cli-base": "cli-base";
|
|
195
196
|
}>;
|
|
@@ -543,6 +544,7 @@ export declare const agentProfileSchema: z.ZodObject<{
|
|
|
543
544
|
cursor: "cursor";
|
|
544
545
|
grok: "grok";
|
|
545
546
|
nanocode: "nanocode";
|
|
547
|
+
exo: "exo";
|
|
546
548
|
acp: "acp";
|
|
547
549
|
"cli-base": "cli-base";
|
|
548
550
|
}>>;
|
|
@@ -564,6 +566,7 @@ export declare const agentProfileSchema: z.ZodObject<{
|
|
|
564
566
|
cursor: "cursor";
|
|
565
567
|
grok: "grok";
|
|
566
568
|
nanocode: "nanocode";
|
|
569
|
+
exo: "exo";
|
|
567
570
|
acp: "acp";
|
|
568
571
|
"cli-base": "cli-base";
|
|
569
572
|
}>;
|