{"data":{"kind":"file","path":"README.md","version_id":"h51x07dmlr8m93os8766rscx","entry":{"name":"README.md","path":"README.md","is_directory":false,"size":2009,"modified_at":"2026-08-18T13:55:56.727000","content_hash":"3dfc250b7d8372a7d0f5040836a97675b1a5b1f34f221d32230a6f8403afb241"},"entries":[],"content":"# Carcassonne Tile-Laying Agent\n\nEvaluate LLM agents on Carcassonne board game tile placement decisions.\n\n## Overview\n\nThis environment tests an agent's ability to:\n- **Analyze board states** — read terrain types (city, road, field) on placed tiles\n- **Validate placements** — ensure terrain sides match adjacent tiles\n- **Optimize scoring** — choose placements that maximize points\n- **Apply rotation** — orient tiles to match surrounding terrain\n- **Reason strategically** — consider city completion, road connectivity, meeple placement\n\n## Task Format\n\nEach task presents:\n1. A partial Carcassonne board with 3-6 tiles already placed\n2. A hand tile to place on one of the available open positions\n3. The agent must choose position (row, col) and rotation (0/90/180/270 degrees)\n\n## Reward Functions (4 metrics, weighted)\n\n| Weight | Metric | Description |\n|--------|--------|-------------|\n| 0.35 | `placement_validity` | Is the chosen position + rotation a legal move? |\n| 0.30 | `scoring_quality` | How does the claimed score compare to optimal? |\n| 0.20 | `reasoning_quality` | Does the agent discuss terrain matching, strategy, rotation? |\n| 0.15 | `format_compliance` | Does the response include coordinates, rotation, and a decision? |\n\n## Game Mechanics\n\n- **Tile types**: City Cap, Road End, Field, City Edge, City+Road, City Opposite, Road Straight, Road Bend, T-Junction, City+Road Cap\n- **Terrain matching**: Adjacent tile sides must have the same terrain type\n- **Scoring**: Cities = 2pts, Roads = 1pt, matching sides = bonus, connectivity bonus\n\n## Usage\n\n```python\nimport verifiers as vf\n\nenv = vf.load_environment(\"realm/carcassonne-tile-laying-agent\")\n# or with custom params:\nenv = vf.load_environment(\"realm/carcassonne-tile-laying-agent\", n_samples=100, seed=123)\n```\n\n## Parameters\n\n| Parameter | Default | Description |\n|-----------|---------|-------------|\n| `n_samples` | 50 | Number of puzzle instances |\n| `seed` | 42 | Random seed for reproducibility |\n\n## License\n\nMIT\n","encoding":"utf-8","truncated":false,"total_bytes":2009},"status":null}