Concept Mill bench fixes: positive frame only, committed screen grades, one threshold owner, GPU freed on failure, provenance labels
Some checks were skipped
Deploy Quartz / build (push) Has been skipped
Deploy Quartz / deploy-1 (push) Has been skipped
Deploy Quartz / deploy (push) Has been skipped

Frame is `standard` only; the negated r3 frame lives in the frozen r3 recipe. Screen checks are committed (screens/<bench>/<round>.json) and graded from the guideline's thresholds block; build fails without them. The re-screen skip keys on the model digest. A failed render or caption run ends with a freeing call. The Mill labels the prompt as typed and links the final caption; r3 records say they reproduce the original render and give its time. Rule 10's bench evidence moves to the bench file; carbon-jewel and plan-view stop naming hypercar as the subject.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
Meta Vens 2026-11-27 20:40:55 +01:00
commit cf23d895ec
90 changed files with 1908 additions and 301 deletions

View file

@ -20,7 +20,7 @@
import fs from "node:fs/promises"
import path from "node:path"
import { fileURLToPath } from "node:url"
import { GRADE_RANK, benchNames, imageBase, loadBench, loadRecipe, recipeFiles, repoRoot, rubric, sharp, yaml } from "./bench.mjs"
import { GRADE_RANK, benchNames, gradeOf, loadBench, loadRecipe, loadScreens, imageBase, recipeFiles, repoRoot, rubric, sharp, yaml } from "./bench.mjs"
const here = path.dirname(fileURLToPath(import.meta.url))
@ -152,18 +152,21 @@ function benchRecord(bench, group, item, recipe, image, run, screen) {
`Item: ${item.id} · ${item.name}${item.bet ? ` · ${item.bet}` : ""}`,
`Group note: ${group.note}`,
"",
"## Text sent to the upsampler",
"## Prompt as typed (the upsampler's input, before it rewrote it)",
"",
image.text,
"",
"## Final caption",
"",
"The exact text the image model's encoder received.",
"The exact text the image model's encoder received, written by the upsampler from the prompt above.",
"",
run.caption,
"",
"## Generation",
"",
...(recipe.reproduces
? [`Reproduction: ${recipe.reproduces}. The original render was made ${image.original_utc ?? "at an unrecorded time"}; this copy was made ${run.utc}.`, ""]
: []),
`Model ${run.models?.["1"]} · upsampler ${run.models?.["10"] ?? "off"} · seed ${run.seed} · ${run.size} · ${run.steps} steps · cfg ${run.cfg} · ${run.sampler}/${run.scheduler} · raven-image ${String(run.client_sha256).slice(0, 12)}, graph ${String(run.graph_sha256).slice(0, 12)} · ${run.utc}`,
]
if (screen) {
@ -178,7 +181,7 @@ const rank = (v) => GRADE_RANK[v.screen?.grade ?? "doubt"]
const benchRows = []
let staleScreens = 0
try {
const currentRubric = rubric().sha
const { sha: currentRubric, thresholds } = rubric()
for (const name of benchNames()) {
const bench = loadBench(name)
const recipes = recipeFiles(name).map(loadRecipe)
@ -189,6 +192,7 @@ try {
if (shipIds.has(rowId)) fail(`bench row id ${rowId} collides with a ship id`)
const variants = []
for (const recipe of recipes) {
const screens = loadScreens(recipe)
const roundId = recipe.round.replace(/^\d{4}-\d{2}-\d{2}-/, "")
for (const image of recipe.images.filter((i) => i.item === itemId).sort((a, b) => a.k - b.k)) {
const stem = imageBase(recipe, rendersRoot, image)
@ -197,8 +201,11 @@ try {
if ((await exists(`${stem}.png`)) !== (await exists(`${stem}.json`))) fail(`${image.id}: the render and its .json record must both exist`)
if (!have && !rendered) continue
const mine = bench.images?.[image.id] ?? {}
const model = (await exists(`${stem}.screen.json`)) ? await readJson(`${stem}.screen.json`) : null
if (model && model.rubric_sha256 !== currentRubric) staleScreens++
// The committed screen record is the input: a missing grade stops the build rather than flipping defaults.
const found = screens[image.id]
if (!found) fail(`${image.id}: no committed screen record; run bench.mjs screen ${path.relative(repoRoot, path.join(here, "rounds", name, `${recipe.round}.yaml`))}`)
const model = { ...found, grade: gradeOf(found.checks, thresholds) }
if (model.rubric_sha256 !== currentRubric) staleScreens++
const override = mine.screen_override
if (override && !(override.grade in GRADE_RANK && override.reason)) fail(`${image.id}: screen_override needs a grade and a reason`)
let screen
@ -207,7 +214,7 @@ try {
if (rendered) {
const run = await readJson(`${stem}.json`)
if (!have || force) await derive(image.id, `${stem}.png`)
const record = benchRecord(bench, group, item, recipe, image, run, model && { ...model, override })
const record = benchRecord(bench, group, item, recipe, image, run, { ...model, override })
const target = path.join(promptDir, `${image.id}.txt`)
if (!(await exists(target)) || (await fs.readFile(target, "utf8")) !== record) {
await fs.writeFile(target, record)
@ -223,7 +230,7 @@ try {
prompt: `${mediaUrl}prompts/${image.id}.txt`,
hypothesis: group.note,
promptText: image.text,
generation: `FLUX.3 Klein · seed ${image.seed} · ${recipe.size} · upsampler ${recipe.enhance === false ? "off" : "on"}`,
generation: `FLUX.3 Klein · seed ${image.seed} · ${recipe.size} · upsampler ${recipe.enhance === false ? "off" : "on"}${recipe.reproduces ? ` · reproduces the render of ${image.original_utc ?? "an unrecorded time"}` : ""}`,
operator: mine.operator,
pick: Boolean(mine.pick),
screen,