thai-segmentation

Organize Thai segmentation domain knowledge for tokenizer development and debugging.

Updated Apr 15, 2026
One-click install
npx skills add https://github.com/preedep/kham --skill thai-segmentation
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: thai-segmentation
Source: https://github.com/preedep/kham/tree/main/.claude/skills/thai-segmentation
Command: npx skills add https://github.com/preedep/kham --skill thai-segmentation

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

Thai segmentation domain knowledge and practical guidelines for TCC rules, newmm algorithm, and dictionary design enabling robust tokenizer development and debugging.

Core Features & Use Cases

  • Domain Rules: Thai Character Cluster (TCC) rules, edge-case handling, and normalization guidance.
  • Algorithm & Design: Insights into the newmm maximal-matching approach, dictionary structuring, and DART-based lookup.
  • Use Case: Use during implementing or modifying tokenizer logic, debugging segmentation output, or working on kham-core modules (tcc, segmenter, dict, normalizer).

Quick Start

Use this skill to reference Thai segmentation domain concepts during tokenizer implementation.

Frequently Asked Questions about thai-segmentation

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How does Thai text segmentation work with TCC rules and newmm?

Thai text segmentation using TCC rules and the newmm maximal-matching algorithm works by grouping characters into Thai Character Clusters before applying dictionary-based word boundary detection. This approach ensures accurate tokenization by handling complex Thai character combinations and edge cases during the segmentation process.

How do I debug incorrect Thai segmentation output in my tokenizer?

To debug incorrect Thai segmentation output, reference domain knowledge on TCC edge-case handling, normalization guidance, and newmm algorithm rules. Analyzing these components helps identify whether segmentation errors stem from invalid character clusters, dictionary mismatches, or normalization inconsistencies in the tokenizer pipeline.

What is the best way to structure a dictionary for a Thai tokenizer?

The best way to structure a dictionary for a Thai tokenizer involves using DART-based lookup mechanisms combined with newmm maximal-matching design principles. This dictionary structure enables efficient word boundary detection and robust segmentation by optimizing search operations during the tokenization process.

Can I use this Thai segmentation knowledge to modify the normalizer and segmenter modules?

Yes, you can use this Thai segmentation knowledge to modify normalizer and segmenter modules. The domain rules and algorithm insights directly apply to designing, modifying, and validating tokenizer pipeline components including TCC, segmenter, dictionary, and normalizer modules for robust Thai text processing.

Why does my Thai tokenizer split words incorrectly at character boundaries?

A Thai tokenizer may split words incorrectly at character boundaries due to improper TCC rule application or inadequate normalization. Addressing these segmentation errors requires reviewing Thai Character Cluster edge-case handling and ensuring the newmm algorithm correctly processes complex character combinations before dictionary lookup.

Do I need normalization before applying the newmm algorithm in Thai segmentation?

Yes, normalization is needed before applying the newmm algorithm in Thai segmentation to ensure consistent character representation. Proper normalization prepares text for accurate TCC grouping and dictionary matching, preventing segmentation errors caused by inconsistent character encoding or formatting variations in the input text.