niceeval 0.13.1 → 0.13.2
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/INDEX.md +25 -2
- package/README.md +9 -10
- package/README.zh.md +9 -10
- package/dist/agents/ai-sdk.cjs.map +1 -1
- package/dist/agents/ai-sdk.d.cts +1 -1
- package/dist/agents/ai-sdk.d.mts +1 -1
- package/dist/agents/ai-sdk.d.ts +1 -1
- package/dist/agents/bub-install-spec.cjs +19 -5
- package/dist/agents/bub-install-spec.cjs.map +1 -1
- package/dist/agents/bub-install-spec.d.cts +9 -2
- package/dist/agents/bub-install-spec.d.mts +9 -2
- package/dist/agents/bub-install-spec.d.ts +9 -2
- package/dist/agents/bub-install-spec.js +14 -12
- package/dist/agents/bub.cjs +10 -6
- package/dist/agents/bub.cjs.map +1 -1
- package/dist/agents/bub.d.cts +2 -2
- package/dist/agents/bub.d.mts +2 -2
- package/dist/agents/bub.d.ts +2 -2
- package/dist/agents/claude-code.cjs.map +1 -1
- package/dist/agents/claude-code.d.cts +2 -2
- package/dist/agents/claude-code.d.mts +2 -2
- package/dist/agents/claude-code.d.ts +2 -2
- package/dist/agents/codex.cjs +4 -4
- package/dist/agents/codex.cjs.map +1 -1
- package/dist/agents/codex.d.cts +3 -3
- package/dist/agents/codex.d.mts +3 -3
- package/dist/agents/codex.d.ts +3 -3
- package/dist/agents/coding-cli-versions.cjs +10 -1
- package/dist/agents/coding-cli-versions.cjs.map +1 -1
- package/dist/agents/coding-cli-versions.d.cts +8 -3
- package/dist/agents/coding-cli-versions.d.mts +8 -3
- package/dist/agents/coding-cli-versions.d.ts +8 -3
- package/dist/agents/coding-cli-versions.js +18 -12
- package/dist/agents/deepseek-harness.cjs +151 -0
- package/dist/agents/deepseek-harness.cjs.map +1 -0
- package/dist/agents/deepseek-harness.d.cts +14 -0
- package/dist/agents/deepseek-harness.d.mts +14 -0
- package/dist/agents/deepseek-harness.d.ts +14 -0
- package/dist/agents/deepseek-harness.js +7 -0
- package/dist/agents/deepseek-harness.js.map +1 -0
- package/dist/agents/exact-npm-plugins.cjs +28 -0
- package/dist/agents/exact-npm-plugins.cjs.map +1 -0
- package/dist/agents/exact-npm-plugins.d.cts +10 -0
- package/dist/agents/exact-npm-plugins.d.mts +10 -0
- package/dist/agents/exact-npm-plugins.d.ts +10 -0
- package/dist/agents/exact-npm-plugins.js +8 -0
- package/dist/agents/exact-npm-plugins.js.map +1 -0
- package/dist/agents/index.cjs +5 -1
- package/dist/agents/index.cjs.map +1 -1
- package/dist/agents/index.d.cts +4 -0
- package/dist/agents/index.d.mts +4 -0
- package/dist/agents/index.d.ts +4 -0
- package/dist/agents/index.js +54 -50
- package/dist/agents/index.mjs +54 -50
- package/dist/agents/omp.cjs +170 -0
- package/dist/agents/omp.cjs.map +1 -0
- package/dist/agents/omp.d.cts +14 -0
- package/dist/agents/omp.d.mts +14 -0
- package/dist/agents/omp.d.ts +14 -0
- package/dist/agents/omp.js +7 -0
- package/dist/agents/omp.js.map +1 -0
- package/dist/agents/openclaw.cjs +51 -2
- package/dist/agents/openclaw.cjs.map +1 -1
- package/dist/agents/openclaw.d.cts +2 -0
- package/dist/agents/openclaw.d.mts +2 -0
- package/dist/agents/openclaw.d.ts +2 -0
- package/dist/agents/types.cjs.map +1 -1
- package/dist/agents/types.d.cts +4 -4
- package/dist/agents/types.d.mts +4 -4
- package/dist/agents/types.d.ts +4 -4
- package/dist/agents/ui-message-stream.cjs +24 -7
- package/dist/agents/ui-message-stream.cjs.map +1 -1
- package/dist/analysis/api.cjs +28 -2
- package/dist/analysis/api.cjs.map +1 -1
- package/dist/analysis/api.d.cts +22 -1
- package/dist/analysis/api.d.mts +22 -1
- package/dist/analysis/api.d.ts +22 -1
- package/dist/analysis/api.js +8 -6
- package/dist/analysis/bindings.cjs +11 -18
- package/dist/analysis/bindings.cjs.map +1 -1
- package/dist/analysis/bindings.d.cts +177 -49
- package/dist/analysis/bindings.d.mts +177 -49
- package/dist/analysis/bindings.d.ts +177 -49
- package/dist/analysis/contracts.cjs +1 -0
- package/dist/analysis/contracts.cjs.map +1 -1
- package/dist/analysis/contracts.d.cts +43 -3
- package/dist/analysis/contracts.d.mts +43 -3
- package/dist/analysis/contracts.d.ts +43 -3
- package/dist/analysis/cost-projection.cjs +2 -1
- package/dist/analysis/cost-projection.cjs.map +1 -1
- package/dist/analysis/cost-projection.d.cts +1 -1
- package/dist/analysis/cost-projection.d.mts +1 -1
- package/dist/analysis/cost-projection.d.ts +1 -1
- package/dist/analysis/cost.cjs +13 -3
- package/dist/analysis/cost.cjs.map +1 -1
- package/dist/analysis/cost.d.cts +10 -3
- package/dist/analysis/cost.d.mts +10 -3
- package/dist/analysis/cost.d.ts +10 -3
- package/dist/analysis/experiment-groups.cjs +96 -0
- package/dist/analysis/experiment-groups.cjs.map +1 -0
- package/dist/analysis/experiment-groups.d.cts +9 -0
- package/dist/analysis/experiment-groups.d.mts +9 -0
- package/dist/analysis/experiment-groups.d.ts +9 -0
- package/dist/analysis/experiment-groups.js +10 -0
- package/dist/analysis/experiment-groups.js.map +1 -0
- package/dist/analysis/index.cjs +4 -1
- package/dist/analysis/index.cjs.map +1 -1
- package/dist/analysis/index.d.cts +4 -2
- package/dist/analysis/index.d.mts +4 -2
- package/dist/analysis/index.d.ts +4 -2
- package/dist/analysis/index.js +40 -36
- package/dist/analysis/index.mjs +40 -36
- package/dist/assertions/limits.cjs +4 -0
- package/dist/assertions/limits.cjs.map +1 -1
- package/dist/assertions/limits.d.cts +4 -0
- package/dist/assertions/limits.d.mts +4 -0
- package/dist/assertions/limits.d.ts +4 -0
- package/dist/assertions/match.cjs +63 -25
- package/dist/assertions/match.cjs.map +1 -1
- package/dist/assertions/match.d.cts +7 -0
- package/dist/assertions/match.d.mts +7 -0
- package/dist/assertions/match.d.ts +7 -0
- package/dist/assertions/record/attachment.cjs +32 -4
- package/dist/assertions/record/attachment.cjs.map +1 -1
- package/dist/assertions/record/diff.cjs +10 -4
- package/dist/assertions/record/diff.cjs.map +1 -1
- package/dist/assertions/record/producer.cjs +101 -4
- package/dist/assertions/record/producer.cjs.map +1 -1
- package/dist/assertions/record/producer.d.cts +4 -1
- package/dist/assertions/record/producer.d.mts +4 -1
- package/dist/assertions/record/producer.d.ts +4 -1
- package/dist/assertions/runtime.cjs +45 -5
- package/dist/assertions/runtime.cjs.map +1 -1
- package/dist/cli/record.cjs +113 -8
- package/dist/cli/record.cjs.map +1 -1
- package/dist/cli/record.d.cts +20 -1
- package/dist/cli/record.d.mts +20 -1
- package/dist/cli/record.d.ts +20 -1
- package/dist/cli/record.js +4 -2
- package/dist/cli.cjs +386 -31
- package/dist/cli.cjs.map +1 -1
- package/dist/cli.d.cts +10 -2
- package/dist/cli.d.mts +10 -2
- package/dist/cli.d.ts +10 -2
- package/dist/context/send-retry.cjs +4 -4
- package/dist/context/send-retry.cjs.map +1 -1
- package/dist/coordination/host/runtime.cjs +8 -30
- package/dist/coordination/host/runtime.cjs.map +1 -1
- package/dist/coordination/host/runtime.d.cts +3 -3
- package/dist/coordination/host/runtime.d.mts +3 -3
- package/dist/coordination/host/runtime.d.ts +3 -3
- package/dist/coordination/host/types.cjs.map +1 -1
- package/dist/coordination/host/types.d.cts +0 -5
- package/dist/coordination/host/types.d.mts +0 -5
- package/dist/coordination/host/types.d.ts +0 -5
- package/dist/coordination/platform/node.cjs +90 -9
- package/dist/coordination/platform/node.cjs.map +1 -1
- package/dist/define.cjs +25 -1
- package/dist/define.cjs.map +1 -1
- package/dist/experiment/host/index.cjs +1 -0
- package/dist/experiment/host/index.cjs.map +1 -1
- package/dist/i18n/en.cjs +26 -8
- package/dist/i18n/en.cjs.map +1 -1
- package/dist/i18n/en.d.cts +19 -6
- package/dist/i18n/en.d.mts +19 -6
- package/dist/i18n/en.d.ts +19 -6
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +1 -1
- package/dist/index.d.mts +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/o11y/parsers/hermes.cjs +1 -1
- package/dist/o11y/parsers/hermes.cjs.map +1 -1
- package/dist/o11y/prices.json +1 -1
- package/dist/o11y/record/families.cjs +12 -3
- package/dist/o11y/record/families.cjs.map +1 -1
- package/dist/o11y/record/families.d.cts +8 -8
- package/dist/o11y/record/families.d.mts +8 -8
- package/dist/o11y/record/families.d.ts +8 -8
- package/dist/o11y/record/family-projectors.d.cts +66 -18
- package/dist/o11y/record/family-projectors.d.mts +66 -18
- package/dist/o11y/record/family-projectors.d.ts +66 -18
- package/dist/o11y/record/family-writers.d.cts +11 -3
- package/dist/o11y/record/family-writers.d.mts +11 -3
- package/dist/o11y/record/family-writers.d.ts +11 -3
- package/dist/o11y/record/runner-producer.cjs +14 -4
- package/dist/o11y/record/runner-producer.cjs.map +1 -1
- package/dist/record/codec/core.d.cts +2 -2
- package/dist/record/codec/core.d.mts +2 -2
- package/dist/record/codec/core.d.ts +2 -2
- package/dist/record/family/catalog.d.cts +44 -12
- package/dist/record/family/catalog.d.mts +44 -12
- package/dist/record/family/catalog.d.ts +44 -12
- package/dist/record/family/index.js +128 -124
- package/dist/record/family/observability-v1.cjs +35 -0
- package/dist/record/family/observability-v1.cjs.map +1 -0
- package/dist/record/family/observability-v1.d.cts +3 -0
- package/dist/record/family/observability-v1.d.mts +3 -0
- package/dist/record/family/observability-v1.d.ts +3 -0
- package/dist/record/family/observability-v1.js +6 -0
- package/dist/record/family/observability-v1.js.map +1 -0
- package/dist/record/family/observability.cjs +58 -9
- package/dist/record/family/observability.cjs.map +1 -1
- package/dist/record/family/observability.d.cts +1014 -15
- package/dist/record/family/observability.d.mts +1014 -15
- package/dist/record/family/observability.d.ts +1014 -15
- package/dist/record/family/observability.js +22 -18
- package/dist/record/host/runtime.cjs +600 -31
- package/dist/record/host/runtime.cjs.map +1 -1
- package/dist/record/host/types.cjs.map +1 -1
- package/dist/record/host/types.d.cts +33 -9
- package/dist/record/host/types.d.mts +33 -9
- package/dist/record/host/types.d.ts +33 -9
- package/dist/record/maintenance/runtime.cjs +1 -2
- package/dist/record/maintenance/runtime.cjs.map +1 -1
- package/dist/record/model/core.cjs.map +1 -1
- package/dist/record/model/core.d.cts +1 -1
- package/dist/record/model/core.d.mts +1 -1
- package/dist/record/model/core.d.ts +1 -1
- package/dist/record/model/definition.d.cts +6 -6
- package/dist/record/model/definition.d.mts +6 -6
- package/dist/record/model/definition.d.ts +6 -6
- package/dist/record/model/identifiers.cjs +1 -1
- package/dist/record/model/identifiers.cjs.map +1 -1
- package/dist/record/model/identifiers.d.cts +1 -1
- package/dist/record/model/identifiers.d.mts +1 -1
- package/dist/record/model/identifiers.d.ts +1 -1
- package/dist/record/platform/node.cjs +159 -23
- package/dist/record/platform/node.cjs.map +1 -1
- package/dist/record/platform/services.cjs.map +1 -1
- package/dist/record/platform/services.d.cts +15 -2
- package/dist/record/platform/services.d.mts +15 -2
- package/dist/record/platform/services.d.ts +15 -2
- package/dist/record/reader/errors.cjs +37 -1
- package/dist/record/reader/errors.cjs.map +1 -1
- package/dist/record/reader/errors.d.cts +49 -1
- package/dist/record/reader/errors.d.mts +49 -1
- package/dist/record/reader/errors.d.ts +49 -1
- package/dist/record/reader/errors.js +22 -12
- package/dist/record/reader/format.cjs +76 -17
- package/dist/record/reader/format.cjs.map +1 -1
- package/dist/record/reader/format.d.cts +11 -4
- package/dist/record/reader/format.d.mts +11 -4
- package/dist/record/reader/format.d.ts +11 -4
- package/dist/record/reader/format.js +2 -0
- package/dist/record/reader/index.js +32 -18
- package/dist/record/reader/runtime.cjs +64 -0
- package/dist/record/reader/runtime.cjs.map +1 -1
- package/dist/record/reader/runtime.d.cts +15 -0
- package/dist/record/reader/runtime.d.mts +15 -0
- package/dist/record/reader/runtime.d.ts +15 -0
- package/dist/record/reader/runtime.js +2 -0
- package/dist/report/assets/styles.css +53 -29
- package/dist/report/built-in/analysis-values.cjs +21 -13
- package/dist/report/built-in/analysis-values.cjs.map +1 -1
- package/dist/report/built-in/analysis-values.d.cts +11 -22
- package/dist/report/built-in/analysis-values.d.mts +11 -22
- package/dist/report/built-in/analysis-values.d.ts +11 -22
- package/dist/report/built-in/analysis-values.js +4 -6
- package/dist/report/built-in/index.cjs +1 -3
- package/dist/report/built-in/index.cjs.map +1 -1
- package/dist/report/built-in/index.d.cts +1 -1
- package/dist/report/built-in/index.d.mts +1 -1
- package/dist/report/built-in/index.d.ts +1 -1
- package/dist/report/built-in/index.js +4 -8
- package/dist/report/built-in/index.mjs +4 -8
- package/dist/report/built-in/machine.cjs +0 -2
- package/dist/report/built-in/machine.cjs.map +1 -1
- package/dist/report/built-in/machine.d.cts +0 -2
- package/dist/report/built-in/machine.d.mts +0 -2
- package/dist/report/built-in/machine.d.ts +0 -2
- package/dist/report/built-in/result-components.cjs +49 -51
- package/dist/report/built-in/result-components.cjs.map +1 -1
- package/dist/report/built-in/result-components.d.cts +16 -17
- package/dist/report/built-in/result-components.d.mts +16 -17
- package/dist/report/built-in/result-components.d.ts +16 -17
- package/dist/report/built-in/result-components.js +0 -4
- package/dist/report/built-in/run-membership-overview.cjs +126 -17
- package/dist/report/built-in/run-membership-overview.cjs.map +1 -1
- package/dist/report/built-in/run-membership-overview.d.cts +14 -0
- package/dist/report/built-in/run-membership-overview.d.mts +14 -0
- package/dist/report/built-in/run-membership-overview.d.ts +14 -0
- package/dist/report/built-in/run-membership-overview.js +4 -2
- package/dist/report/built-in/standard.cjs +80 -45
- package/dist/report/built-in/standard.cjs.map +1 -1
- package/dist/report/built-in/standard.d.cts +19 -41
- package/dist/report/built-in/standard.d.mts +19 -41
- package/dist/report/built-in/standard.d.ts +19 -41
- package/dist/report/built-in/standard.js +6 -6
- package/dist/report/components/attempt-detail/compute.cjs +78 -2
- package/dist/report/components/attempt-detail/compute.cjs.map +1 -1
- package/dist/report/components/attempt-detail/compute.d.cts +1 -1
- package/dist/report/components/attempt-detail/compute.d.mts +1 -1
- package/dist/report/components/attempt-detail/compute.d.ts +1 -1
- package/dist/report/components/attempt-detail/content.cjs +1 -1
- package/dist/report/components/attempt-detail/content.cjs.map +1 -1
- package/dist/report/components/entity-lists/compute.cjs +42 -5
- package/dist/report/components/entity-lists/compute.cjs.map +1 -1
- package/dist/report/components/entity-lists/compute.d.cts +10 -8
- package/dist/report/components/entity-lists/compute.d.mts +10 -8
- package/dist/report/components/entity-lists/compute.d.ts +10 -8
- package/dist/report/components/entity-lists/content.cjs +31 -6
- package/dist/report/components/entity-lists/content.cjs.map +1 -1
- package/dist/report/components/entity-lists/index.cjs +9 -4
- package/dist/report/components/entity-lists/index.cjs.map +1 -1
- package/dist/report/components/entity-lists/index.d.cts +4 -7
- package/dist/report/components/entity-lists/index.d.mts +4 -7
- package/dist/report/components/entity-lists/index.d.ts +4 -7
- package/dist/report/components/summaries/compute.cjs +8 -1
- package/dist/report/components/summaries/compute.cjs.map +1 -1
- package/dist/report/components/summaries/compute.d.cts +9 -1
- package/dist/report/components/summaries/compute.d.mts +9 -1
- package/dist/report/components/summaries/compute.d.ts +9 -1
- package/dist/report/components/summaries/index.cjs +48 -4
- package/dist/report/components/summaries/index.cjs.map +1 -1
- package/dist/report/components/summaries/index.d.cts +7 -4
- package/dist/report/components/summaries/index.d.mts +7 -4
- package/dist/report/components/summaries/index.d.ts +7 -4
- package/dist/report/definition/cell.cjs +3 -0
- package/dist/report/definition/cell.cjs.map +1 -1
- package/dist/report/definition/cell.d.cts +2 -0
- package/dist/report/definition/cell.d.mts +2 -0
- package/dist/report/definition/cell.d.ts +2 -0
- package/dist/report/definition/primitives/chart.cjs +8 -5
- package/dist/report/definition/primitives/chart.cjs.map +1 -1
- package/dist/report/definition/primitives/points-dataset.cjs +1 -0
- package/dist/report/definition/primitives/points-dataset.cjs.map +1 -1
- package/dist/report/definition/primitives.cjs +15 -2
- package/dist/report/definition/primitives.cjs.map +1 -1
- package/dist/report/definition/report.cjs +27 -3
- package/dist/report/definition/report.cjs.map +1 -1
- package/dist/report/definition/report.d.cts +8 -0
- package/dist/report/definition/report.d.mts +8 -0
- package/dist/report/definition/report.d.ts +8 -0
- package/dist/report/execution/machine.cjs +30 -14
- package/dist/report/execution/machine.cjs.map +1 -1
- package/dist/report/execution/machine.d.cts +20 -10
- package/dist/report/execution/machine.d.mts +20 -10
- package/dist/report/execution/machine.d.ts +20 -10
- package/dist/report/execution/machine.js +6 -6
- package/dist/report/host/execute.cjs +25 -16
- package/dist/report/host/execute.cjs.map +1 -1
- package/dist/report/host/execute.d.cts +4 -0
- package/dist/report/host/execute.d.mts +4 -0
- package/dist/report/host/execute.d.ts +4 -0
- package/dist/report/host/from-record.cjs +22 -5
- package/dist/report/host/from-record.cjs.map +1 -1
- package/dist/report/host/machine.cjs +53 -11
- package/dist/report/host/machine.cjs.map +1 -1
- package/dist/report/host/site-runtime.cjs +9 -8
- package/dist/report/host/site-runtime.cjs.map +1 -1
- package/dist/report/host/site-runtime.d.cts +1 -1
- package/dist/report/host/site-runtime.d.mts +1 -1
- package/dist/report/host/site-runtime.d.ts +1 -1
- package/dist/report/host/static.cjs +56 -9
- package/dist/report/host/static.cjs.map +1 -1
- package/dist/report/index.cjs.map +1 -1
- package/dist/report/index.d.cts +1 -1
- package/dist/report/index.d.mts +1 -1
- package/dist/report/index.d.ts +1 -1
- package/dist/report/model/dataset.cjs +7 -2
- package/dist/report/model/dataset.cjs.map +1 -1
- package/dist/report/model/locale.cjs +2 -0
- package/dist/report/model/locale.cjs.map +1 -1
- package/dist/report/model/locale.d.cts +1 -0
- package/dist/report/model/locale.d.mts +1 -0
- package/dist/report/model/locale.d.ts +1 -0
- package/dist/report/model/metrics.cjs +3 -1
- package/dist/report/model/metrics.cjs.map +1 -1
- package/dist/report/model/pricing.cjs +16 -11
- package/dist/report/model/pricing.cjs.map +1 -1
- package/dist/report/react/styles.css +53 -29
- package/dist/runner/adoption.cjs +1 -0
- package/dist/runner/adoption.cjs.map +1 -1
- package/dist/runner/attempt.cjs +44 -5
- package/dist/runner/attempt.cjs.map +1 -1
- package/dist/runner/attempt.d.cts +13 -1
- package/dist/runner/attempt.d.mts +13 -1
- package/dist/runner/attempt.d.ts +13 -1
- package/dist/runner/config-identity.cjs +10 -2
- package/dist/runner/config-identity.cjs.map +1 -1
- package/dist/runner/config-identity.d.cts +4 -2
- package/dist/runner/config-identity.d.mts +4 -2
- package/dist/runner/config-identity.d.ts +4 -2
- package/dist/runner/feedback/human.cjs +298 -59
- package/dist/runner/feedback/human.cjs.map +1 -1
- package/dist/runner/feedback/json.cjs +14 -6
- package/dist/runner/feedback/json.cjs.map +1 -1
- package/dist/runner/feedback/json.d.cts +3 -2
- package/dist/runner/feedback/json.d.mts +3 -2
- package/dist/runner/feedback/json.d.ts +3 -2
- package/dist/runner/feedback/reducer.cjs +2 -0
- package/dist/runner/feedback/reducer.cjs.map +1 -1
- package/dist/runner/judge-config.cjs +1 -1
- package/dist/runner/judge-config.cjs.map +1 -1
- package/dist/runner/ledger.cjs +124 -12
- package/dist/runner/ledger.cjs.map +1 -1
- package/dist/runner/project-current.cjs +13 -5
- package/dist/runner/project-current.cjs.map +1 -1
- package/dist/runner/run.cjs +564 -256
- package/dist/runner/run.cjs.map +1 -1
- package/dist/runner/sandbox-pool.cjs +161 -30
- package/dist/runner/sandbox-pool.cjs.map +1 -1
- package/dist/runner/sandbox-pool.d.cts +34 -2
- package/dist/runner/sandbox-pool.d.mts +34 -2
- package/dist/runner/sandbox-pool.d.ts +34 -2
- package/dist/runner/shared-state-lease.cjs +803 -0
- package/dist/runner/shared-state-lease.cjs.map +1 -0
- package/dist/runner/shared-state-lease.d.cts +121 -0
- package/dist/runner/shared-state-lease.d.mts +121 -0
- package/dist/runner/shared-state-lease.d.ts +121 -0
- package/dist/runner/shared-state-lease.js +24 -0
- package/dist/runner/shared-state-lease.js.map +1 -0
- package/dist/runner/teardown-registry.cjs +97 -34
- package/dist/runner/teardown-registry.cjs.map +1 -1
- package/dist/runner/teardown-registry.d.cts +27 -1
- package/dist/runner/teardown-registry.d.mts +27 -1
- package/dist/runner/teardown-registry.d.ts +27 -1
- package/dist/runner/teardown-registry.js +20 -16
- package/dist/runner/types.cjs.map +1 -1
- package/dist/runner/types.d.cts +31 -5
- package/dist/runner/types.d.mts +31 -5
- package/dist/runner/types.d.ts +31 -5
- package/dist/sample/analysis.cjs +249 -459
- package/dist/sample/analysis.cjs.map +1 -1
- package/dist/sample/capability.cjs +138 -7
- package/dist/sample/capability.cjs.map +1 -1
- package/dist/sample/capability.d.cts +3 -1
- package/dist/sample/capability.d.mts +3 -1
- package/dist/sample/capability.d.ts +3 -1
- package/dist/sample/capability.js +8 -6
- package/dist/sandbox/docker-agent-image.cjs +5 -1
- package/dist/sandbox/docker-agent-image.cjs.map +1 -1
- package/dist/sandbox/docker-agent-image.d.cts +2 -0
- package/dist/sandbox/docker-agent-image.d.mts +2 -0
- package/dist/sandbox/docker-agent-image.d.ts +2 -0
- package/dist/sandbox/docker-agent-image.js +14 -10
- package/dist/sandbox/docker-profile/schema.cjs +283 -534
- package/dist/sandbox/docker-profile/schema.cjs.map +1 -1
- package/dist/sandbox/docker-profile/schema.d.cts +10 -27
- package/dist/sandbox/docker-profile/schema.d.mts +10 -27
- package/dist/sandbox/docker-profile/schema.d.ts +10 -27
- package/dist/sandbox/e2b-agent-template.cjs +5 -2
- package/dist/sandbox/e2b-agent-template.cjs.map +1 -1
- package/dist/sandbox/index.cjs +4 -2
- package/dist/sandbox/index.cjs.map +1 -1
- package/dist/sandbox/index.d.cts +1 -1
- package/dist/sandbox/index.d.mts +1 -1
- package/dist/sandbox/index.d.ts +1 -1
- package/dist/sandbox/index.js +120 -116
- package/dist/sandbox/index.mjs +120 -116
- package/dist/sandbox/keep-registry.cjs +28 -66
- package/dist/sandbox/keep-registry.cjs.map +1 -1
- package/dist/sandbox/types.cjs.map +1 -1
- package/dist/sandbox/types.d.cts +1 -1
- package/dist/sandbox/types.d.mts +1 -1
- package/dist/sandbox/types.d.ts +1 -1
- package/dist/shared/aggregate.cjs +16 -6
- package/dist/shared/aggregate.cjs.map +1 -1
- package/dist/shared/aggregate.d.cts +12 -4
- package/dist/shared/aggregate.d.mts +12 -4
- package/dist/shared/aggregate.d.ts +12 -4
- package/dist/shared/turn-label.cjs +20 -2
- package/dist/shared/turn-label.cjs.map +1 -1
- package/dist/shared/turn-label.d.cts +2 -0
- package/dist/shared/turn-label.d.mts +2 -0
- package/dist/shared/turn-label.d.ts +2 -0
- package/dist/shared/turn-label.js +4 -2
- package/dist/vendor/remark/remark-gfm.cjs +7 -7
- package/dist/vendor/remark/remark-gfm.cjs.map +1 -1
- package/dist/vendor/remark/remark-parse.cjs +12 -12
- package/dist/vendor/remark/remark-parse.cjs.map +1 -1
- package/dist/vendor/remark/remark.cjs +13 -13
- package/dist/vendor/remark/remark.cjs.map +1 -1
- package/dist/view/server.cjs +6 -0
- package/dist/view/server.cjs.map +1 -1
- package/docs-site/images/hitl-handshake-zh.svg +3 -3
- package/docs-site/zh/examples/ai-agent-application.mdx +1 -1
- package/docs-site/zh/examples/coding-agent-extensions.mdx +1 -1
- package/docs-site/zh/examples/integrations/ai-sdk-v7.mdx +4 -3
- package/docs-site/zh/examples/integrations/claude-sdk.mdx +3 -3
- package/docs-site/zh/examples/integrations/codex-sdk.mdx +5 -5
- package/docs-site/zh/examples/integrations/langgraph.mdx +4 -4
- package/docs-site/zh/examples/integrations/pi-sdk.mdx +5 -5
- package/docs-site/zh/explanation/adapter.mdx +5 -5
- package/docs-site/zh/explanation/assert.mdx +7 -7
- package/docs-site/zh/explanation/drive.mdx +4 -2
- package/docs-site/zh/explanation/evals.mdx +10 -8
- package/docs-site/zh/explanation/experiment.mdx +2 -2
- package/docs-site/zh/explanation/hitl.mdx +9 -9
- package/docs-site/zh/explanation/judge.mdx +5 -5
- package/docs-site/zh/explanation/overview.mdx +3 -3
- package/docs-site/zh/explanation/runner.mdx +1 -1
- package/docs-site/zh/index.mdx +3 -3
- package/docs-site/zh/reference/builtin-agents.mdx +13 -13
- package/docs-site/zh/reference/capabilities.mdx +1 -1
- package/docs-site/zh/reference/cli.mdx +18 -12
- package/docs-site/zh/reference/define-agent.mdx +130 -5
- package/docs-site/zh/reference/define-config.mdx +2 -2
- package/docs-site/zh/reference/define-eval.mdx +4 -4
- package/docs-site/zh/reference/events.mdx +11 -11
- package/docs-site/zh/reference/official-adapters.mdx +6 -6
- package/docs-site/zh/reference/results-data.mdx +6 -0
- package/docs-site/zh/troubleshooting/debugging.mdx +1 -1
- package/docs-site/zh/troubleshooting/recover-after-kill.mdx +37 -5
- package/docs-site/zh/tutorials/accept-results.mdx +72 -0
- package/docs-site/zh/tutorials/agent-onboarding.mdx +6 -6
- package/docs-site/zh/tutorials/authoring.mdx +9 -13
- package/docs-site/zh/tutorials/ci-integration.mdx +6 -6
- package/docs-site/zh/tutorials/compare-runs.mdx +61 -0
- package/docs-site/zh/tutorials/concurrency.mdx +13 -12
- package/docs-site/zh/tutorials/configuration.mdx +4 -6
- package/docs-site/zh/tutorials/connect-your-agent.mdx +1 -1
- package/docs-site/zh/tutorials/control-run-cost.mdx +58 -0
- package/docs-site/zh/tutorials/criteria-files.mdx +2 -2
- package/docs-site/zh/tutorials/custom-reports.mdx +2 -2
- package/docs-site/zh/tutorials/debug-lifecycle-plan.mdx +46 -0
- package/docs-site/zh/tutorials/docker-in-docker.mdx +52 -43
- package/docs-site/zh/tutorials/eval-groups.mdx +6 -6
- package/docs-site/zh/tutorials/evaluation-kinds.mdx +3 -3
- package/docs-site/zh/tutorials/experiments.mdx +2 -3
- package/docs-site/zh/tutorials/handle-execution-failures.mdx +18 -10
- package/docs-site/zh/tutorials/install-custom-sandbox-agent.mdx +16 -8
- package/docs-site/zh/tutorials/nixos-managed-dind.mdx +160 -0
- package/docs-site/zh/tutorials/plugins.mdx +14 -0
- package/docs-site/zh/tutorials/rerun-and-cache.mdx +4 -2
- package/docs-site/zh/tutorials/sandbox-agent.mdx +17 -11
- package/docs-site/zh/tutorials/sandbox-providers.mdx +17 -13
- package/docs-site/zh/tutorials/sandbox-reuse.mdx +12 -19
- package/docs-site/zh/tutorials/select-and-preview.mdx +65 -0
- package/docs-site/zh/tutorials/verify-judge.mdx +78 -0
- package/docs-site/zh/tutorials/viewing-results.mdx +38 -1
- package/docs-site/zh/tutorials/write-experiment.mdx +7 -5
- package/docs-site/zh/tutorials/write-send.mdx +9 -8
- package/package.json +9 -5
- package/dist/report/built-in/overview.cjs +0 -44
- package/dist/report/built-in/overview.cjs.map +0 -1
- package/dist/report/built-in/overview.d.cts +0 -6
- package/dist/report/built-in/overview.d.mts +0 -6
- package/dist/report/built-in/overview.d.ts +0 -6
- package/dist/report/built-in/overview.js +0 -9
- package/dist/report/built-in/overview.js.map +0 -1
- package/dist/runner/gate-lease.cjs +0 -283
- package/dist/runner/gate-lease.cjs.map +0 -1
- package/dist/runner/gate-lease.d.cts +0 -62
- package/dist/runner/gate-lease.d.mts +0 -62
- package/dist/runner/gate-lease.d.ts +0 -62
- package/dist/runner/gate-lease.js +0 -22
- package/dist/runner/gate-lease.js.map +0 -1
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: "配置并验证 Judge"
|
|
3
|
+
sidebarTitle: "配置并验证 Judge"
|
|
4
|
+
description: "连接 OpenAI 兼容 Judge 网关,用一条最小评估真实预检和判分,再从结果区分配置缺失、网络失败与低质量输出。"
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
Judge 适合规则难以写成精确 Match 的开放式质量判断。先用一条最小评估确认模型、密钥和端点都能真实判分,再把 Judge 加进正式题目。
|
|
8
|
+
|
|
9
|
+
## 配置模型和凭据来源
|
|
10
|
+
|
|
11
|
+
```ts title="niceeval.config.ts"
|
|
12
|
+
import { defineConfig } from "niceeval";
|
|
13
|
+
|
|
14
|
+
export default defineConfig({
|
|
15
|
+
judge: {
|
|
16
|
+
model: "judge-model",
|
|
17
|
+
baseUrl: "https://gateway.example.com/v1",
|
|
18
|
+
apiKeyEnv: "JUDGE_GATEWAY_KEY",
|
|
19
|
+
timeoutMs: 180_000,
|
|
20
|
+
},
|
|
21
|
+
});
|
|
22
|
+
```
|
|
23
|
+
|
|
24
|
+
密钥只放进进程环境:
|
|
25
|
+
|
|
26
|
+
```sh
|
|
27
|
+
export JUDGE_GATEWAY_KEY="..."
|
|
28
|
+
```
|
|
29
|
+
|
|
30
|
+
配置文件只保存环境变量名,不保存密钥值。项目需要比较 Judge 模型时,在不同 Experiment 中覆盖 `judge.model`,不要添加单次 recipe model 参数。
|
|
31
|
+
|
|
32
|
+
## 写一条最小真实判分
|
|
33
|
+
|
|
34
|
+
```ts title="evals/judge-smoke.eval.ts"
|
|
35
|
+
import { defineEval } from "niceeval";
|
|
36
|
+
|
|
37
|
+
export default defineEval({
|
|
38
|
+
judge: true,
|
|
39
|
+
async test(t) {
|
|
40
|
+
t.judge.autoevals.closedQA("文本是否明确表达成功?", {
|
|
41
|
+
input: "operation completed successfully",
|
|
42
|
+
output: "operation completed successfully",
|
|
43
|
+
})
|
|
44
|
+
.gate(0.8)
|
|
45
|
+
.label("成功表达");
|
|
46
|
+
},
|
|
47
|
+
});
|
|
48
|
+
```
|
|
49
|
+
|
|
50
|
+
`judge: true` 声明这条评估需要 Judge,并从 Experiment 与项目配置继承字段。`.gate(0.8)` 把 measurement 变成通过制要求;低于阈值时 Attempt 为 `failed`。
|
|
51
|
+
|
|
52
|
+
## 只运行这条验证评估
|
|
53
|
+
|
|
54
|
+
先确保一个现有 Experiment 的 `evals` 选择范围包含 `judge-smoke`,再用第二个位置参数只选择这条评估。下面以 Experiment ID `local` 为例:
|
|
55
|
+
|
|
56
|
+
```sh
|
|
57
|
+
pnpm exec niceeval exp local judge-smoke
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
用 `pnpm exec niceeval exp list` 查实际 Experiment ID;不要把评估用例 ID 同时当成 Experiment ID。模型和密钥都存在时,Runner 会在派发前预检 Judge 端点。预检失败属于 setup error,不会生成伪造的 Judge 分数。
|
|
61
|
+
|
|
62
|
+
## 查看判分结果
|
|
63
|
+
|
|
64
|
+
从完成反馈复制 Run ID:
|
|
65
|
+
|
|
66
|
+
```sh
|
|
67
|
+
pnpm exec niceeval show --run <run-id>
|
|
68
|
+
```
|
|
69
|
+
|
|
70
|
+
结果应包含 Judge measurement、threshold、condition、理由和裁剪后的材料。重点区分三类失败:
|
|
71
|
+
|
|
72
|
+
| 结果 | 含义 |
|
|
73
|
+
| --- | --- |
|
|
74
|
+
| `judge-model-unresolved` / `judge-key-unresolved` | 配置或环境变量缺失,没有发起网络预检。 |
|
|
75
|
+
| `unavailable` | 请求开始后网络或 Provider 不可用,不等于零分。 |
|
|
76
|
+
| evaluator `errored` | 响应无效、分数不是有限数或超出 `[0, 1]`。 |
|
|
77
|
+
|
|
78
|
+
正式题目应先用代表性结果校准 rubric 和阈值。比较两个 Judge 模型时,让两个 Experiment 选择同一批评估用例,并用不同 `labels` 标出 Judge 条件;完整矩阵写法见[实验矩阵](/zh/tutorials/experiments)。
|
|
@@ -29,6 +29,8 @@ pnpm exec niceeval show --run 7b8d2ea4-b840-4870-9840-f85a436a5527
|
|
|
29
29
|
|
|
30
30
|
不带 locator、`--run` 或 `--experiment` 时,命令使用 `project-current`:它保留全部仍与当前项目身份匹配的已发布结果,而不是只选最新一条。需要阅读历史结果时,传入完整 `--run`;要限制当前项目结果时,重复传入完整的 `--experiment <id>`。
|
|
31
31
|
|
|
32
|
+
`project-current` 按 Run 中的 slot occurrence 保留结果。它不会把多个 Run 里同名的 Experiment、评估用例和 Attempt 序号合并成一个位置。重复运行或分多次执行 `accept` 都可能增加当前 `Sample` 的分母。
|
|
33
|
+
|
|
32
34
|
Sample 记录每个位置的状态:
|
|
33
35
|
|
|
34
36
|
| 状态 | 含义 |
|
|
@@ -51,6 +53,24 @@ pnpm exec niceeval show --run <run-id> --report ./reports/quality.tsx --json
|
|
|
51
53
|
|
|
52
54
|
省略 `--page` 时,`show` 使用 Report 的默认可导航页面。提供 `--page` 时,它只 decode、load、render 和关闭这一个精确 route。参数 Page 不会因此调用 `enumerate()`;其它 Page、Analysis 查询和作者 callback 也不会执行。
|
|
53
55
|
|
|
56
|
+
显式 `--run` 在没有指定 `--report` 时使用内建 Run 结果页。例如,某个 Run 引用了历史 Attempt 时:
|
|
57
|
+
|
|
58
|
+
```text
|
|
59
|
+
Report run-membership-overview
|
|
60
|
+
Sample: 1 run(s), 1 slot(s)
|
|
61
|
+
|
|
62
|
+
Page /
|
|
63
|
+
Run results
|
|
64
|
+
Planned attempts
|
|
65
|
+
Experiment | Eval | Attempt | Result | Details
|
|
66
|
+
checkout | checkout/basic | #1 | using result @91DDC61BAE96 | @91DDC61BAE96
|
|
67
|
+
|
|
68
|
+
Problems
|
|
69
|
+
none
|
|
70
|
+
```
|
|
71
|
+
|
|
72
|
+
`Result` 显示 `passed`、`failed`、`errored`、`not started` 或 `using result @<locator>`;`Details` 的 locator 可继续下钻。Attempt 创建前失败时,页面另外显示 `Run errors` 和该错误真正影响的未启动 Attempt 数。Human 页不显示 Slot 等内部字段;机器 `--json` 仍保留稳定 membership keys。
|
|
73
|
+
|
|
54
74
|
`show --json` 仍是同一个单目标操作。内建 Report 返回 Host 拥有的具名领域 JSON;自定义 Report 返回该 Page 的 route、标题、固定英语 80-column rendered text、下载摘要和问题表。
|
|
55
75
|
两种 v1 JSON 都在顶层带有同一形状的 `projections` 对象,只包含目标 Page 捕获的闭合投影。
|
|
56
76
|
|
|
@@ -66,6 +86,23 @@ pnpm exec niceeval show --run <run-id> --report ./reports/quality.tsx --json
|
|
|
66
86
|
|
|
67
87
|
JSON 不包含其它 Page、HTML、React tree、站点 identity 或 Record 读取能力。
|
|
68
88
|
|
|
89
|
+
## 按题型读取主读数
|
|
90
|
+
|
|
91
|
+
默认报告按评估类型选择主读数:
|
|
92
|
+
|
|
93
|
+
- 通过制评估显示通过率。
|
|
94
|
+
- 计分制评估显示 earned score。
|
|
95
|
+
- mixed Experiment 显示 Score,并在通过制评估子行显示通过率,不把两者合成百分比。
|
|
96
|
+
|
|
97
|
+
计分制评估上声明的 `points` 是评分项的贡献权重,不是 Experiment 的固定满分。动态执行、条件分支或不可用材料可能让评分项集合不同,因此默认报告不会自动把 earned score 除以所有源码里声明的 `points`。
|
|
98
|
+
|
|
99
|
+
项目没有配置 Report 时,`project-current` 使用内建 `standard`。Overview 通过同一个 `ExperimentTable` 呈现通过制和分数制结果,
|
|
100
|
+
并提供筛选、逐层展开与 Attempt 详情链接。`standard` 只额外包含由该表链接到的 Experiment 和 Attempt 详情 Page;两种详情
|
|
101
|
+
不会改变 Score 或通过率的计算口径。
|
|
102
|
+
|
|
103
|
+
Overview 的实验对比图使用同一题型判断:通过制画成本 × 通过率,分数制画成本 × 总分。两种题型同时存在时显示两张图,
|
|
104
|
+
不会把 points 和 ratio 放进同一纵轴。通过率刻度显示百分比;内部的 `ratio` 量纲不会出现在图表文案里。
|
|
105
|
+
|
|
69
106
|
## 在浏览器读取完整站点
|
|
70
107
|
|
|
71
108
|
```sh
|
|
@@ -81,7 +118,7 @@ view 在启动 server 前枚举所有显式声明的普通 Page 与参数 Page
|
|
|
81
118
|
|
|
82
119
|
## 读懂不完整数据
|
|
83
120
|
|
|
84
|
-
`MetricValue` 的 `samples` 是实际贡献数,`total` 是既定分母,`state` 和 `issues`
|
|
121
|
+
`MetricValue` 的 `samples` 是实际贡献数,`total` 是既定分母,`state` 和 `issues` 说明为什么数据不完整。自定义 Report 使用 `formatMetricValue()` 时仍可得到 `2 / 4 slot · partial` 这类紧凑格式;它表示四个已选位置中有两个提供该指标,不是 score,也不是“完成了一半”。默认 Overview 改用上面的独立覆盖区域。`partial` 可以有数值;`empty`、`unsupported` 与 `failed` 不是零。Evidence refs 保留可复核的定位信息。
|
|
85
122
|
|
|
86
123
|
Analysis 数据问题继续作为页面内容显示。相反,选中 Page 的 callback、参数 key 或成员资格失败会让 `show` 返回单目标错误;任何全站 Page、路径、资源或预算失败都会阻止新的站点发布。
|
|
87
124
|
|
|
@@ -121,7 +121,7 @@ npx niceeval exp prompts/concise
|
|
|
121
121
|
| `flags` | 实验条件(A/B 里的 feature flag),任意 JSON 对象,经 `ctx.flags` / `t.flags` 透传 |
|
|
122
122
|
| `attempts` | 每个评估用例 × 配置最多跑几次 |
|
|
123
123
|
| `earlyExit` | 多次运行里通过一次就提前停止。默认关,`attempts` 默认跑满测完整通过率 |
|
|
124
|
-
| `evals` | `"*"`、
|
|
124
|
+
| `evals` | `"*"`、ID 前缀数组,或遍历只读评估用例描述并返回 Boolean 的函数 |
|
|
125
125
|
| `timeoutMs` | 单个 attempt 的超时 |
|
|
126
126
|
| `budget` | 这一格配置的预算上限 |
|
|
127
127
|
| `maxConcurrency` | 这一格配置的并发上限 |
|
|
@@ -220,6 +220,8 @@ export default defineExperiment({
|
|
|
220
220
|
});
|
|
221
221
|
```
|
|
222
222
|
|
|
223
|
+
`maxConcurrency: 1` 只串行本 Invocation。`sharedState.key` 在同一项目 Coordination 域内保护跨 Invocation 的 checkpoint。租约从 Experiment 与 Sandbox setup 前开始,到全部 Sandbox teardown、Provider finalizer 和 Experiment teardown 完成。它只提供互斥;存储、原子回存、强杀恢复与跨机器协调仍由作者负责。
|
|
224
|
+
|
|
223
225
|
固定的 Agent CLI、系统包和大模型缓存应先做进 image/template/snapshot。`.setup()` 不应在每个 Attempt 重建同一套环境。从官方 Docker 镜像、E2B 模板或 Vercel runtime 派生预制环境的步骤见 [Sandbox Provider · 从官方基线继续构建以提速](/zh/tutorials/sandbox-providers#从官方基线继续构建以提速)。
|
|
224
226
|
|
|
225
227
|
Hook 的执行时机、多 Hook 顺序和失败语义见 [Sandbox provider · 生命周期](/zh/tutorials/sandbox-providers#生命周期)。
|
|
@@ -263,7 +265,7 @@ export default defineExperiment({
|
|
|
263
265
|
});
|
|
264
266
|
```
|
|
265
267
|
|
|
266
|
-
一份实验文件从上往下读就是完整的运行说明:整场一次的宿主机资源在实验级 Hook 对里。每 Sandbox 的写入与回存在 `sandbox` 链式 Hook 里,读实验级产物。
|
|
268
|
+
一份实验文件从上往下读就是完整的运行说明:整场一次的宿主机资源在实验级 Hook 对里。每 Sandbox 的写入与回存在 `sandbox` 链式 Hook 里,读实验级产物。Agent 怎么连接被测对象、评估用例的 Fixture,各自在 Agent 定义与 `EvalDef` 里,不进实验文件。
|
|
267
269
|
|
|
268
270
|
### 多个实验共享同一套生命周期代码
|
|
269
271
|
|
|
@@ -357,7 +359,7 @@ export const sharedNowledge = {
|
|
|
357
359
|
|
|
358
360
|
## 让不同评估用例使用不同预制环境
|
|
359
361
|
|
|
360
|
-
一批真实任务可能需要不同版本的运行时和依赖。把具体的 template-bearing factory
|
|
362
|
+
一批真实任务可能需要不同版本的运行时和依赖。把具体的 template-bearing factory 直接放在每条评估用例上,让任务与执行环境保持为同一份声明:
|
|
361
363
|
|
|
362
364
|
```ts
|
|
363
365
|
// evals/astropy-2021.eval.ts
|
|
@@ -377,7 +379,7 @@ export const python39 = () => e2bSandbox({ template: "codex-python39" });
|
|
|
377
379
|
```
|
|
378
380
|
|
|
379
381
|
```ts
|
|
380
|
-
// experiments/e2b.ts ——
|
|
382
|
+
// experiments/e2b.ts —— 评估用例拥有 template,Experiment 只拥有 Agent
|
|
381
383
|
import { defineExperiment } from "niceeval";
|
|
382
384
|
|
|
383
385
|
export default defineExperiment({
|
|
@@ -385,6 +387,6 @@ export default defineExperiment({
|
|
|
385
387
|
});
|
|
386
388
|
```
|
|
387
389
|
|
|
388
|
-
没有 profile registry,也没有按 source kind 登记的 materializer 表。每个 factory 同时拥有支持声明与实现,physical planning 会在创建任何 Sandbox
|
|
390
|
+
没有 profile registry,也没有按 source kind 登记的 materializer 表。每个 factory 同时拥有支持声明与实现,physical planning 会在创建任何 Sandbox 前校验所有选中评估用例。重复 template 用普通 TypeScript 辅助函数共享。同一个 Experiment 仍能覆盖全部评估用例,link planning 会逐条把评估用例 layer 与 Experiment layer 配对。
|
|
389
391
|
|
|
390
392
|
跨配置比较的设计建议见[实验矩阵](/zh/tutorials/experiments)。Adapter 对 `ctx.model` 和 `ctx.flags` 的用法见 [Adapter](/zh/explanation/adapter)。
|
|
@@ -75,7 +75,7 @@ if (!res.requestId) {
|
|
|
75
75
|
|
|
76
76
|
`progress` 不落盘。diagnostic 会写入 Attempt-owned 通道,并从已选 Run 的详情页面回顾。HTTP 连接失败或响应无法解析时直接抛错;runner 会记录错误发生在 `agent.run`,并在 `niceeval.verdict` 通道形成 `errored` Verdict。
|
|
77
77
|
|
|
78
|
-
**这一步支持**:`t.reply
|
|
78
|
+
**这一步支持**:`t.reply` 的直接值检查(`t.check(t.reply, includes(...))` 或 `pattern(...)`)、Judge 的全部对话材料,以及 Experiment 侧的**模型对比**。`ctx.model` 来自 Experiment 的 `model`。运行器原样传递,Adapter 只负责转发。接入等级见 [Tier](/zh/explanation/tier)。
|
|
79
79
|
|
|
80
80
|
它有两个明显的局限:每轮都是一场全新对话(第二次 `t.send` 接不上第一次),工具调用完全看不见。后面两步各解决一个。
|
|
81
81
|
|
|
@@ -155,8 +155,8 @@ export default defineAgent({
|
|
|
155
155
|
`Usage` 的完整字段还有可选的 `cacheReadTokens` / `cacheCreationTokens`、推理 token 数 `reasoningTokens`、请求次数 `requests`,以及
|
|
156
156
|
`costUSD`。`costUSD` 只在 provider 或 adapter 如实返回 USD observed 成本时填写;上游估算、模型目录价目表或本地计算绝不写入它。每个字段只在接口真实提供时填,接口不回用量就整个不填 `usage`,其它断言不受影响。
|
|
157
157
|
|
|
158
|
-
Runner 始终从 Config/runtime price table 独立计算 `estimatedCostUSD`,即使有 observed `costUSD`
|
|
159
|
-
`t.maxCost()` 使用这个 estimate。Report 则只使用显式 `PricingProfile` 和 sealed Usage 进行 Analysis 成本投影,绝不消费 Runner
|
|
158
|
+
Runner 始终从 `model`、上报的 token 用量和 Config/runtime price table 独立计算 `estimatedCostUSD`,即使有 observed `costUSD`
|
|
159
|
+
也不改变该计算;Experiment budget 与 `t.maxCost()` 使用这个 estimate。Report 则只使用显式 `PricingProfile` 和 sealed Usage 进行 Analysis 成本投影,绝不消费 Runner
|
|
160
160
|
estimate。
|
|
161
161
|
|
|
162
162
|
当 Config/runtime price table 无法形成 Runner estimate 时,`t.maxCost()` 为 `unavailable`,绝不能把缺失当成 `0`。显式零费率实际
|
|
@@ -236,10 +236,10 @@ type StreamEvent =
|
|
|
236
236
|
|
|
237
237
|
| 你吐的事件 | 解锁的断言 |
|
|
238
238
|
|---|---|
|
|
239
|
-
| `message` | `t.reply`、`t.
|
|
239
|
+
| `message` | `t.reply`、`t.check(turn.message, includes(...))` / `pattern(...)`、Judge 的对话材料 |
|
|
240
240
|
| tool `operation.started` / `operation.finished`(靠 `operationId` 配对) | `turn.calledTool()` / `turn.toolOrder()` / `turn.maxToolCalls()` / `turn.noFailedActions()`… |
|
|
241
|
-
| `input.requested`(配合 status `"waiting"`) | `t.
|
|
242
|
-
| `thinking` / `compaction` / `error` |
|
|
241
|
+
| `input.requested`(配合 status `"waiting"`) | `t.check(turn.status, equals("waiting"))`、`t.requireInputRequest()`、`t.respond()`(第五步) |
|
|
242
|
+
| `thinking` / `compaction` / `error` | 报告与诊断;当前没有对应的公开 `eventMatch` selector |
|
|
243
243
|
|
|
244
244
|
Chat Completions 响应**不保证包含完整过程记录**。应用可能在服务端完成工具循环,只返回最终答案。因此,`turnFromChatCompletion` 的返回不带完整性证明:`calledTool` 等正断言可用,`notCalledTool` 等负断言会提示证据不完整。Responses 协议要求 `output` 数组记录完整过程,`turnFromResponses` 的返回带完整性证明,负断言可信。两者的可信度差异来自接口契约。
|
|
245
245
|
|
|
@@ -249,7 +249,7 @@ Chat Completions 响应**不保证包含完整过程记录**。应用可能在
|
|
|
249
249
|
|
|
250
250
|
应用中途停下来等人(工具审批、等补充信息)时,`send` 两侧各有义务:
|
|
251
251
|
|
|
252
|
-
- **停轮**:返回 `status: "waiting"`,并且每个待回答的问题吐一条带稳定 `id` 的 `input.requested` 事件——`t.
|
|
252
|
+
- **停轮**:返回 `status: "waiting"`,并且每个待回答的问题吐一条带稳定 `id` 的 `input.requested` 事件——`t.check(turn.status, equals("waiting"))` 与 `t.requireInputRequest()` 读取它,回答靠这个 `id` 对位。
|
|
253
253
|
- **回答轮**:评估用例里的 `t.respond(...)` 到 Adapter 是**又一次普通的 `send`**(还是同一条会话线、同一份状态),人的裁决以结构化形式随 `input.responses` 到达,每条带 `requestId`、`optionId` 或 `text`(形态见[不同回答的入参](/zh/explanation/adapter#不同回答的入参))。Adapter 先把裁决交回应用,再接着取结果。被人拒绝的调用,tool `operation.finished` 的 `status` 置 `"rejected"` 而不是 `"failed"`——拒绝是人的决定、不是工具故障,`noFailedActions()` 不误伤。
|
|
254
254
|
|
|
255
255
|
"停轮时读了一半的现场"(比如一条读到一半的 SSE 流)也存在 `ctx.session` 上。Adapter 先用 `createSessionSlot<Pending>()` 创建私有 slot,停轮时 `ctx.session.set(slot, pending)`,回答轮开头 `ctx.session.take(slot)` 取回。取到即清除,一次消费。
|
|
@@ -312,7 +312,8 @@ export default defineAgent({
|
|
|
312
312
|
|
|
313
313
|
不需要 HITL 的接口,删掉停轮现场相关的三处(`Pending`、`hold`、开头的 `take` 分支)即可,其余不变。停轮 / 回答 / 续跑的完整心智模型见 [HITL](/zh/explanation/hitl)。
|
|
314
314
|
|
|
315
|
-
**这一步支持**:`t.
|
|
315
|
+
**这一步支持**:`t.check(turn.status, equals("waiting"))`、`t.requireInputRequest()`、`t.respond()` / `t.respondAll()`。
|
|
316
|
+
被人拒绝的调用可用 `calledTool(toolMatch(..., { status: "rejected" }))` 精确断言。
|
|
316
317
|
|
|
317
318
|
## 第六步:接上 OTel trace
|
|
318
319
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "niceeval",
|
|
3
|
-
"version": "0.13.
|
|
3
|
+
"version": "0.13.2",
|
|
4
4
|
"description": "Agent-native eval tool — eval agents, services, functions, and coding-agent fixtures",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|
|
@@ -264,6 +264,7 @@
|
|
|
264
264
|
"braintrust": "^3.20.0",
|
|
265
265
|
"class-variance-authority": "^0.7.1",
|
|
266
266
|
"clsx": "^2.1.1",
|
|
267
|
+
"concurrently": "^10.0.5",
|
|
267
268
|
"dockerode": "^4.0.2",
|
|
268
269
|
"e2b": "^2.31.0",
|
|
269
270
|
"esbuild": "^0.28.1",
|
|
@@ -319,12 +320,14 @@
|
|
|
319
320
|
},
|
|
320
321
|
"scripts": {
|
|
321
322
|
"typecheck": "tsc --noEmit && tsc -p docs/feature/assertions/reference/tsconfig.json",
|
|
322
|
-
"lint": "
|
|
323
|
+
"lint": "pnpm run docs:mint && concurrently --names vitest,validate,links \"pnpm run lint:vitest\" \"pnpm run docs:validate\" \"pnpm run docs:links\"",
|
|
324
|
+
"lint:vitest": "vitest run --project lint-docs --project lint-docs-site",
|
|
323
325
|
"lint:docs": "vitest run --project lint-docs",
|
|
324
|
-
"lint:docs-site": "vitest run --project lint-docs-site
|
|
326
|
+
"lint:docs-site": "pnpm run docs:mint && concurrently --names vitest,validate,links \"vitest run --project lint-docs-site\" \"pnpm run docs:validate\" \"pnpm run docs:links\"",
|
|
325
327
|
"niceeval": "node bin/niceeval.js",
|
|
326
328
|
"e2e": "tsx e2e/scripts/cli.ts",
|
|
327
329
|
"gen:diff-code": "tsx scripts/gen-diff-code.ts",
|
|
330
|
+
"pr:body": "tsx scripts/pr-body.ts",
|
|
328
331
|
"docs:reference": "tsx scripts/generate-reference.ts",
|
|
329
332
|
"tiers:sync": "node scripts/sync-tiers.mjs sync",
|
|
330
333
|
"view:build": "vite build --config src/view/app/vite.config.ts",
|
|
@@ -334,7 +337,8 @@
|
|
|
334
337
|
"site:dev": "cd site && node scripts/dev.mjs",
|
|
335
338
|
"site:build": "cd site && next build && cd .. && tsx scripts/submit-indexnow.ts",
|
|
336
339
|
"docs:dev": "node scripts/docs-dev.mjs",
|
|
337
|
-
"docs:
|
|
338
|
-
"docs:
|
|
340
|
+
"docs:mint": "cd docs-site && npx --yes mint@4.2.812 --version",
|
|
341
|
+
"docs:validate": "cd docs-site && npx --yes mint@4.2.812 validate",
|
|
342
|
+
"docs:links": "cd docs-site && npx --yes mint@4.2.812 broken-links --check-anchors --check-redirects"
|
|
339
343
|
}
|
|
340
344
|
}
|
|
@@ -1,44 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.overview = exports.defaultOverviewReport = void 0;
|
|
4
|
-
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
5
|
-
const analysis_values_ts_1 = require("./analysis-values.cjs");
|
|
6
|
-
const result_components_tsx_1 = require("./result-components.cjs");
|
|
7
|
-
const machine_ts_1 = require("./machine.cjs");
|
|
8
|
-
function heroData(snapshot) {
|
|
9
|
-
const latest = snapshot.runs.reduce((current, run) => current === null || Number(run.startedAt) > current ? Number(run.startedAt) : current, null);
|
|
10
|
-
return Object.freeze({
|
|
11
|
-
latestStartedAt: latest === null ? null : new Date(latest).toISOString(),
|
|
12
|
-
runs: snapshot.runs.length,
|
|
13
|
-
});
|
|
14
|
-
}
|
|
15
|
-
const overviewPage = {
|
|
16
|
-
id: "overview",
|
|
17
|
-
path: "/",
|
|
18
|
-
title: "Overview",
|
|
19
|
-
load: async (sample) => {
|
|
20
|
-
const [summary, experiments] = await Promise.all([
|
|
21
|
-
(0, analysis_values_ts_1.loadBuiltInSummaryRows)(sample),
|
|
22
|
-
(0, analysis_values_ts_1.loadBuiltInExperimentRows)(sample),
|
|
23
|
-
]);
|
|
24
|
-
return Object.freeze({
|
|
25
|
-
hero: heroData(sample.snapshot),
|
|
26
|
-
summary,
|
|
27
|
-
experiments,
|
|
28
|
-
counts: Object.freeze({
|
|
29
|
-
experiments: experiments.length,
|
|
30
|
-
attempts: sample.snapshot.slots.filter((slot) => slot.state === "included").length,
|
|
31
|
-
}),
|
|
32
|
-
});
|
|
33
|
-
},
|
|
34
|
-
render: (input) => (0, jsx_runtime_1.jsx)(result_components_tsx_1.StandardOverviewResultView, input),
|
|
35
|
-
};
|
|
36
|
-
/** The default project-current report over Analysis-issued closed rows. */
|
|
37
|
-
exports.defaultOverviewReport = (0, machine_ts_1.defineBuiltInReport)(machine_ts_1.builtInMachineProducerIds.defaultOverview, {
|
|
38
|
-
title: "NiceEval overview",
|
|
39
|
-
pages: [overviewPage],
|
|
40
|
-
});
|
|
41
|
-
/** Stable built-in token target for an explicit `--report overview`. */
|
|
42
|
-
exports.overview = exports.defaultOverviewReport;
|
|
43
|
-
exports.default = exports.defaultOverviewReport;
|
|
44
|
-
//# sourceMappingURL=overview.cjs.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"overview.js","sourceRoot":"","sources":["overview.ts"],"names":[],"mappings":";;;AAEA,mDAAwC;AAGxC,6DAA+I;AAC/I,kEAAsE;AACtE,6CAA+E;AAU/E,SAAS,QAAQ,CAAC,QAAwB;IACtC,MAAM,MAAM,GAAG,QAAQ,CAAC,IAAI,CAAC,MAAM,CAAgB,CAAC,OAAO,EAAE,GAAG,EAAE,EAAE,CAAC,OAAO,KAAK,IAAI,IAAI,MAAM,CAAC,GAAG,CAAC,SAAS,CAAC,GAAG,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,GAAG,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,OAAO,EAAE,IAAI,CAAC,CAAC;IAClK,OAAO,MAAM,CAAC,MAAM,CAAC;QACjB,eAAe,EAAE,MAAM,KAAK,IAAI,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,IAAI,IAAI,CAAC,MAAM,CAAC,CAAC,WAAW,EAAE;QACxE,IAAI,EAAE,QAAQ,CAAC,IAAI,CAAC,MAAM;KAC7B,CAAC,CAAC;AACP,CAAC;AACD,MAAM,YAAY,GAAG;IACjB,EAAE,EAAE,UAAU;IACd,IAAI,EAAE,GAAG;IACT,KAAK,EAAE,UAAU;IACjB,IAAI,EAAE,KAAK,EAAE,MAAc,EAA8B,EAAE;QACvD,MAAM,CAAC,OAAO,EAAE,WAAW,CAAC,GAAG,MAAM,OAAO,CAAC,GAAG,CAAC;YAC7C,IAAA,2CAAsB,EAAC,MAAM,CAAC;YAC9B,IAAA,8CAAyB,EAAC,MAAM,CAAC;SACpC,CAAC,CAAC;QACH,OAAO,MAAM,CAAC,MAAM,CAAC;YACjB,IAAI,EAAE,QAAQ,CAAC,MAAM,CAAC,QAAQ,CAAC;YAC/B,OAAO;YACP,WAAW;YACX,MAAM,EAAE,MAAM,CAAC,MAAM,CAAC;gBAClB,WAAW,EAAE,WAAW,CAAC,MAAM;gBAC/B,QAAQ,EAAE,MAAM,CAAC,QAAQ,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,IAAI,CAAC,KAAK,KAAK,UAAU,CAAC,CAAC,MAAM;aACrF,CAAC;SACL,CAAC,CAAC;IACP,CAAC;IACD,MAAM,EAAE,CAAC,KAAwB,EAAE,EAAE,CAAC,IAAA,iBAAG,EAAC,kDAA0B,EAAE,KAAK,CAAC;CACvC,CAAC;AAC1C,2EAA2E;AAC9D,QAAA,qBAAqB,GAAG,IAAA,gCAAmB,EAAC,sCAAyB,CAAC,eAAe,EAAE;IAChG,KAAK,EAAE,mBAAmB;IAC1B,KAAK,EAAE,CAAC,YAAY,CAAC;CACxB,CAAC,CAAC;AACH,wEAAwE;AAC3D,QAAA,QAAQ,GAAG,6BAAqB,CAAC;AAC9C,kBAAe,6BAAqB,CAAC","sourcesContent":["/** The stable project-current built-in selector. */\nimport type { Sample, SampleSnapshot, } from \"../../analysis/index.ts\";\nimport { jsx } from \"react/jsx-runtime\";\nimport type { Page } from \"../definition/report.ts\";\nimport { type HeroData } from \"../components/site-components/index.tsx\";\nimport { loadBuiltInExperimentRows, loadBuiltInSummaryRows, type BuiltInExperimentRows, type BuiltInSummaryRows, } from \"./analysis-values.ts\";\nimport { StandardOverviewResultView, } from \"./result-components.tsx\";\nimport { builtInMachineProducerIds, defineBuiltInReport, } from \"./machine.ts\";\ninterface OverviewPageInput {\n readonly hero: HeroData;\n readonly summary: BuiltInSummaryRows;\n readonly experiments: BuiltInExperimentRows;\n readonly counts: {\n readonly experiments: number;\n readonly attempts: number;\n };\n}\nfunction heroData(snapshot: SampleSnapshot): HeroData {\n const latest = snapshot.runs.reduce<number | null>((current, run) => current === null || Number(run.startedAt) > current ? Number(run.startedAt) : current, null);\n return Object.freeze({\n latestStartedAt: latest === null ? null : new Date(latest).toISOString(),\n runs: snapshot.runs.length,\n });\n}\nconst overviewPage = {\n id: \"overview\",\n path: \"/\",\n title: \"Overview\",\n load: async (sample: Sample): Promise<OverviewPageInput> => {\n const [summary, experiments] = await Promise.all([\n loadBuiltInSummaryRows(sample),\n loadBuiltInExperimentRows(sample),\n ]);\n return Object.freeze({\n hero: heroData(sample.snapshot),\n summary,\n experiments,\n counts: Object.freeze({\n experiments: experiments.length,\n attempts: sample.snapshot.slots.filter((slot) => slot.state === \"included\").length,\n }),\n });\n },\n render: (input: OverviewPageInput) => jsx(StandardOverviewResultView, input),\n} satisfies Page<void, OverviewPageInput>;\n/** The default project-current report over Analysis-issued closed rows. */\nexport const defaultOverviewReport = defineBuiltInReport(builtInMachineProducerIds.defaultOverview, {\n title: \"NiceEval overview\",\n pages: [overviewPage],\n});\n/** Stable built-in token target for an explicit `--report overview`. */\nexport const overview = defaultOverviewReport;\nexport default defaultOverviewReport;\n"]}
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
/** The stable project-current built-in selector. */
|
|
2
|
-
/** The default project-current report over Analysis-issued closed rows. */
|
|
3
|
-
export declare const defaultOverviewReport: import("../definition/report.cjs").ReportDefinition;
|
|
4
|
-
/** Stable built-in token target for an explicit `--report overview`. */
|
|
5
|
-
export declare const overview: import("../definition/report.cjs").ReportDefinition;
|
|
6
|
-
export default defaultOverviewReport;
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
/** The stable project-current built-in selector. */
|
|
2
|
-
/** The default project-current report over Analysis-issued closed rows. */
|
|
3
|
-
export declare const defaultOverviewReport: import("../definition/report.mjs").ReportDefinition;
|
|
4
|
-
/** Stable built-in token target for an explicit `--report overview`. */
|
|
5
|
-
export declare const overview: import("../definition/report.mjs").ReportDefinition;
|
|
6
|
-
export default defaultOverviewReport;
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
/** The stable project-current built-in selector. */
|
|
2
|
-
/** The default project-current report over Analysis-issued closed rows. */
|
|
3
|
-
export declare const defaultOverviewReport: import("../definition/report.js").ReportDefinition;
|
|
4
|
-
/** Stable built-in token target for an explicit `--report overview`. */
|
|
5
|
-
export declare const overview: import("../definition/report.js").ReportDefinition;
|
|
6
|
-
export default defaultOverviewReport;
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import { createRequire as __niceevalCreateRequire } from "node:module";
|
|
2
|
-
const __niceevalRequire = __niceevalCreateRequire(import.meta.url);
|
|
3
|
-
const __niceevalCanonical = __niceevalRequire("./overview.cjs");
|
|
4
|
-
export default __niceevalCanonical.default;
|
|
5
|
-
const __niceevalExport0 = __niceevalCanonical["defaultOverviewReport"];
|
|
6
|
-
export { __niceevalExport0 as defaultOverviewReport };
|
|
7
|
-
const __niceevalExport1 = __niceevalCanonical["overview"];
|
|
8
|
-
export { __niceevalExport1 as overview };
|
|
9
|
-
//# sourceMappingURL=overview.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"overview.js","sources":[],"names":[],"mappings":""}
|