@tangle-network/agent-interface 0.33.0 → 0.35.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/agent-candidate-code-schema.d.ts +0 -3
- package/dist/agent-candidate-execution-plan-schema.d.ts +11 -17
- package/dist/agent-candidate-lineage-schema.d.ts +2 -2
- package/dist/agent-candidate-outcome-schema.d.ts +4 -4
- package/dist/agent-candidate-profile-schema.d.ts +0 -3
- package/dist/agent-candidate-promotion-schema.d.ts +1418 -885
- package/dist/agent-candidate-promotion-schema.js +55 -346
- package/dist/agent-candidate-receipt-schema.d.ts +9 -11
- package/dist/agent-candidate-receipt-schema.js +1 -0
- package/dist/agent-candidate-schema.d.ts +0 -6
- package/dist/agent-candidate-schema.js +1 -3
- package/dist/agent-candidate.d.ts +15 -7
- package/dist/agent-execution-limits.d.ts +28 -0
- package/dist/agent-execution-limits.js +77 -0
- package/dist/agent-improvement-measurement-schema.d.ts +198 -0
- package/dist/agent-improvement-measurement-schema.js +349 -0
- package/dist/agent-improvement-source.d.ts +23 -0
- package/dist/agent-improvement-source.js +38 -0
- package/dist/agent-profile-improvement-schema.d.ts +1088 -0
- package/dist/agent-profile-improvement-schema.js +560 -0
- package/dist/agent-profile-improvement.d.ts +140 -0
- package/dist/agent-profile-improvement.js +1 -0
- package/dist/agent-profile.d.ts +2 -2
- package/dist/agent-profile.js +2 -2
- package/dist/harness-capabilities.d.ts +1 -1
- package/dist/harness-capabilities.js +9 -12
- package/dist/harness.d.ts +1 -10
- package/dist/harness.js +0 -13
- package/dist/index.d.ts +8 -1
- package/dist/index.js +6 -0
- package/dist/interaction.d.ts +0 -17
- package/dist/interaction.js +0 -23
- package/dist/number-validation.d.ts +1 -0
- package/dist/number-validation.js +4 -0
- package/dist/profile-schema.d.ts +0 -3
- package/package.json +1 -1
|
@@ -0,0 +1,140 @@
|
|
|
1
|
+
import type { AgentCandidateBenchmarkDimension, AgentCandidateBenchmarkGraderIdentity, AgentCandidateDigestAlgorithm, AgentCandidateEvaluationPolicy, AgentCandidateExecutionLimits, AgentCandidateFixedSpend, AgentCandidateLineage, AgentCandidateResolvedModel, AgentImprovementMeasuredComparisonBase, Sha256Digest } from "./agent-candidate.js";
|
|
2
|
+
import type { AgentImprovementSource } from "./agent-improvement-source.js";
|
|
3
|
+
import type { AgentProfileDiff } from "./profile-diff.js";
|
|
4
|
+
/** An access-controlled evidence record emitted by a host-owned profile run. */
|
|
5
|
+
export interface AgentProfileImprovementEvidence {
|
|
6
|
+
kind: string;
|
|
7
|
+
identity: string;
|
|
8
|
+
digest: Sha256Digest;
|
|
9
|
+
}
|
|
10
|
+
/** One profile task whose content and evaluator are frozen before either arm runs. */
|
|
11
|
+
export interface AgentProfileImprovementTaskMaterial {
|
|
12
|
+
kind: "agent-profile-improvement-task";
|
|
13
|
+
digestAlgorithm: AgentCandidateDigestAlgorithm;
|
|
14
|
+
scenario: {
|
|
15
|
+
id: string;
|
|
16
|
+
kind: string;
|
|
17
|
+
digest: Sha256Digest;
|
|
18
|
+
};
|
|
19
|
+
grader: AgentCandidateBenchmarkGraderIdentity;
|
|
20
|
+
model: AgentCandidateResolvedModel;
|
|
21
|
+
limits: AgentCandidateExecutionLimits;
|
|
22
|
+
}
|
|
23
|
+
export interface AgentProfileImprovementTask extends AgentProfileImprovementTaskMaterial {
|
|
24
|
+
digest: Sha256Digest;
|
|
25
|
+
}
|
|
26
|
+
/** The full paired denominator for host-owned profile executions. */
|
|
27
|
+
export interface AgentProfileImprovementSuiteMaterial {
|
|
28
|
+
kind: "agent-profile-improvement-suite";
|
|
29
|
+
digestAlgorithm: AgentCandidateDigestAlgorithm;
|
|
30
|
+
splitDigest: Sha256Digest;
|
|
31
|
+
taskDigests: [Sha256Digest, ...Sha256Digest[]];
|
|
32
|
+
reps: number;
|
|
33
|
+
/** Task-major, then repetition-major. */
|
|
34
|
+
seeds: [number, ...number[]];
|
|
35
|
+
}
|
|
36
|
+
export interface AgentProfileImprovementSuite extends AgentProfileImprovementSuiteMaterial {
|
|
37
|
+
digest: Sha256Digest;
|
|
38
|
+
}
|
|
39
|
+
export interface AgentProfileImprovementSuiteInputs {
|
|
40
|
+
suite: AgentProfileImprovementSuite;
|
|
41
|
+
tasks: [AgentProfileImprovementTask, ...AgentProfileImprovementTask[]];
|
|
42
|
+
}
|
|
43
|
+
/** The complete profile state that actually runs. */
|
|
44
|
+
export interface AgentProfileImprovementArm {
|
|
45
|
+
stateDigest: Sha256Digest;
|
|
46
|
+
}
|
|
47
|
+
/**
|
|
48
|
+
* Ordered portable profile patches retained for review and activation.
|
|
49
|
+
*
|
|
50
|
+
* Applying the steps in order matters: a full resource replacement is a reset
|
|
51
|
+
* followed by a replacement step. Prompt and inline skill content can be
|
|
52
|
+
* sensitive, so the product that persists this value owns access control and
|
|
53
|
+
* redaction.
|
|
54
|
+
*/
|
|
55
|
+
export type AgentProfileImprovementChange = [AgentProfileDiff, ...AgentProfileDiff[]];
|
|
56
|
+
/** A measured comparison of two states of one host-owned agent profile. */
|
|
57
|
+
export interface AgentProfileImprovementExperimentMaterial {
|
|
58
|
+
kind: "agent-profile-improvement-experiment";
|
|
59
|
+
digestAlgorithm: AgentCandidateDigestAlgorithm;
|
|
60
|
+
source: AgentImprovementSource;
|
|
61
|
+
baseline: AgentProfileImprovementArm;
|
|
62
|
+
candidate: AgentProfileImprovementArm;
|
|
63
|
+
change: AgentProfileImprovementChange;
|
|
64
|
+
candidateLineage: AgentCandidateLineage;
|
|
65
|
+
benchmark: AgentProfileImprovementSuiteInputs;
|
|
66
|
+
policy: AgentCandidateEvaluationPolicy;
|
|
67
|
+
}
|
|
68
|
+
export interface AgentProfileImprovementExperiment extends AgentProfileImprovementExperimentMaterial {
|
|
69
|
+
digest: Sha256Digest;
|
|
70
|
+
}
|
|
71
|
+
/** Exact identity for one profile attempt in a frozen experiment. */
|
|
72
|
+
export interface AgentProfileImprovementRunCellMaterial {
|
|
73
|
+
kind: "agent-profile-improvement-run-cell";
|
|
74
|
+
experimentDigest: Sha256Digest;
|
|
75
|
+
arm: "baseline" | "candidate";
|
|
76
|
+
stateDigest: Sha256Digest;
|
|
77
|
+
suiteDigest: Sha256Digest;
|
|
78
|
+
taskDigest: Sha256Digest;
|
|
79
|
+
taskIndex: number;
|
|
80
|
+
repetition: number;
|
|
81
|
+
seed: number;
|
|
82
|
+
attempt: number;
|
|
83
|
+
}
|
|
84
|
+
export interface AgentProfileImprovementRunCell extends AgentProfileImprovementRunCellMaterial {
|
|
85
|
+
digest: Sha256Digest;
|
|
86
|
+
}
|
|
87
|
+
/** Verifiable output from one profile execution and its frozen evaluator. */
|
|
88
|
+
export interface AgentProfileImprovementRunReceipt {
|
|
89
|
+
kind: "agent-profile-improvement-run";
|
|
90
|
+
digestAlgorithm: AgentCandidateDigestAlgorithm;
|
|
91
|
+
executionId: string;
|
|
92
|
+
runCell: AgentProfileImprovementRunCell;
|
|
93
|
+
runRecord: AgentProfileImprovementEvidence;
|
|
94
|
+
billing: [AgentProfileImprovementEvidence, ...AgentProfileImprovementEvidence[]];
|
|
95
|
+
timing: {
|
|
96
|
+
startedAtMs: number;
|
|
97
|
+
endedAtMs: number;
|
|
98
|
+
durationMs: number;
|
|
99
|
+
};
|
|
100
|
+
steps: number;
|
|
101
|
+
resolvedModel: AgentCandidateResolvedModel;
|
|
102
|
+
limits: AgentCandidateExecutionLimits;
|
|
103
|
+
usage: AgentCandidateFixedSpend;
|
|
104
|
+
trace: {
|
|
105
|
+
evidence: AgentProfileImprovementEvidence;
|
|
106
|
+
eventCount: number;
|
|
107
|
+
modelCallCount: number;
|
|
108
|
+
};
|
|
109
|
+
output: AgentProfileImprovementEvidence;
|
|
110
|
+
outcome: {
|
|
111
|
+
status: "succeeded";
|
|
112
|
+
} | {
|
|
113
|
+
status: "failed";
|
|
114
|
+
code: string;
|
|
115
|
+
message: string;
|
|
116
|
+
};
|
|
117
|
+
grading: {
|
|
118
|
+
grader: AgentCandidateBenchmarkGraderIdentity;
|
|
119
|
+
evidence: AgentProfileImprovementEvidence;
|
|
120
|
+
timing: {
|
|
121
|
+
startedAtMs: number;
|
|
122
|
+
endedAtMs: number;
|
|
123
|
+
durationMs: number;
|
|
124
|
+
};
|
|
125
|
+
usage: AgentCandidateFixedSpend;
|
|
126
|
+
score: number;
|
|
127
|
+
passed: boolean;
|
|
128
|
+
dimensions: AgentCandidateBenchmarkDimension[];
|
|
129
|
+
};
|
|
130
|
+
digest: Sha256Digest;
|
|
131
|
+
}
|
|
132
|
+
/** One paired result from the exact same task, seed, and evaluator. */
|
|
133
|
+
export interface AgentProfileImprovementMeasurement {
|
|
134
|
+
baseline: AgentProfileImprovementRunReceipt;
|
|
135
|
+
candidate: AgentProfileImprovementRunReceipt;
|
|
136
|
+
}
|
|
137
|
+
/** Portable paired comparison from ordinary profile executions. */
|
|
138
|
+
export interface AgentProfileImprovementMeasuredComparison extends AgentImprovementMeasuredComparisonBase<AgentProfileImprovementExperiment, AgentProfileImprovementMeasurement, "agent-profile-improvement-measured-comparison"> {
|
|
139
|
+
kind: "agent-profile-improvement-measured-comparison";
|
|
140
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
package/dist/agent-profile.d.ts
CHANGED
|
@@ -3,8 +3,8 @@
|
|
|
3
3
|
*
|
|
4
4
|
* These model portable agent intent at the application boundary. Individual
|
|
5
5
|
* backends translate this shape into their own native profile/configuration
|
|
6
|
-
* formats internally. This is the canonical home
|
|
7
|
-
*
|
|
6
|
+
* formats internally. This package is the canonical public home for these
|
|
7
|
+
* symbols.
|
|
8
8
|
*/
|
|
9
9
|
import type { HarnessType } from "./harness.js";
|
|
10
10
|
/**
|
package/dist/agent-profile.js
CHANGED
|
@@ -3,8 +3,8 @@
|
|
|
3
3
|
*
|
|
4
4
|
* These model portable agent intent at the application boundary. Individual
|
|
5
5
|
* backends translate this shape into their own native profile/configuration
|
|
6
|
-
* formats internally. This is the canonical home
|
|
7
|
-
*
|
|
6
|
+
* formats internally. This package is the canonical public home for these
|
|
7
|
+
* symbols.
|
|
8
8
|
*/
|
|
9
9
|
/**
|
|
10
10
|
* Helper for creating typed inline resource refs.
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { ReasoningEffort } from "./agent-profile.js";
|
|
2
|
-
import {
|
|
2
|
+
import type { HarnessType } from "./harness.js";
|
|
3
3
|
/**
|
|
4
4
|
* The unified harness capability layer — the single source of truth for:
|
|
5
5
|
* 1. harness ↔ model compatibility (which models a harness can run), and
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { canonicalizeHarness } from "./harness.js";
|
|
2
1
|
/**
|
|
3
2
|
* The unified harness capability layer — the single source of truth for:
|
|
4
3
|
* 1. harness ↔ model compatibility (which models a harness can run), and
|
|
@@ -28,8 +27,7 @@ export const reasoningLadder = [
|
|
|
28
27
|
// ── Harness ↔ model compatibility ────────────────────────────────────────────
|
|
29
28
|
/**
|
|
30
29
|
* Provider prefixes a harness is vendor-locked to (canonical-id prefix, e.g. `anthropic`, `openai`).
|
|
31
|
-
* A harness with no entry is router-backed: it runs any model.
|
|
32
|
-
* (`claude`/`claudish`/`kimi`) resolve through `canonicalizeHarness` first.
|
|
30
|
+
* A harness with no entry is router-backed: it runs any model.
|
|
33
31
|
*
|
|
34
32
|
* `nanoclaw` is deliberately absent despite the "claw" name: its runner routes every provider through
|
|
35
33
|
* the Tangle router (canonical model id straight to the gateway), so it is router-backed like
|
|
@@ -47,7 +45,7 @@ export function modelProvider(modelId) {
|
|
|
47
45
|
}
|
|
48
46
|
/** The providers a harness is locked to, or `null` when it is router-backed (any model). */
|
|
49
47
|
export function harnessProviders(harness) {
|
|
50
|
-
return harnessProviderLock[
|
|
48
|
+
return harnessProviderLock[harness] ?? null;
|
|
51
49
|
}
|
|
52
50
|
/**
|
|
53
51
|
* Whether a harness can run a model. Router-backed harnesses (no provider lock) accept anything;
|
|
@@ -76,7 +74,7 @@ export function preferredHarnessForModel(modelId) {
|
|
|
76
74
|
/**
|
|
77
75
|
* Per-harness ranking patterns for {@link snapModelToHarness}, best first; within one pattern the
|
|
78
76
|
* highest version wins (numeric-aware). Only vendor-locked harnesses need an entry — a router-backed
|
|
79
|
-
* harness never snaps (it runs the model as-is).
|
|
77
|
+
* harness never snaps (it runs the model as-is).
|
|
80
78
|
*/
|
|
81
79
|
const harnessPreferredModelPatterns = {
|
|
82
80
|
"claude-code": [
|
|
@@ -101,7 +99,7 @@ const numericDesc = new Intl.Collator(undefined, {
|
|
|
101
99
|
export function snapModelToHarness(harness, modelId, candidateIds) {
|
|
102
100
|
if (harnessSupportsModel(harness, modelId))
|
|
103
101
|
return modelId;
|
|
104
|
-
const patterns = harnessPreferredModelPatterns[
|
|
102
|
+
const patterns = harnessPreferredModelPatterns[harness] ?? [];
|
|
105
103
|
for (const pattern of patterns) {
|
|
106
104
|
const matches = candidateIds
|
|
107
105
|
.filter((id) => pattern.test(id))
|
|
@@ -164,11 +162,10 @@ const harnessReasoningCeiling = {
|
|
|
164
162
|
/** The reasoning efforts a harness can express, independent of model — its explicit override set, or
|
|
165
163
|
* `none` up to its ceiling (default `ultracode` for router/model-driven harnesses). */
|
|
166
164
|
export function harnessReasoningEfforts(harness) {
|
|
167
|
-
const
|
|
168
|
-
const override = harnessReasoningEffortsOverride[canonical];
|
|
165
|
+
const override = harnessReasoningEffortsOverride[harness];
|
|
169
166
|
if (override)
|
|
170
167
|
return override;
|
|
171
|
-
const ceiling = harnessReasoningCeiling[
|
|
168
|
+
const ceiling = harnessReasoningCeiling[harness] ?? "ultracode";
|
|
172
169
|
return reasoningLadder.slice(0, reasoningLadder.indexOf(ceiling) + 1);
|
|
173
170
|
}
|
|
174
171
|
/**
|
|
@@ -191,7 +188,7 @@ export function reasoningEffortsFor(harness, model) {
|
|
|
191
188
|
/**
|
|
192
189
|
* Harnesses whose runner DROPS a per-turn selector — grounded in the cli-bridge adapter audit, NOT a
|
|
193
190
|
* guess. Most harnesses honor both selectors, so only the exceptions are listed; a harness absent from
|
|
194
|
-
* a set honors that selector.
|
|
191
|
+
* a set honors that selector.
|
|
195
192
|
*
|
|
196
193
|
* - model dropped: `amp` (own agent picks the model), `openclaw` (dispatcher routes by its own
|
|
197
194
|
* config), `nanoclaw` (socket-bridge runner is config/env-driven).
|
|
@@ -215,11 +212,11 @@ const harnessIgnoresEffort = new Set([
|
|
|
215
212
|
]);
|
|
216
213
|
/** Whether the harness's runner honors a per-turn MODEL override (vs. picking the model itself). */
|
|
217
214
|
export function harnessHonorsModel(harness) {
|
|
218
|
-
return !harnessIgnoresModel.has(
|
|
215
|
+
return !harnessIgnoresModel.has(harness);
|
|
219
216
|
}
|
|
220
217
|
/** Whether the harness's runner honors a reasoning-EFFORT override (vs. dropping it). */
|
|
221
218
|
export function harnessHonorsEffort(harness) {
|
|
222
|
-
return !harnessIgnoresEffort.has(
|
|
219
|
+
return !harnessIgnoresEffort.has(harness);
|
|
223
220
|
}
|
|
224
221
|
/** Whether the harness honors BOTH chat selectors — i.e. the model and effort pickers are live. */
|
|
225
222
|
export function harnessHonorsSelectors(harness) {
|
package/dist/harness.d.ts
CHANGED
|
@@ -14,20 +14,15 @@ import { z } from "zod";
|
|
|
14
14
|
* a one-shot) with no full coding-agent harness. The rest are full agentic harnesses run in a
|
|
15
15
|
* sandbox or locally via the CLI bridge.
|
|
16
16
|
*
|
|
17
|
-
* Some values are input aliases that collapse to a base runner (`claude`/`claudish` → `claude-code`,
|
|
18
|
-
* `kimi` → `kimi-code`); normalize with {@link canonicalizeHarness} before keying per-runner config.
|
|
19
17
|
*/
|
|
20
|
-
export type HarnessType = "claude-code" | "
|
|
18
|
+
export type HarnessType = "claude-code" | "nanoclaw" | "codex" | "opencode" | "kimi-code" | "pi" | "gemini" | "hermes" | "openclaw" | "amp" | "factory-droids" | "acp" | "cli-base";
|
|
21
19
|
/** Runtime validator for {@link HarnessType}. Kept in lockstep with the type by the drift guard below. */
|
|
22
20
|
export declare const harnessTypeSchema: z.ZodEnum<{
|
|
23
21
|
"claude-code": "claude-code";
|
|
24
|
-
claude: "claude";
|
|
25
|
-
claudish: "claudish";
|
|
26
22
|
nanoclaw: "nanoclaw";
|
|
27
23
|
codex: "codex";
|
|
28
24
|
opencode: "opencode";
|
|
29
25
|
"kimi-code": "kimi-code";
|
|
30
|
-
kimi: "kimi";
|
|
31
26
|
pi: "pi";
|
|
32
27
|
gemini: "gemini";
|
|
33
28
|
hermes: "hermes";
|
|
@@ -37,7 +32,3 @@ export declare const harnessTypeSchema: z.ZodEnum<{
|
|
|
37
32
|
acp: "acp";
|
|
38
33
|
"cli-base": "cli-base";
|
|
39
34
|
}>;
|
|
40
|
-
/** Input alias → canonical base runner. Aliases accept legacy/shorthand harness names. */
|
|
41
|
-
export declare const harnessAliases: Partial<Record<HarnessType, HarnessType>>;
|
|
42
|
-
/** Collapse an alias to its base runner (idempotent on canonical values). */
|
|
43
|
-
export declare function canonicalizeHarness(harness: HarnessType): HarnessType;
|
package/dist/harness.js
CHANGED
|
@@ -2,13 +2,10 @@ import { z } from "zod";
|
|
|
2
2
|
/** Runtime validator for {@link HarnessType}. Kept in lockstep with the type by the drift guard below. */
|
|
3
3
|
export const harnessTypeSchema = z.enum([
|
|
4
4
|
"claude-code",
|
|
5
|
-
"claude",
|
|
6
|
-
"claudish",
|
|
7
5
|
"nanoclaw",
|
|
8
6
|
"codex",
|
|
9
7
|
"opencode",
|
|
10
8
|
"kimi-code",
|
|
11
|
-
"kimi",
|
|
12
9
|
"pi",
|
|
13
10
|
"gemini",
|
|
14
11
|
"hermes",
|
|
@@ -18,15 +15,5 @@ export const harnessTypeSchema = z.enum([
|
|
|
18
15
|
"acp",
|
|
19
16
|
"cli-base",
|
|
20
17
|
]);
|
|
21
|
-
/** Input alias → canonical base runner. Aliases accept legacy/shorthand harness names. */
|
|
22
|
-
export const harnessAliases = {
|
|
23
|
-
claude: "claude-code",
|
|
24
|
-
claudish: "claude-code",
|
|
25
|
-
kimi: "kimi-code",
|
|
26
|
-
};
|
|
27
|
-
/** Collapse an alias to its base runner (idempotent on canonical values). */
|
|
28
|
-
export function canonicalizeHarness(harness) {
|
|
29
|
-
return harnessAliases[harness] ?? harness;
|
|
30
|
-
}
|
|
31
18
|
const _harnessSchemaMatchesType = true;
|
|
32
19
|
void _harnessSchemaMatchesType;
|
package/dist/index.d.ts
CHANGED
|
@@ -157,7 +157,7 @@ export declare function normalizeInputParts(input: {
|
|
|
157
157
|
export declare function renderInputPartsAsText(parts: InputPart[]): string;
|
|
158
158
|
/**
|
|
159
159
|
* The primary event for all part updates from OpenCode.
|
|
160
|
-
* This is the canonical event
|
|
160
|
+
* This is the canonical event for all part updates.
|
|
161
161
|
*/
|
|
162
162
|
export type MessagePartUpdatedEvent = {
|
|
163
163
|
type: "message.part.updated";
|
|
@@ -613,7 +613,14 @@ export interface SdkProviderAdapter {
|
|
|
613
613
|
export * from "./interaction.js";
|
|
614
614
|
export * from "./agent-candidate.js";
|
|
615
615
|
export * from "./agent-candidate-schema.js";
|
|
616
|
+
export type { Sha256Digest } from "./agent-candidate.js";
|
|
617
|
+
export { canonicalCandidateBytes, canonicalCandidateDigest, canonicalCandidateJson, sha256Bytes, sha256DigestSchema, sha256Utf8, } from "./agent-candidate-schema-common.js";
|
|
616
618
|
export * from "./agent-candidate-promotion-schema.js";
|
|
619
|
+
export { agentCandidateEvaluationPolicySchema } from "./agent-improvement-measurement-schema.js";
|
|
620
|
+
export * from "./agent-improvement-source.js";
|
|
621
|
+
export * from "./agent-profile-improvement.js";
|
|
622
|
+
export * from "./agent-profile-improvement-schema.js";
|
|
623
|
+
export * from "./agent-execution-limits.js";
|
|
617
624
|
export * from "./agent-profile.js";
|
|
618
625
|
export * from "./certified-context.js";
|
|
619
626
|
export * from "./profile-diff.js";
|
package/dist/index.js
CHANGED
|
@@ -126,7 +126,13 @@ export function resolveNativeWebTools(tools) {
|
|
|
126
126
|
export * from "./interaction.js";
|
|
127
127
|
export * from "./agent-candidate.js";
|
|
128
128
|
export * from "./agent-candidate-schema.js";
|
|
129
|
+
export { canonicalCandidateBytes, canonicalCandidateDigest, canonicalCandidateJson, sha256Bytes, sha256DigestSchema, sha256Utf8, } from "./agent-candidate-schema-common.js";
|
|
129
130
|
export * from "./agent-candidate-promotion-schema.js";
|
|
131
|
+
export { agentCandidateEvaluationPolicySchema } from "./agent-improvement-measurement-schema.js";
|
|
132
|
+
export * from "./agent-improvement-source.js";
|
|
133
|
+
export * from "./agent-profile-improvement.js";
|
|
134
|
+
export * from "./agent-profile-improvement-schema.js";
|
|
135
|
+
export * from "./agent-execution-limits.js";
|
|
130
136
|
export * from "./agent-profile.js";
|
|
131
137
|
export * from "./certified-context.js";
|
|
132
138
|
export * from "./profile-diff.js";
|
package/dist/interaction.d.ts
CHANGED
|
@@ -256,23 +256,6 @@ export type PermissionGrant = z.infer<typeof PermissionGrantSchema>;
|
|
|
256
256
|
export declare function permissionAnswerSpec(opts?: {
|
|
257
257
|
allowFeedback?: boolean;
|
|
258
258
|
}): InteractionAnswerSpec;
|
|
259
|
-
/** Shape of one legacy question (kept for the back-compat shim). */
|
|
260
|
-
export type LegacyQuestion = {
|
|
261
|
-
question: string;
|
|
262
|
-
options?: Array<{
|
|
263
|
-
label: string;
|
|
264
|
-
description?: string;
|
|
265
|
-
}>;
|
|
266
|
-
multiSelect?: boolean;
|
|
267
|
-
/** When true the select field accepts write-in answers beyond `options`. */
|
|
268
|
-
allowCustom?: boolean;
|
|
269
|
-
};
|
|
270
|
-
/**
|
|
271
|
-
* Build an answer spec from the legacy `question` event shape. Each question
|
|
272
|
-
* becomes one select field (free text when it declares no options), so the old
|
|
273
|
-
* question/answer path is expressible as a `question` interaction.
|
|
274
|
-
*/
|
|
275
|
-
export declare function questionAnswerSpec(questions: LegacyQuestion[]): InteractionAnswerSpec;
|
|
276
259
|
export type InteractionValidation = {
|
|
277
260
|
ok: true;
|
|
278
261
|
} | {
|
package/dist/interaction.js
CHANGED
|
@@ -176,29 +176,6 @@ export function permissionAnswerSpec(opts) {
|
|
|
176
176
|
}
|
|
177
177
|
return { fields };
|
|
178
178
|
}
|
|
179
|
-
/**
|
|
180
|
-
* Build an answer spec from the legacy `question` event shape. Each question
|
|
181
|
-
* becomes one select field (free text when it declares no options), so the old
|
|
182
|
-
* question/answer path is expressible as a `question` interaction.
|
|
183
|
-
*/
|
|
184
|
-
export function questionAnswerSpec(questions) {
|
|
185
|
-
const fields = questions.map((q, i) => {
|
|
186
|
-
const name = `q${i}`;
|
|
187
|
-
if (q.options && q.options.length > 0) {
|
|
188
|
-
return {
|
|
189
|
-
type: "select",
|
|
190
|
-
name,
|
|
191
|
-
label: q.question,
|
|
192
|
-
required: true,
|
|
193
|
-
multi: q.multiSelect === true,
|
|
194
|
-
...(q.allowCustom === true ? { allowCustom: true } : {}),
|
|
195
|
-
options: q.options.map((o) => ({ value: o.label, label: o.label, description: o.description })),
|
|
196
|
-
};
|
|
197
|
-
}
|
|
198
|
-
return { type: "text", name, label: q.question, required: true };
|
|
199
|
-
});
|
|
200
|
-
return { fields };
|
|
201
|
-
}
|
|
202
179
|
/**
|
|
203
180
|
* Validate an accepted answer against its spec. Used by the broker before a
|
|
204
181
|
* response reaches the adapter, so malformed answers are rejected centrally.
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function numbersApproximatelyEqual(left: number, right: number): boolean;
|
package/dist/profile-schema.d.ts
CHANGED
|
@@ -268,13 +268,10 @@ export declare const agentProfileSchema: z.ZodObject<{
|
|
|
268
268
|
}, z.core.$strict>>;
|
|
269
269
|
harness: z.ZodOptional<z.ZodEnum<{
|
|
270
270
|
"claude-code": "claude-code";
|
|
271
|
-
claude: "claude";
|
|
272
|
-
claudish: "claudish";
|
|
273
271
|
nanoclaw: "nanoclaw";
|
|
274
272
|
codex: "codex";
|
|
275
273
|
opencode: "opencode";
|
|
276
274
|
"kimi-code": "kimi-code";
|
|
277
|
-
kimi: "kimi";
|
|
278
275
|
pi: "pi";
|
|
279
276
|
gemini: "gemini";
|
|
280
277
|
hermes: "hermes";
|