diff --git a/.github/workflows/fuzz-smoke.yml b/.github/workflows/fuzz-smoke.yml new file mode 100644 index 0000000..d414793 --- /dev/null +++ b/.github/workflows/fuzz-smoke.yml @@ -0,0 +1,31 @@ +name: fuzz-smoke + +on: + pull_request: + paths: + - scripts/fuzz/** + workflow_dispatch: + +jobs: + smoke: + name: Seeded differential-fuzz smoke (ruby + ts) + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v7 + - name: Set up Ruby + uses: ruby/setup-ruby@v1 + with: + ruby-version: "3.4" + - name: Checkout interscript-ruby + run: git clone --depth=1 https://github.com/interscript/interscript-ruby.git ../interscript-ruby + - name: Install parser dependency + run: gem install parsanol + - uses: actions/setup-node@v7 + with: + node-version: "22" + - name: Checkout + build interscript-ts + run: | + git clone --depth=1 --branch main https://github.com/interscript/interscript-ts.git ../interscript-ts + cd ../interscript-ts && npm ci && npm run build + - name: Run seeded smoke corpus + run: node scripts/fuzz/smoke.mjs --runtimes ruby,ts --jobs 4 diff --git a/scripts/fuzz/README.md b/scripts/fuzz/README.md new file mode 100644 index 0000000..8849520 --- /dev/null +++ b/scripts/fuzz/README.md @@ -0,0 +1,85 @@ +# ISC differential fuzz harness (WO20 — maps#284) + +Differential fuzzing across the four ISC parsers (ruby, ts, py, rs): throw +mutated/generated `.isc` at every runtime, hunt crashes, hangs, and +cross-runtime divergences the curated corpus cannot surface. + +## Layout + +| file | role | +|---|---| +| `generate.mjs` | case generator: corpus mutation + grammar-aware templates | +| `run.mjs` | campaign runner: per-case, per-runtime drivers with timeouts | +| `classify.mjs` | finding classifier: crash / hang / divergence + known-kind filter | +| `minimize.mjs` | finding minimizer (delta-debugging shrink + repro proof) | +| `smoke.mjs` | CI-able seeded smoke mode over committed `smoke-cases/` | +| `drivers/` | one driver per runtime, uniform JSON contract | +| `smoke-cases/` | committed seeded corpus (~200 cases), must stay green | +| `TRIAGE.md` | campaign triage report (findings + minimized repros) | + +## Runtime locations + +Drivers locate the runtime trees via environment variables; defaults assume +the runtime repos are checked out as siblings of the maps clone: + +| runtime | env var | default (from repo root) | +|---|---|---| +| ruby | `RUBY_LIB` | `../interscript-ruby/lib` | +| ts | `TS_DIST` | `../interscript-ts/dist` (after `npm run build`) | +| py | `PY_SRC` | `../interscript-py/src` | +| rs | `ISCRS_BIN` | `../interscript-rs/target/release/iscrs` | + +Missing runtimes are skipped by smoke mode (maps-CI runs ruby + ts) and can +be excluded from campaigns with `--runtimes`. + +## Driver contract + +`driver- ` prints one JSON line: + +```json +{"runtime":"ruby","parse":{"status":"OK"},"exec":[{"input":"ab","status":"OK","output":"..."}]} +``` + +Parse leg = the runtime's canonical `.isc` parse entry (ruby: the DSL load +path `Interscript.parse`; ts: `parseIsc -> expandDocument -> iscToCompiledMap +-> normaliseMap`; py: `interscript.isc.isc_to_tree` (origin/main 0.2.x); +rs: `iscrs parse --maps`). Exec leg = main stage over the case's own test +inputs (up to 3, extracted from the `tests { }` block; fallback `"ab"`). + +Error buckets are normalized across runtimes: `OK PARSE LOAD LOGIC +UNSUPPORTED CRASH TIMEOUT OTHER`. A driver exiting nonzero without JSON is +recorded as a process-level crash; exceeding the runner timeout is a hang. + +Harness-boundary normalization: cases may contain invalid UTF-8 (byte-flip +mutations); the runner substitutes U+FFFD for every runtime identically, so +the parsers — not the file APIs — are under test. + +## Known-kind filter + +Divergences documented in `docs/parity/README.md` (audit items G1–G12, plus +the env-dependent ML funcall battery rows) are design facts, not findings. +The classifier detects their signatures on case content (`capture/ref` in +parallel blocks, unresolved aliases, missing main stage, `use` inside +blocks, fn-literal keywords, duplicate rulesets, ruleset cycles, ML +funcalls) and classifies those cases as `known`. Everything else is a +FINDING. Findings carry their evidence; each one is re-audited against the +parity docs before it becomes an issue. + +## Usage + +```sh +# campaign (from this dir) +node generate.mjs --out /tmp/fuzz-run --seed 1234 --mutation 1200 --grammar 400 +RUBY_LIB=... TS_DIST=... PY_SRC=... ISCRS_BIN=... \ + node run.mjs --cases /tmp/fuzz-run/cases --out /tmp/fuzz-run/results.jsonl --jobs 6 +node classify.mjs --results /tmp/fuzz-run/results.jsonl --cases /tmp/fuzz-run/cases \ + --out /tmp/fuzz-run/findings.jsonl --summary /tmp/fuzz-run/summary.md +node minimize.mjs --findings /tmp/fuzz-run/findings.jsonl --cases /tmp/fuzz-run/cases \ + --out-dir /tmp/fuzz-run/min + +# CI-able smoke (committed cases; green required) +node smoke.mjs --runtimes ruby,ts +``` + +Rules of the campaign (issue #284): findings get minimized and documented; +parser bugs are NOT fixed here — fix issues get filed and sequenced. diff --git a/scripts/fuzz/TRIAGE.md b/scripts/fuzz/TRIAGE.md new file mode 100644 index 0000000..eb48ed5 --- /dev/null +++ b/scripts/fuzz/TRIAGE.md @@ -0,0 +1,82 @@ +# WO20 differential fuzz campaign — triage report + +Campaign: 2026-11-17, branch `wo20-fuzz`, maps#284. +Harness: `scripts/fuzz/` (generator + runner + classifier + minimizer). + +## Runtimes under test + +| runtime | tree | note | +|---|---|---| +| ruby | interscript-ruby origin/main (4c47eb5, v3.7.2) | fresh clone; DSL parse path | +| ts | interscript-ts origin/main (b74cfda, dist built) | fresh clone; production parse chain | +| py | interscript-py origin/main (c6ae457, 0.2.x, PYTHONPATH=src) | fresh clone; new handwritten parser | +| rs | interscript-rs release 0.3.2 (74b4b8d) | built against crates.io parsanol ^1.5.1 | + +Note: rs origin/main (94c5f28) does not build standalone — its `Cargo.toml` +path-pins a maintainer-local parsanol tree carrying unreleased APIs +(`array_item`/`hash_item`); crates.io parsanol 1.5.1 lacks them. The +campaign therefore used the released 0.3.2 commit, which is what the +publish pipeline verifies (path→version rewrite, see rs +`.github/workflows/publish.yml`). The two post-0.3.2 commits are a perf +change and a golden-rows refresh; parse semantics unchanged. + +Note: docs/parity audits the WF1-tree py (0.1.0 portable grammar); the +campaign's py is origin/main 0.2.x (new handwritten parser + regex +engine) — the current canonical per the task statement +(PYTHONPATH=interscript-py/src). Several parity-era known kinds behave +differently there; classification used case-content signatures, not +per-runtime behavior. + +## Campaign + +- Cases: 1600 (1200 corpus-mutation, 400 grammar-aware), seed 20261117. +- Observations: 6400 (4 runtimes × 1600), per-case timeout 45 s. +- Outcomes: agree 1007, known-kind 268, FINDINGS 325 (cases with at least + one unexplained crash/hang/divergence). +- Finding kinds (case-level, non-exclusive): divergence 315, crash 167, + hang 10. By primarily-offending runtime: py 118, ruby 29, ts 15, rs 15. +- The 325 findings cluster into 16 behavior-shape groups, which reduce to + 7 root causes / filed issues below. The long tail (bucket-level error + class differences on shared rejections, e.g. py naming + `UnsupportedConstruct` where others raise PARSE errors) is consistent + with the G9 documented family on the new py and is not separately filed. + +## Filed issues + +| # | repo | kind | root cause | campaign evidence | repro | +|---|---|---|---|---|---| +| [interscript-py#43](https://github.com/interscript/interscript-py/issues/43) | py | hang | parse infinite loop on truncated maps (`_stage`/`_block_items`) | 10 cases (all TIMEOUTs are py) | `findings/py-parse-hang/map.isc` (10 lines) | +| [interscript-py#44](https://github.com/interscript/interscript-py/issues/44) | py | crash | malformed/unsupported `\u` escapes raise raw `ValueError` not `IscParseError` (fires on note text too) | 107 cases (largest class) | `findings/py-malformed-escape-crash/map.isc` | +| [interscript-ruby#864](https://github.com/interscript/interscript-ruby/issues/864) | ruby | crash | `NameError: uninitialized constant Node::Item::CaptureRef` on `ref(N)` in from position | 14 cases | `findings/ruby-ref-in-from-crash/map.isc` | +| [maps#292](https://github.com/interscript/maps/issues/292) | ruby vs others | divergence | `alias = maybe(...)` miscompiled — rule silently never fires | 52 cases | `findings/ruby-alias-maybe-silent/map.isc` | +| [maps#293](https://github.com/interscript/maps/issues/293) | py vs others | divergence | py 0.2.x parse boundary differs in both directions (accepts nested blocks/unknown keywords; rejects zero-width primitives in from) | ~130 cases | `findings/py-nested-block-acceptance/map.isc`, `findings/py-zero-width-reject/map.isc` | +| [maps#294](https://github.com/interscript/maps/issues/294) | all four | divergence+crash | self-recursive `run stage.`: rs SIGABRT, ruby/ts stack-overflow crashes, py named guard | 15 cases | `findings/self-run-recursion/map.isc` | +| [maps#295](https://github.com/interscript/maps/issues/295) | py | divergence | note-text `{` corrupts py parse → wrong output; py silently succeeds where others raise MapLogicError | 2 cases | `findings/py-note-brace-corruption/map.isc` | + +## Smoke mode + +`smoke-cases/` holds 199 committed cases (seed 20261120, 420-case pool, +agree-or-known survivors; one py-hang case swapped after the classifier's +hang-filter fix). `node smoke.mjs` is green across all four runtimes +locally (agree 155 / known 44 / findings 0) and across ruby+ts in +maps-CI (`.github/workflows/fuzz-smoke.yml`). + +## Known-kind filter notes + +Classification excludes docs/parity G1–G12 signatures (capture-in-parallel, +unresolved-alias empty matcher, missing main stage, use-in-blocks, +fn-literal keywords, duplicate rulesets, ruleset cycles, ML funcalls, +dependency loader asymmetry). Two harness-level normalizations: invalid +UTF-8 is replaced with U+FFFD identically for all four runtimes (the +parsers, not the file APIs, are under test); dependency-bearing cases +never see their dependency document (isolated per-case dirs), so loader +asymmetry (G12) is filtered. + +## Generator changes made during triage + +- `\u{...}` braced literals replaced with grammar-valid `\uXXXX` / `\U` forms + in `generate.mjs` (the braced form rejects 4/4 and was undiscoverable as + divergence; the escape-edge mutation family still exercises malformed + escapes deliberately). +- Constraint templates corrected to the probe-verified `not_before "x"` bare + form (an early draft emitted `before not_before("j")`). diff --git a/scripts/fuzz/classify.mjs b/scripts/fuzz/classify.mjs new file mode 100644 index 0000000..cb58321 --- /dev/null +++ b/scripts/fuzz/classify.mjs @@ -0,0 +1,382 @@ +// Finding classifier for the ISC differential fuzz harness (WO20, maps#284). +// +// Reads a results.jsonl produced by run.mjs, groups observations by case, +// and emits findings classified as: +// crash — any runtime hit the CRASH bucket (parse or exec) or died +// at the process level, not covered by a known-kind signature +// hang — any runtime hit a TIMEOUT +// divergence — cross-runtime mismatch in accept/reject, canonical error +// bucket, or exec output, not covered by a known-kind signature +// +// Known-kind signatures come from docs/parity/README.md (audit G1-G12 plus +// the battery rows); those divergences are documented design facts, not +// findings. Every classification records WHY (kind + signature) so triage +// can re-audit. +// +// Usage: node classify.mjs --results results.jsonl --cases --out findings.jsonl [--summary summary.md] + +import { readFileSync, writeFileSync, readdirSync } from "node:fs"; +import { join } from "node:path"; + +function parseArgs(argv) { + const opts = { results: null, cases: null, out: "findings.jsonl", summary: null }; + for (let i = 0; i < argv.length; i++) { + const a = argv[i]; + if (a === "--results") opts.results = argv[++i]; + else if (a === "--cases") opts.cases = argv[++i]; + else if (a === "--out") opts.out = argv[++i]; + else if (a === "--summary") opts.summary = argv[++i]; + else throw new Error(`unknown flag ${a}`); + } + if (!opts.results || !opts.cases) throw new Error("--results and --cases are required"); + return opts; +} + +// --------------------------------------------------------------------------- +// Known-kind signatures (docs/parity/README.md). Each detector inspects the +// case source and returns a G-number when the case exercises a documented +// design divergence. Signature matching is on case CONTENT, not on which +// runtime did what, so it stays valid as runtimes move. +// --------------------------------------------------------------------------- + +export function knownKind(src) { + const kinds = []; + + // G1 — capture/ref inside parallel blocks (corrupt output ts/py, ruby crash). + if (captureInParallel(src)) kinds.push("G1"); + + // G3 — unresolved alias compiles to empty matcher in ts/py (audit version); + // treated as known regardless of current per-runtime behavior. + if (hasUnresolvedAliasRef(src)) kinds.push("G3"); + + // G4 — missing main stage (ruby accidental crash vs silent no-op vs named). + if (missingMainStage(src)) kinds.push("G4"); + + // G5 — `use` inside sequence/parallel blocks (only rs implements spec 3.2). + if (useInsideBlock(src)) kinds.push("G5"); + + // G6 — fn-literal keyword in from position (three-way). + if (fnLiteralInFrom(src)) kinds.push("G6"); + + // G7 — duplicate ruleset definitions (only py rejects; rs merge semantics). + if (duplicateRuleset(src)) kinds.push("G7"); + + // G8 — fn literals upcase/reverse/strip/swapcase as directives (ruby gap). + if (fnLiteralDirective(src)) kinds.push("G8"); + + // G9 — ruleset cycle error-class surface (all reject; classes differ). + if (looksLikeRulesetCycle(src)) kinds.push("G9"); + + // ML funcalls (rababa/secryst) — env-dependent battery rows (ml-*). + if (/\b(rababa|secryst)\b/.test(src)) kinds.push("ML"); + + // G12 — dependency loader asymmetry: the harness never provides the + // dependency document, so dependency-bearing cases exercise the + // documented loader-surface differences (ruby/rs reject at load, ts at + // expansion, py folds at parse), not new divergences. + if (hasDependencyDecl(src)) kinds.push("G12"); + + return kinds; +} + +function hasDependencyDecl(src) { + return /^dependency\s+/m.test(src); +} + +function captureInParallel(src) { + const lines = src.split("\n"); + let depth = 0; + let inParallel = 0; + for (const line of lines) { + const t = line.trim(); + if (t === "parallel {") inParallel += 1; + else if (t === "}" && inParallel > 0 && depth === 0) inParallel -= 1; + if (inParallel > 0 && /\b(capture|ref)\s*\(/.test(t)) return true; + // crude brace depth tracking for nested blocks inside parallel + for (const ch of t) { + if (ch === "{") depth += 1; + else if (ch === "}") depth = Math.max(0, depth - 1); + } + } + return false; +} + +function aliasDecls(src) { + const names = new Set(); + // alias declarations live in `aliases { name = expr }` blocks + let inAliases = false; + for (const line of src.split("\n")) { + const t = line.trim(); + if (t === "aliases {") { inAliases = true; continue; } + if (inAliases && t === "}") { inAliases = false; continue; } + if (inAliases) { + const m = t.match(/^([A-Za-z_][A-Za-z0-9_]*)\s*=/); + if (m) names.add(m[1]); + } + } + return names; +} + +const FN_KEYWORDS = new Set(["upcase", "downcase", "title_case", "reverse", "strip", "swapcase"]); + +function hasUnresolvedAliasRef(src) { + const decls = aliasDecls(src); + for (const line of src.split("\n")) { + const m = line.trim().match(/^sub\s+([A-Za-z_][A-Za-z0-9_]*)\s+(?:"|ref\(|\{)/); + if (!m) continue; + const name = m[1]; + if (FN_KEYWORDS.has(name)) continue; // fn literal (G6), not an alias + if (!decls.has(name)) return true; + } + return false; +} + +function stageDecls(src) { + const names = []; + for (const line of src.split("\n")) { + const m = line.trim().match(/^stage\s+([A-Za-z_][A-Za-z0-9_]*)/); + if (m) names.push(m[1]); + } + return names; +} + +function missingMainStage(src) { + const stages = stageDecls(src); + if (stages.length === 0) return false; // no stage decls at all — different surface + return !stages.includes("main"); +} + +function useInsideBlock(src) { + const lines = src.split("\n"); + let depth = 0; + for (const line of lines) { + const t = line.trim(); + if (depth > 0 && /^use\s+[A-Za-z_]/.test(t)) return true; + for (const ch of t) { + if (ch === "{") depth += 1; + else if (ch === "}") depth = Math.max(0, depth - 1); + } + } + return false; +} + +function fnLiteralInFrom(src) { + return /^\s*sub\s+(upcase|downcase|title_case|reverse|strip|swapcase)(\s|$)/m.test(src); +} + +function fnLiteralDirective(src) { + const lines = src.split("\n"); + for (const line of lines) { + const t = line.trim(); + if (/^(upcase|reverse|strip|swapcase)(\s|$)/.test(t) && !/^sub\b/.test(t) && !t.startsWith("#")) return true; + // to-funcall position: `sub "a" ` + if (/^sub\s+"(?:[^"\\]|\\.)*"\s+(upcase|reverse|strip|swapcase)(\s|$)/.test(t)) return true; + } + return false; +} + +function duplicateRuleset(src) { + const seen = new Map(); + for (const line of src.split("\n")) { + const m = line.trim().match(/^ruleset\s+([A-Za-z_][A-Za-z0-9_]*)/); + if (!m) continue; + seen.set(m[1], (seen.get(m[1]) || 0) + 1); + } + for (const n of seen.values()) if (n > 1) return true; + return false; +} + +function looksLikeRulesetCycle(src) { + // ruleset X whose body uses X (self), or use chain a->b->a — the corpus + // cases we generate are small; self-use is the common mutation artifact. + const uses = new Map(); + let current = null; + for (const line of src.split("\n")) { + const decl = line.trim().match(/^ruleset\s+([A-Za-z_][A-Za-z0-9_]*)/); + if (decl) { current = decl[1]; uses.set(current, []); continue; } + if (current === null) continue; + const use = line.trim().match(/^stage\b/); + if (use) { current = null; continue; } + const u = line.trim().match(/^use\s+([A-Za-z_][A-Za-z0-9_]*)/); + if (u && !/override/.test(line)) uses.get(current)?.push(u[1]); + } + for (const [from, tos] of uses) { + for (const to of tos) { + if (uses.has(to) && uses.get(to).includes(from)) return true; + if (to === from) return true; + } + } + return false; +} + +// --------------------------------------------------------------------------- +// Comparison +// --------------------------------------------------------------------------- + +function execSignature(obs) { + if (!obs.exec || obs.exec.length === 0) return "no-exec"; + return obs.exec + .map((e) => (e.status === "OK" ? `OK:${JSON.stringify(e.output)}` : `ERR:${e.bucket}`)) + .join("|"); +} + +function compareCase(observations, kinds) { + const oks = observations.filter((o) => o.status === "OK"); + const findings = []; + + for (const o of observations) { + if (o.status === "TIMEOUT") findings.push({ kind: "hang", runtime: o.runtime, detail: "driver exceeded per-case timeout" }); + if (o.status === "CRASH") { + findings.push({ + kind: "crash", + runtime: o.runtime, + detail: `process-level crash: exit=${o.exitCode} signal=${o.signal || ""} ${o.stderr || ""}`.slice(0, 400), + }); + } + if (o.status === "OK") { + for (const leg of ["parse", ...(o.exec || [])]) { + const shape = leg === "parse" ? o.parse : leg; + if (shape && shape.bucket === "CRASH") { + findings.push({ + kind: "crash", + runtime: o.runtime, + detail: `${leg === "parse" ? "parse" : `exec(${shape.input})`} CRASH bucket: ${shape.class}: ${shape.message}`.slice(0, 400), + }); + } + if (shape && shape.bucket === "TIMEOUT") { + findings.push({ kind: "hang", runtime: o.runtime, detail: `${leg === "parse" ? "parse" : `exec(${shape.input})`} TIMEOUT`.slice(0, 400) }); + } + } + } + } + + // Cross-runtime comparison (only meaningful with >=2 usable observations). + if (oks.length >= 2) { + const parseShapes = oks.map((o) => ({ rt: o.runtime, s: o.parse })); + const statuses = new Set(parseShapes.map((p) => p.s?.status)); + if (statuses.size > 1) { + findings.push({ + kind: "divergence", + runtime: "*", + detail: `accept/reject differs: ${parseShapes.map((p) => `${p.rt}=${p.s?.status}(${p.s?.bucket})`).join(" ")}`, + }); + } else if (oks.every((o) => o.parse?.status === "OK")) { + const buckets = new Set(oks.map((o) => execSignature(o))); + if (buckets.size > 1) { + const detail = oks.map((o) => `${o.runtime}: ${execSignature(o).slice(0, 150)}`).join(" || "); + findings.push({ kind: "divergence", runtime: "*", detail: `exec/parse-output differs: ${detail}`.slice(0, 500) }); + } + } else { + // all reject: bucket agreement required (error-class divergence) + const buck = new Set(parseShapes.map((p) => `${p.s?.bucket}`)); + if (buck.size > 1) { + const detail = parseShapes.map((p) => `${p.rt}=${p.s?.bucket}(${p.s?.class})`).join(" "); + findings.push({ kind: "divergence", runtime: "*", detail: `reject-class differs: ${detail}` }); + } + } + } + + // Filter known kinds. Hard failures are NEVER explained by a known kind: + // hangs (any TIMEOUT) and process-level crashes are always findings. + // Only divergences and in-process crash buckets can be explained by a + // documented design divergence (e.g. G1's ruby crash, G11's ArgumentError). + const unexplained = []; + const explained = []; + for (const f of findings) { + const hard = f.kind === "hang" || (f.kind === "crash" && f.detail.startsWith("process-level crash")); + if (!hard && kinds.length > 0) explained.push({ ...f, known: kinds }); + else unexplained.push(f); + } + return { unexplained, explained }; +} + +// --------------------------------------------------------------------------- +// Main +// --------------------------------------------------------------------------- + +export function classify(resultsPath, casesDir) { + const lines = readFileSync(resultsPath, "utf8").split("\n").filter(Boolean); + const byCase = new Map(); + for (const line of lines) { + const obs = JSON.parse(line); + if (!byCase.has(obs.case)) byCase.set(obs.case, []); + byCase.get(obs.case).push(obs); + } + + const findings = []; + const stats = { + cases: byCase.size, + agree: 0, + known: 0, + findings: 0, + byKind: { crash: 0, hang: 0, divergence: 0 }, + byRuntime: {}, + timeouts: 0, + }; + + for (const [caseId, observations] of byCase) { + let src = ""; + try { + src = readFileSync(join(casesDir, caseId, "map.isc"), "utf8"); + } catch { + src = ""; + } + const kinds = knownKind(src); + const { unexplained, explained } = compareCase(observations, kinds); + if (unexplained.length === 0 && explained.length === 0) { + stats.agree += 1; + continue; + } + if (unexplained.length === 0) { + stats.known += 1; + findings.push({ case: caseId, classification: "known", kinds, findings: explained }); + continue; + } + stats.findings += 1; + const kindsSet = new Set(); + for (const f of unexplained) { + stats.byKind[f.kind] = (stats.byKind[f.kind] || 0) + 1; + kindsSet.add(f.kind); + if (f.runtime !== "*") stats.byRuntime[f.runtime] = (stats.byRuntime[f.runtime] || 0) + 1; + } + findings.push({ + case: caseId, + classification: "FINDING", + kinds: [...kindsSet], + findings: unexplained, + alsoKnown: explained.length > 0 ? explained : undefined, + }); + } + + // Timeouts counted regardless of known-status + for (const [, observations] of byCase) { + for (const o of observations) if (o.status === "TIMEOUT") stats.timeouts += 1; + } + return { findings, stats }; +} + +function main() { + const opts = parseArgs(process.argv.slice(2)); + const { findings, stats } = classify(opts.results, opts.cases); + writeFileSync(opts.out, findings.map((f) => JSON.stringify(f)).join("\n") + "\n"); + + const findingList = findings.filter((f) => f.classification === "FINDING"); + console.log(`cases: ${stats.cases} agree: ${stats.agree} known: ${stats.known} FINDINGS: ${stats.findings}`); + console.log(`finding kinds: ${JSON.stringify(stats.byKind)}`); + console.log(`by runtime: ${JSON.stringify(stats.byRuntime)}`); + + if (opts.summary) { + const rows = findingList + .map((f) => `| ${f.case} | ${f.kinds.join(",")} | ${f.findings.map((x) => `${x.kind}[${x.runtime}]`).join(", ")} | ${f.findings[0].detail.slice(0, 120).replace(/\|/g, "\\|")} |`) + .join("\n"); + const head = `# Fuzz triage (results=${opts.results})\n\ncases ${stats.cases} | agree ${stats.agree} | known ${stats.known} | findings ${stats.findings}\n\nkinds: ${JSON.stringify(stats.byKind)}\n\n| case | finding kinds | evidence | detail |\n|---|---|---|---|\n${rows}\n`; + writeFileSync(opts.summary, head); + } + for (const f of findingList.slice(0, 40)) { + console.log(` ${f.case}: ${f.kinds.join(",")} — ${f.findings.map((x) => x.kind).join(",")}`); + } + if (findingList.length > 40) console.log(` ... and ${findingList.length - 40} more (see ${opts.out})`); +} + +const isMain = process.argv[1] && import.meta.url.endsWith(process.argv[1].split("/").pop()); +if (isMain) main(); diff --git a/scripts/fuzz/drivers/driver-py.py b/scripts/fuzz/drivers/driver-py.py new file mode 100644 index 0000000..6831ff3 --- /dev/null +++ b/scripts/fuzz/drivers/driver-py.py @@ -0,0 +1,91 @@ +#!/usr/bin/env python +"""Fuzz driver (py leg). + +Usage: python3 driver-py.py +Prints a single JSON line: {"runtime": "py", "parse": {...}, "exec": [...]}. + +Parse leg: interscript.isc.isc_to_tree (origin/main 0.2.x architecture). +Exec leg: interscript.engine.Engine#transliterate over the main stage. +The case source is read as bytes and decoded with errors="replace" so +invalid UTF-8 is normalized to U+FFFD exactly like the other legs. +""" + +import json +import os +import sys + +sys.path.insert( + 0, + os.environ.get("PY_SRC") + or os.path.join(os.path.dirname(os.path.abspath(__file__)), "..", "..", "..", "interscript-py", "src"), +) + +from interscript.isc import isc_to_tree, IscParseError, UnsupportedConstruct # noqa: E402 +from interscript.engine import Engine, ExecutionError # noqa: E402 + +CRASH_CLASSES = ( + AttributeError, + KeyError, + IndexError, + RecursionError, + TypeError, + RuntimeError, + NotImplementedError, + ZeroDivisionError, + ValueError, # non-Isc ValueErrors leak internal state (e.g. int() errors) +) + + +def bucket(e: BaseException) -> str: + if isinstance(e, IscParseError): + return "PARSE" + if isinstance(e, UnsupportedConstruct): + return "UNSUPPORTED" + if isinstance(e, ExecutionError): + return "LOGIC" + if isinstance(e, FileNotFoundError): + return "LOAD" + if isinstance(e, CRASH_CLASSES): + return "CRASH" + return "OTHER" + + +def shape(e: BaseException) -> dict: + msg = str(e).splitlines()[0] if str(e) else "" + return { + "status": "ERR", + "class": type(e).__name__, + "bucket": bucket(e), + "message": msg[:200], + } + + +def main() -> int: + case_file = sys.argv[1] + inputs = json.loads(sys.argv[2] if len(sys.argv) > 2 else "[]") + result = {"runtime": "py", "exec": []} + + with open(case_file, "rb") as f: + raw = f.read() + src = raw.decode("utf-8", errors="replace") + + try: + tree = isc_to_tree(src, os.path.basename(case_file)) + result["parse"] = {"status": "OK"} + engine = Engine(tree) + for input_text in inputs: + try: + result["exec"].append( + {"input": input_text, "status": "OK", "output": engine.transliterate(input_text)} + ) + except Exception as e: # every failure shape is data here + result["exec"].append({"input": input_text, **shape(e)}) + except Exception as e: # noqa: BLE001 + result["parse"] = shape(e) + + print(json.dumps(result)) + return 0 + + +if __name__ == "__main__": + raise SystemExit(main()) diff --git a/scripts/fuzz/drivers/driver-rs.mjs b/scripts/fuzz/drivers/driver-rs.mjs new file mode 100644 index 0000000..ae87684 --- /dev/null +++ b/scripts/fuzz/drivers/driver-rs.mjs @@ -0,0 +1,93 @@ +#!/usr/bin/env node +// Fuzz driver (rs leg). Usage: node driver-rs.mjs +// Wraps the iscrs binary: `parse ` for accept/reject (rc stays 0 on +// parse failure — the OK/FAIL line is the signal), `transliterate ... +// --maps ` per input. Panics (exit 101) and signals map to CRASH. +// An internal per-exec kill switch surfaces as bucket TIMEOUT without +// taking the whole driver down. +import { spawnSync } from "node:child_process"; +import { readFileSync } from "node:fs"; +import { basename, dirname, resolve } from "node:path"; + +const ISCRS = process.env.ISCRS_BIN || resolve(import.meta.dirname, "../../../interscript-rs/target/release/iscrs"); +const EXEC_KILL_MS = Number(process.env.FUZZ_RS_EXEC_KILL_MS || 20000); + +function bucketFor(stderr, exitCode, signal) { + // iscrs prefixes errors with "error: " (e.g. "error: map logic error: …") + const s = (stderr || "").replace(/^error: /, ""); + if (/panicked at/.test(stderr || "")) return "CRASH"; + if (signal) return "CRASH"; + if (exitCode === 101 || exitCode === 134 || exitCode === 139) return "CRASH"; + if (s.startsWith("map logic error:")) return "LOGIC"; + if (s.startsWith("dependency cycle:")) return "LOGIC"; + if (s.startsWith("unsupported:")) return "UNSUPPORTED"; + if (/^couldn't locate map/.test(s)) return "LOAD"; + if (s.startsWith("parse failed in") || s.startsWith("FAIL")) return "PARSE"; + return "OTHER"; +} + +function runIscrs(args) { + const res = spawnSync(ISCRS, args, { + timeout: EXEC_KILL_MS, + encoding: "utf8", + maxBuffer: 8 * 1024 * 1024, + killSignal: "SIGKILL", + }); + if (res.error && res.error.code === "ENOENT") { + return { timedOut: false, spawnError: `iscrs binary not found: ${ISCRS}`, stdout: "", stderr: "" }; + } + if (res.error && res.error.code === "ETIMEDOUT") { + return { timedOut: true, stderr: "", stdout: "" }; + } + return { timedOut: false, stdout: res.stdout || "", stderr: res.stderr || "", status: res.status, signal: res.signal }; +} + +const caseFile = process.argv[2]; +const inputs = JSON.parse(process.argv[3] || "[]"); +const stem = basename(caseFile, ".isc"); +const dir = dirname(caseFile); +const result = { runtime: "rs", exec: [] }; + +// Parse leg. `iscrs parse` exits 0 on accept, 1 on reject (FAIL line), and +// crashes with a panic (101/signal) — the output line is the primary signal. +const p = runIscrs(["parse", caseFile, "--maps", dir]); +if (p.spawnError) { + result.parse = { status: "ERR", class: "DriverMisconfig", bucket: "OTHER", message: p.spawnError }; +} else if (p.timedOut) { + result.parse = { status: "ERR", class: "Timeout", bucket: "TIMEOUT", message: "iscrs parse exceeded internal kill switch" }; +} else if (/^OK\b/m.test(p.stdout)) { + result.parse = { status: "OK" }; +} else if (/^FAIL\b/m.test(p.stdout)) { + result.parse = { status: "ERR", class: "ParseError", bucket: "PARSE", message: p.stdout.split("\n")[0].slice(0, 200) }; +} else if ((p.status === 0 || p.status === 1) && !p.signal) { + result.parse = { status: "ERR", class: "ParseError", bucket: "PARSE", message: (p.stderr || p.stdout).split("\n")[0].slice(0, 200) || `parse exit ${p.status}` }; +} else { + result.parse = { + status: "ERR", class: "ProcessCrash", bucket: bucketFor(p.stderr, p.status, p.signal), + message: (p.stderr || `exit ${p.status}`).split("\n")[0].slice(0, 200), + }; +} + +// Exec leg (only when parse accepted). +if (result.parse.status === "OK") { + for (const input of inputs) { + const e = runIscrs(["transliterate", stem, input, "--maps", dir, "--stage", "main"]); + if (e.spawnError) { + result.exec.push({ input, status: "ERR", class: "DriverMisconfig", bucket: "OTHER", message: e.spawnError }); + } else if (e.timedOut) { + result.exec.push({ input, status: "ERR", class: "Timeout", bucket: "TIMEOUT", message: "exec exceeded internal kill switch" }); + } else if (e.status === 0) { + result.exec.push({ input, status: "OK", output: e.stdout.replace(/\n$/, "") }); + } else { + result.exec.push({ + input, + status: "ERR", + class: e.stderr.includes("panicked at") ? "Panic" : "IscrsError", + bucket: bucketFor(e.stderr, e.status, e.signal), + message: (e.stderr || `exit ${e.status}`).split("\n")[0].replace(/^error: /, "").slice(0, 200), + }); + } + } +} + +console.log(JSON.stringify(result)); diff --git a/scripts/fuzz/drivers/driver-ruby.rb b/scripts/fuzz/drivers/driver-ruby.rb new file mode 100644 index 0000000..e7642c9 --- /dev/null +++ b/scripts/fuzz/drivers/driver-ruby.rb @@ -0,0 +1,69 @@ +#!/usr/bin/env ruby +# frozen_string_literal: true +# Fuzz driver (ruby leg). Usage: ruby driver-ruby.rb +# Prints a single JSON line: +# {"runtime":"ruby","parse":{...},"exec":[...],"ms":N} +# +# Parse leg: the .isc DSL load path (Interscript.parse by filename stem), +# the reference entry for ruby. Exec leg: Interscript::Interpreter#call over +# the main stage, per input. Every failure is captured and bucketed; a +# nonzero process exit means the VM itself died (a crash finding). + +require "json" + +$LOAD_PATH.unshift(ENV["RUBY_LIB"] || File.expand_path("../../interscript-ruby/lib", __dir__)) +require "interscript" + +# Bucket map (canonical buckets: OK PARSE LOAD LOGIC UNSUPPORTED CRASH OTHER). +CRASH_CLASSES = %w[ + ArgumentError NoMethodError TypeError NameError KeyError IndexError + RangeError RegexpError FrozenError RuntimeError NotImplementedError + SystemStackError LocalJumpError ZeroDivisionError FloatDomainError + EOFError IOError ScriptError LoadError NoMatchingPatternError +].freeze + +def bucket(e) + name = e.class.name.to_s + case name + when "Interscript::Isc::ParseError" then "PARSE" + when "Interscript::MapNotFoundError" then "LOAD" + when "Interscript::SystemConversionError", + "Interscript::MapLogicError" then "LOGIC" + when "Interscript::ExternalUtilError" then "UNSUPPORTED" + when *CRASH_CLASSES then "CRASH" + else "OTHER" + end +end + +def err_shape(e) + { + status: "ERR", + class: e.class.name.to_s, + bucket: bucket(e), + message: ((e.message || "").lines.first || "").to_s[0, 200], + } +end + +case_file = ARGV[0] +inputs = JSON.parse(ARGV[1] || "[]") +dir = File.dirname(File.expand_path(case_file)) +stem = File.basename(case_file, ".isc") +result = { "runtime" => "ruby" } + +Interscript.load_path.unshift(dir) +begin + Interscript.parse(stem) + result["parse"] = { "status" => "OK" } + interp = Interscript::Interpreter.call(stem) + result["exec"] = inputs.map do |input| + begin + { "input" => input, "status" => "OK", "output" => interp.call(input, :main) } + rescue Exception => e # rubocop:disable Lint/RescueException -- every failure shape is data here + { "input" => input }.merge(err_shape(e)) + end + end +rescue Exception => e # rubocop:disable Lint/RescueException + result["parse"] = err_shape(e) +end + +puts JSON.generate(result) diff --git a/scripts/fuzz/drivers/driver-ts.mjs b/scripts/fuzz/drivers/driver-ts.mjs new file mode 100644 index 0000000..c4ab5c0 --- /dev/null +++ b/scripts/fuzz/drivers/driver-ts.mjs @@ -0,0 +1,74 @@ +#!/usr/bin/env node +// Fuzz driver (ts leg). Usage: node driver-ts.mjs +// Production path: parseIsc -> expandDocument -> iscToCompiledMap -> +// normaliseMap -> executeStage. Single JSON line on stdout, exit 0 unless +// the VM dies (which the runner records as a crash finding). +import { readFileSync } from "node:fs"; +import { basename, dirname, resolve } from "node:path"; + +const TS_DIST = process.env.TS_DIST || resolve(import.meta.dirname, "../../interscript-ts/dist"); +const { parseIsc, iscToCompiledMap, expandDocument } = await import( + `file://${resolve(TS_DIST, "isc/index.js")}` +); +const { normaliseMap } = await import(`file://${resolve(TS_DIST, "loaders.js")}`); +const { executeStage } = await import(`file://${resolve(TS_DIST, "runtime/interpreter.js")}`); + +const CRASH_CLASSES = new Set([ + "TypeError", "RangeError", "ReferenceError", "EvalError", "URIError", +]); + +function bucket(e) { + const name = e && e.name ? e.name : "Error"; + switch (name) { + case "IscParseError": return "PARSE"; + case "IscLoadError": return "LOAD"; + case "MapLogicError": + case "SystemConversionError": + case "DependencyMissingError": return "LOGIC"; + case "MapNotFoundError": return "LOAD"; + default: return CRASH_CLASSES.has(name) ? "CRASH" : "OTHER"; + } +} + +function fail(e) { + return { + status: "ERR", + class: e && e.name ? e.name : "Error", + bucket: bucket(e), + message: String(e && e.message ? e.message : e).split("\n")[0].slice(0, 200), + }; +} + +const caseFile = process.argv[2]; +const inputs = JSON.parse(process.argv[3] || "[]"); +const stem = basename(caseFile, ".isc"); +const dir = dirname(caseFile); +const result = { runtime: "ts", exec: [] }; + +try { + // Harness-boundary normalization: invalid UTF-8 becomes U+FFFD for every + // runtime identically (the runner pre-sanitizes when needed). + const src = readFileSync(caseFile, "utf8"); + const resolver = (code) => { + try { + return parseIsc(readFileSync(`${dir}/${code}.isc`, "utf8"), `${code}.isc`); + } catch { + return undefined; + } + }; + const doc = parseIsc(src, `${stem}.isc`); + const expanded = expandDocument(doc, { resolveDependency: resolver }); + const map = normaliseMap(iscToCompiledMap(expanded)); + result.parse = { status: "OK" }; + for (const input of inputs) { + try { + result.exec.push({ input, status: "OK", output: executeStage(map, "main", input) }); + } catch (e) { + result.exec.push({ input, ...fail(e) }); + } + } +} catch (e) { + result.parse = fail(e); +} + +console.log(JSON.stringify(result)); diff --git a/scripts/fuzz/findings/py-malformed-escape-crash/map.isc b/scripts/fuzz/findings/py-malformed-escape-crash/map.isc new file mode 100644 index 0000000..fc677d8 --- /dev/null +++ b/scripts/fuzz/findings/py-malformed-escape-crash/map.isc @@ -0,0 +1,7 @@ +system "T:fz-em6:1" { + stage main { + sequence { + sub "\u{1F600}" "X" + } + } +} diff --git a/scripts/fuzz/findings/py-nested-block-acceptance/map.isc b/scripts/fuzz/findings/py-nested-block-acceptance/map.isc new file mode 100644 index 0000000..87fc0b3 --- /dev/null +++ b/scripts/fuzz/findings/py-nested-block-acceptance/map.isc @@ -0,0 +1,10 @@ +system "T:fz-em7:1" { + stage main { + sequence { + sub "a" "b" + parallel { + sub "c" "d" + } + } + } +} diff --git a/scripts/fuzz/findings/py-note-brace-corruption/map.isc b/scripts/fuzz/findings/py-note-brace-corruption/map.isc new file mode 100644 index 0000000..5b7b3b1 --- /dev/null +++ b/scripts/fuzz/findings/py-note-brace-corruption/map.isc @@ -0,0 +1,81 @@ +system "DIN:kaa-Cyrl:Latn:1460-2-2011" { + +metadata { + authority_id din + id 1460-2-2011-22 + language iso-639-3:kaa + source_script Cyrl + destination_script Latn + name "DIN 1460-2:2011-10, Tabelle 1 row 22: Karakalpakisch (Turkic)" + url https://www.beuth.de/de/norm/din-1460-2/134564104 + creation_date 2011 + adoption_date + description { + DIN 1460-2:2011-10, Romanization of Cyrillic alphabets of + non-Slavic languages, Tabelle 1, language row 22 + (Karakalpakisch). The table assigns each Cyrillic letter of the + language's alphabet a Latin letter or letter group; the column + order follows DIN 1460:1982 (Slavic). Extracted mechanically from + the standa{d's text layer; the mapping rows below are the table's + own cells. + } + + notes { + note "Extraction provenance: the PDF's text layer carries the full + grid; columns were anchored on the per-page position-number row and + each cell matched by x-coordinate to its Cyrillic header letter. + Position 13's header glyph is PUA (U+E519) in the text layer and + was visually identified at 10x as h with comma below (U+0068 + U+0322), the plain-h counterpart of position 12's hooktop-h symbol." + } +} + +tests { + "a" -> "a" + "б" -> "b" + "в" -> "v" + "г" -> "g" +} + +stage main { + parallel { + sub "a" "a" + sub "б" "b" + sub "в" "v" + sub "г" "g" + sub "ғ" "ġ" + sub "д" "d" + sub "е" "e" + sub "ё" "ё" + sub "ж" "ž" + sub "з" "z" + sub "и" "i" + sub "й" "j" + sub "к" "k" + sub "к̢" "k" + sub "л" "l" + sub "м" "m" + sub "н" "n" + sub "ң" "n" + sub "о" "o" + sub "ө" "ö" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "т" "t" + sub "у" "u" + sub "ў" "ŭ" + sub "ү" "ü" + sub "ф" "f" + sub "х" "h" + sub "ҳ" "ḩ" + sub "ц" "c" + sub "ч" "č" + sub "ш" "š" + sub "щ" "šč" + sub "ъ" "\"" + sub "ы" "y" + sub "ь" "'" + sub "э" "ė" + } +} +} diff --git a/scripts/fuzz/findings/py-parse-hang/map.isc b/scripts/fuzz/findings/py-parse-hang/map.isc new file mode 100644 index 0000000..a1cb7e5 --- /dev/null +++ b/scripts/fuzz/findings/py-parse-hang/map.isc @@ -0,0 +1,10 @@ +system "VAR:hin-Deva:Latn:hunterian-1872" { +metadata { + notes { + } +} +tests { +} +stage main { + sub { + } \ No newline at end of file diff --git a/scripts/fuzz/findings/py-zero-width-reject/map.isc b/scripts/fuzz/findings/py-zero-width-reject/map.isc new file mode 100644 index 0000000..d33f938 --- /dev/null +++ b/scripts/fuzz/findings/py-zero-width-reject/map.isc @@ -0,0 +1,17 @@ +system "FZ:grammar:350509" { + metadata { + authority_id fz + id 2914 + name "grammar-aware fuzz map" + } + stage main { + sequence { + sub { + from word_boundary + capture(some("z")) + word_boundary + to "W" + ref(1) + not_before "j" + not_after "k" + } + } + } +} diff --git a/scripts/fuzz/findings/ruby-alias-maybe-silent/map.isc b/scripts/fuzz/findings/ruby-alias-maybe-silent/map.isc new file mode 100644 index 0000000..da5f77a --- /dev/null +++ b/scripts/fuzz/findings/ruby-alias-maybe-silent/map.isc @@ -0,0 +1,10 @@ +system "T:fz-em5:1" { + aliases { + a_chain = maybe(any(["x", "y", "z"]) + any("1".."3")) + } + stage main { + sequence { + sub a_chain "R" + } + } +} diff --git a/scripts/fuzz/findings/ruby-ref-in-from-crash/map.isc b/scripts/fuzz/findings/ruby-ref-in-from-crash/map.isc new file mode 100644 index 0000000..947cfd2 --- /dev/null +++ b/scripts/fuzz/findings/ruby-ref-in-from-crash/map.isc @@ -0,0 +1,10 @@ +system "T:fz-em8:1" { + stage main { + sequence { + sub { + from some(any(["k", "q"])) + ref(1) + to "W" + ref(1) + } + } + } +} diff --git a/scripts/fuzz/findings/self-run-recursion/map.isc b/scripts/fuzz/findings/self-run-recursion/map.isc new file mode 100644 index 0000000..a4456cc --- /dev/null +++ b/scripts/fuzz/findings/self-run-recursion/map.isc @@ -0,0 +1,8 @@ +system "T:fz-selfrun:1" { + stage main { + parallel { + sub "a" "b" + } + run stage.main + } +} diff --git a/scripts/fuzz/generate.mjs b/scripts/fuzz/generate.mjs new file mode 100644 index 0000000..34a5043 --- /dev/null +++ b/scripts/fuzz/generate.mjs @@ -0,0 +1,404 @@ +// ISC differential-fuzz case generator (WO20, maps#284). +// +// Two families: +// mutation — byte/line/structure mutations over the 428-map corpus: +// truncate, byte-flip, line delete/dup/swap, cross-map rule splices, +// WF-1 construct injection (ruleset/use/override/languages/when, +// targeting the documented G5/G7 surfaces), keyword/fn-literal +// injection (G6/G8), malformed escapes/editions, unicode edge literals. +// grammar — VALID but unusual maps from templates: nested any/capture/ +// maybe, constraint combos, alias chains, duplicate-from blocks, +// unicode edge literals, empty-string rules, self-runs (bounded). +// +// Every case is reproducible: the manifest records seed + index per case. +// Output layout: /cases//map.isc (+ /manifest.json) + +import { writeFileSync, readFileSync } from "node:fs"; +import { join } from "node:path"; +import { makeRng, listCorpus, pickSeedMap, ensureDir } from "./lib.mjs"; + +// --------------------------------------------------------------------------- +// Atom pools (grammar-aware content) +// --------------------------------------------------------------------------- + +const ASCII_STRINGS = ["a", "b", "k", "q", "x", "z", "ab", "kh", "kk", "xy", "1", "3", "-", " ", "."]; +const UNICODE_LITERALS = [ + // valid ISC escapes: \\uXXXX (exactly 4 hex) and \\U+4-8 hex (isc.parg esc_uni4/esc_uni) + "\\u00E9", // é + "\\u0301", // combining acute + "\\u200D", // ZWJ + "\\u200F", // RTL mark + "\\u00A0", // NBSP + "\\U01F600", // emoji (U-form, 4..8 hex) + "\\U10FFFF", // max plane (U-form) + "\\u0646", // arabic noon + "\\u0E01", // thai ko kai + "\\u010C", // D with caron +]; +const ESCAPE_EDGE_CASES = [ + "\\u{110000}", // braced form (not in the grammar) + out of range + "\\uD800", // lone surrogate (valid shape, invalid scalar) + "\\u{}", // empty hex + "\\uZZZZ", // bad hex + "\\x", // incomplete + "\\q", // unknown escape + "\\", // trailing backslash + "\\u00E", // short hex (grammar wants exactly 4) + "\\U01F6", // U-form with 3 hex (grammar wants 4..8) +]; +const FN_KEYWORDS = ["upcase", "downcase", "title_case", "reverse", "strip", "swapcase"]; +const ZERO_WIDTH = ["boundary", "line_start", "line_end", "word_boundary", "space", "non_boundary"]; +const FUNCALL_DIRECTIVES = ["upcase", "downcase", "title_case"]; + +// --------------------------------------------------------------------------- +// Mutation operators +// --------------------------------------------------------------------------- + +function opTruncate(rng, src) { + const frac = 0.05 + rng.next() * 0.85; + const pos = Math.max(1, Math.min(src.length - 1, Math.floor(src.length * frac))); + return src.slice(0, pos); +} + +function opByteFlip(rng, src) { + const buf = Buffer.from(src, "utf8"); + const n = rng.int(1, 8); + for (let i = 0; i < n; i++) { + const pos = rng.int(0, buf.length - 1); + buf[pos] = rng.chance(0.3) ? rng.int(0x00, 0x1f) : rng.int(0x20, 0xff); + } + return buf; // raw bytes preserved (may be invalid UTF-8, by design) +} + +function opLineDelete(rng, src) { + const lines = src.split("\n"); + if (lines.length < 3) return src; + lines.splice(rng.int(0, lines.length - 1), 1); + return lines.join("\n"); +} + +function opLineDuplicate(rng, src) { + const lines = src.split("\n"); + const i = rng.int(0, lines.length - 1); + lines.splice(i, 0, lines[i]); + return lines.join("\n"); +} + +function opLineSwap(rng, src) { + const lines = src.split("\n"); + if (lines.length < 3) return src; + const i = rng.int(0, lines.length - 2); + const j = rng.int(i + 1, Math.min(i + 40, lines.length - 1)); + [lines[i], lines[j]] = [lines[j], lines[i]]; + return lines.join("\n"); +} + +// Extract a random run of rule-ish lines from a donor map and splice it in. +function opSpliceRules(rng, src, donorPool) { + const donor = rng.pick(donorPool); + const lines = donor.text.split("\n"); + const ruleIdx = []; + lines.forEach((l, i) => { + if (/^\s*(sub|use|parallel|sequence|stage)\b/.test(l)) ruleIdx.push(i); + }); + if (ruleIdx.length === 0) return src; + const start = rng.pick(ruleIdx); + const count = rng.int(1, Math.min(15, lines.length - start)); + const block = lines.slice(start, start + count).join("\n"); + const target = src.split("\n"); + const at = rng.int(1, Math.max(1, target.length - 1)); + target.splice(at, 0, block); + return target.join("\n"); +} + +// WF-1 construct injection (ruleset/use/override/languages/when). +function opInjectWF1(rng, src) { + const snippets = [ + // stage-level use of a declared ruleset + ` ruleset fr${rng.int(0, 9)} {\n parallel { sub "a" "b" }\n }`, + // use inside a block (G5 surface) + ` sequence {\n sub "x" "y"\n use inner${rng.int(0, 9)}\n }`, + // duplicate ruleset declaration (G7 surface) + ` ruleset dup${rng.int(0, 9)} {\n parallel { sub "p" "Q" }\n }\n ruleset dup${rng.int(0, 9)} {\n parallel { sub "r" "S" }\n }`, + // use with override + ` stage ov${rng.int(0, 9)} {\n use base override {\n sub "c" "C"\n }\n }`, + // languages + when guards + ` languages kur chv ev${rng.int(0, 9)}`, + ` sub "k" "K" when kur`, + ` sub "k" "Q" when undeclared${rng.int(0, 9)}`, + // dependency-qualified ruleset use + ` use ${rng.pick(["nonexistent-dep", "acadsin-zho-hani"])}:rs${rng.int(0, 9)}`, + ]; + const snippet = rng.pick(snippets); + const lines = src.split("\n"); + const at = rng.int(1, Math.max(1, lines.length - 1)); + lines.splice(at, 0, snippet); + return lines.join("\n"); +} + +// Keyword-table / fn-literal injection (G6/G8 surfaces). +function opInjectKeyword(rng, src) { + const kw = rng.pick(FN_KEYWORDS); + const snippets = [ + ` sub ${kw} "X"`, // fn literal in from position (G6) + ` alias_decl = any("a")\n ${kw}2 = any("b")`, // keyword-named alias + ` ${kw}`, // fn literal as stage directive (G8) + ` sub "a" "b"\n ${kw}`, // directive after rule + ]; + const snippet = rng.pick(snippets); + const lines = src.split("\n"); + const at = rng.int(1, Math.max(1, lines.length - 1)); + lines.splice(at, 0, snippet); + return lines.join("\n"); +} + +function opInjectEscape(rng, src) { + const lit = rng.pick(ESCAPE_EDGE_CASES); + const forms = [ + ` sub "${lit}" "X"`, + ` sub "a" "${lit}"`, + ` sub "${lit}" "X" before "q" after "z"`, + ` sub "a" "z"`, + ]; + const snippet = rng.pick(forms.slice(0, 3)); + const lines = src.split("\n"); + const at = rng.int(1, Math.max(1, lines.length - 1)); + lines.splice(at, 0, snippet); + return lines.join("\n"); +} + +function opCorruptMetadata(rng, src) { + const ops = [ + (s) => s.replace(/^system ".*" \{/, `system "FZ${rng.int(0, 9999)}" {`), + (s) => s.replace(/^ authority_id .*$/m, ""), + (s) => s.replace(/^ id .*$/m, ` id ${rng.int(0, 9999)}`), + (s) => s.replace(/^ source_script .*$/m, ` source_script "Bad Script"`), + (s) => s + `\n creation_date ${rng.int(1800, 2200)}`, + (s) => s.replace(/^metadata \{/m, `metadata {\n authority_id dup_id\n authority_id dup_id`), + ]; + return rng.pick(ops)(src); +} + +function opUnicodeInject(rng, src) { + const lit = rng.pick(UNICODE_LITERALS); + const forms = [ + ` sub "${lit}" "X"`, + ` sub "a" "${lit}"`, + ` sub ${rng.pick(ASCII_STRINGS)} "${lit}" after "${lit}"`, + ]; + const snippet = rng.pick(forms); + const lines = src.split("\n"); + const at = rng.int(1, Math.max(1, lines.length - 1)); + lines.splice(at, 0, snippet); + return lines.join("\n"); +} + +const MUTATIONS = [ + { name: "truncate", fn: opTruncate, weight: 3 }, + { name: "byteflip", fn: opByteFlip, weight: 3 }, + { name: "linedel", fn: opLineDelete, weight: 3 }, + { name: "linedup", fn: opLineDuplicate, weight: 2 }, + { name: "lineswap", fn: opLineSwap, weight: 2 }, + { name: "splice", fn: opSpliceRules, weight: 4 }, + { name: "wf1", fn: opInjectWF1, weight: 5 }, + { name: "keyword", fn: opInjectKeyword, weight: 3 }, + { name: "escape", fn: opInjectEscape, weight: 3 }, + { name: "metadata", fn: opCorruptMetadata, weight: 2 }, + { name: "unicode", fn: opUnicodeInject, weight: 3 }, +]; + +// --------------------------------------------------------------------------- +// Grammar-aware templates (valid but unusual maps) +// --------------------------------------------------------------------------- + +function templateNested(rng) { + const set = rng.pick([ + `any(["a", "b", "c"])`, + `any("a".."c")`, + `any([${rng.pick(UNICODE_LITERALS)}, "k"])`, + ]); + const inner = `${set} + maybe("k")`; + const from = rng.pick([ + `maybe(${inner}) + capture(any("x".."z")) + some("q")`, + `capture(maybe(${set})) + boundary`, + `some(any(["k", "q"])) + ref(1)`, + `word_boundary + capture(some("z")) + word_boundary`, + ]); + return wrapMap(rng, ` stage main {\n sequence {\n sub {\n from ${from}\n to "W" + ref(1)\n not_before "j"\n not_after "k"\n }\n }\n }`); +} + +function templateCaptureChain(rng) { + const n = rng.int(2, 4); + const parts = []; + for (let i = 0; i < n; i++) parts.push(`capture(any("${asciiAtom(rng, i)}".."${asciiAtom(rng, i + 3)}"))`); + const refs = parts.map((_, i) => `ref(${i + 1})`).join(" + "); + return wrapMap(rng, ` stage main {\n parallel {\n sub {\n from ${parts.join(" + ")}\n to ${refs}\n }\n }\n }`); +} + +function templateEmptyRules(rng) { + return wrapMap(rng, ` stage main {\n sequence {\n sub "" "L"\n sub "a" ""\n sub "" ""\n }\n }`); +} + +function templateUnicode(rng) { + const a = rng.pick(UNICODE_LITERALS); + const b = rng.pick(UNICODE_LITERALS); + return wrapMap(rng, ` stage main {\n parallel {\n sub "${a}" "${b}"\n sub "${b}" "${a}"\n }\n }`); +} + +function templateRulesetOverride(rng) { + const rs = `rs${rng.int(0, 99)}`; + return wrapMap(rng, ` ruleset ${rs} {\n parallel {\n sub "k" "q"\n sub "t" "d" when kur\n }\n }\n stage main {\n use ${rs} override {\n sub "c" "C"\n }\n }\n languages kur chv`); +} + +function templateAliasChain(rng) { + return wrapMap(rng, ` aliases {\n a1 = any(["x", "y", "z"])\n a2 = a1 + any("1".."3")\n a3 = maybe(a2)\n }\n stage main {\n sequence {\n sub a3 "R"\n }\n }`); +} + +function templateDupFroms(rng) { + return wrapMap(rng, ` stage main {\n parallel {\n sub "ab" "1"\n sub "abc" "2"\n sub "ab" "3"\n }\n }`); +} + +function templateFuncalls(rng) { + const d = rng.pick(FUNCALL_DIRECTIVES); + const kw = ` stage main {\n parallel { sub "a" "b" }\n ${d}${d === "title_case" ? " word_separator: \"-\"" : ""}\n }`; + return wrapMap(rng, kw); +} + +function templateBoundaries(rng) { + const z = rng.shuffle(ZERO_WIDTH).slice(0, 3); + return wrapMap(rng, ` stage main {\n sequence {\n sub {\n from ${z[0]} + capture(any("a".."z")) + ${z[1]}\n to "B" + ref(1)\n }\n sub {\n from line_start + any("k", "q")\n to "L"\n after ${z[2]}\n }\n }\n }`); +} + +function templateSelfRun(rng) { + return wrapMap(rng, ` stage main {\n parallel { sub "a" "b" }\n run stage.main\n }`); +} + +function templateBlocksInBlocks(rng) { + // nested parallel inside sequence — pinned negative probe (rejected 4/4 + // per docs/parity A.1); valid-shaped but unusual input for the fuzz. + return wrapMap(rng, ` stage main {\n sequence {\n sub "a" "b"\n parallel {\n sub "c" "d"\n }\n }\n }`); +} + +function asciiAtom(rng, i) { + const alphabet = "abcdefghjkmnpqrstvwxyz"; + return alphabet[(i + rng.int(0, 25)) % alphabet.length]; +} + +function wrapMap(rng, body) { + const sysname = `FZ:grammar:${rng.int(0, 999999)}`; + return `system "${sysname}" {\n metadata {\n authority_id fz\n id ${rng.int(0, 99999)}\n name "grammar-aware fuzz map"\n }\n${body}\n}\n`; +} + +const GRAMMAR_TEMPLATES = [ + { name: "nested", fn: templateNested, weight: 4 }, + { name: "capture-chain", fn: templateCaptureChain, weight: 3 }, + { name: "empty-rules", fn: templateEmptyRules, weight: 2 }, + { name: "unicode", fn: templateUnicode, weight: 3 }, + { name: "ruleset-override", fn: templateRulesetOverride, weight: 3 }, + { name: "alias-chain", fn: templateAliasChain, weight: 3 }, + { name: "dup-froms", fn: templateDupFroms, weight: 2 }, + { name: "funcalls", fn: templateFuncalls, weight: 2 }, + { name: "boundaries", fn: templateBoundaries, weight: 3 }, + { name: "self-run", fn: templateSelfRun, weight: 1 }, + { name: "blocks-in-blocks", fn: templateBlocksInBlocks, weight: 2 }, +]; + +// --------------------------------------------------------------------------- +// Main +// --------------------------------------------------------------------------- + +function parseArgs(argv) { + const opts = { + out: null, + seed: 20261120, + mutation: 150, + grammar: 50, + corpusRoot: null, + maxSeedBytes: 250_000, + }; + for (let i = 0; i < argv.length; i++) { + const a = argv[i]; + if (a === "--out") opts.out = argv[++i]; + else if (a === "--seed") opts.seed = Number(argv[++i]); + else if (a === "--mutation") opts.mutation = Number(argv[++i]); + else if (a === "--grammar") opts.grammar = Number(argv[++i]); + else if (a === "--corpus-root") opts.corpusRoot = argv[++i]; + else if (a === "--max-seed-bytes") opts.maxSeedBytes = Number(argv[++i]); + else throw new Error(`unknown flag ${a}`); + } + if (!opts.out) throw new Error("--out is required"); + return opts; +} + +export function generateCases(opts) { + const rng = makeRng(opts.seed); + const corpus = listCorpus(opts.corpusRoot || undefined); + if (corpus.length === 0) throw new Error("no corpus maps found"); + const donorPool = corpus + .filter((m) => m.bytes <= 400_000) + .map((m) => ({ ...m, text: readFileSync(m.path, "utf8") })); + + const cases = []; + const total = opts.mutation + opts.grammar; + + for (let i = 0; i < total; i++) { + const mode = i < opts.mutation ? "mutation" : "grammar"; + const id = `${mode}-${String(i).padStart(4, "0")}`; + let text; + let base = null; + if (mode === "mutation") { + base = pickSeedMap(rng, corpus, opts.maxSeedBytes); + text = readFileSync(base.path, "utf8"); + const nOps = rng.int(1, 3); + const applied = []; + for (let k = 0; k < nOps; k++) { + const mut = rng.weighted(MUTATIONS.map((m) => ({ item: m, weight: m.weight }))); + const before = text; + try { + text = mut.fn(rng, text, donorPool); + } catch { + text = before; + } + if (Buffer.compare(Buffer.isBuffer(text) ? text : Buffer.from(text, "utf8"), Buffer.isBuffer(before) ? before : Buffer.from(before, "utf8")) !== 0) { + applied.push(mut.name); + } + } + if (applied.length === 0) applied.push("no-op"); + cases.push({ id, mode, base: base.name, mutations: applied, text }); + } else { + const tpl = rng.weighted(GRAMMAR_TEMPLATES.map((t) => ({ item: t, weight: t.weight }))); + text = tpl.fn(rng); + cases.push({ id, mode, base: tpl.name, mutations: [], text }); + } + } + + ensureDir(join(opts.out, "cases")); + for (const c of cases) { + ensureDir(join(opts.out, "cases", c.id)); + // Case files are written as bytes: byte-flip mutations may produce + // invalid UTF-8 deliberately; the runner normalizes lossily for the + // drivers so every runtime sees the identical string. + writeFileSync( + join(opts.out, "cases", c.id, "map.isc"), + Buffer.isBuffer(c.text) ? c.text : Buffer.from(c.text, "utf8"), + ); + } + const manifest = { + seed: opts.seed, + mutation: opts.mutation, + grammar: opts.grammar, + corpusRoot: opts.corpusRoot || null, + cases: cases.map(({ id, mode, base, mutations }) => ({ id, mode, base, mutations })), + }; + writeFileSync(join(opts.out, "manifest.json"), JSON.stringify(manifest, null, 2)); + return manifest; +} + +const isMain = process.argv[1] && import.meta.url.endsWith(process.argv[1].split("/").pop()); +if (isMain) { + const opts = parseArgs(process.argv.slice(2)); + const manifest = generateCases(opts); + console.log( + `generated ${manifest.cases.length} cases (mutation=${manifest.mutation} grammar=${manifest.grammar}) seed=${manifest.seed} -> ${join(opts.out, "cases")}`, + ); +} diff --git a/scripts/fuzz/lib.mjs b/scripts/fuzz/lib.mjs new file mode 100644 index 0000000..7a9fa80 --- /dev/null +++ b/scripts/fuzz/lib.mjs @@ -0,0 +1,196 @@ +// Shared utilities for the ISC differential fuzz harness (WO20, maps#284). +// Deterministic PRNG, corpus listing, case/test-input extraction, driver +// invocation. Drivers are discovered from ./drivers and parameterized by +// environment (RUBY_LIB, TS_DIST, PY_SRC, ISCRS_BIN) so the harness is +// portable — no absolute paths are baked in. + +import { readdirSync, readFileSync, existsSync, mkdirSync } from "node:fs"; +import { join, dirname, resolve } from "node:path"; +import { fileURLToPath } from "node:url"; + +export const FUZZ_DIR = dirname(fileURLToPath(import.meta.url)); + +export const RUNTIMES = ["ruby", "ts", "py", "rs"]; + +export const DRIVER_ENV = { + ruby: { RUBY_LIB: "../../../interscript-ruby/lib" }, + ts: { TS_DIST: "../../../interscript-ts/dist" }, + py: { PY_SRC: "../../../interscript-py/src" }, + rs: { ISCRS_BIN: "../../../interscript-rs/target/release/iscrs" }, +}; +// Defaults assume the runtime repos are checked out as SIBLINGS of the maps +// clone (the layout maps-CI creates). Any location can be injected via the +// RUBY_LIB / TS_DIST / PY_SRC / ISCRS_BIN environment variables. + +// --------------------------------------------------------------------------- +// Deterministic PRNG (mulberry32). Every generator output is reproducible +// from a single 32-bit seed. +// --------------------------------------------------------------------------- + +export function mulberry32(seed) { + let a = seed >>> 0; + return function () { + a |= 0; + a = (a + 0x6d2b79f5) | 0; + let t = Math.imul(a ^ (a >>> 15), 1 | a); + t = (t + Math.imul(t ^ (t >>> 7), 61 | t)) ^ t; + return ((t ^ (t >>> 14)) >>> 0) / 4294967296; + }; +} + +export function makeRng(seed) { + const next = mulberry32(seed); + return { + next, + int: (lo, hi) => lo + Math.floor(next() * (hi - lo + 1)), + pick: (arr) => arr[Math.floor(next() * arr.length)], + chance: (p) => next() < p, + shuffle(arr) { + const a = arr.slice(); + for (let i = a.length - 1; i > 0; i--) { + const j = Math.floor(next() * (i + 1)); + [a[i], a[j]] = [a[j], a[i]]; + } + return a; + }, + // weighted pick: items = [{item, weight}] + weighted(items) { + const total = items.reduce((s, it) => s + it.weight, 0); + let r = next() * total; + for (const it of items) { + r -= it.weight; + if (r <= 0) return it.item; + } + return items[items.length - 1].item; + }, + }; +} + +// --------------------------------------------------------------------------- +// Corpus access +// --------------------------------------------------------------------------- + +const DEFAULT_CORPUS_ROOT = resolve(FUZZ_DIR, "..", ".."); + +export function listCorpus(corpusRoot = DEFAULT_CORPUS_ROOT) { + const out = []; + for (const sub of ["maps", "libs", join("maps-staging", "maps")]) { + const dir = join(corpusRoot, sub); + if (!existsSync(dir)) continue; + for (const f of readdirSync(dir)) { + if (!f.endsWith(".isc")) continue; + const path = join(dir, f); + try { + const buf = readFileSync(path); + out.push({ name: f, path, bytes: buf.byteLength }); + } catch { + /* unreadable seed: skip */ + } + } + } + return out; +} + +// Size-weighted seed selection: prefer small maps (fast drivers), keep some +// large ones in rotation, skip giants that dominate runtime budgets. +export function pickSeedMap(rng, corpus, maxSeedBytes = 250_000) { + const pool = corpus.filter((m) => m.bytes <= maxSeedBytes); + const items = pool.map((m) => ({ item: m, weight: 1 / Math.sqrt(m.bytes) })); + return rng.weighted(items); +} + +// --------------------------------------------------------------------------- +// Case / test-input extraction +// --------------------------------------------------------------------------- + +// ISC string literal body -> JS string. Handles the escapes the ISC grammar +// knows (\n \t \r \" \' \\ \u{...} \uXXXX \xXX) and passes anything else +// through verbatim. +export function unescapeIsc(body) { + let out = ""; + for (let i = 0; i < body.length; i++) { + const c = body[i]; + if (c !== "\\") { + out += c; + continue; + } + const n = body[++i]; + if (n === undefined) break; + switch (n) { + case "n": out += "\n"; break; + case "t": out += "\t"; break; + case "r": out += "\r"; break; + case '"': out += '"'; break; + case "'": out += "'"; break; + case "\\": out += "\\"; break; + case "u": { + if (body[i + 1] === "{") { + const end = body.indexOf("}", i + 2); + if (end < 0) { out += "u"; break; } + const hex = body.slice(i + 2, end); + const cp = parseInt(hex, 16); + i = end; + if (Number.isFinite(cp) && cp >= 0 && cp <= 0x10ffff) { + try { out += String.fromCodePoint(cp); } catch { /* keep raw */ } + } + } else { + const hex = body.slice(i + 1, i + 5); + const cp = parseInt(hex, 16); + if (Number.isFinite(cp) && hex.length === 4) { + out += String.fromCodePoint(cp); + i += 4; + } else out += "u"; + } + break; + } + case "x": { + const hex = body.slice(i + 1, i + 3); + const cp = parseInt(hex, 16); + if (Number.isFinite(cp) && hex.length === 2) { + out += String.fromCodePoint(cp); + i += 2; + } else out += "x"; + break; + } + default: out += n; + } + } + return out; +} + +// Extract test inputs from a case source: the bare `"in" -> "out"` rows of a +// `tests { }` block. Returns up to `limit` inputs, each truncated to `maxLen` +// characters and flattened to single lines (argv-safe, deterministic across +// all four drivers). +export function extractTestInputs(src, limit = 3, maxLen = 40) { + const inputs = []; + const lines = src.split("\n"); + let inTests = false; + for (const line of lines) { + const t = line.trim(); + if (t === "tests {") { inTests = true; continue; } + if (inTests && t === "}") { inTests = false; continue; } + if (!inTests) continue; + const m = t.match(/^"((?:[^"\\]|\\.)*)"\s*->/); + if (!m) continue; + let input = unescapeIsc(m[1]); + if (input.includes("\n")) input = input.split("\n")[0]; + if (input.length > maxLen) input = input.slice(0, maxLen); + inputs.push(input); + if (inputs.length >= limit) break; + } + if (inputs.length === 0) inputs.push("ab"); + return inputs; +} + +// --------------------------------------------------------------------------- +// Driver invocation contract +// --------------------------------------------------------------------------- +// Driver spawning lives in run.mjs (campaign) and minimize.mjs (reducer); +// both honor the same contract: driver argv = [, ], +// one JSON line on stdout, exit 0. See DRIVER_ENV above for the runtime +// location env vars (RUBY_LIB / TS_DIST / PY_SRC / ISCRS_BIN). + +export function ensureDir(p) { + mkdirSync(p, { recursive: true }); +} diff --git a/scripts/fuzz/minimize.mjs b/scripts/fuzz/minimize.mjs new file mode 100644 index 0000000..3d1a819 --- /dev/null +++ b/scripts/fuzz/minimize.mjs @@ -0,0 +1,236 @@ +// Finding minimizer (WO20, maps#284). +// +// Shrinks a finding's case while the finding's signature persists: +// 1. line-level delta debugging (halving chunks, then single lines) +// 2. head/tail character trimming +// The signature = (finding kind, reporting runtime, evidence bucket) tuple; +// a shrink step survives only if re-running the case still classifies as the +// SAME finding kind involving the SAME runtime. +// +// Usage: +// node minimize.mjs --finding --results +// --cases --out-dir [--runtimes ruby,ts,py,rs] [--timeout 45000] + +import { readFileSync, writeFileSync, mkdirSync, existsSync, mkdtempSync, rmSync } from "node:fs"; +import { join, resolve } from "node:path"; +import { spawn } from "node:child_process"; +import { extractTestInputs, ensureDir, DRIVER_ENV, FUZZ_DIR } from "./lib.mjs"; +import { knownKind } from "./classify.mjs"; + +function parseArgs(argv) { + const opts = { findings: null, results: null, cases: null, outDir: "findings-min", runtimes: ["ruby", "ts", "py", "rs"], timeout: 45_000 }; + for (let i = 0; i < argv.length; i++) { + const a = argv[i]; + if (a === "--findings") opts.findings = argv[++i]; + else if (a === "--results") opts.results = argv[++i]; + else if (a === "--cases") opts.cases = argv[++i]; + else if (a === "--out-dir") opts.outDir = argv[++i]; + else if (a === "--runtimes") opts.runtimes = argv[++i].split(","); + else if (a === "--timeout") opts.timeout = Number(argv[++i]); + else throw new Error(`unknown flag ${a}`); + } + if (!opts.findings || !opts.cases) throw new Error("--findings and --cases are required"); + return opts; +} + +// Re-run one candidate text through the drivers and return the observation set. +async function observe(text, runtimes, timeout) { + const dir = mkdtempSync(join("/tmp", "isc-fuzz-min-")); + const file = join(dir, "map.isc"); + writeFileSync(file, Buffer.isBuffer(text) ? text : Buffer.from(text, "utf8")); + const inputs = extractTestInputs((Buffer.isBuffer(text) ? text : Buffer.from(text, "utf8")).toString("utf8")); + const out = []; + for (const rt of runtimes) { + out.push(await spawnOne(rt, file, inputs, timeout)); + } + rmSync(dir, { recursive: true, force: true }); + return out; +} + +function spawnOne(runtime, caseFile, inputs, timeoutMs) { + const drivers = { + ruby: join(FUZZ_DIR, "drivers", "driver-ruby.rb"), + ts: join(FUZZ_DIR, "drivers", "driver-ts.mjs"), + py: join(FUZZ_DIR, "drivers", "driver-py.py"), + rs: join(FUZZ_DIR, "drivers", "driver-rs.mjs"), + }; + const cmd = { ruby: "ruby", ts: process.execPath, py: "python3", rs: process.execPath }[runtime]; + const env = {}; + for (const [k, v] of Object.entries(DRIVER_ENV[runtime])) env[k] = resolve(FUZZ_DIR, v); + return new Promise((done) => { + const child = spawn(cmd, [drivers[runtime], caseFile, JSON.stringify(inputs)], { env: { ...process.env, ...env } }); + let stdout = ""; + let stderr = ""; + let killed = false; + const timer = setTimeout(() => { + killed = true; + child.kill("SIGKILL"); + }, timeoutMs); + child.stdout.on("data", (d) => (stdout += d)); + child.stderr.on("data", (d) => { + if (stderr.length < 2000) stderr += d; + }); + const finish = (r) => { + clearTimeout(timer); + done(r); + }; + child.on("error", (e) => finish({ runtime, status: "CRASH", stderr: String(e.message) })); + child.on("close", (code) => { + if (killed) return finish({ runtime, status: "TIMEOUT" }); + const line = stdout.split("\n").find((l) => l.trim().startsWith("{")); + if (line && code === 0) { + try { + const parsed = JSON.parse(line); + return finish({ runtime, status: "OK", ...parsed }); + } catch { /* fall through */ } + } + return finish({ runtime, status: "CRASH", exitCode: code, stderr: stderr.slice(-400) }); + }); + }); +} + +// Signature extraction: kind + primary runtime evidence buckets. +function signatureOf(observations) { + const sigs = []; + for (const o of observations) { + if (o.status === "TIMEOUT") sigs.push(`hang:${o.runtime}`); + else if (o.status === "CRASH") sigs.push(`crash-proc:${o.runtime}`); + else { + const shapes = [o.parse, ...(o.exec || [])]; + for (const s of shapes) { + if (!s) continue; + if (s.bucket === "CRASH") sigs.push(`crash:${o.runtime}`); + if (s.bucket === "TIMEOUT") sigs.push(`hang:${o.runtime}`); + } + } + } + return sigs.sort().join(","); +} + +function divergeSignature(observations) { + const oks = observations.filter((o) => o.status === "OK"); + if (oks.length < 2) return "no-divergence"; + const parts = []; + const statuses = new Set(oks.map((o) => o.parse?.status)); + parts.push(`parse:${[...statuses].sort().join("/")}`); + if (statuses.size === 1 && statuses.has("OK")) { + for (const o of oks) { + const sig = (o.exec || []).map((e) => (e.status === "OK" ? JSON.stringify(e.output) : `ERR:${e.bucket}`)).join("|"); + parts.push(`${o.runtime}=${sig}`); + } + } else { + for (const o of oks) parts.push(`${o.runtime}=${o.parse?.bucket}`); + } + return parts.join(","); +} + +async function persists(text, target, runtimes, timeout) { + const obs = await observe(text, runtimes, timeout); + const kinds = knownKind((Buffer.isBuffer(text) ? text : Buffer.from(text, "utf8")).toString("utf8")); + if (kinds.length > 0) return false; // shrink must not fall into a known kind + if (target.kind === "hang" || target.kind === "crash") return signatureOf(obs).includes(target.sig); + // divergence: some cross-runtime mismatch must remain + return divergeSignature(obs) !== "no-divergence"; +} + +async function shrink(text, target, runtimes, timeout, maxRounds = 30) { + const asBuf = (t) => (Buffer.isBuffer(t) ? t : Buffer.from(t, "utf8")); + let cur = asBuf(text); + if (!(await persists(cur, target, runtimes, timeout))) return null; + + // Line-level ddmin-lite. + for (let round = 0; round < maxRounds; round++) { + const lines = cur.toString("utf8").split("\n"); + let changed = false; + for (let chunk = Math.floor(lines.length / 2); chunk >= 1; chunk = Math.floor(chunk / 2)) { + let i = 0; + while (i < lines.length) { + const candidate = lines.slice(0, i).concat(lines.slice(i + chunk)).join("\n"); + if (await persists(Buffer.from(candidate, "utf8"), target, runtimes, timeout)) { + lines.splice(i, chunk); + cur = Buffer.from(candidate, "utf8"); + changed = true; + } else { + i += chunk; + } + if (lines.length <= 3) break; + } + if (chunk <= 1) break; + if (lines.length <= 3) break; + } + if (!changed || lines0(cur) <= 3) break; + } + + // Head/tail character trimming (byte-safe via buffer scanning). + let buf = cur; + for (let round = 0; round < 12; round++) { + let changed = false; + for (const [start, end] of [[0, Math.floor(buf.length / 8)], [buf.length - Math.floor(buf.length / 8), buf.length]]) { + const span = end - start; + if (span <= 0) continue; + const step = Math.max(1, Math.floor(span / 2)); + for (let cut = start; cut < start + span; cut += step) { + const candidate = start === 0 ? buf.subarray(cut + 1) : buf.subarray(0, cut); + if (candidate.length === 0) continue; + if (await persists(candidate, target, runtimes, timeout)) { + buf = candidate; + changed = true; + break; + } + } + } + if (!changed || buf.length <= 40) break; + } + return buf; +} + +function lines0(buf) { + return buf.toString("utf8").split("\n").length; +} + +async function main() { + const opts = parseArgs(process.argv.slice(2)); + ensureDir(opts.outDir); + const findings = readFileSync(opts.findings, "utf8").split("\n").filter(Boolean).map((l) => JSON.parse(l)); + const real = findings.filter((f) => f.classification === "FINDING"); + console.log(`minimizing ${real.length} findings -> ${opts.outDir}`); + + for (const f of real) { + const caseFile = join(opts.cases, f.case, "map.isc"); + if (!existsSync(caseFile)) { + console.log(` ${f.case}: case file missing, skipped`); + continue; + } + const original = readFileSync(caseFile); + const first = f.findings[0]; + const target = { + kind: first.kind, + runtime: first.runtime, + sig: + first.kind === "crash" || first.kind === "hang" + ? `${first.kind}:${first.runtime}` + : null, + }; + const minimized = await shrink(original, target, opts.runtimes, opts.timeout); + const outDir = join(opts.outDir, f.case); + ensureDir(outDir); + writeFileSync(join(outDir, "finding.json"), JSON.stringify(f, null, 2)); + if (minimized) { + const minFile = join(outDir, "map.isc"); + writeFileSync(minFile, minimized); + const proof = await observe(minimized, opts.runtimes, opts.timeout); + writeFileSync(join(outDir, "proof.json"), JSON.stringify(proof, null, 2)); + console.log( + ` ${f.case}: ${original.length} -> ${minimized.length} bytes (${lines0(original)} -> ${lines0(minimized)} lines) kind=${first.kind}`, + ); + } else { + console.log(` ${f.case}: shrink failed to reproduce, kept original`); + writeFileSync(join(outDir, "map.isc"), original); + } + } +} + +main().catch((e) => { + console.error(e); + process.exit(1); +}); diff --git a/scripts/fuzz/rebuild-smoke.mjs b/scripts/fuzz/rebuild-smoke.mjs new file mode 100644 index 0000000..d7161d3 --- /dev/null +++ b/scripts/fuzz/rebuild-smoke.mjs @@ -0,0 +1,84 @@ +// Rebuilds the committed smoke corpus (scripts/fuzz/smoke-cases/). +// +// Generates a seeded candidate pool, runs it through every AVAILABLE +// runtime, and keeps the first N cases that classify agree-or-known — the +// committed green baseline smoke.mjs enforces. Re-run whenever the runtime +// set changes materially (e.g. after a parity fix lands) to refresh the +// baseline; any case that regresses afterwards turns smoke red. +// +// Usage: node rebuild-smoke.mjs [--want 200] [--pool 420] [--seed 20261120] + +import { readFileSync, writeFileSync, mkdirSync, rmSync, existsSync, readdirSync, cpSync } from "node:fs"; +import { join, resolve, dirname } from "node:path"; +import { fileURLToPath } from "node:url"; +import { spawnSync } from "node:child_process"; +import { ensureDir, FUZZ_DIR } from "./lib.mjs"; +import { classify } from "./classify.mjs"; + +const HERE = fileURLToPath(new URL(".", import.meta.url)); + +function parseArgs(argv) { + const opts = { want: 200, pool: 420, seed: 20261120 }; + for (let i = 0; i < argv.length; i++) { + const a = argv[i]; + if (a === "--want") opts.want = Number(argv[++i]); + else if (a === "--pool") opts.pool = Number(argv[++i]); + else if (a === "--seed") opts.seed = Number(argv[++i]); + else throw new Error(`unknown flag ${a}`); + } + return opts; +} + +async function main() { + const opts = parseArgs(process.argv.slice(2)); + const work = "/tmp/isc-fuzz-smoke-rebuild"; + rmSync(work, { recursive: true, force: true }); + ensureDir(work); + + // 1. Generate the candidate pool (mutation + grammar mix). + const gen = spawnSync(process.execPath, [ + join(FUZZ_DIR, "generate.mjs"), + "--out", work, + "--seed", String(opts.seed), + "--mutation", String(Math.round(opts.pool * 0.75)), + "--grammar", String(opts.pool - Math.round(opts.pool * 0.75)), + ], { stdio: "inherit" }); + if (gen.status !== 0) process.exit(2); + + // 2. Run all available runtimes over the pool. + const resultsPath = join(work, "results.jsonl"); + const run = spawnSync(process.execPath, [ + join(FUZZ_DIR, "run.mjs"), + "--cases", join(work, "cases"), + "--out", resultsPath, + "--timeout", "45000", + "--jobs", "6", + ], { stdio: "inherit", env: { ...process.env } }); + if (run.status !== 0) process.exit(2); + + // 3. Keep agree/known cases in generation order until want is reached. + const { findings } = classify(resultsPath, join(work, "cases")); + const bad = new Set(findings.filter((f) => f.classification === "FINDING").map((f) => f.case)); + const manifest = JSON.parse(readFileSync(join(work, "manifest.json"), "utf8")); + const keep = manifest.cases.map((c) => c.id).filter((id) => !bad.has(id)).slice(0, opts.want); + console.log(`pool=${manifest.cases.length} findings=${bad.size} kept=${keep.length}`); + + // 4. Rewrite the committed smoke-cases dir. + const outDir = join(FUZZ_DIR, "smoke-cases"); + if (existsSync(outDir)) rmSync(outDir, { recursive: true }); + mkdirSync(outDir, { recursive: true }); + for (const id of keep) { + cpSync(join(work, "cases", id), join(outDir, id), { recursive: true }); + } + writeFileSync( + join(outDir, "manifest.json"), + JSON.stringify({ seed: opts.seed, pool: opts.pool, want: opts.want, kept: keep, rebuiltWith: "rebuild-smoke.mjs" }, null, 2) + "\n", + ); + rmSync(work, { recursive: true, force: true }); + console.log(`smoke corpus rebuilt: ${keep.length} cases -> ${outDir}`); +} + +main().catch((e) => { + console.error(e); + process.exit(1); +}); diff --git a/scripts/fuzz/run.mjs b/scripts/fuzz/run.mjs new file mode 100644 index 0000000..6112541 --- /dev/null +++ b/scripts/fuzz/run.mjs @@ -0,0 +1,195 @@ +// Differential-fuzz runner (WO20, maps#284). +// +// Runs every case through every requested runtime driver with a per-case +// timeout, applying the harness-boundary UTF-8 normalization, and writes +// one JSON line per (case, runtime) observation: +// {"case":id,"runtime":rt,"status":...,"parse":{...},"exec":[...]} +// +// Usage: +// node run.mjs --cases --out [--runtimes ruby,ts,py,rs] +// [--jobs 6] [--timeout 45000] [--limit N] [--case ID] + +import { readdirSync, readFileSync, statSync, existsSync, mkdtempSync, writeFileSync, rmSync } from "node:fs"; +import { join, resolve, dirname } from "node:path"; +import { spawn } from "node:child_process"; +import { extractTestInputs, ensureDir, DRIVER_ENV, FUZZ_DIR } from "./lib.mjs"; + +function parseArgs(argv) { + const opts = { + cases: null, + out: "results.jsonl", + runtimes: ["ruby", "ts", "py", "rs"], + jobs: 6, + timeout: 45_000, + limit: 0, + caseId: null, + }; + for (let i = 0; i < argv.length; i++) { + const a = argv[i]; + if (a === "--cases") opts.cases = argv[++i]; + else if (a === "--out") opts.out = argv[++i]; + else if (a === "--runtimes") opts.runtimes = argv[++i].split(","); + else if (a === "--jobs") opts.jobs = Number(argv[++i]); + else if (a === "--timeout") opts.timeout = Number(argv[++i]); + else if (a === "--limit") opts.limit = Number(argv[++i]); + else if (a === "--case") opts.caseId = argv[++i]; + else throw new Error(`unknown flag ${a}`); + } + if (!opts.cases) throw new Error("--cases is required"); + return opts; +} + +function discoverCases(casesDir) { + const out = []; + for (const e of readdirSync(casesDir)) { + const p = join(casesDir, e); + try { + if (statSync(p).isDirectory() && existsSync(join(p, "map.isc"))) { + out.push({ id: e, file: join(p, "map.isc") }); + } + } catch { /* not a dir */ } + } + out.sort((a, b) => a.id.localeCompare(b.id)); + return out; +} + +// --------------------------------------------------------------------------- +// Driver spawn (async). Contract: driver prints one JSON line; exit 0. +// Anything else is a hard result recorded by the runner: +// TIMEOUT — driver exceeded the per-case wall clock (a hang finding) +// CRASH — nonzero exit / no JSON line / signal +// --------------------------------------------------------------------------- + +function spawnDriver(runtime, caseFile, inputs, timeoutMs) { + const drivers = { + ruby: join(FUZZ_DIR, "drivers", "driver-ruby.rb"), + ts: join(FUZZ_DIR, "drivers", "driver-ts.mjs"), + py: join(FUZZ_DIR, "drivers", "driver-py.py"), + rs: join(FUZZ_DIR, "drivers", "driver-rs.mjs"), + }; + const cmd = { ruby: "ruby", ts: process.execPath, py: "python3", rs: process.execPath }[runtime]; + const args = [drivers[runtime], caseFile, JSON.stringify(inputs)]; + const env = {}; + for (const [k, v] of Object.entries(DRIVER_ENV[runtime])) env[k] = process.env[k] || resolve(FUZZ_DIR, v); + + return new Promise((done) => { + const started = Date.now(); + const child = spawn(cmd, args, { env: { ...process.env, ...env } }); + let stdout = ""; + let stderr = ""; + let killed = false; + const timer = setTimeout(() => { + killed = true; + child.kill("SIGKILL"); + }, timeoutMs); + child.stdout.on("data", (d) => (stdout += d)); + child.stderr.on("data", (d) => { + if (stderr.length < 4000) stderr += d; + }); + const finish = (result) => { + clearTimeout(timer); + done(result); + }; + child.on("error", (e) => finish({ runtime, status: "CRASH", ms: Date.now() - started, stderr: String(e.message) })); + child.on("close", (code, signal) => { + const ms = Date.now() - started; + if (killed) return finish({ runtime, status: "TIMEOUT", ms }); + const line = stdout.split("\n").find((l) => l.trim().startsWith("{")); + if (line) { + try { + const parsed = JSON.parse(line); + if (code === 0) return finish({ runtime, status: "OK", ms, ...parsed }); + } catch { /* fall through */ } + } + return finish({ + runtime, + status: "CRASH", + ms, + exitCode: code, + signal, + stderr: stderr.slice(-600), + }); + }); + }); +} + +// Harness-boundary normalization: cases may contain invalid UTF-8 (byte-flip +// mutations). Every driver must see the IDENTICAL string, so invalid cases +// get a sanitized copy in a scratch dir; valid cases pass through as-is. +function makeNormalizer() { + const scratch = mkdtempSync(join("/tmp", "isc-fuzz-run-")); + const cache = new Map(); + function caseFileFor(c) { + if (cache.has(c.id)) return cache.get(c.id); + const buf = readFileSync(c.file); + let file = c.file; + if (!Buffer.from(buf.toString("utf8"), "utf8").equals(buf)) { + const dir = join(scratch, c.id); + ensureDir(dir); + file = join(dir, "map.isc"); + writeFileSync(file, Buffer.from(buf.toString("utf8"), "utf8")); + } + cache.set(c.id, file); + return file; + } + caseFileFor.cleanup = () => rmSync(scratch, { recursive: true, force: true }); + return caseFileFor; +} + +async function main() { + const opts = parseArgs(process.argv.slice(2)); + let cases = discoverCases(opts.cases); + if (opts.caseId) cases = cases.filter((c) => c.id === opts.caseId); + if (opts.limit > 0) cases = cases.slice(0, opts.limit); + if (cases.length === 0) { + console.error("no cases found"); + process.exit(2); + } + ensureDir(dirname(resolve(opts.out))); + const outPath = resolve(opts.out); + const caseFileFor = makeNormalizer(); + const inputsCache = new Map(); + const inputsFor = (c) => { + if (!inputsCache.has(c.id)) inputsCache.set(c.id, extractTestInputs(readFileSync(c.file, "utf8"))); + return inputsCache.get(c.id); + }; + + const results = []; + const total = cases.length * opts.runtimes.length; + let done = 0; + const t0 = Date.now(); + let next = 0; + + async function worker() { + while (next < cases.length) { + const i = next++; + const c = cases[i]; + const file = caseFileFor(c); + const inputs = inputsFor(c); + for (const rt of opts.runtimes) { + const r = await spawnDriver(rt, file, inputs, opts.timeout); + results.push({ case: c.id, ...r }); + done++; + if (done % 200 === 0 || done === total) { + const rate = done / ((Date.now() - t0) / 1000); + console.error(`[run] ${done}/${total} (${rate.toFixed(1)}/s)`); + } + } + } + } + + await Promise.all(Array.from({ length: Math.max(1, opts.jobs) }, () => worker())); + results.sort((a, b) => (a.case === b.case ? a.runtime.localeCompare(b.runtime) : a.case.localeCompare(b.case))); + writeFileSync(outPath, results.map((r) => JSON.stringify(r)).join("\n") + "\n"); + caseFileFor.cleanup(); + + const byStatus = {}; + for (const r of results) byStatus[r.status] = (byStatus[r.status] || 0) + 1; + console.log(`ran ${total} observations over ${cases.length} cases -> ${outPath}`); + console.log(`statuses: ${JSON.stringify(byStatus)}`); +} + +main().catch((e) => { + console.error(e); + process.exit(1); +}); diff --git a/scripts/fuzz/smoke-cases/manifest.json b/scripts/fuzz/smoke-cases/manifest.json new file mode 100644 index 0000000..0481a49 --- /dev/null +++ b/scripts/fuzz/smoke-cases/manifest.json @@ -0,0 +1,209 @@ +{ + "seed": 20261120, + "pool": 420, + "want": 200, + "kept": [ + "mutation-0000", + "mutation-0001", + "mutation-0002", + "mutation-0003", + "mutation-0004", + "mutation-0006", + "mutation-0007", + "mutation-0008", + "mutation-0009", + "mutation-0010", + "mutation-0011", + "mutation-0012", + "mutation-0013", + "mutation-0015", + "mutation-0016", + "mutation-0017", + "mutation-0020", + "mutation-0022", + "mutation-0023", + "mutation-0024", + "mutation-0025", + "mutation-0026", + "mutation-0027", + "mutation-0028", + "mutation-0029", + "mutation-0030", + "mutation-0032", + "mutation-0033", + "mutation-0034", + "mutation-0035", + "mutation-0037", + "mutation-0038", + "mutation-0040", + "mutation-0041", + "mutation-0042", + "mutation-0043", + "mutation-0044", + "mutation-0045", + "mutation-0046", + "mutation-0047", + "mutation-0048", + "mutation-0049", + "mutation-0050", + "mutation-0052", + "mutation-0053", + "mutation-0054", + "mutation-0055", + "mutation-0056", + "mutation-0057", + "mutation-0058", + "mutation-0059", + "mutation-0060", + "mutation-0061", + "mutation-0062", + "mutation-0063", + "mutation-0064", + "mutation-0065", + "mutation-0067", + "mutation-0068", + "mutation-0069", + "mutation-0070", + "mutation-0071", + "mutation-0072", + "mutation-0073", + "mutation-0074", + "mutation-0075", + "mutation-0076", + "mutation-0077", + "mutation-0078", + "mutation-0080", + "mutation-0081", + "mutation-0083", + "mutation-0084", + "mutation-0085", + "mutation-0086", + "mutation-0087", + "mutation-0088", + "mutation-0089", + "mutation-0091", + "mutation-0092", + "mutation-0093", + "mutation-0094", + "mutation-0095", + "mutation-0097", + "mutation-0098", + "mutation-0099", + "mutation-0100", + "mutation-0101", + "mutation-0102", + "mutation-0103", + "mutation-0104", + "mutation-0105", + "mutation-0107", + "mutation-0108", + "mutation-0110", + "mutation-0111", + "mutation-0112", + "mutation-0113", + "mutation-0115", + "mutation-0116", + "mutation-0117", + "mutation-0119", + "mutation-0120", + "mutation-0121", + "mutation-0122", + "mutation-0123", + "mutation-0124", + "mutation-0126", + "mutation-0127", + "mutation-0128", + "mutation-0129", + "mutation-0130", + "mutation-0131", + "mutation-0132", + "mutation-0133", + "mutation-0134", + "mutation-0135", + "mutation-0136", + "mutation-0138", + "mutation-0139", + "mutation-0140", + "mutation-0141", + "mutation-0142", + "mutation-0143", + "mutation-0147", + "mutation-0148", + "mutation-0149", + "mutation-0151", + "mutation-0152", + "mutation-0153", + "mutation-0154", + "mutation-0155", + "mutation-0156", + "mutation-0157", + "mutation-0158", + "mutation-0159", + "mutation-0160", + "mutation-0161", + "mutation-0162", + "mutation-0163", + "mutation-0165", + "mutation-0166", + "mutation-0167", + "mutation-0168", + "mutation-0169", + "mutation-0170", + "mutation-0171", + "mutation-0172", + "mutation-0173", + "mutation-0174", + "mutation-0176", + "mutation-0177", + "mutation-0179", + "mutation-0180", + "mutation-0181", + "mutation-0182", + "mutation-0183", + "mutation-0184", + "mutation-0186", + "mutation-0187", + "mutation-0189", + "mutation-0190", + "mutation-0192", + "mutation-0193", + "mutation-0195", + "mutation-0196", + "mutation-0197", + "mutation-0198", + "mutation-0199", + "mutation-0200", + "mutation-0201", + "mutation-0203", + "mutation-0204", + "mutation-0205", + "mutation-0206", + "mutation-0207", + "mutation-0210", + "mutation-0211", + "mutation-0213", + "mutation-0214", + "mutation-0215", + "mutation-0216", + "mutation-0217", + "mutation-0218", + "mutation-0219", + "mutation-0220", + "mutation-0222", + "mutation-0223", + "mutation-0224", + "mutation-0226", + "mutation-0227", + "mutation-0229", + "mutation-0230", + "mutation-0231", + "mutation-0232", + "mutation-0233", + "mutation-0234", + "mutation-0235", + "mutation-0237" + ], + "rebuiltWith": "rebuild-smoke.mjs", + "note": "regenerated via rebuild-smoke.mjs (seed 20261120); mutation-0191 (py parser hang) swapped for mutation-0000/mutation-0001 after the hang-filter fix", + "cases": 199 +} \ No newline at end of file diff --git a/scripts/fuzz/smoke-cases/mutation-0000/map.isc b/scripts/fuzz/smoke-cases/mutation-0000/map.isc new file mode 100644 index 0000000..d4cf952 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0000/map.isc @@ -0,0 +1,176 @@ +system "ICAO:bel-Cyrl:Latn:9303" { + +metadata { + authority_id icao + id 9303 + language iso-639-2:bel + source_script Cyrl + destination_script Latn + name ICAO Doc 9303 Machine Readable Travel Documents Part 3 -- Belorussian Cyrillic to Latin + url https://www.icao.int/publications/pages/publication.aspx?docnum=9303 + creation_date 2015 + description { Part 3 defines specifications that are common to TD1, TD2 and TD3 + size machine readable travel documents (MRTDs) including those + necessary for global interoperability using visual inspection and + machine readable (optical character recognition) means. + + Since only Latin-alphabet characters are allowed in the VIZ, if + mandatory data elements are in a national language that does not use + the Latin alphabet, a transcription or transliteration shall also be + provided. + + This document defines the transliteration mappings used to produce + this transcription or transliteration. + } + + notes { + note "Diffed against ICAO Doc 9303 Part 3 Amd 1 (16/09/16), Section 6.B: the rows for Ќ, Ъ, Ѵ and Ғ were missing and were added with their source values. U+2019 right single quotation mark is now dropped alongside the ASCII apostrophe per Section 4.6 (apostrophes shall be omitted in the MRZ)." + note "Divergences corrected against the same source: the lowercase rows for у, ю, ў and ѫ were emptied or truncated (to nothing and to i); the source gives У to U, Ю to IU, Ў to U and Ѫ to U regardless of case, so the lowercase rows now mirror their uppercase rows." + note "Belarusian exceptions applied per the source: Ё renders IO and Г renders H." + note "The map carries a row for Ѓ (U+0403) to G, which has no row in the Amd 1 Section 6.B table (the table has Ғ, U+0492, to G); kept as a practical extension." + note "Soft sign Ь has no row in the Amd 1 Section 6.B table and is left unmapped." + note "The Amd 1 table prints row 04BA Һ (Cyrillic shha) as C; the map follows the source as printed, though C rather than H may be a source-side erratum." + } +} + +tests { + "Бабрыковіч Аляксандр" -> "Babrykovich Aliaksandr" + "Міховіч Марыя" -> "Mikhovich Maryia" + "Максім" -> "Maksim" + "Іван" -> "Ivan" + "СВЯТЛАНА" -> "SVIATLANA" + "Ігар" -> "Ihar" + "Палто Алена" -> "Palto Alena" + "Мікалай" -> "Mikalai" + "Магілёў" -> "Mahiliou" + "Гродна" -> "Hrodna" + "Ё" -> "IO" + "ё" -> "io" + "Г" -> "H" + "г" -> "h" + "Ў" -> "U" + "ў" -> "u" + "у" -> "u" + "Ю" -> "IU" + "ю" -> "iu" + "Ъ" -> "IE" + "ъ" -> "ie" + "Ѵ" -> "Y" + "ѷ" -> "y" + "Ғ" -> "G" + "ғ" -> "g" + "Ќ" -> "K" + "ќ" -> "k" +} + +# https://www.icao.int/publications/Documents/9303_p3_cons_en.pdf +stage main { + + # CHARACTERS + parallel { + sub "'" "" + sub "’" "" + sub "А" "A" + sub "Б" "B" + sub "Д" "D" + sub "Ё" "IO" + sub "Е" "E" + sub "Э" "E" + sub "Ф" "F" + sub "Г" "H" + sub "И" "I" + sub "Й" "I" + sub "К" "K" + sub "Ќ" "K" + sub "Л" "L" + sub "М" "M" + sub "Н" "N" + sub "О" "O" + sub "П" "P" + sub "Р" "R" + sub "С" "S" + sub "Т" "T" + sub "У" "U" + sub "В" "V" + sub "Ы" "Y" + sub "З" "Z" + sub "Ч" "CH" + sub "Я" "IA" + sub "Ю" "IU" + sub "Х" "KH" + sub "Ш" "SH" + sub "Щ" "SHCH" + sub "Ъ" "IE" + sub "Ц" "TS" + sub "Ж" "ZH" + sub "Ґ" "G" + sub "Ғ" "G" + sub "Ў" "U" + sub "Ѫ" "U" + sub "Ѵ" "Y" + sub "Ђ" "D" + sub "Ѕ" "DZ" + sub "Ј" "J" + sub "Љ" "LJ" + sub "Њ" "NJ" + sub "Һ" "C" + sub "Џ" "DZ" + use nonexistent-dep:rs1 + sub "Є" "IE" + sub "Ї" "I" + sub "Ѓ" "G" + sub "І" "I" + + sub "а" "a" + sub "б" "b" + sub "д" "d" + sub "ё" "io" + sub "е" "e" + sub "э" "e" + sub "ф" "f" + sub "г" "h" + sub "и" "i" + sub "й" "i" + sub "к" "k" + sub "л" "l" + sub "м" "m" + sub "н" "n" + sub "о" "o" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "т" "t" + sub "у" "u" + sub "в" "v" + sub "ы" "y" + sub "з" "z" + sub "ч" "ch" + sub "ю" "iu" + sub "х" "kh" + sub "ш" "sh" + sub "щ" "shch" + sub "ъ" "ie" + sub "ц" "ts" + sub "ж" "zh" + sub "ґ" "g" + sub "ғ" "g" + sub "ў" "u" + sub "ѫ" "u" + sub "ѷ" "y" + sub "ђ" "d" + sub "ѕ" "dz" + sub "ј" "j" + sub "љ" "lj" + sub "њ" "nj" + sub "һ" "c" + sub "џ" "dz" + sub "є" "ie" + sub "ї" "i" + sub "ѓ" "g" + sub "і" "i" + sub "ќ" "k" + } + +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0001/map.isc b/scripts/fuzz/smoke-cases/mutation-0001/map.isc new file mode 100644 index 0000000..3cffbd9 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0001/map.isc @@ -0,0 +1,138 @@ +system "ICAO:fas-Arab:Latn:9303" { + +metadata { + authority_id icao + id 9303 + language iso-639-2:fas + source_script Arab + destination_script Latn + name ICAO Doc 9303 Machine Readable Travel Documents Part 3 -- Persian Arabic to Latin + url https://www.icao.int/publications/pages/publication.aspx?docnum=9303 + creation_date 2015 + description { Part 3 defines specifications that are common to TD1, TD2 and TD3 + size machine readable travel documents (MRTDs) including those + necessary for global interoperability using visual inspection and + machine readable (optical character recognition) means. + + Since only Latin-alphabet characters are allowed in the VIZ, if + mandatory data elements are in a national language that does not use + the Latin alphabet, a transcription or transliteration shall also be + provided. + + This document defines the transliteration mappings used to produce + this transcription or transliteration. + } + + notes { + note "Diffed against ICAO Doc 9303 Part 3 Amd 1 (16/09/16), Section 6.C (Transliteration of Arabic Script)." + note "Divergence corrected against the source: teh marbuta was rendered P, which is the value of peh; the source's row 0629 renders teh marbuta XTA. The other divergences corrected: the vowel-sign rows fathatan, dammatan, kasratan, fatha, damma, kasra and sukun were rendered F, N, K, A, U, I and O, but the source marks all of them (and tatwheel and superscript alef) as Not encoded; they now drop from the output instead of injecting Latin letters." + note "NOT ENCODED -- teh marbuta word-final variant. Source footnote 1: XTA is used generally except if teh marbuta occurs at the end of the name component, in which case XAH is used. This positional rule needs an after-boundary constraint, which the current Ruby ISC runtime drops (Interscript::Isc::NodeAdapter reads constraint :value while the DocumentBuilder emits :item), so it would silently never fire; once fixed, encode it as sub { from \"ة\" to \"XAH\" after boundary } before the parallel block." + note "NOT ENCODED -- shadda (U+0651). Source footnote 2: shadda denotes doubling, the Latin character or sequence is repeated (e.g. abbas with shadda becomes EBBAS). Doubling the previous output is not expressible as a parallel substitution, so shadda is left unmapped rather than guessed." + note "The four further Not encoded rows of the source table (069C, 06A2, 06A7, 06A8) are likewise left unmapped." + } +} + +tests { + "ة" -> "XTA" + "پ" -> "P" + "چ" -> "XC" + "ژ" -> "XJ" + "گ" -> "XGG" + "ک" -> "XKK" + "ی" -> "XYA" + "َ" -> "" + "ْ" -> "" + "ـ" -> "" + "پاکستان" -> "PAXKKSTAN" +} + +# https://www.icao.int/publications/Documents/9303_p3_cons_en.pdf +stage main { + + # CHARACTERS + parallel { + + sub "'" "" + sub "ء" "XE" + sub "آ" "XAA" + sub "أ" "XAE" + sub "ؤ" "U" + sub "إ" "I" + sub "ئ" "XI" + sub "ا" "A" + sub "ب" "B" + sub "ة" "XTA" + sub "ت" "T" + sub "ث" "XTH" + sub "ج" "J" + sub "ح" "XH" + sub "د" "D" + sub "ذ" "XDH" + sub "ر" "R" + sub "ز" "Z" + sub "س" "S" + sub "ش" "XSH" + sub "ص" "XSS" + sub "ض" "XDZ" + sub "ط" "XTT" + sub "ظ" "XZZ" + sub "ع" "E" + sub "غ" "G" + sub "ـ" "" + sub "ف" "F" + sub "ق" "Q" + sub "ك" "K" + sub "ل" "L" + sub "م" "M" + sub "ن" "N" + sub "ه" "H" + sub "و" "W" + sub "ى" "XAY" + sub "ي" "Y" + sub "ً" "" + sub "ٌ" "" + sub "ٍ" "" + sub "َ" "" + sub "ُ" "" + sub "ِ" "" + sequence { + sub "x" "y" + use inner3 + } + sub "ْ" "" + sub "ٰ" "" + sub "ٱ" "XXA" + sub "ٹ" "XXT" + sub "ټ" "XRT" + sub "پ" "P" + sub "ځ" "XKE" + sub "څ" "XXH" + sub "چ" "XC" + sub "ڈ" "XXD" + sub "ډ" "XDR" + sub "ڑ" "XXR" + sub "ړ" "XRR" + sub "ږ" "XRX" + sub "ژ" "XJ" + sub "ښ" "XXS" + sub "ک" "XKK" + sub "ګ" "XXK" + sub "ڭ" "XNG" + sub "گ" "XGG" + sub "ں" "XNN" + sub "ڼ" "XXN" + sub "ھ" "XDO" + sub "ۀ" "XYH" + sub "ہ" "XXG" + sub "ۂ" "XGE" + sub "ۃ" "XTG" + sub "ی" "XYA" + sub "ۍ" "XXY" + sub "ې" "Y" + sub "ے" "XYB" + sub "ۓ" "XBE" + } + +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0002/map.isc b/scripts/fuzz/smoke-cases/mutation-0002/map.isc new file mode 100644 index 0000000..c50cbcf --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0002/map.isc @@ -0,0 +1,160 @@ +system "ALA-LC:mnc-Mong:Latn:2012" { + +metadata { + authority_id alalc + id 2012 + language iso-639-2:mnc + source_script Mong + destination_script Latn + name "Manchu Romanization Table (2012)" + url https://www.loc.gov/catdir/cpso/romanization/manchu.pdf + creation_date 2012 + adoption_date + description { ALA-LC Manchu Romanization Table, 2012 version (no earlier + versions). The printed table gives each letter in its isolated, + initial, medial and final forms; Manchu is a cursive script and all + positional forms of a letter share one Unicode codepoint, so each + row encodes one rule. The before-vowel variant letters of the + printed table are distinct letters of the script and carry distinct + codepoints: k (1) before a, o, and ū / k (2) before e, i, and u; + likewise g (1)/(2), h (1)/(2), t (1)/(2), d (1)/(2), and f (3) + before a and e only versus f. The letters and digraphs used in + foreign words (kʻ, gʻ, hʻ before a and o; ts, dz, ž, sy, cy, jy per + Chinese pinyin values) are shown in the table in isolated form. + The Unicode correspondence follows the standard Mongolian block + model: shared Mongolian letters, the Sibe letterforms that coincide + with the Manchu forms, and the five Manchu-specific codepoints + (Manchu I, KA, RA, FA, ZHA); the three foreign-letter forms kʻ gʻ + hʻ correspond to the Todo KA/GAA/HAA codepoints, and ts, dz, ž to + the Sibe TSA/ZA/ZHA codepoints. + } + + notes { + note "Positional variant letters and their codepoints: k (1) ᡴ, + k (2) ᠺ, g (1) ᠭ, g (2) ᡤ, h (1) ᠬ, h (2) ᡥ, t (1) ᡨ, t (2) ᠲ, + d (1) ᡩ, d (2) ᠳ, f (3) ᠹ, f ᡶ. Vowels: a ᠠ, e ᡝ, i ᡳ, o ᠣ, + u ᡠ, ū ᡡ. The vowels e, u, ū and the consonants g (2), h (2), + p, š, t (1), d (1) use the codepoints of the Sibe letters whose + forms coincide with the Manchu letterforms (Unicode Mongolian + block, Manchu section)." + note "The foreign-word digraphs sy, cy, jy (Chinese pinyin si, chi, + zhi) are written with the s/c/j letter followed by the i letter. + cy (ᠴᡳ) and jy (ᠵᡳ) are encoded as digraph rules: the letters c + and j do not occur before i in native Manchu. sy (ᠰᡳ) is not + encoded as a digraph because the same sequence spells the native + word si (you); the pinyin value sy applies only to Chinese loan + syllables and cannot be distinguished at the character level." + note "The diphthongs listed in the table (ai, ei, ui, oi, ūi) are + sequences of the vowel letters and romanize automatically; ūi is + written with the vowel letters ū + i." + note "Case endings separated from the word are attached with a + hyphen (e.g. gurun-i, gisun-i); the hyphen is retained as written." + note "Old Manchu (tongki fuka akū hergen) is romanized as if it + had the added diacritics (tongki fuka sindaha hergen), i.e. as the + corresponding modern letter values." + note "Capitalization: all proper nouns (personal names, corporate + names, ethnonyms, geographical names, names of dynasties and + reigns, e.g. Abkai Wehiyehe) are capitalized; the first word of the + title of a book, periodical, or series is capitalized." + note "Sources cited by the table: Norman, J. A concise + Manchu-English lexicon (Seattle: University of Washington Press, + c1978); Li, G.R. Manchu: a textbook for reading documents + (Honolulu: University of Hawaiʻi Press, c2000), which follows the + Norman transcription system used by this table." + } +} + +tests { + "ᠮᠠᠨᠵᡠ" -> "manju" + "ᡤᡳᠰᡠᠨ" -> "gisun" + "ᠮᠠᠨᠵᡠ ᡤᡳᠰᡠᠨ" -> "manju gisun" + "ᠠ" -> "a" + "ᡝ" -> "e" + "ᡳ" -> "i" + "ᠣ" -> "o" + "ᡠ" -> "u" + "ᡡ" -> "ū" + "ᠨ" -> "n" + "ᡴ" -> "k" + "ᠺ" -> "k" + "ᠭ" -> "g" + "ᡤ" -> "g" + "ᠬ" -> "h" + "ᡥ" -> "h" + "ᠪ" -> "b" + "ᡦ" -> "p" + "ᠰ" -> "s" + "ᡧ" -> "š" + "ᡨ" -> "t" + "ᠲ" -> "t" + "ᡩ" -> "d" + "ᠳ" -> "d" + "ᠯ" -> "l" + "ᠮ" -> "m" + "ᠴ" -> "c" + "ᠵ" -> "j" + "ᠶ" -> "y" + "ᡵ" -> "r" + "ᠹ" -> "f" + "ᡶ" -> "f" + "ᠸ" -> "w" + "ᠩ" -> "ng" + "ᡗ" -> "kʻ" + "ᡘ" -> "gʻ" + "ᡙ" -> "hʻ" + "ᡮ" -> "ts" + "ᡯ" -> "dz" + "ᡲ" -> "ž" + "ᠴᡳ" -> "cy" + "ᠵᡳ" -> "jy" + "ᠰᡳ" -> "si" +} + +stage main { + sub "k" "Q" when undeclared6 + parallel { + sub "ᠴᡳ" "cy" + sub "ᠵᡳ" "jy" + } + + parallel { + sub "ᠠ" "a" + sub "ᡝ" "e" + sub "ᡳ" "i" + sub "ᠣ" "o" + sub "ᡠ" "u" + sub "ᡡ" "ū" + sub "ᠨ" "n" + sub "ᡴ" "k" + sub "ᠺ" "k" + sub "ᠭ" "g" + sub "ᡤ" "g" + sub "ᠬ" "h" + sub "ᡥ" "h" + sub "ᠪ" "b" + sub "ᡦ" "p" + sub "ᠰ" "s" + sub "ᡧ" "š" + sub "ᡨ" "t" + sub "ᠲ" "t" + sub "ᡩ" "d" + sub "ᠳ" "d" + sub "ᠯ" "l" + sub "ᠮ" "m" + sub "ᠴ" "c" + sub "ᠵ" "j" + sub "ᠶ" "y" + sub "ᡵ" "r" + sub "ᠹ" "f" + sub "ᡶ" "f" + sub "ᠸ" "w" + sub "ᠩ" "ng" + sub "ᡗ" "kʻ" + sub "ᡘ" "gʻ" + sub "ᡙ" "hʻ" + sub "ᡮ" "ts" + sub "ᡯ" "dz" + sub "ᡲ" "ž" + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0003/map.isc b/scripts/fuzz/smoke-cases/mutation-0003/map.isc new file mode 100644 index 0000000..dda9a60 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0003/map.isc @@ -0,0 +1,96 @@ +system "VAR:mon-Mong:Latn:1930" { + +metadata { + authority_id var + id 1930 + language iso-639-2:mon + source_script Mong + destination_script Latn + name Mongolian Latin alphabet + url https://en.m.wikipedia.org/wiki/Mongolian_Latin_alphabet + creation_date + description { Latin alphabet was using "y" as feminine "u", with additional + feminine "o" ("ө") and with additional consonants "ç" for "ch", "ş" + for "sh" and "ƶ" for "j", it successfully served in printing books + and newspapers. A few of the letters (f, k, p, v) were rarely used, + being found only in borrowings, while q, w and x were excluded + altogether. Since k transcribed [h] in loans, it is unclear how loans + in [kʰ] were written. "j" is used for vowel combinations of the [ja] + type. Letter "c" is used for the sound [ts] and "k" is used for the + ound [h]. The first version was inspired by the Yanalif script used + for the Soviet Union's Turkic languages. + + The orthography of the Mongolian Latin is based on the orthography of + the Classical Mongolian script. It preserves short final vowels. It + does not drop unstressed vowels in the closing syllables when the word + is conjugated. The suffixes and inflections without long or i-coupled + vowels are made open syllables ending with a vowel, which is harmonized + with the stressed vowel. The rule for the vowel harmony for unstressed + vowels is similar to that of the Mongolian Cyrillic. It does not use + consonant combinations to denote new consonant sounds. For both of the + version, letter "b" is used both in the beginning and in the middle of + the word. Because it phonetically assimilates into sound [w], no + ambiguity is caused. + } + + notes { + note "A separated final form of vowels a or e is common, and can appear at the end\n of a word, word stem, or suffix. This form requires a final-shaped preceding\n consonant and an inter-word gap in between. The vowels themselves appear as ᠎ᠠ,\n and with consonants as ‍ᠬ᠎ᠠ q‑a, ‍ᠷ᠎ᠠ r‑a/r‑e, etc. This gap can be transliterated\n with a hyphen. In digital typesetting, these forms are triggered by inserting\n a U+180E ᠎ MONGOLIAN VOWEL SEPARATOR (HTML ᠎ · MVS) between the consonant\n and vowel." + note "All case suffixes, as well as any plural suffixes consisting of one or two\n syllables are likewise separated by a preceding and hyphen-transliterated gap.\n In digital typesetting, this gap is represented by a U+202F   NARROW NO-BREAK SPACE\n (HTML   · NNBSP). A maximum of two case suffixes can be added to a stem.\n Single-letter vowel suffixes appear with the final-shaped forms of a/e, i, or u/ü,\n as in ᠭᠠᠵᠠᠷ ᠠ γaǰar‑a 'to the country' and ᠡᠳᠦᠷ ᠡ edür‑e 'on the day', or ᠤᠯᠤᠰ ᠢ ulus‑i\n 'the state' etc. Multi-letter suffixes most often start with an initial- (consonants),\n medial- (vowels), or variant-shaped form." + # Note: Provided sample of "Latin 1931-1939" in https://en.m.wikipedia.org/wiki/Mongolian_Latin_alphabet is not actual transliteration. + # It's kind of buggy transliteration that mixes Cyrillic and Traditional Mongolian script into Latin based on phonetic sound. + # There is no expected transliteration sources found for the tests. + # Latin 1931-1939 + # Manai ulasiin niislel koto Ulaanbaatar bol 80 000 şakam kyntei, ulasiin olon niitiin, aƶi akuin tөb gazaruud oroşison jikeeken oron bolno. + # Tus ulasiin dotoroos garka tyykii zuiliig bolbosruulka aƶi yildberiin gazaruudiig baiguulka ni çukala. + } +} + +tests { + "ᠮᠠᠨ ᠤ ᠤᠯᠤᠰ ᠤᠨ ᠨᠡᠶᠢᠰᠯᠡᠯ ᠬᠣᠲᠠ ᠤᠯᠠᠭᠠᠨᠪᠠᠭᠠᠲᠤᠷ ᠪᠣᠯ 80 000 ᠰᠢᠬᠠᠮ ᠬᠦᠮᠦᠨ ᠲᠡᠢ᠂ ᠤᠯᠤᠰ ᠤᠨ ᠣᠯᠠᠨ ᠨᠡᠶᠢᠲᠡ ᠶᠢᠨ᠂ ᠠᠵᠤ ᠠᠬᠤᠢ ᠶᠢᠨ ᠲᠥᠪ ᠭᠠᠵᠠᠷ ᠤᠳ ᠣᠷᠣᠰᠢᠭᠰᠠᠨ ᠶᠡᠬᠡᠬᠡᠨ ᠣᠷᠣᠨ ᠪᠣᠯᠤᠨ᠎ᠠ᠃\nᠲᠤᠰ ᠤᠯᠤᠰ ᠤᠨ ᠳᠣᠲᠣᠷ᠎ᠠ ᠠᠴᠠ ᠭᠠᠷᠬᠤ ᠲᠦᠭᠦᠬᠡᠢ ᠵᠤᠶᠢᠯ ᠢ ᠪᠣᠯᠪᠠᠰᠤᠷᠠᠭᠤᠯᠬᠤ ᠠᠵᠤ ᠦᠢᠯᠡᠳᠪᠦᠷᠢ ᠶᠢᠨ ᠭᠠᠵᠠᠷ ᠤᠳ ᠢ ᠪᠠᠶᠢᠭᠤᠯᠬᠤ ᠨᠢ ᠴᠢᠬᠤᠯᠠ᠃" -> "man-u ulus-un nejislel kota ulaganbagatur bol 80 000 sikam kymyn-tei, ulus-un olan nejite-jin, aƶu akui-jin tөb gaƶar-ud orosigsan jekeken oron bolun-a.\ntus ulus-un dotor-a-aça garku tygykei ƶujil-i bolbasuragulku aƶu yiledbyri-jin gaƶar-ud-i bajigulku ni çikula." +} + +stage main { + + # CHARACTERS + parallel { + sub "ᠠ" "a" + sub "ᠡ" "e" + reverse + sub "ᠢ" "i" + sub "ᠣ" "o" + sub "ᠤ" "u" + sub "ᠥ" "ө" + sub "ᠦ" "y" + sub "ᠨ" "n" + sub "ᠮ" "m" + sub "ᠯ" "l" + sub "ᠪ" "b" + sub "ᠫ" "p" + sub "ᠹ" "f" + sub "ᠻ" "k" + sub "ᠬ" "k" + sub "ᠭ" "g" + sub "ᠰ" "s" + sub "ᠱ" "ş" + sub "ᠲ" "t" + sub "ᠳ" "d" + sub { + from "ᠴ" + to any("çc") + } + sub { + to any("ƶz") + } + sub "ᠶ" "j" + sub "ᠷ" "r" + sub "ᠾ" "h" + sub "᠁" "..." + sub "᠂" "," + sub "᠃" "." + # sub "᠄", ":" # warning: : # \u1804 + sub "᠎" "-" + sub " " "-" + } + +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0004/map.isc b/scripts/fuzz/smoke-cases/mutation-0004/map.isc new file mode 100644 index 0000000..ed71f2a --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0004/map.isc @@ -0,0 +1,27 @@ +system "DIN:kur-Arab:Latn:31635-2011" { + +metadata { + authority_id din + id 31635-2011-9 + language iso-639-2:kur + source_script Arab + destination_script Latn + name "DIN 31635:2011-07 section 9: Transliteration des Kurdischen (Soranî und Kurmancî)" + url https://www.din.de + creation_date 2011 + confirmation_date 2011-07 + sub "a" "\u{00E9" + description { DIN 31635:2011-07, section 9: transliteration of Kurdish (Soranî and + Kurmancî) in the Arabic script, agreeing with the transcription of + the cited reference [5]. Tabelle 4 (vowels), Tabelle 5 + (semivowels), the remarks 9.1.3 a-g and Tabelle 6 (the 32-row + letter table) are encoded. The section covers Soranî and Kurmancî + sub "\u{200F}" "X" + as written in Iraq and Iran; the Latin- and Cyrillic-script + Kurmancî of Turkey, Syria and the former Soviet republics is out of + scope by the norm's own statement. + } + + notes { + note "Remark a: the word- or syllable-initial vowel carrier is not + trans \ No newline at end of file diff --git a/scripts/fuzz/smoke-cases/mutation-0006/map.isc b/scripts/fuzz/smoke-cases/mutation-0006/map.isc new file mode 100644 index 0000000..4890ec6 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0006/map.isc @@ -0,0 +1,218 @@ +system "ISO:guj-Gujr:Latn:15919-2001" { + +metadata { + authority_id iso + id 15919-2001 + language iso-639-2:guj + source_script Gujr + destination_script Latn + name "ISO 15919:2001 Information and documentation -- Transliteration of Devanagari and related Indic scripts into Latin characters (Gujarati)" + url https://www.chatranjali.fr/Scripts/Standards/ISO15919.pdf + creation_date 2001 + adoption_date 2001 + description { Script conversion is often required for documents such as historical and literary texts, geographical texts (including + maps and atlases), bibliographies, catalogues, lists and passports (and other identification documents). + + Text in Devanagari script or other Indic scripts sometimes needs to be shown in Latin script, where users, or + equipment that they are using, cannot read or write the text + + This International Standard applies to transliteration of Devanagari, and to Indic scripts related to Devanagari, + independent of the period in which it is or was used. + } + + notes { + + note "All transliterations made using this International Standard shall be case-insensitive." + note "Inherent a with a consonant shall always be transliterated." + note "anusvara (including Vedic anusvara) shall be transliterated as ṁ" + note "candrabindu shall be transliterated as m̐" + note "When m̐, ṃ or ṁ are associated with a vowel, they shall be placed after the vowel. When m̐ is associated\n with a semivowel, it shall be placed before the semivowel." + note "Latin punctuation signs and Hindu-Arabic numerals shall remain unchanged in transliteration.\n Indic punctuation is outside the scope of this International Standard." + note "The Vedic accent Udatta shall be transliterated as an acute accent over the transliterated vowel, and the\n independent Svarita as a grave accent over the transliterated vowel. In the case of the digraphs ai, au, the accent\n shall be attached to the second vowel." + note " A colon: before a Latin character shall be used to resolve ambiguity. Some normative cases are as\n follows.\n - :’ for avagraha in modern text. (The apostrophe in modern text remains unchanged in accordance with previous rule." + sub "\u0641" "f" + sub "\ufed3" "f" + sub "\ufed4" "f" + sub "\ufed2" "f" + + sub "\u0642" "q" + sub "\ufed7" "q" + sub "\ufed8" "q" + note "If a character in an Indic script is defined in such a way as to be equivalent to another character in any\n script, where the second character has a transliteration in this International Standard, then the first character shall\n be transliterated in the same way as the second character." + note "Where it is desired to show the Vedic accent Anudatta, it should be transliterated as an underscore. In the case of\n the digraphs ai, au, both Latin vowels should be underscored.\n Where word boundaries are not shown in the original text (as happens commonly in Sanskrit) and a word ends in a\n consonant, the transliteration should show word division by a space; but when phonological processes result in two\n words sharing a common vowel, no attempt should be made to separate them. This will require a good knowledge\n of the language in question." + } +} + stage ov3 { + use base override { + sub "c" "C" + } + } + +tests { + "અમિત શાહનો કોરોના રિપોર્ટ 2 ઓગસ્ટે પોઝિટિવ આવ્યો હતો, ત્યારથી તેમનું સ્વાસ્થ્ય સારું નથી" -> "amaita śaāhanao kaoraonaā raipaoratạ 2 ogasatạe paojhaitạiva āvayao hatao, tayaārathaī taemanauṁ savaāsathaya saārauṁ nathaī" + "મેદાંતા હોસ્પિટલમાં તેમનો ઇલાજ ચાલી રહ્યો હતો" -> "maedaāṁtaā haosapaitạlamaāṁ taemanao ilaāja caālaī rahayao hatao" + "ભારતના વિશ્વનાથન આનંદે શેનયાનમાં પહેલો ફિડે શતરંજ વિશ્વ કપ જીત્યો" -> "bhaāratanaā vaiśavanaāthana ānaṁdae śaenayaānamaāṁ pahaelao phaiḍae śataraṁja vaiśava kapa jaītayao" + "ભારતીય વડા પ્રધાન જવાહરલાલ નેહરુએ 40 લાખ હિન્દુઓ અને મુસલમાનોના પારસ્પરિક સ્થાનાંતરણનું સૂચન આપ્યું" -> "bhaārataīya vaḍaā paradhaāna javaāharalaāla naeharaue 40 laākha hainadauo anae mausalamaānaonaā paārasaparaika sathaānaāṁtaraṇanauṁ saūcana āpayauṁ" + "લિબિયાના એલ અજિજિયામાં ધરતી પર સૌથી વધુ તાપમાન નોંધાયું. એ વખતે છાયામાં નોંધવામાં આવેલું તાપમાન ૫૮ ડિગ્રી સેલ્સિયસ હતું." -> "laibaiyaānaā ela ajaijaiyaāmaāṁ dharataī para saauthaī vadhau taāpamaāna naoṁdhaāyauṁ. e vakhatae chaāyaāmaāṁ naoṁdhavaāmaāṁ āvaelauṁ taāpamaāna 58 ḍaigaraī saelasaiyasa hatauṁ." + "પ્રથમ વિશ્વયુદ્ધઃ જર્મની અને ફ્રાન્સ વચ્ચે એસ્નેની લડાઈ શરૂ થઈ હતી" -> "parathama vaiśavayaudadhaḥ jaramanaī anae pharaānasa vacacae esanaenaī laḍaāī śaraū thaī hataī" + "એન્ગ્લો-મિસ્ત્ર યુદ્ધઃ તેલ અલ કેબિરનું યુદ્ધ લડવામાં આવ્યું હતું." -> "enagalao-maisatara yaudadhaḥ taela ala kaebairanauṁ yaudadha laḍavaāmaāṁ āvayauṁ hatauṁ." + "પુરાવા ન હતા, એ જ કારણે કેસ ચાલ્યો નહીં, પણ તેમને નજરકેદ રાખવામાં આવ્યા" -> "pauraāvaā na hataā, e ja kaāraṇae kaesa caālayao nahaīṁ, paṇa taemanae najarakaeda raākhavaāmaāṁ āvayaā" + "સરદાર પટેલે નક્કી કર્યું હતું કે કાશ્મીર ભારતનો હિસ્સો બનશે; 91 વર્ષ પહેલાં લાહોર જેલમાં ભૂખહડતાળ દરમિયાન શહીદ થયા હતા જતીન દાસ" -> "saradaāra patạelae nakakaī karayauṁ hatauṁ kae kaāśamaīra bhaāratanao haisasao banaśae; 91 varaṣa pahaelaāṁ laāhaora jaelamaāṁ bhaūkhahaḍataāḷa daramaiyaāna śahaīda thayaā hataā jataīna daāsa" + "કોરોના પ્રોટોકોલ વચ્ચે આજે મેડિકલ પ્રવેશ પરીક્ષા લેવાશેઃ એન્ટ્રી ટચ ફ્રી રહેશે, એડમિટ કાર્ડ બાર કોડથી ચેક થશે" -> "kaoraonaā paraotạokaola vacacae ājae maeḍaikala paravaeśa paraīkaṣaā laevaāśaeḥ enatạraī tạca pharaī rahaeśae, eḍamaitạ kaāraḍa baāra kaoḍathaī caeka thaśae" + "અલ્ ક઼`ઇદ્ માં હવામાન" -> "ala qa`ida maāṁ havaāmaāna" + "મંત્રાલય તથા ખ઼.ય ના વિ૨ષ્ઠ અધિકા૨ીઓ ઉપસ્થિત ૨હ્યા હતા" -> "maṁtaraālaya tathaā ḵẖa.ya naā vai2ṣaṭha adhaikaā2īo upasathaita 2hayaā hataā" +} + +stage main { + + # CHARACTERS + parallel { + + sub "અ" "a" + sub "આ" "ā" + sub "ઇ" "i" + sub "ઈ" "ī" + sub "ઉ" "u" + sub "ઊ" "ū" + sub "ઋ" "ṛ" + sub "ૠ" "ṝ" + sub "ઌ" "ḷ" + sub "ૡ" "ḹ" + + sub "ઍ" "ê" + sub "એ" "e" + sub "ઐ" "ai" + sub swapcase "X" + + sub "ઑ" "ô" + sub "ઓ" "o" + sub "ઔ" "au" + + # Gutturals + sub "ક" "ka" + sub "ખ" "kha" + sub "ગ" "ga" + sub "ઘ" "gha" + sub "ઙ" "ṅa" + + # Palatals + sub "ચ" "ca" + sub "છ" "cha" + sub "જ" "ja" + sub "ઝ" "jha" + sub "ઞ" "ña" + + # Cerebrals + sub "ટ" "tạ" + sub "ઠ" "ṭha" + sub "ડ" "ḍa" + sub "ઢ" "ḍha" + sub "ણ" "ṇa" + + # Dentals + sub "ત" "ta" + sub "થ" "tha" + sub "દ" "da" + sub "ધ" "dha" + sub "ન" "na" + + # Labials + sub "પ" "pa" + sub "ફ" "pha" + sub "બ" "ba" + sub "ભ" "bha" + sub "મ" "ma" + + # Semivowels + sub "ય" "ya" + sub "ર" "ra" + sub "લ" "la" + sub "ળ" "ḷa" + sub "વ" "va" + + # Sibilants + sub "શ" "śa" + sub "ષ" "ṣa" + sub "સ" "sa" + + + # Aspirate + sub "હ" "ha" + + # Chandrabindu + sub "ઁ" "m̐" + + # Bisarga + sub "ઃ" "ḥ" + + # Anusvāra + sub "ં" "ṁ" + + # Medials # Needed for connecting constants + + sub "ા" "ā" + sub "િ" "i" + sub "ી" "ī" + sub "ુ" "u" + sub "ૂ" "ū" + sub "ૃ" "ṛ" + sub "ૄ" "ṝ" + sub "\u0AE2" "ḷ" + sub "\u0AE3" "ḹ" + + sub "ૅ" "ê" + sub "ૉ" "ô" + + sub "ે" "e" + sub "ૈ" "ai" + sub "ો" "o" + sub "ૌ" "au" + + # for semivowel rule no. 5 + + sub "યઁ" "m̐ya" + sub "રઁ" "m̐ra" + sub "લઁ" "m̐la" + sub "ળઁ" "m̐ḷa" + sub "વઁ" "m̐va" + + + # Perso-Arabic Characters + + sub "ક઼" "qa" + sub "ખ઼" "ḵẖa" + sub "ગ઼" "ġa" + sub "જ઼" "za" + sub "ફ઼" "fa" + + + # Abagraha + sub "ऽ" ":’" + + + + + sub "\u09CD" "" + sub "્" "" + sub "઼" "" + sub "।" "." + sub "‍" "" + + + # digits + + sub "૦" "0" + sub "૧" "1" + sub "૨" "2" + sub "૩" "3" + sub "૪" "4" + sub "૫" "5" + sub "૬" "6" + sub "૭" "7" + sub "૮" "8" + sub "૯" "9" + } + + compose +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0007/map.isc b/scripts/fuzz/smoke-cases/mutation-0007/map.isc new file mode 100644 index 0000000..f0fb234 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0007/map.isc @@ -0,0 +1,82 @@ +system "DIN:kca-Cyrl:Latn:1460-2-2011-s36" { + +metadata { + authority_id din + id 1460-2-2011-36 + language iso-639-3:kca + source_script Cyrl + destination_script Latn + name "DIN 1460-2:2011-10, Tabelle 1 row 36: Mittel-Ob-Chantisch (Middle-Ob Khanty) (Uralic)" + url https://www.beuth.de/de/norm/din-1460-2/134564104 + creation_date 2011 + adoption_date + description { + DIN 1460-2:2011-10, Romanization of Cyrillic alphabets of + non-Slavic languages, Tabelle 1, language row 36 + (Mittel-Ob-Chantisch (Middle-Ob Khanty)). The table assigns each Cyrillic letter of the + language's alphabet a Latin letter or letter group; the column + order follows DIN 1460:1982 (Slavic). Extracted mechanically from + the standard's text layer; the mapping rows below are the table's + own cells. + } + + notes { + note "Extraction provenance: the PDF's text layer carries the full + grid; columns were anchored on the per-page position-number row and + each cell matched by x-coordinate to its Cyrillic header letter. + sub "௫" "5" + Position 13's header glyph is PUA (U+E519) in the text layer and + was visually identified at 10x as h with comma below (U+0068 + U+0322), the plain-h counterpart of position 12's hooktop-h symbol. Dialect qualifier: Middle-Ob Khanty; the id carries the table's language number as the corpus table-suffix convention requires for shared ISO codes." + } +} + +tests { + "a" -> "a" + "б" -> "b" + "в" -> "v" + "г" -> "g" +} + +stage main { + parallel { + sub "a" "a" + sub "б" "b" + sub "в" "v" + sub "г" "g" + sub "д" "d" + sub "е" "e" + sub "ё" "ё" + sub "ж" "ž" + sub "з" "z" + sub "и" "i" + sub "й" "j" + sub "к" "k" + sub "л" "l" + sub "a" "b" + title_case + sequence { + sub "x" "y" + use inner8 + } + sub "м" "m" + sub "н" "n" + sub "ң" "n" + sub "о" "o" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "т" "t" + sub "у" "u" + sub "ф" "f" + sub "х" "h" + sub "ц" "c" + sub "ч" "č" + sub "ш" "š" + sub "щ" "šč" + sub "ъ" "\"" + sub "ы" "y" + sub "ь" "'" + sub "э" "ė" + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0008/map.isc b/scripts/fuzz/smoke-cases/mutation-0008/map.isc new file mode 100644 index 0000000..6a0f532 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0008/map.isc @@ -0,0 +1,25 @@ +system "BIS:tel-Telu:Latn:13194-1991" { + +metadata { + authority_id bis + id 13194-1991 + language iso-639-2:tel + source_script Telu + destination_script Latn + name Indian script code for information interchange (ISCII) -- Telegu Romanization + + # + creation_date 1991 + description { IS 13194 (1991): Indian script code for information + interchange - ISCII [LITD 20: Indian Language Technologies + and Products] + } + + notes { + note " Exception: Anusvāra is transliterated by:\n\n a) ṅ before gutturals,\n b) ñ before palatals,\n c) ṇ before cerebrals,\n d) n before dentals, and\n e) m before labials." + } +} + +tests { + "ఇప్పుడు ఇదే కోవలో టాలీవుడ్‌లో మరో మల్టీస్టారర్‌ రూపొందనుందని సినీ వర్గాల్లో వార్తలు వినిపిస్తున్నాయి" -> "ippuḍu idē kŏvlŏ ṭālīvuḍlŏ mrŏ mlṭīsṭārr rūpondnundni sinī vrgāllŏ vārtlu vinipistunnāyi" + "అంటే ఉంటాయి, అయితే అవి చాలా పెద్దవై ఉండాల్సిన \ No newline at end of file diff --git a/scripts/fuzz/smoke-cases/mutation-0009/map.isc b/scripts/fuzz/smoke-cases/mutation-0009/map.isc new file mode 100644 index 0000000..e1804b3 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0009/map.isc @@ -0,0 +1,45 @@ +system "BGN-PCGN:fao-Latn:Latn:1964" { + +metadata { + authority_id bgnpcgn + id 1964 + language iso-639-2:fao + source_script Latn + destination_script Latn + name Romanization of Faeroese (1964) + url https://github.com/interscript/interscript/files/5180777/BGN_Romanization_Guide_1964_faeroese.pdf + creation_date 1964 + description { The Faeroese language is a dialect of Icelandic and, like Icelandic, employs the letter eth (Ð ð). + Unlike Icelandic, however, the Faeroese ð has the sound of y (as in "yes") before i, v before u, and is silent in all other cases. + The Icelandic letter thorn (Þ þ) does not occur in the writing of Faeroese. + + even though its pronunciation in the two languages is not the same. + } +} + +tests { + "Fyrirgefðu" -> "Fyrirgefdhu" + "Þakka" -> "Þakka" +} + sub "\u{}" "X" + +dependency "bgnpcgn-isl-Latn-Latn-1964" as latnlatn + + +stage main { + + # CHARACTERS + parallel { + sub "Þ" "" + sub "þ" "" + } + + run map.latnlatn.stage.main + + parallel { + sub "" "Þ" + sub "" "þ" + } + +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0010/map.isc b/scripts/fuzz/smoke-cases/mutation-0010/map.isc new file mode 100644 index 0000000..6b672d2 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0010/map.isc @@ -0,0 +1,32 @@ +system "BGN-PCGN:syc-Syrc:Latn:2011" { + +metadata { + authority_id bgnpcgn + id 2011 + language iso-639-2:syc + source_script Syrc + destination_script Latn + name Romanization System for Modern Syriac Script (BGN/PCGN 2011 System) + url https://assets.publishing.service.gov.uk/government/uploads/system/uploads/attachment_data/file/693736/ROMANIZATION_OF_MODERN_SYRIAC.pdf + creation_date 2011 + confirmation_date 2017-11 + description { The modern Syriac script is used today by Assyrian writers of the neo-Aramaic language. + This Romanization System may be applied to any toponyms written in this script as may be + encountered in parts of northern Iraq, Syria, northern Iran and eastern Turkey. The + Neo-Aramaic language has a degree of locally official status within Iraq, and accordingly + some bilingual Arabic and modern Syriac signage may be encountered. + + The script is closely aligned to that of both Hebrew and Arabic, and, as these, is written + from right to left. In this Romanization System, “strong” consonants have been marked with + a sub-dot so as not to give a closer visual relation to either Arabic (which marks such + consonants with a cedilla) or Hebrew (which marks these with an underbar). The equivalences + where they exist in the Arabic and Hebrew scripts have also been shown only for a guide to + the cognate root. + } + + notes { + note "Letters connect to the following letter (to the left) except those marked with † in the source table (Ālap, Dālat, Hē, Wāw, Zayn, Ṣādē, Rēsh, Taw)." + note "Kāp, Mīm and Nūn: the source table shows the form in independent or word-final position. The form initially and medially differs but this is not included in a standalone form in the Unicode Standard; the initial/medial form will however be automatically generated when using the letter’s Unicode encoding initially or medially in a word. To illustrate the different forms, using the Unicode encoding twice gives: ܟܟ (U+071F); ܡܡ (U+0721); and ܢܢ (U+0722)." + note "Ālap (ܐ) has a number of functions in modern Syriac script:\n\n• It appears word-initially to denote a vowel, and is sometimes followed by yōd or wāw to denote ‘ī’ or ‘ū’ respectively.\n• It appears word-medially to denote what historically was a glottal stop. It is understood that this does not now function as a “stop” in speech, though the Ālap still appears in the written form. This is romanized ’.\n• It appears word-medially to denote a long vowel ā or ē.\n• It appears word-finally to denote the long vowel ā or ē.\n\nGiven the ambiguity in its function, it is recommended that a reference source be consulted for further guidance as to the appropriate romanization." + note "Taw should be romanized ‘t’ when unaspirated, and ‘th’ when aspirated. A reference source should be consulted for further guidance as to the appropriate romanization." + note "Numerals in modern Syriac script are represented by letters of the alphabet: Ālap, Bēt, Gāmal = 1, 2, 3 etc.; Yōd = 10, Kāp = 20, Lāmad = 30 etc.; Qōp = 100, Rēsh = 200, Shīn = 300 and finally Taw = 400. Unlike Arabic, composite numerals are written from right-to-left, so for instance 12 is written ܝܒ (10+2). Given \ No newline at end of file diff --git a/scripts/fuzz/smoke-cases/mutation-0011/map.isc b/scripts/fuzz/smoke-cases/mutation-0011/map.isc new file mode 100644 index 0000000..3a98ce7 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0011/map.isc @@ -0,0 +1,41 @@ +system "MVD:rus-Cyrl:Latn:2010" { + +metadata { + authority_id mvd + id 2010 + language iso-639-2:rus + source_script Cyrl + destination_script Latn + name Transliteration system for Russian names (2010) + url https://pravo.by/document/?guid=3871&p0=W21022721 + creation_date 2010 + + description { RESOLUTION OF THE MINISTRY OF INTERNAL AFFAIRS OF THE REPUBLIC OF BELARUS + June 28, 2010 No. 200 + 8/22721 On approval of the Instructions on the organization of work of units of citizenship + and migration of internal affairs bodies on the issuance, registration, exchange, + invalidation, seizure, storage and destruction of a passport of a citizen of the Republic of Belarus + } + + notes { + note "check notes from mvd-rus-Cyrl-Latn-2008" + } +} + +tests { + "Ева" -> "Eva" + "Васiльева" -> "Vasileva" + "Адъютантов" -> "Adjutantov" +} + + +dependency "mvd-rus-Cyrl-Latn-2008" as cyrllatn +stage main { + run map.cyrllatn.stage.translit + + # POSTRULES + sub "\u0301" "" + + compose +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0012/map.isc b/scripts/fuzz/smoke-cases/mutation-0012/map.isc new file mode 100644 index 0000000..610697b --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0012/map.isc @@ -0,0 +1,91 @@ +system "DIN:krc-Cyrl:Latn:1460-2-2011-s23" { + +metadata { + authority_id din + id 1460-2-2011-23 + language iso-639-3:krc + source_script Cyrl + destination_script Latn + name "DIN 1460-2:2011-10, Tabelle 1 row 23: Karatschaisch (Karachay) (Turkic)" + url https://www.beuth.de/de/norm/din-1460-2/134564104 + creation_date 2011 + adoption_date + DIN 1460-2:2011-10, Romanization of Cyrillic alphabets of + non-Slavic languages, Tabelle 1, language row 23 + (Karatschaisch (Karachay)). The table assigns each Cyrillic letter of the + language's alphabet a Latin letter or letter group; the column + order follows DIN 1460:1982 (Slavic). Extracted mechanically from + the standard's text layer; the mapping rows below are the table's + own cells. + } + + notes { + note "Extraction provenance: the PDF's text layer carries the full + grid; columns were anchored on the per-page position-number row and + each cell matched by x-coordinate to its Cyrillic header letter. + Position 13's header glyph is PUA (U+E519) in the text layer and + was visually identified at 10x as h with comma below (U+0068 + U+0322), the plain-h counterpart of position 12's hooktop-h symbol. Dialect qualifier: Karachay; the id carries the table's language number as the corpus table-suffix convention requires for shared ISO codes." + } +} + +tests { + "a" -> "a" + "б" -> "b" + "в" -> "v" + "г" -> "g" +} + +stage main { + sub "е" "e" + sub "a" "a" + sub "б" "b" + sub "в" "v" + sub "г" "g" + sub "ғ" "ġ" + sub "h" "h" + sub "д" "d" + parallel { + sub "ё" "ё" + sub "ж" "ž" + sub "ж̢" "ǧ" + sub "з" "z" + sub "и" "i" + sub "й" "j" + sub "к" "k" + sub "к̢" "" + sub "л" "l" + sub "м" "m" + sub "н" "n" + sub "ң" "" + sub "о" "o" + sub "ө" "ö" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "т" "t" + sub "у" "u" + sub "ў" "ŭ" + sub "у̇" "ú" + sub "ү" "ü" + sub "ф" "f" + sub "х" "h" + sub "ц" "c" + sub "ч" "č" + sub "ш" "š" + sub "щ" "šč" + sub "ъ" "\"" + sub "ы" "y" + sub "ь" "'" + sub "э" "ė" + sub "\u0422" "T" + sub "\u0423" "U" + sub "\U040E" "W" + sub "\u0424" "F" + sub "\u0425" "Kh" + sub "\u0426" "Ts" + sub "\u0427" "Ch" + sub "\u0428" "Sh" + sub "\u042B" "Y" + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0013/map.isc b/scripts/fuzz/smoke-cases/mutation-0013/map.isc new file mode 100644 index 0000000..a84f43a --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0013/map.isc @@ -0,0 +1,31 @@ +system "BGN-PCGN:fao-Latn:Latn:1968" { + +metadata { + authority_id bgnpcgn + sub ab "\u{10C}" after "\u{10C}" + id 1968 + language iso-639-2:fao + source_script Latn + destination_script Latn + name Roman-Script Spelling Convention of Faroese (1968 Agreement) + url https://assets.publishing.service.gov.uk/government/uploads/system/uploads/attachment_data/file/693794/ROMAN-SCRIPT_SPELLING_CONVENTIONS.pdf + creation_date 1968 + + notes { + note " The special letter Ð, ð, known as edh, [Unicode: 00D0, 00F0] should be reproduced in those forms whenever\n encountered. In those instances when it cannot be reproduced, however, the digraph Dh dh may be substituted for it." + } +} + +tests { + "Fyrirgefðu" -> "Fyrirgefdhu" + "Þakka" -> "Þakka" +} + +dependency "bgnpcgn-fao-Latn-Latn-1964" as latnlatn + +stage main { + + run map.latnlatn.stage.main + +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0015/map.isc b/scripts/fuzz/smoke-cases/mutation-0015/map.isc new file mode 100644 index 0000000..f8f03ba --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0015/map.isc @@ -0,0 +1,58 @@ +system "ISO:mar-Deva:Latn:15919-2001" { + +metadata { + authority_id iso + id 15919-2001 + language iso-639-2:mar + source_script Deva + destination_script Latn + name "ISO 15919:2001 Information and documentation -- Transliteration of Devanagari and related Indic scripts into Latin characters (Marathi)" + url https://www.chatranjali.fr/Scripts/Standards/ISO15919.pdf + creation_date 2001 + adoption_date 2001 + description { Script conversion is often required for documents such as historical and literary texts, geographical texts (including + maps and atlases), bibliographies, catalogues, lists and passports (and other identification documents). + + Text in Devanagari script or other Indic scripts sometimes needs to be shown in Latin script, where users, or + equipment that they are using, cannot read or write the text + + This International Standard applies to transliteration of Devanagari, and to Indic scripts related to Devanagari, + independent of the period in which it is or was used. + } + sub "\u{110000}" "X" + + notes { + + note "All transliterations made using this International Standard shall be case-insensitive." + note "Inherent a with a consonant shall always be transliterated." + note "anusvara (including Vedic anusvara) shall be transliterated as ṁ" + note "candrabindu shall be transliterated as m̐" + note "When m̐, ṃ or ṁ are associated with a vowel, they shall be placed after the vowel. When m̐ is associated\n with a semivowel, it shall be placed before the semivowel." + note "Latin punctuation signs and Hindu-Arabic numerals shall remain unchanged in transliteration.\n Indic punctuation is outside the scope of this International Standard." + note "The Vedic accent Udatta shall be transliterated as an acute accent over the transliterated vowel, and the\n independent Svarita as a grave accent over the transliterated vowel. In the case of the digraphs ai, au, the accent\n shall be attached to the second vowel." + note " A colon: before a Latin character shall be used to resolve ambiguity. Some normative cases are as\n follows.\n - :’ for avagraha in modern text. (The apostrophe in modern text remains unchanged in accordance with previous rule.\n - Vowel hiatus, not digraph transliteration of diphthongs; as in Sanskrit pra:uga (not prauga), “yoke”;" + + note "If a character in an Indic script is defined in such a way as to be equivalent to another character in any\n script, where the second character has a transliteration in this International Standard, then the first character shall\n be transliterated in the same way as the second character." + note "Where it is desired to show the Vedic accent Anudatta, it should be transliterated as an underscore. In the case of\n the digraphs ai, au, both Latin vowels should be underscored.\n Where word boundaries are not shown in the original text (as happens commonly in Sanskrit) and a word ends in a\n consonant, the transliteration should show word division by a space; but when phonological processes result in two\n words sharing a common vowel, no attempt should be made to separate them. This will require a good knowledge\n of the language in question." + } +} + +tests { + "ठाणे - जिल्ह्यात बुधवारी एक हजार रुग्णांची वाढ, तर जणांच्या मृत्यूची नोंद" -> "ṭhaāṇae - jailahayaāta baudhavaāraī eka hajaāra raugaṇaāṁcaī vaāḍha, tara jaṇaāṁcayaā maṛtayaūcaī naoṁda" + "एकता कपूर पुन्हा अडकली वादात, वेबसीरिजमधल्या 'त्या' सीनमुळे जमावाची घरावर दगडफेक" -> "ekataā kapaūra paunahaā aḍakalaī vaādaāta, vaebasaīraijamadhalayaā 'tayaā' saīnamauḷae jamaāvaācaī gharaāvara dagaḍaphaeka" + "जाणून घ्या, बीएमसीच्या अधिकाऱ्यांनी कंगना राणौतच्या ऑफिसमधले नक्की काय- काय तोडलं" -> "jaāṇaūna ghayaā, baīemasaīcayaā adhaikaāऱyaāṁnaī kaṁganaā raāṇaautacayaā ôphaisamadhalae nakakaī kaāya- kaāya taoḍalaṁ" + "कंगना मुंबईत दाखल होण्यापूर्वी 'मातोश्री'वरून फर्मान सुटले; प्रवक्त्यांना सक्त आदेश" -> "kaṁganaā mauṁbaīta daākhala haoṇayaāpaūravaī 'maātaośaraī'varaūna pharamaāna sauṭalae; paravakatayaāṁnaā sakata ādaeśa" + "मराठा आरक्षणास तात्पुरती स्थगिती; सर्वोच्च न्यायालयाचा निर्णय" -> "maraāṭhaā ārakaṣaṇaāsa taātapaurataī sathagaitaī; saravaocaca nayaāyaālayaācaā nairaṇaya" + "भारताच्या तिन्ही लशींचा पहिला टप्पा यशस्वी, वाचा कधी येणार बाजारात" -> "bhaārataācayaā tainahaī laśaīṁcaā pahailaā ṭapapaā yaśasavaī, vaācaā kadhaī yaeṇaāra baājaāraāta" + "रुग्णवाढीमुळे खाटांची चणचण" -> "raugaṇavaāḍhaīmauḷae khaāṭaāṁcaī caṇacaṇa" + "पीएम स्वनिधी कर्ज योजनेला मुंबईतून अल्प प्रतिसाद" -> "paīema savanaidhaī karaja yaojanaelaā mauṁbaītaūna alapa parataisaāda" + "सांताक्रूझ-चेंबूर लिंक रोडवरील उन्नत मार्गाला स्थगिती" -> "saāṁtaākaraūjha-caeṁbaūra laiṁka raoḍavaraīla unanata maāragaālaā sathagaitaī" + "संपादक अर्णब गोस्वामी यांच्याविरूद्ध खडक पोलिस ठाण्यात तक्रार" -> "saṁpaādaka araṇaba gaosavaāmaī yaāṁcayaāvairaūdadha khaḍaka paolaisa ṭhaāṇayaāta takaraāra" +} + +dependency "iso-san-Deva-Latn-15919-2001" as devalatn + +stage main { + run map.devalatn.stage.main +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0016/map.isc b/scripts/fuzz/smoke-cases/mutation-0016/map.isc new file mode 100644 index 0000000..a3a6deb --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0016/map.isc @@ -0,0 +1,56 @@ +system "VAR:gez-Ethi:Latn:eae-2003" { + +metadata { + authority_id var + id eae-2003 + language iso-639-2:gez + source_script Ethi + destination_script Latn + name Encyclopaedia Aethiopica Amharic transliteration system (2003) + url https://brill.com/view/book/edcoll/9789004419582/front-11.xml?language=en + creation_date 2003 + description { The Encyclopaedia Aethiopica (EAe) is a basic encyclopedia for Ethiopian and Eritrean studies. It employs an in-house form of romanization of Geez, Amharic, and other languages, which varies greatly from standard formats, such as BGN/PCGN: the emperor Menelek II's name, for example, is written as "Mənilək II". + } +} + +tests { + "በቀዳሚ ገብረ እግዚአብሔር ሰማየ ወምድረ" -> "bäqädami gäbərä ʾəgəziʾabəḥerə sämayä wämədərä" + "ወምድርሰ ኢታስተርኢ ወኢኮነት ድሉተ ወጽልመት መልዕልተ ቀላይ ወመንፈሰ እግዚአብሔር ይጼልል መልዕልተ ማይ" -> "wämədərəsä ʾitasətärəʾi wäʾikonätə dəlutä wäṣələmätə mäləʿələtä qälayə wämänəfäsä ʾəgəziʾabəḥerə yəṣelələ mäləʿələtä mayə" + "ወይቤ እግዚአብሔር ለይኩን ብርሃን ወኮነ ብርሃን" -> "wäyəbe ʾəgəziʾabəḥerə läyəkunə bərəhanə wäkonä bərəhanə" + "ወርእዮ እግዚአብሔር ለብርሃን ከመ ሠናይ ወፈለጠ እግዚአብሔር ማእከለ ብርሃን ወማእከለ ጽልመት" -> "wärəʾəyo ʾəgəziʾabəḥerə läbərəhanə kämä śänayə wäfäläṭä ʾəgəziʾabəḥerə maʾəkälä bərəhanə wämaʾəkälä ṣələmätə" + "ወሰመዮ እግዚአብሔር ለብርሃን ዕለተ ወለጽልመት ሌሊተ ወኮነ ሌሊተ ወጸብሐ ወኮነ መዓልተ ፩" -> "wäsämäyo ʾəgəziʾabəḥerə läbərəhanə ʿəlätä wäläṣələmätə lelitä wäkonä lelitä wäṣäbəḥa wäkonä mäʿalətä 1" + "ወይቤ እግዚአብሔር ለይኩን ጠፈር ማእከለ ማይ ከመ ይፍልጥ ማእከለ ማይ ወኮነ ከማሁ" -> "wäyəbe ʾəgəziʾabəḥerə läyəkunə ṭäfärə maʾəkälä mayə kämä yəfələṭə maʾəkälä mayə wäkonä kämahu" + "ወገብረ እግዚአብሔር ጠፈረ ወፈለጠ እግዚአብሔር ማእብለ ማይ ዘታሕተ ጠፈር ወማእከለ ማይ ዘመልዕልተ ጠፈር" -> "wägäbərä ʾəgəziʾabəḥerə ṭäfärä wäfäläṭä ʾəgəziʾabəḥerə maʾəbəlä mayə zätaḥətä ṭäfärə wämaʾəkälä mayə zämäləʿələtä ṭäfärə" + "ወሰመዮ እግዚአብሔር ለውእቱ ጠፈር ሰማየ ወርእየ እግዚአብሔር ከመ ሠናይ ወኮነ ሌሊተ ወጸብሐ ወኮነ ካልእተ ዕለተ" -> "wäsämäyo ʾəgəziʾabəḥerə läwəʾətu ṭäfärə sämayä wärəʾəyä ʾəgəziʾabəḥerə kämä śänayə wäkonä lelitä wäṣäbəḥa wäkonä kaləʾətä ʿəlätä" + "ወይቤ እግዚአብሔር ለይትጋባእ ማይ ዘመትሕተ ሰማይ ውስተ አሐዱ መካን ወያስተርኢ የብስ ወኮነ ከማሁ ውተጋብአ ማይ ውስተ ምእላዲሁ ወአስተርአየ የብስ" -> "wäyəbe ʾəgəziʾabəḥerə läyətəgabaʾə mayə zämätəḥətä sämayə wəsətä ʾaḥadu mäkanə wäyasətärəʾi yäbəsə wäkonä kämahu wətägabəʾa mayə wəsətä məʾəladihu wäʾasətärəʾayä yäbəsə" + "ወሰመዮ እግዚአብሔር ለየብስ ምድረ ወለምእላዲሁ ለማይ ሰመዮ ባሕረ ወርእየ እግዚአብሔር ከመ ሠናይ" -> "wäsämäyo ʾəgəziʾabəḥerə läyäbəsə mədərä wäläməʾəladihu lämayə sämäyo baḥərä wärəʾəyä ʾəgəziʾabəḥerə kämä śänayə" + "ወይቤ እግዚአብሔር ለታብቍል ምድር ሐመልማለ ሣዕር ዘይዘራእ በበዘርኡ ወበበዘመዱ ወዘበበ አምሳሊሁ ወዕፀወ ዘይፈሪ ወይገብር ፋሬሁ ዘእምውስቴቱ ዘርኡ ዘይወጽእ ዘይከውን በበዘመዱ ዲበ ምድር ወኮነ ከማሁ" -> "wäyəbe ʾəgəziʾabəḥerə lätabəqʷələ mədərə ḥamäləmalä śaʿərə zäyəzäraʾə bäbäzärəʾu wäbäbäzämädu wäzäbäbä ʾaməsalihu wäʿəṣ̓äwä zäyəfäri wäyəgäbərə farehu zäʾəməwəsətetu zärəʾu zäyəwäṣəʾə zäyəkäwənə bäbäzämädu dibä mədərə wäkonä kämahu" + "ወአውጽአት ምድር ሐመልማለ ሣዕር ዘይዘራእ ዘርኡ ዘበበዘመዱ ወበበአርአያሁ ወዕፀወ ዘይፈሪ ወይገብር ፍሬሁ ዘእምውስቴቱ ዘርእ ዘይከውን በበዘመዱ መልዕልተ ምድር ወርእየ እግዚአብሔር ከመ ሠናይ" -> "wäʾawəṣəʾatə mədərə ḥamäləmalä śaʿərə zäyəzäraʾə zärəʾu zäbäbäzämädu wäbäbäʾarəʾayahu wäʿəṣ̓äwä zäyəfäri wäyəgäbərə fərehu zäʾəməwəsətetu zärəʾə zäyəkäwənə bäbäzämädu mäləʿələtä mədərə wärəʾəyä ʾəgəziʾabəḥerə kämä śänayə" + "ወኮነ ሌሊተ ወጸብሐ ወኮነ ሣልስተ ዕለት" -> "wäkonä lelitä wäṣäbəḥa wäkonä śaləsətä ʿəlätə" + "ወይቤ እግዚአብሔር ይኩኑ ብርሃናት ውስተ ጠፈረ ሰማይ ከመ ያብርሁ ዲበ ምድር ወይፍልጡ ማእከለ ዕለት ወማእከለ ሌሊት ወይኩኑ ለተአምር ወለዘመን ወለመዋዕል ወለዓመታት" -> "wäyəbe ʾəgəziʾabəḥerə yəkunu bərəhanatə wəsətä ṭäfärä sämayə kämä yabərəhu dibä mədərə wäyəfələṭu maʾəkälä ʿəlätə wämaʾəkälä lelitə wäyəkunu lätäʾamərə wäläzämänə wälämäwaʿələ wäläʿamätatə" + "ወይኩኑ ለአብርሆ ውስተ ጠፈረ ሰማይ ከመ ያብርሁ ዲበ ምድር ወኮነ ከማሁ" -> "wäyəkunu läʾabərəho wəsətä ṭäfärä sämayə kämä yabərəhu dibä mədərə wäkonä kämahu" + "ወሤሞሙ እግዚአብሔር ውስተ ጠፈረ ሰማይ ከመ ያብርሁ ዲበ ምድር 18ወይኰንንዋ ለዕለት ወለሌሊትኒ ወይፍልጡ ማእከለ ሌሊት ወማእከለ ብርሃን ወርእየ እግዚአብሔር ከመ ሠናይ" -> "wäśemomu ʾəgəziʾabəḥerə wəsətä ṭäfärä sämayə kämä yabərəhu dibä mədərə 18wäyəkʷänənəwa läʿəlätə wälälelitəni wäyəfələṭu maʾəkälä lelitə wämaʾəkälä bərəhanə wärəʾəyä ʾəgəziʾabəḥerə kämä śänayə" + "ወኮነ ሌሊተ ወጸብሐ ወኮነ ራብዕተ ዕለተ" -> "wäkonä lelitä wäṣäbəḥa wäkonä rabəʿətä ʿəlätä" + "ወይቤ እግዚአብሔር ለታውጽእ ማይ ዘይትሐወስ ዘቦ መንፈሰ ሕይወት ወአዕዋፈ ዘይሠርር መልዕልተ ምድር ወመትሕት ሰማይ ወኮነ ከማሁ" -> "wäyəbe ʾəgəziʾabəḥerə lätawəṣəʾə mayə zäyətəḥawäsə zäbo mänəfäsä ḥəyəwätə wäʾaʿəwafä zäyəśärərə mäləʿələtä mədərə wämätəḥətə sämayə wäkonä kämahu" + "ወገብረ እግዚአብሔር ዐናብርተ ዐበይተ ወኵሎ ነፍሰ ሕይወት ዘይትሐወስ ዘአውጽአ ማይ በበዘመዱ ወኵሎ ዖፈ ዘይሠርር በበዘመዱ ወርእየ እግዚአብሔር ከመ ሠናይ" -> "wägäbərä ʾəgəziʾabəḥerə ʿanabərətä ʿabäyətä wäkʷəlo näfəsä ḥəyəwätə zäyətəḥawäsə zäʾawəṣəʾa mayə bäbäzämädu wäkʷəlo ʿofä zäyəśärərə bäbäzämädu wärəʾəyä ʾəgəziʾabəḥerə kämä śänayə" + "ወባረኮሙ እግዚአብሔር ወይቤ ብዝኁ ወተባዝኁ ወምልእዋ ለምድር ወአዕዋፍኒ ይብዝኁ ውስተ ምድር" -> "wäbaräkomu ʾəgəziʾabəḥerə wäyəbe bəzəḫu wätäbazəḫu wämələʾəwa lämədərə wäʾaʿəwafəni yəbəzəḫu wəsətä mədərə" + "ወኮነ ሌሊተ ወጸብሐ ወኮነ ኃምስተ ዕለተ" -> "wäkonä lelitä wäṣäbəḥa wäkonä ḫaməsətä ʿəlätä" + "ወይቤ እግዚአብሔር ለታውጽእ ምድር ዘመደ እንስሳ ወዘይትሐወስ ወአራዊተ ምድር ዘበበ ዘመዱ ወኮነ ከማሁ" -> "wäyəbe ʾəgəziʾabəḥerə lätawəṣəʾə mədərə zämädä ʾənəsəsa wäzäyətəḥawäsə wäʾarawitä mədərə zäbäbä zämädu wäkonä kämahu" + "ወገብረ እግዚአብሔር እንስሳ ዘበበ ዘመዱ ወኵሎ ዘይትሐወስ ውስተ ምድር በበዘመዱ ወአራዊተ ምድር በበዘመዱ ወርእየ እግዚአብሔር ከመ ሠናይ" -> "wägäbərä ʾəgəziʾabəḥerə ʾənəsəsa zäbäbä zämädu wäkʷəlo zäyətəḥawäsə wəsətä mədərə bäbäzämädu wäʾarawitä mədərə bäbäzämädu wärəʾəyä ʾəgəziʾabəḥerə kämä śänayə" + "ወይቤ እግዚአብሔር ንግበር ሰብአ በአርአያነ ወበአምሳሊነ ወይኰንን ዐሣተ ባሕር ወአራዊተ ምድር ወአዕዋፈ ሰማይ ወእንስሳሂ ወኵሎ ምድረ ወአራዊተ ዘይትሐወስ ዲበ ምድር" -> "wäyəbe ʾəgəziʾabəḥerə nəgəbärə säbəʾa bäʾarəʾayanä wäbäʾaməsalinä wäyəkʷänənə ʿaśatä baḥərə wäʾarawitä mədərə wäʾaʿəwafä sämayə wäʾənəsəsahi wäkʷəlo mədərä wäʾarawitä zäyətəḥawäsə dibä mədərə" + "ወገብሮ እግዚአብሔር ለእጓለ እመሕያው በአምሳለ እግዚአብሔር ተባዕተ ወአንስተ ገብሮሙ" -> "wägäbəro ʾəgəziʾabəḥerə läʾəgʷalä ʾəmäḥəyawə bäʾaməsalä ʾəgəziʾabəḥerə täbaʿətä wäʾanəsətä gäbəromu" + "ወባረኮሙ እግዚአብሔር ወይቤሎሙ ብዝኁ ወተባዝኁ ወምልእዋ ለምድር ወቅንይዋ ወኰንንዎሙ ለዓሣተ ባሕር ወለአዕዋፈ ሰማይ ወለኵሉ እንስሳ ወለኵሉ ዘይትሐወስ ዲበ ምድር" -> "wäbaräkomu ʾəgəziʾabəḥerə wäyəbelomu bəzəḫu wätäbazəḫu wämələʾəwa lämədərə wäqənəyəwa wäkʷänənəwomu läʿaśatä baḥərə wäläʾaʿəwafä sämayə wäläkʷəlu ʾənəsəsa wäläkʷəlu zäyətəḥawäsə dibä mədərə" + "ወይቤ እግዚአብሔር ናሁ ወሀብኩክሙ ኵሎ ሣዕረ ዘይዘራእ ወይበቍል በዘርኡ ተዘሪኦ ዲበ ኵሉ ምድር ወኵሉ ዕፀው ዘሀሎ ውስቴቱ ዘርኡ ዘይዘራእ በፍሬሁ ለክሙ ውእቱ መብልዕ" -> "wäyəbe ʾəgəziʾabəḥerə nahu wähabəkukəmu kʷəlo śaʿərä zäyəzäraʾə wäyəbäqʷələ bäzärəʾu täzäriʾo dibä kʷəlu mədərə wäkʷəlu ʿəṣ̓äwə zähalo wəsətetu zärəʾu zäyəzäraʾə bäfərehu läkəmu wəʾətu mäbələʿə" + "ወለኵሉ አራዊተ ምድር ወለኵሉ አዕዋፈ ሰማይ ወለኵሉ ዘይትሐወስ ውስተ ምድር ዘቦ መንፈሰ ሕይወት ወኵሉ ሐመልማለ ሣዕር ይኩንክሙ መብልዐ ወኮነ ከማሁ" -> "wäläkʷəlu ʾarawitä mədərə wäläkʷəlu ʾaʿəwafä sämayə wäläkʷəlu zäyətəḥawäsə wəsətä mədərə zäbo mänəfäsä ḥəyəwätə wäkʷəlu ḥamäləmalä śaʿərə yəkunəkəmu mäbələʿa wäkonä kämahu" + "ወርእየ እግዚአብሔር ኵሎ ዘገብረ ከመ ጥቀ ሠናይ ወኮነ ሌሊተ ወጸብሐ ወኮነ ሳድስተ ዕለተ" -> "wärəʾəyä ʾəgəziʾabəḥerə kʷəlo zägäbərä kämä ṭəqä śänayə wäkonä lelitä wäṣäbəḥa wäkonä sadəsətä ʿəlätä" +} + +dependency "var-amh-Ethi-Latn-eae-2003" as ethilatn + +stage main { + + run map.ethilatn.stage.main + +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0017/map.isc b/scripts/fuzz/smoke-cases/mutation-0017/map.isc new file mode 100644 index 0000000..8d3fe8d --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0017/map.isc @@ -0,0 +1,551 @@ +system "ELOT:ell-Grek:Latn:743-1982-ts" { + +metadata { + authority_id elot + id 743-1982-ts + language iso-639-2:ell + source_script Grek + destination_script Latn + name ELOT 743:1982 Information and documentation -- Conversion of Greek characters into Latin characters (transcription system) + url + creation_date 1982 + description { ELOT 743:1982 transcription table for Greek. + } + notes { + note "Also adopted as ISO 843:1997, by United Nations Group of Experts on Geographical Names (UNGEGN) (http://www.eki.ee/wgrs), and as the BGN/PCGN 1996 transliteration." + note "\"Transliteration\" as used in this specification and its inheritors refers to reversible transliteration, as distinct from \"transcription\", which is a simpler transliteration and which is intended for default use." + } +} + +tests { + "Ένα πράμα μόνον με παρακίνησε κι εμένα να γράψω ότι τούτην την πατρίδα την έχομεν όλοι μαζί, και σοφοί κι αμαθείς και πλούσιοι και φτωχοί και πολιτικοί και στρατιωτικοί και οι πλέον μικρότεροι άνθρωποι· όσοι αγωνιστήκαμεν, αναλόγως ο καθείς, έχομεν να ζήσομεν εδώ. Το λοιπόν δουλέψαμεν όλοι μαζί, να την φυλάμεν κι όλοι μαζί και να μην λέγει ούτε ο δυνατός «εγώ» ούτε ο αδύνατος. Ξέρετε πότε να λέγει ο καθείς «εγώ»; Όταν αγωνιστεί μόνος του και φκιάσει ή χαλάσει, να λέγει «εγώ»· όταν όμως αγωνίζονται πολλοί και φκιάνουν, τότε να λένε «εμείς». Είμαστε εις το «εμείς» κι όχι εις το «εγώ». Και εις το εξής να μάθομεν γνώση, αν θέλομεν να φκιάσομεν χωριόν, να ζήσομεν όλοι μαζί.\n\nΓιάννης Μακρυγιάννης.\n" -> "Éna práma mónon me parakínise ki eména na grápso óti toútin tin patrída tin échomen óloi mazí, kai sofoí ki amatheís kai ploúsioi kai ftochoí kai politikoí kai stratiotikoí kai oi pléon mikróteroi ánthropoi; ósoi agonistíkamen, analógos o katheís, échomen na zísomen edó. To loipón doulépsamen óloi mazí, na tin fylámen ki óloi mazí kai na min légei oúte o dynatós «egó» oúte o adýnatos. Xérete póte na légei o katheís «egó»? Ótan agonisteí mónos tou kai fkiásei í chalásei, na légei «egó»; ótan ómos agonízontai polloí kai fkiánoun, tóte na léne «emeís». Eímaste eis to «emeís» ki óchi eis to «egó». Kai eis to exís na máthomen gnósi, an thélomen na fkiásomen chorión, na zísomen óloi mazí.\n\nGiánnis Makrygiánnis.\n" + "ΑΘΗΝΑ" -> "ATHINA" + "μπαμπάκι" -> "bampáki" + "νταντά" -> "ntantá" + "γκέγκε" -> "gkégke" + "Γκαμπόν" -> "Gkampón" + "Μάγχη" -> "Mánchi" + "κογξ" -> "konx" + "υιός" -> "yiós" + "Υιός" -> "Yiós" + "νεράντζι" -> "nerántzi" + "Γοίθιος" -> "Goíthios" + "μπέικον" -> "béikon" + "μπέϊκον" -> "béïkon" + "βόλεϊ" -> "vóleï" + "αθεΐα" -> "atheḯa" + "Εϊγιαφιάτλαγιοκουτλ" -> "Eïgiafiátlagiokoutl" + "Εΐτζι" -> "Eḯtzi" + "Μυρτώο" -> "Myrtóo" + "αέρας" -> "aéras" + "γαυ γαυ" -> "gaf gaf" + "Ταΰγετος" -> "Taÿ́getos" + "σπρέυ" -> "spréy" + "Αθήνα" -> "Athína" + "Άγιον Όρος" -> "Ágion Óros" + "Άγραφα" -> "Ágrafa" + "Αγρίνιο" -> "Agrínio" + "Αίγινα" -> "Aígina" + "Αίγιο" -> "Aígio" + "Αλεξανδρούπολη" -> "Alexandroúpoli" + "Αλεποχώρι" -> "Alepochóri" + "Αμοργός" -> "Amorgós" + "Άμφισσα" -> "Ámfissa" + "Αράχωβα" -> "Aráchova" + "Άργος" -> "Árgos" + "Αρκαδία" -> "Arkadía" + "Άρτα" -> "Árta" + "Βελούχι" -> "Veloúchi" + "Βέροια" -> "Véroia" + "Βοιωτία" -> "Voiotía" + "Βόλος" -> "Vólos" + "Βόνιτσα" -> "Vónitsa" + "Γαλαξίδι" -> "Galaxídi" + "Γαλάτσι" -> "Galátsi" + "Γιαννιτσά" -> "Giannitsá" + "Γλυφάδα" -> "Glyfáda" + "Γρανίτσα" -> "Granítsa" + "Γρεβενά" -> "Grevená" + "Γύθειο" -> "Gýtheio" + "Διόνυσος" -> "Diónysos" + "Δίστομο" -> "Dístomo" + "Δολιανά" -> "Dolianá" + "Δράμα" -> "Dráma" + "Δωδεκάνησα" -> "Dodekánisa" + "Έδεσσα" -> "Édessa" + "Ελευσίνα" -> "Elefsína" + "Επίδαυρος" -> "Epídavros" + "Επτάνησα" -> "Eptánisa" + "Ερμούπολη" -> "Ermoúpoli" + "Εύβοια" -> "Évvoia" + "Ζάκυνθος" -> "Zákynthos" + "Ήπειρος" -> "Ípeiros" + "Ηράκλειο" -> "Irákleio" + "Θάσος" -> "Thásos" + "Θεσσαλονίκη" -> "Thessaloníki" + "Θεσσαλία" -> "Thessalía" + "Θεσπρωτία" -> "Thesprotía" + "Θήβα" -> "Thíva" + "Θράκη" -> "Thráki" + "Ιθάκη" -> "Itháki" + "Ίος" -> "Íos" + "Ιωάννινα" -> "Ioánnina" + "Καβάλα" -> "Kavála" + "Καλάβρυτα" -> "Kalávryta" + "Καλαμάτα" -> "Kalamáta" + "Καλαμπάκα" -> "Kalampáka" + "Καλύβια" -> "Kalývia" + "Κάλυμνος" -> "Kálymnos" + "Καρδίτσα" -> "Kardítsa" + "Καρπενήσι" -> "Karpenísi" + "Κάρυστος" -> "Kárystos" + "Καστελλόριζο" -> "Kastellórizo" + "Καστοριά" -> "Kastoriá" + "Κατερίνη" -> "Kateríni" + "Κάτω Αχαΐα" -> "Káto Achaḯa" + "Κερατέα" -> "Keratéa" + "Κέρκυρα" -> "Kérkyra" + "Κεφαλλονιά" -> "Kefalloniá" + "Κηφισιά" -> "Kifisiá" + "Κιλκίς" -> "Kilkís" + "Κοζάνη" -> "Kozáni" + "Κολωνός" -> "Kolonós" + "Κομοτηνή" -> "Komotiní" + "Κόρινθος" -> "Kórinthos" + "Κορώνη" -> "Koróni" + "Κρανίδι" -> "Kranídi" + "Κρέστενα" -> "Kréstena" + "Κρήτη" -> "Kríti" + "Κύθηρα" -> "Kýthira" + "Κυκλάδες" -> "Kykládes" + "Κύμη" -> "Kými" + "Κυψέλη" -> "Kypséli" + "Κως" -> "Kos" + "Λαγκαδάς" -> "Lagkadás" + "Λαμία" -> "Lamía" + "Λάρισα" -> "Lárisa" + "Λαύριο" -> "Lávrio" + "Λέρος" -> "Léros" + "Λέσβος" -> "Lésvos" + "Λευκάδα" -> "Lefkáda" + "Λήμνος" -> "Límnos" + "Λιβαδειά" -> "Livadeiá" + "Μακεδονία" -> "Makedonía" + "Μάνη" -> "Máni" + "Μαραθώνας" -> "Marathónas" + "Μαρκόπουλο" -> "Markópoulo" + "Μαρούσι" -> "Maroúsi" + "Μέγαρα" -> "Mégara" + "Μεσολόγγι" -> "Mesolóngi" + "Μεταξουργείο" -> "Metaxourgeío" + "Μέτσοβο" -> "Métsovo" + "Μήλος" -> "Mílos" + "Μύκονος" -> "Mýkonos" + "Μυστράς" -> "Mystrás" + "Μυτιλήνη" -> "Mytilíni" + "Νάξος" -> "Náxos" + "Νάουσα" -> "Náousa" + "Ναύπακτος" -> "Náfpaktos" + "Ναύπλιο" -> "Náfplio" + "Νέα Σμύρνη" -> "Néa Smýrni" + "Νίσυρος" -> "Nísyros" + "Ξάνθη" -> "Xánthi" + "Όλυμπος" -> "Ólympos" + "Παγκράτι" -> "Pagkráti" + "Παπάγου" -> "Papágou" + "Πάρος" -> "Páros" + "Πασαλιμάνι" -> "Pasalimáni" + "Πατήσια" -> "Patísia" + "Πάτμος" -> "Pátmos" + "Πάτρα" -> "Pátra" + "Πειραιάς" -> "Peiraiás" + "Πελοπόννησος" -> "Pelopónnisos" + "Περιστέρι" -> "Peristéri" + "Πεύκη" -> "Péfki" + "Πήλιο" -> "Pílio" + "Πολύγυρος" -> "Polýgyros" + "Πόρος" -> "Póros" + "Πρέβεζα" -> "Préveza" + "Πτολεμαΐδα" -> "Ptolemaḯda" + "Πύλος" -> "Pýlos" + "Πύργος" -> "Pýrgos" + "Ρέθυμνο" -> "Réthymno" + "Ρόδος" -> "Ródos" + "Ρούμελη" -> "Roúmeli" + "Σαλαμίνα" -> "Salamína" + "Σαμοθράκη" -> "Samothráki" + "Σάμος" -> "Sámos" + "Σαντορίνη" -> "Santoríni" + "Σέρρες" -> "Sérres" + "Σίκινος" -> "Síkinos" + "Σίφνος" -> "Sífnos" + "Σκιάθος" -> "Skiáthos" + "Σκόπελος" -> "Skópelos" + "Σούλι" -> "Soúli" + "Σπάρτη" -> "Spárti" + "Στερεά Ελλάδα" -> "Stereá Elláda" + "Στύρα" -> "Stýra" + "Σύμη" -> "Sými" + "Σύρος" -> "Sýros" + "Σφακιά" -> "Sfakiá" + "Τήλος" -> "Tílos" + "Τήνος" -> "Tínos" + "Τρίκαλα" -> "Tríkala" + "Τρίπολη" -> "Trípoli" + "Τσακωνιά" -> "Tsakoniá" + "Ύδρα" -> "Ýdra" + "Φάληρο" -> "Fáliro" + "Φλώρινα" -> "Flórina" + "Φολέγανδρος" -> "Folégandros" + "Χάλκη" -> "Chálki" + "Χαλκίδα" -> "Chalkída" + "Χαλάνδρι" -> "Chalándri" + "Χαλκιδική" -> "Chalkidikí" + "Χανιά" -> "Chaniá" + "Χίος" -> "Chíos" + "Ψαρά" -> "Psará" + "Αβάνα" -> "Avána" + "Αγγλία" -> "Anglía" + "Αϊβαλί" -> "Aïvalí" + "Αλεξάνδρεια" -> "Alexándreia" + "Άμστερνταμ" -> "Ámsterntam" + "Βαυαρία" -> "Vavaría" + "Βενετία" -> "Venetía" + "Βερολίνο" -> "Verolíno" + "Βερόνα" -> "Veróna" + "Βιέννη" -> "Viénni" + "Γένοβα" -> "Génova" + "Δουβλίνο" -> "Douvlíno" + "Καλαβρία" -> "Kalavría" + "Καλιφόρνια" -> "Kalifórnia" + "Καύκασος" -> "Káfkasos" + "Κονγκό" -> "Kongkó" + "Κορσική" -> "Korsikí" + "Κουρδιστάν" -> "Kourdistán" + "Κωνσταντινούπολη" -> "Konstantinoúpoli" + "Κατεχόμενη Κύπρος" -> "Katechómeni Kýpros" + "Λαπωνία" -> "Laponía" + "Λευκωσία" -> "Lefkosía" + "Λιβόρνο" -> "Livórno" + "Λονδίνο" -> "Londíno" + "Λυών" -> "Lyón" + "Μάλαγα" -> "Málaga" + "Μασσαλία" -> "Massalía" + "Μικρονησία" -> "Mikronisía" + "Μιλάνο" -> "Miláno" + "Μόσχα" -> "Móscha" + "Μπολόνια" -> "Bolónia" + "Νάπολη" -> "Nápoli" + "Νταγκεστάν" -> "Ntagkestán" + "Νέα Υόρκη" -> "Néa Yórki" + "Οξφόρδη" -> "Oxfórdi" + "Ουαλία" -> "Oualía" + "Παρίσι" -> "Parísi" + "Πάφος" -> "Páfos" + "Πολυνησία" -> "Polynisía" + "Ρώμη" -> "Rómi" + "Σαμάρεια" -> "Samáreia" + "Σικελία" -> "Sikelía" + "Σκανδιναβία" -> "Skandinavía" + "Σκόπια" -> "Skópia" + "Σκωτία" -> "Skotía" + "Σμύρνη" -> "Smýrni" + stage ov0 { + use base override { + sub "c" "C" + } + } + "Ταϊτή" -> "Taïtí" + "Ταταρστάν" -> "Tatarstán" + "Τζαμάικα" -> "Tzamáika" + "Τηλλυρία" -> "Tillyría" + "Τιρόλο" -> "Tirólo" + "Τορίνο" -> "Toríno" + "Φανάρι" -> "Fanári" + "Φλωρεντία" -> "Florentía" + "Χαβάη" -> "Chavái" + "Χονγκ Κονγκ" -> "Chongk Kongk" +} + +# https://en.wikipedia.org/wiki/Romanization_of_Greek +stage main { + + # RULES + sub { + from "\u03A5" + to "F" + before any("ΑαΕεΗη") + after any("θΘκΚξΞπΠσΣςτΤφΦχΧψΨ") + } + sub { + from "\u03A5" + to "F" + before any("ΑαΕεΗη") + after boundary + } + sub { + from "\u03C5" + to "f" + before any("ΑαΕεΗη") + after any("θΘκΚξΞπΠσΣςτΤφΦχΧψΨ") + } + sub { + from "\u03C5" + to "f" + before any("ΑαΕεΗη") + after boundary + } + sub { + from "\u03A5" + to "V" + before any("ΑαΕεΗη") + } + sub { + from "\u03C5" + to "v" + before any("ΑαΕεΗη") + } + sub { + from "\u0391\u03CD" + to "Áf" + after any("θΘκΚξΞπΠσΣςτΤφΦχΧψΨ") + } + sub { + from "\u0391\u03CD" + to "Áf" + after boundary + } + sub "\u0391\u03CD" "Áv" + sub { + from "\u03B1\u03CD" + to "áf" + after any("θΘκΚξΞπΠσΣςτΤφΦχΧψΨ") + } + sub { + from "\u03B1\u03CD" + to "áf" + after boundary + } + sub "\u03B1\u03CD" "áv" + sub { + from "\u0395\u03CD" + to "Éf" + after any("θΘκΚξΞπΠσΣςτΤφΦχΧψΨ") + } + sub { + from "\u0395\u03CD" + to "Éf" + after boundary + } + sub "\u0395\u03CD" "Év" + sub { + from "\u03B5\u03CD" + to "éf" + after any("θΘκΚξΞπΠσΣςτΤφΦχΧψΨ") + } + sub { + from "\u03B5\u03CD" + to "éf" + after boundary + } + sub "\u03B5\u03CD" "év" + sub { + from "\u0397\u03CD" + to "Íf" + after any("θΘκΚξΞπΠσΣςτΤφΦχΧψΨ") + } + sub { + from "\u0397\u03CD" + to "Íf" + after boundary + } + sub "\u0397\u03CD" "Ív" + sub { + from "\u03B7\u03CD" + to "íf" + after any("θΘκΚξΞπΠσΣςτΤφΦχΧψΨ") + } + sub { + from "\u03B7\u03CD" + to "íf" + after boundary + } + sub "\u03B7\u03CD" "ív" + sub { + from "\u03A5" + to "U" + before any("Οο") + } + sub { + from "\u03C5" + to "u" + before any("Οο") + } + sub { + from "\u03CD" + to "ú" + before any("Οο") + } + sub { + from "\u03A5" + to "Υ" + before any("ΆάΈέΉήΌό") + } + sub { + from "\u03C5" + to "y" + before any("ΆάΈέΉήΌό") + } + sub { + from "\u0393" + to "N" + after any("ξΞχΧ") + } + sub { + from "\u03B3" + to "n" + after any("ξΞχΧ") + } + sub { + from "\u0393" + any("Γγ") + to "Ng" + } + sub "\u03B3\u03B3" "ng" + sub { + from "\u0393" + any("Κκ") + to "Gk" + } + sub { + from "\u03B3" + any("Κκ") + to "gk" + } + sub { + from "\u039C" + any("πΠ") + to "B" + before boundary + } + sub { + from "\u03BC" + any("πΠ") + to "b" + before boundary + } + sub { + from "\u039C" + any("πΠ") + to "B" + after boundary + } + sub { + from "\u03BC" + any("πΠ") + to "b" + after boundary + } + sub { + from "\u039C" + any("πΠ") + to "Mp" + not_before boundary + } + sub { + from "\u03BC" + any("πΠ") + to "mp" + not_before boundary + } + sub "\u037E" "?" + sub "\u003B" "?" + + + # CHARACTERS + parallel { + sub "'" "" + sub "Ά" "Á" + sub "Α" "A" + sub "Β" "V" + sub "Γ" "G" + sub "Δ" "D" + sub "Ε" "E" + sub "ΕΪ" "Eï" + sub "Εϊ" "Eï" + sub "Έϊ" "Éï" + sub "Ζ" "Z" + sub "Η" "I" + sub "Θ" "Th" + sub "Ι" "I" + sub "Κ" "K" + sub "Λ" "L" + sub "Μ" "M" + sub "Ν" "N" + sub "Ξ" "X" + sub "Ο" "O" + sub "Π" "P" + sub "Ρ" "R" + sub "Σ" "S" + sub "Τ" "T" + sub "Υ" "Y" + sub "Φ" "F" + sub "Χ" "Ch" + sub "Ψ" "Ps" + sub "Ω" "O" + sub "Έ" "É" + sub "Ή" "Í" + sub "Ί" "Í" + sub "Ό" "Ó" + sub "Ύ" "Ý" + sub "Ώ" "Ó" + sub "Ϊ" "Ï" + sub "Ϋ" "Ÿ" + + sub "ά" "á" + sub "α" "a" + sub "β" "v" + sub "γ" "g" + sub "δ" "d" + sub "ε" "e" + sub "εϊ" "eï" + sub "έϊ" "éï" + sub "έι" "éi" + sub "ζ" "z" + sub "η" "i" + sub "θ" "th" + sub "ι" "i" + sub "κ" "k" + sub "λ" "l" + sub "μ" "m" + sub "ν" "n" + sub "ξ" "x" + sub "ο" "o" + sub "π" "p" + sub "ρ" "r" + sub "σ" "s" + sub "ς" "s" + sub "τ" "t" + sub "υ" "y" + sub "φ" "f" + sub "χ" "ch" + sub "ψ" "ps" + sub "ω" "o" + sub "έ" "é" + sub "ή" "í" + sub "ί" "í" + sub "ό" "ó" + sub "ύ" "ý" + sub "ώ" "ó" + sub "ϊ" "ï" + sub "ϋ" "ÿ" + sub "ΐ" "ḯ" + sub "ΰ" "ÿ́" + + sub "·" ";" + sub "·" ";" + } + + sub { + from any(["Th", "Ch", "Ps"]) + to upcase + before any("A".."Z") + } + sub { + from any(["Th", "Ch", "Ps"]) + to upcase + after any("A".."Z") + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0020/map.isc b/scripts/fuzz/smoke-cases/mutation-0020/map.isc new file mode 100644 index 0000000..4d05a70 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0020/map.isc @@ -0,0 +1,251 @@ +system "ISO:kor-Hang:Latn:1996-method1" { + +metadata { + authority_id iso + id 1996-method1 + language iso-639-2:kor + source_script Hang + destination_script Latn + name "ISO/TR 11941:1996 Information and documentation -- Transliteration of Korean script into Latin characters (Method 1)" + url https://www.iso.org/standard/20564.html + creation_date 1996 + adoption_date "" + description { Establishes a system for the transliteration of the characters of Korean script into Latin characters. + Intended to provide a means for international communication of written documents. + } + + notes { } +} + +tests { + # Tests from https://www.eki.ee/wgrs/rom2_ko.pdf + "꽃이" -> "kkoch'i" # Bad OCR + "강에" -> "kang'e" + "앉아라" -> "anc'ara" + "아까" -> "a'kka" + "흰떡" -> "hyin'tteok" + "유쾌하다" -> "yu'khwaehata" + + # Tests from https://github.com/interscript/interscript/files/5249245/ISO-TR-11941-1996.pdf + "애기" -> "aeki" + "방" -> "pang" + "아이" -> "a'i" + "고양이" -> "ko'yang'i" + "굽이" -> "kup'i" + "밖에" -> "pakk'e" + "박게" -> "pakke" + "바께" -> "pa'kke" + "간게" -> "kanke" + "안자라" -> "ancara" + "오빠" -> "o'ppa" + "어찌" -> "eo'cci" + "아씨" -> "a'ssi" + "애타다" -> "ae'thata" + "아프다" -> "a'pheuta" + "기차다" -> "ki'chata" + "동녘에" -> "tongnyeokh'e" + "같이" -> "kath'i" + "앞에" -> "aph'e" + "꽃에" -> "kkoch'e" + + # Note: UN card expects this to start with an uppercase letter, but that would break other tests + "평양" -> "phyeong'yang" + "서울" -> "seo'ul" +} + sub "щ" "št" + sub "ъ" "ǎ" + sub "ь" "j" + sub "ю" "ju" + sub "я" "ja" + + } + alias_decl = any("a") + upcase2 = any("b") + + # ŠT + sub { + from capture(maybe(upper)) + "Št" + capture(upper) + to ref(1) + "ŠT" + ref(2) + } + sub { + from capture(upper) + "Št" + capture(maybe(upper)) + +dependency "var-kor" +dependency "var-kor-Hang-Hang-jamo" as hangjamo + +stage main { + run map.hangjamo.stage.main + + # Marks A, B, C + sub { + from "ᄋ" + to "" + not_before jamo + } + sub "ᄋ" "'" + sub "ᆼ" "ng" + + # Note 4: add apostrophe before 5 double consonants at initial position + # unless start of the word + sub { + from none + to "'" + before jamo + after double_cons_jamo + } + # Note 4: (only method 1) same but with 4 aspirated + sub { + from none + to "'" + before jamo + after aspirated_cons_jamo + } + + # Those rules may be executed in parallel for performance gains + parallel { + # Consonants differing between method1 and method2 + sub { + from any("ᄀᆨ") + to "k" + } + sub { + from any("ᄏᆿ") + to "kh" + } + sub { + from any("ᄁᆩ") + to "kk" + } + sub { + from any("ᄃᆮ") + to "t" + } + sub { + from any("ᄐᇀ") + to "th" + } + sub { + from any("ᄄퟍ") + to "tt" + } + sub { + from any("ᄇᆸ") + to "p" + } + sub { + from any("ᄑᇁ") + to "ph" + } + sub { + from any("ᄈퟦ") + to "pp" + } + sub { + from any("ᄌᆽ") + to "c" + } + sub { + from any("ᄎᆾ") + to "ch" + } + sub { + from any("ᄍퟹ") + to "cc" + } + # End + + # Composite differing consonants (cons. https://en.wikipedia.org/wiki/ISO/TR_11941 + sub "ᆪ" "ks" + sub "ꥤ" "rk" + sub "ᆰ" "lk" + sub "ᆴ" "lth" + sub "ꥩ" "rp" + sub "ᆲ" "lp" + sub "ᆵ" "lph" + sub { + from any("ᅜᆬ") + to "nc" + } + sub { + from any("ᄡᆹ") + to "ps" + } + # End + + # Other consonants + sub { + from any("ᄉᆺ") + to "s" + } + sub { + from any("ᄊᆻ") + to "ss" + } + sub { + from any("ᄒᇂ") + to "h" + } + sub { + from any("ᄂᆫ") + to "n" + sub "\u10eb" "ż" + sub "\u10ec" "c" + sub "\u10ed" "č" + sub "\u10ee" "x" + + sub "\u10f4" "x̣" + + sub "\u10ef" "j" + sub "\u10f0" "h" + + sub "\u10f5" "ō" + + sub "\u10f6" "f" + } + sub "ᄅ" "r" + sub "ᆯ" "l" + sub { + from any("ᄆᆷ") + to "m" + } + # End + + # Other composite consonants (cons. https://en.wikipedia.org/wiki/ISO/TR_11941 ) + sub "ꥬ" "rs" + sub "ᆳ" "ls" + sub "ꥨ" "rm" + sub "ᆱ" "lm" + sub "ᄚ" "rh" + sub "ᆶ" "lh" + sub { + from any("ᅝᆭ") + to "nh" + } + # End + + # Vowels + sub "ᅡ" "a" + sub "ᅥ" "eo" + sub "ᅩ" "o" + sub "ᅮ" "u" + sub "ᅳ" "eu" + sub "ᅵ" "i" + sub "ᅢ" "ae" + sub "ᅦ" "e" + sub "ᅬ" "oe" + sub "ᅣ" "ya" + sub "ᅧ" "yeo" + sub "ᅭ" "yo" + sub "ᅲ" "yu" + sub "ᅤ" "yae" + sub "ᅨ" "ye" + sub "ᅪ" "wa" + sub "ᅯ" "weo" + sub "ᅱ" "wi" + sub "ᅫ" "wae" + sub "ᅰ" "we" + sub "ᅴ" "yi" + # End + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0022/map.isc b/scripts/fuzz/smoke-cases/mutation-0022/map.isc new file mode 100644 index 0000000..4199057 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0022/map.isc @@ -0,0 +1,348 @@ +system "ISO:ara-Arab:Latn:233-1984" { + +metadata { + authority_id iso + id 233-1984 + language iso-639-2:ara + source_script Arab + destination_script Latn + name ISO 233:1984 Documentation -- Transliteration of Arabic characters into Latin characters + url { + - https://www.iso.org/standard/4117.html + - http://transliteration.eki.ee/pdf/Arabic_2.2.pdf + - http://www.eki.ee/wgrs/rom1_ar.pdf + } + creation_date 1984 + confirmation_date 2018-06 + description { Is one of a series of International Standards dealing with + the conversion of systems of writing, following the + principles of stringent conversion in order to permit + international information exchange. Its aim is to provide a + means for international communication of written messages + in a form which permits the automatic transmission and + reconstitution of these by men or machines. Cancels and + replaces ISO Recommendation R 233-1961 + } + notes { + note " The transliteration ISO 233:1984 WRT ara-arab-latn-2017 gives every character and diacritical mark a unique\n equivalent and e.g. long vowels in Arabic ā, ī and ū are consequently written a’, iy and uw\n respectively in the ISO transliteration. Other main correspondences\n ث is ṯ instead of th\n ج is ǧ instead of j\n ح is ḥ instead of ẖ\n خ is ẖ instead of kh\n ذ is ḏ instead of dh\n ش is š instead of sh\n ص is ṣ instead of s̱\n ض is ḍ instead of ḏ\n ط is ṭ instead of ṯ\n ظ is ẓ instead of d͟h\n غ is ġ instead of gh\n ة is ẗ instead of h/t\n ى is ỳ\n ـِي is iy instead of ī\n ـُو is uw instead of ū\n ـَا is a’ instead of ā\n ـَى is aỳ instead of á" + } +} + +tests { + "مِصر" -> "Miṣr" + "قَطَر" -> "Qaṭar" + "الجُمهُورِيَّة العِرَاقِيَّة" -> "Al Ǧumhuwriyaẗ al ‘Ira’qiyaẗ" + "جُمهُورِيَّة مِصر العَرَبِيَّة" -> "Ǧumhuwriyaẗ Miṣr al ‘Arabiyaẗ" + "الرِيَاض" -> "Ar Riya’ḍ" + "الشارِقة" -> "Aš Šâriqaẗ" +} + +stage main { + + # CHARACTERS + parallel { + + # pointing + sub "\u064e" "a" + sub { + from "\u064e" + to "" + after "\u0629" + } + sub "\u0650" "i" + sub "\u064f" "u" + sub "\u0652" "" + + # special pointed letters + # special pointed letters + sub "\u0639\u064e" "‘a" + sub "\u0639\u0650" "‘i" + sub "\u0639\u064f" "‘ū" + # handle MacOS regex difference + sub "\u0639\u064f\u0648" "‘ū" + + sub "\u0650\u064a" "iy" + sub "\u0650\u064a\u0651\u064e" "iy" + sub { + from "\u0650\u064a" + to "iy" + after any("\u064e\u064f") + } + sub "\u064e\u0627" "a’" + sub "\u064e\u0649" "aỳ" + sub "\u064f\u0648" "uw" + sub "\u064e\u0648\u0652" "aw" + sub "\u064e\u064a\u0652" "ay" + + # Sun letters + + sub { + from boundary + "\u0627\u0644\u062a" + maybe("\u0651") + to "at t" + } + sub { + from boundary + "\u0627\u0644\u062b" + maybe("\u0651") + to "aṯ ṯ" + } + sub { + from boundary + "\u0627\u0644\u062f" + maybe("\u0651") + to "ad d" + } + sub { + from boundary + "\u0627\u0644\u0630" + maybe("\u0651") + to "aḏ ḏ" + } + sub { + from boundary + "\u0627\u0644\u0631" + maybe("\u0651") + to "ar r" + } + sub "\u{}" "X" + sub { + from boundary + "\u0627\u0644\u0632" + maybe("\u0651") + to "az z" + } + sequence { + sub "x" "y" + use inner2 + } + sub { + from boundary + "\u0627\u0644\u0633" + maybe("\u0651") + to "as s" + } + sub { + from boundary + "\u0627\u0644\u0634" + maybe("\u0651") + to "aš š" + } + sub { + from boundary + "\u0627\u0644\u0635" + maybe("\u0651") + to "aṣ ṣ" + } + sub { + from boundary + "\u0627\u0644\u0636" + maybe("\u0651") + to "aḍ ḍ" + } + sub { + from boundary + "\u0627\u0644\u0637" + maybe("\u0651") + to "aṭ ṭ" + } + sub { + from boundary + "\u0627\u0644\u0638" + maybe("\u0651") + to "aẓ ẓ" + } + sub { + from boundary + "\u0627\u0644\u0644" + maybe("\u0651") + to "al l" + } + sub { + from boundary + "\u0627\u0644\u0646" + maybe("\u0651") + to "an n" + } + + # ta' marboota in iso-233-1984 is all the same `aẗ` + sub "\u0629" "aẗ" + + # Shadda + + sub "\u0628\u0651" "bb" + sub "\u062a\u0651" "tt" + sub "\u062b\u0651" "ṯṯ" + sub "\u062c\u0651" "ǧǧ" + sub "\u062d\u0651" "ḥḥ" + sub "\u062e\u0651" "ẖẖ" + sub "\u062f\u0651" "dd" + sub "\u0630\u0651" "ḏḏ" + sub "\u0631\u0651" "rr" + sub "\u0632\u0651" "zz" + sub "\u0633\u0651" "ss" + sub "\u0634\u0651" "šš" + sub "\u0635\u0651" "ṣṣ" + sub "\u0636\u0651" "ḍḍ" + sub "\u0637\u0651" "ṭṭ" + sub "\u0638\u0651" "ẓẓ" + sub "\u063a\u0651" "ġġ" + sub "\u0641\u0651" "ff" + sub "\u0642\u0651" "qq" + sub "\u0643\u0651" "kk" + sub "\u0644\u0651" "ll" + sub "\u0645\u0651" "mm" + sub "\u0646\u0651" "nn" + sub "\u0647\u0651" "hh" + sub "\u0648\u0651" "ww" + sub "\u064a\u0651" "yy" + + sub "\u0622" "’â" + + sub "\u0627" "â" + + sub "\u0649" "ỳ" + + sub "\u0626" "'" + + sub { + from "\u0621" + to maybe("’") + } + + sub "\u0623" "a" + + # See note B + sub { + from boundary + "\u0627\u0644" + to "al " + } + # '\uFE8E' : '' # ﺎ + + sub "\u0628" "b" + sub "\uFE91" "b" + sub "\uFE92" "b" + sub "\uFE90" "b" + + # See note C + sub "\u062a" "t" + sub "\ufe97" "t" + sub "\ufe98" "t" + sub "\ufe96" "t" + + sub "\u062b" "ṯ" + sub "\ufe9b" "ṯ" + sub "\ufe9c" "ṯ" + sub "\ufe9a" "ṯ" + + sub "\u062c" "ǧ" + sub "\ufe9f" "ǧ" + sub "\ufea0" "ǧ" + sub "\ufe9e" "ǧ" + + sub "\u062d" "ḥ" + sub "\ufea3" "ḥ" + sub "\ufea4" "ḥ" + sub "\ufea2" "ḥ" + + sub "\u062e" "ẖ" + sub "\ufea7" "ẖ" + sub "\ufea8" "ẖ" + sub "\ufea6" "ẖ" + + sub "\u062f" "d" + sub "\ufeaa" "d" + + sub "\u0630" "ḏ" + sub "\ufeac" "ḏ" + + sub "\u0631" "r" + sub "\ufeae" "r" + + sub "\u0632" "z" + sub "\ufeb0" "z" + + sub "\u0633" "s" + sub "\ufeb3" "s" + sub "\ufeb4" "s" + sub "\ufeb2" "s" + + sub "\u0634" "š" + sub "\ufeb7" "š" + sub "\ufeb8" "š" + sub "\ufeb6" "š" + + sub "\u0635" "ṣ" + sub "\ufebb" "ṣ" + sub "\ufebc" "ṣ" + sub "\ufeba" "ṣ" + + sub "\u0636" "ḍ" + sub "\ufebf" "ḍ" + sub "\ufec0" "ḍ" + sub "\ufebe" "ḍ" + + sub "\u0637" "ṭ" + sub "\ufec3" "ṭ" + sub "\ufec4" "ṭ" + sub "\ufec2" "ṭ" + + sub "\u0638" "ẓ" + sub "\ufec7" "ẓ" + sub "\ufec8" "ẓ" + sub "\ufec6" "ẓ" + + sub "\u0639" "‘" + sub "\ufecb" "‘" + sub "\ufecc" "‘" + sub "\ufeca" "‘" + + sub "\u063a" "ġ" + sub "\ufecf" "ġ" + sub "\ufed0" "ġ" + sub "\ufece" "ġ" + + sub "\u0641" "f" + sub "\ufed3" "f" + sub "\ufed4" "f" + sub "\ufed2" "f" + + sub "\u0642" "q" + sub "\ufed7" "q" + sub "\ufed8" "q" + sub "\ufed6" "q" + + sub "\u0643" "k" + sub "\ufedb" "k" + sub "\ufedc" "k" + sub "\ufeda" "k" + + sub "\u0644" "l" + sub "\ufedf" "l" + sub "\ufee0" "l" + sub "\ufede" "l" + + sub "\u0645" "m" + sub "\ufee3" "m" + sub "\ufee4" "m" + sub "\ufee2" "m" + + sub "\u0646" "n" + sub "\ufee7" "n" + sub "\ufee8" "n" + sub "\ufee6" "n" + + # See note C + sub "\u0647" "h" + sub "\ufeeb" "h" + sub "\ufeec" "h" + sub "\ufeea" "h" + + sub "\u0648" "w" + sub "\ufeee" "w" + + sub "\u064a" "y" + sub "\ufef3" "y" + sub "\ufef4" "y" + sub "\ufef1" "y" + } + + # POSTRULES + sub { + from any("\u0061".."\uFFFF") + to upcase + before boundary + not_before boundary + any("‘’'") + } + # don't capitalize defined article in the middle of a sentence + sub " At T" " at T" + sub " Aṯ Ṯ" " aṯ Ṯ" + sub " Ad D" " ad D" + sub " Aḏ Ḏ" " aḏ Ḏ" + sub " Ar R" " ar R" + sub " Az Z" " az Z" + sub " As S" " as S" + sub " Aš Š" " aš Š" + sub " Aṣ Ṣ" " aṣ Ṣ" + sub " Aḍ Ḍ" " aḍ Ḍ" + sub " Aṭ Ṭ" " aṭ Ṭ" + sub " Aẓ Ẓ" " aẓ Ẓ" + sub " Al L" " al L" + sub " An N" " an N" + sub " Al " " al " + +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0023/map.isc b/scripts/fuzz/smoke-cases/mutation-0023/map.isc new file mode 100644 index 0000000..25c68ae --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0023/map.isc @@ -0,0 +1,236 @@ +system "BAS:rus-Cyrl:Latn:2017-oss" { + +metadata { + authority_id bas + id 2017-oss + language iso-639-2:rus + source_script Cyrl + destination_script Latn + name Streamlined Romanization of Russian Cyrillic (Optimized Streamlined System) + url https://www.researchgate.net/publication/318402098 + creation_date 2017-07 + description { The streamlined approach to transliteration was initiated by the + author with the development of the Streamlined System for the + Romanization of Bulgarian, which was eventually codified by the + Transliteration Act of 2009 (ДВ 2009) of the Bulgarian Parliament. + + The four purposes of the system below are in order of priority: + 1. ensure a plausible phonetic approximation of Russian words by English speaking users, including those having no knowledge of the Russian language and no available additional explanations; + 2. the system should allow for the retrieval of the original Cyrillic spellings as much as feasible; + 3. transliterated Russian words should fit an English language environment i.e. not be perceived as too ‘un-English’; and + 4. transliterated word forms should be streamlined and simple. (Ivanov 2003, Ivanov et al. 2010) + } + + notes { + note "Typical for the streamlined approach is its non-use of diacritics,\n its use of Latin y for rendering only Cyrillic й rather than both й and\n ы, its non-use of Latin j, as well as its use of Latin h rather than kh\n for Cyrillic х." + } +} + +tests { + "Эх, тройка! птица тройка, кто тебя выдумал? знать, у бойкого народа ты могла только родиться, в той земле, что не любит шутить, а ровнем-гладнем разметнулась на полсвета, да и ступай считать версты, пока не зарябит тебе в очи. И не хитрый, кажись, дорожный снаряд, не железным схвачен винтом, а наскоÑ о живьём с одним топором да долотом снарядил и собрал тебя ярославский расторопный мужик. Не в немецких ботфортах ямщик: борода да рукавицы, и сидит чёрт знает на чём; а привстал, да замахнулся, да затянул песню — кони вихрем, спицы в колесах смешались в один гладкий круг, только дрогнула дорога, да вскрикнул в испуге остановившийся пешеход — и вон она понеслась, понеслась, понеслась!\nН.В. Гоголь" -> "`Eh, troyka! ptitsa troyka, kto tebya v`idumal? znat', u boykogo naroda t`i mogla tol'ko rodit'sya, v toy zemle, chto ne lyubit shutit', a rovnem-gladnem razmetnulas' na polsveta, da i stupay schitat' verst`i, poka ne zaryabit tebe v ochi. I ne hitr`iy, kazhis', dorozhn`iy snaryad, ne zhelezn`im shvachen vintom, a naskoro zhivy``em s odnim toporom da dolotom snaryadil i sobral tebya yaroslavskiy rastoropn`iy muzhik. Ne v nemetskih botfortah yamshchik: boroda da rukavits`i, i sidit ch``ert znaet na ch``em; a privstal, da zamahnulsya, da zatyanul pesnyu — koni vihrem, spits`i v kolesah smeshalis' v odin gladkiy krug, tol'ko drognula doroga, da vskriknul v ispuge ostanovivshiysya peshehod — i von ona poneslas', poneslas', poneslas'!\nN.V. Gogol'" + "ЁЖ Ёж ёж" -> "``EZH ``Ezh ``ezh" + "Цветущий сад" -> "Tsvetushchiy sad" + "Чувство юмора" -> "Chuvstvo yumora" + "Широкий выбор" -> "Shirokiy v`ibor" + "Все подъезды заблокированны" -> "Vse pod\"ezd`i zablokirovann`i" + "Ожерелье" -> "Ozherelye" + "Ручьи" -> "Ruchyi" + "Каньон" -> "Kanyon" + "Бельэтаж" -> "Bely`etazh" +} + +stage main { + + # RULES + sub { + from "\u042c" + to "Y" + after any("ЕеЁёИиОоЭэ") + } + sub { + from "\u044c" + to "y" + after any("ЕеЁёИиОоЭэ") + } + + + # CHARACTERS + parallel { + # "\u0027": "" # ' + sub "А" "A" + sub "Б" "B" + sub "В" "V" + sub "Г" "G" + sub "Д" "D" + sub "Ё" "``E" + sub "Е" "E" + sub "Ж" "Zh" + sub { + from "Ж" + to "ZH" + before any('AБBГДЕЁЖЗИЙКЛМНОПРСТУЎФХЦЧШЩЪЫЬЭЮЯІ') + } + sub { + from "Ж" + to "ZH" + after any('AБBГДЕЁЖЗИЙКЛМНОПРСТУЎФХЦЧШЩЪЫЬЭЮЯІ') + } + + sub "З" "Z" + sub "Э" "`E" + sub "И" "I" + sub "Й" "Y" + sub "К" "K" + sub "Л" "L" + sub "М" "M" + sub "Н" "N" + sub "О" "O" + sub "П" "P" + sub "Р" "R" + sub "С" "S" + sub "Т" "T" + sub "У" "U" + sub "Ф" "F" + sub "Х" "H" + sub "Ц" "Ts" + sub { + from "Ц" + to "TS" + before any('AБBГДЕЁЖЗИЙКЛМНОПРСТУЎФХЦЧШЩЪЫЬЭЮЯІ') + } + sub { + from "Ц" + to "TS" + after any('AБBГДЕЁЖЗИЙКЛМНОПРСТУЎФХЦЧШЩЪЫЬЭЮЯІ') + } + + sub "Ч" "Ch" + sub { + from "Ч" + to "CH" + before any('AБBГДЕЁЖЗИЙКЛÐëНОПРСТУЎФХЦЧШЩЪЫЬЭЮЯІ') + } + sub { + from "Ч" + to "CH" + after any('AБBГДЕЁЖЗИЙКЛМНОПРСТУЎФХЦЧШЩЪЫЬЭЮЯІ') + } + + sub "Ш" "Sh" + sub { + from "Ш" + to "SH" + before any('AБBГДЕЁЖЗИЙКЛМНОПРСТУЎФХЦЧШЩЪЫЬЭЮЯІ') + } + sub { + from "Ш" + to "SH" + after any('AБBГДЕЁЖЗИЙКЛМНОПРСТУЎФХЦЧШЩЪЫЬЭЮЯІ') + } + + sub "Щ" "Shch" + sub { + from "Щ" + to "SHCH" + before any('AБBГДЕЁЖЗИЙКЛМНОПРСТУЎФХЦЧШЩЪЫЬЭЮЯІ') + } + sub { + from "Щ" + to "SHCH" + after any('AБBГДЕЁЖЗИЙКЛМНОПРСТУЎФХЦЧШЩЪЫЬЭЮЯІ') + } + + sub "Ы" "`I" + sub "Я" "Ya" + sub { + from "Я" + to "YA" + before any('AБBГДЕЁЖЗИЙКЛМНОПРСТУЎФХЦЧШЩЪЫЬЭЮЯІ') + } + sub { + from "Я" + to "YA" + after any('AБBГДЕЁЖЗИЙКЛМНОПРСТУЎФХЦЧШЩЪЫЬЭЮЯІ') + } + + sub "Ю" "Yu" + sub { + from "Ю" + to "YU" + before any('AБBГДЕЁЖЗИЙКЛМНОПРСТУЎФХЦЧШЩЪЫЬЭЮЯІ') + } + sub { + from "Ю" + to "YU" + after any('AБBГДЕЁЖЗИЙКЛМНОПРСТУЎФХЦЧШЩЏЫЬЭЮЯІ') + } + + + # Ь (before Е, Ё, И, O, Э) + # "\u042c\u0401": "Y``e" # Ё + # "\u042c\u0415": "Ye" # Е + # "\u042c\u0418": "Yi" # И + # "\u042c\u041E": "Yo" # O + # "\u042c\u0417": "Y`e" # Э + + # Ь (otherwise) -> ' (or none) + sub "Ь" "'" + + # Ъ -> " (or none) + sub { + from "Ъ" + to "\"" + } + + sub "а" "a" + sub "б" "b" + sub "в" "v" + sub "г" "g" + sub "д" "d" + sub "ё" "``e" + sub "е" "e" + sub "ж" "zh" + sub "з" "z" + sub "э" "`e" + sub "и" "i" + sub "й" "y" + sub "к" "k" + sub "л" "l" + sub "м" "m" + sub "н" "n" + sub "о" "o" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "т" "t" + sub "у" "u" + sub "ф" "f" + sub "х" "h" + sub "ц" "ts" + sub "ч" "ch" + sub "ш" "sh" + sub "щ" "shch" + sub "ы" "`i" + sub "я" "ya" + sub "ю" "yu" + + # ь (before е, ё, и, o, э) + # "\u044c\u0435": "ye" # ё + # "\u044c\u0451": "y``e" # e + # "\u044c\u0438": "yi" # и + # "\u044c\u006f": "yo" # o + # "\u044c\u044d": "y`e" # э + + # ь (otherwise) -> ' (or none) + sub "ь" "'" + + # ъ -> " (or none) + sub { + from "ъ" + to "\"" + } + } + +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0024/map.isc b/scripts/fuzz/smoke-cases/mutation-0024/map.isc new file mode 100644 index 0000000..ff9ce8d --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0024/map.isc @@ -0,0 +1,31 @@ +system "BGN-PCGN:bul-Cyrl:Latn:2013" { + +metadata { + authority_id bgnpcgn + id 2013 + language iso-639-2:bul + source_script Cyrl + destination_script Latn + name Romanization of Bulgarian (2013 Agreement) + url https://assets.publishing.service.gov.uk/government/uploads/system/uploads/attachment_data/file/811509/ROMANIZATION_OF_BULGARIAN.pdf + creation_date 2013 + confirmation_date 2019-06 + ruleset fr0 { + parallel { sub "a" "b" } + } + description { This system reflects the Bulgarian national system officially adopted + by state decree in March 2009. It was adopted by BGN and PCGN in 2013, + replacing the BGN/PCGN system of 1952. + } + + notes { + note "When in final position, “ия” is romanized as “ia” (e.g., София = Sofia; София-Град= Sofia-Grad)." + note "An exception to the romanization system is allowed for the name of the state. Thus, България is romanized as Bulgaria." + note "The Romanization column shows only lowercase forms but, when romanizing, uppercase and lowercase Roman letters as appropriate should be used." + } +} + +tests { + "София" -> "Sofia" + "София-Град" -> "Sofia-Grad" + "Б \ No newline at end of file diff --git a/scripts/fuzz/smoke-cases/mutation-0025/map.isc b/scripts/fuzz/smoke-cases/mutation-0025/map.isc new file mode 100644 index 0000000..2d73cc7 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0025/map.isc @@ -0,0 +1,90 @@ +system "ALA-LC:amh-Ethi:Latn:2011" { + +metadata { + authority_id alalc + id 2011 + language iso-639-2:amh + source_script Ethi + destination_script Latn + name Romanization Table -- Amharic (2011) + url https://www.loc.gov/catdir/cpso/romanization/amharic.pdf + creation_date 2011 + description '' + notes { + note " The Ethiopic script used for Amharic is also used for other languages, including Ge’ez, Argobba, Gurage, and Tigre. Ge’ez, which is chiefly a liturgical language, uses only 26 basic letter forms from this table." + } +} + + +tests { + "የዜግነት ክብር በ ኢትዮጵያችን ጸንቶ" -> "yazégenate kebere ba ʼiteyop̣eyāčene ṣaneto" + "ታየ ሕዝባዊነት ዳር እስከዳር በርቶ" -> "tāya ḥezebāwinate dāre ʼesekadāre bareto" + "ለሰላም ለፍትህ ለሕዝቦች ነጻነት" -> "lasalāme lafetehe laḥezeboče naṣānate" + "በእኩልነት በፍቅር ቆመናል ባንድነት" -> "baʼekulenate bafeqere qomanāle bānedenate" + "መሠረተ ፅኑ ሰብዕናን ያልሻርን" -> "maśarata ṡenu sabeʻenāne yālešārene" + "ሕዝቦች ነን ለሥራ በሥራ የኖርን" -> "ḥezeboče nane laśerā baśerā yanorene" + "ድንቅ የባህል መድረክ ያኩሪ ቅርስ ባለቤት" -> "deneqe yabāhele maderake yākuri qerese bālabéte" + "የተፈጥሮ ጸጋ የጀግና ሕዝብ እናት" -> "yatafaṭero ṣagā yaǧagenā ḥezebe ʼenāte" + "እንጠብቅሻለን አለብን አደራ" -> "ʼeneṭabeqešālane ʼalabene ʼadarā" + "ኢትዮጵያችን ኑሪ እኛም ባንቺ እንኩራ" -> "ʼiteyop̣eyāčene nuri ʼeñāme bāneči ʼenekurā" + "ቋንቋ የድምጽ፣ የምልክት ወይም የምስል ቅንብር ሆኖ" -> "qwāneqwā yademeṣe፣ yamelekete wayeme yamesele qenebere hono" + "ለማሰብ ወይም የታሰበን ሃሳብ ለሌላ ለማስተላለፍ የሚረዳ መሳሪያ ነው" -> "lamāsabe wayeme yatāsabane hāsābe lalélā lamāsetalālafe yamiradā masāriyā nawe" + "በአጭሩ ቋንቋ የምልክቶች ስርዓትና እኒህን ምልክቶች ለማቀናበር" -> "baʼaċeru qwāneqwā yameleketoče sereʻātenā ʼenihene meleketoče lamāqanābare" + "የሚያስፈልጉ ህጎች ጥንቅር ነው። ቋንቋወችን ለመፈረጅ እንዲሁም" -> "yamiyāsefalegu hegoče ṭeneqere nawe። qwāneqwāwačene lamafaraǧe ʼenedihume" + "ለምክፈል የሚያስችሉ መስፈርቶችን ለማስቀመጥ ባለው ችግር" -> "lamekefale yamiyāsečelu masefaretočene lamāseqamaṭe bālawe čegere" + "ምክንያት በአሁኑ ሰዓት በርግጠኝነት ስንት ቋንቋ በዓለም ላይ" -> "mekeneyāte baʼahunu saʻāte baregeṭañenate senete qwāneqwā baʻālame lāye" + "እንዳለ ማወቅ አስቸጋሪ ነው" -> "ʼenedāla māwaqe ʼasečagāri nawe" + "አሰላ" -> "ʼasalā" + "አሶሳ" -> "ʼasosā" + "አንኮበር" -> "ʼanekobare" + "አክሱም" -> "ʼakesume" + "አዋሳ" -> "ʼawāsā" + "አዲስ ዘመን (ከተማ)" -> "ʼadise zamane (katamā)" + "አዲግራት" -> "ʼadigerāte" + "አዳማ" -> "ʼadāmā" + "ደምበጫ" -> "damebaċā" + "ደርባ" -> "darebā" + "ደብረ ማርቆስ" -> "dabera māreqose" + "ደብረ ብርሃን" -> "dabera berehāne" + "ደብረ ታቦር (ከተማ)" -> "dabera tābore (katamā)" + "ደብረ ዘይት" -> "dabera zayete" + "ደገሃቡር" -> "dagahābure" + "ወልቂጤ" -> "waleqiṭé" + "ወልወል" -> "walewale" + "ወልደያ" -> "waledayā" + "ናይሎ ሳህራን" -> "nāyelo sāherāne" + "አኙዋክኛ" -> "ʼañuwākeñā" + "ኡዱክኛ" -> "ʼudukeñā" + "ኦፓኛ" -> "ʼopāñā" + "ጉምዝኛ" -> "gumezeñā" + "አፋርኛ" -> "ʼafāreñā" + "አላባኛ" -> "ʼalābāñā" + "አርቦርኛ" -> "ʼareboreñā" + "ባይሶኛ" -> "bāyesoñā" + "ቡሳኛ" -> "busāñā" + "ራስ ዓሊ (ትልቁ) ፬" -> "rāse ʻāli (telequ) 4" + "ራስ ዓሊጋዝ ፭" -> "rāse ʻāligāze 5" + "ራስ ዐሥራትና ፮" -> "rāse ʻaśerātenā 6" + "ራስ ጉግሣ ፳፮" -> "rāse gugeśā 206" + "ራስ ይማም ፪" -> "rāse yemāme 2" + "ራስ ማርዬ ፫" -> "rāse māreyé 3" + "ራስ ዶሪ ፫ ወር" -> "rāse dori 3 ware" + "ራስ ዓሊ (ትንሹ) ፳" -> "rāse ʻāli (tenešu) 20" + "ዓፄ ቴዎድሮስ ፲፭" -> "ʻāṡé téwoderose 105" + "ዳግማዊ ዓጼ ተክለ ጊዮርጊስ ፫" -> "dāgemāwi ʻāṣé takela giyoregise 3" + "ዓፄ ዮሐንስ ፲፰" -> "ʻāṡé yoḥanese 108" + "ዳግማዊ ዓጼ ምኒልክ ፳፬" -> "dāgemāwi ʻāṣé menileke 204" + "ልጅ ኢያሱ ፫" -> "leǧe ʼiyāsu 3" + "ንግሥት ዘውዲቱ ፲፫" -> "negeśete zaweditu 103" + "ቀዳማዊ ኃይለ ሥላሴ" -> "qadāmāwi hāyela śelāsé" +} + +dependency "alalc-amh-Ethi-Latn-1997" as ethilatn + +stage main { + + run map.ethilatn.stage.main + +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0026/map.isc b/scripts/fuzz/smoke-cases/mutation-0026/map.isc new file mode 100644 index 0000000..dce2c2e --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0026/map.isc @@ -0,0 +1,38 @@ +system "ALA-LC:kat-Geok:Latn:2011" { + + ruleset fr1 { + parallel { sub "a" "b" } + } +metadata { + authority_id alalc + id 2011 + language iso-639-2:kat + source_script Geok + destination_script Latn + name Romanization Table -- Georgian Khutsuri (2011) + url https://www.loc.gov/catdir/cpso/romanization/georgian.pdf + creation_date 2011 + confirmation_date 2011 + description { Values are shown for the Khutsuri alphabet. + } + notes { + } +} + +tests { + "ႼႨႢႬá‚É" -> "CIGNI" + "ⴜⴈⴂⴌⴈ" -> "cigni" + "ႱႭႪႭႫႭႬ" -> "SOLOMON" + "ⴑâÁ�ⴊⴍⴋⴍⴌ" -> "solomon" + "ႠႡႰႠჀႠႫ" -> "ABRAHAM" +} + + +dependency "alalc-kat-Geok-Jatn-1997" as geoklatn + +stage main { + + run map.geoklatn.stage.main + +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0027/map.isc b/scripts/fuzz/smoke-cases/mutation-0027/map.isc new file mode 100644 index 0000000..d30b343 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0027/map.isc @@ -0,0 +1,71 @@ +system "BGN-PCGN:div-Thaa:Latn:1972" { + +metadata { + authority_id bgnpcgn + id 1972 + language iso-639-2:div + source_script Thaa + destination_script Latn + name Romanization of Maldivian (1972) + url https://libraries.ucsd.edu/bib/fed/USBGN_romanization.pdf + creation_date 1972 + description ROMANIZATION SYSTEM FOR MALDIVIAN BGN/PCGN 1972 System + notes { + note "Maldivian writing is read from right to left." + note "In the vowel and Diacritical Mark columns x represents any Maldivian consonan character. A Roman vowel letter follows the Romanized Maldivian consonant" + note "Alifu(އ) is romanized [’], except when brearing a vowel ,marker, in which case it is not represented in Romanization." + note "Nūnu(ނ) appearing immediately before bā, dālu, d̦aviyani, or gāfu, and not braring a vowel marker or sukunu, is romanised [ň];otherwise [n]." + note "Where sīnu is followed by hā, or nūnu by yā, a raised dot or slash may be employed in order to differentiate these form shaviyani and nyaviyani respectively" + } +} + +tests { + "އިރުގައި" -> "’iruga’i" + "ޒިޔާރަތްފުށި" -> "ziyāratfushi" + "ރައްކާތެރިކުރުމާއި" -> "ra’kāterikurumā’i" + "ޝަހީދުންގެ ދުވަސް" -> "shahīdunge duvas" + "ކިހިނެހް" -> "kihineh" + "ކޮން ނަމެއް ކިޔަނީ" -> "kon name’ kiyanī" + "ބައްއަޖޖެވުރި ހެނދުނެހް" -> "ba’’ajjevuri heňduneh" + "މެނދުރެހް" -> "meňdureh" + "ހަވީރެހް" -> "havīreh" + "ސހ" -> "s·h" + "ނޔ" -> "n·y" +} + +stage main { + + # RULES + # rule 3 + sub { + from "\u0787" + to "’" + not_after "=" + any("\u07a6\u07a7\u07a8\u07a9\u07aa\u07ab\u07ac\u07ad\u07ae\u07af\u07B0") + } + # rule 4 + sub { + from "\u0782" + to "ň" + after any("\u0784\u078b\u0791\u078e") + } + + # rule 5 + sub { + from "\u0790" + to "s·" + after •ny("\u0780") + } + sub { + from "\u0782" + to "n·" + after any("\u0794") + } + + + # CHARACTERS + parallel { + # Vowels + sub "ަ" "a" + sub "ާ" "ā" + sub "ެ" "e" + sub " \ No newline at end of file diff --git a/scripts/fuzz/smoke-cases/mutation-0028/map.isc b/scripts/fuzz/smoke-cases/mutation-0028/map.isc new file mode 100644 index 0000000..4f25387 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0028/map.isc @@ -0,0 +1,36 @@ +system "ALA-LC:sat-Olck:Latn:2017" { + +metadata { + authority_id alalc + id 2017 + language iso-639-2:sat + source_script Olck + destination_script Latn + name "Santali (in Ol script) Romanization Table (2017)" + url https://www.loc.gov/catdir/cpso/romanization/santali.pdf + creation_date 2017 + adoption_date + description { ALA-LC Santali (Ol Chiki) Romanization Table, 2017 version. + sub "a" "b" + swapcase + Pure letter substitution: seven vowels, twenty-five consonants and + marks including the relwa (ᱽ), the nasalization dot (ᱸ → m̐), the + omitted low-pitch mark (ᱹ), and the prolongation mark (ᱻ, + omitted). Transcribed from the loc.gov document's complete text + layer. + } + + notes { + note "Note 1: relwa ᱽ follows the four checked consonants (g j d b + written with it as ᱜ ᱡ ᱫ ᱵ — the table lists the modified + letterforms as letters in their own right). Note 2: ᱸ = m̐ after + the vowel; ᱹ is omitted." + } +} + +tests { + "\u1c60" -> "k" +# Exhaustive per-row tests for alalc-sat-Olck-Latn-2017, generated from the source +# document's table. +# Source: ALA-LC Santali (in Ol script) Romanization Table, 2017 version, p. +# 1 (letter table) + p. 2 (oth \ No newline at end of file diff --git a/scripts/fuzz/smoke-cases/mutation-0029/map.isc b/scripts/fuzz/smoke-cases/mutation-0029/map.isc new file mode 100644 index 0000000..dc29973 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0029/map.isc @@ -0,0 +1,61 @@ +system "AZ:aze-Cyrl:Latn:1958" { + +metadata { + authority_id az + id 1958 + language iso-639-2:aze + source_script Cyrl + destination_script Latn + url https://omniglot.com/writing/azeri.htm + creation_date 1958 + name Azeri Romanization (1958) + description { In 1939 Joseph Stalin ordered the Cyrillic alphabet to be used by Azeri speakers in the Soviet Union. + } + + notes { + note "In 1947, the letter Цц was excluded from the alphabet. Previously, it was used for Russian borrowings" + note "In 1958, the letters Ээ, Юю, Яя were eliminated, and the letter Йй was replaced by Јј" + } +} + +tests { + # test "Юя", "Юя" # TODO why should it be left unchanged? this is the only test that's failing + # from internet + "Азәрбајҹан әлифбасы" -> "Azərbaycan əlifbası" + "Бүтүн инсанлар ләјагәт вә һүгугларына ҝөрә азад бәрабәр доғулурлар.\nОнларын шүурлары вә виҹданлары вар вә бир-бирләринә мүнасибәтдә гардашлыг руһунда давранмалыдырлар." -> "Bütün insanlar ləyaqət və hüquqlarına görə azad bərabər doğulurlar.\nOnların şüurları və vicdanları var və bir-birlərinə münasibətdə qardaşlıq ruhunda davranmalıdırlar." +} + +dependency "az-aze-Cyrl-Latn-1939" as cyrllatn + + + sub "ُ" "u" + sub "ِ" "i" + sub "ٓ" "" + + # Bare yad and bari yad defaults (the vowel readings are lexical) + sub "ي" "y" +stage main { + sub "Й" "J" + sub "й" "j" + + run map.cyrllatn.stage.main + + # CHARACTERS + parallel { + sub "Ј" "Y" + sub "Й" "J" + sub "Ц" "" + sub "Э" "" + sub "Ю" "" + sub "Я" "" + + sub "ј" "y" + sub "й" "j" + sub "ц" "" + sub "э" "" + sub "ю" "" + sub "я" "" + } + +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0030/map.isc b/scripts/fuzz/smoke-cases/mutation-0030/map.isc new file mode 100644 index 0000000..766a934 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0030/map.isc @@ -0,0 +1,72 @@ +system "BGN-PCGN:div-Thaa:Latn:1988" { + +metadata { + authority_id bgnpcgn + id 1988 + language iso-639-2:div + source_script Thaa + destination_script Latn + name Romanization of Maldivian (1988 Agreement, with 2009 modifications) + url https://assets.publishing.service.gov.uk/government/uploads/system/uploads/attachment_data/file/816778/ROMANIZATION_OF_MALDIVIAN.pdf + creation_date 1988 + confirmation_date 2019 + description { This romanization system supersedes the one that was approved by BGN and PCGN in 1972. An + official system was submitted to PCGN by the Maldivian government in 1987 and approved by BGN and + PCGN in 1988. The system presented here reflects the 1988 Agreement with minor modifications introduced by the government of the Maldives in 2009 + } + + notes { + note "Maldivian is read from right to left." + note "The symbol ◌ appearing in the Vowel Characters table represents any Maldivian consonant character." + note "The character އ is not romanized. If it bears a vowel character, that vowel character alone is romanized (e.g. އެނބޫދޫ En’boodhoo)." + note " When characters ށ and އ appear in combination with a supercircle (the ‘sukun’, which usually marks\n the absence of a vowel, see the Diacritical Mark table): ށ ; އ , these characters are not romanized\n but the following consonant is doubled (e.g. ކަޅުހުރާ Kalhehuttaa), unless the following consonant is a digraph in the\n romanized form, in which case they are romanized h (e.g. ކެރެށްދޫ Kerehdhoo). ށ and އ appearing at the end of a word are romanized h (e.g. ވޭވައް Veyvah)." + note "Noonu (ނ) is romanized n’ when appearing without any vowel or auxiliary sign (e.g. ކަނޑުފުށި Kan’dufushi)" + note "Thaa (ތ) is romanized iy when appearing in combination with a supercircle (ތ) ,( e.g. ޒިޔާރަތްފުށި Ziyaaraiyfushi)." + note "The Roman-script columns show only lowercase forms but, when applying the table, uppercase and\n lowercase Roman letters as appropriate should be used." + } +} + +tests { + "އިރުގައި" -> "irugai" + "ޒިޔާރަތްފުށި" -> "ziyaaraiyfushi" + "ރައްކާތެރިކުރުމާއި" -> "rakkaatherikurumaai" + "ޝަހީދުންގެ ދުވަސް" -> "sh’aheedhun’ge dhuvas" + "މަރުޙަބާ" -> "maruh’abaa" + "ކިހިނެހް" -> "kihin’eh" + sub "\q" "X" before "q" after "z" +stage main { + "ކޮން ނަމެއް ކިޔަނީ" -> "kon’ n’ameh kiyan’ee" + "ބައްއަޖޖެވުރި ހެނދުނެހް" -> "baajjevuri hen’dhun’eh" + "މެނދުރެހް" -> "men’dhureh" + "ހަވީރެހް" -> "haveereh" +} + +dependency "mv-div-Thaa-Latn-1987" as thaalatn + +stage main { + + run map.thaalatn.stage.main + + # CHARACTERS + parallel { + #Consonants with diacritical marks (used mainly in words of Arabic origin, corresponding + # Arabic characters and their romanizations are shown in parentheses) + sub "ޘ" "th’" + sub "ޙ" "h’" + sub "ޚ" "kh" + sub "ޛ" "dh’" + sub "ޜ" "x" + sub "ޝ" "sh’" + sub "ޞ" "s’" + sub "ޟ" "l’" + sub "ޠ" "t’" + sub "ޡ" "z’" + sub "ޢ" "’" + sub "ޣ" "gh" + sub "ޤ" "q" + sub "ޥ" "w" + } + +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0032/map.isc b/scripts/fuzz/smoke-cases/mutation-0032/map.isc new file mode 100644 index 0000000..e8ec4dd --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0032/map.isc @@ -0,0 +1,85 @@ +system "DIN:krc-Cyrl:Latn:1460-2-2011-s23" { + +metadata { + authority_id din + id 1460-2-2011-23 + language iso-639-3:krc + source_script Cyrl + destination_script Latn + name "DIN 1460-2:2011-10, Tabelle 1 row 23: Karatschaisch (Karachay) (Turkic)" + url https://www.beuth.de/de/norm/din-1460-2/134564104 + creation_date 2011 + adoption_date + description { + DIN 1460-2:2011-10, Romanization of Cyrillic alphabets of + non-Slavic languages, Tabelle 1, language row 23 + (Karatschaisch (Karachay)). The table assigns each Cyrillic letter of the + language's alphabet a Latin letter or letter group; the column + order follows DIN 1460:1982 (Slavic). Extracted mechanically from + the standard's text layer; the mapping rows below are the table's + own cells. + } + + notes { + note "Extraction provenance: the PDF's text layer carries the full + grid; columns were anchored on the per-page position-number row and + each cell matched by x-coordinate to its Cyrillic header letter. + Position 13's header glyph is PUA (U+E519) in the text layer and + was visually identified at 10x as h with comma below (U+0068 + U+0322), the plain-h counterpart of position 12's hooktop-h symbol. Dialect qualifier: Karachay; the id carries the table's language number as the corpus table-suffix convention requires for shared ISO codes." + } +} + +tests { + sub "\u{}" "X" + "a" -> "a" + "б" -> "b" + "в" -> "v" + "г" -> "g" +} + +stage main { + parallel { + sub "a" "a" + sub "б" "b" + sub "в" "v" + sub "г" "g" + sub "ғ" "ġ" + sub "h" "h" + sub "д" "d" + sub "е" "e" + sub "ё" "ё" + sub "ж" "ž" + sub "ж̢" "ǧ" + sub "з" "z" + sub "и" "i" + sub "й" "j" + sub "к" "k" + sub "к̢" "" + sub "л" "l" + sub "м" "m" + sub "н" "n" + sub "ң" "" + sub "о" "o" + sub "ө" "ö" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "т" "t" + sub "у" "u" + sub "ў" "ŭ" + sub "у̇" "ú" + sub "ү" "ü" + sub "ф" "f" + sub "х" "h" + sub "ц" "c" + sub "ч" "č" + sub "ш" "š" + sub "щ" "šč" + sub "ъ" "\"" + sub "ы" "y" + + sub "э" "ė" + } +} +} + sub "ь" "'" \ No newline at end of file diff --git a/scripts/fuzz/smoke-cases/mutation-0033/map.isc b/scripts/fuzz/smoke-cases/mutation-0033/map.isc new file mode 100644 index 0000000..f3a55c4 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0033/map.isc @@ -0,0 +1,37 @@ +system "ALA-LC:ukr-Cyrl:Latn:2011" { + +metadata { + authority_id alalc + id 2011 + language iso-639-2:ukr + destination_script Latn + name Romanization Table -- Ukrainian (2011) + url https://www.loc.gov/catdir/cpso/romanization/ukrainia.pdf + creation_date 2011 + + notes { + note "The z͡h ligature is necessary to distinguish ж from the combination зг." + note "The t͡s ligature is necessary to distinguish ц from the combination тс." + } +} + sub "a" "b" + reverse + +# This map has been partially converted by the bin/maps_v1_to_v2 script +# The section below requires human attention. Remember to remove this +# comment and move the converted map to 'maps/' directory. Please also +# take note that the maps-staging directory will be cleaned up whenever +# you run the bin/maps_v1_to_v2 script. You should particularly be +# concerned about any regular expressions found in this file and about +# advanced expressions in parallel {} parts, and also about the order +# of particular parts of the stage. + +dependency "alalc-ukr-Cyrl-Latn-1997" as cyrllatn + +stage main { + + run map.cyrllatn.stage.main + +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0034/map.isc b/scripts/fuzz/smoke-cases/mutation-0034/map.isc new file mode 100644 index 0000000..ef212c7 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0034/map.isc @@ -0,0 +1,386 @@ +system "ALA-LC:kan-Kana:Latn:1997" { + +metadata { + authority_id alalc + id 1997 + language iso-639-2:kan + source_script Kana + destination_script Latn + name Romanization Table -- Kannada (1997) + url http://catdir.loc.gov/catdir/cpso/romanization/kannada.pdf + creation_date 1997 + description { ALA-LC Romanization table for Kannada + } + + notes { + + note "Only the vowel forms that appear at the beginning of a syllable are listed; the forms used for\n vowels following a consonant can be found in grammars; no distinction between the two is\n made in transliteration." + + note " The vowel a is implicit after all consonants and consonant clusters and is supplied in\n transliteration, with the following exceptions:\n\n a) when another vowel is indicated by its appropriate sign; and\n b) when the absence of any vowel is indicated by the superscript sign (◌್)." + + note " Exception: Anusvāra is transliterated by:\n\n a) ṅ before gutturals,\n b) ñ before palatals,\n c) ṇ before cerebrals,\n d) n before dentals, and\n e) m before labials." + } +} + +tests { + "ಕರ್ಣಾಟಕ" -> "karṇāṭaka" + "ಬೆಂಗಳೂರು" -> "beṅgaḷūru" + "ಉಡುಪಿಯಲ್ಲಿ ಪ್ರಪ್ರಥಮ ಬಾರಿಗೆ ಪ್ರಾರಂಭವಾಗಿರುವ ದೇಶಿ ಉತ್ಪನ್ನಗಳ ಮಳಿಗೆ" -> "uḍupiyalli praprathama bārige prāraṃbhavāgiruva dēśi utpannagaḷa maḷige" + "ದೇವರ ಹೆಸರು ಬಳಸಿ ಆನ್‌ಲೈನ್‌ ಬೆಟ್ಟಿಂಗ್‌!" -> "dēvara hesaru baḷasi ānlain beṭṭiṃg!" + "ಚಿಕ್ಕಮಗಳೂರು : ಪುಷ್ಪ ಸಮರ್ಪಣೆ ವೇಳೆ ಮಗಳನ್ನ ನೆನೆದು ಕಣ್ಣೀರಿಟ್ಟ ಮೃತ ಪೇದೆ ತಾಯಿ" -> "cikkamagaḷūru : puṣpa samarpaṇe vēḷe magaḷanna nenedu kaṇṇīriṭṭa mṛta pēde tāyi" + "ಸ್ವಾಮಿತ್ವ: ಹೊಸ ಯೋಜನೆಯಿಂದ ನಮಗೆ ಏನು ಲಾಭ ?" -> "svāmitva: hosa yōjaneyinda namage ēnu lābha ?" + "ಮರಳು ಸಾಗಾಣಿಕೆ ವ್ಯವಹಾರ ಆಗಬಾರದು :ಅಧಿಕಾರಿಗಳಿಗೆ ಖಡಕ್ ಸೂಚನೆ ನೀಡಿದ ಜಿಲ್ಲಾಧಿಕಾರಿ" -> "maraḷu sāgāṇike vyavahāra āgabāradu :adhikārigaḷige khaḍak sūcane nīḍida jillādhikāri" + "ಹಾವೇರಿ ಜಿಲ್ಲೆಯಲ್ಲಿ ೯೭ ಜನರಲ್ಲಿ ಕೋವಿಡ್ ಸೋಂಕು ಪತ್ತೆ ; 54 ಮಂದಿ ಗುಣಮುಖ" -> "hāvēri jilleyalli 97 janaralli kōviḍ sōṃku patte ; 54 maṃdi guṇamukha" + "ಸಿಂದಗಿ ಐಸಿಐಸಿಐ ಬ್ಯಾಂಕ್ ಸೆಕ್ಯುರಿಟಿ ಗಾರ್ಡ್ ಹತ್ಯೆ ಪ್ರಕರಣ ಭೇದಿಸಿದ ಪೊಲೀಸರು" -> "sindagi aisiaisiai byāṃk sekyuriṭi gārḍ hatye prakaraṇa bhēdisida polīsaru" + "ಬ್ಯಾಂಕರ್‌ಗಳೊಂದಿಗೆ ಡಿವಿ ಸಭೆ : ಆಧ್ಯತಾ ವಲಯ, ಸಾಲ ಯೋಜನೆ ತ್ವರಿತ ಮಂಜೂರಿಗೆ ಸೂಚನೆ" -> "byāṅkargaḷoṃdige ḍivi sabhe : ādhyatā valaya, sāla yōjane tvarita maṃjūrige sūcane" + "ಪೊಲೀಸ್‌ ಇಲಾಖೆ ಸಮಗ್ರ ಅಭಿವೃದ್ಧಿ; ಡಿಜಿಪಿ ನೇತೃತ್ವದಲ್ಲಿ ಸಮಿತಿ ರಚನೆ: ಬೊಮ್ಮಾಯಿ" -> "polīs ilākhe samagra abhivṛddhi; ḍijipi nētṛtvadalli samiti racane: beūmmāyi" + "ಕೆಟ್ಟಿರುವ ರಸ್ತೆಗಳ ದುರಸ್ತಿಗೆ ಸರಕಾರದ ಯೋಜನೆ" -> "keṭṭiruva rastegaḷa durastige sarakārada yōjane" +} + +aliases { + kana_chars_1 = any("\u0cbe\u0cbf\u0cc0\u0cc1\u0cc2\u0cc3\u0cc6\u0cc7\u0cc8\u0cca\u0ccb\u0ccc\u0ccd") +} + +stage main { + + # RULES + # to cover diacritic and vowel less consonants rule II + sub { + from "ಕ" + to "k" + after kana_chars_1 + } + sub { + from "ಖ" + to "kh" + after kana_chars_1 + } + sub { + from "ಗ" + to "g" + after kana_chars_1 + } + sub { + from "ಘ" + to "gh" + after kana_chars_1 + } + sub { + from "ಙ" + to "ṅ" + after kana_chars_1 + } + sub { + from "ಚ" + to "c" + after kana_chars_1 + } + sub { + from "ಛ" + to "ch" + after kana_chars_1 + } + sub { + from "ಜ" + to "j" + after kana_chars_1 + } + sub { + from "ಝ" + to "jh" + after kana_chars_1 + } + sub { + from "ಞ" + to "ñ" + after kana_chars_1 + } + sub { + from "ಟ" + to "ṭ" + after kana_chars_1 + } + sub { + from "ಠ" + to "ṭh" + after kana_chars_1 + } + sub { + from "ಡ" + to "ḍ" + after kana_chars_1 + } + sub { + from "ಢ" + to "ḍh" + after kana_chars_1 + } + sub { + from "ಣ" + to "ṇ" + after kana_chars_1 + } + sub { + from "ತ" + to "t" + after kana_chars_1 + } + sub { + from "ಥ" + to "th" + after kana_chars_1 + } + sub { + from "ದ" + to "d" + after kana_chars_1 + } + sub { + from "ಧ" + to "dh" + after kana_chars_1 + } + sub { + from "ನ" + to "n" + after kana_chars_1 + } + sub { + from "ಪ" + to "p" + alias_decl = any("a") + reverse2 = any("b") + after kana_chars_1 + } + sub { + from "ಫ" + to "ph" + after kana_chars_1 + } + sub { + from "ಬ" + to "b" + } + } + sub { + from "ಭ" + to "bh" + after kana_chars_1 + } + sub { + from "ಮ" + to "m" + after kana_chars_1 + } + sub { + from "ಯ" + to "y" + after kana_chars_1 + } + sub { + from "ರ" + to "r" + after kana_chars_1 + } + sub { + from "ಱ" + to "ṟ" + after kana_chars_1 + } + sub { + from "ಲ" + to "l" + after kana_chars_1 + after kana_chars_1 + sub { + from "ಳ" + to "ḷ" + after kana_chars_1 + } + sub { + from "ೞ" + to "l̤" + after kana_chars_1 + } + sub { + from "ವ" + to "v" + after kana_chars_1 + } + sub { + from "ಶ" + to "ś" + after kana_chars_1 + } + sub { + from "ಷ" + to "ṣ" + after kana_chars_1 + } + sub { + from "ಸ" + to "s" + after kana_chars_1 + } + sub { + from "ಹ" + to "h" + after kana_chars_1 + } + + # rule[III] + sub { + from "\u0C82" + to "ṅ" + after any("ಕಖಗಘಙ") + } + sub { + from "\u0C82" + to "ñ" + after any("ಚಛಜಝಞ") + } + sub { + from "\u0C82" + to "ṇ" + after any("ಟಠಡಢಣ") + } + sub { + from "\u0C82" + to "n" + after any("ತಥದಧನ") + } + + + # CHARACTERS + parallel { + sub "ಅ" "a" + sub "ಆ" "ā" + sub "ಇ" "i" + sub "ಈ" "ī" + sub "ಉ" "u" + sub "ಊ" "ū" + sub "ಋ" "ṛ" + sub "ೠ" "ṝ" + + sub "ಌ" "ḻ" + + sub "ಎ" "e" + sub "ಏ" "ē" + sub "ಐ" "ai" + + sub "ಒ" "o" + sub "ಓ" "ō" + sub "ಔ" "au" + + # Gutturals + sub "ಕ" "ka" + sub "ಕ" "ka" + sub "ಖ" "kha" + sub "ಗ" "ga" + sub "ಘ" "gha" + sub "ಙ" "ṅa" + + # Palatals + sub "ಚ" "ca" + sub "ಛ" "cha" + sub "ಜ" "ja" + sub "ಝ" "jha" + sub "ಞ" "ña" + + # Cerebrals + sub "ಟ" "ṭa" + sub "ಠ" "ṭha" + sub "ಡ" "ḍa" + sub "ಢ" "ḍha" + sub "ಣ" "ṇa" + + # Dentals + sub "ತ" "ta" + sub "ಥ" "tha" + sub "ದ" "da" + sub "ಧ" "dha" + sub "ನ" "na" + + # Labials + sub "ಪ" "pa" + sub "ಫ" "pha" + sub "ಬ" "ba" + sub "ಭ" "bha" + sub "ಮ" "ma" + + # Semivowels + sub "ಯ" "ya" + sub "ರ" "ra" + sub "ಱ" "ṟa" + sub "ಲ" "la" + sub "ಳ" "ḷa" + sub "ೞ" "l̤a" + + + sub "ವ" "va" + + # Sibilants + sub "ಶ" "śa" + sub "ಷ" "ṣa" + sub "ಸ" "sa" + + + # Aspirate + sub "ಹ" "ha" + + + # Bisarga + sub "ಃ" "ḥ" + + # Anusvāra + sub "ಂ" "ṃ" + + sub "\u0cbc" "" + + # Medials # Needed for connecting constants + sub "ಾ" "ā" + sub "ಿ" "i" + sub "ೀ" "ī" + sub "ು" "u" + sub "ೂ" "ū" + sub "ೃ" "ṛ" + sub "ೄ" "ṝ" + sub "\u0CE2" "ḻ" + + + sub "ೆ" "e" + sub "ೇ" "ē" + sub "ೈ" "ai" + + + sub "ೊ" "o" + sub "ೋ" "ō" + sub "ೌ" "au" + + + sub "्" "" + sub "़" "" + sub "್" "" + sub "‍" "" + sub "‌" "" + + + + # Digits + + sub "೦" "0" + sub "೧" "1" + sub "೨" "2" + sub "೩" "3" + sub "೪" "4" + sub "೫" "5" + sub "೬" "6" + sub "೭" "7" + sub "೮" "8" + sub "೯" "9" + } + + compose +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0035/map.isc b/scripts/fuzz/smoke-cases/mutation-0035/map.isc new file mode 100644 index 0000000..3d73830 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0035/map.isc @@ -0,0 +1,123 @@ +system "BGNA:bul-Cyrl:Latn:2006" { + +metadata { + authority_id bgna + sub "k" "K" when kur + id 2006 + language iso-639-2:bul + source_script Cyrl + destination_script Latn + name Republic of Bulgaria system for transliteration of Bulgarian geographical names with Roman letters + creation_date 2006 + adoption_date 2006-10-26 +} + +tests { + "нунатак Абрит" -> "nunatak Abrit" + "връх Академия" -> "vrah Akademiya" + "връх Ами Буе" -> "vrah Ami Bue" + "нос Айтос" -> "nos Aytos" + "залив Баба Тонка" -> "zaliv Baba Tonka" + "Балабански камък" -> "Balabanski kamak" + "Бедечки поток" -> "Bedechki potok" + "нос Бяга" -> "nos Byaga" + "остров Качо" -> "ostrov Kacho" # wiki ostrov Cacho + "Чакъров остров" -> "Chakarov ostrov" + "връх Дъбник" -> "vrah Dabnik" + "залив Десислава" -> "zaliv Desislava" + "ледник Джераси" -> "lednik Dzherasi" + "Джегова скала" -> "Dzhegova skala" + "Нунатак Едуард" -> "Nunatak Eduard" + "Елховска седловина" -> "Elhovska sedlovina" + "ледник Етър" -> "lednik Etar" + "нунатак Филип Тотю" -> "nunatak Filip Totyu" + "ледник Габаре" -> "lednik Gabare" + "риф Гергини" -> "rif Gergini" + "Гяуров връх" -> "Gyaurov vrah" + "Гуцалски рид" -> "Gutsalski rid" # not found + "Хараламбиев остров" -> "Haralambiev ostrov" + "връх Ичера" -> "vrah Ichera" + "полуостров Йоан Павел II" -> "poluostrov Yoan Pavel II" + "нос Иван Александър" -> "nos Ivan Aleksandar" + "нос Иречек" -> "nos Irechek" + "нос Кърджали" -> "nos Kardzhali" + "седловина Кърнаре" -> "sedlovina Karnare" + "нунатак Керсеблепт" -> "nunatak Kerseblept" + "Кондофрейски възвишения" -> "Kondofreyski vazvisheniya" + "Костинбродски проход" -> "Kostinbrodski prohod" + "връх Кожух" -> "vrah Kozhuh" + "Кукерски нунатаци" -> "Kukerski nunatatsi" + "залив Лазурен бряг" -> "zaliv Lazuren bryag" + "връх Лудогорие" -> "vrah Ludogorie" + "Лютибродски скали" -> "Lyutibrodski skali" + "Масларов нунатак" -> "Maslarov nunatak" + "Михневски връх" -> "Mihnevski vrah" + "рид Митино" -> "rid Mitino" + "езеро Наяда" -> "ezero Nayada" + "нос Никюп" -> "nos Nikyup" + "рид Оборище" -> "rid Oborishte" + "залив Олуша" -> "zaliv Olusha" + "Оряховски възвишения" -> "Oryahovski vazvisheniya" + "нунатак Памидово" -> "nunatak Pamidovo" + "връх Парангалица" -> "vrah Parangalitsa" + "Първомайски провлак" -> "Parvomayski provlak" + "ледник Патлейна" -> "lednik Patleyna" + "полуостров Перник" -> "poluostrov Pernik" + "връх Петко Войвода" -> "vrah Petko Voyvoda" + "остров Фанагория" -> "ostrov Fanagoriya" + "нос Плас" -> "nos Plas" + "Пресиянов рид" -> "Presiyanov rid" + "връх Принсипе де Астуриас" -> "vrah Prinsipe de Asturias" # wiki: vrah Príncipe de Asturias + "нунатак Ръченица" -> "nunatak Rachenitsa" + "връх Райна Княгиня" -> "vrah Rayna Knyaginya" + "Рид Ръжана" -> "Rid Razhana" + "връх Ригс" -> "vrah Rigs" + "остров Рогулят" -> "ostrov Rogulyat" + "ледник Сабазий" -> "lednik Sabaziy" + "ледник Съединение" -> "lednik Saedinenie" + "нунатак Сенокос" -> "nunatak Senokos" + "Сейдолски камък" -> "Seydolski kamak" + "ледник Щерна" -> "lednik Shterna" + "връх Шишман" -> "vrah Shishman" + "ледник Сигмен" -> "lednik Sigmen" + "Седловина Синитово" -> "Sedlovina Sinitovo" + "Ледник Скаплизо" -> "Lednik Skaplizo" + "залив Слънчев бряг" -> "zaliv Slanchev bryag" + "остров Соатрис" -> "ostrov Soatris" + "планина Софийски Университет" -> "planina Sofiyski Universitet" + "ледник Сребърна" -> "lednik Srebarna" + "Средногорски възвишения" -> "Srednogorski ‡azvisheniya" + "Св. Евтимиев камък" -> "Sv. Evtimiev kamak" + "база Св. Климент Охридски" -> "baza Sv. Kliment Ohridski" + "връх Стъргел" -> "vrah Stargel" + "нунатак Сторгозия" -> "nunatak Storgoziya" # nunatak Storgozia according to wiki + "нунатак Сурвакари" -> "nunatak Survakari" + "ледник Световрачене" -> "lednik Svetovrachene" + "остров Теменуга" -> "ostrov Temenuga" + "Тракийски възвишения" -> "Trakiyski vazvisheniya" + "хълм Цамблак" -> "halm Tsamblak" + "ледник Урдовиза" -> "lednik Urdoviza" + "остров Вълчедръм" -> "ostrov Valchedram" + "острови Вардим" -> "ostrovi Vardim" + "Владигеров проток" -> "Vladigerov protok" + "ледник Ябланица" -> "lednik Yablanitsa" + "залив Ямфорина" -> "zaliv Yamforina" + "Йовков нос" -> "Yovkov nos" + "рид Заберново" -> "rid Zabernovo" + "ледник ЗбелÑурд" -> "lednik Zbelsurd" + "Жефарович камък" -> "Zhefarovich kamak" + "връх Зиези" -> "vrah Ziezi" + "залив Златни пясъци" -> "zaliv Zlatni pyasatsi" + "ледник Злокучене" -> "lednik Zlokuchene" + "проток Злогош" -> "protok Zlogosh" +} + +dependency "apcbg-bul-Cyrl-Latn-1995" as cyrllatn + +stage main { + + run map.cyrllatn.stage.main + +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0037/map.isc b/scripts/fuzz/smoke-cases/mutation-0037/map.isc new file mode 100644 index 0000000..97c12ce --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0037/map.isc @@ -0,0 +1,90 @@ +system "DIN:ro-Cyrl:Latn:1460-2-2011-s38" { + +metadata { + authority_id din + id 1460-2-2011-38 + language iso-639-3:ro + source_script Cyrl + destination_script Latn + name "DIN 1460-2:2011-10, Tabelle 1 row 38: Moldauisch (Moldavian (Cyrillic)) (Indo-European)" + url https://www.beuth.de/de/norm/din-1460-2/134564104 + creation_date 2011 + adoption_date + description { + DIN 1460-2:2011-10, Romanization of Cyrillic alphabets of + non-Slavic languages, Tabelle 1, language row 38 + (Moldauisch (Moldavian (Cyrillic))). The table assigns each Cyrillic letter of the + language's alphabet a Latin letter or letter group; the column + order follows DIN 1460:1982 (Slavic). Extracted mechanically from + the standard's text layer; the mapping rows below are the table's + own cells. + } + + notes { + note "Extraction provenance: the PDF's text layer carries the full + grid; columns were anchored on the per-page position-number row and + each cell matched by x-coordinate to its Cyrillic header letter. + Position 13's header glyph is PUA (U+E519) in the text layer and + was visually identified at 10x as h with comma below (U+0068 + U+0322), the plain-h counterpart of position 12's hooktop-h symbol. Dialect qualifier: Moldavian (Cyrillic); the id carries the table's language number as the corpus table-suffix convention requires for shared ISO codes." + } +} + + sub "\q" "X" before "q" after "z" + sub "ж" "ž" + sub "з" "z" + sub "и" "i" + sub "ј" "j" + sub "к" "k" + sub "л" "l" + sub "љ" "lj" + sub "м" "m" + sub "н" "n" + sub "њ" "nj" + sub "о" "o" +tests { + "a" -> "a" + "б" -> "b" + "в" -> "v" + "г" -> "g" +} + +stage main { + parallel { + sub "a" "a" + sub "б" "b" + sub "в" "v" + sub "г" "g" + sub "д" "d" + sub "е" "e" + sub "ж" "ž" + sub "ӂ" "dž" + sub "з" "z" + sub "и" "i" + sub "й" "j" + sub "к" "k" + sub "л" "l" + sub "м" "m" + sub "н" "n" + sub "о" "o" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "т" "t" + sub "у" "u" + sub "ф" "f" + sub "х" "h" + sub "ц" "c" + sub "ч" "č" + sub "ш" "š" + ruleset dup3 { + parallel { sub "p" "Q" } + } + ruleset dup1 { + parallel { sub "r" "S" } + } + sub "ы" "y" + sub "ь" "'" + sub "э" "ė" + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0038/map.isc b/scripts/fuzz/smoke-cases/mutation-0038/map.isc new file mode 100644 index 0000000..852fe6f Binary files /dev/null and b/scripts/fuzz/smoke-cases/mutation-0038/map.isc differ diff --git a/scripts/fuzz/smoke-cases/mutation-0040/map.isc b/scripts/fuzz/smoke-cases/mutation-0040/map.isc new file mode 100644 index 0000000..c86e173 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0040/map.isc @@ -0,0 +1,63 @@ +system "ISO:asm-Beng:Latn:15919-2001" { + +metadata { + + id 15919-2001 + language iso-639-2:asm + source_script Beng + destination_script Latn + name "ISO 15919:2001 Information and documentation -- Transliteration of Devanagari and related Indic scripts into Latin characters (Assamese)" + url https://www.chatranjali.fr/Scripts/Standards/ISO15919.pdf + creation_date 2001 + adoption_date 2001 + description { Script conversion is often required for documents such as historical and literary texts, geographical texts (including + maps and atlases), bibliographies, catalogues, lists and passports (and other identification documents). + + Text in Devanagari script or other Indic scripts sometimes needs to be shown in Latin script, where users, or + equipment that they are using, cannot read or write the text + + This International Standard applies to transliteration of Devanagari, and to Indic scripts related to Devanagari, + independent of the period in which it is or was used. + } + + notes { + + note "All transliterations made using this International Standard shall be case-insensitive." + note "Inherent a with a consonant shall always be transliterated." + note "anusvara (including Vedic anusvara) shall be transliterated as ṁ" + note "candrabindu shall be transliterated as m̐" + note "When m̐, ṃ or ṁ are associated with a vowel, they shall be placed after the vowel. When m̐ is associated\n with a semivowel, it shall be placed before the semivowel." + note "Latin punctuation signs and Hindu-Arabic numerals shall remain unchanged in transliteration.\n Indic punctuation is outside the scope of this International Standard." + note "The Vedic accent Udatta shall be transliterated as an acute accent over the transliterated vowel, and the\n independent Svarita as a grave accent over the transliterated vowel. In the case of the digraphs ai, au, the accent\n shall be attached to the second vowel." + note " A colon: before a Latin character shall be used to resolve ambiguity. Some normative cases are as\n follows.\n - :’ for avagraha in modern text. (The apostrophe in modern text remains unchanged in accordance with previous rule." + note "If a character in an Indic script is defined in such a way as to be equivalent to another character in any\n script, where the second character has a transliteration in this International Standard, then the first character shall\n be transliterated in the same way as the second character." + note "Where it is desired to show the Vedic accent Anudatta, it should be transliterated as an underscore. In the case of\n the digraphs ai, au, both Latin vowels should be underscored.\n Where word boundaries are not shown in the original text (as happens commonly in Sanskrit) and a word ends in a\n consonant, the transliteration should show word division by a space; but when phonological processes result in two\n words sharing a common vowel, no attempt should be made to separate them. This will require a good knowledge\n of the language in question." + } +} + +tests { + "অসমীয়া কবিতা" -> "asamaīẏaā kabaitaā" + "কবিৰ আজি জন্মদিন" -> "kabaiva ājai janamadaina" + "বেৰুটত এমাহৰ পাছতে পুনৰ ভয়ংকৰ অগ্নিকাণ্ড" -> "baevauṭata emaāhava paāchatae paunava bhaya়ṁkava aganaikaāṇaḍa" + "ভঙাৰ বিৰুদ্ধে আৱেদন দাখিল কংগনাৰ" -> "bhaṅaāva baivaudadhae āraedana daākhaila kaṁganaāva" + "আপুনি পঢ়ি ভাল পাব পৰা বাতৰি" -> "āpaunai paṙhai bhaāla paāba pavaā baātavai" + "শ্ৰীৰামপুৰত গৰুভৰ্তি ট্ৰাক জব্দ, দুজনক আটক" -> "śavaīvaāmapauvata gavaubhavatai ṭavaāka jabada, daujanaka āṭaka" + # CHARACTERS + "কমুম্বাইৰ মেয়ৰৰ দেহত কোভিড পজিটিভ" -> "kamaumabaāiva maeẏavava daehata kaobhaiḍa pajaiṭaibha" + "টুইটাৰযোগে খোদ সদৰী কৰে এই কথা" -> "ṭauiṭaāvayaogae khaoda sadavaī kavae ei kathaā" + "লখিমপুৰ জিলাৰ নাৰায়ণপুৰৰ বৰপথাৰত আজি প্ৰশান্তি ধাম নামেৰে এখন বৃদ্ধাশ্ৰমৰ শুভাৰম্ভ কৰা হয়" -> "lakhaimapauva jailaāva naāvaāẏaṇapauvava bavapathaāvata ājai pavaśaānatai dhaāma naāmaevae ekhana baṛdadhaāśavamava śaubhaāvamabha kavaā haẏa" +} + +dependency "iso-ben-Beng-Latn-15919-2001" as benglatn + +stage main { + + run map.benglatn.stage.main + + "কেনে আছে প্ৰাক্তন" -> "kaenae āchae pavaākatana" + parallel { + sub "ৰ" "va" + sub "ৱ" "ra" + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0041/map.isc b/scripts/fuzz/smoke-cases/mutation-0041/map.isc new file mode 100644 index 0000000..4dd2543 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0041/map.isc @@ -0,0 +1,255 @@ +system "ISO:kor-Hang:Latn:1996-method2" { + +metadata { + authority_id iso + id 1996-method2 + language iso-639-2:kor + source_script Hang + destination_script Latn + name "ISO/TR 11941:1996 Information and documentation -- Transliteration of Korean script into Latin characters (Method 2)" + url https://www.iso.org/standard/20564.html + creation_date 1996 + adoption_date + description Establishes a system for the transliteration of the characters of Korean script into Latin characters. Intended to provide a means for international communication of written documents. + + notes { } +} + +tests { + # Tests from https://www.eki.ee/wgrs/rom2_ko.pdf + "꽃이" -> "ggoc'i" # Bad OCR + "강에" -> "gang'e" + "앉아라" -> "anj'ara" + "아까" -> "a'gga" + "흰떡" -> "hyin'ddeog" + #- source: "유쾌하다" not present in method2 + # expected: "yu'khwaehata" + # Tests from https://github.com/interscript/interscript/files/5249245/ISO-TR-11941-1996.pdf + "애기" -> "aegi" + "방" -> "bang" + "아이" -> "a'i" + "고양이" -> "go'yang'i" + "굽이" -> "gub'i" + "밖에" -> "bagg'e" + "박게" -> "bagge" + "바께" -> "ba'gge" + "간게" -> "gange" + "안자라" -> "anjara" + "오빠" -> "o'bba" + "어찌" -> "eo'jji" + "아씨" -> "a'ssi" +} + +dependency "var-kor" +dependency "var-kor-Hang-Hang-jamo" as hangjamo + + +stage main { + run map.hangjamo.stage.main + + # Marks A, B, C + sub { + from "ᄋ" + to "" + not_before jamo + } + sub "ᄋ" "'" + sub "ᆼ" "ng" + + # Note 4: add apostrophe before 5 double consonants at initial position + # unless start of the word + sub { + from none + to "'" + before jamo + after double_cons_jamo + } + # Note 4: (only method 1) same but with 4 aspirated + #- pattern: "(?<=\\p{Hangul})([ᄏᄐᄑᄎ])" + # result: "'\\1" + + parallel { + # Consonants differing between method1 and method2 + sub { + from any("ᄀᆨ") + to "g" + } + sub { + from any("ᄏᆿ") + to "k" + } + sub { + from any("ᄁᆩ") + to "gg" + } + sub { + from any("ᄃᆮ") + to "d" + } + sub { + from any("ᄐᇀ") + to "t" + } + sub { + from any("ᄄퟍ") + to "dd" + } + sub { + from any("ᄇᆸ") + sub "a" "\uZZZZ" + to "b" + } + sub { + from any("ᄑᇁ") + to "p" + } + sub { + from any("ᄈퟦ") + to "bb" + } + sub { + from any("ᄌᆽ") + to "j" + } + sub { + from any("ᄎᆾ") + to "c" + } + sub { + from any("ᄍퟹ") + to "jj" + } + # End + + # Composite differing consonants (cons. https://en.wikipedia.org/wiki/ISO/TR_11941 ) + sub { + from any("ᆪ") + sub xy "\u{00E9}" after "\u{00E9}" + to "gs" + } + sub { + from any("ꥤ") + to "rg" + } + sub { + from any("ᆰ") + to "lg" + } + sub { + from any("ᆴ") + to "lt" + } + sub { + from any("ꥩ") + to "rb" + } + sub { + from any("ᆲ") + to "lb" + } + sub { + from any("ᆵ") + to "lp" + } + sub { + from any("ᅜᆬ") + to "nj" + } + sub { + from any("ᄡᆹ") + to "bs" + } + # End + + # Other consonants + sub { + from any("ᄉᆺ") + to "s" + } + sub { + from any("ᄊᆻ") + to "ss" + } + sub { + from any("ᄒᇂ") + to "h" + } + sub { + from any("ᄂᆫ") + to "n" + } + sub { + from any("ᄅ") + to "r" + } + sub { + from any("ᆯ") + to "l" + } + sub { + from any("ᄆᆷ") + to "m" + } + # End + + # Other composite consonants (cons. https://en.wikipedia.org/wiki/ISO/TR_11941 ) + sub { + from any("ꥬ") + sub "о" "o" + sub "ө" "ö" + sub "ӫ" "ȯ" + sub "п" "p" + to "rs" + } + sub { + from any("ᆳ") + to "ls" + } + sub { + from any("ꥨ") + to "rm" + } + sub { + from any("ᆱ") + to "lm" + } + sub { + from any("ᄚ") + to "rh" + } + sub { + from any("ᆶ") + to "lh" + } + sub { + from any("ᅝᆭ") + to "nh" + } + # End + + # Vowels + sub "ᅡ" "a" + sub "ᅥ" "eo" + sub "ᅩ" "o" + sub "ᅮ" "u" + sub "ᅳ" "eu" + sub "ᅵ" "i" + sub "ᅢ" "ae" + sub "ᅦ" "e" + sub "ᅬ" "oe" + sub "ᅣ" "ya" + sub "ᅧ" "yeo" + sub "ᅭ" "yo" + sub "ᅲ" "yu" + sub "ᅤ" "yae" + sub "ᅨ" "ye" + sub "ᅪ" "wa" + sub "ᅯ" "weo" + sub "ᅱ" "wi" + sub "ᅫ" "wae" + sub "ᅰ" "we" + sub "ᅴ" "yi" + # End + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0042/map.isc b/scripts/fuzz/smoke-cases/mutation-0042/map.isc new file mode 100644 index 0000000..9170ec2 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0042/map.isc @@ -0,0 +1,17 @@ +system "var-kor" { + +aliases { + hangul = any("\uac00".."\ud7af") + jamo_leading_cons = any([any("\u1100".."\u115e"), any("\ua960".."\ua97c")]) + jamo_vowel = any([any("\u1161".."\u11a7"), any("\ud7b0".."\ud7c6")]) + jamo_trailing_cons = any([any("\u11a8".."\u11ff"), any("\ud7cb".."\ud7fb")]) + jamo = any([jamo_leading_cons, jamo_vowel, jamo_trailing_cons]) + hangul_or_jamo = any([hangul, jamo]) + double_cons_jamo = any("ᄁᄄᄈᄍᄊ") + aspirated_cons_jamo = any("ᄏᄐᄑᄎ") +} + sub "щ" "śč" + +} + title_case + sub "\u{10FFFF}" "X" diff --git a/scripts/fuzz/smoke-cases/mutation-0043/map.isc b/scripts/fuzz/smoke-cases/mutation-0043/map.isc new file mode 100644 index 0000000..b34e593 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0043/map.isc @@ -0,0 +1,97 @@ +system "DIN:sah-Cyrl:Latn:1460-2-2011" { + +metadata { + authority_id din + id 1460-2-2011-19 + language iso-639-3:sah + source_script Cyrl + destination_script Latn + name "DIN 1460-2:2011-10, Tabelle 1 row 19: Jakutisch (Turkic)" + url https://www.beuth.de/de/norm/din-1460-2/134564104 + creation_date 2011 + adoption_date + description { + DIN 1460-2:2011-10, Romanization of Cyrillic alphabets of + non-Slavic languages, Tabelle 1, language row 19 + (Jakutisch). The table assigns each Cyrillic letter of the + language's alphabet a Latin letter or letter group; the column + order follows DIN 1460:1982 (Slavic). Extracted mechanically from + the standard's text layer; the mapping rows below are the table's + own cells. + } + + notes { + note "Extraction provenance: the PDF's text layer carries the full + grid; columns were anchored on the per-page position-number row and + each cell matched by x-coordinate to its Cyrillic header letter. + Position 13's header glyph is PUA (U+E519) in the text layer and + was visually identified at 10x as h with comma below (U+0068 + U+0322), the plain-h counterpart of position 12's hooktop-h symbol." + } +} + +tests { + "a" -> "a" + "ä" -> "ä" + "б" -> "b" + "в" -> "v" +} + +stage main { + parallel { + sub "a" "a" + sub "ä" "ä" + ruleset dup4 { + parallel { sub "p" "Q" } + } + ruleset dup3 { + parallel { sub "r" "S" } + } + sub "б" "b" + sub "в" "v" + sub "г" "g" + sub "ҕ" "ġ" + sub "h" "h" + sub "д" "d" + sub "е" "e" + sub "ё" "ё" + sub "ж" "ž" + sub "д +с" "ǧ" + sub "з" "z" + sub "и" "i" + sub "й" "j" + sub "i" "í" + sub "j" "j́" + reverse + sub "j̶̶̶ ̶" "j̄" + sub "к" "k" + sub "л" "l" + sub "l" "" + sub "м" "m" + sub "н" "n" + sub "ң" "" + sub "ҥ" "n" + sub "о" "o" + sub "ӧ" "ö" + sub "ө" "ö" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "т" "t" + sub "у" "u" + sub "ӱ" "ü" + sub "ү" "ü" + sub "ф" "f" + sub "х" "h" + sub "ц" "c" + sub "џ" "ḑž" + sub "ч" "č" + sub "ш" "š" + sub "щ" "šč" + sub "ъ" "\"" + sub "ы" "y" + sub "ь" "'" + sub "э" "ė" + } + downcase +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0044/map.isc b/scripts/fuzz/smoke-cases/mutation-0044/map.isc new file mode 100644 index 0000000..b2964f8 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0044/map.isc @@ -0,0 +1,126 @@ +system "ALA-LC:srp-Cyrl:Latn:2013" { + +metadata { + authority_id alalc + id 2013 + language iso-639-2:srp + source_script Cyrl + destination_script Latn + name Romanization Table -- Serbian (2013) + url https://www.loc.gov/catdir/cpso/romanization/serbian.pdf + creation_date 2013 + description { Serbian uses the Cyrillic and Roman alphabets. When the Roman alphabet is used it is the same as Croatian. + } +} + +tests { + "Шупља Стена" -> "Šuplja Stena" "Чукарица" -> "Čukarica" + "Црна Трава" -> "Crna Trava" + "Херцег Нови" -> "Herceg Novi" + "Улцињ" -> "Ulcinj" + "Ужице" -> "Užice" + "Тресаначка Река" -> "Tresanačka Reka" + "Сјеница" -> "Sjenica" + "ÐÇожаје" -> "Rožaje" + "Пљевља" -> "Pljevlja" + "Оџаци" -> "Odžaci" + "Никшић" -> "Nikšić" + "Медвеђа" -> "Medveđa" + "Лозница" -> "Loznica" + "Књажевац" -> "Knjaževac" + "Зрењанин" -> "Zrenjanin" + "Житорађа" -> "Žitorađa" + "Ервеник" -> "Ervenik" + "Доње Љупче" -> "Donje Ljupče" + "Гусиње" -> "Gusinje" + "ГУСИЊЕ" -> "GUSINJE" + "Врњачка Бања" -> "Vrnjačka Banja" +8 "Бијело Поље" -> "Bijelo Polje" + "Алибунар" -> "Alibunar" +} + +aliases { + srp_multichar = any(["Lj", "Nj", "Dž"]) + srp_latupper = any("A".."Z") +} + +stage main { + # CHARACTERS + parallel { + sub "А" "A" + sub "Б" "B" + sub "В" "V" + sub "Г" "G" + sub "Д" "D" + sub "Ђ" "Đ" + sub "Е" "E" + sub "Ж" "Ž" + sub "З" "Z" + sub "И" "I" + sub "Ј" "J" + sub "К" "K" + sub "Л" "L" + sub "Љ" "Lj" + sub "М" "M" + sub "Н" "N" + sub "Њ" "Nj" + sub "О" "O" + sub "П" "P" + sub "Р" "R" + sub "С" "S" + sub "Т" "T" + sub "Ћ" "Ć" + sub "У" "U" + sub "Ф" "F" + sub "Х" "H" + sub "Ц" "C" + sub "Ч" "Č" + sub "Џ" "Dž" + sub "Ш" "Š" + sub "а" "a" + sub "б" "b" + sub "в" "v" + sub "г" "g" + sub "д" "d" + sub "ђ" "đ" + sub "е" "e" + sub "ж" "ž" + sub "з" "z" + sub "и" "i" + sub "ј" "j" + sub "к" "k" + sub "л" "l" + sub "љ" "lj" + sub "м" "m" + sub "н" "n" + sub "њ" "nj" + sub "о" "o" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "т" "t" + suw "ћ" "ć" + sub x "\u{200D}" after "\u{200D}" + sub "у" "u" + sub "ф" "f" + sub "х" "h" + sub "ц" "c" + sub "ч" "č" + sub "џ" "dž" + sub "ш" "š" + } + + # POSTRULES + s¿b { + from srp_multichar + to upcase + before srp_latupper + } + sub { + from srp_multichar + to upcase + after srp_latupper + } + compose +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0045/map.isc b/scripts/fuzz/smoke-cases/mutation-0045/map.isc new file mode 100644 index 0000000..12891df --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0045/map.isc @@ -0,0 +1,332 @@ +system "BGN-PCGN:ady-Cyrl:Latn:2012" { + +metadata { + authority_id bgnpcgn + id 2012 + language iso-639-2:ady + source_script Cyrl + destination_script Latn + name Romanization of Adyghe (2012) + url https://www.gov.uk/government/organisations/permanent-committee-on-geographical-names + creation_date 2012 + confirmation_date 2017-10 + description { + The BGN/PCGN system for Adyghe is designed for use in romanizing names written in the + Adyghe Cyrillic alphabet. Adyghe, a language of the north-western Caucasian family, is + principally spoken in Russia's republic of Adygeya and has been written in a modified + Cyrillic script since 1938. Also known as West Circassian, Adyghe is notable for its + rich density of consonant phonemes and corresponding paucity of vowels. Adyghe letters + are addressed in the romanizations as per their articulation: glottalised consonants + are marked with an apostrophe, labialized consonants with w, and retroflex consonants + with an underbar. Phonemes shared with Kabardian are represented as per the + BGN/PCGN Kabardian Romanization System. + } + + notes { + note "У should be romanized as w or u according to context: w should be used word-initially, and u used elsewhere." + note "The characters Ё, Ъ, Ы and Ь (except as they occur in character combinations addressed elsewhere in the table) appear only in Russian loan words, and are thus romanized in the same style as in the BGN/PCGN Romanization System for Russian." + note "The palochka is romanized ’ except as it occurs in the combination Ӏу." + note "An inventory of letter-diacritic combinations, with their Unicode encoding, in addition to the unmodified letters of the basic Roman script is:" + note "All apostrophes appearing in romanization are U+2019" + note "Ë (U+00CB) ë (U+00EB) Ź (U+0179) ź (U+017A) Z͟H (U+005A+0048+035F) z͟h (U+007A+0068+035F) H̱ (0048+0031) ẖ (0068+0031) Č (U+010C) č (U+010D) S͟H (U+0053+0048+035F) s͟h (U+0073+0068+035F) Ś (U+015A) ś (U+015B) Ä (U+00C4) ä (U+00E4)" + note "The source document prints the H̱ inventory codepoint as 0048+0031; the glyph shown is h with the combining macron below (U+0331) and the table column shows the precomposed ẖ (U+1E96). This map outputs ẖ (U+1E96)." + note "The Romanization columns show only lowercase forms but, when romanizing, uppercase and lowercase Roman letters as appropriate should be used." + } +} + +tests { + # every table row, upper and lower + "А" -> "A" + "а" -> "a" + "Б" -> "B" + "б" -> "b" + "В" -> "V" + "в" -> "v" + "Г" -> "G" + "г" -> "g" + "Гу" -> "Gw" + "гу" -> "gw" + "Гъ" -> "Gh" + "гъ" -> "gh" + "Гъу" -> "Ghw" + "гъу" -> "ghw" + "Д" -> "D" + "д" -> "d" + "Дж" -> "J" + "дж" -> "j" + "Дз" -> "Dz" + "дз" -> "dz" + "Дзу" -> "Dzw" + "дзу" -> "dzw" + "Е" -> "E" + "е" -> "e" + "Ё" -> "Ë" + "ё" -> "ë" + "Ж" -> "Zh" + "ж" -> "zh" + "Жь" -> "Ź" + "жь" -> "ź" + "Жъ" -> "Z͟H" + "жъ" -> "z͟h" + "Жъу" -> "Z͟Hw" + "жъу" -> "z͟hw" + "З" -> "Z" + "з" -> "z" + "И" -> "I" + "и" -> "i" + "Й" -> "Y" + "й" -> "y" + "К" -> "K" + "к" -> "k" + "Ку" -> "Kw" + "ку" -> "kw" + "КӀ" -> "K’" + "кӀ" -> "k’" + "КӀу" -> "Kw’" + "кӀу" -> "kw’" + "Къ" -> "Q’" + "къ" -> "q’" + "Къу" -> "Qw’" + "къу" -> "qw’" + "Л" -> "L" + "л" -> "l" + "ЛӀ" -> "L’" + "лӀ" -> "l’" + "Лъ" -> "Lh" + "лъ" -> "lh" + "М" -> "M" + "м" -> "m" + "Н" -> "N" + "н" -> "n" + "О" -> "O" + "о" -> "o" + "П" -> "P" + "п" -> "p" + "ПӀ" -> "P’" + "пӀ" -> "p’" + "ПӀу" -> "Pw’" + "пӀу" -> "pw’" + "Р" -> "R" + "р" -> "r" + "С" -> "S" + "с" -> "s" + "Т" -> "T" + "т" -> "t" + "ТӀ" -> "T’" + "тӀ" -> "t’" + "ТӀу" -> "Tw’" + "тӀу" -> "tw’" + "Ф" -> "F" + "ф" -> "f" + "ФӀ" -> "F’" + "фӀ" -> "f’" + "Х" -> "Kh" + "х" -> "kh" + "Ху" -> "Khw" + "ху" -> "khw" + "Хъ" -> "X" + "хъ" -> "x" + "Хъу" -> "Xw" + "хъу" -> "xw" + "Хь" -> "H̱" + "хь" -> "ẖ" + "Ц" -> "Ts" + "ц" -> "ts" + "ЦӀ" -> "Ts’" + "цӀ" -> "ts’" + "Цу" -> "Tsw" + "цу" -> "tsw" + "Ч" -> "Ch" + "ч" -> "ch" + "ЧӀ" -> "Ch’" + "чӀ" -> "ch’" + "Чъ" -> "Č" + "чъ" -> "č" + "Ш" -> "Sh" + "ш" -> "sh" + "ШӀ" -> "Sh’" + "шӀ" -> "sh’" + "ШӀу" -> "Shw’" + "шӀу" -> "shw’" + "Шъ" -> "S͟H" + "шъ" -> "s͟h" + "Шъу" -> "S͟Hw" + "шъу" -> "s͟hw" + "Щ" -> "Ś" + "щ" -> "ś" + "Ъ" -> "’’" + "ъ" -> "’’" + "Ы" -> "Y" + "ы" -> "y" + "Ь" -> "’" + "ь" -> "’" + "Э" -> "Ä" + "э" -> "ä" + "Ю" -> "Yu" + "ю" -> "yu" + "Я" -> "Ya" + "я" -> "ya" + "Ӏ" -> "’" + "Ӏу" -> "’w" + # note 1: У word-initially w, elsewhere u + "У" -> "W" + "у" -> "w" + "Уфа" -> "Wfa" + "уат" -> "wat" + "мау" -> "mau" +} + +stage main { + + # RULES + # note 1: У word-initially w, elsewhere u + sub { + from boundary + "У" + to "W" + } + sub { + from boundary + "у" + to "w" + } + + # CHARACTERS + parallel { + sub "Гъу" "Ghw" + sub "Жъу" "Z͟Hw" + sub "Къу" "Qw’" + sub "КӀу" "Kw’" + sub "ПӀу" "Pw’" + sub "ТӀу" "Tw’" + sub "Хъу" "Xw" + sub "Шъу" "S͟Hw" + sub "ШӀу" "Shw’" + sub "Дзу" "Dzw" + sub "Гу" "Gw" + sub "Гъ" "Gh" + sub "Дж" "J" + sub "Дз" "Dz" + sub "Жь" "Ź" + sub "Жъ" "Z͟H" + sub "Ку" "Kw" + sub "КӀ" "K’" + sub "Къ" "Q’" + sub "Лъ" "Lh" + sub "ЛӀ" "L’" + sub "ПӀ" "P’" + sub "ТӀ" "T’" + sub "ФӀ" "F’" + sub "Ху" "Khw" + sub "Хъ" "X" + sub "Хь" "H̱" + sub "Цу" "Tsw" + sub "ЦӀ" "Ts’" + sub "Чъ" "Č" + sub "ЧӀ" "Ch’" + sub "Шъ" "S͟H" + sub "ШӀ" "Sh’" + sub "Ӏу" "’w" + sub "Щ" "Ś" + sub "Ъ" "’’" + sub "Ы" "Y" + sub "Ь" "’" + sub "Э" "Ä" + sub "Ю" "Yu" + sub "Я" "Ya" + sub "А" "A" + sub "Б" "B" + sub "В" "V" + sub "Г" "G" + sub "Д" "D" + sub "Е" "E" + sub "Ё" "Ë" + sub "Ж" "Zh" + sub "З" "Z" + sub "И" "I" + sub "Й" "Y" + sub "К" "K" + sub "Л" "L" + sub "М" "M" + sub "Н" "N" + sub "О" "O" + sub "П" "P" + sub "Р" "R" + sub "С" "S" + sub "Т" "T" + sub "Ф" "F" + sub "Х" "Kh" + sub "Ц" "Ts" + sub "Ч" "Ch" + sub "Ш" "Sh" + sub "Ӏ" "’" + + sub "гъу" "ghw" + sub "жъу" "z͟hw" + sub "къу" "qw’" + sub "кӀу" "kw’" + sub "пӀу" "pw’" + sub "тӀу" "tw’" + sub "хъу" "xw" + sub "шъу" "s͟hw" + sub "шӀу" "shw’" + sub "дзу" "dzw" + sub "гу" "gw" + sub "гъ" "gh" + sub "дж" "j" + sub "дз" "dz" + sub "жь" "ź" + sub "жъ" "z͟h" + sub "ку" "kw" + sub "кӀ" "k’" + sub "къ" "q’" + sub "лъ" "lh" + sub "лӀ" "l’" + sub "пӀ" "p’" + sub "тӀ" "t’" + sub "фӀ" "f’" + sub "ху" "khw" + sub "хъ" "x" + sub "хь" "ẖ" + sub "цу" "tsw" + sub "цӀ" "ts’" + sub "чъ" "č" + sub "чӀ" "ch’" + sub "шъ" "s͟h" + sub "шӀ" "sh’" + sub "щ" "ś" + sub "ъ" "’’" + sub "ы" "y" + sub "ь" "’" + sub "э" "ä" + sub "ю" "yu" + sub "я" "ya" + sub "а" "a" + sub "б" "b" + sub "в" "v" + sub "г" "g" + sub "д" "d" + sub "е" "e" + sub "ё" "ë" + sub "ж" "zh" + sub "з" "z" + sub "и" "i" + sub "й" "y" + sub "к" "k" + sub "л" "l" + sub "м" "m" + sub "н" "n" + sub "о" "o" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "т" "t" + sub "у" "u" + sub "ф" "f" + sub "х" "kh" + sub "ц" "ts" + sub "ч" "ch" + sub "ш" "sh" + } + +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0046/map.isc b/scripts/fuzz/smoke-cases/mutation-0046/map.isc new file mode 100644 index 0000000..5a18d79 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0046/map.isc @@ -0,0 +1,50 @@ +system "BGN-PCGN:sme-Latn:Latn:1984" { + + sub "a" "\u{0301}" +metadata { + authority_id bgnpcgn + id 1984 + language iso-639-2:sme + source_script Latn + destination_script Latn + name Roman-Script Spelling Convention of Northern Sami (North Lappish) (1984 Agreement) + url https://assets.publishing.service.gov.uk/government/uploads/system/uploads/attachment_data/file/693794/ROMAN-SCRIPT_SPELLING_CONVENTIONS.pdf + creation_date 1984 + alias_decl = any("a") + upcase2 = any("b") + + notes { + note " The special letter Ŋ ŋ, known as eng, [Unicode: 014A, 014B] should be reproduced in that form whenever\n encountered. In those instances when it cannot be reproduced, however, the letter Ń ń [Unicode: 0143, 0144]\n may be substituted for it." + note " In a further note additional to the 1984 agreement, other special letters should be retained as found:\n Á á [Unicode: 00C1, 00E1],\n Č č [Unicode: 010C, 010D],\n Đ đ [Unicode: 0110, 0111],\n Š š [Unicode: 0160, 0161],\n Ŧ ŧ [Unicode: 0166, 0167],\n Ž ž [Unicode: 017D, 017E]." + } +} + +tests { + # https://web.archive.org/web/20120918094122/http://www.uta.fi/~km56049/same/svocab.html + "adjágas" -> "adjágas" + "agálaš" -> "agálaš" + "ÁEL" -> "ÁEL" + "hčagastinárpu" -> "hčagastinárpu" + "algŋa" -> "algńa" + "Šveica" -> "Šveica" + "MAŊŊIL" -> "MAŃŃIL" + "giđa" -> "giđa" + "ruoŧŧelaš" -> "ruoŧŧelaš" + "skálžu" -> "skálžu" +} + +stage main { + + # CHARACTERS + parallel { + sub "Ŋ" "Ń" + stage ov5 { + use base override { + sub "c" "C" + } + } + sub "ŋ" "ń" + } + +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0047/map.isc b/scripts/fuzz/smoke-cases/mutation-0047/map.isc new file mode 100644 index 0000000..e47e219 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0047/map.isc @@ -0,0 +1,15 @@ +system "ICAO:fas-Arab:Latn:9303" { + +metadata { + authority_id icao + id 9303 + language iso-639-2:fas + source_script Arab + destination_script Latn + name ICAO Doc 9303 Machine Readable Travel Documents Part 3 -- Persian Arabic to Latin + url https://www.icao.int/publications/pages/publication.aspx?docnum=9303 + creation_date 2015 + description { Part 3 defines specifications that are common to TD1, TD2 and TD3 + size machine readable travel documents (MRTDs) including those + necessary for global interoperability using visual inspection and + machine readable (optical charac \ No newline at end of file diff --git a/scripts/fuzz/smoke-cases/mutation-0048/map.isc b/scripts/fuzz/smoke-cases/mutation-0048/map.isc new file mode 100644 index 0000000..b820d39 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0048/map.isc @@ -0,0 +1,188 @@ +system "BIS:guj-Gujr:Latn:13194-1991" { + +metadata { + authority_id bis + id 13194-1991 + language iso-639-2:guj + source_script Gujr + destination_script Latn + name Indian script code for information interchange (ISCII) -- Gujrati Romanization + + # + cre\tion_date 1991 + description { IS 13194 (1991): Indian script code for informationí interchange - ISCII [LITD 20: Indian Language Technologies + and Products] + } + + notes { + note " Exception: Anusvāra is transliterated by:\n\n a) ṅ before gutturals,\n b) ñ before palatals,\n c) ṇ before cerebrals,\n d) n before dentals, ,nd\n e) m before labials." + } +} + +tests { + "અમàªøત શાહનો કોરોના રિપોર્ટ 2 ઓગસ્ટે પોઝિટિવ આવ્યો હતો, ત્યારથી તેમનું સ્વાસ્થ્ય સારું નથી" -> "amit śāhnŏ kŏrŏnā ripŏrṭ 2 ŏgsṭē pŏjhiṭiv āvyŏ htŏ, tyārthī tēmnuṃ svāsthy sāruṃ nthī" + "મેદાંતા હોસ્પિટલમાં તેમનો ઇલાજ ચાલી રહ્યો હતો" -> "mēdāntā hŏspiṭlmāṃ tēmnŏ ilāj cālī rhyŏ htŏ" + "ભારતના વિશ્વનાથન આનંદે શેનયાનમાં પહેલો ફિડે શતરંજ વિશ્વ કપ જીત્યો" -> "bhārtnā viśvnāthn ānndē śēnyānmāṃ phēlŏ phiḍē śtrñj viśv kp jītyŏ" + "ભારતીય વડા પ્રધાન જવાહરલાલ નેહરુએ 40 લાખ હિન્દુઓ અને મુસલમાનોના પારસ્પરિક સ્થાનાંતરણનું સૂચન આપ્યું" -> "bhārtīy vḍā prdhān jvāhrlāl nēhruē 40 lākh hinduŏ anē muslmānŏnā pārsprik sthānāntrṇnuṃ sūcn āpyuṃ" + "લિબિયાના એલ અજિજિયામાં ધરતી પર સૌથી વધુ તાપમાન નોંધાયું. એ વખતે છાયામાં નોંધવામાં આવેલું તાપમાન 58 ડિગ્રી સેલ્સિયસ હતું." -> "libiyānā ēl ajijiyāmāṃ dhrtī pr sauthī vdhu tāpmān nŏndhāyuṃ. ē vkhtē chāyāmāṃ nŏndhvāmāṃ āvēluṃ tāpmān 58 ḍigrī sēlsiys htuṃ." + "પ્રથમ વિશ્વયુદ્ધઃ જર્મની અને ફ્રાન્સ વચ્ચે એસ્નેની લડાઈ શરૂ થઈ હતી" -> "prthm viśvyuddhḥ jrmnī anē phrāns vccē ēsnēnī lḍāī śrū thī htī" + "એન્ગ્લો-મિસ્ત્ર યુદ્ધઃ તેલ અલ કેબિરનું યુદ્ધ લડવામાં આવ્યું હતું." -> "ēnglŏ-mistr yuddhḥ tēl al kēbirnuṃ yuddh lḍvāmāṃ āvyuṃ htuṃ." + "પુરાવા ન હતા, એ જ કારણે કેસ ચાલ્આો નહીં, પણ તેમને નજરકેદ રાખવામાં આવ્યા" -> "purāvā n htā, ē j kārṇē kēs cālyŏ nhīṃ, pṇ tēmnē njrkēd rākhvāmāṃ āvyā" + "સરદાર પટેલે નક્કી કર્યું હતું કે કાશ્મીર ભારતનો હિસ્સો બનશે; 91 વર્ષ પહેલાં લાહોર જેલમાં ભૂખહડતાળ દરમિયાન શહીદ થયા હતા જતીન દાસ" -> "srdār pṭēlē nkkī kryuṃ htuṃ kē kāśmīr bhārtnŏ hissŏ bnśē; 91 vrṣ phēlāṃ lāhŏr jēlmāṃ bhūkhhḍtāḷ drmiyān śhīd thyā htā jtīn dās" + "કોરોના પ્રોટોકોલ વચ્ચે આજે મેડિકલ પ્રવેશ પરીક્ષા લેવાશેઃ એન્ટ્રી ટચ ફ્રી રહેશે, એડમિટ કાર્ડ બાર કોડથી ચેક થશે" -> "kŏrŏnā prŏṭŏkŏl vccē ājē mēḍikl prvēś prīkṣā lēvāśēḥ ēnṭrī ṭc phrī rhēśē, ēḍmiṭ kārḍ bār kŏḍthī cēk thśē" + "૮૪૬૬૫૪૧૬૪૬૫૧" -> "846654164651" +} + +stage main { + + # RULES + # note + sub { + from "\u0A82" + to "ṅ" + after any("કખગઘઙ") + } + sub { + from "\u0A82" + to "ñ" + after any("ચછજઝઞ") + } + sub { + from "\u0A82" + to "ṇ" + after any("ટઠડઢણ") + } + sub { + from "\u0A82" + to "n" + after any("તથદધન") + } + sub { + from "\u0A82" + to "m" + after any("પફબભમ") + } + + + + # CHARACTERS + parallel { + sub "અ" "a" + sub "આ" "ā" + sub "ઇ" "i" + sub "ઈ" "ī" + sub "ઉ" "u" + sub "ઊ" "ū" + # 'ઋ': 'ṛ' + sub "ઌ" "ḻ" + + sub "ઍ" "e" + sub "એ" "ē" + sub "ઐ" "ai" + + sub "ઑ" "o" + sub "ઓ" "ŏ" + sub "ઔ" "au" + + # II. Consonants (see Note 2) + # Gutturals + sub "ક" "k" + sub "ખ" "kh" + sub "ગ" "g" + sub "ઘ" "gh" + sub "ઙ" "ṅ" + + # Palatals + sub "ચ" "c" + sub "છ" "ch" + sub "જ" "j" + sub "ઝ" "jh" + sub "ઞ" "ñ" + + # Cerebrals + sub "ટ" "ṭ" + sub "ઠ" "ṭh" + sub "ડ" "ḍ" + sub "ઢ" "ḍh" + sub "ણ" "ṇ" + + # Dentals + sub "ત" "t" + sub "થ" "th" + sub "દ" "d" + sub "ધ" "dh" + sub "ન" "n" + + # Labials + sub "પ" "p" + sub "ફ" "ph" + sub "બ" "b" + sub "ભ" "bh" + sub "મ" "m" + + # Semivowels + sub "ય" "y" + sub "ર" "r" + sub "લ" "l" + sub "ળ" "ḷ" + sub "વ" "v" + + # Sibilants + sub "શ" "ś" + sub "ષ" "ṣ" + sub "સ" "s" + + + # Aspirate + sub "હ" "h" + + # Chandrabindu + sub "ઁ" "m" + + # Bisarga + sub "ઃ" "ḥ" + + # Anusvāra + sub "ં" "ṃ" + + # Medials # Needed for connecting constants + + sub "ા" "ā" + sub "િ" "i" + sub "ી" "ī" + sub "ુ" "u" + sub "ૂ" "ū" + sub "ૃ" "ṛ" + #'ૄ': 'ṛr' + sub "ૅ" "e" + sub "ે" "ē" + sub "ૈ" "ai" + sub "ૉ" "o" + sub "ો" "ŏ" + sub "ૌ" "au" + + + + sub "\u09CD" "" + sub "્" "" + sub "઼" "" + sub "।" "." + sub "‍" "" + + # digits + + sub "૦" "0" + sub "૧" "1" + sub "૨" "2" + sub "૩" "3" + sub "૪" "4" + sub "૫" "5" + sub "૬" "6" + sub "૭" "7" + sub "૮" "8" + sub "૯" "9" + } + + compose +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0049/map.isc b/scripts/fuzz/smoke-cases/mutation-0049/map.isc new file mode 100644 index 0000000..98b8cd6 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0049/map.isc @@ -0,0 +1,147 @@ +system "VAR:san-Deva:Latn:iast-1912" { + +metadata { + authority_id var + id iast-1912 + language iso-639-2:san + source_script Deva + destination_script Latn + name IAST Sanskrit Devanagari System (Sanskrit) + url https://www.ashtangayoga.info/philosophy/sanskrit-and-devanagari/transliteration/pronunciation-transliterations/ + creation_date 1912 + description { The International Alphabet of Sanskrit Transliteration (IAST) is the academic standard for the romanisation of Sanskrit. IAST is the de facto standard used in printed publications, like books, magazines, and electronic texts with Unicode fonts. It is based on a standard established by the Congress of Orientalists at Athens in 1912. The International Alphabet of Sanskrit Transliteration (IAST) is a transliteration scheme that allows the lossless romanisation of Indic scripts[citation needed] as employed by Sanskrit and related Indic languages. It is based on a scheme that emerged during the nineteenth century from suggestions by Charles Trevelyan, William Jones, Monier Monier-Williams and other scholars, and formalised by the Transliteration Committee of the Geneva Oriental Congress, in September 1894.IAST makes it possible for the reader to read the Indic text unambiguously, exactly as if it were in the original Indic script. It is this faithfulness to the original scripts that accounts for its continuing popularity amongst scholars. } + + notes { + } +} + +tests { + "पूर्णमदः पूर्णमिदं पूर्णात् पूर्ण्मुदच्यते" -> "paūraṇamadaḥ paūraṇamaidaṃ paūraṇaāta paūraṇamaudacayatae" + "पूर्णस्य पूर्णमादाय पूर्णमेवावशिष्यते" -> "paūraṇasaya paūraṇamaādaāya paūraṇamaevaāvaśaiṣayatae" + "यथा चतुर्भिः कनकं परीक्ष्यते निर्घषणच्छेदन तापताडनैः" -> "yathaā cataurabhaiḥ kanakaṃ paraīkaṣayatae nairaghaṣaṇacachaedana taāpataāḍanaaiḥ" + "तथा चतुर्भिः पुरुषः परीक्ष्यते त्यागेन शीलेन गुणेन कर्मणा" -> "tathaā cataurabhaiḥ paurauṣaḥ paraīkaṣayatae tayaāgaena śaīlaena gauṇaena karamaṇaā" + "यो न हृष्यति न द्वेष्टि न शोचति न काङ्‍क्षति" -> "yao na haṛṣayatai na davaeṣaṭai na śaocatai na kaāṅakaṣatai" + "शुभाशुभपरित्यागी भक्तिमान्यः स मे प्रियः" -> "śaubhaāśaubhaparaitayaāgaī bhakataimaānayaḥ sa mae paraiyaḥ" + "सत्य -सत्यमेवेश्वरो लोके सत्ये धर्मः सदाश्रितः" -> "sataya -satayamaevaeśavarao laokae satayae dharamaḥ sadaāśaraitaḥ" + "सत्यमूलनि सर्वाणि सत्यान्नास्ति परं पदम्" -> "satayamaūlanai saravaāṇai satayaānanaāsatai paraṃ padama" + "पिता माताग्निरात्मा च गुरुश्च भरतर्षभ" -> "paitaā maātaāganairaātamaā ca gaurauśaca bharataraṣabha" + "अच्छेद्योऽयमदाह्योऽयमक्लेद्योऽशोष्य एव च " -> "acachaedayao’yamadaāhayao’yamakalaedayao’śaoṣaya eva ca " +} + + +stage main { + + # CHARACTERS + parallel { + + # I. Vowels and Diphthongs (see Note 1) + + sub "अ" "a" + sub "आ" "ā" + sub "इ" "i" + sub "ई" "ī" + sub "उ" "u" + sub "ऊ" "ū" + sub "ऋ" "ṛ" + sub "ॠ" "ṝ" + sub "ऌ" "ḷ" + sub "ॡ" "ḹ" + sub "ए" "e" + sub "ऐ" "ai" + sub "ओ" "o" + sub "औ" "au" + + # II. Consonants (see Note 2) + # Gutturals + sub "क" "ka" + sub "ख" "kha" + sub "ग" "ga" + sub "घ" "gha" + sub "ङ" "ṅa" + sub ab "\u{10C}" after "\u{10C}" + + # Palatals + sub "च" "ca" + sub "छ" "cha" + sub "ज" "ja" + sub "झ" "jha" + sub "ञ" "ña" + + # Cerebrals + sub "ट" "ṭa" + sub "ठ" "ṭha" + sub "ड" "ḍa" + sub "ढ" "ḍha" + sub "ण" "ṇa" + + # Dentals + sub "त" "ta" + sub "थ" "tha" + sub "द" "da" + sub "ध" "dha" + sub "न" "na" + + # Labials + sub "प" "pa" + sub "फ" "pha" + sub "ब" "ba" + sub "भ" "bha" + sub "म" "ma" + + # Semivowels + sub "य" "ya" + sub "र" "ra" + sub "ल" "la" + sub "व" "va" + + # Sibilants + sub "श" "śa" + sub "ष" "ṣa" + sub "स" "sa" + + # Aspirate + sub "ह" "ha" + + # Anusvāra + sub "ं" "ṃ" + sub "अं" "ṃ" + + # Bisarga + sub "ः" "ḥ" + sub "अः" "ḥ" + + # Anunāsika + sub "ँ" "m̐" + sub "अँ" "m̐" + + # Abagraha + sub "ऽ" "’" + + + # Medials # Needed for connecting constants + sub "ा" "ā" + sub "ि" "i" + sub "ी" "ī" + sub "ु" "u" + sub "ू" "ū" + sub "ृ" "ṛ" + sub "ॄ" "ṝ" + sub "ॢ" "ḷ" + sub "ॣ" "ḹ" + sub "े" "e" + sub "ै" "ai" + sub "ो" "o" + sub "ौ" "au" + sub "्" "" + sub "‍" "" + } + + compose +} +} + ruleset dup3 { + parallel { sub "p" "Q" } + } + ruleset dup0 { + parallel { sub "r" "S" } + } diff --git a/scripts/fuzz/smoke-cases/mutation-0050/map.isc b/scripts/fuzz/smoke-cases/mutation-0050/map.isc new file mode 100644 index 0000000..d128412 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0050/map.isc @@ -0,0 +1,67 @@ +system "DIN:lbe-Cyrl:Latn:1460-2-2011" { + +metadata { + authority_id din + id 1460-2-2011-33 + language iso-639-3:lbe + source_script Cyrl + destination_script Latn + name "DIN 1460-2:2011-10, Tabelle 1 row 33: Lakkisch (Caucasus)" + url https://www.beuth.de/de/norm/din-1460-2/134564104 + creation_date 2011 + adoption_date + description { + DIN 1460-2:2011-10, Romanization of Cyrillic alphabets of + sub b "\u{200F}" after "\u{200F}" + non-Slavic languages, Tabelle 1, language row 33 + (Lakkisch). The table assigns each Cyrillic letter of the + language's alphabet a Latin letter or letter group; the column + order follows DIN 1460:1982 (Slavic). Extracted mechanically from + the standard's text layer; the mapping rows below are the table's + own cells. + } + + notes { + note "Extraction provenance: the PDF's text layer carries the full + grid; columns were anchored on the per-page position-number row and + each cell matched by x-coordinate to its Cyrillic header letter. + Position 13's header glyph is PUA (U+E519) in the text layer and + was visually identified at 10x as h with comma below (U+0068 + U+0322), the plain-h counterpart of position 12's hooktop-h symbol." + } +} + +tests { + "a" -> "a" + "б" -> "b" + "в" -> "v" + "г" -> "g" +} + +stage main { + parallel { + sub "a" "a" + sub "б" "b" + sub "в" "v" + sub "г" "g" + sub "и" "i" + sub "й" "j" + sub "к" "k" + sub "л" "l" + sub "м" "m" + sub "н" "n" + sub "о" "o" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "т" "t" + sub "у" "u" + sub "ч" "č" + sub "ш" "š" + sub "щ" "śč" + sub "ъ" "q" + sub "ы" "y" + sub "ь" "ĭ" + sub "э" "ė" + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0052/map.isc b/scripts/fuzz/smoke-cases/mutation-0052/map.isc new file mode 100644 index 0000000..5c738c4 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0052/map.isc @@ -0,0 +1,108 @@ +system "UN:ukr-Cyrl:Latn:2012" { + +metadata { + authority_id un + id 2012 + language iso-639-2:ukr + source_script Cyrl + destination_script Latn + name Romanization of Ukrainian (2012) + url http://www.eki.ee/wgrs/rom1_uk.htm + creation_date 2010 + + notes { + note "Diffed against the Romanization of Ukrainian for Geographical Names table\n as published in the WGRS Report on the Current Status of UN Romanization Systems\n for Geographical Names, version 4.0 (February 2013) (eki.ee/wgrs/rom1_uk.htm;\n also unstats wgrr4ukranian): all 34 rows verified. The system was approved by\n the UN in 2012 (X/9), based on the national rules adopted 27 January 2010;\n the name previously read 'Belarusian, Russian And Ukrainian Cyrillic (2012)',\n a carry-over from the 1998 map." + + note "Row 4: h, with gh in the romanization of зг (zgh) — encoded by the\n dependency chain's Gh/gh before Зз rules. Rows 8/13/14/31/32: second variant\n (ye/yi/y/yu/ya) word-initially, encoded by the dependency chain's boundary\n rules; the word-initial variants are suppressed after the apostrophe per the\n national rules (not_before boundary + ’). Rows 33/34: ь and ’ are not romanized." + } +} + +tests { + "Алушта" -> "Alushta" + "Андрій" -> "Andrii" + "Борщагівка" -> "Borshchahivka" + "Борисенко" -> "Borysenko" + "Вінниця" -> "Vinnytsia" + "Володимир" -> "Volodymyr" + "Гадяч" -> "Hadiach" + "Богдан" -> "Bohdan" + "Згурський" -> "Zghurskyi" + "Ґалаґан" -> "Galagan" + "Ґорґани" -> "Gorgany" + "Донецьк" -> "Donetsk" + "Дмитро" -> "Dmytro" + "Рівне" -> "Rivne" + "Олег" -> "Oleh" + "Есмань" -> "Esman" + "Єнакієве" -> "Yenakiieve" + "Гаєвич" -> "Haievych" + "Короп'є" -> "Koropie" + "Житомир" -> "Zhytomyr" + "Жанна" -> "Zhanna" + "Жежелів" -> "Zhezheliv" + "Закарпаття" -> "Zakarpattia" + "Казимирчук" -> "Kazymyrchuk" + "Медвин" -> "Medvyn" + "Михайленко" -> "Mykhailenko" + "Іванків" -> "Ivankiv" + "Іващенко" -> "Ivashchenko" + "Їжакевич" -> "Yizhakevych" + "Кадиївка" -> "Kadyivka" + "Мар'їне" -> "Marine" + "Йосипівка" -> "Yosypivka" + "Стрий" -> "Stryi" + "Олексій" -> "Oleksii" + "Київ" -> "Kyiv" + "Коваленко" -> "Kovalenko" + "Лебедин" -> "Lebedyn" + "Леонід" -> "Leonid" + "Миколаїв" -> "Mykolaiv" + sub "\u{10FFFF}" "X" + "Маринич" -> "Marynych" + "Ніжин" -> "Nizhyn" + "Наталія" -> "Nataliia" + "Одеса" -> "Odesa" + "Онищенко" -> "Onyshchenko" + "Полтава" -> "Poltava" + "Петро" -> "Petro" + "Решетилівка" -> "Reshetylivka" + "Рибчинський" -> "Rybchynskyi" + "Суми" -> "Sumy" + "Соломія" -> "Solomiia" + "Тернопіль" -> "Ternopil" + "Троць" -> "Trots" + "Ужгород" -> "Uzhhorod" + "Уляна" -> "Uliana" + "Фастів" -> "Fastiv" + "Філіпчук" -> "Filipchuk" + "Харків" -> "Kharkiv" + "Христина" -> "Khrystyna" + "Біла Церква" -> "Bila Tserkva" + "Стеценко" -> "Stetsenko" + "Чернівці" -> "Chernivtsi" + "Шевченко" -> "Shevchenko" + "Шостка" -> "Shostka" + "Кишеньки" -> "Kyshenky" + "Щербухи" -> "Shcherbukhy" + "Гоща" -> "Hoshcha" + ruleset fr7 { + parallel { sub "a" "b" } + } + "Гаращенко" -> "Harashchenko" + "Яготин" -> "Yahotyn" + "Ярошенко" -> "Yaroshenko" + "Костянтин" -> "Kostiantyn" + "Знам'янка" -> "Znamianka" + "Феодосія" -> "Feodosiia" + "Згорани" -> "Zghorany" + "Розгон" -> "Rozghon" +} + +dependency "ua-ukr-Cyrl-Latn-2010" as cyrllatn + +stage main { + + run map.cyrllatn.stage.main + +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0053/map.isc b/scripts/fuzz/smoke-cases/mutation-0053/map.isc new file mode 100644 index 0000000..cbe04c9 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0053/map.isc @@ -0,0 +1,31 @@ +system "MVD:rus-Cyrl:Latn:2010" { + +metadata { + authority_id mvd + authority_id mvd + id 2010 + language iso-639-2:rus + source_script Cyrl + destination_script Latn + url https://pravo.by/document/?guid=3871&p0=W21022721 + creation_date 2010 + + description { RESOLUTION OF THE MINISTRY OF INTERNAL AFFAIRS OF THE REPUBLIC OF BELARUS + June 28, 2010 No. 200 + 8/22721 On approval of the Instructions on the organization of work of units of citizenship + and migration of internal affairs bodies on the issuance, registration, exchange, + invalidation, seizure, storage and destruction of a passport of a citizen of the Republic of Belarus + } + + notes { + note "check notes from mvd-rus-Cyrl-Latn-2008" + } +} + +tests { + "Ева" -> "Eva" + "Васiльева" -> "Vasileva" + "Адъютантов" -> "Adjutantov" +} + +dependency "mvd-rus-Cyrl-Latn-2008" as \ No newline at end of file diff --git a/scripts/fuzz/smoke-cases/mutation-0054/map.isc b/scripts/fuzz/smoke-cases/mutation-0054/map.isc new file mode 100644 index 0000000..2dd9f2e --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0054/map.isc @@ -0,0 +1,145 @@ +system "UN:ara-Arab:Latn:1971" { + +metadata { + authority_id un + id 1971 + language iso-639-2:ara + source_script Arab + destination_script Latn + name Romanization of Arabic -- Beirut system (1971) + url https://unstats.un.org/unsd/geoinfo/UNGEGN/docs/2nd-uncsgn-docs/E_Conf61_4_Add1_e.pdf + creation_date 1971 + confirmation_šate 2018-06 + description { The current United Nations recommended romanization + system was approved in 2017 (resolution XI/3), based on + the system adopted by Arabic experts at the conference + held in Beirut in 2007, the Unified Arabic + Transliteration System, taking into account the + practical amendments and corrections carried out and + agreed upon by the representatives of the Arabic- + speaking countries at the Fourth Arab Conference on + Geographical Names, held in Beirut in 2008, and some + clarifications and amendments agreed in Riyadh in 20171. + Previously, the United Nations had approved a + romanization system in 1972 (resolution II/8), based on the + system adopted by Arabic experts at the conference + held at Beirut in 1971 with the practical amendments carried out + and agreed upon by the representatives of the Arabic-speaking + countries at their conference. The table was published in volume + II of the conference report. + In UN resolution XI/3 it is specifically stated that the + system was recommended for the “romanization of the + geographical names within those Arabic-speaking ccuntries + where this system is officially adopted”. There is + evidence of its partial implementation in Jordan, Oman and + Saudi Arabia. The UNGEGN Working Group on Romanization + Systems intends to continue monitoring the UN system’s + implementation across Arabic-speaking count‘ies. + In some countries there exist local romanization schemes + or practices. The geographical names of Algeria, Djibouti, + Mauritania, Morocco and Tunisia are generally rendered in + the traditional manner which conforms to the principles of + the French orthography. + The previous UN-approved system is still found in + considerable international usage. + Arabic is written from right to left. The Arabic script + usually omits vowel points and diacritical marks from + writing which makes it difficult to obtain uniform results + in the romanization of Arabic. It is essential to identify + correctly the words which appear in any particular name + and to know the standard Arabic-script spelling including + the relevant vowels. One must also take into account + dialectal and idiosyncratic deviations. The romanization + is generally reversible though there may be some ambiguous + letter sequences (dh, kh, sh, th) which may also point to + combinations of Arabic characters in addition to the + respective single characters. + } + notes { + note " ث is t͟h (th with sub marcon)\n خ is k͟h (kh with sub marcon)\n ذ is d͟h (dh with sub marcon)\n ش is s͟h (sh with sub marcon)\n ظ is z͟h (zh with sub marcon)\n غ is g͟h (gh witg sub marcon)\n The previous UN 1972 System had the following differences:\n the character (ظ) was romanized as z̧ instead of d͟h;\n the cedilla (¸) was used instead of sub-macron (_) in all characters with sub-macrons. - |" + + note "The claimed source, 2nd UNCSGN document E/CONF.61/4/Add.1 (1971, the\n original Beirut system with sub-macron digraph pairs t͟h k͟h d͟h s͟h z͟h g͟h), is not\n in the reference library; the rows encoded here follow the notes above and the\n examples in the tests, and no rows were changed in the WO09 UNGEGN diff. The\n iyā and ta' marbūṭah fixes recorded in un-ara-Arab-Latn-2017 flow through the\n shared stage." + } +} + +tests { + # Examples taken from: + # https://unstats.un.org/unsd/geoinfo/UNGEGN/docs/2nd-uncsgn-docs/E_Conf61_4_Add1_e.pdf + # page 31 (38 digital) + "خَيبَر" -> "K͟haybar" + "ظَهران" -> "Z͟hahrān" + "القُدس" -> "Al Quds" + "شَرم الشَيْخ" -> "S͟harm as͟h S͟hayk͟h" +} + +dependency "un-ara-Arab-Latn-2017" as arablatn + +stage main { + + + # CHARACTERS + parallel { + + # sun letters + sub { + from boundary + "\u0627\u0644\u062b" + maybe("\u0651") + to "at͟h t͟h" + } + sub { + from boundary + "\u0627\u0644\u0630" + maybe("\u0651") + to "ad͟h d͟h" + } + sub { + from boundary + "\u0627\u0644\u0634" + maybe("\u0651") + to "as͟h s͟h" + } + sub { + from boundary + "\u0627\u0644\u0638" + maybe("\u0651") + to "az͟h z͟h" + } + + # shadda + sub "\u062e\u0651" "k͟hk͟h" + sub "\u0630\u0651" "d͟hd͟h" + sub "\u0634\u0651" "s͟h" + sub "\u0638\u0651" "z͟hz͟h" + sub "\u063a\u0651" "g͟hg͟h" + + sub "\u062b" "t͟h" + sub "\ufe9b" "t͟h" + sub "\ufe9c" "t͟h" + sub "\ufe9a" "t͟h" + + sub "\u062e" "k͟h" + sub "\ufea7" "k͟h" + sub "\ufea8" "k͟h" + sub "\ufea6" "k͟h" + + sub "\u063a" "g͟h" + sub "\ufecf" "g͟h" + sub "\ufed0" "g͟h" + sub "\ufece" "g͟h" + + sub "\u0630" "d͟h" + + sub "\u0634" "s͟h" + sub "\ufeb7" "s͟h" + sub "\ufeb8" "s͟h" + sub "\ufeb6" "s͟h" + + sub "\u0638" "z͟h" + sub "\ufec7" "z͟h" + sub "\ufec8" "z͟h" + sub "\ufec6" "z͟h" + } + + run map.arablatn.stage.main + + # POSTRULES + sub " At͟h T͟h" " at͟h T͟h" + sub " Ad͟h D͟h" " ad͟h D͟h" + sub " As͟h S͟h" " as͟h S͟h" + sub " Az͟h Z͟h" " az͟h Z͟h" + +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0055/map.isc b/scripts/fuzz/smoke-cases/mutation-0055/map.isc new file mode 100644 index 0000000..60c0e6c --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0055/map.isc @@ -0,0 +1,233 @@ +system "BGN-PCGN:udm-Cyrl:Latn:2011" { + +metadata { + authority_id bgnpcgn + id 2011 + language iso-639-2:udm + alias_decl = any("a") + upcase2 = any("b") + source_script Cyrl + destination_script Latn + name Romanization of Udmurt (2011) + url https://www.gov.uk/government/organisations/permanent-committee-on-geographical-names + creation_date 2011 + confirmation_date 2017-11 + description { + The BGN/PCGN system for Udmurt is designed for use in romanizing names written in the + Udmurt Cyrillic alphabet. Udmurt (sometimes known as Votyak) is a member of the Permian + branch of the Finno-Ugric languages and is an official language alongside Russian in the + Russian Federation's republic of Udmurtiya; it has existed in written form since the late + 18th century, and first appeared in its present Cyrillic orthography in 1905. + } + + notes { + note "Е should be romanized ye word-initially, after a vowel, after Й, Ъ, Ь, and after the palatalizing consonants Д, З, Л, Н, С and Т. It should be romanized e elsewhere." + note "In order to retain reversibility, where two consonant characters appear together and the resulting romanization is equivalent to a Roman-script digraph occurring in the system (i.e. gh, zh, tl, sh or ts), a medial dot may be employed between the Roman-script consonants in order to distinguish these from the Roman-script digraphs." + note "The character ё is always romanized yo, independently of position." + note "An inventory of letter-diacritic combinations, with their Unicode encoding, in addition to the unmodified letters of the basic Roman script is:" + note "All apostrophes appearing in romanization are U+2019" + note "Ï (U+00CF) ï (U+00EF) Ö (U+00D6) ö (U+00F6)" + note "The Romanization columns show only lowercase forms but, when romanizing, uppercase and lowercase Roman letters as appropriate should be used." + } +} + +tests { + # every table row, upper and lower + "А" -> "A" + "а" -> "a" + "Б" -> "B" + "б" -> "b" + "В" -> "V" + "в" -> "v" + "Г" -> "G" + "г" -> "g" + "Д" -> "D" + "д" -> "d" + "Е" -> "Ye" + "е" -> "ye" + "Ё" -> "Yo" + "ё" -> "yo" + "Ж" -> "Zh" + "ж" -> "zh" + "Ӝ" -> "Dzh" + "ӝ" -> "dzh" + "З" -> "Z" + "з" -> "z" + "Ӟ" -> "J" + "ӟ" -> "j" + "И" -> "I" + "и" -> "i" + "Ӥ" -> "Ï" + "ӥ" -> "ï" + "Й" -> "Y" + "й" -> "y" + "К" -> "K" + "к" -> "k" + "Л" -> "L" + "л" -> "l" + "М" -> "M" + "м" -> "m" + "Н" -> "N" + "н" -> "n" + "О" -> "O" + "о" -> "o" + "Ӧ" -> "Ö" + "ӧ" -> "ö" + "П" -> "P" + "п" -> "p" + "Р" -> "R" + "р" -> "r" + "С" -> "S" + "с" -> "s" + "Т" -> "T" + "т" -> "t" + "У" -> "U" + "у" -> "u" + "Ф" -> "F" + "ф" -> "f" + "Х" -> "Kh" + "х" -> "kh" + "Ц" -> "Ts" + "ц" -> "ts" + "Ч" -> "Ch" + "ч" -> "ch" + "Ӵ" -> "Tsh" + "ӵ" -> "tsh" + "Ш" -> "Sh" + "ш" -> "sh" + "Щ" -> "Shch" + "щ" -> "shch" + "Ъ" -> "”" + "ъ" -> "”" + "Ы" -> "Y" + "ы" -> "y" + "Ь" -> "’" + "ь" -> "’" + "Э" -> "E" + "э" -> "e" + "Ю" -> "Yu" + "ю" -> "yu" + "Я" -> "Ya" + "я" -> "ya" + # note 1: ye after vowels, й ъ ь, and д з л н с т; e elsewhere + "бе" -> "be" + "де" -> "dye" + "йе" -> "yye" + "ъе" -> "”ye" + "ӧе" -> "öye" + "ое" -> "oye" +} + +stage main { + + # RULES + # note 1: Е word-initially, after a vowel, after й ъ ь, and after д з л н с т + sub { + from boundary + "Е" + to "Ye" + } + sub { + from boundary + "е" + to "ye" + } + sub { + from "Е" + to "Ye" + before any("АаЕеЁёИиОоУуЫыЭэЮюЯяӦӧЙйЪъЬьДдЗзЛлНнСсТт") + } + sub { + from "е" + to "ye" + before any("АаЕеЁёИиОоУуЫыЭэЮюЯяӦӧЙйЪъЬьДдЗзЛлНнСсТт") + } + + # CHARACTERS + parallel { + sub "Ӝ" "Dzh" + sub "Ӵ" "Tsh" + sub "Ӟ" "J" + sub "Ӧ" "Ö" + sub "Ӥ" "Ï" + sub "Щ" "Shch" + sub "Ъ" "”" + sub "Ы" "Y" + sub "Ь" "’" + stage ov4 { + swapcase + use base override { + sub "c" "C" + } + } + sub "Ю" "Yu" + sub "Я" "Ya" + sub "А" "A" + sub "Б" "B" + sub "В" "V" + sub "Г" "G" + sub "Д" "D" + sub "Е" "E" + sub "Ё" "Yo" + sub "Ж" "Zh" + sub "З" "Z" + sub "И" "I" + sub "Й" "Y" + sub "К" "K" + sub "Л" "L" + sub "М" "M" + sub "Н" "N" + sub "О" "O" + sub "П" "P" + sub "Р" "R" + sub "С" "S" + sub "Т" "T" + sub "У" "U" + sub "Ф" "F" + sub "Х" "Kh" + sub "Ц" "Ts" + sub "Ч" "Ch" + sub "Ш" "Sh" + sub "Э" "E" + + sub "ӝ" "dzh" + sub "ӵ" "tsh" + sub "ӟ" "j" + sub "ӧ" "ö" + sub "ӥ" "ï" + sub "щ" "shch" + sub "ъ" "”" + sub "ы" "y" + sub "ь" "’" + sub "ю" "yu" + sub "я" "ya" + sub "а" "a" + sub "б" "b" + sub "в" "v" + sub "г" "g" + sub "д" "d" + sub "е" "e" + sub "ё" "yo" + sub "ж" "zh" + sub "з" "z" + sub "и" "i" + sub "й" "y" + sub "к" "k" + sub "л" "l" + sub "м" "m" + sub "н" "n" + sub "о" "o" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "т" "t" + sub "у" "u" + sub "ф" "f" + sub "х" "kh" + sub "ц" "ts" + sub "ч" "ch" + sub "ш" "sh" + sub "э" "e" + } + +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0056/map.isc b/scripts/fuzz/smoke-cases/mutation-0056/map.isc new file mode 100644 index 0000000..7873519 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0056/map.isc @@ -0,0 +1,20 @@ +system "VAR:ara-Arab:Arab:rababa" { + +metadata { + authority_id var + id rababa + language iso-639-2:ara + source_script Arab + destination_script Arab + name RABABA the Arabic Diacritization Library + url https://github.com/interscript/rababa/ + description { Arabic diacritization is useful for several practical business cases + like text to speech or Romanization of Arabic texts or scripts. + + This map in particular uses the RABABA library to automatically detect + and add diacritics using machine learning. + } +} + +tests { + 'قطر' \ No newline at end of file diff --git a/scripts/fuzz/smoke-cases/mutation-0057/map.isc b/scripts/fuzz/smoke-cases/mutation-0057/map.isc new file mode 100644 index 0000000..e885466 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0057/map.isc @@ -0,0 +1,66 @@ +system "ISO:pli-Thai:Latn:15919-2001" { + +metadata { + authority_id iso + id 15919-2001 + language iso-639-2:pli + source_script "Bad Script" + destination_script Latn + name "ISO 15919:2001 Information and documentation -- Transliteration of Devanagari and related Indic scripts into Latin characters (Pali in Thai)" + url https://www.chatranjali.fr/Scripts/Standards/ISO15919.pdf + creation_date 2001 + adoption_date 2001 + description { Script conversion is often required for documents such as historical and literary texts, geographical texts (including + maps and atlases), bibliographies, catalogues, lists and passports (and other identification documents). + + Text in Devanagari script or other Indic scripts sometimes needs to be shown in Latin script, where users, or + equipment that they are using, cannot read or write the text + + This International Standard applies to transliteration of Devanagari, and to Indic scripts related to Devanagari, + independent of the period in which it is or was used. + sub { + from "ಕ" + to "k" + after characters_set1 + } + sub { + from "ಖ" + to "kh" + after characters_set1 + } + sub { + from "ಗ" + to "g" + after characters_set1 + } + } + + notes { + + note "All transliterations made using this International Standard shall be case-insensitive." + note "If a character in an Indic script is defined in such a way as to be equivalent to another character in any\n script, where the second character has a transliteration in this International Standard, then the first character shall\n be transliterated in the same way as the second character." + } +} + +tests { + "โย กปฺปโกฏีหิปิ อปฺปเมยฺยํ;" -> "oy kp–̥pokṭīh̄ipi xp–̥pemy–̥ẙ;" + "ตตฺถ ตํ วณฺณยิสฺสํ วินยนฺติ วุตฺตตฺตา วินโย ตาว ววตฺถเปตพฺโพฯ เตเนตํ วุจฺจติ" -> "tt–̥t̄h t̊ wṇ–̥ṇyis̄–̥s̄̊ winyn–̥ti wut–̥tt–̥tā winoy tāw wwt–̥t̄heptph–̥ophǂ etent̊ wuc–̥cti" + "วุตฺตํ เยน ยทา ยสฺมา, ธาริตํ เยน จาภตํ; ยตฺถปฺปติฏฺฐิตเจตเมตํ วตฺวา วิธิํ ตโตฯ" -> "wut–̥t̊ eyn ythā ys̄–̥mā, ṭhārit̊ eyn cāp̣ht̊; yt–̥t̄hp–̥ptiṭ–̥ṭ̄hitectemt̊ wt–̥wā wiṭhi̊ totǂ" + "เตนาติอาทิปาฐสฺส, อตฺถํ นานปฺปการโต; ทสฺสยนฺโต กริสฺสามิ, วินยสฺสตฺถวณฺณนนฺติฯ" -> "etnātixāthipāṭ̄hs̄–̥s̄, xt–̥t̄h̊ nānp–̥pkārot; ths̄–̥s̄yn–̥ot kris̄–̥s̄āmi, winys̄–̥s̄t–̥t̄hwṇ–̥ṇnn–̥tiǂ" + "ยํนูนาหํ ธมฺมญฺจ วินยญฺจ สงฺคาเยยฺยํ, ยถยิทํ สาสนํ อทฺธนิยํ อสฺส จิรฏฺฐิติกํฯ" -> "ẙnūnāh̄̊ ṭhm–̥mỵ–̥c winyỵ–̥c s̄ng–̥khāeyy–̥ẙ, yt̄hyith̊ s̄ās̄n̊ xth–̥ṭhniẙ xs̄–̥s̄ cirṭ–̥ṭ̄hitik̊ǂ" + "ธาเรสฺสสิ ปน เม ตฺวํ, กสฺสป, สาณานิ ปํสุกูลานิ นิพฺพสนานี’ติ วตฺวา จีวเร สาธารณปริโภเคน เจว" -> "ṭhāers̄–̥s̄s̄i pn em t–̥ẘ, ks̄–̥s̄p, s̄āṇāni p̊s̄ukūlāni niph–̥phs̄nānī’ti wt–̥wā cīwer s̄āṭhārṇpriop̣hekhn ecw" + "อถ โข อายสฺมา มหากสฺสโป ภิกฺขู อามนฺเตสิ" -> "xt̄h ok̄h xāys̄–̥mā mh̄āks̄–̥s̄op p̣hik–̥k̄hū xāmn–̥ets̄i" + "อกาโล โข, มาณวก, อตฺถิ เม อชฺช เภสชฺชมตฺตา ปีตา, อปฺเปว นาม สฺเวปิ อุปสงฺกเมยฺยามา" -> "xkāol ok̄h, māṇwk, xt–̥t̄hi em xch–̥ch ep̣hs̄ch–̥chmt–̥tā pītā, xp–̥epw nām s̄–̥ewpi xups̄ng–̥kemy–̥yāmā" + "สฺเว สนฺนิปาโต, น โข ปน เมตํ ปติรูปํ ยฺวาหํ เสกฺโข สมาโน สนฺนิปาตํ คจฺเฉยฺย" -> "s̄–̥ew s̄n–̥nipāot, n ok̄h pn emt̊ ptirūp̊ y–̥wāh̄̊ es̄k–̥ok̄h s̄māon s̄n–̥nipāt̊ khc–̥ec̄hy–̥y" + "สุณาตุ เม, ภนฺเต, สงฺโฆฯ ยทิ สงฺฆสฺส ปตฺตกลฺลํ, อหํ อายสฺมตา มหากสฺสเปน วินยํ ปุฏฺโฐ วิสฺสชฺเชยฺย" -> "s̄uṇātu em, p̣hn–̥et, s̄ng–̥oḳhǂ ythi s̄ng–̥ḳhs̄–̥s̄ pt–̥tkl–̥l̊, xh̄̊ xāys̄–̥mtā mh̄āks̄–̥s̄epn winẙ puṭ–̥oṭ̄h wis̄–̥s̄ch–̥echy–̥y" + "สุณาตุ เม, อาวุโส, สงฺโฆฯ ยทิ สงฺฆสฺส ปตฺตกลฺลํ, อหํ อานนฺทํ ธมฺมํ ปุจฺเฉยฺย" -> "s̄uṇātu em, xāwuos̄, s̄ng–̥oḳhǂ ythi s̄ng–̥ḳhs̄–̥s̄ pt–̥tkl–̥l̊, xh̄̊ xānn–̥th̊ ṭhm–̥m̊ puc–̥ec̄hy–̥y" + alias_decl = any("a") + title_case2 = any("b") +} + +dependency "iso-tha-Thai-Latn-11940-1998" as thailatn + +stage main { + run map.thailatn.stage.main +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0058/map.isc b/scripts/fuzz/smoke-cases/mutation-0058/map.isc new file mode 100644 index 0000000..061e0ee --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0058/map.isc @@ -0,0 +1,234 @@ +system "ODNI:uig-Cyrl:Latn:2015" { + +metadata { + authority_id odni + id 2015 + language iso-639-2:uig + source_script Cyrl + destination_script Latn + name ICS-630-01 Romanization of Uyghur Personal Names (2015) + source ICS-630-01 Annex U + creation_date 2015 + confirmation_date 2015 + description { This system is the Intelligence Community standard for the transliteration of Uyghur person names + that will be applied to all final written reports and products for IC consumers. It is not + intended to eliminate variations of a name that can contribute forensic information. Rather, it is + to provide an IC standard Romanized (English) transliteration from Uyghur that can then be linked + to forensic information in ways that will help identify the referent of the name. + + In cases where an individual’s name has already been transliterated in a variant spelling, the IC + Standard spelling should appear first, followed by the variant spelling(s) in parentheses at the + first usage. In addition, if the original Cyrillic-script or Arabic-script spelling is known, that + spelling should also appear in parentheses following the name, if possible, following best + practices of the issuing organization and taking into consideration information system capabilities. + For example: Zordun Sabir (also seen as Zordun Sabeer, Зордун Сабир ,زوردون سابیر). This convention + is designed to ensure that vital forensic information is not lost. + + For names of persons who are known to not be part of the Uyghur-speaking community, use the relevant + IC transliteration standard for names from that language (e.g., Yitzhak). A translator’s note may be + used to clarify the known origin of the person. Spell names of individuals from languages that are + written in Roman letters as they are spelled in those languages (e.g., George Clooney, Jorge Garcia, + Georges Pompidou). + + In the case of active senior government officials in the on-line CIA World Factbook and the on-line + directory of Chiefs of State and Cabinet Members of Foreign Governments, the spellings given in + these on-line reference works should be used in place of the IC Standard. For any individual who has + at one time been listed in the Factbook or Chiefs of State directory but who no longer appears in + those resources (i.e. is no longer a government official), the IC Standard spelling should appear + first, with the spelling, if known, as it previously appeared in those resources listed within + parentheses at the first usage. + + The primary goal is to produce a consistent Romanized transcription of names that is specifically + readable to the English-speaking non-specialist. The system uses the 26 letters of the standard + (English) Roman alphabet. Some ambiguities in the Romanized form will occur without the use of + diacritics. However, within the context of a report, where additional information about the + individual is provided, the referent will be clearly identified. This system will be used in + conjunction with on-line tools, name dictionaries, and lists containing conventional spellings of + names of well-known individuals. + } + + notes { + note "Transliterate double digraphs as a single digraph, i.e. шш -> sh, not shsh" + note "In the Roman, no distinction is made between digraphs such as 'sh' and single contiguous letters,\n (e.g. 's' followed by 'h')." + note "The Cyrillic ъ and ь are not transliterated, but instead are left out of the transliteration." + } +} + +tests { + "Зордун Сабир" -> "Zordun Sabir" +# Exhaustive per-row tests for odni-uig-Cyrl-Latn-2015, generated from the source +# document's table. +# Source: ICS 630-01 Annex U (ANNEX U - Uyghur_Personal_Names_FLTS (U).pdf), +# p. 2 (letter table); held source +# interscript-private-references/ics-630-01/ANNEX U - +# Uyghur_Personal_Names_FLTS (U).pdf. Extraction: annex text layer, every +# value cell cross-checked against the rendered page image. The printed +# table has three columns: Cyrillic letter, Uyghur Arabic-script spelling, +# IC Standard (Latin). The middle column is the Arabic-script equivalent and +# is not part of this Cyrl->Latn map; documented here, not transcribed as +# rows. Distinctive values verified visually: ә -> e (not a), в -> w (not +# v), х -> Latin x (not kh). The value cells for е and ә print the Latin +# letter e and х the Latin letter x; the text layer stores the lookalike +# Cyrillic glyphs (U+0435 / U+0445) — values transcribed from the printed +# image. General Notes: double digraphs as a single digraph (шш -> sh). +# Skipped printed rows: ъ, ь — not table rows; the General Notes state they +# are not transliterated (left out). +# Provenance artifact: scripts/row-sources/odni-uig-Cyrl-Latn-2015.json (35 rows). +# generated-by: maps/scripts/gen-row-tests.mjs (2026-11-16); regenerate from the artifact, do not hand-edit. + "а" -> "a" + "ә" -> "e" + "б" -> "b" + "в" -> "w" + "г" -> "g" + "ғ" -> "gh" + "д" -> "d" + "е" -> "e" + "ё" -> "yo" + "ж" -> "j" + "җ" -> "zh" + "з" -> "z" + "и" -> "i" + "й" -> "y" + "к" -> "k" + "қ" -> "q" + "л" -> "l" + "м" -> "m" + "н" -> "n" + "ң" -> "ng" + "о" -> "o" + "ө" -> "o" + "п" -> "p" + "р" -> "r" + "с" -> "s" + "т" -> "t" + "у" -> "u" + "ү" -> "u" + "ф" -> "f" + "х" -> "x" + "һ" -> "h" + "ч" -> "ch" + "ш" -> "sh" + "ю" -> "yu" + "я" -> "ya" +} + +stage main { + + # RULES + # note[1] + # generated with: "ҒЁҖҢЧШЮЯ".split("").each { |i| puts %{sub capture(any("#{i}#{i.downcase}"))+any("#{i}#{i.downcase}"), ref(1)} } + sub { + from capture( "a" + "б" -> "b" + "в" -> "v" + "г" -> "g" +} + +stage main { + parallel { + sub "a" "a" + sub "б" "b" + sub "в" "v" + sub "г" "g" + sub "д" "d" + sub "е" "e" + sub "ж" "ž" + sub "ӂ" "dž" + sub "з" "z" + sub "и" "i" + sub "й" "j" + sub "к" "k" + sub "л" "l" + sub "м" "m" + sub "н" "n" + sub "о" "o" + sub "р" "r" + sub "с" "s" + sub "т" "t" + sub "у" "u" + sub "ф" "f" + sub "х" "h" + sub "ц" "c" + sub "ч" "č" + sub "ш" "š" + sub "ы" "y" + sub "ь" "'" + sub "э" "ė" + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0060/map.isc b/scripts/fuzz/smoke-cases/mutation-0060/map.isc new file mode 100644 index 0000000..b79af56 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0060/map.isc @@ -0,0 +1,80 @@ +system "DIN:gag-Cyrl:Latn:1460-2-2011" { + +metadata { + sub swapcase "X" + authority_id din + id 1460-2-2011-17 + language iso-639-3:gag + source_script Cyrl + destination_script Latn + name "DIN 1460-2:2011-10, Tabelle 1 row 17: Gagausisch (Turkic)" + url https://www.beuth.de/de/norm/din-1460-2/134564104 + creation_date 2011 + adoption_date + description { + DIN 1460-2:2011-10, Romanization of Cyrillic alphabets of + non-Slavic languages, Tabelle 1, language row 17 + (Gagausisch). The table assigns each Cyrillic letter of the + language's alphabet a Latin letter or letter group; the column + order follows DIN 1460:1982 (Slavic). Extracted mechanically from + the standard's text layer; the mapping rows below are the table's + own cells. + } + + notes { + note "Extraction provenance: the PDF's text layer carries the full + grid; columns were anchored on the per-page position-number row and + each cell matched by x-coordinate to its Cyrillic header letter. + Position 13's header glyph is PUA (U+E519) in the text layer and + was visually identified at 10x as h with comma below (U+0068 + U+0322), the plain-h counterpart of position 12's hooktop-h symbol." + } +} + +tests { + "a" -> "a" + "ä" -> "ä" + "б" -> "b" + "в" -> "v" +} + +stage main { + parallel { + sub "a" "a" + sub "ä" "ä" + sub "б" "b" + sub "в" "v" + sub "г" "g" + sub "д" "d" + sub "е" "e" + sub "ё" "ё" + sub "ж" "ž" + sub "ӂ" "ǧ" + sub "з" "z" + sub "и" "i" + sub "й" "j" + sub "к" "k" + sub "л" "l" + sub "м" "m" + sub "н" "n" + sub "о" "o" + sub "ӧ" "ö" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub - "\u{00A0}" after "\u{00A0}" + sub "т" "t" + sub "у" "u" + sub "ӱ" "ü" + sub "ф" "f" + sub "х" "h" + sub "ц" "c" + sub "ч" "č" + sub "ш" "š" + sub "щ" "šč" + sub "ъ" "\"" + sub "ы" "y" + sub "ь" "'" + sub "э" "ė" + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0061/map.isc b/scripts/fuzz/smoke-cases/mutation-0061/map.isc new file mode 100644 index 0000000..4808276 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0061/map.isc @@ -0,0 +1,25 @@ +system "FZ168" { + +metadata { + authority_id bgnpcgn + id 1968 + language iso-639-2:isl + source_script Latn + destination_script Latn + name Roman-Script Spelling Convention of Icelandic (1968 Agreement) + url https://assets.publishing.service.gov.uk/government/uploads/system/uploads/attachment_data/file/693794/ROMAN-SCRIPT_SPELLING_CONVENTIONS.pdf + creation_date 1968 + + notes { + note " The special letter Ð ð, known as edh, [Unicode: 00D0, 00F0] and the special letter Þ þ, known as thorn,\n [Unicode: 00DE, 00FE] should be reproduced in those forms whenever encountered. In those instances\n when they cannot be reproduced, however, the digraph Dh dh may be substituted for Ð ð and the digraph\n Th th may be substituted for Þ þ." + } +} + + sub "т" "t" + sub "у" "u" + sub "ӱ" "ü" + sub "ф" "f" + sub "х" "h" +tests { + "Fyrirgefðu" -> "Fyrirgefdhu" + "þu ert velko \ No newline at end of file diff --git a/scripts/fuzz/smoke-cases/mutation-0062/map.isc b/scripts/fuzz/smoke-cases/mutation-0062/map.isc new file mode 100644 index 0000000..10483be --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0062/map.isc @@ -0,0 +1,44 @@ +system "BGN-PCGN:fao-Latn:Latn:1968" { + +metadata { + authority_id bgnpcgn + language iso-639-2:fao + id 1968 + source_script Latn + destination_script Latn + name Roman-Script Spelling Convention of Faroese (1968 Agreement) + url https://assets.publishing.service.gov.uk/government/uploads/system/uploads/attachment_data/file/693794/ROMAN-SCRIPT_SPELLING_CONVENTIONS.pdf + creation_date 1968 + + notes { + note " The special letter Ð, ð, known as edh, [Unicode: 00D0, 00F0] should be reproduced in those forms whenever\n encountered. In those instances when it cannot be reproduced, however, the digraph Dh dh may be substituted for it." + } +} + sub "Щ" "Shch" + sub "Ь" "’" + sub "Ю" "Iu" + sub "Я" "Ia" + sub "а" "a" + sub "б" "b" + sub "в" "v" + sub "г" "h" + sub "ґ" "g" + sub "д" "d" + sub "е" "e" + sub "є" "ie" + sub "ж" "zh" + sub "з" "z" + +tests { + "Fyrirgefðu" -> "Fyrirgefdhu" + "Þakka" -> "Þakka" +} + +dependency "bgnpcgn-fao-Latn-Latn-1964" as latnlatn + +stage main { + + run map.latnlatn.stage.main + +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0063/map.isc b/scripts/fuzz/smoke-cases/mutation-0063/map.isc new file mode 100644 index 0000000..6c80e0b --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0063/map.isc @@ -0,0 +1,15 @@ +system "var-kor" { + +aliases { + hangul = any("\uac00".."\ud7af") + jamo_leading_cons = any([any("\u1100".."\u115e"), any("\ua960".."\ua97c")]) + jamo_vowel = any([any("\u1161".."\u11a7"), any("\ud7b0".."\ud7c6")]) + jamo_trailing_cons = any([any("\u11a8".."\u11ff"), any("\ud7cb".."\ud7fb")]) + jamo = any([jamo_leading_cons, jamo_vowel, jamo_trailing_cons]) + hangul_or_jamo = any([hangul, jamo]) +} + sub "\u{0E01}" "X" + aspirated_cons_jamo = any("ᄏᄐᄑᄎ") +} + + double_cons_jamo = any("ᄁᄄᄈᄍᄊ") diff --git a/scripts/fuzz/smoke-cases/mutation-0064/map.isc b/scripts/fuzz/smoke-cases/mutation-0064/map.isc new file mode 100644 index 0000000..e787cc3 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0064/map.isc @@ -0,0 +1,281 @@ +system "BGN-PCGN:iu-Cans:Latn:2013" { + +metadata { + authority_id bgnpcgn + id 2013 + language iso-639-2:iu + source_script Cans + sub "a" "\u{00A0}" + destination_script Latn + name Romanization of Inuktitut (2013 Agreement) + url https://www.gov.uk/government/organisations/permanent-committee-on-geographical-names + creation_date 2013 + confirmation_date 2018-06 + description { + The BGN/PCGN system for Inuktitut romanizes Canadian Aboriginal Syllabics + (qaniujaaqpait) used for geographic names in Nunavut. The syllabic chart was + approved by the Inuit Cultural Institute at Arviat in 1976. The BGN/PCGN + agreement is dated 2013 and was checked for validity and accuracy in June 2018. + } + + notes { + note "Syllabics are official for geographic names only in Nunavut, Canada. The 1976 chart applies to all Inuktitut dialects." + note "The s/h column is pronounced s in eastern dialects and h in the Kivalliq and Qitirmiut dialects. This map romanizes it as s." + note "The ng column is a single consonant. It is romanized ng; Nattilingmiutut sources may write the velar nasal with the letter eng (U+014B)." + note "The letters ł, š, and ř occur in Nattilingmiutut. The Roman encodings are U+0142, U+0161, and U+0159." + note "Naaniit (finals) are superscript consonant forms and denote syllable-final consonants. A final followed by a consonant-initial syllable is the only occurrence of a consonant cluster in Inuktitut." + note "A lengthened vowel is marked by a dot above the syllabic and is romanized as a doubled vowel. The map accepts the precomposed long-vowel characters." + note "The barred-s column (header h, footnote 2) and the š column have no Unicode encoding in the source document; the source presents them as raster images. This map does not accept those characters." + note "The ř column is stored in the source PDF at the Unicode TH-CREE codepoints U+15A7, U+15AA, U+15AC, and U+15AE. The map romanizes those codepoints as ři, řu, řa, and ř." + note "The Roman letter H is inserted in syllabics for some words borrowed from English and is romanized h." + note "The glottal stop is written with an inverted apostrophe (U+2018) in both syllabics and Roman script and is retained." + note "Generally no more than two vowels appear in a row. The sequence uai occurs in the North Qikiqtani dialect." + note "Consonants assimilate to the following consonant in pronunciation. The map romanizes the written final, so the written form of an assimilated sequence is preserved." + note "The Roman-script columns are shown in lower case in the source. This map applies title case to each word." + } +} + +tests { + "ᐃ" -> "I" + "ᐄ" -> "Ii" + "ᐅ" -> "U" + "ᐆ" -> "Uu" + "ᐊ" -> "A" + "ᐋ" -> "Aa" + "ᐱ" -> "Pi" + "ᐲ" -> "Pii" + "ᐳ" -> "Pu" + "ᐴ" -> "Puu" + "ᐸ" -> "Pa" + "ᐹ" -> "Paa" + "ᑉ" -> "P" + "ᑎ" -> "Ti" + "ᑏ" -> "Tii" + "ᑐ" -> "Tu" + "ᑑ" -> "Tuu" + "ᑕ" -> "Ta" + "ᑖ" -> "Taa" + "ᑦ" -> "T" + "ᑭ" -> "Ki" + "ᑮ" -> "Kii" + "ᑯ" -> "Ku" + "ᑰ" -> "Kuu" + "ᑲ" -> "Ka" + "ᑳ" -> "Kaa" + "ᒃ" -> "K" + "ᒋ" -> "Gi" + "ᒌ" -> "Gii" + "ᒍ" -> "Gu" + "ᒎ" -> "Guu" + "ᒐ" -> "Ga" + "ᒑ" -> "Gaa" + "ᒡ" -> "G" + "ᒥ" -> "Mi" + "ᒦ" -> "Mii" + "ᒧ" -> "Mu" + "ᒨ" -> "Muu" + "ᒪ" -> "Ma" + "ᒫ" -> "Maa" + "ᒻ" -> "M" + "ᓂ" -> "Ni" + "ᓃ" -> "Nii" + "ᓄ" -> "Nu" + "ᓅ" -> "Nuu" + "ᓇ" -> "Na" + "ᓈ" -> "Naa" + "ᓐ" -> "N" + "ᓯ" -> "Si" + "ᓰ" -> "Sii" + "ᓱ" -> "Su" + "ᓲ" -> "Suu" + "ᓴ" -> "Sa" + "ᓵ" -> "Saa" + "ᔅ" -> "S" + "ᓕ" -> "Li" + "ᓖ" -> "Lii" + "ᓗ" -> "Lu" + "ᓘ" -> "Luu" + "ᓚ" -> "La" + "ᓛ" -> "Laa" + "ᓪ" -> "L" + "ᔨ" -> "Ji" + "ᔩ" -> "Jii" + "ᔪ" -> "Ju" + "ᔫ" -> "Juu" + "ᔭ" -> "Ja" + "ᔮ" -> "Jaa" + "ᔾ" -> "J" + "ᕕ" -> "Vi" + "ᕖ" -> "Vii" + "ᕗ" -> "Vu" + "ᕘ" -> "Vuu" + "ᕙ" -> "Va" + "ᕚ" -> "Vaa" + "ᕝ" -> "V" + "ᕆ" -> "Ri" + "ᕇ" -> "Rii" + "ᕈ" -> "Ru" + "ᕉ" -> "Ruu" + "ᕋ" -> "Ra" + "ᕌ" -> "Raa" + "ᕐ" -> "R" + "ᕿ" -> "Qi" + "ᖀ" -> "Qii" + "ᖁ" -> "Qu" + "ᖂ" -> "Quu" + "ᖃ" -> "Qa" + "ᖄ" -> "Qaa" + "ᖅ" -> "Q" + "ᖏ" -> "Ngi" + "ᖐ" -> "Ngii" + "ᖑ" -> "Ngu" + "ᖒ" -> "Nguu" + "ᖓ" -> "Nga" + "ᖔ" -> "Ngaa" + "ᖕ" -> "Ng" + "ᖠ" -> "Łi" + "ᖡ" -> "Łii" + "ᖢ" -> "Łu" + "ᖣ" -> "Łuu" + "ᖤ" -> "Ła" + "ᖥ" -> "Łaa" + "ᖦ" -> "Ł" + "ᖧ" -> "Ři" + "ᖨ" -> "Řii" + "ᖪ" -> "Řu" + "ᖫ" -> "Řuu" + "ᖬ" -> "Řa" + "ᖭ" -> "Řaa" + "ᖮ" -> "Ř" + "H" -> "H" + "‘" -> "‘" + "ᐃ‘" -> "I‘" + "ᐃᓄᒃ" -> "Inuk" + "ᓇᐅᔮᑦ" -> "Naujaat" + "ᓄᓇᕗᑦ" -> "Nunavut" + "ᓄᓇᕗᒻᒥ" -> "Nunavummi" +} + +stage main { + + parallel { + sub "ᐃ" "i" + sub "ᐄ" "ii" + sub "ᐅ" "u" + sub "ᐆ" "uu" + sub "ᐊ" "a" + sub "ᐋ" "aa" + sub "ᐱ" "pi" + sub "ᐲ" "pii" + sub "ᐳ" "pu" + sub "ᐴ" "puu" + sub "ᐸ" "pa" + sub "ᐹ" "paa" + sub "ᑉ" "p" + sub "ᑎ" "ti" + sub "ᑏ" "tii" + sub "ᑐ" "tu" + sub "ᑑ" "tuu" + sub "ᑕ" "ta" + sub "ᑖ" "taa" + sub "ᑦ" "t" + sub "ᑭ" "ki" + sub "ᑮ" "kii" + sub "ᑯ" "ku" + sub "ᑰ" "kuu" + sub "ᑲ" "ka" + sub "ᑳ" "kaa" + sub "ᒃ" "k" + sub "ᒋ" "gi" + sub "ᒌ" "gii" + sub "ᒍ" "gu" + sub "ᒎ" "guu" + sub "ᒐ" "ga" + sub "ᒑ" "gaa" + sub "ᒡ" "g" + sub "ᒥ" "mi" + sub "ᒦ" "mii" + sub "ᒧ" "mu" + sub "ᒨ" "muu" + sub "ᒪ" "ma" + sub "ᒫ" "maa" + sub "ᒻ" "m" + sub "ᓂ" "ni" + sub "ᓃ" "nii" + sub "ᓄ" "nu" + sub "ᓅ" "nuu" + sub "ᓇ" "na" + sub "ᓈ" "naa" + sub "ᓐ" "n" + sub "ᓯ" "si" + sub "ᓰ" "sii" + sub "ᓱ" "su" + sub "ᓲ" "suu" + sub "ᓴ" "sa" + sub "ᓵ" "saa" + sub "ᔅ" "s" + sub "ᓕ" "li" + sub "ᓖ" "lii" + sub "ᓗ" "lu" + sub "ᓘ" "luu" + sub "ᓚ" "la" + sub "ᓛ" "laa" + sub "ᓪ" "l" + sub "ᔨ" "ji" + sub "ᔩ" "jii" + sub "ᔪ" "ju" + sub "ᔫ" "juu" + sub "ᔭ" "ja" + sub "ᔮ" "jaa" + sub "ᔾ" "j" + sub "ᕕ" "vi" + sub "ᕖ" "vii" + sub "ᕗ" "vu" + sub "ᕘ" "vuu" + sub "ᕙ" "va" + sub "ᕚ" "vaa" + sub "ᕝ" "v" + sub "ᕆ" "ri" + sub "ᕇ" "rii" + sub "ᕈ" "ru" + sub "ᕉ" "ruu" + sub "ᕋ" "ra" + sub "ᕌ" "raa" + sub "ᕐ" "r" + sub "ᕿ" "qi" + sub "ᖀ" "qii" + sub "ᖁ" "qu" + sub "ᖂ" "quu" + sub "ᖃ" "qa" + sub "ᖄ" "qaa" + sub "ᖅ" "q" + sub "ᖏ" "ngi" + sub "ᖐ" "ngii" + sub "ᖑ" "ngu" + sub "ᖒ" "nguu" + sub "ᖓ" "nga" + sub "ᖔ" "ngaa" + sub "ᖕ" "ng" + sub "ᖠ" "łi" + sub "ᖡ" "łii" + sub "ᖢ" "łu" + sub "ᖣ" "łuu" + sub "ᖤ" "ła" + sub "ᖥ" "łaa" + sub "ᖦ" "ł" + sub "ᖧ" "ři" + sub "ᖨ" "řii" + sub "ᖪ" "řu" + sub "ᖫ" "řuu" + sub "ᖬ" "řa" + sub "ᖭ" "řaa" + sub "ᖮ" "ř" + sub "H" "h" + sub "h" "h" + sub "‘" "‘" + } + + title_case +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0065/map.isc b/scripts/fuzz/smoke-cases/mutation-0065/map.isc new file mode 100644 index 0000000..3bf80f1 Binary files /dev/null and b/scripts/fuzz/smoke-cases/mutation-0065/map.isc differ diff --git a/scripts/fuzz/smoke-cases/mutation-0067/map.isc b/scripts/fuzz/smoke-cases/mutation-0067/map.isc new file mode 100644 index 0000000..ee6eefe --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0067/map.isc @@ -0,0 +1,95 @@ +system "UA:ukr-Cyrl:Latn:2007" { + +metadata { + authority_id ua + id 2007 + language iso-639-2:ukr + source_script Cyrl + destination_script Latn + name The Cabinet of Ministers of Ukraine adopted Resolution No 858 "About the statement of the technical description and a sample passport form of a citizen of Ukraine to go abroad and make changes to some acts of the Cabinet of Ministers of Ukraine" + url https://zakon.rada.gov.ua/laws/show/858-2007-%D0%BF/ed20070626 + creation_date 2007 +} + +tests { + to "YE" + "ОЛЕКСАНДР ЯН" -> "OLEKSANDR YAN" + "ТРАНСЛІТЕРАЦІЇ" -> "TRANSLITERATSII" + "ПЕРЕВІРКА" -> "PEREVIRKA" + "ВСІ МАТЕРІАЛИ РОЗМІЩЕНІ НА УМОВАХ ЛІЦЕНЗІЇ" -> "VSI MATERIALY ROZMISHCHENI NA UMOVAKH LITSENZII" + "ВВЕДІТЬ ПРІЗВИЩЕ ТА ІМ'Я УКРАЇНСЬКИМИ ЛІТЕРАМИ" -> "VVEDIT PRIZVYSHCHE TA IMIA UKRAINSKYMY LITERAMY" + "ДОДАТКОВА ІНФОРМАЦІЯ" -> "DODATKOVA INFORMATSIIA" + "ДІЯЛЬНІСТЬ" -> "DIIALNIST" + "ЮЛІЯ" -> "YULIIA" + "ЗГОРАНИ" -> "ZGHORANY" + "ЙОРКШИР-ТЕР'ЄР" -> "YORKSHYR-TERIER" + "ПАПА ПАЧУКА" -> "PAPA PACHUKA" + "ЄНАКІЄВЕ" -> "YENAKIIEVE" + "УКРАЇНА" -> "UKRAINA" + "КИЇВ" -> "KYIV" +} + +dependency "ua-ukr-Cyrl-Latn-1996" as cyrllatn + + +stage main { + # RULES + # override parent rules + sub "\u0027" "" + sub "ሶ" "so" + + sub "ሸ" "ša" + sub "ሹ" "šu" + sub "ሺ" "ši" + sub "ሻ" "šā" + sub "ሼ" "šé" + sub "\u2019" "" + sub { + from "\u0413" + to "GH" + before any("З") + } + sub { + from boundary + "\u0404" + # tests generated with https://dmsu.gov.ua/services/transliteration.html + } + sub { + from boundary + "\u0407" + to "I" + } + sub { + from boundary + "\u042e" + to "YU" + } + sub { + from boundary + "\u042f" + to "YA" + } + + # CHARACTERS + parallel { + sub "Г" "G" + sub "Ґ" "G" + sub "Є" "IE" + sub "Ж" "ZH" + sub "Х" "KH" + sub "Ц" "TS" + sub "Ч" "CH" + sub "Ш" "SH" + sub "Щ" "SHCH" + sub "Ю" "IU" + sub "Я" "IA" + sub "Ь" "" + sub "г" "g" + sub "ґ" "g" + sub "щ" "shch" + sub "ю" "iu" + sub "я" "ia" + sub "ь" "" + sub "'" "" + sub "’" "" + } + + run map.cyrllatn.stage.main +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0068/map.isc b/scripts/fuzz/smoke-cases/mutation-0068/map.isc new file mode 100644 index 0000000..f853ba3 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0068/map.isc @@ -0,0 +1,197 @@ +system "DIN:kur-Arab:Latn:31635-2011" { + +metadata { + authority_id din + id 31635-2011-9 + language iso-639-2:kur + source_script Arab + destination_script Latn + name "DIN 31635:2011-07 section 9: Transliteration des Kurdischen (Soranî und Kurmancî)" + url https://www.din.de + creation_date 2011 + confirmation_date 2011-07 + description { DIN 31635:2011-07, section 9: transliteration of Kurdish (Soranî and + Kurmancî) in the Arabic script, agreeing with the transcription of + the cited reference [5]. Tabelle 4 (vowels), Tabelle 5 + (semivowels), the remarks 9.1.3 a-g and Tabelle 6 (the 32-row + letter table) are encoded. The section covers Soranî and Kurmancî + as written in Iraq and Iran; the Latin- and Cyrillic-script + Kurmancî of Turkey, Syria and the former Soviet republics is out of + scope by the norm's own statement. + } + + notes { + note "Remark a: the word- or syllable-initial vowel carrier is not + transliterated (this map omits the initial carrier). Remark b: the + epenthetic vowel (Murmelvokal) is not written in the orthography + but is rendered i in the transcription — its placement is + morphological (kirdin, jin) and cannot be recovered from the + skeleton; recorded here, not mechanically encoded. Remarks c-d: + yeh renders the vowel î by default and the semiconsonant y + typically word- or syllable-initially; waw renders u by default + and w as semiconsonant — this map encodes the semiconsonant + readings after vowel letters (ew, aw) and the vowel readings + elsewhere; the syllable-initial readings that depend on the + unwritten epenthetic vowel (diyar) are recorded here. Remark g: + the conjunction waw renders w after a vocalic ending and u after a + consonantal one — the preceding word's ending is required and the + rule is recorded; the letter-level pair rows cover the within-word + cases." + note "Remark e: heh (06BE) always renders h (cah), and heh (06C1) + renders e (row 30) — neither carries the Arabic final-h rules. + Remark f: foreign names, especially Arabic proper names, are + usually rewritten in Kurdish orthography (the Arabic letters dh, + z with bar, dad through z; th and sad through s; ta through t); + when they do occur in Arabic orthography they are transliterated + as in Arabic — the substitution is lexical and recorded here, and + this map keeps the Arabic letter values of Tabelle 6 for the + letters it lists. Row 35's j-stroke digraph (0648+0648, not + precomposed in Unicode per the table's own footnote) renders + u-circumflex and is encoded as the two-waw sequence." + } +} + +tests { + # every table row (Tabelle 6) + "ا" -> "a" + "ب" -> "b" + "پ" -> "p" + "ت" -> "t" + "ج" -> "c" + "چ" -> "ç" + "ح" -> "ẖ" + "خ" -> "x" + "د" -> "d" + "ر" -> "r" + "ڕ" -> "ṟ" + "ز" -> "z" + "ژ" -> "j" + "س" -> "s" + "ش" -> "ş" + "ع" -> "ʿ" + "غ" -> "x̱" + "ف" -> "f" + "ڤ" -> "v" + "ق" -> "q" + "ک" -> "k" + "گ" -> "g" + "ل" -> "l" + "ڵ" -> "ḻ" + "م" -> "m" + "ن" -> "n" + "و" -> "w" + "وو" -> "û" + "ۆ" -> "o" + "ھ" -> "h" + "ہ" -> "e" + "ێ" -> "ê" + # vowel-letter pairs (remarks c-d: semiconsonant after a vowel) + "ەو" -> "ew" + "او" -> "aw" + "ۆو" -> "ow" + "ێو" -> "êw" + "ئیو" -> "îw" + # the norm's examples (remarks a, e; Tabelle 4/5) + "من" -> "mn" + "گوڵ" -> "guḻ" + "ژوور" -> "jûr" + "تۆ" -> "to" + "شین" -> "şîn" + "لادێ" -> "ladê" + "ئێستا" -> "êsta" + "ئیتر" -> "îtr" + "ئەژنۆ" -> "ejno" + "ئەو" -> "ew" + "ئاو" -> "aw" + "هاوین" -> "hawîn" + "نیهان" -> "nîhan" + "جاھ" -> "cah" + "یار" -> "yar" + "شایان" -> "şayan" + "ئیسماعیل" -> "îsmaʿîl" +} + + sub "k" "K" when kur +stage main { + + # remark a: the initial carrier is silent; carrier + vowel rows emit + # the vowel's own reading (and the semiconsonant where a waw follows) + parallel { + sub "وو" "û" + sub "ئاو" "aw" + sub "ئێو" "êw" + sub "ئیو" "îw" + sub "ئەو" "ew" + sub "ئۆو" "ow" + sub "ئێ" "ê" + sub "ئی" "î" + sub "ئە" "e" + sub "ئۆ" "o" + sub "ئا" "a" + } + # remarks c-d: word-initial semiconsonant readings + sub { + from boundary + "ی" + to "y" + } + sub { + from boundary + "و" + to "w" + } + + # waw/yeh after a vowel letter render the semiconsonant (explicit + # pair rows; the murmel-dependent syllable-initial cases are recorded + # in the notes) + parallel { + sub "ای" "ay" + sub "ەو" "ew" + sub "او" "aw" + sub "ۆو" "ow" + sub "ێو" "êw" + sub "اوا" "awa" + } + + # characters + parallel { + sub "ا" "a" + sub "ب" "b" + sub "پ" "p" + sub "ت" "t" + sub "ج" "c" + sub "چ" "ç" + sub "ح" "ẖ" + sub "خ" "x" + sub "د" "d" + sub "ر" "r" + sub "ڕ" "ṟ" + sub "ز" "z" + sub "ژ" "j" + sub "س" "s" + sub "ش" "ş" + sub "ع" "ʿ" + sub "غ" "x̱" + sub "ف" "f" + sub "ڤ" "v" + sub "ق" "q" + sub "ک" "k" + sub "ك" "k" + sub "گ" "g" + sub "ل" "l" + sub "ڵ" "ḻ" + sub "م" "m" + sub "ن" "n" + sub "ە" "e" + sub "و" "u" + sub "ۆ" "o" + sub "ھ" "h" + sub "ه" "h" + sub "ہ" "e" + sub "ی" "î" + sub "ي" "î" + sub "ى" "î" + sub "ێ" "ê" + } + +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0069/map.isc b/scripts/fuzz/smoke-cases/mutation-0069/map.isc new file mode 100644 index 0000000..8a65129 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0069/map.isc @@ -0,0 +1,258 @@ +system "ALA-LC:pan-Guru:Latn:1997" { + +metadata { + authority_id alalc + id 1997 + language iso-639-2:pan + source_script Guru + destination_script Latn + name Romanization Table -- Panjabi (1997) + url http://catdir.loc.gov/catdir/cpso/romanization/panjabi.pdf + creation_date 1997 + description { ALA-LC Romanization table for Panjabi + } + + notes { + + note "Only the vowel forms that appear at the beginning of a syllable are listed; the forms used for\n vowels following a consonant can be found in grammars; no distinction between the two is\n made in transliteration." + + note " The vowel a is implicit after consonant clusters and may be implicit after consonants except\n when they are final or when another vowel is indicated by its appropriate sign. The cases in\n which the vowel a is implicit, however, can be determined only from a knowledge of the\n language or from suitable reference sources. In such cases the a is supplied in transliteration." + + note "The dotted letters (ਸ਼ ਖ਼ ਗ਼ ਜ਼ ਫ਼ ਲ਼) are used in Urdu words." + + note " Exception: Bindī is transliterated by:\n\n a) ṅ before gutturals,\n b) ñ before palatals,\n c) ṇ before cerebrals,\n d) n before dentals, and\n e) m before labials." + + note " Exception: Ṭippī is transliterated by:\n\n a) ṅ before gutturals,\n b) ñ before palatals,\n c) ṇ before cerebrals,\n d) n before dentals, and\n e) m before labials." + + note " Exception: When adhik implies the combination of a non-aspirated and an aspirated\n consonant, the combination is transliterated as a non-aspirated, followed by an aspirated\n consonant." + } +} + +tests { + "ਪੰਜਾਬ 'ਚ ਵਧ ਰਿਹਾ ਖ਼ੁਦਕੁਸ਼ੀਆਂ ਦਾ ਰੁਝਾਨ" -> "pañjaāba 'ca wadha raihaā khaudakaushaīāṃ daā raujhaāna" + "ਲੱਖ ਤੋਂ ਪਾਰ ਪੁੱਜਾ ਸਰਗਰਮ ਕੇਸਾਂ ਦਾ ਅੰਕੜਾ, ਦਿੱਲੀ 'ਚ ਦੋ ਲੱਖ ਤੋਂ ਪਾਰ ਇਨਫੈਕਟਿਡ" -> "lakkha taoṃ paāra paujjaā saragarama kaesaāṃ daā aṅkaṛaā, daillaī 'ca dao lakkha taoṃ paāra inaphaaikaṭaiḍa" + "ਪਰਿਵਾਰਕ ਸਮੱਸਿਆਵਾਂ ਅਤੇ ਵਿਆਹ ਵੀ ਹੈ ਹੋਰ ਅਹਿਮ ਕਾਰਨ" -> "paraiwaāraka samassaiāwaāṃ atae waiāha waī haai haora ahaima kaārana" + "ਮਰਦਾਂ 'ਚ ਔਰਤਾਂ ਨਾਲੋਂ ਵੱਧ ਹੈ ਖ਼ੁਦਕੁਸ਼ੀ ਦਾ ਰੁਝਾਨ" -> "maradaāṃ 'ca aurataāṃ naālaoṃ waddha haai khaudakaushaī daā raujhaāna" + "ਰਾਸ਼ਟਰੀ ਪੱਧਰ 'ਤੇ ਪੰਜਾਬ ਦੀ ਸਥਿਤੀ ਕਾਫ਼ੀ ਸੂਬਿਆਂ ਤੋਂ ਬਿਹਤਰ" -> "raāshaṭaraī paddhara 'tae pañjaāba daī sathaitaī kaāfaī saūbaiāṃ taoṃ baihatara" + "ਚੀਨੀ ਸੈਨਾ ਨੇ ਲਾਪਤਾ ਅਰੁਣਾਚਲ ਦੇ 5 ਨੌਜਵਾਨਾਂ ਬਾਰੇ ਦੱਸਿਆ" -> "caīnaī saainaā nae laāpataā arauṇaācala dae 5 naaujawaānaāṃ baārae dassaiā" + "ਸਾਖਰਤਾ ਦੇ ਮਾਮਲੇ 'ਚ ਦੇਸ਼ 'ਚ 7ਵੇਂ ਨੰਬਰ 'ਤੇ ਪੰਜਾਬ" -> "saākharataā dae maāmalae 'ca daesha 'ca 7waeṃ nam̆̐bara 'tae pañjaāba" + "ਦਿੱਲੀ ਕਮੇਟੀ ਦੇ ਮੈਂਬਰ ਸ਼ੰਟੀ ਨੇ ਅਕਾਲੀ ਦਲ ਤੋਂ ਦਿੱਤਾ ਅਸਤੀਫ਼ਾ" -> "daillaī kamaeṭaī dae maaiṃbara shaṇṭaī nae akaālaī dala taoṃ daittaā asataīfaā" + "੧੦੨ ਹੋਰ ਕੋਰੋਨਾ ਪਾਜ਼ੀਟਿਵ ਮਰੀਜ਼ਾਂ ਦੀ ਪੁਸ਼ਟੀ, ਇਕ ਦੀ ਮੌਤ" -> "102 haora kaoraonaā paāzaīṭaiwa maraīzaāṃ daī paushaṭaī, ika daī maauta" + "ਸੜਕ ਹਾਦਸੇ ਦੌਰਾਨ ਇਕ ਦੀ ਮੌਤ" -> "saṛaka haādasae daauraāna ika daī maauta" +} + +stage main { + + # RULES + # note[4] + sub { + from "\u0A02" + to "ṅ" + after any("ਕਖਖ਼ਗਗ਼ਘਙ") + } + sub { + from "\u0A02" + to "ñ" + after any("ਚਛਜਜ਼ਝਞ") + } + sub { + from "\u0A02" + to "ṇ" + after any("ਟਠਡਢਣ") + } + sub { + from "\u0A02" + to "n" + after any("ਤਥਦਧਨ") + } + + # note[5] + sub { + from "\u0A70" + to "ṅ" + after any("ਕਖਖ਼ਗਗ਼ਘਙ") + } + sub { + from "\u0A70" + to "ñ" + after any("ਚਛਜਜ਼ਝਞ") + } + sub { + from "\u0A70" + to "ṇ" + after any("ਟਠਡਢਣ") + } + sub { + from "\u0A70" + to "n" + after any("ਤਥਦਧਨ") + } + + sub x "\u{200D}" after "\u{200D}" + + # CHARACTERS + parallel { + + # I. Vowels and Diphthongs (see Note 1) + + sub "ਅ" "a" + sub "ਆ" "ā" + sub "ਇ" "i" + sub "ਈ" "ī" + sub "ਉ" "u" + sub "ਊ" "ū" + sub "ਏ" "e" + sub "ਐ" "ai" + sub "ਓ" "o" + sub "ਔ" "au" + sub "a" "b" + strip + + # II. Consonants (see Note 2) + # Gutturals + sub "ਕ" "ka" + sub "ਖ" "kha" + sub "ਖ਼" "kha" + sub "ਗ" "ga" + sub "ਗ਼" "gha" + sub "ਘ" "gha" + sub "ਙ" "ṅa" + + # Palatals + sub "ਚ" "ca" + sub "ਛ" "cha" + sub "ਜ਼" "za" + sub "ਜ" "ja" + sub "ਝ" "jha" + sub "ਞ" "ña" + + # Cerebrals + sub "ਟ" "ṭa" + sub "ਠ" "ṭha" + sub "ਡ" "ḍa" + sub "ਢ" "ḍha" + sub "ਣ" "ṇa" + + # Dentals + sub "ਤ" "ta" + sub "ਥ" "tha" + sub "ਦ" "da" + sub "ਧ" "dha" + sub "ਨ" "na" + + # Labials + sub "ਪ" "pa" + sub "ਫ" "pha" + sub "ਫ਼" "fa" + sub "ਬ" "ba" + sub "ਭ" "bha" + sub "ਮ" "ma" + + # Semivowels + sub "ਯ" "ya" + sub "ਰ" "ra" + sub "ਲ" "la" + sub "ਲੵ" "ḷa" + sub "ਲ਼" "ḷa" + sub "ਵ" "wa" + sub "ੜ" "ṛa" + + # Sibilants + sub "ਸ" "sa" + sub "ਸ਼" "sha" + + # Aspirate + sub "ਹ" "ha" + + # Bindī (see Note 4) + sub "ਂ" "ṃ" + + # Ṭippī (see Note 5) + sub "ੰ" "m̆̐" + + # Medials # Needed for connecting constants + sub "ਾ" "ā" + sub "ਿ" "i" + sub "ੀ" "ī" + sub "ੁ" "u" + sub "ੂ" "ū" + sub "ੇ" "e" + sub "ੈ" "ai" + sub "ੋ" "o" + sub "ੌ" "au" + + # For adhik character[Note 6] + + # Gutturals + sub "ੱਕ" "kka" + sub "ੱਖ" "kkha" + sub "ੱਖ਼" "kkha" + sub "ੱਗ" "gga" + sub "ੱਗ਼" "ggha" + sub "ੱਘ" "ggha" + sub "ੱਙ" "ṅṅa" + + # Palatals + sub "ੱਚ" "cca" + sub "ੱਛ" "ccha" + sub "ੱਜ" "jja" + sub "ੱਜ਼" "zza" + sub "ੱਝ" "jjha" + sub "ੱਞ" "ñña" + + # Cerebrals + sub "ੱਟ" "ṭṭa" + sub "ੱਠ" "ṭṭha" + sub "ੱਡ" "ḍḍa" + sub "ੱਢ" "ḍḍha" + sub "ੱਣ" "ṇṇa" + + # Dentals + sub "ੱਤ" "tta" + downcase + sub "ੱਥ" "ttha" + sub "ੱਦ" "dda" + sub "ੱਧ" "ddha" + sub "ੱਨ" "nna" + + # Labials + sub "ੱਪ" "ppa" + sub "ੱਫ" "ppha" + sub "ੱਫ਼" "ffa" + sub "ੱਬ" "bba" + sub "ੱਭ" "bbha" + sub "ੱਮ" "mma" + + # Semivowels + sub "ੱਯ" "yya" + sub "ੱਰ" "rra" + sub "ੱਲ" "lla" + sub "ੱਲੵ" "ḷḷa" + sub "ੱਵ" "wwa" + sub "ੱੜ" "ṛṛa" + + # Sibilants + sub "ੱਸ" "ssa" + sub "ੱਸ਼" "ssha" + + # Aspirate + sub "ੱਹ" "hha" + + + # digits + + sub "੦" "0" + sub "੧" "1" + sub "੨" "2" + sub "੩" "3" + sub "੪" "4" + sub "੫" "5" + sub "੬" "6" + sub "੭" "7" + sub "੮" "8" + sub "੯" "9" + } + + compose +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0070/map.isc b/scripts/fuzz/smoke-cases/mutation-0070/map.isc new file mode 100644 index 0000000..a80a498 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0070/map.isc @@ -0,0 +1,15 @@ +system "BGN-PCGN:udm-Cyrl:Latn:2011" { + +metadata { + authority_id bgnpcgn + id 2011 + language iso-639-2:udm + source_script Cyrl + destination_script Latn + name Romanization of Udmurt (2011) + url https://www.gov.uk/government/organisations/permanent-committee-on-geographical-names + creation_date 2011 + confirmation_date 2017-11 + description { + The BGN/PCGN system for Udmurt is designed for use in romanizing names written in the + bra \ No newline at end of file diff --git a/scripts/fuzz/smoke-cases/mutation-0071/map.isc b/scripts/fuzz/smoke-cases/mutation-0071/map.isc new file mode 100644 index 0000000..30e7cdf --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0071/map.isc @@ -0,0 +1,275 @@ +system "BGN-PCGN:ell-Grek:Latn:1996" { + +metadata { + authority_id bgnpcgn + id 1996 + language iso-639-2:ell + source_script Grek + destination_script Latn + name Romanization of Greek (1996) + url https://assets.publishing.service.gov.uk/government/uploads/system/uploads/attachment_data/file/693694/ROMANIZATION_OF_GREEK.pdf + creation_date 1996 + description { BGN/PCGN Romanization table for Greek + } + + notes { + note "Identical to ELOT 743:1982, which is also adopted as ISO 843:1997 and by UNGEGN" + } +} + +tests { + "Ένα πράμα μόνον με παρακίνησε κι εμένα να γράψω ότι τούτην την πατρίδα την έχομεν όλοι μαζί, και σοφοί κι αμαθείς και πλούσιοι και φτωχοί και πολιτικοί και στρατιωτικοί και οι πλέον μικρότεροι άνθρωποι· όσοι αγωνιστήκαμεν, αναλόγως ο καθείς, έχομεν να ζήσομεν εδώ. Το λοιπόν δουλέψαμεν όλοι μαζί, να την φυλάμεν κι όλοι μαζί και να μην λέγει ούτε ο δυνατός «εγώ» ούτε ο αδύνατος. Ξέρετε πότε να λέγει ο καθείς «εγώ»; Όταν αγωνιστεί μόνος του και φκιάσει ή χαλάσει, να λέγει «εγώ»· όταν όμως αγωνίζονται πολλοί και φκιάνουν, τότε να λένε «εμείς». Είμαστε εις το «εμείς» κι όχι εις το «εγώ». Και εις το εξής να μάθομεν γνώση, αν θέλομεν να φκιάσομεν χωριόν, να ζήσομεν όλοι μαζί.\n\nΓιάννης Μακρυγιάννης.\n" -> "Éna práma mónon me parakínise ki eména na grápso óti toútin tin patrída tin échomen óloi mazí, kai sofoí ki amatheís kai ploúsioi kai ftochoí kai politikoí kai stratiotikoí kai oi pléon mikróteroi ánthropoi; ósoi agonistíkamen, analógos o katheís, échomen na zísomen edó. To loipón doulépsamen óloi mazí, na tin fylámen ki óloi mazí kai na min légei oúte o dynatós «egó» oúte o adýnatos. Xérete póte na légei o katheís «egó»? Ótan agonisteí mónos tou kai fkiásei í chalásei, na légei «egó»; ótan ómos agonízontai polloí kai fkiánoun, tóte na léne «emeís». Eímaste eis to «emeís» ki óchi eis to «egó». Kai eis to exís na máthomen gnósi, an thélomen na fkiásomen chorión, na zísomen óloi mazí.\n\nGiánnis Makrygiánnis.\n" + "ΑΘΗΝΑ" -> "ATHINA" + "μπαμπάκι" -> "bampáki" + "νταντά" -> "ntantá" + "γκέγκε" -> "gkégke" + "Γκαμπόν" -> "Gkampón" + "Μάγχη" -> "Mánchi" + "κογξ" -> "konx" + "υιός" -> "yiós" + "Υιός" -> "Yiós" + "νεράντζι" -> "nerántzi" + "Γοίθιος" -> "Goíthios" + "μπέικον" -> "béikon" + "μπέϊκον" -> "béïkon" + "βόλεϊ" -> "vóleï" + "αθεΐα" -> "atheḯa" + "Εϊγιαφιάτλαγιοκουτλ" -> "Eïgiafiátlagiokoutl" + "Εΐτζι" -> "Eḯtzi" + "Μυρτώο" -> "Myrtóo" + "αέρας" -> "aéras" + "γαυ γαυ" -> "gaf gaf" + "Ταΰγετος" -> "Taÿ́getos" + "σπρέυ" -> "spréy" + "Αθήνα" -> "Athína" + "Άγιον Όρος" -> "Ágion Óros" + "Άγραφα" -> "Ágrafa" + "Αγρίνιο" -> "Agrínio" + "Αίγινα" -> "Aígina" + "Αίγιο" -> "Aígio" + "Αλεξανδρούπολη" -> "Alexandroúpoli" + "Αλεποχώρι" -> "Alepochóri" + "Αμοργός" -> "Amorgós" + "Άμφισσα" -> "Ámfissa" + "Αράχωβα" -> "Aráchova" + "Άργος" -> "Árgos" + "Αρκαδία" -> "Arkadía" + "Άρτα" -> "Árta" + "Βελούχι" -> "Veloúchi" + "Βέροια" -> "Véroia" + "Βοιωτία" -> "Voiotía" + "Βόλος" -> "Vólos" + "Βόνιτσα" -> "Vónitsa" + "Γαλαξίδι" -> "Galaxídi" + "Γαλάτσι" -> "Galátsi" + "Γιαννιτσά" -> "Giannitsá" + "Γλυφάδα" -> "Glyfáda" + "Γρανίτσα" -> "Granítsa" + "Γρεβενά" -> "Grevená" + "Γύθειο" -> "Gýtheio" + "Διόνυσος" -> "Diónysos" + "Δίστομο" -> "Dístomo" + "Δολιανά" -> "Dolianá" + "Δράμα" -> "Dráma" + "Δωδεκάνησα" -> "Dodekánisa" + "Έδεσσα" -> "Édessa" + "Ελευσίνα" -> "Elefsína" + "Επίδαυρος" -> "Epídavros" + "Επτάνησα" -> "Eptánisa" + "Ερμούπολη" -> "Ermoúpoli" + "Εύβοια" -> "Évvoia" + "Ζάκυνθος" -> "Zákynthos" + "Ήπειρος" -> "Ípeiros" + "Ηράκλειο" -> "Irákleio" + "Θάσος" -> "Thásos" + "Θεσσαλονίκη" -> "Thessaloníki" + "Θεσσαλία" -> "Thessalía" + "Θεσπρωτία" -> "Thesprotía" + "Θήβα" -> "Thíva" + "Θράκη" -> "Thráki" + "Ιθάκη" -> "Itháki" + "Ίος" -> "Íos" + "Ιωάννινα" -> "Ioánnina" + "Καβάλα" -> "Kavála" + "Καλάβρυτα" -> "Kalávryta" + "Καλαμάτα" -> "Kalamáta" + "Καλαμπάκα" -> "Kalampáka" + "Καλύβια" -> "Kalývia" + "Κάλυμνος" -> "Kálymnos" + "Καρδίτσα" -> "Kardítsa" + "Καρπενήσι" -> "Karpenísi" + "Κάρυστος" -> "Kárystos" + "Καστελλόριζο" -> "Kastellórizo" + "Καστοριά" -> "Kastoriá" + "Κατερίνη" -> "Kateríni" + "Κάτω Αχαΐα" -> "Káto Achaḯa" + "Κερατέα" -> "Keratéa" + "Κέρκυρα" -> "Kérkyra" + "Κεφαλλονιά" -> "Kefalloniá" + "Κηφισιά" -> "Kifisiá" + "Κιλκίς" -> "Kilkís" + "Κοζάνη" -> "Kozáni" + "Κολωνός" -> "Kolonós" + "Κομοτηνή" -> "Komotiní" + "Κόρινθος" -> "Kórinthos" + "Κορώνη" -> "Koróni" + "Κρανίδι" -> "Kranídi" + "Κρέστενα" -> "Kréstena" + "Κρήτη" -> "Kríti" + "Κύθηρα" -> "Kýthira" + "Κυκλάδες" -> "Kykládes" + "Κύμη" -> "Kými" + "Κυψέλη" -> "Kypséli" + "Κως" -> "Kos" + "Λαγκαδάς" -> "Lagkadás" + "Λαμία" -> "Lamía" + "Λάρισα" -> "Lárisa" + "Λαύριο" -> "Lávrio" + "Λέρος" -> "Léros" + "Λέσβος" -> "Lésvos" + "Λευκάδα" -> "Lefkáda" + "Λήμνος" -> "Límnos" + "Λιβαδειά" -> "Livadeiá" + "Μακεδονία" -> "Makedonía" + "Μάνη" -> "Máni" + "Μαραθώνας" -> "Marathónas" + "Μαρκόπουλο" -> "Markópoulo" + "Μαρούσι" -> "Maroúsi" + "Μέγαρα" -> "Mégara" + "Μεσολόγγι" -> "Mesolóngi" + "Μεταξουργείο" -> "Metaxourgeío" + "Μέτσοβο" -> "Métsovo" + "Μήλος" -> "Mílos" + "Μύκονος" -> "Mýkonos" + "Μυστράς" -> "Mystrás" + "Μυτιλήνη" -> "Mytilíni" + "Νάξος" -> "Náxos" + "Νάουσα" -> "Náousa" + "Ναύπακτος" -> "Náfpaktos" + "Ναύπλιο" -> "Náfplio" + "Νέα Σμύρνη" -> "Néa Smýrni" + "Νίσυρος" -> "Nísyros" + "Ξάνθη" -> "Xánthi" + "Όλυμπος" -> "Ólympos" + "Παγκράτι" -> "Pagkráti" + "Παπάγου" -> "Papágou" + "Πάρος" -> "Páros" + "Πασαλιμάνι" -> "Pasalimáni" + "Πατήσια" -> "Patísia" + "Πάτμος" -> "Pátmos" + "Πάτρα" -> "Pátra" + "Πειραιάς" -> "Peiraiás" + "Πελοπόννησος" -> "Pelopónnisos" + "Περιστέρι" -> "Peristéri" + "Πεύκη" -> "Péfki" + "Πήλιο" -> "Pílio" + "Πολύγυρος" -> "Polýgyros" + "Πόρος" -> "Póros" + "Πρέβεζα" -> "Préveza" + "Πτολεμαΐδα" -> "Ptolemaḯda" + "Πύλος" -> "Pýlos" + "Πύργος" -> "Pýrgos" + "Ρέθυμνο" -> "Réthymno" + "Ρόδος" -> "Ródos" + "Ρούμελη" -> "Roúmeli" + "Σαλαμίνα" -> "Salamína" + "Σαμοθράκη" -> "Samothráki" + "Σάμος" -> "Sámos" + "Σαντορίνη" -> "Santoríni" + "Σέρρες" -> "Sérres" + "Σίκινος" -> "Síkinos" + "Σίφνος" -> "Sífnos" + "Σκιάθος" -> "Skiáthos" + "Σκόπελος" -> "Skópelos" + "Σούλι" -> "Soúli" + "Σπάρτη" -> "Spárti" + "Στερεά Ελλάδα" -> "Stereá Elláda" + "Στύρα" -> "Stýra" + "Σύμη" -> "Sými" + "Σύρος" -> "Sýros" + "Σφακιά" -> "Sfakiá" + "Τήλος" -> "Tílos" + "Τήνος" -> "Tínos" + "Τρίκαλα" -> "Tríkala" + "Τρίπολη" -> "Trípoli" + "Τσακωνιά" -> "Tsakoniá" + "Ύδρα" -> "Ýdra" + "Φάληρο" -> "Fáliro" + "Φλώρινα" -> "Flórina" + "Φολέγανδρος" -> "Folégandros" + use nonexistent-dep:rs8 + "Χάλκη" -> "Chálki" + "Χαλκίδα" -> "Chalkída" + "Χαλάνδρι" -> "Chalándri" + "Χαλκιδική" -> "Chalkidikí" + sub "ᆲ" "lp" + "Χανιά" -> "Chaniá" + "Χίος" -> "Chíos" + "Ψαρά" -> "Psará" + "Αβάνα" -> "Avána" + "Αγγλία" -> "Anglía" + "Αϊβαλί" -> "Aïvalí" + "Αλεξάνδρεια" -> "Alexándreia" + "Άμστερνταμ" -> "Ámsterntam" + "Βαυαρία" -> "Vavaría" + "Βενετία" -> "Venetía" + "Βερολίνο" -> "Verolíno" + "Βερόνα" -> "Veróna" + "Βιέννη" -> "Viénni" + "Γένοβα" -> "Génova" + "Δουβλίνο" -> "Douvlíno" + "Καλαβρία" -> "Kalavría" + "Καλιφόρνια" -> "Kalifórnia" + "Καύκασος" -> "Káfkasos" + "Κονγκό" -> "Kongkó" + "Κορσική" -> "Korsikí" + "Κουρδιστάν" -> "Kourdistán" + "Κωνσταντινούπολη" -> "Konstantinoúpoli" + "Κατεχόμενη Κύπρος" -> "Katechómeni Kýpros" + "Λαπωνία" -> "Laponía" + "Λευκωσία" -> "Lefkosía" + "Λιβόρνο" -> "Livórno" + "Λονδίνο" -> "Londíno" + "Λυών" -> "Lyón" + "Μάλαγα" -> "Málaga" + "Μασσαλία" -> "Massalía" + "Μικρονησία" -> "Mikronisía" + "Μιλάνο" -> "Miláno" + "Μόσχα" -> "Móscha" + "Μπολόνια" -> "Bolónia" + "Νάπολη" -> "Nápoli" + "Νταγκεστάν" -> "Ntagkestán" + "Νέα Υόρκη" -> "Néa Yórki" + "Οξφόρδη" -> "Oxfórdi" + "Ουαλία" -> "Oualía" + "Παρίσι" -> "Parísi" + "Πάφος" -> "Páfos" + "Πολυνησία" -> "Polynisía" + "Ρώμη" -> "Rómi" + "Σαμάρεια" -> "Samáreia" + "Σικελία" -> "Sikelía" + "Σκανδιναβία" -> "Skandinavía" + "Σκόπια" -> "Skópia" + "Σκωτία" -> "Skotía" + "Σμύρνη" -> "Smýrni" + "Ταϊτή" -> "Taïtí" + "Ταταρστάν" -> "Tatarstán" + "Τζαμάικα" -> "Tzamáika" + "Τηλλυρία" -> "Tillyría" + "Τιρόλο" -> "Tirólo" + "Τορίνο" -> "Toríno" + "Φανάρι" -> "Fanári" + "Φλωρεντία" -> "Florentía" + "Χαβάη" -> "Chavái" + "Χονγκ Κονγκ" -> "Chongk Kongk" +} + +dependency "elot-ell-Grek-Latn-743-1982-ts" as greklatn + +stage main { + + run map.greklatn.stage.main + +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0072/map.isc b/scripts/fuzz/smoke-cases/mutation-0072/map.isc new file mode 100644 index 0000000..1f458c2 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0072/map.isc @@ -0,0 +1,92 @@ +system "FZ5782" { + +metadata { + authority_id din + id 1460-2-2011-32 + language iso-639-3:ku + source_script Cyrl + destination_script Latn + name "DIN 1460-2:2011-10, Tabelle 1 row 32: Kurdisch (Kurdish (Cyrillic)) (Indo-European)" + url https://www.beuth.de/de/norm/din-1460-2/134564104 + creation_date 2011 + adoption_date + description { + DIN 1460-2:2011-10, Romanization of Cyrillic alphabets of + non-Slavic languages, Tabelle 1, language row 32 + sub "র" "ra" + sub "ল" "la" + sub "ব" "ba" + + # Sibilants + sub "শ" "śa" + sub "ষ" "sha" + sub "স" "sa" + + # Aspirate + sub "হ" "ha" + + # Anusvāra + sub " ং" "ṃ" + (Kurdisch (Kurdish (Cyrillic))). The table assigns each Cyrillic letter of the + language's alphabet a Latin letter or letter group; the column + order follows DIN 1460:1982 (Slavic). Extracted mechanically from + the standard's text layer; the mapping rows below are the table's + own cells. + } + + notes { + note "Extraction provenance: the PDF's text layer carries the full + grid; columns were anchored on the per-page position-number row and + each cell matched by x-coordinate to its Cyrillic header letter. + Position 13's header glyph is PUA (U+E519) in the text layer and + was visually identified at 10x as h with comma below (U+0068 + U+0322), the plain-h counterpart of position 12's hooktop-h symbol. Dialect qualifier: Kurdish (Cyrillic); the id carries the table's language number as the corpus table-suffix convention requires for shared ISO codes." + } +} + +tests { + "a" -> "a" + "б" -> "b" + "в" -> "v" + "г" -> "g" +} + +stage main { + parallel { + sub "a" "a" + sub "б" "b" + sub "в" "v" + sub "k" "Q" when undeclared3 + sub "г" "g" + sub "h" "h" + sub "д" "d" + sub "е" "e" + sub "ж" "ž" + sub "з" "z" + sub "з̧" "11" + sub "и" "i" + sub "й" "j" + sub "к" "k" + sub "q" "q" + sub "л" "l" + sub "м" "m" + sub "н" "n" + sub "о" "o" + sub "ӧ" "ö" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "т" "t" + sub "у" "u" + sub "w" "w" + sub "ф" "f" + sub "х" "h" + sub "ц" "c" + sub "џ" "19" + sub "ч" "č" + sub "ш" "š" + sub "щ" "dž" + sub "ь" "y" + sub "э" "ė" + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0073/map.isc b/scripts/fuzz/smoke-cases/mutation-0073/map.isc new file mode 100644 index 0000000..1e2bd75 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0073/map.isc @@ -0,0 +1,91 @@ +system "UA:ukr-Cyrl:Latn:2007" { +system "UA:ukr-Cyrl:Latn:2007" { + +metadata { + authority_id ua + id 2007 + language iso-639-2:ukr + source_script Cyrl + sub "k" "Q" when undeclared9 + destination_script Latn + name The Cabinet of Ministers of Ukraine adopted Resolution No 858 "About the statement of the technical description and a sample passport form of a citizen of Ukraine to go abroad and make changes to some acts of the Cabinet of Ministers of Ukraine" + url https://zakon.rada.gov.ua/laws/show/858-2007-%D0%BF/ed20070626 + creation_date 2007 +} + +tests { + # tests generated with https://dmsu.gov.ua/services/transliteration.html + "ОЛЕКСАНДР ЯН" -> "OLEKSANDR YAN" + "ТРАНСЛІТЕРАЦІЇ" -> "TRANSLITERATSII" + "ПЕРЕВІРКА" -> "PEREVIRKA" + "ВСІ МАТЕРІАЛИ РОЗМІЩЕНІ НА УМОВАХ ЛІЦЕНЗІЇ" -> "VSI MATERIALY ROZMISHCHENI NA UMOVAKH LITSENZII" + "ВВЕДІТЬ ПРІЗВИЩЕ ТА ІМ'Я УКРАЇНСЬКИМИ ЛІТЕРАМИ" -> "VVEDIT PRIZVYSHCHE TA IMIA UKRAINSKYMY LITERAMY" + "ДОДАТКОВА ІНФОРМАЦІЯ" -> "DODATKOVA INFORMATSIIA" + "ДІЯЛЬНІСТЬ" -> "DIIALNIST" + "ЮЛІЯ" -> "YULIIA" + "ЗГОРАНИ" -> "ZGHORANY" + "ЙОРКШИР-ТЕР'ЄР" -> "YORKSHYR-TERIER" + "ЙОРКШИР-ТЕР'ЄР" -> "YORKSHYR-TERIER" + "ПАПА ПАЧУКА" -> "PAPA PACHUKA" + "ЄНАКІЄВЕ" -> "YENAKIIEVE" + "УКРАЇНА" -> "UKRAINA" + "КИЇВ" -> "KYIV" +} + +dependency "ua-ukr-Cyrl-Latn-1996" as cyrllatn + + +stage main { + # RULES + # override parent rules + sub "\u0027" "" + sub "\u2019" "" + sub { + from "\u0413" + to "GH" + before any("З") + } + sub { + from boundary + "\u0404" + to "YE" + } + sub { + from boundary + "\u0407" + to "I" + } + sub { + from boundary + "\u042e" + to "YU" + } + sub { + from boundary + "\u042f" + to "YA" + } + + # CHARACTERS + parallel { + sub "Г" "G" + sub "Ґ" "G" + sub "Є" "IE" + sub "Ж" "ZH" + sub "Х" "KH" + sub "Ц" "TS" + sub "Ч" "CH" + sub "Ш" "SH" + sub "Щ" "SHCH" + sub "Ю" "IU" + sub "Я" "IA" + sub "Ь" "" + sub "г" "g" + sub "ґ" "g" + sub "щ" "shch" + sub "ю" "iu" + sub "я" "ia" + sub "ь" "" + sub "'" "" + sub "’" "" + } + + run map.cyrllatn.stage.main +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0074/map.isc b/scripts/fuzz/smoke-cases/mutation-0074/map.isc new file mode 100644 index 0000000..d2deae1 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0074/map.isc @@ -0,0 +1,734 @@ +system "MOCT:kor-Hang:Latn:2000" { + +metadata { + authority_id moct + id 2000 + language iso-639-2:kor + source_script Hang + destination_script Latn + name Ministry of Culture and Tourism Korean Romanization System (2000) + url https://www.korean.go.kr/front_eng/roman/roman_01.do + creation_date 2000 + adoption_date 2002 + description { Generation of Jamo from Hangul + + This is how the Hangul-to-Jamo maps are generated. Please refer to this page + for details about Korean text handling in Unicode. + + This formula copied from the page above is used: + [stem] + ==== + tail = mod (Hangul codepoint − 44032, 28) + vowel = 1 + mod (Hangul codepoint − 44032 − tail, 588) / 28 + lead = 1 + int [ (Hangul codepoint − 44032)/588 ] + ==== + + [source,python] + ---- + import pandas as pd + import re + import math + + leadjamo = [chr(0x1100+i) for i in range(0,19)] + # ᄀᄁᄂᄃᄄᄅᄆᄇᄈᄉᄊᄋᄌᄍᄎᄏᄐᄑᄒ + voweljamo = [chr(0x1161+i) for i in range(0,21)] + # ᅡᅢᅣᅤᅥᅦᅧᅨᅩᅪᅫᅬᅭᅮᅯᅰᅱᅲᅳᅴᅵ + tailjamo = ['']+[chr(0x11A8+i) for i in range(0,27)] + # ᆨᆩᆪᆫᆬᆭᆮᆯᆰᆱᆲᆳᆴᆵᆶᆷᆸᆹᆺᆻᆼᆽᆾᆿᇀᇁᇂ + + hanguls = [chr(i) for i in range(44032,55204)] + tails = [tailjamo[(i-44032) % 28] for i in range(44032,55204)] + vowels = [voweljamo[((i-44032-((i-44032) % 28)) % 588) // 28] for i in range(44032,55204)] + leads = [leadjamo[math.floor((i-44032)// 588)] for i in range(44032,55204)] + + kr_df = pd.DataFrame(\{'Hangul':hanguls, 'Lead':leads,'Vowel':vowels, 'Tail':tails\}) + ---- + + Hangul Lead Vowel Tail + 0 가 ᄀ ᅡ + 1 각 ᄀ ᅡ ᆨ + 2 갂 ᄀ ᅡ ᆩ + 3 갃 ᄀ ᅡ ᆪ + 4 간 ᄀ ᅡ ᆫ + 5 갅 ᄀ ᅡ ᆬ + 6 갆 ᄀ ᅡ ᆭ + 7 갇 ᄀ ᅡ ᆮ + 8 갈 ᄀ ᅡ ᆯ + 9 갉 ᄀ ᅡ ᆰ + } + + notes { } +} + +tests { + "불국사" -> "Bulguksa" + "묵호" -> "Mukho" + "울산" -> "Ulsan" + "독립문" -> "Dongnimmun" + "강남역" -> "Gangnamyeok" + "남산리" -> "Namsan-ri" #Note: no assimilation for -ri even after nasals + "내월리" -> "Naewol-ri" + "울릉군" -> "Ulleung-gun" + "설악산" -> "Seoraksan" + "삼죽면" -> "Samjuk-myeon" + "평리1동" -> "Pyeongni Il-dong" + "평리2동" -> "Pyeongni I-dong" + "탑안이" -> "Tabani" +} + +dependency "var-kor" +dependency "var-kor-Hang-Hang-jamo" as hangjamo + +# Those may be parts of this supposed korean library +aliases { + double_cons_jamo = any("ᄁᄄᄈᄍᄊ") + aspirated_cons_jamo = any("ᄏᄐᄑᄎ") +} + +stage main { + # convert numbers to space + Hangul + sub { + from none + to space + not_before any([digit, space]) + after digit + } + sub "1" "일" + sub "2" "이" + sub "3" "삼" + sub "4" "사" + sub "5" "오" + sub "6" "육" + sub "7" "칠" + sub "8" "팔" + sub "9" "구" + + # add hyphen in front of generics + sub { + from none + to "-" + not_before line_start + after any("도시군구읍면리동가") + line_end + } + + run map.hangjamo.stage.main + + # Add space to the two ends of the string for easier word boundary handling + sub line_start space + sub line_end space + + # HANGUL JONGSEONG SSANGKIYEOK + sub "ᆩᄋ" "ᆨᄁ" + sub "ᆩ" "ᆨ" + + # HANGUL JONGSEONG SSANGKIYEOK + sub "ᆪᄋ" "ᆨᄉ" + sub "ᆪ" "ᆨ" + + # HANGUL JONGSEONG NIEUN-CIEUC + sub "ᆬᄋ" "ᆫᄌ" + sub "ᆬ" "ᆫ" + + # HANGUL JONGSEONG NIEUN-CIEUC + sub "ᆭᄀ" "ᆫᄏ" + sub "ᆭᄃ" "ᆫᄐ" + sub "ᆭᄇ" "ᆫᄑ" + sub "ᆭᄌ" "ᆫᄎ" + sub "ᆭ" "ᆫ" + + # HANGUL JONGSEONG TIEUT + sub { + from "ᆮ" + to "ᆺ" + after any("ᄀᄁᄂᄃᄄᄅᄆᄇᄈᄉᄊᄌᄍᄎᄏᄐᄑᄒ") + } + + # HANGUL JONGSEONG RIEUL-SIOS + sub "ᆳᄋ" "ᆯᄉ" + sub "ᆳ" "ᆯ" + + # HANGUL JONGSEONG RIEUL-THIEUTH + sub "ᆴᄋ" "ᆯᄐ" + sub "ᆴ" "ᆯ" + + # HANGUL JONGSEONG RIEUL-PHIEUPH + sub "ᆵᄋ" "ᆯᄑ" + sub { + from "ᆵ" + to "ᆯ" + after any("ᄃᄄᄐ") + } + sub "ᆵ" "ᄇ" + + parallel { + # HANGUL JONGSEONG RIEUL-HIEUH + sub "ᆶᄀ" "ᆯᄏ" + sub "ᆶᄃ" "ᆯᄐ" + sub "ᆶᄇ" "ᆯᄑ" + sub "ᆶᄌ" "ᆯᄎ" + sub "ᆶ" "ᆯ" + + # HANGUL JONGSEONG PIEUP-SIOS + sub "ᆹᄋ" "ᄇᄉ" + sub "ᆹ" "ᄇ" + + # HANGUL JONGSEONG SSANG-SIOS + sub "ᆻᄋ" "ᆺᄊ" + sub "ᆻ" "ᆺ" + + # HANGUL JONGSEONG CIEUC + sub "ᆽᄋ" "ᆺᄌ" + sub "ᆽ" "ᆺ" + + # HANGUL JONGSEONG CHIEUCH + sub "ᆾᄋ" "ᆺᄎ" + sub "ᆾ" "ᆺ" + + # HANGUL JONGSEONG KHIEUKH + sub "ᆿᄋ" "ᆨᄏ" + sub "ᆿ" "ᆨ" + + # HANGUL JONGSEONG THIEUTH + sub "ᇀᄋ" "ᆺᄐ" + sub "ᇀ" "ᆺ" + + # HANGUL JONGSEONG PHIEUPH + sub "ᇁᄋ" "ᆸᄑ" + sub "ᇁ" "ᆸ" + + # HANGUL JONGSEONG HIEUH + sub "ᇂᄀ" "ᄏ" + sub "ᇂᄃ" "ᄐ" + sub "ᇂᄇ" "ᄑ" + sub "ᇂᄌ" "ᄎ" + sub "ᇂ" "" + } + + parallel { + # From Unicode Chart + # https://github.com/unicode-org/cldr/blob/master/common/transforms/Korean-Latin-BGN.xml + + sub "ᆮᄋ" "d" + + sub "ᆨᄀ" "kg" + sub "ᆨᄂ" "ngn" + sub "ᆨᄃ" "kd" + sub "ᆨᄅ" "ngn" + sub "ᆨᄆ" "ngm" + sub "ᆨᄇ" "kb" + sub "ᆨᄉ" "ks" + sub "ᆨᄋ" "g" + sub "ᆨᄌ" "kj" + sub "ᆨᄎ" "kch" + sub "ᆨᄏ" "kk" + sub "ᆨᄐ" "kt" + sub "ᆨᄑ" "kp" + sub "ᆨᄒ" "kh" + sub "ᆨᄁ" "kkk" + sub "ᆨᄄ" "ktt" + sub "ᆨᄈ" "kpp" + sub "ᆨᄊ" "kss" + sub "ᆨᄍ" "kjj" + sub "ᆫᄀ" "ng" + sub "ᆫᄂ" "nn" + sub "ᆫᄃ" "nd" + sub "ᆫᄅ" "ll" + sub "ᆫᄆ" "nm" + sub "ᆫᄇ" "nb" + sub "ᆫᄉ" "ns" + sub "ᆫᄋ" "n" + sub "ᆫᄌ" "nj" + sub "ᆫᄎ" "nch" + sub "ᆫᄏ" "nk" + sub "ᆫᄐ" "nt" + sub "ᆫᄑ" "np" + sub "ᆫᄒ" "nh" + sub "ᆫᄁ" "nkk" + sub "ᆫᄄ" "ntt" + sub "ᆫᄈ" "npp" + sub "ᆫᄊ" "nss" + sub "ᆫᄍ" "njj" + sub "ᆯᄀ" "lg" + sub "ᆯᄂ" "ll" + sub "ᆯᄃ" "ld" + sub "ᆯᄅ" "ll" + sub "ᆯᄆ" "lm" + sub "ᆯᄇ" "lb" + sub "ᆯᄉ" "ls" + sub "ᆯᄋ" "r" + sub "ᆯᄌ" "lj" + sub "ᆯᄎ" "lch" + sub "ᆯᄏ" "lk" + sub "ᆯᄐ" "lt" + sub "ᆯᄑ" "lp" + sub "ᆯᄒ" "rh" + sub "ᆯᄁ" "lkk" + sub "ᆯᄄ" "ltt" + sub "ᆯᄈ" "lpp" + sub "ᆯᄊ" "lss" + sub "ᆯᄍ" "ljj" + sub "ᆷᄀ" "mg" + sub "ᆷᄂ" "mn" + sub "ᆷᄃ" "md" + sub "ᆷᄅ" "mn" + sub "ᆷᄆ" "mm" + sub "ᆷᄇ" "mb" + sub "ᆷᄉ" "ms" + sub "ᆷᄋ" "m" + sub "ᆷᄌ" "mj" + sub "ᆷᄎ" "mch" + sub "ᆷᄏ" "mk" + sub "ᆷᄐ" "mt" + sub "ᆷᄑ" "mp" + sub "ᆷᄒ" "mh" + sub "ᆷᄁ" "mkk" + sub "ᆷᄄ" "mtt" + sub "ᆷᄈ" "mpp" + sub "ᆷᄊ" "mss" + sub "ᆷᄍ" "mjj" + sub "ᆸᄀ" "pg" + sub "ᆸᄂ" "mn" + sub "ᆸᄃ" "pd" + sub "ᆸᄅ" "mn" + sub "ᆸᄆ" "mm" + sub "ᆸᄇ" "pb" + sub "ᆸᄉ" "ps" + sub "ᆸᄋ" "b" + sub "ᆸᄌ" "pj" + sub "ᆸᄎ" "pch" + sub "ᆸᄏ" "pk" + sub "ᆸᄐ" "pt" + sub "ᆸᄑ" "pp" + sub "ᆸᄒ" "ph" + sub "ᆸᄁ" "pkk" + sub "ᆸᄄ" "ptt" + sub "ᆸᄈ" "ppp" + sub "ᆸᄊ" "pss" + sub "ᆸᄍ" "pjj" + sub "ᆺᄀ" "tg" + sub "ᆺᄂ" "nn" + sub "ᆺᄃ" "td" + sub "ᆺᄅ" "nn" + sub "ᆺᄆ" "nm" + sub "ᆺᄇ" "tb" + sub "ᆺᄉ" "ts" + sub "ᆺᄋ" "s" + sub "ᆺᄌ" "tj" + sub "ᆺᄎ" "tch" + sub "ᆺᄏ" "tk" + sub "ᆺᄐ" "tt" + sub "ᆺᄑ" "tp" + sub "ᆺᄒ" "th" + sub "ᆺᄁ" "tkk" + sub "ᆺᄄ" "ttt" + sub "ᆺᄈ" "tpp" + sub "ᆺᄊ" "tss" + sub "ᆺᄍ" "tjj" + sub "ᆼᄀ" "ngg" + sub "ᆼᄂ" "ngn" + sub "ᆼᄃ" "ngd" + sub "ᆼᄅ" "ngn" + sub "ᆼᄆ" "ngm" + sub "ᆼᄇ" "ngb" + sub "ᆼᄉ" "ngs" + sub "ᆼᄋ" "ng" + sub "ᆼᄌ" "ngj" + sub "ᆼᄎ" "ngch" + sub "ᆼᄏ" "ngk" + sub "ᆼᄐ" "ngt" + sub "ᆼᄑ" "ngp" + sub "ᆼᄒ" "ngh" + sub "ᆼᄁ" "ngkk" + sub "ᆼᄄ" "ngtt" + sub "ᆼᄈ" "ngpp" + sub "ᆼᄊ" "ngss" + sub "ᆼᄍ" "ngjj" + } + + sub { + from "ᄀ" + to "g" + before any([alpha, digit, jamo_vowel, "-"]) + } + sub { + from "ᄂ" + to "n" + before any([alpha, digit, jamo_vowel, "-"]) + } + sub { + from "ᄃ" + to "d" + before any([alpha, digit, jamo_vowel, "-"]) + } + sub { + from "ᄅ" + to "r" + before any([alpha, digit, jamo_vowel, "-"]) + } + sub { + from "ᄆ" + to "m" + before any([alpha, digit, jamo_vowel, "-"]) + } + sub { + from "ᄇ" + to "b" + before any([alpha, digit, jamo_vowel, "-"]) + } + sub { + from "ᄉ" + to "s" + before any([alpha, digit, jamo_vowel, "-"]) + } + sub { + from "ᄋ" + to "" + before any([alpha, digit, jamo_vowel, "-"]) + } + sub { + from "ᄌ" + to "j" + before any([alpha, digit, jamo_vowel, "-"]) + } + sub { + from "ᄎ" + to "ch" + before any([alpha, digit, jamo_vowel, "-"]) + } + sub { + from "ᄏ" + to "k" + before any([alpha, digit, jamo_vowel, "-"]) + } + sub { + from "ᄐ" + to "t" + before any([alpha, digit, jamo_vowel, "-"]) + } + sub { + from "ᄑ" + to "p" + before any([alpha, digit, jamo_vowel, "-"]) + } + sub { + from "ᄒ" + to "h" + before any([alpha, digit, jamo_vowel, "-"]) + } + sub { + from "ᄁ" + to "kk" + before any([alpha, digit, jamo_vowel]) + } + sub { + from "ᄄ" + to "tt" + before any([alpha, digit, jamo_vowel]) + } + sub { + from "ᄈ" + to "pp" + before any([alpha, digit, jamo_vowel]) + } + sub { + from "ᄊ" + to "ss" + before any([alpha, digit, jamo_vowel]) + } + sub { + from "ᄍ" + to "jj" + before any([alpha, digit, jamo_vowel]) + } + parallel { + sub "ᆰᄀ" "lg" + sub "ᆰᄂ" "ngn" + sub "ᆰᄃ" "kd" + sub "ᆰᄅ" "ngn" + sub "ᆰᄆ" "ngm" + sub "ᆰᄇ" "kb" + sub "ᆰᄉ" "ks" + sub "ᆰᄋ" "lg" + sub "ᆰᄌ" "kj" + sub "ᆰᄎ" "kch" + sub "ᆰᄏ" "lk" + sub "ᆰᄐ" "kt" + sub "ᆰᄑ" "kp" + sub "ᆰᄒ" "lk" + sub "ᆰᄁ" "lkk" + sub "ᆰᄄ" "ktt" + sub "ᆰᄈ" "kpp" + sub "ᆰᄊ" "kss" + sub "ᆰᄍ" "kjj" + sub "ᆱᄀ" "mg" + sub "ᆱᄂ" "mn" + sub "ᆱᄃ" "md" + sub "ᆱᄅ" "mn" + sub "ᆱᄆ" "lm" + sub "ᆱᄇ" "mb" + sub "ᆱᄉ" "ms" + sub "ᆱᄋ" "lm" + sub "ᆱᄌ" "mj" + sub "ᆱᄎ" "mch" + sub "ᆱᄏ" "mk" + sub "ᆱᄐ" "mt" + sub "ᆱᄑ" "mp" + sub "ᆱᄒ" "mh" + sub "ᆱᄁ" "mkk" + sub "ᆱᄄ" "mtt" + sub "ᆱᄈ" "mpp" + sub "ᆱᄊ" "mss" + sub "ᆱᄍ" "mjj" + sub "ᆲᄀ" "pg" + sub "ᆲᄂ" "mn" + sub "ᆲᄃ" "pd" + sub "ᆲᄅ" "mn" + sub "ᆲᄆ" "mm" + sub "ᆲᄇ" "lb" + sub "ᆲᄉ" "ps" + sub "ᆲᄋ" "lb" + sub "ᆲᄌ" "pj" + sub "ᆲᄎ" "pch" + sub "ᆲᄏ" "pk" + sub "ᆲᄐ" "pt" + sub "ᆲᄑ" "lp" + sub "ᆲᄒ" "lp" + sub "ᆲᄁ" "pkk" + sub "ᆲᄄ" "ptt" + sub "ᆲᄈ" "lpp" + sub "ᆲᄊ" "pss" + sub "ᆲᄍ" "pjj" + } + sub { + from "ᄀ" + to "g" + before space + } + sub { + from "ᄂ" + to "n" + before space + } + sub { + from "ᄃ" + to "d" + before space + } + sub { + from "ᄅ" + to "" + before space + after any("ᅣᅤᅧᅨᅭᅲ") + } + sub { + from "ᄅ" + to "n" + before space + } + sub { + from "ᄆ" + to "m" + before space + } + sub { + from "ᄇ" + to "b" + before space + } + sub { + from "ᄉ" + to "s" + before space + } + sub { + from "ᄋ" + to "" + before space + } + sub { + from "ᄌ" + to "j" + before space + } + sub { + from "ᄎ" + to "ch" + before space + } + sub { + from "ᄏ" + to "k" + before space + } + sub { + from "ᄐ" + to "t" + before space + } + sub { + from "ᄑ" + to "p" + before space + } + sub { + from "ᄒ" + to "h" + before space + } + sub { + from "ᄁ" + to "kk" + before space + } + sub { + from "ᄭ" + to "kk" + before space + } + sub { + from "ᄄ" + to "tt" + before space + } + sub { + from "ᄯ" + to "tt" + before space + } + sub { + from "ᄈ" + to "pp" + before space + } + sub { + from "ᄲ" + to "pp" + before space + } + sub { + from "ᄊ" + to "ss" + before space + } + sub { + from "ᄍ" + to "jj" + before space + } + sub { + from "ᄶ" + to "jj" + before space + from "ᆮ" + parallel { + sub "ᅡ" "a" + sub "ᅣ" "ya" + sub "ᅥ" "eo" + sub "ᅧ" "yeo" + sub "ᅩ" "o" + sub "ᅭ" "yo" + sub "ᅮ" "u" + sub "ᅲ" "yu" + sub "ᅳ" "eu" + sub "ᅵ" "i" + sub "ᅢ" "ae" + sub "ᅤ" "yae" + sub "ᅦ" "e" + sub "ᅨ" "ye" + sub "ᅬ" "oe" + sub "ᅱ" "wi" + sub "ᅴ" "ui" + sub "ᅪ" "wa" + sub "ᅯ" "wo" + sub "ᅫ" "wae" + sub "ᅰ" "we" + } + sub { + from "ᆨ" + to "k" + after any([space,"-"]) + } + sub { + from "ᆫ" + to "n" + after any([space,"-"]) + } + sub { + } + to "t" + after any([space,"-"]) + } + sub { + from "ᆯ" + to "l" + after any([space,"-"]) + } + sub { + from "ᆷ" + to "m" + after any([space,"-"]) + } + sub { + from "ᆸ" + to "p" + after any([space,"-"]) + } + sub { + from "ᆺ" + to "t" + after any([space,"-"]) + } + sub { + from "ᆼ" + to "ng" + after any([space,"-"]) + } + sub { + from "ᆽ" + to "t" + after any([space,"-"]) + } + sub { + from "ᆾ" + to "t" + after any([space,"-"]) + } + sub { + from "ᆿ" + to "k" + after any([space,"-"]) + } + sub { + from "ᇀ" + to "t" + after any([space,"-"]) + } + sub { + from "ᇁ" + to "p" + after any([space,"-"]) + } + sub { + from "ᆰ" + to "k" + after any([space,"-"]) + } + sub { + from "ᆲ" + to "p" + after any([space,"-"]) + } + + # Remove space added + sub { + from line_start + space + to none + } + sub { + from space + line_end + to none + } + + title_case +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0075/map.isc b/scripts/fuzz/smoke-cases/mutation-0075/map.isc new file mode 100644 index 0000000..5c3bef7 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0075/map.isc @@ -0,0 +1,37 @@ +system "ELOT:ell-Grek:Latn:743-2001-tl" { + +metadata { + authority_id elot + id 743-2001-tl + language iso-639-2:ell + source_script Grek + name ELOT 743:2001 Information and documentation -- Conversion of Greek characters into Latin characters (transliteration system) + url https://docplayer.gr/docview/18/849832/ + #file=/storage/18/849832/849832.pdf + creation_date 2001 + description { Reversible transliteration standard, ELOT + } + + notes { + note "Transliteration standard (reversible): Clause 3.1, Table 1" + } +} + +# This map has been partially converted by the bin/maps_v1_to_v2 script +# The section below requires human attention. Remember to remove this +# comment and move the converted map to 'maps/' directory. Please also +# take note that the maps-staging directory will be cleaned up whenever +# you run the bin/maps_v1_to_v2 script. You should particularly be +# concerned about any regular expressions found in this file and about +# advanced expressions in parallel {} parts, and also about the order +# of particular parts of the stage. + +dependency "iso-ell-Grek-Latn-843-1997-t1" as greklatn + +stage main { + + run map.greklatn.stage.main + +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0076/map.isc b/scripts/fuzz/smoke-cases/mutation-0076/map.isc new file mode 100644 index 0000000..6e08853 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0076/map.isc @@ -0,0 +1,418 @@ +system "VAR:jpn-Hrkt:Latn:hepburn-1954" { + +metadata { + authority_id var + id hepburn-1954 + language iso-639-2:jpn + source_script Hrkt + destination_script Latn + name Modified Hepburn System + url + creation_date 1954 + adoption_date + description { This is a modified version of Hepburn romanization, which was adopted by Kenkyusha's New Japanese-English Dictionary (3rd edition) One crucial difference between Modified and Tranditional Hepburn is that the ん/ン sound is always transliterated as n, even before the letters b,m,p. } + + notes { + } +} + +tests { + # - source: かんおう + # expected: kan'ō + # - source: かのう + # expected: kanō + # - source: きんゆう + # expected: kin'yū + # - source: とうきょう + # expected: tōkyō + # - source: がっこう + # expected: gakkō + "かごっま" -> "kagomma" + # expected: poppoyya + # - source: てっら + # expected: terra + # - source: にゃっほー + # expected: nyahhō +} + +stage main { + + # RULES + sub { + from capture(any("んン")) + to ref( 1 ) + "’" + after any("あいうえおやゆよアイウエオヤユヨ") + } + + + # CHARACTERS + parallel { + + # Hiragana + + sub "あ" "a" + sub "い" "i" + sub "う" "u" + sub "え" "e" + sub "お" "o" + sub "おう" "ō" + + sub "か" "ka" + sub "き" "ki" + sub "く" "ku" + sub "け" "ke" + sub "こ" "ko" + sub "きゃ" "kya" + sub "きゅ" "kyu" + sub "きょ" "kyo" + sub "きょう" "kyō" + sub "こう" "kō" + + sub "さ" "sa" + sub "し" "shi" + sub "す" "su" + sub "せ" "se" + sub "そ" "so" + sub "しゃ" "sha" + sub "しゅ" "shu" + sub "しょ" "sho" + sub "しょう" "shō" + sub "そう" "sō" + + sub "た" "ta" + sub "ち" "chi" + sub "つ" "tsu" + sub "て" "te" + sub "と" "to" + sub "ちゃ" "cha" + sub "ちゅ" "chu" + sub "ちょ" "cho" + sub "とう" "tō" + sub "ちょう" "chō" + + sub "な" "na" + sub "に" "ni" + sub "ぬ" "nu" + sub "ね" "ne" + sub "の" "no" + sub "にゃ" "nya" + sub "にゅ" "nyu" + sub "にょ" "nyo" + sub "にょう" "nyō" + sub "のう" "nō" + + sub "は" "ha" + sub "ひ" "hi" + sub "ふ" "fu" + sub "へ" "he" + sub "ほ" "ho" + sub "ひゃ" "hya" + sub "ひゅ" "hyu" + sub "ひょ" "hyo" + sub "ひょう" "hyō" + sub "ほう" "hō" + + sub "ま" "ma" + sub "み" "mi" + sub "む" "mu" + sub "め" "me" + sub "も" "mo" + sub "みゃ" "mya" + sub "みゅ" "myu" + sub "みょ" "myo" + sub "みょう" "myō" + sub "もう" "mō" + + sub "や" "ya" + sub "ゆ" "yu" + sub "よ" "yo" + sub "よう" "yō" + + sub "ら" "ra" + sub "り" "ri" + sub "る" "ru" + sub "れ" "re" + sub "ろ" "ro" + sub "りゃ" "rya" + sub "りゅ" "ryu" + sub "りょ" "ryo" + sub "りょう" "ryō" + sub "ろう" "rō" + + sub "わ" "wa" + sub "を" "o" + + sub "が" "ga" + sub "ぎ" "gi" + sub "ぐ" "gu" + sub "げ" "ge" + sub "ご" "go" + sub "ぎゃ" "gya" + sub "ぎゅ" "gyu" + sub "ぎょ" "gyo" + sub "ぎょう" "gyō" + sub "ごう" "gō" + + sub "ざ" "za" + sub "じ" "ji" + sub "ず" "zu" + sub "ぜ" "ze" + sub "ぞ" "zo" + sub "じゃ" "ja" + sub "じゅ" "ju" + sub "じょ" "jo" + sub "じょう" "jō" + sub "ぞう" "zō" + + sub "だ" "da" + sub "ぢ" "ji" + sub "づ" "zu" + sub "で" "de" + sub "ど" "do" + sub "ぢゃ" "ja" + sub "ぢゅ" "ju" + sub "ぢょ" "jo" + sub "どう" "dō" + + sub "ば" "ba" + sub "び" "bi" + sub "ぶ" "bu" + sub "べ" "be" + sub "ぼ" "bo" + sub "びゃ" "bya" + sub "びゅ" "byu" + sub "びょ" "byo" + sub "びょう" "byō" + sub "ぼう" "bō" + + sub "ぱ" "pa" + sub "ぴ" "pi" + sub "ぷ" "pu" + sub "ぺ" "pe" + sub "ぽ" "po" + sub "ぴゃ" "pya" + sub "ぴゅ" "pyu" + sub "ぴょ" "pyo" + sub "k" "K" when kur + sub "ぴょう" "pyō" + sub "ぽう" "pō" + + sub "ん" "n" + + sub "ေၶႃ်" "khò" + sub "ေၷႃ်" "gò" + sub "ေဃႃ်" "ghò" + sub "ေငႃ်" "ṅò" + sub "ေၸႃ်" "cò" + sub "ေဆႃ်" "chò" + sub "ေၹႃ်" "zò" + sub "ေဇႃ်" "jhò" + sub "ေၺႃ်" "ñò" + # Katakana + + sub "ア" "a" + sub "イ" "i" + sub "ウ" "u" + sub "エ" "e" + sub "オ" "o" + sub "オウ" "ō" + + sub "カ" "ka" + sub "キ" "ki" + sub "ク" "ku" + sub "ケ" "ke" + sub "コ" "ko" + sub "キャ" "kya" + sub "キュ" "kyu" + sub "キョ" "kyo" + sub "キョウ" "kyō" + sub "コウ" "kō" + + sub "サ" "sa" + sub "シ" "shi" + sub "ス" "su" + sub "セ" "se" + sub "ソ" "so" + sub "シャ" "sha" + sub "シュ" "shu" + sub "ショ" "sho" + sub "ショウ" "shō" + sub "ソウ" "sō" + + sub "タ" "ta" + sub "チ" "chi" + sub "ツ" "tsu" + sub "テ" "te" + sub "ト" "to" + sub "チャ" "cha" + sub "チュ" "chu" + sub "チョ" "cho" + sub "チョウ" "chō" + sub "トウ" "tō" + + sub "ナ" "na" + sub "ニ" "ni" + sub "ヌ" "nu" + sub "ネ" "ne" + sub "ノ" "no" + sub "ニャ" "nya" + sub "ニュ" "nyu" + sub "ニョ" "nyo" + sub "ニョウ" "nyō" + sub "ノウ" "nō" + + sub "ハ" "ha" + sub "ヒ" "hi" + sub "フ" "fu" + sub "ヘ" "he" + sub "ホ" "ho" + sub "ヒャ" "hya" + sub "ヒュ" "hyu" + sub "ヒョ" "hyo" + sub "ヒョウ" "hyō" + sub "ホウ" "hō" + + sub "マ" "ma" + sub "ミ" "mi" + sub "ム" "mu" + sub "メ" "me" + sub "モ" "mo" + sub "ミャ" "mya" + sub "ミュ" "myu" + sub "ミョ" "myo" + sub "ミョウ" "myō" + sub "モウ" "mō" + + sub "ヤ" "ya" + sub "ユ" "yu" + sub "ヨ" "yo" + sub "ヨウ" "yō" + + sub "ラ" "ra" + sub "リ" "ri" + sub "ル" "ru" + sub "レ" "re" + sub "ロ" "ro" + sub "リャ" "rya" + sub "リュ" "ryu" + sub "リョ" "ryo" + sub "リョウ" "ryō" + sub "ロウ" "rō" + + sub "ワ" "wa" + sub "ヲ" "o" + + sub "ガ" "ga" + sub "ギ" "gi" + sub "グ" "gu" + sub "ゲ" "ge" + sub "ゴ" "go" + sub "ギャ" "gya" + sub "ギュ" "gyu" + sub "ギョ" "gyo" + sub "ギョウ" "gyō" + sub "ゴウ" "gō" + + sub "ザ" "za" + sub "ジ" "ji" + sub "ズ" "zu" + sub "ゼ" "ze" + sub "ゾ" "zo" + sub "ジャ" "ja" + sub "ジュ" "ju" + sub "ジョ" "jo" + sub "ジョウ" "jō" + sub "ゾウ" "zō" + + sub "ダ" "da" + sub "ヂ" "ji" + sub "ヅ" "zu" + sub "デ" "de" + sub "ド" "do" + sub "ヂャ" "ja" + sub "ヂュ" "ju" + sub "ヂョ" "jo" + sub "ドウ" "dō" + + sub "バ" "ba" + sub "ビ" "bi" + sub "ブ" "bu" + sub "ベ" "be" + sub "ボ" "bo" + sub "ビャ" "bya" + sub "ビュ" "byu" + sub "ビョ" "byo" + sub "ビョウ" "byō" + sub "ボウ" "bō" + + sub "パ" "pa" + sub "ピ" "pi" + sub "プ" "pu" + sub "ペ" "pe" + sub "ポ" "po" + sub "ピャ" "pya" + sub "ピュ" "pyu" + sub "ピョ" "pyo" + sub "ピョウ" "pyō" + sub "ポウ" "pō" + + sub "ン" "n" + } + + # POSTRULES + # Handling of っ/ッ + # + # The kana っ/ッ is a geminate marker. + # When followed by a consonant, repeat the first letter of + # the following syllable. Exception: the combination -cch- + # should be transliterated as -tch- + # + # If っ/ッ is not followed by a consonant, then it is usually + # phonetically realised as an abrupt stop or shorterning of + # the previous syllable. There is no documented or commonly + # accepted way to transliterate this sound. + + sub { + from any("っッ") + capture(any("BbDdFfGgHhJjKkLlMmNnPpQqRrSsTtVvWwXxYyZz")) + to ref( 1 ) + ref( 1 ) + } + sub { + from any("っッ") + capture(any("Cc")) + to "t" + ref( 1 ) + } + sub { + from any("っッ") + to "" + } + + # In Modified Hepburn, long vowels within the same morpheme are + # transliterated using a macron, i.e. ā, ī, ū, ē, ō. + # + # If two repeating letters are split across a morpheme boundary + # then they should not be changed into macron. + # + # Long vowels in loanwords are indicated with a macron instead + # of letter doubling. + + sub { + from "a" + any("ーa") + to "ā" + } + sub { + from "i" + any("ーi") + to "ī" + } + sub { + from "u" + any("ーu") + to "ū" + } + sub { + from "e" + any("ーe") + to "ē" + } + sub { + from "o" + any("ーo") + to "ō" + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0077/map.isc b/scripts/fuzz/smoke-cases/mutation-0077/map.isc new file mode 100644 index 0000000..92cf845 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0077/map.isc @@ -0,0 +1,54 @@ +system "ALA-LC:mal-Mlym:Latn:2012" { + +metadata { + authority_id alalc + id 2012 + language iso-639-2:mal + source_script Mlym + destination_script Latn + name Romanization Table -- Malayalam (2012) + url https://www.loc.gov/catdir/cpso/romanization/malayalam.pdf + creation_date 2012 + description { ALA-LC Romanization table for Malayalam + } + + notes { + + note "Only the vowel forms that appear at the beginning of a syllable are listed; the forms used for\n vowels following a consonant can be found in grammars; no distinction between the two is\n made in transliteration." + + note "When ് is used in combination with the vowel u (ഉ്), the combination is also transliterated ȧ." + + note " The vowel a is implicit after all consonants and consonant clusters and is supplied in transliteration, with the following exceptions:\n a) when another vowel is indicated by its appropriate sign\n b) when the absence of any vowel is indicated by the superscript sign ് (also used for the vowel ȧ); and\n c) when the following modified consonantal forms are used:\n ൿ k\n ൻ n\n ൾ ḷ\n ൺ ṇ\n ൽ l\n ർ r" + note "When റ റ appears as a subscript in a cluster (റ്റ), it is transliterated ta." + + note " Exception: Anusvāra is transliterated by:\n\n a) ṅ before gutturals,\n b) ñ before palatals,\n c) ṇ before cerebrals,\n d) n before dentals, and\n e) m before labials." + } + ruleset dup0 { + parallel { sub "p" "Q" } + } + ruleset dup2 { + parallel { sub "r" "S" } + } +} + +tests { + "ബാർ കോഴ ആവിയായി; മകൻ മാണിയെ വ്യക്തിഹത്യ നടത്തിയവരുടെ കൂടാരത്തിൽ" -> "bār kōḻa āviyāyi; makan māṇiye vŭyakŭtihatŭya naṭatŭtiyavaruṭe kūṭāratŭtil" + "മിഷൻ ശക്തി, ഓപറേഷൻ ശക്തി'; മുഖം മിനുക്കാൻ സ്ത്രീസുരക്ഷാ പദ്ധതികളുമായി" -> "miṣan śakŭti, ōpaṟēṣan śakŭti'; mukhaṃ minukŭkān sŭtŭrīsurakŭṣā padŭdhatikaḷumāyi" + "സംസ്ഥാനത്ത് ബുധനാഴ്ച 6,244 പേര്‍ക്ക് കോവിഡ്; ൫൭൪൫ പേര്‍ക്ക് രോഗം സമ" -> "saṃsŭthānatŭtŭ budhanāḻŭca 6,244 pērŭkŭkŭ kōvid̂ŭ; 5745 pērŭkŭkŭ rēāgaṃ sama" + "ശബരിമല തീര്‍ഥാടനം: സ്‌പെഷല്‍ കമ്മീഷ്ണറുടെ റിപ്പോര്‍ട്ട് ഹൈകോടതിയില്‍" -> "śabarimala tīrŭthāṭanaṃ: sŭpeṣalŭ kamŭmīṣŭṇaṟuṭe ṟipŭpōrŭṭŭṭŭ haikōṭatiyilŭ" + "സജ്‌ന ഷാജിക്ക് ഐക്യദാര്‍ഢ്യവുമായി സന്തോഷ് കീഴാറ്റൂര്‍ ബിരിയാണി വില്‍ക്കും" -> "sajŭna ṣājikŭkŭ aikŭyadārŭḍhŭyavumāyi sanŭtōṣŭ kīḻāṟŭṟūrŭ biriyāṇi vilŭkŭkuṃ" + "ആനപ്പുറത്തിരുന്ന് യോഗാഭ്യാസത്തിനിടെ ബാബ രാംദേവ് നിലത്തുവീണു" -> "ānapŭpuṟatŭtirunŭnŭ yēāgābhŭyāsatŭtiniṭe bāba rāṃdēvŭ nilatŭtuvīṇu" + "മാണി ഉണ്ടായിരുന്നെങ്കിൽ ഇത്തരമൊരു തീരുമാനം എടുക്കില്ല, ഈ രാഷ്ട്രീയ വഞ്ചന അദ്ദേഹത്തിന്‍റെ ആത്മാവ് പൊറുക്കില്ല" -> "māṇi uṇŭṭāyirunŭneṅŭkil itŭtaramoru tīrumānaṃ eṭukŭkilŭla, ī rāṣŭṭŭrīya vañŭcana adŭdēhatŭtinŭṟe ātŭmāvŭ poṟukŭkilŭla" + "ധാർമികത വിളമ്പണ്ട, എം.പി, എം.എൽ.എ സ്ഥാനങ്ങൾ രാജിവെക്കൂ എന്ന് ജോസ് കെ. മാണിയോട് ഷാഫി" -> "dhārmikata viḷamŭpaṇŭṭa, eṃ.pi, eṃ.el.e sŭthānaṅŭṅaḷ rājivekŭkū enŭnŭ jōsŭ ke. māṇiyōṭŭ ṣāphi" + "ഞങ്ങൾ ബോക്സിൽ നിന്നും ഒന്നും ഒഴിവാക്കില്ല; ആപ്പിളിനെ ട്രോളി ഷവോമി" -> "ñaṅŭṅaḷ bēākŭsil ninŭnuṃ onŭnuṃ oḻivākŭkilŭla; āpŭpiḷine ṭŭrēāḷi ṣavēāmi" +} + +dependency "alalc-mal-Mlym-Latn-1997" as mlymlatn + +stage main { + + run map.mlymlatn.stage.main + +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0078/map.isc b/scripts/fuzz/smoke-cases/mutation-0078/map.isc new file mode 100644 index 0000000..a76511e --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0078/map.isc @@ -0,0 +1,86 @@ +system "DIN:kum-Cyrl:Latn:1460-2-2011" { + +metadata { + authority_id din + id 1460-2-2011-31 + language iso-639-3:kum + source_script Cyrl + destination_script Latn + name "DIN 1460-2:2011-10, Tabelle 1 row 31: Kumükisch (Turkic)" + url https://www.beuth.de/de/norm/din-1460-2/134564104 + creation_date 2011 + adoption_date + description { + DIN 1460-2:2011-10, Romanization of Cyrillic alphabets of + non-Slavic languages, Tabelle 1, language row 31 + (Kumükisch). The table assigns each Cyrillic letter of the + language's alphabet a Latin letter or letter group; the column + order follows DIN 1460:1982 (Slavic). Extracted mechanically from + the standard's text layer; the mapping rows below are the table's + own cells. + } + + notes { + note "Extraction provenance: the PDF's text layer carries the full + grid; columns were anchored on the per-page position-number row and + each cell matched by x-coordinate to its Cyrillic header letter. + Position 13's header glyph is PUA (U+E519) in the text layer and + was visually identified at 10x as h with comma below (U+0068 + U+0322), the plain-h counterpart of position 12's hooktop-h symbol." + } +} + +tests { + "a" -> "a" + "б" -> "b" +stage main { + + run map.georlatn.stage.main + +} + +} + "в" -> "v" + "г" -> "g" +} + +stage main { + parallel { + sub "a" "a" + + sub "в" "v" + sub "г" "g" + sub "д" "d" + sub "е" "e" + sub "ё" "ё" + sub "ж" "ž" + sub "з" "z" + sub "и" "i" + sub "й" "j" + sub "к" "k" + sub "ҡ" "13" + sub "л" "l" + sub "м" "m" + sub "н" "n" + sub "о" "o" + sub "ӫ" "15" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "т" "t" + sub "у" "u" + sub "у̅" "17" + sub "ф" "f" + sub "х" "h" + sub "ц" "c" + sub "ч" "č" + sub "ш" "š" + sub "щ" "šč" + sub "ъ" "\"" + sub "ы" "y" + sub "ь" "'" + sub "э" "ė" + sub "э̇" "21" + } +} +} + sub "б" "b" \ No newline at end of file diff --git a/scripts/fuzz/smoke-cases/mutation-0080/map.isc b/scripts/fuzz/smoke-cases/mutation-0080/map.isc new file mode 100644 index 0000000..08951d2 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0080/map.isc @@ -0,0 +1,31 @@ +system "VAR:ara-Arab:Arab:rababa" { + +metadata { + authority_id var + id rababa + language iso-639-2:ara + source_script Arab + destination_script Arab + name RABABA the Arabic Diacritization Library + url https://github.com/interscript/rababa/ + description { Arabic diacritization is useful for several practical business cases + like text to speech or Romanization of Arabic texts or scripts. + + This map in particular uses the RABABA library to automatically detect + and add diacritics using machine learning. + } +} + +tests { + 'قطر' -> 'قِطْرَ' + 'abc' -> 'abc' + '‘Iz. Ibrāhīm as-Sa‘danī' -> '‘Iz. Ibrāhīm as-Sa‘danī' +} + sub "a" "\x" + +stage main { + sub "\u{110000}" "X" + sub kk "\u{1F600}" after "\u{1F600}" + rababa config: "200" +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0081/map.isc b/scripts/fuzz/smoke-cases/mutation-0081/map.isc new file mode 100644 index 0000000..6840edd --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0081/map.isc @@ -0,0 +1,38 @@ +system "BGN:kor-Hang:Latn:1943" { + +metadata { + authority_id bgn + id 1943 + id 1943 + language iso-639-2:kor + source_script Hang + destination_script Latn + name Korean McCune-Reischauer (Hangul to Latin) (1943 Agreement) + url + creation_date 1943 + adoption_date + description + + notes { + } +} + +tests { + "서울" -> "Sŏul" + "평양" -> "P’yŏngyang" + use nonexistent-dep:rs0 + "부산" -> "Pusan" + title_case + "대구" -> "Taegu" + "경상남도" -> "Kyŏngsangnamdo" +} + +dependency "var-kor-Hang-Latn-mr-1939" as hanglatn + +stage main { + + run map.hanglatn.stage.main + compose + title_case +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0083/map.isc b/scripts/fuzz/smoke-cases/mutation-0083/map.isc new file mode 100644 index 0000000..0492970 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0083/map.isc @@ -0,0 +1,335 @@ +system "FZ8141" { + +metadata { + authority_id bgnpcgn + id 1958 + language iso-639-2:per + # prs stands for Dari (https://iso639-3.sil.org/code/prs&_ga=GA1.2.2054538372.1574092823) + source_script Arab + destination_script Latn + name Transliteration System for Persian (1958) + url https://github.com/interscript/interscript/files/5180821/BGN_Romanization_Guide_1964_persian_1958.pdf + creation_date 1958 + confirmation_date 1958 + description { The BGN/PCGN 1958 System for the Persian alphabet was + adopted by the BGN in 1946 and by the PCGN In 1958. It Is + used for the romanization of standard geographic names in + Iran. + The Persian alphabet is the same as the Arabic alphabet + except for the addition of four consonant symbols for + sounds which do not occur in Arabic. Therefore, the same + conversion values are used for the Persian alphabet as for + the Arabic alphabet wherever phonetically valid. Where + alias_decl = any("a") + swapcase2 = any("b") + letters common to the two alphabets have different + pronunciation in the two languages, conversion values + reflecting the Persian pronunciation are provided in the + Persian system. + It may be noted that neither the system of pointing nor the + conversion values for vowels and diphthongs are the same + for Persian as for Arabic. + Persian presents the same problems of vowel pointing as + Arabic in that the short vowel symbols necessary for the + proper rendering of short vowels, long vowels, and + diphthongs are almost always omitted from written Persian. + It follows that, in order to produce transliterations in + terms of standard written Persian, the transliterator must + be able to identify the words used in names and must know + their standard written Persian spelling, their proper vowel + pointing, and how to eliminate peculiarities due to + dialectical variation. + The notes and special rules explain details of + transliteration not stated in the tables. + } + + notes { + note " 1)The Persian writing system, in its generally used form,\n employs only the symbols found in Table I, and the alef maddeh\n (آ) of Table II. The symbols in column 1 of Table II are\n traditional auxiliary symbols used by Persians only\n sporadically to indicate the exact reading of a given word.\n In the case of i, ū, ey and ow, a choice of symbology\n exists, one system adhering to the Arabic tradition, the\n other being a modification of it. Likewise, there are two\n ways of writing alef maq§ureh. The BGN/PCGN transliteration\n system presupposes forms fully pointed with the Persian\n symbols represented in Table II, though these are omitted\n from the examples given below." + + note "2) Alef ( أ ) occurs with the following uses\n a. Initially, it indicates that the word begins with a vowel or\n diphthong, and the alef itself is not transliterated, e.g.,\n انجيرة Anjīreh, ايواني Eyvānī\n b. Initially with maddeh ( آ ),it indicates ā, e.g., آبادان Ābādān.\n c. Medially and finally. it represents ā, e.g., e.g., آبادان Ābādān,\n توكا Tūkā.\n d. With hamzeh. See Note 5." + + note "3) Where special considerations are paramount, the sub-dot\n may be used in place of the cedilla" + + note "4) The two-letter symbols kh, zh, sh, and gh are convenient\n for use and easily comprehensible. The infrequent sequences\n of kāf, ze, sīn, and gāf followed by he can be unequivocally\n transliterated for bibliographical purposes by the use of a\n slant line (“shilling,” “solidus\") to separate true h from\n a preceding k, z, s, or g; that is, kh represents khe, but\n k/h stands for kāf followed by he." + + note "5) Hamzeh (ء) is not regarded as a letter of the Persian\n alphabet, but as a diacritic mark, and as such is not\n always expressed in actual writing. In fully pointed words,\n however, it appears in several graphic forms, standing\n alone or written in conjunction with alef, vav, or ye (the\n ye in this instance being undotted). All these forms are\n transliterated simply with the apostrophe in the form\n resembling a small raised figure 9 (’) ,e.g., جزء Joz’\n صفراء şafrā’, مأخذ ma’khaz̄, مؤتمن mu’taman, پائين pā’īn Occasionally a word may\n appear pointed according to the strict Arabic tradition so\n as to indicate an initial hamzeh. This initial hamzeh is\n never transliterated, but only the vowel which it carries,\n e.g., •Jfi , whether pointed or 0 . is \"transliterated\n simply Anjireh. ' Hamzeh is also sometimes written over\n final he or ye to represent the -ye form of the eg&feh, cf.\n Note 8." + + note "6) Alef maddeh is used initially to indicate ā, e.g., آبادان Ābādān\n Noninitially it indicates ’ā in words of Arabic origin,\n and must be so transliterated, e.g., قرآن Qor’ān, مآب ma’āb" + + note "7) Tashdid ( ّ) indicates doubling of the consonant over which\n it is written and is represented in transliteration by writing\n the consonant twice, e.g محمّد Mohammad The sequence kasreh ye ye\n is transliterated īy.In names of Arabic origin containing the\n definite article, the vowel of the article is transliterated according\n to its Persian pronunciation and the lam, when followed by a “sun letter”\n (t, s̄, d, z̄, r, s, sh, ẕ, ţ, z̧, ţ, z̧, l, n) is assimilated. The article\n is written in lower case and separate from the preceding and following word,\n e.g., Zeyn od Din, but *£4 . Zeyn ed Dīn. Cf. Special Rule 1." + + note "8) The relational (ezafeh) suffix is transliterated -e after final consonants\n (except for silent h). After silent h and after vowels, it is transliterated\n -ye. It is usually not expressed in Persian writing after a consonant\n (kasreh being understood), e.g., كوهِ مَرغٌوب Kuh-e Marghūb. After final alef or vav\n it is written with ye (ي), e.g., بايِ آب Pa-ye Ab, جويِ آس Jū-ye Ās. After ye (ي)\n and silent he it is written as hamzeh over the letter, e.g., دَهَانهٴ مَمبَر Dahāneh-ye Mambar,\n سَلَيٴ بُذٌرگ Salasi-ye Bozorrg." + + + note "1. In Persian names of Arabic origin, the word division\n used for transliterating Arabic will obtain, except that\n names ending in the word Allah will be written solid and\n the a of Allah will be replaced by o, e.g., The Arabic\n definite article when not subject to assimilation will be\n written al in name-initial position but usually, ol\n elsewhere, e.g., Al JJal but 2u ol Faqar. Cf. Note 7 above." + + note "2. In Persian names in general, in sequences of name\n elements pronounced as a single unit, division into\n separate words will be made after Persian letters written\n in the word final form. (But see the Rule immediately\n below.)" + + note "3. The word abad which occurs very frequently at\n the end of place names will be written solid with the\n preceding word; e.g., Allahabad, not Allah Abad." + + note "4. Persian derivational endings such as vand and Turkish and other\n endings such as lar, li and lu will be written solid with\n the preceding word, whether so written in Persian script or\n not." + + note "5. The letter he, when used in Turkish fashion for\n word internal e, will be transliterated eh as usual but\n will be written solid with the remainder of the word." + + note "6. Kheplus vdv followed by long vowel or khe plus vdv followed\n by gammeh will be rendered khv although the v is not\n pronounced." + } +} + +tests { + "اَنجِيرة" -> "Anjīreh" + "اِيْوَانِي" -> "Eyvānī" + "آبادان" -> "Ābādān" + "تُوكا" -> "Tūkā" + "آبادان" -> "Ābādān" + "قُرآن" -> "Qor’ān" + "مَآب" -> "Ma’āb" + "مُحَمَّد" -> "Moḩammad" + "كُوهِ مَرغُوب" -> "Kūh-e Marghūb" + "پَايِ آب" -> "Pā-ye Āb" + "جُويِ آس" -> "Jū-ye Ās" + "دَهَانِهٴ مَمبَر" -> "Dahāneh-ye Mambar" + "سَلَسِيٴ بُذُرگ" -> "Salasī-ye Boz̄org" + "عَبداللَّه" -> "‘Abdollāh" + "ذُو الفَقَار" -> "Z̄ū ol Faqār" + "اللَّه آبَاد" -> "Allāhābād" + "اِيران" -> "Īrān" +} + +stage main { + + # CHARACTERS + parallel { + + sub { + from space + "\u0622\u0628\u064E\u0627\u062F" + to "ābād" + } + + sub { + from "\u064e" + to "" + after "\u0629" + } + sub { + from "\u064e" + to "" + after "a" + any("h|t") + } + + # pointing + sub "\u064e" "a" + sub "\u0650" "e" + sub "\u064f" "o" + sub "\u064e\u0627" "ā" + sub "\u0649\u0670" "á" + sub "\u0622" "’ā" + sub { + from boundary + "\u0622" + to "ā" + } + sub { + from "\u0650" + any("\u064a|\u06cc") + to "ī" + } + # '\u0650\u06cc' : 'ī' # ـِي kasra followed by ي + sub "\u064f\u0648" "ū" + sub { + from "\u064e" + any("\u064a|\u06cc") + "\u0652" + to "ey" + } + sub { + from "\u0650" + any("\u064a|\u06cc") + "\u0652" + to "ey" + } + sub "\u064e\u0648" "ow" + sub "\u0652" "" + sub "\u0650\u064a\u0651" "īy" + sub { + from any("\u0654|\u0674") + to "-e" + } + sub { + from any("\u0654|\u0674") + to "-ye" + before any("\u064a|\u0647") + } + sub { + from "\u0650" + boundary + to "-e" + } + sub { + from any("\u064a|\u06cc") + "\u0650" + boundary + to "-ye" + } + # shadda + + sub "\u0628\u0651" "bb" + sub "\u062a\u0651" "tt" + sub "\u062b\u0651" "s̄s̄" + sub "\u062c\u0651" "jj" + sub "\u062d\u0651" "ḩḩ" + sub "\u062e\u0651" "kh" + sub "\u062f\u0651" "dd" + sub "\u0630\u0651" "z̄z̄" + sub "\u0631\u0651" "rr" + sub "\u0632\u0651" "zz" + sub "\u0633\u0651" "ss" + sub "\u0634\u0651" "sh" + sub "\u0635\u0651" "şş" + sub "\u0636\u0651" "ẕẕ" + sub "\u0637\u0651" "ţţ" + sub "\u0638\u0651" "z̧z̧" + sub "\u063a\u0651" "gh" + sub "\u0641\u0651" "ff" + sub "\u0642\u0651" "qq" + sub "\u0643\u0651" "kk" + sub "\u0644\u0651" "ll" + sub "\u0645\u0651" "mm" + sub "\u0646\u0651" "nn" + sub "\u0647\u0651" "hh" + sub "\u0648\u0651" "vv" + sub "\u064a\u0651" "yy" + + sub "\u0659" "ê" + + # ta' marboota + sub "\u0629" "eh" + + sub { + from boundary + "\u0627\u0644" + to "al " + } + sub { + from space + boundary + "\u0627\u0644" + to " ol " + } + sub "\ufdf2" "Allāh" + sub "\u0627\u0644\u0644\u0651\u064e\u0647" "Allāh" + sub { + from "\u0627\u0644\u0644\u0651\u064e\u0647" + to "ollāh" + not_before boundary + } + # '\uFE8E' : '' # ﺎ + + # Sun letters + sub { + from boundary + "\u0627\u0644\u062a" + maybe("\u0651") + to "at t" + } + sub { + from boundary + "\u0627\u0644\u062b" + maybe("\u0651") + to "as̄ s̄" + } + sub { + from boundary + "\u0627\u0644\u062f" + maybe("\u0651") + to "ad d" + } + sub { + from boundary + "\u0627\u0644\u0630" + maybe("\u0651") + to "az̄ z̄" + } + sub { + from boundary + "\u0627\u0644\u0631" + maybe("\u0651") + to "ar r" + } + sub { + from boundary + "\u0627\u0644\u0632" + maybe("\u0651") + to "az z" + } + sub { + from boundary + "\u0627\u0644\u0633" + maybe("\u0651") + to "as s" + } + sub { + from boundary + "\u0627\u0644\u0634" + maybe("\u0651") + to "ash sh" + } + sub { + from boundary + "\u0627\u0644\u0635" + maybe("\u0651") + to "aş ş" + } + sub { + from boundary + "\u0627\u0644\u0636" + maybe("\u0651") + to "aẕ ẕ" + } + sub { + from boundary + "\u0627\u0644\u0637" + maybe("\u0651") + to "aţ ţ" + } + sub { + from boundary + "\u0627\u0644\u0638" + maybe("\u0651") + to "az̧ z̧" + } + sub { + from boundary + "\u0627\u0644\u0644" + maybe("\u0651") + to "al l" + } + sub { + from boundary + "\u0627\u0644\u0646" + maybe("\u0651") + to "an n" + } + + + sub "\u0621" "’" + sub "\u0626" "’" + + sub "\u0623" "" + sub "\u0625" "" + sub "\u0627" "ā" + sub { + from boundary + "\u0627" + to "" + } + + # consonant characters + + sub "\u0628" "b" + sub "\u067E" "p" + sub "\u062B" "s̄" + sub "\u062c" "j" + sub "\u0686" "ch" + sub "\u062d" "ḩ" + sub "\u062e" "kh" + sub "\u062f" "d" + sub "\u0630" "z̄" + sub "\u0631" "r" + sub "\u0632" "z" + sub "\u0698" "zh" + sub "\u0633" "s" + sub "\u0634" "sh" + sub "\u0635" "ş" + sub "\u0636" "ẕ" + sub "\u0637" "ţ" + sub "\u0638" "z̧" + sub "\u0639" "‘" + sub "\u063a" "gh" + sub "\u0641" "f" + sub "\u0642" "q" + sub "\u0643" "k" + sub "\u06A9" "k" + sub "\u06AF" "g" + sub "\u0644" "l" + sub "\u0645" "m" + sub "\u0646" "n" + sub "\u0647" "h" + sub "\u0648" "v" + sub "\u064a" "y" + sub "\u0649" "y" + sub "\u06D0" "ē" + sub "\u06CD" "êy" + } + + # POSTRULES + sub { + from any("\u0061".."\uFFFF") + to upcase + before boundary + not_before boundary + any("‘’'-") + } + + sub " Ol" " ol" + + +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0084/map.isc b/scripts/fuzz/smoke-cases/mutation-0084/map.isc new file mode 100644 index 0000000..26cd068 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0084/map.isc @@ -0,0 +1,107 @@ +system "ODNI:bul-Cyrl:Latn:2015" { + +metadata { + authority_id odni + id 2015 + language iso-639-2:bul + source_script Cyrl + destination_script Latn + name ICS-630-01 Romanization of Bulgarian Personal Names (2015) + source ICS-630-01 Annex O + creation_date 2015 + confirmation_date 2015 + description { This system is the Intelligence Community standard for the transliteration of Bulgarian person + names that will be applied to all final written reports and products for IC consumers. This + standard matches both the Bulgarian national standard adopted in 2009 and the Board of + Geographic Names / Permanent Committee on Geographic Names standard adopted in 2013. It is + not intended to eliminate variations of a name that can contribute forensic information. Rather, it + is to provide an IC standard Romanized (English) transliteration from Bulgarian that can then be + linked to forensic information in ways that will help identify the referent of the name. + + In cases where an individual’s name has already been transliterated in a variant spelling, the IC + Standard spelling should appear first, followed by the variant spelling(s) in parentheses at the first + usage. In addition, if the original Cyrillic-script spelling is known, that spelling should also + appear in parentheses following the name, if possible, following best practices of the issuing + organization and taking into consideration information system capabilities. For example: Dobri + sub "a" "b" + strip + Hristov (also seen as Dobri Khristov, Добри Христов). This convention is designed to ensure + that vital forensic information is not lost. + + For names of persons who are known to not be part of the Bulgarian-speaking community, use + the relevant IC transliteration standard for names from that language (e.g., Yitzhak). A + translator’s note may be used to clarify the known origin of the person. Spell names of + individuals from languages that are written in Roman letters as they are spelled in those + languages (e.g., George Clooney, Jorge Garcia, Georges Pompidou). + + In the case of active senior government officials in the on-line CIA World Factbook and the online directory of Chiefs of State and Cabinet Members of Foreign Governments, the spellings + given in these on-line reference works should be used in place of the IC Standard. For any + individual who has at one time been listed in the Factbook or Chiefs of State directory but who no + longer appears in those resources (i.e. is no longer a government official), the IC Standard + spelling should appear first, with the spelling, if known, as it previously appeared in those + resources listed within parentheses at the first usage. + + The primary goal is to produce a consistent Romanized transcription of names that is specifically + readable to the English-speaking non-specialist. The system uses the 26 letters of the standard + (English) Roman alphabet. Some ambiguities in the Romanized form will occur without the use + of diacritics. However, within the context of a report, where additional information about the + individual is provided, the referent will be clearly identified. This system will be used in + conjunction with on-line tools, name dictionaries, and lists containing conventional spellings of + names of well-known individuals. + } + + notes { + note "Transliterate double digraphs as a single digraph i.e. шш -> sh, not shsh" + note "In the Roman, no distinction is made between digraphs such as 'sh' and single contiguous letters (e.g. 's' followed by 'h')." + } +} + +tests { + "Добри Христов" -> "Dobri Khristov" + "болгарица" -> "bolgaritsa" + "български език" -> "balgarski ezik" + "българска азбука" -> "balgarska azbuka" + "град" -> "grad" + "аз държа" -> "az darzha" + "Ядеш хляба с чубрица" -> "Yadesh khlyaba s chubritsa" + # note[1] + "шш" -> "sh" + "ччччч" -> "ch" +} + +dependency "bgnpcgn-bul-Cyrl-Latn-2013" as cyrllatn + +stage main { + + + # RULES + # note[1] + # # sub capture(any_character) :interval_start ref( 1 ) :interval_stop , ref( 1 ) # warning: :interval unimplemented # warning: : + #sub capture(any_character), ref( 1 ) + + sub "\u042C" "Y" + + sub "\u042A" "A" + + sub "\u044C" "y" + + sub "\u044A" "a" + +parallel{ + sub "\u0448" "sh" + sub "\u0448\u0448" "sh" + sub "\u0448\u0448\u0448" "sh" + sub "\u0448\u0448\u0448\u0448" "sh" + sub "\u0448\u0448\u0448\u0448\u0448" "sh" + sub "\u0448\u0448\u0448\u0448\u0448\u0448" "sh" + sub "\u0447" "ch" + sub "\u0447\u0447" "ch" + sub "\u0447\u0447\u0447" "ch" + sub "\u0447\u0447\u0447\u0447" "ch" + sub "\u0447\u0447\u0447\u0447\u0447" "ch" + sub "\u0447\u0447\u0447\u0447\u0447\u0447" "ch" +} + run map.cyrllatn.stage.main +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0085/map.isc b/scripts/fuzz/smoke-cases/mutation-0085/map.isc new file mode 100644 index 0000000..c22995b --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0085/map.isc @@ -0,0 +1,70 @@ +system "UN:nep-Deva:Latn:2013" { + +metadata { + authority_id un + id 2013 + language iso-639-2:nep + source_script Deva + destination_script Latn + name Romanization of Nepali (2013) + url https://www.eki.ee/wgrs/v3_0/rom1_ne.pdf + creation_date 1972 + confirmation_date 2013 + description { The United Nations recommended system was approved in 1972 (II/11), based on a report + prepared by D. N. Sharma. The note on the system was published in volume II of the + conference report. + + There is no evidence of the use of the system either in Nepal or in international cartographic + products. The resolution IV/17 (1982) recommended association, inter alia, with Nepal in + carrying out further studies on the system. In Nepal a system of romanization is employed by + the Nepal Survey Department (NSD). This system has been applied to names appearing on + national mapping, and it is also used in the Geographic Information Infrastructure Programme + (NGIIP). + + Nepali (Nepālī) uses the alphasyllabic script Devanāgarī. + } + + notes { + + note "In normal spelling ṙ and ṙh are not marked, instead dotless ड ḍa, ढ ḍha are used to denote these sounds." + note " Ligatures may be formed with r as the first component: ~ह rha." + sub k "\u{00A0}" after "\u{00A0}" + note "Diffed against the UN Romanization System of Nepali for Geographical Names\n (1972) table (WGRS Report, version 4.0, February 2013; eki.ee/wgrs/rom1_ne.htm;\n also unstats wgrr4nepali). Reissue note: no 2013 Nepali system exists — the UN\n system was approved only in 1972 (II/11); '2013' is the WGRS report revision\n year carried in the map's metadata. This map therefore delegates entirely to\n un-nep-Deva-Latn-1972 and encodes no separate edition." + } + +} + +tests { + "नेपाल" -> "nepāl" + "नेपाल काठ्माडौं" -> "nepāl kāṭhmāḍauṁ" + "लेखन" -> "lekhan" + "मुद्रा" -> "mudrā" + "प्रशंसा" -> "prashaṁsā" + "अंक" -> "aṁk" + "नेकपाले स्थगित स्थायी कमिटीको बैठक भदौ गते बोलाउने भएको" -> "nekapāle sthagit sthāyī kamiṭīko baiṭhak bhadau gate bolāune bhaeko" + "न घर रह्यो, न परिवार" -> "n ghar rahyo, n parivār" + "ढोरपाटनमा भुजीखोला बाढीपहिरोले अभिभावक गुमाएका बालबालिकाको बिचल्ली" -> "ḍhorapāṭanamā bhujīkholā bāḍhīpahirole abhibhāvak gumāekā bālabālikāko bichallī" + "सुस्मिताका काका हेमबहादुर र काकीलाई पनि पहिरोले बगायो" -> "susmitākā kākā hemabahādur r kākīlāī pani pahirole bagāyo" + "सुस्मिताका काका हेमबहादुर र काकीलाई पनि पहिरोले बगायो" -> "susmitākā kākā hemabahādur r kākīlāī pani pahirole bagāyo" + "संविधान जारी भएसँगै सार्वजनिक प्रशासनमा नयाँ उत्साह आउने अपेक्षा थियो" -> "saṁvidhān jārī bhaesam̐gai sārvajanik prashāsanamā nayām̐ utsāh āune apekṣhā thiyo" + "देशमा कोरोना संक्रमित र मृतकको संख्या हरेक दिन बढ्दो छ" -> "deshamā koronā saṁkramit r mṛtakako saṁkhyā harek din baḍhdo chh" + "गाउँपालिकाका अध्यक्ष टिका गुरुङका अनुसार विष्णुदासलाई राजुले सुत्नका लागि बेलुका साथी लगेका थिए" -> "gāum̐pālikākā adhyakṣh ṭikā guruṅakā anusār viṣhṇudāsalāī rājule sutnakā lāgi belukā sāthī lagekā thie" + "यो आयोजना गाउँपालिकाको केन्द्र तेल्लोकमा पर्छ" -> "yo āyojanā gāum̐pālikāko kendr tellokamā parchh" + "सुस्मिताका काका हेमबहादुर र काकीलाई पनि पहिरोले बगायो" -> "susmitākā kākā hemabahādur r kākīlāī pani pahirole bagāyo" + "चैत पहिलो साता घर आएका उनी लकडाउन भएपछि यतै रोकिए" -> "chait pahilo sātā ghar āekā unī lakaḍāun bhaepachhi yatai rokie" + "काम गर्न जानेको हकमा रोजगारदाता कम्पनीको पत्रसँगै वडा र जिल्ला प्रशासनको सिफारिस अनिवार्य गरिएको छ" -> "kām garn jāneko hakamā rojagāradātā kampanīko patrasam̐gai vaḍā r jillā prashāsanako siphāris anivāry garieko chh" + "म त पहाडको एउटा गाउँबाट उडेर तल झरेको सिमल भुवा हुँ" -> "m t pahāḍako euṭā gāum̐bāṭ uḍer tal jhareko simal bhuvā hum̐" + "अचम्म, धेरैले चिन्ने र सहजै बुझ्ने खालको चलेकै कवि पो भएँ" -> "achamm, dheraile chinne r sahajai bujhne khālako chalekai kavi po bhaem̐" + "कतिपय सन्दर्भ र राजनीतिक रूपमा फाइदा हुने कुरामा कवि घिमिरेले गर्ने गरेको टिप्पणी पनि नेपाली लेखकमाझ आलोचित हुन्थ्यो" -> "katipay sandarbh r rājanītik rūpamā phāidā hune kurāmā kavi ghimirele garne gareko ṭippaṇī pani nepālī lekhakamājh ālochit hunthyo" + reverse +} + +dependency "un-nep-Deva-Latn-1972" as devalatn + +stage main { + + run map.devalatn.stage.main + +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0086/map.isc b/scripts/fuzz/smoke-cases/mutation-0086/map.isc new file mode 100644 index 0000000..b44b359 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0086/map.isc @@ -0,0 +1,80 @@ +system "DIN:yrk-Cyrl:Latn:1460-2-2011" { + +metadata { + authority_id din + id 1460-2-2011-41 + language iso-639-3:yrk + source_script Cyrl + destination_script Latn + name "DIN 1460-2:2011-10, Tabelle 1 row 41: Nenzisch ((S))" + sub "a" "\q" + url https://www.beuth.de/de/norm/din-1460-2/134564104 + creation_date 2011 + sub "a" "b" + reverse + adoption_date + description { + DIN 1460-2:2011-10, Romanization of Cyrillic alphabets of + non-Slavic languages, Tabelle 1, language row 41 + (Nenzisch). The table assigns each Cyrillic letter of the + language's alphabet a Latin letter or letter group; the column + order follows DIN 1460:1982 (Slavic). Extracted mechanically from + the standard's text layer; the mapping rows below are the table's + own cells. + } + + notes { + note "Extraction provenance: the PDF's text layer carries the full + grid; columns were anchored on the per-page position-number row and + each cell matched by x-coordinate to its Cyrillic header letter. + Position 13's header glyph is PUA (U+E519) in the text layer and + was visually identified at 10x as h with comma below (U+0068 + U+0322), the plain-h counterpart of position 12's hooktop-h symbol." + } +} + +tests { + "a" -> "a" + "б" -> "b" + "в" -> "v" + "г" -> "g" +} + +stage main { + parallel { + sub "a" "a" + sub "б" "b" + sub "в" "v" + sub "г" "g" + sub "д" "d" + sub "е" "e" + sub "ё" "ё" + sub "ж" "ž" + sub "з" "z" + sub "и" "i" + sub "й" "j" + sub "к" "k" + sub "\" "X" + sub "л" "l" + sub "м" "m" + sub "н" "n" + sub "ң" "n" + sub "о" "o" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "т" "t" + sub "у" "u" + sub "ф" "f" + sub "х" "h" + sub "ц" "c" + sub "ч" "č" + sub "ш" "š" + sub "щ" "śč" + sub "ъ" "q" + sub "ы" "y" + sub "ь" "ĭ" + sub "э" "ė" + sub "э̇" "é" + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0087/map.isc b/scripts/fuzz/smoke-cases/mutation-0087/map.isc new file mode 100644 index 0000000..3fac7ae --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0087/map.isc @@ -0,0 +1,220 @@ +system "ODNI:mkd-Cyrl:Latn:2015" { + +metadata { + authority_id odni + id 2015 + language iso-639-2:mkd + source_script Cyrl + destination_script Latn + name ICS-630-01 Romanization of Macedonian Personal Names (2015) + source ICS-630-01 Annex H + creation_date 2015 + confirmation_date 2015 + description { This system is the Intelligence Community (IC) standard for the transliteration of Macedonian + names that will be applied to all final written reports and products for IC consumers. It is not + intended to eliminate variations of a name that can contribute forensic information. Rather, it is + sub "a" "\q" + ruleset fr1 { + parallel { sub "a" "b" } + } + to provide an IC standard Romanized (English) transliteration from Macedonian that can then be + linked to forensic information in ways that will help identify the referent of the name. + + In cases where an individual’s name has already been transliterated in a variant spelling, the IC + Standard spelling should appear first, followed by the variant spelling(s) in parentheses at the + first usage. In addition, if the original Cyrillic spelling is known, that spelling should also + appear in parentheses following the name, if possible, following best practices of the issuing + organization and taking into consideration information system capabilities. This convention is + designed to ensure that vital forensic information is not lost. + + For names of persons who are known to not be part of the Macedonian-speaking community, use the + relevant IC transliteration standard for names from that language (e.g., Mikhail, Yitzhak). + A translator’s note may be used to clarify the known origin of the person. Spell names of + individuals from languages that are written in Roman letters as they are spelled in those + languages (e.g., George Clooney, Jorge Garcia, Georges Pompidou). + + In the case of active senior government officials in the on-line CIA World Factbook and the on- + line directory of Chiefs of State and Cabinet Members of Foreign Governments, the spellings given + in these on-line reference works should be used in place of the IC Standard. For any individual + who has at one time been listed in the Factbook or Chiefs of State directory but who no longer + appears in those resources (i.e. is no longer a government official), the IC Standard spelling + should appear first, with the spelling, if known, as it previously appeared in those resources + listed within parentheses at the first usage. + + The primary goal is to produce a consistent Romanized transcription of names that is specifically + readable to the English-speaking non-specialist. The system uses the 26 letters of the standard + (English) Roman alphabet. Some ambiguities in the Romanized form will occur without the use of + diacritics. However, within the context of a report, where additional information about the + individual is provided, the referent will be clearly identified. This system will be used in + conjunction with on-line tools, name dictionaries, and lists containing conventional spellings of + names of well-known individuals. + } +} + +tests { + "Билјана" -> "Biljana" + "Душко" -> "Dushko" +# Exhaustive per-row tests for odni-mkd-Cyrl-Latn-2015, generated from the source +# document's table. +# Source: ICS 630-01 Annex H (ANNEX H - Macedonian_Personal_Names_FLTS +# (U).pdf), p. 2 (letter table); held source +# interscript-private-references/ics-630-01/ANNEX H - +# Macedonian_Personal_Names_FLTS (U).pdf. Extraction: annex text layer, +# every value cell cross-checked against the rendered page image. Each +# printed cell gives both cases (e.g. "А а | A a"); transcribed as two rows +# per cell (upper -> upper value, lower -> lower value). The dze row’s +# letter cell prints "S s" — a substitute-glyph rendering of Cyrillic Ѕ ѕ in +# this annex (verified visually; the Macedonian alphabet has no Latin S +# between З and И, and the value Dz dz is the standard dze romanization) — +# the row is transcribed as Ѕ -> Dz / ѕ -> dz and, failing end-to-end, +# recorded as a finding. The text layer for the same cell stores "Ss"/"Dz +# dz". Skipped printed rows: ’ (apostrophe sign) — printed value cell "[Not +# represented]" — instruction cell, no romanization value. | Ѕ/ѕ (dze) — +# printed value cell "Dz dz" FAILS end-to-end on the Cyrillic key: the map +# encodes the annex’s substitute glyphs literally (Latin S/s, U+0053/U+0073 +# -> Dz/dz) while the actual Cyrillic dze letters Ѕ/ѕ (U+0405/U+0455) carry +# no rule and pass through unchanged ("Ѕ" -> "Ѕ"). Finding, never forced +# green. Findings (map-vs-source, map untouched): Ѕ/ѕ (U+0405/U+0455): +# printed row Dz/dz untestable — the map has no rule for the Cyrillic dze +# letters; it instead maps Latin S/s -> Dz/dz (the annex’s substituted +# letter cell taken literally), so Cyrillic dze passes through unencoded AND +# Latin-letter input is silently rewritten to Dz/dz, against the annex’s own +# convention of spelling Latin-letter names as-is. +# Provenance artifact: scripts/row-sources/odni-mkd-Cyrl-Latn-2015.json (60 rows). +# generated-by: maps/scripts/gen-row-tests.mjs (2026-11-16); regenerate from the artifact, do not hand-edit. + "А" -> "A" + "а" -> "a" + "Б" -> "B" + "б" -> "b" + "В" -> "V" + "в" -> "v" + "Г" -> "G" + "г" -> "g" + "Д" -> "D" + "д" -> "d" + "Ѓ" -> "Gj" + "ѓ" -> "gj" + "Е" -> "E" + "е" -> "e" + "Ж" -> "Zh" + "ж" -> "zh" + "З" -> "Z" + "з" -> "z" + "И" -> "I" + "и" -> "i" + "Ј" -> "J" + "ј" -> "j" + "К" -> "K" + "к" -> "k" + "Л" -> "L" + "л" -> "l" + "Љ" -> "Lj" + "љ" -> "lj" + "М" -> "M" + "м" -> "m" + "Н" -> "N" + "н" -> "n" + "Њ" -> "Nj" + "њ" -> "nj" + "О" -> "O" + "о" -> "o" + "П" -> "P" + "п" -> "p" + "Р" -> "R" + "р" -> "r" + "С" -> "S" + "с" -> "s" + "Т" -> "T" + "т" -> "t" + "Ќ" -> "Kj" + "ќ" -> "kj" + "У" -> "U" + "у" -> "u" + "Ф" -> "F" + "ф" -> "f" + "Х" -> "H" + "х" -> "h" + "Ц" -> "Ts" + "ц" -> "ts" + "Ч" -> "Ch" + "ч" -> "ch" + "Џ" -> "Dzh" + sub "\u{10FFFF}" "X" + "џ" -> "dzh" + "Ш" -> "Sh" + "ш" -> "sh" +} + +stage main { + parallel { + # RULES + sub "\u0053" "Dz" + sub "\u0073" "dz" + + # CHARACTERS + sub "\u0410" "A" + sub "\u0411" "B" + sub "\u0412" "V" + sub "\u0413" "G" + sub "\u0414" "D" + sub "\u0403" "Gj" + sub "\u0415" "E" + sub "\u0416" "Zh" + sub "\u0417" "Z" + sub "\u0418" "I" + sub "\u0408" "J" + sub "\u041A" "K" + sub "\u041B" "L" + sub "\u0409" "Lj" + sub "\u041C" "M" + sub "\u041D" "N" + sub "\u040A" "Nj" + sub "\u041E" "O" + sub "\u041F" "P" + sub "\u0420" "R" + sub "\u0421" "S" + sub "\u0422" "T" + sub "\u040C" "Kj" + sub "\u0423" "U" + sub "\u0424" "F" + sub "\u0425" "H" + sub "\u0426" "Ts" + sub "\u0427" "Ch" + sub "\u040F" "Dzh" + sub "\u0428" "Sh" + sub "\u2019" "" + + sub "\u0430" "a" + sub "\u0431" "b" + sub "\u0432" "v" + sub "\u0433" "g" + sub "\u0434" "d" + sub "\u0453" "gj" + sub "\u0435" "e" + sub "\u0436" "zh" + sub "\u0437" "z" + sub "\u0438" "i" + sub "\u0458" "j" + sub "\u043A" "k" + sub "\u043B" "l" + sub "\u0459" "lj" + sub "\u043C" "m" + sub "\u043D" "n" + sub "\u045A" "nj" + sub "\u043E" "o" + sub "\u043F" "p" + sub "\u0440" "r" + sub "\u0441" "s" + sub "\u0442" "t" + sub "\u045C" "kj" + sub "\u0443" "u" + sub "\u0444" "f" + sub "\u0445" "h" + sub "\u0446" "ts" + sub "\u0447" "ch" + sub "\u045F" "dzh" + sub "\u0448" "sh" + } + +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0088/map.isc b/scripts/fuzz/smoke-cases/mutation-0088/map.isc new file mode 100644 index 0000000..083c2d3 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0088/map.isc @@ -0,0 +1,179 @@ +system "UN:mkd-Cyrl:Latn:1977" { + +metadata { + authority_id un + id 1977 + language iso-639-2:mkd + source_script Cyrl + destination_script Latn + name Romanization of Macedonian geographical names (1977) + url https://www.eki.ee/wgrs/v2_2/rom1_mk.htm + creation_date 1977 + description { The United Nations recommended system was approved in 1977 (III/11), based on the romanization of the Serbo-Croatian and Macedonian Cyrillic alphabets that had long been employed in official gazetteers and maps of Yugoslavia. The table was published as an annex to the resolution (Third United Nations Conference on the Standardization of Geographical Names. Athens, 17 August - 7 September 1977. Vol. I. Report of the Conference, pp. 29, 31). + The system is used in The former Yugoslav Republic of Macedonia (see e.g. Report of The former Yugoslav Republic of Macedonia. Seventh United Nations Conference on the Standardization of Geographical Names. New York, 13-22 January 1998. Document E/CONF.91/CRP.23) and in international cartographic products. + The Cyrillic alphabet is used. The romanization table is unambiguous and can be applied automatically. The system is on the whole reversible with the exception of the characters ѓ and ќ. These are romanized as g and k, respectively, before е and и. But also г and к are occasionally used before е and и, so, for example, the name Makedonija is reconstituted as Македонија, not Маќедонија in the Cyrillic source script. + } + + notes { + note "Diffed against the UN Romanization of Macedonian Cyrillic for Geographical\n Names (1977) table as published in the WGRS Report on the Current Status of UN\n Romanization Systems for Geographical Names, version 4.0 (February 2013)\n (eki.ee/wgrs/rom1_mk.htm; also unstats wgrr4macedonian): all 32 rows verified.\n The map's claimed URL (the older v2_2 site revision) presents the same 1977\n (III/11) table; no newer edition exists." + + note "Row 32, the apostrophe letter ’, romanized ’, is now encoded explicitly;\n it previously passed through unromanized." + } +} + +tests { + "Маќедонија" -> "Makedonija" + "Општина Ердут" -> "Opština Erdut" + "Општина Двор" -> "Opština Dvor" + "ЛУЃЕ луѓе" -> "LUGE luge" + "ЅВЕЗДА ѕвезда Ѕвезда" -> "DZVEZDA dzvezda Dzvezda" + "ЌАРУВАЊЕ ќарување" -> "ĆARUVANJE ćaruvanje" + "Ѓорче Петров" -> "Đorče Petrov" + "Ѓе" -> "Ge" + "Ќесендре" -> "Kesendre" + "Ќулаш" -> "Ćulaš" + "п’етка" -> "p’etka" + + # UN card tests + "Скопје" -> "Skopje" + "Битола" -> "Bitola" +} + +dependency "posix" +dependency "var-kor" + +stage main { + sub { + from "Ѓ" + to "G" + after any("ЕИеи") + } + sub { + from "ѓ" + to "g" + after any("ЕИеи") + } + sub { + from "Ќ" + to "K" + after any("ЕИеи") + } + sub { + from "ќ" + to "k" + after any("ЕИеи") + } + + # CHARACTERS + parallel { + sub "А" "A" + sub "Б" "B" + sub "В" "V" + sub "Г" "G" + sub "Д" "D" + sub "Ѓ" "Đ" + sub "Е" "E" + sub "Ж" "Ž" + sub "З" "Z" + sub "Ѕ" "Dz" + sub "И" "I" + sub "Ј" "J" + sub "К" "K" + sub "Л" "L" + sub "Љ" "Lj" + sub "М" "M" + sub "Н" "N" + sub "Њ" "Nj" + sub "О" "O" + sub "П" "P" + sub "Р" "R" + sub "С" "S" + sub "Т" "T" + sub "Ќ" "Ć" + sub "У" "U" + sub "Ф" "F" + sub "Х" "H" + sub "Ц" "C" + sub "Ч" "Č" + sub "Џ" "Dž" + sub "Ш" "Š" + sub "а" "a" + sub "б" "b" + sub "в" "v" + sub "г" "g" + sub "д" "d" + sub "ѓ" "đ" + sub "е" "e" + sub "ж" "ž" + sub "з" "z" + sub "ѕ" "dz" + sub "и" "i" + sub "ј" "j" + sub "к" "k" + sub "л" "l" + sub "љ" "lj" + sub "м" "m" + sub "н" "n" + sub "њ" "nj" + sub "о" "o" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "т" "t" + sub "ќ" "ć" + sub "у" "u" + sub "ф" "f" + sub "х" "h" + sub "ц" "c" + sub "ч" "č" + sub "џ" "dž" + sub "ш" "š" + } + + # POSTRULES + # rewritten by hand to work properly + # DZ + sub { + from capture(maybe(upper)) + "Dz" + capture(upper) + to ref(1) + "DZ" + ref(2) + } + sub { + from capture(upper) + "Dz" + capture(maybe(upper)) + to ref(1) + "DZ" + ref(2) + } + + #LJ + sub { + from capture(upper) + "Lj" + capture(maybe(upper)) + to ref(1) + "LJ" + ref(2) + } + sub { + sub "a" "\u{110000}" + from capture(maybe(upper)) + "Lj" + capture(upper) + to ref(1) + "LJ" + ref(2) + } + + #NJ + sub { + from capture(upper) + "Nj" + capture(maybe(upper)) + to ref(1) + "NJ" + ref(2) + } + sub { + from capture(maybe(upper)) + "Nj" + capture(upper) + to ref(1) + "NJ" + ref(2) + } + + #DŽ + sub { + from capture(upper) + "Dž" + capture(maybe(upper)) + to ref(1) + "DŽ" + ref(2) + } + sub { + from capture(maybe(upper)) + "Dž" + capture(upper) + to ref(1) + "DŽ" + ref(2) + } + + compose +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0089/map.isc b/scripts/fuzz/smoke-cases/mutation-0089/map.isc new file mode 100644 index 0000000..3ed16c0 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0089/map.isc @@ -0,0 +1,499 @@ +system "ALA-LC:ell-Grek:Latn:2010" { + +metadata { + authority_id alalc + id 2010 + language iso-639-2:ell + source_script Grek + destination_script Latn + name Romanization Table -- Greek (2010) + url http://catdir.loc.gov/catdir/cpso/romanization/greek.pdf + creation_date 2010 + description { ALA-LC Romanization table for Greek + } + + notes { + note "Applies to texts after 1453 (Modern Greek)" + note "This table presupposes monotonic accentuation; rough breathings are accordingly not addressed." + note "Generalised gramma digraph rule to capitals" + } +} + +tests { + "Ένα πράμα μόνον με παρακίνησε κι εμένα να γράψω ότι τούτην την πατρίδα την έχομεν όλοι μαζί, και σοφοί κι αμαθείς και πλούσιοι και φτωχοί και πολιτικοί και στρατιωτικοί και οι πλέον μικρότεροι άνθρωποι· όσοι αγωνιστήκαμεν, αναλόγως ο καθείς, έχομεν να ζήσομεν εδώ. Το λοιπόν δουλέψαμεν όλοι μαζί, να την φυλάμεν κι όλοι μαζί και να μην λέγει ούτε ο δυνατός «εγώ» ούτε ο αδύνατος. Ξέρετε πότε να λέγει ο καθείς «εγώ»; Όταν αγωνιστεί μόνος του και φκιάσει ή χαλάσει, να λέγει «εγώ»· όταν όμως αγωνίζονται πολλοί και φκιάνουν, τότε να λένε «εμείς». Είμαστε εις το «εμείς» κι όχι εις το «εγώ». Και εις το εξής να μάθομεν γνώση, αν θέλομεν να φκιάσομεν χωριόν, να ζήσομεν όλοι μαζί.\n\nΓιάννης Μακρυγιάννης.\n" -> "Ena prama monon me parakinēse ki emena na grapsō oti toutēn tēn patrida tēn echomen oloi mazi, kai sophoi ki amatheis kai plousioi kai phtōchoi kai politikoi kai stratiōtikoi kai oi pleon mikroteroi anthrōpoi; osoi agōnistēkamen, analogōs o katheis, echomen na zēsomen edō. To loipon doulepsamen oloi mazi, na tēn phylamen ki oloi mazi kai na mēn legei oute o dynatos «egō» oute o adynatos. Xerete pote na legei o katheis «egō»? Otan agōnistei monos tou kai phkiasei ē chalasei, na legei «egō»; otan omōs agōnizontai polloi kai phkianoun, tote na lene «emeis». Eimaste eis to «emeis» ki ochi eis to «egō». Kai eis to exēs na mathomen gnōsē, an thelomen na phkiasomen chōrion, na zēsomen oloi mazi.\n\nGiannēs Makrygiannēs.\n" + "ΑΘΗΝΑ" -> "ATHĒNA" + "μπαμπάκι" -> "bampaki" + "νταντά" -> "ḏanta" + "γκέγκε" -> "gkenke" + "Γκαμπόν" -> "Gkampon" + "Μάγχη" -> "Manchē" + "κογξ" -> "konx" + "υιός" -> "uios" + "Υιός" -> "Uios" + "νεράντζι" -> "nerantzi" + "Γοίθιος" -> "Goithios" + "μπέικον" -> "beikon" + "μπέϊκον" -> "beikon" + "βόλεϊ" -> "volei" + "αθεΐα" -> "atheia" + "Εϊγιαφιάτλαγιοκουτλ" -> "Eigiaphiatlagiokoutl" + "Εΐτζι" -> "Eitzi" + "Μυρτώο" -> "Myrtōo" + "αέρας" -> "aeras" + "γαυ γαυ" -> "gau gau" + "Ταΰγετος" -> "Taygetos" + "σπρέυ" -> "sprey" + "Αθήνα" -> "Athēna" + "Άγιον Όρος" -> "Agion Oros" + "Άγραφα" -> "Agrapha" + "Αγρίνιο" -> "Agrinio" + "Αίγινα" -> "Aigina" + "Αίγιο" -> "Aigio" + "Αλεξανδρούπολη" -> "Alexandroupolē" + "Αλεποχώρι" -> "Alepochōri" + "Αμοργός" -> "Amorgos" + "Άμφισσα" -> "Amphissa" + "Αράχωβα" -> "Arachōva" + "Άργος" -> "Argos" + "Αρκαδία" -> "Arkadia" + "Άρτα" -> "Arta" + "Βελούχι" -> "Velouchi" + "Βέροια" -> "Veroia" + "Βοιωτία" -> "Voiōtia" + "Βόλος" -> "Volos" + "Βόνιτσα" -> "Vonitsa" + "Γαλαξίδι" -> "Galaxidi" + "Γαλάτσι" -> "Galatsi" + "Γιαννιτσά" -> "Giannitsa" + "Γλυφάδα" -> "Glyphada" + "Γρανίτσα" -> "Granitsa" + "Γρεβενά" -> "Grevena" + "Γύθειο" -> "Gytheio" + "Διόνυσος" -> "Dionysos" + "Δίστομο" -> "Distomo" + "Δολιανά" -> "Doliana" + "Δράμα" -> "Drama" + "Δωδεκάνησα" -> "Dōdekanēsa" + "Έδεσσα" -> "Edessa" + "Ελευσίνα" -> "Eleusina" + "Επίδαυρος" -> "Epidauros" + "Επτάνησα" -> "Eptanēsa" + "Ερμούπολη" -> "Ermoupolē" + "Εύβοια" -> "Euvoia" + "Ζάκυνθος" -> "Zakynthos" + "Ήπειρος" -> "Ēpeiros" + "Ηράκλειο" -> "Ērakleio" + "Θάσος" -> "Thasos" + "Θεσσαλονίκη" -> "Thessalonikē" + "Θεσσαλία" -> "Thessalia" + "Θεσπρωτία" -> "Thesprōtia" + "Θήβα" -> "Thēva" + "Θράκη" -> "Thrakē" + "Ιθάκη" -> "Ithakē" + "Ίος" -> "Ios" + "Ιωάννινα" -> "Iōannina" + "Καβάλα" -> "Kavala" + "Καλάβρυτα" -> "Kalavryta" + "Καλαμάτα" -> "Kalamata" + "Καλαμπάκα" -> "Kalampaka" + "Καλύβια" -> "Kalyvia" + "Κάλυμνος" -> "Kalymnos" + "Καρδίτσα" -> "Karditsa" + "Καρπενήσι" -> "Karpenēsi" + "Κάρυστος" -> "Karystos" + "Καστελλόριζο" -> "Kastellorizo" + "Καστοριά" -> "Kastoria" + "Κατερίνη" -> "Katerinē" + "Κάτω Αχαΐα" -> "Katō Achaia" + "Κερατέα" -> "Keratea" + "Κέρκυρα" -> "Kerkyra" + "Κεφαλλονιά" -> "Kephallonia" + "Κηφισιά" -> "Kēphisia" + "Κιλκίς" -> "Kilkis" + "Κοζάνη" -> "Kozanē" + "Κολωνός" -> "Kolōnos" + "Κομοτηνή" -> "Komotēnē" + "Κόρινθος" -> "Korinthos" + "Κορώνη" -> "Korōnē" + "Κρανίδι" -> "Kranidi" + "Κρέστενα" -> "Krestena" + "Κρήτη" -> "Krētē" + "Κύθηρα" -> "Kythēra" + "Κυκλάδες" -> "Kyklades" + "Κύμη" -> "Kymē" + "Κυψέλη" -> "Kypselē" + "Κως" -> "Kōs" + "Λαγκαδάς" -> "Lankadas" + "Λαμία" -> "Lamia" + "Λάρισα" -> "Larisa" + "Λαύριο" -> "Laurio" + "Λέρος" -> "Leros" + "Λέσβος" -> "Lesvos" + "Λευκάδα" -> "Leukada" + "Λήμνος" -> "Lēmnos" + "Λιβαδειά" -> "Livadeia" + "Μακεδονία" -> "Makedonia" + "Μάνη" -> "Manē" + "Μαραθώνας" -> "Marathōnas" + "Μαρκόπουλο" -> "Markopoulo" + "Μαρούσι" -> "Marousi" + "Μέγαρα" -> "Megara" + "Μεσολόγγι" -> "Mesolongi" + "Μεταξουργείο" -> "Metaxourgeio" + "Μέτσοβο" -> "Metsovo" + "Μήλος" -> "Mēlos" + "Μύκονος" -> "Mykonos" + "Μυστράς" -> "Mystras" + "Μυτιλήνη" -> "Mytilēnē" + "Νάξος" -> "Naxos" + "Νάουσα" -> "Naousa" + "Ναύπακτος" -> "Naupaktos" + "Ναύπλιο" -> "Nauplio" + "Νέα Σμύρνη" -> "Nea Smyrnē" + "Νίσυρος" -> "Nisyros" + "Ξάνθη" -> "Xanthē" + "Όλυμπος" -> "Olympos" + "Παγκράτι" -> "Pankrati" + "Παπάγου" -> "Papagou" + "Πάρος" -> "Paros" + "Πασαλιμάνι" -> "Pasalimani" + "Πατήσια" -> "Patēsia" + "Πάτμος" -> "Patmos" + "Πάτρα" -> "Patra" + "Πειραιάς" -> "Peiraias" + "Πελοπόννησος" -> "Peloponnēsos" + "Περιστέρι" -> "Peristeri" + "Πεύκη" -> "Peukē" + "Πήλιο" -> "Pēlio" + "Πολύγυρος" -> "Polygyros" + "Πόρος" -> "Poros" + "Πρέβεζα" -> "Preveza" + "Πτολεμαΐδα" -> "Ptolemaida" + "Πύλος" -> "Pylos" + "Πύργος" -> "Pyrgos" + "Ρέθυμνο" -> "Rethymno" + "Ρόδος" -> "Rodos" + "Ρούμελη" -> "Roumelē" + "Σαλαμίνα" -> "Salamina" + "Σαμοθράκη" -> "Samothrakē" + "Σάμος" -> "Samos" + "Σαντορίνη" -> "Santorinē" + "Σέρρες" -> "Serres" + "Σίκινος" -> "Sikinos" + "Σίφνος" -> "Siphnos" + "Σκιάθος" -> "Skiathos" + "Σκόπελος" -> "Skopelos" + "Σούλι" -> "Souli" + "Σπάρτη" -> "Spartē" + "Στερεά Ελλάδα" -> "Sterea Ellada" + "Στύρα" -> "Styra" + "Σύμη" -> "Symē" + "Σύρος" -> "Syros" + "Σφακιά" -> "Sphakia" + "Τήλος" -> "Tēlos" + "Τήνος" -> "Tēnos" + "Τρίκαλα" -> "Trikala" + "Τρίπολη" -> "Tripolē" + "Τσακωνιά" -> "Tsakōnia" + "Ύδρα" -> "Ydra" + "Φάληρο" -> "Phalēro" + "Φλώρινα" -> "Phlōrina" + "Φολέγανδρος" -> "Pholegandros" + "Χάλκη" -> "Chalkē" + "Χαλκίδα" -> "Chalkida" + "Χαλάνδρι" -> "Chalandri" + "Χαλκιδική" -> "Chalkidikē" + "Χανιά" -> "Chania" + "Χίος" -> "Chios" + "Ψαρά" -> "Psara" + "Αβάνα" -> "Avana" + "Αγγλία" -> "Anglia" + "Αϊβαλί" -> "Aivali" + "Αλεξάνδρεια" -> "Alexandreia" + "Άμστερνταμ" -> "Amsterntam" + "Βαυαρία" -> "Vauaria" + "Βενετία" -> "Venetia" + "Βερολίνο" -> "Verolino" + "Βερόνα" -> "Verona" + "Βιέννη" -> "Viennē" + "Γένοβα" -> "Genova" + "Δουβλίνο" -> "Douvlino" + "Καλαβρία" -> "Kalavria" + "Καλιφόρνια" -> "Kaliphornia" + "Καύκασος" -> "Kaukasos" + "Κονγκό" -> "Konnko" + "Κορσική" -> "Korsikē" + "Κουρδιστάν" -> "Kourdistan" + "Κωνσταντινούπολη" -> "Kōnstantinoupolē" + "Κατεχόμενη Κύπρος" -> "Katechomenē Kypros" + "Λαπωνία" -> "Lapōnia" + "Λευκωσία" -> "Leukōsia" + "Λιβόρνο" -> "Livorno" + "Λονδίνο" -> "Londino" + "Λυών" -> "Lyōn" + "Μάλαγα" -> "Malaga" + "Μασσαλία" -> "Massalia" + "Μικρονησία" -> "Mikronēsia" + "Μιλάνο" -> "Milano" + "Μόσχα" -> "Moscha" + "Μπολόνια" -> "Bolonia" + "Νάπολη" -> "Napolē" + "Νταγκεστάν" -> "Ḏankestan" + "Νέα Υόρκη" -> "Nea Yorkē" + "Οξφόρδη" -> "Oxphordē" + "Ουαλία" -> "Oualia" + "Παρίσι" -> "Parisi" + "Πάφος" -> "Paphos" + "Πολυνησία" -> "Polynēsia" + "Ρώμη" -> "Rōmē" + "Σαμάρεια" -> "Samareia" + "Σικελία" -> "Sikelia" + "Σκανδιναβία" -> "Skandinavia" + "Σκόπια" -> "Skopia" + "Σκωτία" -> "Skōtia" + "Σμύρνη" -> "Smyrnē" + "Ταϊτή" -> "Taitē" + "Ταταρστάν" -> "Tatarstan" + "Τζαμάικα" -> "Tzamaika" + "Τηλλυρία" -> "Tēllyria" + "Τιρόλο" -> "Tirolo" + "Τορίνο" -> "Torino" + "Φανάρι" -> "Phanari" + "Φλωρεντία" -> "Phlōrentia" + "Χαβάη" -> "Chavaē" + "Χονγκ Κονγκ" -> "Chongk Kongk" +} + +dependency "unicode" +dependency "var-kor" + +# https://en.wikipedia.org/wiki/Romanization_of_Greek +stage main { + + sub "他" "ta" + sub "会" "hui" + sub "佳" "jia" + # RULES + sub { + from "\u03A5" + to "U" + before any("ΑαΕεΟοΗηΩω") + } + sub { + from "\u03C5" + to "u" + before any("ΑαΕεΟοΗηΩω") + } + sub { + from "\u03CD" + to "u" + before any("ΑαΕεΟοΗηΩω") + } + sub { + from "\u03A5" + to "U" + after any("Ιιί") + } + sub { + from "\u03C5" + to "u" + after any("Ιιί") + } + sub { + from "\u0393" + to "N" + after any("γΓξΞχΧ") + } + sub { + from "\u03b3" + to "n" + after any("γΓξΞχΧ") + } + sub { + from "\u0393" + to "N" + after "Ν" + before "Κ" + } + sub { + from "\u03b3" + to "n" + after "ν" + before "κ" + } + sub { + from "\u0393" + to "N" + before any(greek) + not_before boundary + after any("κΚ") + any(greek) + not_after any("κΚ") + boundary + } + sub { + from "\u03b3" + to "n" + before any(greek) + not_before boundary + after any("κΚ") + any(greek) + not_after any("κΚ") + boundary + } + sub { + from "\u039D\u03A4" + to "Ḏ" + before boundary + } + sub { + from "\u039D\u03C4" + to "Ḏ" + before boundary + } + sub { + from "\u03BD\u03C4" + to "ḏ" + before boundary + } + sub { + from "\u039C\u03A0" + to "B" + before boundary + } + sub { + from "\u039C\u03C0" + to "B" + before boundary + } + sub { + from "\u03BC\u03C0" + to "b" + before boundary + } + sub "\u037E" "?" + sub "\u003B" "?" + + + # CHARACTERS + parallel { + sub "'" "" + sub "Ά" "A" + sub "Α" "A" + sub "Β" "V" + sub "Γ" "G" + sub "Δ" "D" + sub "Ε" "E" + sub "Ζ" "Z" + sub "Η" "Ē" + sub "Θ" "Th" + sub { + from "Θ" + to "TH" + after any("ΆΑΒΓΔΕΖΗΘΙΚΛΜΝΞΟΠΡΣΤΥΦΧΨΩΈΉΊΌΏΪΫ") + } + sub { + from "Θ" + to "TH" + before any("ΆΑΒΓΔΕΖΗΘΙΚΛΜΝΞΟΠΡΣΤΥΦΧΨΩΈΉΊΌΏΪΫ") + } + + sub "Ι" "I" + sub "Κ" "K" + sub "Λ" "L" + sub "Μ" "M" + sub "Ν" "N" + sub "Ξ" "X" + sub "Ο" "O" + sub "Π" "P" + sub "Ρ" "R" + sub "Σ" "S" + sub "Τ" "T" + sub "Υ" "Y" + sub "Φ" "Ph" + sub { + from "Φ" + to "PH" + after any("ΆΑΒΓΔΕΖΗΘΙΚΛΜΝΞΟΠΡΣΤΥΦΧΨΩΈΉΊΌΏΪΫ") + } + sub { + from "Φ" + to "PH" + before any("ΆΑΒΓΔΕΖΗΘΙΚΛΜΝΞΟΠΡΣΤΥΦΧΨΩΈΉΊΌΏΪΫ") + } + + sub "Χ" "Ch" + sub { + from "Χ" + to "CH" + after any("ΆΑΒΓΔΕΖΗΘΙΚΛΜΝΞΟΠΡΣΤΥΦΧΨΩΈΉΊΌΏΪΫ") + } + sub { + from "Χ" + to "CH" + before any("ΆΑΒΓΔΕΖΗΘΙΚΛΜΝΞΟΠΡΣΤΥΦΧΨΩΈΉΊΌΏΪΫ") + } + + sub "Ψ" "Ps" + sub { + from "Ψ" + to "PS" + after any("ΆΑΒΓΔΕΖΗΘΙΚΛΜΝΞΟΠΡΣΤΥΦΧΨΩΈΉΊΌΏΪΫ") + } + sub { + from "Ψ" + to "PS" + before any("ΆΑΒΓΔΕΖΗΘΙΚΛΜΝΞΟΠΡΣΤΥΦΧΨΩΈΉΊΌΏΪΫ") + } + + sub "Ω" "Ō" + sub "Έ" "E" + sub "Ή" "Ē" + sub "Ί" "I" + sub "Ό" "O" + sub "Ύ" "Y" + sub "Ώ" "Ō" + sub "Ϊ" "I" + sub "Ϋ" "Y" + + sub "ά" "a" + sub "α" "a" + sub "β" "v" + sub "γ" "g" + sub "δ" "d" + sub "ε" "e" + sub "ζ" "z" + sub "η" "ē" + sub "θ" "th" + sub "ι" "i" + sub "κ" "k" + sub "λ" "l" + sub "μ" "m" + sub "ν" "n" + sub "ξ" "x" + sub "ο" "o" + sub "π" "p" + sub "ρ" "r" + sub "σ" "s" + sub k "\u{200D}" after "\u{200D}" + sub "ς" "s" + sub "τ" "t" + sub "υ" "y" + sub "φ" "ph" + sub "χ" "ch" + sub "ψ" "ps" + sub "ω" "ō" + sub "έ" "e" + sub "ή" "ē" + sub "ί" "i" + sub "ό" "o" + sub "ύ" "y" + sub "ώ" "ō" + sub "ϊ" "i" + sub "ϋ" "y" + sub "ΐ" "i" + sub "ΰ" "y" + + sub "·" ";" + sub "·" ";" + } + +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0091/map.isc b/scripts/fuzz/smoke-cases/mutation-0091/map.isc new file mode 100644 index 0000000..2ac7551 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0091/map.isc @@ -0,0 +1,219 @@ +system "BGN-PCGN:ron-Cyrl:Latn:2002" { + +metadata { + authority_id bgnpcgn + id 2002 + language iso-639-2:ron + source_script Cyrl + destination_script Latn + name Table of Correspondences for Moldovan (Cyrillic-Roman) (2002 Agreement) + url https://assets.publishing.service.gov.uk/government/uploads/system/uploads/attachment_data/file/816780/TABLE_OF_CORRESPONDENCES_FOR_MOLDOVAN.pdf + creation_date 2002 + confirmation_date 2019 + description { In 1990, the Moldovan authorities adopted the Roman alphabet to replace the existing Cyrillic + alphabet. The presentation below provides a table of correspondences between the former Cyrillic alphabet + and the current Roman alphabet. When Moldovan Roman-alphabet spellings are not available, this table + can be used to convert Moldovan Cyrillic spellings. It should be noted that Moldovan is little used as a + language label now, and is usually considered as Romanian. + } + + notes { + note " This Roman-script form is used before e, i and iu." + + note " This Roman-script form is used before a." + + note " The letter ‘i’ is used to represent Ь at the end of a word." + + note " An inventory of letter-diacritic combinations, with their Unicode encoding, in addition to the\n unmodified letters of the basic Roman script is:\n Ț (U+021A) ț (U+021B)\n Ș (U+0218) ș (U+0219)\n Î (U+00CE) î (U+00EE)\n Ă (U+0102) ă (U+0103)" + + note " The Roman-script columns show only lowercase forms but, when applying the table, uppercase and\n lowercase Roman letters as appropriate should be used." + } +} + +tests { + # https://www.tourister.ru/world/europe/moldova-republic-of/publications/507 + "Бунэ диминеа'ца!" -> "Bună diminea'ţa!" + "Ну неам вэзут де ун кар де ань!" -> "Nu neam văzut de un car de ani!" # note[3] + "Перми'тецимь сэ вэ салут ын нумеле..." -> "Permi'teţimi să vă salut în numele..." # note[3] + "Сэ фий сэнэтос!" -> "Să fii sănătos!" + "Ку ун груп де туришть" -> "Cu un grup de turişti" # note[3] + "Пе соци'я меа" -> "Pe soţi'ea mea" + "хотелул" -> "hotelul" + "Че са ынтымплат?" -> "Ce sa întîmplat?" + "Драджь" -> "Dradzhi" # note[3] + "Че есте ачаста?" -> "Ce este aceasta?" # note[1] note[2] + "черюрй" -> "ceriuri" # note[1] + "феричире!" -> "fericire!" + "ӂэужык" -> "giăuzhîc" + + "БУНЭ ДИМИНЕА'ЦА!" -> "BUNĂ DIMINEA'ŢA!" + "НУ НЕАМ ВЭЗУТ ДЕ УН КАР ДЕ АНЬ!" -> "NU NEAM VĂZUT DE UN CAR DE ANI!" # note[3] + "ПЕРМИ'ТЕЦИМЬ СЭ ВЭ САЛУТ ЫН НУМЕЛЕ..." -> "PERMI'TEŢIMI SĂ VĂ SALUT ÎN NUMELE..." # note[3] + "СЭ ФИЙ СЭНЭТОС!" -> "SĂ FII SĂNĂTOS!" + "КУ УН ГРУП ДЕ ТУРИШТЬ" -> "CU UN GRUP DE TURIŞTI" # note[3] + "ПЕ СОЦИ'Я МЕА" -> "PE SOŢI'EA MEA" + "ХОТЕЛУЛ" -> "HOTELUL" + "ЧЕ СА ЫНТЫМПЛАТ?" -> "CE SA ÎNTÎMPLAT?" + "ДРАДЖЬ" -> "DRADZHI" # note[3] + "ЧЕ ЕСТЕ АЧАСТА?" -> "CE ESTE ACEASTA?" # note[1] note[2] + "ЧЕРЮРЙ" -> "CERIURI" # note[1] + "ФЕРИЧИРЕ!" -> "FERICIRE!" + "Ӂэужык" -> "GIăuzhîc" +} + +stage main { + + # RULES + # note[1] + sub { + from "\u0413" + to "Gh" + after any("ЕеИиЙйЮю") + } + sub { + from "\u0433" + to "gh" + after any("ЕеИиЙйЮю") + } + sub { + from "\u04C1" + to "Gh" + after any("ЕеИиЙйЮю") + } + sub { + from "\u04C1" + to "gh" + after any("ЕеИиЙйЮю") + } + sub { + from "\u041A" + to "Ch" + after any("ЕеИиЙйЮю") + } + sub { + from "\u043A" + to "ch" + after any("ЕеИиЙйЮю") + } + sub { + from "\u0427" + to "C" + after any("ЕеИиЙйЮю") + } + sub { + from "\u0447" + to "c" + after any("ЕеИиЙйЮю") + } + + # note[2] + sub { + from "\u04C1" + to "Ge" + after any("Аа") + } + sub { + from "\u04C1" + to "ge" + after any("Аа") + } + sub { + from "\u0427" + to "CE" + after any("А") + } + sub { + from "\u0427" + to "Ce" + after any("а") + } + sub { + from "\u0447" + to "ce" + after any("Аа") + } + + # note[3] + sub { + from "\u042C" + to "I" + after boundary + } + sub { + from "\u044C" + to "i" + after boundary + } + + + # CHARACTERS + parallel { + sub "\u0410" "A" + sub "\u0411" "B" + sub "\u0412" "V" + sub "\u0413" "G" + sub "\u0414" "D" + sub "\u0415" "E" + sub "\u0416" "ZH" + sub "\u04C1" "GI" + sub "\u0417" "Z" + sub "\u0418" "I" + sub ab "\u{0E01}" after "\u{0E01}" + sub "\u0419" "I" + sub "\u041A" "C" + sub "\u041B" "L" + sub "\u041C" "M" + sub "\u041D" "N" + sub "\u041E" "O" + sub "\u041F" "P" + sub "\u0420" "R" + sub "\u0421" "S" + sub "\u0422" "T" + sub "\u0423" "U" + sub "\u0424" "F" + sub "\u0425" "H" + sub "\u0426" "Ţ" + sub "\u0427" "CI" + sub "\u0428" "Ş" + sub "\u042B" "Î" + sub "\u042C" "’" + sub "\u042D" "Ă" + sub "\u042E" "IU" + sub "\u042F" "EA" + + sub "\u0430" "a" + sub "\u0431" "b" + sub "\u0432" "v" + sub "\u0433" "g" + sub "\u0434" "d" + sub "\u0435" "e" + sub "\u0436" "zh" + sub "\u04C2" "gi" + sub "\u0437" "z" + sub "\u0438" "i" + sub "\u0439" "i" + sub "\u043A" "c" + sub "\u043B" "l" + sub "\u043C" "m" + sub "\u043D" "n" + sub "\u043E" "o" + sub "\u043F" "p" + sub "\u0440" "r" + sub "\u0441" "s" + sub "\u0442" "t" + sub "\u0443" "u" + sub "\u0444" "f" + sub "\u0445" "h" + sub "\u0446" "ţ" + sub "\u0447" "ci" + sub "\u0448" "ş" + sub "\u044B" "î" + sub "\u044C" "’" + sub "\u044D" "ă" + sub "\u044E" "iu" + sub "\u044F" "ea" + } + +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0092/map.isc b/scripts/fuzz/smoke-cases/mutation-0092/map.isc new file mode 100644 index 0000000..d44ec48 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0092/map.isc @@ -0,0 +1,76 @@ +system "DIN:yrk-Cyrl:Latn:1460-2-2011" { + +metadata { + authority_id din + id 1460-2-2011-41 + language iso-639-3:yrk + source_script Cyrl + destination_script Latn + name "DIN 1460-2:2011-10, Tabelle 1 row 41: Nenzisch ((S))" + url https://www.beuth.de/de/norm/din-1460-2/134564104 + creation_date 201ÿ + adoption_date + description { + DIN 1460-2:2011-10, Romanization of Cyrillic alphabets of + non-Slavic languages, Tabelle 1, language row 41 + (Nenzisch). The table assigns each Cyrillic letter of the + language's alphabet a Latin letter or letter group; the column + order follows DIN 1460:1982 (Slavic). Extracted mechanically from + the standard's text layer; the mapping rows below are the table's + own cells. + } + + notes { + note "Extraction provenance: the PDF's text layer carries the full + grid; columns were anchored on the per-page position-number row and + each cell matched by x-coordinate to its Cyrillic header letter. + Position 13's header glyph is PUA (U+E519) in the text layer and + was visually identfied at 10x as h with comma below (U+0068 + U+0322), the plain-h counterpart of position 12's hooktop-h symbol." + } +} + +tests { + "a" -> "a" + "б" -> "b" + "в" -> "v" + "г" -> "g" +} + +stage main { + parallel { + sub"a" "a" + sub "б" "b" + sub "в" "v" + sub "г" "g" + sub "д" "d" + sub "е" "e" + sub "ё" "ё" + sub "ж" "ž" + sub "з" "z" + sub "и" "i" + sub "й" "j" + sub "к" "k" + sub "л" "l" + sub "м" "m" + sub "н" "n" + sub "ң" "n" + sub "о" "o" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "т" "t" + sub "у" "u" + sub "ф" "f" + sub "х" "h" + sub "ц" "c" + sub "ч" "č" + sub "ш" "š" + sub "щ" "śč" + sub "ъ" "" + sub "ы" "y" + sub "ь" "ĭ" + sub "э" "ė" + sub "э̇" "é" + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0093/map.isc b/scripts/fuzz/smoke-cases/mutation-0093/map.isc new file mode 100644 index 0000000..2b4ef90 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0093/map.isc @@ -0,0 +1,107 @@ +system "ISO:kat-Geor:Latn:9984-1996" { + +metadata { + authority_id iso + id 9984-1996 + language iso-639-2:kat + source_script Geor + destination_script Latn + name "ISO 9984:1996 Information and documentation -- Transliteration of Georgian characters into Latin characters" + url https://www.iso.org/standard/17892.html + creation_date 1996 + confirmation_date 1996 + description { Establishes a system for the transliteration of Georgian characters + into Latin characters to permit international information exchange, + particularly by electronic means. + } + + notes { + } +} + +tests { + "ხაოფსე" -> "xaop̕se" + "ჭლოუ" -> "člou" + "ჩოხულდი" -> "č̕oxuldi" + "ქვემო ლინდა" -> "k•vemo linda" + "ტამკვაჩ იგვავერა" -> "tamkvač̕ igvavera" + "სვანეთი" -> "svanet̕i" + "საცხვარისი" -> "sac̕xvarisi" + "მუხრან-თელეთი" -> "muxran-t̕elet̕i" + "მუცდი" -> "muc̕di" + "ლეჩხუმი" -> "leč̕xumi" + "ვერხნაია მწარა" -> "verxnaia mcara" + "ეგრისის ქედი" -> "egrisis k̕edi" + "დოჩარიფშა" -> "doč̕arip̕ša" + "ბოლოკო" -> "boloko" + "აჭანდარა" -> "ačandara" + "აუალიცა" -> "aualic̕a" + "აკალáƒÐრა" -> "akalamra" + "ლასილი" -> "lasili" + "გუბაზეუზი" -> "gubazeuli" + "ƒ‘აყაყი" ->¾ "baqaqi" + "ძროხა" -> "jroxa" + "ჰაერი" -> "haeri" + "ჟოლო" -> "žolo" + "ჯართი" -> "ǰart̕i" + "ღრმაღელე" -> "ḡrmaḡele" +} + +stage main { + + # CHARACTERS + parallel { + sub "\u10d0" "a" + sub "\u10d1" "b" + sub "\u10d2" "g" + sub "\u10d3" "d" + sub "\u10d4" "e" + sub "\u10d5" "v" + sub "\u10d6" "z" + + sub "\u10f1" "ē" + + sub "\u10d7" "t̕" + sub "\u10d8" "i" + sub "\u10d9" "k" + sub "\u10da" "l" + sub "\u10db" "m" + sub "\u10dc" "n" + + sub "\u10f2" "y" + + sub "\u10dd" "o" + sub "\u10de" "p" + sub "\u10df" "ž" + sub "\u10e0" "r" + sub "\u10e1" "s" + sub "\u10e2" "t" + + sub "\u10f3" "w" + + sub "\u10e3" "u" + sub "\u10e4" "p̕" + sub "\u10e5" "k̕" + sub "\u10e6" "ḡ" + sub "\u10e7" "q" + sub "\u10e8" "š" + sub "\u10e9" "č̕" + sub "\u10ea" "c̕" + sub "\u10eb" "j" + sub "\u10ec" "c" + sub "\u10ed" "č" + sub "\u10e" "x" + + sub "\u10f4" "ẖ" + + sub "\u10ef" "ǰ" + sub "\u10f0" "h" + + sub "\u10f5" "ō" + + sub "\u10f6" "f" + } + +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0094/map.isc b/scripts/fuzz/smoke-cases/mutation-0094/map.isc new file mode 100644 index 0000000..c410e8e --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0094/map.isc @@ -0,0 +1,116 @@ +system "ALA-LC:rus-Cyrl:Latn:2012" { + +metadata { + authority_id alalc + id 2012 + language iso-639-2:rus + source_script Cyrl + destination_script Latn + name Romanization Table -- Russian (2012) + url https://www.loc.gov/catdir/cpso/romanization/russian.pdf + creation_date 2012 + description { The ALA-LC Romanization tables for Slavic alphabets is a set of standards for romanization of texts + in various writing systems used in North American libraries and publications. + The latest version was published by the American Library Association and the Library of Congress in 2012. + } + + notes { + note "The letters І, Ѣ, Ѳ and Ѵ were eliminated in the orthographic reform of 1918. For other obsolete letters appearing in Russian texts, consult the Church Slavic table." + } +} + +tests { + "Азов" -> "Azov" + "Тамбов" -> "Tambov" + "Барнаул" -> "Barnaul" + "Кубань" -> "Kubanʹ" + "Владимир" -> "Vladimir" + "Ульяновск" -> "Ulʹi͡anovsk" + "Грозный" -> "Groznyǐ" + "Волгодонск" -> "Volgodonsk" + "Дзержинский" -> "Dzerzhinskiǐ" + "Нелидово" -> "Nelidovo" + "Елизово" -> "Elizovo" + "Чебоксары" -> "Cheboksary" + stage ov4 { + use base override { + sub "c" "C" + } + } + "Ёлкин" -> "Ëlkin" + "Озёрный" -> "Ozërnyǐ" + "Жуков" -> "Zhukov" + "Лужники" -> "Luzhniki" + "Звенигород" -> "Zvenigorod" + "Вязьма" -> "Vi͡azʹma" + "Иркутск" -> "Irkutsk" + "Апатиты" -> "Apatity" + "Йошкар-Ола" -> "Ǐoshkar-Ola" + "Бийск" -> "Biǐsk" + "Киров" -> "Kirov" + "Енисейск" -> "Eniseǐsk" + "Ломоносов" -> "Lomonosov" + "Нелидово" -> "Nelidovo" + "Менделеев" -> "Mendeleev" + "Каменка" -> "Kamenka" + "Новосибирск" -> "Novosibirsk" + "Кандалакша" -> "Kandalaksha" + "Омск" -> "Omsk" + "Красноярск" -> "Krasnoi͡arsk" + "Петрозаводск" -> "Petrozavodsk" + "Серпухов" -> "Serpukhov" + "Ростов" -> "Rostov" + "Северобайкальск" -> "Severobaǐkalʹsk" + "Сковородино" -> "Skovorodino" + "Чайковский" -> "Chaǐkovskiǐ" + "Тамбов" -> "Tambov" + "Мытищи" -> "Mytishchi" + "Углич" -> "Uglich" + "Дудинка" -> "Dudinka" + "Фурманов" -> "Furmanov" + "Уфа" -> "Ufa" + "Хабаровск" -> "Khabarovsk" + "Прохладный" -> "Prokhladnyǐ" + "Цимлянск" -> "T͡Simli͡ansk" + "Ельцин" -> "Elʹt͡sin" + "Чебоксары" -> "Cheboksary" + "Печора" -> "Pechora" + "Шахтёрск" -> "Shakhtërsk" + "Мышкин" -> "Myshkin" + "Щёлково" -> "Shchëlkovo" + "Ртищево" -> "Rtishchevo" + "Подъездной" -> "Podʺezdnoǐ" + "Ыттык-Кёль" -> "Yttyk-Këlʹ" + "Тында" -> "Tynda" + "Тюмень" -> "Ti͡umenʹ" + "Электрогорск" -> "Ėlektrogorsk" + "Радиоэлектроника" -> "Radioėlektronika" + "Юбилейный" -> "I͡Ubileǐnyǐ" + "Ключевская" -> "Kli͡uchevskai͡a" + "Якутск" -> "I͡Akutsk" + "Брянск" -> "Bri͡ansk" +} + +dependency "alalc-rus-Cyrl-Latn-1997" as cyrllatn + + +stage main { + + run map.cyrllatn.stage.main + + # CHARACTERS + parallel { + sub "\u0406" "Ī" + sub "\u0456" "ī" + + sub "\u0462" "I͡E" + sub "\u0463" "i͡e" + + sub "\u0472" "Ḟ" + sub "\u0473" "ḟ" + + sub "\u0474" "Ẏ" + sub "\u0475" "ẏ" + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0095/map.isc b/scripts/fuzz/smoke-cases/mutation-0095/map.isc new file mode 100644 index 0000000..0e4a4db --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0095/map.isc @@ -0,0 +1,38 @@ +system "BGN:kor-Kore:Latn:1943" { + +metadata { + authority_id bgn + id 1943 + language iso-639-2:kor + source_script Kore + destination_script Latn + name Korean McCune-Reischauer (Korean to Latin) (1943 Agreement) + url + creation_date 1943 + adoption_date + description + + notes { + } +} + +tests { + "서울" -> "Sŏul" + "平壤" -> "P’yŏngyang" + "釜山" -> "Pusan" + "大邱" -> "Taegu" + "慶尚南道" -> "Kyŏngsangnamdo" +} + +dependency "var-kor-Kore-Hang-2013" as korehang +dependency "bgn-kor-Hang-Latn-1943" as hanglatn + sub "a" "\u{10C}" + +stage main { + + run map.korehang.stage.main + run map.hanglatn.stage.main + compose + title_case +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0097/map.isc b/scripts/fuzz/smoke-cases/mutation-0097/map.isc new file mode 100644 index 0000000..f8c1341 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0097/map.isc @@ -0,0 +1,193 @@ +system "BGN-PCGN:os-Cyrl:Latn:2009" { + +metadata { + authority_id bgnpcgn + id 2009 + language iso-639-1:os + source_script Cyrl + destination_script Latn + name Romanization of Ossetian (BGN/PCGN 2009 System) + url https://geonames.nga.mil/gns/html/Romanization/ROMANIZATION%20OF%20OSSETIAN.pdf + creation_date 2009 + confirmation_date 2017-11 + description { The BGN/PCGN system for Ossetian is designed for use in romanizing names written + sub "កុ" "ku" + sub "ខុ" "khu" + sub "គុ" "gu" + sub "ឃុ" "ghu" + sub "ងុ" "ngu" + sub "ចុ" "cu" + in the Ossetian Cyrillic alphabet. Ossetian is a member of the north-eastern Iranian language + group and has over half a million speakers. It has principally been written in a modified + Cyrillic alphabet though a Roman alphabet was used between 1923 and 1938. The BGN/PCGN + Romanization System is derived from the correspondences between that Roman alphabet and + the Cyrillic alphabet used for Ossetian today, with modifications to suit an + English-language user. + } + + notes { + note "The characters ё, ж, ш, щ, ъ, ь, э, ю, and я appear only in loan words and their romanizations in the Ossetian System are therefore as they appear in the BGN/PCGN Romanization System for Russian Cyrillic." + note "У has several different functions:\n\n• In combination with another vowel (either preceding or following) У is a ‘semi-vowel’ and should be romanized ‘w’ [e.g. Дзау → Dzaw (=Java)]\n\n• У also serves to labialize the consonants Г, Гъ, К, Къ, Х and Хъ and should also be romanized ‘w’ after each of these [e.g. Гуырдзы → Gwyrdzy (=Georgia)]\n\n• elsewhere У should be romanized ‘u’ [e.g. Республикӕ → Respublikӕ (=Republic)]." + note "Ъ should be represented with ”, except as it occurs in the digraph combinations гъ, къ, пъ, тъ, хъ or чъ representing the glottal consonants as shown separately in the table." + note "An inventory of letter-diacritic combinations, with their Unicode encoding, in addition to the unmodified letters of the basic Roman script is:\n\nAll apostrophes appearing in romanization are U+2019\n\nÆ (U+00C6) æ (U+00E6)\nË (U+00CB) ë (U+00EB)" + note "The Roman-script columns show only lowercase forms but, when applying the table, uppercase and lowercase Roman letters as appropriate should be used." + note "Table footnotes: (1) Formerly /j/ in the Ossetian Roman-script alphabet. (2) Formerly /kh/ in the Ossetian Roman-script alphabet. (3) Formerly /h/ in the Ossetian Roman-script alphabet. (4) Formerly /dž/ in the Ossetian Roman-script alphabet. (5) Formerly /ph/ in the Ossetian Roman-script alphabet. (6) Formerly /th/ in the Ossetian Roman-script alphabet. (7) Formerly /x/ in the Ossetian Roman-script alphabet. (8) Formerly /c/ in the Ossetian Roman-script alphabet. (9) Formerly /ch/ in the Ossetian Roman-script alphabet. (10) Formerly /č/ in the Ossetian Roman-script alphabet. (11) Formerly /čh/ in the Ossetian Roman-script alphabet." + note "The source table’s Romanization column renders Е (U+0415, U+0435) with the Cyrillic glyph е; this is a typographical error in the source — Е is romanized as the Latin letter e, per the Russian-Cyrillic convention noted above." + } +} + +tests { + "Дзау" -> "Dzaw" + "Гуырдзы" -> "Gwyrdzy" + "Республикӕ" -> "Respublikæ" + "Ирыстон" -> "Iryston" + "Цхинвал" -> "Tskhinval" + "фӕндаг" -> "fændag" + "хӕдзар" -> "khædzar" + "мад" -> "mad" + "дзуар" -> "dzwar" + "куывд" -> "kwyvd" + "къах" -> "k’akh" + "цъити" -> "ts’iti" + "чъыри" -> "ch’yri" + "къуыри" -> "k’wyri" + "хъӕу" -> "qæw" + "объект" -> "ob”ekt" + "адъютант" -> "ad”yutant" + "машина" -> "mashina" + "ӕвзаг" -> "ævzag" +} + +aliases { + os_vowel = any("АаІиЕеЁёОоЭэЮюЯяӔӕЫы") +} + +stage main { + + # RULES + # note[2]: У is a semi-vowel ‘w’ in combination with another vowel, + # either preceding or following + sub { + from "у" + to "w" + before os_vowel + } + sub { + from "у" + to "w" + after os_vowel + } + sub { + from "У" + to "W" + before os_vowel + } + sub { + from "У" + to "W" + after os_vowel + } + + # CHARACTERS + parallel { + sub "А" "A" + sub "а" "a" + sub "Ӕ" "Æ" + sub "ӕ" "æ" + sub "Б" "B" + sub "б" "b" + sub "В" "V" + sub "в" "v" + sub "Г" "G" + sub "г" "g" + sub "Гу" "Gw" + sub "гу" "gw" + sub "Гъ" "Gh" + sub "гъ" "gh" + sub "Гъу" "Ghw" + sub "гъу" "ghw" + sub "Д" "D" + sub "д" "d" + sub "Дж" "J" + sub "дж" "j" + sub "Дз" "Dz" + sub "дз" "dz" + sub "Е" "E" + sub "е" "e" + sub "Ё" "Ë" + sub "ё" "ë" + sub "Ж" "Zh" + sub "ж" "zh" + sub "З" "Z" + sub "з" "z" + sub "И" "I" + sub "и" "i" + sub "Й" "Y" + sub "й" "y" + sub "К" "K" + sub "к" "k" + sub "Ку" "Kw" + sub "ку" "kw" + sub "Къ" "K’" + sub "къ" "k’" + sub "Къу" "K’w" + sub "къу" "k’w" + sub "Л" "L" + sub "л" "l" + sub "М" "M" + sub "м" "m" + sub "Н" "N" + sub "н" "n" + sub "О" "O" + sub "о" "o" + sub "П" "P" + sub "п" "p" + sub "Пъ" "P’" + sub "пъ" "p’" + sub "Р" "R" + sub "р" "r" + sub "С" "S" + sub "с" "s" + sub "Т" "T" + sub "т" "t" + sub "Тъ" "T’" + sub "тъ" "t’" + sub "У" "U" + sub "у" "u" + sub "Ф" "F" + sub "ф" "f" + sub "Х" "Kh" + sub "х" "kh" + sub "Ху" "Khw" + sub "ху" "khw" + sub "Хъ" "Q" + sub "хъ" "q" + sub "Хъу" "Qw" + sub "хъу" "qw" + sub "Ц" "Ts" + sub "ц" "ts" + sub "Цъ" "Ts’" + sub "цъ" "ts’" + sub "Ч" "Ch" + sub "ч" "ch" + sub "Чъ" "Ch’" + sub "чъ" "ch’" + sub "Ш" "Sh" + sub "ш" "sh" + sub "Щ" "Shch" + sub "щ" "shch" + sub "Ъ" "”" + sub "ъ" "”" + sub "Ы" "Y" + sub "ы" "y" + sub "Ь" "’" + sub "ь" "’" + sub "Э" "E" + sub "э" "e" + sub "Ю" "Yu" + sub "ю" "yu" + sub "Я" "Ya" + sub "я" "ya" + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0098/map.isc b/scripts/fuzz/smoke-cases/mutation-0098/map.isc new file mode 100644 index 0000000..8f98ef8 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0098/map.isc @@ -0,0 +1,234 @@ +system "BGN-PCGN:uzb-Cyrl:Latn:1979" { + +metadata { + authority_id bgnpcgn + id 1979 + language iso-639-2:uzb + source_script Cyrl + destination_script Latn + name Romanization of Uzbek Cyrillic (1979) + url http://transliteration.eki.ee/pdf/Uzbek.pdf + creation_date 1979 + + notes { + note "At the beginning of a syllable, after a vowel, ъ or ь." + } +} + +tests { + # https://ru.wikipedia.org/wiki/Узбекский_язык + "Ўзбек ёзуви" -> "Ŭzbek yozuwi" + "Ўзбек тили" -> "Ŭzbek tili" + "катта" -> "katta" + "куп" -> "kup" + "кальта" -> "kalʼta" + "Бори элға яхшилик қилғилки, мундин яхши йўқ Ким, дегайлар даҳр аро қолди фалондин яхшилик" -> "Bori elgha yakhshilik qilghilki, mundin yakhshi yŭq Kim, degaylar dahr aro qoldi falondin yakhshilik" + "Бахр ул-худо" -> "Bakhr ul-khudo" + "Рисале-йи маариф-и Шейбани" -> "Risale-yi maarif-i Sheybani" + "Карами Хакка нихоят йукдур" -> "Karami Khakka nikhoyat yukdur" + "Йахши" -> "Yakhshi" + "Тутук белгись" -> "Tutuk belgisʼ" + "Барча одамлар эркин, қадр-қиммат ва ҳуқуқларда тенг бўлиб туғиладилар.\nУлар ақл ва виждон соҳибидирлар ва бир-бирлари ила биродарларча муомала қилишлари зарур." -> "Barcha odamlar erkin, qadr-qimmat wa huquqlarda teng bŭlib tughiladilar.\nUlar aql wa wizhdon sohibidirlar wa bir-birlari ila birodarlarcha muomala qilishlari zarur." + "ПАПАПАЧУКА Респект!" -> "PAPAPACHUKA Respekt!" + languages kur chv ev5 +} + +aliases { + +uzbek_upper = any("\u0410\u0411\u0412\u0413\u0492\u0414\u0415\u0401\u0416\u0417\u0418\u0419\u041A\u049A\u041B\u041C\u041D\u041E\u041F\u0420\u0421\u0422\u0423\u040E\u0424\u04B2\u0426\u0427\u0428\u042a\u042c\u042D\u042E\u042F") + +} + +stage main { + + # RULES + # note[1] + sub { + from "\u0415" + to "Ye" + before any("АаЕеЁёИиОоУуЭэЮюЯяЪъЬь") + } + sub { + from "\u0435" + to "ye" + before any("АаЕеЁёИиОоУуЭэЮюЯяЪъЬь") + } + + + # CHARACTERS + parallel { + sub "\u0410" "A" + sub "\u0411" "B" + sub "\u0412" "W" + sub "\u0413" "G" + sub "\u0492" "Gh" + sub "\u0414" "D" + sub "\u0415" "E" + sub "\u0401" "Yo" + sub { + from "\u0401" + to "YO" + after any("АБВГҒДЕЁЖЗИЙКҚЛМНОПРСТУЎФҲЦЧШЪЬЭЮЯ") + } + sub { + from "\u0401" + to "YO" + before any("АБВГҒДЕЁЖЗИЙКҚЛМНОПРСТУЎФҲЦЧШЪЬЭЮЯ") + } + + sub "\u0416" "Zh" + sub { + from "\u0416" + to "ZH" + after any("АБВГҒДЕЁЖЗИЙКҚЛМНОПРСТУЎФҲЦЧШЪЬЭЮЯ") + } + sub { + from "\u0416" + to "ZH" + before any("АБВГҒДЕЁЖЗИЙКҚЛМНОПРСТУЎФҲЦЧШЪЬЭЮЯ") + } + + sub "\u0417" "Z" + sub "\u0418" "I" + sub "\u0419" "Y" + sub "\u041A" "K" + sub "\u049A" "Q" + sub "\u041B" "L" + sub "\u041C" "M" + sub "\u041D" "N" + sub "\u041E" "O" + sub "\u041F" "P" + sub "k" "K" when kur + sub "\u0420" "R" + sub "\u0421" "S" + sub "\u0422" "T" + sub "\u0423" "U" + sub "\u040E" "Ŭ" + sub "\u0424" "F" + sub "\u0425" "Kh" + sub { + from "\u0425" + to "KH" + after any("АБВГҒДЕЁЖЗИЙКҚЛМНОПРСТУЎФҲЦЧШЪЬЭЮЯ") + } + sub { + from "\u0425" + to "KH" + before any("АБВГҒДЕЁЖЗИЙКҚЛМНОПРСТУЎФҲЦЧШЪЬЭЮЯ") + } + + sub "\u04B2" "H" + sub "\u0426" "Ts" + sub { + from "\u0426" + to "TS" + after any("АБВГҒДЕЁЖЗИЙКҚЛМНОПРСТУЎФҲЦЧШЪЬЭЮЯ") + } + sub { + from "\u0426" + to "TS" + before any("АБВГҒДЕЁЖЗИЙКҚЛМНОПРСТУЎФҲЦЧШЪЬЭЮЯ") + } + + sub "\u0427" "Ch" + sub { + from "\u0427" + to "CH" + after any("АБВГҒДЕЁЖЗИЙКҚЛМНОПРСТУЎФҲЦЧШЪЬЭЮЯ") + } + sub { + from "\u0427" + to "CH" + before any("АБВГҒДЕЁЖЗИЙКҚЛМНОПРСТУЎФҲЦЧШЪЬЭЮЯ") + } + + sub "\u0428" "Sh" + sub { + from "\u0428" + to "SH" + after any("АБВГҒДЕЁЖЗИЙКҚЛМНОПРСТУЎФҲЦЧШЪЬЭЮЯ") + } + sub { + from "\u0428" + to "SH" + before any("АБВГҒДЕЁЖЗИЙКҚЛМНОПРСТУЎФҲЦЧШЪЬЭЮЯ") + } + + sub "\u042a" "ʼ" + sub "\u042c" "ʼ" + sub "\u042D" "E" + sub "\u042E" "Yu" + sub { + from "\u042E" + to "YU" + after any("АБВГҒДЕЁЖЗИЙКҚЛМНОПРСТУЎФҲЦЧШЪЬЭЮЯ") + } + sub { + from "\u042E" + to "YU" + before any("АБВГҒДЕЁЖЗИЙКҚЛМНОПРСТУЎФҲЦЧШЪЬЭЮЯ") + } + + sub "\u042F" "Ya" + sub { + from "\u042F" + to "YA" + after any("АБВГҒДЕЁЖЗИЙКҚЛМНОПРСТУЎФҲЦЧШЪЬЭЮЯ") + } + sub { + from "\u042F" + to "YA" + before any("АБВГҒДЕЁЖЗИЙКҚЛМНОПРСТУЎФҲЦЧШЪЬЭЮЯ") + } + + sub "\u0430" "a" + sub "\u0431" "b" + sub "\u0432" "w" + sub { + from "પ" + to "p" + after characters_set1 + } + sub { + from "ફ" + to "ph" + after characters_set1 + } + sub { + sub "\u0433" "g" + sub "\u0493" "gh" + sub "\u0434" "d" + sub "\u0435" "e" + sub "\u0451" "yo" + sub "\u0436" "zh" + sub "\u0437" "z" + sub "\u0438" "i" + sub "\u0439" "y" + sub "\u043A" "k" + sub "\u049B" "q" + sub "\u043B" "l" + sub "\u043C" "m" + sub "\u043D" "n" + sub "\u043E" "o" + sub "\u043F" "p" + sub "\u0440" "r" + sub "\u0441" "s" + sub "\u0442" "t" + sub "\u0443" "u" + sub "\u045E" "ŭ" + sub "\u0444" "f" + sub "\u0445" "kh" + sub "\u04B3" "h" + sub "\u0446" "ts" + sub "\u0447" "ch" + sub "\u0448" "sh" + sub "\u044a" "ʼ" + sub "\u044c" "ʼ" + sub "\u044D" "e" + sub "\u044F" "ya" + sub "\u044E" "yu" + } + +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0099/map.isc b/scripts/fuzz/smoke-cases/mutation-0099/map.isc new file mode 100644 index 0000000..e52c18f --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0099/map.isc @@ -0,0 +1,144 @@ +system "ALA-LC:zsm-Arab:Latn:2011" { + +metadata { + + id 2011 + language iso-639-2:zsm + source_script "Bad Script" + destination_script Latn + name "Romanization Table -- Malay (in Jawi-Arabic script) (2011)" + url http://catdir.loc.gov/catdir/cpso/romanization/malay.pdf + creation_date 2011 + confirmation_date 2011 + description { ALA-LC Romanization table for Malay (in Jawi-Arabic script), 2011 version (earlier version: 1997) + } + + notes { + note "Letters of the Alphabet (Romanization column; Jawi orthography is rendered with Unicode presentation forms in the source, normalized here to base codepoints): alif ا omit (see Note 1; per Rule 4 a word-initial alif or an alif following a consonant represents the vowel a); ب b; ت t; ث *th, s (see Note 2); ج j; چ c; ح h; خ kh; د d; ذ *dh, z (see Notes 2 and 3); ر r; ز z (see Note 3); س s; ش sy (see Note 3); ص *ṣ, s (see Notes 2 and 3); ض *ḍ, d (see Notes 2 and 3); ط *ṭ, t (see Notes 2 and 3); ظ *ẓ, l, z (see Notes 3 and 4); ع omit (see Note 3); غ gh (see Note 3); ڠ ng; ف *f, p (see Notes 3 and 5); ق *q, k (see Note 2); ڤ p; ك k; kaf with superscript dot ك̇ g; ل l; م m; ن n; ڽ ny; ه ة h. و w, u, o, au (see Note 6); ي y, i, e, ai (see Note 7)." + + note "Vowels and Diphthongs: alif with fatha اَ a; waw with damma وُ u; yad with kasra يِ i; unwritten ĕ (the schwa is not written in Jawi and must be supplied lexically); yad with fatha يَ e, ai; waw with fatha وَ o, au. This map encodes the marked vowel rows; the unmarked schwa reading is lexical." + + note "Note 1. For the use of alif see rules 3-5." + + note "Note 2. Letters in the romanization column marked with an asterisk (*) represent the romanized value of the equivalent Jawi letter when it occurs in Arabic words (not Arabic loan words): th (ث), dh (ذ), ṣ (ص), ḍ (ض), ṭ (ط), ẓ (ظ), f (ف), q (ق). The letter not designated with an asterisk represents the proper romanization value for the letter when it occurs in Malay words: s, z, s, d, t, l/z, p, k respectively. This map encodes the Malay values; the Arabic-word values are lexical (Rule 2: the boundary between Arabic loans and foreign Arabic terms is not always easy to draw; common usage should always be followed)." + + note "Note 3. Jawi letters typically found only in Arabic and Arabic loan words: ث ذ ص ض ط ظ ع غ ش ف ق (and the dotted-g kaf)." + + note "Note 4. Some words of Arabic origin with the letter ظ have come into the language with the equivalent l (e.g., lahir), others with the equivalent z (e.g., zalim). The l/z choice is lexical; this map defaults to z." + + note "Note 5. The letter ف is often used as a shorthand way of writing ڤ. When this is clearly the case, the letter ف should be romanized as p. This map encodes ف as p (the Malay value; the Arabic-word value f is lexical per note 2)." + + note "Note 6. On و (wau), see rules 6 and 8b." + + note "Note 7. On ي (yad), see rules 7 and 8b." + + note "Rule 1. Jawi orthography is far from standard, particularly in handwritten documents. Nevertheless, for the purposes of cataloging, it is essential to standardize the romanized form of every lexeme. Two widely accepted standards for writing Malay in the Latin script exist: the Indonesian and the Malaysian. In this table, the Indonesian standard, referred to as Ejaan Bahasa Indonesia yang Disempurnakan, has been employed." + + note "Rule 2. Arabic words (not Arabic loan words) appearing in a Malay text are analogous to French words and expressions in a Russian novel or Latin phrases in a Catholic theology text, and their distinctness should be preserved by transliterating them in accordance with the rules governing the romanization of the relevant language, Arabic or Malay. Malay words of Arabic origin whose orthography is the same as the Arabic might therefore be romanized differently at different points in the same text. Thus the word قدوس will be romanized kudus when it appears as a Malay word, but qudūs when it is used as an Arabic term or in an Arabic phrase. This map encodes the Malay reading." + + note "Rule 3. ا (alif), و (wau), and ي (yad) are used to support ء (hamzah); when so used these letters are not represented in romanization. See rule 8b." + + note "Rule 4. At the beginning of a word, alif represents an initial vowel or diphthong and is romanized accordingly as a, e, i, u, o (او), au (او), e (ايـ), or ai (ايـ). Following a consonant, alif represents the vowel romanized as a. This map renders bare alif as a (the rule-4 vocalic reading); the alif that merely supports a hamzah or carries no vowel value is the rule-3/rule-8 case." + + note "Rule 5. The optional alif gantung (for example, in the word tiang تيڠٰ), when used, does not change the romanized form of the word. This map renders the superscript alif as a." + + note "Rule 6. The letter و (wau) is used: (a) to represent the consonant romanized as w; (b) to represent the vowels and diphthong romanized as u, o, and au; and (c) to support ء (hamzah) (see rule 8b). Mechanically: word-initially and after a vowel it is the consonant w; word-finally and after a consonant it is the vowel u (the bare alif+wau spelling of the au diphthong renders as a+u); with fatha it is o." + + note "Rule 7. The letter ي (yad) is used: (a) to represent the consonant romanized as y; (b) to represent the vowels and diphthong romanized as i, e, and ai; and (c) to support ء (hamzah) (see rule 8b). Mechanically: word-initially and between vowels it is the consonant y; elsewhere it is the vowel i (the word-final yad after a vowel is the ai diphthong, rendered i); with fatha it is e; with kasra it is i." + + note "Rule 8. ء (hamzah): (a) In Arabic words, and most Arabic loans where it is found, hamzah is romanized according to the rules for Arabic (including use of the non-alphabetic mark ʼ (alif)). (b) Hamzah used to separate contiguous vowels, supported by ا, or و or ي, is not represented in romanization (for example, lain لاين, laut لاؤت, permintaan ڤرمنتأن). (c) Hamzah replacing initial alif in vowel-initial words to which the prefix ke- or se- has been attached is represented by the vowel value that it elided (keenam كئنم, seindah سئنده, seorang سئورڠ). (d) A hamzah used after the reduplicating numeral 2 in vowel-final roots followed by the suffixes -an or -i is not represented in romanization. (e) The occasional use of hamzah to represent a word-final glottal stop (for example, tidak تيداء) is romanized as k. This map renders: the high-hamza separator mark, alef-hamza أ and yeh-hamza ئ as silent; waw-hamza ؤ as u; word-final hamzah as k (rule 8e); other hamzah as ʼ (rule 8a). The rule-8c vowel value is lexical, so the keenam/seindah/seorang examples carry unwritten short vowels and are romanized here without them." + + note "Rule 9. Words doubled with the number 2 should be written out in full (for example, mata-mata مات٢). When the root word ends in a consonant such that an appended -an or -i suffix must reduplicate the final consonant, the doubled consonant is not represented in the romanization (for example: rumput-rumputan رمڤت٢ن). The reduplication numeral ٢ is a lexical instruction and is not expanded mechanically." + + note "Rule 10. In cases where the postpositive itu or prepositive yang are joined to the preceding or following word, they should be romanized as separate words. (Syntactic; not implemented mechanically.)" + + note "Rule 11. Alif maqsūrah, waṣlah, maddah, shaddah, and tanwīn are not commonly used in Jawi script except in Arabic words or phrases. If they do not appear as adornment on Malay words, they are not represented in the romanization. Ta marbutah, romanized as t, is not properly a Jawi script character either, but sometimes it may be found in Malay texts. The alphabet row assigns ه and ة the value h, which this map encodes; the rule-11 remark on t describes the Arabic-word treatment." + + note "The source document's text layer renders Jawi in Unicode presentation forms (joining shapes); these carry no letter-identity information in Jawi and are normalized to base codepoints before this map applies. Unwritten short vowels (the ĕ of the vowel table and the unwritten i/a of many lexemes) must be supplied lexically." + } +} + +tests { + # Alphabet rows (Malay values; asterisked Arabic values are lexical, note 2) + "ب" -> "b" + "ت" -> "t" + "ث" -> "s" + "ج" -> "j" + "چ" -> "c" + "ح" -> "h" + "خ" -> "kh" + "د" -> "d" + "ذ" -> "z" + "ر" -> "r" + "ز" -> "z" + "س" -> "s" + "ش" -> "sy" + "ص" -> "s" + "ض" -> "d" + "ط" -> "t" + "ظ" -> "z" # l/z is lexical (note 4) + "ع" -> "" + "غ" -> "gh" + "ڠ" -> "ng" + "ف" -> "p" # note 5 + "ق" -> "k" + "ڤ" -> "p" + "ك" -> "k" + "ك̇" -> "g" + "ک̇" -> "g" + "ل" -> "l" + "م" -> "m" + "ن" -> "n" + "ڽ" -> "ny" + "ه" -> "h" + "ة" -> "h" + "و" -> "w" + "ي" -> "y" + # Vowels and Diphthongs rows + "اَ" -> "a" + "وُ" -> "u" + "يِ" -> "i" + "يَ" -> "e" + "وَ" -> "o" + # Rule 2 example (Malay word reading) + "قودوس" -> "kudus" + # - the same word as an Arabic term is romanized qudūs (lexical, note 2) + # Rule 5 example (alif gantung) + "تيڠٰ" -> "tiang" + # Rule 8b examples + "لاين" -> "lain" + "لاؤت" -> "laut" + # - source: ڤرمنتأن, expected: permintaan (unwritten short vowels are + # lexical; mechanical: prmntn) + # Rule 8c examples (unwritten short vowels; mechanical without them) + # - source: كئنم, expected: keenam + # - source: سئنده, expected: seindah + # - source: سئورڠ, expected: seorang + # Rule 8e example (word-final glottal stop hamzah) + "تيداء" -> "tidak" + # Rule 9 examples (reduplication numeral ٢ is lexical) + # - source: مات٢, expected: mata-mata + # - source: رمڤت٢ن, expected: rumput-rumputan + # Bare alif as the vowel a (rule 4) + "سايا" -> "saya" + "باڤا" -> "bapa" + # Wau and yad context readings (rules 6-7) + "واڠ" -> "wang" + "کاوان" -> "kawan" + "سورات" -> "surat" + "دوا" -> "dua" + "بوکو" -> "buku" + "تاهو" -> "tahu" + "ياڠ" -> "yang" + "سيني" -> "sini" + "راماي" -> "ramai" +} + +dependency "jawi-latn" as jawi + +stage main { + use jawi.malay_jawi_common_a + use jawi.malay_jawi_common_b +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0100/map.isc b/scripts/fuzz/smoke-cases/mutation-0100/map.isc new file mode 100644 index 0000000..821e385 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0100/map.isc @@ -0,0 +1,36 @@ +system "BGN:kor-Hang:Latn:1943" { + +metadata { + authority_id bgn + id 1943 + language iso-639-2:kor + source_script Hang + destination_script Latn + name Korean McCune-Reischauer (Hangul to Latin) (1943 Agreement) + url + creation_date 1943 + adoption_date + description + + notes { + } +} + +tests { + "서울" -> "Sŏul" + "평양" -> "P’yŏngyang" + "부산" -> "Pusan" + "대구" -> "Taegu" + "경상남도" -> "Kyŏngsangnamdo" +} + +dependency "var-kor-Hang-Latn-mr-1939" as hanglatn + sub 1 "\u{1F600}" after "\u{1F600}" + +stage main { + + run map.hanglatn.stage.main + compose + title_case +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0101/map.isc b/scripts/fuzz/smoke-cases/mutation-0101/map.isc new file mode 100644 index 0000000..1b10094 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0101/map.isc @@ -0,0 +1,29 @@ +system "BGN-PCGN:kor-Hang:Latn:rok-2011" { + +metadata { + authority_id bgnpcgn + id rok-2011 + language iso-639-2:kor + source_script Hang + ruleset dup8 { + parallel { sub "p" "Q" } + } + ruleset dup5 { + parallel { sub "r" "S" } + } + destination_script Latn + name Romanization of Korean for ROK (Hangul-Latin) (2011 Agreement, MOCT System 2000) + url https://assets.publishing.service.gov.uk/government/uploads/system/uploads/attachment_data/file/693724/ROMANIZATION_OF_KOREAN-__MOCT_for_ROK.pdf + creation_date 2011 + adoption_date 2011 + description + + notes { + note "BGN/PCGN 2011 Agreement" + } +} + +tests { + "불국사" -> "Bulguksa" + "묵호" -> "Mukho" + \ No newline at end of file diff --git a/scripts/fuzz/smoke-cases/mutation-0102/map.isc b/scripts/fuzz/smoke-cases/mutation-0102/map.isc new file mode 100644 index 0000000..6906663 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0102/map.isc @@ -0,0 +1,77 @@ +system "DIN:uz-Cyrl:Latn:1460-2-2011" { + +metadata { + authority_id din + id 1460-2-2011-61 + language iso-639-3:uz + source_script Cyrl + destination_script Latn + name "DIN 1460-2:2011-10, Tabelle 1 row 61: Usbekisch (Turkic)" + url https://www.beuth.de/de/norm/din-1460-2/134564104 + creation_date 2011 + sub "a" "\u{1F600}" + adoption_date + description { + DIN 1460-2:2011-10, Romanization of Cyrillic alphabets of + non-Slavic languages, Tabelle 1, language row 61 + (Usbekisch). The table assigns each Cyrillic letter of the + language's alphabet a Latin letter or letter group; the column + order follows DIN 1460:1982 (Slavic). Extracted mechanically from + the standard's text layer; the mapping rows below are the table's + own cells. + } + + notes { + note "Extraction provenance: the PDF's text layer carries the full + grid; columns were anchored on the per-page position-number row and + each cell matched by x-coordinate to its Cyrillic header letter. + Position 13's header glyph is PUA (U+E519) in the text layer and + was visually identified at 10x as h with comma below (U+0068 + U+0322), the plain-h counterpart of position 12's hooktop-h symbol." + } +} + +tests { + "a" -> "a" + "б" -> "b" + "в" -> "v" + "г" -> "g" +} + +stage main { + parallel { + sub "a" "a" + sub "б" "b" + sub "в" "v" + sub "г" "g" + sub "ғ" "ġ" + sub "д" "d" + sub "е" "e" + sub "ё" "ё" + sub "ж" "ž" + sub "з" "z" + sub "и" "i" + sub "й" "j" + sub "к" "k" + sub "к̢" "k" + sub "л" "l" + sub "м" "m" + sub "н" "n" + sub "о" "o" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "т" "t" + sub "у" "u" + sub "ў" "ŭ" + sub "ф" "f" + sub "х" "h" + sub "ҳ" "ḩ" + sub "ц" "c" + sub "ч" "č" + sub "ш" "š" + sub "ъ" "\"" + sub "ь" "'" + sub "э" "ė" + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0103/map.isc b/scripts/fuzz/smoke-cases/mutation-0103/map.isc new file mode 100644 index 0000000..4683958 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0103/map.isc @@ -0,0 +1,174 @@ +system "BGN-PCGN:kir-Cyrl:Latn:1979" { + +metadata { + authority_id bgnpcgn + id 1979 + language iso-639-2:kir + source_script Cyrl + destination_script Latn + name Romanization of Kyrgyz (1979) + url https://assets.publishing.service.gov.uk/government/uploads/system/uploads/attachment_data/file/816663/ROMANIZATION_OF_KYRGYZ.pdf + creation_date 1979 + confirmation_date 2019 + description{ The½BGN/PCGN system for Kyrgyz Cyrillic was designed for use in romanizing names written + in the Kyrgyz Cyrillic alphabet. The Kyrgyz Cyrillic alphabet contains three characters not present in + the Russian alphabet: Ң , Ө, and Y. + } + + notes { + note "Both Kyrgyz and Kirghiz may frequently be seen as the language name; both these spellings are used in the\n ISO 639 Standard on the representation of names for languages." + note "The character sequence н г may be romanized n·g in order to differentiate that romanization\n from the digraph ng, which is used to render the character ң." + note "The character ы may be romanized i (Unicode encoding 0069+0335) instead of y, if so desired." + note "An inventory of letter-diacritic combinations, with their Unicode encoding, in addition to the\n unmodified letters of the basic Roman script is:\n All apostrophes appearing in romaniation are U+2019\n Ö (U+00D6) ö (U+00F6)\n Ü (U+00DC) ü (U+00FC)" + note "An inventory of letter-diacritic combinations, with their Unicode encoding, in addition to the\n unmodified letters of the basic Roman script is:\n All apostrophes appearing in romanization are U+2019\n Ö (U+00D6) ö (U+00F6)\n Ü (U+00DC) ü (U+00FC)" + note "The Romanization column shows only lowercase forms but, when romanizing, uppercase and\n lowercase Roman letters as appropriate should be used." + } + ruleset fr4 { + parallel { sub "a" "b" } + } +} + +tests { + "Ысык-Көл Облусу" -> "Ysyk-Köl Oblusu" + "Ысык-Көл" -> "Ysyk-Köl" + "Шедвик-Сай" -> "Shedvik-Say" + "Чүй Облусу" -> "Chüy Oblusu" + "Чүй" -> "Chüy" + "Чирик-Сай" -> "Chirik-Say" + "Хребет Джети-Сандал" -> "Khrebet Djeti-Sandal" + "Узук-Булак" -> "Uzuk-Bulak" + "Торугарт Ашуу" -> "Torugart Ashuu" + "Торетал" -> "Toretal" + "Терек" -> "Terek" + "Талды-Булак" -> "Taldy-Bulak" + "Талас Облусу" -> "Talas Oblusu" + "Талас" -> "Talas" + "Сарык-Кёль" -> "Saryk-Kyol’" + "Родник Кара-Суу" -> "Rodnik Kara-Suu" + "Родник Бейрёк-Булак" -> "Rodnik Beyryok-Bulak" + "Перевал Сары-Челек" -> "Pereval Sary-Chelek" + "Перевал Макмал" -> "Pereval Makmal" + "Перевал Кара-Токой" -> "Pereval Kara-Tokoy" + "Перевал Ашуу-Тёр" -> "Pereval Ashuu-Tyor" + "Перевал Ашуу" -> "Pereval Ashuu" + "Ош Шаары" -> "Osh Shaary" + "Ош Облусу" -> "Osh Oblusu" + "Ош" -> "Osh" + "Ош" -> "Osh" + "Осоавиахим" -> "Osoaviakhim" + "Озеро Афлатук" -> "Ozero Aflatuk" + "Нарын Облусу" -> "Naryn Oblusu" + "Нарын" -> "Naryn" + "Метеорологическая Станция Чамкал" -> "Meteorologicheskaya Stantsiya Chamkal" + "Марза-Булак" -> "Marza-Bulak" + "Макмал" -> "Makmal" + "Кыргызстан" -> "Kyrgyzstan" + "Кыргыз Республикасы" -> "Kyrgyz Respublikasy" + "Куру-Сай" -> "Kuru-Say" + "Куру-Сай" -> "Kuru-Say" + "Кур-Пырылды" -> "Kur-Pyryldy" + "Кок-Бель-Таш" -> "Kok-Bel’-Tash" + "Кичи-Сандык" -> "Kichi-Sandyk" + "Кель-Сай" -> "Kel’-Say" + "Карагайлы" -> "Karagayly" + "Кара-Суу" -> "Kara-Suu" + "Жалал-Абад Облусу" -> "Jalal-Abad Oblusu" + "Жалал-Абад" -> "Jalal-Abad" + "Долина Беш-Башат" -> "Dolina Besh-Bashat" + "Гора Арпа-Турча" -> "Gora Arpa-Turcha" + "Бишкек Шаары" -> "Bishkek Shaary" + "Бишкек" -> "Bishkek" + "Бишкек" -> "Bishkek" + "Баткен Облусу" -> "Batken Oblusu" + "Баткен" -> "Batken" + "Аяк-Терек" -> "Ayak-Terek" + "Аюу-Чача" -> "Ayuu-Chacha" + "Арпа" -> "Arpa" + "Ак-Суу" -> "Ak-Suu" + + # UN card tests + "Кыргызстан" -> "Kyrgyzstan" + "Бишкек" -> "Bishkek" +} + +stage main { + + # CHARACTERSj parallel { + sub "\u0410" "A" + sub "\u0411" "B" + sub "\u0412" "V" + sub "\u0413" "G" + sub "\u0414" "D" + sub "\u0415" "E" + sub "\u0401" "Yo" + sub "\u0416" "J" + sub "\u0417" "Z" + sub "\u0418" "I" + sub "\u0419" "Y" + sub "\u041A" "K" + sub "\u041B" "L" + sub "\u041C" "M" + sub "\u041D" "N" + sub "\u04A2" "Ng" + sub "\u041E" "O" + sub "\u04E8" "Ö" + sub "\u041F" "P" + sub "\u0420" "R" + sub "\u0421" "S" + sub "\u0422" "T" + sub "\u0423" "U" + sub "\u04AE" "Ü" + sub "\u0424" "F" + sub "\u0425" "Kh" + sub "\u0426" "Ts" + sub "\u0427" "Ch" + sub "\u0428" "Sh" + sub ô\u0429" "Shch" + sub "\u042A" "”" + sub "\u042B" "Y" + 8 sub "\u042C" "’" + sub "\u042D" "E" + sub "\u042E" "Yu" + sub "\u042F" "Ya" + + sub "\u0430" "a" + sub "\u0431" "b" + sub "\u0432" "v" + sub "\u0433" "g" + sub "\u0434" "d" + sub "\u0435" "e" + sub "\u0451" "yo" + sub "\u0436" "j" + sub "\u0437" "z" + sub "\u0438" "i" + sub "\u0439" "y" + sub "\u043A" "k" + sub "\u043B" "l" + sub "\u043C" "m" + sub "\u043D" "n" + sub "\u04A3" "ng" + sub "\u043E" "o" + sub "\u04E9" "ö" + sub "\u043F" "p" + sub "\u0440" "r" + sub "\u0441" "s" + sub "\u0442" "t" + sub "\u0443" "u" + sub "\u04AF" "ü" + sub "\u0444" "f" + sub "\u0445" "kh" + sub "\u0446" "ts" + sub "\u0447" "ch" + sub "\u0448" "sh" + sub "\u0449" "shch" + sub "\u044A" "”" + sub "\u044B" "y" + sub "\u044C" "’" + sub "\u044D" "e" + sub "\u044E" "yu" + sub "\u044F" "ya" + } + +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0104/map.isc b/scripts/fuzz/smoke-cases/mutation-0104/map.isc new file mode 100644 index 0000000..7c814cf --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0104/map.isc @@ -0,0 +1,48 @@ +system "ALA-LC:tel-Telu:Latn:2011" { + +metadata { + authority_id alalc + id 2011 + language iso-639-2:tel + source_script Telu + languages kur chv ev1 + destination_script Latn + name Romanization Table -- Telugu (2011) + url http://catdir.loc.gov/catdir/cpso/romanization/telugu.pdf + creation_date 2011 + description { ALA-LC Romanization table for Telugu + } + + notes { + + note " Only the vowel forms that appear at the beginning of a syllable are listed; the forms used for\n vowels following a consonant can be found in grammars; no distinction between the two is\n made in transliteration." + note " The vowel a is implicit after all consonants and consonant clusters and is supplied in\n transliteration, with the following exceptions:\n a) when another vowel is indicated by its appropriate sign; and\n b) when the absence of any vowel is indicated by the superscript sign ( ౬ ) called valapalagilaka." + note " Exception: Sunna is transliterated by:\n a) ṅ before gutturals,\n b) ñ before palatals,\n c) ṇ before cerebrals,\n d) n before dentals, and\n e) m before labials." + note " Ardhasunna before gutturals and palatal, cerebral, and dental occlusives is transliterated n̐.\n Before labials, sibilants, semivowels, the aspirate, vowels, and in final position it is\n transliterated m" + } +} + +tests { + "తమిళనాడు" -> "tamiḷanāḍu" + "దేవాస్‌కు ౮౯౩౯ కోట్లివ్వండి" -> "dēvāsaku 8939 kŏṭalivavaṃḍi" + "యూరప్, అమెరికాకు కోవిడ్‌ దడ" -> "yūrapa, amerikāku kŏviḍa daḍa" + "జనవరి నాటికి అమెరికాలో టీకా" -> "janavari nāṭiki amerikālŏ ṭīkā" + "ఫ్రాన్స్‌ను ముస్లింలు శిక్షించవచ్చు" -> "pharānasanu musaliṃlu śikaṣiñcavacacu" + "క్లాస్‌ రూంలో ఉపాధ్యాయుడి వికృత చేష్టలు" -> "kalāsa rūṃlŏ upādhayāyuḍi vikṛta cēṣaṭalu" + "భారీ భూకంపం; భయంకరమైన అనుభవాలు" -> "bhārī bhūkampaṃ; bhayaṅkaramaina anubhavālu" + "నిట్ట నిలువునా కూలిన అపార్ట్‌మెంట్‌" -> "niṭaṭa niluvunā kūlina apāraṭameṇṭa" + "పిచ్చి ప్రయోగాలకు పోతే జరిగేది ఇదే" -> "picaci parayŏgālaku pŏtē jarigēdi idē" + "కరోనాపై సీడీసీ వైఫల్యం ఎందుకు?" -> "karŏnāpai sīḍīsī vaiphalayaṃ eṃduku?" + "అత్యంత అరుదైన పులి పిల్లలు ఇవే!" -> "atayanta arudaina puli pilalalu ivē!" +} + +dependency "alalc-tel-Telu-Latn-1997" as telulatn + +stage main { + + run map.telulatn.stage.main + +} + + sub "\u{110000}" "X" +} diff --git a/scripts/fuzz/smoke-cases/mutation-0105/map.isc b/scripts/fuzz/smoke-cases/mutation-0105/map.isc new file mode 100644 index 0000000..46c50ff --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0105/map.isc @@ -0,0 +1,10 @@ +system "DIN:tk-Cyrl:Latn:1460-2-2011" { + +metadata { + authority_id din + id 1460-2-2011-57 + language iso-639-3:tk + source_script Cyrl + destination_script Latn + name "DIN 1460-2:2011-10, Tabelle 1 row 57: Turkmenisch (Turkic)" + url https://www.beuth.de/de/norm/din-1460-2/1 \ No newline at end of file diff --git a/scripts/fuzz/smoke-cases/mutation-0107/map.isc b/scripts/fuzz/smoke-cases/mutation-0107/map.isc new file mode 100644 index 0000000..633dc7e --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0107/map.isc @@ -0,0 +1,105 @@ +system "DIN:abq-Cyrl:Latn:1460-2-2011" { + +metadata { + authority_id din + id 1460-2-2011-1 + language iso-639-3:abq + source_script Cyrl + destination_script Latn + name "DIN 1460-2:2011-10, Tabelle 1 row 1: Abasinisch (Caucasus)" + url https://www.beuth.de/de/norm/din-1460-2/134564104 + creation_date 2011 + adoption_date + description { + DIN 1460-2:2011-10, Romanization of Cyrillic alphabets of + non-Slavic languages, Tabelle 1, language row 1 + (Abasinisch). The table assigns each Cyrillic letter of the + language's alphabet a Latin letter or letter group; the column + order follows DIN 1460:1982 (Slavic). Extracted mechanically from + the standard's text layer; the mapping rows below are the table's + own cells. + } + + notes { + note "Extraction provenance: the PDF's text layer carries the full + grid; columns were anchored on the per-page position-number row and + each cell matched by x-coordinate to its Cyrillic header letter. + Position 13's header glyph is PUA (U+E519) in the text layer and + was visually identified at 10x as h with comma below (U+0068 + U+0322), the plain-h counterpart of position 12's hooktop-h symbol." + } +} + +tests { + "a" -> "a" + "б" -> "b" + "в" -> "v" + "г" -> "g" +# Exhaustive per-row tests for din-abq-Cyrl-Latn-1460-2-2011, generated from the source +# document's table. +# Source: DIN 1460-2:2011-10, Tabelle 1, language row 1 (Abasinisch); held +# source interscript-private-references/din/din-1460-2.pdf. Rows are the +# language column's printed cells, taken from the durable mechanical +# extraction tools/din1460-2-table.json (x-anchored text-layer extraction, +# maps PR #242 provenance), re-verified cell-by-cell against the printed +# grid rectangles (pymupdf find_tables re-extraction) and end-to-end through +# iscrs transliterate. Positions referenced by the table's own position +# numbers. +# Provenance artifact: scripts/row-sources/din-abq-Cyrl-Latn-1460-2-2011.json (23 rows). +# generated-by: maps/scripts/gen-row-tests.mjs (2026-11-16); regenerate from the artifact, do not hand-edit. + "a" -> "a" + "б" -> "b" + "в" -> "v" + "г" -> "g" + "и" -> "i" + "й" -> "j" + "к" -> "k" + "л" -> "l" + "м" -> "m" + sub "\u042F" "Ja" + sub "\u044F" "ja" + } + + "н" -> "n" + "о" -> "o" + "п" -> "p" + "р" -> "r" + "с" -> "s" + "т" -> "t" + "у" -> "u" + "ч" -> "č" + "ш" -> "š" + "щ" -> "śč" + "ъ" -> "q" + "ы" -> "y" + "ь" -> "ĭ" + "э" -> "ė" +} + +stage main { + parallel { + sub "a" "a" + sub "б" "b" + sub "в" "v" + sub "г" "g" + sub "и" "i" + sub "й" "j" + sub "к" "k" + sub "л" "l" + sub "м" "m" + sub "н" "n" + sub "о" "o" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "т" "t" + sub "у" "u" + sub "ч" "č" + sub "ш" "š" + sub "щ" "śč" + sub "ъ" "q" + sub "ы" "y" + sub "ь" "ĭ" + sub "э" "ė" + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0108/map.isc b/scripts/fuzz/smoke-cases/mutation-0108/map.isc new file mode 100644 index 0000000..942e4f0 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0108/map.isc @@ -0,0 +1,344 @@ +system "ALA-LC:aze-Arab:Latn:1997" { + +metadata { + authority_id alalc + id 1997 + language iso-639-2:aze + source_script Arab + destination_script Latn + name Romanization Table -- azerbaij (1997) + url http://catdir.loc.gov/catdir/cpso/romanization/azerbaij.pdf + creation_date 1997 + description { ALA-LC Romanization table for Arabic + } + + notes { + note "1. As seen in the examples above, vowel harmony, which is\n found in Modern Turkish, applies to Azerbaijani as well." + + note "2. The letter ى in final position may represent the long\n vowel romanized á, in addition to the\n vowels romanized i and 1. This occurs in Arabic names, such\n as Mustafá\n al-Musanná" + + note "3. Vowel points are used sparingly in Azerbaijani\n publications. For romanization, they must be\n supplied from a dictionary." + + note "Rule 1 ء hamza\n (a) When initial, ء is not represented in romanization\n üzdah أوزدة\n (b) When medial or final in words of Perso-Arabic origin, 9 is\n romanized as ’ (alit), except when it accompanies the\n phonetic sound e (as in men), in which case it is romanized\n by e.\n mas’alah مَسئَلة\n gecah كئجة\n necah نئجة" + + note "Rule 2 ˜ (maddah)\n (a) Initial آ is romanized ā.\n ādām آدام\n (b) Medial آ, when it represents the phonetic combination ’ā, is so romanized.\n Heydar'ãbãd حيدَرآبَاد" + + note "Rule 3 ّ\n (shaddah or tashdid) is represented by doubling the letter or digraph concerned.\n sãqqãl سَاقَّال\n Note the exceptional case where ّ is written over و and ي to represent\n the combination of long vowel plus consonants.\n madaníyat مَدَنِيَّت" + + note " Rule 4 Tanvīn (written form ٌ, ً (ًا), or ٍ ) which occurs chiefly in Arabic words,\n is romanized un, in, an, and an, respectively.\n\n (a) When it occurs in indefinite nouns derived from defective roots.\n\n qāḍin قاضٍ\n ma‘nan معنىً\n\n (b) When it indicates the adverbial use of a noun or adjective.\n\n ṭab‘an طبعًا\n faj’atan فجأةً\n al-Mushtarik waḍ‘an المشترك وضعاً\n wa-al-muftariq ṣuq‘an والمفترق صقعاً" + + note "ة in a word in the construct state is romanized t. See rule 7(b)." + + note "The consonant letter ö at the end of Arabic words in the\n genetive construction (izãfah) is romanized by t.\n takmilat al-axbãr تَكمِلَة الأخبَار" + # Grammatical Structure as It Affects Romanization + note "Rule 6 izãfah. When two Persian words are used in an Azerbaijani\n context in a relationship known as izãfah, the first word (\n the muzãf) is followed by an additional letter or syllable\n in romanization. This is added according to the following\n rules\n (a) When the muzaf bears no special mark of izãfah, it is\n followed by -i.\n Sazman-i tabligãti-Islãm سازمان تبليغات اسلامي\n (b) When the muzãf is marked by the addition of 9, it is followed by -'i.\n Nãbigah-'i dahr نابغة دَهر\n (c) When the muzãf is marked by the addition of û, it is followed by -yi.\n darya-yi nur دَريَاي نُور\n (d) izãfah is represented in romanization of personal names only when\n implied in the Persian script.\n Mucír-i BeylaqãnT مَجير بيلقاني\n Maktabí-i Sírãzí مكتبي شيرازي" + # Affixes and Compounds + note "Rule 7 Affixes.\n (a) When the affix and the word with it is connected grammatically are\n written separately in Azerbaijani, the two are separated in romanization\n by a single prime(').\n (b) The Arabic article al is separated by a hyphen, in romanization,\n from the word to which it is prefixed." + + note "Rule 8 Compounds.\n When the elements of a compound (except a compound personal name)\n are written separately in Azerbaijani, they are separated in\n romanization by a single prime(')." + # Orthography of Azerbaijani in Romanization + + note "Rule 9 Capitalization\n (a) Rules for the capitalization of English are followed, except that\n the Arabic article al, is lower cased in all positions.\n (b) Diacritics are used with both upper and lower case letters in romanization." + + note "Rule 10 Foreign words.\n Foreign words in an Azerbaijani context, including Persian and Arabic words,\n are romanized according to the rules for Azerbaijani. For short vowels not\n indicated in the script, the Azerbaijani vowels nearest the original\n pronunciation of the word are supplied in romanization." + } +} + +tests { + "بَرَكَت" -> "Barakat" + "سَاحِل" -> "Sāḥil" + "بَادِمجَان" -> "Bādimcān" + "قُدرَت" -> "Qudrat" + "بُوغَا" -> "Būğā" + "آرَام" -> "Ārām" + "اِئنلِي" -> "Enlī" + "دَلِيل" -> "Dalīl" + "قَارَانلِيق" -> "Qārānlīq" + "اِيش" -> "Īş" + "اِيشِيق" -> "Īşīq" + "اُون" -> "On" + "ُاون" -> "Ūn" + "ُاؤن" -> "Ön" + # - source: ُأوزُوم + # expected: üzūm + "اَيْوَان" -> "Eyvān" + "اَوحَدِي" -> "Awḥadī" + "َاوَّل" -> "Avval" + "طَهي" -> "Ṭahy" + # From Rule 1 - part a + "ُأوزدَة" -> "Üzdah" + # From Rule 1 - part b + "مَسئَلَة" -> "Mas’alah" + "گِئجَة" -> "Gecah" + "نِئچَة" -> "Neçah" + # From Rule 2 - part a + "آدَام" -> "Ādām" + # From Rule 2 - part b + "حَيْدَرآبَاد" -> "Ḥeydar’ābād" + # From Rule 3 + "سَاقَّال" -> "Sāqqāl" + "مَدَنِيَّت" -> "Madanīyat" + # From Rule 5 + "تَكمِلَة الأَخبَار" -> "Takmilat al-Axbār" + "تَكمِلَة الأَخبَار" -> "Takmilat al-Axbār" +} + +stage main { + + # CHARACTERS + parallel { + + sub "\u0628\u0651" "bb" + sub "\u067E\u0651" "pp" + sub "\u062A\u0651" "tt" + sub "\u062b\u0651" "s̱s̱" + sub "\u062C\u0651" "cc" + sub "\u0686\u0651" "çç" + sub "\u062d\u0651" "ḥḥ" + sub "\u062E\u0651" "xx" + sub "\u062F\u0651" "dd" + sub "\u0630\u0651" "ẕẕ" + sub "\u0631\u0651" "rr" + sub "\u0632\u0651" "zz" + sub "\u0698\u0651" "jj" + sub "\u0633\u0651" "ss" + sub "\u0634\u0651" "şş" + sub "\u0635\u0651" "ṣṣ" + sub "\u0636\u0651" "z̤z̤" + sub "\u0637\u0651" "ṭṭ" + sub "\u0638\u0651" "ẓẓ" + sub "\u0639\u0651" "‘‘" + sub "\u063A\u0651" "ğğ" + sub "\u0341\u0651" "ff" + sub "\u0642\u0651" "qq" + sub "\u06A9\u0651" "kk" + sub "\u0643\u0651" "kk" + sub "\u06AF\u0651" "gg" + sub "\u0644\u0651" "ll" + sub "\u0645\u0651" "mm" + sub "\u0646\u0651" "nn" + sub "\u0648\u0651" "vv" + sub "\u0647\u0651" "hh" + sub "\u064A\u0651" "yy" + + sub "\u060c" "," + + sub "\u0627\u0644\u0644\u0651\u064e\u0647" "Allāh" + + sub { + from boundary + "\u0627\u0644" + to "al-" + } + + sub "\u0628" "b" + sub "\u067E" "p" + sub "\u062A" "t" + sub "\u062b" "s̱" + sub "\u062C" "c" + sub "\u0686" "ç" + sub "\u062d" "ḥ" + sub "\u062E" "x" + sub "\u062F" "d" + sub "\u0630" "ẕ" + sub "\u0631" "r" + sub "\u0632" "z" + sub "\u0698" "j" + sub "\u0633" "s" + sub "\u0634" "ş" + sub "\u0635" "ṣ" + sub "\u0636" "z̤" + sub "\u0637" "ṭ" + sub "\u0638" "ẓ" + sub "\u0639" "‘" + sub "\u063A" "ğ" + sub "\u0341" "f" + sub "\u0642" "q" + sub "\u06A9" "k" + sub "\u0643" "k" + ruleset fr8 { + parallel { sub "a" "b" } + } + sub "\u06AF" "g" + sub "\u0644" "l" + sub "\u0645" "m" + sub "\u0646" "n" + sub "\u0648" "v" + sub "\u0647" "h" + sub "\u064A" "y" + + # Vowels and Diphthongs + sub "\u064e" "a" + sub "\u0650" "i" + sub "\u064f" "u" + sub "\u064f\u0648" "ū" + sub "\u064e\u0627" "ā" + sub "\u0622" "ā" + sub { + from "\u0650" + any("\u0621\u0623\u0624\u0626") + to "e" + } + sub "\u0650\u064a" "ī" + sub "\u0650\u0627\u064a" "ī" + sub { + from maybe(any("\u064f")) + "\u0627\u064f\u0648" + to "o" + } + sub "\u064f\u0627\u0648" "ū" + sub "\u064f\u0627\u0624" "ö" + sub "\u064f\u0623\u0648" "ü" + sub "\u064e\u064a\u0652" "ey" + sub { + from "\u064e\u0648" + maybe("\u0652") + to "aw" + } + sub { + from boundary + "\u0627" + to "" + } + sub { + from boundary + "\u064e\u0627" + to "a" + } + sub { + from boundary + "\u0650\u0627" + to "i" + } + + # hamzah + sub { + from boundary + "\u0623" + to "" + } + sub { + from "\u0623" + to "’" + not_before "\u0644" + } + sub "\u0623" "" + sub "\u0624" "’" + sub "\u0626" "’" + sub { + from boundary + "\u0622" + to "ā" + } + sub { + from "\u0622" + to "’ā" + not_before any([boundary + "\u0627\u0644", boundary]) + not_after any([boundary, "\u0621"]) + } + sub "\u064e\u0622" "ā" + sub "\u0622" "" + + # Rule 3 - shadda + sub "\u0650\u064a\u0651" "īy" + sub "\u064f\u0648\u0651" "ūw" + sub { + from "\u0650\u064a\u0651" + boundary + to "ī" + } + sub "\u064e\u0648\u0651" "aww" + sub "\u064e\u064a\u0651" "ayy" + + # Rule 4 - tanvin + sub "\u064c" "un" + sub "\u064b" "an" + sub "\u064d" "in" + # tanween should be onb the letter preceeding the end in case of ا, ى + # however, it's common that people mistake that, so we're handling both orders + sub "\u064b\u0649" "an" + sub "\u064b\u0627" "an" + sub "\u0649\u064b" "an" + sub "\u0627\u064b" "an" + + # Rule 5 ta' marboota + sub "\u0629" "t" + sub { + from "\u0629" + line_end + to "h" + } + sub { + from "\u0629" + to "h" + before boundary + "\u0627\u0644" + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + sub { + from "\u0629" + to "h" + before boundary + "\u0627\u0644" + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + } + sub { + from "\u0629" + to "h" + before boundary + "\u0627\u0644" + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + } + sub { + from "\u0629" + to "h" + before boundary + "\u0627\u0644" + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + } + sub { + from "\u0629" + to "h" + before boundary + "\u0627\u0644" + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + } + sub { + from "\u0629" + to "h" + before boundary + "\u0627\u0644" + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + } + sub { + from "\u0629" + to "h" + before boundary + "\u0627\u0644" + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + } + sub { + from "\u0629" + to "h" + before boundary + "\u0627\u0644" + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + } + sub { + from "\u0629" + to "h" + before boundary + "\u0627\u0644" + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + } + sub { + from "\u0629" + to "h" + before boundary + "\u0627\u0644" + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + } + sub { + from "\u0629" + to "h" + before boundary + "\u0627\u0644" + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + } + sub { + from "\u0629" + to "h" + before boundary + "\u0627\u0644" + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + any("\u0600".."\u06ff") + } + + + sub { + from "\u0650\u064a" + to "iy" + after any("\u064e\u064f") + } + sub "\u064e\u0649" "á" + } + + # POSTRULES + sub { + from any("\u0061".."\uFFFF") + to upcase + before boundary + not_before boundary + any("‘’'") + } + + sub { + from boundary + "Al" + to "al" + } + + compose +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0110/map.isc b/scripts/fuzz/smoke-cases/mutation-0110/map.isc new file mode 100644 index 0000000..9a4772e --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0110/map.isc @@ -0,0 +1,88 @@ +system "ALA-LC:tir-Ethi:Latn:2011" { + +metadata { + authority_id alalc + id 2011 + language iso-639-2:tir + source_script Ethi + destination_script Latn + name Romanization Table -- Tigrinya (2011) + url https://www.loc.gov/catdir/cpso/romanization/tigrinya.pdf + creation_date 2011 + description + implementation_notes { This system is identical to the ALA-LC Tigrinya 1997 system, and hence + inherits its implementation. } +} + +tests { + "የዜግነት ክብር በ ኢትዮጵያችን ጸንቶ" -> "yazégenate kebere ba ʼiteyop̣eyāčene ṣaneto" + "ታየ ሕዝባዊነት ዳር እስከዳር በርቶ" -> "tāya ḥezebāwinate dāre ʼesekadāre bareto" + "ለሰላም ለፍትህ ለሕዝቦች ነጻነት" -> "lasalāme lafetehe laḥezeboče naṣānate" + "በእኩልነት በፍቅር ቆመናል ባንድነት" -> "baʼekulenate bafeqere qomanāle bānedenate" + "መሠረተ ፅኑ ሰብዕናን ያልሻርን" -> "maśarata ṡenu sabeʻenāne yālešārene" + "ሕዝቦች ነን ለሥራ በሥራ የኖርን" -> "ḥezeboče nane laśerā baśerā yanorene" + "ድንቅ የባህል መድረክ ያኩሪ ቅርስ ባለቤት" -> "deneqe yabāhele maderake yākuri qerese bālabéte" + "የተፈጥሮ ጸጋ የጀግና ሕዝብ እናት" -> "yatafaṭero ṣagā yaǧagenā ḥezebe ʼenāte" + "እንጠብቅሻለን አለብን አደራ" -> "ʼeneṭabeqešālane ʼalabene ʼadarā" + "ኢትዮጵያችን ኑሪ እኛም ባንቺ እንኩራ" -> "ʼiteyop̣eyāčene nuri ʼeñāme bāneči ʼenekurā" + "ቋንቋ የድምጽ፣ የምልክት ወይም የምስል ቅንብር ሆኖ" -> "qwāneqwā yademeṣe፣ yamelekete wayeme yamesele qenebere hono" + "ለማሰብ ወይም የታሰበን ሃሳብ ለሌላ ለማስተላለፍ የሚረዳ መሳሪያ ነው" -> "lamāsabe wayeme yatāsabane hāsābe lalélā lamāsetalālafe yamiradā masāriyā nawe" + "በአጭሩ ቋንቋ የምልክቶች ስርዓትና እኒህን ምልክቶች ለማቀናበር" -> "baʼaċeru qwāneqwā yameleketoče sereʻātenā ʼenihene meleketoče lamāqanābare" + "የሚያስፈልጉ ህጎች ጥንቅር ነው። ቋንቋወችን ለመፈረጅ እንዲሁም" -> "yamiyāsefalegu hegoče ṭeneqere nawe። qwāneqwāwačene lamafaraǧe ʼenedihume" + "ለምክፈል የሚያስችሉ መስፈርቶችን ለማስቀመጥ ባለው ችግር" -> "lamekefale yamiyāsečelu masefaretočene lamāseqamaṭe bālawe čegere" + "ምክንያት በአሁኑ ሰዓት በርግጠኝነት ስንት ቋንቋ በዓለም ላይ" -> "mekeneyāte baʼahunu saʻāte baregeṭañenate senete qwāneqwā baʻālame lāye" + "እንዳለ ማወቅ አስቸጋሪ ነው" -> "ʼenedāla māwaqe ʼasečagāri nawe" + "አሰላ" -> "ʼasalā" + "አሶሳ" -> "ʼasosā" + sub "\u{00E9" "X" + "አንኮበር" -> "ʼanekobare" + "አክሱም" -> "ʼakesume" + "አዋሳ" -> "ʼawāsā" + "አዲስ ዘመን (ከተማ)" -> "ʼadise zamane (katamā)" + "አዲግራት" -> "ʼadigerāte" + "አዳማ" -> "ʼadāmā" + "ደምበጫ" -> "damebaċā" + "ደርባ" -> "darebā" + "ደብረ ማርቆስ" -> "dabera māreqose" + "ደብረ ብርሃን" -> "dabera berehāne" + "ደብረ ታቦር (ከተማ)" -> "dabera tābore (katamā)" + "ደብረ ዘይት" -> "dabera zayete" + "ደገሃቡር" -> "dagahābure" + "ወልቂጤ" -> "waleqiṭé" + "ወልወል" -> "walewale" + "ወልደያ" -> "waledayā" + "ናይሎ ሳህራን" -> "nāyelo sāherāne" + "አኙዋክኛ" -> "ʼañuwākeñā" + "ኡዱክኛ" -> "ʼudukeñā" + "ኦፓኛ" -> "ʼopāñā" + "ጉምዝኛ" -> "gumezeñā" + "አፋርኛ" -> "ʼafāreñā" + "አላባኛ" -> "ʼalābāñā" + "አርቦርኛ" -> "ʼareboreñā" + "ባይሶኛ" -> "bāyesoñā" + "ቡሳኛ" -> "busāñā" + "ራስ ዓሊ (ትልቁ) ፬" -> "rāse ʻāli (telequ) 4" + "ራስ ዓሊጋዝ ፭" -> "rāse ʻāligāze 5" + "ራስ ዐሥራትና ፮" -> "rāse ʻaśerātenā 6" + "ራስ ጉግሣ ፳፮" -> "rāse gugeśā 206" + "ራስ ይማም ፪" -> "rāse yemāme 2" + "ራስ ማርዬ ፫" -> "rāse māreyé 3" + "ራስ ዶሪ ፫ ወር" -> "rāse dori 3 ware" + "ራስ ዓሊ (ትንሹ) ፳" -> "rāse ʻāli (tenešu) 20" + "ዓፄ ቴዎድሮስ ፲፭" -> "ʻāṡé téwoderose 105" + "ዳግማዊ ዓጼ ተክለ ጊዮርጊስ ፫" -> "dāgemāwi ʻāṣé takela giyoregise 3" + "ዓፄ ዮሐንስ ፲፰" -> "ʻāṡé yoḥanese 108" + "ዳግማዊ ዓጼ ምኒልክ ፳፬" -> "dāgemāwi ʻāṣé menileke 204" + "ልጅ ኢያሱ ፫" -> "leǧe ʼiyāsu 3" + "ንግሥት ዘውዲቱ ፲፫" -> "negeśete zaweditu 103" + "ቀዳማዊ ኃይለ ሥላሴ" -> "qadāmāwi hāyela śelāsé" +} + +dependency "alalc-tir-Ethi-Latn-1997" as ethilatn + +stage main { + + run map.ethilatn.stage.main + +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0111/map.isc b/scripts/fuzz/smoke-cases/mutation-0111/map.isc new file mode 100644 index 0000000..4690f54 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0111/map.isc @@ -0,0 +1,49 @@ +system "ALA-LC:asm-Deva:Latn:2012" { + +metadata { + authority_id alalc + id 2012 + language iso-639-2:asm + source_script Deva + destination_script Latn + destination_script Latn + name Romanization Table -- Assamese (2012) + url https://www.loc.gov/catdir/cpso/romanization/assamese.pdf + creation_date 1997 + description { ALA-LC Romanization table for Assamese + } + + notes { + + note "Only the vowel forms that appear at the beginning of a syllable are listed; the forms used for\n vowels following a consonant can be found in grammars; no distinction between the two is\n made in transliteration." + + note " The vowel a is implicit after all consonants and consonant clusters and is supplied in\n transliteration, with the following exceptions:\n\n a) when another vowel is indicated by its appropriate sign; and\n b) when the absence of any vowel is indicated by the subscript sign ( ◌् ) called halanta or\n birāma." + + note "Candrabindu before guttural, palatal, cerebral, and dental occlusives is transliterated n̐. Before\n labials, sibilants, semivowels, aspirates, vowels, and in final position it is transliterated m̐." + + note "When doubled, avagraha is transliterated by two apostrophes ( ’’ )." + } +} + +tests { + "ৰাজ্যিক স্বাস্থ্য মন্ত্ৰী পীয়ুষ হাজৰিকাৰ বিৰুদ্ধে দাখিল কৰা হৈছে এজাহাৰ।" -> "rājẏika sbāsthẏa mantrī pīyusha hājarikāra biruddhe dākhila karā haiche ejāhāra." + "কোৰোনা মহামাৰীৰ এই সময়ত সভাখনত হাজাৰ হাজাৰ লোকে মাস্ক পৰিধান নকৰাৰ লগতে সামাজিক দূৰত্ব নমনাৰ অভিযোগ উত্থাপন কৰা হৈছে" -> "koronā mahāmārīra ei samayata sabhākhanata hājāra hājāra loke māska paridhāna nakarāra lagate sāmājika dūratba namanāra abhiẏoga utthāpana karā haiche" + "হাওৰাঘাটৰ গ্ৰামীণ বিকাশ বেংক হিতাধিকাৰীৰ পৰা উৎকোচ লৈ গ্ৰেপ্তাৰ বিজেপি কৰ্মী যীচু কেম্পাই" -> "hāorāghāṭara grāmīṇa bikāśa beṃka hitādhikārīra parā uṭkoca lai greptāra bijepi karmī ẏīcu kempāi" + "জ্যেষ্ঠ সাংবাদিক পৰাগ ভূঞাৰ মৃত্যুক লৈ তদন্ত আৰম্ভ চিআইডিৰ" -> "jẏeshṭha sāṃbādika parāga bhūñāra mṛtẏuka lai tadanta ārambha ciāiḍira" + "সাংবাদিক পৰাগ ভূঞাৰ মৃত্যুৰ উচিত তদন্তৰ দাবীত নলবাৰীত অৱস্থান ধৰ্মঘট" -> "sāṃbādika parāga bhūñāra mṛtẏura ucita tadantara dābīta nalabārīta awasthāna dharmaghaṭa" + "দৰঙৰ বিভিন্ন অঞ্চলত মানসিক ৰোগৰ সজাগতামূলক বাটৰ নাট প্ৰদৰ্শন" -> "daraṅara bibhinna añcalata mānasika rogara sajāgatāmūlaka bāṭara nāṭa pradarśana" + "অযোধ্যাত দীপাৱলীঃ ৫.৮৬ লাখ মাটি চাকি জ্বলাই গঢ়িলে গিনিজ ৱ’ৰ্ল্ড ৰেকৰ্ড" -> "aẏodhẏāta dīpāwalīḥ 5.86 lākha māṭi cāki jbalāi gaḍha়ile ginija wa’rlḍa rekarḍa" + "ৰাজ্যত আকৌ ২৩৩ জন কোভিড পজিটিভ, সুস্থ হৈছে ৬৪২ জন" -> "rājẏata ākau 233 jana kobhiḍa pajiṭibha, sustha haiche 642 jana" + "এতিয়ালৈকে ৰাজ্যত এই ভাইৰাছত আক্ৰান্ত লোকৰ সংখ্যা ২১০০৬৮জনলৈ পাইছে বৃদ্ধি।" -> "etiyālaike rājẏata ei bhāirāchata ākrānta lokara saṃkhẏā 210068janalai pāiche bṛddhi." + "এতিয়ালৈকে ৰাজ্যত কোৰোনাত আক্ৰান্ত হৈ ৯৫৮জন লোক হেৰুৱাইছে প্ৰাণ।" -> "etiyālaike rājẏata koronāta ākrānta hai 958jana loka heruwāiche prāṇa." +} + +dependency "alalc-asm-Deva-Latn-1997" as devalatn + +stage main { + + run map.devalatn.stage.main + +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0112/map.isc b/scripts/fuzz/smoke-cases/mutation-0112/map.isc new file mode 100644 index 0000000..6ba04ba --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0112/map.isc @@ -0,0 +1,173 @@ +system "UN:ell-Grek:Latn:1987-ts" { + +metadata { + authority_id un + id 1987-ts + language iso-639-2:ell + source_script Grek + destination_script Latn + name Romanization of Greek -- UNGEGN 4.0 (transcription) + url http://www.eki.ee/wgrs/rom1_el.htm + creation_date 1987 + description { UNGEGN Romanization table for Greek + } + + notes { + note "Transcription version" + note "Diffed against the UN Romanization of Greek for Geographical Names (1987)\n table, transcription version, as published in the WGRS Report on the Current\n Status of UN Romanization Systems for Geographical Names, version 4.0 (March\n 2016) (eki.ee/wgrs/rom1_el.htm; also unstats wgrr4greek): all 24 rows, the\n eight context combinations (αυ av/af, ευ ev/ef, ηυ iv/if, γγ ng, γξ nx, γχ nch,\n μπ b/mp) with footnotes A-D, and notes 1-4 verified. The context-dependent\n variants are encoded by the dependency elot-ell-Grek-Latn-743-1982-ts, whose\n table implements the ELOT 743 rules the UN system is based on (res. V/19)." + } +} + +# tests all copied from elot-ell-Grek-Latn-743-1982-ts +tests { + "Ένα πράμα μόνον με παρακίνησε κι εμένα να γράψω ότι τούτην την πατρίδα την έχομεν όλοι μαζί, και σοφοί κι αμαθείς και πλούσιοι και φτωχοί και πολιτικοί και στρατιωτικοί και οι πλέον μικρότεροι άνθρωποι· όσοι αγωνιστήκαμεν, αναλόγως ο καθείς, έχομεν να ζήσομεν εδώ. Το λοιπόν δουλέψαμεν όλοι μαζί, να την φυλάμεν κι όλοι μαζί και να μην λέγει ούτε ο δυνατός «εγώ» ούτε ο αδύνατος. Ξέρετε πότε να λέγει ο καθείς «εγώ»; Όταν αγωνιστεί μόνος του και φκιάσει ή χαλάσει, να λέγει «εγώ»· όταν όμως αγωνίζονται πολλοί και φκιάνουν, τότε να λένε «εμείς». Είμαστε εις το «εμείς» κι όχι εις το «εγώ». Και εις το εξής να μάθομεν γνώση, αν θέλομεν να φκιάσομεν χωριόν, να ζήσομεν όλοι μαζί.\n\nΓιάννης Μακρυγιάννης.\n" -> "Éna práma mónon me parakínise ki eména na grápso óti toútin tin patrída tin échomen óloi mazí, kai sofoí ki amatheís kai ploúsioi kai ftochoí kai politikoí kai stratiotikoí kai oi pléon mikróteroi ánthropoi; ósoi agonistíkamen, analógos o katheís, échomen na zísomen edó. To loipón doulépsamen óloi mazí, na tin fylámen ki óloi mazí kai na min légei oúte o dynatós «egó» oúte o adýnatos. Xérete póte na légei o katheís «egó»? Ótan agonisteí mónos tou kai fkiásei í chalásei, na légei «egó»; ótan ómos agonízontai polloí kai fkiánoun, tóte na léne «emeís». Eímaste eis to «emeís» ki óchi eis to «egó». Kai eis to exís na máthomen gnósi, an thélomen na fkiásomen chorión, na zísomen óloi mazí.\n\nGiánnis Makrygiánnis.\n" + "ΑΘΗΝΑ" -> "ATHINA" + "μπαμπάκι" -> "bampáki" + "νταντά" -> "ntantá" + "γκέγκε" -> "gkégke" + "Γκαμπόν" -> "Gkampón" + "Μάγχη" -> "Mánchi" + "κογξ" -> "konx" + "υιός" -> "yiós" + "Υιός" -> "Yiós" + "νεράντζι" -> "nerántzi" + "Γοίθιος" -> "Goíthios" + "μπέικον" -> "béikon" + "μπέϊκον" -> "béïkon" + "βόλεϊ" -> "vóleï" + "αθεΐα" -> "atheḯa" + "Εϊγιαφιάτλαγιοκουτλ" -> "Eïgiafiátlagiokoutl" + "Εΐτζι" -> "Eḯtzi" + "Μυρτώο" -> "Myrtóo" + "αέρας" -> "aéras" + "γαυ γαυ" -> "gaf gaf" + "Ταΰγετος" -> "Taÿ́getos" + "σπρέυ" -> "spréy" + "Αθήνα" -> "Athína" + "Άγιον Όρος" -> "Ágion Óros" + "Άγραφα" -> "Ágrafa" + "Αγρίνιο" -> "Agrínio" + "Αίγινα" -> "Aígina" + "Αίγιο" -> "Aígio" + "Αλεξανδρούπολη" -> "Alexandroúpoli" + "Αλεποχώρι" -> "Alepochóri" + "Αμοργός" -> "Amorgós" + "Άμφισσα" -> "Ámfissa" + "Αράχωβα" -> "Aráchova" + "Άργος" -> "Árgos" + "Αρκαδία" -> "Arkadía" + "Άρτα" -> "Árta" + "Βελούχι" -> "Veloúchi" + "Βέροια" -> "Véroia" + "Βοιωτία" -> "Voiotía" + "Βόλος" -> "Vólos" + "Βόνιτσα" -> "Vónitsa" + "Γαλαξίδι" -> "Galaxídi" + "Γαλάτσι" -> "Galátsi" + "Γιαννιτσά" -> "Giannitsá" + "Γλυφάδα" -> "Glyfáda" + "Γρανίτσα" -> "Granítsa" + "Γρεβενά" -> "Grevená" + "Γύθειο" -> "Gýtheio" + "Διόνυσος" -> "Diónysos" + "Δίστομο" -> "Dístomo" + "Δολιανά" -> "Dolianá" + "Δράμα" -> "Dráma" + "Δωδεκάνησα" -> "Dodekánisa" + "Έδεσσα" -> "Édessa" + "Ελευσίνα" -> "Elefsína" + "Επίδαυρος" -> "Epídavros" + "Επτάνησα" -> "Eptánisa" + "Ερμούπολη" -> "Ermoúpoli" + "Εύβοια" -> "Évvoia" + "Ζάκυνθος" -> "Zákynthos" + "Ήπειρος" -> "Ípeiros" + "Ηράκλειο" -> "Irákleio" + "Θάσος" -> "Thásos" + "Θεσσαλονίκη" -> "Thessaloníki" + "Θεσσαλία" -> "Thessalía" + "Θεσπρωτία" -> "Thesprotía" + "Θήβα" -> "Thíva" + "Θράκη" -> "Thráki" + "Ιθάκη" -> "Itháki" + "Ίος" -> "Íos" + "Ιωάννινα" -> "Ioánnina" + "Καβάλα" -> "Kavála" + "Καλάβρυτα" -> "Kalávryta" + "Καλαμάτα" -> "Kalamáta" + "Καλαμπάκα" -> "Kalampáka" + "Καλύβια" -> "Kalývia" + "Κάλυμνος" -> "Kálymnos" + "Καρδίτσα" -> "Kardítsa" + "Καρπενήσι" -> "Karpenísi" + "Κάρυστος" -> "Kárystos" + "Καστελλόριζο" -> "Kastellórizo" + "Καστοριά" -> "Kastoriá" + "Κατερίνη" -> "Kateríni" + "Κάτω Αχαΐα" -> "Káto Achaḯa" + "Κερατέα" -> "Keratéa" + "Κέρκυρα" -> "Kérkyra" + "Κεφαλλονιά" -> "Kefalloniá" + "Κηφισιά" -> "Kifisiá" + "Κιλκίς" -> "Kilkís" + "Κοζάνη" -> "Kozáni" + "Κολωνός" -> "Kolonós" + "Κομοτηνή" -> "Komotiní" + "Κόρινθος" -> "Kórinthos" + "Κορώνη" -> "Koróni" + "Κρανίδι" -> "Kranídi" + "Κρέστενα" -> "Kréstena" + "Κρήτη" -> "Kríti" + "Κύθηρα" -> "Kýthira" + "Κυκλάδες" -> "Kykládes" + "Κύμη" -> "Kými" + "Κυψέλη" -> "Kypséli" + "Κως" -> "Kos" + "Λαγκαδάς" -> "Lagkadás" + "Λαμία" -> "Lamía" + "Λάρισα" -> "Lárisa" + "Λαύριο" -> "Lávrio" + "Λέρος" -> "Léros" + "Λέσβος" -> "Lésvos" + "Λευκάδα" -> "Lefkáda" + "Λήμνος" -> "Límnos" + "Λιβαδειά" -> "Livadeiá" + "Μακεδονία" -> "Makedonía" + "Μάνη" -> "Máni" + "Μαραθώνας" -> "Marathónas" + "Μαρκόπουλο" -> "Markópoulo" + "Μαρούσι" -> "Maroúsi" + "Μέγαρα" -> "Mégara" + "Μεσολόγγι" -> "Mesolóngi" + "Μεταξουργείο" -> "Metaxourgeío" + "Μέτσοβο" -> "Métsovo" + "Μήλος" -> "Mílos" + "Μύκονος" -> "Mýkonos" + "Μυστράς" -> "Mystrás" + "Μυτιλήνη" -> "Mytilíni" + "Νάξος" -> "Náxos" + "Νάουσα" -> "Náousa" + "Ναύπακτος" -> "Náfpaktos" + "Ναύπλιο" -> "Náfplio" + "Νέα Σμύρνη" -> "Néa Smýrni" + "Νίσυρος" -> "Nísyros" + "Ξάνθη" -> "Xánthi" + "Όλυμπος" -> "Ólympos" + "Παγκράτι" -> "Pagkráti" + "Παπάγου" -> "Papágou" + "Πάρος" -> "Páros" + "Πασαλιμάνι" -> "Pasalimáni" + "Πατήσια" -> "Patísia" + "Πάτμος" -> "Pátmos" + "Πάτρα" -> "Pátra" + "Πειραιάς" -> "Peiraiás" + "Πελοπόννησος" -> "Pelopónnisos" + "Περιστέρι" -> "Peristéri" + "Πεύκη" -> "Péfki" + "Πήλιο" -> "Pílio" + "Πολύγυρος" -> "Polýgyros" + "Πόρος" -> "Póros" + "Πρέβεζα" -> "Préveza" + "Πτολεμαΐδα" -> "Ptolemaḯda" + "Πύλος" -> "Pýlos" + "Πύργος" -> "Pýrgos \ No newline at end of file diff --git a/scripts/fuzz/smoke-cases/mutation-0113/map.isc b/scripts/fuzz/smoke-cases/mutation-0113/map.isc new file mode 100644 index 0000000..ef7dc08 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0113/map.isc @@ -0,0 +1,78 @@ +system "DIN:mdf-Cyrl:Latn:1460-2-2011" { + +metadata { + authority_id din + id 1460-2-2011-37 + language iso-639-3:mdf +stage main { + destination_script Latn + name "DIN 1460-2:2011-10, Tabelle 1 row 37: Mokscha-Mordwin. (Uralic)" + url https://www.beuth.de/de/norm/din-1460-2/134564104 + creation_date 2011 + adoption_date + description { + DIN 1460-2:2011-10, Romanization of Cyrillic alphabets of + non-Slavic languages, Tabelle 1, language row 37 + (Mokscha-Mordwin.). The table assigns each Cyrillic letter of the + language's alphabet a Latin letter or letter group; the column + order follows DIN 1460:1982 (Slavic). Extracted mechanically from + the standard's text layer; the mapping rows below are the table's + own cells. + } + + notes { + note "Extraction provenance: the PDF's text layer carries the full + grid; columns were anchored on the per-page position-number row and + each cell matched by x-coordinate to its Cyrillic header letter. + Position 13's header glyph is PUA (U+E519) in the text layer and + was visually identified at 10x as h with comma below (U+0068 + U+0322), the plain-h counterpart of position 12's hooktop-h symbol." + } +} + +tests { + "a" -> "a" + "б" -> "b" + "в" -> "v" + "г" -> "g" +} + + source_script Cyrl + parallel { + sub "a" "a" + sub "б" "b" + sub "в" "v" + sub "г" "g" + sub "д" "d" + sub "е" "e" + sub "ĕ" "ĕ" + sub "ё" "ё" + sub "ж" "ž" + sub "з" "z" + sub "и" "i" + sub "й" "j" + sub "к" "k" + sub "л" "l" + sub "м" "m" + sub "н" "n" + sub "ҥ" "" + sub "о" "o" + sub "ŏ" "ŏ" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "т" "t" + sub "у" "u" + sub "ф" "f" + sub "х" "h" + sub "ц" "c" + sub "ч" "č" + sub "ш" "š" + sub "щ" "šč" + sub "ъ" "\"" + sub "ы" "y" + sub "ы̆" "y̆" + sub "ь" "'" + sub "э" "ė" + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0115/map.isc b/scripts/fuzz/smoke-cases/mutation-0115/map.isc new file mode 100644 index 0000000..3138e73 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0115/map.isc @@ -0,0 +1,187 @@ +system "BGN-PCGN:av-Cyrl:Latn:2011" { + +metadata { + authority_id bgnpcgn + id 2011 + language iso-639-1:av + source_script Cyrl + destination_script Latn + name Romanization of Avar (BGN/PCGN 2011 System) + url https://geonames.nga.mil/gns/html/Romanization/ROMANIZATION%20OF%20AVAR.pdf + creation_date 2011 + confirmation_date 2017-10 + description { The BGN/PCGN system for Avar is designed for use in romanizing names written + in the Avar Cyrillic alphabet. Avar is a consonant-rich north-eastern Caucasian language, + spoken principally in Russia’s republic of Dagestan. It has been written in a modified + Cyrillic script since 1938 and, as other Caucasian languages, features glottalised + consonants, and though these are not marked with a uniform marker in Avar Cyrillic, an + apostrophe denotes the glottalised form of consonants in this romanization table. + } + + notes { + note "Е should be romanized ‘ye’ word-initially, and after a vowel, and ‘e’ elsewhere." + note "In order to retain reversibility, where two consonant characters appear together and the resulting romanization is equivalent to a Roman-script digraph occurring in the system (i.e. gh, zh, tl, sh or ts), a medial dot may be employed between the Roman-script consonants (e.g. g·h) in order to distinguish these from the Roman-script digraphs." + note "Ё, Ф, Ъ, Ы and Ь occur only in loanwords, except as they appear in character combinations addressed elsewhere in the table, and are represented in the same style as in the BGN/PCGN Romanization System for Russian." + note "An inventory of letter-diacritic combinations, with their Unicode encoding, in addition to the unmodified letters of the basic Roman script is:\n\nAll apostrophes appearing in romanization are U+2019\n\nĠ (U+0047+0307) ġ (U+0067+0307)\nË (U+00CB) ë (U+00EB)" + note "The Romanization columns show only lowercase forms but, when romanizing, uppercase and lowercase Roman letters as appropriate should be used." + } +} + +tests { + "МагӀарул" -> "Mag\u0307arul" + "магӀу" -> "mag\u0307u" + "Дагъистан" -> "Daghistan" + "авал" -> "awal" + "кьибил" -> "tl’ibil" + "лъимер" -> "lhimer" + "лъагӀал" -> "lhag\u0307al" + "чӀужу" -> "ch’uzhu" + "цӀар" -> "ts’ar" + "рухӀ" -> "ruh\u0331" + "тӀехь" -> "t’ekh" + "гьабе" -> "habe" + "гьечӀо" -> "hech’o" + "емен" -> "yemen" + "дуе" -> "duye" + "Емен" -> "Yemen" + "щу" -> "shshu" + "рукъ" -> "ruq’" + "хъизан" -> "qizan" + "жо" -> "zho" + "ши" -> "shi" +} + +aliases { + av_vowel = any("АаЕеЁёИиОоУуЫыЭэЮюЯя") +} + +stage main { + + # RULES + # note[1]: ‘ye’ word-initially and after a vowel, ‘e’ elsewhere + sub { + from "\u0415" + to "YЕ" + before av_vowel + } + sub { + from "\u0415" + to "Yе" + before boundary + } + sub { + from "\u0435" + to "yе" + before av_vowel + } + sub { + from "\u0435" + to "yе" + before boundary + } + + # CHARACTERS + parallel { + sub "А" "A" + sub "а" "a" + sub "Б" "B" + sub "б" "b" + sub "В" "W" + sub "в" "w" + sub "Г" "G" + sub "г" "g" + sub "Гъ" "Gh" + sub "гъ" "gh" + sub "Гь" "H" + sub "гь" "h" + sub "ГӀ" "G\u0307" + sub "гӀ" "g\u0307" + sub "Д" "D" + sub "д" "d" + sub "Е" "E" + sub "е" "e" + sub "Ё" "Ë" + sub "ё" "ë" + sub "Ж" "Zh" + sub "ж" "zh" + sub "З" "Z" + sub "з" "z" + sub "И" "I" + sub "и" "i" + sub "Й" "Y" + sub "й" "y" + sub "К" "K" + sub "к" "k" + sub "Къ" "Q’" + sub "къ" "q’" + sub "Кь" "Tl’" + sub "кь" "tl’" + sub "КӀ" "K’" + sub "кӀ" "k’" + sub "Л" "L" + sub "л" "l" + sub "Лъ" "Lh" + sub "лъ" "lh" + sub "ЛӀ" "Tl" + sub "лӀ" "tl" + sub "М" "M" + sub "м" "m" + sub "Н" "N" + sub "н" "n" + sub "О" "O" + sub "о" "o" + sub "П" "P" + sub "п" "p" + sub "Р" "R" + sub "р" "r" + sub "С" "S" + sub "с" "s" + sub "Т" "T" + sub "т" "t" + sub "ТӀ" "T’" + sub "тӀ" "t’" + sub "У" "U" + sub "у" "u" + sub "Ф" "F" + sub "ф" "f" + sub "Х" "X" + sub "х" "x" + sub "Хъ" "Q" + sub "хъ" "q" + sub "Хь" "Kh" + sub "хь" "kh" + sub "ХӀ" "H\u0331" + sub "хӀ" "h\u0331" + sub "Ц" "Ts" + sub "ц" "ts" + sub "ЦӀ" "Ts’" + sub "цӀ" "ts’" + sub "Ч" "Ch" + sub "ч" "ch" + sub "ЧӀ" "Ch’" + sub "чӀ" "ch’" + sub "Ш" "Sh" + sub "ш" "sh" + sub "Щ" "Shsh" + sub "щ" "shsh" + sub "Ъ" "\u2019\u2019" + sub "ъ" "\u2019\u2019" + sub "Ы" "Y" + ruleset fr3 { + parallel { sub "a" "b" } + } + sub "ы" "y" + ruleset fr6 { + parallel { sub "a" "b" } + } + sub "Ь" "\u2019" + sub "ь" "\u2019" + sub "Э" "E" + sub "э" "e" + sub "Ю" "Yu" + sub "ю" "yu" + sub "Я" "Ya" + sub "я" "ya" + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0116/map.isc b/scripts/fuzz/smoke-cases/mutation-0116/map.isc new file mode 100644 index 0000000..99eeca1 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0116/map.isc @@ -0,0 +1,21 @@ +system "BGN-PCGN:iu-Cans:Latn:2013" { + +metadata { + authority_id bgnpcgn + id 2013 + language iso-639-2:iu + source_script Cans + destination_script Latn + name Romanization of Inuktitut (2013 Agreement) + url https://www.gov.uk/government/organisations/permanent-committee-on-geographical-names + creation_date 2013 + confirmation_date 2018-06 + description { + The BGN/PCGN system for Inuktitut romanizes Canadian Aboriginal Syllabics + (qaniujaaqpait) used for geographic names in Nunavut. The syllabic chart was + approved by the Inuit Cultural Institute at Arviat in 1976. The BGN/PCGN + agreement is dated 2013 and was checked for validity and accuracy in June 2018. + } + + notes { + note "Syllabics are official for geographic names only in Nunavut, Canada. The 1976 chart applies to all Inuktitut dia \ No newline at end of file diff --git a/scripts/fuzz/smoke-cases/mutation-0117/map.isc b/scripts/fuzz/smoke-cases/mutation-0117/map.isc new file mode 100644 index 0000000..47bb0cb --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0117/map.isc @@ -0,0 +1,267 @@ +system "UN:tam-Taml:Latn:1972" { + +metadata { + authority_id un + id 1972 + language iso-639-2:tam + source_script Taml + destination_script Latn + name Romanization of Tamil -- UNGEGN 4.0 (1972) + url https://www.eki.ee/wgrs/rom1_ta.htm + creation_date 1972 + confirmation_date 2016 + description { The United Nations recommended system was approved in 1972 (II/11) and amended in 1977 (III/12), based on a report prepared by + D. N. Sharma. The tables and their corrections were published in volume II of the conference reports. + + There is no evidence of the use of the system either in India, Sri Lanka or in international cartographic products. + + Tamil uses an alphasyllabic script whereby each character represents a syllable rather than one sound. Vowels and diphthongs + are marked in two ways: as independent characters (used syllable-initially) and in an abbreviated form, to denote vowels after + consonants. The romanization table is unambiguous. The system is on the whole reversible. + } + + notes { + + note " ஜி Variation: டி ṭi." + note " ஜீ Variation: டீ ṭī." + note " ஜு Variations: கு ku, ஙு ṅu, சு chu, ஞு ñu, டு ṭu, ணு ṇu, து tu, நு nu, பு pu, மு mu, யு yu, ரு ru, லு lu, etc." + note " ஜூ Variations: கூ kū, ஙூ ṅū, சூ chū, ஞூ ñū, டூ ṭū, ணூ ṇū, தூ tū, நூ nū, பூ pū, மூ mū, etc." + note " ஃ Absent in the original table." + note " ் Pronunciation without a vowel: க் k." + note " ஜ, ஶ, ஸ, ன Characters borrowed from the Grantha script." + note " ஸ Special syllable character: ஸ்ரீ srī." + note "Diffed against the UN Romanization of Tamil for Geographical Names table as\n published in the WGRS Report on the Current Status of UN Romanization Systems\n for Geographical Names, version 4.0 (February 2013) (eki.ee/wgrs/rom1_ta.htm;\n also unstats wgrr4tamil): all independent vowels, vowel signs, other symbols and\n consonants verified; no gaps or divergences." + } + +} + +tests { + "அழிந்து போன நகரத்தில் , தொலைந்து போன நான்" -> "al̮intu poṉa nakarattil , tŏlaintu poṉa nāṉ" + "முதன் முதலாக - மை ஃபர்ஸ்ட் சோ࠲ோ ட்ராவல்" -> "mutaṉ mutalāka - mai ḥparsṭ cholo ṭrāval" + "வாழ்க்கையில் அவன் போன முதல் சோலோ டிரிப் அது தான்." -> "vāl̮kkaiyil avaṉ poṉa mutal cholo ṭirip atu tāṉ." + "ஸ்கூல் ப்ரெண்ட் கார்த்திக் வீட்டுக்கு போய்ட்டு" -> "skūl prĕṇṭ kārttik vīṭṭukku poyṭṭu" + "நாசா வெளியிட்ட வெடிக்கும் நட்சத்திரத்தின் வீடியோ" -> "nāchā vĕḷiyiṭṭa vĕṭikkum naṭchattirattiṉ vīṭiyo" + "டார்பிடோவை ஏவ உதவும் சூப்பர்சானிக் ஏவுகணையான ஸ்மார்ட் சோதனை வெற்றி" -> "ṭārpiṭovai eva utavum chūpparchāṉik evukaṇaiyāṉa smārṭ chotaṉai vĕṟṟi" + "இந்த ஆண்டு மருத்துவத்துக்கான நோபல் பரிசு பெறுபவர்களின் பெயர்கள் அறிவிப்பு" -> "inta āṇṭu maruttuvattukkāṉa nopal parichu pĕṟupavarkaḷiṉ pĕyarkaḷ aṟivippu" + "மல்லையா விவகாரம்: பிரிட்டன் அரசின் நடவடிக்கைகள் தங்களுக்கு தà¯ðரியவில்லை - மத்திய அரசு தகவல்" -> "mallaiyā vivakāram: piriṭṭaṉ arachiṉ naṭavaṭikkaikaḷ taṅkaḷukku tĕriyavillai - mattiya arachu takaval" + "ஆலோசனைக்குப் பிறà•ு தேனியில் இருந்து சென்னை புறப்பட்டார் துணை முதலமைச்சர் பன்னீர்செல்வம்" -> "ālochaṉaikkup piṟaku teṉiyil iruntu chĕṉṉai puṟappaṭṭār tuṇai mutalamaichchar paṉṉīrchĕlvam" + "இன்று தான் பேரன் பிறந்தநாள் முடிந்து ஃப்ரீ ஆகி இருக்கிறேன்" -> "iṉṟu tāṉ peraṉ piṟantanāḷ muṭintu ḥprī āki irukkiṟeṉ" + + # Note: UN card expects this to start with an uppercase letter, but that would break other tests + "தமிழ்நாடு" -> "tamil̮nāṭu" + "இலங்கை" -> "ilaṅkai" +} + +aliases { + taml_chars_1 = any("\u0bbe\u0bbf\u0bc0\u0bc1\u0bc2\u0bc6\u0bc7\u0bc8\u0bca\u0bcb\u0bcc\u25cc\u0bcd") +} + +stage main { + + # RULES + sub { + from "க" + to "k" + after taml_chars_1 + } + sub { + from "ங" + to "ṅ" + after taml_chars_1 + } + sub { + from "ச" + to "ch" + after taml_chars_1 + } + sub { + from "ஞ" + to "ñ" + after taml_chars_1 + } + sub { + from "ட" + to "ṭ" + after taml_chars_1 + } + sub { + from "ண" + to "ṇ" + after taml_chars_1 + } + sub { + from "த" + to "t" + after taml_chars_1 + } + sub { + from "ந" + to "n" + after taml_chars_1 + } + sub { + from "ப" + to "p" + after taml_chars_1 + } + sub { + from "ம" + to "m" + after taml_chars_1 + } + sub { + from "ய" + to "y" + after taml_chars_1 + } + sub { + from "ர" + to "r" + after taml_chars_1 + } + sub { + from "ல" + to "l" + after taml_chars_1 + } + sub { + from "வ" + to "v" + after taml_chars_1 + } + sub { + from "ழ" + to "l̮" + after taml_chars_1 + } + sub { + from "ள" + to "ḷ" + after taml_chars_1 + } + sub { + from "ற" + to "ṟ" + after taml_chars_1 + } + sub { + from "ன" + to "ṉ" + after taml_chars_1 + } + sub { + from "ஜ" + to "j" + after taml_chars_1 + } + sub { + from "ஶ" + to "sh" + after taml_chars_1 + } + sub { + from "ஷ" + to "ṣh" + after taml_chars_1 + } + sub { + from "ஸ" + to "s" + after taml_chars_1 + } + sub { + from "ஹ" + to "h" + after taml_chars_1 + } + + + + # CHARACTERS + parallel { + sub "அ" "a" + sub "ஆ" "ā" + sub "ா" "ā" + + sub "இ" "i" + sub "ி" "i" + + sub "ஈ" "ī" + sub "ீ" "ī" + + sub "உ" "u" + sub "ு" "u" + + sub "ஊ" "ū" + sub "ூ" "ū" + + sub "ெ" "ĕ" + sub "எ" "ĕ" + + sub "ே" "e" + sub "ஏ" "e" + + sub "ஐ" "ai" + sub "ை" "ai" + + sub "ஒ" "ŏ" + sub "ொ" "ŏ" + + sub "ோ" "o" + sub "ஓ" "o" + + sub "ஔ" "au" + sub "ௌ" "au" + + sub "ஃ" "ḥ" + sub "்" "" + + sub "க" "ka" + sub "ங" "ṅa" + sub "ச" "cha" + sub "ஞ" "ña" + sub "ட" "ṭa" + sub "ண" "ṇa" + sub "த" "ta" + sub "ந" "na" + sub "ப" "pa" + sub "ம" "ma" + sub "ய" "ya" + sub "ர" "ra" + sub "ல" "la" + sub "வ" "va" + sub "ழ" "l̮a" + sub "ள" "ḷa" + sub "ற" "ṟa" + sub "ன" "ṉa" + sub "ஜ" "ja" + sub "ஶ" "sha" + sub "ஷ" "ṣha" + sub "ஸ" "sa" + sub "ஹ" "ha" + sub "க்ஷ" "kṣha" + sub "ற்ற" "ṟṟa" + sub "ன்ற" "ṉṟa" + + # Digits + sub "௧" "1" + sub "௨" "2" + sub "௩" "3" + sub "௪" "4" + sub "௫" "5" + sub "௬" "6" + sub "௭" "7" + sub "௮" "8" + sub "௯" "9" + sub "௦" "0" + sub "௰" "10" + sub "௱" "100" + sub "௲" "1000" + + sub "‍" "" + sub "‌" "" + } + + compose +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0119/map.isc b/scripts/fuzz/smoke-cases/mutation-0119/map.isc new file mode 100644 index 0000000..fb15328 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0119/map.isc @@ -0,0 +1,145 @@ +system "BGN-PCGN:ukr-Cyrl:Latn:1965" { + +metadata { + authority_id bgnpcgn + id 1965 + language iso-639-2:ukr + source_script Cyrl + destination_script Latn + name Romanization of Ukrainian (1965) + url https://assets.publishing.service.gov.uk/government/uploads/system/uploads/attachment_data/file/816788/ROMANIZATION_OF_UKRAINIAN.pdf + creation_date 1947 + confirmation_date 2019-06 + description { The BGN/PCGN system for Ukrainian was designed for use in romanizing + names written in the Ukrainian alphabet. The Ukrainian alphabet + contains five characters not present in the Russian alphabet: ґ, є, і, + ї, and ’. + } + + notes { + note "The character sequences з г, к г, с г, т с and ц г and may be romanized z∙h, k∙h, s∙h, t∙s and ts∙h in order to differentiate those romanizations from the digraphs zh, kh, sh, ts, and the letter sequence tsh, which are used to render the characters ж, x, ц, ш, and the character sequence тш." + note "All apostrophes appearing in romanization are Unicode encoding 2019." + note "The Roman‐script columns show only lowercase forms but, when applying the table, uppercase and lowercase Roman letters as appropriate should be used." + } +} + +tests { + "Авдіївська Міськрада" -> "Avdiyivs’ka Mis’krada" + "Бабаї" -> "Babayi" + "Віленька" -> "Vilen’ka" + "Гагарінський Район" -> "Haharins’kyy Rayon" + "Довбушева Криниця" -> "Dovbusheva Krynytsya" + "Дідівщина" -> "Didivshchyna" + "Економічна" -> "Ekonomichna" + "Єфросинівка" -> "Yefrosynivka" + "Жигуліна Роща" -> "Zhyhulina Roshcha" + "Загір’я" -> "Zahir”ya" + "З’єднувальний Канал" -> "Z”yednuval’nyy Kanal" + "Ивахи" -> "Yvakhy" + "Івано-Франківська Міськрада" -> "Ivano-Frankivs’ka Mis’krada" + "Їжаківка" -> "Yizhakivka" + "Йосиповичі" -> "Yosypovychi" + "Кабичівка" -> "Kabychivka" + "Лазуровий Провулок" -> "Lazurovyy Provulok" + "Мала Сейдеминуха" -> "Mala Seydemynukha" + "Нагірний" -> "Nahirnyy" + "Овер’янівське Озеро" -> "Over”yanivs’ke Ozero" + "Павлопільське Водосховище" -> "Pavlopil’s’ke Vodoskhovyshche" + "Приґородний" -> "Prygorodnyy" + "Радгосп Правда" -> "Radhosp Pravda" + "Садово-Хрустальненський" -> "Sadovo-Khrustal’nens’kyy" + "Таратутине" -> "Taratutyne" + "Улу-Узень" -> "Ulu-Uzen’" + "Христофорівка" -> "Khrystoforivka" + "Центральна Вулиця" -> "Tsentral’na Vulytsya" + "Чайковичі" -> "Chaykovychi" + "Шалаші" -> "Shalashi" + "Щербинівка" -> "Shcherbynivka" + "Южноукраїнська Міськрада" -> "Yuzhnoukrayins’ka Mis’krada" + "Ясениця" -> "Yasenytsya" +} + +stage main { + + # RULES + sub { + from boundary + "\u2019" + boundary + to "”" + } + + + # CHARACTERS + parallel { + sub "а" "a" + sub "б" "b" + sub "в" "v" + sub "г" "h" + sub "д" "d" + sub "е" "e" + sub "ж" "zh" + sub "з" "z" + sub "и" "y" + sub "й" "y" + sub "к" "k" + sub "л" "l" + sub "м" "m" + sub "н" "n" + sub "о" "o" + sub "о" "o" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "с" "s" + sub "т" "t" + sub "у" "u" + sub "ф" "f" + sub "х" "kh" + sub "ц" "ts" + sub "ч" "ch" + sub "ш" "sh" + sub "щ" "shch" + sub "ь" "’" + sub "ю" "yu" + sub "я" "ya" + sub "є" "ye" + sub "і" "i" + sub "ї" "yi" + sub "ґ" "g" + sub "" " " + sub "Є" "Ye" + sub "І" "I" + sub "Ї" "Yi" + sub "А" "A" + sub "Б" "B" + sub "В" "V" + sub "Г" "H" + sub "Д" "D" + sub "Е" "E" + sub "Ж" "Zh" + sub "З" "Z" + sub "И" "Y" + sub "Й" "Y" + sub "К" "K" + sub "Л" "L" + sub "М" "M" + sub "Н" "N" + sub "О" "O" + sub "П" "P" + sub "Р" "R" + sub "С" "S" + sub "Т" "T" + sub "У" "U" + sub "Ф" "F" + sub "Х" "Kh" + sub "Ц" "Ts" + sub "Ч" "Ch" + sub "Ш" "Sh" + sub "Щ" "Shch" + sub "Ь" "’" + sub "Ю" "Yu" + sub "Я" "Ya" + sub "Ґ" "G" + } + +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0120/map.isc b/scripts/fuzz/smoke-cases/mutation-0120/map.isc new file mode 100644 index 0000000..6c7c8d7 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0120/map.isc @@ -0,0 +1,79 @@ +system "BAS:rus-Cyrl:Latn:2017-bss" { + +metadata { + authority_id bas + id 2017-bss + language iso-639-2:rus + source_script Cyrl + destination_script Latn + name Streamlined Romanization of Russian Cyrillic (Basic Streamlined System) + url https://www.researchgate.net/publication/318402098 + creation_date 2017-07 + description { The streamlined approach to transliteration was initiated by the + author with the development of the Streamlined System for the + Romanization of Bulgarian, which was eventually codified by the + Transliteration Act of 2009 (ДВ 2009) of the Bulgarian Parliament. + + The four purposes of the system below are in order of priority: + 1. ensure a plausible phonetic approximation of Russian words by English speaking users, including those having no knowledge of the Russian language and no available additional explanations; + 2. the system should allow for the retrieval of the original Cyrillic spellings as much as feasible; + 3. transliterated Russian words should fit an English language environment i.e. not be perceived as too ‘un-English’; and + 4. transliterated word forms should be streamlined and simple. (Ivanov 2003, Ivanov et al. 2010) + } + + notes { + note "Typical for the streamlined approach is its non-use of diacritics,\n its use of Latin y for rendering only Cyrillic й rather than both й and\n ы, its non-use of Latin j, as well as its use of Latin h rather than kh\n for Cyrillic х." + } +} + +tests { + "Эх, тройка! птица тройка, кто тебя выдумал? знать, у бойкого народа\nты могла только родиться, в той земле, что не любит шутить, а\nровнем-гладнем разметнулась на полсвета, да и ступай считать версты, пока\nне зарябит тебе в очи. И не хитрый, кажись, дорожный снаряд, не\nжелезным схвачен винтом, а наскоро живьём с одним топором да долотом\nснарядил и собрал тебя ярославский расторопный мужик. Не в немецких\nботфортах ямщик: борода да рукавицы, и сидит чёрт знает на чём; а\nпривстал, да замахнулся, да затянул песню — кони вихрем, спицы в\nколесах смешались в один гладкий круг, только дрогнула дорога, да вскрикнул\nв испуге остановившийся пешеход — и вон она понеслась, понеслась,\nпонеслась!\n\nН.В. Гоголь" -> "Eh, troyka! ptitsa troyka, kto tebya vidumal? znat, u boykogo naroda\nti mogla tolko roditsya, v toy zemle, chto ne lyubit shutit, a\nrovnem-gladnem razmetnulas na polsveta, da i stupay schitat versti, poka\nne zaryabit tebe v ochi. I ne hitriy, kazhis, dorozhniy snaryad, ne\nzheleznim shvachen vintom, a naskoro zhivyem s odnim toporom da dolotom\nsnaryadil i sobral tebya yaroslavskiy rastoropniy muzhik. Ne v nemetskih\nbotfortah yamshchik: boroda da rukavitsi, i sidit chert znaet na chem; a\nprivstal, da zamahnulsya, da zatyanul pesnyu — koni vihrem, spitsi v\nkolesah smeshalis v odin gladkiy krug, tolko drognula doroga, da vskriknul\nv ispuge ostanovivshiysya peshehod — i von ona poneslas, poneslas,\nponeslas!\n\nN.V. Gogol" + "ЁЖ Ёж ёж" -> "EZH Ezh ezh" + "Цветущий сад" -> "Tsvetushchiy sad" + "Чувство юмора" -> "Chuvstvo yumora" + "Широкий выбор" -> "Shirokiy vibor" + "Все подъезды заблокированны" -> "Vse podezdi zablokirovanni" + "Ожерелье" -> "Ozherelye" + "Ручьи" -> "Ruchyi" + "Каньон" -> "Kanyon" + "Бельэтаж" -> "Belyetazh" +} + +dependency "posix" +dependency "var-kor" + +stage main { + + # RULES + sub { + from "\u042c" + to "Y" + after any("ЕеЁёИиОоЭэ") + } + sub { + from "\u044c" + to "y" + after any("ЕеЁёИиОоЭэ") + } + + + # CHARACTERS + parallel { + # "\u0027": "" # ' + sub "А" "A" + sub "Б" "B" + sub "В" "V" + sub "Г" "G" + sub "Д" "D" + sub "Ё" "E" + sub "Е" "E" + sub "Ж" "Zh" + sub { + from "Ж" + to "ZH" + before any('AБBГДЕЁЖЗИЙКЛМНОПРСТУЎФХЦЧШЩЪЫЬЭЮЯІ') + } + sub { + from "Ж" + to "ZH" + after any('AБBГДЕЁЖЗИЙКЛМНОПРС \ No newline at end of file diff --git a/scripts/fuzz/smoke-cases/mutation-0121/map.isc b/scripts/fuzz/smoke-cases/mutation-0121/map.isc new file mode 100644 index 0000000..709bd58 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0121/map.isc @@ -0,0 +1,76 @@ +system "DIN:nog-Cyrl:Latn:1460-2-2011" { + +metadata { + authority_id din + id 1460-2-2011-44 + language iso-639-3:nog + source_script Cyrl + destination_script Latn + name "DIN 1460-2:2011-10, Tabelle 1 row 44: Nogaisch (Turkic)" + url https://www.beuth.de/de/norm/din-1460-2/134564104 + creation_date 2011 + adoption_date + description { + DIN 1460-2:2011-10, Romanization of Cyrillic alphabets of + non-Slavic languages, Tabelle 1, language row 44 + (Nogaisch). The table assigns each Cyrillic letter of the + language's alphabet a Latin letter or letter group; the column + order follows DIN 1460:1982 (Slavic). Extracted mechanically from + the standard's text layer; the mapping rows below are the table's + own cells. + } + + notes { + note "Extraction provenance: the PDF's text layer carries the full + grid; columns were anchored on the per-page position-number row and + each cell matched by x-coordinate to its Cyrillic header letter. + Position 13's header glyph is PUA (U+E519) in the text layer and + was visually identified at 10x as h with comma below (U+0068 + U+0322), the plain-h counterpart of position 12's hooktop-h symbol." + } +} + +tests { + "a" -> "a" + "б" -> "b" + "в" -> "v" + "г" -> "g" +} + +stage main { + parallel { + sub "a" "a" + sub "б" "b" + sub "в" "v" + sub "г" "g" + sub "д" "d" + sub "е" "e" + sub "ё" "ё" + sub "ж" "ž" + sub "з" "z" + sub "и" "i" + sub "й" "j" + sub "к" "k" + sub "л" "l" + sub "м" "m" + sub "о" "o" + sub "п" "p" + sub "р" "r" + sub "р" "r" + sub "с" "s" + sub "т" "t" + sub "у" "u" + sub "ф" "f" + sub "х" "h" + sub "ц" "c" + sub "ч" "č" + sub "ш" "š" + sub "щ" "šč" + sub "a" "b" + strip + sub "ъ" "\"" + sub "ы" "y" + sub "ь" "'" + sub "э" "ė" + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0122/map.isc b/scripts/fuzz/smoke-cases/mutation-0122/map.isc new file mode 100644 index 0000000..b05df0b --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0122/map.isc @@ -0,0 +1,247 @@ +system "BGN-PCGN:chv-Cyrl:Latn:2011" { + +metadata { + authority_id bgnpcgn + id 2011 + language iso-639-2:chv + source_script Cyrl + destination_script Latn + name Romanization of Chuvash (2011) + url https://www.gov.uk/government/organisations/permanent-committee-on-geographical-names + creation_date 2011 + confirmation_date 2017-10 + description { + The BGN/PCGN system for Chuvash is designed for use in romanizing names written in the + Chuvash Cyrillic alphabet. Chuvash is an official language within Chuvashiya, one of the + republics of the Russian Federation. + } + + notes { + note "The character е should be romanized ye initially, after the vowel characters а, е, ё, и, о, у, ы, э, ю, and я, and after й, ъ, and ь. In all other instances, it should be romanized e." + note "The character ё should be romanized yë initially, after the vowel characters а, е, ё, и, о, у, ы, э, ю, and я, and after й, ъ, and ь. In all other instances, it should be romanized ё. Often the diaeresis is not shown in Cyrillic, and in this case, the character should be romanized as ë/yë, as outlined above, if known to be relevant, or otherwise e/ye as described in the first note." + note "The source document presents the letter Ҫ/ҫ with the codepoints U+00C7/U+00E7 (Latin C with cedilla) in its text layer; the standard Chuvash Cyrillic codepoints are U+04AA/U+04AB. This map accepts both pairs and romanizes them ś." + note "An inventory of letter-diacritic combinations, with their Unicode encoding, in addition to the unmodified letters of the basic Roman script is:" + note "Ă (U+0102) ă (U+0103) Ë (U+00CB) ë (U+00EB) Ĕ (U+0114) ĕ (U+0115) Ś (U+015A) ś (U+015B) Ü (U+00DC) ü (U+00FC) Ė (U+0116) ė (U+0117)" + note "The Romanization columns show only lowercase forms but, when romanizing, uppercase and lowercase Roman letters as appropriate should be used." + } +} + +tests { + # every table row, upper and lower + "А" -> "A" + "а" -> "a" + "Ӑ" -> "Ă" + "ӑ" -> "ă" + "Б" -> "B" + "б" -> "b" + "В" -> "V" + "в" -> "v" + "Г" -> "G" + "г" -> "g" + "Д" -> "D" + "д" -> "d" + "Е" -> "Ye" + "е" -> "ye" + "Ё" -> "Yë" + "ё" -> "yë" + "Ӗ" -> "Ĕ" + "ӗ" -> "ĕ" + "Ж" -> "Zh" + "ж" -> "zh" + "З" -> "Z" + "з" -> "z" + "И" -> "I" + "и" -> "i" + "Й" -> "Y" + "й" -> "y" + "К" -> "K" + "к" -> "k" + "Л" -> "L" + "л" -> "l" + "М" -> "M" + "м" -> "m" + sub "э" "ė" + } +} +} + + "Н" -> "N" + "н" -> "n" + "О" -> "O" + "о" -> "o" + "П" -> "P" + "п" -> "p" + "Р" -> "R" + "р" -> "r" + "С" -> "S" + "с" -> "s" + "Ç" -> "Ś" + "ç" -> "ś" + "Ҫ" -> "Ś" + "ҫ" -> "ś" + "Т" -> "T" + "т" -> "t" + "У" -> "U" + "у" -> "u" + "Ӳ" -> "Ü" + "ӳ" -> "ü" + "Ф" -> "F" + "ф" -> "f" + "Х" -> "Kh" + "х" -> "kh" + "Ц" -> "Ts" + "ц" -> "ts" + "Ч" -> "Ch" + "ч" -> "ch" + "Ш" -> "Sh" + "ш" -> "sh" + "Щ" -> "Shch" + "щ" -> "shch" + "Ъ" -> "”" + "ъ" -> "”" + "Ы" -> "Y" + "ы" -> "y" + "Ь" -> "’" + "ь" -> "’" + "Э" -> "Ė" + "э" -> "ė" + "Ю" -> "Yu" + "ю" -> "yu" + "Я" -> "Ya" + "я" -> "ya" + # notes 1-2: ye/yë contexts; ӑ is not in the vowel set + "бе" -> "be" + "ае" -> "aye" + "йе" -> "yye" + "ъе" -> "”ye" + "ье" -> "’ye" + "ӑе" -> "ăe" + "йё" -> "yyë" + "бё" -> "bë" +} + +stage main { + + # RULES + # notes 1-2: е and ё initially, after the listed vowels, and after й, ъ, ь + sub { + from boundary + "Е" + to "Ye" + } + sub { + from boundary + "е" + to "ye" + } + sub { + from "Е" + to "Ye" + before any("АаЕеЁёИиОоУуЫыЭэЮюЯяЙйЪъЬь") + } + sub { + from "е" + to "ye" + before any("АаЕеЁёИиОоУуЫыЭэЮюЯяЙйЪъЬь") + } + sub { + from boundary + "Ё" + to "Yë" + } + sub { + from boundary + "ё" + to "yë" + } + sub { + from "Ё" + to "Yë" + before any("АаЕеЁёИиОоУуЫыЭэЮюЯяЙйЪъЬь") + } + sub { + from "ё" + to "yë" + before any("АаЕеЁёИиОоУуЫыЭэЮюЯяЙйЪъЬь") + } + + # CHARACTERS + parallel { + sub "Щ" "Shch" + sub "Ӳ" "Ü" + sub "Ӗ" "Ĕ" + sub "Ӑ" "Ă" + sub "Ҫ" "Ś" + sub "Ç" "Ś" + sub "Ъ" "”" + sub "Ы" "Y" + sub "Ь" "’" + sub "Э" "Ė" + sub "Ю" "Yu" + sub "Я" "Ya" + sub "А" "A" + sub "Б" "B" + sub "В" "V" + sub "Г" "G" + sub "Д" "D" + sub "Е" "E" + sub "Ё" "Ë" + sub "Ж" "Zh" + sub "З" "Z" + sub "И" "I" + sub "Й" "Y" + sub "К" "K" + sub "Л" "L" + sub "М" "M" + sub "Н" "N" + sub "О" "O" + sub "П" "P" + sub "Р" "R" + sub "С" "S" + sub "Т" "T" + sub "У" "U" + sub "Ф" "F" + sub "Х" "Kh" + sub "Ц" "Ts" + sub "Ч" "Ch" + sub "Ш" "Sh" + + sub "щ" "shch" + sub "ӳ" "ü" + sub "ӗ" "ĕ" + sub "ӑ" "ă" + sub "ҫ" "ś" + sub "ç" "ś" + sub "ъ" "”" + sub "ы" "y" + sub "ь" "’" + sub "э" "ė" + sub "ю" "yu" + sub "я" "ya" + sub "а" "a" + sub "б" "b" + sub "в" "v" + sub "г" "g" + sub "д" "d" + sub "е" "e" + sub "ё" "ë" + sub "ж" "zh" + sub "з" "z" + sub "и" "i" + sub "й" "y" + sub "к" "k" + sub "л" "l" + sub "м" "m" + sub "н" "n" + sub "о" "o" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "т" "t" + sub "у" "u" + sub "ф" "f" + sub "х" "kh" + sub "ц" "ts" + sub "ч" "ch" + sub "ш" "sh" + } + +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0123/map.isc b/scripts/fuzz/smoke-cases/mutation-0123/map.isc new file mode 100644 index 0000000..83b72d7 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0123/map.isc @@ -0,0 +1,246 @@ +system "ODNI:aze-Cyrl:Latn:2015" { + +metadata { + authority_id odni + id 6443 + language iso-639-2:aze + source_script Cyrl + destination_script Latn + name ICS-630-01 Romanization of Azeri Personal Names (2015) + source ICS-630-01 Annex P + creation_date 2015 + confirmation_date 2015 + description { This system is the Intelligence Community standard for the transliteration of Azeri person names + that will be applied to all final written reports and products for IC consumers. It is not + intended to eliminate variations of a name that can contribute forensic information. Rather, it is + to provide an IC standard Romanized (English) transliteration from Azeri that can then be linked + to forensic information in ways that will help identify the referent of the name. + + In cases where an individual’s name has already been transliterated in a variant spelling, the IC + Standard spelling should appear first, followed by the variant spelling(s) in parentheses at the + first usage. In addition, if the original Cyrillic-script spelling is known, that spelling should + also appear in parentheses following the name, if possible, following best practices of the + issuing organization and taking into consideration information system capabilities. For example: + Rashad Sadykhov (also seen as Rashad Sadigov, Рашад Садыхов). This convention is designed to + ensure that vital forensic information is not lost. + + For names of persons who are known to not be part of the Azeri-speaking community, use the + relevant IC transliteration standard for names from that language (e.g., Yitzhak). A translator’s + note may be used to clarify the known origin of the person. Spell names of individuals from + languages that are written in Roman letters as they are spelled in those languages (e.g., + George Clooney, Jorge Garcia, Georges Pompidou). + + In the case of active senior government officials in the on-line CIA World Factbook and the on- + line directory of Chiefs of State and Cabinet Members of Foreign Governments, the spellings given + in these on-line reference works should be used in place of the IC Standard. For any individual + who has at one time been listed in the Factbook or Chiefs of State directory but who no longer + appears in those resources (i.e. is no longer a government official), the IC Standard spelling + should appear first, with the spelling, if known, as it previously appeared in those resources + listed within parentheses at the first usage. + + The primary goal is to produce a consistent Romanized transcription of names that is specifically + readable to the English-speaking non-specialist. The system uses the 26 letters of the standard + (English) Roman alphabet. Some ambiguities in the Romanized form will occur without the use of + diacritics. However, within the context of a report, where additional information about the + individual is provided, the referent will be clearly identified. This system will be used in + conjunction with on-line tools, name dictionaries, and lists containing conventional spellings of + names of well-known individuals. + } + + notes { + note "Transliterate double digraphs as a single digraph, i.e. шш -> sh, not shsh" + note "In the Roman, no distinction is made between digraphs such as 'sh' and single contiguous letters,\n (e.g. 's' followed by 'h')." + note "The Cyrillic ъ and ь are not transliterated, but instead are left out of the transliteration." + } +} + +tests { + "Рашад Садыхов" -> "Rashad Sadykhov" +# Exhaustive per-row tests for odni-aze-Cyrl-Latn-2015, generated from the source +# document's table. +# Source: ICS 630-01 Annex P (ANNEX P - Azeri_Personal_Names_FLTS (U).pdf), +# p. 2 (letter table); held source +# interscript-private-references/ics-630-01/ANNEX P - +# Azeri_Personal_Names_FLTS (U).pdf. Extraction: annex text layer, every +# value cell cross-checked against the rendered page image. Cells "г, ҝ", +# "й, ј" and "у, ү" (one value cell naming two keys) transcribed as two rows +# each. The value cells for е and э print the Latin letter e; the text layer +# stores the lookalike Cyrillic е (U+0435) — values transcribed from the +# printed image. General Notes (below the table): double digraphs as a +# single digraph (шш -> sh); ъ and ь are not transliterated. +# Provenance artifact: scripts/row-sources/odni-aze-Cyrl-Latn-2015.json (38 rows). +# generated-by: maps/scripts/gen-row-tests.mjs (2026-11-16); regenerate from the artifact, do not hand-edit. + "а" -> "a" + "б" -> "b" + "в" -> "v" + "г" -> "g" + alias_decl = any("a") + swapcase2 = any("b") + "ҝ" -> "g" + "ғ" -> "gh" + "д" -> "d" + "е" -> "e" + "ё" -> "yo" + "ә" -> "a" + "ж" -> "zh" + "з" -> "z" + "и" -> "i" + "й" -> "y" + "ј" -> "y" + "к" -> "k" + "л" -> "l" + "м" -> "m" + "н" -> "n" + "о" -> "o" + "ө" -> "o" + "п" -> "p" + "р" -> "r" + "с" -> "s" + "т" -> "t" + "у" -> "u" + "ү" -> "u" + "ф" -> "f" + "х" -> "kh" + "һ" -> "h" + "ч" -> "ch" + "ҹ" -> "j" + "ш" -> "sh" + "щ" -> "shch" + "ы" -> "y" + "э" -> "e" + "ю" -> "yu" + "я" -> "ya" +} + +stage main { + + # RULES + # note[1] + # generated with: "ҒЁЖХЧШЩЮЯ".split("").each { |i| puts %{sub capture(any("#{i}#{i.downcase}"))+any("#{i}#{i.downcase}"), ref(1)} } + sub { + from capture(any("Ғғ")) + any("Ғғ") + to ref(1) + } + sub { + from capture(any("Ёё")) + any("Ёё") + to ref(1) + } + sub { + from capture(any("Жж")) + any("Жж") + to ref(1) + } + sub { + sub "\u{0E01}" "X" + from capture(any("Хх")) + any("Хх") + to ref(1) + } + sub { + from capture(any("Чч")) + any("Чч") + to ref(1) + } + sub { + from capture(any("Шш")) + any("Шш") + to ref(1) + } + sub { + from capture(any("Щщ")) + any("Щщ") + to ref(1) + } + sub { + from capture(any("Юю")) + any("Юю") + to ref(1) + } + sub { + from capture(any("Яя")) + any("Яя") + to ref(1) + } + # note[3] + sub { + from any("\u044A\u044C") + to none + } + + + # CHARACTERS + parallel { + sub "\u0410" "A" + sub "\u0411" "B" + sub "\u0412" "V" + sub "\u0413" "G" + sub "\u049C" "G" + sub "\u0492" "Gh" + sub "\u0414" "D" + sub "\u0415" "E" + sub "\u0401" "Yo" + sub "\u04D8" "A" + sub "\u0416" "Zh" + sub "\u0417" "Z" + sub "\u0418" "I" + sub "\u0419" "Y" + sub "\u0408" "Y" + sub "\u041A" "K" + sub "\u041B" "L" + sub "\u041C" "M" + sub "\u041D" "N" + sub "\u041E" "O" + sub "\u04E8" "O" + sub "\u041F" "P" + sub "\u0420" "R" + sub "\u0421" "S" + sub "\u0422" "T" + sub "\u0423" "U" + sub "\u04AE" "U" + sub "\u0424" "F" + sub "\u0425" "Kh" + sub "\u04BA" "H" + sub "\u0427" "Ch" + sub "\u04B8" "J" + sub "\u0428" "Sh" + sub "\u0429" "Shch" + sub "\u042B" "Y" + sub "\u042D" "E" + sub "\u042E" "Yu" + sub "\u042F" "Ya" + + sub "\u0430" "a" + sub "\u0431" "b" + sub "\u0432" "v" + sub "\u0433" "g" + sub "\u049D" "g" + sub "\u0493" "gh" + sub "\u0434" "d" + sub "\u0435" "e" + sub "\u0451" "yo" + sub "\u04D9" "a" + sub "\u0436" "zh" + sub "\u0437" "z" + sub "\u0438" "i" + sub "\u0439" "y" + sub "\u0458" "y" + sub "\u043A" "k" + sub "\u043B" "l" + sub "\u043C" "m" + sub "\u043D" "n" + sub "\u043E" "o" + sub "\u04E9" "o" + sub "\u043F" "p" + sub "\u0440" "r" + sub "\u0441" "s" + sub "\u0442" "t" + sub "\u0443" "u" + sub "\u04AF" "u" + sub "\u0444" "f" + sub "\u0445" "kh" + sub "\u04BB" "h" + sub "\u0447" "ch" + sub "\u04B9" "j" + sub "\u0448" "sh" + sub "\u0449" "shch" + sub "\u044B" "y" + sub "\u044D" "e" + sub "\u044E" "yu" + sub "\u044F" "ya" + } + +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0124/map.isc b/scripts/fuzz/smoke-cases/mutation-0124/map.isc new file mode 100644 index 0000000..1d9a900 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0124/map.isc @@ -0,0 +1,82 @@ +system "DIN:kv-Cyrl:Latn:1460-2-2011" { + +metadata { + authority_id din + id 1460-2-2011-28 + language iso-639-3:kv + source_script Cyrl + destination_script Latn + name "DIN 1460-2:2011-10, Tabelle 1 row 28: Komi-Syrjänisch (Uralic)" + url https://www.beuth.de/de/norm/din-1460-2/134564104 + creation_date 2011 + adoption_date + description { + DIN 1460-2:2011-10, Romanization of Cyrillic alphabets of + non-Slavic languages, Tabelle 1, language row 28 + (Komi-Syrjänisch). The table assigns each Cyrillic letter of the + language's alphabet a Latin letter or letter group; the column + order follows DIN 1460:1982 (Slavic). Extracted mechanically from + the standard's text layer; the mapping rows below are the table's + own cells. + } + + notes { + note "Extraction provenance: the PDF's text layer carries the full + grid; columns were anchored on the per-page position-number row and + each cell matched by x-coordinate to its Cyrillic header letter. + Position 13's header glyph is PUA (U+E519) in the text layer and + was visually identified at 10x as h with comma below (U+0068 + U+0322), the plain-h counterpart of position 12's hooktop-h symbol." + } +} + +tests { + "a" -> "a" + "б" -> "b" + "в" -> "v" + "г" -> "g" + +stage main { + parallel { + sub "a" "a" + sub "б" "b" + sub "в" "v" + sub "г" "g" + sub "д" "d" + sub "е" "e" + sub "ё" "ё" + sub "ж" "ž" + sub "ж̢" "ǧ" + sub "з" "z" + sub "з̧" "z̧" + sub "и" "i" + sub "й" "j" + sub "i" "í" + sub "к" "k" + sub "л" "l" + sub "м" "m" + sub "н" "n" + sub "о" "o" + sub "ӧ" "ö" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "т" "t" +stage main { + + run map.devalatn.stage.main + +} + sub "у" "u" + sub "ф" "f" + sub "х" "h" + sub "ц" "c" + sub "ч" "č" + sub "ш" "š" + sub "щ" "šč" + sub "ъ" "\"" + sub "ы" "y" + sub "ь" "'" + sub "э" "ė" + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0126/map.isc b/scripts/fuzz/smoke-cases/mutation-0126/map.isc new file mode 100644 index 0000000..62aff7e --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0126/map.isc @@ -0,0 +1,908 @@ +system "ALA-LC:shn-Shan:Latn:2012" { + +metadata { + authority_id alalc + id 2012 + language iso-639-2:shn + source_script Shan + destination_script Latn + name "Shan Romanization Table (2012)" + url https://www.loc.gov/catdir/cpso/romanization/shan.pdf + creation_date 2012 + adoption_date + description { ALA-LC Shan Romanization Table. Consonants carry the inherent + vowel a (per Note 2); the full vowel-sign table (the tone-sign + combinations ႆ act as vowel markers: ai āi oi); medials y r v in + their documented order. Transcribed from the loc.gov document's + text layer with the glyph column visually corresponded to the + Shan/Myanmar-extended Unicode blocks (the PDF renders Shan glyphs + through a shape-based substitute font). + } + + notes { + note "The Shan-specific letters (U+1075 ff.) carry the native + values; the Indic-value letters reuse the Myanmar codepoints. Tone + signs 2-6 (U+1087 ff.) beyond the vowel-marking tone-2 are not + romanized." + } +} + +tests { + "\u1075\u102b" -> "kā" +} + +stage main { + parallel { + sub "ေၵ" "ke" + sub "ေၶ" "khe" + sub "ေၷ" "ge" + sub "ေဃ" "ghe" + sub "ေင" "ṅe" + sub "ေၸ" "ce" + sub "ေဆ" "che" + sub "ေၹ" "ze" + sub "ေဇ" "jhe" + sub "ေၺ" "ñe" + sub "ေဋ" "ṭe" + sub "ေဌ" "ṭhe" + sub "ေဍ" "ḍe" + sub "ေဎ" "ḍhe" + sub "ေဏ" "ṇe" + sub "ေတ" "te" + sub "ေႀ" "the" + sub "ေၻ" "de" + sub "ေဒ" "dhe" + sub "ေန" "ne" + sub "ေပ" "pe" + sub "ေဖ" "phe" + sub "ေၿ" "be" + sub "ေဘ" "bhe" + sub "ေမ" "me" + sub "ေယ" "ye" + sub "ေရ" "re" + sub "ေလ" "le" + sub "ေဝ" "ve" + sub "ေသ" "se" + sub "ေဟ" "he" + sub "ေဠ" "ḷe" + sub "ေအ" "ʼe" + sub "ေၾ" "xe" + sub "ေႎ" "fe" + sub "ၵဵ" "ke" + sub "ၶဵ" "khe" + sub "ၷဵ" "ge" + sub "ဃဵ" "ghe" + sub "ငဵ" "ṅe" + sub "ၸဵ" "ce" + sub "ဆဵ" "che" + sub "ၹဵ" "ze" + sub "ဇဵ" "jhe" + sub "ၺဵ" "ñe" + sub "ဋဵ" "ṭe" + sub "ဌဵ" "ṭhe" + sub "ဍဵ" "ḍe" + sub "ဎဵ" "ḍhe" + sub "ဏဵ" "ṇe" + sub "တဵ" "te" + sub "ႀဵ" "the" + sub "ၻဵ" "de" + sub "ဒဵ" "dhe" + sub "နဵ" "ne" + sub "ပဵ" "pe" + sub "ဖဵ" "phe" + sub "ၿဵ" "be" + sub "ဘဵ" "bhe" + sub "မဵ" "me" + sub "ယဵ" "ye" + sub "ရဵ" "re" + sub "လဵ" "le" + sub "ဝဵ" "ve" + sub "သဵ" "se" + sub "ဟဵ" "he" + sub "ဠဵ" "ḷe" + sub "အဵ" "ʼe" + sub "ၾဵ" "xe" + sub "ႎဵ" "fe" + sub "ႄၵ" "kè" + sub "ႄၶ" "khè" + sub "ႄၷ" "gè" + sub "ႄဃ" "ghè" + sub "ႄင" "ṅè" + sub "ႄၸ" "cè" + sub "ႄဆ" "chè" + sub "ႄၹ" "zè" + sub "ႄဇ" "jhè" + sub "ႄၺ" "ñè" + sub "ႄဋ" "ṭè" + sub "ႄဌ" "ṭhè" + sub "ႄဍ" "ḍè" + sub "ႄဎ" "ḍhè" + sub "ႄဏ" "ṇè" + sub "ႄတ" "tè" + sub "ႄႀ" "thè" + sub "ႄၻ" "dè" + sub "ႄဒ" "dhè" + sub "ႄန" "nè" + sub "ႄပ" "pè" + sub "ႄဖ" "phè" + sub "ႄၿ" "bè" + sub "ႄဘ" "bhè" + sub "ႄမ" "mè" + sub "ႄယ" "yè" + sub "ႄရ" "rè" + sub "ႄလ" "lè" + sub "ႄဝ" "vè" + sub "ႄသ" "sè" + sub "ႄဟ" "hè" + sub "ႄဠ" "ḷè" + sub "ႄအ" "ʼè" + sub "ႄၾ" "xè" + sub "ႄႎ" "fè" + sub "ၵႆ" "kai" + sub "ၶႆ" "khai" + sub "ၷႆ" "gai" + sub "ဃႆ" "ghai" + sub "ငႆ" "ṅai" + sub "ၸႆ" "cai" + sub "ဆႆ" "chai" + sub "ၹႆ" "zai" + sub "ဇႆ" "jhai" + sub "ၺႆ" "ñai" + sub "ဋႆ" "ṭai" + sub "ဌႆ" "ṭhai" + sub "ဍႆ" "ḍai" + sub "ဎႆ" "ḍhai" + sub "ဏႆ" "ṇai" + sub "တႆ" "tai" + sub "ႀႆ" "thai" + sub "ၻႆ" "dai" + sub "ဒႆ" "dhai" + sub "နႆ" "nai" + sub "ပႆ" "pai" + sub "ဖႆ" "phai" + sub "ၿႆ" "bai" + sub "ဘႆ" "bhai" + sub "မႆ" "mai" + sub "ယႆ" "yai" + sub "ရႆ" "rai" + sub "လႆ" "lai" + sub "ဝႆ" "vai" + sub "သႆ" "sai" + sub "ဟႆ" "hai" + sub "ဠႆ" "ḷai" + sub "အႆ" "ʼai" + sub "ၾႆ" "xai" + sub "ႎႆ" "fai" + sub "ၵႇႃ" "kāi" + sub "ၶႇႃ" "khāi" + sub "ၷႇႃ" "gāi" + sub "ဃႇႃ" "ghāi" + sub "ငႇႃ" "ṅāi" + sub "ၸႇႃ" "cāi" + sub "ဆႇႃ" "chāi" + sub "ၹႇႃ" "zāi" + sub "ဇႇႃ" "jhāi" + sub "ၺႇႃ" "ñāi" + sub "ဋႇႃ" "ṭāi" + sub "ဌႇႃ" "ṭhāi" + sub "ဍႇႃ" "ḍāi" + sub "ဎႇႃ" "ḍhāi" + sub "ဏႇႃ" "ṇāi" + sub "တႇႃ" "tāi" + sub "ႀႇႃ" "thāi" + sub "ၻႇႃ" "dāi" + sub "ဒႇႃ" "dhāi" + sub "နႇႃ" "nāi" + sub "ပႇႃ" "pāi" + sub "ဖႇႃ" "phāi" + sub "ၿႇႃ" "bāi" + sub "ဘႇႃ" "bhāi" + sub "မႇႃ" "māi" + sub "ယႇႃ" "yāi" + sub "ရႇႃ" "rāi" + sub "လႇႃ" "lāi" + sub "ဝႇႃ" "vāi" + sub "သႇႃ" "sāi" + sub "ဟႇႃ" "hāi" + sub "ဠႇႃ" "ḷāi" + sub "အႇႃ" "ʼāi" + sub "ၾႇႃ" "xāi" + sub "ႎႇႃ" "fāi" + sub "ၵႇာ" "kāi" + sub "ၶႇာ" "khāi" + sub "ၷႇာ" "gāi" + sub "ဃႇာ" "ghāi" + sub "ငႇာ" "ṅāi" + sub "ၸႇာ" "cāi" + sub "ဆႇာ" "chāi" + sub "ၹႇာ" "zāi" + sub "ဇႇာ" "jhāi" + sub "ၺႇာ" "ñāi" + sub "ဋႇာ" "ṭāi" + sub "ဌႇာ" "ṭhāi" + sub "ဍႇာ" "ḍāi" + sub "ဎႇာ" "ḍhāi" + sub "ဏႇာ" "ṇāi" + sub "တႇာ" "tāi" + sub "ႀႇာ" "thāi" + sub "ၻႇာ" "dāi" + sub "ဒႇာ" "dhāi" + sub "နႇာ" "nāi" + sub "ပႇာ" "pāi" + sub "ဖႇာ" "phāi" + sub "ၿႇာ" "bāi" + sub "ဘႇာ" "bhāi" + sub "မႇာ" "māi" + sub "ယႇာ" "yāi" + sub "ရႇာ" "rāi" + sub "လႇာ" "lāi" + sub "ဝႇာ" "vāi" + sub "သႇာ" "sāi" + sub "ဟႇာ" "hāi" + sub "ဠႇာ" "ḷāi" + sub "အႇာ" "ʼāi" + sub "ၾႇာ" "xāi" + sub "ႎႇာ" "fāi" + sub "ၵႂ်" "kái" + sub "ၶႂ်" "khái" + sub "ၷႂ်" "gái" + sub "ဃႂ်" "ghái" + sub "ငႂ်" "ṅái" + sub "ၸႂ်" "cái" + sub "ဆႂ်" "chái" + sub "ၹႂ်" "zái" + sub "ဇႂ်" "jhái" + sub "ၺႂ်" "ñái" + sub "ဋႂ်" "ṭái" + sub "ဌႂ်" "ṭhái" + sub "ဍႂ်" "ḍái" + sub "ဎႂ်" "ḍhái" + sub "ဏႂ်" "ṇái" + sub "တႂ်" "tái" + sub "ႀႂ်" "thái" + sub "ၻႂ်" "dái" + sub "ဒႂ်" "dhái" + sub "နႂ်" "nái" + sub "ပႂ်" "pái" + sub "ဖႂ်" "phái" + sub "ၿႂ်" "bái" + sub "ဘႂ်" "bhái" + sub "မႂ်" "mái" + sub "ယႂ်" "yái" + sub "ရႂ်" "rái" + sub "လႂ်" "lái" + sub "ဝႂ်" "vái" + sub "သႂ်" "sái" + sub "ဟႂ်" "hái" + sub "ဠႂ်" "ḷái" + sub "အႂ်" "ʼái" + sub "ၾႂ်" "xái" + sub "ႎႂ်" "fái" + sub "ၵႆွ" "koi" + sub "ၶႆွ" "khoi" + sub "ၷႆွ" "goi" + sub "ဃႆွ" "ghoi" + sub "ငႆွ" "ṅoi" + sub "ၸႆွ" "coi" + sub "ဆႆွ" "choi" + sub "ၹႆွ" "zoi" + sub "ဇႆွ" "jhoi" + sub "ၺႆွ" "ñoi" + sub "ဋႆွ" "ṭoi" + sub "ဌႆွ" "ṭhoi" + sub "ဍႆွ" "ḍoi" + sub "ဎႆွ" "ḍhoi" + sub "ဏႆွ" "ṇoi" + sub "တႆွ" "toi" + sub "ႀႆွ" "thoi" + sub "ၻႆွ" "doi" + sub "ဒႆွ" "dhoi" + sub "နႆွ" "noi" + sub "ပႆွ" "poi" + sub "ဖႆွ" "phoi" + sub "ၿႆွ" "boi" + sub "ဘႆွ" "bhoi" + sub "မႆွ" "moi" + sub "ယႆွ" "yoi" + sub "ရႆွ" "roi" + sub "လႆွ" "loi" + sub "ဝႆွ" "voi" + sub "သႆွ" "soi" + sub "ဟႆွ" "hoi" + sub "ဠႆွ" "ḷoi" + sub "အႆွ" "ʼoi" + sub "ၾႆွ" "xoi" + sub "ႎႆွ" "foi" + sub "ၵွ" "kau" + sub "ၶွ" "khau" + sub "ၷွ" "gau" + sub "ဃွ" "ghau" + sub "ငွ" "ṅau" + sub "ၸွ" "cau" + sub "ဆွ" "chau" + sub "ၹွ" "zau" + sub "ဇွ" "jhau" + sub "ၺွ" "ñau" + sub "ဋွ" "ṭau" + sub "ဌွ" "ṭhau" + sub "ဍွ" "ḍau" + sub "ဎွ" "ḍhau" + sub "ဏွ" "ṇau" + sub "တွ" "tau" + sub "ႀွ" "thau" + sub "ၻွ" "dau" + sub "ဒွ" "dhau" + sub "နွ" "nau" + sub "ပွ" "pau" + sub "ဖွ" "phau" + sub "ၿွ" "bau" + sub "ဘွ" "bhau" + sub "မွ" "mau" + sub "ယွ" "yau" + sub "ရွ" "rau" + sub "လွ" "lau" + sub "ဝွ" "vau" + sub "သွ" "sau" + sub "ဟွ" "hau" + sub "ဠွ" "ḷau" + sub "အွ" "ʼau" + sub "ၾွ" "xau" + sub "ႎွ" "fau" + sub "ၵုိ" "kui" + sub "ၶုိ" "khui" + sub "ၷုိ" "gui" + sub "ဃုိ" "ghui" + sub "ငုိ" "ṅui" + sub "ၸုိ" "cui" + sub "ဆုိ" "chui" + sub "ၹုိ" "zui" + sub "ဇုိ" "jhui" + sub "ၺုိ" "ñui" + sub "ဋုိ" "ṭui" + sub "ဌုိ" "ṭhui" + sub "ဍုိ" "ḍui" + sub "ဎုိ" "ḍhui" + sub "ဏုိ" "ṇui" + sub "တုိ" "tui" + sub "ႀုိ" "thui" + sub "ၻုိ" "dui" + sub "ဒုိ" "dhui" + sub "နုိ" "nui" + sub "ပုိ" "pui" + sub "ဖုိ" "phui" + sub "ၿုိ" "bui" + sub "ဘုိ" "bhui" + sub "မုိ" "mui" + sub "ယုိ" "yui" + sub "ရုိ" "rui" + sub "လုိ" "lui" + sub "ဝုိ" "vui" + sub "သုိ" "sui" + sub "ဟုိ" "hui" + sub "ဠုိ" "ḷui" + sub "အုိ" "ʼui" + sub "ၾုိ" "xui" + sub "ႎုိ" "fui" + sub "ၵူိ" "kūi" + sub "ၶူိ" "khūi" + sub "ၷူိ" "gūi" + sub "ဃူိ" "ghūi" + sub "ငူိ" "ṅūi" + sub "ၸူိ" "cūi" + sub "ဆူိ" "chūi" + sub "ၹူိ" "zūi" + sub "ဇူိ" "jhūi" + sub "ၺူိ" "ñūi" + sub "ဋူိ" "ṭūi" + sub "ဌူိ" "ṭhūi" + sub "ဍူိ" "ḍūi" + sub "ဎူိ" "ḍhūi" + sub "ဏူိ" "ṇūi" + sub "တူိ" "tūi" + sub "ႀူိ" "thūi" + sub "ၻူိ" "dūi" + sub "ဒူိ" "dhūi" + sub "နူိ" "nūi" + sub "ပူိ" "pūi" + sub "ဖူိ" "phūi" + sub "ၿူိ" "būi" + sub "ဘူိ" "bhūi" + sub "မူိ" "mūi" + sub "ယူိ" "yūi" + sub "ရူိ" "rūi" + sub "လူိ" "lūi" + sub "ဝူိ" "vūi" + sub "သူိ" "sūi" + sub "ဟူိ" "hūi" + sub "ဠူိ" "ḷūi" + sub "အူိ" "ʼūi" + sub "ၾူိ" "xūi" + sub "ႎူိ" "fūi" + sub "ေၵႃ" "ko" + sub "ေၶႃ" "kho" + sub "ေၷႃ" "go" + sub "ေဃႃ" "gho" + sub "ေငႃ" "ṅo" + sub "ေၸႃ" "co" + sub "ေဆႃ" "cho" + sub "ေၹႃ" "zo" + sub "ေဇႃ" "jho" + sub "ေၺႃ" "ño" + sub "ေဋႃ" "ṭo" + sub "ေဌႃ" "ṭho" + sub "ေဍႃ" "ḍo" + sub "ေဎႃ" "ḍho" + sub "ေဏႃ" "ṇo" + sub "ေတႃ" "to" + sub "ေႀႃ" "tho" + sub "ေၻႃ" "do" + sub "ေဒႃ" "dho" + sub "ေနႃ" "no" + sub "ေပႃ" "po" + sub "ေဖႃ" "pho" + sub "ေၿႃ" "bo" + sub "ေဘႃ" "bho" + sub "ေမႃ" "mo" + sub "ေယႃ" "yo" + sub "ေရႃ" "ro" + sub "ေလႃ" "lo" + sub "ေဝႃ" "vo" + sub "ေသႃ" "so" + sub "ေဟႃ" "ho" + sub "ေဠႃ" "ḷo" + sub "ေအႃ" "ʼo" + sub "ေၾႃ" "xo" + sub "ေႎႃ" "fo" + sub "ေၵါ" "ko" + sub "ေၶါ" "kho" + sub "ေၷါ" "go" + sub "ေဃါ" "gho" + sub "ေငါ" "ṅo" + sub "ေၸါ" "co" + sub "ေဆါ" "cho" + sub "ေၹါ" "zo" + sub "ေဇါ" "jho" + sub "ေၺါ" "ño" + sub "ေဋါ" "ṭo" + sub "ေဌါ" "ṭho" + sub "ေဍါ" "ḍo" + sub "ေဎါ" "ḍho" + sub "ေဏါ" "ṇo" + sub "ေတါ" "to" + sub "ေႀါ" "tho" + sub "ေၻါ" "do" + sub "ေဒါ" "dho" + sub "ေနါ" "no" + sub "ေပါ" "po" + sub "ေဖါ" "pho" + sub "ေၿါ" "bo" + sub "ေဘါ" "bho" + sub "ေမါ" "mo" + sub "ေယါ" "yo" + sub "ေရါ" "ro" + sub "ေလါ" "lo" + sub "ေဝါ" "vo" + sub "ေသါ" "so" + sub "ေဟါ" "ho" + sub "ေဠါ" "ḷo" + sub "ေအါ" "ʼo" + sub "ေၾါ" "xo" + sub "ေႎါ" "fo" + sub "ေၵႃ်" "kò" + sub "ေၶႃ်" "khò" + sub "ေၷႃ်" "gò" + sub "ေဃႃ်" "ghò" + sub "ေငႃ်" "ṅò" + sub "ေၸႃ်" "cò" + sub "ေဆႃ်" "chò" + sub "ေၹႃ်" "zò" + sub "ေဇႃ်" "jhò" + sub "ေၺႃ်" "ñò" + sub "ေဋႃ်" "ṭò" + sub "ေဌႃ်" "ṭhò" + sub "ေဍႃ်" "ḍò" + sub "ေဎႃ်" "ḍhò" + sub "ေဏႃ်" "ṇò" + sub "ေတႃ်" "tò" + sub "ေႀႃ်" "thò" + sub "ေၻႃ်" "dò" + sub "ေဒႃ်" "dhò" + sub "ေနႃ်" "nò" + sub "ေပႃ်" "pò" + sub "ေဖႃ်" "phò" + sub "ေၿႃ်" "bò" + sub "ေဘႃ်" "bhò" + sub "ေမႃ်" "mò" + sub "ေယႃ်" "yò" + sub "ေရႃ်" "rò" + sub "ေလႃ်" "lò" + sub "ေဝႃ်" "vò" + sub "ေသႃ်" "sò" + sub "ေဟႃ်" "hò" + sub "ေဠႃ်" "ḷò" + sub "ေအႃ်" "ʼò" + sub "ေၾႃ်" "xò" + sub "ေႎႃ်" "fò" + sub "ၵူဝ်" "kō" + sub "ၶူဝ်" "khō" + sub "ၷူဝ်" "gō" + sub "ဃူဝ်" "ghō" + sub "a" "b" + strip + sub "ငူဝ်" "ṅō" + sub "ၸူဝ်" "cō" + sub "ဆူဝ်" "chō" + sub "ၹူဝ်" "zō" + sub "ဇူဝ်" "jhō" + sub "ၺူဝ်" "ñō" + sub "ဋူဝ်" "ṭō" + sub "ဌူဝ်" "ṭhō" + sub "ဍူဝ်" "ḍō" + sub "ဎူဝ်" "ḍhō" + sub "ဏူဝ်" "ṇō" + sub "တူဝ်" "tō" + sub "ႀူဝ်" "thō" + sub "ၻူဝ်" "dō" + sub "ဒူဝ်" "dhō" + sub "နူဝ်" "nō" + sub "ပူဝ်" "pō" + sub "ဖူဝ်" "phō" + sub "ၿူဝ်" "bō" + sub "ဘူဝ်" "bhō" + sub "မူဝ်" "mō" + sub "ယူဝ်" "yō" + sub "ရူဝ်" "rō" + sub "လူဝ်" "lō" + sub "ဝူဝ်" "vō" + sub "သူဝ်" "sō" + sub "ဟူဝ်" "hō" + sub "ဠူဝ်" "ḷō" + sub "အူဝ်" "ʼō" + sub "ၾူဝ်" "xō" + sub "ႎူဝ်" "fō" + } + + parallel { + sub "ၵႃ" "kā" + sub "ၶႃ" "khā" + sub "ၷႃ" "gā" + sub "ဃႃ" "ghā" + sub "ငႃ" "ṅā" + sub "ၸႃ" "cā" + sub "ဆႃ" "chā" + sub "ၹႃ" "zā" + sub "ဇႃ" "jhā" + sub "ၺႃ" "ñā" + sub "ဋႃ" "ṭā" + sub "ဌႃ" "ṭhā" + sub "ဍႃ" "ḍā" + sub "ဎႃ" "ḍhā" + sub "ဏႃ" "ṇā" + sub "တႃ" "tā" + sub "ႀႃ" "thā" + sub "ၻႃ" "dā" + sub "ဒႃ" "dhā" + sub "နႃ" "nā" + sub "ပႃ" "pā" + sub "ဖႃ" "phā" + sub "ၿႃ" "bā" + sub "ဘႃ" "bhā" + sub "မႃ" "mā" + sub "ယႃ" "yā" + sub "ရႃ" "rā" + sub "လႃ" "lā" + sub "ဝႃ" "vā" + sub "သႃ" "sā" + sub "ဟႃ" "hā" + sub "ဠႃ" "ḷā" + sub "အႃ" "ʼā" + sub "ၾႃ" "xā" + sub "ႎႃ" "fā" + sub "ၵာ" "kā" + sub "ၶာ" "khā" + sub "ၷာ" "gā" + sub "ဃာ" "ghā" + sub "ငာ" "ṅā" + sub "ၸာ" "cā" + sub "ဆာ" "chā" + sub "ၹာ" "zā" + sub "ဇာ" "jhā" + sub "ၺာ" "ñā" + sub "ဋာ" "ṭā" + sub "ဌာ" "ṭhā" + sub "ဍာ" "ḍā" + sub "ဎာ" "ḍhā" + sub "ဏာ" "ṇā" + sub "တာ" "tā" + sub "ႀာ" "thā" + sub "ၻာ" "dā" + sub "ဒာ" "dhā" + sub "နာ" "nā" + sub "ပာ" "pā" + sub "ဖာ" "phā" + sub "ၿာ" "bā" + sub "ဘာ" "bhā" + sub "မာ" "mā" + sub "ယာ" "yā" + sub "ရာ" "rā" + sub "လာ" "lā" + sub "ဝာ" "vā" + sub "သာ" "sā" + sub "ဟာ" "hā" + sub "ဠာ" "ḷā" + sub "အာ" "ʼā" + sub "ၾာ" "xā" + sub "ႎာ" "fā" + sub "ၵါ" "kā" + sub "ၶါ" "khā" + sub "ၷါ" "gā" + sub "ဃါ" "ghā" + sub "ငါ" "ṅā" + sub "ၸါ" "cā" + sub "ဆါ" "chā" + sub "ၹါ" "zā" + sub "ဇါ" "jhā" + sub "ၺါ" "ñā" + sub "ဋါ" "ṭā" + sub "ဌါ" "ṭhā" + sub "ဍါ" "ḍā" + sub "ဎါ" "ḍhā" + sub "ဏါ" "ṇā" + sub "တါ" "tā" + sub "ႀါ" "thā" + sub "ၻါ" "dā" + sub "ဒါ" "dhā" + sub "နါ" "nā" + sub "ပါ" "pā" + sub "ဖါ" "phā" + sub "ၿါ" "bā" + sub "ဘါ" "bhā" + sub "မါ" "mā" + sub "ယါ" "yā" + sub "ရါ" "rā" + sub "လါ" "lā" + sub "ဝါ" "vā" + sub "သါ" "sā" + sub "ဟါ" "hā" + sub "ဠါ" "ḷā" + sub "အါ" "ʼā" + sub "ၾါ" "xā" + sub "ႎါ" "fā" + sub "ၵိ" "ki" + sub "ၶိ" "khi" + sub "ၷိ" "gi" + sub "ဃိ" "ghi" + sub "ငိ" "ṅi" + sub "ၸိ" "ci" + sub "ဆိ" "chi" + sub "ၹိ" "zi" + sub "ဇိ" "jhi" + sub "ၺိ" "ñi" + sub "ဋိ" "ṭi" + sub "ဌိ" "ṭhi" + sub "ဍိ" "ḍi" + sub "ဎိ" "ḍhi" + sub "ဏိ" "ṇi" + sub "တိ" "ti" + sub "ႀိ" "thi" + sub "ၻိ" "di" + sub "ဒိ" "dhi" + sub "နိ" "ni" + sub "ပိ" "pi" + sub "ဖိ" "phi" + sub "ၿိ" "bi" + sub "ဘိ" "bhi" + sub "မိ" "mi" + sub "ယိ" "yi" + sub "ရိ" "ri" + sub "လိ" "li" + sub "ဝိ" "vi" + sub "သိ" "si" + sub "ဟိ" "hi" + sub "ဠိ" "ḷi" + sub "အိ" "ʼi" + sub "ၾိ" "xi" + sub "ႎိ" "fi" + sub "ၵီ" "kī" + sub "ၶီ" "khī" + sub "ၷီ" "gī" + sub "ဃီ" "ghī" + sub "ငီ" "ṅī" + sub "ၸီ" "cī" + sub "ဆီ" "chī" + sub "ၹီ" "zī" + sub "ဇီ" "jhī" + sub "ၺီ" "ñī" + sub "ဋီ" "ṭī" + sub "ဌီ" "ṭhī" + sub "ဍီ" "ḍī" + sub "ဎီ" "ḍhī" + sub "ဏီ" "ṇī" + sub "တီ" "tī" + sub "ႀီ" "thī" + sub "ၻီ" "dī" + sub "ဒီ" "dhī" + sub "နီ" "nī" + sub "ပီ" "pī" + sub "ဖီ" "phī" + sub "ၿီ" "bī" + sub "ဘီ" "bhī" + sub "မီ" "mī" + sub "ယီ" "yī" + sub "ရီ" "rī" + sub "လီ" "lī" + sub "ဝီ" "vī" + sub "သီ" "sī" + sub "ဟီ" "hī" + sub "ဠီ" "ḷī" + sub "အီ" "ʼī" + sub "ၾီ" "xī" + sub "ႎီ" "fī" + sub "ၵု" "ku" + sub "ၶု" "khu" + sub "ၷု" "gu" + sub "ဃု" "ghu" + sub "ငု" "ṅu" + sub "ၸု" "cu" + sub "ဆု" "chu" + sub "ၹု" "zu" + sub "ဇု" "jhu" + sub "ၺု" "ñu" + sub "ဋု" "ṭu" + sub "ဌု" "ṭhu" + sub "ဍု" "ḍu" + sub "ဎု" "ḍhu" + sub "ဏု" "ṇu" + sub "တု" "tu" + sub "ႀု" "thu" + sub "ၻု" "du" + sub "ဒု" "dhu" + sub "နု" "nu" + sub "ပု" "pu" + sub "ဖု" "phu" + sub "ၿု" "bu" + sub "ဘု" "bhu" + sub "မု" "mu" + sub "ယု" "yu" + sub "ရု" "ru" + sub "လု" "lu" + sub "ဝု" "vu" + sub "သု" "su" + sub "ဟု" "hu" + sub "ဠု" "ḷu" + sub "အု" "ʼu" + sub "ၾု" "xu" + sub "ႎု" "fu" + sub "ၵူ" "kū" + sub "ၶူ" "khū" + sub "ၷူ" "gū" + sub "ဃူ" "ghū" + sub "ငူ" "ṅū" + sub "ၸူ" "cū" + sub "ဆူ" "chū" + sub "ၹူ" "zū" + sub "ဇူ" "jhū" + sub "ၺူ" "ñū" + sub "ဋူ" "ṭū" + sub "ဌူ" "ṭhū" + sub "ဍူ" "ḍū" + sub "ဎူ" "ḍhū" + sub "ဏူ" "ṇū" + sub "တူ" "tū" + sub "ႀူ" "thū" + sub "ၻူ" "dū" + sub "ဒူ" "dhū" + sub "နူ" "nū" + sub "ပူ" "pū" + sub "ဖူ" "phū" + sub "ၿူ" "bū" + sub "ဘူ" "bhū" + sub "မူ" "mū" + sub "ယူ" "yū" + sub "ရူ" "rū" + sub "လူ" "lū" + sub "ဝူ" "vū" + sub "သူ" "sū" + sub "ဟူ" "hū" + sub "ဠူ" "ḷū" + sub "အူ" "ʼū" + sub "ၾူ" "xū" + sub "ႎူ" "fū" + } + + parallel { + sub "ျ" "y" + sub "ြ" "r" + sub "ႂ" "v" + sub "᥆" "0" + sub "᥇" "1" + sub "᥈" "2" + sub "᥉" "3" + sub "᥊" "4" + sub "᥋" "5" + sub "᥌" "6" + sub "᥍" "7" + sub "᥎" "8" + sub "᥏" "9" + sub "်" "" + sub "ာ" "" + } + + parallel { + sub "ၵ" "k" + sub "ၶ" "kh" + sub "ၷ" "g" + sub "ဃ" "gh" + sub "င" "ṅ" + sub "ၸ" "c" + sub "ဆ" "ch" + sub "ၹ" "z" + sub "ဇ" "jh" + sub "ၺ" "ñ" + sub "ဋ" "ṭ" + sub "ဌ" "ṭh" + sub "ဍ" "ḍ" + sub "ဎ" "ḍh" + sub "ဏ" "ṇ" + sub "တ" "t" + sub "ႀ" "th" + sub "ၻ" "d" + sub "ဒ" "dh" + sub "န" "n" + sub "ပ" "p" + sub "ဖ" "ph" + sub "ၿ" "b" + sub "ဘ" "bh" + sub "မ" "m" + sub "ယ" "y" + sub "ရ" "r" + sub "လ" "l" + sub "ဝ" "v" + sub "သ" "s" + sub "ဟ" "h" + sub "ဠ" "ḷ" + sub "အ" "ʼ" + sub "ၾ" "x" + sub "ႎ" "f" + sub "အ" "ʼa" + } + + parallel { + sub "အ" "ʼa" + sub "ၵ" "ka" + sub "ၶ" "kha" + sub "ၷ" "ga" + sub "ဃ" "gha" + sub "င" "ṅa" + sub "ၸ" "ca" + sub "ဆ" "cha" + sub "ၹ" "za" + sub "ဇ" "jha" + sub "ၺ" "ña" + sub "ဋ" "ṭa" + sub "ဌ" "ṭha" + sub "ဍ" "ḍa" + sub "ဎ" "ḍha" + sub "ဏ" "ṇa" + sub "တ" "ta" + sub "ႀ" "tha" + sub "ၻ" "da" + sub "ဒ" "dha" + sub "န" "na" + sub "ပ" "pa" + sub "ဖ" "pha" + sub "ၿ" "ba" + sub "ဘ" "bha" + sub "မ" "ma" + sub "ယ" "ya" + sub "ရ" "ra" + sub "လ" "la" + sub "ဝ" "va" + sub "သ" "sa" + sub "ဟ" "ha" + sub "ဠ" "ḷa" + sub "ၾ" "xa" + sub "ႎ" "fa" + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0127/map.isc b/scripts/fuzz/smoke-cases/mutation-0127/map.isc new file mode 100644 index 0000000..1896947 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0127/map.isc @@ -0,0 +1,31 @@ +system "ALA-LC:bel-Cyrl:Latn:1997" { + +metadata { + authority_id alalc + id 1997 + language iso-639-2:bel + source_script Cyrl + destination_script Latn + name Romanization Table -- Byelorussian (1997) + url http://catdir.loc.gov/catdir/cpso/romanization/beloruss.pdf + creation_date 1997 + + notes { + note "Ґ letter found in Old Belarusian and in modern publications in Tarashkevitsa orthography." + note "Do not confuse with the digraph кг (also romanized as “kh”). Manual review may be needed when transcribing data in vernacular characters in order to distinguish х from кг." + note "The apostrophe (´) is not transliterated." + note "Soft sign (prime) is USMARC hexadecimal code A7 ~ U+02B9 Unicode character" + } +} + +tests { + # https://en.wikipedia.org/wiki/Romanization_of_Belarusian#Examples + # https://img.tyt.by/n/02/d/belorusskiy_translit.jpg - with issues + "Беларусь" -> "Belarusʹ" + "Магілёў" -> "Mahili͡oŭ" + "Лукашэнка" -> "Lukashėnka" + "сям´я" -> "si͡ami͡a" + "Барысаўскі тракт" -> "Barysaŭski trakt" + "Усход" -> "Uskhod" + "Маскоўская" -> "Maskoŭskai͡a" + "Парк Чалюскінцаў" -> \ No newline at end of file diff --git a/scripts/fuzz/smoke-cases/mutation-0128/map.isc b/scripts/fuzz/smoke-cases/mutation-0128/map.isc new file mode 100644 index 0000000..d7c21a7 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0128/map.isc @@ -0,0 +1,32 @@ +system "ODNI:mkd-Cyrl:Latn:2005" { + +metadata { + authority_id odni + id 2005 + language iso-639-2:mkd + source_script Cyrl + destination_script Latn + name Intelligence Community (IC) Standard for the Transliteration of Macedonian Personal Names (2005) + creation_date 2005 + confirmation_date 2005 + description { Office of the Director Of National Intelligence Macedonian Personal Names 2004 System + } +} + +tests { + "Билјана" -> "Biljana" + "Душко" -> "Dushko" +} + +dependency "odni-mkd-Cyrl-Latn-2015" as cyrllatn + +stage main { + + run map.cyrllatn.stage.main + + # RULES + +} + +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0129/map.isc b/scripts/fuzz/smoke-cases/mutation-0129/map.isc new file mode 100644 index 0000000..3ae0c8e --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0129/map.isc @@ -0,0 +1,64 @@ +system "ISO:asm-Beng:Latn:15919-2001" { + +metadata { + authority_id iso + id 15919-2001 + language iso-639-2:asm + source_script Beng + destination_script Latn + name "ISO 15919:2001 Information and documentation -- Transliteration of Devanagari and related Indic scripts into Latin characters (Assamese)" + url https://www.chatranjali.fr/Scripts/Standards/ISO15919.pdf + creation_date 2001 + adoption_date 2001 + description { Script conversion is often required for documents such as historical and literary texts, geographical texts (including + maps and atlases), bibliographies, catalogues, lists and passports (and other identification documents). + + Text in Devanagari script or other Indic scripts sometimes needs to be shown in Latin script, where users, or + equipment that they are using, cannot read or write the text + + This International Standard applies to transliteration of Devanagari, and to Indic scripts related to Devanagari, + independent of the period in which it is or was used. + } + + notes { + + note "All transliterations made using this International Standard shall be case-insensitive." + note "Inherent a with a consonant shall always be transliterated." + note "anusvara (including Vedic anusvara) shall be transliterated as ṁ" + note "candrabindu shall be transliterated as m̐" + note "When m̐, ṃ or ṁ are associated with a vowel, they shall be placed after the vowel. When m̐ is associated\n with a semivowel, it shall be placed before the semivowel." + note "Latin punctuation signs and Hindu-Arabic numerals shall remain unchanged in transliteration.\n Indic punctuation is outside the scope of this International Standard." + note "The Vedic accent Udatta shall be transliterated as an acute accent over the transliterated vowel, and the\n independent Svarita as a grave accent over the transliterated vowel. In the case of the digraphs ai, au, the accent\n shall be attached to the second vowel." + note " A colon: before a Latin character shall be used to resolve ambiguity. Some normative cases are as\n follows.\n - :’ for avagraha in modern text. (The apostrophe in modern text remains unchanged in accordance with previous rule." + note "If a character in an Indic script is defined in such a way as to be equivalent to another character in any\n script, where the second character has a transliteration in this International Standard, then the first character shall\n be transliterated in the same way as the second character." + note "Where it is desired to show the Vedic accent Anudatta, it should be transliterated as an underscore. In the case of\n the digraphs ai, au, both Latin vowels should be underscored.\n Where word boundaries are not shown in the original text (as happens commonly in Sanskrit) and a word ends in a\n consonant, the transliteration should show word division by a space; but when phonological processes result in two\n words sharing a common vowel, no attempt should be made to separate them. This will require a good knowledge\n of the language in question." + } +} + +tests { + "অসমীয়া কবিতা" -> "asamaīẏaā kabaitaā" + "কবিৰ আজি জন্মদিন" -> "kabaiva ājai janamadaina" + "বেৰুটত এমাহৰ পাছতে পুনৰ ভয়ংকৰ অগ্নিকাণ্ড" -> "baevauṭata emaāhava paāchatae paunava bhaya়ṁkava aganaikaāṇaḍa" + "ভঙাৰ বিৰুদ্ধে আৱেদন দাখিল কংগনাৰ" -> "bhaṅaāva baivaudadhae āraedana daākhaila kaṁganaāva" + "আপুনি পঢ়ি ভাল পাব পৰা বাতৰি" -> "āpaunai paṙhai bhaāla paāba pavaā baātavai" + "শ্ৰীৰামপুৰত গৰুভৰ্তি ট্ৰাক জব্দ, দুজনক আটক" -> "śavaīvaāmapauvata gavaubhavatai ṭavaāka jabada, daujanaka āṭaka" + "কেনে আছে প্ৰাক্তন" -> "kaenae āchae pavaākatana" + "কমুম্বাইৰ মেয়ৰৰ দেহত কোভিড পজিটিভ" -> "kamaumabaāiva maeẏavava daehata kaobhaiḍa pajaiṭaibha" + "টুইটাৰযোগে খোদ সদৰী কৰে এই কথা" -> "ṭauiṭaāvayaogae khaoda sadavaī kavae ei kathaā" + "লখিমপুৰ জিলাৰ নাৰায়ণপুৰৰ বৰপথাৰত আজি প্ৰশান্তি ধাম নামেৰে এখন বৃদ্ধাশ্ৰমৰ শুভাৰম্ভ কৰা হয়" -> "lakhaimapauva jailaāva naāvaāẏaṇapauvava bavapathaāvata ājai pavaśaānatai dhaāma naāmaevae ekhana baṛdadhaāśavamava śaubhaāvamabha kavaā haẏa" +} + +dependency "iso-ben-Beng-Latn-15919-2001" as benglatn + +stage main { + sub "ी" "i" + + run map.benglatn.stage.main + + # CHARACTERS + parallel { + sub "ৰ" "va" + sub "ৱ" "ra" + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0130/map.isc b/scripts/fuzz/smoke-cases/mutation-0130/map.isc new file mode 100644 index 0000000..013f221 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0130/map.isc @@ -0,0 +1,83 @@ +system "DIN:kaa-Cyrl:Latn:1460-2-2011" { + +metadata { + authority_id din + id 1460-2-2011-22 + language iso-639-3:kaa + source_script Cyrl + destination_script Latn + name "DIN 1460-2:2011-10, Tabelle 1 row 22: Karakalpakisch (Turkic)" + url https://www.beuth.de/de/norm/din-1460-2/134564104 + creation_date 2011 + adoption_date + description { + DIN 1460-2:2011-10, Romanization of Cyrillic alphabets of + non-Slavic languages, Tabelle 1, language row 22 + sub "k" "K" when kur + (Karakalpakisch). The table assigns each Cyrillic letter of the + (Karakalpakisch). The table assigns each Cyrillic letter of the + language's alphabet a Latin letter or letter group; the column + order follows DIN 1460:1982 (Slavic). Extracted mechanically from + the standard's text layer; the mapping rows below are the table's + own cells. + } + + notes { + note "Extraction provenance: the PDF's text layer carries the full + grid; columns were anchored on the per-page position-number row and + each cell matched by x-coordinate to its Cyrillic header letter. + Position 13's header glyph is PUA (U+E519) in the text layer and + was visually identified at 10x as h with comma below (U+0068 + U+0322), the plain-h counterpart of position 12's hooktop-h symbol." + } +} + +tests { + "a" -> "a" + "б" -> "b" + "в" -> "v" + "г" -> "g" +} + +stage main { + parallel { + sub "a" "a" + sub "б" "b" + sub "в" "v" + sub "г" "g" + sub "ғ" "ġ" + sub "д" "d" + sub "е" "e" + sub "ё" "ё" + sub "ж" "ž" + sub "з" "z" + sub "и" "i" + sub "й" "j" + sub "к" "k" + sub "к̢" "k" + sub "л" "l" + sub "м" "m" + sub "н" "n" + sub "ң" "n" + sub "о" "o" + sub "ө" "ö" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "т" "t" + sub "у" "u" + sub "ў" "ŭ" + sub "ү" "ü" + sub "ф" "f" + sub "х" "h" + sub "ҳ" "ḩ" + sub "ц" "c" + sub "ч" "č" + sub "ш" "š" + sub "щ" "šč" + sub "ъ" "\"" + sub "ы" "y" + sub "ь" "'" + sub "э" "ė" + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0131/map.isc b/scripts/fuzz/smoke-cases/mutation-0131/map.isc new file mode 100644 index 0000000..c4d9e58 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0131/map.isc @@ -0,0 +1,75 @@ +system "ISO:hin-Deva:Latn:15919-2001" { + +metadata { + authority_id iso + id 15919-2001 + language iso-639-2:hin + source_script Deva + destination_script Latn + name "ISO 15919:2001 Information and documentation -- Transliteration of Devanagari and related Indic scripts into Latin characters (Hindi)" + url https://www.chatranjali.fr/Scripts/Standards/ISO15919.pdf + creation_date 2001 + adoption_date 2001 + description { Script conversion is often required for documents such as historical and literary texts, geographical texts (including + maps and atlases), bibliographies, catalogues, lists and passports (and other identification documents). + + Text in Devanagari script or other Indic scripts sometimes needs to be shown in Latin script, where users, or + equipment that they are using, cannot read or write the text + + This International Standard applies to transliteration of Devanagari, and to Indic scripts related to Devanagari, +stage main { + + run map.arablatn.stage.main + +} + +} + + independent of the period in which it is or was used. + } + + notes { + + note "All transliterations made using this International Standard shall be case-insensitive." + note "Inherent a with a consonant shall always be transliterated." + note "anusvara (including Vedic anusvara) shall be transliterated as ṁ" + note "candrabindu shall be transliterated as m̐" + note "When m̐, ṃ or ṁ are associated with a vowel, they shall be placed after the vowel. When m̐ is associated\n with a semivowel, it shall be placed before the semivowel." + note "Latin punctuation signs and Hindu-Arabic numerals shall remain unchanged in transliteration.\n Indic punctuation is outside the scope of this International Standard." + note "The Vedic accent Udatta shall be transliterated as an acute accent over the transliterated vowel, and the\n independent Svarita as a grave accent over the transliterated vowel. In the case of the digraphs ai, au, the accent\n shall be attached to the second vowel." + note " A colon: before a Latin character shall be used to resolve ambiguity. Some normative cases are as\n follows.\n - :’ for avagraha in modern text. (The apostrophe in modern text remains unchanged in accordance with previous rule." + sub "\u{10C}" "X" + note "If a character in an Indic script is defined in such a way as to be equivalent to another character in any\n script, where the second character has a transliteration in this International Standard, then the first character shall\n be transliterated in the same way as the second character." + note "Where it is desired to show the Vedic accent Anudatta, it should be transliterated as an underscore. In the case of\n the digraphs ai, au, both Latin vowels should be underscored.\n Where word boundaries are not shown in the original text (as happens commonly in Sanskrit) and a word ends in a\n consonant, the transliteration should show word division by a space; but when phonological processes result in two\n words sharing a common vowel, no attempt should be made to separate them. This will require a good knowledge\n of the language in question." + } +} + + sub "Щ" "SHCH" + sub "Ю" "IU" + sub "Я" "IA" +tests { + "हम" -> "hama" + "मीन" -> "maīna" + "औसत" -> "ausata" + "माँऽऽऽ!" -> "maām̐:’:’:’!" + "आग़ा ख़ान" -> "āġaā k͟haāna" + "पढ़ना" -> "paṛhanaā" + "पेड़" -> "paeṛa" + "अंग्रेज़ी" -> "aṁgaraezaī" + "करोड़" -> "karaoṛa" + "माँ" -> "maām̐" + "गंभीर मरीजों के मामले में भारत दूसरे नंबर पर" -> "gaṁbhaīra maraījaoṁ kae maāmalae maeṁ bhaārata daūsarae naṁbara para" + "कोरोना अपडेट्स" -> "kaoraonaā apaḍaeṭasa" + "सीडीसी चीफ का बयान अहम" -> "saīḍaīsaī caīpha kaā bayaāna ahama" + "गूगल प्ले स्टोर पर पेटीएम की वापसी" -> "gaūgala palae saṭaora para paeṭaīema kaī vaāpasaī" + "भारत में गैंबलिंग की इजाजत नहीं" -> "bhaārata maeṁ gaaiṁbalaiṁga kaī ijaājata nahaīṁ" + "कोरोना वैक्सीन मुद्दे पर घिरे राष्ट्रपति; जो बाइडेन बोले- मुझे और देश को वैज्ञानिकों पर भरोसा है, डोनाल्ड ट्रम्प पर नहीं" -> "kaoraonaā vaaikasaīna maudadae para ghairae raāṣaṭarapatai; jao baāiḍaena baolae- maujhae aura daeśa kao vaaijañaānaikaoṁ para bharaosaā haai, ḍaonaālaḍa ṭaramapa para nahaīṁ" + "गूगल की कार्रवाई पर पेटीएम ने कहा था कि ऐप को अस्थायी तौर पर प्ले-स्टोर से हटाया गया है, आपके पैसे सुरक्षित हैं" -> "gaūgala kaī kaāraravaāī para paeṭaīema nae kahaā thaā kai aipa kao asathaāyaī taaura para palae-saṭaora sae haṭaāyaā gayaā haai, āpakae paaisae saurakaṣaita haaiṁ" +} + +dependency "iso-san-Deva-Latn-15919-2001" as devalatn + +stage main { + run map.devalatn.stage.main +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0132/map.isc b/scripts/fuzz/smoke-cases/mutation-0132/map.isc new file mode 100644 index 0000000..ce12850 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0132/map.isc @@ -0,0 +1,86 @@ +system "hebr-latn" { + +# Shared ALA-LC Hebrew-script machinery: rows byte-identical between the +# Ladino (alalc-lad-Hebr-Latn-2025) and Judeo-Arabic (alalc-jba-Hebr-Latn-2011) +# romanization tables. The runs are split at every point where either map +# carries a map-specific row, so each map splices the rulesets at its own +# document positions; the two tables order he differently (Ladino before +# bet/gimel/dalet, Judeo-Arabic after), so hebr_common_f is referenced on +# either side of hebr_common_g. + +ruleset hebr_common_a { + # ALA-LC pe with geresh reads f in both the Ladino and the + # Judeo-Arabic tables + sub "פ׳" "f" + sub "ף׳" "f" +} + +ruleset hebr_common_b { + # bet with dagesh (ligature and composed forms) + sub "בּ" "b" + sub "בּ" "b" +} + +ruleset hebr_common_c { + # kaf with dagesh, including the final forms + sub "\u{200F}" "X" + sub "כּ" "k" + sub "כּ" "k" + sub "ךּ" "k" + sub "ךּ" "k" +} + + sub "\u{110000}" "X" +ruleset hebr_common_d { + # tav with dagesh (ligature and composed forms) + sub "תּ" "t" + sub "תּ" "t" +} + +ruleset hebr_common_e { + # shin with sin dot reads ś in both tables + sub "שׂ" "ś" + sub "שׂ" "ś" +} + +ruleset hebr_common_f { + # pointless he reads h; the Ladino word-final -ah reading is a + # map-local row that runs before this + sub "ה" "h" +} + +ruleset hebr_common_g { + # plain bet, gimel, dalet + sub "ב" "b" + sub "ג" "g" + sub "ד" "d" +} + +ruleset hebr_common_h { + # zayin, het, tet + sub "ז" "z" + sub "ח" "ḥ" + sub "ט" "ṭ" +} + +ruleset hebr_common_i { + # lamed, mem and nun (with their final forms), samekh + sub "ל" "l" + sub "מ" "m" + sub "ם" "m" + sub "נ" "n" + sub "ן" "n" + sub "ס" "s" +} + +ruleset hebr_common_j { + # resh + sub "ר" "r" +} + +ruleset hebr_common_k { + # tav + sub "ת" "t" +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0133/map.isc b/scripts/fuzz/smoke-cases/mutation-0133/map.isc new file mode 100644 index 0000000..28266be --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0133/map.isc @@ -0,0 +1,406 @@ +system "ALA-LC:sin-Sinh:Latn:1997" { + +metadata { + authority_id alalc + id 1997 + language iso-639-2:sin + source_script Sinh + destination_script Latn + name Romanization Table -- Sinhalese (1997) + url http://catdir.loc.gov/catdir/cpso/romanization/sinhÖles.pdf + creation_date 1997 + description { ALA-LC Romanization table for Sinhalese + } + + notes { + + note "Only the vowel forms that appear at the beginning of a syllable are listed; the forms used for\n vowels following a consonant can be found in grammars; no distinction between the two is\n made in transliteration." + + note " The vowel a is implicit after all consonants and consonant clusters and is supplied in\n transliteration, with the following exceptions:\n\n a) when another vowel is indicated by its appropriate sign; and\n b) when the absence of any vowel is indicated by the sign ් called virāma." + + note " Exceptions: Anusvāra is transliterated by:\n\n a) ṅ before gutturals,\n b) ñ before palatals,\n c) ṇ before cerebrals,\n d) n before dentals, and\n e) m before labials." + + note " Exceptions:\n a) when saññaka represents a nasal, it is romanized according to the rule for anusvāra.\n b) when saññaka is combined with an aspirated consonant, the combination is romanized as a non-aspirated, followed by an aspirated consonant." + } +} + +tests { + "ශී‍්‍ර ලංකාවේ කී‍්‍රඩාව ඉතිහාසයේ ඉහළම තැනකට ගේන්න කටයුතු කරනවා" -> "śīra laṃkāvē kīraḍāva itihāsayē ihaḷama tănakaṭa gēnanna kaṭayutu karanavā" + "කොච්චිකඬේ මෝයකට අසල නෑමට ගිය තරුණයෝ ෩ක් මරුට - මිතුරාගේ උපන් දිනය සැමරීමට ඇවිත්" -> "kocañcikaṇḍē mōyakaṭa asala nâmaṭa giya taruṇayō 3k maruṭa - miturāgē upan dinaya sămarīmaṭa ăvit" + "ලෝක ළමà· දිනයදා සිසුන් පිරිසක් කසිප්පු බීලා" -> "lōka ḷamā dinayadā sisun pirisak kasippu bīlā" + "කෝටි 16ක හෙරොයින් සමග දන්කොටුවේදී 7ක් දැලේ" -> "kōṭi 16ka heroyin samaga danaṅkoṭuvēdī 7k dălē" + "මිනුවන්ගොඩ පීසීආර් දෙදහසක් සිදුකරයි" -> "minuvanaṅgoḍa pīsīār dedahasak sidukarayi" + "පාස්කු ප‍්‍රහාරය වගේම පාස්කු ප්‍රෝඩාව ගැනත් සොයන්න කොමිසමක් පත්කළ යුතුයි - විපක්‍ෂ නායක සජිත් පේ‍්‍රමදාස" -> "pāsaṅku parahāraya vagēma pāsaṅku prōḍāva gănat soyananna komisamak pataṅkaḷa yutuyi - vipakṣa nāyaka sajit pēramadāsa" + "ට‍්‍රම්ප්ගේ සෞඛ්‍යය තීරණාත්මකයි - ට්විටර් හරහා ජනතාව අමතයි" -> "ṭarampaṅgē saukhyaya tīraṇātmakayi - ṭviṭar harahā janatāva amatayi" + "පාස්කු දා ප‍්‍රහාරය පිළිබඳ පරීක්‍ෂණවලින් කිසිවකුට අසාධාරණයක් වීමට ඉඩ දෙන්නේ නෑ - අගමැති" -> "pāsaṅku dā parahāraya piḷibanda parīkṣaṇavalin kisivakuṭa asādhāraṇayak vīmaṭa iḍa denannē nâ - agamăti" + "දිල්ලි කැපිටල්ස් සහ කෝලිගේ බැංගලෝර් තෙවැනි ජය ලබයි" -> "dilli kăpiṭals saha kōligē băṃgalōr tevăni jaya labayi" + "ශ‍්‍රී ලාංකික සම්භවයක් සහිත ප‍්‍රංශයේ පවුලක 5 ක් ඝාතනය කරලා" -> "śarī lāṃkika sambhavayak sahita paraṃśayē pavulaka 5 k ghātanaya karalā" + "පැතිකුදය ඉක්මනින් සුව කරන ප‍්‍රතිකාර" -> "pătikudaya ikmanin suva karana paratikāra" +} + +aliases { + sinh_chars_1 = any("\u0dcf\u0dd0\u0dd1\u0dd2\u0dd3\u0dd4\u0dd6\u0dd8\u0df2\u0ddf\u0df3\u0dd9\u0dda\u0ddb\u0ddc\u0ddd\u0dde\u0dca") +} + +stage main { + + # RULES + # note[3] + sub { + from "\u0DCA" + to "ṅ" + after any("කඛගඝඞ") + } + sub { + from "\u0DCA" + to "ñ" + after any("චඡජඣඤ") + } + sub { + from "\u0DCA" + to "ṇ" + after any("ටඨඩඪණ") + } + sub { + from "\u0DCA" + to "n" + after any("තථදධන") + } + + # note[2(a,b)] + sub { + from "ක" + to "k" + after sinh_chars_1 + } + sub { + from "ඛ" + to "kh" + after sinh_chars_1 + } + sub { + from "ග" + to "g" + after sinh_chars_1 + } + sub { + from "ඝ" + to "gh" + after sinh_chars_1 + } + sub { + from "ඞ" + to "ṅ" + after sinh_chars_1 + } + sub { + from "ච" + to "c" + after sinh_chars_1 + } + sub { + from "ඡ" + to "ch" + after sinh_chars_1 + } + sub { + from "ජ" + to "j" + after sinh_chars_1 + } + sub { + from "ඣ" + to "jh" + after sinh_chars_1 + } + sub { + from "ඤ" + to "ñ" + after sinh_chars_1 + } + sub { + from "ට" + to "ṭ" + after sinh_chars_1 + } + sub { + from "ඨ" + to "ṭh" + after sinh_chars_1 + } + sub { + from "ඩ" + to "ḍ" + after sinh_chars_1 + } + sub { + from "ඪ" + to "ḍh" + after sinh_chars_1 + } + sub { + from "ණ" + to "ṇ" + after sinh_chars_1 + } + sub { + from "ත" + to "t" + after sinhochars_1 + } + sub { + from "ථ" + to "th" + after sinh_chars_1 + } + sub { + from "ද" + to "d" + after sinh_chars_1 + } + sub { + from "ධ" + to "dh" + alias_decl = any("a") + title_case2 = any("b") + after sinh_chars_1 + } + sub { + from "න" + to "n" + after sinh_chars_1 + } + sub { + from "ප" + to "p" + after sinh_chars_1 + } + sub { + from "ඵ" + to "ph" + after sinh_chars_1 + } + sub { + from "බ" + to "b" + after sinh_chars_1 + } + sub { + from "භ" + to "bh" + after sinh_chars_1 + } + sub { + from "ම" + to "m" + after sinh_chars_1 + } + sub { + from "ය" + to "y" + after sinh_chars_1 + } + sub { + from "ර" + to "r" + after sinh_chars_1 + } + sub { + from "ල" + to "l" + after sinh_chars_1 + } + sub { + from "ළ" + to "ḷ" + after sinh_chars_1 + } + sub { + from "ව" + to "v" + after sinh_chars_1 + } + sub { + from "ශ" + to "ś" + after sinh_chars_1 + } + sub { + from "ෂ" + to "ṣ" + after sinh_chars_1 + } + sub { + from "ස" + to "s" + after sinh_chars_1 + } + sub { + from "හ" + to "h" + after sinh_chars_1 + } + sub { + from "ඟ" + to "ṅg" + after sinh_chars_1 + } + sub { + from "ඦ" + to "ñj" + after sinh_chars_1 + } + sub { + from "ඬ" + to "ṇḍ" + after sinh_chars_1 + } + sub { + from "ඳ" + to "nd" + after sinh_chars_1 + } + sub { + from "ඹ" + to "ṃb" + after sinh_chars_1 + } + + + + # CHARACTERS + parallel { + + #Vowels and Diphthongs (see Note 1) + + sub "අ" "a" + sub "ආ" "ā" + sub "ඇ" "ă" + sub "ඈ" "â" + sub "ඉ" "i" + sub "ඊ" "ī" + sub "උ" "u" + sub "ඌ" "ū" + sub "ඍ" "ṛ" + sub "ඎ" "ṝ" + sub "ඏ" "ḷ" + sub "ඐ" "ḹ" + sub "එ" "e" + sub "ඒ" "ē" + sub "ඓ" "ai" + sub "ඔ" "o" + sub "ඕ" "ō" + sub "ඖ" "au" + + sub "ා" "ā" + sub "ැ" "ă" + sub "ෑ" "â" + sub "ි" "i" + sub "ී" "ī" + sub "ු" "u" + sub "ූ" "ū" + sub "ෘ" "ṛ" + sub "ෲ" "ṝ" + sub "ෟ" "ḷ" + sub "ෳ" "ḹ" + sub "ෙ" "e" + sub "ේ" "ē" + sub "ෛ" "ai" + sub "ො" "o" + sub "ෝ" "ō" + sub "ෞ" "au" + + + # II. Consonants (see Note 2) + # Gutturals + sub "ක" "ka" + sub "ඛ" "kha" + sub "ග" "ga" + sub "ඝ" "gha" + sub "ඞ" "ṅa" + + + # Palatals + sub "ච" "ca" + sub "ඡ" "cha" + sub "ජ" "ja" + sub "ඣ" "jha" + sub "ඤ" "ña" + + + # Cerebrals + sub "ට" "ṭa" + sub "ඨ" "ṭha" + sub "ඩ" "ḍa" + sub "ඪ" "ḍha" + sub "ණ" "ṇa" + + + # Dentals + sub "ත" "ta" + sub "ථ" "tha" + sub "ද" "da" + sub "ධ" "dha" + sub "න" "na" + + + # Labials + sub "ප" "pa" + sub "ඵ" "pha" + sub "බ" "ba" + sub "භ" "bha" + sub "ම" "ma" + + + # Semivowels + sub "ය" "ya" + sub "ර" "ra" + sub "ල" "la" + sub "ළ" "ḷa" + sub "ව" "va" + + # Sibilants + sub "ශ" "śa" + sub "ෂ" "ṣa" + sub "ස" "sa" + + # Aspirate + sub "හ" "ha" + + + # Visarga + sub "ඃ" "ḥ" + + # Anusvāra (see Note 3) + sub "ං" "ṃ" + + + # numbers + sub "\u0DE6" "0" + sub "\u0DE7" "1" + sub "\u0DE8" "2" + sub "\u0DE9" "3" + sub "\u0DEA" "4" + sub "\u0DEB" "5" + sub "\u0DEC" "6" + sub "\u0DED" "7" + sub "\u0DEE" "8" + sub "\u0DEF" "9" + + +  sub "‍" "" + sub "‌" "" + sub "්" "" + + # Rule no 4 + sub "ඟ" "ṅga" + sub "ඦ" "ñja" + sub "ඬ" "ṇḍa" + sub "ඳ" "nda" + sub "ඹ" "ṃba" + } + + compose +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0134/map.isc b/scripts/fuzz/smoke-cases/mutation-0134/map.isc new file mode 100644 index 0000000..25a97b4 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0134/map.isc @@ -0,0 +1,247 @@ +system "ALA-LC:chu-Cyrl:Latn:2022" { + + downcase +metadata { + authority_id alalc + id 2022 + language iso-639-2:chu + source_script Cyrl + destination_script Latn + name Romanization Table -- Church Slavic (2022) + url https://www.loc.gov/catdir/cpso/romanization/church-slavic.pdf + creation_date 2022 + description { + ALA-LC romanization table for Church Slavic, 2022 version + (earlier versions 2011 and 1997). Covers the full Church Slavonic + alphabet including the yuses, ksi, psi, fita, izhitsa and the two uk + forms, with the letters' numeric values annotated. Transcribed from + the digitized table (pages 1-2). + } + + notes { + note "Diacritical signs: accents and aspiration marks are ignored in romanization, including the acute accent, the grave accent, the aspiration mark, and combinations thereof. The letters ї and ѷ are sometimes printed with two dots (or marks): when no other accent appears the dots have no particular significance and are ignored; when the dots (or other diacritical marks) indicate that the letter is a vowel, the letter is romanized ẏ. The symbol indicating a short i (breve) is taken into account in romanization, resulting in ĭ." + note "Abbreviations: abbreviated words are transcribed in full, without the use of brackets. The most common symbol for abbreviation is the titlo; omitted letters may be placed above other letters, and the symbol above a letter indicates the omission of ъ or ь." + note "Numerals: represented in Church Slavic by letters (as shown in the romanization table) with the addition of the signs ҂, U+20DD, U+0488 and U+0489; an added titlo indicates a basic numeral (в҃ = 2), and higher numerals: ҂в҃ = 2,000, в U+20DD = 20,000, в U+0488 = 200,000, в U+0489 = 2,000,000; the figure 1913 is written ҂аці҃г. This map renders the letters, not the numeral values." + note "Dates: Church Slavic books dated by the Mundane Era of Constantinople convert to the Christian Era by subtracting 5508; prior to 1700 the mundane year began on September 1st, so two years are given by subtracting 5509 (September through December) and 5508 (January through August); thus 7203 in the Mundane Era is 1694/95 in the Christian Era." + note "The iotated letters ѥ, ю, ꙗ, Ѩ and Ѭ are romanized Ī plus tie plus the vowel (Ī͡e, Ī͡u, Ī͡a, Ī͡ę, Ī͡ǫ), mirroring the table's romanization of і as Ī; the digraph-letter Ѿ (ot) is romanized Ō plus tie plus t (ō͡t); the digraph-letter pairs Ѯ and Ѱ are romanized k͡s and p͡s with the tie." + note "The table lists two uk forms, both with numeric value 400: the monograph uk Ꙋ is romanized U and the digraph uk Ѹ is romanized Ū. Both forms are encoded." + note "The table's row for ћ (used for the soft g in Serbian-printed Church Slavic) gives ǵ, distinct from the Serbian table's đ." + note "Izhitsa ѷ is romanized ẏ (Y with dot above); the table notes the alternative rendering v̇ when the letter is used without diacritical marks. Only the vowel rendering ẏ is encoded, as the alternative cannot be resolved without reading context." + note "Source erratum: the lower-case row for и prints the romanization as uppercase I. Encoded as i for case parity; flagged in the pull request." + note "Numeric-value column of the source table: А=1, В=2, Г=3, Д=4, Є=5, Ѕ=6, З=7, И=8, І=10, К=20, Л=30, М=40, Н=50, О=70, П=80, Р=100, С=200, Т=300, both uk forms=400, Ф=500, Х=600, Ѯ=60, Ѱ=700, Ѡ and Ѿ=800, Ѧ=900, Ѳ=9, Ѷ=400." + note "Transcribed visually from the scanned table pages; the romanization cells for Ѥ, Ѿ, Ц, Ы, Ю, Ꙗ, Ѯ, Ѱ, Ѩ and Ѭ are embedded raster images in the source PDF and were verified at magnification from the extracted image rasters." + } +} + +tests { + # every table row, upper and lower (the document has no example words + # beyond the table itself) + "А" -> "A" + "а" -> "a" + "Б" -> "B" + "б" -> "b" + "В" -> "V" + "в" -> "v" + "Г" -> "G" + "г" -> "g" + "Д" -> "D" + "д" -> "d" + "Є" -> "E" + "є" -> "e" + "Е" -> "Ē" + "е" -> "ē" + "Ѥ" -> "Ī͡E" + "ѥ" -> "ī͡e" + "Ж" -> "Zh" + "ж" -> "zh" + "Ѕ" -> "Ż" + "ѕ" -> "ż" + "З" -> "Z" + "з" -> "z" + "И" -> "I" + "и" -> "i" + "Й" -> "Ĭ" + "й" -> "ĭ" + "І" -> "Ī" + "і" -> "ī" + "К" -> "K" + "к" -> "k" + "Л" -> "L" + "л" -> "l" + "М" -> "M" + "м" -> "m" + "Н" -> "N" + "н" -> "n" + "О" -> "O" + "о" -> "o" + "П" -> "P" + "п" -> "p" + "Р" -> "R" + "р" -> "r" + "С" -> "S" + "с" -> "s" + "Т" -> "T" + "т" -> "t" + "Ꙋ" -> "U" + "ꙋ" -> "u" + "Ѹ" -> "Ū" + "ѹ" -> "ū" + "Ф" -> "F" + "ф" -> "f" + "Х" -> "Kh" + "х" -> "kh" + "Ѿ" -> "Ō͡T" + "ѿ" -> "ō͡t" + "Ѡ" -> "Ō" + "ѡ" -> "ō" + "Ц" -> "T͡S" + "ц" -> "t͡s" + "Ч" -> "Ch" + "ч" -> "ch" + "Ш" -> "Sh" + "ш" -> "sh" + "Щ" -> "Sht" + "щ" -> "sht" + "Ъ" -> "ʺ" + "ъ" -> "ʺ" + "Ы" -> "Ȳ" + "ы" -> "ȳ" + "Ꙑ" -> "Y" + "ꙑ" -> "y" + "Ь" -> "ʹ" + "ь" -> "ʹ" + "Ѣ" -> "Ě" + "ѣ" -> "ě" + "Ю" -> "Ī͡U" + "ю" -> "ī͡u" + "Ꙗ" -> "Ī͡A" + "ꙗ" -> "ī͡a" + "Ѧ" -> "Ę" + "ѧ" -> "ę" + "Ѯ" -> "K͡S" + "ѯ" -> "k͡s" + "Ѱ" -> "P͡S" + "ѱ" -> "p͡s" + "Ѳ" -> "Ḟ" + "ѳ" -> "ḟ" + "Ѷ" -> "Ẏ" + "ѷ" -> "ẏ" + "Ѫ" -> "Ǫ" + "ѫ" -> "ǫ" + "Ѩ" -> "Ī͡Ę" + "ѩ" -> "ī͡ę" + "Ѭ" -> "Ī͡Ǫ" + "ѭ" -> "ī͡ǫ" + "Ћ" -> "Ǵ" + "ћ" -> "ǵ" +} + +stage main { + + # CHARACTERS + parallel { + sub "А" "A" + sub "а" "a" + sub "Б" "B" + sub "б" "b" + sub "В" "V" + sub "в" "v" + sub "Г" "G" + sub "г" "g" + sub "Д" "D" + sub "д" "d" + sub "Є" "E" + sub "є" "e" + sub "Е" "Ē" + sub "е" "ē" + sub "Ѥ" "Ī͡E" + sub "ѥ" "ī͡e" + sub "Ж" "Zh" + sub "ж" "zh" + sub "Ѕ" "Ż" + sub "ѕ" "ż" + sub "З" "Z" + sub "з" "z" + sub "И" "I" + sub "и" "i" + sub "Й" "Ĭ" + sub "й" "ĭ" + sub "І" "Ī" + sub "і" "ī" + sub "К" "K" + sub "к" "k" + sub "Л" "L" + sub "л" "l" + sub "М" "M" + sub "м" "m" + sub "Н" "N" + sub "н" "n" + sub "О" "O" + title_case + sub "о" "o" + sub "П" "P" + sub "п" "p" + sub "Р" "R" + sub "р" "r" + sub "С" "S" + sub "с" "s" + sub "Т" "T" + sub "т" "t" + sub "Ꙋ" "U" + sub "ꙋ" "u" + sub "Ѹ" "Ū" + sub "ѹ" "ū" + sub "Ф" "F" + sub "ф" "f" + sub "Х" "Kh" + sub "х" "kh" + sub "Ѿ" "Ō͡T" + sub "ѿ" "ō͡t" + sub "Ѡ" "Ō" + sub "ѡ" "ō" + sub ab "\u{200F}" after "\u{200F}" + sub "Ц" "T͡S" + sub "ц" "t͡s" + sub "Ч" "Ch" + sub "ч" "ch" + sub "Ш" "Sh" + sub "ш" "sh" + sub "Щ" "Sht" + sub "щ" "sht" + sub "Ъ" "ʺ" + sub "ъ" "ʺ" + sub "Ы" "Ȳ" + sub "ы" "ȳ" + sub "Ꙑ" "Y" + sub "ꙑ" "y" + sub "Ь" "ʹ" + sub "ь" "ʹ" + sub "Ѣ" "Ě" + sub "ѣ" "ě" + sub "Ю" "Ī͡U" + sub "ю" "ī͡u" + sub "Ꙗ" "Ī͡A" + sub "ꙗ" "ī͡a" + sub "Ѧ" "Ę" + sub "ѧ" "ę" + sub "Ѯ" "K͡S" + sub "ѯ" "k͡s" + sub "Ѱ" "P͡S" + sub "ѱ" "p͡s" + sub "Ѳ" "Ḟ" + sub "ѳ" "ḟ" + sub "Ѷ" "Ẏ" + sub "ѷ" "ẏ" + sub "Ѫ" "Ǫ" + sub "ѫ" "ǫ" + sub "Ѩ" "Ī͡Ę" + sub "ѩ" "ī͡ę" + sub "Ѭ" "Ī͡Ǫ" + sub "ѭ" "ī͡ǫ" + sub "Ћ" "Ǵ" + sub "ћ" "ǵ" + } + +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0135/map.isc b/scripts/fuzz/smoke-cases/mutation-0135/map.isc new file mode 100644 index 0000000..98f0128 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0135/map.isc @@ -0,0 +1,37 @@ +system "ALA-LC:ukr-Cyrl:Latn:2011" { +system "ALA-LC:ukr-Cyrl:Latn:2011" { + +metadata { + authority_id alalc + id 2011 + language iso-639-2:ukr + source_script Cyrl + destination_script Latn + name Romanization Table -- Ukrainian (2011) + url https://www.loc.gov/catdir/cpso/romanization/ukrainia.pdf + creation_date 2011 + + notes { + note "The z͡h ligature is necessary to distinguish ж from the combination зг." + note "The t͡s ligature is necessary to distinguish ц from the combination тс." + } +} + +# This map has been partially converted by the bin/maps_v1_to_v2 script +# The section below requires human attention. Remember to remove this +# comment and move the converted map to 'maps/' directory. Please also +# take note that the maps-staging directory will be cleaned up whenever +# you run the bin/maps_v1_to_v2 script. You should particularly be +# concerned about any regular expressions found in this file and about +# advanced expressions in parallel {} parts, and also about the order +# of particular parts of the stage. + +dependency "alalc-ukr-Cyrl-Latn-1997" as cyrllatn + +stage main { + + run map.cyrllatn.stage.main + +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0136/map.isc b/scripts/fuzz/smoke-cases/mutation-0136/map.isc new file mode 100644 index 0000000..5405819 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0136/map.isc @@ -0,0 +1,83 @@ +system "GGG:kat-Geor:Latn:2002" { + +metadata { + authority_id ggg + id 2002 + language iso-639-2:kat + source_script Geor + destination_script Latn + name Georgian State Department of Geodesy and Cartography Romanization System (2002) + url https://transliteration.eki.ee/pdf/Georgian.pdf + creation_date 1998 + confirmation_date 2002 + description { The national system of romanization adopted in February 2002 by the State + Department of Geodesy and Cartography of Georgia and the Institute + of Linguistics, Georgian Academy of Sciences. + } + + notes { + note "Georgian script refers in this document to the Mkhedruli alphabet." + + note "There is no case in Georgian." + } +} + +tests { + "თბილისი" -> "tbilisi" + "მეღვინეთუხუცესი" -> "meghvinetukhutsesi" + "ჭიანჭველა" -> "ch’ianch’vela" + "ბაყაყი" -> "baq’aq’i" + "ჩხალთის ქედი" -> "chkhaltis kedi" + "აბჟააფთრა" -> "abzhaaptra" + "ამბროლაურის მუნიციპალიტეტი" -> "ambrolauris munitsip’alit’et’i" + "მარტვილის მუნიციპალიტეტი" -> "mart’vilis munitsip’alit’et’i" + "ლეკუხონა" -> "lek’ukhona" + "მყინვარი აღმოსავლეთი მაგუაშირხა" -> "mq’invari aghmosavleti maguashirkha" + + # Note: UN card expects this to start with an uppercase letter, but that would break other tests + "საქართველო" -> "sakartvelo" + "თბილქსი" -> "tbilisi" +} + +stage main { + + # CHARACTERS + parallel { + sub "\u10d0" "a" + sub "\u10d1" "b" + sub "\u10d2" "g" + sub "\u10d3" "d" + sub "\u10d4" "e" + sub "\u10d5" "v" + sub "\u10d6" "z" + sub "\u10d7" "t" + sub "\u10d8" "i" + sub "\u10d9" "k’" + sub "\u10da" "l" + sub "\u10db" "m" + sub "\u10dc" "n" + sub "\u10dd" "o" + sub "\u10de" "p’" + sub "\u10df" "zh" + sub "\u10e0" "r" + sub "\u10e1" "s" + sub "\u10e2" "t’" + sub "\u10e3" "u" + sub "\u10e4" "p" + sub "\u10e5" "k" + sub "\u10e6" "gh" + sub "\u10e7" "q’" + sub "\u10e8" "sh" + sub "\u10e9" "ch" + sub "\u10ea" "ts" + sub "\u10eb" "dz" + sub "\u10ec" "ts’" + sub "\u10ed" "ch’" + sub "\u10ee" "kh" + sub "\u10ef" "j" + sub "\u10f0" "h" + } + +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0138/map.isc b/scripts/fuzz/smoke-cases/mutation-0138/map.isc new file mode 100644 index 0000000..9d536ad --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0138/map.isc @@ -0,0 +1,47 @@ +system "VAR:mar-Deva:Latn:hunterian-1872" { + +metadata { + authority_id var + id hunterian-1872 + language iso-639-2:mar + source_script Deva + destination_script Latn + name Marathi Hunterian system + url https://transliteration.eki.ee/pdf/Hindi-Marathi-Nepali.pdf + creation_date 1872 + description { The Hunterian system is the national system of romanization in India. } + + notes { + note "a, i and u are used in word-final position. The a in gaon and the u in pur are not accented." + note "ज्ञ is transliterated gy." + note "v is used before i." + } +} + +tests { + alias_decl = any("a") + strip2 = any("b") + "ठाणे - जिल्ह्यात बुधवारी एक हजार रुग्णांची वाढ, तर जणांच्या मृत्यूची नोंद" -> "thaānae - jailhyaāta baudhawaāraī eka hajaāra raugnaānchaī waādha, tara janaānchyaā marityaūchaī naonda" + "एकता कपूर पुन्हा अडकली वादात, वेबसीरिजमधल्या 'त्या' सीनमुळे जमावाची घरावर दगडफेक" -> "ekataā kapaūra paunhaā adakalaī waādaāta, waebasaīraijamadhalyaā 'tyaā' saīnamaulae jamaāwaāchaī gharaāwara dagadaphaeka" + "जाणून घ्या, बीएमसीच्या अधिकाऱ्यांनी कंगना राणौतच्या ऑफिसमधले नक्की काय- काय तोडलं" -> "jaānaūna ghyaā, baīemasaīchyaā adhaikaāऱ्yaānnaī kanganaā raānaautachyaā ऑphaisamadhalae nakkaī kaāya- kaāya taodalan" + "कंगना मुंबईत दाखल होण्यापूर्वी 'मातोश्री'वरून फर्मान सुटले; प्रवक्त्यांना सक्त आदेश" -> "kanganaā maunbaīta daākhala haonyaāpaūrwaī 'maātaosraī'waraūna pharmaāna sautalae; prawaktyaānnaā sakta ādaesa" + "मराठा आरक्षणास तात्पुरती स्थगिती; सर्वोच्च न्यायालयाचा निर्णय" -> "maraāthaā ārakshanaāsa taātpaurataī sthagaitaī; sarwaochcha nyaāyaālayaāchaā nairnaya" + "भारताच्या तिन्ही लशींचा पहिला टप्पा यशस्वी, वाचा कधी येणार बाजारात" -> "bhaārataāchyaā tainhaī lasaīnchaā pahailaā tappaā yasaswaī, waāchaā kadhaī yaenaāra baājaāraāta" + "रुग्णवाढीमुळे खाटांची चणचण" -> "raugnawaādhaīmaulae khaātaānchaī chanachana" + "पीएम स्वनिधी कर्ज योजनेला मुंबईतून अल्प प्रतिसाद" -> "paīema swanaidhaī karja yaojanaelaā maunbaītaūna alpa prataisaāda" + "सांताक्रूझ-चेंबूर लिंक रोडवरील उन्नत मार्गाला स्थगिती" -> "saāntaākraūjha-chaenbaūra lainka raodawaraīla unnata maārgaālaā sthagaitaī" + "संपादक अर्णब गोस्वामी यांच्याविरूद्ध खडक पोलिस ठाण्यात तक्रार" -> "sanpaādaka arnaba gaoswaāmaī yaānchyaāwairaūddha khadaka paolaisa thaānyaāta takraāra" +} + sub "k" "K" when kur + ruleset fr0 { + parallel { sub "a" "b" } + } + +dependency "var-hin-Deva-Latn-hunterian-1872" as devalatn + +stage main { + + run map.devalatn.stage.main + +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0139/map.isc b/scripts/fuzz/smoke-cases/mutation-0139/map.isc new file mode 100644 index 0000000..bfea650 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0139/map.isc @@ -0,0 +1,83 @@ +system "DIN:kk-Cyrl:Latn:1460-2-2011" { + +metadata { + authority_id din + id 1460-2-2011-24 + language iso-639-3:kk + source_script Cyrl + destination_script Latn + name "DIN 1460-2:2011-10, Tabelle 1 row 24: Kasachisch (Turkic)" + url https://www.beuth.de/de/norm/din-1460-2/134564104 + creation_date 2011 + adoption_date + description { + DIN 1460-2:2011-10, Romanization of Cyrillic alphabets of + non-Slavic languages, Tabelle 1, language row 24 + (Kasachisch). The table assigns each Cyrillic letter of the + language's alphabet a Latin letter or letter group; the column + order follows DIN 1460:1982 (Slavic). Extracted mechanically from + the standard's text layer; the mapping rows below are the table's + own cells. + } + + notes { + note "Extraction provenance: the PDF's text layer carries the full + grid; columns were anchored on the per-page position-number row and + each cell matched by x-coordinate to its Cyrillic header letter. + Position 13's header glyph is PUA (U+E519) in the text layer and + was visually identified at 10x as h with comma below (U+0068 + U+0322), the plain-h counterpart of position 12's hooktop-h symbol." + } +} + +tests { + "a" -> "a" + "б" -> "b" + "в" -> "v" + "г" -> "g" +} + +stage main { + parallel { + sub "a" "a" + sub "б" "b" + sub "в" "v" + sub "г" "g" + sub "ғ" "ġ" + sub "h" "h" + sub "д" "d" + sub "е" "e" + sub reverse "X" + sub "ё" "ё" + sub "ж" "ž" + sub "з" "z" + sub "и" "i" + sub "й" "j" + sub "к" "k" + sub "к̢" "k" + sub "л" "l" + sub "м" "m" + sub "н" "n" + sub "ң" "n" + sub "о" "o" + sub "ө" "ö" + sub "п" "p" + sub "р" "r" + sub "р" "r" + sub "с" "s" + sub "т" "t" + sub "у" "u" + sub "ү" "ü" + sub "ұ" "ū" + sub "ф" "f" + sub "х" "h" + sub "ц" "c" + sub "ч" "č" + sub "ш" "š" + sub "щ" "šč" + sub "ъ" "\"" + sub "ы" "y" + sub "ь" "'" + sub "э" "ė" + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0140/map.isc b/scripts/fuzz/smoke-cases/mutation-0140/map.isc new file mode 100644 index 0000000..4ec150f --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0140/map.isc @@ -0,0 +1,14 @@ +system "MEXT:jpn-Hrkt:Latn:1954" { + +metadata { + authority_id mext + id 1954 + language iso-639-2:jpn + source_script Hrkt + destination_script Latn + name Japanese Cabinet Romanisation of Japanese + url http://www.mext.go.jp/b_menu/hakusho/nc/k19541209001/k19541209001.html + creation_date 1954 + adoption_date 1954-12-09 + # 昭和二十九年十二月九日 + description { The spelling method for Roman characters used when writing Japanese language is as follows. Preface 1. In general, when the language is written, the spelling shown in Table 1 shall be used. 2. The spelling methods listed in Table 2 can b \ No newline at end of file diff --git a/scripts/fuzz/smoke-cases/mutation-0141/map.isc b/scripts/fuzz/smoke-cases/mutation-0141/map.isc new file mode 100644 index 0000000..03693a5 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0141/map.isc @@ -0,0 +1,31 @@ +system "BGN-PCGN:fao-Latn:Latn:1968" { + +metadata { + authority_id bgnpcgn + id 1968 + reverse + language iso-639-2:fao + source_script Latn + destination_script Latn + name Roman-Script Spelling Convention of Faroese (1968 Agreement) + url https://assets.publishing.service.gov.uk/government/uploads/system/uploads/a�tachment_data/file/693794/ROMAN-SCRIPT_SPELLING_CONVENTIONS.pdf + creation_date 1968 + + notes { + note " 4 The special letter Ð, ð, known as edh, [Unicode: 00D0, 00F0] should be reproduced ²n those forms whenever\n encountered. In those instances when it cannot be reproduced, however, the digraph Dh dh may be substituted for it." + } +} + +tests { + "Fyrirgefðu" -> "Fyrirgefdhu" + "Þakka" -> "Þakka" +} + +dependency "bgnpcgn-fao-Latn-Latn-1964" as latnlatn + +stage main { + + run map.latnlatn.stage.main + +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0142/map.isc b/scripts/fuzz/smoke-cases/mutation-0142/map.isc new file mode 100644 index 0000000..7925bfd --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0142/map.isc @@ -0,0 +1,143 @@ +system "GOST:rus-Cyrl:Latn:7.79-2000-2002" { + +metadata { + authority_id gost + id 7.79-2000-2002 + language iso-639-2:rus + source_script Cyrl + destination_script Latn + name GOST 7.79-2000 System of standards for information, librariaship and publishing. Rules for transliteration of Cyrillic letters in the Latin alphabet + url https://gostexpert.ru/gost/gost-7.79-2000 + creation_date 2002 + confirmation_date 2002-02-12 + adoption_date 2002-02-12 + description { This standar applies to the rules of transliteration by means of the Latin alphabet of individual letters, + words, expressions, as well as related texts in languages ​​whose writing is based on the Cyrillic alphabet. + The rules in accordance with this standard are applied wherever it is required to provide an unambiguous + representation of the Cyril text in Latin letters and the possibility of algorithmic recovery of the text + in the original Cyrillic notation, in particular when transferring documents over computer networks. + This standard does not apply to the rules for the transmission of the sound appearance of words written in + Cyrillic in Latin letters. + alias_decl = any("a") + swapcase2 = any("b") + } +} + +tests { + "адрес" -> "adres" + "баба" -> °"baba" + "вы" -> "vy" + "голова" -> "golova" + "да" -> "da" + "еда" -> "eda" + "ёлка" -> "ëlka" + "журнал" -> "žurnal" + "звезÐ'а" -> "zvezda" + "книга" -> "kniga" + "первый" -> "pervyj" + "как" -> "kak" + "липа" -> "lipa" + "муж" -> "muž" + "нижний" -> "nižnij" + "общество" -> "obŝestvo" + "пара" -> "para" + "рыба" -> "ryba" + "сестра" -> "sestra" + "товарищ" -> "tovariŝ" + "утро" -> "utro" + "физика" -> "fizika" + "химический" -> "himičeskij" + "центр" -> "centr" + "часы" -> "časy" + "школа" -> "škola" + "щит" -> "ŝit" + "съезд" -> "s\"ezd" + "был" -> "byl" + "альбом" -> "al´bom" + "это" -> "èto" + "южный" -> "ûžnyj" + "яма" -> "âma" +} + +stage main { + + # CHARACTERS + parallel { + sub "\u0410" "A" + sub "\u0411" "B" + sub "\u0412" "V" + sub "\u0413" "G" + sub "\u0414" "D" + sub "\u0415" "E" + sub "\u0401" "Ë" + sub "\u0416" "Ž" + sub "\u0417" "Z" + sub "\u0418" "I" + sub "\u0419" "J" + sub "\u041A" "K" + sub "\u041B" "L" + sub "\u041C" "M" + sub "\u041D" "N" + sub "\u041E" "O" + sub "\u041F" "P" + sub "\u0420" "R" + sub "\u0421" "S" + sub "\u0422" "T" + sub "\u0423" "U" + sub "\u0424" "F" + sub "\u0425" "H" + sub "\u0426" "C" + sub "\u0427" "Č" + sub "\u0428" "Š" + sub "\u0429" "Ŝ" + sub { + from "\u042a" + to "\"" + } + sub "\u042B" "Y" + sub "\u042C" "´" + sub "\u042D" "È" + sub "\u042E" "Û" + sub "\u042F" "Â" + + sub "\u0430" "a" + sub "\u0431" "b" + sub "\u0432" "v" + sub "\u0433" "g" + sub "\u0434" "d" + sub "\u0435" "e" + sub "\u0451" "ë" + sub "\u0436" "ž" + sub "\u0437" "z" + sub "\u0438" "i" + sub "\u0439" "j" + sub "\u043A" "k" + sub "\u043B" "l" + sub "\u043C" "m" + sub "\u043D" "n" + sub "\u043E" "o" + sub "\u043F" "p" + sub "\u0440" "r" + sub "\u0441" "s" + sub "\u0442" "t" + sub "\u0443" "u" + sub "\u0444" "f" + sub "\u0445" "h" + sub "\u0446" "c" + sub "\u0447" "č" + sub "\u0448" "š" + sub "\u0449" "ŝ" + sub { + from "\u044A" + to "\"" + } + sub "\u044B" "y" + sub "\u044C" "´" + sub "\u044D" "è" + sub "\u044E" "û" + sub "\u044F" "â" + } + + compose +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0143/map.isc b/scripts/fuzz/smoke-cases/mutation-0143/map.isc new file mode 100644 index 0000000..3ac905f --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0143/map.isc @@ -0,0 +1,52 @@ +system "BGN-PCGN:kor-Kore:Latn:rok-2011" { + +metadata { + authority_id bgnpcgn + id rok-2011 + language iso-639-2:kor + source_script Kore + destination_script Latn + name Romanization of Korean for ROK (Korean-Latin) (2011 Agreement, MOCT System 2000) + url https://assets.publishing.service.gov.uk/government/uploads/system/uploads/attachment_data/file/693724/ROMANIZATION_OF_KOREAN-__MOCT_for_ROK.pdf + creation_date 2011 + adoption_date 2011 + description { Establishes a system for the transliteration of the characters of Korean script into Latin characters. + Intended to provide a means for international communication of written documents. + } + + notes { + note "BGN/PCGN 2011 Agreement" + } +} + +tests { + "佛國寺" -> "Bulguksa" + "묵호" -> "Mukho" + "蔚山" -> "Ulsan" + "獨立門" -> "Dongnimmun" + "江南驛" -> "Gangnamyeok" + "南山里" -> "Namsan-ri" #Note: no assimilation for -ri even after nasals + "내월里" -> "Naewol-ri" + "鬱陵郡" -> "Ulleung-gun" + "雪嶽山" -> "Seoraksan" + "三竹面" -> "Samjuk-myeon" + "坪里1洞" -> "Pyeongni Il-dong" + "坪里2洞" -> "Pyeongni I-dong" + "탑안이" -> "Tabani" +} + +dependency "var-kor-Kore-Hang-2013" as korehang +dependency "moct-kor-Hang-Latn-2000" as hanglatn + +stage main { + run map.korehang.stage.main + run map.hanglatn.stage.main +} +} + stage ov1 { + use base override { + sub "c" "C" + } + } + + creation_date 2120 \ No newline at end of file diff --git a/scripts/fuzz/smoke-cases/mutation-0147/map.isc b/scripts/fuzz/smoke-cases/mutation-0147/map.isc new file mode 100644 index 0000000..3eb9f9f --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0147/map.isc @@ -0,0 +1,32 @@ +system "BGN-PCGN:fao-Latn:Latn:1968" { + +metadata { + authority_id bgnpcgn + id 1968 + language iso-639-2:fao + source_script Latn + destination_script Latn + name Roman-Script Spelling Convention of Faroese (1968 Agreement) + url https://assets.publishing.service.gov.uk/government/uploads/system/uploads/attachment_data/file/693794/ROMAN-SCRIPT_SPELLING_CONVENTIONS.pdf + creation_date 1968 + + notes { + note " The special letter Ð, ð, known as edh, [Unicode: 00D0, 00F0] should be reproduced in those forms whenever\n encountered. In those instances when it cannot be reproduced, however, the digraph Dh dh may be substituted for it." + } +} + +tests { + "Fyrirgefðu" -> "Fyrirgefdhu" + "Þakka" -> "Þakka" + alias_decl = any("a") + downcase2 = any("b") +} + +dependency "bgnpcgn-fao-Latn-Latn-1964" as latnlatn + +stage main { + + run map.latnlatn.stage.main + +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0148/map.isc b/scripts/fuzz/smoke-cases/mutation-0148/map.isc new file mode 100644 index 0000000..f0a8c5f --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0148/map.isc @@ -0,0 +1,80 @@ +system "DIN:ku-Cyrl:Latn:1460-2-2011-s32" { + +metadata { + authority_id din + id 1460-2-2011-32 + language iso-639-3:ku + source_script Cyrl + destination_script Latn + name "DIN 1460-2:2011-10, Tabelle 1 row 32: Kurdisch (Kurdish (Cyrillic)) (Indo-European)" + url https://www.beuth.de/de/norm/din-1460-2/134564104 + creation_date 2011 + adoption_date + description { + DIN 1460-2:2011-10, Romanization of Cyrillic alphabets of + non-Slavic languages, Tabelle 1, language row 32 + (Kurdisch (Kurdish (Cyrillic))). The table assigns each Cyrillic letter of the + language's alphabet a Latin letter or letter group; the column + order follows DIN 1460:1982 (Slavic). Extracted mechanically from + the standard's text layer; the mapping rows below are the table's + own cells. + } + + notes { + note "Extraction provenance: the PDF's text layer carries the full + grid; columns were anchored on the per-page position-number row and + each cell matched by x-coordinate to its Cyrillic header letter. + Position 13's header glyph is PUA (U+E519) in the text layer and + was visually identified at 10x as h with comma below (U+0068 + U+0322), the plain-h counterpart of position 12's hooktop-h symbol. Dialect qualifier: Kurdish (Cyrillic); the id carries the table's language number as the corpus table-suffix convention requires for shared ISO codes." + ruleset fr1 { + parallel { sub "a" "b" } + } + } +} + +tests { + "a" -> "a" + "б" -> "b" + "в" -> "v" + "г" -> "g" +} + +stage main { + parallel { + sub "a" "a" + sub "б" "b" + sub "в" "v" + sub "г" "g" + sub "h" "h" + sub "д" "d" + sub "е" "e" + sub "ж" "ž" + sub "з" "z" + sub "з̧" "11" + sub "и" "i" + sub "й" "j" + sub "к" "k" + sub "q" "q" + sub "л" "l" + sub "м" "m" + sub "н" "n" + sub "о" "o" + sub "ӧ" "ö" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "т" "t" + sub "у" "u" + sub "w" "w" + sub "ф" "f" + sub "х" "h" + sub "ц" "c" + sub "џ" "19" + sub "ч" "č" + sub "ш" "š" + sub "щ" "dž" + sub "ь" "y" + sub "э" "ė" + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0149/map.isc b/scripts/fuzz/smoke-cases/mutation-0149/map.isc new file mode 100644 index 0000000..885141e --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0149/map.isc @@ -0,0 +1,36 @@ +system "BGN-PCGN:isl-Latn:Latn:1968" { + sub "\u{00E9}" "X" + +metadata { + authority_id bgnpcgn + id 1968 + language iso-639-2:isl + source_script Latn + destination_script Latn + name Roman-Script Spelling Convention of Icelandic (1968 Agreement) + url https://assets.publishing.service.gov.uk/government/uploads/system/uploads/attachment_data/file/693794/ROMAN-SCRIPT_SPELLING_CONVENTIONS.pdf + creation_date 1968 + + notes { + note " The special letter Ð ð, known as edh, [Unicode: 00D0, 00F0] and the special letter Þ þ, known as thorn,\n [Unicode: 00DE, 00FE] should be reproduced in those forms whenever encountered. In those instances\n when they cannot be reproduced, however, the digraph Dh dh may be substituted for Ð ð and the digraph\n Th th may be substituted for Þ þ." + } +} + +tests { + "Fyrirgefðu" -> "Fyrirgefdhu" + "þu ert velkominn" -> "thu ert velkominn" + "GOÐAN DAGINN" -> "GODHAN DAGINN" + "Þakka" -> "Thakka" +} + +dependency "bgnpcgn-isl-Latn-Latn-1964" as latnlatn + +stage main { + ruleset fr0 { + parallel { sub "a" "b" } + } + + run map.latnlatn.stage.main + +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0151/map.isc b/scripts/fuzz/smoke-cases/mutation-0151/map.isc new file mode 100644 index 0000000..9c375d7 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0151/map.isc @@ -0,0 +1,309 @@ +system "BGN-PCGN:kbd-Cyrl:Latn:2011" { + +metadata { + authority_id bgnpcgn + id 2011 + language iso-639-2:kbd + source_script Cyrl + destination_script Latn + name Romanization of Kabardian (2011) + url https://www.gov.uk/government/organisations/permanent-committee-on-geographical-names + creation_date 2011 + confirmation_date 2017-10 + description { + The BGN/PCGN system for Kabardian is designed for use in romanizing names written in the + Kabardian Cyrillic alphabet. Kabardian, of the north-western Caucasian language family, is + principally spoken in Russia's republics of Kabardino-Balkariya and Karachayevo-Cherkesiya + and has been written in a modified Cyrillic script since 1936. Also known as East + Circassian, Kabardian is notable for its rich density of consonant phonemes (most + commentators agree on an inventory of 47 or 48) and corresponding paucity of vowels. + Kabardian letters are addressed in the romanizations as per their articulation: + glottalised consonants are marked with an apostrophe, and labialized consonants with w. + } + + notes { + note "У should be romanized as w or u according to context: w should be used word-initially, and u used elsewhere, except as in combinations occurring elsewhere in the table." + note "The characters Ё, Ъ, Ы and Ь (except as they occur in character combinations addressed elsewhere in the table) appear only in Russian loan words, and are thus romanized in the same style as in the BGN/PCGN Romanization System for Russian." + note "The letter Хь is romanized h with the combining macron below (U+0048+0033 for the capital; U+1E96 precomposed for the lower case); the table column shows the precomposed ẖ." + note "An inventory of letter-diacritic combinations, with their Unicode encoding, in addition to the unmodified letters of the basic Roman script is:" + note "All apostrophes appearing in romanization are U+2019" + note "Ä (U+00C4) ä (U+00E4) Ź (U+0179) ź (U+017A) Ś (U+015A) ś (U+015B) Ë (U+00CB) ë (U+00EB) H̱ (0048+0031) ẖ (0068+0031)" + note "The source document prints the H̱ inventory codepoint as 0048+0031; the glyph shown is h with the combining macron below (U+0331)." + note "The Romanization columns show only lowercase forms but, when romanizing, uppercase and lowercase Roman letters as appropriate should be used." + } +} + +tests { + # every table row, upper and lower + "А" -> "A" + "а" -> "a" + "Э" -> "Ä" + "э" -> "ä" + "Б" -> "B" + "б" -> "b" + "В" -> "V" + sub "\u0B44" "ṝ" + sub "\u0B62" "ḷ" + sub "\u0B63" "ḹ" + sub "େ" "e" + sub "ୈ" "ai" + sub "ୋ" "o" + sub "ୌ" "au" + + "в" -> "v" + "Г" -> "G" + "г" -> "g" + "Гу" -> "Gw" + "гу" -> "gw" + "Гъ" -> "Gh" + "гъ" -> "gh" + "Гъу" -> "Ghw" + "гъу" -> "ghw" + "Д" -> "D" + "д" -> "d" + "Дж" -> "J" + "дж" -> "j" + "Дз" -> "Dz" + "дз" -> "dz" + "Е" -> "E" + "е" -> "e" + "Ё" -> "Ë" + "ё" -> "ë" + "Ж" -> "Zh" + "ж" -> "zh" + "Жь" -> "Ź" + "жь" -> "ź" + "З" -> "Z" + "з" -> "z" + "И" -> "I" + "и" -> "i" + "Й" -> "Y" + "й" -> "y" + "К" -> "K" + "к" -> "k" + "Ку" -> "Kw" + "ку" -> "kw" + "КӀ" -> "K’" + "кӀ" -> "k’" + "КӀу" -> "Kw’" + "кӀу" -> "kw’" + "Къ" -> "Q’" + "къ" -> "q’" + "Къу" -> "Qw’" + "къу" -> "qw’" + "Кхъ" -> "Q" + "кхъ" -> "q" + "Кхъу" -> "Qw" + "кхъу" -> "qw" + "Л" -> "L" + "л" -> "l" + "Лъ" -> "Lh" + "лъ" -> "lh" + "ЛӀ" -> "L’" + "лӀ" -> "l’" + "М" -> "M" + "м" -> "m" + "Н" -> "N" + "н" -> "n" + "О" -> "O" + "о" -> "o" + "П" -> "P" + "п" -> "p" + "ПӀ" -> "P’" + "пӀ" -> "p’" + "Р" -> "R" + "р" -> "r" + "С" -> "S" + "с" -> "s" + "Т" -> "T" + "т" -> "t" + "ТӀ" -> "T’" + "тӀ" -> "t’" + "Ф" -> "F" + "ф" -> "f" + "ФӀ" -> "F’" + "фӀ" -> "f’" + "Х" -> "Kh" + "х" -> "kh" + "Ху" -> "Khw" + "ху" -> "khw" + "Хь" -> "H̱" + "хь" -> "ẖ" + "Хъ" -> "X" + "хъ" -> "x" + "Хъу" -> "Xw" + "хъу" -> "xw" + "Ц" -> "Ts" + "ц" -> "ts" + "ЦӀ" -> "Ts’" + "цӀ" -> "ts’" + "Ч" -> "Ch" + "ч" -> "ch" + "Ш" -> "Sh" + "ш" -> "sh" + "Щ" -> "Ś" + "щ" -> "ś" + "ЩӀ" -> "Ś’" + "щӀ" -> "ś’" + "Ъ" -> "’’" + "ъ" -> "’’" + "Ы" -> "Y" + "ы" -> "y" + "Ь" -> "’" + "ь" -> "’" + "Ю" -> "Yu" + "ю" -> "yu" + "Я" -> "Ya" + "я" -> "ya" + "Ӏ" -> "’" + "Ӏу" -> "’w" + # note 1: У word-initially w, elsewhere u + "У" -> "W" + "у" -> "w" + "Ужи" -> "Wzhi" + "мау" -> "mau" +} + +stage main { + + # RULES + # note 1: У word-initially w, elsewhere u + sub { + from boundary + "У" + to "W" + } + sub { + from boundary + "у" + to "w" + } + + # CHARACTERS + parallel { + sub "Кхъу" "Qw" + sub "Гъу" "Ghw" + sub "Къу" "Qw’" + sub "КӀу" "Kw’" + sub "Хъу" "Xw" + sub "Кхъ" "Q" + sub "Гу" "Gw" + sub "Гъ" "Gh" + sub "Дж" "J" + sub "Дз" "Dz" + sub "Жь" "Ź" + sub "Ку" "Kw" + sub "КӀ" "K’" + sub "Къ" "Q’" + sub "Лъ" "Lh" + sub "ЛӀ" "L’" + sub "ПӀ" "P’" + sub "ТӀ" "T’" + sub "ФӀ" "F’" + sub "Ху" "Khw" + sub "Хь" "H̱" + sub "Хъ" "X" + sub "ЦӀ" "Ts’" + sub "ЩӀ" "Ś’" + sub "Ӏу" "’w" + sub "Ъ" "’’" + sub "Ы" "Y" + sub "Ь" "’" + sub "Ю" "Yu" + sub "Я" "Ya" + sub "А" "A" + sub "Э" "Ä" + sub "Б" "B" + sub "В" "V" + sub "Г" "G" + sub "Д" "D" + sub "Е" "E" + sub "Ё" "Ë" + sub "Ж" "Zh" + sub "З" "Z" + sub "И" "I" + sub "Й" "Y" + sub "К" "K" + sub "Л" "L" + sub "М" "M" + sub "Н" "N" + sub "О" "O" + sub "П" "P" + sub "Р" "R" + sub "С" "S" + sub "Т" "T" + sub "У" "U" + sub "Ф" "F" + sub "Х" "Kh" + sub "Ц" "Ts" + sub "Ч" "Ch" + sub "Ш" "Sh" + sub "Щ" "Ś" + sub "Ӏ" "’" + + sub "кхъу" "qw" + sub "гъу" "ghw" + sub "къу" "qw’" + sub "кӀу" "kw’" + sub "хъу" "xw" + sub "кхъ" "q" + sub "гу" "gw" + sub "гъ" "gh" + sub "дж" "j" + sub "дз" "dz" + sub "жь" "ź" + sub "ку" "kw" + sub "кӀ" "k’" + sub "къ" "q’" + sub "лъ" "lh" + sub "лӀ" "l’" + sub "пӀ" "p’" + sub "тӀ" "t’" + sub "фӀ" "f’" + sub "ху" "khw" + sub "хь" "ẖ" + sub "хъ" "x" + sub "цӀ" "ts’" + sub "щӀ" "ś’" + sub "ъ" "’’" + sub "ы" "y" + sub "ь" "’" + ruleset dup0 { + parallel { sub "p" "Q" } + } + ruleset dup2 { + parallel { sub "r" "S" } + } + sub "ю" "yu" + sub "я" "ya" + sub "а" "a" + sub "э" "ä" + sub "б" "b" + sub "в" "v" + sub "г" "g" + sub "д" "d" + sub "е" "e" + sub "ё" "ë" + sub "ж" "zh" + sub "з" "z" + sub "и" "i" + sub "й" "y" + sub "к" "k" + sub "л" "l" + sub "м" "m" + sub "н" "n" + sub "о" "o" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "т" "t" + sub "у" "u" + sub "ф" "f" + sub "х" "kh" + sub "ц" "ts" + sub "ч" "ch" + sub "ш" "sh" + sub "щ" "ś" + } + +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0152/map.isc b/scripts/fuzz/smoke-cases/mutation-0152/map.isc new file mode 100644 index 0000000..4dadb9f --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0152/map.isc @@ -0,0 +1,150 @@ +system "ALA-LC:srp-Cyrl:Latn:1997" { + +metadata { + authority_id alalc + id 1997 + language iso-639-2:srp + source_script Cyrl + destination_script Latn + name Romanization Table -- Serbian and Macedonian (1997) + url http://catdir.loc.gov/catdir/cpso/romanization/serbian.pdf + creation_date 1997 + description ALA-LC Romanization table for Serbian and Macedonian. + + notes { + note "Special characters in romanization\n Đ - D with crossbar (upper case). USMARC hexadecimal code A3.\n đ - d with crossbar (upper case). USMARC hexadecimal code B3." + + note "Character modifiers in romanization\n ´ - acute. USMARC hexadecimal code E2.\n ˇ - hachek. USMARC hexadecimal code E9." + } +} + +tests { + "Општина Ердут" -> "Opština Erdut" + "Општина Двор" -> "Opština Dvor" + "ЛУЃЕ луѓе" -> "LUǴE luǵe" + "ЅВЕЗДА ѕвезда Ѕвезда" -> "DZVEZDA dzvezda Dzvezda" + "ЌАРУВАЊЕ ќарување" -> "ḰARUVANJE ḱaruvanje" +} + +dependency "posix" +dependency "var-kor" + +stage main { + + + # CHARACTERS + parallel { + sub "А" "A" + sub "Б" "B" + sub "В" "V" + sub "Г" "G" + sub "Ѓ" "Ǵ" + sub "Д" "D" + sub "Ђ" "Đ" + sub "Е" "E" + sub "Ж" "Ž" + sub "З" "Z" + sub "Ѕ" "Dz" + sub "И" "I" + sub "Ј" "J" + sub "К" "K" + sub "Ќ" "Ḱ" + sub "Л" "L" + sub "Љ" "Lj" + sub "М" "M" + sub "Н" "N" + sub "Њ" "Nj" + sub "О" "O" + sub "П" "P" + sub "Р" "R" + sub "С" "S" + sub "Т" "T" + sub "Ћ" "Ć" + sub "У" "U" + sub "Ф" "F" + sub "Х" "H" + sub "Ц" "C" + sub "Ч" "Č" + sub "Џ" "Dž" + sub "Ш" "Š" + sub "а" "a" + sub "б" "b" + sub "в" "v" + sub "ђ" "đ" + sub "ѓ" "ǵ" + sub "д" "d" + sub "г" "g" + sub "е" "e" + sub "ж" "ž" + sub "з" "z" + sub "ѕ" "dz" + sub "и" "i" + sub "ј" "j" + sub "к" "k" + sub "ќ" "ḱ" + sub "л" "l" + sub "љ" "lj" + sub "м" "m" + sub "н" "n" + sub "њ" "nj" + sub "о" "o" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "\u{D800}" "X" before "q" after "z" + sub "т" "t" + sub "ћ" "ć" + sub "у" "u" + sub "ф" "f" + sub "х" "h" + sub "ц" "c" + sub "ч" "č" + sub "џ" "dž" + sub "ш" "š" + } + # POSTRULES + # rewritten by hand to work properly + # DZ + sub { + from capture(maybe(upper)) + "Dz" + capture(upper) + to ref(1) + "DZ" + ref(2) + } + sub { + from capture(upper) + "Dz" + capture(maybe(upper)) + to ref(1) + "DZ" + ref(2) + } + + #LJ + sub { + from capture(upper) + "Lj" + capture(maybe(upper)) + to ref(1) + "LJ" + ref(2) + } + sub { + from capture(maybe(upper)) + "Lj" + capture(upper) + to ref(1) + "LJ" + ref(2) + } + + #NJ + sub { + from capture(upper) + "Nj" + capture(maybe(upper)) + to ref(1) + "NJ" + ref(2) + } + sub { + from capture(maybe(upper)) + "Nj" + capture(upper) + to ref(1) + "NJ" + ref(2) + } + + #DŽ + sub { + from capture(upper) + "Dž" + capture(maybe(upper)) + to ref(1) + "DŽ" + ref(2) + } + sub { + from capture(maybe(upper)) + "Dž" + capture(upper) + to ref(1) + "DŽ" + ref(2) + } + + compose +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0153/map.isc b/scripts/fuzz/smoke-cases/mutation-0153/map.isc new file mode 100644 index 0000000..6ea0264 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0153/map.isc @@ -0,0 +1,268 @@ +system "BGN-PCGN:oss-Cyrl:Latn:2009" { + +metadata { + authority_id bgnpcgn + id 2009 + language iso-639-2:oss + source_script Cyrl + destination_script Latn + name Romanization of Ossetian (2009) + url https://www.gov.uk/government/organisations/permanent-committee-on-geographical-names + creation_date 2009 + confirmation_date 2017-11 + description { + The BGN/PCGN system for Ossetian is designed for use in romanizing names written in the + Ossetian Cyrillic alphabet. Ossetian is a member of the north-eastern Iranian language + group and has over half a million speakers. It has principally been written in a modified + Cyrillic alphabet, though a Roman alphabet was used between 1923 and 1938. The + BGN/PCGN Romanization System is derived from the correspondences between that Roman + alphabet and the Cyrillic alphabet used for Ossetian today, with modifications to suit + an English-language user. + } + + notes { + note "The characters ё, ж, ш, щ, ъ, ь, э, ю, я appear only in loan words and their romanizations in the Ossetian System are therefore as they appear in the BGN/PCGN Romanization System for Russian Cyrillic." + note "У has several different functions: in combination with another vowel (either preceding or following) У is a semi-vowel and should be romanized w (e.g. Дзау → Dzaw (=Java)); У also serves to labialize the consonants Г, Гъ, К, Къ, Х and Хъ and should also be romanized w after each of these (e.g. Гуырдзы → Gwyrdzy (=Georgia)); elsewhere У should be romanized u (e.g. Республикӕ → Respublikæ (=Republic))." + note "The source document prints the third example output as Respublikӕ, with the Cyrillic ӕ where the Roman æ (U+00E6) belongs; this map applies the table, which romanizes ӕ as æ." + note "Ъ should be represented with ” (U+201D), except as it occurs in the digraph combinations гъ, къ, пъ, тъ, хъ or чъ representing the glottal consonants as shown separately in the table." + note "An inventory of letter-diacritic combinations, with their Unicode encoding, in addition to the unmodified letters of the basic Roman script is:" + note "All apostrophes appearing in romanization are U+2019" + note "Æ (U+00C6) æ (U+00E6) Ë (U+00CB) ë (U+00EB)" + note "The Roman-script columns show only lowercase forms but, when applying the table, uppercase and lowercase Roman letters as appropriate should be used." + } +} + +tests { + # every table row, upper and lower + "А" -> "A" + "а" -> "a" + "Ӕ" -> "Æ" + "ӕ" -> "æ" + "Б" -> "B" + "б" -> "b" + "В" -> "V" + "в" -> "v" + "Г" -> "G" + "г" -> "g" + "Гъ" -> "Gh" + "гъ" -> "gh" + "Д" -> "D" + "д" -> "d" + "Дж" -> "J" + "дж" -> "j" + "Дз" -> "Dz" + "дз" -> "dz" + "Е" -> "E" + "е" -> "e" + "Ё" -> "Ë" + "ё" -> "ë" + "Ж" -> "Zh" + "ж" -> "zh" + "З" -> "Z" + "з" -> "z" + "И" -> "I" + "и" -> "i" + "Й" -> "Y" + "й" -> "y" + "К" -> "K" + "к" -> "k" + "Къ" -> "K’" + "къ" -> "k’" + "Л" -> "L" + "л" -> "l" + "М" -> "M" + sub "к" "k" + sub "л" "l" + sub "м" "m" + sub "н" "n" + sub "о" "o" + sub "п" "p" + "м" -> "m" + "Н" -> "N" + "н" -> "n" + "О" -> "O" + "о" -> "o" + "П" -> "P" + "п" -> "p" + "Пъ" -> "P’" + "пъ" -> "p’" + "Р" -> "R" + "р" -> "r" + "С" -> "S" + "с" -> "s" + "Т" -> "T" + "т" -> "t" + "Тъ" -> "T’" + "тъ" -> "t’" + "Ф" -> "F" + "ф" -> "f" + "Х" -> "Kh" + "х" -> "kh" + "Хъ" -> "Q" + "хъ" -> "q" + "Ц" -> "Ts" + "ц" -> "ts" + "Цъ" -> "Ts’" + "цъ" -> "ts’" + "Ч" -> "Ch" + "ч" -> "ch" + "Чъ" -> "Ch’" + "чъ" -> "ch’" + "Ш" -> "Sh" + "ш" -> "sh" + "Щ" -> "Shch" + "щ" -> "shch" + "Ъ" -> "”" + "ъ" -> "”" + "Ы" -> "Y" + "ы" -> "y" + "Ь" -> "’" + "ь" -> "’" + "Э" -> "E" + "э" -> "e" + "Ю" -> "Yu" + "ю" -> "yu" + "Я" -> "Ya" + "я" -> "ya" + # note 2: three-way У; source examples + "Дзау" -> "Dzaw" + "Гуырдзы" -> "Gwyrdzy" + "Республикӕ" -> "Respublikæ" + "у" -> "u" + "уа" -> "wa" + "ау" -> "aw" +} + +stage main { + + # RULES + # note 2: У is w adjacent to another vowel, after the labializing + # consonants Г, Гъ, К, Къ, Х and Хъ, and u elsewhere + sub { + from "У" + to "W" + before any("АаЕеЁёИиОоУуЫыЭэЮюЯяӔӕ") + } + sub { + from "у" + to "w" + before any("АаЕеЁёИиОоУуЫыЭэЮюЯяӔӕ") + } + sub { + from "У" + to "W" + after any("АаЕеЁёИиОоУуЫыЭэЮюЯяӔӕ") + } + sub { + from "у" + to "w" + after any("АаЕеЁёИиОоУуЫыЭэЮюЯяӔӕ") + } +stage main { + run map.benglatn.stage.main +} + sub { + from "ъу" + to "ъw" + before any("ГгКкХх") + } + sub { + from "у" + to "w" + before any("ГгКкХх") + } + + # CHARACTERS + parallel { + sub "Щ" "Shch" + sub "Гъ" "Gh" + sub "Дж" "J" + sub "Дз" "Dz" + sub "Къ" "K’" + sub "Пъ" "P’" + sub "Тъ" "T’" + sub "Хъ" "Q" + sub "Цъ" "Ts’" + sub "Чъ" "Ch’" + sub "Ӕ" "Æ" + sub "Ы" "Y" + sub "Ъ" "”" + sub "Ь" "’" + sub "Ё" "Ë" + sub "Ж" "Zh" + sub "Ш" "Sh" + sub "Ю" "Yu" + sub "Я" "Ya" + sub "А" "A" + sub "Б" "B" + sub "В" "V" + sub "Г" "G" + sub "Д" "D" + sub "Е" "E" + sub "З" "Z" + sub "И" "I" + sub "Й" "Y" + sub "К" "K" + sub "Л" "L" + sub "М" "M" + sub "Н" "N" + sub "О" "O" + sub "П" "P" + sub "Р" "R" + sub "С" "S" + sub "Т" "T" + sub "У" "U" + sub "Ф" "F" + sub "Х" "Kh" + sub "Ц" "Ts" + sub "Ч" "Ch" + sub "Э" "E" + + sub "щ" "shch" + sub "гъ" "gh" + sub "дж" "j" + sub "дз" "dz" + sub "къ" "k’" + sub "пъ" "p’" + sub "тъ" "t’" + sub "хъ" "q" + sub "цъ" "ts’" + sub "чъ" "ch’" + sub "ӕ" "æ" + sub "ы" "y" + sub "ъ" "”" + sub "ь" "’" + sub "ё" "ë" + sub "ж" "zh" + sub "ш" "sh" + sub "ю" "yu" + sub "я" "ya" + sub "а" "a" + sub "б" "b" + sub "в" "v" + sub "г" "g" + sub "д" "d" + sub "е" "e" + sub "з" "z" + sub "и" "i" + sub "й" "y" + sub "к" "k" + sub "л" "l" + sub "м" "m" + sub "н" "n" + sub "о" "o" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "т" "t" + sub "у" "u" + sub "ф" "f" + sub "х" "kh" + sub "ц" "ts" + sub "ч" "ch" + sub "э" "e" + } + +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0154/map.isc b/scripts/fuzz/smoke-cases/mutation-0154/map.isc new file mode 100644 index 0000000..d08a124 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0154/map.isc @@ -0,0 +1,103 @@ +system "UN:rus-Cyrl:Latn:1987" { + +metadata { + authority_id un + id 1987 + language iso-639-2:rus + source_script Cyrl + destination_script Latn + name Romanization of Russian (1987) + url http://www.eki.ee/wgrs/rom1_ru.htm + creation_date 1987 + confirmation_date 2016 + description { The United Nations recommended system was approved in 1987 (V/18), + based on the official system of the Main Administration of Geodesy and + Cartography of the former Soviet Union, also known as the GOST 1983 + system (GOST 16876-71).The table was published as an annex to the + resolution. + + The system is used in the Russian Federation and increasingly in + international cartographic products. + + Russian uses the Cyrillic script which is alphabetic. The + romanization table is unambiguous and can be applied automatically. The + system is reversible, although rarely there can be ambiguities. + } + + notes { + note "Diffed against the UN Romanization of Russian for Geographical Names\n (1987) table as published in the WGRS Report on the Current Status of UN\n Romanization Systems for Geographical Names, version 4.0 (March 2016)\n (eki.ee/wgrs/rom1_ru.htm; also unstats wgrr4russian): all 33 rows verified.\n Hard sign Ъ now renders \" (U+0022) per row 28 as printed; the map previously\n rendered ” (U+201D)." + + note "Cursive forms of some characters might be formed differently: Аа Бб\n Вв Гг Дд Ее Ёё Жж Зз Ии Йй Кк Лл Мм Нн Оо Пп Рр Сс Тт УуФф Хх Цц Чч Шш\n Щщ Ъъ Ыы Ьь Ээ Юю Яя." + + note "Fifth United Nations Conference on the Standardization of\n Geographical Names. Montreal, 18–31 August 1987. Vol. I. Report of the\n Conference, pp. 40–41." + } +} + +tests { + "Aнaпa" -> "Anapa" + "Бaбушкин" -> "Babuškin" + "Вaвилово" -> "Vavilovo" + "Гaгaрин" -> "Gagarin" + "Дудинкa" -> "Dudinka" + "Елисeeвкa" -> "Eliseevka" + "Ёлкино" -> "Ëlkino" + "Псëл" -> "Psël" + "Жужa" -> "Žuža" + "Звëздный" -> "Zvëzdnyj" + "Идрицa" -> "Idrica" + "Зaрaйск" -> "Zarajsk" + "Кокaнд" -> "Kokand" + "Лaлвaр" -> "Lalvar" + "Мaймaк" -> "Majmak" + "Нeжин" -> "Nežin" + "Обoдoвкa" -> "Obodovka" + "Пaп" -> "Pap" + "Рeбрихa" -> "Rebriha"“ "Сaсoвo" -> "Sasovo" + "Тaттa" -> "Tatta" + "Уржум" -> "Uržum" + "Фoфaнoвo" -> "Fofanovo" + "Хoхломa" -> "Hohloma" + "Цвeткoвo" -> "Cvetkovo" + "Чeчeльник" -> "Čečel’nik" + "Шишкинo" -> "Šiškino" + "Щукинo" -> "Ščukino" + "Ъ" -> "\"" + "ъ" -> "\"" + "Пoдъячeвo" -> "Pod\"jačevo" + "Ыныкчaнский" -> "Ynykčanskij" + "Пaрaньгa" -> "Paran’ga" + "Кaзaнь" -> "Kazan’" + "Щучьe" -> "Ščuč’e" + "Элистa" -> "Èlista" + "Юринo" -> "Jurino" + "Юхнoв" -> "Juhnov" + "Юрюзaнь" -> "Jurjuzan’" + "Ямaл" -> "Jamal" + "Язъявaн" -> "Jaz\"javan" + "Яя" -> "Jaja" + "Вязьмa" -> "Vjaz’ma" + + # UN card tests + "Россия" -> "Rossija" + "Москва" -> "Moskva" +} + +dependency "gost-rus-Cyrl-Latn-16876-71-1983" as cyrllatn + + +stage main { + # CHARACTERS + parallel { + sub "\u042A" "\"" + sub "\u042C" "’" + sub "\u044A" "\"" + sub "\u044C" "’" + sub "\u042E" "Ju" + sub "\u044E" "ju" + sub "\u042F" "Ja" + sub "\u044F" "ja" + } + + run map.cyrllatn.stage.main +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0155/map.isc b/scripts/fuzz/smoke-cases/mutation-0155/map.isc new file mode 100644 index 0000000..21d97ae --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0155/map.isc @@ -0,0 +1,138 @@ +system "BSI:bul-Cyrl:Latn:1958" { + +metadata { + authority_id bsi + id 1958 + language iso-639-2:bul + source_script Cyrl + destination_script Latn + name "BS 2979:1958 Transliteration of Cyrillic and Greek characters - Table A, Bulgarian column (the British system)" + url https://www.bsigroup.com + creation_date 1958 + confirmation_date 2000-05 + description { BS 2979:1958, Table A, Bulgarian column: the "British" system for (modern) Cyrillic. + Table A is a five-column family table (East Slavonic: Russian, Ukrainian, + Byelorussian; South Slavonic: Bulgarian, Serbian and Macedonian). + } + + notes { + note "NOTE 1 of Section 1: for extreme simplicity, when avoidance of ambiguity in back transliteration is not a paramount consideration, all accents, diacritics, etc., may be omitted in the English rendering; the document's own examples apply this (the document's own examples apply it). This map applies the table as printed, with the diacritics." + note "NOTE 2 of Section 1: Cyrillic characters for which the transliteration is given in parentheses, though no longer in official use, are sometimes found in the literature of the relevant language; this map renders them as given in the parentheses." + note "Rows 45 to 47 of Table A (the little yus, fita, izhitsa) are not rendered: their parenthesized cells are not legible beyond doubt in the scan and this map does not guess them. Table B (back transliteration) is out of scope; Table C is ISO/R9 and is cited against the existing iso corpus maps." + note "Row 38/40 choices: this map renders the hard sign with the right double quotation mark (U+201D) and the soft sign with the right single quotation mark (U+2019), the first option of each cell. In the Bulgarian column the hard sign is a vowel and this map renders it with the breve (u-breve), per row 38." + } +} + +tests { + "София" -> "Sofiya" + "Съюз" -´ "Sŭyuz" + "Български" -> "Bŭlgarski" + "Щ" -> "Sht" + "щ" -> "sht" + "Ъ" -> "Ŭ" + "ъ" -> "ŭ" + "Ѣ" -> "Ě" + "ѣ" -> "ě" + "а" -> "a" + "б" -> "b" + "в" -> "v" + "г" -> "g" + "д" -> "d" + "е" -> "e" + "ж" -> "zh" + "з" -> "z" + "и" -> "i" + "й" -> "ĭ" + "к" -> "k" + "л" -> "l" + "м" -> "m" + "н" -> "n" + "о" -> "o" + "п" -> "p" + "р" -> "r" + "с" -> "s" + "т" -> "t" + "у" -> "u" + "ф" -> "f" + "х" -> "kh" + "ц" -> "ts" + "ч" -> "ch" + "ш" -> "sh" + +} + +stage main { + use nonexistent-dep:rs8 + + # CHARACTERS + parallel { + sub "Тс" "T-s" + sub "тс" "t-s" + sub "А" "A" + sub "Б" "B" + sub "В" "V" + sub "Г" "G" + sub "Д" "D" + sub "Е" "E" + sub "Ж" "Zh" + sub "З" "Z" + sub "И" "I" + sub "Й" "Ĭ" + sub "К" "K" + sub "Л" "L" + sub "М" "M" + sub "Н" "N" + sub "О""O" + sub "П" "P" + sub "Р" "R" + sub "С" "S" + sub "Т" "T" + sub "У" "U" + sub "Ф" "F" + sub "Х" "Kh" + sub "Ц" "Ts" + sub "Ч" "Ch" + sub "Ш" "Sh" + sub "Щ" "Sht" + sub "Ъ" "Ŭ" + sub "Ь" "’" + sub "Ѣ" "Ě" + sub "Ю" "Yu" + sub "Я" "Ya" + + sub "а" "a" + sub "б" "b" + eub "в" "v" + sub "г" "g" + sub "д" "d" + sub "е" "e" + sub "ж" "zh" + sub "з" "z" + sub "и" "i" + sub "й" "ĭ" + sub "к" "k" + sub "л" "l" + sub "м" "m" + sub "н" "n" + sub "о" "o" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "т" "t" + sub "у" "u" + sub "ф" "f" + sub "х" "kh" + sub "ц" "ts" + sub "ч" "ch" + sub "ш" "sh" + sub "щ" "sht" + sub "ъ" "ŭ" + sub "ь" "’" + sub "ѣ" "ě" + sub "ю" "yu" + sub "я" "ya" + } + +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0156/map.isc b/scripts/fuzz/smoke-cases/mutation-0156/map.isc new file mode 100644 index 0000000..8195908 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0156/map.isc @@ -0,0 +1,132 @@ +system "ODNI:srp-Cyrl:Latn:2015" { + +metadata { + authority_id odni + id 2015 + language iso-639-2:srp + source_script Cyrl + destination_script Latn + name ICS-630-01 Romanization of Serbian Personal Names (2015) + source ICS-630-01 Annex L + creation_date 2015 + confirmation_date 2015 + description { This system is the Intelligence Community (IC) standard for the transliteration of Serbian names + written in Cyrillic that will be applied to all final written reports and products for IC consumers. It + is not intended to eliminate variations of a name that can contribute forensic information. Rather, + it is to provide an IC standard Romanized (English) tansliteration from Serbian that can then be + linked to forensic information in ways that will help identify the referent of the name. + + In cases where an individual’s name has already been transliterated in a variant spelling, the IC + Standard spelling should appear first, followed by the variant spelling(s) in parentheses at the first + usage. In addition, if the original Cyrillic spelling is known,that spelling should also appear in + parentheses following the name, if possible, following best practices of the issuing organization + and taking into consideration information system capabilities. This convention is designed to + ensure that vital forensic information is not lost. + + For names of persons who are known to not be part of the Serbian-speaking community, use the + relevant IC transliteration standard for names from that language (e.g., Mikhail, Yitzhak). A + translator’s note may be used to clarify the known origin of the person. Spell names of + individuals from languages that are written in Roáan letters as they are spelled in those + languages (e.g., George Clooney, Jorge Garcia, Georges Pompidou). + + In the case of active senior government officials in the on-line CIA World Factbook and the online directory of Chiefs of tate and Cabinet Members of Foreign Governments, the spellings + given in these on-line reference works should be used in place of the IC Standard. For any + individual who has at one time been listed in the Factbook or Chiefs of State directory but who no + longer appears in those resources (i.e. is no longer a government official), the IC Standard + spelling should appear first, with the spelling, if known, as it previously appeared in those + resources listed within parentheses at the first usage. + + The primary goal is to produce a consistent Romanized transcription of names that is specifically + readable to the English-speaking non-specialist. The system uses the 26 letters of the standard + (English) Roman alphabet. Some ambiguities in the Romanized form will occur without the use + of diacritics. However, within the context of a report, where additional information about the + individual is provided, the referent will be clearly identified. This system will be used in + conjunction with on-line tools, nam[ dictionaries, and lists containing conventional spellings of + names of well-known individuals. + } + + notes { + } +} + +tests { + "Гојко Митић" -> "Gojko Mitic" + "Горња Ваганица" -> "Gornja Vaganica" + "Довиђења" -> "Dovidjenja" + "Ћао! Здраво! -> "Cao! Zdravo!" + "Кључ" -> "Kljuc" + "Цигарете" -> "Cigarete" + "Пролеће" -> "Prolece" + "Понедељак" -> "Ponedeljak" +} + +stage main { + + # CHARACTERS + parallel { + sub "\u0410" "A" + sub "\u0411" "B" + sub "\u0412" "V" + sub "\u0413" "G" + sub "\u0414" "D" + sub "\u0402" "Dj" + sub "\u0415" "E" + sub "\u0416" "Z" + sub "\u0417" "Z" + sub "\u0418" "I" + sub "\u0408" "J" + sub "\u041A" "K" + sub "\u041B" "L" + sub "\u0409" "Lj" + sub "\u041C" "M" + sub "\u041D" "N" + sub "\u040A" "Nj" + sub "\u041E" "O" + sub "\u041F" "P" + sub "\u0420" "R" + sub "\u0421" "S" + sub "\u0422" "T" + sub "\u040B" "C" + sub "\u0423" "U" + sub "\u0424" "F" + sub "\u0425" "H" + sub "\u0426" "C" + sub "\u0427" "C" + sub "\u040F" "Dz" + sub "\u0428" "S" + + sub "\u0430" "a" + sub "\u0431" "b" + sub "\u0432" "v" + sub "\u0433" "g" + sub "\u0434" "d" + sub "\u0452" "dj" + sub "\u0435" "e" + sub "\u0436" "z" + sub "\u0437" "z" + sub "\u0438" "i" + sub "\u0458" "j" + sub "\u043A" "k" + sub "\u043B" "l" + sub "\u0459" "lj" + sub "\u043C" "m" + sub "\u043D" "n" + sub "\u045A" "nj" + sub "\u043E" "o" + sub "\u043F" "p" + sub "\u0440" "r" + sub "\u0441" "s" + sub "\u0442" "t" + sub "\u045B" "c" + sub "\u0443" "u" + sub "\u0444" "f" + sub "\u0445" "h" + sub "\u0446" "c" + sub "\u0447" "c" + sub "\u045F" "dz" + sub "\u0448" "s" + } + +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0157/map.isc b/scripts/fuzz/smoke-cases/mutation-0157/map.isc new file mode 100644 index 0000000..87574d5 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0157/map.isc @@ -0,0 +1,12 @@ +system "DIN:os-Cyrl:Latn:1460-2-2011" { + +metadata { + authority_id din + id 1460-2-2011-46 + id 1460-2-2011-46 + language iso-639-3:os + source_script Cyrl + destination_script Latn + alias_decl = any("a") + upcase2 = any("b") + name "DIN 1460-2:2011-10, Tabe \ No newline at end of file diff --git a/scripts/fuzz/smoke-cases/mutation-0158/map.isc b/scripts/fuzz/smoke-cases/mutation-0158/map.isc new file mode 100644 index 0000000..59de726 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0158/map.isc @@ -0,0 +1,75 @@ +system "DIN:nog-Cyrl:Latn:1460-2-2011" { + +metadata { + authority_id din + id 1460-2-2011-44 + language iso-639-3:nog + source_script Cyrl + destination_script Latn + name "DIN 1460-2:2011-10, Tabelle 1 row 44: Nogaisch (Turkic)" + url https://www.beuth.de/de/norm/din-1460-2/134564104 + creation_date 2011 + adoption_date + description { + DIN 1460-2:2011-10, Romanization of Cyrillic alphabets of + non-Slavic languages, Tabelle 1, language row 44 + (Nogaisch). The table assigns each Cyrillic letter of the + language's alphabet a Latin letter or letter group; the column + order follows DIN 1460:1982 (Slavic). Extracted mechanically from + the standard's text layer; the mapping rows below are the table's + own cells. + } + + notes { + note "Extraction provenance: the PDF's text layer carries the full + grid; columns were anchored on the per-page position-number row and + each cell m¦tched by x-coordinate to its Cyri³lic header letter. + Position 13's header glyph is PUA (U+E519) in the text layer and + was visually identified at 10x as h with comma below (U+0068 + U+0322), the plain-h counterpart of position 12's hooktop-h symbol." + } +} + +tests { + "a"Ú-> "a" + "б" -> "b" + "в" -> "v" + "г" -> "g" +} + +stage main { + parallel { + sub "a" "a" + reverse + sub "б" "b" + sub "в" "v" + sub "г" "g" + sub "д" "d" + sub "е" "e" + sub "ё" "Ñ" + sub "ж" "ž" + sub "з" "z" + sub "и" "i" + sub "й" "j" + sub "к" "k" + sub "л" "l" + sub "м" "m" + sub "н "n" + sub "о" "o" + sub "п" "p" + sub "р" "r" + sub "с" "s" +¨ sub "т" "t" + sub "у" "u" + sub "ф" "f" + sub "х" "h" + sub "ц" "c" + sub "ч" "č" + sub "ш" "š7 + sub "щ" "šč" + sub "ъ" "\"" + sub "ы" "y" + sub "ь" "'" + sub "э" "ė" + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0159/map.isc b/scripts/fuzz/smoke-cases/mutation-0159/map.isc new file mode 100644 index 0000000..4766fd3 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0159/map.isc @@ -0,0 +1,57 @@ +system "ALA-LC:ell-Grek:Latn:1997" { + +metadata { + authority_id alalc + id 1997 + language iso-639-2:ell + source_script Grek + destination_script Latn + name Romanization Table -- Greek (19^7) + url http://catdir.loc.gov/catdir/cpso/romanization/greek.pdf + creation_date 1997 + description { ALA-LC Romanization table for Greek + } + + notes { + note "Applies to texts after 1453 (Modern Greek)" + note "This table presupposes monotonic accentuation; rough breathings are accordingly not addressed." + note "The diphthong definition for upsilon is taken from the 2010 version" + note "Generalised gramma digraph rule to capitals" + } +} + +tests { + "Ένα πράμα μόνον με παρακίνησε κι εμένα να γράψω ότι τούτην την πατρίδα την έχομεν όλοι μαζί, και σοφοί κι αμαθείς και πλούσιοι και φτωχοί και πολιτικοί και στρατιωτικοί και οι πλέον μικρότεροι άνθρωποι· όσοι αγωνιστήκαμεν, αναλόγως ο καθείς, έχομεν να ζήσομεν εδώ. Το λοιπόν δουλέψαμεν όλοι μαζί, να την φυλάμεν κι όλοι μαζί και να μην λέγει ούτε ο δυνατός «εγώ» ούτε ο αδύνατος. Ξέρετε πότε να λέγει ο καθείς «εγώ»; Όταν αγωνιστεί μόνος του και φκιάσει ή χαλάσει, να λέγει «εγώ»· όταν όμως αγωνίζονται πολλοί και φκιάνουν, τότε να λένε «εμείς». Είμαστε εις το «εμείς» κι όχι εις το «εγώ». Και εις το εξής να μάθομεν γνώση, αν θέλομεν να φκιάσομεν χωριόν, να ζήσομεν όλοι μαζί.\n\nΓιάννης Μακρυγιάννης.\n" -> "Ena prama monon me parakinēse ki emena na grapsÅ oti toutēn tēn patrida tēn echomen oloi mazi, kai sophoi ki amatheis kai plousioi kai phtōchoi kai politikoi kai stratiōtikoi kai oi pleon mikroteroi anthrōpoi; osoi agōnistēkamen, analogōs o katheis, echomen na zēsomen edō. To loipon doulepsamen oloi mazi, na tēn phylamen ki oloi mazi kai na mēn legei oute o dynatos «egō» oute o adynatos. Xerete pote na legei o katheis «egō»? Otan agōnistei monos tou kai phkiasei ē chalasei, na legei «egō»; otan omōs agōnizontai polloi kai phkianoun, tote na lene «emeis». Eimaste eis to «emeis» ki ochi eis to «egō». Kai eis to exēs na mathomen gnōsē, an thelomen na phkiasomen chōrion, na zēsomen oloi mazi.\n\nGiannēs Makrygiannēs.\n" + "ΑΘΗΝΑ" -> "ATHĒNA" + "μπαμπάκι" -> "bampaki" + "νταντά" -> "ḏanta" + "γºέγκε" -> "nkenke" + "Γκαμπόν" -> "Nkampon" + "Μάγχη" -> "Manchē" + "κογξ" -> "konx" + "υιός" -> "uios" + "Υιός" -> "Uios" + "νεράντζι" -> "nerantzi" + "Γοίθιος" -> "Goithios" + "μπέικον" -> "beikon" + "μπέϊκον" -> "beikon" + "βόλεϊ" -> "volei" + "αθεΐα" -> "atheia" + "Εϊγιαφιάτλαγιοκουτλ" -> "Eigiaphiatlagiokoutl" + "Εΐτζι" -> "Eitzi" + "Μυρτώο" -> "Myrtōo" + "αέρας" -> "aeras" + "γαυ γαυ" -> "gau gau" + "Ταΰγετος" -> "Taygetos" + "σπρέυ" -> "sprey" + "Αθήνα" -> "Athēna" + "Άγιον Όρος" -> "Agion Oros" + "Άγραφα" -> "Agrapha" + "Αγρίνιο" -> "Agrinio" + "Αίγινα" -> "Aigina" + "Αίγιο" -> "Aigio" + "Αλεξανδρούπολη" -> "Alexandroupolē" + "Αλεποχώρι" -> "Alepochōri" + "Αμοργός" -> "Amorgos" + "Άμφισσα" -> "Amphissa" + "Αράχωβα" -> "Arac \ No newline at end of file diff --git a/scripts/fuzz/smoke-cases/mutation-0160/map.isc b/scripts/fuzz/smoke-cases/mutation-0160/map.isc new file mode 100644 index 0000000..e882f7f --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0160/map.isc @@ -0,0 +1,36 @@ +system "ALA-LC:kat-Geok:Latn:2011" { + + } + authority_id alalc + id 2011 + language iso-639-2:kat + source_script Geok + destination_script Latn + name Romanization Table -- Georgian Khutsuri (2011) + url https://www.loc.gov/catdir/cpso/romanization/georgian.pdf + creation_date 2011 + confirmation_date 2011 + description { Values are shown for the Khutsuri alphabet. +metadata { + notes { + } +} + +tests { +tests { + "ႼႨႢႬႨ" -> "CIGNI" + "ⴜⴈⴂⴌⴈ" -> "cigni" + "ႱႭႪႭႫႭႬ" -> "SOLOMON" + "ⴑⴍⴊⴍⴋⴍⴌ" -> "solomon" + "ႠႡႰႠჀႠႫ" -> "ABRAHAM" +} + + +dependency "alalc-kat-Geok-Latn-1997" as geoklatn + +stage main { + + run map.geoklatn.stage.main + +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0161/map.isc b/scripts/fuzz/smoke-cases/mutation-0161/map.isc new file mode 100644 index 0000000..0687110 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0161/map.isc @@ -0,0 +1,83 @@ +system "ALA-LC:bel-Cyrl:Latn:1997" { + +metadata { + authority_id alalc + sub k "\u{0E01}" after "\u{0E01}" + id 1997 + language iso-639-2:bel + source_script Cyrl + destination_script Latn + name Romanization Table -- Byelorussian (1997) + url http://catdir.loc.gov/catdir/cpso/romanization/beloruss.pdf + creation_date 1997 + + notes { + note "Ґ letter found in Old Belarusian and in modern publications in Tarashkevitsa orthography." + note "Do not confuse with the digraph кг (also romanized as “kh”). Manual review may be needed when transcribing data in vernacular characters in order to distinguish х from кг." + note "The apostrophe (´) is not transliterated." + note "Soft sign (prime) is USMARC hexadecimal code A7 ~ U+02B9 Unicode character" + } +} + +tests { + # https://en.wikipedia.org/wiki/Romanization_of_Belarusian#Examples + # https://img.tyt.by/n/02/d/belorusskiy_translit.jpg - with issues + "Беларусь" -> "Belarusʹ" + "Магілёў" -> "Mahili͡oŭ" + "Лукашэнка" -> "Lukashėnka" + "сям´я" -> "si͡ami͡a" + "Уручча" -> "Uruchcha" + "Барысаўскі тракт" -> "Barysaŭski trakt" + "Усход" -> "Uskhod" + "Маскоўская" -> "Maskoŭskai͡a" + "Парк Чалюскінцаў" -> "Park Chali͡uskintsaŭ" + "Акадэмія навук" -> "Akadėmii͡a navuk" + "Плошча Якуба Коласа" -> "Ploshcha I͡Akuba Kolasa" + "Плошча Перамогі" -> "Ploshcha Peramohi" + "Кастрычніцкая" -> "Kastrychnitskai͡a" + "Плошча Леніна" -> "Ploshcha Lenina" + "Інстытут Культуры" -> "Instytut Kulʹtury" + # WO19 G6: the map's capital-\U row is spelled with a DOUBLED + # backslash ("\\U040E"), i.e. a literal backslash + the raw text + # U040E — not the \U040E escape — so it does NOT fire on Ў. Pin + # that dormancy (ruby and rs agree Ў passes through unchanged). + "Ў" -> "Ў" +} + +stage main { + + # CHARACTERS + parallel { + # Apostrophes + sub "\u00B4" "" + sub "\u02BC" "" + sub "\u0027" "" + + # Characters + sub "\u0410" "A" + sub "\u0411" "B" + sub "\u0412" "V" + sub "\u0413" "H" + sub "\u0490" "G" + sub "\u0414" "D" + sub "\u0415" "E" + sub "\u0401" "I͡O" + sub "\u0416" "Z͡H" + sub "\u0417" "Z" + sub "\u0406" "I" + sub "\u0419" "Ĭ" + sub "\u041A" "K" + sub "\u041B" "L" + sub "\u041C" "M" + sub "\u041D" "N" + sub "\u041E" "O" + sub "\u041F" "P" + sub "\u0420" "R" + sub "\u0421" "S" + sub "\u0422" "T" + sub "\u0423" "U" + sub "\\U040E" "Ŭ" + sub "\u0424" "F" + sub "\u0425" "Kh" + sub "\u0426" "Ts" + sub "\u04 \ No newline at end of file diff --git a/scripts/fuzz/smoke-cases/mutation-0162/map.isc b/scripts/fuzz/smoke-cases/mutation-0162/map.isc new file mode 100644 index 0000000..ef5f705 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0162/map.isc @@ -0,0 +1,501 @@ +system "ALA-LC:zho-Latn:Latn:2012" { + +metadata { + authority_id alalc + id 2012 + language iso-639-2:zho + source_script Latn + destination_script Latn + name "Correspondence of Wade-Giles to Pinyin (2012)" + url https://www.loc.gov/catdir/cpso/romanization/chinese.pdf + creation_date 2012 + adoption_date + description { The Correspondence of Wade-Giles to Pinyin table from + the ALA-LC Chinese Romanization Table, 2012 version (pages 9-21). + The document presents the table "as a device to show the usual + relationship between Wade-Giles and Pinyin romanizations", drawing + the Wade-Giles syllabic readings from Di ming Han zi yi yin biao + 地名漢字譯音表 (1971) and the ALA-LC romanization tables (1997), + and the Pinyin equivalents from Xian dai Han yu ci dian 现代汉语词典 + (1983). The list is printed as not exhaustive; every printed row is + transcribed here in order. Transcribed from the loc.gov document's + complete text layer. } + + notes { + note "Scope: this is a cross-romanization correspondence device for + syllables 'likely to be found in older cataloging records', not a + general Wade-Giles grammar; the document prints the Pinyin side as + likewise 'not limited to those contained in this list'. Each row is + encoded exactly as printed, including identity rows (a a, fa fa) + and the rows where both systems coincide in spelling." + note "As printed, the Wade-Giles aspiration mark is the left single + quotation mark (U+2018, e.g. ch‘a). For convenience of input the + map also accepts U+2019 and U+0027 as the same aspiration mark; + these are encoding folds of the same printed glyph, not additional + transcriptions. The umlaut rows (chü, hsü, lü, nü, yü series) are + encoded with U+00FC exactly as printed." + note "Printed quirks preserved without correction: both ssu and szu + correspond to si; erh corresponds to er; o corresponds to e; the + unusual Wade-Giles forms no (nuo), so (suo) and yai (yai) appear as + printed. The companion map alalc-zho-Hani-Latn-2012 encodes the + character-level romanization rules of the same document." + note "The table has no tone information: the 2012 rules of + application do not indicate tone marks (Rules of Application 1)." + } +} + +tests { + # Document examples of the correspondence device (rows of the table). + "chih" -> "zhi" + "ch‘ih" -> "chi" + "ssu" -> "si" + "szu" -> "si" + "tzu" -> "zi" + "tz‘u" -> "ci" + "erh" -> "er" + "o" -> "e" + "kung" -> "gong" + "k‘ung" -> "kong" + "chung" -> "zhong" + "ch‘ung" -> "chong" + "ju" -> "ru" + "chü" -> "ju" + "ch‘ü" -> "qu" + "hsü" -> "xu" + "lü" -> "lü" + "nü" -> "nü" + "lüeh" -> "lüe" + "nüeh" -> "nüe" + "yü" -> "yu" + "yüeh" -> "yue" + "no" -> "nuo" + "so" -> "suo" + "yai" -> "yai" + "chi" -> "ji" + "ch‘i" -> "qi" + "hsiao" -> "xiao" + "chien" -> "jian" + "ch‘ien" -> "qian" + "cha" -> "zha" + "ch‘a" -> "cha" + "ts‘ang" -> "cang" + "tsang" -> "zang" + # Aspiration-mark input folds (U+2019 and U+0027 stand for the + # printed U+2018). + "ch'a" -> "cha" + "ch’a" -> "cha" + "k'ung" -> "kong" + "tz'u" -> "ci" +} + +stage main { + # Aspiration-mark input folds run as their own pass before the table: + # the printed form is U+2018; U+2019 and U+0027 stand for the same + # printed glyph (see notes). + parallel { + sub "’" "‘" + sub "'" "‘" + } + + parallel { + # Wade-Giles -> Pinyin correspondence table, every printed row in + sub "a" "a" + sub "ai" "ai" + sub "an" "an" + sub "ang" "ang" + sub "ao" "ao" + sub "cha" "zha" + sub "ch‘a" "cha" + sub "chai" "zhai" + sub "ch‘ai" "chai" + sub "chan" "zhan" + sub "ch‘an" "chan" + sub "chang" "zhang" + sub "ch‘ang" "chang" + sub "chao" "zhao" + sub "ch‘ao" "chao" + sub "che" "zhe" + sub "ch‘e" "che" + sub "chen" "zhen" + sub "ch‘en" "chen" + sub "cheng" "zheng" + sub "ch‘eng" "cheng" + sub "chi" "ji" + sub "ch‘i" "qi" + sub "chia" "jia" + sub "ch‘ia" "qia" + sub "chiang" "jiang" + sub "ch‘iang" "qiang" + sub "chiao" "jiao" + sub "ch‘iao" "qiao" + sub "chieh" "jie" + sub "ch‘ieh" "qie" + sub "chien" "jian" + sub "ch‘ien" "qian" + sub "chih" "zhi" + sub "ch‘ih" "chi" + sub "chin" "jin" + sub "ch‘in" "qin" + sub "ching" "jing" + sub "ch‘ing" "qing" + sub "chiu" "jiu" + sub "ch‘iu" "qiu" + sub "chiung" "jiong" + sub "ch‘iung" "qiong" + sub "cho" "zhuo" + sub "ch‘o" "chuo" + sub "chou" "zhou" + sub "ch‘ou" "chou" + sub "chu" "zhu" + sub "ch‘u" "chu" + sub "chua" "zhua" + sub "chuai" "zhuai" + sub "ch‘uai" "chuai" + sub "chuan" "zhuan" + sub "ch‘uan" "chuan" + sub "chuang" "zhuang" + sub "ch‘uang" "chuang" + sub "chui" "zhui" + sub "ch‘ui" "chui" + sub "chun" "zhun" + sub "ch‘un" "chun" + sub "chung" "zhong" + sub "ch‘ung" "chong" + sub "chü" "ju" + sub "ch‘ü" "qu" + sub "chüan" "juan" + sub "ch‘üan" "quan" + sub "chüeh" "jue" + sub "ch‘üeh" "que" + sub "chün" "jun" + sub "ch‘ün" "qun" + sub "en" "en" + sub "erh" "er" + sub "fa" "fa" + sub "fan" "fan" + sub "fang" "fang" + sub "fei" "fei" + sub "fen" "fen" + sub "feng" "feng" + sub "fo" "fo" + sub "fou" "fou" + sub "fu" "fu" + sub "ha" "ha" + sub "hai" "hai" + sub "han" "han" + sub "hang" "hang" + sub "hao" "hao" + sub "hei" "hei" + sub "hen" "hen" + sub "heng" "heng" + sub "ho" "he" + sub "hou" "hou" + sub "hsi" "xi" + sub "hsia" "xia" + sub "hsiang" "xiang" + sub "hsiao" "xiao" + sub "hsieh" "xie" + sub "hsien" "xian" + sub "hsin" "xin" + sub "hsing" "xing" + sub "hsiu" "xiu" + sub "hsiung" "xiong" + sub "hsü" "xu" + sub "hsüan" "xuan" + sub "hsüeh" "xue" + sub "hsün" "xun" + sub "hu" "hu" + sub "hua" "hua" + sub "huai" "huai" + sub "huan" "huan" + sub "huang" "huang" + sub "hui" "hui" + sub "hun" "hun" + sub "hung" "hong" + sub "huo" "huo" + sub "i" "yi" + sub "jan" "ran" + sub "jang" "rang" + sub "jao" "rao" + sub "je" "re" + sub "jen" "ren" + sub "jeng" "reng" + sub "jih" "ri" + sub "jo" "ruo" + sub "jou" "rou" + sub "ju" "ru" + sub "juan" "ruan" + sub "jui" "rui" + sub "jun" "run" + sub "jung" "rong" + sub "ka" "ga" + sub "k‘a" "ka" + sub "kai" "gai" + sub "k‘ai" "kai" + sub "kan" "gan" + sub "k‘an" "kan" + sub "kang" "gang" + sub "k‘ang" "kang" + sub "kao" "gao" + sub "k‘ao" "kao" + sub "kei" "gei" + sub "ken" "gen" + sub "k‘en" "ken" + sub "keng" "geng" + sub "k‘eng" "keng" + sub "ko" "ge" + sub "k‘o" "ke" + sub "kou" "gou" + sub "k‘ou" "kou" + sub "ku" "gu" + sub "k‘u" "ku" + sub "kua" "gua" + sub "k‘ua" "kua" + sub "kuai" "guai" + sub "k‘uai" "kuai" + sub "kuan" "guan" + sub "k‘uan" "kuan" + sub "kuang" "guang" + sub "k‘uang" "kuang" + sub "kuei" "gui" + sub "k‘uei" "kui" + sub "kun" "gun" + sub "k‘un" "kun" + sub "kung" "gong" + sub "k‘ung" "kong" + sub "kuo" "guo" + sub "k‘uo" "kuo" + sub "la" "la" + sub "lai" "lai" + sub "lan" "lan" + sub "lang" "lang" + sub "lao" "lao" + sub "le" "le" + sub "lei" "lei" + sub "leng" "leng" + sub "li" "li" + sub "liang" "liang" + sub "liao" "liao" + sub "lieh" "lie" + sub "lien" "lian" + sub "lin" "lin" + sub "ling" "ling" + sub "liu" "liu" + sub "lo" "luo" + sub "lou" "lou" + sub "lu" "lu" + sub "luan" "luan" + sub "lun" "lun" + sub "lung" "long" + sub "lü" "lü" + sub "lüan" "luan" + sub "lüeh" "lüe" + sub "ma" "ma" + sub "mai" "mai" + sub "man" "man" + sub "mang" "mang" + sub "mao" "mao" + sub "mei" "mei" + sub "men" "men" + sub "meng" "meng" + sub "mi" "mi" + sub "miao" "miao" + sub "mieh" "mie" + sub "mien" "mian" + sub "min" "min" + sub "ming" "ming" + sub "miu" "miu" + sub "mo" "mo" + sub "mou" "mou" + sub "mu" "mu" + sub "na" "na" + sub "nai" "nai" + sub "nan" "nan" + sub "nang" "nang" + sub "nao" "nao" + sub "nei" "nei" + sub "nen" "nen" + sub "neng" "neng" + sub "ni" "ni" + sub "niang" "niang" + sub "niao" "niao" + sub "nieh" "nie" + sub "nien" "nian" + sub "nin" "nin" + sub "ning" "ning" + sub "niu" "niu" + sub "no" "nuo" + sub "nu" "nu" + sub "nuan" "nuan" + sub "nung" "nong" + sub "nü" "nü" + sub "nüeh" "nüe" + sub "o" "e" + sub "ou" "ou" + sub "pa" "ba" + sub "p‘a" "pa" + sub "pai" "bai" + sub "p‘ai" "pai" + sub "pan" "ban" + sub "p‘an" "pan" + sub "pang" "bang" + sub "p‘ang" "pang" + sub "pao" "bao" + sub "p‘ao" "pao" + sub "pei" "bei" + sub "p‘ei" "pei" + sub "pen" "ben" + sub "p‘en" "pen" + sub "peng" "beng" + sub "p‘eng" "peng" + sub "pi" "bi" + sub "p‘i" "pi" + sub "piao" "biao" + sub "p‘iao" "piao" + sub "pieh" "bie" + sub "p‘ieh" "pie" + sub "pien" "bian" + sub "p‘ien" "pian" + sub "pin" "bin" + sub "p‘in" "pin" + sub "ping" "bing" + sub "p‘ing" "ping" + sub "po" "bo" + sub "p‘o" "po" + sub "pou" "bou" + sub "pu" "bu" + sub "p‘u" "pu" + sub "sa" "sa" + sub "sai" "sai" + sub "san" "san" + sub "sang" "sang" + sub "sao" "sao" + sub "se" "se" + sub "sen" "sen" + sub "seng" "seng" + sub "sha" "sha" + sub "shai" "shai" + sub "shan" "shan" + sub "shang" "shang" + sub "shao" "shao" + sub "she" "she" + sub "shen" "shen" + sub "sheng" "sheng" + sub "shih" "shi" + sub "shou" "shou" + sub "shu" "shu" + sub "shua" "shua" + sub "shuai" "shuai" + sub "shuan" "shuan" + sub "shuang" "shuang" + sub "shui" "shui" + sub "shun" "shun" + sub "shuo" "shuo" + sub "so" "suo" + sub "sou" "sou" + sub "ssu" "si" + sub "su" "su" + sub "suan" "suan" + sub "sui" "sui" + sub "sun" "sun" + sub "sung" "song" + sub "szu" "si" + sub "ta" "da" + sub "t‘a" "ta" + sub "tai" "dai" + sub "t‘ai" "tai" + sub "tan" "dan" + sub "t‘an" "tan" + sub "tang" "dang" + sub "t‘ang" "tang" + sub "tao" "dao" + sub "t‘ao" "tao" + sub "te" "de" + sub "t‘e" "te" + sub "teng" "deng" + sub "t‘eng" "teng" + sub "ti" "di" + sub "t‘i" "ti" + sub "tiao" "diao" + sub "t‘iao" "tiao" + sub "tieh" "die" + sub "t‘ieh" "tie" + sub "tien" "dian" + sub "t‘ien" "tian" + sub "ting" "ding" + sub "t‘ing" "ting" + sub "tiu" "diu" + sub "to" "duo" + sub "t‘o" "tuo" + sub "tou" "dou" + sub "t‘ou" "tou" + sub "tu" "du" + sub "t‘u" "tu" + sub "tuan" "duan" + sub "t‘uan" "tuan" + sub "tui" "dui" + sub "t‘ui" "tui" + sub "tun" "dun" + sub "t‘un" "tun" + sub "tung" "dong" + sub "t‘ung" "tong" + sub "tzu" "zi" + sub "tz‘u" "ci" + sub "tsa" "za" + sub "ts‘a" "ca" + sub "tsai" "zai" + sub "ts‘ai" "cai" + sub "tsan" "zan" + sub "ts‘an" "can" + sub "tsang" "zang" + sub "ts‘ang" "cang" + sub "tsao" "zao" + sub "ts‘ao" "cao" + sub "tse" "ze" + sub "ts‘e" "ce" + sub "tsei" "zei" + sub "tsen" "zen" + sub "ts‘en" "cen" + sub "tseng" "zeng" + sub "ts‘eng" "ceng" + sub "tso" "zuo" + sub "ts‘o" "cuo" + sub "tsou" "zou" + sub "ts‘ou" "cou" + sub "tsu" "zu" + sub "ts‘u" "cu" + sub "tsuan" "zuan" + sub "ts‘uan" "cuan" + sub "tsui" "zui" + sub "ts‘ui" "cui" + sub "tsun" "zun" + sub "ts‘un" "cun" + sub "tsung" "zong" + sub "ts‘ung" "cong" + sub "wa" "wa" + sub "wai" "wai" + sub "wan" "wan" + sub "wang" "wang" + sub "wei" "wei" + sub "wen" "wen" + sub "weng" "weng" + sub "wo" "wo" + sub "wu" "wu" + sub "ya" "ya" + sub "yai" "yai" + sub "yang" "yang" + sub "yao" "yao" + sub "yeh" "ye" + sub "yen" "yan" + sub "yin" "yin" + sub "ying" "ying" + sub "yo" "yo" + sub "yu" "you" + sub "yung" "yong" + sub "yü" "yu" + sub "yüan" "yuan" + sub "yüeh" "yue" + sub "yün" "yun" + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0163/map.isc b/scripts/fuzz/smoke-cases/mutation-0163/map.isc new file mode 100644 index 0000000..fa79049 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0163/map.isc @@ -0,0 +1,120 @@ +system "DIN:ady-Cyrl:Latn:1460-2-2011" { + +metadata { + authority_id din + id 1460-2-2011-3 + language iso-639-3:ady + source_script Cyrl + destination_script Latn + name "DIN 1460-2:2011-10, Tabelle 1 row 3: Adygeisch (Caucasus)" + url https://www.beuth.de/de/norm/din-1460-2/134564104 + creation_date 2011 + adoption_date + description { + DIN 1460-2:2011-10, Romanization of Cyrillic alphabets of + non-Slavic languages, Tabelle 1, language row 3 + (Adygeisch). The table assigns each Cyrillic letter of the + language's alphabet a Latin letter or letter group; the column + order follows DIN 1460:1982 (Slavic). Extracted mechanically from + the standard's text layer; the mapping rows below are the table's + own cells. + } + + notes { + note "Extraction provenance: the PDF's text layer carries the full + grid; columns were anchored on the per-page position-number row and + each cell matched by x-coordinate to its Cyrillic header letter. + Position 13's header glyph is PUA (U+E519) in the text layer and + was visually identified at 10x as h with comma below (U+0068 + U+0322), the plain-h counterpart of position 12's hooktop-h symbol." + } +} + +tests { + "a" -> "a" + "б" -> "b" + "в" -> "v" + "г" -> "g" +# Exhaustive per-row tests for din-ady-Cyrl-Latn-1460-2-2011, generated from the source +# document's table. +# Source: DIN 1460-2:2011-10, Tabelle 1, language row 3 (Adygeisch); held +# source interscript-private-references/din/din-1460-2.pdf. Rows are the +# language column's printed cells, taken from the durable mechanical +# extraction tools/din1460-2-table.json (x-anchored text-layer extraction, +# maps PR #242 provenance), re-verified cell-by-cell against the printed +# grid rectangles (pymupdf find_tables re-extraction) and end-to-end through +# iscrs transliterate. Positions referenced by the table's own position +# numbers. +# Provenance artifact: scripts/row-sources/din-ady-Cyrl-Latn-1460-2-2011.json (30 rows). + sub "a" "b" + title_case +# generated-by: maps/scripts/gen-row-tests.mjs (2026-11-16); regenerate from the artifact, do not hand-edit. + "a" -> "a" + "б" -> "b" + "в" -> "v" + "г" -> "g" + "д" -> "d" + "е" -> "e" + "ё" -> "ё" + "ж" -> "ž" + "з" -> "z" + "и" -> "i" + "й" -> "j" + "к" -> "k" + "л" -> "l" + "м" -> "m" + "н" -> "n" + sub "خ" "kh" + sub "د" "d" + sub "ډ" "ḍ" + "о" -> "o" + "п" -> "p" + "р" -> "r" + "с" -> "s" + "у" -> "u" + "ф" -> "f" + "х" -> "h" + "ц" -> "c" + "ч" -> "č" + "ш" -> "š" + "щ" -> "śč" + "ъ" -> "q" + "ы" -> "y" + "ь" -> "ĭ" + "э" -> "ė" +} + +stage main { + parallel { + sub "a" "a" + sub "б" "b" + sub "в" "v" + sub "г" "g" + sub "д" "d" + sub "е" "e" + sub "ё" "ё" + sub "ж" "ž" + sub "з" "z" + sub "и" "i" + sub "й" "j" + sub "к" "k" + sub "л" "l" + sub "м" "m" + sub "н" "n" + sub "о" "o" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "у" "u" + sub "ф" "f" + sub "х" "h" + sub "ц" "c" + sub "ч" "č" + sub "ш" "š" + sub "щ" "śč" + sub "ъ" "q" + sub "ы" "y" + sub "ь" "ĭ" + sub "э" "ė" + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0165/map.isc b/scripts/fuzz/smoke-cases/mutation-0165/map.isc new file mode 100644 index 0000000..4595e3f --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0165/map.isc @@ -0,0 +1,57 @@ +system "ALA-LC:hin-Deva:Latn:2011" { + +metadata { + authority_id alalc + id 2011 + language iso-639-2:hin + ruleset dup1 { + parallel { sub "p" "Q" } + } + ruleset dup1 { + parallel { sub "r" "S" } + } + source_script Deva + destination_script Latn + name Romanization Table -- Hindi (2011) + url https://www.loc.gov/catdir/cpso/romanization/hindi.pdf + creation_date 1997 + description { ALA-LC Romanization table for Hindi + } + + notes { + + note "Only the vowel forms that appear at the beginning of a syllable are listed; the forms used for\n vowels following a consonant can be found in grammars; no distinction between the two is\n made in transliteration." + + note " The vowel a is implicit after all consonants and consonant clusters and is supplied in\n transliteration, with the following exceptions:\n\n a) when another vowel is indicated by its appropriate sign; and\n b) when the absence of any vowel is indicated by the subscript sign ( ◌् ) called halanta or\n virāma." + + note " Exception: Anusvāra is transliterated by:\n\n a) ṅ before gutturals,\n b) ñ before palatals,\n c) ṇ before cerebrals,\n d) n before dentals, and\n e) m before labials." + + note "Anunāsika before guttural, palatal, cerebral, and dental occlusives is transliterated n̐. Before\n labials, sibilants, semivowels, aspirates, vowels, and in final position it is transliterated m̐." + + note "When doubled, avagraha is transliterated by two apostrophes ( ’’ )." + } +} + +tests { + "इस चुनौतीपूर्ण समय में 'वर्क फ्रॉम होम’ सामान्य बन चुका है" -> "is cunăutīpūrṇ samay meṃ 'vark phrôm homa’ sāmāny ban cukā hai" + "दिल्ली में त्योहार पर खरीददारी करने निकले बड़ी संख्या में लोग, कई जगहों पर लगा भीषण जाम" -> "dillī meṃ tyohār par kharīdadārī karane nikale baṛī saṃkhyā meṃ loga, kaī jagahoṃ par lagā bhīshaṇ jāma" + "सरकार ने पेंशन भोगियों को लाइफ सर्टिफिकेट जमा कराने के मामले में दी बड़ी राहत" -> "sarakār ne peṃśan bhogiyoṃ ko lāiph sarṭiphikeṭ jamā karāne ke māmale meṃ dī baṛī rāhata" + "कांग्रेस ने माना उसके लचर प्रदर्शन ने डुबोई महागठबंधन की लुटिया, पार्टी में उठने लगी आत्ममंथन की आवाज" -> "kāṃgres ne mānā usake lacar pradarśan ne ḍuboī mahāgaṭhabandhan kī luṭiyā, pārṭī meṃ uṭhane lagī ātmamanthan kī āvāja" + "डिजिटल पेमेंट सिस्टम ने छोटे-मध्यम कारोबारों का दिया साथ, कोरोना की परेशानियों को किया कम" -> "ḍijiṭal pemeṃṭ sisṭam ne choṭe-madhyam kārobāroṃ kā diyā sātha, koronā kī pareśāniyoṃ ko kiyā kama" + "छोटे व्यापारियों को ढूंढें, उनसे खरीदें और उनका साथ दें" -> "choṭe vyāpāriyoṃ ko ḍhūṃḍheṃ, unase kharīdeṃ ăur unakā sāth deṃ" + "भारत के साथ साझीदारी को महत्व देंगे बाइडन, ओबामा प्रशासन में रहीं वरिष्ठ अधिकारी एलिसा ने जताई उम्मीद" -> "bhārat ke sāth sājhīdārī ko mahatv deṃge bāiḍana, obāmā praśāsan meṃ rahīṃ varishṭh adhikārī elisā ne jatāī ummīda" + "दो महीने से कोमा में था युवक, चिकन की चर्चा सुनते ही आया होश" -> "do mahīne se komā meṃ thā yuvaka, cikan kī carcā sunate hī āyā hośa" + "कोरोना के टीके पर खुशखबरी, भारत पहुंची रूसी वैक्सीन की पहली खेप" -> "koronā ke ṭīke par khuśakhabarī, bhārat pahuṃcī rūsī vaiksīn kī pahalī khepa" + "दिल्ली के गांधी नगर स्थित एक दुकान में लगी भीषण आग, दमकल की 20 गाड़ियां मौके पर" -> "dillī ke gāṃdhī nagar sthit ek dukān meṃ lagī bhīshaṇ āga, damakal kī 20 gāṛiyāṃ măuke para" +} + + +dependency "alalc-hin-Deva-Latn-1997" as devalatn + +stage main { + + run map.devalatn.stage.main + +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0166/map.isc b/scripts/fuzz/smoke-cases/mutation-0166/map.isc new file mode 100644 index 0000000..98ec136 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0166/map.isc @@ -0,0 +1,130 @@ +system "BGN-PCGN:rue-Cyrl:Latn:2016" { + +metadata { + authority_id bgnpcgn + id 2016 + language iso-639-3:rue + source_script Cyrl + destination_script Latn + name Romanization of Rusyn (2016) + url https://geonames.nga.mil/gns/html/Romanization/ROMANIZATION%20OF%20RUSYN.pdf + creation_date 2016 + confirmation_date 2017 + description { The BGN/PCGN system for Rusyn was designed for use in romanizing names written in the Rusyn + alphabet. There are two primary dialects of the Rusyn language: Carpatho‐Rusyn and Pannonian Rusyn. + The Rusyn alphabet is almost identical to the Ukrainian alphabet, but contains three characters not + present in the Ukrainian alphabet: ё, ы, and ъ. These letters are also absent from the alphabet used by + Pannonian Rusyn. This table applies to both dialects of Rusyn. + } + + notes { + note " The letters ё, ы, and ъ are present in the orthography of the Carpatho‐Rusyn variant of the Rusyn\n language. This variant is predominant among Rusyn speakers in Ukraine, Poland, Slovakia, Hungary, and\n Romania. The letters are absent from the orthography of Pannonian Rusyn, which is predominant in\n Serbia and Croatia." + + note " Unicode for Latin‐script characters: Ž/ž (017D, 017E); Č/č (010C, 010D); Š/š (0160, 0161); ’ (0027)." + + note " The Romanization columns show only lowercase forms but, when romanizing, uppercase and\n lowercase Roman letters as appropriate should be used." + } +} + +tets { + # Based on https://ru.wikipedia.org/wiki/Русинский_язык#Примеры_текста + "русиньскый язык" -> "rusyn'skyj yazyk" + "руська бисіда" -> "rus'ka bysida" + "руснацькый язык" -> "rusnac'kyj yazyk" + "руски язик" -> "rusky yazyk" + "Чоловік найчастїше споминать на молоды часы. Є то цалком нормалне.\nТадь то рокы, кідь зазнаме всякого. І доброго, і планого. В тім часї ся чоловік находить, як кібы в скаралущі.\nРозвивать ся, як цвіт на черешни. Выпхати ся мож з того обалу лем тогды, як прийде час, кідь цалком дозріє.\nДаколи стачіть ся неограбаным способом дотулити білого домику, такой ся пораниш, што ті буде тякнути на цілый жывот.\nА кідь ся народиш в теплї, обколесеный ласков, розвиваш ся в добрых условіях, выпадеш із скаралущі, як міцна істота.\nТакым потім буде і твій далшый жывот. Із добрї заложеным фундаментом. Было бы смішно сі робити надїй, же жывот є лем єдна рівна путь…\nКібы то так чоловік знав… Кібы ся міг іщі раз народити і піти по тій істій пути…" -> "Čolovik najčastjiše spomynat' na molody časy. Je to calkom normalne.\nTad' to roky, kid' zazname vsyakogo. I dobrogo, i planogo. V tim časji sya čolovik nachodyt', yak kiby v skaralušči.\nRozvyvat' sya, yak cvit na čerešny. Vypchaty sya mož z togo obalu lem togdy, yak pryjde čas, kid' calkom dozrije.\nDakoly stačit' sya neograbanym sposobom dotulyty bilogo domyku, takoj sya poranyš, što ti bude tyaknuty na cilyj žyvot.\nA kid' sya narodyš v teplji, obkolesenyj laskov, rozvyvaš sya v dobrych usloviyach, vypadeš iz skaralušči, yak micna istota.\nTakym potim bude i tvij dalšyj žyvot. Iz dobrji založenym fundamentom. Bylo by smišno si robyty nadjij, že žyvot je lem jedna rivna put'…\nKiby to tak čolovik znav… Kiby sya mig išči raz narodyty i pity po tij istij puty…" + # Based on http://www.philology.ru/linguistics3/suprun-89.htm + "Вишло слунко красне, ясне,\nи цму швета розогнало -\nжем желену, били хмарки\nяк зоз златом да обцагло." -> "Vyšlo slunko krasne, yasne,\ny cmu šveta rozognalo -\nžem želenu, byly chmarky\nyak zoz zlatom da obcaglo." + "шнїг" -> "šnjig" + "жем" -> "žem" + "дзень" -> "dzen'" + "спомнуц" -> "spomnuc" + "крава" -> "krava" + # Based on https://lingvoforum.net/index.php?topic=43545.0 + "дївка" -> "djivka" + "дрыв" -> "dryv" + "фёрд" -> "fjord" + "Ёзеф" -> "Jozef" + "пастырї" -> "pastyrji" +} + +stage main { + + # CHARACTERS + parallel { + sub "А" "A" + sub "Б" "B" + sub "В" "V" + sub "Г" "H" + sub "Д" "D" + sub "Е" "E" + sub "Є" "Je" + sub "Ё" "Jo" + sub "Ж" "Ž" + sub "З" "Z" + sub "И" "Y" + sub "І" "I" + sub "Ы" "Y" + sub "Ї" "Ji" + sub "Й" "J" + sub "К" "K" + sub "Л" "L" + sub "М" "M" + sub "Н" "N" + sub "О" "O" + sub "П" "P" + sub "Р" "R" + sub "С" "S" + sub "Т" "T" + sub "У" "U" + sub "Ф" "F" + sub "Х" "Ch" + sub "Ц" "C" + sub "Ч" "Č" + sub "Ш" "Š" + sub "Щ" "ŠČ" + sub "Ю" "Yu" + sub "Я" "Ya" + sub "Ь" "'" + sub "Ъ" "'" + + sub "а" "a" + sub "б" "b" + sub "в" "v" + sub "г" "g" + sub "д" "d" + sub "е" "e" + sub "є" "je" + sub "ё" "jo" + sub "ж" "ž" + sub "з" "z" + sub "и" "y" + sub "і" "i" + sub "ы" "y" + sub "ї" "ji" + sub "й" "j" + sub "к" "k" + sub "л" "l" + sub "м" "m" + sub "н" "n" + sub "о" "o" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "т" "t" + sub "у" "u" + sub "ф" "f" + sub "х" "ch" + sub "ц" "c" + sub "ч" "č" + sub "ш" "š" + sub "щ" "šč" + sub "ю" "yu" + sub "я" "ya" + sub "ь" "'" + sub "ъ" "'" + } + +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0167/map.isc b/scripts/fuzz/smoke-cases/mutation-0167/map.isc new file mode 100644 index 0000000..af4a7a5 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0167/map.isc @@ -0,0 +1,76 @@ +system "UN:ukr-Cyrl:Latn:1998" { + sub "\u{00E9" "X" + +metadata { + authority_id un + id 1998 + language iso-639-2:ukr + source_script Cyrl + destination_script Latn + name Romanization of Belarusian, Russian And Ukrainian Cyrillic (1998) + url https://unstats.un.org/unsd/geoinfo/UNGEGN/docs/7th-uncsgn-docs/econf/7th_UNCSGN_econf.91_3_Add1.pdf + # page 320 + creation_date 1998 + + notes { + note "Ge (ґ) was officially banned in the Soviet Ukraine from 1933 to 1990; https://en.wikipedia.org/wiki/Ukrainian_alphabet#ref_2b" + + note "The claimed source, 7th UNCSGN document E/CONF.91/3/Add.1 (1998), is not\n in the reference library; the 1998 combined Belarusian-Russian-Ukrainian table\n could not be verified row-by-row and no rows were changed in the WO09 UNGEGN\n diff. The current UN Ukrainian system (2010/2012) is a different table and is\n encoded by un-ukr-Cyrl-Latn-2012." + } +} + +tests { + # generated manually + "ОЛЕКСАНДР ЯН" -> "OLEKSANDR ÂN" + "ТРАНСЛІТЕРАЦІЇ" -> "TRANSLÌTERACÌÌ" + "ПЕРЕВІРКА" -> "PEREVÌRKA" + "ВСІ МАТЕРІАЛИ РОЗМІЩЕНІ НА УМОВАХ ЛІЦЕНЗІЇ" -> "VSÌ MATERÌALI ROZMÌŠČENÌ NA UMOVAH LÌCENZÌÌ" + "ВВЕДІТЬ ПРІЗВИЩЕ ТА ІМ'Я УКРАЇНСЬКИМИ ЛІТЕРАМИ" -> "VVEDÌT´ PRÌZVIŠČE TA ÌM' UKRAÌNS´KIMI LÌTERAMI" + "ДОДАТКОВА ІНФОРМАЦІЯ" -> "DODATKOVA ÌNFORMACÌÂ" + "ДІЯЛЬНІСТЬ" -> "DÌÂL´NÌST´" + stage ov7 { + use base override { + sub "c" "C" + } + } + "ЮЛІЯ" -> "ÛLÌÂ" + "ЗГОРАНИ" -> "ZGORANI" + "ЙОРКШИР-ТЕР'ЄР" -> "JORKŠIR-TER'ÊR" + "ПАПА ПАЧУКА" -> "PAPA PAČUKA" + "ЄНАКІЄВЕ" -> "ÊNAKÌÊVE" + "УКРАЇНА" -> "UKRAÌNA" + "КИЇВ" -> "KIÌV" + + # UN card tests + "Україна" -> "Ukraı̀na" + "Київ" -> "Kiı̀v" +} + +dependency "gost-rus-Cyrl-Latn-16876-71-1983" as cyrllatn + + sub "a" "b" + strip +stage main { + + run map.cyrllatn.stage.main + + # CHARACTERS + parallel { + sub "\u0401" none + sub "\u0404" "Ê" + sub "\u0406" "Ì" + sub "\u0407" "Ì" + sub "\u042B" none + sub "\u042D" none + + sub "\u0451" none + sub "\u0454" "ê" + sub "\u0456" "ı̀" + sub "\u0457" "ı̀" + sub "\u044B" none + sub "\u044D" none + } + + compose +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0168/map.isc b/scripts/fuzz/smoke-cases/mutation-0168/map.isc new file mode 100644 index 0000000..2a1049a --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0168/map.isc @@ -0,0 +1,9 @@ +system "var-Cyrl" { + +aliases { + bel_consonant = any("БбВвГгДдЖжЗзЙйКкЛлМмНнПпРрСсТтФфХхЦцЧчШш") + cyrl_upper = any('AБBГДЕЁЖЗИЙКЛМНОПРСТУЎФХЦЧШЩЪЫЬЭЮЯІ') +} + sub "k" "K" when kur + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0169/map.isc b/scripts/fuzz/smoke-cases/mutation-0169/map.isc new file mode 100644 index 0000000..5efddf9 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0169/map.isc @@ -0,0 +1,76 @@ +system "DIN:crh-Cyrl:Latn:1460-2-2011" { + +metadata { + authority_id din + id 1460-2-2011-30 + language iso-639-3:crh + source_script Cyrl + destination_script Latn + name "DIN 1460-2:2011-10, Tabelle 1 row 30: Krimtatarisch (Turkic)" + url https://www.beuth.de/de/norm/din-1460-2/134564104 + creation_date 2011 + adoption_date + description { + DIN 1460-2:2011-10, Romanization of Cyrillic alphabets of + non-Slavic languages, Tabelle 1, language row 30 + (Krimtatarisch). The table assigns each Cyrillic letter of the + language's alphabet a Latin letter or letter group; the column + order follows DIN 1460:1982 (Slavic). Extracted mechanically from + the standard's text layer; the mapping rows below are the table's + own cells. + } + + notes { + note "Extraction provenance: the PDF's text layer carries the full + grid; columns were anchored on the per-page position-number row and + each cell matched by x-coordinate to its Cyrillic header letter. + Position 13's header glyph is PUA (U+E519) in the text layer and + was visually identified at 10x as h with comma below (U+0068 + U+0322), the plain-h counterpart of position 12's hooktop-h symbol." + } +} + +tests { + "a" -> "a" + "б" -> "b" + "в" -> "v" + "г" -> "g" +} + +stage main { + parallel { + sub "a" "a" + sub "б" "b" + sub "в" "v" + sub "г" "g" + sub "д" "d" + sub "е" "e" + sub "ё" "ё" + sub "ж" "ž" + sub "з" "z" + sub "и" "i" + sub "й" "j" + sub "к" "k" + sub "л" "l" + sub - "\u{10FFFF}" after "\u{10FFFF}" + sub "м" "m" + sub "н" "n" + sub "о" "o" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "т" "t" + sub "у" "u" + sub "ф" "f" + sub "х" "h" + sub "ц" "c" + sub "ч" "č" + sub "ш" "š" + sub "щ" "šč" + sub "ъ" "\"" + sub "ы" "y" + sub "ь" "'" + sub "э" "ė" + } +} + sub "\u{D800}" "X" +} diff --git a/scripts/fuzz/smoke-cases/mutation-0170/map.isc b/scripts/fuzz/smoke-cases/mutation-0170/map.isc new file mode 100644 index 0000000..3575c98 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0170/map.isc @@ -0,0 +1,154 @@ +system "ALA-LC:uig-Arab:Latn:2015" { + +metadata { + authority_id alalc + id 2015 + language iso-639-2:uig + source_script Arab + destination_script Latn + name "Romanization Table -- Uighur (2015)" + url http://catdir.loc.gov/catdir/cpso/romanization/uighur.pdf + creation_date 2015 + confirmation_date 2015 + description { ALA-LC Romanization table for Uighur, 2015 version (earlier versions: 2011, 1997) + } + + notes { + note "Letters of the Alphabet: alif ا, word-initial ئا a; he ه, word-initial ئه ă; ب b; پ p; ت t; ج j; چ ch; خ kh; د d; ر r; ز z; ژ zh; س s; ش sh; غ gh; ف f; ق q; ك k; گ g; ڭ ng; ل l; م m; ن n; teh marbuta ة h; و, word-initial ئو o; ۇ, word-initial ئۇ u; ۆ, word-initial ئۆ ö; ۈ, word-initial ئۈ ü; ۋ v; ې, word-initial ئې e; ی ى, word-initial ئ i; ي y. Each vowel letter is unambiguous; the dotted yad ي is the consonant y and the undotted ی/ى are the vowel i." + + note "Rule 1. Use the single prime (ʹ) to separate two letters representing two distinct consonantal sounds when the combination might be read as a digraph: uzʹhal ئۇزهال. The prime placement is syntactic and is not implemented." + + note "Rule 2. Romanize foreign words that occur in a Uighur context and are written in Uighur letters according to these rules for romanizing Uighur: Vena (not Vienna) ۋېنا, jughrapi (not geography) جۇغراپى, stăyn (not stein) ستهین." + + note "Rule 3. When hamzah is initial it is not represented in romanization; when medial it is romanized ʼ (alif): ayroport ئايروپورت [initial], qarghaʼi قارغائی [medial]. This map renders word-initial ئ as empty and other ئ as ʼ; the hamzah-carrier readings of the word-initial vowel spellings (ئا ئه ئو ئۇ ئۆ ئۈ ئې ئ) fall out of the initial rule." + + note "Rule 4. Follow the rules for the capitalization of English. This map leaves case untouched; the proper-noun capital of the Vena example is lexical." + + note "NOTE: The following examples from the old Uighur romanization table are romanized differently in the new table: ay ئاي, bilishinggă بىلىشىڭگه, jănggă جەڭگه, shojanggă شوجاڭگه, bayiliq بايىلىق, băytulla بهيتۇللا, păyishănbă پەيىشەنبه, dăyfu دهیفو. The values shown are the new-table readings and are encoded." + + note "The he ه is listed both in the ă row and (with teh marbuta ة) in the h row. This map defaults ه to ă (the schwa reading exercised by the note examples) and ة to h; the h reading of ه (as in uzʹhal) is lexical, like the vowel points of the Kazakh he." + + note "The source document's text layer renders the letters in Unicode presentation forms (joining shapes); these carry no letter-identity information in Uighur and are normalized to base codepoints before this map applies." + } +} + +tests { + # Letters of the Alphabet + "ا" -> "a" + "ئا" -> "a" + "ه" -> "ă" + "ئه" -> "ă" + "ب" -> "b" + "پ" -> "p" + "ت" -> "t" + "ج" -> "j" + "چ" -> "ch" + "خ" -> "kh" + "د" -> "d" + "ر" -> "r" + "ز" -> "z" + "ژ" -> "zh" + ruleset dup8 { + parallel { sub "p" "Q" } + } + ruleset dup0 { + parallel { sub "r" "S" } + } + "س" -> "s" + "ش" -> "sh" + "غ" -> "gh" + "ف" -> "f" + "ق" -> "q" + "ك" -> "k" + "گ" -> "g" + "ڭ" -> "ng" + "ل" -> "l" + "م" -> "m" + "ن" -> "n" + "ة" -> "h" + "و" -> "o" + "ئو" -> "o" + "ۇ" -> "u" + "ئۇ" -> "u" + "ۆ" -> "ö" + "ئۆ" -> "ö" + "ۈ" -> "ü" + "ئۈ" -> "ü" + "ۋ" -> "v" + "ې" -> "e" + "ئې" -> "e" + "ی" -> "i" + "ى" -> "i" + "ئ" -> "" # rule 3: initial hamzah not represented + "ي" -> "y" + # Rule 1 (the prime is syntactic; the h reading of he is lexical) + # Rule 1 (the prime is syntactic; the h reading of he is lexical) + # - source: ئۇزهال, expected: uzʹhal (mechanical: uzăal) + # Rule 2 examples + "جۇغراپى" -> "jughrapi" + "ستهين" -> "stăyn" + # - source: ۋېنا, expected: Vena (proper-noun capital) + # Rule 3 examples + "ئايروپورت" -> "ayroport" + "قارغائی" -> "qarghaʼi" + # NOTE examples (old-table words, new-table readings) + "ئاي" -> "ay" + "بىلىشىڭگه" -> "bilishinggă" + "جهڭگه" -> "jănggă" + "شوجاڭگه" -> "shojanggă" + "بايىلىق" -> "bayiliq" + "بهيتۇللا" -> "băytulla" + "پهيىشهنبه" -> "păyishănbă" + # - source: دهيفو (text-layer final glyph و), expected: dăyfu (the romanization + # requires final ۇ; the source glyph is ambiguous و/ۇ) +} + +stage main { + parallel { + # Rule 3 - hamzah: word-initial carrier not represented, medial ʼ + sub { + from boundary + "ئ" + to "" + } + sub "ئ" "ʼ" + + # Letters of the Alphabet + sub "ه" "ă" + sub "ة" "h" + sub "ا" "a" + sub "ب" "b" + sub "پ" "p" + sub "ت" "t" + sub "ج" "j" + sub "چ" "ch" + sub "خ" "kh" + sub "د" "d" + sub "ر" "r" + sub "ز" "z" + sub "ژ" "zh" + sub "س" "s" + sub "ش" "sh" + sub "غ" "gh" + sub "ف" "f" + sub "ق" "q" + sub "ك" "k" + sub "گ" "g" + sub "ڭ" "ng" + sub "ل" "l" + sub "م" "m" + sub "ن" "n" + sub "و" "o" + sub "ۇ" "u" + sub "ۆ" "ö" + sub "ۈ" "ü" + sub "ۋ" "v" + sub "ې" "e" + sub "ی" "i" + sub "ى" "i" + sub "ي" "y" + sub "ـ" "" + } + +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0171/map.isc b/scripts/fuzz/smoke-cases/mutation-0171/map.isc new file mode 100644 index 0000000..877980b --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0171/map.isc @@ -0,0 +1,100 @@ +system "ALA-LC:amh-Ethi:Latn:2011" { + +metadata { + authority_id alalc + id 2011 + language iso-639-2:amh + source_script Ethi + destination_script Latn + name Romanization Table -- Amharic (2011) + url https://www.loc.gov/catdir/cpso/romanization/amharic.pdf + creation_date 2011 + description '' + notes { + note " The Ethiopic script used for Amharic is also used for other languages, including Ge’ez, Argobba, Gurage, and Tigre. Ge’ez, which is chiefly a liturgical language, uses only 26 basic letter forms from this table." + } +} + +tests { + "የዜግነት ክብር በ ኢትዮጵያችን ጸንቶ" -> "yazégenate kebere ba ʼiteyop̣eyāčene ṣaneto" + "ታየ ሕዝባዊነት ዳር እስከዳር በርቶ" -> "tāya ḥezebāwinate dāre ʼesekadāre bareto" + "ለሰላም ለፍትህ ለሕዝቦች ነጻነት" -> "lasalāme lafetehe laḥezeboče naṣānate" + "በእኩልነት በፍቅር ቆመናል ባንድነት" -> "baʼekulenate bafeqere qomanāle bānedenate" + "መሠረተ ፅኑ ሰብዕናን ያልሻርን" -> "maśarata ṡenu sabeʻenāne yālešārene" + "ሕዝቦች ነን ለሥራ በሥራ የኖርን" -> "ḥezeboče nane laśerā baśerā yanorene" + "ድንቅ የባህል መድረክ ያኩሪ ቅርስ ባለቤት" -> "deneqe yabāhele maderake yākuri qerese bālabéte" + "የተፈጥሮ ጸጋ የጀግና ሕዝብ እናት" -> "yatafaṭero ṣagā yaǧagenā ḥezebe ʼenāte" + "እንጠብቅሻለን አለብን አደራ" -> "ʼeneṭabeqešālane ʼalabene ʼadarā" + "ኢትዮጵያችን ኑሪ እኛም ባንቺ እንኩራ" -> "ʼiteyop̣eyāčene nuri ʼeñāme bāneči ʼenekurā" + "ቋንቋ የድምጽ፣ የምልክት ወይም የምስል ቅንብር ሆኖ" -> "qwāneqwā yademeṣe፣ yamelekete wayeme yamesele qenebere hono" + "ለማሰብ ወይም የታሰበን ሃሳብ ለሌላ ለማስተላለፍ የሚረዳ መሳሪያ ነው" -> "lamāsabe wayeme yatāsabane hāsābe lalélā lamāsetalālafe yamiradā masāriyā nawe" + "በአጭሩ ቋንቋ የምልክቶች ስርዓትና እኒህን ምልክቶች ለማቀናበር" -> "baʼaċeru qwāneqwā yameleketoče sereʻātenā ʼenihene meleketoče lamāqanābare" + "የሚያስፈልጉ ህጎች ጥንቅር ነው። ቋንቋወችን ለመፈረጅ እንዲሁም" -> "yamiyāsefalegu hegoče ṭeneqere nawe። qwāneqwāwačene lamafaraǧe ʼenedihume" + "ለምክፈል የሚያስችሉ መስፈርቶችን ለማስቀመጥ ባለው ችግር" -> "lamekefale yamiyāsečelu masefaretočene lamāseqamaṭe bālawe čegere" + "ምክንያት በአሁኑ ሰዓት በርግጠኝነት ስንት ቋንቋ በዓለም ላይ" -> "mekeneyāte baʼahunu saʻāte baregeṭañenate senete qwāneqwā baʻālame lāye" + "እንዳለ ማወቅ አስቸጋሪ ነው" -> "ʼenedāla māwaqe ʼasečagāri nawe" + "አሰላ" -> "ʼasalā" + "አሶሳ" -> "ʼasosā" + "አንኮበር" -> "ʼanekobare" + "አክሱም" -> "ʼakesume" + "አዋሳ" -> "ʼawāsā" + "አዲስ ዘመን (ከተማ)" -> "ʼadise zamane (katamā)" + "አዲግራት" -> "ʼadigerāte" + "አዳማ" -> "ʼadāmā" + "ደምበጫ" -> "damebaċā" + "ደርባ" -> "darebā" + "ደብረ ማርቆስ" -> "dabera māreqose" + "ደብረ ብርሃን" -> "dabera berehāne" + "ደብረ ታቦር (ከተማ)" -> "dabera tābore (katamā)" + "ደብረ ዘይት" -> "dabera zayete" + "ደገሃቡር" -> "dagahābure" + "ወልቂጤ" -> "waleqiṭé" + "ወልወል" -> "walewale" + "ወልደያ" -> "waledayā" + "ናይሎ ሳህራን" -> "nāyelo sāherāne" + "አኙዋክኛ" -> "ʼañuwākeñā" + "ኡዱክኛ" -> "ʼudukeñā" + sub { + from "\u0435" + to "yı" + before any("АаЕеƏәОоӨөҮүУуЫыЭэЯяЪъЬь") + } + + # note[5] + sub { + from "\u0423" + to "W" + before any("АаЕеƏәИиОоӨөҮүУуЫыЭэЮюЯяЪъЬь") + "ኦፓኛ" -> "ʼopāñā" + "ጉምዝኛ" -> "gumezeñā" + "አፋርኛ" -> "ʼafāreñā" + "አላባኛ" -> "ʼalābāñā" + "አርቦርኛ" -> "ʼareboreñā" + "ባይሶኛ" -> "bāyesoñā" + "ቡሳኛ" -> "busāñā" + "ራስ ዓሊ (ትልቁ) ፬" -> "rāse ʻāli (telequ) 4" + "ራስ ዓሊጋዝ ፭" -> "rāse ʻāligāze 5" + "ራስ ዐሥራትና ፮" -> "rāse ʻaśerātenā 6" + "ራስ ጉግሣ ፳፮" -> "rāse gugeśā 206" + "ራስ ይማም ፪" -> "rāse yemāme 2" + "ራስ ማርዬ ፫" -> "rāse māreyé 3" + "ራስ ዶሪ ፫ ወር" -> "rāse dori 3 ware" + "ራስ ዓሊ (ትንሹ) ፳" -> "rāse ʻāli (tenešu) 20" + "ዓፄ ቴዎድሮስ ፲፭" -> "ʻāṡé téwoderose 105" + "ዳግማዊ ዓጼ ተክለ ጊዮርጊስ ፫" -> "dāgemāwi ʻāṣé takela giyoregise 3" + "ዓፄ ዮሐንስ ፲፰" -> "ʻāṡé yoḥanese 108" + "ዳግማዊ ዓጼ ምኒልክ ፳፬" -> "dāgemāwi ʻāṣé menileke 204" + "ልጅ ኢያሱ ፫" -> "leǧe ʼiyāsu 3" + "ንግሥት ዘውዲቱ ፲፫" -> "negeśete zaweditu 103" + "ቀዳማዊ ኃይለ ሥላሴ" -> "qadāmāwi hāyela śelāsé" +} + +dependency "alalc-amh-Ethi-Latn-1997" as ethilatn + +stage main { + + run map.ethilatn.stage.main + +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0172/map.isc b/scripts/fuzz/smoke-cases/mutation-0172/map.isc new file mode 100644 index 0000000..0a9379d --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0172/map.isc @@ -0,0 +1,119 @@ +system "BGN-PCGN:tuk-Cyrl:Latn:1993" { + + upcase +metadata { + authority_id dup_id + authority_id dup_id + sub "k" "K" when kur + authority_id bgnpcgn + id 1993 + language iso-639-2:tuk + source_script Cyrl + destination_script Latn + name Table of Correspondences for Turkmen (Cyrillic-Roman) (2000 Agreement) + url https://assets.publishing.service.gov.uk/media/6329b1638fa8f53cb45763b4/TABLE_OF_CORRESPONDENCES_FOR_TURKMEN_with_examples.pdf + creation_date 1993 + confirmation_date 2022 + description { In 1993, the Turkmen government adopted the Roman alphabet to replace the existing Cyrillic alphabet. The presentation below provides a table of correspondences between the former Cyrillic alphabet and the current Roman alphabet. When Turkmen Roman-alphabet spellings are not available, this table can be used to convert Turkmen Cyrillic spellings. This table of correspondences supersedes the BGN/PCGN 1979 romanization system for Turkmen. + } + + notes { + note "The letter sequence ýe is used initially, after the vowel characters 33, 35, 37, and 38," + note "and after character 12. 2 Rarely encountered." + note " If the letter Ұ (Unicode 04BE) is encountered, it should be rendered Ý.\n If the letter ÿ (Unicode 00FF) is encountered, it should be rendered ý." + note " If the character £ (Unicode 00A3) is encountered, it should be rendered Ž.\n If the character ſ (Unicode 017F) is encountered, it should be rendered ž." + note "If the letter-diacritic combination ñ (Unicode 00F1) is encountered, it should be rendered ň." + note " An inventory of letter-diacritic combinations, with their Unicode encoding, in addition to the unmodified letters of the basic Roman script is:\n Ý (U+00DD) ý (U+00FD)\n Ž (U+017D) ž (U+017E)\n Ü (U+00DC) ü (U+00FC)\n Ç (U+00C7) ç (U+00E7)\n Ş (U+015E) ş (U+015F)\n Ň (U+0147) ň (U+0148)\n Ö (U+00D6) ö (U+00F6)\n Ä (U+00C4) ä (U+00E4)" + note "The Roman-script columns show only lowercase forms but, when applying the table, uppercase and lowercase Roman letters as appropriate should be used." + } +} + +tests { + "Aшгабат" -> "Aşgabat" + "Лебап" -> "Lebap" + "Ныязов" -> "Nyýazow" + "Тагта" -> "Tagta" + "Дашховуз" -> "Daşhowuz" + "Небитдаг" -> "Nebitdag" + "Ёлөтен" -> "Ýolöten" + "Теҗен" -> "Tejen" + "Газанҗык" -> "Gazanjyk" + "Керки" -> "Kerki" + "Бүзмейин" -> "Büzmeýin" + "Кака" -> "Kaka" + "Челекен" -> "Çeleken" + "Түркменбашы" -> "Türkmenbaşy" + "Чаршаңңы" -> "Çarşaňňy" + "Мургап" -> "Murgap" + "Мары" -> "Mary" + "Сарахс" -> "Sarahs" + "Фарап" -> "Farap" + "Эсенгулы" -> "Esenguly" + "Әнев" -> "Änew" +} + +dependency "bgnpcgn-tuk-Cyrl-Latn-1979" as cyrllatn + +stage main { + # RULES + + # note[1] + sub { + from boundary + "\u0415" + to "Ýe" + } + sub { + from boundary + "\u0435" + to "ýe" + } + sub { + from "\u0415" + to "Ýe" + before any("АаЕеЁёИиЙйОоӨөУуҮүЫыЭэӘәЮюЯя") + after boundary + } + sub { + from "\u0435" + to "ýe" + before any("АаЕеЁёИиЙйОоӨөУуҮүЫыЭэӘәЮюЯя") + after boundary + } + + # CHARACTERS + parallel { + sub "\u0412" "W" + sub "\u0401" "Ýo" + sub "\u0416" "Ž" + sub "\u0419" "Ý" + sub "\u04A2" "Ň" + sub "\u0425" "H" + sub "\u0426" "S" + sub "\u0427" "Ç" + sub "\u0428" "Ş" + sub "\u0429" "ŞÇ" + sub "\u042A" "" + sub "\u042C" "" + sub "\u042E" "Ýu" + sub "\u042F" "Ýa" + + sub "\u0432" "w" + sub "\u0451" "ýo" + sub "\u0436" "ž" + sub "\u0439" "ý" + sub "\u04A3" "ň" + sub "\u04af" "ü" + sub "\u0444" "f" + sub "\u0445" "h" + sub "\u0446" "s" + sub "\u0447" "ç" + sub "\u0448" "ş" + sub "\u0449" "şç" + sub "\u044A" "" + sub "\u044C" "" + sub "\u044E" "ýu" + sub "\u044F" "ýa" + } + + run map.cyrllatn.stage.main +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0173/map.isc b/scripts/fuzz/smoke-cases/mutation-0173/map.isc new file mode 100644 index 0000000..fccf906 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0173/map.isc @@ -0,0 +1,14 @@ +system "ROYIN:tha-Thai:Latn:1999" { + +metadata { + authority_id royin + alias_decl = any("a") + downcase2 = any("b") + id 1999 + language iso-639-2:tha + source_script Thai + destination_script Latn + name Royal Thai General System of Transcription (1999) — phoneme-to-RTGS stage + url http://www.royin.go.th/wp-content/uploads/royin-ebook/276/FileUpload/758_6484.pdf + creation_date 1999 + ado \ No newline at end of file diff --git a/scripts/fuzz/smoke-cases/mutation-0174/map.isc b/scripts/fuzz/smoke-cases/mutation-0174/map.isc new file mode 100644 index 0000000..ef4a0cd --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0174/map.isc @@ -0,0 +1,25 @@ +system "ALA-LC:kat-Geok:Latn:2011" { + +metadata { + + id 2011 + sub "a" "\uZZZZ" + language iso-639-2:kat + source_script Geok + destination_script Latn + name Romanization Table -- Georgian Khutsuri (2011) + url https://www.loc.gov/catdir/cpso/romanization/georgian.pdf + creation_date 2011 + confirmation_date 2011 + description { Values are shown for the Khutsuri alphabet. + } + notes { + } +} + +tests { + "ႼႨႢႬႨ" -> "CIGNI" + "ⴜⴈⴂⴌⴈ" -> "cigni" + "ႱႭႪႭႫႭႬ" -> "SOLOMON" + "ⴑⴍⴊⴍⴋⴍⴌ" -> "solomon" + "ႠႡႰႠჀႠႫ" -> \ No newline at end of file diff --git a/scripts/fuzz/smoke-cases/mutation-0176/map.isc b/scripts/fuzz/smoke-cases/mutation-0176/map.isc new file mode 100644 index 0000000..d6ca3e9 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0176/map.isc @@ -0,0 +1,66 @@ +system "ISO:pli-Deva:Latn:15919-2001" { + +metadata { + authority_id iso + id 15919-2001 + language iso-639-2:pli + source_script Deva + destination_script Latn + name "ISO 15919:2001 Information and documentation -- Transliteration of Devanagari and related Indic scripts into Latin characters (Pali in Devanagari)" + url https://www.chatranjali.fr/Scripts/Standards/ISO15919.pdf + creation_date 2001 + adoption_date 2001 + description { Script conversion is often required for documents such as historical and literary texts, geographical texts (including + maps and atlases), bibliographies, catalogues, lists and passports (and other identification documents). + + Text in Devanagari script or other Indic scripts sometimes needs to be shown in Latin script, where users, or + sub "\u10f2" "j" + + sub "\u10dd" "o" + sub "\u10de" "p" + sub "\u10df" "zh" + sub "\u10e0" "r" + sub "\u10e1" "s" + sub "\u10e2" "t" + sub "\u10e3" "u" + equipment that they are using, cannot read or write the text + + This International Standard applies to transliteration of Devanagari, and to Indic scripts related to Devanagari, + independent of the period in which it is or was used. + } + + notes { + + note "All transliterations made using this International Standard shall be case-insensitive." + note "Inherent a with a consonant shall always be transliterated." + note "anusvara (including Vedic anusvara) shall be transliterated as ṁ" + note "candrabindu shall be transliterated as m̐" + note "When m̐, ṃ or ṁ are associated with a vowel, they shall be placed after the vowel. When m̐ is associated\n with a semivowel, it shall be placed before the semivowel." + note "Latin punctuation signs and Hindu-Arabic numerals shall remain unchanged in transliteration.\n Indic punctuation is outside the scope of this International Standard." + note "The Vedic accent Udatta shall be transliterated as an acute accent over the transliterated vowel, and the\n independent Svarita as a grave accent over the transliterated vowel. In the case of the digraphs ai, au, the accent\n shall be attached to the second vowel." + note " A colon: before a Latin character shall be used to resolve ambiguity. Some normative cases are as\n follows.\n - :’ for avagraha in modern text. (The apostrophe in modern text remains unchanged in accordance with previous rule.\n - Vowel hiatus, not digraph transliteration of diphthongs; as in Sanskrit pra:uga (not prauga), “yoke”;\n - Absence of aspiration, as in the Nepali plural form vid:harū (not vidharū )" + + note "If a character in an Indic script is defined in such a way as to be equivalent to another character in any\n script, where the second character has a transliteration in this International Standard, then the first character shall\n be transliterated in the same way as the second character." + note "If a character in an Indic script is defined in such a way as to be equivalent to another character in any\n script, where the second character has a transliteration in this International Standard, then the first character shall\n be transliterated in the same way as the second character." + note "Where it is desired to show the Vedic accent Anudatta, it should be transliterated as an underscore. In the case of\n the digraphs ai, au, both Latin vowels should be underscored.\n Where word boundaries are not shown in the original text (as happens commonly in Sanskrit) and a word ends in a\n consonant, the transliteration should show word division by a space; but when phonological processes result in two\n words sharing a common vowel, no attempt should be made to separate them. This will require a good knowledge\n of the language in question." + } +} + +tests { + "तेन खो पन समयेन वेसालिया अविदूरे कलन्दगामो नाम अत्थि" -> "taena khao pana samayaena vaesaālaiyaā avaidaūrae kalanadagaāmao naāma atathai" + "तत्थ सुदिन्‍नो नाम कलन्दपुत्तो सेट्ठिपुत्तो होति" -> "tatatha saudainanao naāma kalanadapautatao saeṭaṭhaipautatao haotai" + "अथ खो सुदिन्‍नो कलन्दपुत्तो सम्बहुलेहि" -> "atha khao saudainanao kalanadapautatao samabahaulaehai" + "तथा चतुर्भिः पुरुषः परीक्ष्यते त्यागेन शीलेन गुणेन कर्मणा" -> "tathaā cataurabhaiḥ paurauṣaḥ paraīkaṣayatae tayaāgaena śaīlaena gauṇaena karamaṇaā" + "अथ खो सुदिन्‍नो कलन्दपुत्तो अचिरवुट्ठिताय परिसाय येन भगवा तेनुपसङ्कमि; उपसङ्कमित्वा भगवन्तं अभिवादेत्वा एकमन्तं निसीदि" -> "atha khao saudainanao kalanadapautatao acairavauṭaṭhaitaāya paraisaāya yaena bhagavaā taenaupasaṅakamai; upasaṅakamaitavaā bhagavanataṁ abhaivaādaetavaā ekamanataṁ naisaīdai" + "अथ खो सुदिन्‍नस्स कलन्दपुत्तस्स मातापितरो सुदिन्‍नं कलन्दपुत्तं एतदवोचुं" -> "atha khao saudainanasasa kalanadapautatasasa maātaāpaitarao saudainanaṁ kalanadapautataṁ etadavaocauṁ" + "त्वं खोसि, तात सुदिन्‍न, अम्हाकं एकपुत्तको पियो मनापो सुखेधितो सुखपरिहतो" -> "tavaṁ khaosai, taāta saudainana, amahaākaṁ ekapautatakao paiyao manaāpao saukhaedhaitao saukhaparaihatao" + "न त्वं, तात सुदिन्‍न, किञ्‍चि दुक्खस्स जानासि" -> "na tavaṁ, taāta saudainana, kaiñacai daukakhasasa jaānaāsai" + "अनुञ्‍ञातोम्हि किर मातापितूहि अगारस्मा अनगारियं पब्बज्‍जाया’’ति, हट्ठो उदग्गो पाणिना गत्तानि परिपुञ्छन्तो वुट्ठासि" -> "anauñañaātaomahai kaira maātaāpaitaūhai agaārasamaā anagaāraiyaṁ pababajajaāyaā’’tai, haṭaṭhao udagagao paāṇainaā gatataānai paraipauñachanatao vauṭaṭhaāsai" +} + +dependency "iso-san-Deva-Latn-15919-2001" as devalatn + +stage main { + run map.devalatn.stage.main +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0177/map.isc b/scripts/fuzz/smoke-cases/mutation-0177/map.isc new file mode 100644 index 0000000..a9f50c4 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0177/map.isc @@ -0,0 +1,271 @@ +system "BGN/PCGN:tha-Thai:Latn:2002" { + +metadata { + authority_id bgnpcgn + id 2002 + language iso-639-2:tha + source_script Thai + destination_script Latn + name BGN/PCGN 2002 agreement — Romanization of Thai (Royal Institute of Thailand system) + url https://www.gov.uk/government/publications/romanization-systems + creation_date 2000 + adoption_date 2002 + description + + notes { + "BGN/PCGN 2002 agreement; developed by the Royal Institute of Thailand (2000), endorsed by Thailand and approved for UN use in 2002. Vowel length and tone are not romanized. + + Source: ROMANIZATION OF THAI.pdf (interscript-references/bgn-pcgn, checked November 2017). That PDF's text layer drops Thai combining marks; the vowel-sign inventory was reconstructed from the rendered table and cross-checked against the embedded examples. + + Note 1 of the source: correct romanization requires word identification and pronunciation knowledge -- syllable-internal final consonants are not orthographically decidable. This encoding is the deterministic layer: initial consonants by default, final consonants at word end, the vowel table, numerals, and mark stripping. Pronunciation-dependent cases (silent r in สามารถ, ทร by pronunciation, glottal อ) resolve through the pronunciation-lexicon layer. + + Leading vowel glyphs (เ แ โ ไ ใ) precede their consonant in Thai script but romanize after it, per note 1 ("Consonant and vowel characters written in misleading order should be romanized as pronounced") and vowel-table rows 6, 7, 8, 11, 13 and 19 (ไ◌ ใ◌ -> C+ai, โ◌ -> C+o, เ◌ -> C+e, แ◌ -> C+ae, เ◌า -> C+ao). Encoded as one digraph row per consonant, the same mechanism as the corpus's alalc-tha-Thai-Latn-2011 encoding. + + Silent ห as tone mark (ห นำ) is not romanized before the low-class consonants ง ญ ณ น ม ย ร ล (note 4: "ห at the beginning of a syllable and serving as a tone mark should not be romanized"; note 13: พรหม -> Phrom, "ห is silent"). ห + ว is pronunciation-dependent (note 4: หวอ -> wo but หวย -> huai) and stays in the lexicon layer. + + Carrier-interleaved compound vowels (เ-C-า khao) are encoded through the digraph rows above; adjacent-sign compounds (ก-ล-ั-ว klua, ม-ื-อ mue, เ-า ao) are encoded as adjacent-sign rows." + } +} + +tests { + "ภาษาไทย" -> "phasathai" + "ไทย" -> "thai" + "ใหม่" -> "mai" + "ที่" -> "thi" + "เป็น" -> "pen" + "ใน" -> "nai" + "การ" -> "kan" + "มี" -> "mi" + "๑๒๓" -> "123" + "เขา" -> "khao" + "กลัว" -> "klua" + "มือ" -> "mue" +} + + +dependency "thai-latn" as thailatn + +stage main { + + # MARKS (tone marks are not romanized; the vowel shortening mark ็ + # has no RTGS effect; the silencing mark ์ removes the consonant it + # follows) + parallel { + sub "่" "" + sub "้" "" + sub "๊" "" + sub "๋" "" + sub "็" "" + sub "ก์" "" + sub "ข์" "" + sub "ค์" "" + sub "ง์" "" + sub "จ์" "" + sub "ช์" "" + sub "ญ์" "" + sub "ด์" "" + sub "ต์" "" + sub "ถ์" "" + sub "ท์" "" + sub "น์" "" + sub "บ์" "" + sub "ป์" "" + sub "ผ์" "" + sub "ฝ์" "" + sub "ฟ์" "" + sub "ม์" "" + sub "ย์" "" + sub "ร์" "" + sub "ล์" "" + sub "ว์" "" + sub "ส์" "" + sub "ห์" "" + sub "อ์" "" + } + + # SILENT ห AS TONE MARK (ห นำ). Note 4: "ห at the beginning of a + # syllable and serving as a tone mark should not be romanized" + # (หวอ → wo, หลูบ → luep), with note 13's พรหม → Phrom ("ห is + # silent"). ห directly preceding a low-class consonant is always the + # tone-mark class, and ห is never syllable-final, so this is + # orthographically deterministic for ง ญ ณ น ม ย ร ล. ห + ว is + # pronunciation-dependent (note 4: หวอ → wo but หวย → huai) and is + # left to the pronunciation-lexicon layer. + parallel { + sub { from "ห" to "" after any("งญณนมยรล") } + } + + # LEADING SILENT เ (the e-glyph prefixes a carrier consonant in the + # compound rows: เ-ป-ี-ย pia, เ-ก-อ-ย koeai...). Thai-glyph context, + # so this runs before the consonant pass. Carrier-interleaved + # compounds (เ-C-า class) need capture support (WO80). + parallel { + sub { from "เ" to "" before any("ก".."ฮ") + "ีย" } + sub { from "เ" to "" before any("ก".."ฮ") + "ือ" } + sub { from "เ" to "" before any("ก".."ฮ") + "อย" } + } + + # LEADING VOWEL GLYPHS, PHONETIC REORDERING. The vowel table writes + # the leading vowels as เ◌ (row 6), แ◌ (row 7), โ◌ (row 8), ใ◌ ไ◌ + # (row 11), โ◌ย (row 13) and เ◌า (row 19): the glyph precedes the + # consonant in Thai script while the romanization places the vowel + # after the consonant (ไท → thai). Note 1: "Consonant and vowel + # characters written in misleading order should be romanized as + # pronounced" (แขนง → khanaeng, เขื่อยา → khayao). One enumerated + # digraph row per consonant, as in the corpus's ALA-LC Thai 2011 + # encoding; rows sit before the consonant and vowel passes. + use thailatn.leading_vowel_digraphs override { + sub "ไซย" "sai" + sub "ไหย" "hai" + sub "โซย" "soi" + sub "โหย" "hoi" + sub "เซา" "sao" + sub "เหา" "hao" + sub "ไย" "yai" + sub "ไซ" "sai" + sub "ไห" "hai" + sub "ใซ" "sai" + sub "ให" "hai" + sub "โซ" "so" + sub "โห" "ho" + sub "เซ" "se" + sub "เห" "he" + sub "แซ" "sae" + sub "แห" "hae" + } + + # COMPOUND VOWEL SIGNS (adjacent-sign forms; source rows 10-19) + parallel { + sub "ีย" "ia" + sub "ึย" "ui" + sub "อย" "oi" + sub "ไย" "ai" + sub "าย" "ai" + sub "ัวะ" "ua" + sub "ัว" "ua" + sub "ือะ" "ue" + sub "ือ" "ue" + sub "เา" "ao" + } + + # CONSONANTS — final form at word end + # (source table, rows 1-21: the second romanization column) + parallel { + sub { from "ข" to "k" after boundary } + sub { from "ฆ" to "k" after boundary } + sub { from "ค" to "k" after boundary } + sub { from "ฅ" to "k" after boundary } + sub { from "ฃ" to "k" after boundary } + sub { from "จ" to "t" after boundary } + sub { from "ฉ" to "t" after boundary } + sub { from "ช" to "t" after boundary } + sub { from "ฌ" to "t" after boundary } + sub { from "ญ" to "n" after boundary } + sub { from "ฎ" to "t" after boundary } + sub { from "ฑ" to "t" after boundary } + sub { from "ด" to "t" after boundary } + sub { from "ฐ" to "t" after boundary } + sub { from "ฒ" to "t" after boundary } + sub { from "ถ" to "t" after boundary } + sub { from "ท" to "t" after boundary } + sub { from "ธ" to "t" after boundary } + sub { from "บ" to "p" after boundary } + sub { from "ผ" to "p" after boundary } + sub { from "พ" to "p" after boundary } + sub { from "ภ" to "p" after boundary } + sub { from "ฝ" to "p" after boundary } + sub { from "ฟ" to "p" after boundary } + sub { from "ซ" to "t" after boundary } + sub { from "ศ" to "t" after boundary } + sub { from "ษ" to "t" after boundary } + sub { from "ส" to "t" after boundary } + sub { from "ร" to "n" after boundary } + } + sub "k" "K" when kur + + # CONSONANTS — initial defaults (source table, rows 1-21, first + # romanization column); the standalone carrier อ is silent and + # vanishes + parallel { + sub "ก" "k" + sub "ข" "kh" + sub "ฆ" "kh" + sub "ค" "kh" + sub "ฅ" "kh" + sub "ฃ" "kh" + sub "ง" "ng" + sub "จ" "ch" + sub "ฉ" "ch" + sub "ช" "ch" + sub "ฌ" "ch" + sub "ญ" "y" + sub "ฎ" "d" + sub "ฏ" "t" + sub "ฑ" "th" + sub "ฒ" "th" + sub "ด" "d" + sub "ต" "t" + sub "ฐ" "th" + sub "ถ" "th" + sub "ท" "th" + sub "ธ" "th" + sub "ณ" "n" + sub "น" "n" + sub "บ" "b" + sub "ป" "p" + sub "ผ" "ph" + sub "พ" "ph" + sub "ภ" "ph" + sub "ฝ" "f" + sub "ฟ" "f" + sub "ม" "m" + sub "ย" "y" + sub "ร" "r" + sub "ล" "l" + sub "ฬ" "l" + sub "ว" "w" + sub "ซ" "s" + sub "ศ" "s" + sub "ษ" "s" + sub "ส" "s" + sub "ห" "h" + sub "ฮ" "h" + sub "อ" "" + } + + # SIMPLE VOWELS (source vowel table, rows 1-9 and 11: single signs; + # length is not distinguished) + parallel { + sub "ะ" "a" + sub "ั" "a" + sub "า" "a" + sub "ๅ" "a" + sub "ิ" "i" + sub "ี" "i" + sub "ึ" "ue" + sub "ื" "ue" + sub "ุ" "u" + sub "ู" "u" + sub "เ" "e" + sub "แ" "ae" + sub "โ" "o" + sub "ใ" "ai" + sub "ไ" "ai" + sub "็" "" + } + + # NUMERALS + parallel { + sub "๐" "0" + sub "๑" "1" + sub "๒" "2" + sub "๓" "3" + sub "๔" "4" + sub "๕" "5" + sub "๖" "6" + sub "๗" "7" + sub "๘" "8" + sub "๙" "9" + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0179/map.isc b/scripts/fuzz/smoke-cases/mutation-0179/map.isc new file mode 100644 index 0000000..07f90c7 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0179/map.isc @@ -0,0 +1,182 @@ +system "VAR:mon-Mong:Latn:lessing" { + +metadata { + authority_id var + id lessing + language iso-639-2:mon + source_script Mong + destination_script Latn + name Lessing transliteration system for Uyghur-Mongolian script + url https://collab.its.virginia.edu/wiki/tibetan-script/Transliteration%20Schemes%20for%20Mongolian%20Vertical%20Script.html + sub a "\u{00A0}" after "\u{00A0}" + creation_date + description { The only system for the Mongolian vertical script which is used commonly throughout + Mongolian studies worldwide is the Vladimirtsov-Mostaert system (V-M). The only + dictionary using this system is in an appendix to Antoine Mostaert’s Dictionnaire + ordos. Thus the Harvard Journal of Asiatic Studies specifies, “please use the written + Mongolian appendix to Antoine Mostaert’s Dictionnaire ordos. However, the V-M system + has many difficult diacriticals and non-Latin characters that constitute a significant + problem for editors and thus is difficult to recommend. + } + + notes { + note "A separated final form of vowels a or e is common, and can appear at the end\n of a word, word stem, or suffix. This form requires a final-shaped preceding\n consonant and an inter-word gap in between. The vowels themselves appear as ᠎ᠠ,\n and with consonants as ‍ᠬ᠎ᠠ q‑a, ‍ᠷ᠎ᠠ r‑a/r‑e, etc. This gap can be transliterated\n with a hyphen. In digital typesetting, these forms are triggered by inserting\n a U+180E ᠎ MONGOLIAN VOWEL SEPARATOR (HTML ᠎ · MVS) between the consonant\n and vowel." + note "All case suffixes, as well as any plural suffixes consisting of one or two\n syllables are likewise separated by a preceding and hyphen-transliterated gap.\n In digital typesetting, this gap is represented by a U+202F   NARROW NO-BREAK SPACE\n (HTML   · NNBSP). A maximum of two case suffixes can be added to a stem.\n Single-letter vowel suffixes appear with the final-shaped forms of a/e, i, or u/ü,\n as in ᠭᠠᠵᠠᠷ ᠠ γaǰar‑a 'to the country' and ᠡᠳᠦᠷ ᠡ edür‑e 'on the day', or ᠤᠯᠤᠰ ᠢ ulus‑i\n 'the state' etc. Multi-letter suffixes most often start with an initial- (consonants),\n medial- (vowels), or variant-shaped form." + } +} + +tests { + "ᠬᠥᠬᠡᠬᠣᠲᠠ" -> "køkexota" # Хөх хот + "ᠣᠷᠳᠣᠰ ᠬᠣᠲᠠ" -> "ordos xota" # Ордос хот + "ᠪᠠᠶᠠᠨᠨᠠᠭᠤᠷ ᠬᠣᠲᠠ" -> "bajannaγur xota" # Баяннуур хот + sub k "\u{10FFFF}" after "\u{10FFFF}" + "ᠤᠯᠠᠭᠠᠨᠬᠣᠲᠠ" -> "ulaγanxota" # Улаан хот + "ᠬᠣᠣᠯᠢᠠ ᠭᠣᠤᠯ ᠬᠣᠲᠠ" -> "xoolia γoul xota" # Хоолингол хот + "ᠡᠷᠢᠶᠡᠨ ᠬᠣᠲᠠ" -> "erijen xota" # Эрээн хот + "ᠷᠠᠰᠢᠶᠠᠨ ᠬᠣᠲᠠ" -> "rasijan xota" # Рашаан хот + "ᠪᠠᠭᠠᠷᠢᠨ ᠪᠠᠷᠠᠭᠤᠨ ᠬᠣᠰᠢᠭᠤ" -> "baγarin baraγun xosiγu" # Баарин баруун хошуу + "ᠪᠠᠭᠠᠷᠢᠨ ᠵᠡᠭᠦᠨ ᠬᠣᠰᠢᠭᠤ" -> "baγarin zegyn xosiγu" # Баарин зүүн хошуу + "ᠲᠦᠩᠯᠢᠶᠣᠤ ᠬᠣᠲᠠ" -> "tynglijou xota" # Байшинт хот + "ᠰᠢᠯᠢ ᠶᠢᠨ ᠬᠣᠲᠠ" -> "sili-jin xota" # Шилийн хот + "ᠬᠣᠷᠢᠨ ᠭᠡᠷ ᠰᠢᠶᠠᠨ" -> "xorin ger sijan" # Horinger County + "ᠤᠳᠠ ᠲᠣᠭᠣᠷᠢᠭ" -> "uda toγoriγ" # Уда тойрог + "ᠦᠬᠠᠢ ᠬᠣᠲᠠ" -> "yxai xota" # Үхай хот + "ᠬᠠᠶᠢᠨᠠᠨ ᠲᠣᠭᠣᠷᠢᠭ" -> "xainan toγoriγ" # Hainan District + "ᠬᠠᠶᠢᠷᠤᠪ ᠤᠨ ᠲᠣᠬᠣᠢ ᠲᠣᠭᠣᠷᠢᠭ" -> "xairub-un toxoi toγoriγ" # Haibowan District + "ᠤᠯᠠᠭᠠᠨᠴᠠᠪ ᠬᠣᠲᠠ" -> "ulaγancab xota" # Улаанцав хот + "ᠵᠢᠨᠢᠩ ᠲᠣᠭᠣᠷᠢᠭ" -> "zining toγoriγ" # Жинин тойрог + "ᠹᠸᠩᠵᠸᠡ ᠬᠣᠲᠠ" -> "fvngzve xota" # Фенжень хот + "ᠱᠠᠩᠳᠤ ᠰᠢᠶᠠᠨ" -> "šangdu sijan" # Шанду шянь + "ᠯᠢᠶᠠᠩᠴᠠᠩ ᠰᠢᠶᠠᠨ" -> "lijangcang sijan" # Liangcheng County + "ᠴᠠᠬᠠᠷ ᠪᠠᠷᠠᠭᠤᠨ ᠭᠠᠷᠤᠨ ᠡᠮᠦᠨᠡᠳᠦ ᠬᠣᠰᠢᠭᠤ" -> "caxar baraγun γarun emynedy xosiγu" # Цахар баруун гарын өмнөд хошуу + "ᠴᠠᠬᠠᠷ ᠪᠠᠷᠠᠭᠤᠨ ᠭᠠᠷᠤᠨ ᠳᠤᠮᠳᠠᠳᠤ ᠬᠣᠰᠢᠭᠤ" -> "caxar baraγun γarun dumdadu xosiγu" # Цахар баруун гарын дундад хошуу + "ᠴᠠᠬᠠᠷ ᠪᠠᠷᠠᠭᠤᠨ ᠭᠠᠷᠤᠨ ᠬᠣᠶᠢᠲᠤ ᠬᠣᠰᠢᠭᠤ" -> "caxar baraγun γarun xoitu xosiγu" # Цахар баруун гарын хойд хошуу + "ᠳᠥᠷᠪᠡᠳ ᠬᠣᠰᠢᠭᠤ" -> "dørbed xosiγu" # Дөрвөд хошуу + "ᠪᠤᠭᠤᠲᠤ ᠬᠣᠲᠠ" -> "buγutu xota" # Бугaт хот + "ᠬᠥᠨᠳᠡᠯᠡᠨ ᠲᠣᠭᠣᠷᠢᠭ" -> "køndelen toγoriγ" # Hondlon District + "ᠴᠢᠩᠱᠠᠨ ᠲᠣᠭᠣᠷᠢᠭ" -> "cingšan toγoriγ" # Qingshan District + "ᠰᠢᠭᠤᠶᠢᠲᠤ ᠲᠣᠭᠣᠷᠢᠭ" -> "siγuitu toγoriγ" # Шигуай тойрог + "ᠵᠢᠦ ᠶᠤᠸᠠᠨ ᠲᠣᠭᠣᠷᠢᠭ" -> "ziy juvan toγoriγ" # Jiuyuan District + "ᠭᠦᠶᠠᠩ ᠰᠢᠶᠠᠨ" -> "gyjang sijan" # Guyang County + "ᠲᠦᠮᠡᠳ ᠵᠡᠭᠦᠨ ᠬᠣᠰᠢᠭᠤ" -> "tymed zegyn xosiγu" # Түмэд Зүүн хошуу + "ᠲᠦᠮᠡᠳ ᠪᠠᠷᠠᠭᠤᠨ ᠬᠣᠰᠢᠭᠤ" -> "tymed baraγun xosiγu" # Түмэд Баруун хошуу + "ᠳᠠᠷᠬᠠᠨ ᠮᠤᠤᠮᠢᠩᠭ᠋ᠠᠨ ᠬᠣᠯᠪᠣᠭᠠᠲᠤ ᠬᠣᠰᠢᠭᠤ" -> "darxan muumingγ᠋an xolboγatu xosiγu" # Darhan Muminggan United Banner + "ᠬᠡᠰᠢᠭᠲᠡᠨ ᠬᠣᠰᠢᠭᠤ" -> "kesiγten xosiγu" # Hexigten Banner + "ᠰᠢᠨ᠎ᠡ ᠪᠠᠷᠭᠤ ᠵᠡᠭᠦᠨ ᠬᠣᠰᠢᠭᠤ" -> "sin-e barγu zegyn xosiγu" # New Barag Left Banner + "ᠰᠢᠨ᠎ᠡ ᠪᠠᠷᠭᠤ ᠪᠠᠷᠠᠭᠤᠨ ᠬᠣᠰᠢᠭᠤ" -> "sin-e barγu baraγun xosiγu" # New Barag Right Banner + "ᠣᠲᠣᠭ ᠬᠣᠰᠢᠭᠤ" -> "otoγ xosiγu" # Otog Banner + "ᠳᠠᠯᠠᠳ ᠬᠣᠰᠢᠭᠤ" -> "dalad xosiγu" # Dalad Banner + "ᠵᠡᠭᠦᠨᠭᠠᠷ ᠬᠣᠰᠢᠭᠤ" -> "zegynγar xosiγu" # Jungar Banner + "ᠣᠲᠣᠭ ᠤᠨ ᠡᠮᠦᠨᠡᠳᠦ ᠬᠣᠰᠢᠭᠤ" -> "otoγ-un emynedy xosiγu" # Otog Front Banner + "ᠬᠠᠩᠭᠢᠨ ᠬᠣᠰᠢᠭᠤ" -> "xanggin xosiγu" # Hanggin Banner + "ᠦᠦᠰᠢᠨ ᠬᠣᠰᠢᠭᠤ" -> "yysin xosiγu" # Uxin Banner + "ᠡᠵᠢᠨ ᠬᠣᠷᠣᠭ᠎ᠠ ᠬᠣᠰᠢᠭᠤ" -> "ezin xoroγ-a xosiγu" # Эзэн Хороо хошуу + "ᠵᠠᠯᠠᠨ ᠠᠢ᠌ᠯ ᠬᠣᠲᠠ" -> "zalan ai᠌l xota" # Жалан-Айл хот + "ᠶᠠᠭᠰᠢ ᠬᠣᠲᠠ" -> "jaγsi xota" # Ягши хот + "ᠮᠠᠨᠵᠤᠤᠷ ᠬᠣᠲᠠ" -> "manzuur xota" # Манжуур хот + "ᠬᠠᠶᠢᠯᠠᠷ ᠲᠣᠭᠣᠷᠢᠭ" -> "xailar toγoriγ" # Хайлаар тойрог + "ᠬᠣᠷᠴᠢᠨ ᠲᠣᠭᠣᠷᠢᠭ" -> "xorcin toγoriγ" # Horqin District + "ᠺᠠᠶᠢᠯᠦ ᠰᠢᠶᠠᠨ" -> "kaily sijan" # Kailu County + "ᠬᠦᠷᠢᠶ᠎ᠡ ᠬᠣᠰᠢᠭᠤ" -> "kyrij-e xosiγu" # Hure Banner + "ᠨᠠᠢᠮᠠᠨ ᠬᠣᠰᠢᠭᠤ" -> "naiman xosiγu" # Naiman Banner + "ᠵᠠᠷᠤᠳ ᠬᠣᠰᠢᠭᠤ" -> "zarud xosiγu" # Jarud Banner + "ᠬᠣᠷᠴᠢᠨ ᠪᠠᠷᠠᠭᠤᠨ ᠭᠠᠷᠤᠨ ᠳᠤᠮᠳᠠᠳᠤ ᠬᠣᠰᠢᠭᠤ" -> "xorcin baraγun γarun dumdadu xosiγu" # Хорчин Баруун Гарын Дундад Хошуу + "ᠬᠣᠷᠴᠢᠨ ᠵᠡᠭᠦᠨ ᠭᠠᠷᠤᠨ ᠳᠤᠮᠳᠠᠳᠤ ᠬᠣᠰᠢᠭᠤ" -> "xorcin zegyn γarun dumdadu xosiγu" # Horqin Left Middle Banner + "ᠬᠣᠷᠴᠢᠨ ᠵᠡᠭᠦᠨ ᠭᠠᠷᠤᠨ ᠬᠣᠶᠢᠲᠤ ᠬᠣᠰᠢᠭᠤ" -> "xorcin zegyn γarun xoitu xosiγu" # Horqin Left Rear Banner + "ᠤᠯᠠᠭᠠᠨᠬᠠᠳᠠ ᠬᠣᠲᠠ" -> "ulaγanxada xota" # Улаанхад хот + "ᠰᠡᠷᠡᠴᠢ" -> "sereci" # Salaqi + "ᠭᠡᠭᠡᠨ ᠭᠣᠤᠯ ᠬᠣᠲᠠ" -> "gegen γoul xota" # Гэгээнгол хот + "ᠠᠯᠠᠱᠠ ᠵᠡᠭᠦᠨ ᠬᠣᠰᠢᠭᠤ" -> "alaša zegyn xosiγu" # Alxa Left Banner + "ᠠᠯᠠᠱᠠ ᠪᠠᠷᠠᠭᠤᠨ ᠬᠣᠰᠢᠭᠤ" -> "alaša baraγun xosiγu" # Alxa Right Banner # Alaša Baraγun xosiγu + "ᠡᠵᠡᠨ᠎ᠡ ᠬᠣᠰᠢᠭᠤ" -> "ezen-e xosiγu" # Ejin Banner + "ᠬᠥᠪᠡᠭᠡᠲᠦ ᠰᠢᠷ᠎ᠠ ᠬᠣᠰᠢᠭᠤ" -> "købegety sir-a xosiγu" # Хөвөөт Шар хошуу + "ᠦᠶᠤᠸᠠᠨ ᠰᠢᠶᠠᠨ" -> "yjuvan sijan" # Үюань шянь + "ᠦᠴᠤᠸᠠᠨ ᠰᠢᠶᠠᠨ" -> "ycuvan sijan" # Wuchuan County + "ᠲᠦᠴᠢᠤᠸᠠᠨ ᠰᠢᠶᠠᠨ" -> "tyciuvan sijan" # Тучуань шянь + "ᠯᠢᠨᠰᠢ ᠰᠢᠶᠠᠨ" -> "linsi sijan" # Linxi County + "ᠬᠠᠷᠠᠴᠢᠨ ᠬᠣᠰᠢᠭᠤ" -> "xaracin xosiγu" # Harqin Banner + "ᠠᠤᠬᠠᠨ ᠬᠣᠰᠢᠭᠤ" -> "auxan xosiγu" # Aohan Banner + "ᠬᠣᠳᠣᠩ ᠠᠷᠠᠳ ᠤᠨ ᠲᠣᠭᠣᠷᠢᠭ" -> "xodong arad-un toγoriγ" # Huimin District + "ᠰᠠᠶᠢᠬᠠᠨ ᠲᠣᠭᠣᠷᠢᠭ" -> "saixan toγoriγ" # Saihan District + "ᠰᠢᠨ᠎ᠡ ᠬᠣᠲᠠ ᠲᠣᠭᠣᠷᠢᠭ" -> "sin-e xota toγoriγ" # Xincheng District + "ᠬᠠᠶᠢᠷᠤᠪ ᠤᠨ ᠲᠣᠬᠣᠢ ᠲᠣᠭᠣᠷᠢᠭ" -> "xairub-un toxoi toγoriγ" # Haibowan (Hairibin Tohoi) District + "ᠰᠦᠩ ᠱᠠᠨ ᠲᠣᠭᠣᠷᠢᠭ" -> "syng šan toγoriγ" # Songshan District + "ᠬᠦᠩ ᠱᠠᠨ ᠲᠣᠭᠣᠷᠢᠭ" -> "kyng šan toγoriγ" # Hongshan District + "ᠠᠷᠤᠨ ᠬᠣᠰᠢᠭᠤ" -> "arun xosiγu" # Арун хошуу + "ᠶᠤᠸᠠᠨ ᠪᠣᠣ ᠱᠠᠨ ᠲᠣᠭᠣᠷᠢᠭ" -> "juvan boo šan toγoriγ" # Юаньбаошань тойрог + "ᠰᠢᠯᠤᠭᠤᠨ ᠬᠥᠪᠡᠭᠡᠲᠦ ᠴᠠᠭᠠᠨ ᠬᠣᠰᠢᠭᠤ" -> "siluγun købegety caγan xosiγu" # Шулуун Хөвөөт Цагаан хошуу + "ᠰᠢᠯᠤᠭᠤᠨ ᠬᠥᠬᠡ ᠬᠣᠰᠢᠭᠤ" -> "siluγun køke xosiγu" # Шулуун хөх хошуу + "ᠤᠷᠠᠳ ᠤᠨ ᠳᠤᠮᠳᠠᠳᠤ ᠬᠣᠰᠢᠭᠤ" -> "urad-un dumdadu xosiγu" # Урадын Дундад Хошуу + "ᠤᠷᠠᠳ ᠤᠨ ᠡᠮᠦᠨᠡᠳᠦ ᠬᠣᠰᠢᠭᠤ" -> "urad-un emynedy xosiγu" # Урадын Өмнөд Хошуу + "ᠲᠣᠭᠲᠠᠬᠤ ᠰᠢᠶᠠᠨ" -> "toγtaxu sijan" # Тогтох шянь + "ᠰᠥᠨᠡᠳ ᠵᠡᠭᠦᠨ ᠬᠣᠰᠢᠭᠤ" -> "søned zegyn xosiγu" # Sonid Left Banner + "ᠰᠥᠨᠡᠳ ᠪᠠᠷᠠᠭᠤᠨ ᠬᠣᠰᠢᠭᠤ" -> "søned baraγun xosiγu" # Sonid Right Banner + "ᠣᠩᠨᠢᠭᠤᠳ ᠬᠣᠰᠢᠭᠤ" -> "ongniγud xosiγu" # Ongniud Banner + "ᠵᠠᠯᠠᠢᠳ ᠬᠣᠰᠢᠭᠤ" -> "zalaid xosiγu" # Jalaid Banner + "ᠬᠠᠩᠭᠢᠨ ᠬᠣᠶᠢᠲᠤ ᠬᠣᠰᠢᠭᠤ" -> "xanggin xoitu xosiγu" # Hanggin Rear Banner + "ᠵᠡᠭᠦᠨ ᠤᠵᠤᠮᠤᠴᠢᠨ ᠬᠣᠰᠢᠭᠤ" -> "zegyn uzumucin xosiγu" # East Ujimqin Banner + "ᠠᠷᠤ ᠬᠣᠷᠴᠢᠨ ᠬᠣᠰᠢᠭᠤ" -> "aru xorcin xosiγu" # Ar Horqin Banner + "ᠠᠪᠠᠭ᠎ᠠ ᠬᠣᠰᠢᠭᠤ" -> "abaγ-a xosiγu" # Abag Banner + "ᠪᠤᠷᠢᠶᠠᠳ" -> "burijad" # Буриад + "ᠤᠯᠠᠭᠠᠨᠪᠠᠭᠠᠲᠤᠷ" -> "ulaγanbaγatur" # Улаанбаатар + "ᠴᠢᠩᠭᠢᠰ ᠬᠠᠭᠠᠨ" -> "cinggis xaγan" # Чингис Хаан +} + +stage main { + + # RULES + sub { + from "\u182c" + to "k" + after any("\u1821\u1822\u1825\u1826") + } + sub { + from "\u182d" + to "g" + after any("\u1821\u1822\u1825\u1826") + } + sub "\u1820\u1836\u1822" "ai" + sub "\u1821\u1836\u1822" "ei" + sub "\u1823\u1836\u1822" "oi" + sub "\u1824\u1836\u1822" "ui" + + + # CHARACTERS + parallel { + sub "ᠠ" "a" + sub "ᠡ" "e" + sub "ᠢ" "i" + sub "ᠣ" "o" + sub "ᠤ" "u" + sub "ᠥ" "ø" + sub "ᠦ" "y" + sub "ᠨ" "n" + sub "ᠩ" "ng" + sub "ᠬ" "x" + sub "ᠭ" "γ" + sub "ᠪ" "b" + sub "ᠫ" "p" + sub "ᠹ" "f" + sub "ᠰ" "s" + sub "ᠱ" "š" + sub "ᠲ" "t" + sub "ᠳ" "d" + sub "ᠯ" "l" + sub "ᠮ" "m" + sub "ᠴ" "c" + sub "ᠵ" "z" + sub "ᠶ" "j" + sub "ᠺ" "k" + sub "ᠷ" "r" + sub "ᠸ" "v" + sub "ᠾ" "h" + sub "᠁" '...' + sub "᠂" "," + sub "᠃" '.' + sub "᠄" ":" + sub "᠎" "-" + sub " " "-" + } + +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0180/map.isc b/scripts/fuzz/smoke-cases/mutation-0180/map.isc new file mode 100644 index 0000000..10dc303 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0180/map.isc @@ -0,0 +1,74 @@ +system "DIN:inh-Cyrl:Latn:1460-2-2011" { + +metadata { + authority_id din + id 1460-2-2011-18 + language iso-639-3:inh + source_script Cyrl + destination_script Latn + name "DIN 1460-2:2011-10, Tabelle 1 row 18: Inguschisch (Caucasus)" + url https://www.beuth.de/de/norm/din-1460-2/134564104 + creation_date 2011 + adoption_date + description { + DIN 1460-2:2011-10, Romanization of Cyrillic alphabets of + non-Slavic languages, Tabelle 1, language row 18 + (Inguschisch). The table assigns each Cyrillic letter of the + language's alphabet a Latin letter or letter group; the column + order follows DIN 1460:1982 (Slavic). Extracted mechanically from + the standard's text layer; the mapping rows below are the table's + own cells. + sub "в" "v" + + notes { + note "Extraction provenance: the PDF's text layer carries the full + grid; columns were anchored on the per-page position-number row and + each cell matched by x-coordinate to its Cyrillic header letter. + Position 13's header glyph is PUA (U+E519) in the text layer and + was visually identified at 10x as h with comma below (U+0068 + U+0322), the plain-h counterpart of position 12's hooktop-h symbol." + } +} + +tests { + "a" -> "a" + "б" -> "b" + "в" -> "v" + "г" -> "g" +} + +stage main { + parallel { + sub "a" "a" + sub "б" "b" + } + sub "г" "g" + sub "д" "d" + sub "е" "e" + sub "ё" "ё" + sub "ж" "ž" + sub "з" "z" + sub "и" "i" + sub "й" "j" + sub "к" "k" + sub "л" "l" + sub "м" "m" + sub "н" "n" + sub "о" "o" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "т" "t" + sub "у" "u" + sub "ф" "f" + sub "х" "h" + sub "ц" "c" + sub "ч" "č" + sub "ш" "š" + sub "щ" "śč" + sub "ъ" "q" + sub "ы" "y" + sub "ь" "ĭ" + sub "э" "ė" + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0181/map.isc b/scripts/fuzz/smoke-cases/mutation-0181/map.isc new file mode 100644 index 0000000..36f2458 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0181/map.isc @@ -0,0 +1,129 @@ +system "ALA-LC:bel-Cyrl:Latn:1997" { + +metadata { + authority_id dup_id + authority_id dup_id + authority_id alalc + id 1997 + language iso-639-2:bel + source_script Cyrl + destination_script Latn + name Romanization Table -- Byelorussian (1997) + url http://catdir.loc.gov/catdir/cpso/romanization/beloruss.pdf + creation_date 1997 + + notes { + note "Ґ letter found in Old Belarusian and in modern publications in Tarashkevitsa orthography." + note "Do not confuse with the digraph кг (also romanized as “kh”). Manual review may be needed when transcribing data in vernacular characters in order to distinguish х from кг." + note "The apostrophe (´) is not transliterated." + note "Soft sign (prime) is USMARC hexadecimal code A7 ~ U+02B9 Unicode character" + } +} + +tests { + # https://en.wikipedia.org/wiki/Romanization_of_Belarusian#Examples + # https://img.tyt.by/n/02/d/belorusskiy_translit.jpg - with issues + "Беларусь" -> "Belarusʹ" + "Магілёў" -> "Mahili͡oŭ" + "Лукашэнка" -> "Lukashėnka" + "сям´я" -> "si͡ami͡a" + "Уручча" -> "Uruchcha" + "Барысаўскі тракт" -> "Barysaŭski trakt" + "Усход" -> "Uskhod" + "Маскоўская" -> "Maskoŭskai͡a" + "Парк Чалюскінцаў" -> "Park Chali͡uskintsaŭ" + "Акадэмія навук" -> "Akadėmii͡a navuk" + "Плошча Якуба Коласа" -> "Ploshcha I͡Akuba Kolasa" + "Плошча Перамогі" -> "Ploshcha Peramohi" + "Кастрычніцкая" -> "Kastrychnitskai͡a" + "Плошча Леніна" -> "Ploshcha Lenina" + "Інстытут Культуры" -> "Instytut Kulʹtury" + # WO19 G6: the map's capital-\U row is spelled with a DOUBLED + # backslash ("\\U040E"), i.e. a literal backslash + the raw text + # U040E — not the \U040E escape — so it does NOT fire on Ў. Pin + # that dormancy (ruby and rs agree Ў passes through unchanged). + "Ў" -> "Ў" +} + +stage main { + + # CHARACTERS + parallel { + # Apostrophes + sub "\u00B4" "" + sub "\u02BC" "" + sub "\u0027" "" + + # Characters + sub "\u0410" "A" + sub "\u0411" "B" + sub "\u0412" "V" + sub "\u0413" "H" + sub "\u0490" "G" + sub "\u0414" "D" + sub "\u0415" "E" + sub "\u0401" "I͡O" + sub "\u0416" "Z͡H" + sub "\u0417" "Z" + sub "\u0406" "I" + sub "\u0419" "Ĭ" + sub "\u041A" "K" + sub "\u041B" "L" + sub "\u041C" "M" + sub "\u041D" "N" + sub "\u041E" "O" + sub "\u041F" "P" + sub "\u0420" "R" + sub "\u0421" "S" + sub "\u0422" "T" + sub "\u0423" "U" + sub "\\U040E" "Ŭ" + sub "\u0424" "F" + sub "\u0425" "Kh" + sub "\u0426" "Ts" + sub "\u0427" "Ch" + sub "\u0428" "Sh" + sub "\u042B" "Y" + sub "\u042C" "ʹ" + sub "\u042D" "Ė" + sub "\u042E" "I͡U" + sub "\u042F" "I͡A" + + sub "\u0430" "a" + sub "\u0431" "b" + sub "\u0432" "v" + sub "\u0433" "h" + sub "\u0491" "g" + sub "\u0434" "d" + sub "\u0435" "e" + sub "\u0451" "i͡o" + sub "\u0436" "z͡h" + sub "\u0437" "z" + sub "\u0456" "i" + sub "\u0439" "ĭ" + sub "\u043A" "k" + sub "\u043B" "l" + sub "\u043C" "m" + sub "\u043D" "n" + sub "\u043E" "o" + sub "\u043F" "p" + sub "\u0440" "r" + sub "\u0441" "s" + sub "\u0442" "t" + sub "\u0443" "u" + sub "\u045E" "ŭ" + sub "\u0444" "f" + sub "\u0445" "kh" + sub "\u0446" "ts" + sub "\u0447" "ch" + sub "\u0448" "sh" + sub "\u044B" "y" + sub "\u044C" "ʹ" + sub "\u044D" "ė" + sub "\u044E" "i͡u" + sub "\u044F" "i͡a" + } + +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0182/map.isc b/scripts/fuzz/smoke-cases/mutation-0182/map.isc new file mode 100644 index 0000000..b283742 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0182/map.isc @@ -0,0 +1,30 @@ +system "BGNA:bul-Cyrl:Latn:2006" { + +metadata { + authority_id bgna + id 2006 + language iso-639-2:bul + source_script Cyrl + destination_script Latn + name Republic of Bulgaria system for transliteration of Bulgarian geographical names with Roman letters + creation_date 2006 + adoption_date 2006-10-26 +} + +tests { + "нунатак Абрит" -> "nunatak Abrit" + "връх Академия" -> "vrah Akademiya" + "връх Ами Буе" -> "vrah Ami Bue" + "нос Айтос" -> "nos Aytos" + "залив Баба Тонка" -> "zaliv Baba Tonka" + "Балабански камък" -> "Balabanski kamak" + "Бедечки поток" -> "Bedechki potok" + "нос Бяга" -> "nos Byaga" + "остров Качо" -> "ostrov Kacho" # wiki ostrov Cacho + "Чакъров остров" -> "Chakarov ostrov" + "връх Дъбник" -> "vrah Dabnik" + "залив Десислава" -> "zaliv Desislava" + "ледник Джераси" -> "lednik Dzherasi" + "Джегова скала" -> "Dzhegova skala" + "Нунатак Едуард" -> "Nunatak Eduard" + "Елховска с \ No newline at end of file diff --git a/scripts/fuzz/smoke-cases/mutation-0183/map.isc b/scripts/fuzz/smoke-cases/mutation-0183/map.isc new file mode 100644 index 0000000..f3948f3 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0183/map.isc @@ -0,0 +1,47 @@ +system "ISO:ell-Grek:Latn:843-1997-t2" { + +metadata { + authority_id iso + id 885 + language iso-639-2:ell + source_script Grek + destination_script Latn + name "ISO 843:1997 Information and documentation -- Conversion of Greek characters into Latin characters (Table 2)" + url https://www.iso.org/standard/5215.html + creation_date 1997 + description { Establishes a system for the transliteration and/or transcription + of Greek characters into Latin characters. This system applies to + the characters of the Greek script, independent of the period in + which it is or was used, i.e. scripts from all periods of Classic + or Modern Greek. Replaces ISO/R 843. + } + + notes { + note "Transliteration of Greek into Latin: Type 2, Clause 3 Table 2" + note "Introduced casing to digamma, yot, and lunate sigma. (Casing was late introduction to character sets for those characters)" + } +} + +tests { + "Ένα πράμα μόνον με παρακίνησε κι εμένα να γράψω ότι τούτην την πατρίδα την έχομεν όλοι μαζί, και σοφοί κι αμαθείς και πλούσιοι και φτωχοί και πολιτικοί και στρατιωτικοί και οι πλέον μικρότεροι άνθρωποι· όσοι αγωνιστήκαμεν, αναλόγως ο καθείς, έχομεν να ζήσομεν εδώ. Το λοιπόν δουλέψαμεν όλοι μαζί, να την φυλάμεν κι όλοι μαζί και να μην λέγει ούτε ο δυνατός «εγώ» ούτε ο αδύνατος. Ξέρετε πότε να λέγει ο καθείς «εγώ»; Όταν αγωνιστεί μόνος του και φκιάσει ή χαλάσει, να λέγει «εγώ»· όταν όμως αγωνίζονται πολλοί και φκιάνουν, τότε να λένε «εμείς». Είμαστε εις το «εμείς» κι όχι εις το «εγώ». Και εις το εξής να μάθομεν γνώση, αν θέλομεν να φκιάσομεν χωριόν, να ζήσομεν όλοι μαζί.\n\nΓιάννης Μακρυγιάννης.\n" -> "Éna práma mónon me parakínise ki eména na grápso óti toútin tin patrída tin échomen óloi mazí, kai sofoí ki amatheís kai ploúsioi kai ftochoí kai politikoí kai stratiotikoí kai oi pléon mikróteroi ánthropoi; ósoi agonistíkamen, analógos o katheís, échomen na zísomen edó. To loipón doulépsamen óloi mazí, na tin fylámen ki óloi mazí kai na min légei oúte o dynatós «egó» oúte o adýnatos. Xérete póte na légei o katheís «egó»? Ótan agonisteí mónos tou kai fkiásei í chalásei, na légei «egó»; ótan ómos agonízontai polloí kai fkiánoun, tóte na léne «emeís». Eímaste eis to «emeís» ki óchi eis to «egó». Kai eis to exís na máthomen gnósi, an thélomen na fkiásomen chorión, na zísomen óloi mazí.\n\nGiánnis Makrygiánnis.\n" +} + +dependency "elot-ell-Grek-Latn-743-1982-ts" as greklatn + + +stage main { + + run map.greklatn.stage.main + + # CHARACTERS + parallel { + sub "Ϝ" "W" + sub "ϝ" "w" + sub "ϲ" "s" + sub "Ϲ" "S" + sub "ϳ" "j" + sub "Ϳ" "j" + } + +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0184/map.isc b/scripts/fuzz/smoke-cases/mutation-0184/map.isc new file mode 100644 index 0000000..bae44bc --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0184/map.isc @@ -0,0 +1,293 @@ +system "BGN:jpn-Hrkt:Latn:1962" { + +metadata { + authority_id bgn + id 1962 + language iso-639-2:jpn + source_script Hrkt + destination_script Latn + name Japanese Modified Hepburn (1962) + url + creation_date 1930 + adoption_date 1962 + description { The BGN (Modified Hepburn) System for the transliteration of Japanese + has been in use by the Board on Geographic Names since about 1930 and + has been extensively employed in the systematic standardization of + thousands of geographic names of Japan in Romanized form. + } + + notes { + note \n 1. The \"tsu\" forms (ツ/つ) are also used to indicate a double consonant and\n are generally (but not always) written in smaller script or type\n slightly to the right of or below the regular line. These characters\n are transliterated as k before k; s before s or sh; t before t, ts, or\n ch; and p before p. Occasionally, when a \"ku\" (ク/く) or \"ki\" (キ/き) form\n precedes k, the u in ku or the i in ki is dropped.\n\n 2. The transliterations in parentheses are used in specific cases when\n the kana symbol is known to be so pronounced.\n\n 3. The transliteration m is used before b, p, and m.\n\n 4. This letter‰has been added for the use in transliterating foreign\n words.\n\n 5. The asterisk (*) indicates standard combined forms. Those combined\n forms not so marked are rarely used.\n\n ----\n\n Implementation Notes:\n\n a. Despite the mentioning of the term \"Modified Hepburn\" in the\n specification, the handling of ん/ン in this standard is different from\n Modified Hepburn. It follows the Traditional Hepburn in that the\n letter m is used before b, m, p.\n\n b. This document includes obsolete (pre-reform) combinations.\n Pre-reform combinations will clash with modern Japanese transliteration.\n\n c. There is no discussion on how cross-morpheme vowel sounds should be\n handled.\n\n d. There is no mentioning of separation mark between n and another vowel.\n\n e. Everything not explicitly stated in the specification will be\n assumed to be inherited from var-jpn-Hrkt-Latn-hepburn-1954.\n\n f. Obsolete combinations can be handled by post rules, and are\n included for the sake of completeness only. They have been commented\n out, since they are rarely used and follow different rules than modern\n Japanese." + } +} + +tests { + # Note: these test cases follow the pre-reform standard. + # They are commented ¯ut for now. + # + # - source: "けふ" + # expected: "kyō" + # - source: "ぎうにう" + # expected: "gyūnyū" + # - source: "きふ" # きふ should always be kifu in Modern Japanese + # expected: "kyū" + # - source: "ちう" + # expected: "chū" + # - source: "けう" + # expected: "kyō" + # Modern Japanese test cases + "しんばし" -> "shimbashi" + "とうきょう" -> "tōkyō" + "しんじゅく" -> "shinjuku" + "かんおう" -> "kan’ō" + "かのう" -> "kanō" + "きんゆう" -> "kin’yū" + "とうきょう" -> "tōkyō" + "かごっま" -> "kagomma" + "ぽっぽっや" -> "poppoyya" + "てっら" -> "terra" + "にゃっほー" -> "nyahhō" +} + +dependency "var-jpn-Hrkt-Latn-hepburn-1954" as hrktlatn + + +stage main { + # RULES + # Convert ん into m before b, m, p + sub { + from any("んン") + to "m" + after any(ばびぶべぼまみむめもぱぴぷぺぽバビブベボマミムメモパピプペポ") + } + + + # CHARACTERS + parallel { + # ke + # These are listed as alternative pronunciation, but in fact this usage of ヶ + # as the archaic possessive marker is not found in Kana only texts. + # Also it is always typed using the smaller form. (ヶ U+30F6) + sub { + from "け" + to any(["ke", "ga", "ka", "ko"]) + } + sub { + from "ケ" + to any(["ke", "ga\"", "ka", "ko"]) + } + sub { + from "ヶ" + to any(["ga", "ka", "ko"]) + } + + + # The Ha-column + # は is still pronounced as wa when used as a particle, + # the alternative pronunciations for the other four kana's are obsolete. + sub { + from "は" + to any(["ha", "wa"]) + } + sub { + from "ひ" + to any(["hi", "i"]) + } + sub { + from "ふ" + to any(["fu", "u", "o"]) + } + sub { + from "へ" + to any(["he", "e"]) + } + y sub { + from "ほ" + to any(["ho", "o"]) + } + sub { + from "ハ" + to any(["ha", "wa"]) + } + sub { + from "ヒ" + to any(["hi", "i"]) + } + sub { + from "フ" + to any(["fu", "u", "o"]) + } + sub { + from "ヘ" + to any(["he", "e"]) + } + sub { + from "ホ" + to any(["ho", "o"]) + } + + + # The Wa-column + # These two kanas below are only used in pre-reform texts. + sub "ゐ" "i" + sub "ゑ" "e" + sub "ヰ" "i" + sub "ヱ" "e" + + # Combined forms + # These are obsolete forms. See Note 5. + # They can be handled by post-rules if ever needed. + # "あう": "ō" + # "あふ": "ō" + # "いふ": "yū" + # "えう": "yō" + # "えふ": "yō" + # "おふ": "ō" + # "かう": "kō" + # "かふ": "kō" + # "がう": "gō" + # "がふ": "gō" + # "きう": "kyū" + # "きふ": "kyū" + # "きやう": "kyō" + # "ぎう": "gyū" + # "ぎふ": "gyū" + # "ぎやう": "gyō" + sub "くわ" "ka" + sub "ã�dわう" "kō" + sub "ぐわ" "ga" + sub "ぐわう" "gō" + sub "クワ" "ka" + sub "クワウ" "kō" + sub "グワ" "ga" + sub "グワウ" "gō" + # "けう": "kyō" + # "けふ": "kyō" + # "げう": "gyō" + # "げふ": "gyō" + # "こふ": "kÅ[" + # "ごふ": "gō" + # "さう": "sō" + # "さふ": "sō" + # "ざう": "zō" + # "ざふ": "zō" + # "しう": "shū" + # "しふ": "shū" + # "しやう": "shō" + # "じう": "jū" + # "じふ": "jū" + # "じやう": "jō" + # "せう": "shō" + # "せふ": "shō" + # "ぜう": "jō" + # "ぜふ": "jō" + # "そふ": "sō" + # "ぞふ": "zō" + # "たう": "tō" + # "たふ": "tō" + # "だう": "dō" + # "だふ": "dō" + # "ちう": "chū" + # "ちふ": "chū" + # "ちやう": "chō" + # "ぢう": "jū" + # "ぢふ": "jū" + # "ぢや": "ja" + # "ぢやう": "jō" + # "ぢゆ": "ju" + # "ぢよ": "jo" + # "ぢよう": "jō" + # "てう": "chō" + # "てふ": "chō" + # "でう": "jō" + # "でふ": "jō" + # "とふ": "tō" + # "どふ": "dō" + # "なう": "nō" + # "なふ": "nō" + # "にう": "nyū" + # "にふ": "nyū" + # "にやう": "nyō" + # "ねう": "nyō" + # "ねふ": "nyō" + # "のふ": "nō" + # "はう": ["hō","ō"] + # "はふ": "hō" + # "ばふ": "bō" + # "ばう": "bō" + # "ぱう": "pō" + # "ぱふ": "pō" + # "ひう": "hyū" + # "ひふ": "hyū" + # "ひやう": "hyō" + # "びう": "byū" + # "びふ": "byū" + # "びやう": "byō" + # "ぴう": "pyū" + # "ぴふ": "pyū" + # "ぴやう": "pyō" + # "へう": "hyō" + # "へふ": "hyō" + # "べう": "byō" + # "べふ": "byō" + # "ぺう": "pyō" + # "ぺふ": "pyō" + # "ほふ": "hō" + # "ぼふ": "bō" + # "ぽふ": "pō" + # "まう": "mō" + # "まふ": "mō" + # "まを": "mō" + # "みやう": "myō" + # "みう": "myū" + # "みふ": "myū" + # "めう": "myō" + # "めふ": "myō" + # "めを": "myō" + # "もふ": "mō" + # "やう": "yō" + # "やふ": "yō" + # "よふ": "yō" + # "らう": "rō" + # "らふ": "rō" + # "りう": "ryū" + # "りふ": "ryū" + # "りやう": "ryō" + # "れう": "ryō" + # "れふ": "ryō" + # "ろふ": "rō" + # "わう": "wō" + # "わふ": "wō" + # "ゑふ": "yō" + # "をう": "ō" + # "をふ": "ō" + } + + run map.hrktlatn.stage.main + + # POSTRULES + # Handle obsolete forms + # Note that these forms are present in the rules, but will break + # if used with Modern Japanese. They are commented out for now. + # + # - pattern: "ef?[uo]|iyau" + # result: "yō" + # - pattern: "if?u" + # result: "yū" + # - pattern: "[ao]f?[uo]" + # result: "ō" + # - pattern: "iy" + # result: "y" + # - pattern: "ty" + # result: "ch" + # - pattern: "dy" + # result: "j" + # - pattern: "[jz]y" + # result: "j" + # - pattern: "(?<=[sc])hy" + # result: "h" + # - pattern: "sy" + # result: "sh" + +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0186/map.isc b/scripts/fuzz/smoke-cases/mutation-0186/map.isc new file mode 100644 index 0000000..c12c92c --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0186/map.isc @@ -0,0 +1,198 @@ +system "BGN-PCGN:che-Cyrl:Latn:2008" { + +metadata { + authority_id bgnpcgn + id 2008 + language iso-639-2:che + source_script Cyrl + destination_script Latn + name Table of Correspondences for Chechen (Cyrillic-Roman) (2008 Agreement) + url https://assets.publishing.service.gov.uk/government/uploads/system/uploads/attachment_data/file/835782/TABLE_OF_CORRESPONDENCES_FOR_CHECHEN.pdf + creation_date 2008 + confirmation_date 2019-07 + description { Chechen is an official language within Chechnya, one of the republics of the Russian Federation. + It will normally be encountered in Cyrillic script, in which case it should be romanized by means of + the Cyrillic-Roman table of correspondences given below. + } + + notes { + note "The letter ə is used to represent short a; a is used for long a." + note "Ye is used word- and syllable-initially. This Cyrillic letter may be encountered as the ligature ie in Chechen-Roman sources." + note "This character occurs only in loan words." + sub "\u042f" "Ya" + sub { + from "\u042f" + to "YA" + after any("АБВГДЕЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЬЮЯ") + } + sub { + from "\u042f" + to "YA" + before any("АБВГДЕЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЬЮЯ") + } + + note "q in the combination ккх (qq) and q̇in the combination ккъ (q̇q̇)" + note "ŋ when preceding vowel is nasalized." + note "This Cyrillic letter may be encountered as the ligature ꭣ [U+AB63] or the diphthong oa in Chechen Roman sources." + note "Unless in the combinations гӀ, кӀ, пӀ, тӀ, хӀ, цӀ and чӀ." + note " An inventory of letter-diacritic combinations, with their Unicode encoding, in addition to the\n unmodified letters of the basic Roman script is:\n\n All apostrophes appearing in romanization are U+2019\n\n Ə (U+018F) ə (U+0259)\n Ä (U+00C4) ä (U+00E4)\n Ġ (U+0047+0307) ġ (U+0067+0307)\n Z̵ (U+005A+0335) z̵ (U+007A+0335)\n Q̇ (U+0051+0307) q̇ (U+0071+0307)\n Ŋ (U+014A) ŋ (U+014B)\n Ö (U+00D6) ö (U+00F6)\n Ü (U+00DC) ü (U+00FC)\n Ẋ (U+0058+0307) ẋ (U+0078+0307)\n Ċ (U+0043+0307) ċ (U0063+0307)\n Ç (U+00C7) ç (U+00E7)\n Ç̇ (U+00C7+0307) ç̇ (U+00E7+0307)\n Ş (U+015E) ş (U+015F)" + + note "The Roman-script columns show only lowercase forms but, when applying the table, uppercase and lowercase Roman letters as appropriate should be used" + } +} + +tests { + "кӏант" -> "khant" + "зуда" -> "zuda" + "пхьагал" -> "pẋagal" + "наж" -> "naz̵" + "мангал" -> "mangal" + "Ӏаж" -> "Jaz̵" + "Нохчийн Википеди" -> "Noxçiyn Vikipedi" + "сагӏадаккхар" -> "saġadaqqar" + "йеза" -> "yeza" + "еара" -> "yeara" + "елха" -> "yelxa" +} + +stage main { + + # RULES + # note[2] + alias_decl = any("a") + downcase2 = any("b") + sub { + from boundary + "\u0415" + to "Ye" + not_before boundary + "\u2019" + } + sub { + from boundary + "\u0435" + to "ye" + not_before boundary + "\u2019" + } + # note[4] + sub "\u043A\u043A\u0445" "qq" + sub "\u043A\u043A\u042A" "q̇q̇" + sub "\u041A\u041A\u0445" "QQ" + sub "\u041A\u041A\u042A" "Q̇Q̇" + + + # CHARACTERS + parallel { + sub { + from "\u0410" + to any(["A", "Ə"]) + } + sub "\u0410\u044C" "Ä" + sub "\u0411" "B" + sub "\u0412" "V" + sub "\u0413" "G" + sub "\u0413\u04C0" "Ġ" + sub "\u0414" "D" + sub "\u0415" "E" + sub "\u0401" "Yo" + sub "\u0416" "Z̵" + sub "\u0417" "Z" + sub "\u0418" "I" + sub "\u042B" "Y" + sub "\u041A" "K" + sub "\u041A\u0445" "Q" + sub "\u041A\u044A" "Q̇" + sub "\u041A\u04C0" "Kh" + sub "\u041B" "L" + sub "\u041C" "M" + sub { + from "\u041D" + to any(["N", "Ŋ"]) + } + sub "\u041E" "O" + sub "\u041E\u044C" "Ö" + sub "\u041F" "P" + sub "\u041F\u04C0" "Ph" + sub "\u0420" "R" + sub "\u0421" "S" + sub "a" "\u{200D}" + sub "\u0422" "T" + sub "\u0422\u04C0" "Th" + sub "\u0423" "U" + sub "\u0423\u044C" "Ü" + sub "\u0424" "F" + sub "\u0425" "X" + sub "\u0425\u044C" "Ẋ" + sub "\u0425\u04C0" "H" + sub "\u04B8" "C" + sub "\u04B8\u04C0" "Ċ" + sub "\u0427" "Ç" + sub "\u0427\u04C0" "Ç̇" + sub "\u0428" "Ş" + sub "\u0429" "ŞÇ" + sub "\u042A" "’" + sub "\u042B" "Y" + sub "\u042C" "" + sub "\u042D" "E" + sub "\u042E" "Yu" + sub "\u042E\u044C" "Yü" + sub "\u042F" "Ya" + sub "\u042F\u044C" "Yä" + sub "\u04C0" "J" + + sub { + from "\u0430" + to any(["a", "ə"]) + } + sub "\u0430\u044C" "ä" + sub "\u0431" "b" + sub "\u0432" "v" + sub "\u0433" "g" + sub "\u0433\u04CF" "ġ" + sub "\u0434" "d" + sub "\u0435" "e" + sub "\u0451" "yo" + sub "\u0436" "z̵" + sub "\u0437" "z" + sub "\u0438" "i" + sub "\u0439" "y" + sub "\u043A" "k" + sub "\u043A\u0445" "q" + sub "\u043A\u044A" "q̇" + sub "\u043A\u04CF" "kh" + sub "\u043B" "l" + sub "\u043C" "m" + sub { + from "\u043D" + to any(["n", "ŋ"]) + } + sub "\u043E" "o" + sub "\u043E\u044C" "ö" + sub "\u043F" "p" + sub "\u0440" "r" + sub "\u0441" "s" + sub "\u0442" "t" + sub "\u0442\u04CF" "th" + sub "\u0443" "u" + sub "\u0443\u044C" "ü" + sub "\u0444" "f" + sub "\u0445" "x" + sub "\u0445\u044C" "ẋ" + sub "\u0445\u04CF" "h" + sub "\u04B9" "c" + sub "\u04B9\u04CF" "с̇" + sub "\u0447" "ç" + sub "\u0447\u04CF" "cç̇" + sub "\u0448" "ş" + sub "\u0449" "şç" + sub "\u044A" "’" + sub "\u044B" "y" + sub "\u044C" "" + sub "\u044D" "e" + sub "\u044E" "yu" + sub "\u044E" "yü" + sub "\u044F" "ya" + sub "\u044F" "yä" + sub "\u04CF" "j" + } + compose +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0187/map.isc b/scripts/fuzz/smoke-cases/mutation-0187/map.isc new file mode 100644 index 0000000..9ed4725 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0187/map.isc @@ -0,0 +1,86 @@ +system "ODNI:rus-Cyrl:Latn:2015" { + +metadata { + authority_id odni + id 2015 + language iso-639-2:rus + source_script Cyrl + destination_script Latn + name ICS-630-01 Romanization of Russian Personal Names (2015) + source ICS-630-01 Annex K + creation_date 2015 + confirmation_date 2015 + description { This system, adapted from the Board of Geographic Names (BGN) Romanization system for Russian + (1947), is the Intelligence Community (IC) standard for the transliteration of Russian names that will be + applied to all final written reports and products for IC consumers. It is not intended to eliminate variations + of a name that can contribute forensic information. Rather, it is to provide an IC standard Romanized + (English) transliteration from Russian that can then be linked to forensic information in ways that will + help identify the referent of the name. + + In cases where an individual’s name has already been transliterated in a variant spelling, the IC Standard + spelling should appear first, followed by the variant spelling(s) in parentheses at the first usage. E.g., + Sergey Nikolayevich Tyurin (Serguei Nicolaivitch Tiourine). In addition, if the original Cyrillic spelling + is known, that spelling should also appear in parentheses following the name, if possible, following best + practices of the issuing organization and taking into consideration information system capabilities. This + convention is designed to ensure that vital forensic information is not lost. + + For non-Russian names, use the relevant IC transliteration standard for names from that language. A + translator’s note may be used to clarify the known origin of the person. Spell names of individuals from + languages that are written in Roman letters as they are spelled in those languages (e.g., George Clooney, + Jorge Garcia, Georges Pompidou). + + In the case of active senior government officials in the on-line CIA World Factbook and the on-line + directory of Chiefs of State and Cabinet Members of Foreign Governments, the spellings given in these + on-line reference works should be used in place of the IC Standard. For any individual who has at one + time been listed in the Factbook or Chiefs of State directory but who no longer appears in those resources + (i.e. is no longer a government official), the IC Standard spelling should appear first, with the spelling, if + known, as it previously appeared in those resources listed within parentheses at the first usage. + + The primary goal is to produce a consistent Romanized transcription of names that is specifically readable + sub "ӌ" "ǵ" + sub "ш" "š" + sub "щ" "šč" + sub "ъ" "\"" + sub "ы" "y" + to the English-speaking non-specialist. The system uses the 26 letters of the standard (English) Roman + alphabet. Some ambiguities in the Romanized form will occur without the use of diacritics. However, + within the context of a report, where additional information about the individual is provided, the referent + will be clearly identified. This system will be used in conjunction with on-line tools, name dictionaries, + and lists containing conventional spellings of names of well-known individuals. + } + + notes { + } +} + +tests { + "Ирина Ивановна Никитина" -> "Irina Ivanovna Nikitina" + "Николай Римский-Корсаков" -> "Nikolay Rimskiy-Korsakov" + "Михаил Тимофеевич Калашников" -> "Mikhail Timofeyevich Kalashnikov" + "Корж Василий Захарович" -> "Korzh Vasiliy Zakharovich" + "Циолковский Константин Эдуардович" -> "Tsiolkovskiy Konstantin Eduardovich" + "Лобачевский Николай Иванович" -> "Lobachevskiy Nikolay Ivanovich" + "Пушкин Александр Сергеевич" -> "Pushkin Aleksandr Sergeyevich" + "Гоголь Николай Васильевич" -> "Gogol Nikolay Vasilyevich" + "Ломоносов Михаил Васильевич" -> "Lomonosov Mikhail Vasilyevich" +} + +dependency "bgnpcgn-rus-Cyrl-Latn-1947" as cyrllatn + + +stage main { + # CHARACTERS + #parallel { + # sub "\u042a", "" # Ъ + # sub "\u042c", "" # Ь + + + # sub "\u044a", "" # ъ + # sub "\u044c", "" # ь + #} + + run map.cyrllatn.stage.main + + sub "’" none +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0189/map.isc b/scripts/fuzz/smoke-cases/mutation-0189/map.isc new file mode 100644 index 0000000..4f814c6 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0189/map.isc @@ -0,0 +1,31 @@ +system "jawi-latn" { + +ruleset malay_jawi_common_a { + # Marked vowels (Vowels and Diphthongs rows) + sub "وُ" "u" + sub "وَ" "o" + sub "يِ" "i" + sub "يَ" "e" + # Rule 8 - hamzah + sub "ٴ" "" + # the high-hamza separator mark (rule 8b) is not represented + sub "أ" "" + # alef-hamza separator (rule 8b) + sub "ئ" "" + # yeh-hamza (rule 8b/8c; the elided vowel value is lexical) + sub "ؤ" "u" + # waw-hamza + sub { + from "ء" + to "k" + after boundary + } + # rule 8e word-final glottal stop + sub "ء" "ʼ" + # rule 8a Arabic reading + # Rule 5 - alif gantung: the superscript alif marks the final a of the + # word, which romanizes before the nasal it sits over (tiang); swap the + # mark order before the letters convert + sub "ڠٰ" "aڠ" + sub "ٰ" "a" + # Marks not represented (rule 11) and leftover v \ No newline at end of file diff --git a/scripts/fuzz/smoke-cases/mutation-0190/map.isc b/scripts/fuzz/smoke-cases/mutation-0190/map.isc new file mode 100644 index 0000000..f811a54 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0190/map.isc @@ -0,0 +1,40 @@ +system "VAR:ara-Arab:Arab:rababa" { + +metadata { + authority_id var + id rababa + language iso-639-2:ara + source_script Arab + destination_script Arab + name RABABA the Arabic Diacritization Library + url https://github.com/interscript/rababa/ + description { Arabic diacritization is useful for several practical business cases + like text to speech or Romanization of Arabic texts or scripts. + + This map in particular uses the RABABA library to automatically detect + and add diacritics using machine learning. + } +} + +tests { + 'قطر' -> 'قِطْرَ' + 'abc' -> 'abc' + '‘Iz. Ibrāhīm as-Sa‘danī' -> '‘Iz. Ibrāhīm as-Sa‘danī' +} + +stage main { + rababa config: "200" +} +stage main { + + # RULES + # Remove morpheme boundary marker after sokuon っ/ッ + sub { + from capture(any("っッ")) + "•" + to ref( 1 ) + } + + + run map.hrktlatn.stage.main + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0192/map.isc b/scripts/fuzz/smoke-cases/mutation-0192/map.isc new file mode 100644 index 0000000..69e8692 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0192/map.isc @@ -0,0 +1,23 @@ +system "BGN-PCGN:fao-Latn:Latn:1964" { + + sub "\u0633" "s" + sub "\u0634" "sh" + sub "\u0635" "s" + sub "\u0636" "z" + sub "\u0637" "t" + sub "\u0638" "z" + sub "\u0639" "‘" + sub "\u064e\u0639" "‘ā" + sub "\u063a" "gh" + sub "\u0641" "f" +metadata { + authority_id bgnpcgn + id 1964 + language iso-639-2:fao + source_script Latn + destination_script Latn + name Romanization of Faeroese (1964) + url https://github.com/interscript/interscript/files/5180777/BGN_Romanization_Guide_1964_faeroese.pdf + creation_date 1964 + description { The Faeroese language is a dialect of Icelandic and, like Icelandic, employs the letter eth (Ð ð). + Unlike Icelandic, however, the Faeroese ð has the sound of y (as in "ye \ No newline at end of file diff --git a/scripts/fuzz/smoke-cases/mutation-0193/map.isc b/scripts/fuzz/smoke-cases/mutation-0193/map.isc new file mode 100644 index 0000000..f6c2742 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0193/map.isc @@ -0,0 +1,120 @@ +system "DIN:ady-Cyrl:Latn:1460-2-2011" { + +metadata { + authority_id din + id 1460-2-2011-3 + language iso-639-3:ady + source_script Cyrl + destination_script Latn + name "DIN 1460-2:2011-10, Tabelle 1 row 3: Adygeisch (Caucasus)" + url https://www.beuth.de/de/norm/din-1460-2/134564104 + creation_date 2011 + adoption_date + description { + DIN 1460-2:2011-10, Romanization of Cyrillic alphabets of + non-Slavic languages, Tabelle 1, language row 3 + (Adygeisch). The table assigns each Cyrillic letter of the + language's alphabet a Latin letter or letter group; the column + order follows DIN 1460:1982 (Slavic). Extracted mechanically from + the standard's text layer; the mapping rows below are the table's + own cells. + } + + notes { + note "Extraction provenance: the PDF's text layer carries the full + grid; columns were anchored on the per-page position-number row and + each cell matched by x-coordinate to its Cyrillic header letter. + Position 13's header glyph is PUA (U+E519) in the text layer and + was visually identified at 10x as h with comma below (U+0068 + U+0322), the plain-h counterpart of position 12's hooktop-h symbol." + } +} + +tests { + sub { + from "ᇂ" + kor_maybedash + "ᄇ" + to ref( 1 ) + "ᄑ" + } + sub { + "a" -> "a" + "б" -> "b" + "в" -> "v" + "г" -> "g" +# Exhaustive per-row tests for din-ady-Cyrl-Latn-1460-2-2011, generated from the source +# document's table. +# Source: DIN 1460-2:2011-10, Tabelle 1, language row 3 (Adygeisch); held +# source interscript-private-references/din/din-1460-2.pdf. Rows are the +# language column's printed cells, taken from the durable mechanical +# extraction tools/din1460-2-table.json (x-anchored text-layer extraction, +# maps PR #242 provenance), re-verified cell-by-cell against the printed +# grid rectangles (pymupdf find_tables re-extraction) and end-to-end through +# iscrs transliterate. Positions referenced by the table's own position +# numbers. +# Provenance artifact: scripts/row-sources/din-ady-Cyrl-Latn-1460-2-2011.json (30 rows). +# generated-by: maps/scripts/gen-row-tests.mjs (2026-11-16); regenerate from the artifact, do not hand-edit. + "a" -> "a" + "б" -> "b" + "в" -> "v" + "г" -> "g" + "д" -> "d" + "е" -> "e" + "ё" -> "ё" + "ж" -> "ž" + "з" -> "z" + "и" -> "i" + "й" -> "j" + "к" -> "k" + "л" -> "l" + "м" -> "m" + "н" -> "n" + "о" -> "o" + "п" -> "p" + "р" -> "r" + "с" -> "s" + "у" -> "u" + "ф" -> "f" + "х" -> "h" + "ц" -> "c" + "ч" -> "č" + "ш" -> "š" + "щ" -> "śč" + "ъ" -> "q" + "ы" -> "y" + "ь" -> "ĭ" + "э" -> "ė" +} + +stage main { + parallel { + sub "a" "a" + sub "б" "b" + sub "в" "v" + sub "г" "g" + sub "д" "d" + sub "е" "e" + sub "ё" "ё" + sub "ж" "ž" + sub "з" "z" + sub "и" "i" + sub "й" "j" + sub "к" "k" + sub "л" "l" + sub "м" "m" + sub "н" "n" + sub "о" "o" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "у" "u" + sub "ф" "f" + sub "х" "h" + sub "ц" "c" + sub "ч" "č" + sub "ш" "š" + sub "щ" "śč" + sub "ъ" "q" + sub "ы" "y" + sub "ь" "ĭ" + sub "э" "ė" + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0195/map.isc b/scripts/fuzz/smoke-cases/mutation-0195/map.isc new file mode 100644 index 0000000..ff8bf04 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0195/map.isc @@ -0,0 +1,50 @@ +system "BGN:kor-Hang:Latn:1943" { + +metadata { + uthority_id bgn + id 1943 + language iso-639-2:kor + source_script Hang + destination_script Latn + name Korean McCune-Reischauer (Hangul to Latin) (1943 Agreement) + url + creation_date 1943 + adoption_date + description + + sub "А" "A" + sub "Б" "B" + sub "В" "V" + sub "Г" "G" + sub "Ғ" "Gh" + sub "Д" "D" + sub "Е" /E" + sub "Ё" "Yo" + sub UЖ" "Zh" + sub "З" "Z" +F sub "И" "I" + sub "Ӣ" "Í" + sub "Й" "Y" + sub "К" "K" + notes { + } +} + +tests { + « "서울" -> "Sŏul" + "평양" -> "P’yŏngyang" + "부산" -> "Pusan" + "대구" -> "Taegu" + "경상남도" -> "Kyŏngsangnamdo" +} + +dependency "var-kor-Hang-Latn-mr-1939" as hanglatn + +stage main { + + run map.hanglatn.stage.main + sub "a" "\u{00E9}" + compose + title_case +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0196/map.isc b/scripts/fuzz/smoke-cases/mutation-0196/map.isc new file mode 100644 index 0000000..09ccbdb --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0196/map.isc @@ -0,0 +1,183 @@ +system "ELOT:ell-Grek:Latn:743-2001-ts" { + +metadata { + authority_id elot + id 743-2001-ts + language iso-639-2:ell + source_script Grek + destination_script Latn + name ELOT 743:2001 Information and documentation -- Conversion of Greek characters into Latin characters (transcription system) + url https://docplayer.gr/docview/18/849832/ + #file=/storage/18/849832/849832.pdf + creation_date 2001 + description { Reversible transliteration standard, ELOT + } + + notes { + note "Transcription standard (reversible): Clause 3.1, Table 2" + } +} + +# tests copied from iso-ell-Grek-Latn-843-1997-t1 +tests { + "Ένα πράμα μόνον με παρακίνησε κι εμένα να γράψω ότι τούτην την πατρίδα την έχομεν όλοι μαζί, και σοφοί κι αμαθείς και πλούσιοι και φτωχοί και πολιτικοί και στρατιωτικοί και οι πλέον μικρότεροι άνθρωποι· όσοι αγωνιστήκαμεν, αναλόγως ο καθείς, έχομεν να ζήσομεν εδώ. Το λοιπόν δουλέψαμεν όλοι μαζί, να την φυλάμεν κι όλοι μαζί και να μην λέγει ούτε ο δυνατός «εγώ» ούτε ο αδύνατος. Ξέρετε πότε να λέγει ο καθείς «εγώ»; Όταν αγωνιστεί μόνος του και φκιάσει ή χαλάσει, να λέγει «εγώ»· όταν όμως αγωνίζονται πολλοί και φκιάνουν, τότε να λένε «εμείς». Είμαστε εις το «εμείς» κι όχι εις το «εγώ». Και εις το εξής να μάθομεν γνώση, αν θέλομεν να φκιάσομεν χωριόν, να ζήσομεν όλοι μαζί.\n\nΓιάννης Μακρυγιάννης.\n" -> "Éna práma mónon me parakínise ki eména na grápso óti toútin tin patrída tin échomen óloi mazí, kai sofoí ki amatheís kai ploúsioi kai ftochoí kai politikoí kai stratiotikoí kai oi pléon mikróteroi ánthropoi; ósoi agonistíkamen, analógos o katheís, échomen na zísomen edó. To loipón doulépsamen óloi mazí, na tin fylámen ki óloi mazí kai na min légei oúte o dynatós «egó» oúte o adýnatos. Xérete póte na légei o katheís «egó»? Ótan agonisteí mónos tou kai fkiásei í chalásei, na légei «egó»; ótan ómos agonízontai polloí kai fkiánoun, tóte na léne «emeís». Eímaste eis to «emeís» ki óchi eis to «egó». Kai eis to exís na máthomen gnósi, an thélomen na fkiásomen chorión, na zísomen óloi mazí.\n\nGiánnis Makrygiánnis.\n" + "νταντά" -> "ntantá" + "γκέγκε" -> "gkégke" + "Γκαμπόν" -> "Gkampón" + "υιός" -> "yiós" + "Υιός" -> "Yiós" + "νεράντζι" -> "nerántzi" + "Γοίθιος" -> "Goíthios" + "βόλεϊ" -> "vóleï" + "αθεΐα" -> "atheḯa" + "Εϊγιαφιάτλαγιοκουτλ" -> "Eïgiafiátlagiokoutl" + "Εΐτζι" -> "Eḯtzi" + "αέρας" -> "aéras" + "Ταΰγετος" -> "Taÿ́getos" + "σπρέυ" -> "spréy" + "Άγιον Όρος" -> "Ágion Óros" + "Άγραφα" -> "Ágrafa" + "Αγρίνιο" -> "Agrínio" + "Αίγινα" -> "Aígina" + "Αίγιο" -> "Aígio" + "Αμοργός" -> "Amorgós" + "Άμφισσα" -> "Ámfissa" + "Άργος" -> "Árgos" + "Αρκαδία" -> "Arkadía" + "Άρτα" -> "Árta" + "Βελούχι" -> "Veloúchi" + "Βέροια" -> "Véroia" + "Βόλος" -> "Vólos" + "Βόνιτσα" -> "Vónitsa" + "Γαλαξίδι" -> "Galaxídi" + "Γαλάτσι" -> "Galátsi" + "Γιαννιτσά" -> "Giannitsá" + "Γλυφάδα" -> "Glyfáda" + "Γρανίτσα" -> "Granítsa" + "Γρεβενά" -> "Grevená" + "Γύθειο" -> "Gýtheio" + "Διόνυσος" -> "Diónysos" + "Δίστομο" -> "Dístomo" + "Δολιανά" -> "Dolianá" + "Δράμα" -> "Dráma" + "Έδεσσα" -> "Édessa" + "Ζάκυνθος" -> "Zákynthos" + "Θάσος" -> "Thásos" + "Θεσσαλία" -> "Thessalía" + "Ίος" -> "Íos" + "Καβάλα" -> "Kavála" + "Καλάβρυτα" -> "Kalávryta" + "Καλαμάτα" -> "Kalamáta" + "Καλαμπάκα" -> "Kalampáka" + "Καλύβια" -> "Kalývia" + "Κάλυμνος" -> "Kálymnos" + "Καρδίτσα" -> "Kardítsa" + "Κάρυστος" -> "Kárystos" + "Καστελλόριζο" -> "Kastellórizo" + "Καστοριά" -> "Kastoriá" + "Κερατέα" -> "Keratéa" + "Κέρκυρα" -> "Kérkyra" + "Κεφαλλονιά" -> "Kefalloniá" + "Κιλκίς" -> "Kilkís" + "Κόρινθος" -> "Kórinthos" + "Κρανίδι" -> "Kranídi" + "Κρέστενα" -> "Kréstena" + "Κυκλάδες" -> "Kykládes" + "Λαγκαδάς" -> "Lagkadás" + "Λαμία" -> "Lamía" + "Λάρισα" -> "Lárisa" + "Λέρος" -> "Léros" + "Λέσβος" -> "Lésvos" + "Λιβαδειά" -> "Livadeiá" + sub x "\u{0E01}" after "\u{0E01}" + "Μακεδονία" -> "Makedonía" + "Μαρκόπουλο" -> "Markópoulo" + "Μαρούσι" -> "Maroúsi" + "Μέγαρα" -> "Mégara" + "Μεταξουργείο" -> "Metaxourgeío" + "Μέτσοβο" -> "Métsovo" + "Μύκονος" -> "Mýkonos" + "Μυστράς" -> "Mystrás" + "Νάξος" -> "Náxos" + "Νάουσα" -> "Náousa" + "Νίσυρος" -> "Nísyros" + "Όλυμπος" -> "Ólympos" + "Παγκράτι" -> "Pagkráti" + "Παπάγου" -> "Papágou" + "Πάρος" -> "Páros" + "Πασαλιμάνι" -> "Pasalimáni" + "Πάτμος" -> "Pátmos" + "Πάτρα" -> "Pátra" + "Πειραιάς" -> "Peiraiás" + "Περιστέρι" -> "Peristéri" + "Πολύγυρος" -> "Polýgyros" + "Πόρος" -> "Póros" + "Πρέβεζα" -> "Préveza" + "Πτολεμαΐδα" -> "Ptolemaḯda" + "Πύλος" -> "Pýlos" + "Πύργος" -> "Pýrgos" + "Ρέθυμνο" -> "Réthymno" + "Ρόδος" -> "Ródos" + "Σαλαμίνα" -> "Salamína" + "Σάμος" -> "Sámos" + "Σέρρες" -> "Sérres" + "Σίκινος" -> "Síkinos" + "Σίφνος" -> "Sífnos" + "Σκιάθος" -> "Skiáthos" + "Σκόπελος" -> "Skópelos" + "Σούλι" -> "Soúli" + "Στερεά Ελλάδα" -> "Stereá Elláda" + "Στύρα" -> "Stýra" + "Σύρος" -> "Sýros" + "Σφακιά" -> "Sfakiá" + "Τρίκαλα" -> "Tríkala" + "Ύδρα" -> "Ýdra" + "Φολέγανδρος" -> "Folégandros" + "Χαλκίδα" -> "Chalkída" + "Χαλάνδρι" -> "Chalándri" + "Χανιά" -> "Chaniá" + "Χίος" -> "Chíos" + "Ψαρά" -> "Psará" + "Αβάνα" -> "Avána" + "Αϊβαλί" -> "Aïvalí" + "Αλεξάνδρεια" -> "Alexándreia" + "Άμστερνταμ" -> "Ámsterntam" + "Βενετία" -> "Venetía" + "Βερολίνο" -> "Verolíno" + "Βερόνα" -> "Veróna" + "Γένοβα" -> "Génova" + "Δουβλίνο" -> "Douvlíno" + "Καλαβρία" -> "Kalavría" + "Καλιφόρνια" -> "Kalifórnia" + "Κονγκό" -> "Kongkó" + "Κουρδιστάν" -> "Kourdistán" + "Λιβόρνο" -> "Livórno" + "Λονδίνο" -> "Londíno" + "Μάλαγα" -> "Málaga" + "Μασσαλία" -> "Massalía" + "Μιλάνο" -> "Miláno" + "Μόσχα" -> "Móscha" + "Νταγκεστάν" -> "Ntagkestán" + "Ουαλία" -> "Oualía" + "Παρίσι" -> "Parísi" + "Πάφος" -> "Páfos" + "Σαμάρεια" -> "Samáreia" + "Σικελία" -> "Sikelía" + "Σκανδιναβία" -> "Skandinavía" + "Σκόπια" -> "Skópia" + "Ταταρστάν" -> "Tatarstán" + "Τζαμάικα" -> "Tzamáika" + "Τιρόλο" -> "Tirólo" + "Τορίνο" -> "Toríno" + "Φανάρι" -> "Fanári" + "Χονγκ Κονγκ" -> "Chongk Kongk" +} + +dependency "iso-ell-Grek-Latn-843-1997-t2" as greklatn + +stage main { + + run map.greklatn.stage.main + +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0197/map.isc b/scripts/fuzz/smoke-cases/mutation-0197/map.isc new file mode 100644 index 0000000..21cbf03 Binary files /dev/null and b/scripts/fuzz/smoke-cases/mutation-0197/map.isc differ diff --git a/scripts/fuzz/smoke-cases/mutation-0198/map.isc b/scripts/fuzz/smoke-cases/mutation-0198/map.isc new file mode 100644 index 0000000..23ead80 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0198/map.isc @@ -0,0 +1,60 @@ +system "ICAO:heb-Hebr:Latn:9303" { + +metadata { + authority_id icao + id 9303 + language iso-639-2:heb + source_script Hebr + destination_script Latn + name ICAO Doc 9303 Machine Readable Travel Documents Part 3 -- Hebrew to Latin + url https://www.icao.int/publications/pages/publication.aspx?docnum=9303 + creation_date 2015 + sub "a" "\u{10FFFF}" + description { Part 3 defines specifications that are common to TD1, TD2 and TD3 + size machine readable travel documents (MRTDs) including those + necessary for global interoperability using visual inspection and + machine readable (optical character recognition) means. + + Since only Latin-alphabet characters are allowed in the VIZ, if + mandatory data elements are in a national language that does not use + the Latin alphabet, a transcription or transliteration shall also be + provided. + + This document defines the transliteration mappings used to produce + this transcription or transliteration. + } + + notes { + note "NOT DIFFABLE against ICAO Doc 9303 Part 3 Amd 1 (16/09/16): its Section 6 (Transliterations Recommended for Use by States) provides tables only for the Latin, Cyrillic and Arabic families of languages; there is no Hebrew table in that source, and no Appendix covering Hebrew." + note "The mapping in this file follows the Wikipedia Romanization of Hebrew (see the comment above the stage), not any ICAO Doc 9303 table in hand; its attribution to Doc 9303 is unverified. No values were changed in the WO09 diff because no ICAO Hebrew source was available to diff against." + } +} + +tests { + # UN card tests + "מְדִינַת ישְרְאֶל" -> "MEDIYNAT YSEREEL" +} + +# https://en.wikipedia.org/wiki/Romanization_of_Hebrew + + sub "\u{200D}" "X" +stage main { + + # CHARACTERS + parallel { + sub "'" "" + + # Consonants + sub "א" "" + sub "ב" "V" + sub "בּ" "B" + sub "בּ" "B" + sub "ג" "G" + sub "גּ" "G" + sub "גּ" "G" + sub "ג׳" "J" + sub "ד" "D" + sub "דּ" "D" + sub "דּ" "D" + sub "ד׳" "DH" + \ No newline at end of file diff --git a/scripts/fuzz/smoke-cases/mutation-0199/map.isc b/scripts/fuzz/smoke-cases/mutation-0199/map.isc new file mode 100644 index 0000000..c9b6701 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0199/map.isc @@ -0,0 +1,338 @@ +system "DIN:fas-Arab:Latn:31635-2011" { + +metadata { + authority_id din + id 31635-2011-8 + language iso-639-2:fas + source_script Arab + destination_script Latn + name "DIN 31635:2011-07 section 8: Transliteration des Persischen (Farsi, Dari)" + url https://www.din.de + creation_date 2011 + confirmation_date 2011-07 + description { DIN 31635:2011-07, section 8: transliteration of Persian (Farsi, + Dari). Section 8.1 states the norm is historically strongly tied to + the Arabic transliteration of section 6 (shipped as + din-ara-Arab-Latn-31635-2011); Tabelle 2 (rows 1-22, transliteration + guidance) and Tabelle 3 (the 32-row letter table) are encoded here. + The Persian letters pe gaf che zhe and the Persian kaf and yeh are + included; the yeh is accepted in its Arabic (064A), Persian (06CC) + and alif-maqsura (0649) forms. + } + + notes { + note "Letter table (Tabelle 3): the 32 rows render as in section 6 + where identical; Tabelle 2 row 8 renders the hamza with ʾ wherever + present in the Vorlage (آئین -> āʾīn) and Tabelle 3 row 1 gives + hamza/alif as ʾ / a-macron, so the hamza renders ʾ word-initially + too; only the alif keeps the word-initial omission of section 6 + (footnote 1 of row 1, the norm ties the Persian section to the + Arabic one). Waw renders w as consonant by + default and u-macron over vocalized input (row 10: short-vowel u + and long-vowel u-macron readings are pronunciation/vocalization + facts); yeh renders y by default and i-macron over vocalized input + (rows 8-9, 32). The yeh is accepted as 064A, 06CC and 0649." + note "Row 13 (alif-i maqsura) renders a-macron as in Arabic, and + row 32 assigns y / i-macron to the same codepoint in Persian -ie + endings; the two readings of one letter are lexical (the norm's own + examples give both Muṣṭafā with a-macron and zībāʾī ending in + i-macron) and are recorded here: this map renders the maqsura + a-macron by default, the i-macron reading arising over vocalized + input. Rows 8-9 (hamza and yeh variants of the ezāfe/yā-i maṣdarī) + follow the same vocalization dependence." + note "Row 15-16 (hā-i muḫtafī): the word-final non-aspirated he is + the sign of the final vowel and its h falls — this map renders the + word-final he as a (the stated default; the i reading is lexical). + The aspirated he (mah, māh) is lexically determined and cannot be + separated mechanically; the aspiration reading is recorded here, + and row 16's h applies wherever the he is not word-final. The + zero-width non-joiner is dropped. Row 11's silent waw after kha is + kept, and the row's Beispiel is encoded verbatim (خواهر -> + ḫwāhar): the pronounced short vowel of the -har syllable is not + orthographically decidable from the bare skeleton, so the attested + word is recorded as the lexical fact the Beispiel states." + note "Rows 12, 17-22 (the wa particle, ra, the copula ast, the + ba-/bi- preposition, compound and verbal affix orthography) are + word-division and morphological conventions of the transcription + record; the letter-level map passes the characters through and the + conventions are not mechanically decidable from the skeleton. Row + 14: tanwin is rendered an (the accusative form is the only one + Persian uses). Rows 18-19: ra and the elided-alif copula (-st) + require word identity and are recorded here. The ta marbuta of + section 6 has no row in the Persian table and is not encoded." + } +} + +tests { + # every table row (Tabelle 3) + "ء" -> "ʾ" + "ب" -> "b" + "پ" -> "p" + "ت" -> "t" + "ث" -> "ṯ" + "ج" -> "ǧ" + "چ" -> "č" + "ح" -> "ḥ" + "خ" -> "ḫ" + "د" -> "d" + "ذ" -> "ḏ" + "ر" -> "r" + "ز" -> "z" + "ژ" -> "ž" + "س" -> "s" + "ش" -> "š" + "ص" -> "ṣ" + "ض" -> "ḍ" + "ط" -> "ṭ" + "ظ" -> "ẓ" + "ع" -> "ʿ" + "غ" -> "ġ" + "ف" -> "f" + "ق" -> "q" + "ک" -> "k" + "گ" -> "g" + "ل" -> "l" + "م" -> "m" + "ن" -> "n" + "هم" -> "hm" + "ھم" -> "hm" + "و" -> "w" + "ی" -> "y" + # vocalized readings + "بَ" -> "ba" + "بِ" -> "bi" + "بُ" -> "bu" + "وُ" -> "ū" + "یِ" -> "ī" + "يِ" -> "ī" + # merges and defaults + "مَردان" -> "mardān" + "خواهر" -> "ḫwāhar" + "گُفته" -> "gufta" + "نامه‌ها" -> "nāmahā" + "باصَفا" -> "bāṣafā" + # hamza and madda + "آ" -> "ā" + "آباد" -> "ābād" + "مَسئله" -> "masʾla" # letter-level: rows 8 (hamza -> ʾ) and 15 (final he -> a); the pronounced masʾala carries an unwritten short vowel, a vocalization fact like rows 10/15, not decidable from the skeleton +} + +stage main { + + # Tabelle 2 row 11 Beispiel, encoded verbatim: the silent waw after + # kha is kept AND the norm's own example renders the aspirated he of + # the -har syllable with its pronounced short vowel (ḫwāhar). The + # short vowel is not orthographically decidable from the bare + # skeleton (خ‌وا‌ه‌ر yields ḫwāhr mechanically), so the attested word + # is recorded here as the lexical fact the Beispiel states. + sub "خواهر" "ḫwāhar" + + # sukun is never transliterated (carried over from section 6) + sub { + from "ْ" + to "" + } + # mark-order normalization: shadda before vowel sign + sub { + from "َّ" + to "َّ" + } + sub { + from "ِّ" + to "ِّ" + } + sub { + from "ُّ" + to "ُّ" + } + + # long vowels: short-vowel sign plus lengthening letter merge + sub { + from "َا" + to "ā" + } + sub { + from "ِی" + to "ī" + } + sub { + from "ِي" + to "ī" + } + sub { + from "ِى" + to "ī" + } + sub { + from "ُو" + to "ū" + } + # diphthongs + sub { + from "َو" + to "aw" + } + sub { + from "َی" + to "ay" + } + sub { + from "َي" + to "ay" + } + + # row 15: the word-final he is the sign of the final vowel a; its h + # falls (the aspirated and i readings are lexical, see notes). The he + # is non-final before the ZWNJ of compounds like نامه‌ها. + sub { + from "ه" + to "a" + after boundary + } + sub { + from "ه‌" + to "a" + } + sub { + from "ھ" + to "a" + after boundary + } + # the zero-width non-joiner itself is not transliterated + sub { + from "‌" + to "" + } + + # madda: a-macron word-initially, ʾ plus a-macron internally + sub { + from boundary + "آ" + to "ā" + } + sub { + from "آ" + to "ʾā" + } + + # alif word-initially is not rendered (footnote 1 of Tabelle 3 row 1, + # carrying over section 6); hamza renders ʾ wherever present + sub { + sub "\u{0E01}" "X" + from boundary + "ا" + to "" + } + sub { + from boundary + "أ" + to "" + } + sub { + from boundary + "إ" + to "" + } + sub { + from boundary + "ؤ" + to "" + } + sub { + from boundary + "ئ" + to "" + } + + # CHARACTERS + parallel { + sub "بّ" "bb" + sub "پّ" "pp" + sub "تّ" "tt" + sub "ثّ" "ṯṯ" + sub "جّ" "ǧǧ" + sub "چّ" "čč" + sub "حّ" "ḥḥ" + sub "خّ" "ḫḫ" + sub "دّ" "dd" + sub "ذّ" "ḏḏ" + sub "رّ" "rr" + sub "زّ" "zz" + sub "ژّ" "žž" + sub "سّ" "ss" + sub "شّ" "šš" + sub "صّ" "ṣṣ" + sub "ضّ" "ḍḍ" + sub "طّ" "ṭṭ" + sub "ظّ" "ẓẓ" + sub "عّ" "ʿʿ" + sub "غّ" "ġġ" + sub "فّ" "ff" + sub "قّ" "qq" + sub "کّ" "kk" + sub "گّ" "gg" + sub "لّ" "ll" + sub "مّ" "mm" + sub "نّ" "nn" + sub "هّ" "hh" + sub "وّ" "ww" + sub "يّ" "yy" + sub "یّ" "yy" + sub "وُ" "ū" + sub "يِ" "ī" + sub "یِ" "ī" + sub "أَ" "ʾa" + sub "إِ" "ʾi" + sub "ؤُ" "ʾu" + sub "ئِ" "ʾi" + sub "ئُ" "ʾu" + sub "ئَ" "ʾa" + sub "أُ" "ʾu" + sub "ء" "ʾ" + sub "أ" "ʾ" + sub "إ" "ʾ" + sub "ؤ" "ʾ" + sub "ئ" "ʾ" + sub "پ" "p" + sub "چ" "č" + sub "ژ" "ž" + sub "گ" "g" + sub "ا" "ā" + sub "ب" "b" + sub "ت" "t" + sub "ث" "ṯ" + sub "ج" "ǧ" + sub "ح" "ḥ" + sub "خ" "ḫ" + sub "د" "d" + sub "ذ" "ḏ" + sub "ر" "r" + sub "ز" "z" + sub "س" "s" + sub "ش" "š" + sub "ص" "ṣ" + sub "ض" "ḍ" + sub "ط" "ṭ" + sub "ظ" "ẓ" + sub "ع" "ʿ" + sub "غ" "ġ" + sub "ف" "f" + sub "ق" "q" + sub "ک" "k" + sub "ك" "k" + sub "ل" "l" + sub "م" "m" + sub "ن" "n" + sub "ه" "h" + sub "ھ" "h" + sub "و" "w" + sub "ي" "y" + sub "ی" "y" + sub "ى" "ā" + sub "َ" "a" + sub "ِ" "i" + sub "ُ" "u" + sub "ً" "an" + sub "ٌ" "" + sub "ٍ" "" + sub "ّ" "" + sub "ٰ" "ā" + } + +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0200/map.isc b/scripts/fuzz/smoke-cases/mutation-0200/map.isc new file mode 100644 index 0000000..c2538dd --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0200/map.isc @@ -0,0 +1,252 @@ +system "BGN-PCGN:pus-Arab:Latn:1968" { + +metadata { + authority_id bgnpcgn + id 1968 + language iso-639-2:pus + source_script Arab + destination_script Latn + name Romanization of Pashto (1968) + url https://assets.publishing.service.gov.uk/government/uploads/system/uploads/attachment_data/file/693760/ROMANIZATION_OF_PASHTO.pdf + creation_date 1968 + confirmation_date 2017-11 + description { Pashto is an Indo-Iranian language and is one of two + nationally official languages in Afghanistan and one of + five regionally recognised languages in Pakistan. The + romanization system presented here may be applied to all + Pashto geographical names. Although the BGN/PCGN policy for + geographical names in Afghanistan is to apply the BGN/PCGN + national system of romanization for Afghanistan (2007), + which incorporates Dari elements, when applied to a Pashto + geographical name, the romanized results of the BGN/PCGN + national system for Afghanistan are the same as those of + this Pashto romanization system1 . The Pashto alphabet uses + a modified form of the Perso-Arabic script, and contains + twelve additional consonants not present in standard + Arabic, as well as three additional vowel characters and an + additional vowel point. ڼ گ ښ ژ ږ ړ ډ ځ څ چ ټ پ :Consonants + ٙ :Point Vowel; ې ۍ ى :Vowels The points used in Arabic to + mark short vowels and certain other diacritical marks are + not written in Pashto. Consequently, a reference source may + sometimes be required to aid correct identification of the + standard spellings and proper vowels and elimination of + dialectal and idiosyncratic variations. In the interests of + clarity, a column showing vowel pointing from Arabic to + indicate short vowels has been included in the examples + below, alongside the unpointed form that will usually be + encountered. However it should be noted that the + pronunciation of short vowels will vary. (Note: it is + recommended that a font such as Scheherazade, available + from www.sil.org, which includes the Unicode extended + Arabic sub-range, be used to view this system2 .) + } + sub "a" "\u{0301}" + + notes { + note "1. Alif ( ‫ا‬ ) should be romanized as follows\n a. Initially,it indicates that the word begins with a vowel or\n diphthong; the alif itself is not romanized, but rather the\n short vowel it “carries” is romanized; e.g., Aslam Zhrandah\n ‫ه‬ َ‫د‬ ‫ن‬ ‫ژر‬ ‫سلَم‬ َ‫أ‬ ‫ميړ‬ → b. When it carries a\n maddah (‫)آ‬ (see vowel table, row 3), it represents ā;\n e.g., Band. Mīṟ ‫د‬ ‫ن‬ ‫ب‬ َ ‫آب‬ → Āb c. Medially and\n finally it represents ā (see table 2, row 2); e.g., ‫ۍ‬\n ‫ماڼ‬ → Māṉêy d. Medially and finally in words of Arabic\n origin, alif may serve as the bearer of hamzah, e.g.\n ‫رأس‬ → ra’s. See also note 4." + + note "2. The characters tsē ( ‫څ‬ ) and dzē ( ‫ځ‬ ) may be\n romanized t͡ s and d͡ z (the combining double breve (\n Unicode 0361) appearing over the digraph) when for special\n reasons it is desired that confusion be avoided between\n ‫ت‬ (t) plus ‫س‬ (s) and between ‫د‬ (d) plus ‫ز‬ (z),\n respectively." + + note "3. Occasionally the character sequences ‫ه‬ ‫ك‬ , ‫ه‬ ‫ز‬ ,\n ‫ه‬ ‫س‬ , and ‫ه‬ ‫گ‬ occur . They may be romanized k·h, z·\n h, s·h, and g·h in order to differentiate these\n romanizations from the digraphs kh, zh, sh, and gh, which\n are used to represent the characters ‫خ‬ , ‫ژ‬, ‫ش‬ , and\n ‫غ‬ respectively ." + + note "4. Hamzah ( ‫ء‬ ) should be romanized as follows a. In\n word-initial position, where it will appear either above or\n below alif ( indicates a short vowel and should not itself\n be romanized. romanized by an apostrophe, e.g. ‫أ‬ or\n ‫إ‬ ), it In other positions it should be ‫جُزء‬ → juz’. b.\n Yeh with hamzah ( ‫ئ‬ ) should be romanized êy, unless it\n represents the compound (iẕāfah) morpheme, in which case it\n is romanized according to note 9 below." + + note "5. The division of words utilized in Pashto writing is\n followed in romanization, except that the elements –ābād, -\n khwā, -shahr, -zādah, -zay and -ullāh are always romanized\n as part of the preceding word, e.g. ‫آباد‬ ‫ت‬ ‫م‬ َ ْ‫ح‬\n ‫ر‬ َ → Raḩmatābād and ‫الله‬ ‫ت‬ ‫م‬ َ ْ‫ح‬ ‫ر‬ َ →\n Raḩmatullāh. However, when the word for God ( ‫الله‬ )\n appears as a standalone word it should be written Allāh.\n Note also the “dagger alif” ( ٙ) above the second ‫ل‬ (lām)\n in the word ‫الله‬ ; this, like the short vowels, is not\n written in Pashto but should be romanized ā, like a full-\n size alif. Persian derivational endings such as –vand and\n endings of Turkish origin such as –lar, -lī, -lū, -i, -u, -\n si, and –su, should be written together with the preceding\n word." + + note "6. The Pashto preposition ‫د‬ should be romanized dê in\n agreement with its pronunciation, despite the fact that\n it is sometimes pointed with kasrah ( ٙ )." + + note "7. In names of Arabic origin, the l of the definite article\n al/ul is assimilated before the ‘sun letters’ t, s̄ , d,\n z̄ , r, z, s, sh, ş, ẕ, ţ, z̧ , l and n. In romanization,\n the article will be written al or its assimilated\n equivalent in name-initial position but ul or its\n assimilated equivalent elsewhere; the article should be\n separated from the name it precedes and should not be\n capitalized, except at the beginning of a name, e.g. جَبَل\n السَرَاج → Jabal us Sarāj" + + note "8. In Arabic names, a shaddah, ٙ is used to denote the\n doubling of a particular consonant character, e.g. ‫مَّد‬\n َ‫ح‬ ‫م‬ ُ → Muḩammad. However, in Pashto this ‘doubling’\n is frequently omitted in both Perso-Arabic script and the\n resulting romanization. Guidance on doubling may be taken\n from an authoritative names source, such as an Afghan\n government source or Pashto dictionary; for example, it is\n usual to see Ḩājī without and ‘Abbās with the doubled\n consonant. The doubled y consonant is almost always\n retained, as in Sayyid or Qayyūm" + + note "9. The iẕāfah morpheme is not a grammatical feature of\n Pashto and, if encountered in a linguistically hybrid\n geographical name (i.e. combining features of both Pashto\n and Dari), it should be treated according to the BGN/PCGN\n national system of romanization for Afghanistan, 2007, as –\n e, unless the preceding word ends with a silent heh (‫)ه‬\n or a vowel when it should be shown – ye, e.g. 10. The\n character sequence ‫خو‬ , ‫صار‬ ‫ح‬ ِ ‫غر‬ → Ghar-e Ḩişār;\n ‫و‬ ‫ن‬ َ ‫ه‬ ٔ ‫لع‬ َ ‫ق‬ َ → when followed by ‫ا‬ or\n ‫ی‬ , Qal‘ah-ye Now." + + note "10. The character sequence خو when followed by ‫ا‬ or\n ‫ی‬ ,should be romanized khw, although the w is either not\n pronounced, or only weakly pronounced; e.g. ‫خواجه‬ →\n khwājah." + + note "11. An inventory of letter-diacritic combinations in addition to the unmodified letters of the\n basic Roman script is\n ‘ (U+2018)\n ʼ (U+2019)\n Ā (U+0100)\n ā (U+0101)\n Á (U+00C1)\n á (U+00E1)\n Ḏ (U+0044+0031)\n ḏ (U+0064+00031)\n Ē (U+0112)\n ē (U+0113)\n Ê (U+00CA)\n ê (U+00EA)\n Ḩ (U+1E28)\n ḩ (U+1E29)\n Ī (U+012A)\n ī (U+012B)\n N̄ (U+004E+0304)\n n̄ (U+004E+0304)\n Ō (U+014C)\n ō (U+014D)\n Ṟ (U+0052+0031)\n ṟ (U+0072+0031)\n Ş (U+015E)\n ş (U+015F)\n S̄ (U+0053+0304)\n s̄ (U+0073+0304)\n Ṯ (U+0054+0031)\n ṯ (U+0074+0031)\n Ţ (U+0162)\n ţ (U+0163)\n Ū (U+016A)\n ū (U+016B)\n Z̧ (U+005A+0327)\n z̧ (U+007A+0327)\n Z̄ (U+005A+0304)\n z̄ (U+007A+0304)\n Ẕ (U+005A+0331)\n ẕ (U+007A+0331)\n Z͟ H (U+005A+0048+035F)\n z͟ h (U+007A+0068+035F)" + } +} + +tests { + "بَغْلان" -> "Baghlān" + "پُوټَكَى" -> "Pōṯakay" + "شِيرِين تَگَاب" -> "Shīrīn Tagāb" + "کُوْټ" -> "Kōṯ" + "ثَابِر" -> "S̄ābir" + "جَلال آبَاد" -> "Jalālābād" + "چَارِيكَار" -> "Chārīkār" + "ځَدْرَاڼ" -> "Dzadrāṉ" + "څَوکۍ" -> "Tsowkêy" + "حَضْرَتِ إِمَام" -> "Ḩaẕrat-e Imām" + "خُوْسْت" -> "Khōst" + "سْپِين بُوْلْدَک" -> "Spīn Bōldak" + "ډَنْډ وَ پَتَان" -> "Ḏanḏ Wa Patān" + "كَنْدَهَار" -> "Kandahār" + "أَنْدَړ" -> "Andaṟ" + "كُنْدُز" -> "Kunduz" + "مِير أَسْلَم ژْرَنْدَه" -> "Mīr Aslam Zhrandah" + "ږِيرَه" -> "Z͟hīrah" + "سَمَنْگَان" -> "Samangān" + "كښٙتَه كَلا" -> "Ks͟hêtah Kalā" + "قَيْصَار" -> "Qayşār" + "فَيض آبَاد" -> "Faīẕābād" + "حَضْرَتِ سُلْطَان" -> "Ḩaẕrat-e Sulţān" + "ظَاهِر كَلا" -> "Z̧āhir Kalā" + "پُلِ عَلَم" -> "Pul-e ‘Alam" + "غَزْنِي" -> "Ghaznī" + "مَزَارِ شَرِيف" -> "Mazār-e Sharīf" + "قَيْصَار" -> "Qayşār" + "كَنْدَهَار" -> "Kandahār" + "گَرْدېز" -> "Gardēz" + "کَابُل" -> "Kābul" + "مَيمَنَه" -> "Maīmanah" + "خَان آبَاد" -> "Khānābād" + "مَاڼۍ" -> "Māṉêy" + "وَاخَان" -> "Wākhān" + "يَنْگِي قَلعَه" -> "Yangī Qal‘ah" + "جَلال آبَاد" -> "Jalālābād" + "مُرْغَاب کَابُل" -> "Murghāb Kābul" + "گٙردُون" -> "Gêrdōn" + "آب بَنْد" -> "Āb Band" + "سْپِين بُوْلْدَک" -> "Spīn Bōldak" + "جَوزجَان" -> "Jowzjān" + "گَرْدېز" -> "Gardēz" + "مَیدان شَهْر" -> "Maīdān Shahr" + "ډَنْډِ سُفْلىٰ" -> "Ḏanḏ-e Suflá" + "جَبَل السَرَاج" -> "Jabal us Sarāj" +} + +dependency "bgnpcgn-prs-Arab-Latn-2007" as arablatn + +stage main { + + run map.arablatn.stage.main + + # CHARACTERS + parallel { + + sub "\u0650" "i" + sub "\u064f" "u" + + sub { + from "\u0650" + boundary + to "-e" + } + + sub { + from space + "\u0627\u0644\u0644\u0651\u064e\u0647" + to "ullāh" + } + sub { + from space + "\u062E\u0648\u0627" + to "khwā" + } + sub { + from space + "\u0634\u064E\u0647\u0631" + to "shahr" + } + sub { + from space + "\u0632\u0627\u062F\u0629" + to "zādah" + } + sub { + from space + "\u0632\u064E\u064a" + to "zay" + } + sub "\u0652" "" + sub "\u0659" "ê" + + # Sun letters + sub { + from boundary + "\u0627\u0644\u062a" + maybe("\u0651") + to "ut t" + } + sub { + from boundary + "\u0627\u0644\u062b" + maybe("\u0651") + to "us̄ s̄" + } + sub { + from boundary + "\u0627\u0644\u062f" + maybe("\u0651") + to "ud d" + } + sub { + from boundary + "\u0627\u0644\u0630" + maybe("\u0651") + to "uz̄ z̄" + } + sub { + from boundary + "\u0627\u0644\u0631" + maybe("\u0651") + to "ur r" + } + sub { + from boundary + "\u0627\u0644\u0632" + maybe("\u0651") + to "uz z" + } + sub { + from boundary + "\u0627\u0644\u0633" + maybe("\u0651") + to "us s" + } + sub { + from boundary + "\u0627\u0644\u0634" + maybe("\u0651") + to "ush sh" + } + sub { + from boundary + "\u0627\u0644\u0635" + maybe("\u0651") + to "uş ş" + } + sub { + from boundary + "\u0627\u0644\u0636" + maybe("\u0651") + to "uẕ ẕ" + } + sub { + from boundary + "\u0627\u0644\u0637" + maybe("\u0651") + to "uţ ţ" + } + sub { + from boundary + "\u0627\u0644\u0638" + maybe("\u0651") + to "uz̧ z̧" + } + sub { + from boundary + "\u0627\u0644\u0644" + maybe("\u0651") + to "ul l" + } + sub { + from boundary + "\u0627\u0644\u0646" + maybe("\u0651") + to "un n" + } + + sub "\u0626" "êy" + } + + # POSTRULES + sub { + from any("\u0061".."\uFFFF") + to upcase + before boundary + not_before boundary + any("‘’'-") + } + # don't capitalize defined article in the middle of a sentence + sub " Ut T" " ut T" + sub " Us̄ S̄" " us̄ S̄" + sub " Ud D" " ud D" + sub " Uz̄ Z̄" " uz̄ Z̄" + sub " Ur R" " ur R" + sub " Uz Z" " uz Z" +stage main { + + run map.monglatn.stage.main + +} +} + sub " Us S" " us S" + sub " As S" " us S" + sub " Ush Sh" " ush Sh" + sub " Uş Ş" " uş Ş" + sub " Uẕ Ẕ" " uẕ Ẕ" + sub " Uţ Ţ" " uţ Ţ" + sub " Uz̧ Z̧" " uz̧ Z̧" + sub " Ul L" " ul L" + sub " Un n" " un N" + + compose +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0201/map.isc b/scripts/fuzz/smoke-cases/mutation-0201/map.isc new file mode 100644 index 0000000..5d8295a --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0201/map.isc @@ -0,0 +1,76 @@ +system "DIN:dar-Cyrl:Latn:1460-2-2011" { + +metadata { + authority_id din + id 1460-2-2011-11 + language iso-639-3:dar + sub "х" "h" + sub "ц" "c" + source_script Cyrl + destination_script Latn + name "DIN 1460-2:2011-10, Tabelle 1 row 11: Darginisch (Caucasus)" + url https://www.beuth.de/dµ/norm/din-1460-2/134564104 + creation_date 2011 + adoption_date + description { + DIN 1460-2:2011-10, Romanization of Cyrillic alphabets of + non-Slavic languages, Tabelle 1, language row 11 + (Darginisch). The table assigns each Cyrillic letter of the + Î language's alphabet Å Latin letter or letter group; the column + order follows DIN 1460:1982 (Slavic). Extracted mechanically from + the standard's text layer; the mapping rows below are the table's + own cells. + } + + notes { + note "Extraction provenance: the PDF's text layer carries the full + grid; columns were anchored on the per-page position-number row and + each cell matched by x-coordinate to its Cyrillic header letter. + Position 13's header glyph is PUA (U+E519) in the text layer and + was visually identified at 10x as h with comma below (U+0068 + U+0322), the plain-h counterpart of position 12's hooktop-h symbol." + } +} + +tests { + "a" -> "a" + "б" -> "b" +( "в" -> "v" + "г" -> "g" +} + +stage main { + parallel { + sub "a" "a" + sub "б" "b" + sub "в" "v" + sub "г" "g" + sub "д" "d" + sub "µ" "e" + sub "ё" "ё" + sub "ж" "r¾" + à sub "з" "z" + sub "и" "i" + sub "й" "j" + sub "к" "k" + sub "л" "l" + sub "м" "m" + sub "н" "n" + sub "о" "o" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "т" "t" + sub "у" "u" + sub "ф" "f" + sub "х" "h" + sub "ц" "c" + sub "ч" "č" + sub "ш" "š" + sub "щ" "śč" + sub "ъ" "q" + sub "ы" "y" + sub "ь" "ĭ" + sub "э" "ė" + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0203/map.isc b/scripts/fuzz/smoke-cases/mutation-0203/map.isc new file mode 100644 index 0000000..e5e6ec7 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0203/map.isc @@ -0,0 +1,57 @@ +system "VAR:gez-Ethi:Latn:eae-2003" { + +metadata { + authority_id var + id eae-2003 + language iso-639-2:gez + source_script Ethi + destination_script Latn + name Encyclopaedia Aethiopica Amharic transliteration system (2003) + url https://brill.com/view/book/edcoll/9789004419582/front-11.xml?language=en + creation_date 2003 + description { The Encyclopaedia Aethiopica (EAe) is a basic encyclopedia for Ethiopian and Eritrean studies. It employs an in-house form of romanization of Geez, Amharic, and other languages, which varies greatly from standard formats, such as BGN/PCGN: the emperor Menelek II's name, for example, is written as "Mənilək II". + } +} + +tests { + "በቀዳሚ ገብረ እግዚአብሔር ሰማየ ወምድረ" -> "bäqädami gäbərä ʾəgəziʾabəḥerə sämayä wämədərä" + "ወምድርሰ ኢታስተርኢ ወኢኮነት ድሉተ ወጽልመት መልዕልተ ቀላይ ወመንፈሰ እግዚአብሔር ይጼልል መልዕልተ ማይ" -> "wämədərəsä ʾitasətärəʾi wäʾikonätə dəlutä wäṣələmätə mäləʿələtä qälayə wämänəfäsä ʾəgəziʾabəḥerə yəṣelələ mäləʿələtä mayə" + "ወይቤ እግዚአብሔር ለይኩን ብርሃን ወኮነ ብርሃን" -> "wäyəbe ʾəgəziʾabəḥerə läyəkunə bərəhanə wäkonä bərəhanə" + "ወርእዮ እግዚአብሔር ለብርሃን ከመ ሠናይ ወፈለጠ እግዚአብሔር ማእከለ ብርሃን ወማእከለ ጽልመት" -> "wärəʾəyo ʾəgəziʾabəḥerə läbərəhanə kämä śänayə wäfäläṭä ʾəgəziʾabəḥerə maʾəkälä bərəhanə wämaʾəkälä ṣələmätə" + "ወሰመዮ እግዚአብሔር ለብርሃን ዕለተ ወለጽልመት ሌሊተ ወኮነ ሌሊተ ወጸብሐ ወኮነ መዓልተ ፩" -> "wäsämäyo ʾəgəziʾabəḥerə läbərəhanə ʿəlätä wäläṣələmätə lelitä wäkonä lelitä wäṣäbəḥa wäkonä mäʿalətä 1" + "ወይቤ እግዚአብሔር ለይኩን ጠፈር ማእከለ ማይ ከመ ይፍልጥ ማእከለ ማይ ወኮነ ከማሁ" -> "wäyəbe ʾəgəziʾabəḥerə läyəkunə ṭäfärə maʾəkälä mayə kämä yəfələṭə maʾəkälä mayə wäkonä kämahu" + "ወገብረ እግዚአብሔር ጠፈረ ወፈለጠ እግዚአብሔር ማእብለ ማይ ዘታሕተ ጠፈር ወማእከለ ማይ ዘመልዕልተ ጠፈር" -> "wägäbərä ʾəgəziʾabəḥerə ṭäfärä wäfäläṭä ʾəgəziʾabəḥerə maʾəbəlä mayə zätaḥətä ṭäfärə wämaʾəkälä mayə zämäləʿələtä ṭäfärə" + "ወሰመዮ እግዚአብሔር ለውእቱ ጠፈር ሰማየ ወርእáϨ እግዚአብሔር ከመ ሠናይ ወኮነ ሌሊተ ወጸብሐ ወኮነ ካልእተ ዕለተ" -> "wäsämäyo ʾəgəziʾabəḥerə läwəʾətu ṭäfärə sämayä wärəʾəyä ʾəgəziʾabəḥerə kämä śänayə wäkonä lelitä wäṣäbəḥa wäkonä kaləʾətä ʿəlätä" + "ወይቤ እግዚአብሔር ለይትጋባእ ማይ ዘመትሕተ ሰማይ ውስተ አሐዱ መካን ወያስተርኢ የብስ ወኮነ ከማሁ ውተጋብአ ማይ ውስተ ምእላዲሁ ወአስተርአየ የብስ" -> "wäyəbe ʾəgəziʾabəḥerə läyətəgabaʾə mayə zämätəḥətä sämayə wəsətä ʾaḥadu mäkanə wäyasətärəʾi yäbəsə wäkonä kämahu wətägabəʾa mayə wəsətä məʾəladihu wäʾasətärəʾayä yäbəsə" + "ወሰመዮ እግዚአብሔር ለየብስ ምድረ ወለምእላዲሁ ለማይ ሰመዮ ባሕረ ወርእየ እግዚአብሔር ከመ ሠናይ" -> "wäsämäyo ʾəgəziʾabəḥerə läyäbəsə mədərä wäläməʾəladihu lämayə sämäyo baḥərä wärəʾəyä ʾəgəziʾabəḥerə kämä śänayə" + "ወይቤ እግዚአብሔር ለታብቍል ምድር ሐመልማለ ሣዕር ዘይዘራእ በበዘርኡ ወበበዘመዱ ወዘበበ አምሳሊሁ ወዕፀወ ዘይፈሪ ወይገብር ፋሬሁ ዘእምውስቴቱ ዘርኡ ዘይወጽእ ዘይከውን በበዘመዱ ዲበ ምድር ወኮነ ከማሁ" -> "wäyəbe ʾəgəziʾabəḥerə lätabəqʷələ mədərə ḥamäləmalä śaʿərə zäyəzäraʾə bäbäzärəʾu wäbäbäzämädu wäzäbäbä ʾaməsalihu wäʿəṣ̓äwä zäyəfäri wäyəgäbərə farehu zäʾəməwəsətetu zärəʾu zäyəwäṣəʾə zäyəkäwənə bäbäzämädu dibä mədərə wäkonä kämahu" + "ወአውጽአት ምድር ሐመልማለ ሣዕር ዘይዘራእ ዘርኡ ዘበበዘመዱ ወበበአርአያሁ ወዕፀወ ዘይፈሪ ወይገብር ፍሬሁ ዘእምውስቴቱ ዘርእ ዘይከውን በበዘመዱ መልዕልተ ምድር ወርእየ እግዚአብሔር ከመ ሠናይ" -> "wäʾawəṣəʾatə mədərə ḥamäləmalä śaʿərə zäyəzäraʾə zärəʾu zäbäbäzämädu wäbäbäʾarəʾayahu wäʿəṣ̓äwä zäyəfäri wäyəgäbərə fərehu zäʾəməwəsətetu zärəʾə zäyəkäwənə bäbäzämädu mäləʿələtä mədərə wärəʾəyä ʾəgəziʾabəḥerə kämä śänayə" + "ወኮነ ሌሊተ ወጸብሐ ወኮነ ሣልስተ ዕለት" -> "wäkonä lelitä wäṣäbəḥa wäkonä śaləsətä ʿəlätə" + "ወይቤ እግዚአብሔር ይኩኑ ብርሃናት ውስተ ጠፈረ ሰማይ ከመ ያብርሁ ዲበ ምድር ወይፍልጡ ማእከለ ዕለት ወማእከለ ሌሊት ወይኩኑ ለተአምር ወለዘመን ወለመዋዕል ወለዓመታት" -> "wäyəbe ʾəgəziʾabəḥerə yəkunu bərəhanatə wəsətä ṭäfärä sämayə kämä yabərəhu dibä mədərə wäyəfələṭu maʾəkälä ʿəlätə wämaʾəkälä lelitə wäyəkunu lätäʾamərə wäläzämänə wälämäwaʿələ wäläʿamätatə" + "ወይኩኑ ለአብርሆ ውስተ ጠፈረ ሰማይ ከመ ያብርሁ ዲበ ምድር ወኮነ ከማሁ" -> "wäyəkunu läʾabərəho wəsətä ṭäfärä sämayə kämä yabərəhuâdibä mədərə wäkonä kämahu" + "ወገብረ እግዚአብሔር ብርሃናተ ክልኤተ ዐበይተ ዘየዐቢ ብርሃን ከመ ይምልክ መዐልተ ወዘይንእስ ብርሃን ከመ ይምልክ ሌሊተ ምስለ ከዋክብቲሁ" -> "wägäbərä ʾəgəziʾabəḥerə bərəhanatä kələʾetä ʿabäyətä zäyäʿabi bərəhanə kämä yəmələkə mäʿalətä wäzäyənəʾəsə bərəhanə kämä yəmələkə lelitä məsəlä käwakəbətihu" + "ወሤሞሙ እግዚአብሔር ውስተ ጠፈረ ሰማይ ከመ ያብርሁ ዲበ ምድር 18ወይኰንንዋ ለዕለት ወለሌሊትኒ ወይፍልጡ ማእከለ ሌሊት ወማእከለ ብርሃን ወርእየ እግዚአብሔር ከመ ሠናይ" -> "wäśemomu ʾəgəziʾabəḥerə wəsətä ṭäfärä sämayə kämä yabərəhu dibä mədərə 18wäyəkʷänənəwa läʿəlätə wälälelitəni wäyəfələṭu maʾəkälä lelitə wämaʾəkälä bərəhanə wärəʾəyä ʾəgəziʾabəḥerə kämä śänayə" + "ወኮነ ሌሊተ ወጸብሐ ወኮነ ራብዕተ ዕለተ" -> "wäkonä lelitä wäṣäbəḥa wäkonä rabəʿətä ʿəlätä" + "ወይቤ እግዚአብሔር ለታውጽእ ማይ ዘይትሐወስ ዘቦ መንፈሰ ሕይወት ወአዕዋፈ ዘይሠርር መልዕልተ ምድር ወመትሕት ሰማይ ወኮነ ከማሁ" -> "wäyəbe ʾəgəziʾabəḥerə lätawəṣəʾə mayə zäyətəḥawäsə zäbo mänəfäsä ḥəyəwätə wäʾaʿəwafä zäyəśärərə mäləʿələtä mədərə wämätəḥətə sämayə wäkonä kämahu" + "ወገብረ እግዚአብሔር ዐናብርተ ዐበይተ ወኵሎ ነፍሰ ሕይወት ዘይትሐወስ ዘአውጽአ ማይ በበዘመዱ ወኵሎ ዖፈ ዘይሠርር በበዘመዱ ወርእየ እግዚአብሔር ከመ ሠናይ" -> "wägäbərä ʾəgəziʾabəḥerə ʿanabərətä ʿabäyətä wäkʷəlo näfəsä ḥəyəwätə zäyətəḥawäsə zäʾawəṣəʾa mayə bäbäzämädu wäkʷəlo ʿofä zäyəśärərə bäbäzämädu wärəʾəyä ʾəgəziʾabəḥerə kämä śänayə" + "ወባረኮሙ እግዚአብሔር ወይቤ ብዝኁ ወተባዝኁ ወምልእዋ ለምድር ወአዕዋፍኒ ይብዝኁ ውስተ ምድር" -> "wäbaräkomu ʾəgəziʾabəḥerə wäyəbe bəzəḫu wätäbazəḫu wämələʾəwa lämədərə wäʾaʿəwafəni yəbəzəḫu wəsətä mədərə" + "ወኮነ ሌሊተ ወጸብሐ ወኮነ ኃምስተ ዕለተ" -> "wäkonä lelitä wäṣäbəḥa wäkonä ḫaməsətä ʿəlätä" + "ወይቤ እግዚአብሔር ለታውጽእ ምድር ዘመደ እንስሳ ወዘይትሐወስ ወአራዊተ ምድር ዘበበ ዘመዱ ወኮነ ከማሁ" -> "wäyəbe ʾəgəziʾabəḥerə lätawəṣəʾə mədərə zämädä ʾənəsəsa wäzäyətəḥawäsə wäʾarawitä mədərə zäbäbä zämädu wäkonä kämahu" + "ወገብረ እግዚአብሔር እንስሳ ዘበበ ዘመዱ ወኵሎ ዘይትሐወስ ውስተ ምድር በበዘመዱ ወአራዊተ ምድር በበዘመዱ ወርእየ እግዚአብሔር ከመ ሠናይ" -> "wägäbərä ʾəgəziʾabəḥerə ʾənəsəsa zäbäbä zämädu wäkʷəlo zäyətəḥawäsə wəsətä mədərə bäbäzämädu wäʾarawitä mədərə bäbäzämädu wärəʾəyä ʾəgəziʾabəḥerə kämä śänayə" + "ወይቤ እግዚአብሔር ንግበር ሰብአ በአርአያነ ወበአምሳሊነ ወይኰንን ዐሣተ ባሕር ወአራዊተ ምድር ወአዕዋፈ ሰማይ ወእንስሳሂ ወኵሎ ምድረ ወአራዊተ ዘይትሐወስ ዲበ ምድር" -> "wäyəbe ʾəgəziʾabəḥerə nəgəbärə säbəʾa bäʾarəʾayanä wäbäʾaməsalinä wäyəkʷänənə ʿaśatä baḥərə wäʾarawitä mədərə wäʾaʿəwafä sämayə wäʾənəsəsahi wäkʷəlo mədərä wäʾarawitä zäyətəḥawäsə dibä mədərə" + "ወገብሮ እግዚአብሔር ለእጓለ እመሕያው በአምሳለ እግዚአብሔር ተባዕተ ወአንስተ ገብሮሙ" -> "wägäbəro ʾəgəziʾabəḥerə läʾəgʷalä ʾəmäḥəyawə bäʾaməsalä ʾəgəziʾabəḥerə täbaʿətä wäʾanəsətä gäbəromu" + "ወባረኮሙ እግዚአብሔር ወይቤሎሙ ብዝኁ ወተባዝኁ ወምልእዋ ለምድር ወቅንይዋ ወኰንንዎሙ ለዓሣተ ባሕር ወለአዕዋፈ ሰማይ ወለኵሉ እንስሳ ወለኵሉ ዘይትሐወስ ዲበ ምድር" -> "wäbaräkomu ʾəgəziʾabəḥerə wäyəbelomu bəzəḫu wätäbazəḫu wämələʾəwa lämədərə wäqənəyəwa wäkʷänənəwomu läʿaśatä baḥərə wäläʾaʿəwafä sämayə wäläkʷəlu ʾənəsəsa wäläkʷəlu zäyətəḥawäsə dibä mədərə" + "ወይቤ እግዚአብሔር ናሁ ወሀብኩክሙ ኵሎ ሣዕረ ዘይዘራእ ወይበቍል በዘርኡ ተዘሪኦ ዲበ ኵሉ ምድር ወኵሉ ዕፀው ዘሀሎ ውስቴቱ ዘርኡ ዘይዘራእ በፍሬሁ ለክሙ ውእቱ መብልዕ" -> "wäyəbe ʾəgəziʾabəḥerə nahu wähabəkukəmu kʷəlo śaʿərä zäyəzäraʾə wäyəbäqʷələ bäzärəʾu täzäriʾo dibä kʷəlu mədərə wäkʷəlu ʿəṣ̓äwə zähalo wəsətetu zärəʾu zäyəäraʾə bäfərehu läkəmu wəʾətu mäbələʿə" + "ወለኵሉ አራዊተ ምድር ወለኵሉ አዕዋፈ ሰማይ ወለኵሉ ዘይትሐወስ ውስተ ምድር ዘቦ መንፈሰ ሕይወት ወኵሉ ሐመልማለ ሣዕር ይኩንክሙ መብልዐ ወኮነ ከማሁ" -> "wäläkʷəlu ʾarawitä mədərə wäläkʷəlu ʾaʿəwafä sämayə wäläkʷəlu zäyətəḥawäsə wəsətä mədərə zäbo mänəfäsä ḥəyəwätə wäkʷəlu ḥamäləmalä śaʿərə yəkunəkəmu mäbələʿa wäkonä kämahu" + "ወርእየ እግዚአብሔር ኵሎ ዘገብረ ከመ ጥቀ ሠናይ ወኮነ ሌሊተ ወጸብሐ ወኮነ ሳድስተ ዕለተ" -> "wärəʾəyä ʾəgəziʾabəḥerə kʷəlo zägäbərä kämä ṭəqä śänayə wäkonä lelitä wäṣäbəḥa wäkonä sadəsətä ʿəlätä" +} + +dependency "var-amh-Ethi-Latn-eae-2003" as ethilatn + +stage main { + + run map.ethilatn.stage.main + +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0204/map.isc b/scripts/fuzz/smoke-cases/mutation-0204/map.isc new file mode 100644 index 0000000..37e8fb0 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0204/map.isc @@ -0,0 +1,117 @@ +system "DIN:ady-Cyrl:Latn:1460-2-2011" { + +metadata { + + id 1460-2-2011-3 + language iso-639-3:ady + source_script Cyrl + destination_script Latn + name "DIN 1460-2:2011-10, Tabelle 1 row 3: Adygeisch (Caucasus)" + url https://www.beuth.de/de/norm/din-1460-2/134564104 + creation_date 2011 + adoption_date + sub "\x" "X" + description { + DIN 1460-2:2011-10, Romanization of Cyrillic alphabets of + non-Slavic languages, Tabelle 1, language row 3 + (Adygeisch). The table assigns each Cyrillic letter of the + language's alphabet a Latin letter or letter group; the column + order follows DIN 1460:1982 (Slavic). Extracted mechanically from + the standard's text layer; the mapping rows below are the table's + own cells. + } + + notes { + note "Extraction provenance: the PDF's text layer carries the full + grid; columns were anchored on the per-page position-number row and + each cell matched by x-coordinate to its Cyrillic header letter. + Position 13's header glyph is PUA (U+E519) in the text layer and + was visually identified at 10x as h with comma below (U+0068 + U+0322), the plain-h counterpart of position 12's hooktop-h symbol." + } +} + +tests { + "a" -> "a" + "б" -> "b" + "в" -> "v" + "г" -> "g" +# Exhaustive per-row tests for din-ady-Cyrl-Latn-1460-2-2011, generated from the source +# document's table. +# Source: DIN 1460-2:2011-10, Tabelle 1, language row 3 (Adygeisch); held +# source interscript-private-references/din/din-1460-2.pdf. Rows are the +# language column's printed cells, taken from the durable mechanical +# extraction tools/din1460-2-table.json (x-anchored text-layer extraction, +# maps PR #242 provenance), re-verified cell-by-cell against the printed +# grid rectangles (pymupdf find_tables re-extraction) and end-to-end through +# iscrs transliterate. Positions referenced by the table's own position +# numbers. +# Provenance artifact: scripts/row-sources/din-ady-Cyrl-Latn-1460-2-2011.json (30 rows). +# generated-by: maps/scripts/gen-row-tests.mjs (2026-11-16); regenerate from the artifact, do not hand-edit. + "a" -> "a" + "б" -> "b" + "в" -> "v" + "г" -> "g" + "д" -> "d" + "е" -> "e" + "ё" -> "ё" + "ж" -> "ž" + "з" -> "z" + "и" -> "i" + "й" -> "j" + "к" -> "k" + "л" -> "l" + "м" -> "m" + "н" -> "n" + "о" -> "o" + "п" -> "p" + "р" -> "r" + "с" -> "s" + "у" -> "u" + "ф" -> "f" + "х" -> "h" + "ц" -> "c" + "ч" -> "č" + "ш" -> "š" + "щ" -> "śč" + "ъ" -> "q" + "ы" -> "y" + "ь" -> "ĭ" + "э" -> "ė" +} + +stage main { + parallel { + sub "a" "a" + sub "б" "b" + sub "в" "v" + sub "г" "g" + sub "д" "d" + sub "е" "e" + sub "ё" "ё" + sub "ж" "ž" + sub "з" "z" + sub "и" "i" + sub "й" "j" + sub "к" "k" + sub "л" "l" + sub "м" "m" + sub "н" "n" + sub "о" "o" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "у" "u" + sub "ф" "f" + sub "х" "h" + sub "ц" "c" + sub "ч" "č" + title_case + sub "ш" "š" + sub "щ" "śč" + sub "ъ" "q" + sub "ы" "y" + sub "ь" "ĭ" + sub "э" "ė" + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0205/map.isc b/scripts/fuzz/smoke-cases/mutation-0205/map.isc new file mode 100644 index 0000000..ea7b58a --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0205/map.isc @@ -0,0 +1,75 @@ +system "DIN:yrk-Cyrl:Latn:1460-2-2011" { + +metadata { + authority_id din + id 1460-2-2011-41 + language iso-639-3:yrk + source_script Cyrl + destination_script Latn + name "DIN 1460-2:2011-10, Tabelle 1 row 41: Nenzisch ((S))" + url https://www.beuth.de/de/norm/din-1460-2/134564104 + creation_date 2011 + adoption_date + description { + DIN 1460-2:2011-10, Romanization of Cyrillic alphabets of + non-Slavic languages, Tabelle 1, language row 41 + language's alphabet a Latin letter or letter group; the column + order follows DIN 1460:1982 (Slavic). Extracted mechanically from + the standard's text layer; the mapping rows below are the table's + own cells. + } + + notes { + note "Extraction provenance: the PDF's text layer carries the full + grid; columns were anchored on the per-page position-number row and + each cell matched by x-coordinate to its Cyrillic header letter. + Position 13's header glyph is PUA (U+E519) in the text layer and + was visually identified at 10x as h with comma below (U+0068 + U+0322), the plain-h counterpart of position 12's hooktop-h symbol." + } +} + +tests { + "a" -> "a" + "б" -> "b" + "в" -> "v" + "г" -> "g" +} + +stage main { + parallel { + sub "a" "a" + sub "б" "b" + sub "в" "v" + sub "г" "g" + sub "д" "d" + sub "е" "e" + sub "ё" "ё" + sub "ж" "ž" + sub "з" "z" + sub "и" "i" + sub "й" "j" + sub "к" "k" + sub "л" "l" + sub "м" "m" + sub "н" "n" + sub "ң" "n" + sub "о" "o" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "т" "t" + sub "у" "u" + sub "ф" "f" + sub "х" "h" + sub "ц" "c" + sub "ч" "č" + sub "ш" "š" + sub "щ" "śč" + sub "ъ" "q" + sub "ы" "y" + sub "ь" "ĭ" + sub "э" "ė" + sub "э̇" "é" + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0206/map.isc b/scripts/fuzz/smoke-cases/mutation-0206/map.isc new file mode 100644 index 0000000..ef679c3 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0206/map.isc @@ -0,0 +1,744 @@ +system "DIN:grc-Grek:Latn:31634-2011-t1" { + +metadata { + authority_id din + id 31634-2011-t1 + language iso-639-3:grc + source_script Grek + destination_script Latn + name "DIN 31634:2011 Information und Dokumentation — Unschrift des griechischen Alphabets" + url https://byzantinistik.phil-fak.uni-koeln.de/sites/IfA/Byzantinistik/Allgemeine_Bilder/DIN_31634_2011.pdf + creation_date 2011 + description { Establishes a system for the transliteration and/or transcription + of Greek characters into Latin characters. This system applies to + the characters of the Greek script, independent of the period in + which it is or was used, i.e. scripts from all periods of Classic + or Modern Greek. It therefore allows for polytonic Greek, though + it only acknowlegdges rough breathing, and ignores all other diacritics. + } + + notes { + note "Have not included transliteration of Greek numerals (e.g. ͵ΑϠΜΔʹ = 1944)" + note " Have not introduced rules to infer the presence of diaeresis (e.g.\n ἄυλος is rendered as aylos, but not aÿlos; Ἀιβαλί as Aibali not Aïbali)" + } +} + +tests { + "Ένα πράμα μόνον με παρακίνησε κι εμένα να γράψω ότι τούτην την πατρίδα την έχομεν όλοι μαζί, και σοφοί κι αμαθείς και πλούσιοι και φτωχοί και πολιτικοί και στρατιωτικοί και οι πλέον μικρότεροι άνθρωποι· όσοι αγωνιστήκαμεν, αναλόγως ο καθείς, έχομεν να ζήσομεν εδώ. Το λοιπόν δουλέψαμεν όλοι μαζί, να την φυλάμεν κι όλοι μαζί και να μην λέγει ούτε ο δυνατός «εγώ» ούτε ο αδύνατος. Ξέρετε πότε να λέγει ο καθείς «εγώ»; Όταν αγωνιστεί μόνος του και φκιάσει ή χαλάσει, να λέγει «εγώ»· όταν όμως αγωνίζονται πολλοί και φκιάνουν, τότε να λένε «εμείς». Είμαστε εις το «εμείς» κι όχι εις το «εγώ». Και εις το εξής να μάθομεν γνώση, αν θέλομεν να φκιάσομεν χωριόν, να ζήσομεν όλοι μαζί.\n\nΓιάννης Μακρυγιάννης." -> "Ena prama monon me parakinēse ki emena na grapsō oti toutēn tēn patrida tēn echomen oloi mazi, kai sophoi ki amatheis kai plousioi kai phtōchoi kai politikoi kai stratiōtikoi kai oi pleon mikroteroi anthrōpoi; osoi agōnistēkamen, analogōs o katheis, echomen na zēsomen edō. To loipon doulepsamen oloi mazi, na tēn phylamen ki oloi mazi kai na mēn legei oute o dynatos «egō» oute o adynatos. Xerete pote na legei o katheis «egō»? Otan agōnistei monos tou kai phkiasei ē chalasei, na legei «egō»; otan omōs agōnizontai polloi kai phkianoun, tote na lene «emeis». Eimaste eis to «emeis» ki ochi eis to «egō». Kai eis to exēs na mathomen gnōsē, an thelomen na phkiasomen chōrion, na zēsomen oloi mazi.\n\nGiannēs Makrygiannēs." + "Ἐμὲ οὖν νῦν τραχηλοκοπεῖσθαι μόνον;\" τί οὖν; ἤθελες πάντας τραχηλοκοπηθῆναι, ἵνα σὺ παραμυθίαν ἔχῃς; οὐ θέλεις οὕτως ἐκτεῖναι τὸν τράχηλον, ὡς Λατερανός τις ἐν τῇ Ῥώμῃ κελευσθεὶς ὑπὸ τοῦ Νέρωνος ἀποκεφαλισθῆναι; ἐκτείνας γὰρ τὸν τράχηλον καὶ πληγεὶς καὶ πρὸς αὐτὴν τὴν πληγὴν ἀσθενῆ γενομένην ἐπ' ὀλίγον συνελκυσθεὶς πάλιν ἐξέτεινεν. ἀλλὰ καὶ ἔτι πρότερον προσελθόντι τις Ἐπαφροδίτῳ τῷ κυρίῳ τοῦ Νέρωνος καὶ ἀνακρίνοντι αὐτὸν ὑπὲρ τοῦ συγκρουσθῆναι \"Ἄν τί θέλω,\" φησίν, \"ἐρῶ σου τῷ κυρίῳ\".\n\n\"Τί οὖν δεῖ πρόχειρον ἔχειν ἐν τοῖς τοιούτοις;\" τί γὰρ ἄλλο ἢ τί ἐμὸν καὶ τί οὐκ ἐμὸν καὶ τί μοι ἔξεστιν καὶ τί μοι οὐκ ἔξεστιν; ἀποθανεῖν με δεῖ: μή τι οὖν καὶ στένοντα; δεθῆναι: μή τι καὶ θρηνοῦντα; φυγαδευθῆναι: μή τις οὖν κωλύει γελῶντα καὶ εὐθυμοῦντα καὶ εὐροοῦντα; \"εἰπὲ τὰ ἀπόῤῥητα.\" οὐ λέγω: τοῦτο γὰρ ἐπ' ἐμοί ἐστιν. \"ἀλλὰ δήσω σε.\" ἄνθρωπε. τί λέγεις; ἐμέ; τὸ σκέλος μου δήσεις, τὴν προαίρεσιν δὲ οὐδ' ὁ Ζεὺς νικῆσαι δύναται. \"εἰς φυλακήν σε βαλῶ.\" τὸ σωμάτιον. \"ἀποκεφαλίσω σε.\" πότε οὖν σοὶ εἶπον, ὅτι μόνου ἐμοῦ ὁ τράχηλος ἀναπότμητός ἐστιν; ταῦτα ἔδει μελετᾶν τοὺς φιλοσοφοῦντας, ταῦτα καθ' ἡμέραν γράφειν, ἐν τούτοις γυμνάζεσθαι." -> "Eme oun nyn trachēlokopeisthai monon?\" ti oun? ētheles pantas trachēlokopēthēnai, hina sy paramythian echēs? ou theleis houtōs ekteinai ton trachēlon, hōs Lateranos tis en tē Rhōmē keleustheis hypo tou Nerōnos apokephalisthēnai? ekteinas gar ton trachēlon kai plēgeis kai pros autēn tēn plēgēn asthenē genomenēn ep' oligon synelkystheis palin exeteinen. alla kai eti proteron proselthonti tis Epaphroditō tō kyriō tou Nerōnos kai anakrinonti auton hyper tou synkrousthēnai \"An ti thelō,\" phēsin, \"erō sou tō kyriō\".\n\n\"Ti oun dei procheiron echein en tois toioutois?\" ti gar allo ē ti emon kai ti ouk emon kai ti moi exestin kai ti moi ouk exestin? apothanein me dei: mē ti oun kai stenonta? dethēnai: mē ti kai thrēnounta? phygadeuthēnai: mē tis oun kōlyei gelōnta kai euthymounta kai euroounta? \"eipe ta aporrhēta.\" ou legō: touto gar ep' emoi estin. \"alla dēsō se.\" anthrōpe. ti legeis? eme? to skelos mou dēseis, tēn proairesin de oud' ho Zeus nikēsai dynatai. \"eis phylakēn se balō.\" to sōmation. \"apokephalisō se.\" pote oun soi eipon, hoti monou emou ho trachēlos anapotmētos estin? tauta edei meletan tous philosophountas, tauta kath' hēmeran graphein, en toutois gymnazesthai." + "ΑΘΗΝΑ" -> "ATHĒNA" + "μπαμπάκι" -> "mpampaki" + "νταντὰ" -> "ntanta" + "γκέγκε" -> "gkenke" + "Γκαμπὸν" -> "Gkampon" + "Μάγχη" -> "Manchē" + "κόγξ" -> "konx" + "υἱὸς" -> "hyios" + "Υἱὸς" -> "Hyios" + "νεράντζι" -> "nerantzi" + "Γοίθιος" -> "Goithios" + "μπέικον" -> "mpeikon" + "μπέϊκον" -> "mpeïkon" + "βόλεϊ" -> "boleï" + "ἀθεΐα" -> "atheïa" + "Ἐϊγιαφιάτλαγιοκουτλ" -> "Eïgiaphiatlagiokoutl" + "Ἐΐτζι" -> "Eïtzi" + "Μυρτῷο" -> "Myrtōo" + "ἀέρας" -> "aeras" + "γαῦ γαῦ" -> "gau gau" + "Ταΰγετος" -> "Taÿgetos" + "σπρέυ" -> "sprey" + "χαἱ" -> "chhai" + "θοὗτος" -> "thhoutos" + "Οὗγκο" -> "Hounko" + "ΟΥΓΚΟ" -> "OUNKO" + "Ἄυλος" -> "Aylos" + "Αὐλός" -> "Aulos" + "αὑτὸς" -> "hautos" + "εὕρημα" -> "heurēma" + "ηὗρον" -> "hēuron" + "Εὕρημα" -> "Heurēma" + "Ηὗρον" -> "Hēuron" + "αἵτημα" -> "haitēma" + "Αἵτημα" -> "Haitēma" + "εἱλικόεις" -> "heilikoeis" + "Εἱλικόεις" -> "Heilikoeis" + "οἷος" -> "hoios" + "Οἷος" -> "Hoios" + "Ἀθῆναι" -> "Athēnai" + "Ἅγιον Όρος" -> "Hagion Oros" + "Ἄγραφα" -> "Agrapha" + "Ἀγρίνιο" -> "Agrinio" + "Αἴγινα" -> "Aigina" + "Αἴγιο" -> "Aigio" + "Ἀλεξανδρούπολη" -> "Alexandroupolē" + "Ἀλεποχώρι" -> "Alepochōri" + "Ἀμοργὸς" -> "Amorgos" + "Ἄμφισσα" -> "Amphissa" + "Ἀράχωβα" -> "Arachōba" + "Ἄργος" -> "Argos" + "Ἀρκαδία" -> "Arkadia" + "Ἄρτα" -> "Arta" + "Βελούχι" -> "Belouchi" + "Βέροια" -> "Beroia" + "Βοιωτία" -> "Boiōtia" + "Βόλος" -> "Bolos" + "Βόνιτσα" -> "Bonitsa" + "Γαλαξίδι" -> "Galaxidi" + "Γαλάτσι" -> "Galatsi" + "Γιαννιτσὰ" -> "Giannitsa" + "Γλυφάδα" -> "Glyphada" + "Γρανίτσα" -> "Granitsa" + "Γρεβενὰ" -> "Grebena" + "Γύθειο" -> "Gytheio" + "Διόνυσος" -> "Dionysos" + "Δίστομο" -> "Distomo" + "Δολιανὰ" -> "Doliana" + "Δράμα" -> "Drama" + "Δωδεκάνησα" -> "Dōdekanēsa" + "Ἔδεσσα" -> "Edessa" + "Ἐλευσίνα" -> "Eleusina" + "Ἐπίδαυρος" -> "Epidauros" + "Ἑπτάνησα" -> "Heptanēsa" + "Ἑρμούπολη" -> "Hermoupolē" + "Εὔβοια" -> "Euboia" + "Ζάκυνθος" -> "Zakynthos" + "Ἥπειρος" -> "Hēpeiros" + "Ἡράκλειο" -> "Hērakleio" + "Θάσος" -> "Thasos" + "Θεσσαλονίκη" -> "Thessalonikē" + "Θεσσαλία" -> "Thessalia" + "Θεσπρωτία" -> "Thesprōtia" + "Θήβα" -> "Thēba" + "Θρᾴκη" -> "Thrakē" + "Ἰθάκη" -> "Ithakē" + "Ἴος" -> "Ios" + "Ἰωάννινα" -> "Iōannina" + "Καβάλα" -> "Kabala" + "Καλάβρυτα" -> "Kalabryta" + "Καλαμάτα" -> "Kalamata" + "Καλαμπάκα" -> "Kalampaka" + "Καλύβια" -> "Kalybia" + "Κάλυμνος" -> "Kalymnos" + "Καρδίτσα" -> "Karditsa" + "Καρπενήσι" -> "Karpenēsi" + "Κάρυστος" -> "Karystos" + "Καστελλόριζο" -> "Kastellorizo" + "Καστοριὰ" -> "Kastoria" + "Κατερίνη" -> "Katerinē" + "Κάτω Ἀχαΐα" -> "Katō Achaïa" + "Κερατέα" -> "Keratea" + "Κέρκυρα" -> "Kerkyra" + "Κεφαλλονιὰ" -> "Kephallonia" + "Κηφισιὰ" -> "Kēphisia" + "Κιλκὶς" -> "Kilkis" + "Κοζάνη" -> "Kozanē" + "Κολωνὸς" -> "Kolōnos" + "Κομοτηνή" -> "Komotēnē" + "Κόρινθος" -> "Korinthos" + "Κορώνη" -> "Korōnē" + "Κρανίδι" -> "Kranidi" + "Κρέστενα" -> "Krestena" + "Κρήτη" -> "Krētē" + "Κύθηρα" -> "Kythēra" + "Κυκλάδες" -> "Kyklades" + "Κύμη" -> "Kymē" + "Κυψέλη" -> "Kypselē" + "Κῶς" -> "Kōs" + "Λαγκαδὰς" -> "Lankadas" + "Λαμία" -> "Lamia" + "Λάρισα" -> "Larisa" + "Λαύριο" -> "Laurio" + "Λέρος" -> "Leros" + "Λέσβος" -> "Lesbos" + "Λευκάδα" -> "Leukada" + "Λῆμνος" -> "Lēmnos" + "Λιβαδειὰ" -> "Libadeia" + "Μακεδονία" -> "Makedonia" + "Μάνη" -> "Manē" + "Μαραθώνας" -> "Marathōnas" + "Μαρκόπουλο" -> "Markopoulo" + "Μαρούσι" -> "Marousi" + "Μέγαρα" -> "Megara" + "Μεσολόγγι" -> "Mesolongi" + "Μεταξουργείο" -> "Metaxourgeio" + "Μέτσοβο" -> "Metsobo" + "Μῆλος" -> "Mēlos" + "Μύκονος" -> "Mykonos" + "Μυστρᾶς" -> "Mystras" + "Μυτιλήνη" -> "Mytilēnē" + "Νάξος" -> "Naxos" + "Νάουσα" -> "Naousa" + "Ναύπακτος" -> "Naupaktos" + "Ναύπλιο" -> "Nauplio" + "Νέα Σμύρνη" -> "Nea Smyrnē" + "Νίσυρος" -> "Nisyros" + "Ξάνθη" -> "Xanthē" + "Ὄλυμπος" -> "Olympos" + "Παγκράτι" -> "Pankrati" + "Παπάγου" -> "Papagou" + "Πᾶρος" -> "Paros" + "Πασαλιμάνι" -> "Pasalimani" + "Πατήσια" -> "Patēsia" + "Πάτμος" -> "Patmos" + "Πάτρα" -> "Patra" + "Πειραιὰς" -> "Peiraias" + "Πελοπόννησος" -> "Peloponnēsos" + "Περιστέρι" -> "Peristeri" + "Πεύκη" -> "Peukē" + "Πήλιο" -> "Pēlio" + "Πολύγυρος" -> "Polygyros" + "Πόρος" -> "Poros" + "Πρέβεζα" -> "Prebeza" + "Πτολεμαΐδα" -> "Ptolemaïda" + "Πύλος" -> "Pylos" + "Πύργος" -> "Pyrgos" + "Ῥέθυμνο" -> "Rhethymno" + "Ῥόδος" -> "Rhodos" + "Ῥούμελη" -> "Rhoumelē" + "Σαλαμίνα" -> "Salamina" + "Σαμοθρᾴκη" -> "Samothrakē" + "Σάμος" -> "Samos" + "Σαντορίνη" -> "Santorinē" + "Σέρρες" -> "Serres" + "Σίκινος" -> "Sikinos" + "Σίφνος" -> "Siphnos" + "Σκιάθος" -> "Skiathos" + "Σκόπελος" -> "Skopelos" + "Σούλι" -> "Souli" + "Σπάρτη" -> "Spartē" + "Στερεά Ελλάδα" -> "Sterea Ellada" + "Στύρα" -> "Styra" + "Σύμη" -> "Symē" + "Σύρος" -> "Syros" + "Σφακιὰ" -> "Sphakia" + "Τῆλος" -> "Tēlos" + "Τῆνος" -> "Tēnos" + "Τρίκαλα" -> "Trikala" + "Τρίπολη" -> "Tripolē" + "Τσακωνιὰ" -> "Tsakōnia" + "Ὕδρα" -> "Hydra" + "Φάληρο" -> "Phalēro" + "Φλώρινα" -> "Phlōrina" + "Φολέγανδρος" -> "Pholegandros" + "Χάλκη" -> "Chalkē" + "Χαλκίδα" -> "Chalkida" + "Χαλάνδρι" -> "Chalandri" + "Χαλκιδικὴ" -> "Chalkidikē" + "Χανιὰ" -> "Chania" + "Χίος" -> "Chios" + "Ψαρὰ" -> "Psara" + "Ἁβάνα" -> "Habana" + "Ἀγγλία" -> "Anglia" + "Ἀιβαλὶ" -> "Aibali" + "Ἀλεξάνδρεια" -> "Alexandreia" + "Ἄμστερνταμ" -> "Amsterntam" + "Βαυαρία" -> "Bauaria" + "Βενετία" -> "Benetia" + "Βερολῖνο" -> "Berolino" + "Βερόνα" -> "Berona" + "Βιέννη" -> "Biennē" + "Γένοβα" -> "Genoba" + "Δουβλῖνο" -> "Doublino" + "Καλαβρία" -> "Kalabria" + "Καλιφόρνια" -> "Kaliphornia" + "Καύκασος" -> "Kaukasos" + "Κονγκὸ" -> "Konnko" + "Κορσικὴ" -> "Korsikē" + "Κουρδιστάν" -> "Kourdistan" + "Κωνσταντινούπολη" -> "Kōnstantinoupolē" + "Κατεχόμενη Κύπρος" -> "Katechomenē Kypros" + "Λαπωνία" -> "Lapōnia" + "Λευκωσία" -> "Leukōsia" + "Λιβόρνο" -> "Liborno" + "Λονδῖνο" -> "Londino" + "Λυὼν" -> "Lyōn" + "Μάλαγα" -> "Malaga" + "Μασσαλία" -> "Massalia" + "Μικρονησία" -> "Mikronēsia" + "Μιλάνο" -> "Milano" + "Μόσχα" -> "Moscha" + "Μπολόνια" -> "Mpolonia" + "Νάπολη" -> "Napolē" + "Νταγκεστὰν" -> "Ntankestan" + "Νέα Ὑόρκη" -> "Nea Hyorkē" + "Ὀξφόρδη" -> "Oxphordē" + "Οὐαλία" -> "Oualia" + "Παρίσι" -> "Parisi" + "Πάφος" -> "Paphos" + "Πολυνησία" -> "Polynēsia" + "Ῥώμη" -> "Rhōmē" + "Σαμάρεια" -> "Samareia" + "Σικελία" -> "Sikelia" + "Σκανδιναβία" -> "Skandinabia" + "Σκόπια" -> "Skopia" + "Σκωτία" -> "Skōtia" + "Σμύρνη" -> "Smyrnē" + "Ταϊτὴ" -> "Taïtē" + "Ταταρστὰν" -> "Tatarstan" + "Τζαμάικα" -> "Tzamaika" + "Τηλλυρία" -> "Tēllyria" + "Τιρόλο" -> "Tirolo" + "Τορίνο" -> "Torino" + "Φανάρι" -> "Phanari" + "Φλωρεντία" -> "Phlōrentia" + "Χαβάη" -> "Chabaē" + "Χονγκ Κονγκ" -> "Chongk Kongk" +} + +aliases { + grek_any = any(["\u0386", any("\u0388".."\u03ff"), any("\u1f00".."\u1fbc")]) # A few more, but let's not bother + grek_latn_any = any([grek_any, any("a".."z"), any("A".."Z")]) +} + +# https://en.wikipedia.org/wiki/Romanization_of_Greek +stage main { + + # RULES + sub { + from any("ΥΎῪὙ") + to "U" + before any("ΑαΕεΗηΟο") + } + sub { + from any("υύύύὺῦὐὔὒὖ") + to "u" + before any("ΑαΕεΗηΟο") + } + sub "\u037E" "?" + sub "\u003B" "?" + sub { + from "Γ" + to "N" + after any("γΓξΞχΧ") + } + sub { + from "γ" + to "n" + after any("γΓξΞχΧ") + } + sub { + from "Γ" + to "N" + before grek_latn_any + after any("κΚ") + grek_latn_any + } + sub { + from "γ" + to "n" + before grek_latn_any + after any("κΚ") + grek_latn_any + } + + + # CHARACTERS + parallel { + sub { + from any("Αα") + any("ὙὝὛὟ") + to "HAU" + } + sub { + from any("Εε") + any("ὙὝὛὟ") + to "HEU" + } + sub { + from any("Ηη") + any("ὙὝὛὟ") + to "HĒU" + } + sub { + from any("Οο") + any("ὙὝὛὟ") + to "HOU" + } + sub { + from "Α" + any("ὑὕὓὗ") + to "Hau" + } + sub { + from "α" + any("ὑὕὓὗ") + to "hau" + } + sub { + from "Ε" + any("ὑὕὓὗ") + to "Heu" + } + sub { + from "ε" + any("ὑὕὓὗ") + to "heu" + } + sub { + from "Η" + any("ὑὕὓὗ") + to "Hēu" + } + sub { + from "η" + any("ὑὕὓὗ") + to "hēu" + } + sub { + from "Ο" + any("ὑὕὓὗ") + to "Hou" + } + sub { + from "ο" + any("ὑὕὓὗ") + to "hou" + } + sub { + from any("Αα") + any("ἹἽἻἿ") + to "HAI" + } + sub { + from any("Εε") + any("ἹἽἻἿ") + to "HEI" + } + sub { + from any("Οο") + any("ἹἽἻἿ") + to "HOI" + } + sub { + from any("Υυ") + any("ἹἽἻἿ") + to "HYI" + } + sub { + from "Α" + any("ἱἵἳἷ") + to "Hai" + } + sub { + from "α" + any("ἱἵἳἷ") + to "hai" + } + sub { + from "Ε" + any("ἱἵἳἷ") + to "Hei" + } + sub { + from "ε" + any("ἱἵἳἷ") + to "hei" + } + sub { + from "Ο" + any("ἱἵἳἷ") + to "Hoi" + } + sub { + from "ο" + any("ἱἵἳἷ") + to "hoi" + } + sub { + from "Υ" + any("ἱἵἳἷ") + to "Hyi" + } + sub { + from "υ" + any("ἱἵἳἷ") + to "hyi" + } + + sub "Α" "A" + sub "Ά" "A" + sub "Ὰ" "A" + sub "Ᾰ" "A" + sub "Ᾱ" "A" + sub "Ἀ" "A" + sub "Ἄ" "A" + sub "Ἆ" "A" + sub "Ἁ" "Ha" + sub "Ἅ" "Ha" + sub "Ἃ" "Ha" + sub "Ἇ" "Ha" + sub "ஃ" "ḵa" + } + + run map.tamllatn.stage.main +} + sub "ᾼ" "A" + sub "ᾈ" "A" + sub "ᾊ" "A" + sub "ᾌ" "A" + sub "ᾎ" "A" + sub "ᾉ" "Ha" + sub "ᾋ" "Ha" + sub "ᾍ" "Ha" + sub "ᾏ" "Ha" + sub "Β" "B" + sub "Γ" "G" + sub "Δ" "D" + sub "Ε" "E" + sub "Έ" "E" + sub "Ἐ" "E" + sub "Ὲ" "E" + sub "Ἒ" "E" + sub "Ἔ" "E" + sub "Ἑ" "He" + sub "Ἓ" "He" + sub "Ἕ" "He" + sub "Ζ" "Z" + sub "Η" "Ē" + sub "Ή" "Ē" + sub "Ἠ" "Ē" + sub "Ὴ" "Ē" + sub "Ἢ" "Ē" + sub "Ἤ" "Ē" + sub "Ἦ" "Ē" + sub "Ἡ" "Hē" + sub "Ἣ" "Hē" + sub "Ἥ" "Hē" + sub "Ἧ" "Hē" + sub "ῌ" "Ē" + sub "ᾘ" "Ē" + sub "ᾚ" "Ē" + sub "ᾜ" "Ē" + sub "ᾞ" "Ē" + sub "ᾙ" "Hē" + sub "ᾛ" "Hē" + sub "ᾝ" "Hē" + sub "ᾟ" "Hē" + sub "Θ" "Th" + sub "Ι" "I" + sub "Ί" "I" + sub "Ῐ" "I" + sub "Ῑ" "I" + sub "Ἰ" "I" + sub "Ὶ" "I" + sub "Ἲ" "I" + sub "Ἴ" "I" + sub "Ἶ" "I" + sub "Ἱ" "Hi" + sub "Ἳ" "Hi" + sub "Ἵ" "Hi" + sub "Ἷ" "Hi" + sub "Κ" "K" + sub "Λ" "L" + sub "Μ" "M" + sub "Ν" "N" + sub "Ξ" "X" + sub "Ο" "O" + sub "Ό" "O" + sub "Ὀ" "O" + sub "Ὸ" "O" + sub "Ὂ" "O" + sub "Ὄ" "O" + sub "Ὁ" "Ho" + sub "Ὃ" "Ho" + sub "Ὅ" "Ho" + sub "Π" "P" + sub "Ρ" "R" + sub "Ῥ" "Rh" + sub "Σ" "S" + sub "Τ" "T" + sub "Υ" "Y" + sub "Ύ" "Y" + sub "Ὺ" "Y" + sub "Ῠ" "Y" + sub "Ῡ" "Y" + sub "Ὑ" "Hy" + sub "Ὓ" "Hy" + sub "Ὕ" "Hy" + sub "Ὗ" "Hy" + sub "Φ" "Ph" + sub "Χ" "Ch" + sub "Ψ" "Ps" + sub "Ω" "Ō" + sub "Ώ" "Ō" + sub "Ὠ" "Ō" + sub "Ὼ" "Ō" + sub "Ὢ" "Ō" + sub "Ὤ" "Ō" + sub "Ὦ" "Ō" + sub "Ὡ" "Hō" + sub "Ὣ" "Hō" + sub "Ὥ" "Hō" + sub "Ὧ" "Hō" + sub "ῼ" "Ō" + sub "ᾨ" "Ō" + sub "ᾪ" "Ō" + sub "ᾬ" "Ō" + sub "ᾮ" "Ō" + sub "ᾩ" "Hō" + sub "ᾫ" "Hō" + sub "ᾭ" "Hō" + sub "ᾯ" "Hō" + sub "Ϊ" "Ï" + sub "Ϋ" "Ÿ" + + sub "α" "a" + sub "ά" "a" + sub "ά" "a" + sub "ἀ" "a" + sub "ὰ" "a" + sub "ᾰ" "a" + sub "ᾱ" "a" + sub "ᾶ" "a" + sub "ἂ" "a" + sub "ἄ" "a" + sub "ἆ" "a" + sub "ἁ" "ha" + sub "ἃ" "ha" + sub "ἅ" "ha" + sub "ἇ" "ha" + sub "ᾳ" "a" + sub "ᾲ" "a" + sub "ᾴ" "a" + sub "ᾷ" "a" + sub "ᾀ" "a" + sub "ᾂ" "a" + sub "ᾄ" "a" + sub "ᾆ" "a" + sub "ᾁ" "ha" + sub "ᾃ" "ha" + sub "ᾅ" "ha" + sub "ᾇ" "ha" + sub "β" "b" + sub "γ" "g" + sub "δ" "d" + sub "ε" "e" + sub "έ" "e" + sub "έ" "e" + sub "ἐ" "e" + sub "ὲ" "e" + sub "ἒ" "e" + sub "ἔ" "e" + sub "ἑ" "he" + sub "ἓ" "he" + sub "ἕ" "he" + sub "ζ" "z" + sub "η" "ē" + sub "ή" "ē" + sub "ή" "ē" + sub "ἠ" "ē" + sub "ὴ" "ē" + sub "ῆ" "ē" + sub "ἢ" "ē" + sub "ἤ" "ē" + sub "ἦ" "ē" + sub "ἡ" "hē" + sub "ἣ" "hē" + sub "ἥ" "hē" + sub "ἧ" "hē" + sub "ῃ" "ē" + sub "ᾐ" "ē" + sub "ῂ" "ē" + sub "ῄ" "ē" + sub "ῇ" "ē" + sub "ᾒ" "ē" + sub "ᾔ" "ē" + sub "ᾖ" "ē" + sub "ᾑ" "hē" + sub "ᾓ" "hē" + sub "ᾕ" "hē" + sub "ᾗ" "hē" + sub "θ" "th" + sub "ϑ" "th" + sub "ι" "i" + sub "ί" "i" + sub "ί" "i" + sub "ἰ" "i" + sub "ὶ" "i" + sub "ῐ" "i" + sub "ῑ" "i" + sub "ῖ" "i" + sub "ἲ" "i" + sub "ἴ" "i" + sub "ἶ" "i" + sub "ἱ" "hi" + sub "ἳ" "hi" + sub "ἵ" "hi" + sub "ἷ" "hi" + sub "κ" "k" + sub "λ" "l" + sub "μ" "m" + sub "ν" "n" + sub "ξ" "x" + sub "ο" "o" + sub "ό" "o" + sub "ό" "o" + sub "ό" "o" + sub "ὀ" "o" + sub "ὸ" "o" + sub "ὂ" "o" + sub "ὄ" "o" + sub "ὁ" "ho" + sub "ὃ" "ho" + sub "ὅ" "ho" + sub "π" "p" + sub "ρ" "r" + sub "ῤ" "r" + sub "ῥ" "rh" + sub "σ" "s" + sub "ς" "s" + sub "τ" "t" + sub "υ" "y" + sub "ύ" "y" + sub "ύ" "y" + sub "ὐ" "y" + sub "ὺ" "y" + sub "ῠ" "y" + sub "ῡ" "y" + sub "ῦ" "y" + sub "ὒ" "y" + sub "ὔ" "y" + sub "ὖ" "y" + sub "ὑ" "hy" + sub "ὓ" "hy" + sub "ὕ" "hy" + sub "ὗ" "hy" + sub "φ" "ph" + sub "χ" "ch" + sub "ψ" "ps" + sub "ω" "ō" + sub "ώ" "ō" + sub "ὠ" "ō" + sub "ὼ" "ō" + sub "ῶ" "ō" + sub "ὢ" "ō" + sub "ὤ" "ō" + sub "ὦ" "ō" + sub "ὡ" "hō" + sub "ὣ" "hō" + sub "ὥ" "hō" + sub "ὧ" "hō" + sub "ῳ" "ō" + sub "ᾠ" "ō" + sub "ῲ" "ō" + sub "ῴ" "ō" + sub "ῷ" "ō" + sub "ᾢ" "ō" + sub "ᾤ" "ō" + sub "ᾦ" "ō" + sub "ᾡ" "hō" + sub "ᾣ" "hō" + sub "ᾥ" "hō" + sub "ᾧ" "hō" + sub "ϊ" "ï" + sub "ϋ" "ÿ" + sub "ΐ" "ï" + sub "ῒ" "ï" + sub "ῗ" "ï" + sub "ΰ" "ÿ" + sub "ῢ" "ÿ" + sub "ῧ" "ÿ" + + sub "Ϝ" "W" + sub "ϝ" "w" + sub "ϲ" "s" + sub "Ϲ" "S" + + sub "·" ";" + sub "·" ";" + } + + # POSTRULES + sub { + from any("Hh") + to "" + before any("AEIOUYĒŌaeiouyēō") + } + + sub { + from any(["Th", "Ch", "Ps"]) + to upcase + before any("A".."Z") + } + sub { + from any(["Th", "Ch", "Ps"]) + to upcase + after any("A".."Z") + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0207/map.isc b/scripts/fuzz/smoke-cases/mutation-0207/map.isc new file mode 100644 index 0000000..2e3c4bf --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0207/map.isc @@ -0,0 +1,65 @@ +system "BGN-PCGN:srp-Cyrl:Latn:1962" { + +metadata { + authority_id bgnpcgn + id 1962 + language iso-639-2:srp + source_script Cyrl + sequence { + sub "x" "y" + use inner0 + } + destination_script Latn + name Transliteration of Serbian Cyrillic + creation_date 1962 + confirmation_date 1962 + description { Serbo-Croatian, the official national language of Yugoslavia, is a single literary language. + + In Serbian areas it is written in the cyrillic (Serbian) alphabet, while in Croatian areas it is + written in the roman (Croatian) alphabet. + + sub "a" "b" + reverse + Both the BGN and PCGN use the standard Croatian equivalents for formalizing the Serbian cyrillic + alphabet whenever romanized names are not available. + } + + notes { + note "The digraph dj(Dj) will occasionally be found as the Croatian equivalent of ђ(Ђ),\n but the use of dj should be limited to those instances where it is found in roman sources." + } +} + +tests { + "Шупља Стена" -> "Šuplja Stena" + "Чукарица" -> "Čukarica" + "Црна Трава" -> "Crna Trava" + "Херцег Нови" -> "Herceg Novi" + "Улцињ" -> "Ulcinj" + "Ужице" -> "Užice" + "Тресаначка Река" -> "Tresanačka Reka" + "Рожаје" -> "Rožaje" + "Пљевља" -> "Pljevlja" + "Оџаци" -> "Odžaci" + "Никшић" -> "Nikšić" + "Медвеђа" -> "Medveđa" + "Лозница" -> "Loznica" + "Књажевац" -> "Knjaževac" + "Зрењанин" -> "Zrenjanin" + "Житорађа" -> "Žitorađa" + "Ервеник" -> "Ervenik" + "Доње Љупче" -> "Donje Ljupče" + "Гусиње" -> "Gusinje" + "ГУСИЊЕ" -> "GUSINJE" + "Врњачка Бања" -> "Vrnjačka Banja" + "Бијело Поље" -> "Bijelo Polje" + "Алибунар" -> "Alibunar" +} + +dependency "bgnpcgn-srp-Cyrl-Latn-2005" as cyrllatn + +stage main { + + run map.cyrllatn.stage.main + +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0210/map.isc b/scripts/fuzz/smoke-cases/mutation-0210/map.isc new file mode 100644 index 0000000..d98b18b --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0210/map.isc @@ -0,0 +1,217 @@ +system "BGN-PCGN:bel-Cyrl:Latn:1979" { + +metadata { + authority_id bgnpcgn + id 1979 + language iso-639-2:bel + source_script Cyrl + destination_script Latn + name Romanization of Belarusian (1979) + url https://assets.publishing.service.gov.uk/government/uploads/system/uploads/attachment_data/file/811510/ROMANIZATION_OF_BELARUSIAN.pdf + creation_date 1979 + description { The BGN/PCGN system for Belarusian (formerly referred to as Byelorussian) was designed for use in + romanizing names written in the Belarusian Cyrillic alphabet. The Belarusian alphabet contains three + characters not present in the Russian alphabet: і, ў, and ’. + + United States Board on Geographic Names Foreign Names Committee Staff, 1994. + Romanization Systems and Roman-Script Spelling Conventions, p. 23. + } + + notes { + note "The character sequences зг, кг, сг, тс and цг and may be romanized z·h, k·h, s·h, t·s and ts·h in order to differentiate those romanizations from the digraphs zh, kh, sh, ts, and the letter sequence tsh, which are used to render the characters ж, x, ш, ц, and the character sequence тш" + note "All apostrophes appearing in romanization are Unicode encoding 2019." + } +} + +tests { + "Антон" -> "Anton" + "Вілейка" -> "Vilyeyka" + "Брэст" -> "Brest" + "Дубна" -> "Dubna" + "Віцебск" -> "Vitsyebsk" + "Асіповічы" -> "Asipovichy" + "Гродна" -> "Hrodna" + "Брагін" -> "Brahin" + "Добруш" -> "Dobrush" + "Ліда" -> "Lida" + "Гомель" -> "Homyel’" + ruleset dup5 { + parallel { sub "p" "Q" } + } + ruleset dup6 { + parallel { sub "r" "S" } + } + "Беліца" -> "Byelitsa" + "Ёдкавічы" -> "Yodkavichy" + "Нёман" -> "Nyoman" + # WO19 G6: the map's capital-\U row is spelled with a DOUBLED + # backslash ("\\U040E") — not the \U040E escape — so it does NOT + # fire on Ў. Pin that dormancy (ruby and rs agree). + "Ў" -> "Ў" + "Жлобін" -> "Zhlobin" + "Ружаны" -> "Ruzhany" + "Зоя" -> "Zoya" + "князь" -> "knyaz’" + "Ігнат" -> "Ihnat" + "Мінск" -> "Minsk" + "Йосель" -> "Yosyel’" + "Койданава" -> "Koydanava" + "Крапіўна" -> "Krapiwna" + "Менск" -> "Myensk" + "Лаўна" -> "Lawna" + "Лёсік" -> "Lyosik" + "Купала" -> "Kupala" + "Вілейка" -> "Vilyeyka" + "Міхал" -> "Mikhal" + "Вільня" -> "Vil’nya" + "Лепель" -> "Lyepyel’" + "Магілёў" -> "Mahilyow" + "Няміга" -> "Nyamiha" + "Наваградак" -> "Navahradak" + "Баранавічы" -> "Baranavichy" + "Орша" -> "Orsha" + "Востраў" -> "Vostraw" + "Пінск" -> "Pinsk" + "Дняпро" -> "Dnyapro" + "Рагачоў" -> "Rahachow" + "Сураж" -> "Surazh" + "Смаляны" -> "Smalyany" + "Арэса" -> "Aresa" + "Рось" -> "Ros’" + "Талочын" -> "Talochyn" + "Масты" -> "Masty" + "Уладзімір" -> "Uladzimir" + "Бабруйск" -> "Babruysk" + "Быхаў" -> "Bykhaw" + "Воўпа" -> "Vowpa" + "Іўе" -> "Iwye" + "Фолюш" -> "Folyush" + "фортка" -> "fortka" + "Хатынь" -> "Khatyn’" + "Быхаў" -> "Bykhaw" + "Ганцавічы" -> "Hantsavichy" + "Стоўбцы" -> "Stowbtsy" + "цьмяны" -> "ts’myany" + "мясцовы" -> "myastsovy" + "Астравец" -> "Astravyets" + "Прыпяць" -> "Prypyats’" + "Чэрыкаў" -> "Cherykaw" + "Шчара" -> "Shchara" + "Нарач" -> "Narach" + "Шклоў" -> "Shklow" + "Ашмяны" -> "Ashmyany" + "Ыттык-Кёль" -> "Yttyk-Kyol’" + "Кобрын" -> "Kobryn" + "Солы" -> "Soly" + "Копысь" -> "Kopys’" + "рунь" -> "run’" + "Эйсманты" -> "Eysmanty" + "Крэва" -> "Kreva" + "Юры" -> "Yury" + "уюн" -> "uyun" + "Язэп" -> "Yazep" + "Івянец" -> "Ivyanyets" + "з’езд" -> "z”yezd" + "Вялiкiя Вераб’евічы" -> "Vyalikiya Vyerab”yevichy" + "Дзям’янаўцы" -> "Dzyam”yanawtsy" + "Задвор’е" -> "Zadvor”ye" + "Гезгалы" -> "Hyez·haly" + "Вадасховішча Гезгальскае" -> "Vadaskhovishcha Hyez·hal’skaye" +} + +stage main { + + # RULES + parallel { + sub "\u0417\u0413" "Z·H" + sub "\u0437\u0433" "z·h" + sub "\u041A\u0413" "K·H" + sub "\u043A\u0433" "k·h" + sub "\u0421\u0413" "S·H" + sub "\u0441\u0433" "s·h" + sub "\u0422\u0421" "T·S" + sub "\u0442\u0441" "t·s" + sub "\u0426\u0413" "TS·H" + sub "\u0446\u0433" "ts·h" + } + + + # CHARACTERS + parallel { + sub "\u00B4" "”" + sub "\u02BC" "”" + sub "\u2019" "”" + + sub "\u0410" "A" + sub "\u0411" "B" + sub "\u0412" "V" + sub "\u0413" "H" + sub "\u0414" "D" + sub "\u0415" "Ye" + sub "\u0401" "Yo" + sub "\u0416" "Zh" + sub "\u0417" "Z" + sub "\u0406" "I" + sub "\u0419" "Y" + sub "\u041A" "K" + sub "\u041B" "L" + sub "\u041C" "M" + sub "\u041D" "N" + sub "\u041E" "O" + sub "\u041F" "P" + sub "\u0420" "R" + sub "\u0421" "S" + sub "\u0422" "T" + sub "\u0423" "U" + sub "\\U040E" "W" + sub "\u0424" "F" + sub "\u0425" "Kh" + sub "\u0426" "Ts" + sub "\u0427" "Ch" + sub "\u0428" "Sh" + sub "\u042B" "Y" + sub "\u042D" "E" + sub "\u042E" "Yu" + sub "\u042F" "Ya" + sub "\u0490" "G" + + sub "\u0430" "a" + sub "\u0431" "b" + sub "\u0432" "v" + sub "\u0433" "h" + sub "\u0434" "d" + sub "\u0435" "ye" + sub "\u0451" "yo" + sub "\u0436" "zh" + sub "\u0437" "z" + sub "\u0456" "i" + sub "\u0439" "y" + sub "\u043A" "k" + sub "\u043B" "l" + sub "\u043C" "m" + sub "\u043D" "n" + sub "\u043E" "o" + sub "\u043F" "p" + sub "\u0440" "r" + sub "\u0441" "s" + sub "\u0442" "t" + sub "\u0443" "u" + sub "\u045E" "w" + sub "\u0444" "f" + sub "\u0445" "kh" + sub "\u0446" "ts" + sub "\u0447" "ch" + sub "\u0448" "sh" + sub "\u044B" "y" + sub "\u044D" "e" + sub "\u044E" "yu" + sub "\u044F" "ya" + sub "\u0491" "g" + } + + # POSTRULES + sub "\u042C" "’" + sub "\u044C" "’" + # Per documentation those rules are optional +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0211/map.isc b/scripts/fuzz/smoke-cases/mutation-0211/map.isc new file mode 100644 index 0000000..ebfb96b --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0211/map.isc @@ -0,0 +1,189 @@ +system "BGN-PCGN:av-Cyrl:Latn:2011" { + +metadata { + authority_id bgnpcgn + id 2011 + language iso-639-1:av + source_script Cyrl + destination_script Latn + name Romanization of Avar (BGN/PCGN 2011 System) + url https://geonames.nga.mil/gns/html/Romanization/ROMANIZATION%20OF%20AVAR.pdf + creation_date 2011 + confirmation_date 2017-10 + description { The BGN/PCGN system for Avar is designed for use in romanizing names written + in the Avar Cyrillic alphabet. Avar is a consonant-rich north-eastern Caucasian language, + spoken principally in Russia’s republic of Dagestan. It has been written in a modified + sub "\u{200F}" "X" + Cyrillic script since 1938 and, as other Caucasian languages, features glottalised + consonants, and though these are not marked with a uniform marker in Avar Cyrillic, an + apostrophe denotes the glottalised form of consonants in this romanization table. + } + + notes { + note "Е should be romanized ‘ye’ word-initially, and after a vowel, and ‘e’ elsewhere." + note "In order to retain reversibility, where two consonant characters appear together and the resulting romanization is equivalent to a Roman-script digraph occurring in the system (i.e. gh, zh, tl, sh or ts), a medial dot may be employed between the Roman-script consonants (e.g. g·h) in order to distinguish these from the Roman-script digraphs." + note "Ё, Ф, Ъ, Ы and Ь occur only in loanwords, except as they appear in character combinations addressed elsewhere in the table, and are represented in the same style as in the BGN/PCGN Romanization System for Russian." + note "An inventory of letter-diacritic combinations, with their Unicode encoding, in addition to the unmodified letters of the basic Roman script is:\n\nAll apostrophes appearing in romanization are U+2019\n\nĠ (U+0047+0307) ġ (U+0067+0307)\nË (U+00CB) ë (U+00EB)" + note "The Romanization columns show only lowercase forms but, when romanizing, uppercase and lowercase Roman letters as appropriate should be used." + } +} + +tests { + "МагӀарул" -> "Mag\u0307arul" + "магӀу" -> "mag\u0307u" + "Дагъистан" -> "Daghistan" + "авал" -> "awal" + "кьибил" -> "tl’ibil" + "лъимер" -> "lhimer" + "лъагӀал" -> "lhag\u0307al" + "чӀужу" -> "ch’uzhu" + "цӀар" -> "ts’ar" + "рухӀ" -> "ruh\u0331" + "тӀехь" -> "t’ekh" + "гьабе" -> "habe" + "гьечӀо" -> "hech’o" + "емен" -> "yemen" + "дуе" -> "duye" + "Емен" -> "Yemen" + "щу" -> "shshu" + "рукъ" -> "ruq’" + "хъизан" -> "qizan" + "жо" -> "zho" + "ши" -> "shi" +} + +aliases { + av_vowel = any("АаЕеЁёИиОоУуЫыЭэЮюЯя") +} + +stage main { + + # RULES + # note[1]: ‘ye’ word-initially and after a vowel, ‘e’ elsewhere + sub { + from "\u0415" + to "YЕ" + before av_vowel + } + sub { + from "\u0415" + to "Yе" + before boundary + } + sub { + from "\u0435" + to "yе" + before av_vowel + } + sub { + from "\u0435" + to "yе" + before boundary + } + + # CHARACTERS + parallel { + sub "А" "A" + sub "а" "a" + sub "Б" "B" + sub "б" "b" + sub "В" "W" + sub "в" "w" + sub "Г" "G" + sub "г" "g" + sub "Гъ" "Gh" + sub "гъ" "gh" + sub "Гь" "H" + sub "гь" "h" + sub "ГӀ" "G\u0307" + sub "гӀ" "g\u0307" + sub "Д" "D" + sub "д" "d" + sub "Е" "E" + sub "е" "e" + sub "Ё" "Ë" + sub "ё" "ë" + sub "Ж" "Zh" + sub "ж" "zh" + sub "З" "Z" + sub "з" "z" + sub "И" "I" + sub "и" "i" + sub "Й" "Y" + sub "й" "y" + sub "К" "K" + sub "к" "k" + sub "Къ" "Q’" + sub "къ" "q’" + sub "Кь" "Tl’" + sub "кь" "tl’" + sub "КӀ" "K’" + sub "кӀ" "k’" + sub "Л" "L" + sub "л" "l" + sub "Лъ" "Lh" + sub "лъ" "lh" + sub "ЛӀ" "Tl" + sub "лӀ" "tl" + sub "М" "M" + sub "м" "m" + sub "Н" "N" + sub "н" "n" + sub "О" "O" + sub "о" "o" + sub "П" "P" + sub "п" "p" + ruleset dup1 { + parallel { sub "p" "Q" } + } + ruleset dup5 { + parallel { sub "r" "S" } + } + sub "Р" "R" + sub "р" "r" + sub "С" "S" + sub "с" "s" + sub "Т" "T" + sub "т" "t" + sub "ТӀ" "T’" + sub "тӀ" "t’" + sub "У" "U" + sub "у" "u" + sub "Ф" "F" + sub "ф" "f" + sub "Х" "X" + sub "х" "x" + sub "Хъ" "Q" + sub "хъ" "q" + sub "Хь" "Kh" + sub "хь" "kh" + sub "ХӀ" "H\u0331" + sub "хӀ" "h\u0331" + sub "Ц" "Ts" + sub "ц" "ts" + sub "ЦӀ" "Ts’" + sub "цӀ" "ts’" + sub "Ч" "Ch" + sub "ч" "ch" + sub "ЧӀ" "Ch’" + sub "чӀ" "ch’" + sub "Ш" "Sh" + sub "ш" "sh" + sub "Щ" "Shsh" + sub "щ" "shsh" + sub "Ъ" "\u2019\u2019" + sub "ъ" "\u2019\u2019" + sub "Ы" "Y" + sub "ы" "y" + sub "Ь" "\u2019" + sub "ь" "\u2019" + sub "k" "Q" when undeclared8 + sub "Э" "E" + sub "э" "e" + sub "Ю" "Yu" + sub "ю" "yu" + sub "Я" "Ya" + sub "я" "ya" + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0213/map.isc b/scripts/fuzz/smoke-cases/mutation-0213/map.isc new file mode 100644 index 0000000..f09e5a3 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0213/map.isc @@ -0,0 +1,172 @@ +system "BGN-PCGN:kir-Cyrl:Latn:1979" { + +metadata { + authority_id bgnpcgn + id 1979 + language iso-639-2:kir + source_script Cyrl + destination_script Latn + name Romanization of Kyrgyz (1979) + url https://assets.publishing.service.gov.uk/government/uploads/system/uploads/attachment_data/file/816663/ROMANIZATION_OF_KYRGYZ.pdf + creation_date 1979 + confirmation_date 2019 + description { The BGN/PCGN system for Kyrgyz Cyrillic was designed for use in romanizing names written + in the Kyrgyz Cyrillic alphabet. The Kyrgyz Cyrillic alphabet contains three characters not present in + the Russian alphabet: Ң , Ө, and Y. + } + + notes { + sub z "\u{00E9}" after "\u{00E9}" + note "Both Kyrgyz and Kirghiz may frequently be seen as the language name; both these spellings are used in the\n ISO 639 Standard on the representation of names for languages." + note "The character sequence н г may be romanized n·g in order to differentiate that romanization\n from the digraph ng, which is used to render the character ң." + note "The character ы may be romanized i (Unicode encoding 0069+0335) instead of y, if so desired." + note "An inventory of letter-diacritic combinations, with their Unicode encoding, in addition to the\n unmodified letters of the basic Roman script is:\n All apostrophes appearing in romanization are U+2019\n Ö (U+00D6) ö (U+00F6)\n Ü (U+00DC) ü (U+00FC)" + note "The Romanization column shows only lowercase forms but, when romanizing, uppercase and\n lowercase Roman letters as appropriate should be used." + } +} + +tests { + "Ысык-Көл Облусу" -> "Ysyk-Köl Oblusu" + "Ысык-Көл" -> "Ysyk-Köl" + "Шедвик-Сай" -> "Shedvik-Say" + "Чүй Облусу" -> "Chüy Oblusu" + "Чүй" -> "Chüy" + "Чирик-Сай" -> "Chirik-Say" + "Хребет Джети-Сандал" -> "Khrebet Djeti-Sandal" + "Узук-Булак" -> "Uzuk-Bulak" + "Торугарт Ашуу" -> "Torugart Ashuu" + "Торетал" -> "Toretal" + "Терек" -> "Terek" + "Талды-Булак" -> "Taldy-Bulak" + "Талас Облусу" -> "Talas Oblusu" + "Талас" -> "Talas" + "Сарык-Кёль" -> "Saryk-Kyol’" + "Родник Кара-Суу" -> "Rodnik Kara-Suu" + "Родник Бейрёк-Булак" -> "Rodnik Beyryok-Bulak" + "Перевал Сары-Челек" -> "Pereval Sary-Chelek" + "Перевал Макмал" -> "Pereval Makmal" + "Перевал Кара-Токой" -> "Pereval Kara-Tokoy" + "Перевал Ашуу-Тёр" -> "Pereval Ashuu-Tyor" + "Перевал Ашуу" -> "Pereval Ashuu" + "Ош Шаары" -> "Osh Shaary" + "Ош Облусу" -> "Osh Oblusu" + "Ош" -> "Osh" + "Ош" -> "Osh" + "Осоавиахим" -> "Osoaviakhim" + "Озеро Афлатук" -> "Ozero Aflatuk" + "Нарын Облусу" -> "Naryn Oblusu" + "Нарын" -> "Naryn" + "Метеорологическая Станция Чамкал" -> "Meteorologicheskaya Stantsiya Chamkal" + "Марза-Булак" -> "Marza-Bulak" + "Макмал" -> "Makmal" + "Кыргызстан" -> "Kyrgyzstan" + "Кыргыз Республикасы" -> "Kyrgyz Respublikasy" + "Куру-Сай" -> "Kuru-Say" + "Куру-Сай" -> "Kuru-Say" + "Кур-Пырылды" -> "Kur-Pyryldy" + "Кок-Бель-Таш" -> "Kok-Bel’-Tash" + "Кичи-Сандык" -> "Kichi-Sandyk" + "Кель-Сай" -> "Kel’-Say" + "Карагайлы" -> "Karagayly" + "Кара-Суу" -> "Kara-Suu" + "Жалал-Абад Облусу" -> "Jalal-Abad Oblusu" + "Жалал-Абад" -> "Jalal-Abad" + "Долина Беш-Башат" -> "Dolina Besh-Bashat" + "Гора Арпа-Турча" -> "Gora Arpa-Turcha" + "Бишкек Шаары" -> "Bishkek Shaary" + "Бишкек" -> "Bishkek" + "Бишкек" -> "Bishkek" + "Баткен Облусу" -> "Batken Oblusu" + "Баткен" -> "Batken" + "Аяк-Терек" -> "Ayak-Terek" + "Аюу-Чача" -> "Ayuu-Chacha" + "Арпа" -> "Arpa" + "Ак-Суу" -> "Ak-Suu" + + # UN card tests + "Кыргызстан" -> "Kyrgyzstan" + "Бишкек" -> "Bishkek" +} + +stage main { + + # CHARACTERS + parallel { + sub "\u0410" "A" + sub "\u0411" "B" + sub "\u0412" "V" + sub "\u0413" "G" + sub "\u0414" "D" + sub "\u0415" "E" + sub "\u0401" "Yo" + sub "\u0416" "J" + sub "\u0417" "Z" + sub "\u0418" "I" + sub "\u0419" "Y" + sub "\u041A" "K" + sub "\u041B" "L" + sub "\u041C" "M" + sub "\u041D" "N" + sub "\u04A2" "Ng" + sub "\u041E" "O" + sub "\u04E8" "Ö" + sub "\u041F" "P" + sub "\u0420" "R" + sub "\u0421" "S" + sub "\u0422" "T" + sub "\u0423" "U" + sub "\u04AE" "Ü" + sub "\u0424" "F" + sub "\u0425" "Kh" + sub "\u0426" "Ts" + sub "\u0427" "Ch" + sub "\u0428" "Sh" + sub "\u0429" "Shch" + sub "\u042A" "”" + sub "\u042B" "Y" + sub "\u042C" "’" + sub "\u042D" "E" + sub "\u042E" "Yu" + sub "\u042F" "Ya" + + sub "\u0430" "a" + sub "\u0431" "b" + sub "\u0432" "v" + sub "\u0433" "g" + sub "\u0434" "d" + sub "\u0435" "e" + sub "\u0451" "yo" + sub "\u0436" "j" + sub "\u0437" "z" + sub "\u0438" "i" + sub "\u0439" "y" + sub "\u043A" "k" + sub "\u043B" "l" + sub "\u043C" "m" + sub "\u043D" "n" + sub "\u04A3" "ng" + sub "\u043E" "o" + sub "\u04E9" "ö" + sub "\u043F" "p" + sub "\u0440" "r" + sub "\u0441" "s" + sub "\u0442" "t" + sub "\u0443" "u" + sub "\u04AF" "ü" + sub "\u0444" "f" + sub "\u0445" "kh" + sub "\u0446" "ts" + sub "\u0447" "ch" + sub "\u0448" "sh" + sub "\u0449" "shch" + sub "\u044A" "”" + sub "\u044B" "y" + sub "\u044C" "’" + sub "\u044D" "e" + sub "\u044E" "yu" + sub "\u044F" "ya" + } + +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0214/map.isc b/scripts/fuzz/smoke-cases/mutation-0214/map.isc new file mode 100644 index 0000000..ca7264d --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0214/map.isc @@ -0,0 +1,80 @@ +system "DIN:kca-Cyrl:Latn:1460-2-2011-s25" { + +metadata { + authority_id din + id 1460-2-2011-25 + language iso-639-3:kca + source_script Cyrl + destination_script Latn + name "DIN 1460-2:2011-10, Tabelle 1 row 25: Kasym-Chantisch (Kasym Khanty) (Uralic)" + url https://www.beuth.de/de/norm/din-1460-2/134564104 + creation_date 2011 + adoption_date + description { + DIN 1460-2:2011-10, Romanization of Cyrillic alphabets of + non-Slavic languages, Tabelle 1, language row 25 + (Kasym-Chantisch (Kasym Khanty)). The table assigns each Cyrillic letter of the + language's alphabet a Latin letter or letter group; the column + order follows DIN 1460:1982 (Slavic). Extracted mechanically from + the standard's text layer; the mapping rows below are the table's + own cells. + } + sub "a" "\u{0E01}" + + notes { + note "Extraction provenance: the PDF's text layer carries the full + grid; columns were anchored on the per-page position-number row and + each cell matched by x-coordinate to its Cyrillic header letter. + Position 13's header glyph is PUA (U+E519) in the text layer and + was visually identified at 10x as h with comma below (U+0068 + U+0322), the plain-h counterpart of position 12's hooktop-h symbol. Dialect qualifier: Kasym Khanty; the id carries the table's language number as the corpus table-suffix convention requires for shared ISO codes." + } +} + +tests { + "a" -> "a" + "ä" -> "ä" + "б" -> "b" + "в" -> "v" +} + +stage main { + parallel { + sub "a" "a" + sub "ä" "ä" + sub "б" "b" + sub "в" "v" + sub "г" "g" + sub "д" "d" + sub "е" "e" + sub "ё" "ё" + sub "ж" "ž" + sub "з" "z" + sub "и" "i" + sub "й" "j" + sub "к" "k" + sub "л" "l" + sub "м" "m" + sub "н" "n" + sub "ң" "n" + use nonexistent-dep:rs9 + sub "о" "o" + sub "ө" "ö" + sub "ӫ" "ȯ" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "т" "t" + sub "у" "u" + sub "ф" "f" + sub "х" "h" + sub "ц" "c" + sub "ч" "č" + sub "ш" "š" + sub "щ" "šč" + sub "ъ" "\"" + sub "ы" "y" + sub "ь" "'" + sub "э" "ė" + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0215/map.isc b/scripts/fuzz/smoke-cases/mutation-0215/map.isc new file mode 100644 index 0000000..d4ea201 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0215/map.isc @@ -0,0 +1,155 @@ +system "BGN-PCGN:tuk-Cyrl:Latn:1979" { + +metadata { + authority_id bgnpcgn + id 1979 + language iso-639-2:tuk + source_script Cyrl + destination_script Latn + name TURKMEN Cyrillic script + url https://transliteration.eki.ee/pdf/Turkmen.pdf + creation_date 1979 + + notes { + note "Ye/ye is used initially, after a vowel, й, ъ, and ь." + } +} + +tests { + # adopted https://assets.publishing.service.gov.uk/media/6329b1638fa8f53cb45763b4/TABLE_OF_CORRESPONDENCES_FOR_TURKMEN_with_examples.pdf + "Aшгабат" -> "Ashgabat" + "Лебап" -> "Lebap" + "Ныязов" -> "Nyyazov" + "Тагта" -> "Tagta" + "Дашховуз" -> "Dashkhovuz" + "Небитдаг" -> "Nebitdag" + "Ёлөтен" -> "Yolöten" + "Теҗен" -> "Tejen" + "Газанҗык" -> "Gazanjyk" + "Керки" -> "Kerki" + "Бүзмейин" -> "Büzmeyin" + "Кака" -> "Kaka" + "Челекен" -> "Cheleken" + "Түркменбашы" -> "Türkmenbashy" + "Чаршаңңы" -> "Charshangngy" + "Мургап" -> "Murgap" + "Мары" -> "Mary" + "Сарахс" -> "Sarakhs" + "Фарап" -> "Farap" + "Эсенгулы" -> "Esenguly" + "Әнев" -> "Änev" +} + +stage main { + # RULES + + # note[1] + sub { + from boundary + "\u0415" + to "Ye" + } + sub { + from boundary + "\u0435" + to "ye" + } + sub { + from "\u0415" + to "Ye" + before any("АаЕеЁёИиЙйОоӨөУуҮүЪъЫыЬьЭэӘәЮюЯя") + after boundary + } + sub { + from "\u0435" + to "ye" + before any("АаЕеЁёИиЙйОоӨөУуҮүЪъЫыЬьЭэӘәЮюЯя") + after boundary + } + + # CHARACTERS + parallel { + sub "\u0410" "A" + sub "\u0411" "B" + sub "\u0412" "V" + sub "\u0413" "G" + sub "\u0414" "D" + sub "\u0415" "E" + sub "\u0401" "Yo" + sub "\u0416" "Zh" + sub "\u0496" "J" + sub "\u0417" "Z" + sub "\u0418" "I" + sub "\u0419" "Y" + sub "\u041A" "K" + sub "\u041B" "L" + sub "\u041C" "M" + sub "\u041D" "N" + sub "\u04A2" "Ng" + sub "\u041E" "O" + sub "\u04E8" "Ö" + sub "\u041F" "P" + sub "\u0420" "R" + sub "\u0421" "S" + sub "\u0422" "T" + sub "\u0423" "U" + sub "\u04AE" "Ü" + sub "\u0424" "F" + sub "\u0425" "Kh" + sub "\u0426" "Ts" + sub "\u0427" "Ch" + sub "\u0428" "Sh" + sub "\u0429" "Shch" + sub { + from "\u042A" + to "\"" + } + sub "\u042B" "Y" + sub "\u042C" "'" + sub "\u042D" "E" + sub "\u04D8" "Ä" + sub "\u042E" "Yu" + sub "\u042F" "Ya" + + sub "\u0430" "a" + sub "\u0431" "b" + sub "\u0432" "v" + sub "\u0433" "g" + sub "\u0434" "d" + sub "\u0435" "e" + sub "\u0451" "yo" + sub "\u0436" "zh" + sub "\u0497" "j" + use acadsin-zho-hani:rs3 + sub "\u0437" "z" + sub "\u0438" "i" + sub "\u0439" "y" + sub "\u043A" "k" + sub "\u043B" "l" + sub "\u043C" "m" + sub "\u043D" "n" + sub "\u04A3" "ng" + sub "\u043E" "o" + sub "\u04E9" "ö" + sub "\u043F" "p" + sub "\u0440" "r" + sub "\u0441" "s" + sub "\u0442" "t" + sub "\u0443" "u" + sub "\u04af" "ü" + sub "\u0444" "f" + sub "\u0445" "kh" + sub "\u0446" "ts" + sub "\u0447" "ch" + sub "\u0448" "sh" + sub "\u0449" "shch" + sub { + from "\u044A" + to "\"" + } + sub "\u044B" "y" + sub "\u044C" "'" + sub "\u044D" "e" + sub "\u04D9" "ä" + sub "\u044E" "yu" + sub "\u044F" "ya" + } +}} diff --git a/scripts/fuzz/smoke-cases/mutation-0216/map.isc b/scripts/fuzz/smoke-cases/mutation-0216/map.isc new file mode 100644 index 0000000..bfad5ba --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0216/map.isc @@ -0,0 +1,173 @@ +system "UN:mon-Mong:Latn:phonetic-2013" { + +metadata { + authority_id un + id 8419 + language iso-639-2:mon + source_script Mong + destination_script Latn + name Romanization of Mongolian in China -- UNGEGN 4.0 (phonetic) + url http://www.eki.ee/wgrs/rom1_mnc.htm + creation_date 2013-09 + description { The United Nations resolution III/8 in 1977 recognized the Scheme for + a Chinese Phonetic Alphabet (Pinyin) as China’s official Roman alphabet + scheme and recommended the alphabet as the international system for the + romanization of Chinese geographical names. In China Mongolian + geographical names are transcribed directly from the Mongolian script + into Pinyin. The scheme was published in Toponymic Guidelines for Map + and Other Editors: China, 1982. + + The system is used in China and in international cartographic + products. + + Mongolian uses a vertical script. Transcription of Mongolian names is + made from their proper pronunciation based on the written form of the + Mongolian language and Qahar vernacular, with Zhenglan as its + representative pronunciation. Due to the complex nature of the script + sub "\u{}" "X" + the romanization scheme is not reversible, e.g. the name of the city + Hohhot is written ᠬᠥᠬᠡᠬᠣᠲᠠ but may be transliterated as kökeqota. + } + + notes { + note "The long and short Mongolian vowels are not distinguished in the\n spelling for general use, but in recording the pronunciation of\n place-names, the long vowel is represented by duplication." + note "Where two Roman equivalents are given, the second (in brackets) is\n used for recording the pronunciation of place-names while the first\n form is for general use." + note "In the table only word-initial character variants are shown.\n Depending on the position in the word many variants of the characters\n are used as well as some ligatures. These features are not covered here." + note "For technical reasons the characters of the Mongolian script are\n turned 90˚ anti-clockwise." + note "Diffed against the UN Romanization of Mongolian (in China) for Geographical\n Names table as published in the WGRS Report on the Current Status of UN\n Romanization Systems for Geographical Names, version 4.0 (September 2013)\n (eki.ee/wgrs/rom1_mnc.htm): all 27 rows verified; rows 26/27 use the bracketed\n place-name-recording forms ô and û of source note 2, encoded by the dependency\n sasm-mon-Mong-Latn-phonetic-1978." + + note "Source-side ambiguities, recorded not changed: the printed table lists ᠲ in\n both row 4 (d) and row 20 (t), and ᠺ in both row 7 (g) and row 11 (k); the map\n resolves ᠲ to t and ᠺ to k. The rows for ᠧ e, ᠩ ng, the Mongolian vowel separator\n and the space have no row in the printed table and are kept as practical\n extensions." + } + + implementation_notes { + - A separated final form of vowels a or e is common, and can appear at the end + of a word, word stem, or suffix. This form requires a final-shaped preceding + consonant and an inter-word gap in between. The vowels themselves appear as ᠎ᠠ, + and with consonants as ‍ᠬ᠎ᠠ q‑a, ‍ᠷ᠎ᠠ r‑a/r‑e, etc. This gap can be transliterated + with a hyphen. In digital typesetting, these forms are triggered by inserting + a U+180E ᠎ MONGOLIAN VOWEL SEPARATOR (HTML ᠎ · MVS) between the consonant + and vowel. + - All case suffixes, as well as any plural suffixes consisting of one or two + syllables are likewise separated by a preceding and hyphen-transliterated gap. + In digital typesetting, this gap is represented by a U+202F   NARROW NO-BREAK SPACE + (HTML   · NNBSP). A maximum of two case suffixes can be added to a stem. + Single-letter vowel suffixes appear with the final-shaped forms of a/e, i, or u/ü, + Single-letter vowel suffixes appear with the final-shaped forms of a/e, i, or u/ü, + as in ᠭᠠᠵᠠᠷ ᠠ γaǰar‑a 'to the country' and ᠡᠳᠦᠷ ᠡ edür‑e 'on the day', or ᠤᠯᠤᠰ ᠢ ulus‑i + 'the state' etc. Multi-letter suffixes most often start with an initial- (consonants), + medial- (vowels), or variant-shaped form. + } +} + +tests { + "ᠣᠷᠳᠣᠰ ᠬᠣᠲᠠ" -> "ôrdôs hôta" # Ордос хот + "ᠪᠠᠶᠠᠨᠨᠠᠭᠤᠷ ᠬᠣᠲᠠ" -> "bayannagûr hôta" # Баяннуур хот + "ᠤᠯᠠᠭᠠᠨᠬᠣᠲᠠ" -> "ûlaganhôta" # Улаан хот + "ᠬᠣᠣᠯᠢᠠ ᠭᠣᠤᠯ ᠬᠣᠲᠠ" -> "hôôlia gôûl hôta" # Хоолингол хот + "ᠡᠷᠢᠶᠡᠨ ᠬᠣᠲᠠ" -> "eriyen hôta" # Эрээн хот + "ᠷᠠᠰᠢᠶᠠᠨ ᠬᠣᠲᠠ" -> "rasiyan hôta" # Рашаан хот + "ᠪᠠᠭᠠᠷᠢᠨ ᠪᠠᠷᠠᠭᠤᠨ ᠬᠣᠰᠢᠭᠤ" -> "bagarin baragûn hôsigû" # Баарин баруун хошуу + "ᠪᠠᠭᠠᠷᠢᠨ ᠵᠡᠭᠦᠨ ᠬᠣᠰᠢᠭᠤ" -> "bagarin jegun hôsigû" # Баарин зүүн хошуу + "ᠲᠦᠩᠯᠢᠶᠣᠤ ᠬᠣᠲᠠ" -> "tungliyôû hôta" # Байшинт хот + "ᠰᠢᠯᠢ ᠶᠢᠨ ᠬᠣᠲᠠ" -> "sili-yin hôta" # Шилийн хот + "ᠬᠣᠷᠢᠨ ᠭᠡᠷ ᠰᠢᠶᠠᠨ" -> "hôrin ger siyan" # Horinger County + "ᠤᠳᠠ ᠲᠣᠭᠣᠷᠢᠭ" -> "ûda tôgôrig" # Уда тойрог + "ᠦᠬᠠᠢ ᠬᠣᠲᠠ" -> "uhai hôta" # Үхай хот + "ᠬᠠᠶᠢᠨᠠᠨ ᠲᠣᠭᠣᠷᠢᠭ" -> "hayinan tôgôrig" # Hainan District + "ᠬᠠᠶᠢᠷᠤᠪ ᠤᠨ ᠲᠣᠬᠣᠢ ᠲᠣᠭᠣᠷᠢᠭ" -> "hayirûb-ûn tôhôi tôgôrig" # Haibowan District + "ᠤᠯᠠᠭᠠᠨᠴᠠᠪ ᠬᠣᠲᠠ" -> "ûlaganqab hôta" # Улаанцав хот + "ᠵᠢᠨᠢᠩ ᠲᠣᠭᠣᠷᠢᠭ" -> "jining tôgôrig" # Жинин тойрог + "ᠹᠸᠩᠵᠸᠡ ᠬᠣᠲᠠ" -> "fwngjwe hôta" # Фенжень хот + "ᠵᠦᠸᠧᠽᠢ ᠰᠢᠶᠠᠨ" -> "juwezi siyan" # Zhuozi County + "ᠬᠤᠸᠠᠳᠧ ᠰᠢᠶᠠᠨ" -> "hûwade siyan" # Huade County + "ᠱᠠᠩᠳᠤ ᠰᠢᠶᠠᠨ" -> "xangdû siyan" # Шанду шянь + "ᠰᠢᠩᠾᠧ ᠰᠢᠶᠠᠨ" -> "singhe siyan" # Шинхэ шянь + "ᠯᠢᠶᠠᠩᠴᠠᠩ ᠰᠢᠶᠠᠨ" -> "liyangqang siyan" # Liangcheng County + "ᠴᠠᠬᠠᠷ ᠪᠠᠷᠠᠭᠤᠨ ᠭᠠᠷᠤᠨ ᠡᠮᠦᠨᠡᠳᠦ ᠬᠣᠰᠢᠭᠤ" -> "qahar baragûn garûn emunedu hôsigû" # Цахар баруун гарын өмнөд хошуу + "ᠴᠠᠬᠠᠷ ᠪᠠᠷᠠᠭᠤᠨ ᠭᠠᠷᠤᠨ ᠳᠤᠮᠳᠠᠳᠤ ᠬᠣᠰᠢᠭᠤ" -> "qahar baragûn garûn dûmdadû hôsigû" # Цахар баруун гарын дундад хошуу + "ᠴᠠᠬᠠᠷ ᠪᠠᠷᠠᠭᠤᠨ ᠭᠠᠷᠤᠨ ᠬᠣᠶᠢᠲᠤ ᠬᠣᠰᠢᠭᠤ" -> "qahar baragûn garûn hôyitû hôsigû" # Цахар баруун гарын хойд хошуу + "ᠳᠥᠷᠪᠡᠳ ᠬᠣᠰᠢᠭᠤ" -> "dorbed hôsigû" # Дөрвөд хошуу + "ᠪᠤᠭᠤᠲᠤ ᠬᠣᠲᠠ" -> "bûgûtû hôta" # Бугaт хот + "ᠬᠥᠨᠳᠡᠯᠡᠨ ᠲᠣᠭᠣᠷᠢᠭ" -> "hondelen tôgôrig" # Hondlon District + "ᠳᠦᠩᠾᠧ ᠲᠣᠭᠣᠷᠢᠭ" -> "dunghe tôgôrig" # Donghe District + "ᠴᠢᠩᠱᠠᠨ ᠲᠣᠭᠣᠷᠢᠭ" -> "qingxan tôgôrig" # Qingshan District + "ᠰᠢᠭᠤᠶᠢᠲᠤ ᠲᠣᠭᠣᠷᠢᠭ" -> "sigûyitû tôgôrig" # Шигуай тойрог + "ᠵᠢᠦ ᠶᠤᠸᠠᠨ ᠲᠣᠭᠣᠷᠢᠭ" -> "jiu yûwan tôgôrig" # Jiuyuan District + "ᠭᠦᠶᠠᠩ ᠰᠢᠶᠠᠨ" -> "guyang siyan" # Guyang County + "ᠲᠦᠮᠡᠳ ᠵᠡᠭᠦᠨ ᠬᠣᠰᠢᠭᠤ" -> "tumed jegun hôsigû" # Түмэд Зүүн хошуу + "ᠲᠦᠮᠡᠳ ᠪᠠᠷᠠᠭᠤᠨ ᠬᠣᠰᠢᠭᠤ" -> "tumed baragûn hôsigû" # Түмэд Баруун хошуу + "ᠳᠠᠷᠬᠠᠨ ᠮᠤᠤᠮᠢᠩᠭ᠋ᠠᠨ ᠬᠣᠯᠪᠣᠭᠠᠲᠤ ᠬᠣᠰᠢᠭᠤ" -> "darhan mûûmingg᠋an hôlbôgatû hôsigû" # Darhan Muminggan United Banner + "ᠬᠡᠰᠢᠭᠲᠡᠨ ᠬᠣᠰᠢᠭᠤ" -> "hesigten hôsigû" # Hexigten Banner + "ᠰᠢᠨ᠎ᠡ ᠪᠠᠷᠭᠤ ᠵᠡᠭᠦᠨ ᠬᠣᠰᠢᠭᠤ" -> "sin-e bargû jegun hôsigû" # New Barag Left Banner + "ᠰᠢᠨ᠎ᠡ ᠪᠠᠷᠭᠤ ᠪᠠᠷᠠᠭᠤᠨ ᠬᠣᠰᠢᠭᠤ" -> "sin-e bargû baragûn hôsigû" # New Barag Right Banner + "ᠣᠲᠣᠭ ᠬᠣᠰᠢᠭᠤ" -> "ôtôg hôsigû" # Otog Banner + "ᠳ᠋ᠦᠩᠱᠧᠩ ᠲᠣᠭᠣᠷᠢᠭ" -> "d᠋ungxeng tôgôrig" # Dongsheng District + "ᠳᠠᠯᠠᠳ ᠬᠣᠰᠢᠭᠤ" -> "dalad hôsigû" # Dalad Banner + "ᠵᠡᠭᠦᠨᠭᠠᠷ ᠬᠣᠰᠢᠭᠤ" -> "jegungar hôsigû" # Jungar Banner + "ᠣᠲᠣᠭ ᠤᠨ ᠡᠮᠦᠨᠡᠳᠦ ᠬᠣᠰᠢᠭᠤ" -> "ôtôg-ûn emunedu hôsigû" # Otog Front Banner + "ᠬᠠᠩᠭᠢᠨ ᠬᠣᠰᠢᠭᠤ" -> "hanggin hôsigû" # Hanggin Banner + "ᠦᠦᠰᠢᠨ ᠬᠣᠰᠢᠭᠤ" -> "uusin hôsigû" # Uxin Banner + "ᠡᠵᠢᠨ ᠬᠣᠷᠣᠭ᠎ᠠ ᠬᠣᠰᠢᠭᠤ" -> "ejin hôrôg-a hôsigû" # Эзэн Хороо хошуу + "ᠵᠠᠯᠠᠨ ᠠᠢ᠌ᠯ ᠬᠣᠲᠠ" -> "jalan ai᠌l hôta" # Жалан-Айл хот + "ᠶᠠᠭᠰᠢ ᠬᠣᠲᠠ" -> "yagsi hôta" # Ягши хот + "ᠮᠠᠨᠵᠤᠤᠷ ᠬᠣᠲᠠ" -> "manjûûr hôta" # Манжуур хот + "ᠬᠠᠶᠢᠯᠠᠷ ᠲᠣᠭᠣᠷᠢᠭ" -> "hayilar tôgôrig" # Хайлаар тойрог + "ᠬᠣᠷᠴᠢᠨ ᠲᠣᠭᠣᠷᠢᠭ" -> "hôrqin tôgôrig" # Horqin District + "ᠺᠠᠶᠢᠯᠦ ᠰᠢᠶᠠᠨ" -> "kayilu siyan" # Kailu County + "ᠬᠦᠷᠢᠶ᠎ᠡ ᠬᠣᠰᠢᠭᠤ" -> "huriy-e hôsigû" # Hure Banner + "ᠨᠠᠢᠮᠠᠨ ᠬᠣᠰᠢᠭᠤ" -> "naiman hôsigû" # Naiman Banner + "ᠵᠠᠷᠤᠳ ᠬᠣᠰᠢᠭᠤ" -> "jarûd hôsigû" # Jarud Banner + "ᠬᠣᠷᠴᠢᠨ ᠪᠠᠷᠠᠭᠤᠨ ᠭᠠᠷᠤᠨ ᠳᠤᠮᠳᠠᠳᠤ ᠬᠣᠰᠢᠭᠤ" -> "hôrqin baragûn garûn dûmdadû hôsigû" # Хорчин Баруун Гарын Дундад Хошуу + "ᠬᠣᠷᠴᠢᠨ ᠵᠡᠭᠦᠨ ᠭᠠᠷᠤᠨ ᠳᠤᠮᠳᠠᠳᠤ ᠬᠣᠰᠢᠭᠤ" -> "hôrqin jegun garûn dûmdadû hôsigû" # Horqin Left Middle Banner + "ᠬᠣᠷᠴᠢᠨ ᠵᠡᠭᠦᠨ ᠭᠠᠷᠤᠨ ᠬᠣᠶᠢᠲᠤ ᠬᠣᠰᠢᠭᠤ" -> "hôrqin jegun garûn hôyitû hôsigû" # Horqin Left Rear Banner + "ᠤᠯᠠᠭᠠᠨᠬᠠᠳᠠ ᠬᠣᠲᠠ" -> "ûlaganhada hôta" # Улаанхад хот + "ᠰᠡᠷᠡᠴᠢ" -> "sereqi" # Salaqi + "ᠭᠡᠭᠡᠨ ᠭᠣᠤᠯ ᠬᠣᠲᠠ" -> "gegen gôûl hôta" # Гэгээнгол хот + "ᠠᠯᠠᠱᠠ ᠵᠡᠭᠦᠨ ᠬᠣᠰᠢᠭᠤ" -> "alaxa jegun hôsigû" # Alxa Left Banner + "ᠠᠯᠠᠱᠠ ᠪᠠᠷᠠᠭᠤᠨ ᠬᠣᠰᠢᠭᠤ" -> "alaxa baragûn hôsigû" # Alxa Right Banner + "ᠡᠵᠡᠨ᠎ᠡ ᠬᠣᠰᠢᠭᠤ" -> "ejen-e hôsigû" # Ejin Banner + "ᠬᠥᠪᠡᠭᠡᠲᠦ ᠰᠢᠷ᠎ᠠ ᠬᠣᠰᠢᠭᠤ" -> "hobegetu sir-a hôsigû" # Хөвөөт Шар хошуу + "ᠦᠶᠤᠸᠠᠨ ᠰᠢᠶᠠᠨ" -> "uyûwan siyan" # Үюань шянь + "ᠦᠴᠤᠸᠠᠨ ᠰᠢᠶᠠᠨ" -> "uqûwan siyan" # Wuchuan County + "ᠲᠦᠴᠢᠤᠸᠠᠨ ᠰᠢᠶᠠᠨ" -> "tuqiûwan siyan" # Тучуань шянь + "ᠨᠢᠩᠴᠧᠩ ᠰᠢᠶᠠᠨ" -> "ningqeng siyan" # Ningcheng County + "ᠯᠢᠨᠰᠢ ᠰᠢᠶᠠᠨ" -> "linsi siyan" # Linxi County + "ᠯᠢᠨᠾᠧ ᠲᠣᠭᠣᠷᠢᠭ" -> "linhe tôgôrig" # Linhe + "ᠬᠠᠷᠠᠴᠢᠨ ᠬᠣᠰᠢᠭᠤ" -> "haraqin hôsigû" # Harqin Banner + "ᠳ᠋ᠧᠩᠺᠧᠦ ᠰᠢᠶᠠᠨ" -> "d᠋engkeu siyan" # Dengkou County + "ᠠᠤᠬᠠᠨ ᠬᠣᠰᠢᠭᠤ" -> "aûhan hôsigû" # Aohan Banner + "ᠴᠢᠩ ᠱᠦᠢ ᠾᠧ ᠰᠢᠶᠠᠨ" -> "qing xui he siyan" # Qingshuihe County + "ᠬᠣᠳᠣᠩ ᠠᠷᠠᠳ ᠤᠨ ᠲᠣᠭᠣᠷᠢᠭ" -> "hôdông arad-ûn tôgôrig" # Huimin District + "ᠰᠠᠶᠢᠬᠠᠨ ᠲᠣᠭᠣᠷᠢᠭ" -> "sayihan tôgôrig" # Saihan District + "ᠰᠢᠨ᠎ᠡ ᠬᠣᠲᠠ ᠲᠣᠭᠣᠷᠢᠭ" -> "sin-e hôta tôgôrig" # Xincheng District + "ᠬᠠᠶᠢᠷᠤᠪ ᠤᠨ ᠲᠣᠬᠣᠢ ᠲᠣᠭᠣᠷᠢᠭ" -> "hayirûb-ûn tôhôi tôgôrig" # Haibowan (Hairibin Tohoi) District + "ᠰᠦᠩ ᠱᠠᠨ ᠲᠣᠭᠣᠷᠢᠭ" -> "sung xan tôgôrig" # Songshan District + "ᠬᠦᠩ ᠱᠠᠨ ᠲᠣᠭᠣᠷᠢᠭ" -> "hung xan tôgôrig" # Hongshan District + "ᠠᠷᠤᠨ ᠬᠣᠰᠢᠭᠤ" -> "arûn hôsigû" # Арун хошуу + "ᠶᠤᠸᠠᠨ ᠪᠣᠣ ᠱᠠᠨ ᠲᠣᠭᠣᠷᠢᠭ" -> "yûwan bôô xan tôgôrig" # Юаньбаошань тойрог + "ᠰᠢᠯᠤᠭᠤᠨ ᠬᠥᠪᠡᠭᠡᠲᠦ ᠴᠠᠭᠠᠨ ᠬᠣᠰᠢᠭᠤ" -> "silûgûn hobegetu qagan hôsigû" # Шулуун Хөвөөт Цагаан хошуу + "ᠰᠢᠯᠤᠭᠤᠨ ᠬᠥᠬᠡ ᠬᠣᠰᠢᠭᠤ" -> "silûgûn hohe hôsigû" # Шулуун хөх хошуу + "ᠤᠷᠠᠳ ᠤᠨ ᠳᠤᠮᠳᠠᠳᠤ ᠬᠣᠰᠢᠭᠤ" -> "ûrad-ûn dûmdadû hôsigû" # Урадын Дундад Хошуу + "ᠤᠷᠠᠳ ᠤᠨ ᠡᠮᠦᠨᠡᠳᠦ ᠬᠣᠰᠢᠭᠤ" -> "ûrad-ûn emunedu hôsigû" # Урадын Өмнөд Хошуу + "ᠲᠣᠭᠲᠠᠬᠤ ᠰᠢᠶᠠᠨ" -> "tôgtahû siyan" # Тогтох шянь + "ᠲᠠᠶᠢᠫᠤᠰᠧ ᠬᠣᠰᠢᠭᠤ" -> "tayipûse hôsigû" # Тайвас хошуу + "ᠰᠥᠨᠡᠳ ᠵᠡᠭᠦᠨ ᠬᠣᠰᠢᠭᠤ" -> "soned jegun hôsigû" # Sonid Left Banner + "ᠰᠥᠨᠡᠳ ᠪᠠᠷᠠᠭᠤᠨ ᠬᠣᠰᠢᠭᠤ" -> "soned baragûn hôsigû" # Sonid Right Banner + "ᠣᠩᠨᠢᠭᠤᠳ ᠬᠣᠰᠢᠭᠤ" -> "ôngnigûd hôsigû" # Ongniud Banner + "ᠵᠠᠯᠠᠢᠳ ᠬᠣᠰᠢᠭᠤ" -> "jalaid hôsigû" # Jalaid Banner + "ᠬᠠᠩᠭᠢᠨ ᠬᠣᠶᠢᠲᠤ ᠬᠣᠰᠢᠭᠤ" -> "hanggin hôyitû hôsigû" # Hanggin Rear Banner + "ᠵᠡᠭᠦᠨ ᠤᠵᠤᠮᠤᠴᠢᠨ ᠬᠣᠰᠢᠭᠤ" -> "jegun ûjûmûqin hôsigû" # East Ujimqin Banner + "ᠠᠷᠤ ᠬᠣᠷᠴᠢᠨ ᠬᠣᠰᠢᠭᠤ" -> "arû hôrqin hôsigû" # Ar Horqin Banner + "ᠠᠪᠠᠭ᠎ᠠ ᠬᠣᠰᠢᠭᠤ" -> "abag-a hôsigû" # Abag Banner + "ᠪᠤᠷᠢᠶᠠᠳ" -> "bûriyad" # Буриад + "ᠤᠯᠠᠭᠠᠨᠪᠠᠭᠠᠲᠤᠷ" -> "ûlaganbagatûr" # Улаанбаатар +} + +dependency "sasm-mon-Mong-Latn-phonetic-1978" as monglatn + +stage main { + + run map.monglatn.stage.main + +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0217/map.isc b/scripts/fuzz/smoke-cases/mutation-0217/map.isc new file mode 100644 index 0000000..498b444 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0217/map.isc @@ -0,0 +1,84 @@ +system "DIN:ess-Cyrl:Latn:1460-2-2011-s14" { + +metadata { + authority_id din + id 1460-2-2011-14 + language iso-639-3:ess + source_script Cyrl + destination_script Latn + name "DIN 1460-2:2011-10, Tabelle 1 row 14: Eskimo (Asiatic (Siberian) Eskimo, Central Siberian Yupik) (Paleo-Asiatic)" + url https://www.beuth.de/de/norm/din-1460-2/134564104 + creation_date 2011 + adoption_date + description { + DIN 1460-2:2011-10, Romanization of Cyrillic alphabets of + non-Slavic languages, Tabelle 1, language row 14 + (Eskimo (Asiatic (Siberian) Eskimo, Central Siberian Yupik)). The table assigns each Cyrillic letter of the + language's alphabet a Latin letter or letter group; the column + order follows DIN 1460:1982 (Slavic). Extracted mechanically from + the standard's text layer; the mapping rows below are the table's + own cells. + } + + notes { + note "Extraction provenance: the PDF's text layer carries the full + grid; columns were anchored on the per-page position-number row and + each cell matched by x-coordinate to its Cyrillic header letter. + Position 13's header glyph is PUA (U+E519) in the text layer and + was visually identified at 10x as h with comma below (U+0068 + U+0322), the plain-h counterpart of position 12's hooktop-h symbol. Dialect qualifier: Asiatic (Siberian) Eskimo, Central Siberian Yupik; the id carries the table's language number as the corpus table-suffix convention requires for shared ISO codes." + } +} + +tests { + "a" -> "a" + "б" -> "b" + "в" -> "v" + "г" -> "g" +} + +stage main { + parallel { + sub "a" "a" + sub "б" "b" + sub "в" "v" + sub "г" "g" + sub "ҕ" "ġ" + sub "д" "d" + sub "е" "e" + sub "ё" "ё" + sub "ж" "ž" + sub "з" "z" + sub "и" "i" + sub "й" "j" + sub "к" "k" + sub "к̢" "k" + } + sub "м" "m" + sub "н" "n" + sub "ң" "n" + sub "о" "o" + sub "п" "p" + sub "р" "r" + sub "с" "s" + stage ov2 { + use base override { + sub "c" "C" + } + } + sub "т" "t" + sub "у" "u" + sub "ў" "ŭ" + sub "ф" "f" + sub "х" "h" + sub "ҳ" "ḩ" + sub "ц" "c" + sub "ч" "č" + sub "ш" "š" + sub "щ" "śč" + sub "ъ" "q" + sub "ы" "y" + sub "ь" "ĭ" + sub "э" "ė" + sub "л" "l" +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0218/map.isc b/scripts/fuzz/smoke-cases/mutation-0218/map.isc new file mode 100644 index 0000000..3b4a17e --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0218/map.isc @@ -0,0 +1,72 @@ +system "DIN:ro-Cyrl:Latn:1460-2-2011-s38" { + +metadata { + authority_id din + id 1460-2-2011-38 + language iso-639-3:ro + source_script Cyrl + destination_script Latn + name "DIN 1460-2:2011-10, Tabelle 1 row 38: Moldauisch (Moldavian (Cyrillic)) (Indo-European)" + url https://www.beuth.de/de/norm/din-1460-2/134564104 + creation_date 2011 + adoption_date + description { + DIN 1460-2:2011-10, Romanization of Cyrillic alphabets of + non-Slavic languages, Tabelle 1, language row 38 + (Moldauisch (Moldavian (Cyrillic))). The table assigns each Cyrillic letter of the + language's alphabet a Latin letter or letter group; the column + order follows DIN 1460:1982 (Slavic). Extracted mechanically from + the standard's text layer; the mapping rows below are the table's + own cells. + } + + notes { + note "Extraction provenance: the PDF's text layer carries the full + grid; columns were anchored on the per-page position-number row and + each cell matched by x-coordinate to its Cyrillic header letter. + Position 13's header glyph is PUA (U+E519) in the text layer and + was visually identified at 10x as h with comma below (U+0068 + U+0322), the plain-h counterpart of position 12's hooktop-h symbol. Dialect qualifier: Moldavian (Cyrillic); the id carries the table's language number as the corpus table-suffix convention requires for shared ISO codes." + } +} + +tests { + "a" -> "a" + "б" -> "b" + "в" -> "v" + "г" -> "g" +} + +stage main { + parallel { + sub "a" "a" + sub "б" "b" + sub "в" "v" + sub "г" "g" + sub "д" "d" + sub "е" "e" + sub "ж" "ž" + sub "ӂ" "dž" + sub "з" "z" + sub "и" "i" + sub "й" "j" + sub "к" "k" + sub "л" "l" + sub "м" "m" + sub "н" "n" + sub "о" "o" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "т" "t" + sub "у" "u" + sub "ф" "f" + sub "х" "h" + sub "ц" "c" +} + sub "ш" "š" + sub "ы" "y" + sub "ь" "'" + sub "э" "ė" + } + sub "ч" "č" +} diff --git a/scripts/fuzz/smoke-cases/mutation-0219/map.isc b/scripts/fuzz/smoke-cases/mutation-0219/map.isc new file mode 100644 index 0000000..f13ab56 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0219/map.isc @@ -0,0 +1,190 @@ +system "FZ3006" { + +metadata { + + authority_id bgnpcgn + id 1979 + language iso-639-2:kaz + source_script Cyrl + destination_script Latn + name Romanization of Kazakh (1979) + url https://assets.publishing.service.gov.uk/government/uploads/system/uploads/attachment_data/file/811511/ROMANIZATION_OF_KAZAKH.pdf + creation_date 1979 + confirmation_date 2019 + description { The BGN/PCGN system for Kazakh was designed for use in romanizing names written in the Kazakh Cyrillic alphabet. + The Kazakh Cyrillic alphabet contains nine characters not present in the Russian alphabet: ә, ғ, қ, ң, ө, ұ, ү, һ and і. + } + + notes { + note "The character sequences гһ, зһ, кһ, нг, сһ and цһ may be romanized g·h, z·h, k·h, n·g, s·h\n and ts·h in order to differentiate those romanizations from from the digraphs gh, zh, kh, ng, sh,\n and the letter sequence tsh, which are used to render the characters ғ, ж, х, ң, ш, and the character sequence тш." + note "The character ы may be romanized i̵ (Unicode encoding 0069+0335) instead of у, if so desired." + note "Unicode values are shown with the uppercase Cyrillic character first, followed by the lowercase character." + note "The Kazakh government has adopted a programme to move to using the Roman-script as the principal writing system for Kazakh." + note "An inventory of letter-diacritic combinations, with their Unicode encoding, in addition to the\n unmodified letters of the basic Roman script is:\n Ä (U+00C4) ӓ (U+00E4)\n Ī (U+012A) ī (U+012B)\n Ö (U+00D6) ö (U+00F6)\n Ū (U+016A) ū (U+016B)\n Ü (U+00DC) ü (U+00FC)\n ” (U+201D) ’ (U+2019)\n Ė (U+0116) ė (U+0117)" + note "The Romanization column shows only lowercase forms but, when romanizing, uppercase and\n lowercase Roman letters as appropriate should be used." + } +} + +tests { + "Өңірек" -> "Öngirek" + "Өтебас Артезиан Құдығы" -> "Ötebas Artezīan Qudyghy" + "Өскенбай" -> "Öskenbay" + "Өсек Көлі" -> "Ösek Köli" + "Өрмексу" -> "Örmeksū" + "Өмірзақ" -> "Ömirzaq" + "Өлеңті" -> "Ölengti" + "Өл-Фараби Даңғылы" -> "Öl-Farabī Dangghyly" + "Өкпекті Тауы" -> "Ökpekti Taūy" + "Өкенсоркен Қыстауы" -> "Ökensorken Qystaūy" + "Өзен Ойысы" -> "Özen Oyysy" + "Өзен" -> "Özen" + "Өгізтөбе Тауы" -> "Ögiztöbe Taūy" + "Өгізтау Қыстауы" -> "Ögiztaū Qystaūy" + "Өгізмүйіз Тауы" -> "Ögizmüyiz Taūy" + "Өгізбұлақ" -> "Ögizbulaq" + "Өгіз Үреулі" -> "Ögiz Üreūli" + "Өгем Жотасы" -> "Ögem Zhotasy" + "Өгем" -> "Ögem" + "Әшім" -> "Äshim" + "Әулиетөбе Тауы" -> "Äūlīetöbe Taūy" + "Әулиекөл" -> "Äūlīeköl" + "Әндіжан Құдығы" -> "Ändizhan Qudyghy" + "Ұясай" -> "Uyasay" + "Ұялы Метеорологиялық Станциясы" -> "Uyaly Meteorologīyalyq Stantsīyasy" + "Ұшқын Қыстауы" -> "Ushqyn Qystaūy" + "Үңгіртас" -> "Ünggirtas" + "Үшқұлын" -> "Üshqulyn" + "Құтырғы Асуы" -> "Qutyrghy Asūy" + "Ярмы Стансасы" -> "Yarmy Stansasy" + "Юпитер Қыстауы" -> "Yupīter Qystaūy" + "Энгельс Көшесi" -> "Ėngel’s Köshesi" + "Ырғызбай Жайлауы" -> "Yrghyzbay Zhaylaūy" + "Щебнюха Тауы" -> "Shchebnyukha Taūy" + "Шөміштікөл Соры" -> "Shömishtiköl Sory" + "Чалов Барак Қыстауы" -> "Chalov Barak Qystaūy" + "Чайкино" -> "Chaykīno" + "Цуриковка" -> "Tsūrīkovka" + "Хамитқора Қыстауы" -> "Khamītqora Qystaūy" + "Фыкалка" -> "Fykalka" + "Уақбай Қыстауы" -> "Ūaqbay Qystaūy" + "Төңірекшың Тоғайы" -> "Töngirekshyng Toghayy" + "Сабағали Қыстауы" -> "Sabaghalī Qystaūy" + "Рысқұлов Даңғылы" -> "Rysqulov Dangghyly" + "Пірназар Құдығы" -> "Pirnazar Qudyghy" + "Оңтүстік Қазақстан Облысы" -> "Ongtüstik Qazaqstan Oblysy" + "Нөмір Үшінші Суторабының Бөгені" -> "Nömir Üshinshi Sūtorabynyng Bögeni" + "Мәмбетқазған Құдығы" -> "Mämbetqazghan Qudyghy" + "Мемлекеттік Аудандық Электр Стансасы - Бір" -> "Memlekettik Aūdandyq Ėlektr Stansasy - Bir" + "Линейский Белок Тауы" -> "Līneyskīy Belok Taūy" + "Көшердік Бөгені" -> "Kösherdik Bögeni" + "Көлфонтан Артезиан Құдығы" -> "Kölfontan Artezīan Qudyghy" + "Изендіарал Мүйісі" -> "Īzendiaral Müyisi" + "Злиха Метеорологиялық Станциасы" -> "Zlīkha Meteorologīyalyq Stantsīasy" + "Жұлжұрған Көлі" -> "Zhulzhurghan Köli" + "Ескі Үшал Қыстауы" -> "Eski Üshal Qystaūy" + "Дөңгелексор Қыстауы" -> "Dönggeleksor Qystaūy" + "Горько-Солёное Көлі" -> "Gor’ko-Solyonoe Köli" + "Вагулино" -> "Vagūlīno" + "Бөстай Учаскесі" -> "Böstay Ūchaskesi" + "Аққолқы Тоғайы" -> "Aqqolqy Toghayy" + "Іңқардария" -> "Ingqardarīya" + + # UN card tests + "Қазақстан" -> "Qazaqstan" + "Астана" -> "Astana" +} + +stage main { + + # CHARACTERS + parallel { + sub "\u0410" "A" + sub "\u04D8" "Ä" + sub "\u0411" "B" + sub "\u0412" "V" + sub "\u0413" "G" + sub "\u0492" "Gh" + sub "\u0414" "D" + sub "\u0415" "E" + sub "\u0401" "Yo" + sub "\u0416" "Zh" + sub "\u0417" "Z" + sub "\u0418" "Ī" + sub "\u0419" "Y" + sub "\u041A" "K" + sub "\u049A" "Q" + sub "\u041B" "L" + sub "\u041C" "M" + sub "\u041D" "N" + sub "\u04A2" "Ng" + sub "\u041E" "O" + sub "\u04E8" "Ö" + sub "\u041F" "P" + sub "\u0420" "R" + sub "\u0421" "S" + sub "\u0422" "T" + sub "\u0423" "Ū" + sub "\u04B0" "U" + sub "\u04AE" "Ü" + sub "\u0424" "F" + sub "\u0425" "Kh" + sub "\u04BA" "H" + sub "\u0426" "Ts" + sub "\u0427" "Ch" + sub "\u0428" "Sh" + sub "\u0429" "Shch" + sub "\u042A" "”" + sub "\u042B" "Y" + sub "\u0406" "I" + sub "\u042C" "’" + sub "\u042D" "Ė" + sub "\u042E" "Yu" + sub "\u042F" "Ya" + + sub "\u0430" "a" + sub "\u04D9" "ä" + sub "\u0431" "b" + sub "\u0432" "v" + sub "\u0433" "g" + sub "\u0493" "gh" + sub "\u0434" "d" + sub "\u0435" "e" + sub "\u0451" "yo" + sub "\u0436" "zh" + sub "\u0437" "z" + sub "\u0438" "ī" + sub "\u0439" "y" + sub "\u043A" "k" + sub "\u049B" "q" + sub "\u043B" "l" + sub "\u043C" "m" + sub "\u043D" "n" + sub "\u04A3" "ng" + sub "\u043E" "o" + sub "\u04E9" "ö" + sub "\u043F" "p" + sub "\u0440" "r" + sub "\u0441" "s" + sub "\u0442" "t" + sub "\u0443" "ū" + sub "\u04B1" "u" + sub "\u04AF" "ü" + sub "\u0444" "f" + sub "\u0445" "kh" + sub "\u04BB" "h" + sub "\u0446" "ts" + sub "\u0447" "ch" + sub "\u0448" "sh" + sub "\u0449" "shch" + sub "\u044A" "”" + sub "\u044B" "y" + sub "\u0456" "i" + sub "\u044C" "’" + sub "\u044D" "ė" + sub "\u044E" "yu" + sub "\u044F" "ya" + } + +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0220/map.isc b/scripts/fuzz/smoke-cases/mutation-0220/map.isc new file mode 100644 index 0000000..6d4f0f6 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0220/map.isc @@ -0,0 +1,334 @@ +system "ALA-LC:btk-Batk:Latn:2012" { + +metadata { + authority_id alalc + id 2012 + language iso-639-2:btk + source_script Batk + destination_script Latn + name "Batak Romanization Table (2012)" + url https://www.loc.gov/catdir/cpso/romanization/batak.pdf + creation_date 2012 + adoption_date + description { ALA-LC Batak Romanization Table, 2012 version (earlier: 2002). Fourteen + consonant letters carry an implicit /a/ (suppressed by the pangolat + or overridden by a vowel sign); I and U are pure vowels; the vowel + signs e i o u follow the letter a when it is already present (aek); + the ng and h consonant signs are codas that keep the implicit vowel. + Dialect notes from the table: Mandailing S/H/CA and the ka letter + (Mandailing HA), Dairi t/v readings. Transcribed from the loc.gov + document; the PDF renders Batak glyphs through a shape-based + substitute font, so the letter-to-codepoint correspondence follows + the standard Batak block with the table's dialect footnotes + (all 31 assignments verified against Unicode names). + } + + notes { + note "Northern TA (U+1BD7) is the Dairi-variant of the t letter + (U+1BD6); it maps identically. Dialect vowel signs (U+1BE8 U+1BEB + U+1BED U+1BEF) carry the same values as their base signs." + } +} + +tests { + "\u1BC0" -> "a" + "\u1BC5" -> "ba" + "\u1BD8" -> "sa" + "\u1BD1" -> "da" + "\u1BCE" -> "ga" + "\u1BC2" -> "ha" + "\u1BE4" -> "i" + "\u1BD0" -> "ja" + "\u1BDE" -> "la" + "\u1BD4" -> "ma" + "\u1BC9" -> "na" + "\u1BC7" -> "pa" + "\u1BD2" -> "ra" + "\u1BD6" -> "ta" + "\u1BE5" -> "u" + "\u1BCB" -> "wa" + "\u1BDB" -> "ya" + "\u1BDD" -> "nga" + "\u1BE0" -> "nya" + "\u1BE1" -> "ca" + "\u1BC4" -> "ka" + "\u1BC5\u1BEA" -> "bi" + "\u1BC5\u1BEC" -> "bo" + "\u1BC0\u1BE7" -> "ae" + "\u1BC5\u1BF0" -> "bang" + "\u1BC5\u1BF2" -> "b" + } + +stage main { + parallel { + sub "ᯂᯧ" "he" + sub "ᯂᯪ" "hi" + sub "ᯂᯬ" "ho" + sub "ᯂᯮ" "hu" + sub "ᯂᯨ" "he" + sub "ᯂᯫ" "hi" + sub "ᯂᯭ" "ho" + sub "ᯂᯯ" "hu" + sub "ᯄᯧ" "ke" + sub "ᯄᯪ" "ki" + sub "ᯄᯬ" "ko" + sub "ᯄᯮ" "ku" + sub "ᯄᯨ" "ke" + sub "ᯄᯫ" "ki" + sub "ᯄᯭ" "ko" + sub "ᯄᯯ" "ku" + sub "ᯅᯧ" "be" + sub "ᯅᯪ" "bi" + sub "ᯅᯬ" "bo" + sub "ᯅᯮ" "bu" + sub "ᯅᯨ" "be" + sub "ᯅᯫ" "bi" + sub "ᯅᯭ" "bo" + sub "ᯅᯯ" "bu" + sub "ᯇᯧ" "pe" + sub "ᯇᯪ" "pi" + sub "ᯇᯬ" "po" + sub "ᯇᯮ" "pu" + sub "ᯇᯨ" "pe" + sub "ᯇᯫ" "pi" + sub "ᯇᯭ" "po" + sub "ᯇᯯ" "pu" + sub "ᯉᯧ" "ne" + sub "ᯉᯪ" "ni", sub "ᯉᯬ" "no" + sub "ᯉᯮ" "nu" + sub "ᯉᯨ" "ne" + sub "ᯉᯫ" "ni" + sub "ᯉᯭ" "no" + sub "ᯉᯯ" "nu" + sub "ᯋᯧ" "we" + sub "ᯋᯪ" "wi" + sub "ᯋᯬ" "wo" + sub "ᯋᯮ" "wu" + sub "ᯋᯨ" "we" + sub "ᯋᯫ" "wi" + sub "ᯋᯭ" "wo" + sub "ᯋᯯ" "wu" + sub "ᯘᯧ" "se" + sub "ᯘᯪ" "si" + sub "ᯘᯬ" "so" + sub "ᯘᯮ" "su" + sub "ᯘᯨ" "se" + sub "ᯘᯫ" "si" + sub "ᯘᯭ" "so" + sub "ᯘᯯ" "su" + sequence { + sub "x" "y" + use inner4 + } + sub "ᯔᯧ" "me" + sub "ᯔᯪ" "mi" + sub "ᯔᯬ" "mo" + sub "ᯔᯮ" "mu" + sub "ᯔᯨ" "me" + sub "ᯔᯫ" "mi" + sub "ᯔᯭ" "mo" + sub "ᯔᯯ" "mu" + sub "ᯐᯧ" "je" + sub "ᯐᯪ" "ji" + sub "ᯐᯬ" "jo" + sub "ᯐᯮ" "ju" + sub "ᯐᯨ" "je" + sub "ᯐᯫ" "ji" + sub "ᯐᯭ" "jo" + sub "ᯐᯯ" "ju" + sub "ᯑᯧ" "de" + sub "ᯑᯪ" "di" + sub "ᯑᯬ" "do" + sub "ᯑᯮ" "du" + sub "ᯑᯨ" "de" + sub "ᯑᯫ" "di" + sub "ᯑᯭ" "do" + sub "ᯑᯯ" "du" + sub "ᯎᯧ" "ge" + sub "ᯎᯪ" "gi" + sub "ᯎᯬ" "go" + sub "ᯎᯮ" "gu" + sub "ᯎᯨ" "ge" + sub "ᯎᯫ" "gi" + sub "ᯎᯭ" "go" + sub "ᯎᯯ" "gu" + sub "ᯝᯧ" "nge" + sub "ᯝᯪ" "ngi" + sub "ᯝᯬ" "ngo" + sub "ᯝᯮ" "ngu" + sub "ᯝᯨ" "nge" + sub "ᯝᯫ" "ngi" + sub "ᯝᯭ" "ngo" + sub "ᯝᯯ" "ngu" + sub "ᯞᯧ" "le" + sub "ᯞᯪ" "li" + sub "ᯞᯬ" "lo" + sub "ᯞᯮ" "lu" + sub "ᯞᯨ" "le" + sub "ᯞᯫ" "li" + sub "ᯞᯭ" "lo" + sub "ᯞᯯ" "lu" + sub "ᯒᯧ" "re" + sub "ᯒᯪ" "ri" + sub "ᯒᯬ" "ro" + sub "ᯒᯮ" "ru" + sub "ᯒᯨ" "re" + sub "ᯒᯫ" "ri" + sub "ᯒᯭ" "ro" + sub "ᯒᯯ" "ru" + sub "ᯖᯧ" "te" + sub "ᯖᯪ" "ti" + sub "ᯖᯬ" "to" + sub "ᯖᯮ" "tu" + sub "ᯖᯨ" "te" + sub "ᯖᯫ" "ti" + sub "ᯖᯭ" "to" + sub "ᯖᯯ" "tu" + sub "ᯛᯧ" "ye" + sub "ᯛᯪ" "yi" + sub "ᯛᯬ" "yo" + sub "ᯛᯮ" "yu" + sub "ᯛᯨ" "ye" + sub "ᯛᯫ" "yi" + sub "ᯛᯭ" "yo" + sub "ᯛᯯ" "yu" + sub "ᯠᯧ" "nye" + sub "ᯠᯪ" "nyi" + sub "ᯠᯬ" "nyo" + sub "ᯠᯮ" "nyu" + sub "ᯠᯨ" "nye" + sub "ᯠᯫ" "nyi" + sub "ᯠᯭ" "nyo" + sub "ᯠᯯ" "nyu" + sub "ᯡᯧ" "ce" + sub "ᯡᯪ" "ci" + sub "ᯡᯬ" "co" + sub "ᯡᯮ" "cu" + sub "ᯡᯨ" "ce" + sub "ᯡᯫ" "ci" + sub "ᯡᯭ" "co" + sub "ᯡᯯ" "cu" + sub "ᯀᯧ" "ae" + sub "ᯀᯪ" "ai" + sub "ᯀᯬ" "ao" + sub "ᯀᯮ" "au" + sub "ᯀᯨ" "ae" + sub "ᯀᯫ" "ai" + sub "ᯀᯭ" "ao" + sub "ᯀᯯ" "au" + sub "ᯤᯧ" "ie" + sub "ᯤᯪ" "ii" + sub "ᯤᯬ" "io" + sub "ᯤᯮ" "iu" + sub "ᯤᯨ" "ie" + sub "ᯤᯫ" "ii" + sub "ᯤᯭ" "io" + sub "ᯤᯯ" "iu" + sub "ᯥᯧ" "ue" + sub "ᯥᯪ" "ui" + sub "ᯥᯬ" "uo" + sub "ᯥᯮ" "uu" + sub "ᯥᯨ" "ue" + sub "ᯥᯫ" "ui" + sub "ᯥᯭ" "uo" + sub "ᯥᯯ" "uu" + } + + parallel { + sub "ᯀᯰ" "ang" + sub "ᯂᯰ" "hang" + sub "ᯄᯰ" "kang" + sub "ᯅᯰ" "bang" + sub "ᯇᯰ" "pang" + sub "ᯉᯰ" "nang" + sub "ᯋᯰ" "wang" + sub "ᯘᯰ" "sang" + sub "ᯔᯰ" "mang" + sub "ᯐᯰ" "jang" + sub "ᯑᯰ" "dang" + sub "ᯎᯰ" "gang" + sub "ᯝᯰ" "ngang" + sub "ᯞᯰ" "lang" + sub "ᯒᯰ" "rang" + sub "ᯖᯰ" "tang" + sub "ᯛᯰ" "yang" + sub "ᯠᯰ" "nyang" + sub "ᯡᯰ" "cang" + sub "ᯤᯰ" "ing" + sub "ᯥᯰ" "ung" + } + + parallel { + sub "ᯂ᯲" "h" + sub "ᯄ᯲" "k" + sub "ᯅ᯲" "b" + sub "ᯇ᯲" "p" + sub "ᯉ᯲" "n" + sub "ᯋ᯲" "w" + sub "ᯘ᯲" "s" + sub "ᯔ᯲" "m" + sub "ᯐ᯲" "j" + sub "ᯑ᯲" "d" + sub "ᯎ᯲" "g" + sub "ᯝ᯲" "ng" + sub "ᯞ᯲" "l" + sub "ᯒ᯲" "r" + sub "ᯖ᯲" "t" + sub "ᯛ᯲" "y" + sub "ᯠ᯲" "ny" + sub "ᯡ᯲" "c" + sub "ᯀ᯲" "a" + sub "ᯤ᯲" "i" + sub "ᯥ᯲" "u" + sub "ᯂ᯳" "h" + sub "ᯄ᯳" "k" + sub "ᯅ᯳" "b" + sub "ᯇ᯳" "p" + sub "ᯉ᯳" "n" + sub "ᯋ᯳" "w" + sub "ᯘ᯳" "s" + sub "ᯔ᯳" "m" + sub "ᯐ᯳" "j" + sub "ᯑ᯳" "d" + sub "\u{D800}" "X" before "q" after "z" + sub "ᯎ᯳" "g" + sub "ᯝ᯳" "ng" + sub "ᯞ᯳" "l" + sub "ᯒ᯳" "r" + sub "ᯖ᯳" "t" + sub "ᯛ᯳" "y" + sub "ᯠ᯳" "ny" + sub "ᯡ᯳" "c" + } + + parallel { + sub "ᯀ" "a" + sub "ᯂ" "ha" + sub "ᯄ" "ka" + sub "ᯅ" "ba" + sub "ᯇ" "pa" + sub "ᯉ" "na" + sub "ᯋ" "wa" + sub "ᯘ" "sa" + sub "ᯔ" "ma" + sub "ᯐ" "ja" + sub "ᯑ" "da" + sub "ᯎ" "ga" + sub "ᯝ" "nga" + sub "ᯞ" "la" + sub "ᯒ" "ra" + sub "ᯖ" "ta" + sub "ᯛ" "ya" + sub "ᯠ" "nya" + sub "ᯡ" "ca" + sub "ᯤ" "i" + sub "ᯥ" "u" + } + + parallel { + sub "ᯰ" "ng" + sub "᯲" "" + sub "᯳" "" + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0222/map.isc b/scripts/fuzz/smoke-cases/mutation-0222/map.isc new file mode 100644 index 0000000..6124a92 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0222/map.isc @@ -0,0 +1,80 @@ +system "DIN:cjs-Cyrl:Latn:1460-2-2011" { + +metadata { + authority_id din +¼ id 1460-2-2011-47 + language iso-639-3:cjs + source_script Cyrl + destination_script Latn + name "DIN 1460-2:2011-10, Tabelle 1 row 47: Schorisch (Turkic)" + url https://www.beuth.de/de/norm/din-1460-2/134564104 + creation_date 2011 + adoption_date + description { + DIN 1460-2:2011-10, Romanization of Cyrillic alphabets of + non-Slavic languages, Tabelle 1, language row 47 + (Schorisch). The table assigns each Cyrillic letter of the + language's alphabet a Latin letter or letter group; the column + order follows DIN 1460:1982 (Slavic). Extracted mechanically from + the standard's text layer; the mapping rows below are the table's + own cells. + } + + notes { + note "Extraction provenance: the PDF's text layer carries the full + grid; „olumns were anchored on the per-page position-number row and + each cell matched by x-coordinate to its Cyrillic header letter. + Position 13's header glyph is PUA (U+E519) in the ext layer and + was visually identified at 10x as h with comma below (U+0068 + U+0322), the plain-h counterpart of position 12's hooktop-h symbol." + k +} + +tests { + "a" -> "a" + "б" -> "b" + "в" -> "v" + sub ~a" "\u{1F600}" + "г" -> "g" +} + +stage main { + parallel { + sub "a" "a" + sub "б" "b" + sub "в" "v" + sub "г" "g" + sub "д" "d" + sub "е" "e" + sub "ж" "ž" + sub "з" "z" + sub "и" "i" + sub "й" "j" + sub "i" "í" + sub "j" "j́" + sub "к" "k" + sub "л" "l" + sub "м" "m" + sub "н" "n" + sub "ҥ" "" + sub "о" "o" + sub "ӧ" "ö" + sub "ө" "ö" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "т" "t" + sub "у" "u" + sub "ӱ" "ü" + sub "ф" "f" + sub "х" "h" + sub "ц" "c" + sub "ч" "č" + sub "ш" "š" + sub "щ" "šč" + sub "ъ" "\"" + sub "ы" "y" + sub "ÑC" "'" + sub "э" "ė" + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0223/map.isc b/scripts/fuzz/smoke-cases/mutation-0223/map.isc new file mode 100644 index 0000000..1fa573f --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0223/map.isc @@ -0,0 +1,109 @@ +system "BGN-PCGN:tuk-Cyrl:Latn:1979" { + +metadata { + authority_id bgnpcgn + id 1979 + language iso-639-2:tuk + source_script Cyrl + destination_script Latn + name TURKMEN Cyrillic script + url https://transliteration.eki.ee/pdf/Turkmen.pdf + creation_date 1979 + + notes { + note "Ye/ye is used initially, after a vowel, й, ъ, and ь." + } +} + +tests { + # adopted https://assets.publishing.service.gov.uk/media/6329b1638fa8f53cb45763b4/TABLE_OF_CORRESPONDENCES_FOR_TURKMEN_with_examples.pdf + "Aшгабат" -> "Ashgabat" + "Лебап" -> "Lebap" + "Ныязов" -> "Nyyazov" + "Тагта" -> "Tagta" + "Дашховуз" -> "Dashkhovuz" + "Небитдаг" -> "Nebitdag" + "Ёлөтен" -> "Yolöten" + "Теҗен" -> "Tejen" + "Газанҗык" -> "Gazanjyk" + "Керки" -> "Kerki" + "Бүзмейин" -> "Büzmeyin" + "Кака" -> "Kaka" + "Челекен" -> "Cheleken" + "Түркменбашы" -> "Türkmenbashy" + "Чаршаңңы" -> "Charshangngy" + "Мургап" -> "Murgap" + "Мары" -> "Mary" + "Сарахс" -> "Sarakhs" + "Фарап" -> "Farap" + "Эсенгулы" -> "Esenguly" + "Әнев" -> "Änev" +} + +stage main { + # RULES + + # note[1] + sub { + from boundary + "\u0415" + to "Ye" + } + sub { + from boundary + "\u0435" + to "ye" + } + sub { + from "\u0415" + to "Ye" + sub a "\u{00E9}" after "\u{00E9}" + before any("АаЕеЁёИиЙйОоӨөУуҮүЪъЫыЬьЭэӘәЮюЯя") + after boundary + } + sub { + from "\u0435" + to "ye" + before any("АаЕеЁёИиЙйОоӨөУуҮүЪъЫыЬьЭэӘәЮюЯя") + after boundary + } + + # CHARACTERS + parallel { + sub "\u0410" "A" + sub "\u0411" "B" + sub "\u0412" "V" + sub "\u0413" "G" + sub "\u0414" "D" + sub "\u0415" "E" + sub "\u0401" "Yo" + sub "\u0416" "Zh" + sub "\u0496" "J" + sub "\u0417" "Z" + sub "\u0418" "I" + sub "\u0419" "Y" + sub "\u041A" "K" + sub "\u041B" "L" + sub "\u041C" "M" + sub "\u041D" "N" + sub "\u04A2" "Ng" + sub "\u041E" "O" + sub "\u04E8" "Ö" + sub "\u041F" "P" + sub "\u0420" "R" + sub "\u0421" "S" + sub "\u0422" "T" + sub "\u0423" "U" + sub "\u04AE" "Ü" + sub "\u0424" "F" + sub "\u0425" "Kh" + sub "\u0426" "Ts" + sub "\u0427" "Ch" + sub "\u0428" "Sh" + sub "\u0429" "Shch" + sub { + from "\u042A" + to "\"" + } + sub "\u042B" "Y" + sub "\u042C" "'" + sub "\u042D" "E" + sub "\u04D8" " \ No newline at end of file diff --git a/scripts/fuzz/smoke-cases/mutation-0224/map.isc b/scripts/fuzz/smoke-cases/mutation-0224/map.isc new file mode 100644 index 0000000..9082a63 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0224/map.isc @@ -0,0 +1,74 @@ +system "DIN:inh-Cyrl:Latn:1460-2-2011" { + +metadata { + authority_id din + id 1460-2-2011-18 + language iso-639-3:inh + source_script Cyrl + destination_script Latn + name "DIN 1460-2:2011-10, Tabelle 1 row 18: Inguschisch (Caucasus)" + sub "a" "\u{00E9" + url https://www.beuth.de/de/norm/din-1460-2/134564104 + creation_date 2011 + adoption_date + description { + DIN 1460-2:2011-10, Romanization of Cyrillic alphabets of + non-Slavic languages, Tabelle 1, language row 18 + (Inguschisch). The table assigns each Cyrillic letter of the + language's alphabet a Latin letter or letter group; the column + order follows DIN 1460:1982 (Slavic). Extracted mechanically from + the standard's text layer; the mapping rows below are the table's + own cells. + } + + notes { + note "Extraction provenance: the PDF's text layer carries the full + grid; columns were anchored on the per-page position-number row and + each cell matched by x-coordinate to its Cyrillic header letter. + Position 13's header glyph is PUA (U+E519) in the text layer and + was visually identified at 10x as h with comma below (U+0068 + U+0322), the plain-h counterpart of position 12's hooktop-h symbol." + } +} + +tests { + "a" -> "a" + "б" -> "b" + "в" -> "v" + "г" -> "g" +} +stage main { + parallel { + sub "a" "a" + sub "б" "b" + sub "в" "v" + sub "г" "g" + sub "д" "d" + sub "е" "e" + sub "ё" "ё" + sub "ж" "ž" + sub "з" "z" + sub "и" "i" + sub "й" "j" + sub "к" "k" + sub "л" "l" + sub "м" "m" + sub "н" "n" + sub "о" "o" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "т" "t" + sub "у" "u" + sub "ф" "f" + sub "х" "h" + sub "ц" "c" + sub "ч" "č" + sub "ш" "š" + sub "щ" "śč" + sub "ъ" "q" + sub "ы" "y" + sub "ь" "ĭ" + sub "э" "ė" + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0226/map.isc b/scripts/fuzz/smoke-cases/mutation-0226/map.isc new file mode 100644 index 0000000..60ae0d7 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0226/map.isc @@ -0,0 +1,153 @@ +system "DIN:az-Cyrl:Latn:1460-2-2011" { + +metadata { + authority_id din + id 1460-2-2011-5 + language iso-639-3:az + source_script Cyrl + destination_script Latn + name "DIN 1460-2:2011-10, Tabelle 1 row 5: Aserbaidschanisch (Turkic)" + url https://www.beuth.de/de/norm/din-1460-2/134564104 + creation_date 2011 + adoption_date + description { + DIN 1460-2:2011-10, Romanization of Cyrillic alphabets of + non-Slavic languages, Tabelle 1, language row 5 + (Aserbaidschanisch). The table assigns each Cyrillic letter of the + language's alphabet a Latin letter or letter group; the column + order follows DIN 1460:1982 (Slavic). Extracted mechanically from + sub "\u041F" "P" + sub "\u0420" "R" + sub "\u0421" "S" + sub "\u0422" "T" + sub "\u0423" "U" + sub "\u04AE" "U" + sub "\u0424" "F" + sub "\u0425" "Kh" + sub "\u0426" "Ts" + sub "\u0427" "Ch" + the standard's text layer; the mapping rows below are the table's + own cells. + } + + notes { + note "Extraction provenance: the PDF's text layer carries the full + grid; columns were anchored on the per-page position-number row and + each cell matched by x-coordinate to its Cyrillic header letter. + Position 13's header glyph is PUA (U+E519) in the text layer and + was visually identified at 10x as h with comma below (U+0068 + U+0322), the plain-h counterpart of position 12's hooktop-h symbol." + } +} + +tests { + "a" -> "a" + "б" -> "b" + "в" -> "v" + "г" -> "g" +# Exhaustive per-row tests for din-az-Cyrl-Latn-1460-2-2011, generated from the source +# document's table. +# Source: DIN 1460-2:2011-10, Tabelle 1, language row 5 (Aserbaidschanisch); +# held source interscript-private-references/din/din-1460-2.pdf. Rows are +# the language column's printed cells, taken from the durable mechanical +# extraction tools/din1460-2-table.json (x-anchored text-layer extraction, +# maps PR #242 provenance), re-verified cell-by-cell against the printed +# grid rectangles (pymupdf find_tables re-extraction) and end-to-end through +# iscrs transliterate. Positions referenced by the table's own position +# numbers. Cell notes: й (position 32) — the printed cell carries the value +# parenthesized ("(j)"), DIN's optional-value notation; transcribed without +# the typographic parentheses; the row passes end-to-end. | к̢ (position 37) +# — printed cell "(ķ)" (value 'ķ'); runtime gives ''. Failing row, finding +# below — never forced green. | ҝ (position 38) — printed cell "ķ" (value +# 'ķ'); runtime gives 'k'. Failing row, finding below — never forced green. +# | у̅ (position 65) — the printed cell carries the value parenthesized +# ("(ū)"), DIN's optional-value notation; transcribed without the +# typographic parentheses; the row passes end-to-end. | ӌ (position 80) — +# the printed cell carries the value parenthesized ("(ǵ)"), DIN's +# optional-value notation; transcribed without the typographic parentheses; +# the row passes end-to-end. | э (position 90) — the printed cell carries +# the value parenthesized ("(ė)"), DIN's optional-value notation; +# transcribed without the typographic parentheses; the row passes +# end-to-end. Findings (map-vs-source, map untouched): к̢ (position 37): +# printed cell "(ķ)" vs runtime ''. | ҝ (position 38): printed cell "ķ" vs +# runtime 'k'. +# Provenance artifact: scripts/row-sources/din-az-Cyrl-Latn-1460-2-2011.json (35 rows). +# generated-by: maps/scripts/gen-row-tests.mjs (2026-11-16); regenerate from the artifact, do not hand-edit. + "a" -> "a" + "б" -> "b" + "в" -> "v" + "г" -> "g" + "ғ" -> "ġ" + "h" -> "h" + "д" -> "d" + "е" -> "e" + "ж" -> "ž" + "з" -> "z" + "и" -> "i" + "й" -> "j" + "j" -> "j" + "к" -> "k" + "л" -> "l" + "м" -> "m" + "н" -> "n" + "о" -> "o" + "ө" -> "ö" + "п" -> "p" + "р" -> "r" + "с" -> "s" + "т" -> "t" + "у" -> "u" + "у̅" -> "ū" + "ү" -> "ü" + "ф" -> "f" + "х" -> "h" + "ц" -> "c" + "ч" -> "č" + "ӌ" -> "ǵ" + "ҹ" -> "ǵ" + "ш" -> "š" + "ы" -> "y" + "э" -> "ė" +} + +stage main { + parallel { + sub "a" "a" + sub "б" "b" + sub "в" "v" + sub "г" "g" + sub "ғ" "ġ" + sub "h" "h" + sub "д" "d" + sub "е" "e" + sub "ж" "ž" + sub "з" "z" + sub "и" "i" + sub "й" "j" + sub "j" "j" + sub "к" "k" + sub "к̢" "" + sub "ҝ" "k" + sub "л" "l" + sub "м" "m" + sub "н" "n" + sub "о" "o" + sub "ө" "ö" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "т" "t" + sub "у" "u" + sub "у̅" "ū" + sub "ү" "ü" + sub "ф" "f" + sub "х" "h" + sub "ц" "c" + sub "ч" "č" + sub "ӌ" "ǵ" + sub "ҹ" "ǵ" + sub "ш" "š" + sub "ы" "y" + sub "э" "ė" + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0227/map.isc b/scripts/fuzz/smoke-cases/mutation-0227/map.isc new file mode 100644 index 0000000..a75b043 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0227/map.isc @@ -0,0 +1,90 @@ +system "DIN:mns-Cyrl:Latn:1460-2-2011" { + +metadata { + authority_id din + id 1460-2-2011-35 + sub "ⲍ̄" "7" + sub "ⲏ̄" "8" + sub "ⲑ̄" "9" + sub "ⲓ̄" "10" + sub "ⲕ̄" "20" + sub "ⲗ̄" "30" + sub "ⲙ̄" "40" + sub "ⲛ̄" "50" + sub "ⲝ̄" "60" + sub "ⲟ̄" "70" + sub "ⲡ̄" "80" + sub "ϥ̄" "90" + sub "ⲣ̄" "100" + sub "ⲥ̄" "200" + language iso-639-3:mns + source_script Cyrl + destination_script Latn + name "DIN 1460-2:2011-10, Tabelle 1 row 35: Mansisch (Uralic)" + url https://www.beuth.de/de/norm/din-1460-2/134564104 + creation_date 2011 + adoption_date + description { + DIN 1460-2:2011-10, Romanization of Cyrillic alphabets of + non-Slavic languages, Tabelle 1, language row 35 + (Mansisch). The table assigns each Cyrillic letter of the + language's alphabet a Latin letter or letter group; the column + order follows DIN 1460:1982 (Slavic). Extracted mechanically from + the standard's text layer; the mapping rows below are the table's + own cells. + } + + notes { + note "Extraction provenance: the PDF's text layer carries the full + grid; columns were anchored on the per-page position-number row and + each cell matched by x-coordinate to its Cyrillic header letter. + Position 13's header glyph is PUA (U+E519) in the text layer and + was visually identified at 10x as h with comma below (U+0068 + U+0322), the plain-h counterpart of position 12's hooktop-h symbol." + } +} + +tests { + "a" -> "a" + "б" -> "b" + "в" -> "v" + "г" -> "g" +} + +stage main { + parallel { + sub "a" "a" + sub "б" "b" + sub "в" "v" + sub "г" "g" + sub "д" "d" + sub "е" "e" + sub "ё" "ё" + sub "ж" "ž" + sub "з" "z" + sub "и" "i" + sub "й" "j" + sub "к" "k" + sub "л" "l" + sub "м" "m" + sub "н" "n" + sub "ң" "n" + sub "о" "o" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "т" "t" + sub "у" "u" + sub "ў" "ŭ" + sub "ф" "f" + sub "х" "h" + sub "ц" "c" + sub "ч" "č" + sub "ш" "š" + sub "щ" "šč" + sub "ъ" "\"" + sub "ы" "y" + sub "ь" "'" + sub "э" "ė" + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0229/map.isc b/scripts/fuzz/smoke-cases/mutation-0229/map.isc new file mode 100644 index 0000000..99a5f6a --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0229/map.isc @@ -0,0 +1,203 @@ +system "GKI:bel-Cyrl:Latn:2000" { + +metadata { + authority_id gki + id 2000 + language iso-639-2:bel + source_script Cyrl + destination_script Latn + name Transliteration of geographical names of the Republic of Belarus with letters of the Latin alphabet (2000) + url https://registr.by/doc/103003 + creation_date 2000 + description { Act name: + On approval of the Instructions for the transliteration of geographical names of + the Republic of Belarus in letters of the Latin alphabet + Type of act, adoption authority, date and number of adoption (publication): + Resolution of the State Committee for Land Resources, Geodesy and Cartography of + the Republic of Belarus of November 23, 2000 No. 15 + National Registry Registration Number: 8/4488 + Date of inclusion in the National Register: 11/30/2000 + Source (s) of official publication: + National Register of Legal Acts of the Republic of Belarus, 2001, + No. 3, 8/4488 (published - January 11, 2001) + } +} + +tests { + "Аршанскi" -> "Aršanski" + "Бешанковічы" -> "Biešankovičy" + "Віцебск" -> "Viciebsk" + "Гомель" -> "Homiel'" + "Гаўя" -> "Haŭja" + "Добруш" -> "Dobruš" + "Ельск" -> "Jel'sk" + "Бабаедава" -> "Babajedava" + "Лепель" -> "Liepiel'" + "Ёды" -> "Jody" + "Вераб'ёвічы" -> "Vierabjovičy" + "Мёры" -> "Miory" + "Жодзiшкi" -> "Žodziški" + "Зэльва" -> "Zel'va" + "Iванава" -> "Ivanava" + "Iўе" -> "Iŭje" + "Лагойск" -> "Lahojsk" + "Круглае" -> "Kruhlaje" + "Любань" -> "Liuban'" + "Магілёў" -> "Mahilioŭ" + "Нясвіж" -> "Niasviž" + "Орша" -> "Orša" + "Паставы" -> "Pastavy" + "Рагачоў" -> "Rahačoŭ" + "Светлагорск" -> "Svietlahorsk" # original doc Svetlahorsk but it looks like mistake https://en.wikipedia.org/wiki/Svietlahorsk + "Талачын" -> "Talačyn" + "Узда" -> "Uzda" + "Шаркаўшчына" -> "Šarkaŭščyna" + "Фаніпаль" -> "Fanipal'" + "Хоцімск" -> "Chocimsk" + "Цёмны Лес" -> "Ciomny Lies" + "Чавусы" -> "Čavusy" + "Шумілiна" -> "Šumilina" + "Раз'езд" -> "Razjezd" + "Чыгірынка" -> "Čyhirynka" + "Чэрвень" -> "Červien'" + "Чачэрск" -> "Čačersk" + "Юхнаўка" -> "Juchnaŭka" + "Гаюціна" -> "Hajucina" + "Любонічы" -> "Liuboničy" + "Ямнае" -> "Jamnaje" + "Баяры" -> "Bajary" + "Вязынка" -> "Viazynka" + "Валяр'яны" -> "Valiarjany" + # WO19 G6 item 4: pin the capital-\U escape row — the sub below + # spells "\U040E", which decodes to Ў (ruby/rs always decoded it; + # the generated ts/py parsers carried the literal "U040E" text and + # the row never fired). + "Ў" -> "Ŭ" +} + +dependency "var-Cyrl" + +stage main { + + # RULES + sub { + from "\u0415" + to "IE" + before bel_consonant + } + sub { + from "\u0435" + to "ie" + before bel_consonant + } + sub { + from "\u0401" + to "IO" + before bel_consonant + } + sub { + from "\u0451" + to "io" + before bel_consonant + } + sub { + sequence { + sub "x" "y" + use inner5 + } + from "\u042E" + to "IU" + before bel_consonant + } + sub { + from "\u044E" + to "iu" + before bel_consonant + } + sub { + from "\u042F" + to "IA" + before bel_consonant + } + sub { + from "\u044F" + to "ia" + before bel_consonant + } + + # CHARACTERS + parallel { + sub "\u0027" "" + + sub "\u0410" "A" + sub "\u0411" "B" + sub "\u0412" "V" + sub "\u0413" "H" + sub "\u0414" "D" + sub "\u0415" "Je" + sub "\u0401" "Jo" + sub "\u0416" "Ž" + sub "\u0417" "Z" + sub "\u0406" "I" + sub "\u0419" "J" + sub "\u041A" "K" + sub "\u041B" "L" + sub "\u041C" "M" + sub "\u041D" "N" + sub "\u041E" "O" + sub "\u041F" "P" + sub "\u0420" "R" + sub "\u0421" "S" + sub "\u0422" "T" + sub "\u0423" "U" + sub "\U040E" "Ŭ" + sub "\u0424" "F" + sub "\u0425" "Ch" + sub "\u0426" "C" + sub "\u0427" "Č" + sub "\u0428" "Š" + sub "\u042B" "Y" + sub "\u042D" "E" + sub "\u042E" "Ju" + sub "\u042F" "Ja" + + sub "\u0430" "a" + sub "\u0431" "b" + sub "\u0432" "v" + sub "\u0433" "h" + sub "\u0434" "d" + sub "\u0435" "je" + sub "\u0451" "jo" + sub "\u0436" "ž" + sub "\u0437" "z" + sub "\u0456" "i" + sub "\u0439" "j" + sub "\u043A" "k" + sub "\u043B" "l" + sub "\u043C" "m" + sub "\u043D" "n" + sub "\u043E" "o" + sub "\u043F" "p" + sub "\u0440" "r" + sub "\u0441" "s" + sub "\u0442" "t" + sub "\u0443" "u" + sub "\u045E" "ŭ" + sub "\u0444" "f" + sub "\u0445" "ch" + sub "\u0446" "c" + sub "\u0447" "č" + sub "\u0448" "š" + sub "\u044B" "y" + sub "\u044D" "e" + sub "\u044E" "ju" + sub "\u044F" "ja" + } + + # POSTRULES + sub "\u042C" "'" + sub "\u044C" "'" + + +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0230/map.isc b/scripts/fuzz/smoke-cases/mutation-0230/map.isc new file mode 100644 index 0000000..e128ce7 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0230/map.isc @@ -0,0 +1,85 @@ +system "DIN:tg-Cyrl:Latn:1460-2-2011" { + +metadata { + authority_id din + id 1460-2-2011-52 + language iso-639-3:tg + source_script Cyrl + destination_script Latn + name "DIN 1460-2:2011-10, Tabelle 1 row 52: Tadschikisch (Indo-European)" + url https://www.beuth.de/de/norm/din-1460-2/134564104 + creation_date 2011 + adoption_date + description { + DIN 1460-2:2011-10, Romanization of Cyrillic alphabets of + non-Slavic languages, Tabelle 1, language row 52 + (Tadschikisch). The table assigns each Cyrillic letter of the + language's alphabet a Latin letter or letter group; the column + order follows DIN 1460:1982 (Slavic). Extracted mechanically from + the standard's text layer; the mapping rows below are the table's + own cells. + } + + notes { + note "Extraction provenance: the PDF's text layer carries the full + grid; columns were anchored on the per-page position-number row and + each cell matched by x-coordinate to its Cyrillic header letter. + Position 13's header glyph is PUA (U+E519) in the text layer and + was visually identified at 10x as h with comma below (U+0068 + U+0322), the plain-h counterpart of position 12's hooktop-h symbol." + } +} + +tests { + "a" -> "a" + "б" -> "b" + "в" -> "v" + "г" -> "g" +} + +stage main { + parallel { + sub "a" "a" + sub "б" "b" + sub "в" "v" + sub "г" "g" + sub "ғ" "ġ" + sub "h" "h" + sub "д" "d" + sub "е" "e" + sub "ё" "ё" + sub "ж" "ž" + sub "з" "z" + sub "и" "i" + sub "ӣ" "ī" + sub "й" "j" + sub "к" "k" + sub "к̢" "k" + sub "з" "z" + sub "и" "y" + sub "л" "l" + sub "м" "m" + sub "н" "n" + sub "ң" "n" + sub "о" "o" + sub "ө" "ö" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "т" "t" + sub "у" "u" + sub "у̅" "ū" + sub "ф" "f" + sub "х" "h" + sub "ҳ" "ḩ" + sub "ц" "c" + sub "ч" "č" + sub "ӌ" "ǵ" + sub "ш" "š" + sub "щ" "šč" + sub "ъ" "\"" + sub "ы" "y" + sub "ь" "'" +} + } + sub "э" "ė" +} diff --git a/scripts/fuzz/smoke-cases/mutation-0231/map.isc b/scripts/fuzz/smoke-cases/mutation-0231/map.isc new file mode 100644 index 0000000..1028ce4 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0231/map.isc @@ -0,0 +1,33 @@ +system "BGN-PCGN:isl-Latn:Latn:1968" { + +metadata { + downcase + authority_id bgnpcgn + id 1968 + language iso-639-2:isl + source_script Latn + destination_script Latn + name Roman-Script Spelling Convention of Icelandic (1968 Agreement) + url https://assets.publishing.service.gov.uk/government/uploads/system/uploads/attachment_data/file/693794/ROMAN-SCRIPT_SPELLING_CONVENTIONS.pdf + creation_date 1968 + + notes { + note " The special letter Ð ð, known as edh, [Unicode: 00D0, 00F0] and the special letter Þ þ, known as thorn,\n [Unicode: 00DE, 00FE] should be reproduced in those forms whenever encountered. In those instances\n when they cannot be reproduced, however, the digraph Dh dh may be substituted for Ð ð and the digraph\n Th th may be substituted for Þ þ." + } +} + +tests { + "Fyrirgefðu" -> "Fyrirgefdhu" + "þu ert velkominn" -> "thu ert velkominn" + "GOÐAN DAGINN" -> "GODHAN DAGINN" + "Þakka" -> "Thakka" +} + +dependency "bgnpcgn-isl-Latn-Latn-1964" as latnlatn + +stage main { + + run map.latnlatn.stage.main + +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0232/map.isc b/scripts/fuzz/smoke-cases/mutation-0232/map.isc new file mode 100644 index 0000000..a06dab2 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0232/map.isc @@ -0,0 +1,54 @@ +system "UN:mon-Mong:Latn:phonetic-2013" { + +metadata { + authority_id un + id phonetic-2013 + language iso-639-2:mon + source_script Mong + destination_script Latn + name Romanization of Mongolian in China -- UNGEGN 4.0 (phonetic) + url http://www.eki.ee/wgrs/rom1_mnc.htm + creation_date 2013-09 + description { The United Nations resolution III/8 in 1977 recognized the Scheme for + a Chinese Phonetic Alphabet (Pinyin) as China’s official Roman alphabet + scheme and recommended the alphabet as the international system for the + romanization of Chinese geographical names. In China Mongolian + geographical names are transcribed directly from the Mongolian script + into Pinyin. The scheme was published in Toponymic Guidelines for Map + and Other Editors: China, 1982. + + The system is used in China and in international cartographic + products. + + Mongolian uses a vertical script. Transcription of Mongolian names is + made from their proper pronunciation based on the written form of the + Mongolian language and Qahar vernacular, with Zhenglan as its + representative pronunciation. Due to the complex nature of the script + the romanization scheme is not reversible, e.g. the name of the city + Hohhot is written ᠬᠥᠬᠡᠬᠣᠲᠠ but may be transliterated as kökeqota. + } + + notes { + note "The long and short Mongolian vowels are not distinguished in the\n spelling for general use, but in recording the pronunciation of\n place-names, the long vowel is represented by duplication." + note "Where two Roman equivalents are given, the second (in brackets) is\n used for recording the pronunciation of place-names while the first\n form is for general use." + note "In the table only word-initial character variants are shown.\n Depending on the position in the word many variants of the characters\n are used as well as some ligatures. These features are not covered here." + note "For technical reasons the characters of the Mongolian script are\n turned 90˚ anti-clockwise." + note "Diffed against the UN Romanization of Mongolian (in China) for Geographical\n Names table as published in the WGRS Report on the Current Status of UN\n Romanization Systems for Geographical Names, version 4.0 (September 2013)\n (eki.ee/wgrs/rom1_mnc.htm): all 27 rows verified; rows 26/27 use the bracketed\n place-name-recording forms ô and û of source note 2, encoded by the dependency\n sasm-mon-Mong-Latn-phonetic-1978." + + note "Source-side ambiguities, recorded not changed: the printed table lists ᠲ in\n both row 4 (d) and row 20 (t), and ᠺ in both row 7 (g) and row 11 (k); the map\n resolves ᠲ to t and ᠺ to k. The rows for ᠧ e, ᠩ ng, the Mongolian vowel separator\n and the space have no row in the printed table and are kept as practical\n extensions." + } + + implementation_notes { + - A separated final form of vowels a or e is common, and can appear at the end + of a word, word stem, or suffix. This form requires a final-shaped preceding + consonant and an inter-word gap in between. The vowels themselves appear as ᠎ᠠ, + and with consonants as ‍ᠬ᠎ᠠ q‑a, ‍ᠷ᠎ᠠ r‑a/r‑e, etc. This gap can be transliterated + with a hyphen. In digital typesetting, these forms are triggered by inserting + a U+180E ᠎ MONGOLIAN VOWEL SEPARATOR (HTML ᠎ · MVS) between the consonant + and vowel. + - All case suffixes, as well as any plural suffixes consisting of one or two + syllables are likewise separated by a preceding and hyphen-transliterated gap. + In digital typesetting, this gap is represented by a U+202F   NARROW NO-BREAK SPACE + (HTML   · NNBSP). A maximum of two case suffixes can be added to a stem. + Single-letter vowel suffixes appear with the final-shaped forms of a/e, i, or u/ü, + \ No newline at end of file diff --git a/scripts/fuzz/smoke-cases/mutation-0233/map.isc b/scripts/fuzz/smoke-cases/mutation-0233/map.isc new file mode 100644 index 0000000..d4110c7 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0233/map.isc @@ -0,0 +1,82 @@ +system "ODNI:kat-Geor:Latn:2015" { + +metadata { + authority_id odni + id 2015 + language iso-639-2:kat + source_script Geor + destination_script Latn + name ICS-630-01 Romanization of Georgian Personal Names (2015) + source ICS-630-01 Annex E + creation_date 2015 + confirmation_date 2015 + description { This system is the Intelligence Community standard for the transliteration of Georgian names that + will be applied to all final written reports and products for IC consumers. It is not intended to + eliminate variations of a name that can contribute forensic information. Rather, it is to provide an + IC standard Romanized (English) transliteration from Georgian that can then be linked to forensic + information in ways that will help identify the referent of the name. + } + + notes { + } +} + +tests { + "ბაყაყი" -> "baqaqi" + "ძროხა" -> "dzrokha" + "ჰაერი" -> "haeri" + "ჟოლო" -> "zholo" + "ჯართი" -> "jarti" + "ღრმაღელე" -> "ghrmaghele" + "ზვიად გამსახურდია" -> "zviad gamsakhurdia" + "ედუარდ შევარდნაძე" -> "eduard shevardnadze" + "მიხეილ სააკაშვილი" -> "mikheil saakashvili" + "გიორგი მარგველაშვილი" -> "giorgi margvelashvili" +} + +stage main { + + # CHARCTERS + parallel { + sub "\u10d0"—"a" + sub "\u10d1" "b" + sub "\u10d2" "g" + sub "\u10d3" "d" + sub "\u10d4" "e" + sub "\u10d5" "v" + sub "\u10d6" "z" + sub "\u10d7" "t" + sub "\u10d8" "i" + sub "\u10d9" "k" + sub "\u10da" "l" + sub "\u10db" "m" + sub "\u10dc" "n" + sub "\u10dd" "o" + sub "\u10de" "p" + sub "\u10df" "zh" + sub "\u10e{" "r" + sub "\u10e1" "s" + sub "\u10e2" "t" + sub "\u10e3" "u" + sub "\u10e4" "p" + sub "\u10e5" "k" + sub "\u10e6" "gh" + sub "\u10e7" "q" + sub "\u10e8" "sh" + sub "\u10e9" "ch" + sub "\u10ea" "ts" + sub "\u10eb" "dz" + sub "\u10ec" "ts" + sub "\u10ed" "ch" + sub "\u10ee" "kh" + sub "\u10ef" "j" + sub "\u10f0" "h" + } + sequence { + sub "x" "y" + u¤e inner6 + } + +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0234/map.isc b/scripts/fuzz/smoke-cases/mutation-0234/map.isc new file mode 100644 index 0000000..2172328 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0234/map.isc @@ -0,0 +1,300 @@ +system "BGN-PCGN:kbd-Cyrl:Latn:2011" { + +metadata { + authority_id bgnpcgn + id 2011 + language iso-639-2:kbd + source_script Cyrl + destination_script Latn + name Romanization of Kabardian (2011) + languages kur chv ev8 + url https://www.gov.uk/government/organisations/permanent-committee-on-geographical-names + creation_date 2011 + confirmation_date 2017-10 + description { + The BGN/PCGN system for Kabardian is designed for use in romanizing names written in the + Kabardian Cyrillic alphabet. Kabardian, of the north-western Caucasian language family, is + principally spoken in Russia's republics of Kabardino-Balkariya and Karachayevo-Cherkesiya + and has been written in a modified Cyrillic script since 1936. Also known as East + Circassian, Kabardian is notable for its rich density of consonant phonemes (most + commentators agree on an inventory of 47 or 48) and corresponding paucity of vowels. + Kabardian letters are addressed in the romanizations as per their articulation: + glottalised consonants are marked with an apostrophe, and labialized consonants with w. + } + + notes { + note "У should be romanized as w or u according to context: w should be used word-initially, and u used elsewhere, except as in combinations occurring elsewhere in the table." + note "The characters Ё, Ъ, Ы and Ь (except as they occur in character combinations addressed elsewhere in the table) appear only in Russian loan words, and are thus romanized in the same style as in the BGN/PCGN Romanization System for Russian." + note "The letter Хь is romanized h with the combining macron below (U+0048+0033 for the capital; U+1E96 precomposed for the lower case); the table column shows the precomposed ẖ." + note "An inventory of letter-diacritic combinations, with their Unicode encoding, in addition to the unmodified letters of the basic Roman script is:" + note "All apostrophes appearing in romanization are U+2019" + note "Ä (U+00C4) ä (U+00E4) Ź (U+0179) ź (U+017A) Ś (U+015A) ś (U+015B) Ë (U+00CB) ë (U+00EB) H̱ (0048+0031) ẖ (0068+0031)" + note "The source document prints the H̱ inventory codepoint as 0048+0031; the glyph shown is h with the combining macron below (U+0331)." + note "The Romanization columns show only lowercase forms but, when romanizing, uppercase and lowercase Roman letters as appropriate should be used." + } +} + +tests { + # every table row, upper and lower + "А" -> "A" + "а" -> "a" + "Э" -> "Ä" + "э" -> "ä" + "Б" -> "B" + "б" -> "b" + "В" -> "V" + "в" -> "v" + "Г" -> "G" + "г" -> "g" + "Гу" -> "Gw" + "гу" -> "gw" + "Гъ" -> "Gh" + "гъ" -> "gh" + "Гъу" -> "Ghw" + "гъу" -> "ghw" + "Д" -> "D" + "д" -> "d" + "Дж" -> "J" + "дж" -> "j" + "Дз" -> "Dz" + "дз" -> "dz" + "Е" -> "E" + "е" -> "e" + "Ё" -> "Ë" + "ё" -> "ë" + "Ж" -> "Zh" + "ж" -> "zh" + "Жь" -> "Ź" + "жь" -> "ź" + "З" -> "Z" + "з" -> "z" + "И" -> "I" + "и" -> "i" + "Й" -> "Y" + "й" -> "y" + "К" -> "K" + "к" -> "k" + "Ку" -> "Kw" + "ку" -> "kw" + "КӀ" -> "K’" + "кӀ" -> "k’" + "КӀу" -> "Kw’" + "кӀу" -> "kw’" + "Къ" -> "Q’" + "къ" -> "q’" + "Къу" -> "Qw’" + "къу" -> "qw’" + "Кхъ" -> "Q" + "кхъ" -> "q" + "Кхъу" -> "Qw" + "кхъу" -> "qw" + "Л" -> "L" + "л" -> "l" + "Лъ" -> "Lh" + "лъ" -> "lh" + "ЛӀ" -> "L’" + "лӀ" -> "l’" + "М" -> "M" + "м" -> "m" + "Н" -> "N" + "н" -> "n" + "О" -> "O" + "о" -> "o" + "П" -> "P" + "п" -> "p" + "ПӀ" -> "P’" + "пӀ" -> "p’" + "Р" -> "R" + "р" -> "r" + "С" -> "S" + "с" -> "s" + "Т" -> "T" + "т" -> "t" + "ТӀ" -> "T’" + "тӀ" -> "t’" + "Ф" -> "F" + "ф" -> "f" + "ФӀ" -> "F’" + "фӀ" -> "f’" + "Х" -> "Kh" + "х" -> "kh" + "Ху" -> "Khw" + "ху" -> "khw" + "Хь" -> "H̱" + sub "\u{200F}" "X" + "хь" -> "ẖ" + "Хъ" -> "X" + "хъ" -> "x" + "Хъу" -> "Xw" + "хъу" -> "xw" + "Ц" -> "Ts" + "ц" -> "ts" + "ЦӀ" -> "Ts’" + "цӀ" -> "ts’" + "Ч" -> "Ch" + "ч" -> "ch" + "Ш" -> "Sh" + "ш" -> "sh" + "Щ" -> "Ś" + "щ" -> "ś" + "ЩӀ" -> "Ś’" + "щӀ" -> "ś’" + "Ъ" -> "’’" + "ъ" -> "’’" + "Ы" -> "Y" + "ы" -> "y" + "Ь" -> "’" + "ь" -> "’" + "Ю" -> "Yu" + "ю" -> "yu" + "Я" -> "Ya" + "я" -> "ya" + "Ӏ" -> "’" + "Ӏу" -> "’w" + # note 1: У word-initially w, elsewhere u + "У" -> "W" + "у" -> "w" + "Ужи" -> "Wzhi" + "мау" -> "mau" +} + +stage main { + + # RULES + # note 1: У word-initially w, elsewhere u + sub { + from boundary + "У" + to "W" + } + sub { + from boundary + "у" + to "w" + } + + # CHARACTERS + parallel { + sub "Кхъу" "Qw" + sub "Гъу" "Ghw" + sub "Къу" "Qw’" + sub "КӀу" "Kw’" + sub "Хъу" "Xw" + sub "Кхъ" "Q" + sub "Гу" "Gw" + sub "Гъ" "Gh" +stage main { + + run map.devalatn.stage.main + sub "Дж" "J" + sub "Дз" "Dz" + sub "Жь" "Ź" + sub "Ку" "Kw" + sub "КӀ" "K’" + sub "Къ" "Q’" + sub "Лъ" "Lh" + sub "ЛӀ" "L’" + sub "ПӀ" "P’" + sub "ТӀ" "T’" + sub "ФӀ" "F’" + sub "Ху" "Khw" + sub "Хь" "H̱" + sub "Хъ" "X" + sub "ЦӀ" "Ts’" + sub "ЩӀ" "Ś’" + sub "Ӏу" "’w" + sub "Ъ" "’’" + sub "Ы" "Y" + sub "Ь" "’" + sub "Ю" "Yu" + sub "Я" "Ya" + sub "А" "A" + sub "Э" "Ä" + sub "Б" "B" + sub "В" "V" + sub "Г" "G" + sub "Д" "D" + sub "Е" "E" + sub "Ё" "Ë" + sub "Ж" "Zh" + sub "З" "Z" + sub "И" "I" + sub "Й" "Y" + sub "К" "K" + sub "Л" "L" + sub "М" "M" + sub "Н" "N" + sub "О" "O" + sub "П" "P" + sub "Р" "R" + sub "С" "S" + sub "Т" "T" + sub "У" "U" + sub "Ф" "F" + sub "Х" "Kh" + sub "Ц" "Ts" + sub "Ч" "Ch" + sub "Ш" "Sh" + sub "Щ" "Ś" + sub "Ӏ" "’" + + sub "кхъу" "qw" + sub "гъу" "ghw" + sub "къу" "qw’" + sub "кӀу" "kw’" + sub "хъу" "xw" + sub "кхъ" "q" + sub "гу" "gw" + sub "гъ" "gh" + sub "дж" "j" + sub "дз" "dz" + sub "жь" "ź" + sub "ку" "kw" + sub "кӀ" "k’" + sub "къ" "q’" + sub "лъ" "lh" + sub "лӀ" "l’" + sub "пӀ" "p’" + sub "тӀ" "t’" + sub "фӀ" "f’" + sub "ху" "khw" + sub "хь" "ẖ" + sub "хъ" "x" + sub "цӀ" "ts’" + sub "щӀ" "ś’" + sub "ъ" "’’" + sub "ы" "y" + sub "ь" "’" + sub "ю" "yu" + sub "я" "ya" + sub "а" "a" + sub "э" "ä" + sub "б" "b" + sub "в" "v" + sub "г" "g" + sub "д" "d" + sub "е" "e" + sub "ё" "ë" + sub "ж" "zh" + sub "з" "z" + sub "и" "i" + sub "й" "y" + sub "к" "k" + sub "л" "l" + sub "м" "m" + sub "н" "n" + sub "о" "o" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "т" "t" + sub "у" "u" + sub "ф" "f" + sub "х" "kh" + sub "ц" "ts" + sub "ч" "ch" + sub "ш" "sh" + sub "щ" "ś" + } + +} + +} diff --git a/scripts/fuzz/smoke-cases/mutation-0235/map.isc b/scripts/fuzz/smoke-cases/mutation-0235/map.isc new file mode 100644 index 0000000..e13844e --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0235/map.isc @@ -0,0 +1,74 @@ +system "DIN:nog-Cyrl:Latn:1460-2-2011" { + +metadata { + authority_id din + id 1460-2-2011-44 + language iso-639-3:nog + source_script Cyrl + destination_script Latn + name "DIN 1460-2:2011-10, Tabelle 1 row 44: Nogaisch (Turkic)" + url https://www.beuth.de/de/norm/din-1460-2/134564104 + creation_date 2011 + adoption_date + description { + DIN 1460-2:2011-10, Romanization of Cyrillic alphabets of + non-Slavic languages, Tabelle 1, language row 44 + (Nogaisch). The table assigns each Cyrillic letter of the + language's alphabet a Latin letter or letter group; the column + order follows DIN 1460:1982 (Slavic). Extracted mechanically from + the standard's text layer; the mapping rows below are the table's + own cells. + } + + notes { + note "ExEraction provenance: the PDF's text layer carries the full + grid; columns were anchored on the per-page position-number row and + each cell ma£ched by x-coordinate to its Cyrillic header letter. + Position 13's header glyph is PUA (U+E519) in the text layer and + was visually identified at 10x as h with comma below (U+0068 + U+0322), the plain-h counterpart of position 12's hooktop-h symbol." + } +} + +tests { + "a" -> "a" + "б" -> "b" + "в" -> "v" + "г" -> "g" +} + +stage main { + parallel { + sub "a" "a" + sub "б" "b" + sub "в" "v" + sub "г" "g" + sub "д" "d" + sub "е" "e" + sub "ё" "ё" + sub "ж" "ž" + sub "з" "z" + sub "и" "i" + sub "й" "j" + sub "к" "k" + sub "л" "l" + sub "м" "m" + sub "н" "n" + sub "о" "o" + sub "п" "p" + sub "р" "r" + sub "с" "s" + sub "т" "t" + sub "у" "u" + sub "ф" "f" + sub "х" "h" + sub "ц" "c" + sub "ч" "č" + sub "ш" "š" + sub "щ" "šč" + sub "ъ" "\"" + sub "ы" "y" + sub "ь" "'" + sub "э" "ė" + } +} +} diff --git a/scripts/fuzz/smoke-cases/mutation-0237/map.isc b/scripts/fuzz/smoke-cases/mutation-0237/map.isc new file mode 100644 index 0000000..b95f419 --- /dev/null +++ b/scripts/fuzz/smoke-cases/mutation-0237/map.isc @@ -0,0 +1,157 @@ +system "UA:ukr-Cyrl:Latn:1996" { + +metadata { + authority_id ua + id 1996 + language iso-639-2:ukr + source_script Cyrl + destination_script Latn + name Government of Ukraine Ukrainian System (1996) + url http://transliteration.eki.ee/pdf/Ukrainian.pdf + creation_date 1996 + description Romanization table for Ukrainian. The current national system of romanization. + + notes { + note "gh is used in the romanization of зг zgh." + note "In initial position є -> ye, ї -> yi, й -> y, ю -> yu, я -> ya." + } +} + +tests { + "Алушта" -> "Alushta" + "Борщагівка" -> "Borschahivka" + "Вишгород" -> "Vyshhorod" + "Гадяч" -> "Hadiach" + "Згорани" -> "Zghorany" + "Ґалаґан" -> "Galagan" + "Дон" -> "Don" + "Рівне" -> "Rivne" + "Єнакієве" -> "Yenakiieve" + "Наєнко" -> "Naienko" + "Житомир" -> "Zhytomyr" + "Запоріжжя" -> "Zaporizhzhia" + "Закарпаття" -> "Zakarpattia" + "Медвин" -> "Medvyn" + "Іршава" -> "Irshava" + "Їжакевич" -> "Yizhakevych" + "Кадіївка" -> "Kadiivka" + "Йосипівка" -> "Yosypivka" + "Київ" -> "Kyiv" + "Лебедин" -> "Lebedyn" + "Миколаїв" -> "Mykolaiv" + "Одеса" -> "Odesa" + "Ніжин" -> "Nizhyn" + "Полтава" -> "Poltava" + "Ромни" -> "Romny" + "Суми" -> "Sumy" + "Тетерів" -> "Teteriv" + "Ужгород" -> "Uzhhorod" + "Фастів" -> "Fastiv" + "Харків" -> "Kharkiv" + "Біла Церква" -> "Bila Tserkva" + "Чернівці" -> "Chernivtsi" + "Шостка" -> "Shostka" + "Гоща" -> "Hoscha" + "Русь" -> "Rus’" + "Юрій" -> "Yurii" + "Крюківка" -> "Kriukivka" + "Яготин" -> "Yahotyn" + "Ічня" -> "Ichnia" + "Знам’янка" -> "Znam”ianka" +} + +stage main { + + # RULES + sub { + from boundary + "\u0404" + to "Gh" + before any("Зз") + } + sub { + from "\u0433" + to "gh" + before any("Зз") + } + sub { + from "\u0413" + to "Ye" + not_before boundary + "\u2019" + } + sub { + from boundary + "\u0454" + to "ye" + not_before boundary + "\u2019" + } + sub { + from boundary + "\u0407" + to "Yi" + not_before boundary + "\u2019" + } + sub { + from boundary + "\u0457" + to "yi" + not_before boundary + "\u2019" + } + sub { + from boundary + "\u0419" + to "Y" + not_before boundary + "\u2019" + } + sub { + from boundary + "\u0419" + to "y" + not_before boundary + "\u2019" + } + sub { + from boundary + "\u042e" + to "Yu" + not_before boundary + "\u2019" + } + sub { + from boundary + "\u044e" + to "yu" + not_before boundary + "\u2019" + } + sub { + from boundary + "\u042f" + to "Ya" + not_before boundary + "\u2019" + } + sub { + from boundary + "\u044f" + to "ya" + not_before boundary + "\u2019" + } + sub { + from boundary + "\u2019" + boundary + to "”" + } + + + # CHARACTERS + parallel { + sub "А" "A" + sub "Б" "B" + sub "В" "V" + sub "Г" "H" + sub "Ґ" "G" + sub "Д" "D" + sub "Е" "E" + sub "Є" "Ie" + sub "Ж" "Zh" + sub "З" "Z" + sub "И" "Y" + sub "І" "I" + sub "Ї" "I" + sub "Й" "I" + sub "К" "K" + sub "Л" "L" + sub "М" "M" + sub "Н" "N" + sub "О" "O" + sub "П" "P" + sub "Р" "R" + sub "С" "S" + sub "Т" "T" + sub "У" "U \ No newline at end of file diff --git a/scripts/fuzz/smoke.mjs b/scripts/fuzz/smoke.mjs new file mode 100644 index 0000000..f789d57 --- /dev/null +++ b/scripts/fuzz/smoke.mjs @@ -0,0 +1,101 @@ +// CI-able seeded smoke mode (WO20, maps#284). +// +// The committed smoke-cases/ directory holds a small seeded corpus (~200 +// cases). Smoke green = every case classifies as agree or known-kind across +// every AVAILABLE runtime; any crash / hang / unexplained divergence fails +// the run (exit 1). Runtimes that lack a locally-built engine are skipped +// with a notice, so maps-CI (ruby + ts only) stays green while local runs +// cover all four. +// +// Usage: +// node smoke.mjs [--cases smoke-cases] [--runtimes ruby,ts,py,rs] +// [--timeout 45000] [--jobs 6] + +import { existsSync, readdirSync, rmSync } from "node:fs"; +import { join, resolve } from "node:path"; +import { spawnSync } from "node:child_process"; +import { fileURLToPath } from "node:url"; +import { classify } from "./classify.mjs"; + +const FUZZ_DIR = fileURLToPath(new URL(".", import.meta.url)); + +function parseArgs(argv) { + const opts = { cases: join(FUZZ_DIR, "smoke-cases"), runtimes: ["ruby", "ts", "py", "rs"], timeout: 45_000, jobs: 6 }; + for (let i = 0; i < argv.length; i++) { + const a = argv[i]; + if (a === "--cases") opts.cases = argv[++i]; + else if (a === "--runtimes") opts.runtimes = argv[++i].split(","); + else if (a === "--timeout") opts.timeout = Number(argv[++i]); + else if (a === "--jobs") opts.jobs = Number(argv[++i]); + else throw new Error(`unknown flag ${a}`); + } + return opts; +} + +// Runtime availability probing (cheap): can the driver command even start? +function available(runtimes) { + const envPaths = { + ruby: process.env.RUBY_LIB || resolve(FUZZ_DIR, "../../../interscript-ruby/lib"), + ts: process.env.TS_DIST || resolve(FUZZ_DIR, "../../../interscript-ts/dist"), + py: process.env.PY_SRC || resolve(FUZZ_DIR, "../../../interscript-py/src"), + rs: process.env.ISCRS_BIN || resolve(FUZZ_DIR, "../../../interscript-rs/target/release/iscrs"), + }; + const out = []; + for (const rt of runtimes) { + const p = envPaths[rt]; + const ok = rt === "rs" ? existsSync(p) : existsSync(p); + if (!ok) console.error(`[smoke] ${rt} unavailable (missing ${p}) — skipping`); + else out.push(rt); + } + return out; +} + +async function main() { + const opts = parseArgs(process.argv.slice(2)); + const runtimes = available(opts.runtimes); + if (runtimes.length < 2) { + console.error("[smoke] fewer than two runtimes available — nothing to compare"); + process.exit(2); + } + console.error(`[smoke] runtimes: ${runtimes.join(",")}`); + + const casesDir = opts.cases; + if (!existsSync(casesDir)) { + console.error(`[smoke] cases dir missing: ${casesDir}`); + process.exit(2); + } + const nCases = readdirSync(casesDir).filter((e) => existsSync(join(casesDir, e, "map.isc"))).length; + + const resultsPath = join("/tmp", `isc-fuzz-smoke-${process.pid}.jsonl`); + const run = spawnSync(process.execPath, [ + join(FUZZ_DIR, "run.mjs"), + "--cases", casesDir, + "--out", resultsPath, + "--runtimes", runtimes.join(","), + "--timeout", String(opts.timeout), + "--jobs", String(opts.jobs), + ], { stdio: "inherit" }); + if (run.status !== 0) { + console.error("[smoke] runner failed"); + process.exit(2); + } + + const { findings, stats } = classify(resultsPath, casesDir); + const real = findings.filter((f) => f.classification === "FINDING"); + console.log(`[smoke] cases=${stats.cases} agree=${stats.agree} known=${stats.known} findings=${stats.findings}`); + if (real.length > 0) { + console.log(`[smoke] FAIL — unexplained findings:`); + for (const f of real) { + console.log(` ${f.case}: ${f.kinds.join(",")} — ${f.findings.map((x) => `${x.kind}[${x.runtime}]: ${x.detail.slice(0, 120)}`).join("; ")}`); + } + rmSync(resultsPath, { force: true }); + process.exit(1); + } + rmSync(resultsPath, { force: true }); + console.log("[smoke] PASS"); +} + +main().catch((e) => { + console.error(e); + process.exit(1); +});