sidrefresh's picture
Add files using upload-large-folder tool
2e7de11 verified
|
Raw History Blame Contribute Delete
12.5 kB

t35 — follow text instructions: draw it, then spin it

Harbor task sid/t35-follow-text-instructions, version 0.1.0; rubric penrose-spin-v1.0.

The agent is given a written brief and nothing else to work from. It draws a Penrose impossible triangle in GIMP from that brief, then takes the drawing into Friction, sets the anchor point at the centre of the image, animates three clockwise turns across exactly five seconds with motion blur on, and exports the result. A rendered copy of the original reference artwork is on the desktop as a picture it may look at — but the brief comes first, and opening the reference file inside GIMP is treated as cheating.

The point of the task is instruction-following under a spec that is precise about some things (six vertex coordinates, three hex fills, a 6px stroke) and demanding about one thing that cannot be reached by copying numbers: the three T-junctions that make the figure impossible.

What the agent receives

environment/media/, copied to /root/media/:

  • penrose-spec.md — the brief, verbatim as supplied, plus a short "Notes on reading this brief" section that resolves its one internal contradiction (see Known conflict below).
  • reference/Penrose_triangle.svg — the original reference figure (2,716 bytes, 280×243, Inkscape 0.44), chmod 444.
  • reference/reference-preview.png — a 1000×1000 white-backed raster of that SVG, rendered at image build time with rsvg-convert. The Reference Image desktop launcher opens this in Ristretto, an image viewer, so that looking at the reference can never become "opened it in GIMP".

Deliverables, all named in instruction.md:

Path What it is
/root/edit/penrose.xcf the GIMP working file
/root/edit/penrose.png the flattened drawing, 1000×1000 RGB
/root/edit/penrose.friction the Friction project
/root/Desktop/final.mp4 the export: H.264, 1000×1000, ≥30 fps, 5.0 s

Rubric

Fourteen checks, weights summing to exactly 1.0 (asserted at import time in tests/penrose_score.py). Each check is a fraction in [0, 1]; the reward is the weighted sum.

Check Weight Evidence
drawing_canvas 2% 1000×1000 exactly; 55% for another square canvas 700–1400
drawing_background_white 3% border ring white and overall white share
drawing_face_colors 9% each of #E0D5E7 / #FFFECB / #C2DFC9 covering 1.5–18% of the canvas at tolerance 8; 45% credit at tolerance 28
drawing_stroke_6px 6% 97th-percentile Euclidean distance transform of the black mask, doubled
drawing_geometry 4% silhouette extremes vs the four outer bounds and the hole's bounding box and area
drawing_impossible_loop 10% 0.25 face-to-beam assignment, 0.25 lavender-before-green at the lower left, 0.5 the three joint lines being present
gimp_xcf_present 2% an .xcf over 4 KiB in /root/edit
friction_import_of_artwork 10% the render carries the agent's own palette (0.4) and its normalised radial ink profile (0.6)
rotation_direction_clockwise 6% fraction of inter-frame steps that increase the lavender-face angle
rotation_three_turns 10% unwrapped total rotation / 360, multiplied by the direction score
motion_blur 12% non-palette "mixed" pixel share in the render over the same share in the agent's own still (0.75), outer-vs-inner annulus smear (0.25)
duration_5s 8% container duration, full credit within ±0.20 s
anchor_centered 10% figure-centroid drift across frames and its offset from the frame centre
export_valid 8% codec, frame count, and the render not being static

Two gates sit above the weights:

  • Terminal attempt — a non-empty /logs/artifacts/terminal-attempts.log sets the reward to 0.0 with zeroed_because in the report. Standing image rule; the agent has no terminal and every launcher is a logging stub.
  • Reference SVG imported into GIMP — every drawing_* check is zeroed (34% of the reward) if penrose_triangle.svg appears in GIMP's documents / sessionrc / gimprc, in recently-used.xbel, or as a string inside a delivered .xcf. The animation half is still earnable: the gate punishes tracing, not the whole run.

The seven items Sid asked for map onto the checks like this:

Requested Checks
1. VLM comparison of the GIMP output against the original reference drawing_* (34%) in-sandbox, plus the host-side t35 judge — see SCORING.md
2. the file is imported inside Friction friction_import_of_artwork (10%)
3. clockwise rotation animation rotation_direction_clockwise (6%), rotation_three_turns (10%)
4. motion blur enabled motion_blur (12%)
5. the animation is 5 seconds duration_5s (8%)
6. anchor point at the centre anchor_centered (10%)
7. the file is exported export_valid (8%), gimp_xcf_present (2%)

The GIMP image and the final video are also collected outside the task: tests/test.sh copies final.mp4, penrose.png, all of /root/edit, a recovery sweep, and GIMP's config evidence into both /logs/artifacts/ and /logs/verifier/artifacts/, because harbor collects the first before the verifier runs and the second after.

Calibration

tools/build_calibration.py renders the brief's figure with PIL, spins it with ffmpeg, then scores that plus fourteen deliberate corruptions. Measured with penrose-spin-v1.0:

Variant Reward What it loses
good (oracle) 1.0000 —
no-joint-lines 0.9500 half of drawing_impossible_loop: a flat, possible ring
eight-seconds 0.9041 duration_5s
hairline-stroke 0.9007 drawing_stroke_6px 0.60, motion_blur 0.37
no-blur 0.8800 motion_blur 0.00
off-center-pivot 0.8642 anchor_centered 0.00
counter-clockwise 0.8400 both rotation checks 0.00
one-turn 0.8378 rotation_three_turns 0.00
foreign-artwork 0.8195 friction_import_of_artwork 0.40, motion_blur 0.00
black-background 0.8103 background, stroke and geometry
still-frame 0.7180 rotation, blur, export_valid 0.60
wrong-face-colors 0.7296 drawing_face_colors 0.00, half the loop check
video-only (no drawing on disk) 0.5400 all drawing_*, gimp_xcf_present, friction_import_of_artwork
drawing-only (no export) 0.3600 everything the video carries
nothing 0.0000 do-nothing floor

Oracle 1.0, do-nothing floor 0.0, every mid-task state strictly between — fcpx.md §1c-5. The full per-check matrix lives in the calibration output (--out <dir>/summary.json); it is not committed.

Two couplings are intentional and worth knowing when reading a report: motion_blur is measured relative to the agent's own still, so a render whose artwork does not match the still (foreign-artwork, wrong-face-colors) also loses blur credit; and rotation_three_turns is gated on direction, so a perfect counter-clockwise triple spin loses 16%, not 6%.

Known conflict between the brief and the reference

The brief's six coordinates and its phrase "uniform beam width of 80px" do not describe the same figure. With the given outer triangle (inradius 210.08, centroid 500,500) and inner triangle (inradius 103.63, centroid 500,466.67) the beams are roughly 90px on the two diagonals and 140px across the base, and the central hole is smaller and higher than the reference's.

penrose-spec.md resolves this by declaring the six coordinates authoritative and the 80px phrase descriptive, and the verifier grades only the coordinates. The host-side VLM prompt states the conflict explicitly so a faithful agent is not marked down for it.

If the conflict should be removed instead of documented, the concentric inner triangle that does give a uniform 80px beam is (500.0, 239.9) (725.4, 630.0) (274.6, 630.0) — but changing it moves HOLE, JOINT_CUTS and the two palette probe rows in tests/penrose_score.py, so it is a rubric-version event and needs a recalibration run.

The oracle

solution/solve.sh is an artifact-calibration oracle. It draws the figure with GIMP's batch Script-Fu — solution/penrose.scm, the same code an agent can paste into Filters ▸ Script-Fu ▸ Console — falls back to solution/render_penrose.py (PIL) if the batch route is unavailable, then renders the spin with ffmpeg:

fps=240,rotate=a='18.849556*t/5.0':fillcolor=white:ow=iw:oh=ih,tmix=frames=8,fps=30

ffmpeg's rotate angle is positive for an on-screen clockwise turn; the first version of this render measured −1071.6° and had to be flipped.

It produces no penrose.friction: a binary Qt project cannot be authored outside the GUI. That deliverable therefore carries zero weight and is reported as evidence only (friction_evidence: size, sha256, whether it mentions penrose.png and motion blur). The animation half of the reward is paid for by pixel measurements of the render instead.

Build and local checks

./suite/suite.sh refresh tasks/t35-follow-text-instructions
./suite/suite.sh doctor  tasks/t35-follow-text-instructions
docker build --platform linux/amd64 \
  -f tasks/t35-follow-text-instructions/environment/Dockerfile \
  -t refresh-fcpx-t35:penrose-v1 tasks/t35-follow-text-instructions/environment
python3 tasks/t35-follow-text-instructions/tools/build_calibration.py --out /tmp/t35cal

The host-side tools need NumPy, SciPy, Pillow, FFmpeg/FFprobe and pytest; the Dockerfile installs the evaluation dependencies at build time (python3-numpy python3-scipy python3-pil).

The advisory judge (needs anthropic and an API key on the host, costs money):

./suite/vision_judge.py jobs/<job>        # t35 mode auto-detects penrose.png

Deliberate divergences from neighbouring tasks

  • t15 purged GIMP because its Script-Fu console is a scripting surface. t35 keeps GIMP and keeps Script-Fu reachable: the task explicitly allows "expressions and scripts within gimp". Script-Fu's TinyScheme has no process-spawning primitive, so it is not a terminal.
  • Python-Fu is deliberately absent. It would hand the agent os.system(), which is a terminal by another name. Debian bookworm no longer ships it; the Dockerfile asserts ! ls /usr/lib/gimp/2.0/python.
  • t24 compiles friction-gui-only.so to block Friction's expression editor. t35 ships no such guard — the only banned surface here is a terminal, and Friction expressions are allowed.
  • Only three GUI applications are exposed: GIMP, Friction, and the Ristretto reference viewer. environment/harden-desktop.py enforces that allow-list over launchers, panel plugins and autostart.
  • Chromium is installed but unexposed. t24 purges it; t35 cannot, because computer-1's runtime hard-codes /usr/bin/chromium, boots its own XFCE session on :1, and times out agent setup without it (the first local run died exactly this way). It has no .desktop entry and the sandbox has no network. This is the README's "environment contract", not a relaxation of the no-terminal rule.

Prelaunch checklist

  1. Freeze a real penrose.friction. Drive Friction once in the locally built image, save the project, and keep it under source-assets/ as the reviewer's reference for what a genuine project file looks like. Until then nobody has seen a correct one for this task.
  2. Confirm penrose.scm runs under the image's GIMP 2.10, not just on the host. gimp-context-set-stroke-method and the gimp-drawable-edit-* family are 2.10-only; the oracle silently falls back to PIL if they fail, which would hide a broken Script-Fu route.
  3. Pilot with computer-1. The 14,400-second agent timeout is a guess, not a measured completion budget. Two applications and a from-scratch vector drawing is a large GUI workload.
  4. Check the SVG-import gate on a real GIMP session — open an unrelated file, confirm it lands in /root/.config/GIMP/2.10/documents, and confirm the reference viewer does not.
  5. Decide the brief-vs-reference conflict above: document it (current state) or re-cut the geometry and bump the rubric version.
  6. Publish the task GUI snapshot and record it in the central environments/vedit/env.toml; never rely on the suite CLI's fallback.