@jinn-network/client 0.1.8 → 0.1.9-canary.144d87d2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +6 -0
- package/dist/adapters/mech/adapter.d.ts +21 -1
- package/dist/adapters/mech/adapter.js +77 -10
- package/dist/adapters/mech/adapter.js.map +1 -1
- package/dist/adapters/mech/contracts.js +62 -28
- package/dist/adapters/mech/contracts.js.map +1 -1
- package/dist/adapters/mech/safe-revert.d.ts +4 -0
- package/dist/adapters/mech/safe-revert.js +5 -1
- package/dist/adapters/mech/safe-revert.js.map +1 -1
- package/dist/adapters/mech/safe.js +5 -1
- package/dist/adapters/mech/safe.js.map +1 -1
- package/dist/adapters/mech/verdict-code.js +1 -1
- package/dist/adapters/mech/verdict-code.js.map +1 -1
- package/dist/api/bootstrap-endpoint.d.ts +1 -0
- package/dist/api/bootstrap-endpoint.js +1 -0
- package/dist/api/bootstrap-endpoint.js.map +1 -1
- package/dist/api/discovery-endpoint.d.ts +1 -0
- package/dist/api/discovery-endpoint.js +24 -0
- package/dist/api/discovery-endpoint.js.map +1 -1
- package/dist/api/fleet-build.d.ts +1 -7
- package/dist/api/fleet-build.js +0 -7
- package/dist/api/fleet-build.js.map +1 -1
- package/dist/api/gather-status.d.ts +8 -2
- package/dist/api/gather-status.js +29 -117
- package/dist/api/gather-status.js.map +1 -1
- package/dist/api/loop-completion-build.d.ts +79 -0
- package/dist/api/loop-completion-build.js +155 -0
- package/dist/api/loop-completion-build.js.map +1 -0
- package/dist/api/operator-artifacts-endpoint.js +1 -1
- package/dist/api/operator-artifacts-endpoint.js.map +1 -1
- package/dist/api/peers.js +2 -0
- package/dist/api/peers.js.map +1 -1
- package/dist/api/setup-endpoints.d.ts +32 -0
- package/dist/api/setup-endpoints.js +94 -24
- package/dist/api/setup-endpoints.js.map +1 -1
- package/dist/api/solvernets-endpoints.js +4 -1
- package/dist/api/solvernets-endpoints.js.map +1 -1
- package/dist/api/status-build.d.ts +43 -33
- package/dist/api/status-build.js +3 -26
- package/dist/api/status-build.js.map +1 -1
- package/dist/api/status-rollup-build.d.ts +0 -4
- package/dist/api/status-rollup-build.js +0 -4
- package/dist/api/status-rollup-build.js.map +1 -1
- package/dist/api/stop-hook.d.ts +1 -1
- package/dist/api/stop-hook.js +1 -1
- package/dist/api/stop-hook.js.map +1 -1
- package/dist/build-info.json +4 -4
- package/dist/build-meta.json +1 -1
- package/dist/cli/commands/codedigest-revert-check.js +6 -2
- package/dist/cli/commands/codedigest-revert-check.js.map +1 -1
- package/dist/cli/commands/doctor.d.ts +3 -0
- package/dist/cli/commands/doctor.js +37 -2
- package/dist/cli/commands/doctor.js.map +1 -1
- package/dist/cli/commands/eval.d.ts +87 -0
- package/dist/cli/commands/eval.js +481 -0
- package/dist/cli/commands/eval.js.map +1 -0
- package/dist/cli/commands/rewards.d.ts +2 -0
- package/dist/cli/commands/rewards.js +30 -3
- package/dist/cli/commands/rewards.js.map +1 -1
- package/dist/cli/commands/solver-nets.js +68 -0
- package/dist/cli/commands/solver-nets.js.map +1 -1
- package/dist/cli/commands/status.js +0 -1
- package/dist/cli/commands/status.js.map +1 -1
- package/dist/cli/index.js +2 -0
- package/dist/cli/index.js.map +1 -1
- package/dist/config.d.ts +102 -15
- package/dist/config.js +166 -19
- package/dist/config.js.map +1 -1
- package/dist/daemon/ai-units-gate.d.ts +6 -6
- package/dist/daemon/ai-units-gate.js +11 -10
- package/dist/daemon/ai-units-gate.js.map +1 -1
- package/dist/daemon/balance-topup-loop.js +3 -0
- package/dist/daemon/balance-topup-loop.js.map +1 -1
- package/dist/daemon/checkpoint-loop.js +2 -2
- package/dist/daemon/creator.d.ts +1 -0
- package/dist/daemon/creator.js +26 -14
- package/dist/daemon/creator.js.map +1 -1
- package/dist/daemon/daemon.d.ts +15 -0
- package/dist/daemon/daemon.js +78 -22
- package/dist/daemon/daemon.js.map +1 -1
- package/dist/daemon/eviction-loop.d.ts +7 -0
- package/dist/daemon/eviction-loop.js +19 -3
- package/dist/daemon/eviction-loop.js.map +1 -1
- package/dist/daemon/jinn-claim-loop.js +3 -0
- package/dist/daemon/jinn-claim-loop.js.map +1 -1
- package/dist/daemon/join-applier.d.ts +35 -0
- package/dist/daemon/join-applier.js +49 -0
- package/dist/daemon/join-applier.js.map +1 -0
- package/dist/daemon/loop-heartbeat.d.ts +34 -0
- package/dist/daemon/loop-heartbeat.js +39 -0
- package/dist/daemon/loop-heartbeat.js.map +1 -0
- package/dist/daemon/reward-claim-loop.js +4 -1
- package/dist/daemon/reward-claim-loop.js.map +1 -1
- package/dist/daemon/watchdog-loop.d.ts +84 -0
- package/dist/daemon/watchdog-loop.js +91 -0
- package/dist/daemon/watchdog-loop.js.map +1 -0
- package/dist/dashboard/assets/index-8tAiMbUV.css +1 -0
- package/dist/dashboard/assets/index-D6a-DfaM.js +171 -0
- package/dist/dashboard/index.html +2 -2
- package/dist/discovery/http.d.ts +17 -0
- package/dist/discovery/http.js +295 -25
- package/dist/discovery/http.js.map +1 -1
- package/dist/discovery/onchain.js +155 -1
- package/dist/discovery/onchain.js.map +1 -1
- package/dist/discovery/types.d.ts +106 -0
- package/dist/discovery/types.js +40 -0
- package/dist/discovery/types.js.map +1 -1
- package/dist/discovery/with-fallback.js +14 -0
- package/dist/discovery/with-fallback.js.map +1 -1
- package/dist/earning/bootstrap.d.ts +25 -0
- package/dist/earning/bootstrap.js +79 -28
- package/dist/earning/bootstrap.js.map +1 -1
- package/dist/earning/faucet.d.ts +1 -1
- package/dist/earning/faucet.js +2 -2
- package/dist/earning/faucet.js.map +1 -1
- package/dist/earning/safe-adapter.js +11 -0
- package/dist/earning/safe-adapter.js.map +1 -1
- package/dist/earning/stolas-claim.js +5 -5
- package/dist/earning/types.d.ts +1 -1
- package/dist/earning/types.js +1 -1
- package/dist/earning/types.js.map +1 -1
- package/dist/eval/eval-harness-run.d.ts +63 -0
- package/dist/eval/eval-harness-run.js +123 -0
- package/dist/eval/eval-harness-run.js.map +1 -0
- package/dist/eval/orchestrator.d.ts +224 -0
- package/dist/eval/orchestrator.js +250 -0
- package/dist/eval/orchestrator.js.map +1 -0
- package/dist/eval/paired.d.ts +68 -0
- package/dist/eval/paired.js +93 -0
- package/dist/eval/paired.js.map +1 -0
- package/dist/eval/resolve-slate-tasks.d.ts +35 -0
- package/dist/eval/resolve-slate-tasks.js +56 -0
- package/dist/eval/resolve-slate-tasks.js.map +1 -0
- package/dist/eval/screen-discovery.d.ts +22 -0
- package/dist/eval/screen-discovery.js +71 -0
- package/dist/eval/screen-discovery.js.map +1 -0
- package/dist/eval/screen-progress.d.ts +41 -0
- package/dist/eval/screen-progress.js +60 -0
- package/dist/eval/screen-progress.js.map +1 -0
- package/dist/eval/screen-runner.d.ts +30 -0
- package/dist/eval/screen-runner.js +289 -0
- package/dist/eval/screen-runner.js.map +1 -0
- package/dist/eval/screen.d.ts +107 -0
- package/dist/eval/screen.js +159 -0
- package/dist/eval/screen.js.map +1 -0
- package/dist/eval/slope.d.ts +29 -0
- package/dist/eval/slope.js +46 -0
- package/dist/eval/slope.js.map +1 -0
- package/dist/eval/train-sequence.d.ts +35 -0
- package/dist/eval/train-sequence.js +59 -0
- package/dist/eval/train-sequence.js.map +1 -0
- package/dist/eval/wilson.d.ts +45 -0
- package/dist/eval/wilson.js +48 -0
- package/dist/eval/wilson.js.map +1 -0
- package/dist/events/types.d.ts +1 -1
- package/dist/events/types.js +1 -1
- package/dist/events/types.js.map +1 -1
- package/dist/harnesses/engine/canonical-json.js +5 -3
- package/dist/harnesses/engine/canonical-json.js.map +1 -1
- package/dist/harnesses/engine/engine.d.ts +24 -0
- package/dist/harnesses/engine/engine.js +72 -9
- package/dist/harnesses/engine/engine.js.map +1 -1
- package/dist/harnesses/engine/packaging.js +1 -1
- package/dist/harnesses/engine/packaging.js.map +1 -1
- package/dist/harnesses/engine/persistence.d.ts +17 -0
- package/dist/harnesses/engine/persistence.js +28 -0
- package/dist/harnesses/engine/persistence.js.map +1 -1
- package/dist/harnesses/impls/claude-mcp-hyperliquid/mcp-tools.d.ts +1 -1
- package/dist/harnesses/impls/claude-mcp-hyperliquid/mcp-tools.js +1 -1
- package/dist/harnesses/impls/claude-mcp-hyperliquid/mcp-tools.js.map +1 -1
- package/dist/harnesses/impls/hermes-agent/adapter.d.ts +2 -0
- package/dist/harnesses/impls/hermes-agent/adapter.js +8 -5
- package/dist/harnesses/impls/hermes-agent/adapter.js.map +1 -1
- package/dist/harnesses/impls/hermes-agent/bootstrap.d.ts +1 -0
- package/dist/harnesses/impls/hermes-agent/bootstrap.js +6 -1
- package/dist/harnesses/impls/hermes-agent/bootstrap.js.map +1 -1
- package/dist/harnesses/impls/hermes-agent/harness.d.ts +17 -3
- package/dist/harnesses/impls/hermes-agent/harness.js +68 -5
- package/dist/harnesses/impls/hermes-agent/harness.js.map +1 -1
- package/dist/harnesses/impls/index.d.ts +2 -0
- package/dist/harnesses/impls/index.js +9 -0
- package/dist/harnesses/impls/index.js.map +1 -1
- package/dist/harnesses/impls/jinn-repo-evaluator/eval-runner.d.ts +34 -0
- package/dist/harnesses/impls/jinn-repo-evaluator/eval-runner.js +111 -0
- package/dist/harnesses/impls/jinn-repo-evaluator/eval-runner.js.map +1 -0
- package/dist/harnesses/impls/jinn-repo-evaluator/evaluator.d.ts +24 -0
- package/dist/harnesses/impls/jinn-repo-evaluator/evaluator.js +19 -0
- package/dist/harnesses/impls/jinn-repo-evaluator/evaluator.js.map +1 -0
- package/dist/harnesses/impls/jinn-repo-evaluator/harness.d.ts +64 -0
- package/dist/harnesses/impls/jinn-repo-evaluator/harness.js +125 -0
- package/dist/harnesses/impls/jinn-repo-evaluator/harness.js.map +1 -0
- package/dist/harnesses/impls/jinn-repo-evaluator/repro.d.ts +32 -0
- package/dist/harnesses/impls/jinn-repo-evaluator/repro.js +73 -0
- package/dist/harnesses/impls/jinn-repo-evaluator/repro.js.map +1 -0
- package/dist/harnesses/impls/learner/adapters/claude-code.js +5 -0
- package/dist/harnesses/impls/learner/adapters/claude-code.js.map +1 -1
- package/dist/harnesses/impls/learner/harness.d.ts +17 -1
- package/dist/harnesses/impls/learner/harness.js +51 -1
- package/dist/harnesses/impls/learner/harness.js.map +1 -1
- package/dist/harnesses/impls/learner/harvest.d.ts +2 -0
- package/dist/harnesses/impls/learner/harvest.js +51 -1
- package/dist/harnesses/impls/learner/harvest.js.map +1 -1
- package/dist/harnesses/impls/learner/plugin-path.js +1 -0
- package/dist/harnesses/impls/learner/plugin-path.js.map +1 -1
- package/dist/harnesses/impls/swe-rebench-v2-evaluator/harness.js +3 -1
- package/dist/harnesses/impls/swe-rebench-v2-evaluator/harness.js.map +1 -1
- package/dist/harnesses/impls/swe-rebench-v2-evaluator/index.d.ts +2 -2
- package/dist/harnesses/impls/swe-rebench-v2-evaluator/index.js +3 -1
- package/dist/harnesses/impls/swe-rebench-v2-evaluator/index.js.map +1 -1
- package/dist/harnesses/readiness-registry.d.ts +10 -0
- package/dist/harnesses/readiness-registry.js +13 -0
- package/dist/harnesses/readiness-registry.js.map +1 -1
- package/dist/harnesses/types.d.ts +14 -0
- package/dist/learner/revert-decision.d.ts +16 -1
- package/dist/learner/revert-decision.js +38 -18
- package/dist/learner/revert-decision.js.map +1 -1
- package/dist/learner/revert-stats.d.ts +14 -0
- package/dist/learner/revert-stats.js +42 -0
- package/dist/learner/revert-stats.js.map +1 -1
- package/dist/local-provider-url.d.ts +3 -0
- package/dist/local-provider-url.js +28 -0
- package/dist/local-provider-url.js.map +1 -0
- package/dist/main.js +94 -25
- package/dist/main.js.map +1 -1
- package/dist/mcp/operator-server.js +1 -1
- package/dist/mcp/operator-server.js.map +1 -1
- package/dist/mcp/server.js +1 -1
- package/dist/mcp/server.js.map +1 -1
- package/dist/plugins/learner/.claude-plugin/plugin.json +1 -1
- package/dist/plugins/learner/.codex-plugin/plugin.json +1 -1
- package/dist/plugins/learner/hooks/session-start +30 -1
- package/dist/plugins/learner/skills/learn/consolidator-prompt.md +4 -0
- package/dist/preflight/deployment-readiness.d.ts +147 -0
- package/dist/preflight/deployment-readiness.js +366 -0
- package/dist/preflight/deployment-readiness.js.map +1 -0
- package/dist/preflight/pidfile-liveness.d.ts +7 -1
- package/dist/preflight/pidfile-liveness.js +14 -0
- package/dist/preflight/pidfile-liveness.js.map +1 -1
- package/dist/rpc/transport.d.ts +43 -5
- package/dist/rpc/transport.js +131 -30
- package/dist/rpc/transport.js.map +1 -1
- package/dist/scripts/swe-rebench-v2-seed-pool.json +2 -1
- package/dist/solver-nets/registry.d.ts +19 -0
- package/dist/solver-nets/registry.js +95 -66
- package/dist/solver-nets/registry.js.map +1 -1
- package/dist/solver-types/_jinn-repo-pool.d.ts +27 -0
- package/dist/solver-types/_jinn-repo-pool.js +27 -0
- package/dist/solver-types/_jinn-repo-pool.js.map +1 -0
- package/dist/solver-types/_swe-rebench-v2-held-out-slate.d.ts +76 -0
- package/dist/solver-types/_swe-rebench-v2-held-out-slate.js +156 -0
- package/dist/solver-types/_swe-rebench-v2-held-out-slate.js.map +1 -0
- package/dist/solver-types/_swe-rebench-v2-pool-recovery.d.ts +81 -0
- package/dist/solver-types/_swe-rebench-v2-pool-recovery.js +116 -0
- package/dist/solver-types/_swe-rebench-v2-pool-recovery.js.map +1 -0
- package/dist/solver-types/_swe-rebench-v2-state.d.ts +9 -0
- package/dist/solver-types/_swe-rebench-v2-state.js +14 -0
- package/dist/solver-types/_swe-rebench-v2-state.js.map +1 -1
- package/dist/solver-types/_swe-rebench-v2-validated-pool.d.ts +30 -0
- package/dist/solver-types/_swe-rebench-v2-validated-pool.js +40 -0
- package/dist/solver-types/_swe-rebench-v2-validated-pool.js.map +1 -1
- package/dist/solver-types/index.js +2 -0
- package/dist/solver-types/index.js.map +1 -1
- package/dist/solver-types/jinn-repo-admit.d.ts +17 -0
- package/dist/solver-types/jinn-repo-admit.js +16 -0
- package/dist/solver-types/jinn-repo-admit.js.map +1 -0
- package/dist/solver-types/jinn-repo-auto.d.ts +60 -0
- package/dist/solver-types/jinn-repo-auto.js +163 -0
- package/dist/solver-types/jinn-repo-auto.js.map +1 -0
- package/dist/solver-types/jinn-repo-definition.d.ts +15 -0
- package/dist/solver-types/jinn-repo-definition.js +34 -0
- package/dist/solver-types/jinn-repo-definition.js.map +1 -0
- package/dist/solver-types/jinn-repo-extract.d.ts +16 -0
- package/dist/solver-types/jinn-repo-extract.js +32 -0
- package/dist/solver-types/jinn-repo-extract.js.map +1 -0
- package/dist/solver-types/jinn-repo.d.ts +21 -0
- package/dist/solver-types/jinn-repo.js +23 -0
- package/dist/solver-types/jinn-repo.js.map +1 -0
- package/dist/solver-types/learner-loop-test.js +1 -1
- package/dist/solver-types/learner-loop-test.js.map +1 -1
- package/dist/solver-types/slates/held-out-slate.swe-rebench-v2.v1.json +20 -0
- package/dist/solver-types/slates/held-out-slate.swe-rebench-v2.v2.json +19 -0
- package/dist/solver-types/slates/held-out-slate.swe-rebench-v2.v2.screening-report.json +628 -0
- package/dist/solver-types/solver-type.d.ts +8 -0
- package/dist/solver-types/swe-rebench-v2.d.ts +2 -0
- package/dist/solver-types/swe-rebench-v2.js +115 -10
- package/dist/solver-types/swe-rebench-v2.js.map +1 -1
- package/dist/solvernets/launched-record-dispatcher.d.ts +5 -0
- package/dist/solvernets/launched-record-dispatcher.js +8 -1
- package/dist/solvernets/launched-record-dispatcher.js.map +1 -1
- package/dist/solvernets/registry-client-erc8004.js +29 -37
- package/dist/solvernets/registry-client-erc8004.js.map +1 -1
- package/dist/solvernets/registry-client.d.ts +6 -0
- package/dist/solvernets/store.d.ts +1 -1
- package/dist/solvernets/store.js +8 -3
- package/dist/solvernets/store.js.map +1 -1
- package/dist/spend/ai-units-config.d.ts +10 -0
- package/dist/spend/ai-units-config.js +7 -1
- package/dist/spend/ai-units-config.js.map +1 -1
- package/dist/spend/ai-units.d.ts +51 -0
- package/dist/spend/ai-units.js +73 -0
- package/dist/spend/ai-units.js.map +1 -1
- package/dist/spend/record.js +12 -5
- package/dist/spend/record.js.map +1 -1
- package/dist/store/store.d.ts +91 -5
- package/dist/store/store.js +170 -7
- package/dist/store/store.js.map +1 -1
- package/dist/trajectory/harness-bundle-schema.d.ts +1 -1
- package/dist/trajectory/harness-bundle-schema.js +1 -1
- package/dist/trajectory/harness-bundle-schema.js.map +1 -1
- package/dist/trajectory/schema.d.ts +1 -1
- package/dist/trajectory/schema.js +1 -1
- package/dist/trajectory/schema.js.map +1 -1
- package/dist/trajectory/transcript-parsers/types.d.ts +1 -1
- package/dist/trajectory/transcript-parsers/types.js +1 -1
- package/dist/trajectory/transcript-parsers/types.js.map +1 -1
- package/dist/types/envelope.d.ts +1 -1
- package/dist/types/envelope.js +1 -1
- package/dist/types/envelope.js.map +1 -1
- package/dist/types/payloads/index.d.ts +1 -1
- package/dist/types/payloads/index.js +7 -1
- package/dist/types/payloads/index.js.map +1 -1
- package/dist/types/payloads/portfolio-v0.d.ts +1 -1
- package/dist/types/payloads/portfolio-v0.js +1 -1
- package/dist/types/payloads/portfolio-v0.js.map +1 -1
- package/dist/types/payloads/prediction-apy-v0.d.ts +1 -1
- package/dist/types/payloads/prediction-apy-v0.js +1 -1
- package/dist/types/payloads/prediction-apy-v0.js.map +1 -1
- package/dist/types/payloads/prediction-v0.d.ts +1 -1
- package/dist/types/payloads/prediction-v0.js +1 -1
- package/dist/types/payloads/prediction-v0.js.map +1 -1
- package/dist/types/portfolio.d.ts +1 -1
- package/dist/types/portfolio.js +1 -1
- package/dist/types/portfolio.js.map +1 -1
- package/dist/types/prediction-apy.d.ts +1 -1
- package/dist/types/prediction-apy.js +1 -1
- package/dist/types/prediction-apy.js.map +1 -1
- package/dist/types/prediction.d.ts +1 -1
- package/dist/types/prediction.js +1 -1
- package/dist/types/prediction.js.map +1 -1
- package/dist/types/session-provenance.d.ts +1 -1
- package/dist/types/session-provenance.js +1 -1
- package/dist/types/session-provenance.js.map +1 -1
- package/dist/types/task-document.d.ts +1 -1
- package/dist/types/task-document.js +1 -1
- package/dist/types/task-document.js.map +1 -1
- package/dist/types/task.d.ts +1 -1
- package/dist/types/task.js +1 -1
- package/dist/types/task.js.map +1 -1
- package/dist/types/window.d.ts +1 -1
- package/dist/types/window.js +1 -1
- package/dist/types/window.js.map +1 -1
- package/dist/vendor/@jinn-network/sdk/dist/checkpoint.d.ts +1 -1
- package/dist/vendor/@jinn-network/sdk/dist/checkpoint.js +1 -1
- package/dist/vendor/@jinn-network/sdk/dist/contracts.d.ts +3 -2
- package/dist/vendor/@jinn-network/sdk/dist/contracts.js +49 -0
- package/dist/vendor/@jinn-network/sdk/dist/jinn-repo.d.ts +44 -0
- package/dist/vendor/@jinn-network/sdk/dist/jinn-repo.js +25 -0
- package/dist/vendor/@jinn-network/sdk/dist/json-schema.d.ts +1 -1
- package/dist/vendor/@jinn-network/sdk/dist/json-schema.js +1 -1
- package/dist/vendor/@jinn-network/sdk/dist/payloads/jinn-repo.d.ts +38 -0
- package/dist/vendor/@jinn-network/sdk/dist/payloads/jinn-repo.js +22 -0
- package/dist/vendor/@jinn-network/sdk/dist/payloads/prediction-v1.d.ts +1 -1
- package/dist/vendor/@jinn-network/sdk/dist/payloads/prediction-v1.js +1 -1
- package/dist/vendor/@jinn-network/sdk/dist/payloads/session-derived.d.ts +1 -1
- package/dist/vendor/@jinn-network/sdk/dist/payloads/session-derived.js +1 -1
- package/dist/vendor/@jinn-network/sdk/dist/payloads/swe-rebench-v2.d.ts +109 -2
- package/dist/vendor/@jinn-network/sdk/dist/payloads/swe-rebench-v2.js +26 -2
- package/dist/vendor/@jinn-network/sdk/dist/prediction-v1.d.ts +1 -1
- package/dist/vendor/@jinn-network/sdk/dist/prediction-v1.js +1 -1
- package/dist/vendor/@jinn-network/sdk/dist/solvernets/jinn-repo.d.ts +4 -0
- package/dist/vendor/@jinn-network/sdk/dist/solvernets/jinn-repo.js +2 -0
- package/dist/vendor/@jinn-network/sdk/dist/solvernets/manifest-schema.d.ts +1 -1
- package/dist/vendor/@jinn-network/sdk/dist/solvernets/manifest-schema.js +1 -1
- package/dist/vendor/@jinn-network/sdk/dist/solvernets/swe-rebench-v2-held-out-slate.d.ts +65 -0
- package/dist/vendor/@jinn-network/sdk/dist/solvernets/swe-rebench-v2-held-out-slate.js +123 -0
- package/dist/vendor/@jinn-network/sdk/dist/solvernets/swe-rebench-v2.d.ts +2 -2
- package/dist/vendor/@jinn-network/sdk/dist/solvernets/swe-rebench-v2.js +1 -1
- package/dist/vendor/@jinn-network/sdk/dist/swe-rebench-v2.d.ts +1 -1
- package/dist/vendor/@jinn-network/sdk/dist/swe-rebench-v2.js +1 -1
- package/dist/vendor/@jinn-network/sdk/package.json +9 -1
- package/docker-compose.yml +3 -2
- package/package.json +23 -20
- package/plugins/jinn-repo-runtime/.claude-plugin/plugin.json +5 -0
- package/plugins/jinn-repo-runtime/.codex-plugin/plugin.json +39 -0
- package/plugins/jinn-repo-runtime/README.md +27 -0
- package/plugins/jinn-repo-runtime/hooks/hooks.json +16 -0
- package/plugins/jinn-repo-runtime/hooks/session-start +73 -0
- package/plugins/jinn-repo-runtime/jinn.plugin.json +11 -0
- package/plugins/jinn-repo-runtime/skills/task/SKILL.md +92 -0
- package/plugins/learner/.claude-plugin/plugin.json +1 -1
- package/plugins/learner/.codex-plugin/plugin.json +1 -1
- package/plugins/learner/hooks/session-start +30 -1
- package/plugins/learner/skills/learn/consolidator-prompt.md +4 -0
- package/plugins/swe-rebench-v2-runtime/hooks/hooks.json +16 -0
- package/plugins/swe-rebench-v2-runtime/hooks/session-start +74 -0
- package/dist/dashboard/assets/index-CzKxvMcU.css +0 -32
- package/dist/dashboard/assets/index-yVemxHot.js +0 -351
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"_jinn-repo-pool.js","sourceRoot":"","sources":["../../src/solver-types/_jinn-repo-pool.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AACvC,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AACzC,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CA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
|
+
/**
|
|
2
|
+
* Held-out task slate for the swe-rebench-v2 RL eval harness (issue #817).
|
|
3
|
+
*
|
|
4
|
+
* A slate is a versioned, content-addressed set of swe-rebench-v2
|
|
5
|
+
* `instance_id`s RESERVED from the training pool. The generator excludes
|
|
6
|
+
* slate instances from the train stream so they never enter training; a
|
|
7
|
+
* future eval orchestrator runs solvers against the slate to measure
|
|
8
|
+
* out-of-sample performance. Scores are only comparable *within* a slate
|
|
9
|
+
* version — a version bump (`v2`, …) is a distinct artifact with a distinct
|
|
10
|
+
* content hash, never compared against an earlier version.
|
|
11
|
+
*
|
|
12
|
+
* The artifact ships as a JSON file under `slates/` next to this module
|
|
13
|
+
* (`held-out-slate.swe-rebench-v2.<version>.json`). It carries a self-declared
|
|
14
|
+
* content hash: the loader recomputes a sha256 over the canonicalised,
|
|
15
|
+
* instance-id-sorted artifact and compares it to the file's `hash` field,
|
|
16
|
+
* failing loud on mismatch. This guards against accidental drift — a hand-edit
|
|
17
|
+
* that adds or removes an instance without re-deriving the hash. It is NOT a
|
|
18
|
+
* tamper-proof anchor: the declared hash lives in the same file it verifies, so
|
|
19
|
+
* a deliberate edit that also re-derives the hash passes, and the check is
|
|
20
|
+
* skipped entirely when the `hash` field is absent. A real trust anchor (an
|
|
21
|
+
* external/on-chain hash) is out of scope here.
|
|
22
|
+
*
|
|
23
|
+
* Hashing mirrors `hashVettedPoolArtifact` in `_swe-rebench-v2-validated-pool`:
|
|
24
|
+
* `sha256(canonicalJson(normalized))` with a `sha256:` prefix.
|
|
25
|
+
*/
|
|
26
|
+
import type { PoolTask } from './_swe-rebench-v2-pool.js';
|
|
27
|
+
export declare const HELD_OUT_SLATE_SCHEMA_VERSION: "held-out-slate.v1";
|
|
28
|
+
export interface HeldOutSlateArtifact {
|
|
29
|
+
schemaVersion: typeof HELD_OUT_SLATE_SCHEMA_VERSION;
|
|
30
|
+
solverType: string;
|
|
31
|
+
version: string;
|
|
32
|
+
generatedAt: string;
|
|
33
|
+
instanceIds: string[];
|
|
34
|
+
}
|
|
35
|
+
export interface LoadedHeldOutSlate {
|
|
36
|
+
version: string;
|
|
37
|
+
hash: `sha256:${string}`;
|
|
38
|
+
instanceIds: Set<string>;
|
|
39
|
+
}
|
|
40
|
+
export declare function parseHeldOutSlateArtifact(raw: unknown): HeldOutSlateArtifact;
|
|
41
|
+
export declare function hashHeldOutSlateArtifact(artifact: HeldOutSlateArtifact): `sha256:${string}`;
|
|
42
|
+
/**
|
|
43
|
+
* Load the held-out slate for `solverType` at `version`. Validates the version
|
|
44
|
+
* shape, that the file's declared `solverType`/`version` match the request, and
|
|
45
|
+
* (when a `hash` field is present) that the recomputed content hash matches it —
|
|
46
|
+
* catching accidental edit-without-rehash drift, not deliberate tampering (see
|
|
47
|
+
* the module header). Throws if no slate file exists for the requested version
|
|
48
|
+
* (scores are only comparable within a known version).
|
|
49
|
+
*
|
|
50
|
+
* `opts.dir` overrides the slate file directory; it defaults to the
|
|
51
|
+
* module-relative `slatesDir()`. Production callers omit it (and so resolve the
|
|
52
|
+
* shipped slates); tests inject a temp dir to drive the fail-loud throw paths
|
|
53
|
+
* against malformed fixtures.
|
|
54
|
+
*/
|
|
55
|
+
export declare function loadHeldOutSlate(solverType: string, version: string, opts?: {
|
|
56
|
+
dir?: string;
|
|
57
|
+
}): LoadedHeldOutSlate;
|
|
58
|
+
/**
|
|
59
|
+
* Drop any pool task whose `instance_id` is in the held-out slate. This is the
|
|
60
|
+
* single train-stream exclusion (issue #817 AC#2): the generator is the sole
|
|
61
|
+
* train-stream chokepoint, so a slate instance filtered here is never posted,
|
|
62
|
+
* never claimable, and never trains.
|
|
63
|
+
*/
|
|
64
|
+
export declare function excludeHeldOutSlate(pool: PoolTask[], slateIds: Set<string>): PoolTask[];
|
|
65
|
+
/**
|
|
66
|
+
* Slate versions currently used as held-out exams. The generator excludes the
|
|
67
|
+
* UNION of these from the train stream, so every active exam stays out of
|
|
68
|
+
* training while non-slate instances of every repo remain trainable. Add a
|
|
69
|
+
* version here ONLY when its slate file exists (loadHeldOutSlate fails loud on
|
|
70
|
+
* a missing file).
|
|
71
|
+
*/
|
|
72
|
+
export declare const ACTIVE_HELD_OUT_SLATE_VERSIONS: readonly ["v1", "v2"];
|
|
73
|
+
/** Union of instance ids across the given active slate versions. */
|
|
74
|
+
export declare function loadActiveHeldOutSlateIds(solverType: string, versions: readonly string[], opts?: {
|
|
75
|
+
dir?: string;
|
|
76
|
+
}): Set<string>;
|
|
@@ -0,0 +1,156 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Held-out task slate for the swe-rebench-v2 RL eval harness (issue #817).
|
|
3
|
+
*
|
|
4
|
+
* A slate is a versioned, content-addressed set of swe-rebench-v2
|
|
5
|
+
* `instance_id`s RESERVED from the training pool. The generator excludes
|
|
6
|
+
* slate instances from the train stream so they never enter training; a
|
|
7
|
+
* future eval orchestrator runs solvers against the slate to measure
|
|
8
|
+
* out-of-sample performance. Scores are only comparable *within* a slate
|
|
9
|
+
* version — a version bump (`v2`, …) is a distinct artifact with a distinct
|
|
10
|
+
* content hash, never compared against an earlier version.
|
|
11
|
+
*
|
|
12
|
+
* The artifact ships as a JSON file under `slates/` next to this module
|
|
13
|
+
* (`held-out-slate.swe-rebench-v2.<version>.json`). It carries a self-declared
|
|
14
|
+
* content hash: the loader recomputes a sha256 over the canonicalised,
|
|
15
|
+
* instance-id-sorted artifact and compares it to the file's `hash` field,
|
|
16
|
+
* failing loud on mismatch. This guards against accidental drift — a hand-edit
|
|
17
|
+
* that adds or removes an instance without re-deriving the hash. It is NOT a
|
|
18
|
+
* tamper-proof anchor: the declared hash lives in the same file it verifies, so
|
|
19
|
+
* a deliberate edit that also re-derives the hash passes, and the check is
|
|
20
|
+
* skipped entirely when the `hash` field is absent. A real trust anchor (an
|
|
21
|
+
* external/on-chain hash) is out of scope here.
|
|
22
|
+
*
|
|
23
|
+
* Hashing mirrors `hashVettedPoolArtifact` in `_swe-rebench-v2-validated-pool`:
|
|
24
|
+
* `sha256(canonicalJson(normalized))` with a `sha256:` prefix.
|
|
25
|
+
*/
|
|
26
|
+
import { readFileSync } from 'node:fs';
|
|
27
|
+
import { createHash } from 'node:crypto';
|
|
28
|
+
import { fileURLToPath } from 'node:url';
|
|
29
|
+
import { dirname, resolve as resolvePath, join } from 'node:path';
|
|
30
|
+
import { canonicalJson } from '../harnesses/engine/canonical-json.js';
|
|
31
|
+
export const HELD_OUT_SLATE_SCHEMA_VERSION = 'held-out-slate.v1';
|
|
32
|
+
function isObject(raw) {
|
|
33
|
+
return typeof raw === 'object' && raw !== null;
|
|
34
|
+
}
|
|
35
|
+
export function parseHeldOutSlateArtifact(raw) {
|
|
36
|
+
if (!isObject(raw))
|
|
37
|
+
throw new Error('held-out slate artifact must be an object');
|
|
38
|
+
if (raw['schemaVersion'] !== HELD_OUT_SLATE_SCHEMA_VERSION) {
|
|
39
|
+
throw new Error(`held-out slate schemaVersion must be ${HELD_OUT_SLATE_SCHEMA_VERSION}`);
|
|
40
|
+
}
|
|
41
|
+
if (typeof raw['solverType'] !== 'string' || raw['solverType'].length === 0) {
|
|
42
|
+
throw new Error('held-out slate solverType must be a non-empty string');
|
|
43
|
+
}
|
|
44
|
+
if (typeof raw['version'] !== 'string' || raw['version'].length === 0) {
|
|
45
|
+
throw new Error('held-out slate version must be a non-empty string');
|
|
46
|
+
}
|
|
47
|
+
if (typeof raw['generatedAt'] !== 'string') {
|
|
48
|
+
throw new Error('held-out slate generatedAt must be a string');
|
|
49
|
+
}
|
|
50
|
+
if (!Array.isArray(raw['instanceIds']) ||
|
|
51
|
+
raw['instanceIds'].some((id) => typeof id !== 'string' || id.length === 0)) {
|
|
52
|
+
throw new Error('held-out slate instanceIds must be an array of non-empty strings');
|
|
53
|
+
}
|
|
54
|
+
return {
|
|
55
|
+
schemaVersion: HELD_OUT_SLATE_SCHEMA_VERSION,
|
|
56
|
+
solverType: raw['solverType'],
|
|
57
|
+
version: raw['version'],
|
|
58
|
+
generatedAt: raw['generatedAt'],
|
|
59
|
+
instanceIds: raw['instanceIds'].slice(),
|
|
60
|
+
};
|
|
61
|
+
}
|
|
62
|
+
function normalizeHeldOutSlateArtifact(artifact) {
|
|
63
|
+
return {
|
|
64
|
+
schemaVersion: HELD_OUT_SLATE_SCHEMA_VERSION,
|
|
65
|
+
solverType: artifact.solverType,
|
|
66
|
+
version: artifact.version,
|
|
67
|
+
generatedAt: artifact.generatedAt,
|
|
68
|
+
instanceIds: [...artifact.instanceIds].sort((a, b) => a.localeCompare(b)),
|
|
69
|
+
};
|
|
70
|
+
}
|
|
71
|
+
export function hashHeldOutSlateArtifact(artifact) {
|
|
72
|
+
const canonical = canonicalJson(normalizeHeldOutSlateArtifact(artifact));
|
|
73
|
+
return `sha256:${createHash('sha256').update(canonical).digest('hex')}`;
|
|
74
|
+
}
|
|
75
|
+
/**
|
|
76
|
+
* Resolve the slate file directory. At runtime the compiled module lives at
|
|
77
|
+
* `dist/solver-types/<this>.js` and the slate JSON at `dist/solver-types/slates/`
|
|
78
|
+
* (copied during `yarn build`); in dev/test the source module is at
|
|
79
|
+
* `src/solver-types/<this>.ts` with the slate JSON at `src/solver-types/slates/`.
|
|
80
|
+
* `./slates` resolves correctly in both layouts.
|
|
81
|
+
*/
|
|
82
|
+
function slatesDir() {
|
|
83
|
+
return resolvePath(dirname(fileURLToPath(import.meta.url)), 'slates');
|
|
84
|
+
}
|
|
85
|
+
function slateFileName(solverType, version) {
|
|
86
|
+
if (!/^v\d+$/.test(version)) {
|
|
87
|
+
throw new Error(`held-out slate version must match /^v\\d+$/ (got ${JSON.stringify(version)})`);
|
|
88
|
+
}
|
|
89
|
+
return `held-out-slate.${solverType.replace(/\.v\d+$/, '')}.${version}.json`;
|
|
90
|
+
}
|
|
91
|
+
/**
|
|
92
|
+
* Load the held-out slate for `solverType` at `version`. Validates the version
|
|
93
|
+
* shape, that the file's declared `solverType`/`version` match the request, and
|
|
94
|
+
* (when a `hash` field is present) that the recomputed content hash matches it —
|
|
95
|
+
* catching accidental edit-without-rehash drift, not deliberate tampering (see
|
|
96
|
+
* the module header). Throws if no slate file exists for the requested version
|
|
97
|
+
* (scores are only comparable within a known version).
|
|
98
|
+
*
|
|
99
|
+
* `opts.dir` overrides the slate file directory; it defaults to the
|
|
100
|
+
* module-relative `slatesDir()`. Production callers omit it (and so resolve the
|
|
101
|
+
* shipped slates); tests inject a temp dir to drive the fail-loud throw paths
|
|
102
|
+
* against malformed fixtures.
|
|
103
|
+
*/
|
|
104
|
+
export function loadHeldOutSlate(solverType, version, opts = {}) {
|
|
105
|
+
const path = join(opts.dir ?? slatesDir(), slateFileName(solverType, version));
|
|
106
|
+
let raw;
|
|
107
|
+
try {
|
|
108
|
+
raw = readFileSync(path, 'utf8');
|
|
109
|
+
}
|
|
110
|
+
catch {
|
|
111
|
+
throw new Error(`held-out slate not found for solverType=${solverType} version=${version} (expected ${path})`);
|
|
112
|
+
}
|
|
113
|
+
const parsed = JSON.parse(raw);
|
|
114
|
+
const artifact = parseHeldOutSlateArtifact(parsed);
|
|
115
|
+
if (artifact.version !== version) {
|
|
116
|
+
throw new Error(`held-out slate version mismatch: file declares ${artifact.version}, requested ${version}`);
|
|
117
|
+
}
|
|
118
|
+
if (artifact.solverType !== solverType) {
|
|
119
|
+
throw new Error(`held-out slate solverType mismatch: file declares ${artifact.solverType}, requested ${solverType}`);
|
|
120
|
+
}
|
|
121
|
+
const hash = hashHeldOutSlateArtifact(artifact);
|
|
122
|
+
const declared = parsed['hash'];
|
|
123
|
+
if (typeof declared === 'string' && declared !== hash) {
|
|
124
|
+
throw new Error(`held-out slate hash mismatch for ${solverType} ${version}: declared ${declared}, computed ${hash} (artifact was edited without re-deriving the hash)`);
|
|
125
|
+
}
|
|
126
|
+
return { version: artifact.version, hash, instanceIds: new Set(artifact.instanceIds) };
|
|
127
|
+
}
|
|
128
|
+
/**
|
|
129
|
+
* Drop any pool task whose `instance_id` is in the held-out slate. This is the
|
|
130
|
+
* single train-stream exclusion (issue #817 AC#2): the generator is the sole
|
|
131
|
+
* train-stream chokepoint, so a slate instance filtered here is never posted,
|
|
132
|
+
* never claimable, and never trains.
|
|
133
|
+
*/
|
|
134
|
+
export function excludeHeldOutSlate(pool, slateIds) {
|
|
135
|
+
if (slateIds.size === 0)
|
|
136
|
+
return pool;
|
|
137
|
+
return pool.filter((task) => !slateIds.has(task.instance_id));
|
|
138
|
+
}
|
|
139
|
+
/**
|
|
140
|
+
* Slate versions currently used as held-out exams. The generator excludes the
|
|
141
|
+
* UNION of these from the train stream, so every active exam stays out of
|
|
142
|
+
* training while non-slate instances of every repo remain trainable. Add a
|
|
143
|
+
* version here ONLY when its slate file exists (loadHeldOutSlate fails loud on
|
|
144
|
+
* a missing file).
|
|
145
|
+
*/
|
|
146
|
+
export const ACTIVE_HELD_OUT_SLATE_VERSIONS = ['v1', 'v2'];
|
|
147
|
+
/** Union of instance ids across the given active slate versions. */
|
|
148
|
+
export function loadActiveHeldOutSlateIds(solverType, versions, opts = {}) {
|
|
149
|
+
const ids = new Set();
|
|
150
|
+
for (const version of versions) {
|
|
151
|
+
for (const id of loadHeldOutSlate(solverType, version, opts).instanceIds)
|
|
152
|
+
ids.add(id);
|
|
153
|
+
}
|
|
154
|
+
return ids;
|
|
155
|
+
}
|
|
156
|
+
//# sourceMappingURL=_swe-rebench-v2-held-out-slate.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"_swe-rebench-v2-held-out-slate.js","sourceRoot":"","sources":["../../src/solver-types/_swe-rebench-v2-held-out-slate.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AAEH,OAAO,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AACvC,OAAO,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AACzC,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AACzC,OAAO,EAAE,OAAO,EAAE,OAAO,IAAI,WAAW,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AAClE,OAAO,EAA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KAAK,CACb,oCAAoC,UAAU,IAAI,OAAO,cAAc,QAAQ,cAAc,IAAI,qDAAqD,CACvJ,CAAC;IACJ,CAAC;IACD,OAAO,EAAE,OAAO,EAAE,QAAQ,CAAC,OAAO,EAAE,IAAI,EAAE,WAAW,EAAE,IAAI,GAAG,CAAC,QAAQ,CAAC,WAAW,CAAC,EAAE,CAAC;AACzF,CAAC;AAED;;;;;GAKG;AACH,MAAM,UAAU,mBAAmB,CAAC,IAAgB,EAAE,QAAqB;IACzE,IAAI,QAAQ,CAAC,IAAI,KAAK,CAAC;QAAE,OAAO,IAAI,CAAC;IACrC,OAAO,IAAI,CAAC,MAAM,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,CAAC,QAAQ,CAAC,GAAG,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC,CAAC;AAChE,CAAC;AAED;;;;;;GAMG;AACH,MAAM,CAAC,MAAM,8BAA8B,GAAG,CAAC,IAAI,EAAE,IAAI,CAAU,CAAC;AAEpE,oEAAoE;AACpE,MAAM,UAAU,yBAAyB,CACvC,UAAkB,EAClB,QAA2B,EAC3B,OAAyB,EAAE;IAE3B,MAAM,GAAG,GAAG,IAAI,GAAG,EAAU,CAAC;IAC9B,KAAK,MAAM,OAAO,IAAI,QAAQ,EAAE,CAAC;QAC/B,KAAK,MAAM,EAAE,IAAI,gBAAgB,CAAC,UAAU,EAAE,OAAO,EAAE,IAAI,CAAC,CAAC,WAAW;YAAE,GAAG,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC;IACxF,CAAC;IACD,OAAO,GAAG,CAAC;AACb,CAAC"}
|
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Fresh-volume vetted-pool recovery for the swe-rebench-v2 generator (#957).
|
|
3
|
+
*
|
|
4
|
+
* A freshly-deployed operator has an empty disk: no `validated-pool.json`, so
|
|
5
|
+
* the generator's admission gate hits `admission-required-no-data` and posts 0
|
|
6
|
+
* tasks. The vetted pool was previously published to IPFS; we recover it via the
|
|
7
|
+
* indexer (DR-2026-06-02 open-question #4, Option B — read the artifact ref via
|
|
8
|
+
* the DiscoveryAPI, not on-chain directly):
|
|
9
|
+
*
|
|
10
|
+
* 1. `discoveryApi.getMostRecentTaskCidDigest(manifestCid)` → a recent task's
|
|
11
|
+
* on-chain `taskCidDigest` (pure indexer/chain read; no IPFS in discovery).
|
|
12
|
+
* 2. Reconstruct the IPFS task CID (`f01551220 + digestHexWithout0x`, the same
|
|
13
|
+
* derivation as `adapters/mech/adapter.ts`) and fetch the task body.
|
|
14
|
+
* 3. Read the vetted-pool ref from the task's `eligibility.vettedPoolRef`
|
|
15
|
+
* (`VETTED_POOL_REF_ELIGIBILITY_KEY`).
|
|
16
|
+
* 4. Fetch + parse the artifact at `ref.artifactCid`.
|
|
17
|
+
* 5. SECURITY: verify `hashVettedPoolArtifact(artifact) === ref.artifactHash`.
|
|
18
|
+
* A mismatch is REJECTED — no file is written.
|
|
19
|
+
* 6. Write the scorable entries into `validated-pool.json` via
|
|
20
|
+
* `ValidatedPoolStore.record`. After a successful recovery the generator's
|
|
21
|
+
* existing `resolvePublishedVettedPool` / pool-load path picks up the now-
|
|
22
|
+
* present `validated-pool.json`.
|
|
23
|
+
*
|
|
24
|
+
* Never-overwrite: if a local validated pool already exists for the current
|
|
25
|
+
* `EVAL_SEMANTICS_VERSION`, recovery is a no-op (`local-pool-present`) — the same
|
|
26
|
+
* "don't clobber newer local data" stance as `resolvePublishedVettedPool`'s
|
|
27
|
+
* `validatedNewer` guard.
|
|
28
|
+
*
|
|
29
|
+
* Fail-closed: every external call is wrapped so any failure returns a structured
|
|
30
|
+
* `{ recovered: false, reason }`. Recovery NEVER throws — it must fall through to
|
|
31
|
+
* the existing `admission-required-no-data` path so a recovery failure can never
|
|
32
|
+
* crash the generator tick.
|
|
33
|
+
*/
|
|
34
|
+
import { ValidatedPoolStore } from './_swe-rebench-v2-validated-pool.js';
|
|
35
|
+
import type { DiscoveryAPI } from '../discovery/types.js';
|
|
36
|
+
export interface RecoverVettedPoolResult {
|
|
37
|
+
recovered: boolean;
|
|
38
|
+
/**
|
|
39
|
+
* Why recovery did not complete (only set when `recovered === false`):
|
|
40
|
+
* - `local-pool-present` — a local validated pool already exists; not clobbered.
|
|
41
|
+
* - `no-task` — the indexer reports no task for the manifest yet.
|
|
42
|
+
* - `no-ref` — the recovered task carries no `vettedPoolRef` eligibility.
|
|
43
|
+
* - `hash-mismatch` — the fetched artifact's hash did not match the ref (SECURITY).
|
|
44
|
+
* - `error:<msg>` — any external call failed (discovery / IPFS / parse).
|
|
45
|
+
*/
|
|
46
|
+
reason?: string;
|
|
47
|
+
/** Count of scorable entries written, on a successful recovery. */
|
|
48
|
+
entriesRecovered?: number;
|
|
49
|
+
}
|
|
50
|
+
/**
|
|
51
|
+
* Whether a recovery outcome is TERMINAL — i.e. retrying cannot help, so the
|
|
52
|
+
* caller should latch permanently and never attempt recovery again:
|
|
53
|
+
*
|
|
54
|
+
* - `recovered === true` — done; the pool was written.
|
|
55
|
+
* - `local-pool-present` — a local pool already exists; nothing to recover.
|
|
56
|
+
*
|
|
57
|
+
* All other outcomes (`no-task`, `no-ref`, `error:*`, `hash-mismatch`) are
|
|
58
|
+
* TRANSIENT/retryable, so the caller must NOT latch on them (it retries under a
|
|
59
|
+
* bounded cap instead):
|
|
60
|
+
* - `no-task` — a fresh SolverNet may not have posted its first task yet.
|
|
61
|
+
* - `no-ref` — the task's eligibility may not yet carry a vettedPoolRef.
|
|
62
|
+
* - `error:*` — the indexer / IPFS gateway may be having a transient blip.
|
|
63
|
+
* - `hash-mismatch` — the fetched artifact's hash didn't match the ref. This is
|
|
64
|
+
* SECURITY-rejected at write time (the bad artifact is NEVER written), and it
|
|
65
|
+
* can be transient: a corrupted IPFS-gateway response may fetch cleanly on a
|
|
66
|
+
* later attempt, or the launcher may re-publish a corrected ref that a later
|
|
67
|
+
* task carries. Retrying re-resolves the most-recent task's ref AND re-fetches
|
|
68
|
+
* from IPFS, so a corrected pool is picked up without a restart; the bounded
|
|
69
|
+
* retry cap prevents looping on a genuinely-bad ref.
|
|
70
|
+
*/
|
|
71
|
+
export declare function isTerminalRecoveryOutcome(result: RecoverVettedPoolResult): boolean;
|
|
72
|
+
export interface RecoverVettedPoolDeps {
|
|
73
|
+
stateDir: string;
|
|
74
|
+
manifestCid: string;
|
|
75
|
+
discoveryApi: DiscoveryAPI;
|
|
76
|
+
ipfsGatewayUrl: string;
|
|
77
|
+
store: ValidatedPoolStore;
|
|
78
|
+
/** Injected so tests can stub the IPFS round-trip; production passes `fetchFromIpfs`. */
|
|
79
|
+
fetchFromIpfs: (gatewayUrl: string, cid: string) => Promise<unknown>;
|
|
80
|
+
}
|
|
81
|
+
export declare function recoverVettedPoolFromNetwork(deps: RecoverVettedPoolDeps): Promise<RecoverVettedPoolResult>;
|
|
@@ -0,0 +1,116 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Fresh-volume vetted-pool recovery for the swe-rebench-v2 generator (#957).
|
|
3
|
+
*
|
|
4
|
+
* A freshly-deployed operator has an empty disk: no `validated-pool.json`, so
|
|
5
|
+
* the generator's admission gate hits `admission-required-no-data` and posts 0
|
|
6
|
+
* tasks. The vetted pool was previously published to IPFS; we recover it via the
|
|
7
|
+
* indexer (DR-2026-06-02 open-question #4, Option B — read the artifact ref via
|
|
8
|
+
* the DiscoveryAPI, not on-chain directly):
|
|
9
|
+
*
|
|
10
|
+
* 1. `discoveryApi.getMostRecentTaskCidDigest(manifestCid)` → a recent task's
|
|
11
|
+
* on-chain `taskCidDigest` (pure indexer/chain read; no IPFS in discovery).
|
|
12
|
+
* 2. Reconstruct the IPFS task CID (`f01551220 + digestHexWithout0x`, the same
|
|
13
|
+
* derivation as `adapters/mech/adapter.ts`) and fetch the task body.
|
|
14
|
+
* 3. Read the vetted-pool ref from the task's `eligibility.vettedPoolRef`
|
|
15
|
+
* (`VETTED_POOL_REF_ELIGIBILITY_KEY`).
|
|
16
|
+
* 4. Fetch + parse the artifact at `ref.artifactCid`.
|
|
17
|
+
* 5. SECURITY: verify `hashVettedPoolArtifact(artifact) === ref.artifactHash`.
|
|
18
|
+
* A mismatch is REJECTED — no file is written.
|
|
19
|
+
* 6. Write the scorable entries into `validated-pool.json` via
|
|
20
|
+
* `ValidatedPoolStore.record`. After a successful recovery the generator's
|
|
21
|
+
* existing `resolvePublishedVettedPool` / pool-load path picks up the now-
|
|
22
|
+
* present `validated-pool.json`.
|
|
23
|
+
*
|
|
24
|
+
* Never-overwrite: if a local validated pool already exists for the current
|
|
25
|
+
* `EVAL_SEMANTICS_VERSION`, recovery is a no-op (`local-pool-present`) — the same
|
|
26
|
+
* "don't clobber newer local data" stance as `resolvePublishedVettedPool`'s
|
|
27
|
+
* `validatedNewer` guard.
|
|
28
|
+
*
|
|
29
|
+
* Fail-closed: every external call is wrapped so any failure returns a structured
|
|
30
|
+
* `{ recovered: false, reason }`. Recovery NEVER throws — it must fall through to
|
|
31
|
+
* the existing `admission-required-no-data` path so a recovery failure can never
|
|
32
|
+
* crash the generator tick.
|
|
33
|
+
*/
|
|
34
|
+
import { EVAL_SEMANTICS_VERSION, vettedPoolArtifactRefFromEligibility, parseVettedPoolArtifact, hashVettedPoolArtifact, } from './_swe-rebench-v2-validated-pool.js';
|
|
35
|
+
/**
|
|
36
|
+
* Whether a recovery outcome is TERMINAL — i.e. retrying cannot help, so the
|
|
37
|
+
* caller should latch permanently and never attempt recovery again:
|
|
38
|
+
*
|
|
39
|
+
* - `recovered === true` — done; the pool was written.
|
|
40
|
+
* - `local-pool-present` — a local pool already exists; nothing to recover.
|
|
41
|
+
*
|
|
42
|
+
* All other outcomes (`no-task`, `no-ref`, `error:*`, `hash-mismatch`) are
|
|
43
|
+
* TRANSIENT/retryable, so the caller must NOT latch on them (it retries under a
|
|
44
|
+
* bounded cap instead):
|
|
45
|
+
* - `no-task` — a fresh SolverNet may not have posted its first task yet.
|
|
46
|
+
* - `no-ref` — the task's eligibility may not yet carry a vettedPoolRef.
|
|
47
|
+
* - `error:*` — the indexer / IPFS gateway may be having a transient blip.
|
|
48
|
+
* - `hash-mismatch` — the fetched artifact's hash didn't match the ref. This is
|
|
49
|
+
* SECURITY-rejected at write time (the bad artifact is NEVER written), and it
|
|
50
|
+
* can be transient: a corrupted IPFS-gateway response may fetch cleanly on a
|
|
51
|
+
* later attempt, or the launcher may re-publish a corrected ref that a later
|
|
52
|
+
* task carries. Retrying re-resolves the most-recent task's ref AND re-fetches
|
|
53
|
+
* from IPFS, so a corrected pool is picked up without a restart; the bounded
|
|
54
|
+
* retry cap prevents looping on a genuinely-bad ref.
|
|
55
|
+
*/
|
|
56
|
+
export function isTerminalRecoveryOutcome(result) {
|
|
57
|
+
if (result.recovered)
|
|
58
|
+
return true;
|
|
59
|
+
return result.reason === 'local-pool-present';
|
|
60
|
+
}
|
|
61
|
+
export async function recoverVettedPoolFromNetwork(deps) {
|
|
62
|
+
const { stateDir: _stateDir, manifestCid, discoveryApi, ipfsGatewayUrl, store, fetchFromIpfs } = deps;
|
|
63
|
+
void _stateDir; // reserved for symmetry with resolvePublishedVettedPool; store already binds stateDir
|
|
64
|
+
try {
|
|
65
|
+
// Never-overwrite guard: a local validated pool already present (operator
|
|
66
|
+
// validated locally, or a prior recovery ran) → do not clobber it.
|
|
67
|
+
const existing = await store.getScorableIds(EVAL_SEMANTICS_VERSION);
|
|
68
|
+
if (existing !== null) {
|
|
69
|
+
return { recovered: false, reason: 'local-pool-present' };
|
|
70
|
+
}
|
|
71
|
+
// 1) Most-recent task digest for the SolverNet (pure indexer/chain read).
|
|
72
|
+
const recent = await discoveryApi.getMostRecentTaskCidDigest(manifestCid);
|
|
73
|
+
if (!recent)
|
|
74
|
+
return { recovered: false, reason: 'no-task' };
|
|
75
|
+
// 2) Reconstruct the IPFS task CID and fetch the task body. Lowercase the
|
|
76
|
+
// digest defensively (NIT #7): the on-chain bytes32 is lowercase, but a
|
|
77
|
+
// future uppercase-emitting indexer must not produce a wrong CID.
|
|
78
|
+
const taskCid = `f01551220${recent.taskCidDigest.replace(/^0x/, '').toLowerCase()}`;
|
|
79
|
+
const taskDoc = await fetchFromIpfs(ipfsGatewayUrl, taskCid);
|
|
80
|
+
// 3) Read the vetted-pool ref from the task's eligibility.
|
|
81
|
+
const eligibility = taskDoc?.eligibility;
|
|
82
|
+
const ref = vettedPoolArtifactRefFromEligibility(eligibility);
|
|
83
|
+
if (ref === null)
|
|
84
|
+
return { recovered: false, reason: 'no-ref' };
|
|
85
|
+
// 4) Fetch + parse the artifact.
|
|
86
|
+
const rawArtifact = await fetchFromIpfs(ipfsGatewayUrl, ref.artifactCid);
|
|
87
|
+
const artifact = parseVettedPoolArtifact(rawArtifact);
|
|
88
|
+
// 5) SECURITY: verify the artifact hash against the ref before writing.
|
|
89
|
+
if (hashVettedPoolArtifact(artifact) !== ref.artifactHash) {
|
|
90
|
+
return { recovered: false, reason: 'hash-mismatch' };
|
|
91
|
+
}
|
|
92
|
+
// 6) Write the scorable entries into validated-pool.json. Record under the
|
|
93
|
+
// artifact's evalSemanticsVersion so the generator's read path picks them up
|
|
94
|
+
// for the matching version. Each artifact entry is scorable by construction.
|
|
95
|
+
for (const entry of artifact.entries) {
|
|
96
|
+
const poolEntry = {
|
|
97
|
+
scorable: true,
|
|
98
|
+
reason: entry.reason,
|
|
99
|
+
checkedAt: entry.checkedAt,
|
|
100
|
+
...(entry.rowHash ? { rowHash: entry.rowHash } : {}),
|
|
101
|
+
...(entry.imageName ? { imageName: entry.imageName } : {}),
|
|
102
|
+
...(entry.imageDigest ? { imageDigest: entry.imageDigest } : {}),
|
|
103
|
+
...(entry.upstreamEvalCommit ? { upstreamEvalCommit: entry.upstreamEvalCommit } : {}),
|
|
104
|
+
};
|
|
105
|
+
await store.record(entry.instance_id, poolEntry, artifact.evalSemanticsVersion);
|
|
106
|
+
}
|
|
107
|
+
return { recovered: true, entriesRecovered: artifact.entries.length };
|
|
108
|
+
}
|
|
109
|
+
catch (err) {
|
|
110
|
+
// Fail-closed: any failure (discovery, IPFS, parse) must NOT throw — return a
|
|
111
|
+
// structured result so the generator falls through to admission-required-no-data.
|
|
112
|
+
const message = err instanceof Error ? err.message : String(err);
|
|
113
|
+
return { recovered: false, reason: `error:${message}` };
|
|
114
|
+
}
|
|
115
|
+
}
|
|
116
|
+
//# sourceMappingURL=_swe-rebench-v2-pool-recovery.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"_swe-rebench-v2-pool-recovery.js","sourceRoot":"","sources":["../../src/solver-types/_swe-rebench-v2-pool-recovery.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAgCG;AAEH,OAAO,EAEL,sBAAsB,EACtB,oCAAoC,EACpC,uBAAuB,EACvB,sBAAsB,GAEvB,MAAM,qCAAqC,CAAC;AAkB7C;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,MAAM,UAAU,yBAAyB,CAAC,MAA+B;IACvE,IAAI,MAAM,CAAC,SAAS;QAAE,OAAO,IAAI,CAAC;IAClC,OAAO,MAAM,CAAC,MAAM,KAAK,oBAAoB,CAAC;AAChD,CAAC;AAYD,MAAM,CAAC,KAAK,UAAU,4BAA4B,CAChD,IAA2B;IAE3B,MAAM,EAAE,QAAQ,EAAE,SAAS,EAAE,WAAW,EAAE,YAAY,EAAE,cAAc,EAAE,KAAK,EAAE,aAAa,EAAE,GAAG,IAAI,CAAC;IACtG,KAAK,SAAS,CAAC,CAAC,sFAAsF;IAEtG,IAAI,CAAC;QACH,0EAA0E;QAC1E,mEAAmE;QACnE,MAAM,QAAQ,GAAG,MAAM,KAAK,CAAC,cAAc,CAAC,sBAAsB,CAAC,CAAC;QACpE,IAAI,QAAQ,KAAK,IAAI,EAAE,CAAC;YACtB,OAAO,EAAE,SAAS,EAAE,KAAK,EAAE,MAAM,EAAE,oBAAoB,EAAE,CAAC;QAC5D,CAAC;QAED,0EAA0E;QAC1E,MAAM,MAAM,GAAG,MAAM,YAAY,CAAC,0BAA0B,CAAC,W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C,OAAO,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;gBACpD,GAAG,CAAC,KAAK,CAAC,SAAS,CAAC,CAAC,CAAC,EAAE,SAAS,EAAE,KAAK,CAAC,SAAS,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;gBAC1D,GAAG,CAAC,KAAK,CAAC,WAAW,CAAC,CAAC,CAAC,EAAE,WAAW,EAAE,KAAK,CAAC,WAAW,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;gBAChE,GAAG,CAAC,KAAK,CAAC,kBAAkB,CAAC,CAAC,CAAC,EAAE,kBAAkB,EAAE,KAAK,CAAC,kBAAkB,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;aACtF,CAAC;YACF,MAAM,KAAK,CAAC,MAAM,CAAC,KAAK,CAAC,WAAW,EAAE,SAAS,EAAE,QAAQ,CAAC,oBAAoB,CAAC,CAAC;QAClF,CAAC;QAED,OAAO,EAAE,SAAS,EAAE,IAAI,EAAE,gBAAgB,EAAE,QAAQ,CAAC,OAAO,CAAC,MAAM,EAAE,CAAC;IACxE,CAAC;IAAC,OAAO,GAAG,EAAE,CAAC;QACb,8EAA8E;QAC9E,kFAAkF;QAClF,MAAM,OAAO,GAAG,GAAG,YAAY,KAAK,CAAC,CAAC,CAAC,GAAG,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC;QACjE,OAAO,EAAE,SAAS,EAAE,KAAK,EAAE,MAAM,EAAE,SAAS,OAAO,EAAE,EAAE,CAAC;IAC1D,CAAC;AACH,CAAC"}
|
|
@@ -33,6 +33,15 @@ export declare class GeneratorStateStore {
|
|
|
33
33
|
invalidate(): void;
|
|
34
34
|
private save;
|
|
35
35
|
getCounters(instance_id: string): Promise<TaskCounters>;
|
|
36
|
+
/**
|
|
37
|
+
* Instance ids this generator has posted at least once — i.e. that entered
|
|
38
|
+
* the SolverNet train stream. Used by held-out screening (#986) to keep the
|
|
39
|
+
* exam to the never-posted remainder (a posted task may have been trained on,
|
|
40
|
+
* so holding it out later would make a trained-checkpoint pass memorization,
|
|
41
|
+
* not generalization). This is THIS launcher's posting history; complete for a
|
|
42
|
+
* single-launcher SolverNet.
|
|
43
|
+
*/
|
|
44
|
+
postedInstanceIds(): Promise<Set<string>>;
|
|
36
45
|
recordPosted(instance_id: string, now?: number): Promise<void>;
|
|
37
46
|
recordSuccess(instance_id: string): Promise<void>;
|
|
38
47
|
recordLastTaskId(instance_id: string, taskId: string): Promise<void>;
|
|
@@ -47,6 +47,20 @@ export class GeneratorStateStore {
|
|
|
47
47
|
const state = await this.load();
|
|
48
48
|
return state.tasks[instance_id] ?? { posted: 0, successful: 0, last_posted_at: 0 };
|
|
49
49
|
}
|
|
50
|
+
/**
|
|
51
|
+
* Instance ids this generator has posted at least once — i.e. that entered
|
|
52
|
+
* the SolverNet train stream. Used by held-out screening (#986) to keep the
|
|
53
|
+
* exam to the never-posted remainder (a posted task may have been trained on,
|
|
54
|
+
* so holding it out later would make a trained-checkpoint pass memorization,
|
|
55
|
+
* not generalization). This is THIS launcher's posting history; complete for a
|
|
56
|
+
* single-launcher SolverNet.
|
|
57
|
+
*/
|
|
58
|
+
async postedInstanceIds() {
|
|
59
|
+
const state = await this.load();
|
|
60
|
+
return new Set(Object.entries(state.tasks)
|
|
61
|
+
.filter(([, c]) => c.posted > 0)
|
|
62
|
+
.map(([id]) => id));
|
|
63
|
+
}
|
|
50
64
|
async recordPosted(instance_id, now = Date.now()) {
|
|
51
65
|
const state = await this.load();
|
|
52
66
|
const c = state.tasks[instance_id] ?? { posted: 0, successful: 0, last_posted_at: 0 };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"_swe-rebench-v2-state.js","sourceRoot":"","sources":["../../src/solver-types/_swe-rebench-v2-state.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAAE,QAAQ,EAAE,SAAS,EAAE,KAAK,EAAE,MAAM,kBAAkB,CAAC;AAC9D,OAAO,EAAE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,CAAC,CAAC,cAAc,GAAG,GAAG,CAAC;QACvB,KAAK,CAAC,KAAK,CAAC,WAAW,CAAC,GAAG,CAAC,CAAC;QAC7B,MAAM,IAAI,CAAC,IAAI,EAAE,CAAC;IACpB,CAAC;IAED,KAAK,CAAC,aAAa,CAAC,WAAmB;QACrC,MAAM,KAAK,GAAG,MAAM,IAAI,CAAC,IAAI,EAAE,CAAC;QAChC,MAAM,CAAC,GAAG,KAAK,CAAC,KAAK,CAAC,WAAW,CAAC,IAAI,EAAE,MAAM,EAAE,CAAC,EAAE,UAAU,EAAE,CAAC,EAAE,cAAc,EAAE,CAAC,EAAE,CAAC;QACtF,CAAC,CAAC,UAAU,IAAI,CAAC,CAAC;QAClB,KAAK,CAAC,KAAK,CAAC,WAAW,CAAC,GAAG,CAAC,CAAC;QAC7B,MAAM,IAAI,CAAC,IAAI,EAAE,CAAC;IACpB,CAAC;IAED,KAAK,CAAC,gBAAgB,CAAC,WAAmB,EAAE,MAAc;QACxD,MAAM,KAAK,GAAG,MAAM,IAAI,CAAC,IAAI,EAAE,CAAC;QAChC,MAAM,CAAC,GAAG,KAAK,CAAC,KAAK,CAAC,WAAW,CAAC,IAAI,EAAE,MAAM,EAAE,CAAC,EAAE,UAAU,EAAE,CAAC,EAAE,cAAc,EAAE,CAAC,EAAE,CAAC;QACtF,CAAC,CAAC,YAAY,GAAG,MAAM,CAAC;QACxB,KAAK,CAAC,KAAK,CAAC,WAAW,CAAC,GAAG,CAAC,CAAC;QAC7B,MAAM,IAAI,CAAC,IAAI,EAAE,CAAC;IACpB,CAAC;CACF"}
|
|
@@ -141,6 +141,36 @@ export interface ScorableVettedPoolArtifactEntries {
|
|
|
141
141
|
export declare function parseVettedPoolArtifact(raw: unknown): SweRebenchV2VettedPoolArtifact;
|
|
142
142
|
export declare function hashVettedPoolArtifact(artifact: SweRebenchV2VettedPoolArtifact): `sha256:${string}`;
|
|
143
143
|
export declare function loadVettedPoolArtifactScorableEntries(raw: unknown): ScorableVettedPoolArtifactEntries;
|
|
144
|
+
/**
|
|
145
|
+
* Substrate-level held-out exclusion (#986). Returns a copy of the artifact with
|
|
146
|
+
* the `excludeIds` instances dropped, so the PUBLISHED vetted-pool artifact — the
|
|
147
|
+
* shared substrate every generator can source its postable set from — never lists
|
|
148
|
+
* the held-out exam. This moves the exclusion up from each generator's posting
|
|
149
|
+
* decision (which only a generator running the slate code honours) to the artifact
|
|
150
|
+
* itself, so a fresh-recovery / independent / unguarded generator that reads the
|
|
151
|
+
* artifact cannot post the exam tasks either. Pure; never mutates its input. The
|
|
152
|
+
* caller re-hashes via `hashVettedPoolArtifact`.
|
|
153
|
+
*/
|
|
154
|
+
export declare function excludeFromVettedPoolArtifact(artifact: SweRebenchV2VettedPoolArtifact, excludeIds: ReadonlySet<string>): SweRebenchV2VettedPoolArtifact;
|
|
155
|
+
/**
|
|
156
|
+
* Republication decision (#986). The published artifact is authoritative and
|
|
157
|
+
* write-once: it is NOT re-synced to local scorable unless the validated pool is
|
|
158
|
+
* strictly newer (the prior timestamp-gated behaviour, preserved here). But a
|
|
159
|
+
* timestamp-only check never fires when the *held-out set* changes while the
|
|
160
|
+
* validated pool is unchanged — so adding the exclusion in code, or activating a
|
|
161
|
+
* new slate version (e.g. `v3`), would leave the live artifact stale (still
|
|
162
|
+
* listing now-held-out instances) indefinitely. The narrow extra trigger:
|
|
163
|
+
* republish when the existing publication is CONTAMINATED — it still lists a
|
|
164
|
+
* now-held-out instance. This forces exactly the rollout / slate-bump refresh
|
|
165
|
+
* and nothing more (it does NOT republish merely because the publication diverges
|
|
166
|
+
* from local scorable, which would break the write-once / published-authoritative
|
|
167
|
+
* contract other operators recover against).
|
|
168
|
+
*/
|
|
169
|
+
export declare function shouldRepublishVettedPool(args: {
|
|
170
|
+
existingIds: ReadonlySet<string> | null;
|
|
171
|
+
heldOutIds: ReadonlySet<string>;
|
|
172
|
+
validatedNewer: boolean;
|
|
173
|
+
}): boolean;
|
|
144
174
|
export declare function createVettedPoolArtifactRef(args: {
|
|
145
175
|
manifestCid: string;
|
|
146
176
|
artifactCid: string;
|
|
@@ -260,6 +260,46 @@ export function loadVettedPoolArtifactScorableEntries(raw) {
|
|
|
260
260
|
}
|
|
261
261
|
return { ids: new Set(byId.keys()), byId };
|
|
262
262
|
}
|
|
263
|
+
/**
|
|
264
|
+
* Substrate-level held-out exclusion (#986). Returns a copy of the artifact with
|
|
265
|
+
* the `excludeIds` instances dropped, so the PUBLISHED vetted-pool artifact — the
|
|
266
|
+
* shared substrate every generator can source its postable set from — never lists
|
|
267
|
+
* the held-out exam. This moves the exclusion up from each generator's posting
|
|
268
|
+
* decision (which only a generator running the slate code honours) to the artifact
|
|
269
|
+
* itself, so a fresh-recovery / independent / unguarded generator that reads the
|
|
270
|
+
* artifact cannot post the exam tasks either. Pure; never mutates its input. The
|
|
271
|
+
* caller re-hashes via `hashVettedPoolArtifact`.
|
|
272
|
+
*/
|
|
273
|
+
export function excludeFromVettedPoolArtifact(artifact, excludeIds) {
|
|
274
|
+
if (excludeIds.size === 0)
|
|
275
|
+
return artifact;
|
|
276
|
+
return { ...artifact, entries: artifact.entries.filter((e) => !excludeIds.has(e.instance_id)) };
|
|
277
|
+
}
|
|
278
|
+
/**
|
|
279
|
+
* Republication decision (#986). The published artifact is authoritative and
|
|
280
|
+
* write-once: it is NOT re-synced to local scorable unless the validated pool is
|
|
281
|
+
* strictly newer (the prior timestamp-gated behaviour, preserved here). But a
|
|
282
|
+
* timestamp-only check never fires when the *held-out set* changes while the
|
|
283
|
+
* validated pool is unchanged — so adding the exclusion in code, or activating a
|
|
284
|
+
* new slate version (e.g. `v3`), would leave the live artifact stale (still
|
|
285
|
+
* listing now-held-out instances) indefinitely. The narrow extra trigger:
|
|
286
|
+
* republish when the existing publication is CONTAMINATED — it still lists a
|
|
287
|
+
* now-held-out instance. This forces exactly the rollout / slate-bump refresh
|
|
288
|
+
* and nothing more (it does NOT republish merely because the publication diverges
|
|
289
|
+
* from local scorable, which would break the write-once / published-authoritative
|
|
290
|
+
* contract other operators recover against).
|
|
291
|
+
*/
|
|
292
|
+
export function shouldRepublishVettedPool(args) {
|
|
293
|
+
if (!args.existingIds)
|
|
294
|
+
return true;
|
|
295
|
+
if (args.validatedNewer)
|
|
296
|
+
return true;
|
|
297
|
+
for (const id of args.existingIds) {
|
|
298
|
+
if (args.heldOutIds.has(id))
|
|
299
|
+
return true;
|
|
300
|
+
}
|
|
301
|
+
return false;
|
|
302
|
+
}
|
|
263
303
|
export function createVettedPoolArtifactRef(args) {
|
|
264
304
|
return {
|
|
265
305
|
schemaVersion: SOLVERNET_ARTIFACT_REF_SCHEMA_VERSION,
|