Z32794

{
    "Z1K1": "Z2",
    "Z2K1": {
        "Z1K1": "Z6",
        "Z6K1": "Z32794"
    },
    "Z2K2": {
        "Z1K1": "Z14",
        "Z14K1": "Z32793",
        "Z14K3": {
            "Z1K1": "Z16",
            "Z16K1": "Z600",
            "Z16K2": "// https://github.com/amanoese/kana2ipa/tree/263a862500794c21a8146365b0aa7f148146dd15\n/* Copyright 2019 Seito Taka\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n *     http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nlet ipa = {\n  \"ア\"    :\"a\",\n  \"イ\"    :\"i\",\n  \"ウ\"    :\"ɯ\",\n  \"エ\"    :\"e\",\n  \"オ\"    :\"o\",\n  \"ャ\"    :\"ja\",\n  \"ュ\"    :\"jɯ\",\n  \"ョ\"    :\"jo\",\n  \"カ\"    :\"ka\",\n  \"キ\"    :\"kʲi\",\n  \"ク\"    :\"kɯ\",\n  \"ケ\"    :\"ke\",\n  \"コ\"    :\"ko\",\n  \"サ\"    :\"sa\",\n  \"シ\"    :\"ɕi\",\n  \"ス\"    :\"sɯ\",\n  \"セ\"    :\"se\",\n  \"ソ\"    :\"so\",\n  \"タ\"    :\"ta\",\n  \"チ\"    :\"t͡ɕi\",\n  \"ツ\"    :\"tsɯ\",\n  \"テ\"    :\"te\",\n  \"ト\"    :\"to\",\n  \"ナ\"    :\"na\",\n  \"ニ\"    :\"ɲi\",\n  \"ヌ\"    :\"nɯ\",\n  \"ネ\"    :\"ne\",\n  \"ノ\"    :\"no\",\n  \"ハ\"    :\"ha\",\n  \"ヒ\"    :\"çʲi\",\n  \"フ\"    :\"ɸɯ\",\n  \"ヘ\"    :\"he\",\n  \"ホ\"    :\"ho\",\n  \"マ\"    :\"ma\",\n  \"ミ\"    :\"mʲi\",\n  \"ム\"    :\"mɯ\",\n  \"メ\"    :\"me\",\n  \"モ\"    :\"mo\",\n  \"ヤ\"    :\"ja\",\n  \"ユ\"    :\"jɯ\",\n  \"ヨ\"    :\"jo\",\n  \"ラ\"    :\"ɾa\",\n  \"リ\"    :\"ɾʲi\",\n  \"ル\"    :\"ɾɯ\",\n  \"レ\"    :\"ɾe\",\n  \"ロ\"    :\"ɾo\",\n  \"ワ\"    :\"ɰa\",\n  \"ヰ\"    :\"i\",\n  \"ヱ\"    :\"e\",\n  \"ヲ\"    :\"o\",\n  \"ン\"    :\"N\",\n  \"ガ\"    :\"ɡa\",\n  \"ギ\"    :\"ɡʲi\",\n  \"グ\"    :\"ɡɯ\",\n  \"ゲ\"    :\"ɡe\",\n  \"ゴ\"    :\"ɡo\",\n  \"ザ\"    :\"dza\",\n  \"ジ\"    :\"ʤi\",\n  \"ズ\"    :\"dzɯ\",\n  \"ゼ\"    :\"dze\",\n  \"ゾ\"    :\"dzo\",\n  \"ダ\"    :\"da\",\n  \"ヂ\"    :\"ʤi\",\n  \"ヅ\"    :\"dzɯ\",\n  \"デ\"    :\"de\",\n  \"ド\"    :\"do\",\n  \"バ\"    :\"ba\",\n  \"ビ\"    :\"bʲi\",\n  \"ブ\"    :\"bɯ\",\n  \"ベ\"    :\"be\",\n  \"ボ\"    :\"bo\",\n  \"パ\"    :\"pa\",\n  \"ピ\"    :\"pʲi\",\n  \"プ\"    :\"pɯ\",\n  \"ペ\"    :\"pe\",\n  \"ポ\"    :\"po\"\n}\nlet ipa_small = {\n  \"キャ\"  :\"kʲa\",\n  \"キュ\"  :\"kʲɯ\",\n  \"キョ\"  :\"kʲo\",\n  \"シャ\"  :\"ʃa\",\n  \"シュ\"  :\"ʃɯ\",\n  \"ショ\"  :\"ʃo\",\n  \"チャ\"  :\"t͡ɕa\",\n  \"チュ\"  :\"t͡ɕɯ\",\n  \"チョ\"  :\"t͡ɕo\",\n  \"ニャ\"  :\"ɲa\",\n  \"ニュ\"  :\"ɲɯ\",\n  \"ニョ\"  :\"ɲo\",\n  \"ヒャ\"  :\"ça\",\n  \"ヒュ\"  :\"çɯ\",\n  \"ヒョ\"  :\"ço\",\n  \"ミャ\"  :\"mʲa\",\n  \"ミュ\"  :\"mʲɯ\",\n  \"ミョ\"  :\"mʲo\",\n  \"リャ\"  :\"ɾʲa\",\n  \"リュ\"  :\"ɾʲɯ\",\n  \"リョ\"  :\"ɾʲo\",\n  \"ギャ\"  :\"ɡʲa\",\n  \"ギュ\"  :\"ɡʲɯ\",\n  \"ギョ\"  :\"ɡʲo\",\n  \"ジャ\"  :\"ʤa\",\n  \"ジュ\"  :\"ʤɯ\",\n  \"ジョ\"  :\"ʤo\",\n  \"ヂャ\"  :\"ʤa\",\n  \"ヂュ\"  :\"ʤɯ\",\n  \"ヂョ\"  :\"ʤo\",\n  \"ビャ\"  :\"bʲa\",\n  \"ビュ\"  :\"bʲɯ\",\n  \"ビョ\"  :\"bʲo\",\n  \"ピャ\"  :\"pʲa\",\n  \"ピュ\"  :\"pʲɯ\",\n  \"ピョ\"  :\"pʲo\",\n  \"ファ\"  :\"ɸa\",\n  \"フィ\"  :\"ɸi\",\n  \"フゥ\"  :\"ɸɯ\",\n  \"フェ\"  :\"ɸe\",\n  \"フォ\"  :\"ɸo\",\n  \"チェ\"  :\"t͡ɕe\"\n}\n\nfunction hiragana2katakana(text) {\n//const _regexp = /\\p{Hiragana}/gu\n  /*\n3041..3096    ; Hiragana # Lo  [86] HIRAGANA LETTER SMALL A..HIRAGANA LETTER SMALL KE\n309D..309E    ; Hiragana # Lm   [2] HIRAGANA ITERATION MARK..HIRAGANA VOICED ITERATION MARK\n309F          ; Hiragana # Lo       HIRAGANA DIGRAPH YORI\n1B001..1B11F  ; Hiragana # Lo [287] HIRAGANA LETTER ARCHAIC YE..HIRAGANA LETTER ARCHAIC WU\n1B132         ; Hiragana # Lo       HIRAGANA LETTER SMALL KO\n1B150..1B152  ; Hiragana # Lo   [3] HIRAGANA LETTER SMALL WI..HIRAGANA LETTER SMALL WO\n1F200         ; Hiragana # So       SQUARE HIRAGANA HOKA\n  */\n  const _regexp = /[\\u3041-\\u3096\\u309D-\\u309E\\u309F\\u{1B001}-\\u{1B11F}\\u{1B132}\\u{1B150}-\\u{1B152}\\u{1F200}]/gu\n  return text.replace(_regexp,v=\u003E String.fromCharCode(+v.charCodeAt(0) + 0x60))\n}\nfunction kana2ipa(inText) {\n  if (inText.length \u003C= 0) {\n    return inText\n  }\n  let ipa_small_match = Object.keys(ipa_small).join('|').replace(/.*/,'($\u0026)')\n\n  let katakanaText = hiragana2katakana(inText)\n  // replace Basic Word\n  let bIpaString = katakanaText\n    .normalize('NFKC') // harf size to wide size\n    .replace(new RegExp(ipa_small_match,'g'),v=\u003E(ipa_small[v]||v))\n    .match(/./ug)\n    .map(v=\u003Eipa[v]||v)\n    .join('')\n\n  //important ん is Specialy word\n  let nIpaString = bIpaString\n     .replace(/N(p|b|m)/g,'m$1')\n     .replace(/N(t|d|t͡s|n)/gu,'n$1')\n     .replace(/N(k|ɡ)/g,'ŋ$1')\n     .replace(/N(ɽ)/g,'ṉ$1')\n     .replace(/(.)N(a|i|ɯ|e|o|s|h|j|w)/ug,'$1$1\\u0303$2')\n     .replace(/N/ug,'ɴ')\n     .normalize('NFC')\n\n  //convert Specialy word\n  let mIpaString = nIpaString\n     .replace(/ッ(.)/ug,'$1$1')\n     .replace(/mm/ug,'mː') // んの後にpの発音が来たとき用？\n     .replace(/nn/ug,'nː') // これはよくわかんない\n     .replace(/oɯ/ug,'oː') // おう　の発音はオーになる？\n     .replace(/(.)ー/ug,'$1ː')\n     .normalize('NFC')\n\n  return mIpaString\n}\n\nfunction Z32793( Z32793K1 ) {\n\treturn kana2ipa(Z32793K1)\n}"
        }
    },
    "Z2K3": {
        "Z1K1": "Z12",
        "Z12K1": [
            "Z11",
            {
                "Z1K1": "Z11",
                "Z11K1": "Z1002",
                "Z11K2": "IPA transcription from Japanese kana text, JS"
            }
        ]
    },
    "Z2K4": {
        "Z1K1": "Z32",
        "Z32K1": [
            "Z31"
        ]
    },
    "Z2K5": {
        "Z1K1": "Z12",
        "Z12K1": [
            "Z11"
        ]
    }
}