From 1dc2e5da3efca9cc0be1108105d2c2fae7fd469b Mon Sep 17 00:00:00 2001 From: job runner Date: Thu, 15 Oct 2026 06:14:40 +0000 Subject: [PATCH] box-generation-repaired: known failures of c4_qwen3_8_27b_fast_2_p7f083850 from the review Stage: review --- .../c4_qwen3_8_27b_fast_2_p7f083850.json | 96 +++++++++++++++++++ 1 file changed, 96 insertions(+) create mode 100644 crates/generation/tests/fixtures/box-generation-repaired/known-failures/c4_qwen3_8_27b_fast_2_p7f083850.json diff --git a/crates/generation/tests/fixtures/box-generation-repaired/known-failures/c4_qwen3_8_27b_fast_2_p7f083850.json b/crates/generation/tests/fixtures/box-generation-repaired/known-failures/c4_qwen3_8_27b_fast_2_p7f083850.json new file mode 100644 index 00000000..500d54cb --- /dev/null +++ b/crates/generation/tests/fixtures/box-generation-repaired/known-failures/c4_qwen3_8_27b_fast_2_p7f083850.json @@ -0,0 +1,96 @@ +{ + "format": 1, + "function": "c4_qwen3_8_27b_fast_2_p7f083850.rs", + "failing_train_cases": [], + "wrong_inputs": [ + { + "number": 1, + "inputs": { + "display": "FlowRoot", + "float": "None", + "position": "Absolute" + }, + "code_gives": "Display::Block, Float::None", + "spec_gives": "Display::FlowRoot, Float::None (9.7 rule 2: float computes to none; display set by the table, where flow-root is in the 'others | same as specified' row)", + "needs_input": { + "answer": "no" + }, + "cases": [] + }, + { + "number": 2, + "inputs": { + "display": "FlowRoot", + "float": "Left", + "position": "Static" + }, + "code_gives": "Display::Block, Float::Left", + "spec_gives": "Display::FlowRoot, Float::Left (9.7 rule 3: the box floats; the table leaves flow-root unchanged)", + "needs_input": { + "answer": "no" + }, + "cases": [] + }, + { + "number": 3, + "inputs": { + "display": "InlineBlock", + "float": "None", + "position": "Static" + }, + "code_gives": "Display::InlineBlock, Float::None", + "spec_gives": "Display::Block, Float::None (9.7 rule 4: for the root element, display is set according to the table, which maps inline-block to block)", + "needs_input": { + "answer": "yes", + "what": "whether the element is the document's root element (BoxGenerationEngineValues.is_root), which the committed BoxGenerationInputs omits" + }, + "cases": [] + } + ], + "other_failures": [], + "unreadable": [], + "findings": [ + "**Scope claim.** All three committed files (`crates/generation/tests/fixtures/box-generation-repaired/NOTICE`, `.../c4_qwen3_8_27b_fast_2_p7f083850.rs`, `.../types/c4_qwen3_8_27b_fast_2_p7f083850.rs`) are inside the spec's `touches` glob `crates/generation/tests/fixtures/box-generation-repaired/**` — in scope, no file outside it.", + "**What the committed function gets right** (hand-checked against `corpus/display-contents-specification/references/2-dis-pos-flo.txt` (CSS 2.1 9.7) and `.../relevant.txt` (Display 3 2.5), for `resolve` in `c4_qwen3_8_27b_fast_2_p7f083850.rs`):", + "`Display::None` → no box, float none (9.7 rule 1) — correct, and it wins over position/float.", + "`Display::Contents` → no box, float none, checked *before* position and float — correct: a `contents` element's own `position`/`float` have no effect (`specs/display-contents.md` scope, Display 3 2.5); nested and in-`contents`-`none` compose correctly since the call is per-element.", + "`inline-block` + absolute/fixed → `block`, float none; `inline-block` + float → `block`, kept float (9.7 rules 2–3, table row).", + "`block` in every combination → passed through, correct.", + "**Correctness problems on in-scope inputs:**", + "**`flow-root` is blockified by out-of-flow positioning and floats.** 9.7's table (`references/2-dis-pos-flo.txt`) has rows `inline, table-*, inline-block → block` and `others → same as specified`; `flow-root` is in \"others\", so the computed display stays `flow-root` (Display 3 2.7's \"blockifies\" note points at that same CSS 2 table). `FlowRoot` is an in-scope display value — the committed types file (`types/c4_qwen3_8_27b_fast_2_p7f083850.rs`, identical to `crates/layout/src/box_generation_types.rs`) lists it under **Scope** as in, and the spec's scope puts 9.7 in \"as far as the engine's values reach\" (`dom::computed::Display::FlowRoot`, per `box_generation_call_site.txt`). Yet `resolve`'s second branch returns `Display::Block` for `position: Absolute|Fixed` regardless of display, and its third branch returns `Display::Block` for any float. No corpus page uses `flow-root`, which is why this passed 45/45 — but a page in the 9.7 scope (`
` or `;float:left`) is in scope.", + "**The root element cannot be answered, because the input struct dropped `is_root`.** The spec's scope explicitly lists \"the root\" (9.7 rule 4: for the root element, display is set according to the table, so root `inline-block` computes to `block`; only *contents* on the root/`` is excluded). `BoxGenerationEngineValues` provides `is_root` (`crates/layout/src/box_generation_engine.rs`) and the baseline reads it (`crates/layout/src/box_generation.rs::baseline`), but the committed types file's `BoxGenerationInputs` carries only `display`, `position`, `float` and never says the root is out of scope. The function is called on the root (`boxtree.rs build_box`, \"The walk starts at the root element\" in `box_generation_call_site.txt`), and for a root `` with `display:inline-block`, static, no float, `resolve` returns `InlineBlock` where rule 4 + the table give `Block`; it cannot be right without `is_root`.", + "**Questions 3–5.** (3) In scope, as stated above. (4) The commit message (\"store c4_qwen3_8_27b_fast_2_p7f083850.rs, train 45 of 45, held-out 13 of 13\") is a reasonable record of stage 11's `store`: it matches the NOTICE, `corpus/display-contents-batch-store.json` (`misses: \"no\"`, 45/45, `c4` source), and the held-out report (13/13); the stored file is byte-identical to `corpus/display-contents-batch/sources/c4_qwen3_8_27b_fast_2.rs`. (5) Every script stage in the state file is `passed`, and the only check-bearing stage, `prompt`, records a passing check (specification text, marked part, 2 cited sections, 295 expected results) — all artifacts present.", + "The failure is the function's, not the pipeline's: the admitted candidate's rules are wrong on `flow-root` × {absolute, fixed, float} and structurally blind to the root.", + "```wrong-inputs", + "[", + "{", + "\"inputs\": {", + "\"display\": \"FlowRoot\",", + "\"position\": \"Absolute\",", + "\"float\": \"None\"", + "},", + "\"code_gives\": \"Display::Block, Float::None\",", + "\"spec_gives\": \"Display::FlowRoot, Float::None (9.7 rule 2: float computes to none; display set by the table, where flow-root is in the 'others | same as specified' row)\"", + "},", + "{", + "\"inputs\": {", + "\"display\": \"FlowRoot\",", + "\"position\": \"Static\",", + "\"float\": \"Left\"", + "},", + "\"code_gives\": \"Display::Block, Float::Left\",", + "\"spec_gives\": \"Display::FlowRoot, Float::Left (9.7 rule 3: the box floats; the table leaves flow-root unchanged)\"", + "},", + "{", + "\"inputs\": {", + "\"display\": \"InlineBlock\",", + "\"position\": \"Static\",", + "\"float\": \"None\"", + "},", + "\"code_gives\": \"Display::InlineBlock, Float::None\",", + "\"spec_gives\": \"Display::Block, Float::None (9.7 rule 4: for the root element, display is set according to the table, which maps inline-block to block)\",", + "\"needs_input\": \"whether the element is the document's root element (BoxGenerationEngineValues.is_root), which the committed BoxGenerationInputs omits\"", + "}", + "]" + ] +} -- 2.54.0