DuckerMaster/Thai-Natural-DateTime-Dataset
Viewer โข Updated โข 10k
Fine-tuned wangchanberta-base-att-spm-uncased for token-level temporal boundary extraction (B-TIME, I-TIME, O) across colloquial Thai sentences, conversational chat slang, and compound date-time structures.
Paired Dataset: DuckerMaster/Thai-Natural-DateTime-Dataset
Designed as the neural frontend for the End-to-End Hybrid Architecture:
Evaluated against disjoint stratified benchmarks and tested side-by-side with rule baselines and instruction-tuned LLMs on NVIDIA T4 hardware.
| System / Model Architecture | Parameter Size | Hardware Execution | OOD Accuracy / F1 | Mean Latency (ms) | Production SLA (<50ms) |
|---|---|---|---|---|---|
| dateparser (Heuristic Multilingual) | 0 | CPU | 6.0% | 12.4 ms | Pass |
| PyThaiNLP (Rule Parser) | 0 | CPU | 18.7% | 1.8 ms | Pass |
| Qwen2.5-3B-Instruct (4-bit NF4) | 3B | GPU (T4) | 3.3% | 383.3 ms | Fail (Over 7x threshold) |
| Typhoon 30B (Cloud REST API) | 30B | Cloud Server | 47.3% | 2,753.9 ms | Fail (Over 55x threshold) |
| Our Hybrid System (WangchanBERTa + Rule) | 106M | GPU (T4) | 96.9% | 10.2 ms | Pass (Optimal Frontier) |
airesearch/wangchanberta-base-att-spm-uncased).O: Outside temporal entity.B-TIME: Beginning of temporal expression.I-TIME: Continuation of temporal expression.import torch
from transformers import AutoTokenizer, AutoModelForTokenClassification
model_name = "DuckerMaster/DuckerTime-Normalize-Thai"
tokenizer = AutoTokenizer.from_pretrained(model_name)
model = AutoModelForTokenClassification.from_pretrained(model_name)
text = "เธเธญเนเธฅเธทเนเธญเธเนเธเนเธเธงเธฑเธเธเธธเธเธซเธเนเธฒเธเนเธงเธเธเนเธฒเธขเนเธเนเน เธชเธฑเธเธชเธตเนเนเธกเธเนเธขเนเธเนเธเนเนเธซเธกเธเธฐ"
inputs = tokenizer(text, return_tensors="pt")
with torch.no_grad():
logits = model(**inputs).logits
preds = torch.argmax(logits, dim=2)[0].tolist()
tokens = tokenizer.convert_ids_to_tokens(inputs["input_ids"][0])
extracted_tokens = [tok for tok, pred in zip(tokens, preds) if pred != 0]
print("Extracted Temporal Tokens:", extracted_tokens)
thai-temporal-normalizer core package for full ISO-8601 normalization.If you use this model in your research or production systems, please cite:
@software{duckertime_thai_2026,
author = {DuckerMaster},
title = {DuckerTime-Normalize-Thai: Fine-Tuned WangchanBERTa for Colloquial Thai Temporal NLU},
year = {2026},
publisher = {HuggingFace},
howpublished = {\url{https://huggingface.co/DuckerMaster/DuckerTime-Normalize-Thai}}
}