@tangle-network/agent-interface 5.10.23 → 5.10.25
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 +30 -0
- package/dist/agent-candidate-code-schema.d.ts +7 -7
- package/dist/agent-candidate-execution-plan-schema.d.ts +21 -21
- package/dist/agent-candidate-profile-schema.d.ts +4 -4
- package/dist/agent-candidate-promotion-schema.d.ts +155 -80
- package/dist/agent-candidate-receipt-schema.d.ts +10 -10
- package/dist/agent-candidate-schema-common.d.ts +3 -3
- package/dist/agent-candidate-schema.d.ts +5 -5
- package/dist/agent-execution-preparation-receipt.d.ts +4 -2
- 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/agent-profile-materialization.d.ts +1 -1
- package/dist/agent-profile-materialization.js +3 -0
- package/dist/agent-profile.d.ts +3 -0
- package/dist/agent-profile.js +0 -13
- package/dist/environment-interactive-control.d.ts +20 -10
- package/dist/environment-interactive-start.d.ts +6 -2
- package/dist/environment-observation.d.ts +3 -3
- package/dist/environment-provider.d.ts +1 -0
- package/dist/environment-provider.js +1 -0
- package/dist/environment-retained-file.d.ts +124 -0
- package/dist/environment-retained-file.js +37 -0
- package/dist/environment-runtime.d.ts +23 -6
- package/dist/environment-runtime.js +1 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +1 -0
- package/dist/portable-context-transfer.d.ts +6 -2
- package/dist/profile-diff.d.ts +2 -1
- package/dist/profile-diff.js +3 -0
- package/dist/profile-file-output.d.ts +10 -0
- package/dist/profile-file-output.js +8 -0
- package/dist/profile-schema.d.ts +15 -10
- package/dist/profile-schema.js +3 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -77,6 +77,16 @@ Use the host base for CLI Bridge native process paths.
|
|
|
77
77
|
|
|
78
78
|
## Durable runs, interactions, and context
|
|
79
79
|
|
|
80
|
+
An environment may expose `retainFileOutput` and advertise `workspace.retainFileOutput`.
|
|
81
|
+
An authored `AgentProfile.outputFile` selects that output for one profile; it is part of the strict profile schema and canonical profile digest.
|
|
82
|
+
Runtime resolves the policy before provider materialization; other profiles keep their existing output mode.
|
|
83
|
+
Its request binds one canonical managed-workspace-relative path to the exact admitted control reference.
|
|
84
|
+
A published result identifies the stopped source, immutable preserved regular file, raw byte length and SHA-256,
|
|
85
|
+
with the actual provider-owned publication receipt in `providerReference`.
|
|
86
|
+
That reference grants no access: the provider's authorized reader must validate its own receipt and read the selected revision to EOF.
|
|
87
|
+
An unavailable result is an evidence gap, never a quality verdict or permission to read a later file.
|
|
88
|
+
Empty regular files have length zero; they are distinct from absent delivery.
|
|
89
|
+
|
|
80
90
|
`AgentTurnInput.profile` carries the exact `AgentProfile` for a turn through its canonical schema.
|
|
81
91
|
Keep mounted resources and behavior in this typed field, separate from bounded `providerOptions` metadata.
|
|
82
92
|
Providers must honor the profile or refuse it before dispatch; callers must not assume every provider supports per-turn profile changes.
|
|
@@ -432,3 +442,23 @@ confer access. Hosts unable to resolve the saved pins must fail closed rather th
|
|
|
432
442
|
inline JSON into instructions, substitute a newer generation or silently omit them.
|
|
433
443
|
|
|
434
444
|
Profile collection admission uses the shared [contract limits](src/contract-limits.ts) before parsing elements or encoding record keys. Training receipts and knowledge references retain their own typed limits in [the profile schema](src/profile-schema.ts). Opaque metadata is admitted and detached by value as bounded portable data; accessors are refused and cross-key object identity is not preserved. Snapshot validation precedes the final detached copy, preserving explicit undefined fields, canonical hashes and nested isolation. The generic serialized-JSON byte bound is not a whole-profile transport limit.
|
|
445
|
+
|
|
446
|
+
## Profile experiment model and accounting evidence
|
|
447
|
+
|
|
448
|
+
Profile experiments keep their legacy fixed task model unless `modelBinding`
|
|
449
|
+
explicitly selects `profile-default`. That policy binds static authored model
|
|
450
|
+
hints and an exact resolved model/snapshot for each arm. The original task model
|
|
451
|
+
must match the baseline. Schema and Eval share
|
|
452
|
+
`agentProfileImprovementExpectedModel()`; the source-owning executor passes its
|
|
453
|
+
actual profile to that helper and independently observes the returned identity
|
|
454
|
+
for each run. Contradictory defaults, routing/fallback hints and unsupported
|
|
455
|
+
dynamic values refuse. A configured model string alone is not served evidence.
|
|
456
|
+
|
|
457
|
+
Complete profile run receipts and shared `AgentCandidateFixedSpend` remain
|
|
458
|
+
strict. The opt-in `AgentProfileImprovementRecordedRunReceipt` uses the same
|
|
459
|
+
receipt and evidence identities, with a profile-only unavailable accounting
|
|
460
|
+
branch for execution or grading. Every required counter/cost is an explicit
|
|
461
|
+
known value or null, with a reason. `agentProfileImprovementRecordedRunReceiptSchema`
|
|
462
|
+
retains these records; complete comparison/proposal schemas refuse them. An
|
|
463
|
+
unknown amount is neither observed nor estimated zero. Raw native facts outside
|
|
464
|
+
the fixed-spend counters remain in the authoritative evidence references.
|
|
@@ -105,8 +105,8 @@ export declare const agentCandidateContainerLaunchSchema: z.ZodObject<{
|
|
|
105
105
|
kind: z.ZodLiteral<"secret-ref">;
|
|
106
106
|
key: z.ZodString;
|
|
107
107
|
format: z.ZodOptional<z.ZodEnum<{
|
|
108
|
-
raw: "raw";
|
|
109
108
|
bearer: "bearer";
|
|
109
|
+
raw: "raw";
|
|
110
110
|
}>>;
|
|
111
111
|
}, z.core.$strict>], "kind">>>;
|
|
112
112
|
}, z.core.$strict>;
|
|
@@ -129,8 +129,8 @@ export declare const agentCandidateEntrypointLaunchSchema: z.ZodObject<{
|
|
|
129
129
|
kind: z.ZodLiteral<"secret-ref">;
|
|
130
130
|
key: z.ZodString;
|
|
131
131
|
format: z.ZodOptional<z.ZodEnum<{
|
|
132
|
-
raw: "raw";
|
|
133
132
|
bearer: "bearer";
|
|
133
|
+
raw: "raw";
|
|
134
134
|
}>>;
|
|
135
135
|
}, z.core.$strict>], "kind">>>;
|
|
136
136
|
}, z.core.$strict>;
|
|
@@ -144,8 +144,8 @@ export declare const agentCandidateLaunchSchema: z.ZodDiscriminatedUnion<[z.ZodO
|
|
|
144
144
|
kind: z.ZodLiteral<"secret-ref">;
|
|
145
145
|
key: z.ZodString;
|
|
146
146
|
format: z.ZodOptional<z.ZodEnum<{
|
|
147
|
-
raw: "raw";
|
|
148
147
|
bearer: "bearer";
|
|
148
|
+
raw: "raw";
|
|
149
149
|
}>>;
|
|
150
150
|
}, z.core.$strict>], "kind">>>;
|
|
151
151
|
}, z.core.$strict>, z.ZodObject<{
|
|
@@ -167,8 +167,8 @@ export declare const agentCandidateLaunchSchema: z.ZodDiscriminatedUnion<[z.ZodO
|
|
|
167
167
|
kind: z.ZodLiteral<"secret-ref">;
|
|
168
168
|
key: z.ZodString;
|
|
169
169
|
format: z.ZodOptional<z.ZodEnum<{
|
|
170
|
-
raw: "raw";
|
|
171
170
|
bearer: "bearer";
|
|
171
|
+
raw: "raw";
|
|
172
172
|
}>>;
|
|
173
173
|
}, z.core.$strict>], "kind">>>;
|
|
174
174
|
}, z.core.$strict>], "kind">;
|
|
@@ -214,8 +214,8 @@ export declare const agentCandidateExecutionSchema: z.ZodObject<{
|
|
|
214
214
|
kind: z.ZodLiteral<"secret-ref">;
|
|
215
215
|
key: z.ZodString;
|
|
216
216
|
format: z.ZodOptional<z.ZodEnum<{
|
|
217
|
-
raw: "raw";
|
|
218
217
|
bearer: "bearer";
|
|
218
|
+
raw: "raw";
|
|
219
219
|
}>>;
|
|
220
220
|
}, z.core.$strict>], "kind">>>;
|
|
221
221
|
}, z.core.$strict>, z.ZodObject<{
|
|
@@ -237,8 +237,8 @@ export declare const agentCandidateExecutionSchema: z.ZodObject<{
|
|
|
237
237
|
kind: z.ZodLiteral<"secret-ref">;
|
|
238
238
|
key: z.ZodString;
|
|
239
239
|
format: z.ZodOptional<z.ZodEnum<{
|
|
240
|
-
raw: "raw";
|
|
241
240
|
bearer: "bearer";
|
|
241
|
+
raw: "raw";
|
|
242
242
|
}>>;
|
|
243
243
|
}, z.core.$strict>], "kind">>>;
|
|
244
244
|
}, z.core.$strict>], "kind">;
|
|
@@ -265,8 +265,8 @@ export declare const agentCandidateExecutionSchema: z.ZodObject<{
|
|
|
265
265
|
kind: z.ZodLiteral<"secret-ref">;
|
|
266
266
|
key: z.ZodString;
|
|
267
267
|
format: z.ZodOptional<z.ZodEnum<{
|
|
268
|
-
raw: "raw";
|
|
269
268
|
bearer: "bearer";
|
|
269
|
+
raw: "raw";
|
|
270
270
|
}>>;
|
|
271
271
|
}, z.core.$strict>], "kind">>>;
|
|
272
272
|
environment: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
@@ -124,8 +124,8 @@ export declare const agentCandidateProfilePlanMaterialSchema: z.ZodObject<{
|
|
|
124
124
|
kind: z.ZodLiteral<"secret-ref">;
|
|
125
125
|
key: z.ZodString;
|
|
126
126
|
format: z.ZodOptional<z.ZodEnum<{
|
|
127
|
-
raw: "raw";
|
|
128
127
|
bearer: "bearer";
|
|
128
|
+
raw: "raw";
|
|
129
129
|
}>>;
|
|
130
130
|
}, z.core.$strict>;
|
|
131
131
|
}, z.core.$strict>>>;
|
|
@@ -138,8 +138,8 @@ export declare const agentCandidateProfilePlanMaterialSchema: z.ZodObject<{
|
|
|
138
138
|
kind: z.ZodLiteral<"secret-ref">;
|
|
139
139
|
key: z.ZodString;
|
|
140
140
|
format: z.ZodOptional<z.ZodEnum<{
|
|
141
|
-
raw: "raw";
|
|
142
141
|
bearer: "bearer";
|
|
142
|
+
raw: "raw";
|
|
143
143
|
}>>;
|
|
144
144
|
}, z.core.$strict>], "kind">>;
|
|
145
145
|
flags: z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
@@ -149,8 +149,8 @@ export declare const agentCandidateProfilePlanMaterialSchema: z.ZodObject<{
|
|
|
149
149
|
kind: z.ZodLiteral<"secret-ref">;
|
|
150
150
|
key: z.ZodString;
|
|
151
151
|
format: z.ZodOptional<z.ZodEnum<{
|
|
152
|
-
raw: "raw";
|
|
153
152
|
bearer: "bearer";
|
|
153
|
+
raw: "raw";
|
|
154
154
|
}>>;
|
|
155
155
|
}, z.core.$strict>], "kind">>;
|
|
156
156
|
systemPrompt: z.ZodOptional<z.ZodObject<{
|
|
@@ -513,8 +513,8 @@ export declare const agentCandidateExecutionPlanMaterialSchema: z.ZodObject<{
|
|
|
513
513
|
kind: z.ZodLiteral<"secret-ref">;
|
|
514
514
|
key: z.ZodString;
|
|
515
515
|
format: z.ZodOptional<z.ZodEnum<{
|
|
516
|
-
raw: "raw";
|
|
517
516
|
bearer: "bearer";
|
|
517
|
+
raw: "raw";
|
|
518
518
|
}>>;
|
|
519
519
|
}, z.core.$strict>], "kind">>;
|
|
520
520
|
env: z.ZodRecord<z.ZodString, z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
@@ -524,8 +524,8 @@ export declare const agentCandidateExecutionPlanMaterialSchema: z.ZodObject<{
|
|
|
524
524
|
kind: z.ZodLiteral<"secret-ref">;
|
|
525
525
|
key: z.ZodString;
|
|
526
526
|
format: z.ZodOptional<z.ZodEnum<{
|
|
527
|
-
raw: "raw";
|
|
528
527
|
bearer: "bearer";
|
|
528
|
+
raw: "raw";
|
|
529
529
|
}>>;
|
|
530
530
|
}, z.core.$strict>], "kind">>;
|
|
531
531
|
cwd: z.ZodObject<{
|
|
@@ -650,7 +650,7 @@ export declare const agentCandidateProfilePlanEvidenceSchema: z.ZodObject<{
|
|
|
650
650
|
ref: {
|
|
651
651
|
kind: "secret-ref";
|
|
652
652
|
key: string;
|
|
653
|
-
format?: "
|
|
653
|
+
format?: "bearer" | "raw" | undefined;
|
|
654
654
|
};
|
|
655
655
|
}[] | undefined;
|
|
656
656
|
root?: "agent" | undefined;
|
|
@@ -658,7 +658,7 @@ export declare const agentCandidateProfilePlanEvidenceSchema: z.ZodObject<{
|
|
|
658
658
|
env: Record<string, {
|
|
659
659
|
kind: "secret-ref";
|
|
660
660
|
key: string;
|
|
661
|
-
format?: "
|
|
661
|
+
format?: "bearer" | "raw" | undefined;
|
|
662
662
|
} | {
|
|
663
663
|
kind: "public";
|
|
664
664
|
value: string;
|
|
@@ -666,7 +666,7 @@ export declare const agentCandidateProfilePlanEvidenceSchema: z.ZodObject<{
|
|
|
666
666
|
flags: ({
|
|
667
667
|
kind: "secret-ref";
|
|
668
668
|
key: string;
|
|
669
|
-
format?: "
|
|
669
|
+
format?: "bearer" | "raw" | undefined;
|
|
670
670
|
} | {
|
|
671
671
|
kind: "public";
|
|
672
672
|
value: string;
|
|
@@ -719,7 +719,7 @@ export declare const agentCandidateProfilePlanEvidenceSchema: z.ZodObject<{
|
|
|
719
719
|
ref: {
|
|
720
720
|
kind: "secret-ref";
|
|
721
721
|
key: string;
|
|
722
|
-
format?: "
|
|
722
|
+
format?: "bearer" | "raw" | undefined;
|
|
723
723
|
};
|
|
724
724
|
}[] | undefined;
|
|
725
725
|
root?: "agent" | undefined;
|
|
@@ -727,7 +727,7 @@ export declare const agentCandidateProfilePlanEvidenceSchema: z.ZodObject<{
|
|
|
727
727
|
env: Record<string, {
|
|
728
728
|
kind: "secret-ref";
|
|
729
729
|
key: string;
|
|
730
|
-
format?: "
|
|
730
|
+
format?: "bearer" | "raw" | undefined;
|
|
731
731
|
} | {
|
|
732
732
|
kind: "public";
|
|
733
733
|
value: string;
|
|
@@ -735,7 +735,7 @@ export declare const agentCandidateProfilePlanEvidenceSchema: z.ZodObject<{
|
|
|
735
735
|
flags: ({
|
|
736
736
|
kind: "secret-ref";
|
|
737
737
|
key: string;
|
|
738
|
-
format?: "
|
|
738
|
+
format?: "bearer" | "raw" | undefined;
|
|
739
739
|
} | {
|
|
740
740
|
kind: "public";
|
|
741
741
|
value: string;
|
|
@@ -817,7 +817,7 @@ export declare const agentCandidateProfileActivationSchema: z.ZodObject<{
|
|
|
817
817
|
ref: {
|
|
818
818
|
kind: "secret-ref";
|
|
819
819
|
key: string;
|
|
820
|
-
format?: "
|
|
820
|
+
format?: "bearer" | "raw" | undefined;
|
|
821
821
|
};
|
|
822
822
|
}[] | undefined;
|
|
823
823
|
root?: "agent" | undefined;
|
|
@@ -825,7 +825,7 @@ export declare const agentCandidateProfileActivationSchema: z.ZodObject<{
|
|
|
825
825
|
env: Record<string, {
|
|
826
826
|
kind: "secret-ref";
|
|
827
827
|
key: string;
|
|
828
|
-
format?: "
|
|
828
|
+
format?: "bearer" | "raw" | undefined;
|
|
829
829
|
} | {
|
|
830
830
|
kind: "public";
|
|
831
831
|
value: string;
|
|
@@ -833,7 +833,7 @@ export declare const agentCandidateProfileActivationSchema: z.ZodObject<{
|
|
|
833
833
|
flags: ({
|
|
834
834
|
kind: "secret-ref";
|
|
835
835
|
key: string;
|
|
836
|
-
format?: "
|
|
836
|
+
format?: "bearer" | "raw" | undefined;
|
|
837
837
|
} | {
|
|
838
838
|
kind: "public";
|
|
839
839
|
value: string;
|
|
@@ -913,7 +913,7 @@ export declare const agentCandidateProfileActivationSchema: z.ZodObject<{
|
|
|
913
913
|
ref: {
|
|
914
914
|
kind: "secret-ref";
|
|
915
915
|
key: string;
|
|
916
|
-
format?: "
|
|
916
|
+
format?: "bearer" | "raw" | undefined;
|
|
917
917
|
};
|
|
918
918
|
}[] | undefined;
|
|
919
919
|
root?: "agent" | undefined;
|
|
@@ -921,7 +921,7 @@ export declare const agentCandidateProfileActivationSchema: z.ZodObject<{
|
|
|
921
921
|
env: Record<string, {
|
|
922
922
|
kind: "secret-ref";
|
|
923
923
|
key: string;
|
|
924
|
-
format?: "
|
|
924
|
+
format?: "bearer" | "raw" | undefined;
|
|
925
925
|
} | {
|
|
926
926
|
kind: "public";
|
|
927
927
|
value: string;
|
|
@@ -929,7 +929,7 @@ export declare const agentCandidateProfileActivationSchema: z.ZodObject<{
|
|
|
929
929
|
flags: ({
|
|
930
930
|
kind: "secret-ref";
|
|
931
931
|
key: string;
|
|
932
|
-
format?: "
|
|
932
|
+
format?: "bearer" | "raw" | undefined;
|
|
933
933
|
} | {
|
|
934
934
|
kind: "public";
|
|
935
935
|
value: string;
|
|
@@ -1103,7 +1103,7 @@ export declare const agentCandidateExecutionPlanEvidenceSchema: z.ZodObject<{
|
|
|
1103
1103
|
args: ({
|
|
1104
1104
|
kind: "secret-ref";
|
|
1105
1105
|
key: string;
|
|
1106
|
-
format?: "
|
|
1106
|
+
format?: "bearer" | "raw" | undefined;
|
|
1107
1107
|
} | {
|
|
1108
1108
|
kind: "public";
|
|
1109
1109
|
value: string;
|
|
@@ -1111,7 +1111,7 @@ export declare const agentCandidateExecutionPlanEvidenceSchema: z.ZodObject<{
|
|
|
1111
1111
|
env: Record<string, {
|
|
1112
1112
|
kind: "secret-ref";
|
|
1113
1113
|
key: string;
|
|
1114
|
-
format?: "
|
|
1114
|
+
format?: "bearer" | "raw" | undefined;
|
|
1115
1115
|
} | {
|
|
1116
1116
|
kind: "public";
|
|
1117
1117
|
value: string;
|
|
@@ -1375,7 +1375,7 @@ export declare const agentCandidateExecutionPlanEvidenceSchema: z.ZodObject<{
|
|
|
1375
1375
|
args: ({
|
|
1376
1376
|
kind: "secret-ref";
|
|
1377
1377
|
key: string;
|
|
1378
|
-
format?: "
|
|
1378
|
+
format?: "bearer" | "raw" | undefined;
|
|
1379
1379
|
} | {
|
|
1380
1380
|
kind: "public";
|
|
1381
1381
|
value: string;
|
|
@@ -1383,7 +1383,7 @@ export declare const agentCandidateExecutionPlanEvidenceSchema: z.ZodObject<{
|
|
|
1383
1383
|
env: Record<string, {
|
|
1384
1384
|
kind: "secret-ref";
|
|
1385
1385
|
key: string;
|
|
1386
|
-
format?: "
|
|
1386
|
+
format?: "bearer" | "raw" | undefined;
|
|
1387
1387
|
} | {
|
|
1388
1388
|
kind: "public";
|
|
1389
1389
|
value: string;
|
|
@@ -10,8 +10,8 @@ export declare const agentCandidateHookCommandSchema: z.ZodObject<{
|
|
|
10
10
|
kind: z.ZodLiteral<"secret-ref">;
|
|
11
11
|
key: z.ZodString;
|
|
12
12
|
format: z.ZodOptional<z.ZodEnum<{
|
|
13
|
-
raw: "raw";
|
|
14
13
|
bearer: "bearer";
|
|
14
|
+
raw: "raw";
|
|
15
15
|
}>>;
|
|
16
16
|
}, z.core.$strict>], "kind">>>;
|
|
17
17
|
timeoutMs: z.ZodOptional<z.ZodNumber>;
|
|
@@ -24,8 +24,8 @@ export declare const agentCandidateHookCommandSchema: z.ZodObject<{
|
|
|
24
24
|
kind: z.ZodLiteral<"secret-ref">;
|
|
25
25
|
key: z.ZodString;
|
|
26
26
|
format: z.ZodOptional<z.ZodEnum<{
|
|
27
|
-
raw: "raw";
|
|
28
27
|
bearer: "bearer";
|
|
28
|
+
raw: "raw";
|
|
29
29
|
}>>;
|
|
30
30
|
}, z.core.$strict>], "kind">>>;
|
|
31
31
|
}, z.core.$strict>;
|
|
@@ -589,8 +589,8 @@ export declare const agentCandidateProfileSchema: z.ZodObject<{
|
|
|
589
589
|
kind: z.ZodLiteral<"secret-ref">;
|
|
590
590
|
key: z.ZodString;
|
|
591
591
|
format: z.ZodOptional<z.ZodEnum<{
|
|
592
|
-
raw: "raw";
|
|
593
592
|
bearer: "bearer";
|
|
593
|
+
raw: "raw";
|
|
594
594
|
}>>;
|
|
595
595
|
}, z.core.$strict>], "kind">>>;
|
|
596
596
|
timeoutMs: z.ZodOptional<z.ZodNumber>;
|
|
@@ -603,8 +603,8 @@ export declare const agentCandidateProfileSchema: z.ZodObject<{
|
|
|
603
603
|
kind: z.ZodLiteral<"secret-ref">;
|
|
604
604
|
key: z.ZodString;
|
|
605
605
|
format: z.ZodOptional<z.ZodEnum<{
|
|
606
|
-
raw: "raw";
|
|
607
606
|
bearer: "bearer";
|
|
607
|
+
raw: "raw";
|
|
608
608
|
}>>;
|
|
609
609
|
}, z.core.$strict>], "kind">>>;
|
|
610
610
|
}, z.core.$strict>>>>;
|