Module talk:th-translit/testcases

From Wiktionary, the free dictionary
Jump to navigation Jump to search

@Wyang Hi. A new test case has just arrived. ;) Could you please fix it? --Anatoli T. (обсудить/вклад) 11:34, 6 February 2016 (UTC)[reply]

Hooray! Wyang (talk) 13:30, 6 February 2016 (UTC)[reply]
@Wyang Thank you! Here's a fresher one - หฺมาย (mǎai), used in จดหมาย. --Anatoli T. (обсудить/вклад) 23:35, 6 February 2016 (UTC)[reply]
Fixed. :) Wyang (talk) 23:47, 6 February 2016 (UTC)[reply]

Phonemic only[edit]

@Hippietrail Hi. The module uses only phonemic Thai spellings, which can then be automatically transliterated in all occurrences in {{th-l}} or {{th-x}}, eg. บาดแผล (bàat-plɛ̌ɛ), เอร็ดอร่อย (à-rèt-à-rɔ̀i) when entries exist and they use {{th-pron}}. The entries themselves require phonemic spellings "บาด-แผฺล", "อะ-เหฺร็ด อะ-หฺร่อย" (which can be used in test cases), see entries. Note that multisyllabic words will never be transliterated and monosyllabic words can be transliterated incorrectly, if they are iiregular but {{th-l}} will work correctly on existing entries and will attempt to transliterate monosyllabic red-linked terms. I am going to remove your test cases, since the module as expected as far as these words are concerned. --Anatoli T. (обсудить/вклад) 03:39, 12 February 2016 (UTC)[reply]

I partially understand but OK by me. Some automatic transliteration is better than no automatic transliteration after all. Is this restriction documented yet? I know Lao, Thai, and Khmer are all ambiguous scripts to varying degrees and I was surprised even to see Thai attempted. — hippietrail (talk) 05:27, 12 February 2016 (UTC)[reply]
The key here is "phonemic", which is commonly used by Thai to render the actual pronunciation phonetically, no matter how irregular the spelling is. It may work perfectly well if the right parameters are passed. The phonemic Thai spellings can be found in online dictionaries. It still needs to be documented but you can see {{th-new}} and {{th-pron}} require phonemic Thai and the latter has some examples. .--Anatoli T. (обсудить/вклад) 05:37, 12 February 2016 (UTC)[reply]
OK that's clear. Thanks. — hippietrail (talk) 04:43, 13 February 2016 (UTC)[reply]

ทรวง - suuang[edit]

@หมวดซาโต้, Wyang I've added the new case asa per Talk:ทรวง. I noticed this discrepancy but I thought it should be this way. :) --Anatoli T. (обсудить/вклад) 09:17, 13 February 2016 (UTC)[reply]

Words starting with ห + consonant[edit]

@Wyang, Octahedron80 Hi. Words like หลาม (lǎam) produce wrong transliterations before they are defined and use {{th-pron}}. They produce impossible clusters like hl-, hn-, etc. I think the module should produce nil in such cases. --Anatoli T. (обсудить/вклад) 11:49, 20 August 2017 (UTC)[reply]

@Atitarev I think it is fixed. Please see the etymology of หรูหรา (rǔu-rǎa) for an example. Wyang (talk) 07:48, 21 August 2017 (UTC)[reply]
Thank you! --Anatoli T. (обсудить/вклад) 07:52, 21 August 2017 (UTC)[reply]

Respellings, not words[edit]

@Theknightwho, @Benwing2:

Hi, just letting you know that these test cases mostly use respellings, not words.

E.g. นคร (ná-kɔɔn) is respelled "นะ-คอน". That's why it's red linked, showing as นะคอน (non-existent or misspelling). Even if hyphens and symbol ◌ฺ are removed by the module, many words are not real.

Per new discussion, it would be {{tl|m|th|{นคร/นะ-คอน} }} if the word need a respelling (right?). Anatoli T. (обсудить/вклад) 05:48, 24 November 2023 (UTC)[reply]

@Atitarev Yes, that looks like the right syntax. The code I will be writing will use the portion on the left of the slash in links, so it should link correctly. Benwing2 (talk) 05:58, 24 November 2023 (UTC)[reply]
@Benwing2: With a space between } and final }}? Anatoli T. (обсудить/вклад) 06:01, 24 November 2023 (UTC)[reply]
@Atitarev Yes. It might work in this case without that space, but I'm not sure; it depends on exactly how the MediaWiki parser works. It you write something like {{tl|m|th|{นคร/นะ-คอน}}} without the extra space, the parser might interpret the first two right braces as the partners of the two left braces that introduce the template call; then the final right brace would be placed outside the template call, which would mess everything up. User:Theknightwho probably knows the exact rules. Benwing2 (talk) 06:06, 24 November 2023 (UTC)[reply]