vncorenlp / VnCoreNLP

A Vietnamese natural language processing toolkit (NAACL 2018)
Other
587 stars 145 forks source link

Nhận diện tên địa điểm viết tắt ở cuối câu #28

Closed canhnm closed 4 years ago

canhnm commented 4 years ago

Input string: Về ca chỉ điểm ổ dịch Covid-19 tại quán bar Buddha là bệnh nhân 91 (phi công Vietnam Airlines). Hiện, bệnh nhân đang được điều trị tại Bệnh viện Bệnh nhiệt đới TP.HCM. Tình trạng bệnh nhân không sốt, mạch huyết áp bình thường, rối loạn đông máu kiểm soát tạm ổn, chức năng phổi có cải thiện, tiếp tục thở máy và hỗ trợ ECMO.

Khi tokenize từ viết tắt TP.HCM. không được tách đúng:

{
    "depLabel": "nmod",
    "form": "TP.HCM.",
    "head": 8,
    "index": 10,
     "nerLabel": "O",
     "posTag": "Ny"
}

Nếu thay dấu "." ở đoạn văn input thành "Bệnh việt Bệnh nhiệt đới TP.HCM, tình trạng bệnh nhân ...." thì tokenize mới nhận diện được:

{
    "depLabel": "nmod",
    "form": "TP.",
    "head": 8,
    "index": 10,
     "nerLabel": "I-ORG",
    "posTag": "Ny"
}, {
    "depLabel": "nmod",
    "form": "HCM",
    "head": 10,
    "index": 11,
    "nerLabel": "I-ORG",
    "posTag": "Np"
}
datquocnguyen commented 4 years ago

So it's ok with "ECMO.", is not it? This is a very specific case which we will not change the vncorenlp code for handling it. You might want to write a preprocess script to replace "TP.HCM." into "TP. HCM .", before feeding the text into vncorenlp.