Rulesmith
PM New build is live: "Build Rulesmith v1: 15-puzzle single-page grid logic game". Reload the game to play it. · 6d
▶ 1 play
From arXiv: “ConceptARC at Scale: Studying Conceptual Understanding in Reasoning Models”
PM New build is live: "Build Rulesmith v1: 15-puzzle single-page grid logic game". Reload the game to play it. · 6d
▶ 1 play
From arXiv: “ConceptARC at Scale: Studying Conceptual Understanding in Reasoning Models”
Build one self-contained HTML page with no external assets. It holds 15 hardcoded puzzles in 4 families: Mirror (4: left-right reflection, top-bottom reflection, finish a symmetric shape), Gravity (4: fall down, fall left, stack by color), Flood (4: fill enclosed regions, fill a row or column between two markers), and Tally (3: a bar whose length equals a color's count, recolor based on the count). Each puzzle has 3 example input→output pairs and a test input with its expected output. Grids range from 3x3 to 8x8, and the output size can differ from the input size. UI: the example pairs sit side by side with arrows. Below them, the test input sits next to a blank answer grid that is already the correct output size. There is a 10-color palette where black counts as empty, plus a Copy input button. You paint by click or tap, and by dragging with mouse or touch. There are Reset, Check, Hint, and Prev/Next buttons, a "Puzzle n/15 · Family" label, and a puzzle list with checkmarks. Rules: Check compares the whole grid and briefly flashes the wrong cells on a mismatch. Hint shows the family name and a one-line nudge, and that solve then doesn't count toward the streak. The streak goes up on a first-Check solve with no hint and resets to 0 on a wrong Check. Current and best streak are shown. The best streak and the solved puzzles are saved in localStorage.
Build one self-contained HTML page with no external assets. Content: 15 hardcoded puzzles split into 4 families: Mirror (4: left-right reflection, top-bottom reflection, finish a symmetric shape), Gravity (4: colored cells fall down, fall left, stack by color), Flood (4: fill enclosed regions, fill a row or column between two markers), Tally (3: output a bar whose length equals the count of a color, recolor based on the count). Each puzzle has 3 example input→output pairs and 1 test input with the expected output. Grids range from 3x3 to 8x8, and the output size can differ from the input size. UI: Show the example pairs side by side with arrows. Below them, show the test input next to an editable answer grid that starts blank and is already the correct output size. Add a palette of 10 colors (black counts as empty) and a "Copy input" button. Click or tap a cell to paint it, and click-drag to paint several. Add Reset, Check, Hint, and Next/Prev buttons, plus "Puzzle n/15 · Family". Rules: Check tells you whether the whole grid matches. On a mismatch, briefly flash the wrong cells. Hint reveals the family name plus a one-line nudge, and using it means that solve won't count toward the streak. The streak goes up when you solve on the first Check with no hint and resets to 0 on a wrong Check. Show the current streak and the best streak, and keep the best in localStorage along with which puzzles are solved, shown as checkmarks in a puzzle list. Acceptance: all 15 puzzles can be solved, and their expected answers really follow the rule their examples show. It works with mouse and touch, the layout fits a 375px-wide phone, and you can be playing within 5 seconds of the page loading. The original idea, in the owner's words: “Concept Grid Detective: Look at a few before-and-after grids, figure out the hidden rule, then paint the answer grid yourself. Related puzzles share a concept. Handmade set of about 15 puzzles in concept groups (symmetry, gravity, fill, count). Each has 3 example pairs and a test grid you paint with a color palette. Includes a check button, a hint that names the concept, and a streak counter.”
The spec is clear, so I'm planning this as the first build of the game. It will be one HTML file with 15 handmade puzzles in 4 families: Mirror, Gravity, Flood and Tally. You paint answers with drag support, and it has Check with flashing wrong cells, Hint, a streak counter and saved progress. Each puzzle's expected answer will be checked against its examples' rule, and the layout will be tested at 375px wide. No code has been written yet. Queued for implementation in an isolated workspace. I’ll report the checks and a pull request here.
Implemented in pull request #1. The project build and tests passed in the isolated workspace. I built Rulesmith as a single self-contained page, `dist/index.html` (49.6 KB, no external assets or network requests). `npm run build` and `npm test` both pass: 13 of 13 tests. Nothing is committed; the platform handles that. **What's in it** - **Puzzles:** 15 hardcoded puzzles in `src/puzzles.json`: Mirror 4, Gravity 4, Flood 4 and Tally 3. Each has 3 example pairs plus a test input and its expected output, with grids between 3×3 and 8×8. - The two resizing puzzles are a Mirror puzzle where the output doubles in width, and the Tally "bar" puzzle, whose output is a 3×8 gauge. - The fourth Gravity puzzle has grey shelves that catch falling cells. The second Flood puzzle fills closed grey rooms with the color of a dot inside each one. - **Answer grid:** starts blank at the output size. Click, tap, mouse drag and touch drag all paint with the selected color; right-click paints black. - **Buttons:** 10-color palette (black = empty), Copy input, Reset, Hint, Check, Prev/Next, the "Puzzle n/15 · Family" label, and a puzzle list grouped by family with checkmarks. - **Rules:** - Check compares the whole grid and briefly flashes exactly the wrong cells. - Hint shows the family name and a one-line nudge, and that solve then doesn't count toward the streak. - The streak goes up only on a first-Check solve with no hint, and resets to 0 on any wrong Check. Current and best are both shown. - **Saving:** best streak and solved puzzles are saved to localStorage, and also through `hallway.save` when it exists, since Hallway's frame blocks localStorage. - **Sound:** short synthesized effects (different for paint, check, wrong, hint and navigation) with a mute button. No music. **Two choices of mine to confirm** - Checking a completely blank grid shows "paint it first" and does **not** count as a wrong Check, so a mis-tap can't wipe a streak. If you want the spec followed literally, this is a one-line change. - When the output is a different size, Copy input copies only the part of the input that fits. **How I checked it** - **Puzzle rules:** `tests/rules.mjs` implements each rule separately from the data. The tests require all 45 example outputs and all 15 expected answers to match it, and also check the family counts, grid sizes and that no puzzle is trivial. - **Browser tests** (headless Chromium): - entered every puzzle's expected answer by mouse; each was solved and the streak went from 1 to 15 - after a reload, best = 15 and all checkmarks remained - a wrong Check flashed exactly the mismatched cells and reset the streak - hinted solves and retries didn't add to the streak - Copy input, Reset, Prev/Next wrap-around, click-drag, and tap plus touch-drag on a 375px phone all worked - the first puzzle was playable in under 5 seconds - all 15 puzzles fit with no scrolling at 8 sizes from 360×640 to 1440×900, including a 667×375 landscape phone - **Screenshots I reviewed:** start, mid-game with a hint showing, the wrong-cell flash, the solved state, an 8×8 puzzle and the resized Tally puzzle. Sizes were the three defaults plus 360×640, 375×667, 667×375 and 768×1024. - Those reviews led me to fix the message line wrapping badly, the "Copy input" label being cut off, answer cells too small to tap on small phones, and a clipped title in landscape. - The final hallway-shot run reports no scrolling at any default size. On tall phones there is some empty space around the test grids, because their size is limited by the screen width. The cover image is `/tmp/projex-shots/cover-1440x900.png`: puzzle 7 half-painted, six puzzles solved, streak 5. Verification and merge follow the project’s auto-merge setting. You can follow the pull request in the Code tab.
Auto-merged pull request #1 after a fresh build and test run against the latest main branch. Automatic publishing will follow when enabled and hosting is connected; the live release status appears here.
Published: https://projex.fly.dev/play/project_b3d7eb1f-ac2 — fresh build and tests passed, stored content verified, commit 162e124. This is the platform-built version.
Log in to add to the discussion.