“THIRAWAT Mapper”
By Natthawut Adulyanukosol
Deputy Director of Siriraj Data Innovation Center (SiData+)
The Faculty of Medicine Siriraj Hospital, Mahidol University, has developed THIRAWAT Mapper, an AI system designed to assist in mapping Thai drug terminologies and codes to international standards. This system supports the utilization of healthcare data from hospital information systems for research, data analysis, and the development of real-world evidence (RWE) with greater accuracy and verifiability.
This system was developed based on the research titled “Efficient Drug Terminology Mapping with Bidirectional Late-Interaction Reranking and Deterministic Reordering”, published in the journal Healthcare Informatics Research in 2026. It aims to solve critical issues regarding drug data in the Thai healthcare system, namely the diversity of drug names, codes, strengths, dosage forms, brand names, and the disparate data entry methods utilized across different healthcare institutions.
The Problem of Non-Standardized Drug Data
In hospital systems, drug data is frequently recorded in varying formats. Even when referring to the exact same medication item, the details utilized within the systems can differ significantly—ranging from generic names, brand names, strengths, dosage forms, and routes of administration, to the internal drug codes specific to each hospital.
These discrepancies make linking data from multiple sources to international standards, such as the OMOP Common Data Model and RxNorm, a highly time-consuming task. It requires domain experts to manually verify massive amounts of data and is highly susceptible to discrepancies. If drug terminologies are mapped incorrectly, it can lead to inaccurate outcomes in data analysis, pharmacovigilance (drug safety monitoring), or research based on real-world healthcare data.
The Approach of THIRAWAT Mapper
THIRAWAT Mapper was specifically designed as an assistive system for mapping drug terminologies. Instead of relying on Large Language Models (LLMs) at every single step, the system employs an approach directly tailored for drug code mapping: it begins by retrieving drug items that exhibit close similarity, and then rigorously re-ranks those results in detail.
The core of the system is the BiMaxSim (Bidirectional MaxSim) method, which compares drug texts bi-directionally. This allows the system to better evaluate crucial drug attributes—such as drug strength, dosage form, route of administration, release characteristics, and information related to brand names, while still utilizing computational resources appropriately.
Another crucial component is handling scenarios where multiple candidate answers have very close scores. The system employs rules based on detailed drug attributes—such as strength, dosage form, route of administration, release characteristics, and brand name information—to help rank the answers consistently, transparently, and with greater traceability.
This approach ensures that THIRAWAT Mapper is not merely a system that searches for the most visually similar words. Instead, it is a process that integrates the retrieval of relevant drug items, result reranking using BiMaxSim, and the resolution of close-score cases using clear rules to increase accuracy and significantly reduce the manual validation burden on experts.
Evaluation Results
Based on evaluations using the Thai Medicines Terminology (TMT) dataset, the system effectively mapped drug terminologies by accurately organizing the correct answers into the top-ranking positions. This significantly reduced the manual verification workload for experts and increased the convenience of linking drug data to international standards.
Evaluation results across various datasets showed that the system ranked the correct answer accurately as the absolute first choice (Hits@1) in 85.9%–94.2% of all cases, and displayed the correct answer within the top 3 choices (Hits@3) in 93.0%–96.4% of all cases.

These outcomes demonstrate that combining relevant drug retrieval, BiMaxSim reranking, and deterministic rule-based ordering can significantly improve the accuracy of drug code mapping without the necessity of deploying massive language models at every stage.
Implications for Healthcare Data
THIRAWAT Mapper serves as a foundational healthcare data infrastructure that enables drug data from various systems to interconnect seamlessly within a single standard. When drug data is correctly mapped to standards, researchers, physicians, pharmacists, health informatics professionals, and healthcare organizations can utilize the data with greater convenience and reliability.
Examples of further applications include studying treatment outcomes, pharmacovigilance (monitoring drug safety), generating evidence from real-world healthcare data (RWE), conducting cross-institutional data analysis, and collaborating with research networks utilizing the OMOP standard both domestically and internationally.
Open for Study, Trial, and Extension
The research team has published the codes and models of THIRAWAT Mapper so that researchers, developers, and healthcare organizations can study, test, and adapt them within their respective contexts.
* GitHub: sidataplus/THIRAWAT-mapper
* Hugging Face: sidataplus/thirawat collection
Furthermore, the team is currently developing a more user-friendly web application for mapping clinical terminologies to OMOP standard concepts. This will allow general users to test and utilize the system without needing a background in AI or programming. Stay tuned for further developments soon.
Research Reference
Adulyanukosol N, Chaisutyakorn K, Sombutjaroan S, Kanjanapong S, Suriyaphol P. *Efficient Drug Terminology Mapping with Bidirectional Late-Interaction Reranking and Deterministic Reordering*. Healthcare Informatics Research. 2026;32(2):156-165. https://doi.org/10.4258/hir.2026.32.2.156.







