PyThaiNLP / PyThaiNLP/pythainlp

bug: Romanize company name, found repeated strings

Open
#1,403 4 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug question
Dominant language
Python
Stars
1.2k
Forks
304
Avg merge
2d 14h
Merged PRs (30d)
14

Description

Description

Found strange output from feature Romanization

engine: thai2rom_onnx


Sample #1
Input: เอ็มเอฟซีบัญชีเพื่อการชำระค่ารับซื้อคืน
Output (Romanized) : em-epsibanchiphueakanchiphueakanchiphueakanchiphueakanchiphueakanchiphueakanchiphueakanchiphueakanch

Notice: string "banchiphueakan" are repeated many times


Sample #2
Input: บัญชีเพื่อการชำระค่าขายคืนหน่วยลงทุน
Output (Romanized) : banchiphueakanchamrakhakhaikhaikhaikhaikhaikhaikhaikhaikhaikhaikhaikhaikhaikhaikhaikhaikhaikhaikhai
k

Notice: string "khai" are repeated many times

Expected results

There should not be any repeated strings in romanized output.

Current results

Found strange output from feature Romanization

engine: thai2rom_onnx


Sample #1
Input: เอ็มเอฟซีบัญชีเพื่อการชำระค่ารับซื้อคืน
Output (Romanized) : em-epsibanchiphueakanchiphueakanchiphueakanchiphueakanchiphueakanchiphueakanchiphueakanchiphueakanch

Notice: string "banchiphueakan" are repeated many times


Sample #2
Input: บัญชีเพื่อการชำระค่าขายคืนหน่วยลงทุน
Output (Romanized) : banchiphueakanchamrakhakhaikhaikhaikhaikhaikhaikhaikhaikhaikhaikhaikhaikhaikhaikhaikhaikhaikhaikhai
k

Notice: string "khai" are repeated many times

Steps to reproduce

engine: thai2rom_onnx

Sample #1
Input: เอ็มเอฟซีบัญชีเพื่อการชำระค่ารับซื้อคืน

Sample #2
Input: บัญชีเพื่อการชำระค่าขายคืนหน่วยลงทุน

PyThaiNLP version

5.3

Python version

3.12

Operating system and version

Windows

More info

No response

Possible solution

No response

Files

No response

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the two Thai inputs with the thai2rom_onnx engine on Python 3.12 and compare the outputs with the reported repetitions. Trace the romanization entry point and model-inference handling used by this engine; done means both samples produce romanized text without repeated strings such as "banchiphueakan" or "khai".

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
machine-learning
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
55/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.