Thai tokenizer
The thai tokenizer segments Thai text into words, using the Thai segmentation algorithm included with Java. Text in other languages in general will be treated the same as the standard tokenizer.
This tokenizer may not be supported by all JREs. It is known to work with Sun/Oracle and OpenJDK. If your application needs to be fully portable, consider using the ICU Tokenizer instead.
Example output
resp = client.indices.analyze(
tokenizer="thai",
text="การที่ได้ต้องแสดงว่างานดี",
)
print(resp) response = client.indices.analyze(
body: {
tokenizer: 'thai',
text: 'การที่ได้ต้องแสดงว่างานดี'
}
)
puts response const response = await client.indices.analyze({
tokenizer: "thai",
text: "การที่ได้ต้องแสดงว่างานดี",
});
console.log(response); POST _analyze
{
"tokenizer": "thai",
"text": "การที่ได้ต้องแสดงว่างานดี"
} The above sentence would produce the following terms:
[ การ, ที่, ได้, ต้อง, แสดง, ว่า, งาน, ดี ]
Configuration
The thai tokenizer is not configurable.
© 2023-2025 Elasticsearch
As of September 2024, Elasticsearch is available under a choice of three licenses: the Server Side Public License (SSPL), the Elastic License, or the AGPLv3 (OSI approved).
Elasticsearch and the Elasticsearch logo are trademarks of Elasticsearch B.V., registered in the U.S. and in other countries.
https://www.elastic.co/guide/en/elasticsearch/reference/8.17/analysis-thai-tokenizer.html