@tangle-network/agent-eval 0.107.0 → 0.108.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.
Files changed (43) hide show
  1. package/CHANGELOG.md +31 -0
  2. package/README.md +2 -2
  3. package/dist/adapters/http.d.ts +1 -1
  4. package/dist/adapters/langchain.d.ts +1 -1
  5. package/dist/adapters/otel.d.ts +1 -1
  6. package/dist/benchmarks/index.d.ts +3 -1
  7. package/dist/benchmarks/index.js +49 -3
  8. package/dist/campaign/index.d.ts +10 -7
  9. package/dist/campaign/index.js +72 -3407
  10. package/dist/campaign/index.js.map +1 -1
  11. package/dist/chunk-6SKVFBTR.js +4306 -0
  12. package/dist/chunk-6SKVFBTR.js.map +1 -0
  13. package/dist/{chunk-G4DLZAV5.js → chunk-OVPVM4JC.js} +1044 -643
  14. package/dist/chunk-OVPVM4JC.js.map +1 -0
  15. package/dist/chunk-T6W5ADLG.js +766 -0
  16. package/dist/chunk-T6W5ADLG.js.map +1 -0
  17. package/dist/contract/index.d.ts +16 -6
  18. package/dist/contract/index.js +10 -11
  19. package/dist/contract/index.js.map +1 -1
  20. package/dist/{gepa-BmqTrdtg.d.ts → gepa-B3x5Ulcv.d.ts} +3 -40
  21. package/dist/hosted/index.d.ts +1 -1
  22. package/dist/index-pPtfoIJO.d.ts +423 -0
  23. package/dist/index.d.ts +6 -5
  24. package/dist/index.js +8 -7
  25. package/dist/index.js.map +1 -1
  26. package/dist/multishot/index.d.ts +1 -1
  27. package/dist/openapi.json +1 -1
  28. package/dist/{pre-registration-x3f0VpxT.d.ts → pre-registration-BUhVPzE7.d.ts} +1 -1
  29. package/dist/{provenance-CIjRcI6m.d.ts → provenance-DdDhf6cg.d.ts} +3 -2
  30. package/dist/rl.d.ts +1 -1
  31. package/dist/rl.js +6 -6
  32. package/dist/storage-Dw_f7WMt.d.ts +39 -0
  33. package/dist/{types-CNZ0tHET.d.ts → types-BdIv5dvA.d.ts} +1 -1
  34. package/docs/improvement-glossary.md +5 -1
  35. package/package.json +1 -1
  36. package/dist/chunk-6PF6LXRY.js +0 -861
  37. package/dist/chunk-6PF6LXRY.js.map +0 -1
  38. package/dist/chunk-6QDKWHLS.js +0 -223
  39. package/dist/chunk-6QDKWHLS.js.map +0 -1
  40. package/dist/chunk-G4DLZAV5.js.map +0 -1
  41. package/dist/chunk-V75NN2ZR.js +0 -421
  42. package/dist/chunk-V75NN2ZR.js.map +0 -1
  43. package/dist/index-C2CC_dry.d.ts +0 -159
package/CHANGELOG.md CHANGED
@@ -4,6 +4,37 @@ All notable changes to `@tangle-network/agent-eval` and its sibling `agent-eval-
4
4
 
5
5
  ---
6
6
 
7
+ ## [0.108.1] — 2026-07-08 — public catalog docs patch
8
+
9
+ ### Fixed
10
+
11
+ - Added the missing public TSDoc summary for `Lineage`, so downstream primitive catalogs can consume the latest campaign surface without tripping their undocumented-callable ratchet.
12
+
13
+ No behavior changes.
14
+
15
+ ---
16
+
17
+ ## [0.108.0] — 2026-07-08 — placebo control reaches the facades
18
+
19
+ ### Added
20
+
21
+ - **`neutralize` passthrough on `selfImprove`.** 0.107.0 wired the footprint-matched placebo arm at `runImprovementLoop`; the public `selfImprove` facade did not forward it, so the placebo gate was unreachable from the one-call entry point. `selfImprove({ ..., neutralize })` now scores the third placebo arm and exposes `ctx.neutralizedJudgeScores` to the gate — compose `neutralizationGate` into `gate` to act on it.
22
+
23
+ Additive (one optional field); no consumer bump required.
24
+
25
+ ---
26
+
27
+ ## [0.107.0] — 2026-07-07 — footprint-matched placebo promotion gate
28
+
29
+ ### Added
30
+
31
+ - **`neutralizationGate` + `neutralizeText` (`/campaign`).** A composable promotion gate that proves a held-out lift comes from the candidate's *content* rather than from the prompt/mount *footprint* the content added. A held-out gate proves "candidate beat baseline"; it cannot tell an informative surface from one that merely added bytes the model spends attention on. `neutralizationGate` compares the candidate's lift against a footprint-matched neutralized variant (same layout + length, zero content, via `neutralizeText`) and holds any win whose lift survives blanking (decorative) — however large or significant the raw lift. Compose after significance: `composeGate(heldOutGate({ … }), neutralizationGate({ … }))`.
32
+ - **`runImprovementLoop({ neutralize })` + `GateContext.neutralizedJudgeScores` / `neutralizedArtifacts`.** When a `neutralize` function is supplied and the winner changed, the loop scores a third holdout arm (the blanked winner) and exposes it to the gate. Opt-in — one extra holdout campaign only when wired; existing callers are unaffected.
33
+
34
+ Additive (new exports + optional fields only); no consumer bump required.
35
+
36
+ ---
37
+
7
38
  ## [0.100.3] — 2026-07-01 — product benchmark contract + eval fixture UX
8
39
 
9
40
  ### Added
package/README.md CHANGED
@@ -122,7 +122,7 @@ Each example: `README.md` + a single `index.ts` runnable via `pnpm tsx`. Prints
122
122
 
123
123
  | Subpath | What it gives you |
124
124
  |---|---|
125
- | `…/contract` | **The headline, frozen surface — new code starts here.** `defineAgentEval`, `selfImprove`, `analyzeRuns`, `runEval`, `runCampaign`, `runImprovementLoop`, `diffRuns`; intake adapters (`fromFeedbackTable`, `fromOtelSpans`); proposers (`gepaProposer`, `evolutionaryProposer`); gates (`defaultProductionGate`, `heldOutGate`, `paretoSignificanceGate`, `composeGate`); the deployment-outcome store; storage; and the five core types `Scenario` / `Dispatch` / `JudgeConfig` / `SurfaceProposer` / `Gate`. |
125
+ | `…/contract` | **The headline, frozen surface — new code starts here.** `defineAgentEval`, `selfImprove`, `analyzeRuns`, `runEval`, `runCampaign`, `runImprovementLoop`, `diffRuns`; intake adapters (`fromFeedbackTable`, `fromOtelSpans`); proposers (`gepaProposer`, `evolutionaryProposer`); gates (`defaultProductionGate`, `heldOutGate`, `paretoSignificanceGate`, `neutralizationGate`, `composeGate`); the deployment-outcome store; storage; and the five core types `Scenario` / `Dispatch` / `JudgeConfig` / `SurfaceProposer` / `Gate`. |
126
126
  | `…/hosted` | `createHostedClient` / `hostedClientFromEnv` + the wire types to ship eval-run events + trace spans to a hosted orchestrator (ours or your own implementation of the spec) |
127
127
  | `…/adapters/otel` | `createOtelBridge` — forwards OpenTelemetry-shape spans into the hosted-tier ingest, no `@opentelemetry/*` dependency |
128
128
  | `…/adapters/langchain` | Wrap any LangChain `Runnable` as a `Dispatch` (or `JudgeConfig`), no `@langchain/core` peer dep |
@@ -136,7 +136,7 @@ Each example: `README.md` + a single `index.ts` runnable via `pnpm tsx`. Prints
136
136
  | `…/matrix` | `runAgentMatrix` — an N-axis cartesian over caller-supplied substrate values, per-axis pass/score/cost/duration |
137
137
  | `…/multishot` | N-shot persona × shot matrix runner (`runMultishot` / `runMultishotMatrix`) |
138
138
  | `…/wire` | The cross-language HTTP/RPC server + Zod schemas (the source-of-truth protocol the Python client speaks) + the built-in rubric registry |
139
- | `…/benchmarks` | `BenchmarkAdapter` contract + `deterministicSplit` + the bundled `routing` reference benchmark |
139
+ | `…/benchmarks` | `BenchmarkAdapter` contract, `runBenchmarkAdapter`, `calibrateBenchmarkMetric`, standard retrieval parsers + ranked retrieval metrics, `deterministicSplit`, and the bundled `routing` reference benchmark |
140
140
 
141
141
  **Specialized surfaces** (subpath-only): `…/prm` (process-reward grading + best-of-N), `…/meta-eval` (judge calibration + the deployment-outcome store), `…/belief-state` (decision-point extraction + selective-policy reports), `…/pipelines` (trace-diagnostic views: budget breach, failure cluster, stuck loop, …), `…/governance` (EU AI Act / NIST AI RMF / SOC2 reports), `…/knowledge` (knowledge-readiness gating before a run), `…/builder-eval` (code-generator three-layer eval), `…/storyboard` (trace → watchable replay), `…/authenticity` (anti-Goodhart "real or convincing BS" scorer over produced files), `…/workflow` (workflow-trace eval + partner export), `…/telemetry` (Workers-safe telemetry client), `…/testing` (test-only reset helpers).
142
142
 
@@ -1,4 +1,4 @@
1
- import { S as Scenario, D as DispatchFn, b as DispatchContext } from '../types-CNZ0tHET.js';
1
+ import { S as Scenario, D as DispatchFn, b as DispatchContext } from '../types-BdIv5dvA.js';
2
2
  import '../run-record-I-Z3JNvO.js';
3
3
  import '@tangle-network/agent-interface';
4
4
  import '../errors-oeQrLqXC.js';
@@ -1,4 +1,4 @@
1
- import { S as Scenario, J as JudgeScore, D as DispatchFn, a as JudgeConfig } from '../types-CNZ0tHET.js';
1
+ import { S as Scenario, J as JudgeScore, D as DispatchFn, a as JudgeConfig } from '../types-BdIv5dvA.js';
2
2
  import '../run-record-I-Z3JNvO.js';
3
3
  import '@tangle-network/agent-interface';
4
4
  import '../errors-oeQrLqXC.js';
@@ -1,5 +1,5 @@
1
1
  import { TraceSpanEvent, HostedClient } from '../hosted/index.js';
2
- import '../types-CNZ0tHET.js';
2
+ import '../types-BdIv5dvA.js';
3
3
  import '../run-record-I-Z3JNvO.js';
4
4
  import '@tangle-network/agent-interface';
5
5
  import '../errors-oeQrLqXC.js';
@@ -1,5 +1,7 @@
1
- export { B as BENCHMARK_SPLIT_SEED, a as BenchmarkAdapter, b as BenchmarkDatasetItem, c as BenchmarkEvaluation, d as deterministicSplit, e as routing } from '../index-C2CC_dry.js';
1
+ export { B as BENCHMARK_SPLIT_SEED, a as BenchmarkAdapter, b as BenchmarkDatasetItem, k as BenchmarkDistribution, c as BenchmarkEvaluation, d as BenchmarkFamily, l as BenchmarkMetricCalibrationOptions, m as BenchmarkMetricCalibrationResult, n as BenchmarkReport, e as BenchmarkResponder, o as BenchmarkRunOptions, p as BenchmarkRunResult, f as BenchmarkScenario, q as BenchmarkSliceSummary, g as BenchmarkSource, h as BenchmarkTaskKind, r as BuildStandardRetrievalItemsOptions, R as RetrievalIdAdapterOptions, S as StandardRetrievalArtifact, s as StandardRetrievalDocument, t as StandardRetrievalEvaluationOptions, u as StandardRetrievalPayload, v as StandardRetrievalQrel, w as StandardRetrievalQuery, x as StandardRetrievalResult, y as buildStandardRetrievalItems, z as calibrateBenchmarkMetric, A as createRetrievalIdBenchmarkAdapter, i as deterministicSplit, C as evaluateStandardRetrieval, D as normalizeRetrievedDocumentIds, E as parseBeirCorpusJsonl, F as parseBeirQueriesJsonl, G as parseJsonlRows, H as parseQrels, I as parseTsvRows, J as renderBenchmarkReportMarkdown, K as retrievalMetricsAtCutoff, L as routing, M as runBenchmarkAdapter, N as summarizeBenchmarkCampaign } from '../index-pPtfoIJO.js';
2
+ import '../types-BdIv5dvA.js';
2
3
  import '../run-record-I-Z3JNvO.js';
3
4
  import '@tangle-network/agent-interface';
4
5
  import '../errors-oeQrLqXC.js';
5
6
  import '../schema-m0gsnbt3.js';
7
+ import '../storage-Dw_f7WMt.js';
@@ -1,12 +1,58 @@
1
1
  import {
2
2
  BENCHMARK_SPLIT_SEED,
3
+ buildStandardRetrievalItems,
4
+ calibrateBenchmarkMetric,
5
+ createRetrievalIdBenchmarkAdapter,
3
6
  deterministicSplit,
4
- routing_exports
5
- } from "../chunk-6QDKWHLS.js";
7
+ evaluateStandardRetrieval,
8
+ normalizeRetrievedDocumentIds,
9
+ parseBeirCorpusJsonl,
10
+ parseBeirQueriesJsonl,
11
+ parseJsonlRows,
12
+ parseQrels,
13
+ parseTsvRows,
14
+ renderBenchmarkReportMarkdown,
15
+ retrievalMetricsAtCutoff,
16
+ routing_exports,
17
+ runBenchmarkAdapter,
18
+ summarizeBenchmarkCampaign
19
+ } from "../chunk-T6W5ADLG.js";
20
+ import "../chunk-6SKVFBTR.js";
21
+ import "../chunk-OVPVM4JC.js";
22
+ import "../chunk-3PFZBGMR.js";
23
+ import "../chunk-VI2UW6B6.js";
24
+ import "../chunk-LOJ2QVCE.js";
25
+ import "../chunk-2OGPXHOB.js";
26
+ import "../chunk-N22ZO7FV.js";
27
+ import "../chunk-FUCQVFMU.js";
28
+ import "../chunk-45EEMHTC.js";
29
+ import "../chunk-XMSYF4A7.js";
30
+ import "../chunk-RPDDVKI7.js";
31
+ import "../chunk-GGE4NNQT.js";
32
+ import "../chunk-LNQEP766.js";
33
+ import "../chunk-PC4UYEBM.js";
34
+ import "../chunk-VK6HBGAE.js";
35
+ import "../chunk-XJYR7XFV.js";
36
+ import "../chunk-VSMTAMNK.js";
37
+ import "../chunk-ONWEPEDO.js";
6
38
  import "../chunk-PZ5AY32C.js";
7
39
  export {
8
40
  BENCHMARK_SPLIT_SEED,
41
+ buildStandardRetrievalItems,
42
+ calibrateBenchmarkMetric,
43
+ createRetrievalIdBenchmarkAdapter,
9
44
  deterministicSplit,
10
- routing_exports as routing
45
+ evaluateStandardRetrieval,
46
+ normalizeRetrievedDocumentIds,
47
+ parseBeirCorpusJsonl,
48
+ parseBeirQueriesJsonl,
49
+ parseJsonlRows,
50
+ parseQrels,
51
+ parseTsvRows,
52
+ renderBenchmarkReportMarkdown,
53
+ retrievalMetricsAtCutoff,
54
+ routing_exports as routing,
55
+ runBenchmarkAdapter,
56
+ summarizeBenchmarkCampaign
11
57
  };
12
58
  //# sourceMappingURL=index.js.map
@@ -1,11 +1,13 @@
1
- import { S as SignedManifest, B as BackendIntegrityReport, C as CompletionRequirement, R as RuntimeEventLike, a as CompletionVerdict, P as ProducedState, b as CorrectnessChecker } from '../pre-registration-x3f0VpxT.js';
2
- export { L as LlmJudgeDimension, c as LlmJudgeOptions, l as llmJudge } from '../pre-registration-x3f0VpxT.js';
1
+ import { S as SignedManifest, B as BackendIntegrityReport, C as CompletionRequirement, R as RuntimeEventLike, a as CompletionVerdict, P as ProducedState, b as CorrectnessChecker } from '../pre-registration-BUhVPzE7.js';
2
+ export { L as LlmJudgeDimension, c as LlmJudgeOptions, l as llmJudge } from '../pre-registration-BUhVPzE7.js';
3
3
  import { A as AnalyzeTracesOptions, a as AnalyzeTracesInput, b as AnalyzeTracesResult } from '../analyst-C8HHvfJp.js';
4
- import { S as Scenario, M as MutableSurface, b as DispatchContext, a as JudgeConfig, g as Gate, e as GenerationRecord, J as JudgeScore, L as LabeledScenarioStore, s as LabeledScenarioWrite, t as LabeledScenarioSampleArgs, u as LabeledScenarioRecord, v as LabelTrust, f as SurfaceProposer, w as ProposedCandidate, x as ProposeContext, y as LabeledScenarioSource, C as CampaignResult, m as CodeSurface } from '../types-CNZ0tHET.js';
5
- export { i as CampaignAggregates, j as CampaignArtifactWriter, k as CampaignCellResult, l as CampaignCostMeter, z as CampaignTokenUsage, d as CampaignTraceWriter, D as DispatchFn, n as GateContext, h as GateDecision, G as GateResult, o as GenerationCandidate, A as JudgeAggregate, c as JudgeDimension, p as Mutator, O as OptimizationProposer, q as OptimizerConfig, P as ParetoParent, R as RedactionStatus, B as ScenarioAggregate, r as SessionScript, T as TraceSpan, E as isProposedCandidate, F as labelTrustRank } from '../types-CNZ0tHET.js';
6
- import { e as CampaignRunPlan, P as PlanCampaignRunOptions, C as CampaignStorage, b as RunCampaignOptions, c as RunImprovementLoopOptions } from '../gepa-BmqTrdtg.js';
7
- export { h as CampaignRunPlanCell, j as GepaProposerConstraints, G as GepaProposerOptions, O as OpenAutoPrOptions, k as OpenAutoPrResult, a as RunImprovementLoopResult, R as RunOptimizationOptions, l as RunOptimizationResult, m as countSentenceEdits, n as defaultRenderDiff, o as extractH2Sections, f as fsCampaignStorage, g as gepaProposer, i as inMemoryCampaignStorage, p as openAutoPr, q as planCampaignRun, r as runCampaign, d as runImprovementLoop, s as runOptimization, t as surfaceHash } from '../gepa-BmqTrdtg.js';
8
- export { A as AxisEvidence, a as AxisVerdict, B as BuildEvidenceVectorOptions, l as BuildLoopProvenanceArgs, D as DefaultProductionGateOptions, m as EmitLoopProvenanceArgs, n as EmitLoopProvenanceResult, E as EvidenceVector, b as EvolutionaryProposerOptions, H as HeldOutGateOptions, o as LoopProvenanceBackend, q as LoopProvenanceCandidate, L as LoopProvenanceRecord, O as ObjectiveSource, c as ParetoSignificanceGateOptions, P as PowerPreflight, s as PowerPreflightOptions, d as PromotionObjective, e as PromotionPolicy, R as RunEvalOptions, f as buildEvidenceVector, t as buildLoopProvenanceRecord, g as composeGate, h as defaultProductionGate, u as emitLoopProvenance, i as evolutionaryProposer, j as heldOutGate, v as loopProvenanceSpans, p as paretoPolicy, k as paretoSignificanceGate, w as powerPreflight, x as provenanceRecordPath, y as provenanceSpansPath, r as runEval, z as surfaceContentHash } from '../provenance-CIjRcI6m.js';
4
+ import { S as Scenario, M as MutableSurface, b as DispatchContext, a as JudgeConfig, f as Gate, d as GenerationRecord, J as JudgeScore, L as LabeledScenarioStore, s as LabeledScenarioWrite, t as LabeledScenarioSampleArgs, u as LabeledScenarioRecord, v as LabelTrust, e as SurfaceProposer, w as ProposedCandidate, x as ProposeContext, y as LabeledScenarioSource, C as CampaignResult, m as CodeSurface } from '../types-BdIv5dvA.js';
5
+ export { i as CampaignAggregates, j as CampaignArtifactWriter, k as CampaignCellResult, l as CampaignCostMeter, z as CampaignTokenUsage, c as CampaignTraceWriter, D as DispatchFn, n as GateContext, h as GateDecision, G as GateResult, o as GenerationCandidate, A as JudgeAggregate, g as JudgeDimension, p as Mutator, O as OptimizationProposer, q as OptimizerConfig, P as ParetoParent, R as RedactionStatus, B as ScenarioAggregate, r as SessionScript, T as TraceSpan, E as isProposedCandidate, F as labelTrustRank } from '../types-BdIv5dvA.js';
6
+ import { C as CampaignRunPlan, P as PlanCampaignRunOptions, b as RunCampaignOptions, c as RunImprovementLoopOptions } from '../gepa-B3x5Ulcv.js';
7
+ export { e as CampaignRunPlanCell, f as GepaProposerConstraints, G as GepaProposerOptions, O as OpenAutoPrOptions, h as OpenAutoPrResult, a as RunImprovementLoopResult, R as RunOptimizationOptions, i as RunOptimizationResult, j as countSentenceEdits, k as defaultRenderDiff, l as extractH2Sections, g as gepaProposer, o as openAutoPr, p as planCampaignRun, r as runCampaign, d as runImprovementLoop, m as runOptimization, s as surfaceHash } from '../gepa-B3x5Ulcv.js';
8
+ import { C as CampaignStorage } from '../storage-Dw_f7WMt.js';
9
+ export { f as fsCampaignStorage, i as inMemoryCampaignStorage } from '../storage-Dw_f7WMt.js';
10
+ export { A as AxisEvidence, a as AxisVerdict, B as BuildEvidenceVectorOptions, l as BuildLoopProvenanceArgs, D as DefaultProductionGateOptions, m as EmitLoopProvenanceArgs, n as EmitLoopProvenanceResult, E as EvidenceVector, b as EvolutionaryProposerOptions, H as HeldOutGateOptions, o as LoopProvenanceBackend, q as LoopProvenanceCandidate, L as LoopProvenanceRecord, O as ObjectiveSource, c as ParetoSignificanceGateOptions, P as PowerPreflight, s as PowerPreflightOptions, d as PromotionObjective, e as PromotionPolicy, R as RunEvalOptions, f as buildEvidenceVector, t as buildLoopProvenanceRecord, g as composeGate, h as defaultProductionGate, u as emitLoopProvenance, i as evolutionaryProposer, j as heldOutGate, v as loopProvenanceSpans, p as paretoPolicy, k as paretoSignificanceGate, w as powerPreflight, x as provenanceRecordPath, y as provenanceSpansPath, r as runEval, z as surfaceContentHash } from '../provenance-DdDhf6cg.js';
9
11
  import { E as EProcessState, a as PairedBootstrapResult } from '../statistics-D88peojY.js';
10
12
  import { L as LlmClientOptions } from '../llm-client-DyqEH4jH.js';
11
13
  import { AgentProfile } from '@tangle-network/agent-interface';
@@ -105,6 +107,7 @@ declare function lineageNodeId(input: {
105
107
  type LineageNodeInput = Omit<LineageNode, 'id' | 'seq' | 'generation'> & {
106
108
  generation?: number;
107
109
  };
110
+ /** Deterministic improvement-candidate graph with mutation, merge, frontier, and persistence helpers. */
108
111
  declare class Lineage {
109
112
  private readonly byId;
110
113
  private readonly childIds;