Skip to content

armgit / 67.js

Public Imported from GitHub
0

3D engine that AI agents drive

Measure the default look on a cold run and lower the default exposure to 0.8

Nguyen Xuan Anc6555ce75762
diff --git a/CHANGELOG.md b/CHANGELOG.md
index fe88feb7..4c8816da 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -2,6 +2,8 @@
## Unreleased
+- Measure the default look on a cold agent run and lower the default exposure (part of issue #53; the done condition stays open, see below). Breaking look change: a recipe that sets no `effects.exposure` now renders at `0.8` instead of `1` (one constant, `DEFAULT_EXPOSURE`); a recipe that sets it, and the 12 `npm run reference` scenes, which set exposure 1 themselves, are unchanged. Every other default is unchanged: setup `daylight`, `effects.ambientOcclusion` 0, bloom strength 0.12, no depth of field, no bake, no ground, and the same camera and shadow rules. The suite's look harness drew every recipe without the setup's environment map, so its images were darker than what the MCP preview shows an agent; it now draws with the map, `regrade.mjs` finds files of runs made with `--runs`, and the judge ran on the new images. Measured on Haiku, 6 tasks, one run each, no skill, judged by a Sonnet vision judge: agents set no environment, effects, shadow or bake in any run and only a camera in 4 of 6; the judge scored 66 of 72 before and 66 of 72 after, so no lift is shown (see `bench/agent-modeling/README.md`). Not built: a default ground with a contact shadow (a floor in every recipe would change recipes that draw their own) and an automatic bake.
+
- Fix the recipe light bake budget, which rejected the demo room at samples 96, bounces 2, texelsPerUnit 3 (11.5 s before the budget) and scaled `standard` there to 16 samples (part of issue #55). The ray work estimate multiplied by every light and so overcounted open scenes by about 4 times. The budget now counts path steps (texels x samples x bounces), which cost about the same per path in a closed 56 part room and in the demo room. A preset scales down to 5 million path steps (the demo room at `standard` keeps about 52 samples, not 16); explicit settings are limited only by a hard bound of 24 million path steps and by the real 20 s limit, which fails the edit with the scene unchanged and names a lower samples and texelsPerUnit to try. A bake on a worker has 90 s instead of 20 s (the page's own thread keeps 20 s), and the preview's 30 s call deadline grows by 90 s for a `scene_create` with a `bake` and a `scene_apply` with `set-bake`. `bake.used` and `bake.reduced` are unchanged; the capability limit `maxRayWork` is now `maxPathWork`.
- Make room in the npm package without adding a dependency (part of issue #36). The archive fell from 802,581 to 695,041 bytes (353,535 free under 1 MiB; the target was 300,000), and every library and MCP install stays as light as before. Two causes: (1) every one of the 80 built files began with the full `LICENSE` and `THIRD-PARTY-NOTICES.md` text, about 4 KB each; they now carry a one-line notice and the complete texts stay once at the package root, about 61,000 bytes saved; (2) the MCP SDK's Node shim pulls in Ajv (the validator for elicitation answers, about 270 KB before minification) that this server never uses, so `build/mcp/server.mjs` now bundles `scripts/mcp-sdk-shims.mjs` instead, which fails with a clear message if elicitation is ever requested: `server.mjs` fell from 677,484 to 484,111 bytes and the archive by about 47,000 bytes. `build/mcp/LICENSES.md` no longer lists the Ajv family because that code is gone, and its unused copies left `licenses/mcp/`. Measured, and not worth doing: `zod/mini` (zod's classic layer is 30 KB of the server before gzip), source maps (none are shipped), standalone core copies (none in the archive), and docs (every packaged page is linked from the README, `llms.txt`, the MCP guide or the skills). `npm run smoke:package` now loads every `exports` entry in a clean consumer. Film and site code were already outside the archive. Separate lazy-loaded packages were not built: the lazy addons together are about 157 KB gzip, so splitting them out could return at most that much, for the cost of a package, a release pipeline and a version matrix each. `archiveBytes` budget 815,000 to 705,500. Module load of the server is no slower (minimum of 25 runs, 217 and 188 ms against 231 and 209 ms).
diff --git a/bench/agent-modeling/README.md b/bench/agent-modeling/README.md
index 6bf20d09..11285c25 100644
--- a/bench/agent-modeling/README.md
+++ b/bench/agent-modeling/README.md
@@ -187,6 +187,25 @@ What this does and does not show:
The suite now finds tool friction and tracks cost, but does not measure how good an object looks. Tasks with free form,
such as organic shapes or a look to match, would need a score for appearance before they could test more.
+## Default look on a cold run (2026-11-01, issue #53)
+
+`results/2026-11-01-01-25-haiku-look-before.json` and `results/2026-11-01-01-36-haiku-look-after.json`: Haiku, six tasks, one run each, no skill, judged by a Sonnet vision judge (`sonnet-vision`, 0 to 12, against references drawn under the same defaults). The only engine change between them is the default `effects.exposure`, 1 to 0.8. The look harness was also fixed first: it drew without the setup's environment map, so its images were darker than the MCP preview. Both runs were drawn with the fix.
+
+| Task | Judge before | Judge after | Silhouette before | Silhouette after |
+| --- | --- | --- | --- | --- |
+| crate | 12 | 10 | 1 | 1 |
+| mug | 10 | 11 | 0.7927 | 0.934 |
+| table | 11 | 10 | 0.5919 | 0.5784 |
+| soap | 12 | 12 | 1 | 1 |
+| chair | 12 | 12 | 1 | 1 |
+| gear | 9 | 11 | 0.9475 | 0.9724 |
+| Total | 66 | 66 | | |
+
+- **No lift shown.** The totals tie, and each task moved by one or two points either way, which is judge and agent noise at one run. The done condition of #53 (a cold recipe scoring above the current default) is not met by this measure.
+- **The judge cannot see a default change.** It scores shape and features against a reference drawn under the same defaults, and agents never set lights, environment, effects, shadow or bake (their tool calls set only a camera, in 4 of 6 runs, and `roughness` in one), so both sides always share the look. A look score that separates lighting needs a fixed reference drawn under the old default, or a judge question about shading.
+- **What a reader sees.** The images show an object floating on a flat grey backdrop with no contact shadow, and a pale top face at exposure 1. A default ground with a contact shadow is the larger fix and was not built: a floor in every recipe would change recipes that draw their own.
+- Cost: $0.75 and $0.83 for the agent runs, $0.21, $0.99 and $1.19 for the judge.
+
## Clip layers (2026-10-31)
`robot-walk-wave` asks for a character that walks and waves at once through `motion.layers`. The check `assetWalkAndWave` reloads the exported recipe, plays each layer alone (keeping its own speed, offset and loop) and compares part matrices at two times: the legs must match Walking and move, the right arm must leave Walking, the left arm must keep walking. Cold Sonnet, no skill, `results/2026-10-31-11-40-sonnet-walk-wave-cold-fixed-grader.json`: 1 of 1, 7 tool calls (2 errors), $0.31. A first run, with a check that compared against Walking at speed 1 only, failed on a recipe the agent had correct (it set per-layer speeds); the check was fixed and that recipe grades as a pass. One run is not a rate.
diff --git a/bench/agent-modeling/look-harness.js b/bench/agent-modeling/look-harness.js
index 8f623a51..c2362b3e 100644
--- a/bench/agent-modeling/look-harness.js
+++ b/bench/agent-modeling/look-harness.js
@@ -1,6 +1,6 @@
// Runs in the page: draws a recipe from each fixed camera, the way the MCP preview draws a scene.
import { createAgentScene, loadAllAgentSceneModules, loadMeshBooleans, needsMeshBooleans } from '/src/agent-scene.js';
-import { resolveAgentShadow } from '/src/agent-look.js';
+import { agentEnvironmentMap, resolveAgentShadow } from '/src/agent-look.js';
import { Renderer67 } from '/src/renderer.js';
async function renderLookViews(recipe, views) {
@@ -9,7 +9,8 @@ async function renderLookViews(recipe, views) {
const scene = createAgentScene(recipe);
if (recipe.motion) scene.sampleMotion(0);
const canvas = document.querySelector('canvas');
- const environment = scene.environment;
+ // The MCP preview lights a recipe with the setup's environment map; without it the images would show a darker scene than agents get.
+ const environment = { ...scene.environment, map: agentEnvironmentMap(scene.environment) };
const effects = scene.effects;
const renderer = new Renderer67(canvas, scene.parts, {
ground: false, hdr: true, depth: true, samples: 1, pixelRatio: 1, memoryBudgetMiB: 512,
diff --git a/bench/agent-modeling/regrade.mjs b/bench/agent-modeling/regrade.mjs
index cdcd9c8f..43bd529f 100644
--- a/bench/agent-modeling/regrade.mjs
+++ b/bench/agent-modeling/regrade.mjs
@@ -11,17 +11,24 @@ const [runName] = process.argv.slice(2);
const summaryPath = join(repository, 'bench', 'agent-modeling', 'results', `${runName}.json`);
const summary = JSON.parse(await readFile(summaryPath, 'utf8'));
for (const record of summary.records) {
+ // Runs with --runs name their files <task>-<attempt>; runs before that used the bare task name.
+ const attempt = record.attempt ?? 1;
+ const runDirectory = join(repository, 'artifacts', 'agent-modeling', runName);
let recipe;
- try {
- recipe = JSON.parse(await readFile(join(repository, 'artifacts', 'agent-modeling', runName, `${record.task}.recipe.json`), 'utf8'));
- } catch {
- continue;
+ for (const fileStem of [`${record.task}-${attempt}`, record.task]) {
+ try {
+ recipe = JSON.parse(await readFile(join(runDirectory, `${fileStem}.recipe.json`), 'utf8'));
+ break;
+ } catch {
+ recipe = undefined;
+ }
}
+ if (!recipe) continue;
const grade = await gradeRecipe(taskById(record.task), recipe);
record.features = recipeFeatures(recipe);
// Keep a judge's score when the same recipe is scored again.
const judges = record.look?.judges;
- record.look = await scoreLookSafely(record.task, recipe, { imageDirectory: join(repository, 'artifacts', 'agent-modeling', runName, 'look') });
+ record.look = await scoreLookSafely(record.task, recipe, { imageDirectory: join(runDirectory, 'look', String(attempt)) });
if (judges) record.look.judges = judges;
record.pass = grade.pass;
record.passed = grade.passed;
diff --git a/bench/agent-modeling/results/2026-11-01-01-25-haiku-look-before.json b/bench/agent-modeling/results/2026-11-01-01-25-haiku-look-before.json
new file mode 100644
index 00000000..8db0bd25
--- /dev/null
+++ b/bench/agent-modeling/results/2026-11-01-01-25-haiku-look-before.json
@@ -0,0 +1,469 @@
+{
+ "run": "2026-11-01-01-25-haiku-look-before",
+ "model": "claude-haiku-5-5",
+ "date": "2026-11-01T01:31:39.273Z",
+ "skill": false,
+ "runsPerTask": 1,
+ "passed": 6,
+ "tasks": 6,
+ "toolCalls": 34,
+ "costUsd": 0.75,
+ "byModel": {
+ "claude-haiku-5-5": {
+ "runs": 6,
+ "passed": 6,
+ "successRate": 1,
+ "toolCalls": 34,
+ "toolErrors": 0,
+ "inputTokens": 3908046,
+ "outputTokens": 25178,
+ "costUsd": 0.75,
+ "tasks": {
+ "crate": {
+ "runs": 1,
+ "passed": 1,
+ "successRate": 1,
+ "toolCalls": 5,
+ "toolErrors": 0,
+ "inputTokens": 569309,
+ "outputTokens": 4585,
+ "costUsd": 0.12
+ },
+ "mug": {
+ "runs": 1,
+ "passed": 1,
+ "successRate": 1,
+ "toolCalls": 6,
+ "toolErrors": 0,
+ "inputTokens": 716255,
+ "outputTokens": 7141,
+ "costUsd": 0.14
+ },
+ "table": {
+ "runs": 1,
+ "passed": 1,
+ "successRate": 1,
+ "toolCalls": 5,
+ "toolErrors": 0,
+ "inputTokens": 560420,
+ "outputTokens": 2181,
+ "costUsd": 0.11
+ },
+ "soap": {
+ "runs": 1,
+ "passed": 1,
+ "successRate": 1,
+ "toolCalls": 8,
+ "toolErrors": 0,
+ "inputTokens": 931780,
+ "outputTokens": 3683,
+ "costUsd": 0.14
+ },
+ "chair": {
+ "runs": 1,
+ "passed": 1,
+ "successRate": 1,
+ "toolCalls": 5,
+ "toolErrors": 0,
+ "inputTokens": 566329,
+ "outputTokens": 3499,
+ "costUsd": 0.12
+ },
+ "gear": {
+ "runs": 1,
+ "passed": 1,
+ "successRate": 1,
+ "toolCalls": 5,
+ "toolErrors": 0,
+ "inputTokens": 563953,
+ "outputTokens": 4089,
+ "costUsd": 0.12
+ }
+ }
+ }
+ },
+ "records": [
+ {
+ "task": "crate",
+ "attempt": 1,
+ "pass": true,
+ "passed": 8,
+ "total": 8,
+ "failed": [],
+ "model": "claude-haiku-5-5",
+ "toolCalls": 5,
+ "toolErrors": 0,
+ "toolsByName": {
+ "ToolSearch": 1,
+ "scene_create": 1,
+ "mesh_inspect": 1,
+ "scene_look": 1,
+ "scene_export_recipe": 1,
+ "scene_dispose": 1
+ },
+ "features": {
+ "geometryTypes": [
+ "mesh"
+ ],
+ "meshOperations": [
+ "boolean"
+ ],
+ "motionIk": [],
+ "motionTracks": 0
+ },
+ "look": {
+ "silhouette": {
+ "views": {
+ "front": 1,
+ "side": 1,
+ "three-quarter": 1
+ },
+ "mean": 1
+ },
+ "images": [
+ "artifacts/agent-modeling/2026-11-01-01-25-haiku-look-before/look/1/crate-front.png",
+ "artifacts/agent-modeling/2026-11-01-01-25-haiku-look-before/look/1/crate-side.png",
+ "artifacts/agent-modeling/2026-11-01-01-25-haiku-look-before/look/1/crate-three-quarter.png"
+ ],
+ "judges": {
+ "sonnet-vision": {
+ "criteria": {
+ "shape": 3,
+ "proportions": 3,
+ "features": 3,
+ "surface": 3
+ },
+ "total": 12,
+ "score": 1,
+ "note": "The largest difference is colour: the candidate is tan wood and the reference is white. The recess on the right-hand face in the three-quarter view also looks slightly fainter than the reference's."
+ }
+ }
+ },
+ "turns": 7,
+ "costUsd": 0.11963418,
+ "inputTokens": 569309,
+ "outputTokens": 4585,
+ "wallSeconds": 46,
+ "exitCode": 0,
+ "stopped": "success"
+ },
+ {
+ "task": "mug",
+ "attempt": 1,
+ "pass": true,
+ "passed": 7,
+ "total": 7,
+ "failed": [],
+ "model": "claude-haiku-5-5",
+ "toolCalls": 6,
+ "toolErrors": 0,
+ "toolsByName": {
+ "ToolSearch": 1,
+ "scene_capabilities": 1,
+ "scene_create": 1,
+ "mesh_inspect": 1,
+ "scene_look": 1,
+ "scene_export_recipe": 1,
+ "scene_dispose": 1
+ },
+ "features": {
+ "geometryTypes": [
+ "mesh"
+ ],
+ "meshOperations": [
+ "boolean"
+ ],
+ "motionIk": [],
+ "motionTracks": 0
+ },
+ "look": {
+ "silhouette": {
+ "views": {
+ "front": 0.6616,
+ "side": 1,
+ "three-quarter": 0.7164
+ },
+ "mean": 0.7927
+ },
+ "images": [
+ "artifacts/agent-modeling/2026-11-01-01-25-haiku-look-before/look/1/mug-front.png",
+ "artifacts/agent-modeling/2026-11-01-01-25-haiku-look-before/look/1/mug-side.png",
+ "artifacts/agent-modeling/2026-11-01-01-25-haiku-look-before/look/1/mug-three-quarter.png"
+ ],
+ "judges": {
+ "sonnet-vision": {
+ "criteria": {
+ "shape": 3,
+ "proportions": 2,
+ "features": 2,
+ "surface": 3
+ },
+ "total": 10,
+ "score": 0.8333,
+ "note": "The candidate is a recognisable open-top mug with a loop handle on the +X side. Its handle is a short, round torus that sits high on the wall. The reference handle is a taller, oval loop that reaches lower. The candidate handle is about 0.02 m tall against roughly 0.03 m in the reference, and it is "
+ }
+ }
+ },
+ "turns": 8,
+ "costUsd": 0.14211782999999997,
+ "inputTokens": 716255,
+ "outputTokens": 7141,
+ "wallSeconds": 59,
+ "exitCode": 0,
+ "stopped": "success"
+ },
+ {
+ "task": "table",
+ "attempt": 1,
+ "pass": true,
+ "passed": 6,
+ "total": 6,
+ "failed": [],
+ "model": "claude-haiku-5-5",
+ "toolCalls": 5,
+ "toolErrors": 0,
+ "toolsByName": {
+ "ToolSearch": 1,
+ "scene_create": 1,
+ "mesh_inspect": 1,
+ "scene_look": 1,
+ "scene_export_recipe": 1,
+ "scene_dispose": 1
+ },
+ "features": {
+ "geometryTypes": [
+ "box"
+ ],
+ "meshOperations": [],
+ "motionIk": [],
+ "motionTracks": 0
+ },
+ "look": {
+ "silhouette": {
+ "views": {
+ "front": 1,
+ "side": 0.1684,
+ "three-quarter": 0.6073
+ },
+ "mean": 0.5919
+ },
+ "images": [
+ "artifacts/agent-modeling/2026-11-01-01-25-haiku-look-before/look/1/table-front.png",
+ "artifacts/agent-modeling/2026-11-01-01-25-haiku-look-before/look/1/table-side.png",
+ "artifacts/agent-modeling/2026-11-01-01-25-haiku-look-before/look/1/table-three-quarter.png"
+ ],
+ "judges": {
+ "sonnet-vision": {
+ "criteria": {
+ "shape": 3,
+ "proportions": 2,
+ "features": 3,
+ "surface": 3
+ },
+ "total": 11,
+ "score": 0.9167,
+ "note": "The largest difference is the leg placement along Z. The candidate's legs sit much closer to the front and back edges of the top than the reference's."
+ }
+ }
+ },
+ "turns": 7,
+ "costUsd": 0.11109133,
+ "inputTokens": 560420,
+ "outputTokens": 2181,
+ "wallSeconds": 35,
+ "exitCode": 0,
+ "stopped": "success"
+ },
+ {
+ "task": "soap",
+ "attempt": 1,
+ "pass": true,
+ "passed": 7,
+ "total": 7,
+ "failed": [],
+ "model": "claude-haiku-5-5",
+ "toolCalls": 8,
+ "toolErrors": 0,
+ "toolsByName": {
+ "ToolSearch": 1,
+ "scene_capabilities": 1,
+ "scene_create": 1,
+ "mesh_inspect": 1,
+ "scene_look": 2,
+ "scene_apply": 1,
+ "scene_export_recipe": 1,
+ "scene_dispose": 1
+ },
+ "features": {
+ "geometryTypes": [
+ "mesh"
+ ],
+ "meshOperations": [
+ "set_position",
+ "bevel"
+ ],
+ "motionIk": [],
+ "motionTracks": 0
+ },
+ "look": {
+ "silhouette": {
+ "views": {
+ "front": 1,
+ "side": 1,
+ "three-quarter": 1
+ },
+ "mean": 1
+ },
+ "images": [
+ "artifacts/agent-modeling/2026-11-01-01-25-haiku-look-before/look/1/soap-front.png",
+ "artifacts/agent-modeling/2026-11-01-01-25-haiku-look-before/look/1/soap-side.png",
+ "artifacts/agent-modeling/2026-11-01-01-25-haiku-look-before/look/1/soap-three-quarter.png"
+ ],
+ "judges": {
+ "sonnet-vision": {
+ "criteria": {
+ "shape": 3,
+ "proportions": 3,
+ "features": 3,
+ "surface": 3
+ },
+ "total": 12,
+ "score": 1,
+ "note": "Shape is right: a rounded rectangular bar with the same silhouettes. Proportions match the reference, including the 3:1 front view and the side depth. The prompt asks for rounded edges and corners and nothing else, and both images have exactly that. The surface is clean, with smooth, even rounding a"
+ }
+ }
+ },
+ "turns": 10,
+ "costUsd": 0.14150567999999997,
+ "inputTokens": 931780,
+ "outputTokens": 3683,
+ "wallSeconds": 57,
+ "exitCode": 0,
+ "stopped": "success"
+ },
+ {
+ "task": "chair",
+ "attempt": 1,
+ "pass": true,
+ "passed": 7,
+ "total": 7,
+ "failed": [],
+ "model": "claude-haiku-5-5",
+ "toolCalls": 5,
+ "toolErrors": 0,
+ "toolsByName": {
+ "ToolSearch": 1,
+ "scene_create": 1,
+ "mesh_inspect": 1,
+ "scene_look": 1,
+ "scene_export_recipe": 1,
+ "scene_dispose": 1
+ },
+ "features": {
+ "geometryTypes": [
+ "box"
+ ],
+ "meshOperations": [],
+ "motionIk": [],
+ "motionTracks": 0
+ },
+ "look": {
+ "silhouette": {
+ "views": {
+ "front": 1,
+ "side": 1,
+ "three-quarter": 1
+ },
+ "mean": 1
+ },
+ "images": [
+ "artifacts/agent-modeling/2026-11-01-01-25-haiku-look-before/look/1/chair-front.png",
+ "artifacts/agent-modeling/2026-11-01-01-25-haiku-look-before/look/1/chair-side.png",
+ "artifacts/agent-modeling/2026-11-01-01-25-haiku-look-before/look/1/chair-three-quarter.png"
+ ],
+ "judges": {
+ "sonnet-vision": {
+ "criteria": {
+ "shape": 3,
+ "proportions": 3,
+ "features": 3,
+ "surface": 3
+ },
+ "total": 12,
+ "score": 1,
+ "note": "The candidate chair matches the reference in all three views: same forms, proportions and feature count, with no gaps or floating parts. The only visible difference is a slightly bluer tint on the candidate."
+ }
+ }
+ },
+ "turns": 7,
+ "costUsd": 0.11606588000000001,
+ "inputTokens": 566329,
+ "outputTokens": 3499,
+ "wallSeconds": 58,
+ "exitCode": 0,
+ "stopped": "success"
+ },
+ {
+ "task": "gear",
+ "attempt": 1,
+ "pass": true,
+ "passed": 5,
+ "total": 5,
+ "failed": [],
+ "model": "claude-haiku-5-5",
+ "toolCalls": 5,
+ "toolErrors": 0,
+ "toolsByName": {
+ "ToolSearch": 1,
+ "scene_create": 1,
+ "scene_inspect": 1,
+ "mesh_inspect": 1,
+ "scene_export_recipe": 1,
+ "scene_dispose": 1
+ },
+ "features": {
+ "geometryTypes": [
+ "extrude"
+ ],
+ "meshOperations": [],
+ "motionIk": [],
+ "motionTracks": 0
+ },
+ "look": {
+ "silhouette": {
+ "views": {
+ "front": 0.9868,
+ "side": 0.9868,
+ "three-quarter": 0.8688
+ },
+ "mean": 0.9475
+ },
+ "images": [
+ "artifacts/agent-modeling/2026-11-01-01-25-haiku-look-before/look/1/gear-front.png",
+ "artifacts/agent-modeling/2026-11-01-01-25-haiku-look-before/look/1/gear-side.png",
+ "artifacts/agent-modeling/2026-11-01-01-25-haiku-look-before/look/1/gear-three-quarter.png"
+ ],
+ "judges": {
+ "sonnet-vision": {
+ "criteria": {
+ "shape": 2,
+ "proportions": 3,
+ "features": 1,
+ "surface": 3
+ },
+ "total": 9,
+ "score": 0.75,
+ "note": "The largest difference from the reference is the tooth form and count: pointed, star-like teeth (about 10) instead of 12 distinct rectangular teeth."
+ }
+ }
+ },
+ "turns": 7,
+ "costUsd": 0.11691673000000001,
+ "inputTokens": 563953,
+ "outputTokens": 4089,
+ "wallSeconds": 33,
+ "exitCode": 0,
+ "stopped": "success"
+ }
+ ]
+}
diff --git a/bench/agent-modeling/results/2026-11-01-01-36-haiku-look-after.json b/bench/agent-modeling/results/2026-11-01-01-36-haiku-look-after.json
new file mode 100644
index 00000000..7b000d63
--- /dev/null
+++ b/bench/agent-modeling/results/2026-11-01-01-36-haiku-look-after.json
@@ -0,0 +1,470 @@
+{
+ "run": "2026-11-01-01-36-haiku-look-after",
+ "model": "claude-haiku-5-5",
+ "date": "2026-11-01T01:42:42.931Z",
+ "skill": false,
+ "runsPerTask": 1,
+ "passed": 6,
+ "tasks": 6,
+ "toolCalls": 41,
+ "costUsd": 0.83,
+ "byModel": {
+ "claude-haiku-5-5": {
+ "runs": 6,
+ "passed": 6,
+ "successRate": 1,
+ "toolCalls": 41,
+ "toolErrors": 7,
+ "inputTokens": 4484932,
+ "outputTokens": 37195,
+ "costUsd": 0.83,
+ "tasks": {
+ "crate": {
+ "runs": 1,
+ "passed": 1,
+ "successRate": 1,
+ "toolCalls": 6,
+ "toolErrors": 0,
+ "inputTokens": 573504,
+ "outputTokens": 5182,
+ "costUsd": 0.12
+ },
+ "mug": {
+ "runs": 1,
+ "passed": 1,
+ "successRate": 1,
+ "toolCalls": 8,
+ "toolErrors": 2,
+ "inputTokens": 962695,
+ "outputTokens": 9287,
+ "costUsd": 0.16
+ },
+ "table": {
+ "runs": 1,
+ "passed": 1,
+ "successRate": 1,
+ "toolCalls": 8,
+ "toolErrors": 2,
+ "inputTokens": 814038,
+ "outputTokens": 2814,
+ "costUsd": 0.13
+ },
+ "soap": {
+ "runs": 1,
+ "passed": 1,
+ "successRate": 1,
+ "toolCalls": 8,
+ "toolErrors": 1,
+ "inputTokens": 958140,
+ "outputTokens": 4628,
+ "costUsd": 0.15
+ },
+ "chair": {
+ "runs": 1,
+ "passed": 1,
+ "successRate": 1,
+ "toolCalls": 3,
+ "toolErrors": 0,
+ "inputTokens": 346498,
+ "outputTokens": 3142,
+ "costUsd": 0.1
+ },
+ "gear": {
+ "runs": 1,
+ "passed": 1,
+ "successRate": 1,
+ "toolCalls": 8,
+ "toolErrors": 2,
+ "inputTokens": 830057,
+ "outputTokens": 12142,
+ "costUsd": 0.16
+ }
+ }
+ }
+ },
+ "records": [
+ {
+ "task": "crate",
+ "attempt": 1,
+ "pass": true,
+ "passed": 8,
+ "total": 8,
+ "failed": [],
+ "model": "claude-haiku-5-5",
+ "toolCalls": 6,
+ "toolErrors": 0,
+ "toolsByName": {
+ "ToolSearch": 1,
+ "scene_create": 1,
+ "scene_inspect": 1,
+ "mesh_inspect": 1,
+ "scene_look": 1,
+ "scene_export_recipe": 1,
+ "scene_dispose": 1
+ },
+ "features": {
+ "geometryTypes": [
+ "mesh"
+ ],
+ "meshOperations": [
+ "boolean"
+ ],
+ "motionIk": [],
+ "motionTracks": 0
+ },
+ "look": {
+ "silhouette": {
+ "views": {
+ "front": 1,
+ "side": 1,
+ "three-quarter": 1
+ },
+ "mean": 1
+ },
+ "images": [
+ "artifacts/agent-modeling/2026-11-01-01-36-haiku-look-after/look/1/crate-front.png",
+ "artifacts/agent-modeling/2026-11-01-01-36-haiku-look-after/look/1/crate-side.png",
+ "artifacts/agent-modeling/2026-11-01-01-36-haiku-look-after/look/1/crate-three-quarter.png"
+ ],
+ "judges": {
+ "sonnet-vision": {
+ "criteria": {
+ "shape": 3,
+ "proportions": 3,
+ "features": 2,
+ "surface": 2
+ },
+ "total": 10,
+ "score": 0.8333,
+ "note": "The largest difference from the reference is that the recessed panel is weak or missing in the front and side views, and the lid top shows plank seams."
+ }
+ }
+ },
+ "turns": 8,
+ "costUsd": 0.12262348,
+ "inputTokens": 573504,
+ "outputTokens": 5182,
+ "wallSeconds": 50,
+ "exitCode": 0,
+ "stopped": "success"
+ },
+ {
+ "task": "mug",
+ "attempt": 1,
+ "pass": true,
+ "passed": 7,
+ "total": 7,
+ "failed": [],
+ "model": "claude-haiku-5-5",
+ "toolCalls": 8,
+ "toolErrors": 2,
+ "toolsByName": {
+ "ToolSearch": 1,
+ "scene_capabilities": 1,
+ "scene_create": 3,
+ "mesh_inspect": 1,
+ "scene_look": 1,
+ "scene_export_recipe": 1,
+ "scene_dispose": 1
+ },
+ "features": {
+ "geometryTypes": [
+ "mesh"
+ ],
+ "meshOperations": [
+ "boolean"
+ ],
+ "motionIk": [],
+ "motionTracks": 0
+ },
+ "look": {
+ "silhouette": {
+ "views": {
+ "front": 0.8629,
+ "side": 1,
+ "three-quarter": 0.9392
+ },
+ "mean": 0.934
+ },
+ "images": [
+ "artifacts/agent-modeling/2026-11-01-01-36-haiku-look-after/look/1/mug-front.png",
+ "artifacts/agent-modeling/2026-11-01-01-36-haiku-look-after/look/1/mug-side.png",
+ "artifacts/agent-modeling/2026-11-01-01-36-haiku-look-after/look/1/mug-three-quarter.png"
+ ],
+ "judges": {
+ "sonnet-vision": {
+ "criteria": {
+ "shape": 3,
+ "proportions": 2,
+ "features": 3,
+ "surface": 3
+ },
+ "total": 11,
+ "score": 0.9167,
+ "note": "The largest difference from the reference is the handle shape and size: tall and squared in the candidate, small and oval in the reference."
+ }
+ }
+ },
+ "turns": 10,
+ "costUsd": 0.16246012999999998,
+ "inputTokens": 962695,
+ "outputTokens": 9287,
+ "wallSeconds": 77,
+ "exitCode": 0,
+ "stopped": "success"
+ },
+ {
+ "task": "table",
+ "attempt": 1,
+ "pass": true,
+ "passed": 6,
+ "total": 6,
+ "failed": [],
+ "model": "claude-haiku-5-5",
+ "toolCalls": 8,
+ "toolErrors": 2,
+ "toolsByName": {
+ "ToolSearch": 1,
+ "scene_capabilities": 1,
+ "scene_create": 2,
+ "mesh_inspect": 2,
+ "scene_look": 1,
+ "scene_export_recipe": 1,
+ "scene_dispose": 1
+ },
+ "features": {
+ "geometryTypes": [
+ "box"
+ ],
+ "meshOperations": [],
+ "motionIk": [],
+ "motionTracks": 0
+ },
+ "look": {
+ "silhouette": {
+ "views": {
+ "front": 1,
+ "side": 0.1582,
+ "three-quarter": 0.5769
+ },
+ "mean": 0.5784
+ },
+ "images": [
+ "artifacts/agent-modeling/2026-11-01-01-36-haiku-look-after/look/1/table-front.png",
+ "artifacts/agent-modeling/2026-11-01-01-36-haiku-look-after/look/1/table-side.png",
+ "artifacts/agent-modeling/2026-11-01-01-36-haiku-look-after/look/1/table-three-quarter.png"
+ ],
+ "judges": {
+ "sonnet-vision": {
+ "criteria": {
+ "shape": 3,
+ "proportions": 2,
+ "features": 2,
+ "surface": 3
+ },
+ "total": 10,
+ "score": 0.8333,
+ "note": "The largest difference is that the legs are placed at the corners with no inset, so the top overhangs less than the reference in the three-quarter view."
+ }
+ }
+ },
+ "turns": 10,
+ "costUsd": 0.13271283,
+ "inputTokens": 814038,
+ "outputTokens": 2814,
+ "wallSeconds": 29,
+ "exitCode": 0,
+ "stopped": "success"
+ },
+ {
+ "task": "soap",
+ "attempt": 1,
+ "pass": true,
+ "passed": 7,
+ "total": 7,
+ "failed": [],
+ "model": "claude-haiku-5-5",
+ "toolCalls": 8,
+ "toolErrors": 1,
+ "toolsByName": {
+ "ToolSearch": 2,
+ "scene_capabilities": 1,
+ "scene_create": 2,
+ "mesh_inspect": 1,
+ "scene_inspect": 1,
+ "scene_look": 1,
+ "scene_export_recipe": 1,
+ "scene_dispose": 1
+ },
+ "features": {
+ "geometryTypes": [
+ "mesh"
+ ],
+ "meshOperations": [
+ "set_position",
+ "bevel"
+ ],
+ "motionIk": [],
+ "motionTracks": 0
+ },
+ "look": {
+ "silhouette": {
+ "views": {
+ "front": 1,
+ "side": 1,
+ "three-quarter": 1
+ },
+ "mean": 1
+ },
+ "images": [
+ "artifacts/agent-modeling/2026-11-01-01-36-haiku-look-after/look/1/soap-front.png",
+ "artifacts/agent-modeling/2026-11-01-01-36-haiku-look-after/look/1/soap-side.png",
+ "artifacts/agent-modeling/2026-11-01-01-36-haiku-look-after/look/1/soap-three-quarter.png"
+ ],
+ "judges": {
+ "sonnet-vision": {
+ "criteria": {
+ "shape": 3,
+ "proportions": 3,
+ "features": 3,
+ "surface": 3
+ },
+ "total": 12,
+ "score": 1,
+ "note": "The largest difference from the reference is that cooler tint and the slightly sharper corner shading."
+ }
+ }
+ },
+ "turns": 11,
+ "costUsd": 0.14826853,
+ "inputTokens": 958140,
+ "outputTokens": 4628,
+ "wallSeconds": 59,
+ "exitCode": 0,
+ "stopped": "success"
+ },
+ {
+ "task": "chair",
+ "attempt": 1,
+ "pass": true,
+ "passed": 7,
+ "total": 7,
+ "failed": [],
+ "model": "claude-haiku-5-5",
+ "toolCalls": 3,
+ "toolErrors": 0,
+ "toolsByName": {
+ "ToolSearch": 1,
+ "scene_create": 1,
+ "scene_export_recipe": 1,
+ "scene_dispose": 1
+ },
+ "features": {
+ "geometryTypes": [
+ "box"
+ ],
+ "meshOperations": [],
+ "motionIk": [],
+ "motionTracks": 0
+ },
+ "look": {
+ "silhouette": {
+ "views": {
+ "front": 1,
+ "side": 1,
+ "three-quarter": 1
+ },
+ "mean": 1
+ },
+ "images": [
+ "artifacts/agent-modeling/2026-11-01-01-36-haiku-look-after/look/1/chair-front.png",
+ "artifacts/agent-modeling/2026-11-01-01-36-haiku-look-after/look/1/chair-side.png",
+ "artifacts/agent-modeling/2026-11-01-01-36-haiku-look-after/look/1/chair-three-quarter.png"
+ ],
+ "judges": {
+ "sonnet-vision": {
+ "criteria": {
+ "shape": 3,
+ "proportions": 3,
+ "features": 3,
+ "surface": 3
+ },
+ "total": 12,
+ "score": 1,
+ "note": "Largest difference: the candidate renders with a slightly bluer, cooler tone than the reference, and the geometry is otherwise indistinguishable."
+ }
+ }
+ },
+ "turns": 5,
+ "costUsd": 0.10222628,
+ "inputTokens": 346498,
+ "outputTokens": 3142,
+ "wallSeconds": 29,
+ "exitCode": 0,
+ "stopped": "success"
+ },
+ {
+ "task": "gear",
+ "attempt": 1,
+ "pass": true,
+ "passed": 5,
+ "total": 5,
+ "failed": [],
+ "model": "claude-haiku-5-5",
+ "toolCalls": 8,
+ "toolErrors": 2,
+ "toolsByName": {
+ "ToolSearch": 1,
+ "scene_create": 2,
+ "mesh_inspect": 2,
+ "scene_inspect": 1,
+ "scene_look": 1,
+ "scene_export_recipe": 1,
+ "scene_dispose": 1
+ },
+ "features": {
+ "geometryTypes": [
+ "extrude"
+ ],
+ "meshOperations": [],
+ "motionIk": [],
+ "motionTracks": 0
+ },
+ "look": {
+ "silhouette": {
+ "views": {
+ "front": 0.9868,
+ "side": 0.9868,
+ "three-quarter": 0.9437
+ },
+ "mean": 0.9724
+ },
+ "images": [
+ "artifacts/agent-modeling/2026-11-01-01-36-haiku-look-after/look/1/gear-front.png",
+ "artifacts/agent-modeling/2026-11-01-01-36-haiku-look-after/look/1/gear-side.png",
+ "artifacts/agent-modeling/2026-11-01-01-36-haiku-look-after/look/1/gear-three-quarter.png"
+ ],
+ "judges": {
+ "sonnet-vision": {
+ "criteria": {
+ "shape": 3,
+ "proportions": 3,
+ "features": 2,
+ "surface": 3
+ },
+ "total": 11,
+ "score": 0.9167,
+ "note": "The largest difference is tooth shape. The candidate's teeth are slightly narrower and more pointed than the reference's blocky teeth."
+ }
+ }
+ },
+ "turns": 10,
+ "costUsd": 0.15950458,
+ "inputTokens": 830057,
+ "outputTokens": 12142,
+ "wallSeconds": 65,
+ "exitCode": 0,
+ "stopped": "success"
+ }
+ ]
+}
diff --git a/docs/agent-look.md b/docs/agent-look.md
index e4a70c2d..e43ae02f 100644
--- a/docs/agent-look.md
+++ b/docs/agent-look.md
@@ -136,6 +136,8 @@ Setting `setup` through `set-environment` resets `lightDirection`, `keyColor`, `
Remote URLs and HDRI files are not accepted from tool input.
This changes the look of every recipe that sets no lighting: before, the default had no environment map, a key color of `[5.2, 4.7, 4.1]` and a fill intensity of `1`.
To get the earlier flat look, set `keyColor`, `fillIntensity` and `environmentIntensity: 0` yourself.
+The default `effects.exposure` is `0.8` (it was `1`); set `exposure: 1` to get the earlier brightness.
+There is no default ground: an object with no floor under it has no contact shadow, so add a ground node when the object should sit on something.
## Point lights
@@ -191,7 +193,7 @@ Ambient occlusion reads the depth texture, so it needs the HDR depth target that
| Field | Default | Range |
| --- | --- | --- |
-| `exposure` | `1` | `0.01` to `16` |
+| `exposure` | `0.8` | `0.01` to `16`. The default was `1` before the cold-run look check: a mid-grey surface clipped toward white under the daylight key |
| `saturation` | `1` | `0` to `2` |
| `contrast` | `1` | `0.1` to `2` |
| `temperature` | `0` | `-1` to `1` |
diff --git a/docs/parity.md b/docs/parity.md
index d297b8b1..fb1994c3 100644
--- a/docs/parity.md
+++ b/docs/parity.md
@@ -192,7 +192,7 @@ To move to a new Blender release, run `node scripts/parity-manual-snapshot.mjs`.
| Rendering > Cameras | partial | Perspective, orthographic views, focal length, animated paths, depth of field from depth and camera motion blur, both repeatable per frame. Object motion blur and bokeh shapes are missing. | [camera-path](../tests/camera-path.test.js), [camera](../tests/camera.test.js), [render-passes](../tests/render-passes.test.js) | #54 |
| Rendering > Lights > Light Objects | partial | One directional light with a shadow, 8 point lights, 8 spot lights and 4 rectangular area lights. Point and spot lights can cast shadows from one 24-tile atlas (a point light takes 6 tiles, a spot light 1). Area lights use a representative point and cast no shadow. The directional shadow is a single map, not cascaded. | [lighting](../tests/lighting.test.js), `npm run reference` scene `spot-area` | #52 |
| Rendering > Lights > Light Linking | missing | No light linking. | | #52 |
-| Rendering > Lights > World Environment | partial | Recipes pick a named setup (`daylight`, `overcast`, `sunset`, `studio`) that carries a procedural environment map, with opt-in screen-space ambient occlusion. Code can load any HDRI; recipes reach only the named maps, with no URLs or files. No reflections between objects yet. | [environment](../tests/environment.test.js), [default look](../tests/default-look.test.js) | #53 |
+| Rendering > Lights > World Environment | partial | Recipes pick a named setup (`daylight`, `overcast`, `sunset`, `studio`) that carries a procedural environment map, with opt-in screen-space ambient occlusion. Code can load any HDRI; recipes reach only the named maps, with no URLs or files. No reflections between objects yet. The default exposure is 0.8, and a recipe has no default ground or contact shadow. The cold-run look score (#53) is measured but shows no lift over the previous default. | [environment](../tests/environment.test.js), [default look](../tests/default-look.test.js) | #53 |
| Rendering > Materials > Components | partial | Surfaces with PBR factors and five maps, a clear coat, transmission with thickness, attenuation and IOR, sheen, and specular weight and tint. Anisotropic highlights and a thin-film iridescence layer, as in the glTF extensions, are compiled in only when a part uses them. There is no subsurface scattering, volume material or displacement. | [texture-set](../tests/texture-set.test.js), [material-layers](../tests/material-layers.test.js) | #50, #51 |
| Rendering > Materials > Assignment | done | A node names one material. | [agent-scene](../tests/agent-scene.test.js) | |
| Rendering > Materials > Preview | out of scope | Interface for a person. Agents use `scene_look`. | | |
diff --git a/skills/build-67js-scene/SKILL.md b/skills/build-67js-scene/SKILL.md
index 118bf550..91fc4817 100644
--- a/skills/build-67js-scene/SKILL.md
+++ b/skills/build-67js-scene/SKILL.md
@@ -72,7 +72,7 @@ Read [scene-contract.md](references/scene-contract.md) before creating parts or
7. Validate geometry, bounds and scene budgets with the existing Node tests.
8. Capture actual rendered wide and narrow views. Inspect edges, highlights, overlap and the focal point.
9. Exercise orbit, zoom, camera selection and the requested interaction through project dev tooling.
-10. In a recipe, start from the default look: `environment.setup` is `daylight` and `effects.ambientOcclusion` is `0` (off; set 0.4 to 0.8 to add contact darkening). Pick `studio` for products, `overcast` for soft even light, `sunset` for warm low light; Do not hand-tune key, fill and ambient first.
+10. In a recipe, start from the default look: `environment.setup` is `daylight` and `effects.ambientOcclusion` is `0` (off; set 0.4 to 0.8 to add contact darkening). Pick `studio` for products, `overcast` for soft even light, `sunset` for warm low light; Do not hand-tune key, fill and ambient first. The default `effects.exposure` is `0.8`. There is no default ground: add a floor node when an object should sit on something, or it floats with no contact shadow.
Do not treat an `antialias: true` context as proof that the final image looks smooth.
Report measured geometry, draw counts and render size separately from visual judgments.
diff --git a/src/agent-look.js b/src/agent-look.js
index 851655a8..3a43638c 100644
--- a/src/agent-look.js
+++ b/src/agent-look.js
@@ -4,7 +4,7 @@ import { resolveEffects } from './effects.js';
import { resolveVolumeFog } from './volumetric.js';
import { resolveLiquidOptics } from './renderer.js';
import { createLightingSetupMap, lightingSetupFields } from './lighting-setups.js';
-import { DEFAULT_LIGHTING_SETUP, LIGHTING_SETUP_NAMES, DEFAULT_AMBIENT_OCCLUSION } from './agent-scene-capabilities.js';
+import { DEFAULT_LIGHTING_SETUP, LIGHTING_SETUP_NAMES, DEFAULT_AMBIENT_OCCLUSION, DEFAULT_EXPOSURE } from './agent-scene-capabilities.js';
const ENVIRONMENT_FIELDS = [
'world', 'setup', 'environmentIntensity', 'environmentRotation', 'lightDirection', 'keyColor', 'keyIntensity', 'fillIntensity', 'ambientIntensity',
@@ -280,7 +280,7 @@ function effectsFrom(input = {}) {
}
const ambientOcclusion = fallback(input.ambientOcclusion, DEFAULT_AMBIENT_OCCLUSION);
const resolved = resolveEffects({ ...input, ambientOcclusion, ...groups, bloom: { strength: 0.12, threshold: 1, radius: 1, ...groups.bloom } });
- return { ...resolved, exposure: numberInRange(fallback(input.exposure, 1), 0.01, 16, 'exposure') };
+ return { ...resolved, exposure: numberInRange(fallback(input.exposure, DEFAULT_EXPOSURE), 0.01, 16, 'exposure') };
}
function shadowFrom(input = {}) {
diff --git a/src/agent-scene-capabilities.js b/src/agent-scene-capabilities.js
index 55cb5b14..984ee9d5 100644
--- a/src/agent-scene-capabilities.js
+++ b/src/agent-scene-capabilities.js
@@ -80,6 +80,8 @@ export const RECIPE_ALPHA_MODES = Object.freeze(['opaque', 'blend']);
export const LIGHTING_SETUP_NAMES = Object.freeze(['daylight', 'overcast', 'sunset', 'studio']);
export const DEFAULT_LIGHTING_SETUP = 'daylight';
export const DEFAULT_AMBIENT_OCCLUSION = 0;
+// Under the daylight key and sky a mid-grey surface clips toward white at exposure 1 and loses the shading between faces.
+export const DEFAULT_EXPOSURE = 0.8;
// Render passes a render job can write next to the lit image (see RENDER_PASS_MODES in renderer.js, which must list the same names).
export const RENDER_PASS_NAMES = Object.freeze(['albedo', 'normal', 'emission', 'depth', 'objectId']);
diff --git a/tests/agent-look.test.js b/tests/agent-look.test.js
index 7d6b7514..5f43d1a1 100644
--- a/tests/agent-look.test.js
+++ b/tests/agent-look.test.js
@@ -2,6 +2,7 @@ import test from 'node:test';
import assert from 'node:assert/strict';
import { mat4 } from 'gl-matrix';
import { normalizeAgentLook, resolveAgentShadow } from '../src/agent-look.js';
+import { DEFAULT_EXPOSURE } from '../src/agent-scene-capabilities.js';
import { createLightingState, updateLightingState } from '../src/lighting.js';
import { resolveVolumeFog } from '../src/volumetric.js';
@@ -29,7 +30,7 @@ test('default look is complete, detached JSON and idempotent', () => {
depthOfField: { blur: 0, focusDistance: 5 }, motionBlur: { shutter: 0 },
saturation: 1, contrast: 1, temperature: 0, vignette: 0, grain: 0,
ambientOcclusion: 0, ambientOcclusionRadius: 0.5,
- bloom: { strength: 0.12, threshold: 1, radius: 1 }, exposure: 1,
+ bloom: { strength: 0.12, threshold: 1, radius: 1 }, exposure: DEFAULT_EXPOSURE,
});
assert.deepEqual(look.shadow, { target: [0, 1, 0], extent: 3.5, distance: 8, near: 0.1, far: 15 });
assert.deepEqual(JSON.parse(JSON.stringify(look)), look);
diff --git a/tests/default-look.test.js b/tests/default-look.test.js
index 52f7ba76..a44d4476 100644
--- a/tests/default-look.test.js
+++ b/tests/default-look.test.js
@@ -1,6 +1,6 @@
import assert from 'node:assert/strict';
import test from 'node:test';
-import { AGENT_SCENE_CAPABILITIES, DEFAULT_AMBIENT_OCCLUSION, DEFAULT_LIGHTING_SETUP, LIGHTING_SETUP_NAMES } from '../src/agent-scene-capabilities.js';
+import { AGENT_SCENE_CAPABILITIES, DEFAULT_AMBIENT_OCCLUSION, DEFAULT_EXPOSURE,DEFAULT_LIGHTING_SETUP, LIGHTING_SETUP_NAMES } from '../src/agent-scene-capabilities.js';
import { agentEnvironmentMap, environmentPatchWithSetup, normalizeAgentLook } from '../src/agent-look.js';
import { createLightingSetupMap, lightingSetupFields } from '../src/lighting-setups.js';
import { resolveEffects } from '../src/effects.js';
@@ -25,6 +25,7 @@ test('a recipe with no lighting settings gets the default setup and occlusion',
const look = normalizeAgentLook({});
assert.equal(look.environment.setup, DEFAULT_LIGHTING_SETUP);
assert.equal(look.effects.ambientOcclusion, DEFAULT_AMBIENT_OCCLUSION);
+ assert.equal(look.effects.exposure, DEFAULT_EXPOSURE);
assert.deepEqual(look.environment.lightDirection, lightingSetupFields(DEFAULT_LIGHTING_SETUP).lightDirection);
});