← d8111f3f714d · d83b3801c134 →

d833a288bd7d

A 10..20 square-ish canvas contains one dense 3..6 square bitmap in colors 1/8, one yellow source marker at an expanded bbox corner, and a separate three-cell yellow L cluster in the target quadrant. Rotate the colored bitmap by target-source quarter turns and mark the target corner yellow.

parametric family

Generated by the released generator before publication; every output was computed by its Racket reference rule. White outlines mark the cells the rule changed. Lesson check:

refuted: a demonstration contradicts the rival. survived_all: it fits every demonstration and also gives the intended answer, so it cannot mislead here. ambiguous: it fits every demonstration but answers the query differently. Names are as declared by the generator; a declared shortcut is not guaranteed to fit the original pairs (see the paper’s Limitations).

Original task pairs

From the source task; the reference rule must reproduce them.

Reference rule (Racket)

(rule! (lambda (g)
         (let* ((h (rows g))
                (w (cols g)))
           (let* ((shape-cells (for*/list ((r (range 0 h)) (c (range 0 w))
                                   #:when
                                   (or (= (at g r c) 1) (= (at g r c) 8)))
                                 (list r c)))
                  (sr1 (min-of first shape-cells))
                  (sc1 (min-of second shape-cells))
                  (sr2 (max-of first shape-cells))
                  (sc2 (max-of second shape-cells))
                  (sh (+ 1 (- sr2 sr1)))
                  (sw (+ 1 (- sc2 sc1)))
                  (yellows (for*/list ((r (range 0 h)) (c (range 0 w)) #:when (= (at g r c) 4))
                             (list r c)))
                  (corners (list (list (- sr1 1) (- sc1 1) 0)
                                 (list (- sr1 1) (+ sc2 1) 1)
                                 (list (+ sr2 1) (+ sc2 1) 2)
                                 (list (+ sr2 1) (- sc1 1) 3)))
                  (source-diag 0)
                  (dummy1 (for ((y yellows))
                            (for ((c corners))
                              (when
                                (and (= (first y) (first c)) (= (second y) (second c)))
                                (set! source-diag (third c))))))
                  (cluster (filter (lambda (y)
                                     (not (for/or ((c corners))
                                                  (and
                                                    (= (first y) (first c))
                                                    (= (second y) (second c))))))
                                   yellows))
                  (cmr (quotient (for/sum ((y cluster)) (first y)) (length cluster)))
                  (cmc (quotient (for/sum ((y cluster)) (second y)) (length cluster)))
                  (scr (quotient (+ sr1 sr2) 2))
                  (scc (quotient (+ sc1 sc2) 2))
                  (target-diag (cond
                                 ((and (<= cmr scr) (<= cmc scc)) 0)
                                 ((and (<= cmr scr) (> cmc scc)) 1)
                                 ((and (> cmr scr) (> cmc scc)) 2)
                                 (else 3)))
                  (rot (remainder (+ 4 (- target-diag source-diag)) 4))
                  (result (make-hash)))
             (for* ((r (range 0 h)) (c (range 0 w))) (hash-set! result (list r c) 0))
             (for* ((dr (range 0 sh)) (dc (range 0 sw)))
                   (let* ((v (at g (+ sr1 dr) (+ sc1 dc)))
                          (nr (cond
                                ((zero? rot) dr)
                                ((= rot 1) dc)
                                ((= rot 2) (- (- sh 1) dr))
                                (else (- (- sw 1) dc))))
                          (nc (cond
                                ((zero? rot) dc)
                                ((= rot 1) (- (- sh 1) dr))
                                ((= rot 2) (- (- sw 1) dc))
                                (else dr))))
                     (when
                       (or (= v 1) (= v 8))
                       (hash-set! result (list (+ sr1 nr) (+ sc1 nc)) v))))
             (let ((yr (if (< target-diag 2) (- sr1 1) (+ sr2 1)))
                   (yc (if (or (zero? target-diag) (= target-diag 3))
                           (- sc1 1)
                           (+ sc2 1))))
               (hash-set! result (list yr yc) 4))
             (cellmap g (r c v) (hash-ref result (list r c) 0))))))

Provenance

Generator
generators/d833a288bd7d/generator.py
Notes and decisions
generators/d833a288bd7d/notes.md
Review label
reviewed_safe
Generator SHA-256
a3a2b20673699178ba8acc6e8343d9660fbf788b0ebb8e414455dcadf34c124b
Rule hash
67e977ce99e1
Sources
augmented, training
Lesson seeds
20261108, 20261109, 20261110, 20261111, 20261112
Reproduce lesson 1
arcpuzzles generate d833a288bd7d --count 1 --seed 20261108 --test 1