Skip to content

Claude Haiku 5.5 (effort default (no --effort flag) · thinking on) on Multi-window burn-rate alerts from per-minute request counts (integer thresholds, flap smoothing, page-over-ticket priority)

AClaude Haiku 5.5default · thinking on · Claude Code 2.1.299 (headless -p) · cloud · 2026-10-20 · by @bobsiopener

Trust 80%Fully autonomoussuccess · first try
Estimated cost
$0.0059
Wall time
26s
Human step-ins
0
Outcome
Pass

Compare with other models on this task →

Summary

Exact prompt

# Multi-window burn-rate alerts from per-minute request counts `minutes.csv` has one day of per-minute request counts for a service with a **99.9% availability SLO** (error budget 0.001). Write `slo.py` (Python 3 stdlib only) that, run as `python slo.py` in this directory, reads `minutes.csv` and writes `alerts.csv` and `summary.json` following these rules. We re-run it on a freshly generated file, so do not hard-code anything. ## Input cleaning 1. The first line is a header. Each other row must have exactly 3 fields `minute,total,errors`; each field is stripped of spaces and must parse as an integer, otherwise the row is skipped. Rows with a negative value or `errors > total` are skipped. 2. If several valid rows have the same minute, the **last** valid one in the file wins. 3. Minutes run from 0 to M, where M is the largest valid minute. Minutes with no valid row have total = errors = 0. ## Burn rates 4. For minute i and window w (minutes), the window is minutes `max(0, i-w+1) .. i` (shorter at the start of the day). With T and E the sums of total and errors in it, the window is **hot at threshold X** when T > 0 and E / T >= X × 0.001. Compare exactly with integers: `E * 10000 >= (X*10) * T` (X*10 is 144 or 60). 5. A minute is a **page** minute if the 60-minute and the 5-minute windows are both hot at 14.4. It is a **ticket** candidate if the 360-minute and the 30-minute windows are both hot at 6. 6. **Flap smoothing for pages:** for every two page minutes a < b with no page minute between them and b - a equal to 2 or 3 (one or two quiet minutes between), the minutes between become page minutes too. 7. **Pages win:** ticket minutes = ticket candidates that are not page minutes (after rule 6). Then apply the same smoothing as rule 6 to ticket minutes, except a gap is only filled if none of the gap minutes is a page minute. 8. An **alert** is a maximal run of consecutive minutes of the same severity. ## Output 9. `alerts.csv`: header `severity,start,end`, one row per alert, `severity` is `page` or `ticket`, `start`/`end` are the first/last minute (inclusive). Sorted by start (page before ticket on equal start, which cannot normally happen). 10. `summary.json`: an object with `budget_remaining` = `1 - (all errors / all totals) / 0.001` over minutes 0..M rounded to 4 decimals with Python `round` (1.0 if all totals are 0; it can be negative), `page_minutes` and `ticket_minutes` (counts after rules 6-7) and `minutes` = M + 1. ## Scoring Hidden checks (partial credit = fraction passed; all must pass): `page_alerts_exact` and `ticket_alerts_exact` (rows of that severity in `alerts.csv` match exactly), `summary_exact` (all 4 values; `budget_remaining` within 0.00005), then `slo.py` is re-run on a fresh file and `fresh_page_alerts`, `fresh_ticket_alerts`, `fresh_summary` are checked the same way. Each run has a 60-second limit.

Exact alert intervals depend on input cleaning (last valid duplicate wins), short windows at the start, exact integer comparisons, page smoothing, then ticket smoothing that may not bridge page minutes; a fresh-seed rerun blocks hand-editing. 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. page_alerts_exact 2. ticket_alerts_exact 3. summary_exact 4. fresh_page_alerts 5. fresh_ticket_alerts 6. fresh_summary

Setup notes: Use Case Scout batch 8 case i05-slo-burn-rate-alerts (offline fixture). Prepared with batch8/prepare.sh; hidden key/tests kept outside the agent's work dir. Prompt = TASK.md verbatim. Scored with the scout's scorer: `python score.py WORKDIR KEYDIR`. Tools: Read/Write/Edit/Glob/Grep/Bash, web disabled. Single run, no retries. Claude Code's own reported cost for claude-haiku-5.5: $0.005929. Score: 6/6. Cost is an ESTIMATE: measured tokens x pricing.json list price (Claude Pro subscription, nothing billed); input_tokens include cache reads and writes. Single run.

Estimated cost List-price estimate; not actually billed.

Metrics

Estimated cost
$0.0059
Wall time
26s
Human step-ins
0
Turns
4
Model usage
ModelInput tokOutput tokCost
AClaude Haiku 5.5anthropic/claude-haiku-5.5effort default (no --effort flag) · thinking on88,4885,401$0.0059

Reproduce this run

  1. Use the use case prompt on the use case page.
  2. Same setup: Claude Haiku 5.5 (anthropic/claude-haiku-5.5, effort default (no --effort flag) · thinking on) via Claude Code 2.1.299 (headless -p), cloud.
  3. It counts as a success only if it meets every success criterion: 1. page_alerts_exact 2. ticket_alerts_exact 3. summary_exact 4. fresh_page_alerts 5. fresh_ticket_alerts 6. fresh_summary
  4. Log model, tokens, wall time, human step-ins and the evidence log, then submit it as a reproduction. A different model? Submit a head-to-head rerun.

How runs are scored: Methodology.

Was this useful?

⇄ Rerun on another model

Automated checks

Trust 80% comes from these checks (how Trust % works).

Evidence log
[
 {
  "duration_api_ms": 25345,
  "stop_reason": "end_turn",
  "session_id": "[REDACTED]",
  "total_cost_usd": 0.00592899,
  "usage": {
   "input_tokens": 8,
   "cache_creation_input_tokens": 12331,
   "cache_read_input_tokens": 76149,
   "output_tokens": 5401,
   "output_tokens_details": {
    "thinking_tokens": 2277
   },
   "server_tool_use": {
    "web_search_requests": 0,
    "web_fetch_requests": 0
   },
   "service_tier": "standard",
   "cache_creation": {
    "ephemeral_1h_input_tokens": 12331,
    "ephemeral_5m_input_tokens": 0
   },
   "inference_geo": "global",
   "iterations": [
    {
     "input_tokens": 2,
     "output_tokens": 871,
     "cache_read_input_tokens": 23743,
     "cache_creation_input_tokens": 1127,
     "cache_creation": {
      "ephemeral_5m_input_tokens": 0,
      "ephemeral_1h_input_tokens": 1127
     },
     "type": "message"
    }
   ],
   "speed": "standard",
   "fallback_credit": null
  },
  "modelUsage": {
   "claude-haiku-5-5": {
    "inputTokens": 8,
    "outputTokens": 5401,
    "cacheReadInputTokens": 76149,
    "cacheCreationInputTokens": 12331,
    "webSearchRequests": 0,
    "costUSD": 0.00592899,
    "contextWindow": 1000000,
    "maxOutputTokens": 128000,
    "thinkingTokens": 2277,
    "canonicalModel": "claude-haiku-5-5",
    "provider": "firstParty",
    "costBasis": "list"
   }
  },
  "permission_denials": [],
  "terminal_reason": "completed",
  "fast_mode_state": "off",
  "fast_mode_disabled_reason": "sdk_opt_in_required",
  "subagent_stats": {
   "spawned": 0,
   "requested": {
    "background": 0,
    "foreground": 0,
    "unset": 0
   },
   "started_in_background": 0,
   "max_depth": 0,
   "spawned_by_subagents": 0,
   "completed": 0,
   "failed": 0,
   "killed": {
    "parent": 0,
    "user": 0,
    "system": 0
   },
   "refused": {
    "depth_limit": 0,
    "concurrency_limit": 0,
    "budget": 0
   },
   "by_type": {}
  },
  "safety_stops": 0,
  "is_error": false,
  "num_turns": 4,
  "subtype": "success",
  "api_error_status": null,
  "result": "I wrote `slo.py` in the work directory and ran it on the current `minutes.csv`. It produces `alerts.csv` and `summary.json`. I checked the output by running it, not against an independent implementation, so the hidden checks are the real test.\n\nCurrent results:\n- `summary.json`: `budget_remaining` -9.1657, `page_minutes` 66, `ticket_minutes` 363, `minutes` 1440.\n- `alerts.csv`: 13 alerts (5 page, 7 ticket, plus one more ticket run I didn't count separately), sorted by start.\n\nThe script uses only the standard library, computes window sums with prefix sums so it runs in linear time, and does not hard-code any values.\n\nChoices I made where the spec was open:\n- **Parsing:** fields are stripped and parsed with `int()`, so forms like `+5` are accepted. A line with the wrong field count, a parse failure, a negative value, or `errors > total` is skipped.\n- **No valid rows:** `minutes` is 0 and `budget_remaining` is 1.0.\n- **Rule 6 and 7 gaps:** gaps are computed between consecutive members of the set as it stood before that smoothing step, so the page smoothing does not chain into new gaps.",
  "ttft_ms": 1905,
  "type": "result",
  "duration_ms": 25755,
  "uuid": "[REDACTED]",
  "ttft_stream_ms": 1689,
  "time_to_request_ms": 270,
  "first_content_frame_ms": 1690,
  "queued_turn_count": 0,
  "result_index": 0
 }
]

Get new runs and ranking changes weekly