การระบุภาษา

API การระบุภาษาในอุปกรณ์ของ ML Kit ช่วยให้คุณระบุภาษาของสตริงข้อความได้
การระบุภาษาจะมีประโยชน์เมื่อทำงานกับข้อความที่ผู้ใช้ระบุ ซึ่งมักจะไม่ได้มาพร้อมข้อมูลภาษาใดๆ
iOS
Android
ความสามารถหลัก
ตัวอย่างผลการแข่ง
ใช้ภาษาง่ายๆ |
"โฮเวอร์คราฟต์ของฉันมีปลาไหลมากมาย" |
en (ภาษาอังกฤษ) |
"Dao shan xue hai" |
zh-Latn (ภาษาจีนแบบละติน) |
"ph'nglui mglw'nafh wgah'nagl fhtagn" |
und (ยังไม่กำหนด) |
การกระจายความเชื่อมั่น |
"การรัฐประหารที่ไม่เป็นมิตร" |
en (0.52)
fr (0.44)
ca (0.03)
|
เนื้อหาของหน้าเว็บนี้ได้รับอนุญาตภายใต้ใบอนุญาตที่ต้องระบุที่มาของครีเอทีฟคอมมอนส์ 4.0 และตัวอย่างโค้ดได้รับอนุญาตภายใต้ใบอนุญาต Apache 2.0 เว้นแต่จะระบุไว้เป็นอย่างอื่น โปรดดูรายละเอียดที่นโยบายเว็บไซต์ Google Developers Java เป็นเครื่องหมายการค้าจดทะเบียนของ Oracle และ/หรือบริษัทในเครือ
อัปเดตล่าสุด 2025-02-28 UTC
[null,null,["อัปเดตล่าสุด 2025-02-28 UTC"],[[["ML Kit's language identification API allows you to determine the language of a text string, which is particularly helpful when dealing with user-generated content that often lacks language information."],["It supports a wide range of languages, including romanized versions of Arabic, Bulgarian, Greek, Hindi, Japanese, Russian, and Chinese text."],["The API can provide a simple language identification or a confidence distribution across multiple languages for a given text."]]],["ML Kit's on-device API identifies the language of text strings, supporting over one hundred languages, including romanized versions of Arabic, Bulgarian, Greek, Hindi, Japanese, Russian, and Chinese. It's designed for user-provided text that lacks language information. The API outputs language codes (e.g., `en` for English) or `und` for undetermined. For ambiguous cases, it provides a confidence distribution across multiple languages (e.g., `en` (0.52), `fr` (0.44)).\n"]]