@miller-tech/uap 1.175.13 → 1.178.1
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/.tsbuildinfo +1 -1
- package/dist/benchmarks/harness-card.d.ts +86 -0
- package/dist/benchmarks/harness-card.d.ts.map +1 -0
- package/dist/benchmarks/harness-card.js +153 -0
- package/dist/benchmarks/harness-card.js.map +1 -0
- package/dist/benchmarks/paired/report.d.ts +15 -0
- package/dist/benchmarks/paired/report.d.ts.map +1 -1
- package/dist/benchmarks/paired/report.js +12 -0
- package/dist/benchmarks/paired/report.js.map +1 -1
- package/dist/benchmarks/paired/types.d.ts +1 -1
- package/dist/bin/cli.js +27 -0
- package/dist/bin/cli.js.map +1 -1
- package/dist/cli/bench.d.ts.map +1 -1
- package/dist/cli/bench.js +64 -3
- package/dist/cli/bench.js.map +1 -1
- package/dist/cli/harness.d.ts +3 -2
- package/dist/cli/harness.d.ts.map +1 -1
- package/dist/cli/harness.js +81 -0
- package/dist/cli/harness.js.map +1 -1
- package/dist/cli/memory.d.ts +7 -1
- package/dist/cli/memory.d.ts.map +1 -1
- package/dist/cli/memory.js +165 -0
- package/dist/cli/memory.js.map +1 -1
- package/dist/cli/policy.d.ts +43 -0
- package/dist/cli/policy.d.ts.map +1 -1
- package/dist/cli/policy.js +80 -27
- package/dist/cli/policy.js.map +1 -1
- package/dist/delivery/agentic-executor.d.ts +76 -2
- package/dist/delivery/agentic-executor.d.ts.map +1 -1
- package/dist/delivery/agentic-executor.js +231 -29
- package/dist/delivery/agentic-executor.js.map +1 -1
- package/dist/delivery/edit-match.d.ts +134 -0
- package/dist/delivery/edit-match.d.ts.map +1 -0
- package/dist/delivery/edit-match.js +331 -0
- package/dist/delivery/edit-match.js.map +1 -0
- package/dist/memory/dynamic-retrieval.d.ts.map +1 -1
- package/dist/memory/dynamic-retrieval.js +57 -0
- package/dist/memory/dynamic-retrieval.js.map +1 -1
- package/dist/memory/reconstruct-ingest.d.ts +88 -0
- package/dist/memory/reconstruct-ingest.d.ts.map +1 -0
- package/dist/memory/reconstruct-ingest.js +165 -0
- package/dist/memory/reconstruct-ingest.js.map +1 -0
- package/dist/memory/reconstruct-store.d.ts +143 -0
- package/dist/memory/reconstruct-store.d.ts.map +1 -0
- package/dist/memory/reconstruct-store.js +312 -0
- package/dist/memory/reconstruct-store.js.map +1 -0
- package/dist/memory/reconstruct.d.ts +272 -0
- package/dist/memory/reconstruct.d.ts.map +1 -0
- package/dist/memory/reconstruct.js +552 -0
- package/dist/memory/reconstruct.js.map +1 -0
- package/dist/policies/schemas/policy.d.ts +2 -2
- package/dist/self-harness/evidence-proposer.d.ts +58 -0
- package/dist/self-harness/evidence-proposer.d.ts.map +1 -0
- package/dist/self-harness/evidence-proposer.js +132 -0
- package/dist/self-harness/evidence-proposer.js.map +1 -0
- package/dist/self-harness/manifest.d.ts +130 -0
- package/dist/self-harness/manifest.d.ts.map +1 -0
- package/dist/self-harness/manifest.js +247 -0
- package/dist/self-harness/manifest.js.map +1 -0
- package/dist/self-harness/mods.d.ts +57 -3
- package/dist/self-harness/mods.d.ts.map +1 -1
- package/dist/self-harness/mods.js +72 -0
- package/dist/self-harness/mods.js.map +1 -1
- package/dist/self-harness/orchestrator.d.ts +27 -0
- package/dist/self-harness/orchestrator.d.ts.map +1 -1
- package/dist/self-harness/orchestrator.js +47 -4
- package/dist/self-harness/orchestrator.js.map +1 -1
- package/dist/self-harness/pending.d.ts +17 -3
- package/dist/self-harness/pending.d.ts.map +1 -1
- package/dist/self-harness/pending.js +26 -4
- package/dist/self-harness/pending.js.map +1 -1
- package/dist/self-harness/profile.d.ts +17 -1
- package/dist/self-harness/profile.d.ts.map +1 -1
- package/dist/self-harness/profile.js +11 -4
- package/dist/self-harness/profile.js.map +1 -1
- package/dist/self-harness/run.d.ts +19 -0
- package/dist/self-harness/run.d.ts.map +1 -1
- package/dist/self-harness/run.js +43 -4
- package/dist/self-harness/run.js.map +1 -1
- package/dist/self-harness/transfer.d.ts.map +1 -1
- package/dist/self-harness/transfer.js +2 -0
- package/dist/self-harness/transfer.js.map +1 -1
- package/dist/self-harness/validate.d.ts +17 -6
- package/dist/self-harness/validate.d.ts.map +1 -1
- package/dist/self-harness/validate.js +73 -8
- package/dist/self-harness/validate.js.map +1 -1
- package/dist/telemetry/tool-calls.d.ts +82 -0
- package/dist/telemetry/tool-calls.d.ts.map +1 -0
- package/dist/telemetry/tool-calls.js +280 -0
- package/dist/telemetry/tool-calls.js.map +1 -0
- package/dist/telemetry/tool-failure.d.ts +71 -0
- package/dist/telemetry/tool-failure.d.ts.map +1 -0
- package/dist/telemetry/tool-failure.js +123 -0
- package/dist/telemetry/tool-failure.js.map +1 -0
- package/docs/plans/harness-engineering-uplift-2026-07-31.md +280 -0
- package/package.json +1 -1
- package/src/policies/enforcers/__pycache__/_common.cpython-312.pyc +0 -0
- package/templates/hooks/__pycache__/deliver_autoroute.cpython-312.pyc +0 -0
- package/tools/agents/scripts/__pycache__/toolcall_path_normalizer.cpython-312.pyc +0 -0
|
@@ -0,0 +1,132 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Evidence-driven proposer — the D -> B connection (harness plan, 2026-07-31).
|
|
3
|
+
*
|
|
4
|
+
* The plan's load-bearing sequence is D (evidence corpus) THEN B (tool search
|
|
5
|
+
* space): record what the tool layer actually does, then mutate the knobs the
|
|
6
|
+
* evidence implicates. Shipping both halves without this module would leave the
|
|
7
|
+
* corpus written but unread and `ToolMod` defined but never emitted — a search
|
|
8
|
+
* space with nothing searching it.
|
|
9
|
+
*
|
|
10
|
+
* Unlike `heuristicProposer`, which maps a run-level FailureKind to an
|
|
11
|
+
* inference-server knob, this reads per-tool-call outcomes. That is the level
|
|
12
|
+
* the tool layer fails at: an `edit-miss` never surfaces as a run-level failure
|
|
13
|
+
* kind, it just quietly costs a turn, which is exactly why the loop could not
|
|
14
|
+
* see the surface the literature says matters most (tools +3.3pp, arXiv
|
|
15
|
+
* 2604.25850).
|
|
16
|
+
*
|
|
17
|
+
* Every proposal is a HYPOTHESIS with a measurable prediction, not a fix. The
|
|
18
|
+
* paired validator decides, and the change manifest falsifies it next round.
|
|
19
|
+
*/
|
|
20
|
+
import { TOOL_KNOB_ALLOWLIST, validateMod } from './mods.js';
|
|
21
|
+
import { summarizeToolCalls } from '../telemetry/tool-calls.js';
|
|
22
|
+
/** Read a tool knob's in-effect value: profile first, then env, then default. */
|
|
23
|
+
function currentToolKnob(profile, key, fallback) {
|
|
24
|
+
const fromProfile = (profile.tool ?? {})[key];
|
|
25
|
+
if (fromProfile != null)
|
|
26
|
+
return fromProfile;
|
|
27
|
+
return process.env[key] ?? fallback;
|
|
28
|
+
}
|
|
29
|
+
function toolMod(profile, key, to) {
|
|
30
|
+
const spec = TOOL_KNOB_ALLOWLIST[key];
|
|
31
|
+
const from = currentToolKnob(profile, key, spec.type === 'number' ? '' : '1');
|
|
32
|
+
if (from === to)
|
|
33
|
+
return null;
|
|
34
|
+
const mod = { kind: 'tool', key, from, to };
|
|
35
|
+
return validateMod(mod).ok ? mod : null;
|
|
36
|
+
}
|
|
37
|
+
/**
|
|
38
|
+
* Propose tool-layer Mods from the evidence corpus.
|
|
39
|
+
*
|
|
40
|
+
* `summary` is injected so this is testable without a database, and so a caller
|
|
41
|
+
* can scope it to one run.
|
|
42
|
+
*/
|
|
43
|
+
export function proposeFromEvidence(summary, profile, thresholds = {}) {
|
|
44
|
+
const minAttempts = thresholds.minEditAttempts ?? 10;
|
|
45
|
+
const successFloor = thresholds.editSuccessFloor ?? 0.8;
|
|
46
|
+
const tolerantCeiling = thresholds.tolerantShareCeiling ?? 0.3;
|
|
47
|
+
const out = [];
|
|
48
|
+
const e = summary.editHealth;
|
|
49
|
+
if (e.attempts < minAttempts)
|
|
50
|
+
return out; // not enough evidence to act on
|
|
51
|
+
const tolerantShare = e.tolerant / e.attempts;
|
|
52
|
+
// Signal 1 — anchors miss outright. The model's picture of the file is stale,
|
|
53
|
+
// which a bigger read window may fix and tolerance certainly does not.
|
|
54
|
+
if (e.successRate < successFloor && e.misses > 0) {
|
|
55
|
+
const cur = Number(currentToolKnob(profile, 'UAP_READ_WINDOW_BYTES', '8000'));
|
|
56
|
+
if (Number.isFinite(cur)) {
|
|
57
|
+
const next = Math.min(32_000, Math.round(cur * 2));
|
|
58
|
+
const mod = toolMod(profile, 'UAP_READ_WINDOW_BYTES', String(next));
|
|
59
|
+
if (mod)
|
|
60
|
+
out.push(mod);
|
|
61
|
+
}
|
|
62
|
+
// Diagnostics OFF is the counter-hypothesis worth testing when misses
|
|
63
|
+
// dominate: the nearest-region report costs context on every miss, and if it
|
|
64
|
+
// is not converting misses into successes it is pure overhead.
|
|
65
|
+
if (e.misses > e.attempts * 0.4) {
|
|
66
|
+
const mod = toolMod(profile, 'UAP_EDIT_DIAGNOSTICS', '0');
|
|
67
|
+
if (mod)
|
|
68
|
+
out.push(mod);
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
// Signal 2 — a large share of edits land ONLY through tolerance. That is a
|
|
72
|
+
// success today, but it means the model is routinely wrong about the file, so
|
|
73
|
+
// it is worth measuring whether tolerance is rescuing real edits or masking
|
|
74
|
+
// drift that produces subtly wrong ones.
|
|
75
|
+
if (tolerantShare > tolerantCeiling) {
|
|
76
|
+
const mod = toolMod(profile, 'UAP_EDIT_TOLERANT', '0');
|
|
77
|
+
if (mod)
|
|
78
|
+
out.push(mod);
|
|
79
|
+
}
|
|
80
|
+
// Signal 3 — the loop is running out of turns rather than failing on tools.
|
|
81
|
+
const roundsPressure = summary.topFailures.some((f) => f.outcome === 'timeout');
|
|
82
|
+
if (roundsPressure) {
|
|
83
|
+
const cur = Number(currentToolKnob(profile, 'UAP_MAX_TOOL_ROUNDS', '12'));
|
|
84
|
+
if (Number.isFinite(cur)) {
|
|
85
|
+
const mod = toolMod(profile, 'UAP_MAX_TOOL_ROUNDS', String(Math.min(40, Math.round(cur * 1.5))));
|
|
86
|
+
if (mod)
|
|
87
|
+
out.push(mod);
|
|
88
|
+
}
|
|
89
|
+
}
|
|
90
|
+
return out;
|
|
91
|
+
}
|
|
92
|
+
/**
|
|
93
|
+
* A `Proposer` that reads the live corpus.
|
|
94
|
+
*
|
|
95
|
+
* It ignores `weaknesses` by design: those are run-level failure kinds mined
|
|
96
|
+
* from bench records, and this proposer's whole point is the signal that never
|
|
97
|
+
* reaches that level.
|
|
98
|
+
*/
|
|
99
|
+
export function evidenceProposer(opts = {}) {
|
|
100
|
+
return {
|
|
101
|
+
id: 'evidence',
|
|
102
|
+
propose(_weaknesses, profile) {
|
|
103
|
+
const summary = opts.summary ?? summarizeToolCalls(opts.runId);
|
|
104
|
+
return proposeFromEvidence(summary, profile, opts.thresholds);
|
|
105
|
+
},
|
|
106
|
+
};
|
|
107
|
+
}
|
|
108
|
+
/**
|
|
109
|
+
* Run several proposers and concatenate, de-duplicated by structural identity.
|
|
110
|
+
* Lets the loop search the tool layer AND the server layer in one iteration
|
|
111
|
+
* without either proposer knowing about the other.
|
|
112
|
+
*/
|
|
113
|
+
export function combineProposers(id, proposers) {
|
|
114
|
+
return {
|
|
115
|
+
id,
|
|
116
|
+
propose(weaknesses, profile) {
|
|
117
|
+
const seen = new Set();
|
|
118
|
+
const out = [];
|
|
119
|
+
for (const p of proposers) {
|
|
120
|
+
for (const mod of p.propose(weaknesses, profile)) {
|
|
121
|
+
const key = JSON.stringify(mod);
|
|
122
|
+
if (seen.has(key))
|
|
123
|
+
continue;
|
|
124
|
+
seen.add(key);
|
|
125
|
+
out.push(mod);
|
|
126
|
+
}
|
|
127
|
+
}
|
|
128
|
+
return out;
|
|
129
|
+
},
|
|
130
|
+
};
|
|
131
|
+
}
|
|
132
|
+
//# sourceMappingURL=evidence-proposer.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"evidence-proposer.js","sourceRoot":"","sources":["../../src/self-harness/evidence-proposer.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAEH,OAAO,EAAO,m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OAAO;YACzB,MAAM,IAAI,GAAG,IAAI,GAAG,EAAU,CAAC;YAC/B,MAAM,GAAG,GAAU,EAAE,CAAC;YACtB,KAAK,MAAM,CAAC,IAAI,SAAS,EAAE,CAAC;gBAC1B,KAAK,MAAM,GAAG,IAAI,CAAC,CAAC,OAAO,CAAC,UAAU,EAAE,OAAO,CAAC,EAAE,CAAC;oBACjD,MAAM,GAAG,GAAG,IAAI,CAAC,SAAS,CAAC,GAAG,CAAC,CAAC;oBAChC,IAAI,IAAI,CAAC,GAAG,CAAC,GAAG,CAAC;wBAAE,SAAS;oBAC5B,IAAI,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;oBACd,GAAG,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;gBAChB,CAAC;YACH,CAAC;YACD,OAAO,GAAG,CAAC;QACb,CAAC;KACF,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,130 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Change manifests — every harness edit is a falsifiable contract
|
|
3
|
+
* (harness plan area C, 2026-07-31).
|
|
4
|
+
*
|
|
5
|
+
* Agentic Harness Engineering (arXiv 2604.25850) attributes a large part of its
|
|
6
|
+
* Terminal-Bench 2 gain (69.7% -> 77.0%) not to smarter proposals but to
|
|
7
|
+
* DECISION OBSERVABILITY: every edit is paired with a self-declared prediction
|
|
8
|
+
* about which tasks it will fix and which it might break, that prediction is
|
|
9
|
+
* checked against the next round's actual per-task outcomes, and edits whose
|
|
10
|
+
* predictions do not materialise are reverted at file granularity.
|
|
11
|
+
*
|
|
12
|
+
* Without this, an accepted Mod is accepted forever on the strength of one
|
|
13
|
+
* noisy A/B. With it, acceptance is provisional and the loop can un-learn.
|
|
14
|
+
*
|
|
15
|
+
* Everything here is pure except the JSON store at the bottom, so the
|
|
16
|
+
* attribution rules are unit-testable without a bench run.
|
|
17
|
+
*/
|
|
18
|
+
import type { RunRecord } from '../benchmarks/paired/types.js';
|
|
19
|
+
import { Mod } from './mods.js';
|
|
20
|
+
/** A prediction recorded at the moment a Mod is applied. */
|
|
21
|
+
export interface ChangeManifest {
|
|
22
|
+
/** Stable id — `modKey`-derived by the caller, or any unique string. */
|
|
23
|
+
id: string;
|
|
24
|
+
mod: Mod;
|
|
25
|
+
/** ISO timestamp. Injected, never `Date.now()`, so runs stay reproducible. */
|
|
26
|
+
createdAt: string;
|
|
27
|
+
/** Task ids this edit claims it will turn from failing to passing. */
|
|
28
|
+
predictedFixes: string[];
|
|
29
|
+
/** Task ids this edit admits it might break. Declaring them is not a free pass. */
|
|
30
|
+
predictedRisks: string[];
|
|
31
|
+
/**
|
|
32
|
+
* Files/knobs the edit touched, for a file-granular revert. For an env Mod
|
|
33
|
+
* this is the env file; for scaffold/middleware, the component id.
|
|
34
|
+
*/
|
|
35
|
+
touched: string[];
|
|
36
|
+
/** Human-readable summary, for logs and the pending queue. */
|
|
37
|
+
summary: string;
|
|
38
|
+
}
|
|
39
|
+
export interface ManifestAttribution {
|
|
40
|
+
manifestId: string;
|
|
41
|
+
/** Predicted fixes that actually flipped fail -> pass. */
|
|
42
|
+
fixesRealised: string[];
|
|
43
|
+
/** Predicted fixes that did not flip. The falsification. */
|
|
44
|
+
fixesMissed: string[];
|
|
45
|
+
/** Predicted risks that did break (declared, so not a surprise). */
|
|
46
|
+
risksRealised: string[];
|
|
47
|
+
/** Tasks that regressed WITHOUT being declared. The expensive kind. */
|
|
48
|
+
unpredictedRegressions: string[];
|
|
49
|
+
/** Net task delta across the whole suite (passes gained minus lost). */
|
|
50
|
+
netDelta: number;
|
|
51
|
+
}
|
|
52
|
+
export type ManifestVerdict = 'keep' | 'revert';
|
|
53
|
+
export interface ManifestDecision {
|
|
54
|
+
verdict: ManifestVerdict;
|
|
55
|
+
reason: string;
|
|
56
|
+
/** The Mod to apply to undo this change, when the verdict is 'revert'. */
|
|
57
|
+
revert?: Mod;
|
|
58
|
+
}
|
|
59
|
+
/**
|
|
60
|
+
* Check a manifest's prediction against what actually happened.
|
|
61
|
+
*
|
|
62
|
+
* `before` and `after` are the record sets from the round the edit was made and
|
|
63
|
+
* the round after it.
|
|
64
|
+
*/
|
|
65
|
+
export declare function attributeManifest(manifest: ChangeManifest, before: RunRecord[], after: RunRecord[], opts?: {
|
|
66
|
+
condition?: string;
|
|
67
|
+
passRatio?: number;
|
|
68
|
+
}): ManifestAttribution;
|
|
69
|
+
export interface ManifestPolicyOptions {
|
|
70
|
+
/**
|
|
71
|
+
* Revert when an edit predicted fixes and delivered NONE of them, even if the
|
|
72
|
+
* net delta is neutral. Default true — an edit that did not do what it claimed
|
|
73
|
+
* is unexplained behaviour in the harness, and unexplained changes accumulate.
|
|
74
|
+
*/
|
|
75
|
+
revertOnZeroRealised?: boolean;
|
|
76
|
+
/**
|
|
77
|
+
* Tolerated undeclared regressions before an automatic revert. Default 0: the
|
|
78
|
+
* whole point of declaring risks is that undeclared breakage is not tolerated.
|
|
79
|
+
*/
|
|
80
|
+
maxUnpredictedRegressions?: number;
|
|
81
|
+
}
|
|
82
|
+
/**
|
|
83
|
+
* Decide whether a change survives its own prediction.
|
|
84
|
+
*
|
|
85
|
+
* Order matters — undeclared regressions are checked FIRST, because an edit that
|
|
86
|
+
* broke something nobody predicted is disqualified regardless of what else it
|
|
87
|
+
* happened to fix.
|
|
88
|
+
*/
|
|
89
|
+
export declare function decideManifest(manifest: ChangeManifest, attribution: ManifestAttribution, opts?: ManifestPolicyOptions): ManifestDecision;
|
|
90
|
+
/** Build a manifest for a Mod. `now` is injected so runs stay reproducible. */
|
|
91
|
+
export declare function makeManifest(params: {
|
|
92
|
+
id: string;
|
|
93
|
+
mod: Mod;
|
|
94
|
+
now: string;
|
|
95
|
+
predictedFixes?: string[];
|
|
96
|
+
predictedRisks?: string[];
|
|
97
|
+
touched?: string[];
|
|
98
|
+
}): ChangeManifest;
|
|
99
|
+
/** The file/knob a Mod edits — the granularity a revert operates at. */
|
|
100
|
+
export declare function defaultTouched(mod: Mod): string[];
|
|
101
|
+
interface StoreShape {
|
|
102
|
+
open: ChangeManifest[];
|
|
103
|
+
closed: Array<{
|
|
104
|
+
manifest: ChangeManifest;
|
|
105
|
+
attribution: ManifestAttribution;
|
|
106
|
+
decision: ManifestDecision;
|
|
107
|
+
}>;
|
|
108
|
+
}
|
|
109
|
+
/**
|
|
110
|
+
* JSON-backed manifest store under `.uap/self-harness/manifests.json`.
|
|
111
|
+
*
|
|
112
|
+
* Deliberately a plain file, not SQLite: manifests are few, human-auditable, and
|
|
113
|
+
* an operator inspecting why the loop reverted its own change should be able to
|
|
114
|
+
* read them without a client.
|
|
115
|
+
*/
|
|
116
|
+
export declare class ManifestStore {
|
|
117
|
+
private readonly path;
|
|
118
|
+
private data;
|
|
119
|
+
constructor(projectRoot: string);
|
|
120
|
+
private load;
|
|
121
|
+
private persist;
|
|
122
|
+
/** Manifests awaiting next-round attribution. */
|
|
123
|
+
open(): ChangeManifest[];
|
|
124
|
+
record(manifest: ChangeManifest): void;
|
|
125
|
+
/** Move a manifest to the closed log with its verdict. */
|
|
126
|
+
close(manifest: ChangeManifest, attribution: ManifestAttribution, decision: ManifestDecision): void;
|
|
127
|
+
closed(): StoreShape['closed'];
|
|
128
|
+
}
|
|
129
|
+
export {};
|
|
130
|
+
//# sourceMappingURL=manifest.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"manifest.d.ts","sourceRoot":"","sources":["../../src/self-harness/manifest.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAIH,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,+BAA+B,CAAC;AAC/D,OAAO,EAAE,GAAG,EAA0B,MAAM,WAAW,CAAC;AAExD,4DAA4D;AAC5D,MAAM,WAAW,cAAc;IAC7B,wEAAwE;IACxE,EAAE,EAAE,MAAM,CAAC;IACX,GAAG,EAAE,GAAG,CAAC;IACT,8EAA8E;IAC9E,SAAS,EAAE,MAAM,CAAC;IAClB,sEAAsE;IACtE,cAAc,EAAE,MAAM,EAAE,CA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AAM,EAAE;IACnC,EAAE,EAAE,MAAM,CAAC;IACX,GAAG,EAAE,GAAG,CAAC;IACT,GAAG,EAAE,MAAM,CAAC;IACZ,cAAc,CAAC,EAAE,MAAM,EAAE,CAAC;IAC1B,cAAc,CAAC,EAAE,MAAM,EAAE,CAAC;IAC1B,OAAO,CAAC,EAAE,MAAM,EAAE,CAAC;CACpB,GAAG,cAAc,CAUjB;AAED,wEAAwE;AACxE,wBAAgB,cAAc,CAAC,GAAG,EAAE,GAAG,GAAG,MAAM,EAAE,CAajD;AAMD,UAAU,UAAU;IAClB,IAAI,EAAE,cAAc,EAAE,CAAC;IACvB,MAAM,EAAE,KAAK,CAAC;QAAE,QAAQ,EAAE,cAAc,CAAC;QAAC,WAAW,EAAE,mBAAmB,CAAC;QAAC,QAAQ,EAAE,gBAAgB,CAAA;KAAE,CAAC,CAAC;CAC3G;AAID;;;;;;GAMG;AACH,qBAAa,aAAa;IACxB,OAAO,CAAC,QAAQ,CAAC,IAAI,CAAS;IAC9B,OAAO,CAAC,IAAI,CAAa;gBAEb,WAAW,EAAE,MAAM;IAK/B,OAAO,CAAC,IAAI;IAWZ,OAAO,CAAC,OAAO;IASf,iDAAiD;IACjD,IAAI,IAAI,cAAc,EAAE;IAIxB,MAAM,CAAC,QAAQ,EAAE,cAAc,GAAG,IAAI;IAMtC,0DAA0D;IAC1D,KAAK,CACH,QAAQ,EAAE,cAAc,EACxB,WAAW,EAAE,mBAAmB,EAChC,QAAQ,EAAE,gBAAgB,GACzB,IAAI;IAMP,MAAM,IAAI,UAAU,CAAC,QAAQ,CAAC;CAG/B"}
|
|
@@ -0,0 +1,247 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Change manifests — every harness edit is a falsifiable contract
|
|
3
|
+
* (harness plan area C, 2026-07-31).
|
|
4
|
+
*
|
|
5
|
+
* Agentic Harness Engineering (arXiv 2604.25850) attributes a large part of its
|
|
6
|
+
* Terminal-Bench 2 gain (69.7% -> 77.0%) not to smarter proposals but to
|
|
7
|
+
* DECISION OBSERVABILITY: every edit is paired with a self-declared prediction
|
|
8
|
+
* about which tasks it will fix and which it might break, that prediction is
|
|
9
|
+
* checked against the next round's actual per-task outcomes, and edits whose
|
|
10
|
+
* predictions do not materialise are reverted at file granularity.
|
|
11
|
+
*
|
|
12
|
+
* Without this, an accepted Mod is accepted forever on the strength of one
|
|
13
|
+
* noisy A/B. With it, acceptance is provisional and the loop can un-learn.
|
|
14
|
+
*
|
|
15
|
+
* Everything here is pure except the JSON store at the bottom, so the
|
|
16
|
+
* attribution rules are unit-testable without a bench run.
|
|
17
|
+
*/
|
|
18
|
+
import { existsSync, mkdirSync, readFileSync, writeFileSync } from 'node:fs';
|
|
19
|
+
import { dirname, join } from 'node:path';
|
|
20
|
+
import { describeMod, invertMod } from './mods.js';
|
|
21
|
+
/**
|
|
22
|
+
* Task ids that passed, from one CONDITION's records.
|
|
23
|
+
*
|
|
24
|
+
* Scoping to a condition is essential, not tidiness: a real `records.jsonl` from
|
|
25
|
+
* the paired bench holds BOTH arms, so a task the treatment solves and the
|
|
26
|
+
* baseline fails would read as "not passing" in every round, every predicted fix
|
|
27
|
+
* would look unrealised, and `revertOnZeroRealised` would revert every change
|
|
28
|
+
* the loop ever made.
|
|
29
|
+
*
|
|
30
|
+
* `passRatio` is the flakiness bar. Requiring a clean sweep sounds strict but on
|
|
31
|
+
* a stochastic local model it means a task lifted from 1/5 to 4/5 seeds — a real
|
|
32
|
+
* improvement — scores as no fix at all. Default 0.6: pass the majority of seeds.
|
|
33
|
+
*/
|
|
34
|
+
function passingTasks(records, condition, passRatio = 0.6) {
|
|
35
|
+
const seen = new Map();
|
|
36
|
+
for (const r of records) {
|
|
37
|
+
if (condition && r.condition !== condition)
|
|
38
|
+
continue;
|
|
39
|
+
const acc = seen.get(r.taskId) ?? { pass: 0, total: 0 };
|
|
40
|
+
acc.total++;
|
|
41
|
+
if (r.metrics.correct)
|
|
42
|
+
acc.pass++;
|
|
43
|
+
seen.set(r.taskId, acc);
|
|
44
|
+
}
|
|
45
|
+
const passed = new Set();
|
|
46
|
+
for (const [taskId, acc] of seen) {
|
|
47
|
+
if (acc.total > 0 && acc.pass / acc.total >= passRatio)
|
|
48
|
+
passed.add(taskId);
|
|
49
|
+
}
|
|
50
|
+
return passed;
|
|
51
|
+
}
|
|
52
|
+
/** The condition to attribute against when the caller does not name one. */
|
|
53
|
+
function inferCondition(records) {
|
|
54
|
+
const labels = new Set(records.map((r) => r.condition));
|
|
55
|
+
// One arm: unambiguous. Several: prefer the shipping surface, else give up and
|
|
56
|
+
// let the caller name it rather than silently mixing arms.
|
|
57
|
+
if (labels.size === 1)
|
|
58
|
+
return [...labels][0];
|
|
59
|
+
for (const preferred of ['uap-full', 'candidate', 'with-mod']) {
|
|
60
|
+
if (labels.has(preferred))
|
|
61
|
+
return preferred;
|
|
62
|
+
}
|
|
63
|
+
return undefined;
|
|
64
|
+
}
|
|
65
|
+
/**
|
|
66
|
+
* Check a manifest's prediction against what actually happened.
|
|
67
|
+
*
|
|
68
|
+
* `before` and `after` are the record sets from the round the edit was made and
|
|
69
|
+
* the round after it.
|
|
70
|
+
*/
|
|
71
|
+
export function attributeManifest(manifest, before, after, opts = {}) {
|
|
72
|
+
const condition = opts.condition ?? inferCondition(after) ?? inferCondition(before);
|
|
73
|
+
const passedBefore = passingTasks(before, condition, opts.passRatio);
|
|
74
|
+
const passedAfter = passingTasks(after, condition, opts.passRatio);
|
|
75
|
+
// INTERSECTION, not union. A task present in `before` and absent from `after`
|
|
76
|
+
// (suite edited, run aborted, sampled subset, adapter crash) is not a
|
|
77
|
+
// regression — absence is not failure — but a union scored it as one and
|
|
78
|
+
// triggered an immediate revert.
|
|
79
|
+
const beforeIds = new Set(before.filter((r) => !condition || r.condition === condition).map((r) => r.taskId));
|
|
80
|
+
const afterIds = new Set(after.filter((r) => !condition || r.condition === condition).map((r) => r.taskId));
|
|
81
|
+
const allTasks = new Set([...beforeIds].filter((t) => afterIds.has(t)));
|
|
82
|
+
const fixesRealised = [];
|
|
83
|
+
const fixesMissed = [];
|
|
84
|
+
for (const t of manifest.predictedFixes) {
|
|
85
|
+
// A predicted fix for a task that did not run again is unproven, not missed —
|
|
86
|
+
// counting it as missed would revert the change on an incomplete round.
|
|
87
|
+
if (!afterIds.has(t))
|
|
88
|
+
continue;
|
|
89
|
+
if (!passedBefore.has(t) && passedAfter.has(t))
|
|
90
|
+
fixesRealised.push(t);
|
|
91
|
+
else
|
|
92
|
+
fixesMissed.push(t);
|
|
93
|
+
}
|
|
94
|
+
const risky = new Set(manifest.predictedRisks);
|
|
95
|
+
const risksRealised = [];
|
|
96
|
+
const unpredictedRegressions = [];
|
|
97
|
+
let gained = 0;
|
|
98
|
+
let lost = 0;
|
|
99
|
+
for (const t of allTasks) {
|
|
100
|
+
const wasPassing = passedBefore.has(t);
|
|
101
|
+
const isPassing = passedAfter.has(t);
|
|
102
|
+
if (!wasPassing && isPassing)
|
|
103
|
+
gained++;
|
|
104
|
+
if (wasPassing && !isPassing) {
|
|
105
|
+
lost++;
|
|
106
|
+
if (risky.has(t))
|
|
107
|
+
risksRealised.push(t);
|
|
108
|
+
else
|
|
109
|
+
unpredictedRegressions.push(t);
|
|
110
|
+
}
|
|
111
|
+
}
|
|
112
|
+
return {
|
|
113
|
+
manifestId: manifest.id,
|
|
114
|
+
fixesRealised,
|
|
115
|
+
fixesMissed,
|
|
116
|
+
risksRealised,
|
|
117
|
+
unpredictedRegressions,
|
|
118
|
+
netDelta: gained - lost,
|
|
119
|
+
};
|
|
120
|
+
}
|
|
121
|
+
/**
|
|
122
|
+
* Decide whether a change survives its own prediction.
|
|
123
|
+
*
|
|
124
|
+
* Order matters — undeclared regressions are checked FIRST, because an edit that
|
|
125
|
+
* broke something nobody predicted is disqualified regardless of what else it
|
|
126
|
+
* happened to fix.
|
|
127
|
+
*/
|
|
128
|
+
export function decideManifest(manifest, attribution, opts = {}) {
|
|
129
|
+
const maxUnpredicted = opts.maxUnpredictedRegressions ?? 0;
|
|
130
|
+
const revertOnZero = opts.revertOnZeroRealised ?? true;
|
|
131
|
+
if (attribution.unpredictedRegressions.length > maxUnpredicted) {
|
|
132
|
+
return {
|
|
133
|
+
verdict: 'revert',
|
|
134
|
+
reason: `${attribution.unpredictedRegressions.length} undeclared regression(s) ` +
|
|
135
|
+
`(${attribution.unpredictedRegressions.slice(0, 5).join(', ')}) — ` +
|
|
136
|
+
`the manifest did not declare them.`,
|
|
137
|
+
revert: invertMod(manifest.mod),
|
|
138
|
+
};
|
|
139
|
+
}
|
|
140
|
+
if (attribution.netDelta < 0) {
|
|
141
|
+
return {
|
|
142
|
+
verdict: 'revert',
|
|
143
|
+
reason: `net task delta ${attribution.netDelta} — the change costs more than it wins.`,
|
|
144
|
+
revert: invertMod(manifest.mod),
|
|
145
|
+
};
|
|
146
|
+
}
|
|
147
|
+
// Gate on what was actually OBSERVED this round (realised + missed), not on
|
|
148
|
+
// what was predicted: if none of the predicted tasks re-ran, there is no
|
|
149
|
+
// evidence either way and reverting would punish an incomplete round.
|
|
150
|
+
const observed = attribution.fixesRealised.length + attribution.fixesMissed.length;
|
|
151
|
+
if (revertOnZero && observed > 0 && attribution.fixesRealised.length === 0) {
|
|
152
|
+
return {
|
|
153
|
+
verdict: 'revert',
|
|
154
|
+
reason: `predicted ${manifest.predictedFixes.length} fix(es), realised none — ` +
|
|
155
|
+
`the edit did not do what it claimed.`,
|
|
156
|
+
revert: invertMod(manifest.mod),
|
|
157
|
+
};
|
|
158
|
+
}
|
|
159
|
+
return {
|
|
160
|
+
verdict: 'keep',
|
|
161
|
+
reason: `realised ${attribution.fixesRealised.length}/${manifest.predictedFixes.length} predicted fix(es), ` +
|
|
162
|
+
`net delta ${attribution.netDelta}, no undeclared regressions.`,
|
|
163
|
+
};
|
|
164
|
+
}
|
|
165
|
+
/** Build a manifest for a Mod. `now` is injected so runs stay reproducible. */
|
|
166
|
+
export function makeManifest(params) {
|
|
167
|
+
return {
|
|
168
|
+
id: params.id,
|
|
169
|
+
mod: params.mod,
|
|
170
|
+
createdAt: params.now,
|
|
171
|
+
predictedFixes: params.predictedFixes ?? [],
|
|
172
|
+
predictedRisks: params.predictedRisks ?? [],
|
|
173
|
+
touched: params.touched ?? defaultTouched(params.mod),
|
|
174
|
+
summary: describeMod(params.mod),
|
|
175
|
+
};
|
|
176
|
+
}
|
|
177
|
+
/** The file/knob a Mod edits — the granularity a revert operates at. */
|
|
178
|
+
export function defaultTouched(mod) {
|
|
179
|
+
switch (mod.kind) {
|
|
180
|
+
case 'env':
|
|
181
|
+
return [`env:${mod.key}`];
|
|
182
|
+
case 'scaffold':
|
|
183
|
+
return [`scaffold:${mod.component}`];
|
|
184
|
+
case 'middleware':
|
|
185
|
+
return [`middleware:${mod.id}`];
|
|
186
|
+
case 'config':
|
|
187
|
+
return [`config:${mod.key}`];
|
|
188
|
+
case 'tool':
|
|
189
|
+
return [`tool:${mod.key}`];
|
|
190
|
+
}
|
|
191
|
+
}
|
|
192
|
+
const EMPTY_STORE = { open: [], closed: [] };
|
|
193
|
+
/**
|
|
194
|
+
* JSON-backed manifest store under `.uap/self-harness/manifests.json`.
|
|
195
|
+
*
|
|
196
|
+
* Deliberately a plain file, not SQLite: manifests are few, human-auditable, and
|
|
197
|
+
* an operator inspecting why the loop reverted its own change should be able to
|
|
198
|
+
* read them without a client.
|
|
199
|
+
*/
|
|
200
|
+
export class ManifestStore {
|
|
201
|
+
path;
|
|
202
|
+
data;
|
|
203
|
+
constructor(projectRoot) {
|
|
204
|
+
this.path = join(projectRoot, '.uap', 'self-harness', 'manifests.json');
|
|
205
|
+
this.data = this.load();
|
|
206
|
+
}
|
|
207
|
+
load() {
|
|
208
|
+
try {
|
|
209
|
+
if (!existsSync(this.path))
|
|
210
|
+
return { ...EMPTY_STORE, open: [], closed: [] };
|
|
211
|
+
const parsed = JSON.parse(readFileSync(this.path, 'utf-8'));
|
|
212
|
+
return { open: parsed.open ?? [], closed: parsed.closed ?? [] };
|
|
213
|
+
}
|
|
214
|
+
catch {
|
|
215
|
+
// A corrupt store must not wedge the loop; start clean and keep going.
|
|
216
|
+
return { open: [], closed: [] };
|
|
217
|
+
}
|
|
218
|
+
}
|
|
219
|
+
persist() {
|
|
220
|
+
try {
|
|
221
|
+
mkdirSync(dirname(this.path), { recursive: true });
|
|
222
|
+
writeFileSync(this.path, `${JSON.stringify(this.data, null, 2)}\n`, 'utf-8');
|
|
223
|
+
}
|
|
224
|
+
catch {
|
|
225
|
+
/* best-effort */
|
|
226
|
+
}
|
|
227
|
+
}
|
|
228
|
+
/** Manifests awaiting next-round attribution. */
|
|
229
|
+
open() {
|
|
230
|
+
return [...this.data.open];
|
|
231
|
+
}
|
|
232
|
+
record(manifest) {
|
|
233
|
+
this.data.open = this.data.open.filter((m) => m.id !== manifest.id);
|
|
234
|
+
this.data.open.push(manifest);
|
|
235
|
+
this.persist();
|
|
236
|
+
}
|
|
237
|
+
/** Move a manifest to the closed log with its verdict. */
|
|
238
|
+
close(manifest, attribution, decision) {
|
|
239
|
+
this.data.open = this.data.open.filter((m) => m.id !== manifest.id);
|
|
240
|
+
this.data.closed.push({ manifest, attribution, decision });
|
|
241
|
+
this.persist();
|
|
242
|
+
}
|
|
243
|
+
closed() {
|
|
244
|
+
return [...this.data.closed];
|
|
245
|
+
}
|
|
246
|
+
}
|
|
247
|
+
//# sourceMappingURL=manifest.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"manifest.js","sourceRoot":"","sources":["../../src/self-harness/manifest.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,EAAE,UAAU,EAAE,SAAS,EAAE,YAAY,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;AAC7E,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AAE1C,OAAO,EAAO,WAAW,EAAE,SAAS,EAAE,MAAM,WAAW,CAAC;AA6CxD;;;;;;;;;;;;GAYG;AACH,SAAS,YAAY,CAAC,OAAoB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H,CAAC;IAED,iDAAiD;IACjD,IAAI;QACF,OAAO,CAAC,GAAG,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IAC7B,CAAC;IAED,MAAM,CAAC,QAAwB;QAC7B,IAAI,CAAC,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,EAAE,KAAK,QAAQ,CAAC,EAAE,CAAC,CAAC;QACpE,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC;QAC9B,IAAI,CAAC,OAAO,EAAE,CAAC;IACjB,CAAC;IAED,0DAA0D;IAC1D,KAAK,CACH,QAAwB,EACxB,WAAgC,EAChC,QAA0B;QAE1B,IAAI,CAAC,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,EAAE,KAAK,QAAQ,CAAC,EAAE,CAAC,CAAC;QACpE,IAAI,CAAC,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,EAAE,QAAQ,EAAE,WAAW,EAAE,QAAQ,EAAE,CAAC,CAAC;QAC3D,IAAI,CAAC,OAAO,EAAE,CAAC;IACjB,CAAC;IAED,MAAM;QACJ,OAAO,CAAC,GAAG,IAAI,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC;IAC/B,CAAC;CACF"}
|
|
@@ -12,8 +12,15 @@
|
|
|
12
12
|
*/
|
|
13
13
|
import { UapComponent } from '../benchmarks/paired/types.js';
|
|
14
14
|
export type JsonScalar = string | number | boolean;
|
|
15
|
+
/**
|
|
16
|
+
* Where a knob takes effect. `executor` was added with ToolMod (harness plan
|
|
17
|
+
* B1): unlike proxy/llama targets it is read CLIENT-side by the delivery
|
|
18
|
+
* executor, so changing it needs an env var on the candidate arm rather than an
|
|
19
|
+
* inference-server restart — which is precisely why tool knobs can auto-validate.
|
|
20
|
+
*/
|
|
21
|
+
export type KnobTarget = 'proxy' | 'llama' | 'executor';
|
|
15
22
|
export interface NumericKnob {
|
|
16
|
-
target:
|
|
23
|
+
target: KnobTarget;
|
|
17
24
|
type: 'number';
|
|
18
25
|
/** Inclusive safe range. A proposed value outside this is rejected. */
|
|
19
26
|
min: number;
|
|
@@ -23,7 +30,7 @@ export interface NumericKnob {
|
|
|
23
30
|
description: string;
|
|
24
31
|
}
|
|
25
32
|
export interface EnumKnob {
|
|
26
|
-
target:
|
|
33
|
+
target: KnobTarget;
|
|
27
34
|
type: 'enum';
|
|
28
35
|
values: readonly string[];
|
|
29
36
|
description: string;
|
|
@@ -90,6 +97,39 @@ export declare function knobSpec(key: KnownKnob): KnobSpec;
|
|
|
90
97
|
export declare const MIDDLEWARE_IDS: readonly ["toolcall-path-normalizer"];
|
|
91
98
|
export type MiddlewareId = (typeof MIDDLEWARE_IDS)[number];
|
|
92
99
|
export declare function isMiddlewareId(s: string): s is MiddlewareId;
|
|
100
|
+
export declare const TOOL_KNOB_ALLOWLIST: {
|
|
101
|
+
readonly UAP_EDIT_TOLERANT: {
|
|
102
|
+
readonly target: "executor";
|
|
103
|
+
readonly type: "enum";
|
|
104
|
+
readonly values: readonly ["0", "1"];
|
|
105
|
+
readonly description: "edit_file falls back to whitespace-tolerant matching on an exact miss";
|
|
106
|
+
};
|
|
107
|
+
readonly UAP_EDIT_DIAGNOSTICS: {
|
|
108
|
+
readonly target: "executor";
|
|
109
|
+
readonly type: "enum";
|
|
110
|
+
readonly values: readonly ["0", "1"];
|
|
111
|
+
readonly description: "a failed edit returns the nearest current region instead of \"not found\"";
|
|
112
|
+
};
|
|
113
|
+
readonly UAP_READ_WINDOW_BYTES: {
|
|
114
|
+
readonly target: "executor";
|
|
115
|
+
readonly type: "number";
|
|
116
|
+
readonly min: 2000;
|
|
117
|
+
readonly max: 32000;
|
|
118
|
+
readonly integer: true;
|
|
119
|
+
readonly description: "bytes of a file read_file returns per call";
|
|
120
|
+
};
|
|
121
|
+
readonly UAP_MAX_TOOL_ROUNDS: {
|
|
122
|
+
readonly target: "executor";
|
|
123
|
+
readonly type: "number";
|
|
124
|
+
readonly min: 4;
|
|
125
|
+
readonly max: 40;
|
|
126
|
+
readonly integer: true;
|
|
127
|
+
readonly description: "tool-call rounds before a final answer is forced";
|
|
128
|
+
};
|
|
129
|
+
};
|
|
130
|
+
export type KnownToolKnob = keyof typeof TOOL_KNOB_ALLOWLIST;
|
|
131
|
+
export declare function isKnownToolKnob(k: string): k is KnownToolKnob;
|
|
132
|
+
export declare function toolKnobSpec(key: KnownToolKnob): KnobSpec;
|
|
93
133
|
export interface EnvMod {
|
|
94
134
|
kind: 'env';
|
|
95
135
|
key: KnownKnob;
|
|
@@ -131,7 +171,21 @@ export interface ConfigMod {
|
|
|
131
171
|
/** settings-registry category id (for grouping/diffs). */
|
|
132
172
|
category: string;
|
|
133
173
|
}
|
|
134
|
-
|
|
174
|
+
/**
|
|
175
|
+
* A change to the TOOL SURFACE the model sees (harness plan B1). Same shape as
|
|
176
|
+
* an EnvMod, different allow-list and a different application seam: tool knobs
|
|
177
|
+
* are read by the executor process, so an A/B needs an env var on the candidate
|
|
178
|
+
* arm rather than an inference-server restart.
|
|
179
|
+
*/
|
|
180
|
+
export interface ToolMod {
|
|
181
|
+
kind: 'tool';
|
|
182
|
+
key: KnownToolKnob;
|
|
183
|
+
/** Prior value (for revert + audit). */
|
|
184
|
+
from: string;
|
|
185
|
+
/** Proposed value. */
|
|
186
|
+
to: string;
|
|
187
|
+
}
|
|
188
|
+
export type Mod = EnvMod | ScaffoldMod | MiddlewareMod | ConfigMod | ToolMod;
|
|
135
189
|
export interface ValidationOk {
|
|
136
190
|
ok: true;
|
|
137
191
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"mods.d.ts","sourceRoot":"","sources":["../../src/self-harness/mods.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAE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