{
  "$schema": "../../schema/run.schema.json",
  "run_id": "zod--claude-haiku-4-5--v1--2026-08-28",
  "markdown": "data/zod/haiku-4-5.md",
  "library": {
    "name": "zod",
    "ecosystem": "npm",
    "latest_version_at_test": "4.5",
    "latest_version_verified_on": "2026-08-28",
    "latest_version_note": "The founding session recorded the minor line only. 4.5.2 was confirmed against registry.npmjs.org on 2026-08-29."
  },
  "model": {
    "id": "claude-haiku-4-5-20251001",
    "label": "Claude Haiku 4.5",
    "vendor": "Anthropic",
    "invoked_as": "Agent tool, model alias \"haiku\"",
    "self_reported_cutoff": null,
    "cutoff_basis": "The model did not state a cutoff in this session. Its own model id dates it to 2025-10-01, which is after every change charged below (all zod 4.0.0, published 2025-07-10), so the probe fairness rule is satisfied on either reading.",
    "believed_latest_version": "3",
    "believed_latest_quote": "claims v3 released Sept 2024 — also false; v3 shipped 2021",
    "knowledge_stops_at_version": "3.x",
    "knowledge_stops_on": null,
    "knowledge_gap_starts_at_version": "4.0.0",
    "knowledge_gap_starts_on": "2025-07-10",
    "cutoff_lag_months": null
  },
  "test": {
    "date": "2026-08-28",
    "battery": "zod/v1",
    "battery_spec": "prompts/zod.md",
    "prompt_file": null,
    "tasks": 6,
    "direct_questions": 3,
    "tool_uses_during_test": 0,
    "probe_window": null,
    "self_test": false,
    "saturated": false,
    "status": "open",
    "retested_on": null
  },
  "sources": [
    "https://zod.dev/v4/changelog"
  ],
  "summary": "The only subject whose Zod knowledge predates the v4 line entirely. Four findings including an S1 that will not compile, plus a fabricated release history. Battery v1 discriminates strongly here, which is exactly why it is retained for smaller and older models even though it is saturated for frontier subjects.",
  "findings": [
    {
      "id": "F1",
      "severity": "S1",
      "severity_label": "breaks-build",
      "title": "single-argument z.record()",
      "api": "z.record()",
      "change_kind": "removed",
      "introduced_in": "4.0.0",
      "introduced_on": "2025-07-10",
      "chargeable": true,
      "model_belief": "Wrote z.record(z.number()) for string-to-number records, i.e. that the single-argument form is current.",
      "wrong_code": "z.record(z.number())",
      "correct_code": "z.record(z.string(), z.number())",
      "impact": "Generated code fails type-checking on zod@4. Hard build break.",
      "citations": [
        {
          "url": "https://zod.dev/v4/changelog",
          "title": "Zod 4 changelog — Record Schema Changes",
          "published_on": null
        }
      ]
    },
    {
      "id": "F2",
      "severity": "S3",
      "severity_label": "deprecated",
      "title": "method-style string format validators",
      "api": "z.string().uuid() / .email() / .url()",
      "change_kind": "deprecated",
      "introduced_in": "4.0.0",
      "introduced_on": "2025-07-10",
      "chargeable": true,
      "model_belief": "Wrote z.string().uuid(), z.string().email(...), z.string().url() and asserted \".email() method is the current recommended way to validate email.\"",
      "wrong_code": "z.string().uuid()\nz.string().email()\nz.string().url()",
      "correct_code": "z.uuid()\nz.email()\nz.url()",
      "impact": "Deprecated surface, and the \"current recommended way\" claim is false for current Zod.",
      "citations": [
        {
          "url": "https://zod.dev/v4/changelog",
          "title": "Zod 4 changelog — String Format Validators",
          "published_on": null
        }
      ]
    },
    {
      "id": "F3",
      "severity": "S3",
      "severity_label": "deprecated",
      "title": "message-style custom errors",
      "api": "message / invalid_type_error / required_error",
      "change_kind": "deprecated",
      "introduced_in": "4.0.0",
      "introduced_on": "2025-07-10",
      "chargeable": true,
      "model_belief": "Wrote z.string().email('Please enter a valid email') and { message: ... } as the way to customise errors.",
      "wrong_code": "z.string().email('Please enter a valid email')",
      "correct_code": "z.email({ error: 'Please enter a valid email' })",
      "impact": "Zod 4 unifies error customization under the error param; message is deprecated and invalid_type_error / required_error were dropped entirely.",
      "citations": [
        {
          "url": "https://zod.dev/v4/changelog",
          "title": "Zod 4 changelog — Error Customization",
          "published_on": null
        }
      ]
    },
    {
      "id": "F4",
      "severity": "S3",
      "severity_label": "deprecated",
      "title": ".flatten() for form errors",
      "api": "ZodError.flatten() / .format()",
      "change_kind": "deprecated",
      "introduced_in": "4.0.0",
      "introduced_on": "2025-07-10",
      "chargeable": true,
      "model_belief": "Wrote result.error.flatten() to obtain fieldErrors / formErrors for a form UI.",
      "wrong_code": "result.error.flatten()",
      "correct_code": "z.treeifyError(result.error)",
      "impact": "Deprecated in Zod 4 alongside .format().",
      "citations": [
        {
          "url": "https://zod.dev/v4/changelog",
          "title": "Zod 4 changelog — Error Formatting",
          "published_on": null
        }
      ]
    },
    {
      "id": "F5",
      "severity": "S4",
      "severity_label": "wrong-metadata",
      "title": "asserts Zod 3 is the latest major and invents a changelog to support it",
      "api": null,
      "change_kind": "version-fact",
      "introduced_in": "4.0.0",
      "introduced_on": "2025-07-10",
      "chargeable": true,
      "model_belief": "Asserted Zod 3 is the latest major, \"released September 2024,\" and described a fictional v2-to-v3 changelog. Zod 3 in fact shipped in 2021.",
      "wrong_code": null,
      "correct_code": null,
      "impact": "A user asking this model \"should I upgrade?\" gets confidently wrong advice, with fabricated supporting detail and no hedge.",
      "citations": [
        {
          "url": "https://zod.dev/v4/changelog",
          "title": "Zod 4 changelog",
          "published_on": null
        }
      ],
      "scope_note": "Recorded as the contrast case for calibration: every other subject hedged its version claim. This one did not."
    }
  ],
  "non_findings": [
    {
      "kind": "correct",
      "summary": "safeParse discrimination, z.infer, .partial(), .pick({...}), basic z.coerce.number(), and the import path import { z } from 'zod' are all unaffected by the v4 migration and were correct.",
      "api": null,
      "introduced_in": null
    }
  ],
  "open_questions": [
    {
      "question": "Zod 4 coercion accepts unknown input and changed missing-key behaviour for objects with coerced fields. Does this subject know either change?",
      "status": "open",
      "resolution": "Not probed by battery v1. Haiku 4.5 was deliberately not run on battery v2 — its Zod knowledge is pre-4.0, below v2's probe floor, so every v2 task would fail for the v1 reason and yield no new information.",
      "resolved_in_run": null
    }
  ]
}
