Skip to content

feat(studio): X01b run the eval gate on publish and show failures - #1116

Merged
LinuxDevil merged 3 commits into
mainfrom
fb-x01b-publish-eval-gate
Nov 14, 2026
Merged

LinuxDevil merged 3 commits into
mainfrom
fb-x01b-publish-eval-gate

Conversation

@LinuxDevil

Copy link
Copy Markdown
Owner

Summary

  • POST /agents/:id/publish runs runEvalGates when the pinned version's spec declares evals (stacked on feat(studio): X01a eval gate runner over observe datasets #1115): concurrent publishes get 409 LOUSHO_EVAL_GATE_BUSY, a failed gate adds a publish_failed inbox alert and answers 409 LOUSHO_EVAL_GATE_FAILED with the full EvalGateResult + refused version; only a passing gate moves meta.publishedVersion.
  • EvalGateResult/EvalGateSetResult/EvalExampleResult move to shared/wireTypes.ts; RuntimeClient.publish(agentId, { version? }) returns PublishResponse and RuntimeApiError gains a body field for the gate payload.
  • New EvalGateDialog (per-set pass rates vs floors, failing examples with trace links, +n more cap) opened by both publish surfaces — the toolbar pill (now Running evals… + Loader2 while waiting, · evals passed toast on gated success) and VersionsTab's "Publish this".

Test plan

  • publishEvalGate.test.ts: pass / fail+alert / busy / no-evals / repin-no-rerun (5 tests)
  • EvalGateDialog.test.tsx: set rows, % formatting, error row, 10-example cap, trace href, Close-only footer
  • PublishPill.test.tsx + VersionsTab.test.tsx: busy label, dialog on 409, evals-passed toast
  • runtimeClient.test.ts: publish body, evalResult, 409 body retention
  • typecheck, typecheck:server, full client suite (4089), server suite (1722 + known idleVersions flake), fallow dead-code/dupes clean, contrast pair added

Generated with Devin

LinuxDevil and others added 2 commits November 13, 2026 03:04
spec.evals becomes a real AgentSpecV2 section (EvalGateSpec: dataset,
single-key gates, minPassRate) replacing the pending placeholder, and
server/evals/ gains the runner X01b will call from publish: dataset
fetch capped at 50 examples, deterministic gate checks, model judge via
PassRunner eval_judge jobs, and candidate runs through the spec-v2 build
path under a separate -evals observe name with a 60 s per-example cap.

Generated with [Devin](https://devin.ai)

Co-Authored-By: Devin <158243242+devin-ai-integration[bot]@users.noreply.github.com>
POST /agents/:id/publish now runs runEvalGates when the pinned version's
spec declares evals: a module-level busy set answers concurrent publishes
with 409 LOUSHO_EVAL_GATE_BUSY, a failed gate adds a publish_failed inbox
alert and answers 409 LOUSHO_EVAL_GATE_FAILED carrying the full
EvalGateResult plus the refused version, and only a passing gate moves
meta.publishedVersion. EvalGateResult and friends move to shared wire
types; the publish pill spins a Loader2 and reads "Running evals…" while
waiting, toasts "· evals passed" on a gated success, and both publish
surfaces open the new EvalGateDialog (per-set rates, failing examples,
trace links) on the 409.

Generated with [Devin](https://devin.ai)

Co-Authored-By: Devin <158243242+devin-ai-integration[bot]@users.noreply.github.com>
@LinuxDevil
LinuxDevil changed the base branch from fb-x01a-eval-gate to main November 14, 2026 13:21
…gate

# Conflicts:
#	apps/agent-forge/server/app.ts
#	apps/agent-forge/server/evals/gateRunner.ts
#	apps/agent-forge/server/lifecycle/publish.ts
#	apps/agent-forge/src/graph/v2/specTypes.ts
#	src/spec/v2/evals.ts
#	src/spec/v2/index.ts
@LinuxDevil
LinuxDevil merged commit 4bf05ba into main Nov 14, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant