Sailing regatta series scoring with codes, dead heats, redress, discards and tie-breaks
Exact prompt
# Sailing regatta series scoring (low-point system) `input.json` (synthetic) has `entries` (`sail`), `races` (each with `finishes` in finishing order), `discards` ({"min races": discards}), and `penalty_pct`. Write `solve.py` (Python 3 standard library only); `python solve.py input.json answer.json` writes `answer.json` and `results.html`. Fresh series are generated. ## Rules (N = number of entries) 1. A finish item is `{"sail": s}` or `{"sail": [s1, s2, ...]}` (a dead heat), with optional `code` (case-insensitive) and `points`. Sails not in `entries` are ignored. A boat already seen in that race is ignored (only its first item counts). 2. Codes DNC, DNS, OCS, DNF, RET, DSQ, DNE, UFD, BFD score **N + 1** and do **not** take a finishing place (boats behind move up). 3. Other boats take places 1, 2, 3, ... in item order; a dead heat of k boats takes the next k places and each scores their average (e.g. 2.5). 4. ZFP and SCP: place points + round_half_up(N * penalty_pct / 100), capped at N + 1. DPI: place points + `points`, capped at N + 1. 5. RDG with `points`: that score. RDG without `points`: the average of that boat's scores in all other races, excluding its other averaged-RDG races, rounded half-up to 1 decimal; N + 1 if there are none. 6. An entry missing from a race's items scores N + 1 with code DNC. A boat's code for a race is the upper-cased code (`""` if none). 7. Discards: d = the value for the largest key k with races sailed >= k (0 if none). Exclude the boat's d worst scores, never a DNE score; among equal scores exclude the later race first. `total` = sum of all scores; `net` = total - excluded. 8. Ranking: lower net first. Ties: (A8.1) compare each boat's non-excluded scores sorted best to worst, first difference wins; (A8.2) then compare scores in the last race, then the race before, and so on (excluded scores included). Still tied: entry order. ## Visual output: results.html A static, self-contained page (no `<script>`, `<img>`, `<link>`, `<iframe>`/`<object>`/`<embed>`, `on*` handlers, external URLs, CSS url(http)/@import or fetches; renders headless) with `<table id="results">` and one `<tr id="row-<sail>">` per boat, **in rank order**. Layout and styling are not graded. ## answer.json `{"boats": {sail: {"points": [per race], "codes": [per race], "discarded": [0-based race indices, ascending], "total", "net", "rank"}}, "order": [sails in rank order], "discards_applied": d}` ## Scoring Hidden checks (partial credit; all must pass; numbers within 0.001): `codes_and_dnc`, `race_points_incl_ties_penalties`, `discards_and_totals`, `ranking_with_tiebreaks`, `results_html_static` (exists, static rules, ids, row order) on the given series; `fresh_run_1`, `fresh_run_2`. 30-second limit per run.
Each rule is small, but the tests are layered: one place-counting slip changes every later boat's points, discards and the final order. Original benchmark task written for usecaserank.com (not based on a specific public post). Headless, offline run on a reproducible fixture. Each run's notes say how its cost was measured (estimates are marked).
Success criteria: 1. codes_and_dnc 2. race_points_incl_ties_penalties 3. discards_and_totals 4. ranking_with_tiebreaks 5. results_html_static 6. fresh_run_1 7. fresh_run_2
Best model for this task so far: Claude Haiku 5.5 (effort default (no --effort flag) · thinking on) (success, $0.01, 1m).
Latest output per model
All runs (4)
100% pass rate across 4 eligible runs: 4 pass, 0 partial, 0 fail. Partial and failed runs are listed below with everything else.ⓘ
| Model | Cost | Time | Step-insⓘ | Autonomy | Outcome | Trustⓘ | Date | Compare |
|---|---|---|---|---|---|---|---|---|
| OGPT-6.1 Soldefault · thinking on | $0.06 | 56s | 0 | Fully autonomous | pass | Trust 80% | 2026-10-22 | |
| AClaude Haiku 5.5default · thinking on | $0.01 | 1m | 0 | Fully autonomous | pass | Trust 80% | 2026-10-20 | |
| AClaude Opus 5.5default · thinking on | $0.20 | 41s | 0 | Fully autonomous | pass | Trust 80% | 2026-10-20 | |
| AClaude Sonnet 5.5default · thinking on | $0.08 | 37s | 0 | Fully autonomous | pass | Trust 80% | 2026-10-20 |
Embed this result
A live badge for this use case. It links back here and updates as new runs are published.
Get new runs and ranking changes weekly
Which models got better or cheaper on real tasks like this one.