automatic choose the language

added new method automatic choose the language