niceeval 0.13.4-canary.49 → 0.14.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.
Files changed (71) hide show
  1. package/INDEX.md +3 -3
  2. package/dist/inspection/overview.cjs +20 -4
  3. package/dist/inspection/overview.cjs.map +1 -1
  4. package/dist/inspection/overview.d.cts +5 -0
  5. package/dist/inspection/overview.d.mts +5 -0
  6. package/dist/inspection/overview.d.ts +5 -0
  7. package/dist/inspection/protocol.d.cts +238 -0
  8. package/dist/inspection/protocol.d.mts +238 -0
  9. package/dist/inspection/protocol.d.ts +238 -0
  10. package/dist/inspection/public.mjs +19 -16
  11. package/dist/inspection/results.cjs +11 -10
  12. package/dist/inspection/results.cjs.map +1 -1
  13. package/dist/inspection/results.d.cts +34 -0
  14. package/dist/inspection/results.d.mts +34 -0
  15. package/dist/inspection/results.d.ts +34 -0
  16. package/dist/show/contribution.cjs +11 -2
  17. package/dist/show/contribution.cjs.map +1 -1
  18. package/dist/show/contribution.d.cts +7 -0
  19. package/dist/show/contribution.d.mts +7 -0
  20. package/dist/show/contribution.d.ts +7 -0
  21. package/dist/show/model.cjs +1 -0
  22. package/dist/show/model.cjs.map +1 -1
  23. package/dist/show/model.d.cts +2 -0
  24. package/dist/show/model.d.mts +2 -0
  25. package/dist/show/model.d.ts +2 -0
  26. package/dist/show/render.cjs +149 -81
  27. package/dist/show/render.cjs.map +1 -1
  28. package/dist/show/render.d.cts +3 -1
  29. package/dist/show/render.d.mts +3 -1
  30. package/dist/show/render.d.ts +3 -1
  31. package/dist/view/app-dist/.vite/manifest.json +18 -18
  32. package/dist/view/app-dist/assets/{AttemptDialog-zlgkBA66.js → AttemptDialog-76dX1VQq.js} +1 -1
  33. package/dist/view/app-dist/assets/{AttemptRoute-DN6R4719.js → AttemptRoute-DRHVh2JA.js} +1 -1
  34. package/dist/view/app-dist/assets/{ResultsPage-BfH9vA6y.js → ResultsPage-9CSI8dvZ.js} +2 -2
  35. package/dist/view/app-dist/assets/{RunPage-XiJvNLB-.js → RunPage-BUF0REv7.js} +1 -1
  36. package/dist/view/app-dist/assets/{TableContentView-V8MYLnmk.js → TableContentView-_Sbg5wDr.js} +1 -1
  37. package/dist/view/app-dist/assets/index-BGr_6pGY.js +19 -0
  38. package/dist/view/app-dist/assets/{quality-cost-scatter-Bxyj_9oc.js → quality-cost-scatter-B5wDa_F1.js} +1 -1
  39. package/dist/view/app-dist/assets/useSuspenseQuery-D3W8Uy33.js +1 -0
  40. package/dist/view/app-dist/index.html +1 -1
  41. package/dist/view/function-runtime.mjs +35 -20
  42. package/docs-site/zh/examples/ai-agent-application.mdx +1 -1
  43. package/docs-site/zh/examples/index.mdx +1 -3
  44. package/docs-site/zh/explanation/evals.mdx +1 -1
  45. package/docs-site/zh/explanation/experiment.mdx +3 -1
  46. package/docs-site/zh/explanation/overview.mdx +6 -4
  47. package/docs-site/zh/explanation/record.mdx +9 -5
  48. package/docs-site/zh/explanation/runner.mdx +3 -3
  49. package/docs-site/zh/index.mdx +4 -8
  50. package/docs-site/zh/introduction.mdx +2 -2
  51. package/docs-site/zh/reference/cli.mdx +8 -7
  52. package/docs-site/zh/troubleshooting/debug-sandbox.mdx +5 -5
  53. package/docs-site/zh/troubleshooting/debugging.mdx +8 -8
  54. package/docs-site/zh/troubleshooting/recover-after-kill.mdx +35 -55
  55. package/docs-site/zh/tutorials/accept-results.mdx +4 -4
  56. package/docs-site/zh/tutorials/agent-onboarding.mdx +2 -2
  57. package/docs-site/zh/tutorials/authoring.mdx +1 -1
  58. package/docs-site/zh/tutorials/compare-runs.mdx +3 -3
  59. package/docs-site/zh/tutorials/concurrency.mdx +6 -6
  60. package/docs-site/zh/tutorials/connect-your-agent.mdx +2 -2
  61. package/docs-site/zh/tutorials/docker-in-docker.mdx +1 -1
  62. package/docs-site/zh/tutorials/experiments.mdx +1 -1
  63. package/docs-site/zh/tutorials/install-custom-sandbox-agent.mdx +1 -1
  64. package/docs-site/zh/tutorials/quickstart.mdx +2 -2
  65. package/docs-site/zh/tutorials/reporters.mdx +3 -3
  66. package/docs-site/zh/tutorials/sandbox-agent.mdx +2 -2
  67. package/docs-site/zh/tutorials/sandbox-reuse.mdx +3 -3
  68. package/docs-site/zh/tutorials/viewing-results.mdx +10 -11
  69. package/package.json +1 -1
  70. package/dist/view/app-dist/assets/index-BSJP_UAR.js +0 -19
  71. package/dist/view/app-dist/assets/useSuspenseQuery-Bdi9nQF1.js +0 -1
@@ -1 +1 @@
1
- {"version":3,"file":"contribution.js","sourceRoot":"","sources":["contribution.ts"],"names":[],"mappings":";;;AAAA,mCAAgD;AAChD,0DAA+G;AAC/G,4DAAuF;AACvF,qDAAqM;AACrM,mEAAkF;AAClF,8DAA4D;AAC5D,2CAA+L;AAC/L,yCAAyL;AACzL,MAAM,IAAI,GAAG,CAAC,OAAe,EAAE,EAAE,CAAC,MAAM,CAAC,MAAM,CAAC,EAAE,OAAO,EAAE,UAAU,EAAE,QAAiB,EAAE,CAAC,CAAC;AAC5F,MAAM,MAAM,GAAG,CAAC,KAA0B,EAAuB,EAAE,CAAC,MAAM,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC;AAC5E,QAAA,gBAAgB,GAAG,MAAM,CAAC,MAAM,CAAC;IAC1C,MAAM,EAAE,MAAM,CAAC;QACX,IAAI,EAAE,QAAQ;QACd,IAAI,EAAE,IAAI,CAAC,2CAA2C,CAAC;KAC1D,CAAC;IACF,GAAG,EAAE,MAAM,CAAC;QACR,IAAI,EAAE,QAAQ;QACd,QAAQ,EAAE,IAAI;QACd,IAAI,EAAE,IAAI,CAAC,2CAA2C,CAAC;KAC1D,CAAC;IACF,UAAU,EAAE,MAAM,CAAC;QACf,IAAI,EAAE,QAAQ;QACd,QAAQ,EAAE,IAAI;QACd,IAAI,EAAE,IAAI,CAAC,2CAA2C,CAAC;KAC1D,CAAC;IACF,MAAM,EAAE,MAAM,CAAC;QACX,IAAI,EAAE,SAAS;QACf,IAAI,EAAE,IAAI,CAAC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I,GAAG,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,IAAI,GAAG,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;AACpD,CAAC;AACD,SAAS,MAAM,CAAC,KAAc;IAC1B,OAAO,KAAK,YAAY,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC;AAClE,CAAC;AACY,QAAA,cAAc,GAAgD,MAAM,CAAC,MAAM,CAAC;IACrF,IAAI,EAAE,MAAM;IACZ,OAAO,EAAE,iCAAiC;IAC1C,OAAO,EAAE,wBAAgB;IACzB,GAAG,EAAE,OAAO;CACf,CAAC,CAAC","sourcesContent":["import { Effect, Result, Schema } from \"effect\";\nimport { CliArguments, CliInvocationFacts, CliOutput, type CliOptionDefinition, } from \"../cli/application.ts\";\nimport { CliFeatureError, type CliCommandContribution, } from \"../cli/contribution.ts\";\nimport { InspectionIntegrityError, InspectionOperationError, externalInspectionSource, openInspectionSource, operationalInspectionSource, selectInspectionOperation, } from \"../inspection/index.ts\";\nimport { ExperimentIdSchema, RunIdSchema, } from \"../record/codec/identifiers.ts\";\nimport { parseAttemptLocator } from \"../attempt-locator.ts\";\nimport { renderAttempt, renderDiff, renderExperiment, renderOverview, renderRun, renderSources, renderTiming, renderTrace, renderTraceDetail, renderUsage, traceSelector, } from \"./render.ts\";\nimport { projectAttempt, projectDiff, projectExperiment, projectOverview, projectRun, projectSources, projectTiming, projectTrace, projectTraceDetail, projectUsage, } from \"./model.ts\";\nconst help = (summary: string) => Object.freeze({ summary, visibility: \"public\" as const });\nconst option = (value: CliOptionDefinition): CliOptionDefinition => Object.freeze(value);\nexport const SHOW_CLI_OPTIONS = Object.freeze({\n record: option({\n type: \"string\",\n help: help(\"Read an external canonical SQLite Record.\"),\n }),\n run: option({\n type: \"string\",\n multiple: true,\n help: help(\"Show one sealed Run; repeat to show more.\"),\n }),\n experiment: option({\n type: \"string\",\n multiple: true,\n help: help(\"Show one Experiment; repeat to show more.\"),\n }),\n source: option({\n type: \"boolean\",\n help: help(\"Show captured source facts for one Attempt locator.\"),\n }),\n execution: option({\n type: \"boolean\",\n help: help(\"Show the execution outline for one Attempt locator.\"),\n }),\n timing: option({\n type: \"boolean\",\n help: help(\"Show captured timing for one Attempt locator.\"),\n }),\n usage: option({\n type: \"boolean\",\n help: help(\"Show captured usage for one Attempt locator.\"),\n }),\n diff: option({\n type: \"boolean\",\n help: help(\"Show captured file changes for one Attempt locator.\"),\n }),\n expand: option({\n type: \"string\",\n help: help(\"Expand one stable execution identity.\"),\n }),\n help: option({ type: \"boolean\", short: \"h\", help: help(\"Print show help.\") }),\n} satisfies Readonly<Record<string, CliOptionDefinition>>);\nconst SHOW_HELP = `niceeval show — inspect results in the terminal\n\nUsage:\n niceeval show [--record <file>]\n niceeval show --run <run-id>... [--record <file>]\n niceeval show --experiment <experiment-id>... [--record <file>]\n niceeval show @<locator> [--record <file>]\n niceeval show @<locator> --source\n niceeval show @<locator> --execution [--expand <stable-id>]\n niceeval show @<locator> --timing\n niceeval show @<locator> --usage\n niceeval show @<locator> --diff\n\nSelectors:\n --record <file> Read an external canonical SQLite Record.\n --run <run-id> Show one exact sealed Run; repeatable.\n --experiment <experiment-id> Show one exact Experiment; repeatable.\n\nAttempt details:\n --source Show captured sources and Assertion sites.\n --execution Show the bounded execution outline.\n --expand <stable-id> Expand an itemId, toolOccurrenceId, or commandId.\n --timing Show captured timing activities.\n --usage Show captured usage totals and observations.\n --diff Show captured file-change windows.\n\n --help, -h Print show help.\n`;\ntype Requirements = CliArguments | CliInvocationFacts | CliOutput;\ntype Error = CliFeatureError;\nconst failure = (operation: string, cause: unknown) => {\n const detail = cause instanceof InspectionIntegrityError\n ? `Record integrity failure for sealed Run ${cause.runId}.`\n : cause instanceof InspectionOperationError &&\n cause.code === \"inspection-record-integrity-failure\"\n ? `Record integrity failure${cause.identity === undefined ? \"\" : ` for sealed Run ${cause.identity.runId}`}.`\n : cause instanceof InspectionOperationError\n ? cause.code === \"inspection-selection-missing\" ||\n cause.code === \"inspection-result-invalid\"\n ? cause.reason\n : \"The Inspection operation could not be completed.\"\n : undefined;\n return new CliFeatureError({\n feature: \"show\",\n operation,\n cause,\n exitCode: 1,\n ...(detail === undefined\n ? {}\n : { display: `show ${operation} failed: ${detail}\\n` }),\n });\n};\nconst write = (channel: \"stdout\" | \"stderr\", value: string) => Effect.flatMap(CliOutput, (output) => channel === \"stdout\"\n ? output.writeStdout(value)\n : output.writeStderr(value)).pipe(Effect.mapError((cause) => failure(`write ${channel}`, cause)));\nconst usage = (message: string) => write(\"stderr\", `${message}\\n`).pipe(Effect.as(1));\nfunction runShow(argv: readonly string[]): Effect.Effect<number, Error, Requirements> {\n return Effect.gen(function* () {\n const parser = yield* CliArguments;\n const parsedResult = yield* Effect.try({\n try: () => parser.parse(argv, SHOW_CLI_OPTIONS),\n catch: (cause) => failure(\"parse arguments\", cause),\n }).pipe(Effect.result);\n if (Result.isFailure(parsedResult))\n return yield* usage(reason(parsedResult.failure.cause));\n const parsed = parsedResult.success;\n if (parsed.values.help === true) {\n yield* write(\"stdout\", SHOW_HELP);\n return 0;\n }\n const locator = parsed.positionals[0];\n if (parsed.positionals.length > 1)\n return yield* usage(\"niceeval show accepts at most one Attempt locator.\");\n const decodedLocator = locator === undefined\n ? undefined\n : parseAttemptLocator(locator);\n if (decodedLocator !== undefined && !decodedLocator.valid)\n return yield* usage(`Invalid Attempt locator ${JSON.stringify(locator)}; expected canonical @<locator>.`);\n const runIds = parseRunIds(parsed.values.run);\n if (typeof runIds === \"string\")\n return yield* usage(runIds);\n const experimentIds = parseExperimentIds(parsed.values.experiment);\n if (typeof experimentIds === \"string\")\n return yield* usage(experimentIds);\n const source = parsed.values.source === true;\n const execution = parsed.values.execution === true;\n const timing = parsed.values.timing === true;\n const showUsage = parsed.values.usage === true;\n const diff = parsed.values.diff === true;\n const detailModes = [source, execution, timing, showUsage, diff].filter(Boolean).length;\n const expand = typeof parsed.values.expand === \"string\"\n ? parsed.values.expand\n : undefined;\n if (detailModes > 1)\n return yield* usage(\"--source, --execution, --timing, --usage, and --diff are mutually exclusive.\");\n if (detailModes > 0 && locator === undefined)\n return yield* usage(\"--source, --execution, --timing, --usage, and --diff require one Attempt locator.\");\n if (expand !== undefined && !execution)\n return yield* usage(\"--expand requires --execution.\");\n if (expand !== undefined && /^(?:t\\d+\\.c\\d+|cmd\\d+)$/u.test(expand))\n return yield* usage(\"Legacy positional execution handles are not accepted; use a stable itemId, toolOccurrenceId, or commandId from the outline.\");\n if (locator !== undefined && (runIds.length > 0 || experimentIds.length > 0))\n return yield* usage(\"An Attempt locator, --run, and --experiment are mutually exclusive.\");\n if (runIds.length > 0 && experimentIds.length > 0)\n return yield* usage(\"--run and --experiment are mutually exclusive.\");\n const facts = yield* Effect.flatMap(CliInvocationFacts, ({ facts }) => facts).pipe(Effect.mapError((cause) => failure(\"read invocation facts\", cause)));\n const inspectionSource = typeof parsed.values.record === \"string\"\n ? externalInspectionSource(facts.cwd, parsed.values.record)\n : operationalInspectionSource(facts.cwd);\n return yield* Effect.scoped(Effect.gen(function* () {\n const opened = yield* openInspectionSource(inspectionSource).pipe(Effect.mapError((cause) => failure(\"open Record source\", cause)));\n const select = <A>(operation: string, evaluate: () => A): Effect.Effect<A, Error> => Effect.try({\n try: evaluate,\n catch: (cause) => failure(`execute ${operation}`, cause),\n });\n const project = <A>(operation: string, evaluate: () => A): Effect.Effect<A, Error> => Effect.try({\n try: evaluate,\n catch: (cause) => failure(`project ${operation} result`, cause),\n });\n if (decodedLocator === undefined &&\n runIds.length === 0 &&\n experimentIds.length === 0) {\n const document = yield* select(\"overview.get\", () => selectInspectionOperation(opened, { kind: \"overview.get\" }));\n yield* write(\"stdout\", renderOverview(yield* project(\"overview.get\", () => projectOverview(document))));\n return 0;\n }\n if (runIds.length > 0) {\n const rendered: string[] = [];\n for (const runId of runIds) {\n const document = yield* select(\"run.overview\", () => selectInspectionOperation(opened, {\n kind: \"run.overview\",\n runId,\n }));\n rendered.push(renderRun(yield* project(\"run.overview\", () => projectRun(document))));\n }\n yield* write(\"stdout\", rendered.join(\"\"));\n return 0;\n }\n if (experimentIds.length > 0) {\n const rendered: string[] = [];\n for (const experimentId of experimentIds) {\n const document = yield* select(\"experiment.get\", () => selectInspectionOperation(opened, {\n kind: \"experiment.get\",\n experimentId,\n }));\n rendered.push(renderExperiment(yield* project(\"experiment.get\", () => projectExperiment(document))));\n }\n yield* write(\"stdout\", rendered.join(\"\"));\n return 0;\n }\n const selectedLocator = decodedLocator!.locator;\n if (source) {\n const document = yield* select(\"attempt.sources\", () => selectInspectionOperation(opened, {\n kind: \"attempt.sources\",\n locator: selectedLocator,\n }));\n yield* write(\"stdout\", renderSources(yield* project(\"attempt.sources\", () => projectSources(document, selectedLocator))));\n return 0;\n }\n if (execution) {\n const outline = yield* select(\"attempt.trace\", () => selectInspectionOperation(opened, {\n kind: \"attempt.trace\",\n locator: selectedLocator,\n }));\n const trace = yield* project(\"attempt.trace\", () => projectTrace(outline, selectedLocator));\n if (expand === undefined) {\n yield* write(\"stdout\", renderTrace(trace));\n return 0;\n }\n const selector = traceSelector(trace, expand);\n if (selector === undefined)\n return yield* usage(`Stable execution identity ${JSON.stringify(expand)} is not present in this Attempt outline.`);\n const detail = yield* select(\"attempt.trace.detail\", () => selectInspectionOperation(opened, {\n kind: \"attempt.trace.detail\",\n locator: selectedLocator,\n selector,\n }));\n yield* write(\"stdout\", renderTraceDetail(yield* project(\"attempt.trace.detail\", () => projectTraceDetail(detail, selectedLocator))));\n return 0;\n }\n if (timing) {\n const document = yield* select(\"attempt.timing\", () => selectInspectionOperation(opened, {\n kind: \"attempt.timing\",\n locator: selectedLocator,\n }));\n yield* write(\"stdout\", renderTiming(yield* project(\"attempt.timing\", () => projectTiming(document, selectedLocator))));\n return 0;\n }\n if (showUsage) {\n const document = yield* select(\"attempt.usage\", () => selectInspectionOperation(opened, {\n kind: \"attempt.usage\",\n locator: selectedLocator,\n }));\n yield* write(\"stdout\", renderUsage(yield* project(\"attempt.usage\", () => projectUsage(document, selectedLocator))));\n return 0;\n }\n if (diff) {\n const document = yield* select(\"attempt.diff\", () => selectInspectionOperation(opened, {\n kind: \"attempt.diff\",\n locator: selectedLocator,\n }));\n yield* write(\"stdout\", renderDiff(yield* project(\"attempt.diff\", () => projectDiff(document, selectedLocator))));\n return 0;\n }\n const document = yield* select(\"attempt.get\", () => selectInspectionOperation(opened, {\n kind: \"attempt.get\",\n locator: selectedLocator,\n }));\n yield* write(\"stdout\", renderAttempt(yield* project(\"attempt.get\", () => projectAttempt(document))));\n return 0;\n }));\n });\n}\nfunction parseRunIds(value: string | boolean | string[] | undefined): readonly Schema.Schema.Type<typeof RunIdSchema>[] | string {\n const values = typeof value === \"string\" ? [value] : Array.isArray(value) ? value : [];\n const output: Schema.Schema.Type<typeof RunIdSchema>[] = [];\n for (const candidate of values) {\n const decoded = Schema.decodeUnknownResult(RunIdSchema)(candidate);\n if (Result.isFailure(decoded))\n return `Invalid --run value ${JSON.stringify(candidate)}.`;\n if (!output.includes(decoded.success))\n output.push(decoded.success);\n }\n return Object.freeze(output.sort(compareIdentity));\n}\nfunction parseExperimentIds(value: string | boolean | string[] | undefined): readonly Schema.Schema.Type<typeof ExperimentIdSchema>[] | string {\n const values = typeof value === \"string\" ? [value] : Array.isArray(value) ? value : [];\n const output: Schema.Schema.Type<typeof ExperimentIdSchema>[] = [];\n for (const candidate of values) {\n const decoded = Schema.decodeUnknownResult(ExperimentIdSchema)(candidate);\n if (Result.isFailure(decoded))\n return `Invalid --experiment value ${JSON.stringify(candidate)}.`;\n if (!output.includes(decoded.success))\n output.push(decoded.success);\n }\n return Object.freeze(output.sort(compareIdentity));\n}\nfunction compareIdentity(left: string, right: string): number {\n return left < right ? -1 : left > right ? 1 : 0;\n}\nfunction reason(value: unknown): string {\n return value instanceof Error ? value.message : String(value);\n}\nexport const showCliCommand: CliCommandContribution<Requirements, Error> = Object.freeze({\n name: \"show\",\n summary: \"inspect results in the terminal\",\n options: SHOW_CLI_OPTIONS,\n run: runShow,\n});\n"]}
1
+ {"version":3,"file":"contribution.js","sourceRoot":"","sources":["contribution.ts"],"names":[],"mappings":";;;AAAA,mCAAgD;AAChD,0DAA+G;AAC/G,4DAAuF;AACvF,qDAAqM;AACrM,mEAAkF;AAClF,8DAA4D;AAC5D,2CAA+L;AAC/L,yCAAyL;AACzL,MAAM,IAAI,GAAG,CAAC,OAAe,EAAE,EAAE,CAAC,MAAM,CAAC,MAAM,CAAC,EAAE,OAAO,EAAE,UAAU,EAAE,QAAiB,EAAE,CAAC,CAAC;AAC5F,MAAM,MAAM,GAAG,CAAC,KAA0B,EAAuB,EAAE,CAAC,MAAM,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC;AAC5E,QAAA,gBAAgB,GAAG,MAAM,CAAC,MAAM,CAAC;IAC1C,MAAM,EAAE,MAAM,CAAC;QACX,IAAI,EAAE,QAAQ;QACd,IAAI,EAAE,IAAI,CAAC,2CAA2C,CAAC;KAC1D,CAAC;IACF,GAAG,EAAE,MAAM,CAAC;QACR,IAAI,EAAE,QAAQ;QACd,QAAQ,EAAE,IAAI;QACd,IAAI,EAAE,IAAI,CAAC,2CAA2C,CAAC;KAC1D,CAAC;IACF,UAAU,EAAE,MAAM,CAAC;QACf,IAAI,EAAE,QAAQ;QACd,QAAQ,EAAE,IAAI;QACd,IAAI,EAAE,IAAI,CAAC,2CAA2C,CAAC;KAC1D,CAAC;IACF,GAAG,EAAE,MAAM,CAAC;QACR,IAAI,EAAE,SAAS;QACf,IAAI,EAAE,IAAI,CAAC,mDAAmD,CAAC;KAClE,CAAC;IACF,MAAM,EAAE,MAAM,CAAC;QACX,IAAI,EAAE,SAAS;QACf,IAAI,EAAE,IAAI,CAAC,qDAAqD,CAAC;KACpE,CAAC;IACF,SAAS,EAAE,MAAM,CAAC;QACd,IAAI,EAAE,SAAS;QACf,IAAI,EAAE,IA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CAAC,OAAO,CAAC,CAAC;IACrC,CAAC;IACD,OAAO,MAAM,CAAC,MAAM,CAAC,MAAM,CAAC,IAAI,CAAC,eAAe,CAAC,CAAC,CAAC;AACvD,CAAC;AACD,SAAS,eAAe,CAAC,IAAY,EAAE,KAAa;IAChD,OAAO,IAAI,GAAG,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,IAAI,GAAG,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;AACpD,CAAC;AACD,SAAS,MAAM,CAAC,KAAc;IAC1B,OAAO,KAAK,YAAY,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC;AAClE,CAAC;AACY,QAAA,cAAc,GAAgD,MAAM,CAAC,MAAM,CAAC;IACrF,IAAI,EAAE,MAAM;IACZ,OAAO,EAAE,iCAAiC;IAC1C,OAAO,EAAE,wBAAgB;IACzB,GAAG,EAAE,OAAO;CACf,CAAC,CAAC","sourcesContent":["import { Effect, Result, Schema } from \"effect\";\nimport { CliArguments, CliInvocationFacts, CliOutput, type CliOptionDefinition, } from \"../cli/application.ts\";\nimport { CliFeatureError, type CliCommandContribution, } from \"../cli/contribution.ts\";\nimport { InspectionIntegrityError, InspectionOperationError, externalInspectionSource, openInspectionSource, operationalInspectionSource, selectInspectionOperation, } from \"../inspection/index.ts\";\nimport { ExperimentIdSchema, RunIdSchema, } from \"../record/codec/identifiers.ts\";\nimport { parseAttemptLocator } from \"../attempt-locator.ts\";\nimport { renderAttempt, renderDiff, renderExperiment, renderOverview, renderRun, renderSources, renderTiming, renderTrace, renderTraceDetail, renderUsage, traceSelector, } from \"./render.ts\";\nimport { projectAttempt, projectDiff, projectExperiment, projectOverview, projectRun, projectSources, projectTiming, projectTrace, projectTraceDetail, projectUsage, } from \"./model.ts\";\nconst help = (summary: string) => Object.freeze({ summary, visibility: \"public\" as const });\nconst option = (value: CliOptionDefinition): CliOptionDefinition => Object.freeze(value);\nexport const SHOW_CLI_OPTIONS = Object.freeze({\n record: option({\n type: \"string\",\n help: help(\"Read an external canonical SQLite Record.\"),\n }),\n run: option({\n type: \"string\",\n multiple: true,\n help: help(\"Show one sealed Run; repeat to show more.\"),\n }),\n experiment: option({\n type: \"string\",\n multiple: true,\n help: help(\"Show one Experiment; repeat to show more.\"),\n }),\n all: option({\n type: \"boolean\",\n help: help(\"Show Attempts hidden by the compact Results view.\"),\n }),\n source: option({\n type: \"boolean\",\n help: help(\"Show captured source facts for one Attempt locator.\"),\n }),\n execution: option({\n type: \"boolean\",\n help: help(\"Show the execution outline for one Attempt locator.\"),\n }),\n timing: option({\n type: \"boolean\",\n help: help(\"Show captured timing for one Attempt locator.\"),\n }),\n usage: option({\n type: \"boolean\",\n help: help(\"Show captured usage for one Attempt locator.\"),\n }),\n diff: option({\n type: \"boolean\",\n help: help(\"Show captured file changes for one Attempt locator.\"),\n }),\n expand: option({\n type: \"string\",\n help: help(\"Expand one stable execution identity.\"),\n }),\n help: option({ type: \"boolean\", short: \"h\", help: help(\"Print show help.\") }),\n} satisfies Readonly<Record<string, CliOptionDefinition>>);\nconst SHOW_HELP = `niceeval show — inspect results in the terminal\n\nUsage:\n niceeval show [--all] [--record <file>]\n niceeval show --run <run-id>... [--record <file>]\n niceeval show --experiment <experiment-id>... [--record <file>]\n niceeval show @<locator> [--record <file>]\n niceeval show @<locator> --source\n niceeval show @<locator> --execution [--expand <stable-id>]\n niceeval show @<locator> --timing\n niceeval show @<locator> --usage\n niceeval show @<locator> --diff\n\nSelectors:\n --record <file> Read an external canonical SQLite Record.\n --run <run-id> Show one exact sealed Run; repeatable.\n --experiment <experiment-id> Show one exact Experiment; repeatable.\n --all Show Attempts hidden by compact Results.\n\nAttempt details:\n --source Show captured sources and Assertion sites.\n --execution Show the bounded execution outline.\n --expand <stable-id> Expand an itemId, toolOccurrenceId, or commandId.\n --timing Show captured timing activities.\n --usage Show captured usage totals and observations.\n --diff Show captured file-change windows.\n\n --help, -h Print show help.\n`;\ntype Requirements = CliArguments | CliInvocationFacts | CliOutput;\ntype Error = CliFeatureError;\nconst failure = (operation: string, cause: unknown) => {\n const detail = cause instanceof InspectionIntegrityError\n ? `Record integrity failure for sealed Run ${cause.runId}.`\n : cause instanceof InspectionOperationError &&\n cause.code === \"inspection-record-integrity-failure\"\n ? `Record integrity failure${cause.identity === undefined ? \"\" : ` for sealed Run ${cause.identity.runId}`}.`\n : cause instanceof InspectionOperationError\n ? cause.code === \"inspection-selection-missing\" ||\n cause.code === \"inspection-result-invalid\"\n ? cause.reason\n : \"The Inspection operation could not be completed.\"\n : undefined;\n return new CliFeatureError({\n feature: \"show\",\n operation,\n cause,\n exitCode: 1,\n ...(detail === undefined\n ? {}\n : { display: `show ${operation} failed: ${detail}\\n` }),\n });\n};\nconst write = (channel: \"stdout\" | \"stderr\", value: string) => Effect.flatMap(CliOutput, (output) => channel === \"stdout\"\n ? output.writeStdout(value)\n : output.writeStderr(value)).pipe(Effect.mapError((cause) => failure(`write ${channel}`, cause)));\nconst usage = (message: string) => write(\"stderr\", `${message}\\n`).pipe(Effect.as(1));\nfunction runShow(argv: readonly string[]): Effect.Effect<number, Error, Requirements> {\n return Effect.gen(function* () {\n const parser = yield* CliArguments;\n const parsedResult = yield* Effect.try({\n try: () => parser.parse(argv, SHOW_CLI_OPTIONS),\n catch: (cause) => failure(\"parse arguments\", cause),\n }).pipe(Effect.result);\n if (Result.isFailure(parsedResult))\n return yield* usage(reason(parsedResult.failure.cause));\n const parsed = parsedResult.success;\n if (parsed.values.help === true) {\n yield* write(\"stdout\", SHOW_HELP);\n return 0;\n }\n const locator = parsed.positionals[0];\n if (parsed.positionals.length > 1)\n return yield* usage(\"niceeval show accepts at most one Attempt locator.\");\n const decodedLocator = locator === undefined\n ? undefined\n : parseAttemptLocator(locator);\n if (decodedLocator !== undefined && !decodedLocator.valid)\n return yield* usage(`Invalid Attempt locator ${JSON.stringify(locator)}; expected canonical @<locator>.`);\n const runIds = parseRunIds(parsed.values.run);\n if (typeof runIds === \"string\")\n return yield* usage(runIds);\n const experimentIds = parseExperimentIds(parsed.values.experiment);\n if (typeof experimentIds === \"string\")\n return yield* usage(experimentIds);\n const source = parsed.values.source === true;\n const execution = parsed.values.execution === true;\n const timing = parsed.values.timing === true;\n const showUsage = parsed.values.usage === true;\n const diff = parsed.values.diff === true;\n const all = parsed.values.all === true;\n const detailModes = [source, execution, timing, showUsage, diff].filter(Boolean).length;\n const expand = typeof parsed.values.expand === \"string\"\n ? parsed.values.expand\n : undefined;\n if (detailModes > 1)\n return yield* usage(\"--source, --execution, --timing, --usage, and --diff are mutually exclusive.\");\n if (detailModes > 0 && locator === undefined)\n return yield* usage(\"--source, --execution, --timing, --usage, and --diff require one Attempt locator.\");\n if (expand !== undefined && !execution)\n return yield* usage(\"--expand requires --execution.\");\n if (expand !== undefined && /^(?:t\\d+\\.c\\d+|cmd\\d+)$/u.test(expand))\n return yield* usage(\"Legacy positional execution handles are not accepted; use a stable itemId, toolOccurrenceId, or commandId from the outline.\");\n if (locator !== undefined && (runIds.length > 0 || experimentIds.length > 0))\n return yield* usage(\"An Attempt locator, --run, and --experiment are mutually exclusive.\");\n if (runIds.length > 0 && experimentIds.length > 0)\n return yield* usage(\"--run and --experiment are mutually exclusive.\");\n if (all &&\n (locator !== undefined || runIds.length > 0 || experimentIds.length > 0))\n return yield* usage(\"--all applies only to Results, not --experiment, --run, or an Attempt locator.\");\n const facts = yield* Effect.flatMap(CliInvocationFacts, ({ facts }) => facts).pipe(Effect.mapError((cause) => failure(\"read invocation facts\", cause)));\n const inspectionSource = typeof parsed.values.record === \"string\"\n ? externalInspectionSource(facts.cwd, parsed.values.record)\n : operationalInspectionSource(facts.cwd);\n return yield* Effect.scoped(Effect.gen(function* () {\n const opened = yield* openInspectionSource(inspectionSource).pipe(Effect.mapError((cause) => failure(\"open Record source\", cause)));\n const select = <A>(operation: string, evaluate: () => A): Effect.Effect<A, Error> => Effect.try({\n try: evaluate,\n catch: (cause) => failure(`execute ${operation}`, cause),\n });\n const project = <A>(operation: string, evaluate: () => A): Effect.Effect<A, Error> => Effect.try({\n try: evaluate,\n catch: (cause) => failure(`project ${operation} result`, cause),\n });\n if (decodedLocator === undefined &&\n runIds.length === 0 &&\n experimentIds.length === 0) {\n const document = yield* select(\"overview.get\", () => selectInspectionOperation(opened, { kind: \"overview.get\" }));\n yield* write(\"stdout\", renderOverview(yield* project(\"overview.get\", () => projectOverview(document)), { all }));\n return 0;\n }\n if (runIds.length > 0) {\n const rendered: string[] = [];\n for (const runId of runIds) {\n const document = yield* select(\"run.overview\", () => selectInspectionOperation(opened, {\n kind: \"run.overview\",\n runId,\n }));\n rendered.push(renderRun(yield* project(\"run.overview\", () => projectRun(document))));\n }\n yield* write(\"stdout\", rendered.join(\"\"));\n return 0;\n }\n if (experimentIds.length > 0) {\n const rendered: string[] = [];\n for (const experimentId of experimentIds) {\n const document = yield* select(\"experiment.get\", () => selectInspectionOperation(opened, {\n kind: \"experiment.get\",\n experimentId,\n }));\n rendered.push(renderExperiment(yield* project(\"experiment.get\", () => projectExperiment(document))));\n }\n yield* write(\"stdout\", rendered.join(\"\"));\n return 0;\n }\n const selectedLocator = decodedLocator!.locator;\n if (source) {\n const document = yield* select(\"attempt.sources\", () => selectInspectionOperation(opened, {\n kind: \"attempt.sources\",\n locator: selectedLocator,\n }));\n yield* write(\"stdout\", renderSources(yield* project(\"attempt.sources\", () => projectSources(document, selectedLocator))));\n return 0;\n }\n if (execution) {\n const outline = yield* select(\"attempt.trace\", () => selectInspectionOperation(opened, {\n kind: \"attempt.trace\",\n locator: selectedLocator,\n }));\n const trace = yield* project(\"attempt.trace\", () => projectTrace(outline, selectedLocator));\n if (expand === undefined) {\n yield* write(\"stdout\", renderTrace(trace));\n return 0;\n }\n const selector = traceSelector(trace, expand);\n if (selector === undefined)\n return yield* usage(`Stable execution identity ${JSON.stringify(expand)} is not present in this Attempt outline.`);\n const detail = yield* select(\"attempt.trace.detail\", () => selectInspectionOperation(opened, {\n kind: \"attempt.trace.detail\",\n locator: selectedLocator,\n selector,\n }));\n yield* write(\"stdout\", renderTraceDetail(yield* project(\"attempt.trace.detail\", () => projectTraceDetail(detail, selectedLocator))));\n return 0;\n }\n if (timing) {\n const document = yield* select(\"attempt.timing\", () => selectInspectionOperation(opened, {\n kind: \"attempt.timing\",\n locator: selectedLocator,\n }));\n yield* write(\"stdout\", renderTiming(yield* project(\"attempt.timing\", () => projectTiming(document, selectedLocator))));\n return 0;\n }\n if (showUsage) {\n const document = yield* select(\"attempt.usage\", () => selectInspectionOperation(opened, {\n kind: \"attempt.usage\",\n locator: selectedLocator,\n }));\n yield* write(\"stdout\", renderUsage(yield* project(\"attempt.usage\", () => projectUsage(document, selectedLocator))));\n return 0;\n }\n if (diff) {\n const document = yield* select(\"attempt.diff\", () => selectInspectionOperation(opened, {\n kind: \"attempt.diff\",\n locator: selectedLocator,\n }));\n yield* write(\"stdout\", renderDiff(yield* project(\"attempt.diff\", () => projectDiff(document, selectedLocator))));\n return 0;\n }\n const document = yield* select(\"attempt.get\", () => selectInspectionOperation(opened, {\n kind: \"attempt.get\",\n locator: selectedLocator,\n }));\n yield* write(\"stdout\", renderAttempt(yield* project(\"attempt.get\", () => projectAttempt(document))));\n return 0;\n }));\n });\n}\nfunction parseRunIds(value: string | boolean | string[] | undefined): readonly Schema.Schema.Type<typeof RunIdSchema>[] | string {\n const values = typeof value === \"string\" ? [value] : Array.isArray(value) ? value : [];\n const output: Schema.Schema.Type<typeof RunIdSchema>[] = [];\n for (const candidate of values) {\n const decoded = Schema.decodeUnknownResult(RunIdSchema)(candidate);\n if (Result.isFailure(decoded))\n return `Invalid --run value ${JSON.stringify(candidate)}.`;\n if (!output.includes(decoded.success))\n output.push(decoded.success);\n }\n return Object.freeze(output.sort(compareIdentity));\n}\nfunction parseExperimentIds(value: string | boolean | string[] | undefined): readonly Schema.Schema.Type<typeof ExperimentIdSchema>[] | string {\n const values = typeof value === \"string\" ? [value] : Array.isArray(value) ? value : [];\n const output: Schema.Schema.Type<typeof ExperimentIdSchema>[] = [];\n for (const candidate of values) {\n const decoded = Schema.decodeUnknownResult(ExperimentIdSchema)(candidate);\n if (Result.isFailure(decoded))\n return `Invalid --experiment value ${JSON.stringify(candidate)}.`;\n if (!output.includes(decoded.success))\n output.push(decoded.success);\n }\n return Object.freeze(output.sort(compareIdentity));\n}\nfunction compareIdentity(left: string, right: string): number {\n return left < right ? -1 : left > right ? 1 : 0;\n}\nfunction reason(value: unknown): string {\n return value instanceof Error ? value.message : String(value);\n}\nexport const showCliCommand: CliCommandContribution<Requirements, Error> = Object.freeze({\n name: \"show\",\n summary: \"inspect results in the terminal\",\n options: SHOW_CLI_OPTIONS,\n run: runShow,\n});\n"]}
@@ -22,6 +22,13 @@ export declare const SHOW_CLI_OPTIONS: Readonly<{
22
22
  readonly optionalValue?: import("../cli/application.cjs").CliOptionalOptionValue;
23
23
  readonly help?: import("../cli/application.cjs").CliOptionHelp;
24
24
  }>;
25
+ all: Readonly<{
26
+ readonly type: "string" | "boolean";
27
+ readonly multiple?: true;
28
+ readonly short?: string;
29
+ readonly optionalValue?: import("../cli/application.cjs").CliOptionalOptionValue;
30
+ readonly help?: import("../cli/application.cjs").CliOptionHelp;
31
+ }>;
25
32
  source: Readonly<{
26
33
  readonly type: "string" | "boolean";
27
34
  readonly multiple?: true;
@@ -22,6 +22,13 @@ export declare const SHOW_CLI_OPTIONS: Readonly<{
22
22
  readonly optionalValue?: import("../cli/application.mjs").CliOptionalOptionValue;
23
23
  readonly help?: import("../cli/application.mjs").CliOptionHelp;
24
24
  }>;
25
+ all: Readonly<{
26
+ readonly type: "string" | "boolean";
27
+ readonly multiple?: true;
28
+ readonly short?: string;
29
+ readonly optionalValue?: import("../cli/application.mjs").CliOptionalOptionValue;
30
+ readonly help?: import("../cli/application.mjs").CliOptionHelp;
31
+ }>;
25
32
  source: Readonly<{
26
33
  readonly type: "string" | "boolean";
27
34
  readonly multiple?: true;
@@ -22,6 +22,13 @@ export declare const SHOW_CLI_OPTIONS: Readonly<{
22
22
  readonly optionalValue?: import("../cli/application.js").CliOptionalOptionValue;
23
23
  readonly help?: import("../cli/application.js").CliOptionHelp;
24
24
  }>;
25
+ all: Readonly<{
26
+ readonly type: "string" | "boolean";
27
+ readonly multiple?: true;
28
+ readonly short?: string;
29
+ readonly optionalValue?: import("../cli/application.js").CliOptionalOptionValue;
30
+ readonly help?: import("../cli/application.js").CliOptionHelp;
31
+ }>;
25
32
  source: Readonly<{
26
33
  readonly type: "string" | "boolean";
27
34
  readonly multiple?: true;
@@ -12,6 +12,7 @@ exports.projectUsage = projectUsage;
12
12
  exports.projectDiff = projectDiff;
13
13
  const metric = (value) => ({ state: value.state, value: value.value });
14
14
  const aggregate = (value) => ({
15
+ evaluationKind: value.evaluationKind,
15
16
  expected: value.denominator.expected,
16
17
  observed: value.denominator.observed,
17
18
  passed: value.verdict.tally.passed,
@@ -1 +1 @@
1
- {"version":3,"file":"model.js","sourceRoot":"","sources":["model.ts"],"names":[],"mappings":";;AAyQA,0CAWC;AACD,8CAMC;AACD,gCA2BC;AACD,wCA2BC;AACD,wCAqBC;AACD,oCAmCC;AACD,gDAQC;AACD,sCAEC;AACD,oCAEC;AACD,kCAEC;AArLD,MAAM,MAAM,GAAG,CAAC,KAGf,EAAU,EAAE,CAAC,CAAC,EAAE,KAAK,EAAE,KAAK,CAAC,KAAK,EAAE,KAAK,EAAE,KAAK,CAAC,KAAK,EAAE,CAAC,CAAC;AAC3D,MAAM,SAAS,GAAG,CAAC,KAAyC,EAAa,EAAE,CAAC,CAAC;IACzE,QAAQ,EAAE,KAAK,CAAC,WAAW,CAAC,QAAQ;IACpC,QAAQ,EAAE,KAAK,CAAC,WAAW,CAAC,QAAQ;IACpC,MAAM,EAAE,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,MAAM;IAClC,MAAM,EAAE,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,MAAM;I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C,CAAC,CAAC,IAAI,CAAC,IAAI,KAAK,iBAAiB,CAAC,CAAC,CAAC,IAAI,CAAC,gBAAgB,CAAC,CAAC,CAAC,IAAI,CAAC,SAAS;QACvH,IAAI;KACP,CAAC;AACN,CAAC;AACD,SAAgB,aAAa,CAAC,QAAwD,EAAE,OAAe;IACnG,OAAO,EAAE,OAAO,EAAE,GAAG,QAAQ,CAAC,MAAM,EAAE,CAAC;AAC3C,CAAC;AACD,SAAgB,YAAY,CAAC,QAAuD,EAAE,OAAe;IACjG,OAAO,EAAE,OAAO,EAAE,GAAG,QAAQ,CAAC,KAAK,EAAE,CAAC;AAC1C,CAAC;AACD,SAAgB,WAAW,CAAC,QAAsD,EAAE,OAAe;IAC/F,OAAO,EAAE,OAAO,EAAE,GAAG,QAAQ,CAAC,IAAI,EAAE,CAAC;AACzC,CAAC","sourcesContent":["import type { InspectionOverviewResult, InspectionScoredValue, InspectionSuccessDocumentFor, InspectionTraceDetailResult, } from \"../inspection/index.ts\";\nimport type { AttemptOutcome as RecordAttemptOutcome, MembershipAction as RecordMembershipAction } from \"../record/model/core.ts\";\nimport type { Verdict as PublicVerdict } from \"../shared/types.ts\";\nimport type { AgentTurnOutcome as ReceiptAgentTurnOutcome, SANDBOX_COMMAND_PHASES } from \"../record/family/protocol-values.ts\";\nexport type MetricState = \"available\" | \"partial\" | \"unavailable\" | \"empty\" | \"unsupported\" | \"failed\";\nexport type Verdict = PublicVerdict;\nexport type MembershipAction = RecordMembershipAction;\nexport type AttemptOutcome = RecordAttemptOutcome;\nexport type AgentTurnOutcome = ReceiptAgentTurnOutcome;\nexport type SectionState = \"available\" | \"not-recorded\" | \"partial\" | \"unavailable\";\nexport type ProjectionState = \"complete\" | \"partial\" | \"not-recorded\" | \"invalid\";\nexport type SourceState = \"available\" | \"not-recorded\" | \"invalid\";\nexport type ScoredValue = InspectionScoredValue;\nexport type SourceContent = {\n readonly state: \"available\";\n readonly text: string;\n} | {\n readonly state: \"omitted\";\n readonly reason: \"inspection-result-byte-limit\";\n readonly byteLength: number;\n readonly byteLimit: number;\n};\nexport type AssertionSource = {\n readonly state: \"mapped\";\n readonly sourceItemId: string;\n readonly sha256: string;\n} | {\n readonly state: \"unmapped\";\n readonly reason: \"source-snapshot-not-recorded\" | \"position-unrepresentable\";\n};\nexport type CommandPhase = (typeof SANDBOX_COMMAND_PHASES)[number];\nexport type CommandOutcome = \"exited\" | \"terminated\" | \"not-started\";\nexport type Metric = {\n readonly state: MetricState;\n readonly value: number | null;\n};\nexport type ExecutionValue = {\n readonly state: \"available\";\n readonly value: string;\n} | {\n readonly state: \"mixed\";\n} | {\n readonly state: \"unavailable\";\n};\nexport type Aggregate = {\n readonly expected: number;\n readonly observed: number;\n readonly passed: number;\n readonly failed: number;\n readonly errored: number;\n readonly skipped: number;\n readonly passRate: Metric;\n readonly score: Metric;\n readonly durationMs: Metric;\n readonly tokens: Metric;\n};\nexport interface OverviewView {\n readonly totals: Aggregate;\n readonly experiments: readonly {\n readonly experimentId: string;\n readonly agent: ExecutionValue;\n readonly model: ExecutionValue;\n readonly aggregate: Aggregate;\n }[];\n readonly cells: readonly {\n readonly experimentId: string;\n readonly evalId: string;\n readonly aggregate: Aggregate;\n readonly members: readonly {\n readonly publication: {\n readonly state: \"pending\";\n } | {\n readonly state: \"absent\";\n readonly reason: string;\n } | {\n readonly state: \"published\";\n readonly action: MembershipAction;\n readonly attemptId: string;\n readonly attemptLocator: string;\n readonly originRunId: string;\n readonly originSlotId: string;\n readonly score: Metric;\n readonly durationMs: Metric;\n readonly tokens: Metric;\n };\n }[];\n }[];\n}\nexport interface ExperimentView {\n readonly experimentId: string;\n readonly aggregate: Aggregate;\n readonly cells: OverviewView[\"cells\"];\n}\nexport interface RunView {\n readonly runId: string;\n readonly experimentId: string;\n readonly startedAt: number;\n readonly completedAt: number;\n readonly expected: number;\n readonly observed: number;\n readonly coverage: InspectionSuccessDocumentFor<\"run.overview\">[\"runOverview\"][\"coverage\"];\n readonly usage: InspectionSuccessDocumentFor<\"run.overview\">[\"runOverview\"][\"usage\"];\n readonly limitations: InspectionSuccessDocumentFor<\"run.overview\">[\"runOverview\"][\"limitations\"];\n readonly members: readonly {\n readonly slotId: string;\n readonly evalId: string;\n readonly attemptOrdinal: number;\n readonly locator: string | null;\n readonly state: MembershipAction | \"missing\";\n readonly relation: \"origin\" | \"reference\" | null;\n readonly outcome: AttemptOutcome | null;\n readonly verdict: Verdict | null;\n readonly score: ScoredValue | null;\n readonly coverage: InspectionSuccessDocumentFor<\"run.overview\">[\"runOverview\"][\"members\"][number][\"coverage\"];\n readonly usage: InspectionSuccessDocumentFor<\"run.overview\">[\"runOverview\"][\"members\"][number][\"usage\"];\n readonly limitations: InspectionSuccessDocumentFor<\"run.overview\">[\"runOverview\"][\"members\"][number][\"limitations\"];\n }[];\n}\nexport interface AttemptView {\n readonly locator: string;\n readonly verdict: Verdict | null;\n readonly attemptId: string;\n readonly evalId: string;\n readonly slotId: string;\n readonly outcome: AttemptOutcome;\n readonly originRunId: string;\n readonly experimentId: string;\n readonly score: ScoredValue;\n readonly sections: {\n readonly assertions: SectionState;\n readonly sources: SectionState;\n readonly trace: SectionState;\n readonly timing: SectionState;\n readonly usage: SectionState;\n readonly diff: SectionState;\n };\n readonly assertions: {\n readonly state: SourceState;\n readonly entries: readonly {\n readonly entryId: string;\n readonly label?: string;\n readonly key?: string;\n readonly groupPath: readonly string[];\n }[];\n };\n readonly evidenceCoverage: readonly string[];\n readonly limitations: readonly string[];\n}\nexport interface SourcesView {\n readonly locator: string;\n readonly state: SourceState;\n readonly items: readonly {\n readonly path: string;\n readonly sourceItemId: string;\n readonly byteLength: number;\n readonly content: SourceContent;\n }[];\n readonly assertions: {\n readonly state: SourceState;\n readonly sites: readonly {\n readonly entryId: string;\n readonly role: \"declaration\" | \"threshold\" | \"score\" | \"gate\" | \"optional\" | \"stop\";\n readonly start: {\n readonly line: number;\n readonly column: number;\n };\n readonly end: {\n readonly line: number;\n readonly column: number;\n };\n readonly source: AssertionSource;\n }[];\n readonly hasMoreSourceSites: boolean;\n readonly omittedSourceSiteCount: number;\n };\n readonly hasMore: boolean;\n readonly omittedItemCount: number;\n}\ntype WithoutTurnId<Value> = Value extends unknown ? Omit<Value, \"turnId\"> : never;\nexport type TraceItem = WithoutTurnId<InspectionSuccessDocumentFor<\"attempt.trace\">[\"trace\"][\"conversation\"][\"items\"][number]>;\nexport interface TraceView {\n readonly locator: string;\n readonly conversation: {\n readonly state: ProjectionState;\n readonly limitations: InspectionSuccessDocumentFor<\"attempt.trace\">[\"trace\"][\"conversation\"][\"limitations\"];\n readonly limitationsTruncated: boolean;\n readonly omittedLimitationCount: number;\n readonly turnsTruncated: boolean;\n readonly omittedTurnCount: number;\n readonly itemCount: number;\n readonly itemsTruncated: boolean;\n readonly omittedItemCount: number;\n readonly turns: readonly {\n readonly turnId: string;\n readonly sequence: number;\n readonly outcome: AgentTurnOutcome;\n readonly items: readonly TraceItem[];\n }[];\n };\n readonly commands: {\n readonly state: ProjectionState;\n readonly limitations: InspectionSuccessDocumentFor<\"attempt.trace\">[\"trace\"][\"commands\"][\"limitations\"];\n readonly limitationsTruncated: boolean;\n readonly omittedLimitationCount: number;\n readonly hasMore: boolean;\n readonly omittedCommandCount: number;\n readonly items: readonly {\n readonly commandId: InspectionSuccessDocumentFor<\"attempt.trace\">[\"trace\"][\"commands\"][\"items\"][number][\"commandId\"];\n readonly phase: CommandPhase;\n readonly outcome: CommandOutcome;\n }[];\n };\n readonly diagnostics: InspectionSuccessDocumentFor<\"attempt.trace\">[\"trace\"][\"diagnostics\"];\n readonly identities: {\n readonly itemIds: InspectionSuccessDocumentFor<\"attempt.trace\">[\"trace\"][\"identityIndex\"][\"itemIds\"];\n readonly toolOccurrenceIds: InspectionSuccessDocumentFor<\"attempt.trace\">[\"trace\"][\"identityIndex\"][\"toolOccurrenceIds\"][\"ids\"];\n readonly commandIds: InspectionSuccessDocumentFor<\"attempt.trace\">[\"trace\"][\"identityIndex\"][\"commandIds\"];\n };\n}\nexport interface TraceDetailView {\n readonly locator: string;\n readonly kind: \"item\" | \"tool-occurrence\" | \"command\";\n readonly stableId: string;\n readonly body: InspectionTraceDetailResult;\n}\nexport type TimingView = {\n readonly locator: string;\n} & InspectionSuccessDocumentFor<\"attempt.timing\">[\"timing\"];\nexport type UsageView = {\n readonly locator: string;\n} & InspectionSuccessDocumentFor<\"attempt.usage\">[\"usage\"];\nexport type DiffView = {\n readonly locator: string;\n} & InspectionSuccessDocumentFor<\"attempt.diff\">[\"diff\"];\nconst metric = (value: {\n readonly state: MetricState;\n readonly value: number | null;\n}): Metric => ({ state: value.state, value: value.value });\nconst aggregate = (value: InspectionOverviewResult[\"totals\"]): Aggregate => ({\n expected: value.denominator.expected,\n observed: value.denominator.observed,\n passed: value.verdict.tally.passed,\n failed: value.verdict.tally.failed,\n errored: value.verdict.tally.errored,\n skipped: value.verdict.tally.skipped,\n passRate: metric(value.verdict.passRate),\n score: metric(value.score),\n durationMs: metric(value.durationMs),\n tokens: metric(value.tokens),\n});\nconst cells = (values: InspectionOverviewResult[\"cells\"]): OverviewView[\"cells\"] => values.map((cell) => ({\n experimentId: cell.experimentId,\n evalId: cell.evalId,\n aggregate: aggregate(cell),\n members: cell.members.map((member) => ({\n publication: member.publication.state === \"published\"\n ? {\n ...member.publication,\n score: metric(member.publication.score),\n durationMs: metric(member.publication.durationMs),\n tokens: metric(member.publication.tokens),\n }\n : member.publication,\n })),\n}));\nexport function projectOverview(document: InspectionSuccessDocumentFor<\"overview.get\">): OverviewView {\n return {\n totals: aggregate(document.overview.totals),\n experiments: document.overview.experiments.map((experiment) => ({\n experimentId: experiment.experimentId,\n agent: experiment.agent,\n model: experiment.model,\n aggregate: aggregate(experiment),\n })),\n cells: cells(document.overview.cells),\n };\n}\nexport function projectExperiment(document: InspectionSuccessDocumentFor<\"experiment.get\">): ExperimentView {\n return {\n experimentId: document.experiment.experiment.experimentId,\n aggregate: aggregate(document.experiment.experiment),\n cells: cells(document.experiment.cells),\n };\n}\nexport function projectRun(document: InspectionSuccessDocumentFor<\"run.overview\">): RunView {\n const value = document.runOverview;\n return {\n runId: value.identity.runId,\n experimentId: value.identity.experimentId,\n startedAt: value.startedAt,\n completedAt: value.completedAt,\n expected: value.denominator.expected,\n observed: value.denominator.observed,\n coverage: value.coverage,\n usage: value.usage,\n limitations: value.limitations,\n members: value.members.map((member) => ({\n slotId: member.slot.slotId,\n evalId: member.slot.evalId,\n attemptOrdinal: member.slot.attemptOrdinal,\n locator: member.locator,\n state: member.state,\n relation: member.relation,\n outcome: member.outcome,\n verdict: member.verdict,\n score: member.score,\n coverage: member.coverage,\n usage: member.usage,\n limitations: member.limitations,\n })),\n };\n}\nexport function projectAttempt(document: InspectionSuccessDocumentFor<\"attempt.get\">): AttemptView {\n const value = document.attempt;\n return {\n locator: value.locator,\n verdict: value.verdict,\n attemptId: value.core.attemptId,\n evalId: value.core.evalId,\n slotId: value.core.slotId,\n outcome: value.core.outcome,\n originRunId: value.core.originRunId,\n experimentId: value.originRun.experimentId,\n score: value.score,\n sections: {\n assertions: value.sections.assertions.state,\n sources: value.sections.sources.state,\n trace: value.sections.trace.state,\n timing: value.sections.timing.state,\n usage: value.sections.usage.state,\n diff: value.sections.diff.state,\n },\n assertions: {\n state: value.assertions.state,\n entries: value.assertions.entries.map((entry) => ({ entryId: entry.entryId, ...entry.display })),\n },\n evidenceCoverage: value.evidenceCoverage.map((entry) => JSON.stringify(entry)),\n limitations: value.limitations.map((entry) => JSON.stringify(entry)),\n };\n}\nexport function projectSources(document: InspectionSuccessDocumentFor<\"attempt.sources\">, locator: string): SourcesView {\n const value = document.sources;\n return {\n locator,\n state: value.state,\n items: value.items.map((item) => ({ path: item.path, sourceItemId: item.sourceItemId, byteLength: item.byteLength, content: item.content })),\n assertions: {\n state: value.assertions.state,\n sites: value.assertions.sourceSites.map((site) => ({\n entryId: site.entryId,\n role: site.role,\n start: site.start,\n end: site.end,\n source: site.source,\n })),\n hasMoreSourceSites: value.assertions.hasMoreSourceSites,\n omittedSourceSiteCount: value.assertions.omittedSourceSiteCount,\n },\n hasMore: value.hasMore,\n omittedItemCount: value.omittedItemCount,\n };\n}\nexport function projectTrace(document: InspectionSuccessDocumentFor<\"attempt.trace\">, locator: string): TraceView {\n const value = document.trace;\n return {\n locator,\n conversation: {\n state: value.conversation.state,\n limitations: value.conversation.limitations,\n limitationsTruncated: value.conversation.limitationsTruncated,\n omittedLimitationCount: value.conversation.omittedLimitationCount,\n turnsTruncated: value.conversation.turnsTruncated,\n omittedTurnCount: value.conversation.omittedTurnCount,\n itemCount: value.conversation.items.length,\n itemsTruncated: value.conversation.itemsTruncated,\n omittedItemCount: value.conversation.omittedItemCount,\n turns: value.conversation.turns.map((turn) => ({\n ...turn,\n items: value.conversation.items.filter((item) => item.turnId === turn.turnId).map(({ turnId: _turnId, ...item }) => item),\n })),\n },\n commands: {\n state: value.commands.state,\n limitations: value.commands.limitations,\n limitationsTruncated: value.commands.limitationsTruncated,\n omittedLimitationCount: value.commands.omittedLimitationCount,\n hasMore: value.commands.hasMore,\n omittedCommandCount: value.commands.omittedCommandCount,\n items: value.commands.items.map((command) => ({ commandId: command.commandId, phase: command.phase, outcome: command.outcome.kind })),\n },\n diagnostics: value.diagnostics,\n identities: {\n itemIds: value.identityIndex.itemIds,\n toolOccurrenceIds: value.identityIndex.toolOccurrenceIds.ids,\n commandIds: value.identityIndex.commandIds,\n },\n };\n}\nexport function projectTraceDetail(document: InspectionSuccessDocumentFor<\"attempt.trace.detail\">, locator: string): TraceDetailView {\n const body = document.detail;\n return {\n locator,\n kind: body.kind,\n stableId: body.kind === \"item\" ? body.itemId : body.kind === \"tool-occurrence\" ? body.toolOccurrenceId : body.commandId,\n body,\n };\n}\nexport function projectTiming(document: InspectionSuccessDocumentFor<\"attempt.timing\">, locator: string): TimingView {\n return { locator, ...document.timing };\n}\nexport function projectUsage(document: InspectionSuccessDocumentFor<\"attempt.usage\">, locator: string): UsageView {\n return { locator, ...document.usage };\n}\nexport function projectDiff(document: InspectionSuccessDocumentFor<\"attempt.diff\">, locator: string): DiffView {\n return { locator, ...document.diff };\n}\n"]}
1
+ {"version":3,"file":"model.js","sourceRoot":"","sources":["model.ts"],"names":[],"mappings":";;AA4QA,0CAWC;AACD,8CAMC;AACD,gCA2BC;AACD,wCA2BC;AACD,wCAqBC;AACD,oCAmCC;AACD,gDAQC;AACD,sCAEC;AACD,oCAEC;AACD,kCAEC;AAtLD,MAAM,MAAM,GAAG,CAAC,KAGf,EAAU,EAAE,CAAC,CAAC,EAAE,KAAK,EAAE,KAAK,CAAC,KAAK,EAAE,KAAK,EAAE,KAAK,CAAC,KAAK,EAAE,CAAC,CAAC;AAC3D,MAAM,SAAS,GAAG,CAAC,KAAyC,EAAa,EAAE,CAAC,CAAC;IACzE,cAAc,EAAE,KAAK,CAAC,cAAc;IACpC,QAAQ,EAAE,KAAK,CAAC,WAAW,CAAC,QAAQ;IACpC,QAAQ,EAAE,KAAK,CAAC,WAAW,CAAC,QAAQ;IACpC,MAAM,EAAE,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,MAAM;IAClC,MAAM,EAAE,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,MAAM;IAClC,OAAO,EAAE,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,OAAO;IACpC,OAAO,EAAE,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,OAAO;IACpC,QAAQ,EAAE,MAAM,CAAC,KAAK,CAAC,OAAO,CAAC,QAAQ,CAAC;IACxC,KAAK,EAAE,MAAM,CAAC,KAAK,CAAC,KAAK,CAAC;IAC1B,UAAU,EAAE,MAAM,CAAC,KAAK,CAAC,UAAU,CAAC;IACpC,MAAM,EAAE,MAAM,CAAC,KAAK,CAAC,MAAM,CAAC;CAC/B,CAAC,CAAC;AACH,MAAM,KAAK,GAAG,CAAC,MAAyC,EAAyB,EAAE,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,CAAC;IACtG,YAAY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IAAI,EAAE,CAAC;AACzC,CAAC","sourcesContent":["import type { InspectionOverviewResult, InspectionScoredValue, InspectionSuccessDocumentFor, InspectionTraceDetailResult, } from \"../inspection/index.ts\";\nimport type { AttemptOutcome as RecordAttemptOutcome, MembershipAction as RecordMembershipAction } from \"../record/model/core.ts\";\nimport type { Verdict as PublicVerdict } from \"../shared/types.ts\";\nimport type { AgentTurnOutcome as ReceiptAgentTurnOutcome, SANDBOX_COMMAND_PHASES } from \"../record/family/protocol-values.ts\";\nexport type MetricState = \"available\" | \"partial\" | \"unavailable\" | \"empty\" | \"unsupported\" | \"failed\";\nexport type Verdict = PublicVerdict;\nexport type MembershipAction = RecordMembershipAction;\nexport type AttemptOutcome = RecordAttemptOutcome;\nexport type AgentTurnOutcome = ReceiptAgentTurnOutcome;\nexport type SectionState = \"available\" | \"not-recorded\" | \"partial\" | \"unavailable\";\nexport type ProjectionState = \"complete\" | \"partial\" | \"not-recorded\" | \"invalid\";\nexport type SourceState = \"available\" | \"not-recorded\" | \"invalid\";\nexport type ScoredValue = InspectionScoredValue;\nexport type SourceContent = {\n readonly state: \"available\";\n readonly text: string;\n} | {\n readonly state: \"omitted\";\n readonly reason: \"inspection-result-byte-limit\";\n readonly byteLength: number;\n readonly byteLimit: number;\n};\nexport type AssertionSource = {\n readonly state: \"mapped\";\n readonly sourceItemId: string;\n readonly sha256: string;\n} | {\n readonly state: \"unmapped\";\n readonly reason: \"source-snapshot-not-recorded\" | \"position-unrepresentable\";\n};\nexport type CommandPhase = (typeof SANDBOX_COMMAND_PHASES)[number];\nexport type CommandOutcome = \"exited\" | \"terminated\" | \"not-started\";\nexport type Metric = {\n readonly state: MetricState;\n readonly value: number | null;\n};\nexport type ExecutionValue = {\n readonly state: \"available\";\n readonly value: string;\n} | {\n readonly state: \"mixed\";\n} | {\n readonly state: \"unavailable\";\n};\nexport type Aggregate = {\n readonly evaluationKind: \"pass\" | \"points\" | \"mixed\";\n readonly expected: number;\n readonly observed: number;\n readonly passed: number;\n readonly failed: number;\n readonly errored: number;\n readonly skipped: number;\n readonly passRate: Metric;\n readonly score: Metric;\n readonly durationMs: Metric;\n readonly tokens: Metric;\n};\nexport interface OverviewView {\n readonly totals: Aggregate;\n readonly experiments: readonly {\n readonly experimentId: string;\n readonly agent: ExecutionValue;\n readonly model: ExecutionValue;\n readonly aggregate: Aggregate;\n }[];\n readonly cells: readonly {\n readonly experimentId: string;\n readonly evalId: string;\n readonly aggregate: Aggregate;\n readonly members: readonly {\n readonly publication: {\n readonly state: \"pending\";\n } | {\n readonly state: \"absent\";\n readonly reason: string;\n } | {\n readonly state: \"published\";\n readonly action: MembershipAction;\n readonly attemptId: string;\n readonly attemptLocator: string;\n readonly originRunId: string;\n readonly originSlotId: string;\n readonly verdict: Verdict | null;\n readonly score: Metric;\n readonly durationMs: Metric;\n readonly tokens: Metric;\n };\n }[];\n }[];\n}\nexport interface ExperimentView {\n readonly experimentId: string;\n readonly aggregate: Aggregate;\n readonly cells: OverviewView[\"cells\"];\n}\nexport interface RunView {\n readonly runId: string;\n readonly experimentId: string;\n readonly startedAt: number;\n readonly completedAt: number;\n readonly expected: number;\n readonly observed: number;\n readonly coverage: InspectionSuccessDocumentFor<\"run.overview\">[\"runOverview\"][\"coverage\"];\n readonly usage: InspectionSuccessDocumentFor<\"run.overview\">[\"runOverview\"][\"usage\"];\n readonly limitations: InspectionSuccessDocumentFor<\"run.overview\">[\"runOverview\"][\"limitations\"];\n readonly members: readonly {\n readonly slotId: string;\n readonly evalId: string;\n readonly attemptOrdinal: number;\n readonly locator: string | null;\n readonly state: MembershipAction | \"missing\";\n readonly relation: \"origin\" | \"reference\" | null;\n readonly outcome: AttemptOutcome | null;\n readonly verdict: Verdict | null;\n readonly score: ScoredValue | null;\n readonly coverage: InspectionSuccessDocumentFor<\"run.overview\">[\"runOverview\"][\"members\"][number][\"coverage\"];\n readonly usage: InspectionSuccessDocumentFor<\"run.overview\">[\"runOverview\"][\"members\"][number][\"usage\"];\n readonly limitations: InspectionSuccessDocumentFor<\"run.overview\">[\"runOverview\"][\"members\"][number][\"limitations\"];\n }[];\n}\nexport interface AttemptView {\n readonly locator: string;\n readonly verdict: Verdict | null;\n readonly attemptId: string;\n readonly evalId: string;\n readonly slotId: string;\n readonly outcome: AttemptOutcome;\n readonly originRunId: string;\n readonly experimentId: string;\n readonly score: ScoredValue;\n readonly sections: {\n readonly assertions: SectionState;\n readonly sources: SectionState;\n readonly trace: SectionState;\n readonly timing: SectionState;\n readonly usage: SectionState;\n readonly diff: SectionState;\n };\n readonly assertions: {\n readonly state: SourceState;\n readonly entries: readonly {\n readonly entryId: string;\n readonly label?: string;\n readonly key?: string;\n readonly groupPath: readonly string[];\n }[];\n };\n readonly evidenceCoverage: readonly string[];\n readonly limitations: readonly string[];\n}\nexport interface SourcesView {\n readonly locator: string;\n readonly state: SourceState;\n readonly items: readonly {\n readonly path: string;\n readonly sourceItemId: string;\n readonly byteLength: number;\n readonly content: SourceContent;\n }[];\n readonly assertions: {\n readonly state: SourceState;\n readonly sites: readonly {\n readonly entryId: string;\n readonly role: \"declaration\" | \"threshold\" | \"score\" | \"gate\" | \"optional\" | \"stop\";\n readonly start: {\n readonly line: number;\n readonly column: number;\n };\n readonly end: {\n readonly line: number;\n readonly column: number;\n };\n readonly source: AssertionSource;\n }[];\n readonly hasMoreSourceSites: boolean;\n readonly omittedSourceSiteCount: number;\n };\n readonly hasMore: boolean;\n readonly omittedItemCount: number;\n}\ntype WithoutTurnId<Value> = Value extends unknown ? Omit<Value, \"turnId\"> : never;\nexport type TraceItem = WithoutTurnId<InspectionSuccessDocumentFor<\"attempt.trace\">[\"trace\"][\"conversation\"][\"items\"][number]>;\nexport interface TraceView {\n readonly locator: string;\n readonly conversation: {\n readonly state: ProjectionState;\n readonly limitations: InspectionSuccessDocumentFor<\"attempt.trace\">[\"trace\"][\"conversation\"][\"limitations\"];\n readonly limitationsTruncated: boolean;\n readonly omittedLimitationCount: number;\n readonly turnsTruncated: boolean;\n readonly omittedTurnCount: number;\n readonly itemCount: number;\n readonly itemsTruncated: boolean;\n readonly omittedItemCount: number;\n readonly turns: readonly {\n readonly turnId: string;\n readonly sequence: number;\n readonly outcome: AgentTurnOutcome;\n readonly items: readonly TraceItem[];\n }[];\n };\n readonly commands: {\n readonly state: ProjectionState;\n readonly limitations: InspectionSuccessDocumentFor<\"attempt.trace\">[\"trace\"][\"commands\"][\"limitations\"];\n readonly limitationsTruncated: boolean;\n readonly omittedLimitationCount: number;\n readonly hasMore: boolean;\n readonly omittedCommandCount: number;\n readonly items: readonly {\n readonly commandId: InspectionSuccessDocumentFor<\"attempt.trace\">[\"trace\"][\"commands\"][\"items\"][number][\"commandId\"];\n readonly phase: CommandPhase;\n readonly outcome: CommandOutcome;\n }[];\n };\n readonly diagnostics: InspectionSuccessDocumentFor<\"attempt.trace\">[\"trace\"][\"diagnostics\"];\n readonly identities: {\n readonly itemIds: InspectionSuccessDocumentFor<\"attempt.trace\">[\"trace\"][\"identityIndex\"][\"itemIds\"];\n readonly toolOccurrenceIds: InspectionSuccessDocumentFor<\"attempt.trace\">[\"trace\"][\"identityIndex\"][\"toolOccurrenceIds\"][\"ids\"];\n readonly commandIds: InspectionSuccessDocumentFor<\"attempt.trace\">[\"trace\"][\"identityIndex\"][\"commandIds\"];\n };\n}\nexport interface TraceDetailView {\n readonly locator: string;\n readonly kind: \"item\" | \"tool-occurrence\" | \"command\";\n readonly stableId: string;\n readonly body: InspectionTraceDetailResult;\n}\nexport type TimingView = {\n readonly locator: string;\n} & InspectionSuccessDocumentFor<\"attempt.timing\">[\"timing\"];\nexport type UsageView = {\n readonly locator: string;\n} & InspectionSuccessDocumentFor<\"attempt.usage\">[\"usage\"];\nexport type DiffView = {\n readonly locator: string;\n} & InspectionSuccessDocumentFor<\"attempt.diff\">[\"diff\"];\nconst metric = (value: {\n readonly state: MetricState;\n readonly value: number | null;\n}): Metric => ({ state: value.state, value: value.value });\nconst aggregate = (value: InspectionOverviewResult[\"totals\"]): Aggregate => ({\n evaluationKind: value.evaluationKind,\n expected: value.denominator.expected,\n observed: value.denominator.observed,\n passed: value.verdict.tally.passed,\n failed: value.verdict.tally.failed,\n errored: value.verdict.tally.errored,\n skipped: value.verdict.tally.skipped,\n passRate: metric(value.verdict.passRate),\n score: metric(value.score),\n durationMs: metric(value.durationMs),\n tokens: metric(value.tokens),\n});\nconst cells = (values: InspectionOverviewResult[\"cells\"]): OverviewView[\"cells\"] => values.map((cell) => ({\n experimentId: cell.experimentId,\n evalId: cell.evalId,\n aggregate: aggregate(cell),\n members: cell.members.map((member) => ({\n publication: member.publication.state === \"published\"\n ? {\n ...member.publication,\n score: metric(member.publication.score),\n durationMs: metric(member.publication.durationMs),\n tokens: metric(member.publication.tokens),\n }\n : member.publication,\n })),\n}));\nexport function projectOverview(document: InspectionSuccessDocumentFor<\"overview.get\">): OverviewView {\n return {\n totals: aggregate(document.overview.totals),\n experiments: document.overview.experiments.map((experiment) => ({\n experimentId: experiment.experimentId,\n agent: experiment.agent,\n model: experiment.model,\n aggregate: aggregate(experiment),\n })),\n cells: cells(document.overview.cells),\n };\n}\nexport function projectExperiment(document: InspectionSuccessDocumentFor<\"experiment.get\">): ExperimentView {\n return {\n experimentId: document.experiment.experiment.experimentId,\n aggregate: aggregate(document.experiment.experiment),\n cells: cells(document.experiment.cells),\n };\n}\nexport function projectRun(document: InspectionSuccessDocumentFor<\"run.overview\">): RunView {\n const value = document.runOverview;\n return {\n runId: value.identity.runId,\n experimentId: value.identity.experimentId,\n startedAt: value.startedAt,\n completedAt: value.completedAt,\n expected: value.denominator.expected,\n observed: value.denominator.observed,\n coverage: value.coverage,\n usage: value.usage,\n limitations: value.limitations,\n members: value.members.map((member) => ({\n slotId: member.slot.slotId,\n evalId: member.slot.evalId,\n attemptOrdinal: member.slot.attemptOrdinal,\n locator: member.locator,\n state: member.state,\n relation: member.relation,\n outcome: member.outcome,\n verdict: member.verdict,\n score: member.score,\n coverage: member.coverage,\n usage: member.usage,\n limitations: member.limitations,\n })),\n };\n}\nexport function projectAttempt(document: InspectionSuccessDocumentFor<\"attempt.get\">): AttemptView {\n const value = document.attempt;\n return {\n locator: value.locator,\n verdict: value.verdict,\n attemptId: value.core.attemptId,\n evalId: value.core.evalId,\n slotId: value.core.slotId,\n outcome: value.core.outcome,\n originRunId: value.core.originRunId,\n experimentId: value.originRun.experimentId,\n score: value.score,\n sections: {\n assertions: value.sections.assertions.state,\n sources: value.sections.sources.state,\n trace: value.sections.trace.state,\n timing: value.sections.timing.state,\n usage: value.sections.usage.state,\n diff: value.sections.diff.state,\n },\n assertions: {\n state: value.assertions.state,\n entries: value.assertions.entries.map((entry) => ({ entryId: entry.entryId, ...entry.display })),\n },\n evidenceCoverage: value.evidenceCoverage.map((entry) => JSON.stringify(entry)),\n limitations: value.limitations.map((entry) => JSON.stringify(entry)),\n };\n}\nexport function projectSources(document: InspectionSuccessDocumentFor<\"attempt.sources\">, locator: string): SourcesView {\n const value = document.sources;\n return {\n locator,\n state: value.state,\n items: value.items.map((item) => ({ path: item.path, sourceItemId: item.sourceItemId, byteLength: item.byteLength, content: item.content })),\n assertions: {\n state: value.assertions.state,\n sites: value.assertions.sourceSites.map((site) => ({\n entryId: site.entryId,\n role: site.role,\n start: site.start,\n end: site.end,\n source: site.source,\n })),\n hasMoreSourceSites: value.assertions.hasMoreSourceSites,\n omittedSourceSiteCount: value.assertions.omittedSourceSiteCount,\n },\n hasMore: value.hasMore,\n omittedItemCount: value.omittedItemCount,\n };\n}\nexport function projectTrace(document: InspectionSuccessDocumentFor<\"attempt.trace\">, locator: string): TraceView {\n const value = document.trace;\n return {\n locator,\n conversation: {\n state: value.conversation.state,\n limitations: value.conversation.limitations,\n limitationsTruncated: value.conversation.limitationsTruncated,\n omittedLimitationCount: value.conversation.omittedLimitationCount,\n turnsTruncated: value.conversation.turnsTruncated,\n omittedTurnCount: value.conversation.omittedTurnCount,\n itemCount: value.conversation.items.length,\n itemsTruncated: value.conversation.itemsTruncated,\n omittedItemCount: value.conversation.omittedItemCount,\n turns: value.conversation.turns.map((turn) => ({\n ...turn,\n items: value.conversation.items.filter((item) => item.turnId === turn.turnId).map(({ turnId: _turnId, ...item }) => item),\n })),\n },\n commands: {\n state: value.commands.state,\n limitations: value.commands.limitations,\n limitationsTruncated: value.commands.limitationsTruncated,\n omittedLimitationCount: value.commands.omittedLimitationCount,\n hasMore: value.commands.hasMore,\n omittedCommandCount: value.commands.omittedCommandCount,\n items: value.commands.items.map((command) => ({ commandId: command.commandId, phase: command.phase, outcome: command.outcome.kind })),\n },\n diagnostics: value.diagnostics,\n identities: {\n itemIds: value.identityIndex.itemIds,\n toolOccurrenceIds: value.identityIndex.toolOccurrenceIds.ids,\n commandIds: value.identityIndex.commandIds,\n },\n };\n}\nexport function projectTraceDetail(document: InspectionSuccessDocumentFor<\"attempt.trace.detail\">, locator: string): TraceDetailView {\n const body = document.detail;\n return {\n locator,\n kind: body.kind,\n stableId: body.kind === \"item\" ? body.itemId : body.kind === \"tool-occurrence\" ? body.toolOccurrenceId : body.commandId,\n body,\n };\n}\nexport function projectTiming(document: InspectionSuccessDocumentFor<\"attempt.timing\">, locator: string): TimingView {\n return { locator, ...document.timing };\n}\nexport function projectUsage(document: InspectionSuccessDocumentFor<\"attempt.usage\">, locator: string): UsageView {\n return { locator, ...document.usage };\n}\nexport function projectDiff(document: InspectionSuccessDocumentFor<\"attempt.diff\">, locator: string): DiffView {\n return { locator, ...document.diff };\n}\n"]}
@@ -43,6 +43,7 @@ export type ExecutionValue = {
43
43
  readonly state: "unavailable";
44
44
  };
45
45
  export type Aggregate = {
46
+ readonly evaluationKind: "pass" | "points" | "mixed";
46
47
  readonly expected: number;
47
48
  readonly observed: number;
48
49
  readonly passed: number;
@@ -79,6 +80,7 @@ export interface OverviewView {
79
80
  readonly attemptLocator: string;
80
81
  readonly originRunId: string;
81
82
  readonly originSlotId: string;
83
+ readonly verdict: Verdict | null;
82
84
  readonly score: Metric;
83
85
  readonly durationMs: Metric;
84
86
  readonly tokens: Metric;
@@ -43,6 +43,7 @@ export type ExecutionValue = {
43
43
  readonly state: "unavailable";
44
44
  };
45
45
  export type Aggregate = {
46
+ readonly evaluationKind: "pass" | "points" | "mixed";
46
47
  readonly expected: number;
47
48
  readonly observed: number;
48
49
  readonly passed: number;
@@ -79,6 +80,7 @@ export interface OverviewView {
79
80
  readonly attemptLocator: string;
80
81
  readonly originRunId: string;
81
82
  readonly originSlotId: string;
83
+ readonly verdict: Verdict | null;
82
84
  readonly score: Metric;
83
85
  readonly durationMs: Metric;
84
86
  readonly tokens: Metric;
@@ -43,6 +43,7 @@ export type ExecutionValue = {
43
43
  readonly state: "unavailable";
44
44
  };
45
45
  export type Aggregate = {
46
+ readonly evaluationKind: "pass" | "points" | "mixed";
46
47
  readonly expected: number;
47
48
  readonly observed: number;
48
49
  readonly passed: number;
@@ -79,6 +80,7 @@ export interface OverviewView {
79
80
  readonly attemptLocator: string;
80
81
  readonly originRunId: string;
81
82
  readonly originSlotId: string;
83
+ readonly verdict: Verdict | null;
82
84
  readonly score: Metric;
83
85
  readonly durationMs: Metric;
84
86
  readonly tokens: Metric;