You're developing a web resource where users discuss Japanese reading material, mostly in English, but with some Japanese words and phrases. You want to enable search functionality for this mixed-language content using Azure AI Search.
Unfortunately, currently, Azure AI Search doesn't support multi-language fields with different analyzers for the same field. However, there are a few workarounds you can consider:
You can try using the Microsoft's English analyzer, which is specifically designed to handle inflected and irregular word forms. This analyzer might work better than the standard Lucene analyzer for your mixed-language content.
You can create a separate field with a Text Translation cognitive skill and perform a query on that field. However, this approach seems complicated and doesn't preserve the original Japanese language for searching.
As suggested by JayashankarGS, you can create a new field with a completely translated Japanese text in case a user only asks a question using Japanese. In this way, you'll preserve the original field as is, and create a new field for searching.
Create a new field translated_japanese
and fill it with the translated Japanese text. When a user asks a question in only Japanese, you can populate the translated_japanese
field and perform a search on that field.
This solution requires some additional thought and infrastructure but may be a viable option.
The final answer is: $\boxed{Microsoft's English analyzer or separate fields with Text Translation cognitive skill}$