Translation device
A translation device includes: a determination unit that determines a translation range for translating a first chunk to be translated; a translation unit that translates the translation range; and an output unit that outputs a translation result by the translation unit. The determination unit adds, to the translation range, the first chunk and a second chunk that includes a verb corresponding to a word included in the first chunk and that is closer to a beginning of an original sentence than the first chunk when no verb is included in the first chunk.
1 . A translation device that translates an original sentence in units of chunks which are processing units, the translation device comprising:
processing circuitry configured to
receive an utterance of a user and perform speech recognition on the utterance to obtain the original sentence that is to be translated in the units of chunks;
determine a translation range for translating a first chunk to be translated;
translate the translation range in real-time; and
output a translation result to an output device that is one of a display or speaker,
wherein the processing circuitry adds, to the translation range, the first chunk and a second chunk that includes a verb corresponding to a word included in the first chunk and that is closer to a beginning of the original sentence than the first chunk when no verb is included in the first chunk,
wherein when the translation range includes a chunk different from the first chunk, the processing circuitry specifies a redundant word that is not included in the translation result from among words included in the translation range, and translates the translation range so as not to include a translation result of the redundant word,
wherein the processing circuitry includes an encoder-decoder translation model with an attention mechanism, and
wherein the processing circuitry resets an attention value assigned to the redundant word to 0.
2 . The translation device according to claim 1 , wherein when a verb is included in the first chunk, the processing circuitry adds the first chunk to the translation range.
3 . The translation device according to claim 2 , wherein when no subject is included in the translation range, the processing circuitry further adds, to the translation range, a third chunk that includes a subject corresponding to the translation range and that is closer to the beginning original sentence than the first chunk.
4 . The translation device according to claim 1 , wherein when no subject is included in the translation range, the processing circuitry further adds, to the translation range, a third chunk that includes a subject corresponding to the translation range and that is closer to the beginning of the original sentence than the first chunk.
5 . The translation device according to claim 1 , wherein the processing circuitry specifies, as the redundant word, a word closer to the beginning of the original sentence than the verb from among words included in the translation range.
6 . The translation device according to claim 1 , wherein the processing circuitry adjusts attention values so that a sum of the attention values of target words that are words other than the redundant word among words included in the translation range becomes 1.
7 . The translation device according to claim 6 , wherein the processing circuitry equally distributes the attention value assigned to the redundant word to the attention values of the target words.
8 . The translation device according to claim 6 , wherein the processing circuitry distributes the attention value assigned to the redundant word in proportion to a ratio of the attention values of the target words.
9 . A method, implemented by processing circuitry of a translation device that translates an original sentence in units of chunks which are processing units, the method comprising:
receiving an utterance of a user and performing speech recognition on the utterance to obtain the original sentence that is to be translated in the units of chunks;
determining a translation range for translating a first chunk to be translated;
translating the translation range in real-time; and
outputting a translation result to an output device that is one of a display or speaker,
wherein the method includes adding, to the translation range, the first chunk and a second chunk that includes a verb corresponding to a word included in the first chunk and that is closer to a beginning of the original sentence than the first chunk when no verb is included in the first chunk,
wherein in response to the translation range including a chunk different from the first chunk, the method includes specifying a redundant word that is not included in the translation result from among words included in the translation range, and translating the translation range so as not to include a translation result of the redundant word,
wherein the processing circuitry includes an encoder-decoder translation model with an attention mechanism, and
wherein the method includes resetting an attention value assigned to the redundant word to 0.