Disclosure of Invention
In view of the above problems, the present invention provides an interactive speech translation method and system, which can implement speech playing on two terminal devices.
The technical scheme of the invention is realized as follows:
according to an aspect of the present invention, there is provided an interactive speech translation method, including:
a first terminal acquires first voice information of a first language, translates the first voice information into first target voice information of a second language, and sends the first target voice information;
the second terminal receives and plays the first target voice information, wherein the first language is different from the second language; or
The second terminal acquires second voice information of a second language and sends the second voice information to the first terminal;
and the first terminal translates the second voice information into second target voice information of the first language and plays the second target voice information.
According to the embodiment of the invention, when the second terminal acquires the second voice information of the second language, the first terminal suspends voice recognition, wherein the suspended voice recognition comprises suspending acquiring the voice information, suspending calling a translation interface or suspending voice synthesis; and when the second terminal sends the second voice information after finishing acquiring the second voice information, the first terminal starts voice recognition, wherein the voice recognition starting comprises the steps of starting to acquire the voice information, starting to call a translation interface and starting voice synthesis.
According to an embodiment of the invention, the first terminal invokes a translation interface to translate between voice information in a first language and a second language.
According to an embodiment of the invention, the first terminal and the second terminal are wirelessly connected by bluetooth.
According to an embodiment of the invention, the first terminal comprises a smart helmet and the second terminal comprises a smart watch.
According to another aspect of the present invention, there is provided an interactive speech translation system, comprising:
the terminal comprises a first terminal, a second terminal and a third terminal, wherein the first terminal is used for acquiring first voice information of a first language, translating the first voice information into first target voice information of a second language and sending the first target voice information, and the first language is different from the second language;
the second terminal is used for receiving and playing the first target voice information; or
The second terminal is used for acquiring second voice information of a second language and sending the second voice information, and the first terminal is used for receiving the second voice information, translating the second voice information into second target voice information of the first language and playing the second target voice information.
According to the embodiment of the invention, when the second terminal acquires the second voice information of the second language, the first terminal suspends voice recognition, wherein the suspended voice recognition comprises suspending acquiring the voice information, suspending calling a translation interface or suspending voice synthesis;
and when the second terminal sends the second voice information after finishing acquiring the second voice information, the first terminal starts voice recognition, wherein the voice recognition starting comprises the steps of starting to acquire the voice information, starting to call a translation interface and starting voice synthesis.
According to an embodiment of the invention, the first terminal invokes a translation interface to translate between voice information in a first language and a second language.
According to an embodiment of the invention, the first terminal and the second terminal are wirelessly connected by bluetooth.
According to an embodiment of the invention, the first terminal comprises a smart helmet and the second terminal comprises a smart watch.
The method and the system for the interactive voice translation realize the translation on two terminal devices, the two terminal devices are equivalent to a microphone with an automatic translation function, one terminal records and automatically translates the voice, and the voice is played at the other terminal, so that the method and the system are as easy and convenient as two friends using voice to chat.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments that can be derived by one of ordinary skill in the art from the embodiments given herein are intended to be within the scope of the present invention.
According to the embodiment of the invention, a communication type speech translation method is provided to facilitate the communication between two parties familiar with different languages.
As shown in fig. 1, the method for interactive speech translation according to the first embodiment of the present invention includes:
s101, a first terminal acquires first voice information of a first language, translates the first voice information into first target voice information of a second language and sends the first target voice information;
and S102, the second terminal receives and plays the first target voice information, wherein the first language is different from the second language.
Or as shown in fig. 2, the method for ac speech translation according to the second embodiment of the present invention includes:
step S201: and the second terminal acquires second voice information of a second language and sends the second voice information to the first terminal.
Step S202, the first terminal translates the second voice message into a second target voice message of the first language and plays the second target voice message.
Based on the translation methods of the two different modes, the translation can be realized on the two terminal devices, the two terminal devices are equivalent to microphones with automatic translation functions, one terminal records and automatically translates the voices, and then the voices are played at the other terminal, so that the voices are easy and convenient to play as two friends use voice to chat.
Preferably, when the second terminal acquires the second voice information of the second language, the first terminal suspends voice recognition, and the suspended voice recognition comprises suspending acquiring the voice information, suspending calling a translation interface or suspending voice synthesis; and when the second terminal finishes acquiring the second voice information and then sends the second voice information, the first terminal starts voice recognition, wherein the starting of the voice recognition comprises the steps of starting to acquire the voice information, starting to call a translation interface to translate the voice into target language characters, and starting voice synthesis to synthesize the target language characters into voice. In an embodiment of the present invention, the first terminal includes, but is not limited to, a police smart helmet, and the second terminal includes, but is not limited to, a smart watch. In the case that only a first terminal (such as a police helmet) can perform networking, translation, voice synthesis and other operations, when a second terminal (such as a smart watch used by foreigners) receives an instruction to start recording, a translation interface in the first terminal (such as the police helmet) suspends the voice recognition function. In a preferred embodiment, the suspended speech recognition is suspended from acquiring speech information. After the second terminal (such as a smart watch used by a foreigner) finishes recording and sends voice information to the first terminal, the first terminal translates the foreign language into Chinese and plays the Chinese, so that the police can understand the speaking content of the foreigner conveniently. And then the first terminal receives the Chinese voice input by the police officer, translates the Chinese voice into foreign language voice and sends the foreign language voice to the second terminal, and the second terminal plays the foreign language voice, so that the foreigners can conveniently understand the speaking content of the police officer, and the communication between the two parties is realized.
Preferably, the second terminal invokes a translation interface to translate between the speech information in the first language and the second language. The first terminal and the second terminal are wirelessly connected by, but not limited to, bluetooth. Generally speaking, the effective distance of use of bluetooth wireless connection can reach 10 meters, and for the first terminal and the second terminal which are more than 10 meters apart, the connection can also be through the internet.
In one aspect of this embodiment, a police helmet terminal records a chinese voice through a microphone in a helmet, then obtains recording data using a recording function, calls a voice translation interface, uploads the recording data, returns a chinese translation result through the interface, then calls a voice synthesis interface, synthesizes the translation result, returns voice synthesis media data through the interface, sends the synthesized media data to a watch terminal through bluetooth or the internet, and the watch terminal plays the synthesized media data of a foreign language on site after receiving the synthesized media data.
In another aspect of the embodiment, the watch end records foreign language voice through a microphone in the watch, acquires the recording data by using a recording function, then sends the recording data to the helmet through Bluetooth or internet connection, the helmet end calls a voice translation interface after receiving the recording data, uploads the recording data, the interface returns a foreign language translation result, then calls a voice synthesis interface, returns voice synthesis media data, and plays a Chinese synthesis result on site at the helmet end.
Therefore, the invention provides an exchange type translation method, which changes the traditional single translation (namely, the recording and the playing are in the same device), and in order to achieve normal face-to-face communication, the method adopts two devices, including a first terminal and a second terminal, data are transmitted between the two devices through Bluetooth or the Internet, when a translation mode is selected, the two devices are equivalent to microphones with automatic translation functions, one end speaks and automatically translates, and then the two devices are played at the other end, so that the method is as easy and convenient as two friends use voice chat.
As shown in fig. 3, in another aspect, the present invention further provides an interactive speech translation system, including:
a first terminal 301, configured to acquire first voice information in a first language, translate the first voice information into first target voice information in a second language, and send the first target voice information, where the first language is different from the second language;
the second terminal 302, configured to receive and play the first target voice message; or
The second terminal 302 is configured to obtain second voice information in a second language and send the second voice information, and the first terminal 301 is configured to receive the second voice information and translate the second voice information into second target voice information in the first language, and play the second target voice information.
Preferably, when the second terminal 302 acquires the second voice information in the second language, the first terminal 301 suspends the voice recognition; when the second terminal 302 finishes acquiring the second voice message and then sends the second voice message, the first terminal 301 starts voice recognition.
Preferably, the second terminal 302 invokes a translation interface to translate between voice information in the first language and the second language.
Preferably, the first terminal 301 and the second terminal 302 are connected via bluetooth wireless or internet.
Preferably, the first terminal 301 comprises a smart helmet and the second terminal 302 comprises a smart watch.
Therefore, the invention provides an exchange type translation system, which changes the traditional single translation (namely, the recording and the playing are in the same device), and in order to achieve normal face-to-face communication, the invention adopts two devices, including a first terminal 301 and a second terminal 302, data are transmitted between the two devices through Bluetooth or the internet, when a translation mode is selected, the two devices are equivalent to a microphone with an automatic translation function, one end speaks and automatically translates, and then the two devices are played at the other end, so that the translation system is as easy and convenient as two friends use voice chat.
The communication type translation method and the communication type translation system provided by the invention can be applied to translation equipment and translation software, such as: the intelligent language translator, the mobile phone translation software, the chat translation software and the like. People can connect with another translator or a mobile phone with translation software through Bluetooth through one translator or a mobile phone with translation software, and can realize short-distance normal conversation and communication with foreigners. The translation machine or the mobile phone with translation software can also translate the voice of foreign language broadcast, television, movie and the like. The translation mode provided by the invention can be used in real-time voice chat in chat software, so that the words spoken by the user are translated into the voices which can be understood by the opposite party in real time, and the words spoken by the opposite party are translated into the voices which can be understood by the user in real time, thereby facilitating the chat and communication of people.
The above description is only for the purpose of illustrating the preferred embodiments of the present invention and is not to be construed as limiting the invention, and any modifications, equivalents, improvements and the like that fall within the spirit and principle of the present invention are intended to be included therein.