How to count word as text in different language?

Hello Everyone,

I just doing aN app for translation and one of the feature is to count the word input and out. I try to use split by () : count words working with English input language, however the output Chinese language count is not working.

Anyone know about this issue? Would be very thanks for that!

Screenshot 2024-05-16 at 9.36.18 PM