@hona/openeval 0.2.0
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/JUDGING.md +123 -0
- package/LICENSE +21 -0
- package/README.md +133 -0
- package/package.json +39 -0
- package/src/app/add-models.ts +18 -0
- package/src/app/context.ts +15 -0
- package/src/app/cost-plan.ts +118 -0
- package/src/app/eval-state.ts +10 -0
- package/src/app/execution-budget.ts +65 -0
- package/src/app/execution-runtime.ts +63 -0
- package/src/app/input-fingerprints.ts +67 -0
- package/src/app/judge-evidence.ts +71 -0
- package/src/app/judge-run.ts +89 -0
- package/src/app/load-benchmark.ts +267 -0
- package/src/app/merge-runs.ts +117 -0
- package/src/app/monitor-policy.ts +49 -0
- package/src/app/plan-benchmark.ts +127 -0
- package/src/app/read-results.ts +524 -0
- package/src/app/read-run.ts +43 -0
- package/src/app/rejudge.ts +127 -0
- package/src/app/retry-run.ts +87 -0
- package/src/app/run-benchmark.ts +401 -0
- package/src/app/run-eval-pipeline.ts +333 -0
- package/src/app/run-eval.ts +93 -0
- package/src/app/scores.ts +54 -0
- package/src/app/serve-results.ts +252 -0
- package/src/app/snapshot-run.ts +42 -0
- package/src/app/watch-evidence.ts +61 -0
- package/src/cli.ts +145 -0
- package/src/evidence.ts +40 -0
- package/src/index.ts +53 -0
- package/src/infra/containers/candidate.ts +218 -0
- package/src/infra/containers/docker.ts +31 -0
- package/src/infra/containers/oci.ts +335 -0
- package/src/infra/containers/runtime/.dockerignore +7 -0
- package/src/infra/containers/runtime/Dockerfile +19 -0
- package/src/infra/containers/runtime/development-container +19 -0
- package/src/infra/containers/runtime/noninteractive/index.mjs +7 -0
- package/src/infra/containers/runtime/noninteractive/package.json +6 -0
- package/src/infra/containers/runtime/package.json +10 -0
- package/src/infra/containers/runtime/server.mjs +32 -0
- package/src/infra/containers/transfer.ts +144 -0
- package/src/infra/containers/workspace.ts +304 -0
- package/src/infra/evidence/index.ts +783 -0
- package/src/infra/evidence/tool-calls.ts +49 -0
- package/src/infra/files.ts +74 -0
- package/src/infra/judging/agent.ts +61 -0
- package/src/infra/judging/contract.ts +207 -0
- package/src/infra/judging/evidence-tool.ts +79 -0
- package/src/infra/judging/index.ts +115 -0
- package/src/infra/judging/judge-agent.md +80 -0
- package/src/infra/judging/observer.ts +168 -0
- package/src/infra/judging/submission.ts +138 -0
- package/src/infra/judging/tools.ts +145 -0
- package/src/infra/opencode/archive.ts +81 -0
- package/src/infra/opencode/auth.ts +119 -0
- package/src/infra/opencode/checkpoint.ts +68 -0
- package/src/infra/opencode/host.ts +40 -0
- package/src/infra/opencode/read-recording.ts +42 -0
- package/src/infra/opencode/session.ts +321 -0
- package/src/infra/sqlite/index.ts +636 -0
- package/src/infra/sqlite/schema.ts +57 -0
- package/src/judgment.ts +40 -0
- package/src/runtime.ts +60 -0
- package/src/session-replay.ts +245 -0
- package/src/types.ts +302 -0
- package/src/view.ts +269 -0
- package/viewer/THIRD_PARTY_LICENSES.md +3039 -0
- package/viewer/assets/Inter-c8O0ljhh.ttf +0 -0
- package/viewer/assets/JetBrainsMonoNerdFontMono-Regular-BmWcHh8R.woff2 +0 -0
- package/viewer/assets/KaTeX_AMS-Regular-BQhdFMY1.woff2 +0 -0
- package/viewer/assets/KaTeX_AMS-Regular-DMm9YOAa.woff +0 -0
- package/viewer/assets/KaTeX_AMS-Regular-DRggAlZN.ttf +0 -0
- package/viewer/assets/KaTeX_Caligraphic-Bold-ATXxdsX0.ttf +0 -0
- package/viewer/assets/KaTeX_Caligraphic-Bold-BEiXGLvX.woff +0 -0
- package/viewer/assets/KaTeX_Caligraphic-Bold-Dq_IR9rO.woff2 +0 -0
- package/viewer/assets/KaTeX_Caligraphic-Regular-CTRA-rTL.woff +0 -0
- package/viewer/assets/KaTeX_Caligraphic-Regular-Di6jR-x-.woff2 +0 -0
- package/viewer/assets/KaTeX_Caligraphic-Regular-wX97UBjC.ttf +0 -0
- package/viewer/assets/KaTeX_Fraktur-Bold-BdnERNNW.ttf +0 -0
- package/viewer/assets/KaTeX_Fraktur-Bold-BsDP51OF.woff +0 -0
- package/viewer/assets/KaTeX_Fraktur-Bold-CL6g_b3V.woff2 +0 -0
- package/viewer/assets/KaTeX_Fraktur-Regular-CB_wures.ttf +0 -0
- package/viewer/assets/KaTeX_Fraktur-Regular-CTYiF6lA.woff2 +0 -0
- package/viewer/assets/KaTeX_Fraktur-Regular-Dxdc4cR9.woff +0 -0
- package/viewer/assets/KaTeX_Main-Bold-Cx986IdX.woff2 +0 -0
- package/viewer/assets/KaTeX_Main-Bold-Jm3AIy58.woff +0 -0
- package/viewer/assets/KaTeX_Main-Bold-waoOVXN0.ttf +0 -0
- package/viewer/assets/KaTeX_Main-BoldItalic-DxDJ3AOS.woff2 +0 -0
- package/viewer/assets/KaTeX_Main-BoldItalic-DzxPMmG6.ttf +0 -0
- package/viewer/assets/KaTeX_Main-BoldItalic-SpSLRI95.woff +0 -0
- package/viewer/assets/KaTeX_Main-Italic-3WenGoN9.ttf +0 -0
- package/viewer/assets/KaTeX_Main-Italic-BMLOBm91.woff +0 -0
- package/viewer/assets/KaTeX_Main-Italic-NWA7e6Wa.woff2 +0 -0
- package/viewer/assets/KaTeX_Main-Regular-B22Nviop.woff2 +0 -0
- package/viewer/assets/KaTeX_Main-Regular-Dr94JaBh.woff +0 -0
- package/viewer/assets/KaTeX_Main-Regular-ypZvNtVU.ttf +0 -0
- package/viewer/assets/KaTeX_Math-BoldItalic-B3XSjfu4.ttf +0 -0
- package/viewer/assets/KaTeX_Math-BoldItalic-CZnvNsCZ.woff2 +0 -0
- package/viewer/assets/KaTeX_Math-BoldItalic-iY-2wyZ7.woff +0 -0
- package/viewer/assets/KaTeX_Math-Italic-DA0__PXp.woff +0 -0
- package/viewer/assets/KaTeX_Math-Italic-flOr_0UB.ttf +0 -0
- package/viewer/assets/KaTeX_Math-Italic-t53AETM-.woff2 +0 -0
- package/viewer/assets/KaTeX_SansSerif-Bold-CFMepnvq.ttf +0 -0
- package/viewer/assets/KaTeX_SansSerif-Bold-D1sUS0GD.woff2 +0 -0
- package/viewer/assets/KaTeX_SansSerif-Bold-DbIhKOiC.woff +0 -0
- package/viewer/assets/KaTeX_SansSerif-Italic-C3H0VqGB.woff2 +0 -0
- package/viewer/assets/KaTeX_SansSerif-Italic-DN2j7dab.woff +0 -0
- package/viewer/assets/KaTeX_SansSerif-Italic-YYjJ1zSn.ttf +0 -0
- package/viewer/assets/KaTeX_SansSerif-Regular-BNo7hRIc.ttf +0 -0
- package/viewer/assets/KaTeX_SansSerif-Regular-CS6fqUqJ.woff +0 -0
- package/viewer/assets/KaTeX_SansSerif-Regular-DDBCnlJ7.woff2 +0 -0
- package/viewer/assets/KaTeX_Script-Regular-C5JkGWo-.ttf +0 -0
- package/viewer/assets/KaTeX_Script-Regular-D3wIWfF6.woff2 +0 -0
- package/viewer/assets/KaTeX_Script-Regular-D5yQViql.woff +0 -0
- package/viewer/assets/KaTeX_Size1-Regular-C195tn64.woff +0 -0
- package/viewer/assets/KaTeX_Size1-Regular-Dbsnue_I.ttf +0 -0
- package/viewer/assets/KaTeX_Size1-Regular-mCD8mA8B.woff2 +0 -0
- package/viewer/assets/KaTeX_Size2-Regular-B7gKUWhC.ttf +0 -0
- package/viewer/assets/KaTeX_Size2-Regular-Dy4dx90m.woff2 +0 -0
- package/viewer/assets/KaTeX_Size2-Regular-oD1tc_U0.woff +0 -0
- package/viewer/assets/KaTeX_Size3-Regular-CTq5MqoE.woff +0 -0
- package/viewer/assets/KaTeX_Size3-Regular-DgpXs0kz.ttf +0 -0
- package/viewer/assets/KaTeX_Size4-Regular-BF-4gkZK.woff +0 -0
- package/viewer/assets/KaTeX_Size4-Regular-DWFBv043.ttf +0 -0
- package/viewer/assets/KaTeX_Size4-Regular-Dl5lxZxV.woff2 +0 -0
- package/viewer/assets/KaTeX_Typewriter-Regular-C0xS9mPB.woff +0 -0
- package/viewer/assets/KaTeX_Typewriter-Regular-CO6r4hn1.woff2 +0 -0
- package/viewer/assets/KaTeX_Typewriter-Regular-D3Ib7_Hf.ttf +0 -0
- package/viewer/assets/abap-CLvhMVsD.js +1 -0
- package/viewer/assets/abnfDiagram-VCTEODGH-B1kcYgQG.js +1 -0
- package/viewer/assets/actionscript-3-Cs6JJXT5.js +1 -0
- package/viewer/assets/ada-C5qYipkI.js +1 -0
- package/viewer/assets/ahk-CA9gdOdF.js +1 -0
- package/viewer/assets/ahk2-_6rzW9BS.js +1 -0
- package/viewer/assets/amoled-DB5yy8ad.js +1 -0
- package/viewer/assets/andromeeda-vGVdxbeo.js +1 -0
- package/viewer/assets/angular-html-DrYCUiZv.js +1 -0
- package/viewer/assets/angular-ts-BgjwQn-Z.js +1 -0
- package/viewer/assets/apache-U0d_L8uA.js +1 -0
- package/viewer/assets/apex-KFGFyKwG.js +1 -0
- package/viewer/assets/apl-DlHqe8o4.js +1 -0
- package/viewer/assets/applescript-CCn79oCD.js +1 -0
- package/viewer/assets/ara-4CJ0cIlV.js +1 -0
- package/viewer/assets/arc-C4nf7ZoY.js +1 -0
- package/viewer/assets/architecture-7GRP2DOG-Be250VKZ.js +1 -0
- package/viewer/assets/architectureDiagram-5GKGNRK7-BIWoe0fO.js +36 -0
- package/viewer/assets/array-BifhSqXX.js +1 -0
- package/viewer/assets/asciidoc-SCjQUq34.js +1 -0
- package/viewer/assets/asm-Cmm7eHzH.js +1 -0
- package/viewer/assets/astro-BrlHnIh9.js +1 -0
- package/viewer/assets/aura-BpwPh8WE.js +1 -0
- package/viewer/assets/aurora-x-CDeNXAV0.js +1 -0
- package/viewer/assets/awk-BWXHIvNe.js +1 -0
- package/viewer/assets/ayu-BkUPVVqh.js +1 -0
- package/viewer/assets/ayu-dark-DluEY0Gj.js +1 -0
- package/viewer/assets/ayu-light-C3h-C4tm.js +1 -0
- package/viewer/assets/ayu-mirage-Bqwy1Gya.js +1 -0
- package/viewer/assets/ballerina-B7ZEbQpA.js +1 -0
- package/viewer/assets/bat-qdxAdBWQ.js +1 -0
- package/viewer/assets/beancount-D-usSTwE.js +1 -0
- package/viewer/assets/berry-DKpUyyne.js +1 -0
- package/viewer/assets/bibtex-Ci_nEsc7.js +1 -0
- package/viewer/assets/bicep-CUHmPFLl.js +1 -0
- package/viewer/assets/bird2-CYIUgYqB.js +1 -0
- package/viewer/assets/blade-DOcerOiW.js +1 -0
- package/viewer/assets/blockDiagram-I7D4REHJ-C3x13a9m.js +129 -0
- package/viewer/assets/bsl-_VjlB9mv.js +1 -0
- package/viewer/assets/c-BMbThxEo.js +1 -0
- package/viewer/assets/c3-D0apG41V.js +1 -0
- package/viewer/assets/c4Diagram-7LVT6UL2-BeWktchx.js +38 -0
- package/viewer/assets/cadence-CQ2zXKGN.js +1 -0
- package/viewer/assets/cairo-DLTphjLi.js +1 -0
- package/viewer/assets/carbonfox-Bo2FTw5U.js +1 -0
- package/viewer/assets/catppuccin-DK9M8P0P.js +1 -0
- package/viewer/assets/catppuccin-frappe-C9Q5zVZY.js +1 -0
- package/viewer/assets/catppuccin-frappe-DIKI31zD.js +1 -0
- package/viewer/assets/catppuccin-latte-CtsyrtPq.js +1 -0
- package/viewer/assets/catppuccin-macchiato-DYnJ67qk.js +1 -0
- package/viewer/assets/catppuccin-macchiato-R8nAf1vR.js +1 -0
- package/viewer/assets/catppuccin-mocha-DjuaAJKi.js +1 -0
- package/viewer/assets/channel-DtULXRee.js +1 -0
- package/viewer/assets/chapel-k2cjkSmc.js +1 -0
- package/viewer/assets/chunk-2Q5K7J3B-C1jixKkw.js +1 -0
- package/viewer/assets/chunk-4HAMMTFA-o6YtJsqE.js +62 -0
- package/viewer/assets/chunk-5VM5RSS4-ZNzvKenW.js +15 -0
- package/viewer/assets/chunk-75Z2AOVW-KohQa9Nw.js +2 -0
- package/viewer/assets/chunk-DU6HZSFF-C88wxc6m.js +127 -0
- package/viewer/assets/chunk-F27PBJKO-mO4AP2as.js +1 -0
- package/viewer/assets/chunk-FOHPRMQF-CoA4358r.js +161 -0
- package/viewer/assets/chunk-GMAD6QVW-DzQX2Cld.js +72 -0
- package/viewer/assets/chunk-GVQU2GXP-CS78RfJD.js +1 -0
- package/viewer/assets/chunk-IMKFNOWR-DxS42GUo.js +231 -0
- package/viewer/assets/chunk-JWPE2WC7-DVXcaiue.js +1 -0
- package/viewer/assets/chunk-L3NEJ4N5-DGo-uYLy.js +1 -0
- package/viewer/assets/chunk-OSK3NFVY-BOcXQG16.js +10 -0
- package/viewer/assets/chunk-P2QGCYS3-B7GnZdIQ.js +1 -0
- package/viewer/assets/chunk-POPQ4Y6H-DgBcYHog.js +1 -0
- package/viewer/assets/chunk-PWAF6VOD-DpEq6qHA.js +1 -0
- package/viewer/assets/chunk-SHT3W25Y-CrOGxKM2.js +168 -0
- package/viewer/assets/chunk-SVP7TREG-4HY7Fljj.js +88 -0
- package/viewer/assets/chunk-TICWLB2K-B1Rl31EC.js +206 -0
- package/viewer/assets/chunk-XXDRQBXY-CK8giEW-.js +1 -0
- package/viewer/assets/chunk-Y2CYZVJY-DsF7k-Jl.js +1 -0
- package/viewer/assets/clarity-CtfBBspg.js +1 -0
- package/viewer/assets/classDiagram-ZZMXUADV-Bmqu01Xf.js +1 -0
- package/viewer/assets/classDiagram-v2-VYDZK3BY-Bmqu01Xf.js +1 -0
- package/viewer/assets/clojure-DqKBuwfJ.js +1 -0
- package/viewer/assets/cmake-Bj61d0ZC.js +1 -0
- package/viewer/assets/cobalt2-DQbhSfAX.js +1 -0
- package/viewer/assets/cobol-CupUwvw9.js +1 -0
- package/viewer/assets/codeowners-C8r90Shi.js +1 -0
- package/viewer/assets/codeql-oeQT6MSM.js +1 -0
- package/viewer/assets/coffee-C17pkozF.js +1 -0
- package/viewer/assets/common-lisp-Cv5bFMCO.js +1 -0
- package/viewer/assets/coq-DuBRPxYg.js +1 -0
- package/viewer/assets/cose-bilkent-JH36ORCC-V1OmrmCv.js +1 -0
- package/viewer/assets/cpp-BJwVQVXg.js +1 -0
- package/viewer/assets/crystal-BF-oCN-L.js +1 -0
- package/viewer/assets/csharp-oqKa8noW.js +1 -0
- package/viewer/assets/css-BMgkVI3c.js +1 -0
- package/viewer/assets/csv-Dx-8-gkx.js +1 -0
- package/viewer/assets/cue-CE9AQfxI.js +1 -0
- package/viewer/assets/cursor-t2F-UZH_.js +1 -0
- package/viewer/assets/cynefin-OW5HDTMX-BEjY_gsc.js +1 -0
- package/viewer/assets/cynefinDiagram-5FMLGOSQ-bfSYgr6z.js +62 -0
- package/viewer/assets/cypher-ClKdZ_lG.js +1 -0
- package/viewer/assets/cytoscape.esm-B-1iW2ft.js +321 -0
- package/viewer/assets/d-qD-0Kul2.js +1 -0
- package/viewer/assets/dagre-C-rnJpZF.js +1 -0
- package/viewer/assets/dagre-GXQ25YYZ-VtwTgGfa.js +4 -0
- package/viewer/assets/dark-plus-Cs2F2srj.js +1 -0
- package/viewer/assets/dart-CnvKMtbv.js +1 -0
- package/viewer/assets/dax-BkyTk9wS.js +1 -0
- package/viewer/assets/defaultLocale-BFoDCU3G.js +1 -0
- package/viewer/assets/desktop-Dlh5hvp9.js +1 -0
- package/viewer/assets/diagram-S7CK7UJ4-CHaAAyW7.js +30 -0
- package/viewer/assets/diagram-UQ7AKVKN-CjL65-As.js +41 -0
- package/viewer/assets/diagram-VSXAHHWV-Cnxrk1TJ.js +3 -0
- package/viewer/assets/diagram-VX7I27RA-D78jPXr7.js +24 -0
- package/viewer/assets/diagram-Z3DM3KII-DKjnOaF2.js +24 -0
- package/viewer/assets/diff-woXpYk--.js +1 -0
- package/viewer/assets/dist-BTYPW0dz.js +1 -0
- package/viewer/assets/docker-IyjqRm3v.js +1 -0
- package/viewer/assets/dotenv-_5a1GRtc.js +1 -0
- package/viewer/assets/dracula-BHWKrbxM.js +1 -0
- package/viewer/assets/dracula-C3s659y-.js +1 -0
- package/viewer/assets/dracula-soft-5eyTD99u.js +1 -0
- package/viewer/assets/dream-maker-DW3nJb8Q.js +1 -0
- package/viewer/assets/ebnfDiagram-PWID7BFC-7XiXh5Lx.js +1 -0
- package/viewer/assets/edge-B34N_HjN.js +1 -0
- package/viewer/assets/elixir-CQzWMyKD.js +1 -0
- package/viewer/assets/elm-BNJiG-wg.js +1 -0
- package/viewer/assets/emacs-lisp-c_oH4hRZ.js +1 -0
- package/viewer/assets/erDiagram-RLTQ6QDP-YPFEgZxU.js +99 -0
- package/viewer/assets/erb-D5Rm3UNa.js +1 -0
- package/viewer/assets/erlang-Cphh6RMH.js +1 -0
- package/viewer/assets/eventmodeling-NTZA5JFV-CJCg5f6p.js +1 -0
- package/viewer/assets/everforest-BEfZxV1e.js +1 -0
- package/viewer/assets/everforest-dark-sB-x3p7T.js +1 -0
- package/viewer/assets/everforest-light-Df2xbC6M.js +1 -0
- package/viewer/assets/fennel-DQxkIbk2.js +1 -0
- package/viewer/assets/fish-BJitypiv.js +1 -0
- package/viewer/assets/flexoki-Dj5gUbwm.js +1 -0
- package/viewer/assets/flowDiagram-HODETNUW-BFzq4Zvs.js +1 -0
- package/viewer/assets/fluent-C03EYrpw.js +1 -0
- package/viewer/assets/fortran-fixed-form-DEKoE2YW.js +1 -0
- package/viewer/assets/fortran-free-form-CYNrtFtB.js +1 -0
- package/viewer/assets/fsharp-D13ZGOAj.js +1 -0
- package/viewer/assets/ganttDiagram-EL5Y4UJY-ergSGtTP.js +292 -0
- package/viewer/assets/gdresource-xMC7jr7x.js +1 -0
- package/viewer/assets/gdscript-DYvRD3hg.js +1 -0
- package/viewer/assets/gdshader-CBce3t8t.js +1 -0
- package/viewer/assets/genie-CV2tkWYe.js +1 -0
- package/viewer/assets/gherkin-DExj1W_8.js +1 -0
- package/viewer/assets/git-commit-BSykSTBG.js +1 -0
- package/viewer/assets/git-rebase-BpIMZIRG.js +1 -0
- package/viewer/assets/gitGraph-4MIJSDKK-CZt4REVj.js +1 -0
- package/viewer/assets/gitGraphDiagram-WWUBYQGX-h9QMzC2r.js +106 -0
- package/viewer/assets/github-DukYz3BY.js +1 -0
- package/viewer/assets/github-dark-C-LZuMrd.js +1 -0
- package/viewer/assets/github-dark-default-DXG-b-1a.js +1 -0
- package/viewer/assets/github-dark-dimmed-Bx1FflLF.js +1 -0
- package/viewer/assets/github-dark-high-contrast-B_tTalzw.js +1 -0
- package/viewer/assets/github-light-EUqPIrTm.js +1 -0
- package/viewer/assets/github-light-default-BXViO-2h.js +1 -0
- package/viewer/assets/github-light-high-contrast-B68TUdTA.js +1 -0
- package/viewer/assets/gleam-CSRkHgEL.js +1 -0
- package/viewer/assets/glimmer-js-SeSwns5_.js +1 -0
- package/viewer/assets/glimmer-ts-BExI5tTz.js +1 -0
- package/viewer/assets/glsl-CXikKw2b.js +1 -0
- package/viewer/assets/gn-ilITqXS6.js +1 -0
- package/viewer/assets/gnuplot-7GGW24-e.js +1 -0
- package/viewer/assets/go-rLFTqkRN.js +1 -0
- package/viewer/assets/graphlib-DS17s2tU.js +1 -0
- package/viewer/assets/graphql-6GpQIInt.js +1 -0
- package/viewer/assets/groovy-CacY0gHj.js +1 -0
- package/viewer/assets/gruvbox-dark-hard-C820rvS2.js +1 -0
- package/viewer/assets/gruvbox-dark-medium-BPjhmG05.js +1 -0
- package/viewer/assets/gruvbox-dark-soft-MrdJrrXF.js +1 -0
- package/viewer/assets/gruvbox-light-hard-BC_s9l72.js +1 -0
- package/viewer/assets/gruvbox-light-medium-BAWPOn9u.js +1 -0
- package/viewer/assets/gruvbox-light-soft-BSMLrYjP.js +1 -0
- package/viewer/assets/gruvbox-mhPG2W60.js +1 -0
- package/viewer/assets/hack-i7rizvpB.js +1 -0
- package/viewer/assets/haml-C68gmkTf.js +1 -0
- package/viewer/assets/handlebars-BBn_c0Xt.js +1 -0
- package/viewer/assets/haskell-D8IpX4py.js +1 -0
- package/viewer/assets/haxe-C8oCnwJJ.js +1 -0
- package/viewer/assets/hcl-Dh228itO.js +1 -0
- package/viewer/assets/hjson-CxZEssPk.js +1 -0
- package/viewer/assets/hlsl-Cvrh5tZx.js +1 -0
- package/viewer/assets/horizon-CE9ld1lL.js +1 -0
- package/viewer/assets/horizon-bright-DSNQnXHK.js +1 -0
- package/viewer/assets/houston-CsvMBhTu.js +1 -0
- package/viewer/assets/html-BObmAZQA.js +1 -0
- package/viewer/assets/html-derivative-BjMuR1LM.js +1 -0
- package/viewer/assets/http-BJBk8gt0.js +1 -0
- package/viewer/assets/hurl-D7obCYfg.js +1 -0
- package/viewer/assets/hxml-Dcm88srW.js +1 -0
- package/viewer/assets/hy-CZbG8q4J.js +1 -0
- package/viewer/assets/imba-DsUTQ-LC.js +1 -0
- package/viewer/assets/index-FMtYXcX7.js +793 -0
- package/viewer/assets/index-Wz0qQyIk.css +2 -0
- package/viewer/assets/info-A6RAGUB7-CrzitQIU.js +1 -0
- package/viewer/assets/infoDiagram-27XIBGKW-D2CgRDxu.js +2 -0
- package/viewer/assets/ini-B5eOa1yu.js +1 -0
- package/viewer/assets/init-C-OQMol4.js +1 -0
- package/viewer/assets/ishikawaDiagram-5VMMS53U-BhnQMHOo.js +70 -0
- package/viewer/assets/java-5VJU_EW8.js +1 -0
- package/viewer/assets/javascript-r8UgndxQ.js +1 -0
- package/viewer/assets/jinja-BY2ibHG5.js +1 -0
- package/viewer/assets/jison-C_7YxymZ.js +1 -0
- package/viewer/assets/journeyDiagram-3NMN7TZE-DSBzKQEa.js +139 -0
- package/viewer/assets/json-8e1WlJYD.js +1 -0
- package/viewer/assets/json5-BR5RXkoi.js +1 -0
- package/viewer/assets/jsonc-CYpm1nAK.js +1 -0
- package/viewer/assets/jsonl-CmCQp5Yx.js +1 -0
- package/viewer/assets/jsonnet-CJTPZ8u_.js +1 -0
- package/viewer/assets/jssm-DXw9l8Rf.js +1 -0
- package/viewer/assets/jsx-BYp5GD4Y.js +1 -0
- package/viewer/assets/julia-Bkob1uVX.js +1 -0
- package/viewer/assets/just-CUnSjty-.js +1 -0
- package/viewer/assets/kanagawa-D0YhNhTs.js +1 -0
- package/viewer/assets/kanagawa-dragon-Bozd7klA.js +1 -0
- package/viewer/assets/kanagawa-lotus-BmuOG9ZW.js +1 -0
- package/viewer/assets/kanagawa-wave-BML5mF2J.js +1 -0
- package/viewer/assets/kanban-definition-UXKFOSKX-CotbrQue.js +89 -0
- package/viewer/assets/katex-ZlcWpGUi.js +257 -0
- package/viewer/assets/kdl-CsD5j6eV.js +1 -0
- package/viewer/assets/kotlin-DhhofPvG.js +1 -0
- package/viewer/assets/kusto-C7mF5XQf.js +1 -0
- package/viewer/assets/laserwave-C_8bwKvT.js +1 -0
- package/viewer/assets/latex-UdE3ivqk.js +1 -0
- package/viewer/assets/lean-CewbzKMR.js +1 -0
- package/viewer/assets/less-DVTAwKKz.js +1 -0
- package/viewer/assets/light-plus-DVQuIRkW.js +1 -0
- package/viewer/assets/line-DDh6a6hz.js +1 -0
- package/viewer/assets/linear-BxMsCbKb.js +1 -0
- package/viewer/assets/liquid-WL4MvEIT.js +1 -0
- package/viewer/assets/llvm-DqHOMS-s.js +1 -0
- package/viewer/assets/log-BNLmms1o.js +1 -0
- package/viewer/assets/logo-Cluzi2Zq.js +1 -0
- package/viewer/assets/lua-CtOubZta.js +1 -0
- package/viewer/assets/luau-C2pBCSgt.js +1 -0
- package/viewer/assets/lucent-orng-DLA2Fg5T.js +1 -0
- package/viewer/assets/make-Dixweg8N.js +1 -0
- package/viewer/assets/markdown-BYOwaDjH.js +1 -0
- package/viewer/assets/markdown.worker-DqWDoHOY.js +358 -0
- package/viewer/assets/marko-C0GSQJi3.js +1 -0
- package/viewer/assets/material-BoIUTXek.js +1 -0
- package/viewer/assets/material-theme-Bm3Qr25_.js +1 -0
- package/viewer/assets/material-theme-darker-2IIEA8gg.js +1 -0
- package/viewer/assets/material-theme-lighter-uhdI0v04.js +1 -0
- package/viewer/assets/material-theme-ocean-CHQ94UKr.js +1 -0
- package/viewer/assets/material-theme-palenight-B5W6OYN7.js +1 -0
- package/viewer/assets/matlab-D7qyCx1q.js +1 -0
- package/viewer/assets/matrix-CeUtxxjs.js +1 -0
- package/viewer/assets/mdc-DUivddFc.js +1 -0
- package/viewer/assets/mdx-DQZ5AkYe.js +1 -0
- package/viewer/assets/mercury-DIlqACMb.js +1 -0
- package/viewer/assets/mermaid-BxpfTIzt.js +1 -0
- package/viewer/assets/mermaid-parser.core-FhKE_uv2.js +7 -0
- package/viewer/assets/mermaid.core-BSOWwyvd.js +44 -0
- package/viewer/assets/min-dark-BSWPekZh.js +1 -0
- package/viewer/assets/min-light-DDpmG2fV.js +1 -0
- package/viewer/assets/mindmap-definition-YA3MSWOX-tsLZ_Opn.js +96 -0
- package/viewer/assets/mipsasm-BMqwQI7S.js +1 -0
- package/viewer/assets/mojo-fg40_ntQ.js +1 -0
- package/viewer/assets/monokai-B_bV9PQ9.js +1 -0
- package/viewer/assets/monokai-wFuGqe6w.js +1 -0
- package/viewer/assets/moonbit-DgjMoLWr.js +1 -0
- package/viewer/assets/move-BYnGhZoM.js +1 -0
- package/viewer/assets/narrat-_X_XdTYD.js +1 -0
- package/viewer/assets/nextflow-BJtWHP5T.js +1 -0
- package/viewer/assets/nextflow-groovy-DJMQeKeT.js +1 -0
- package/viewer/assets/nginx-B__INAtC.js +1 -0
- package/viewer/assets/night-owl-DhmEMT88.js +1 -0
- package/viewer/assets/night-owl-light-eJ-hLW7d.js +1 -0
- package/viewer/assets/nightowl-D5RifUq0.js +1 -0
- package/viewer/assets/nim-UEY12GJF.js +1 -0
- package/viewer/assets/nix-IvuFDN5E.js +1 -0
- package/viewer/assets/nord-BUnqvSkw.js +1 -0
- package/viewer/assets/nord-Cb4Vim4T.js +1 -0
- package/viewer/assets/nsis-CjNLYCLg.js +1 -0
- package/viewer/assets/nushell-DHYfO66s.js +1 -0
- package/viewer/assets/objective-c-D1A_Heim.js +1 -0
- package/viewer/assets/objective-cpp-BsSzOQcm.js +1 -0
- package/viewer/assets/ocaml-O90oeIOV.js +1 -0
- package/viewer/assets/odin-B1RWQWA5.js +1 -0
- package/viewer/assets/one-dark-MycZLZtN.js +1 -0
- package/viewer/assets/one-dark-pro-CLwyXe_n.js +1 -0
- package/viewer/assets/one-light-D7Lr4KcI.js +1 -0
- package/viewer/assets/onedarkpro-BWy38d_X.js +1 -0
- package/viewer/assets/opencode-Cy-bxafp.js +1 -0
- package/viewer/assets/openscad-BUDT5pXO.js +1 -0
- package/viewer/assets/ordinal-BDEzSJ7C.js +1 -0
- package/viewer/assets/org-DDIZsz95.js +1 -0
- package/viewer/assets/orng-D2APmIHg.js +1 -0
- package/viewer/assets/osaka-jade-DnfGjKZL.js +1 -0
- package/viewer/assets/packet-AYTQ26CC-CqdJnqfo.js +1 -0
- package/viewer/assets/palenight-DG9raf7e.js +1 -0
- package/viewer/assets/pascal-4ZHwLPI5.js +1 -0
- package/viewer/assets/path-fybaL0A-.js +1 -0
- package/viewer/assets/pegDiagram-XKGWAZYB-BJs7qu7m.js +1 -0
- package/viewer/assets/perl-D5KwNZt7.js +1 -0
- package/viewer/assets/php-BEs7d_Dk.js +1 -0
- package/viewer/assets/pie-WAS4IAKB-lgzqBWqy.js +1 -0
- package/viewer/assets/pieDiagram-E7YTZNPT-Cxe9LnnE.js +39 -0
- package/viewer/assets/pierre-dark-sU4Zdns8.js +1 -0
- package/viewer/assets/pierre-dark-soft-HXgun5vs.js +1 -0
- package/viewer/assets/pierre-dark-vibrant-D4RhcSIK.js +1 -0
- package/viewer/assets/pierre-light-DWBk51d8.js +1 -0
- package/viewer/assets/pierre-light-soft-CodEzPxf.js +1 -0
- package/viewer/assets/pierre-light-vibrant-B76X7i5Y.js +1 -0
- package/viewer/assets/pkl-ot-7Btpt.js +1 -0
- package/viewer/assets/plastic-DQwYfKfQ.js +1 -0
- package/viewer/assets/plsql-DGHpHOYJ.js +1 -0
- package/viewer/assets/po-BiJDBrnU.js +1 -0
- package/viewer/assets/poimandres-DRFjx7u4.js +1 -0
- package/viewer/assets/polar-C7UOKdEL.js +1 -0
- package/viewer/assets/postcss-BXeXVLqQ.js +1 -0
- package/viewer/assets/powerquery-DNMTfnFr.js +1 -0
- package/viewer/assets/powershell-CCSX75yM.js +1 -0
- package/viewer/assets/prisma-DMgNhnYS.js +1 -0
- package/viewer/assets/prolog-iXnhIJG7.js +1 -0
- package/viewer/assets/proto-DB4EqR-F.js +1 -0
- package/viewer/assets/pug-B0dsfQOV.js +1 -0
- package/viewer/assets/puppet-CDv2pdJW.js +1 -0
- package/viewer/assets/purescript-9MfHhQsQ.js +1 -0
- package/viewer/assets/python-gzcpVVnB.js +1 -0
- package/viewer/assets/qml-XPIhrIzf.js +1 -0
- package/viewer/assets/qmldir-DCQb3MpD.js +1 -0
- package/viewer/assets/qss-Fe1Jh2GI.js +1 -0
- package/viewer/assets/quadrantDiagram-AXDQQJYC-D5JGwC11.js +7 -0
- package/viewer/assets/r-C6hQdpIM.js +1 -0
- package/viewer/assets/racket-DcIDlBhZ.js +1 -0
- package/viewer/assets/radar-RG4KPBEZ-B7JRLhUA.js +1 -0
- package/viewer/assets/railroad-74A4TZTK-Df7ZQBLn.js +1 -0
- package/viewer/assets/railroad-abnf-HS5TGJTU-Z8q3QVTf.js +1 -0
- package/viewer/assets/railroad-ebnf-LZEXJU2U-BWoRkG3W.js +1 -0
- package/viewer/assets/railroad-peg-WCYAUIDC-BzoV1cN7.js +1 -0
- package/viewer/assets/railroadDiagram-O6MQD6OU-DZJzpmP8.js +1 -0
- package/viewer/assets/raku-B3gFvitq.js +1 -0
- package/viewer/assets/razor-C3KSUuOw.js +1 -0
- package/viewer/assets/rbs-C0MpOrj4.js +1 -0
- package/viewer/assets/red-DX1BQOs8.js +1 -0
- package/viewer/assets/reg-CRGYupPL.js +1 -0
- package/viewer/assets/regexp-n-T936Rk.js +1 -0
- package/viewer/assets/rel-BtDbiS_P.js +1 -0
- package/viewer/assets/requirementDiagram-BXWQKSXE-Be9lEFrk.js +84 -0
- package/viewer/assets/riscv-Ckw8ddFX.js +1 -0
- package/viewer/assets/ron-VUp2lXgN.js +1 -0
- package/viewer/assets/rose-pine-aMsaMD1D.js +1 -0
- package/viewer/assets/rose-pine-dawn-8PwUyIlP.js +1 -0
- package/viewer/assets/rose-pine-moon-DO-qXg-I.js +1 -0
- package/viewer/assets/rosepine-CVx-z9QY.js +1 -0
- package/viewer/assets/rosmsg-CAekHB0j.js +1 -0
- package/viewer/assets/rough.esm-Dy-Kn_BL.js +1 -0
- package/viewer/assets/rst-fVnHDyXD.js +1 -0
- package/viewer/assets/ruby-DuRgxlXF.js +1 -0
- package/viewer/assets/rust-Cfkwpbl8.js +1 -0
- package/viewer/assets/sankeyDiagram-P5KCCOFB-BsgKAEBN.js +40 -0
- package/viewer/assets/sas-C0WA2OFa.js +1 -0
- package/viewer/assets/sass-DXrisJhu.js +1 -0
- package/viewer/assets/scala-BiFt_7mu.js +1 -0
- package/viewer/assets/scheme-DQCgrYNe.js +1 -0
- package/viewer/assets/scss-CQDZ4smR.js +1 -0
- package/viewer/assets/sdbl-bTVj8UrX.js +1 -0
- package/viewer/assets/sequenceDiagram-WJ2MYXX4-BkUDWL0D.js +162 -0
- package/viewer/assets/shaderlab-TOUzSsQk.js +1 -0
- package/viewer/assets/shadesofpurple-dFPspHnY.js +1 -0
- package/viewer/assets/shellscript-CE84G0GP.js +1 -0
- package/viewer/assets/shellsession-BdJvdaqL.js +1 -0
- package/viewer/assets/sizeCapture-INFHLROL-B0uUizjq.js +1 -0
- package/viewer/assets/slack-dark-DnToyrRv.js +1 -0
- package/viewer/assets/slack-ochin-B2OO5cIa.js +1 -0
- package/viewer/assets/smalltalk-BHpQb5nM.js +1 -0
- package/viewer/assets/smithy-Dgaz7aur.js +1 -0
- package/viewer/assets/snazzy-light-4G7pJPwS.js +1 -0
- package/viewer/assets/solarized-19OwMz-R.js +1 -0
- package/viewer/assets/solarized-dark-UdsmMDCL.js +1 -0
- package/viewer/assets/solarized-light-C1IUL_tW.js +1 -0
- package/viewer/assets/solidity-Bj7E1mRn.js +1 -0
- package/viewer/assets/soy-BSxOREC0.js +1 -0
- package/viewer/assets/sparql-D_iOobhT.js +1 -0
- package/viewer/assets/splunk-BC2Px7Mm.js +1 -0
- package/viewer/assets/sprite-B9ixRF_T.svg +1110 -0
- package/viewer/assets/sprite-Fb-TFjRY.svg +11707 -0
- package/viewer/assets/sql-D4MN9uRI.js +1 -0
- package/viewer/assets/src-BT_kESTA.js +1 -0
- package/viewer/assets/ssh-config-BgfXC-Er.js +1 -0
- package/viewer/assets/stata-B6nXAaGV.js +1 -0
- package/viewer/assets/stateDiagram-D77RDMKH-C80wp8xG.js +1 -0
- package/viewer/assets/stateDiagram-v2-MP3YSRHH-CYdsKKlz.js +1 -0
- package/viewer/assets/stylus-B6D30XZt.js +1 -0
- package/viewer/assets/surrealql-fVjZmhV3.js +1 -0
- package/viewer/assets/svelte-DnBQ5p7d.js +1 -0
- package/viewer/assets/swift-CyEgAFGc.js +1 -0
- package/viewer/assets/swimlanes-42K2YHIH-Cff6yT8e.js +1 -0
- package/viewer/assets/swimlanesDiagram-VR7AAH4N-niTUGjMT.js +8 -0
- package/viewer/assets/synthwave-84-nFMaYfgc.js +1 -0
- package/viewer/assets/synthwave84-D5i2TsvP.js +1 -0
- package/viewer/assets/system-verilog-Dh5ihWbf.js +1 -0
- package/viewer/assets/systemd-BxMlprV5.js +1 -0
- package/viewer/assets/talonscript-CohzipZa.js +1 -0
- package/viewer/assets/tasl-DMoTqEGO.js +1 -0
- package/viewer/assets/tcl-CZd0xW_V.js +1 -0
- package/viewer/assets/templ-TCx51Uts.js +1 -0
- package/viewer/assets/terraform-DswuEJGm.js +1 -0
- package/viewer/assets/tex-CF6SMAQ_.js +1 -0
- package/viewer/assets/timeline-definition-24CTP7MA-Cje7BvaN.js +120 -0
- package/viewer/assets/tokyo-night-oM2G3aXe.js +1 -0
- package/viewer/assets/tokyonight-DLjt3AtF.js +1 -0
- package/viewer/assets/toml-CcmNWLt0.js +1 -0
- package/viewer/assets/treeView-Q6P3EWNA-D-QLY3IO.js +1 -0
- package/viewer/assets/treemap-WGGIJYW6-BCHcTa4N.js +1 -0
- package/viewer/assets/ts-tags-BqLRnADX.js +1 -0
- package/viewer/assets/tsv-sltzmVWM.js +1 -0
- package/viewer/assets/tsx-D7KpDX0b.js +1 -0
- package/viewer/assets/turtle-ByJddavk.js +1 -0
- package/viewer/assets/twig-CEZLObpN.js +1 -0
- package/viewer/assets/typescript-DAbIDLbf.js +1 -0
- package/viewer/assets/typespec-BRdr0IET.js +1 -0
- package/viewer/assets/typst-CqN7-whv.js +1 -0
- package/viewer/assets/v-DBj4K9d_.js +1 -0
- package/viewer/assets/vala-zf12oZj6.js +1 -0
- package/viewer/assets/vb-DOwzaHZ0.js +1 -0
- package/viewer/assets/vennDiagram-4TSXK5OY-Bz20rx02.js +34 -0
- package/viewer/assets/vercel-DiG3Swzk.js +1 -0
- package/viewer/assets/verilog-B2gwz-sJ.js +1 -0
- package/viewer/assets/vesper-BArq_vZH.js +1 -0
- package/viewer/assets/vesper-DdrHHSXu.js +1 -0
- package/viewer/assets/vhdl-BroJfC0k.js +1 -0
- package/viewer/assets/viml-DvXPmvsu.js +1 -0
- package/viewer/assets/vitesse-black-fwtXNY1n.js +1 -0
- package/viewer/assets/vitesse-dark-BZCL-v6S.js +1 -0
- package/viewer/assets/vitesse-light-VbXTXTou.js +1 -0
- package/viewer/assets/vue-html-DQmvvKbd.js +1 -0
- package/viewer/assets/vue-kTxN6wdc.js +1 -0
- package/viewer/assets/vue-vine-Did3qTVW.js +1 -0
- package/viewer/assets/vyper-CgoNMtux.js +1 -0
- package/viewer/assets/wardley-WFR3VGLG-CpXaqOit.js +1 -0
- package/viewer/assets/wardleyDiagram-VM6X3IG4-Cz06jHpA.js +78 -0
- package/viewer/assets/wasm-BnjxR4X6.js +1 -0
- package/viewer/assets/wasm-ByWQv1Qj.js +1 -0
- package/viewer/assets/wenyan-C8pVoKbM.js +1 -0
- package/viewer/assets/wgsl-BsKzXJz4.js +1 -0
- package/viewer/assets/wikitext-ClFFjSW2.js +1 -0
- package/viewer/assets/wit-DdvCle-K.js +1 -0
- package/viewer/assets/wolfram-DLL8P-h_.js +1 -0
- package/viewer/assets/worker-DDDBDFQT.js +160 -0
- package/viewer/assets/xml-te2hFcAA.js +1 -0
- package/viewer/assets/xsl-X4fuKSVl.js +1 -0
- package/viewer/assets/xychartDiagram-S5SC5T6Z-BXCw0sfu.js +7 -0
- package/viewer/assets/yaml-NHtDSZab.js +1 -0
- package/viewer/assets/zenburn-COSjCZYx.js +1 -0
- package/viewer/assets/zenscript-BnlCZFoB.js +1 -0
- package/viewer/assets/zig-CMLA9XwU.js +1 -0
- package/viewer/index.html +14 -0
package/JUDGING.md
ADDED
|
@@ -0,0 +1,123 @@
|
|
|
1
|
+
# Judging recorded work
|
|
2
|
+
|
|
3
|
+
## Shared judge agent
|
|
4
|
+
|
|
5
|
+
OpenEval uses the native OpenCode V2 primary agent `openeval-judge` for final
|
|
6
|
+
grading, live checks, rejudging, calibration, and independent audits. Its
|
|
7
|
+
[base system prompt](src/infra/judging/judge-agent.md) owns the common evidence,
|
|
8
|
+
citation, uncertainty, early-decision, and output rules. See
|
|
9
|
+
[OpenCode V2 custom agents](https://opencode.ai/v2/docs/agents/).
|
|
10
|
+
|
|
11
|
+
The native agent's system prompt contains the base instructions and one copy of
|
|
12
|
+
the eval rubric. It remains present across compaction. User turns identify the
|
|
13
|
+
phase; structured context and decisions move through registered Code Mode tools.
|
|
14
|
+
The tools use native Effect schemas for argument validation and catalog types.
|
|
15
|
+
|
|
16
|
+
Every JudgeRun requires its shared profile in `input.agent`, explicit metrics,
|
|
17
|
+
mode, runtime hash, and protocol. The effective
|
|
18
|
+
native configuration is archived at `configuration/opencode.json` in its judge
|
|
19
|
+
directory. The profile contributes to the judge input fingerprint, so a shared
|
|
20
|
+
prompt change schedules rejudging using saved evidence. Candidate input
|
|
21
|
+
fingerprints do not include the judge profile.
|
|
22
|
+
|
|
23
|
+
## Eval metric rubrics
|
|
24
|
+
|
|
25
|
+
Declare one or more metrics in `judge.md`:
|
|
26
|
+
|
|
27
|
+
```md
|
|
28
|
+
# Advice quality
|
|
29
|
+
|
|
30
|
+
## Metric: current_advice — Advice for the current situation
|
|
31
|
+
Pass when the requested advice is present and its recommendations are available now.
|
|
32
|
+
Fail when a recommendation is unavailable now, or the requested advice is omitted.
|
|
33
|
+
|
|
34
|
+
## Metric: later_advice — Advice for later stages
|
|
35
|
+
Judge later recommendations at their explicitly stated stage.
|
|
36
|
+
```
|
|
37
|
+
|
|
38
|
+
Keep metric-specific rules, accepted alternatives, and domain facts in that file.
|
|
39
|
+
The LLM applies these rules. The SDK validates the declared IDs, binary metric
|
|
40
|
+
values, recorded evidence references, and exact optional quotes. It calculates
|
|
41
|
+
the equal-weight metric mean. A missing metric or invalid citation is a judge
|
|
42
|
+
protocol error; missing source evidence can produce a null metric. Every rubric
|
|
43
|
+
must declare at least one `## Metric: id — Label`, and every judgment contains
|
|
44
|
+
the complete metric array.
|
|
45
|
+
|
|
46
|
+
## Structured tool submissions
|
|
47
|
+
|
|
48
|
+
| Tool | Data |
|
|
49
|
+
| --- | --- |
|
|
50
|
+
| `judge_context` | Current request ID, phase, metric declarations, and evidence index |
|
|
51
|
+
| `candidate_evidence` | Recorded responses, tools, events, messages, and artifacts |
|
|
52
|
+
| `submit_judgment` | Scores keyed by metric ID, with reasons and citations |
|
|
53
|
+
| `continue_judging` | An early check's reason for needing more evidence |
|
|
54
|
+
|
|
55
|
+
Native argument validation and citation validation return errors directly to the
|
|
56
|
+
judge. It can correct arguments or retrieve better evidence and retry within the
|
|
57
|
+
same native turn and existing timeout. The runner does not parse assistant text
|
|
58
|
+
for JSON or start synthetic format-repair turns. Ending without an accepted tool
|
|
59
|
+
submission fails the JudgeRun rather than assigning a candidate zero.
|
|
60
|
+
|
|
61
|
+
Tool schemas stay stable across checks. Each request ID is bound to one fixed
|
|
62
|
+
evidence view. Only the first valid submission is accepted; stale, concurrent, or
|
|
63
|
+
cancelled submissions cannot overwrite it or affect a later check. Early
|
|
64
|
+
submissions require every metric to be non-null and irreversible. Final grading
|
|
65
|
+
permits null metrics and rejects `continue_judging`.
|
|
66
|
+
|
|
67
|
+
Accepted submissions and semantic rejections are recorded in
|
|
68
|
+
`judgment-submissions.json`, with their request/check IDs and checkpoints. Native
|
|
69
|
+
schema failures are retained in the native tool transcript.
|
|
70
|
+
|
|
71
|
+
Every decided metric cites recorded evidence. Citations can name a response,
|
|
72
|
+
message ID, tool-call ID, event sequence, or initial/final artifact path. The
|
|
73
|
+
evidence reference/checkpoint binds those citations to the exact recording.
|
|
74
|
+
Source URLs are supplementary domain references, not substitutes for citations
|
|
75
|
+
to the candidate's work.
|
|
76
|
+
|
|
77
|
+
For example, the judge submits this from Code Mode after inspecting the recording:
|
|
78
|
+
|
|
79
|
+
```js
|
|
80
|
+
const context = await tools.judge_context({});
|
|
81
|
+
await tools.submit_judgment({
|
|
82
|
+
requestId: context.requestId,
|
|
83
|
+
metrics: {
|
|
84
|
+
current_advice: {
|
|
85
|
+
value: 1,
|
|
86
|
+
reason: "The current-stage recommendation satisfies the rubric.",
|
|
87
|
+
evidence: [{ kind: "response" }],
|
|
88
|
+
},
|
|
89
|
+
later_advice: {
|
|
90
|
+
value: 0,
|
|
91
|
+
reason: "The later-stage recommendation violates the rubric.",
|
|
92
|
+
evidence: [{ kind: "response" }],
|
|
93
|
+
},
|
|
94
|
+
},
|
|
95
|
+
});
|
|
96
|
+
```
|
|
97
|
+
|
|
98
|
+
The host stores the metric array and aggregate value `0.5`. A citation's optional `quote` must occur
|
|
99
|
+
literally in the referenced response/tool/message/event/artifact. An artifact
|
|
100
|
+
citation must specify `path` and `revision` (`initial` or `final`); other record
|
|
101
|
+
citations specify `id`. Semantic interpretation remains the judge's job.
|
|
102
|
+
|
|
103
|
+
`recordEvidence` creates a calibration recording from supplied text/tool records
|
|
104
|
+
without executing a model or tool. `judgeEvidence` grades retained evidence into
|
|
105
|
+
a new standalone audit directory without changing a benchmark's active scores.
|
|
106
|
+
Use `judgeRuns` when an explicit rejudge should update active selections.
|
|
107
|
+
|
|
108
|
+
Runtime uses recorded work intervals. Judge checks record `executionStartedAt`
|
|
109
|
+
when they obtain a worker, separately from their queue-admission `startedAt`.
|
|
110
|
+
`archiveStartedAt` records active finalization. A persistent judge's waiting time
|
|
111
|
+
is excluded. A check cancelled before worker admission has no runtime. Calendar
|
|
112
|
+
creation/completion dates remain provenance, not elapsed-runtime measurements.
|
|
113
|
+
|
|
114
|
+
## Design references
|
|
115
|
+
|
|
116
|
+
- [DeepSWE quality assurance](https://deepswe.datacurve.ai/blog/deepswe#qa):
|
|
117
|
+
acceptance breadth and alignment between the specification and grading.
|
|
118
|
+
- [DeepSWE metrics](https://arxiv.org/html/2607.07946#S5.SS3): equal task weighting.
|
|
119
|
+
- [JudgeBench](https://arxiv.org/abs/2410.12784): validate factual and logical
|
|
120
|
+
judging ability with known examples, rather than assuming model strength.
|
|
121
|
+
|
|
122
|
+
Keep task-specific decisions in `judge.md`; executable SDK code handles the
|
|
123
|
+
recording protocol and generic arithmetic, not task success rules.
|
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Hona
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
ADDED
|
@@ -0,0 +1,133 @@
|
|
|
1
|
+
# OpenEval
|
|
2
|
+
|
|
3
|
+
A typed prompt-plus-LLM-judge SDK for Bun. Run agents in isolated containers,
|
|
4
|
+
record their work, grade the evidence, and explore the results in a local viewer.
|
|
5
|
+
|
|
6
|
+
## Install
|
|
7
|
+
|
|
8
|
+
Requires Bun 1.4.2 or later, Docker, and an authenticated OpenCode installation.
|
|
9
|
+
The agent runtime currently uses OpenCode `0.0.0-beta-19296`.
|
|
10
|
+
|
|
11
|
+
```sh
|
|
12
|
+
bun add --exact @hona/openeval
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
## Declare a benchmark
|
|
16
|
+
|
|
17
|
+
```text
|
|
18
|
+
my-benchmark/
|
|
19
|
+
benchmark.ts
|
|
20
|
+
evals/
|
|
21
|
+
ask-dialect/
|
|
22
|
+
prompt.md
|
|
23
|
+
judge.md
|
|
24
|
+
```
|
|
25
|
+
|
|
26
|
+
`benchmark.ts`:
|
|
27
|
+
|
|
28
|
+
```ts
|
|
29
|
+
import type { Benchmark } from "@hona/openeval";
|
|
30
|
+
|
|
31
|
+
export default {
|
|
32
|
+
models: ["provider/candidate-model"],
|
|
33
|
+
judge: { model: "provider/judge-model" },
|
|
34
|
+
repetitions: 3,
|
|
35
|
+
} satisfies Benchmark;
|
|
36
|
+
```
|
|
37
|
+
|
|
38
|
+
Replace the model references with models connected in OpenCode.
|
|
39
|
+
|
|
40
|
+
`evals/ask-dialect/prompt.md`:
|
|
41
|
+
|
|
42
|
+
```md
|
|
43
|
+
Write a SQL query for the ten most recent orders for a customer.
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
`evals/ask-dialect/judge.md`:
|
|
47
|
+
|
|
48
|
+
```md
|
|
49
|
+
# Requests the SQL dialect
|
|
50
|
+
|
|
51
|
+
## Metric: asked_dialect — Asks which SQL dialect to use
|
|
52
|
+
|
|
53
|
+
Pass when the agent asks which database or SQL dialect is in use.
|
|
54
|
+
Fail when it assumes a dialect without asking. Asking alongside a draft counts.
|
|
55
|
+
```
|
|
56
|
+
|
|
57
|
+
Prompts are sent verbatim. Each metric is `0`, `1`, or `null` when evidence is
|
|
58
|
+
insufficient. The judge supplies citations to the recording. A shared native
|
|
59
|
+
judge agent supplies the evidence and submission protocol; rubrics contain the
|
|
60
|
+
task-specific criteria. See [JUDGING.md](JUDGING.md).
|
|
61
|
+
|
|
62
|
+
## Run and inspect
|
|
63
|
+
|
|
64
|
+
From your benchmark directory:
|
|
65
|
+
|
|
66
|
+
```sh
|
|
67
|
+
bunx --bun @hona/openeval image
|
|
68
|
+
bunx --bun @hona/openeval plan
|
|
69
|
+
bunx --bun @hona/openeval run
|
|
70
|
+
bunx --bun @hona/openeval view
|
|
71
|
+
```
|
|
72
|
+
|
|
73
|
+
The viewer opens at `http://127.0.0.1:4173`. Use `--benchmark <directory>` to point
|
|
74
|
+
any command at another benchmark, or `--port <port>` for another viewer port.
|
|
75
|
+
|
|
76
|
+
`run` resumes the current aggregate and reuses unchanged work. `--new` starts a
|
|
77
|
+
separate result. Repeat `--only-eval`, `--only-model`, or `--only-repetition` to
|
|
78
|
+
execute a small scope while retaining the full aggregate. `--max-cost <usd>`
|
|
79
|
+
sets a scheduling budget for the invocation. Run `openeval --help` for commands.
|
|
80
|
+
|
|
81
|
+
Scores average repetitions per metric, metrics per eval, then evals equally.
|
|
82
|
+
Unresolved checks produce completion bounds until the final percentage is known.
|
|
83
|
+
The viewer provides metric drilldowns and recorded candidate and judge sessions.
|
|
84
|
+
Elapsed time measures active execution intervals, counting overlapping work once.
|
|
85
|
+
|
|
86
|
+
## Prepare a workspace
|
|
87
|
+
|
|
88
|
+
An eval's optional `workspace/` directory supplies files. An optional `eval.ts`
|
|
89
|
+
can declare a pinned Git repository or readable revision overlays and preparation
|
|
90
|
+
commands:
|
|
91
|
+
|
|
92
|
+
```ts
|
|
93
|
+
import type { Eval } from "@hona/openeval";
|
|
94
|
+
|
|
95
|
+
export default {
|
|
96
|
+
prepare: [{ cwd: ".", argv: ["bun", "install", "--frozen-lockfile"] }],
|
|
97
|
+
} satisfies Eval;
|
|
98
|
+
```
|
|
99
|
+
|
|
100
|
+
Preparation runs before recording the initial candidate workspace. Candidate
|
|
101
|
+
containers receive project inputs, never judge rubrics or evaluator storage.
|
|
102
|
+
Candidates finish naturally, meet an opted-in irreversible judge decision, or
|
|
103
|
+
time out after at most 45 minutes. Finalized recordings remain immutable.
|
|
104
|
+
|
|
105
|
+
## SDK
|
|
106
|
+
|
|
107
|
+
```ts
|
|
108
|
+
import { runBenchmark, serveResults } from "@hona/openeval";
|
|
109
|
+
|
|
110
|
+
await runBenchmark("./my-benchmark");
|
|
111
|
+
```
|
|
112
|
+
|
|
113
|
+
The package also exports types, result readers, snapshot and rejudge functions,
|
|
114
|
+
and reusable view/session data through `@hona/openeval/types`, `/results`,
|
|
115
|
+
`/view`, and `/session`.
|
|
116
|
+
|
|
117
|
+
## Develop and release
|
|
118
|
+
|
|
119
|
+
```sh
|
|
120
|
+
bun install --frozen-lockfile
|
|
121
|
+
bun run typecheck
|
|
122
|
+
bun test
|
|
123
|
+
bun run release:pack
|
|
124
|
+
bun run release:verify
|
|
125
|
+
```
|
|
126
|
+
|
|
127
|
+
The private benchmark client is maintained in a separate repository. It installs
|
|
128
|
+
an exact published SDK version. This repository contains only the reusable SDK,
|
|
129
|
+
CLI, viewer, and development inputs. See [RELEASING.md](https://github.com/Hona/openeval/blob/main/RELEASING.md).
|
|
130
|
+
|
|
131
|
+
OpenEval is MIT licensed. The vendored session UI retains its upstream MIT
|
|
132
|
+
license and revision in `vendor/session-ui`. Built viewer distributions include
|
|
133
|
+
third-party license notices.
|
package/package.json
ADDED
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@hona/openeval",
|
|
3
|
+
"version": "0.2.0",
|
|
4
|
+
"description": "Typed prompt-and-judge evaluations with isolated agents, recorded evidence, and a results viewer",
|
|
5
|
+
"license": "MIT",
|
|
6
|
+
"repository": {
|
|
7
|
+
"type": "git",
|
|
8
|
+
"url": "git+https://github.com/Hona/openeval.git",
|
|
9
|
+
"directory": "packages/openeval"
|
|
10
|
+
},
|
|
11
|
+
"engines": {
|
|
12
|
+
"bun": ">=1.4.2"
|
|
13
|
+
},
|
|
14
|
+
"bin": {
|
|
15
|
+
"openeval": "src/cli.ts"
|
|
16
|
+
},
|
|
17
|
+
"files": ["src", "viewer", "LICENSE", "README.md", "JUDGING.md", "!src/**/*.test.ts"],
|
|
18
|
+
"publishConfig": {
|
|
19
|
+
"access": "public"
|
|
20
|
+
},
|
|
21
|
+
"type": "module",
|
|
22
|
+
"exports": {
|
|
23
|
+
".": "./src/index.ts",
|
|
24
|
+
"./types": "./src/types.ts",
|
|
25
|
+
"./results": "./src/app/read-results.ts",
|
|
26
|
+
"./view": "./src/view.ts",
|
|
27
|
+
"./session": "./src/session-replay.ts"
|
|
28
|
+
},
|
|
29
|
+
"dependencies": {
|
|
30
|
+
"@types/tar-stream": "3.1.4",
|
|
31
|
+
"@opencode/client": "0.0.0-beta-19296",
|
|
32
|
+
"@opencode/core": "0.0.0-beta-19296",
|
|
33
|
+
"@opencode/sdk": "0.0.0-beta-19296",
|
|
34
|
+
"@opencode/util": "0.0.0-beta-19296",
|
|
35
|
+
"drizzle-orm": "0.45.2",
|
|
36
|
+
"effect": "4.0.0-rc.112",
|
|
37
|
+
"tar-stream": "3.1.7"
|
|
38
|
+
}
|
|
39
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import type { ModelRef, ExecutionObserver } from "../types";
|
|
2
|
+
import { Results } from "../infra/sqlite";
|
|
3
|
+
import { resolve } from "node:path";
|
|
4
|
+
import { runBenchmark } from "./run-benchmark";
|
|
5
|
+
|
|
6
|
+
export async function addModels(
|
|
7
|
+
directory: string,
|
|
8
|
+
models: readonly ModelRef[],
|
|
9
|
+
onEvent?: ExecutionObserver,
|
|
10
|
+
) {
|
|
11
|
+
if (!models.length) throw new Error("Select models to add");
|
|
12
|
+
let source: string;
|
|
13
|
+
{
|
|
14
|
+
using results = new Results(resolve(directory, "runner.db"), true);
|
|
15
|
+
source = results.benchmark!.source;
|
|
16
|
+
}
|
|
17
|
+
return runBenchmark(source, { directory, models, onEvent });
|
|
18
|
+
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import type {
|
|
2
|
+
BenchmarkDefinition,
|
|
3
|
+
BenchmarkRun,
|
|
4
|
+
ExecutionObserver,
|
|
5
|
+
} from "../types";
|
|
6
|
+
import type { Results } from "../infra/sqlite";
|
|
7
|
+
|
|
8
|
+
export type ExecutionContext = {
|
|
9
|
+
directory: string;
|
|
10
|
+
definition: BenchmarkDefinition;
|
|
11
|
+
runtime: BenchmarkRun["runtime"];
|
|
12
|
+
results: Results;
|
|
13
|
+
onEvent?: ExecutionObserver;
|
|
14
|
+
finalOnly?: boolean;
|
|
15
|
+
};
|
|
@@ -0,0 +1,118 @@
|
|
|
1
|
+
import type {
|
|
2
|
+
BenchmarkDefinition,
|
|
3
|
+
EvalRun,
|
|
4
|
+
JudgeRun,
|
|
5
|
+
PlanItem,
|
|
6
|
+
} from "../types";
|
|
7
|
+
import type { Results } from "../infra/sqlite";
|
|
8
|
+
|
|
9
|
+
export type CostEstimate = {
|
|
10
|
+
candidates: number;
|
|
11
|
+
judges: number;
|
|
12
|
+
estimatedUSD: number | null;
|
|
13
|
+
unknownItems: number;
|
|
14
|
+
items: Array<{ slotId: string; estimatedUSD: number | null }>;
|
|
15
|
+
};
|
|
16
|
+
const median = (values: number[]) => {
|
|
17
|
+
if (!values.length) return undefined;
|
|
18
|
+
values.sort((a, b) => a - b);
|
|
19
|
+
const middle = Math.floor(values.length / 2);
|
|
20
|
+
return values.length % 2
|
|
21
|
+
? values[middle]
|
|
22
|
+
: (values[middle - 1] + values[middle]) / 2;
|
|
23
|
+
};
|
|
24
|
+
|
|
25
|
+
/** Empirical planning estimates, separate from reported spend.
|
|
26
|
+
* https://deepswe.datacurve.ai/blog/deepswe#beyond-pass-rate
|
|
27
|
+
*/
|
|
28
|
+
export function estimateWork(
|
|
29
|
+
definition: BenchmarkDefinition,
|
|
30
|
+
results: Results,
|
|
31
|
+
plan: readonly PlanItem[],
|
|
32
|
+
): CostEstimate {
|
|
33
|
+
const evals = results.evalRuns(),
|
|
34
|
+
judges = results.judgeRuns();
|
|
35
|
+
const cost = (runs: Array<EvalRun | JudgeRun>) =>
|
|
36
|
+
median(
|
|
37
|
+
runs.flatMap((run) => {
|
|
38
|
+
const value = run.session?.accounting?.costUSD;
|
|
39
|
+
return value === undefined ? [] : [value];
|
|
40
|
+
}),
|
|
41
|
+
);
|
|
42
|
+
const ready = plan.filter(
|
|
43
|
+
(item) => item.action === "candidate" || item.action === "judge",
|
|
44
|
+
);
|
|
45
|
+
const items = ready.map((item) => {
|
|
46
|
+
const candidate =
|
|
47
|
+
cost(
|
|
48
|
+
evals.filter(
|
|
49
|
+
(run) =>
|
|
50
|
+
run.input.evalId === item.slot.evalId &&
|
|
51
|
+
run.input.model === item.slot.model,
|
|
52
|
+
),
|
|
53
|
+
) ??
|
|
54
|
+
cost(evals.filter((run) => run.input.model === item.slot.model)) ??
|
|
55
|
+
cost(evals);
|
|
56
|
+
const judge =
|
|
57
|
+
cost(
|
|
58
|
+
judges.filter(
|
|
59
|
+
(run) =>
|
|
60
|
+
run.input.model === definition.judge.model &&
|
|
61
|
+
evals.some(
|
|
62
|
+
(e) =>
|
|
63
|
+
e.id === run.input.evalRunId &&
|
|
64
|
+
e.input.evalId === item.slot.evalId,
|
|
65
|
+
),
|
|
66
|
+
),
|
|
67
|
+
) ??
|
|
68
|
+
cost(
|
|
69
|
+
judges.filter((run) => run.input.model === definition.judge.model),
|
|
70
|
+
) ??
|
|
71
|
+
cost(judges);
|
|
72
|
+
return {
|
|
73
|
+
slotId: item.slot.id,
|
|
74
|
+
estimatedUSD:
|
|
75
|
+
judge === undefined ||
|
|
76
|
+
(item.action === "candidate" && candidate === undefined)
|
|
77
|
+
? null
|
|
78
|
+
: judge + (item.action === "candidate" ? candidate! : 0),
|
|
79
|
+
};
|
|
80
|
+
});
|
|
81
|
+
return {
|
|
82
|
+
candidates: ready.filter((item) => item.action === "candidate").length,
|
|
83
|
+
judges: ready.length,
|
|
84
|
+
estimatedUSD: items.every((item) => item.estimatedUSD !== null)
|
|
85
|
+
? items.reduce((sum, item) => sum + item.estimatedUSD!, 0)
|
|
86
|
+
: null,
|
|
87
|
+
unknownItems: items.filter((item) => item.estimatedUSD === null).length,
|
|
88
|
+
items,
|
|
89
|
+
};
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
/** Scheduling guard: active work finishes naturally, so this is not a billing ceiling. */
|
|
93
|
+
export class CostBudget {
|
|
94
|
+
private reserved = 0;
|
|
95
|
+
constructor(
|
|
96
|
+
readonly limit: number | undefined,
|
|
97
|
+
private spent: () => number,
|
|
98
|
+
) {
|
|
99
|
+
if (limit !== undefined && (!Number.isFinite(limit) || limit < 0))
|
|
100
|
+
throw new Error("Cost budget must be a non-negative USD amount");
|
|
101
|
+
}
|
|
102
|
+
reserve(estimate: number | null): (() => void) | undefined {
|
|
103
|
+
if (this.limit === undefined) return () => {};
|
|
104
|
+
if (
|
|
105
|
+
estimate === null ||
|
|
106
|
+
this.spent() + this.reserved + estimate > this.limit
|
|
107
|
+
)
|
|
108
|
+
return;
|
|
109
|
+
this.reserved += estimate;
|
|
110
|
+
let released = false;
|
|
111
|
+
return () => {
|
|
112
|
+
if (!released) {
|
|
113
|
+
this.reserved -= estimate;
|
|
114
|
+
released = true;
|
|
115
|
+
}
|
|
116
|
+
};
|
|
117
|
+
}
|
|
118
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import type { EvalRun, EvidenceRef } from "../types";
|
|
2
|
+
|
|
3
|
+
/** A time limit ends execution, but recorded work can still satisfy the rubric. */
|
|
4
|
+
export function canJudgeEval(
|
|
5
|
+
run: EvalRun | undefined,
|
|
6
|
+
): run is EvalRun & { evidence: EvidenceRef } {
|
|
7
|
+
return (
|
|
8
|
+
!!run?.evidence && ["completed", "stopped", "timed_out"].includes(run.state)
|
|
9
|
+
);
|
|
10
|
+
}
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
type Kind = "eval" | "judge";
|
|
2
|
+
type Waiting = { kind: Kind; start(): void; cancel(): void };
|
|
3
|
+
|
|
4
|
+
/** One stage budget. Live monitors reserve one lane so long evals cannot starve checks. */
|
|
5
|
+
export class ExecutionBudget {
|
|
6
|
+
private active = 0;
|
|
7
|
+
private evals = 0;
|
|
8
|
+
private monitors = 0;
|
|
9
|
+
private waiting: Waiting[] = [];
|
|
10
|
+
constructor(readonly limit: number) {
|
|
11
|
+
if (!Number.isInteger(limit) || limit < 1)
|
|
12
|
+
throw new Error("Invalid concurrency limit");
|
|
13
|
+
}
|
|
14
|
+
monitor() {
|
|
15
|
+
if (this.limit < 2)
|
|
16
|
+
throw new Error("Early stopping requires concurrency of at least 2");
|
|
17
|
+
this.monitors++;
|
|
18
|
+
let released = false;
|
|
19
|
+
return () => {
|
|
20
|
+
if (released) return;
|
|
21
|
+
released = true;
|
|
22
|
+
this.monitors--;
|
|
23
|
+
this.pump();
|
|
24
|
+
};
|
|
25
|
+
}
|
|
26
|
+
run<T>(kind: Kind, work: () => Promise<T>, signal?: AbortSignal): Promise<T> {
|
|
27
|
+
if (signal?.aborted) return Promise.reject(signal.reason);
|
|
28
|
+
return new Promise<T>((resolve, reject) => {
|
|
29
|
+
const request: Waiting = {
|
|
30
|
+
kind,
|
|
31
|
+
cancel: () => {
|
|
32
|
+
this.waiting = this.waiting.filter((item) => item !== request);
|
|
33
|
+
signal?.removeEventListener("abort", request.cancel);
|
|
34
|
+
reject(signal?.reason);
|
|
35
|
+
this.pump();
|
|
36
|
+
},
|
|
37
|
+
start: () => {
|
|
38
|
+
signal?.removeEventListener("abort", request.cancel);
|
|
39
|
+
this.active++;
|
|
40
|
+
if (kind === "eval") this.evals++;
|
|
41
|
+
Promise.resolve()
|
|
42
|
+
.then(work)
|
|
43
|
+
.then(resolve, reject)
|
|
44
|
+
.finally(() => {
|
|
45
|
+
this.active--;
|
|
46
|
+
if (kind === "eval") this.evals--;
|
|
47
|
+
this.pump();
|
|
48
|
+
});
|
|
49
|
+
},
|
|
50
|
+
};
|
|
51
|
+
this.waiting.push(request);
|
|
52
|
+
signal?.addEventListener("abort", request.cancel, { once: true });
|
|
53
|
+
this.pump();
|
|
54
|
+
});
|
|
55
|
+
}
|
|
56
|
+
private pump() {
|
|
57
|
+
while (this.active < this.limit) {
|
|
58
|
+
let index = this.waiting.findIndex((item) => item.kind === "judge");
|
|
59
|
+
if (index < 0 && this.evals < this.limit - (this.monitors ? 1 : 0))
|
|
60
|
+
index = this.waiting.findIndex((item) => item.kind === "eval");
|
|
61
|
+
if (index < 0) return;
|
|
62
|
+
this.waiting.splice(index, 1)[0].start();
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
}
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
import type { BenchmarkRun, EvalRun, JudgeRun } from "../types";
|
|
2
|
+
import type { Results } from "../infra/sqlite";
|
|
3
|
+
import { mergeRuntime, timestampMs, type RuntimeInterval } from "../runtime";
|
|
4
|
+
|
|
5
|
+
/** Read-only projection; finalized runs and their original timestamps are untouched. */
|
|
6
|
+
export function executionRuntime(
|
|
7
|
+
run: EvalRun | JudgeRun,
|
|
8
|
+
results: Results,
|
|
9
|
+
benchmark: BenchmarkRun,
|
|
10
|
+
now: number,
|
|
11
|
+
current = true,
|
|
12
|
+
): RuntimeInterval[] {
|
|
13
|
+
const start = timestampMs(run.startedAt),
|
|
14
|
+
completed = timestampMs(run.completedAt);
|
|
15
|
+
if (start === undefined) return [];
|
|
16
|
+
const heartbeat = timestampMs(benchmark.updatedAt) ?? start;
|
|
17
|
+
const live =
|
|
18
|
+
current &&
|
|
19
|
+
run.state === "running" &&
|
|
20
|
+
benchmark.state === "running" &&
|
|
21
|
+
now - heartbeat <= 30_000;
|
|
22
|
+
const lastObserved =
|
|
23
|
+
!current && completed === undefined
|
|
24
|
+
? (results.eventBounds(run.id)?.last ?? start)
|
|
25
|
+
: undefined;
|
|
26
|
+
const closing = completed ?? Math.min(now, lastObserved ?? heartbeat);
|
|
27
|
+
const interval = (begin: number, end?: number): RuntimeInterval[] =>
|
|
28
|
+
Number.isFinite(begin) &&
|
|
29
|
+
(end === undefined || (Number.isFinite(end) && end >= begin))
|
|
30
|
+
? [{ start: begin, ...(end === undefined ? {} : { end }) }]
|
|
31
|
+
: [];
|
|
32
|
+
|
|
33
|
+
if (!("evalRunId" in run.input) || run.input.mode !== "monitor") {
|
|
34
|
+
const end =
|
|
35
|
+
completed !== undefined
|
|
36
|
+
? completed
|
|
37
|
+
: live
|
|
38
|
+
? undefined
|
|
39
|
+
: Math.min(closing, start + run.input.timeoutMs);
|
|
40
|
+
return interval(start, end);
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
// A persistent judge is idle between checks. Its session lifetime is not work.
|
|
44
|
+
const judge = run as JudgeRun;
|
|
45
|
+
const checks = results.judgeChecks(run.id);
|
|
46
|
+
const intervals = checks.flatMap((check) => {
|
|
47
|
+
const begin = timestampMs(check.executionStartedAt);
|
|
48
|
+
if (begin === undefined) return []; // Cancelled before obtaining a worker.
|
|
49
|
+
const end =
|
|
50
|
+
timestampMs(check.completedAt) ??
|
|
51
|
+
(live && judge.activity === "checking" ? undefined : closing);
|
|
52
|
+
return interval(begin, end);
|
|
53
|
+
});
|
|
54
|
+
const archiveStart = timestampMs(judge.archiveStartedAt);
|
|
55
|
+
if (archiveStart !== undefined)
|
|
56
|
+
intervals.push(
|
|
57
|
+
...interval(
|
|
58
|
+
archiveStart,
|
|
59
|
+
live && judge.activity === "finalizing" ? undefined : closing,
|
|
60
|
+
),
|
|
61
|
+
);
|
|
62
|
+
return mergeRuntime(intervals);
|
|
63
|
+
}
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
import type {
|
|
2
|
+
BenchmarkDefinition,
|
|
3
|
+
BenchmarkRun,
|
|
4
|
+
ModelRef,
|
|
5
|
+
JudgeRunInput,
|
|
6
|
+
} from "../types";
|
|
7
|
+
import { fingerprint } from "../infra/files";
|
|
8
|
+
import { JUDGE_PROTOCOL } from "../judgment";
|
|
9
|
+
import { JUDGE_AGENT } from "../infra/judging/agent";
|
|
10
|
+
|
|
11
|
+
/** Declared, candidate-visible inputs. Harness implementation hashes are provenance. */
|
|
12
|
+
export function candidateFingerprint(
|
|
13
|
+
definition: BenchmarkDefinition,
|
|
14
|
+
evalId: string,
|
|
15
|
+
model: ModelRef,
|
|
16
|
+
runtime: BenchmarkRun["runtime"],
|
|
17
|
+
) {
|
|
18
|
+
const item = definition.evals.find((item) => item.id === evalId)!;
|
|
19
|
+
const [name] = model.split("#"),
|
|
20
|
+
slash = name.indexOf("/");
|
|
21
|
+
const provider = definition.candidate.providers?.[name.slice(0, slash)];
|
|
22
|
+
const { models, ...settings } = provider ?? {};
|
|
23
|
+
return fingerprint({
|
|
24
|
+
prompt: item.prompt,
|
|
25
|
+
source: item.sourceHash,
|
|
26
|
+
model,
|
|
27
|
+
image: runtime.imageId,
|
|
28
|
+
candidate: {
|
|
29
|
+
timeoutMs: definition.candidate.timeoutMs,
|
|
30
|
+
websearch: definition.candidate.websearch,
|
|
31
|
+
provider: provider
|
|
32
|
+
? { ...settings, model: models?.[name.slice(slash + 1)] }
|
|
33
|
+
: undefined,
|
|
34
|
+
},
|
|
35
|
+
container: {
|
|
36
|
+
engine: definition.container.engine,
|
|
37
|
+
cpus: definition.container.cpus,
|
|
38
|
+
memoryMiB: definition.container.memoryMiB,
|
|
39
|
+
},
|
|
40
|
+
});
|
|
41
|
+
}
|
|
42
|
+
export const judgeFingerprint = (
|
|
43
|
+
definition: BenchmarkDefinition,
|
|
44
|
+
evalId: string,
|
|
45
|
+
) =>
|
|
46
|
+
fingerprint({
|
|
47
|
+
rubric: definition.evals.find((item) => item.id === evalId)!.judge,
|
|
48
|
+
agent: JUDGE_AGENT,
|
|
49
|
+
judge: definition.judge,
|
|
50
|
+
protocol: JUDGE_PROTOCOL,
|
|
51
|
+
});
|
|
52
|
+
export const savedJudgeFingerprint = (
|
|
53
|
+
input: Pick<
|
|
54
|
+
JudgeRunInput,
|
|
55
|
+
"rubric" | "agent" | "protocol" | "model" | "timeoutMs" | "websearch"
|
|
56
|
+
>,
|
|
57
|
+
) =>
|
|
58
|
+
fingerprint({
|
|
59
|
+
rubric: input.rubric,
|
|
60
|
+
agent: input.agent,
|
|
61
|
+
protocol: input.protocol,
|
|
62
|
+
judge: {
|
|
63
|
+
model: input.model,
|
|
64
|
+
timeoutMs: input.timeoutMs,
|
|
65
|
+
websearch: input.websearch,
|
|
66
|
+
},
|
|
67
|
+
});
|