Translation device
The translation device enhances accuracy and efficiency by translating text in chunks, incorporating verbs and subjects to maintain context and reduce redundancy.
Patent Information
- Application Number
- JP2022566798
- Authority / Receiving Office
- JP · JP
- Patent Type
- Patents
- Current Assignee / Owner
- Priority Date
- 2020-12-02
- Filing Date
- 2021-11-05
- Publication Date
- 2026-01-27
- Estimated Expiration
- 2041-11-05
AI Technical Summary
Existing translation devices fail to consider context when translating segmented character strings, leading to potential inaccuracies even with added phrases.
A translation device that translates text in chunk units, determining translation ranges that include verbs and subjects to clarify meaning, using a machine translation model with an encoder-decoder mechanism and attention mechanism to improve accuracy.
Improves translation accuracy while reducing the time required for translation results by considering context through chunk-based translation and identifying redundant words.
Smart Images

Figure 0007807394000003 
Figure 0007807394000004 
Figure 0007807394000005
Abstract
Description
[Technical Field]
[0001] The present disclosure relates to a translation device. [Background technology]
[0002] There is known a translation device that divides sequentially input character strings, such as character strings obtained by speech recognition of an utterance, into appropriate processing units and translates each divided character string. For example, Patent Document 1 describes a translation device that divides a recognition result character string obtained by performing speech recognition processing on speech uttered in a first language into units for translation processing to generate source language character strings, and translates the source language character strings into target language character strings in a second language. [Prior art documents] [Patent documents]
[0003] [Patent Document 1] Japanese Patent Application Laid-Open No. 2013-206253 Summary of the Invention [Problem to be solved by the invention]
[0004] The translation device described in Patent Document 1 detects whether a target language character string is ambiguous, and if ambiguity exists, adds an additional phrase. However, when the segmented character string is translated, the context is not taken into consideration, so there is a risk that the translated meaning will differ from the meaning in the source language. Therefore, even if an additional phrase is added after translation, there is a possibility that the translation accuracy will not improve.
[0005] The present disclosure describes a translation device that can improve translation accuracy while shortening the time required to obtain a translation result. [Means for solving the problem]
[0006] A translation device according to one aspect of the present disclosure is a device that translates an original text in chunk units, which are processing units. The 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 the translation result by the translation unit. If the first chunk does not contain a verb, the determination unit includes in the translation range the first chunk and a second chunk that contains a verb corresponding to a word contained in the first chunk and is closer to the beginning of the original text than the first chunk.
[0007] In this translation device, the original text is translated chunk by chunk, which reduces the time required to obtain a translation result compared to translating the entire original text. Furthermore, if a first chunk to be translated does not contain a verb, the translation range includes the first chunk and a second chunk that is closer to the beginning of the original text than the first chunk and contains a verb corresponding to a word contained in the first chunk. With this configuration, the translation range includes a verb, which can clarify the meaning of each word in the original text and clarify the context. Therefore, it is possible to improve translation accuracy while reducing the time required to obtain a translation result. [Effects of the Invention]
[0008] According to the present disclosure, it is possible to improve translation accuracy while shortening the time required to obtain a translation result. [Brief explanation of the drawings]
[0009] [Figure 1] FIG. 1 is a block diagram showing the functional configuration of a translation device according to an embodiment. [Figure 2] FIG. 2 is a diagram showing a schematic configuration of a machine translation model provided in the translation unit shown in FIG. [Figure 3] FIG. 3 is a diagram for explaining the processing of the encoder shown in FIG. [Figure 4] FIG. 4 is a diagram for explaining the processing of the decoder shown in FIG. [Figure 5] FIG. 5 is a diagram for explaining in detail the processing of the attention mechanism shown in FIG. [Figure 6] FIG. 6 is a flowchart showing a series of steps in the translation method performed by the translation device shown in FIG. [Figure 7] FIG. 7 is a flowchart showing in detail the translation range determination process shown in FIG. [Figure 8] FIG. 8 is a diagram illustrating an example of chunk division. [Figure 9] FIG. 9 is a diagram illustrating an example of dependency analysis. [Figure 10] FIG. 10 is a diagram showing an example of a translation result. [Figure 11] FIG. 11 is a diagram showing another example of the translation result. [Figure 12] FIG. 12 is a diagram for explaining a method for identifying redundant words. [Figure 13] FIG. 13 is a diagram illustrating a hardware configuration of the translation device shown in FIG. DETAILED DESCRIPTION OF THE INVENTION
[0010] Hereinafter, embodiments of the present disclosure will be described in detail with reference to the accompanying drawings. In the description of the drawings, the same elements are designated by the same reference numerals, and duplicated explanations will be omitted.
[0011] The functional configuration of a translation device 10 will be described with reference to FIG. 1. FIG. 1 is a block diagram showing the functional configuration of a translation device according to an embodiment. The translation device 10 shown in FIG. 1 is a device that translates an original text in chunk units. A chunk is a processing unit suitable for translation processing. The translation device 10 translates an original text in a first language to generate a translated text in a second language different from the first language. The translation device 10 is, for example, a simultaneous translation (real-time translation) device that translates an original text obtained by speech recognition of a user's speech. An example of the translation device 10 is an information processing device such as a server device.
[0012] 1, translation device 10 functionally comprises an acquisition unit 11, a division unit 12, an analysis unit 13, a determination unit 14, a translation unit 15, and an output unit 16. The function (operation) of each functional unit will be explained in detail in the explanation of the translation method given below, so here, the function of each functional unit will be explained briefly.
[0013] The acquisition unit 11 is a functional unit that acquires original text. The acquisition unit 11 acquires the original text from, for example, a speech recognition device (not shown). The acquisition unit 11 acquires the original text in order from the beginning of the original text.
[0014] The division unit 12 is a functional unit that divides an original text into chunks. The division unit 12 extracts specific morphemes (words) from the original text by, for example, named entity extraction and rule-based extraction, and divides the original text based on the extracted morphemes.
[0015] The analysis unit 13 is a functional unit that performs dependency analysis of each word included in the original text. The analysis unit 13 performs dependency analysis to generate dependency information between words. The dependency analysis is performed using a known method.
[0016] The determination unit 14 is a functional unit that determines a translation range for translating a target chunk (first chunk). The target chunk is a chunk to be translated. If the target chunk does not contain a verb, the determination unit 14 includes at least the target chunk and a chunk (second chunk) that contains a verb corresponding to a word contained in the target chunk and is closer to the beginning of the original text than the target chunk in the translation range. If the target chunk contains a verb, the determination unit 14 includes the target chunk in the translation range. If the translation range does not contain a subject, the determination unit 14 further includes in the translation range a chunk (third chunk) that contains a subject corresponding to the translation range and is closer to the beginning of the original text than the target chunk.
[0017] The translation unit 15 is a functional unit that translates the translation range. The translation unit 15 includes a machine translation model 50 that receives chunks included in the translation range as input and outputs a translation result. An example of the machine translation model 50 is an encoder-decoder translation model with an attention mechanism. The machine translation model 50 is generated by performing machine learning using each of multiple pieces of bilingual data included in a bilingual corpus for simultaneous translation as training data. Details of the machine translation model 50 will be described later.
[0018] The output unit 16 is a functional unit that outputs the translation result by the translation unit 15. The output unit 16 outputs the translation result to an output device such as a display and a speaker.
[0019] Next, a detailed configuration of the machine translation model will be described with reference to Figs. 2 to 5. Fig. 2 is a diagram showing a schematic configuration of the machine translation model provided in the translation unit shown in Fig. 1. Fig. 3 is a diagram for explaining the processing of the encoder shown in Fig. 2. Fig. 4 is a diagram for explaining the processing of the decoder shown in Fig. 2. Fig. 5 is a diagram for explaining in detail the processing of the attention mechanism shown in Fig. 2. As shown in Fig. 2, the machine translation model 50 includes an encoder 60 and a decoder 70.
[0020] As shown in FIGS. 2 and 3, the encoder 60 generates a hidden state matrix H, which is expressed numerically, by encoding an original sentence (input sentence X). Specifically, the encoder 60 generates the hidden state matrix H based on the input sentence X. The input sentence X is a translation range determined by the determination unit 14, and is composed of s words (words X1 to X2) (s is an integer equal to or greater than 1). s ) In the example shown in FIG. 3, an English input sentence is used as the input sentence X. The hidden state matrix H is made up of hidden state vectors he1 to he sWhen a word X1 is input to the encoder 60, a hidden state vector he1 is output from the encoder 60, and when a word X2 is input to the encoder 60, a hidden state vector he2 is output from the encoder 60. The relationships between other words and hidden state vectors are similar. The encoder 60 is configured by a neural network. The encoder 60 includes an embedding layer 61 and an LSTM (Long Short-Term Memory) layer 62.
[0021] The embedding layer 61 is a layer that vectorizes the words included in the input sentence X. The embedding layer 61 vectorizes the words included in the input sentence X (words X1 to X s ) one by one and vectorize the received words to obtain the word vector x1~x s The embedding layer 61 outputs each word vector to the LSTM layer 62.
[0022] The LSTM layer 62 is a recursive calculation layer that updates its internal state (hidden state) using the word vectors received from the embedding layer 61. The LSTM layer 62 receives the word vectors (word vectors x1 to x s ) one by one. The LSTM layer 62 receives the received word vector x i (i is an integer between 1 and s) and the previous hidden state vector he i-1 and update the internal state using the hidden state vector he i By repeating this process, the LSTM layer 62 generates the hidden state vectors he1 to he s The LSTM layer 62 outputs each hidden state vector to the LSTM layer 62 and the decoder 70.
[0023] As shown in FIGS. 2, 4, and 5, the decoder 70 generates a translation (output sentence Y) by decoding the hidden state matrix H generated by the encoder 60. Specifically, the decoder 70 generates the output sentence Y based on the hidden state matrix H. The output sentence Y is a translation result of the input sentence X, and is composed of t words (words Y1 to Y2) (t is an integer equal to or greater than 1). t ) Note that the word Y t is a special token that indicates the end of a sentence.<EOS(end of sentence)> In the example shown in Fig. 4, a Japanese output sentence is used as the output sentence Y. The decoder 70 is configured by a neural network. The decoder 70 includes an embedding layer 71, an LSTM layer 72, an attention mechanism (attention layer) 73, and an output layer 74.
[0024] The embedding layer 71 is a layer that vectorizes the words included in the output sentence Y. The embedding layer 71 is a layer that vectorizes the words included in the output sentence Y. <eos>Then, the words contained in the output sentence Y (words Y1 to Y t-1 ) one by one and vectorize the received words. <eos>indicates the beginning of the output sentence Y and the end of the input sentence X. By this process, the embedding layer 71 t-1 The embedding layer 71 outputs each word vector to the LSTM layer 72.
[0025] The LSTM layer 72 is a recursive calculation layer that updates its internal state (hidden state) using the word vectors received from the embedding layer 71. The LSTM layer 72 receives the word vectors (word vectors y0 to y t-1 ) one by one. The LSTM layer 72 receives the received word vector y j-1 (j is an integer between 1 and t) and the previous hidden state vector hd j-1 and update the internal state using the hidden state vector hd j By repeating this process, the LSTM layer 72 generates the hidden state vectors hd1 to hd t The LSTM layer 72 generates the hidden state vector he received from the encoder 60 as the hidden state vector hd0 (initial value of the hidden state vector). s The LSTM layer 72 outputs each hidden state vector to the LSTM layer 72 and the attention mechanism 73.
[0026] The attention mechanism 73 is a mechanism (layer) for utilizing each hidden state vector included in the hidden state matrix H. The attention mechanism 73 uses s hidden state vectors he i Attention value a for i Calculate the attention value a i is the hidden state vector he i and the hidden state vector hd j The attention value a is a value that indicates the similarity with i The larger the hidden state vector he i and the hidden state vector hd j For example, each attention value a i is a value between 0 and 1, and attention values a1 to a s The sum is 1.
[0027] Specifically, as shown in equation (1), the attention mechanism 73 receives the hidden state vector hd from the LSTM layer 72. j and each hidden state vector he contained in the hidden state matrix H i The inner product of the hidden state vector he is calculated and normalized so that the result is within the range of 0 to 1. i Attention value a i Here, the function exp represents the exponential function.
number
[0028] The attention mechanism 73 calculates the hidden state vector he1 to he s The context vector c is calculated by computing the weighted sum of j Specifically, as shown in equation (2), the attention mechanism 73 calculates the attention value a i and the hidden state vector he i This process calculates the product of the context vector c j is obtained.
number
[0029] The attention mechanism 73 calculates the context vector c j and the hidden state vector hd j By concatenating and, the concatenated vector hc j Generate.
[0030] The output layer 74 is a link vector hc j Outputs word Y from sentence Y j The output layer 74 generates, for example, a link vector hc j The output layer 74 calculates the translation score by linearly transforming the word Y j The output layer 74 determines the word Y j is output to the embedding layer 71 and the output unit 16.
[0031] Next, a translation method performed by the translation device 10 will be described with reference to Figs. 6 to 10. Fig. 6 is a flowchart showing a series of processes in the translation method performed by the translation device shown in Fig. 1. Fig. 7 is a flowchart showing in detail the process of determining the translation range shown in Fig. 6. Fig. 8 is a diagram showing an example of chunk division. Fig. 9 is a diagram showing an example of dependency analysis. Fig. 10 is a diagram showing an example of a translation result. The series of processes shown in Fig. 6 is started, for example, when a user speaks using a microphone.
[0032] 6, first, the acquisition unit 11 acquires the original sentence (step S11). In step S11, the acquisition unit 11 acquires the original sentence in order from the beginning of the original sentence. Then, the acquisition unit 11 outputs the acquired original sentence to the division unit 12 in order.
[0033] Next, the division unit 12 divides the original text into chunks (step S12). In step S12, when the division unit 12 receives the original text in order from the acquisition unit 11, the division unit 12 divides the original text into morphemes (words) by performing morphological analysis of the original text using a known method. The division unit 12 generates part-of-speech information indicating the part of speech of each word through the morphological analysis. The part-of-speech information includes part-of-speech tags. Examples of part-of-speech tags include "PRP", "VBD", "IN", "NNP", "WDT", and "VB". "PRP" indicates a personal pronoun. "VBD" indicates the past tense of a verb. "IN" indicates a preposition or a subordinating conjunction. "NNP" indicates the singular form of a proper noun. "WDT" indicates a WH determiner. "VB" indicates the base form of a verb. Then, the division unit 12 divides the original text into chunks using a known method. The dividing unit 12 extracts specific morphemes (words) from the original text by, for example, named entity extraction and rule-based extraction, and divides the original text based on the extracted morphemes.
[0034] A machine learning model (named entity extraction model) is used for named entity extraction. The named entity extraction model may be LSTM, CRF (Conditional Random Fields), or BERT (Bidirectional Encoder Representations from Transformers). Examples of named entity classes used for named entity extraction include English named entity classes defined by MUC (Message Understanding Conference), Japanese named entity classes defined by IREX (Information Retrieve and Extraction Exercise), extended named entity classes, and proprietary named entity classes. Although conjunctions, for example, are extracted according to the rules, other parts of speech such as prepositions may also be extracted. The division unit 12 may divide the source text into chunks using a machine learning technique. In this case, sequence labeling such as BERT and RNN (Recurrent Neural Network) may be used.
[0035] In the example shown in Fig. 8, the division unit 12 extracts the proper nouns "Marriott" and "Nagoya," the conjunction "because," and the WH determiner "which" from the original text So. Then, the division unit 12 divides the original text So according to predetermined rules to generate chunks. In this example, the division unit 12 divides the original text So immediately after the proper nouns and immediately before the conjunctions and WH determiners. As a result, the original text So is divided into chunks Ch1 to Ch4.
[0036] The dividing unit 12 divides the original text into chunks, for example, by inserting delimiter tags into the original text. Delimiter tags are special tokens that indicate division points. The division points are positions at which the original text is divided. The dividing unit 12 then outputs the original text including the delimiter tags together with part-of-speech information to the analyzing unit 13 in order from the beginning of the original text.
[0037] Next, the analysis unit 13 analyzes the dependency of the original sentence (step S13). In step S13, when the analysis unit 13 receives the original sentence including the delimiter tag and the part-of-speech information from the division unit 12, it performs dependency analysis of the original sentence using a known method to generate dependency information between words. As shown in FIG. 9, the dependency information includes a combination of a dependency source word and a dependency destination word, and a dependency tag indicating the meaning of the dependency. Examples of dependency tags include "nsubj," "case," "nmod," "advcl," "punct," "mark," "xcomp," and "ccomp." "nsubj" indicates a subject. "case" indicates a relationship with a particle. "nmod" indicates a modification relationship by a noun class. "advcl" indicates an adverbial clause. "punct" indicates a punctuation mark. "mark" indicates a relative pronoun. "xcomp" indicates a complement phrase. "ccomp" indicates a complement clause.
[0038] In the example shown in Figure 9, dependency information is shown diagrammatically. Delimiter tags are indicated by lines separating division points in the original text So. A dependency relationship exists between two words connected by an arrow. The word at the base of the arrow is the source word, and the word at the tip of the arrow is the destination word. Dependency tags are shown as character strings above the arrow. Then, the analysis unit 13 outputs the source text including the delimiter tags and the dependency information together with the part of speech information to the determination unit 14, starting from the beginning of the original text.
[0039] Next, the determination unit 14 performs a process of determining the translation range (step S14). In step S14, as shown in Fig. 7, the determination unit 14 first receives the original text including the delimiter tag, part-of-speech information, and dependency information from the analysis unit 13, and selects one chunk from the chunks included in the original text as a target chunk (step S41). In step S41, the determination unit 14 selects chunks one by one as target chunks, starting from the beginning of the original text. The following process is repeated for all target chunks, but here we will explain one target chunk.
[0040] Next, the determination unit 14 determines whether the target chunk includes a verb (step S42). If the determination unit 14 determines that the target chunk includes a verb (step S42; YES), it sets the target chunk as a translation range (step S43). On the other hand, if the determination unit 14 determines in step S42 that the target chunk does not include a verb (step S42; NO), it determines whether a chunk including a verb that has a dependency relationship with a word included in the target chunk exists before the target chunk (step S44). In other words, the determination unit 14 determines whether any chunk before the target chunk (closer to the beginning of the sentence) includes a verb that has a dependency relationship with a word included in the target chunk. Note that in this embodiment, the determination unit 14 determines whether a chunk including a verb that is a dependency source of a word included in the target chunk exists before the target chunk.
[0041] Then, if the determination unit 14 determines that there is a chunk before the target chunk that contains a verb that is the source of the word contained in the target chunk (step S44; YES), it sets the translation range from that chunk to the target chunk (step S45).
[0042] Then, the determination unit 14 determines whether the subject is included in the translation range set in step S43 or step S45 (step S46). If the determination unit 14 determines that the subject is included in the translation range (step S46; YES), it determines the translation range as the final translation range and ends the translation range determination process. On the other hand, if the determination unit 14 determines in step S46 that the subject is not included in the translation range (step S46; NO), it adds a chunk including the subject corresponding to the translation range to the translation range (step S47) and ends the translation range determination process. In step S47, the determination unit 14 determines, for example, from the chunk including the subject to the target chunk as the final translation range.
[0043] In step S44, if the determination unit 14 determines that there is no chunk before the target chunk that includes a verb that is a modifier of a word included in the target chunk (step S44; NO), it determines the target chunk as the translation range (step S48) and ends the translation range determination process. Then, the determination unit 14 outputs the translation range (chunks included in the translation range) to the translation unit 15. When the translation range determination process for one target chunk is completed, the determination unit 14 repeats the translation range determination process shown in FIG. 7 until all chunks included in the original text have been selected as target chunks. In other words, the determination unit 14 selects the next chunk as the target chunk (step S41) and performs the processes from step S42 onwards in order.
[0044] In the example shown in Figure 9, chunk Ch1 contains the verb "met" and the subject "We," so only chunk Ch1 is determined as the translation range Si1 of chunk Ch1 (see Figure 10). Chunk Ch2 does not contain a verb, so chunk Ch1 is identified as containing the verb "met," which is the modifier of the word "Nagoya" contained in chunk Ch2. And, because chunk Ch1 contains the subject "We," the range from chunk Ch1 to chunk Ch2 is determined as the translation range Si2 of chunk Ch2 (see Figure 10).
[0045] Because chunk Ch3 contains the verb "decide" and the subject "we," only chunk Ch3 is determined as the translation range Si3 of chunk Ch3 (see Figure 10). Because chunk Ch4 does not contain a verb, chunk Ch3 is identified, which contains the verb "decide," which is the modifier of the word "choose" contained in chunk Ch4. And because chunk Ch3 contains the subject "we," the range from chunk Ch3 to chunk Ch4 is determined as the translation range Si4 of chunk Ch4 (see Figure 10). Note that "to choose" contained in chunk Ch4 is considered to be a to-infinitive, and is therefore not determined to be a verb.
[0046] Next, the translation unit 15 translates the translation range (step S15). When the translation unit 15 receives the translation range (the chunks included in the translation range) from the determination unit 14, the translation unit 15 translates the translation range using, for example, the machine translation model 50, and outputs the translation result to the output unit 16. Specifically, the machine translation model 50 receives, as input sentence X, a character string obtained by arranging the chunks included in the translation range in order from the beginning of the original sentence, and outputs output sentence Y as the translation result. In the example shown in FIG. 10, the English translation ranges Si1 to Si4 are translated into Japanese in order, and Japanese translation sentences St1 to St4 are output, respectively.
[0047] Next, the output unit 16 outputs the translation result (step S16). Upon receiving the translation result from the translation unit 15, the output unit 16 outputs the translation result to an output device such as a display and a speaker. The output unit 16 may output (transmit) the translation result to a device (external device) different from the translation device 10.
[0048] This completes the series of processes in the translation method. Note that step S13 may be performed before step S12 or in parallel with step S12. Steps S46 and S47 may also be performed on the translation range determined (set) in step S48. In step S45, the determination unit 14 sets the translation range from the chunk containing the verb that is the modifier of the word contained in the target chunk to the target chunk, but it is sufficient that at least the chunk containing the verb and the target chunk are included in the translation range. Therefore, if another chunk exists between the chunk containing the verb and the target chunk, the other chunk does not need to be included in the translation range. In step S47, if another chunk exists between the chunk containing the subject and the chunk containing the verb, the other chunk does not need to be included in the translation range.
[0049] In step S47, it is assumed that a chunk including the subject exists before the translation range, but the determination unit 14 may determine whether a chunk including the subject exists before the translation range, and perform step S47 if a chunk including the subject exists before the translation range. In this case, if a chunk including the subject does not exist before the translation range, the determination unit 14 may determine the translation range set in step S43 or step S45 as the final translation range. Steps S46 and S47 may be omitted.
[0050] In the translation device 10 described above, the source text is translated chunk by chunk, thereby reducing the time required to obtain a translation result compared to translating the entire source text. Furthermore, if the target chunk does not contain a verb, the translation range includes a chunk located closer to the beginning of the source text than the target chunk that contains a verb corresponding to a word contained in the target chunk (a verb that has a dependency relationship with the word), and the target chunk, and the translation range is translated. With this configuration, the translation range includes a verb, which can clarify the meaning of each word in the source text and clarify the context. Therefore, it is possible to improve translation accuracy while reducing the time required to obtain a translation result.
[0051] If the target chunk contains a verb, the target chunk is included in the translation range. If the target chunk contains a verb, mistranslation is unlikely to occur even if only the target chunk is translated, so translation accuracy can be maintained.
[0052] For example, when translating a word with the same verb and noun form, such as "train," it may be unclear whether the word is a verb or a noun if there is no subject. Furthermore, the absence of a subject may result in mistranslation into a subject different from the original subject. However, in the translation device 10, when a subject is not included in the translation range, a chunk that includes a subject corresponding to the translation range among chunks located closer to the beginning of the source text than the target chunk is also included in the translation range. With this configuration, the translation range includes a subject and a verb, which are basic components of a sentence, making the context clearer. Therefore, it becomes clear which part of speech a word with the same verb and noun form belongs to. Furthermore, because the subject is clear, the possibility of mistranslation into a different subject is reduced. As a result, it is possible to further improve translation accuracy.
[0053] 10, both translation ranges Si1 and Si2 include chunk Ch1, so there are many overlapping portions between translations St1 and St2. Similarly, both translation ranges Si3 and Si4 include chunk Ch3, so there are many overlapping portions between translations St3 and St4. Therefore, if translations St1 to St4 are output in order, the user may find it unnatural.
[0054] To solve this problem, when a translation range includes a chunk different from the target chunk, the translation unit 15 may identify redundant words from among the words included in the translation range and translate the translation range so that the translation result does not include the redundant words. Redundant words are words that are not included in the translation result of the translation range. The processing of the translation unit 15 according to a modified example will be described in detail below. In this modified example, the determination unit 14 outputs part-of-speech information to the translation unit 15 in addition to the translation range.
[0055] First, when the translation range includes a chunk different from the target chunk, the translation unit 15 identifies redundant words from among words that are closer to the beginning of the original text than the target chunk. Note that the chunk different from the target chunk is closer to the beginning of the original text than the target chunk, and therefore has already been translated as the target chunk.
[0056] An example of a method for identifying redundant words will be described. For example, the translation unit 15 identifies, as redundant words, words that are closer to the beginning of the original sentence than a verb, from among words that are closer to the beginning of the original sentence than the target chunk. For example, as shown in FIG. 11 , the translation range Si2 includes chunk Ch1 (“We met at Marriott”), which is different from chunk Ch2 (“in Nagoya”), which is the target chunk. Therefore, the translation unit 15 identifies, as redundant words Wr, the word “We” that is closer to the beginning of the sentence than the verb “met” included in the translation range Si2. Similarly, the translation range Si4 includes chunk Ch3 (“because we had to decide”), which is different from chunk Ch4 (“which to choose”), which is the target chunk. Therefore, the translation unit 15 identifies, as redundant words Wr, the words “because,” “we,” “had,” and “to,” which are closer to the beginning of the sentence than the verb “decide” included in the translation range Si4.
[0057] Next, the translation unit 15 calculates the attention value a assigned to the redundant word. i is reset to 0. Specifically, the translation unit 15 records the order of redundant words in the translation range as positions where translation is not required. The order of redundant words in the translation range is a number counted from the first word included in the translation range. Then, the context vector c j In the calculation of , if the number i is a position that does not need translation, the attention value a i The calculation is performed with 0. This calculation results in the hidden state vector he corresponding to the redundant word. i is the context vector c j On the other hand, the hidden state vector he s is generated from all words in the source sentence, including redundant words, so that the decoder 70 generates a translation that takes context into account.
[0058] In the example shown in FIG. 11, similar to the example shown in FIG. 10, the English translation ranges Si1 to Si4 are translated into Japanese in order. Because translation range Si1 does not include the redundant word Wr, the translation St11 of translation range Si1 is the same as translation St1. Because translation range Si3 does not include the redundant word Wr, the translation St13 of translation range Si3 is the same as translation St3. On the other hand, because translation range Si2 includes the redundant word Wr, the translation St12 of translation range Si2 does not include the translation result of the redundant word Wr. Similarly, because translation range Si4 includes the redundant word Wr, the translation St14 of translation range Si4 does not include the translation result of the redundant word Wr. Therefore, the overlapping portion between translation St11 and translation St12 is smaller than the overlapping portion between translation St1 and translation St2. The overlapping portion between translation St13 and translation St14 is smaller than the overlapping portion between translation St3 and translation St4.
[0059] In the above modification, when the translation range includes a chunk different from the target chunk, the translation unit 15 identifies redundant words from among the words included in the translation range and translates the translation range so as not to include the translation result of the redundant words. This configuration allows for context-sensitive translation while excluding the translation result of the redundant words. As a result, it is possible to improve translation accuracy while reducing overlap with chunks that have already been translated.
[0060] There is a possibility that a subject or the like may exist before a verb. However, translating a subject or the like that has already been translated again may result in redundancy. On the other hand, omitting the translation of the verb may result in the meaning of the translation being ambiguous. In the above modification, the translation unit 15 identifies, among the words included in the translation range, words that are closer to the beginning of the original sentence than the verb as redundant words. Therefore, it is possible to reduce the redundancy of the translation result while reducing the possibility that the meaning of the translation result will be ambiguous.
[0061] In the above modification, the translation unit 15 calculates the attention value a assigned to the redundant word. i is reset to 0. According to this configuration, all words in the translation range are input to the encoder 60 in order, and the hidden state vector he i Therefore, all words in the translation range are considered, and the translation range is translated taking into account the context. On the other hand, the attention value a assigned to the redundant words i By resetting to 0, the translation result of the redundant word is not included in the translation result of the translation range. Therefore, it is possible to improve the translation accuracy while reducing the overlap with chunks that have already been translated.
[0062] In the above modification, the attention value a assigned to the target word i The sum of the attention values assigned to redundant words is a i The target word is a word included in the translation range that is not a redundant word. Therefore, the attention value a assigned to the redundant word is i If the sum of is small, the attention value a assigned to the redundant word is i Even if the context vector c j does not collapse significantly. In other words, the context vector c j contains the hidden state vector he i On the other hand, the attention value a assigned to redundant words is i If the sum of is large, the attention value a assigned to the redundant word is i is reset to 0, the context vector c j There is a possibility that the context vector c j The value of becomes smaller, and the context vector c j has a hidden state vector he i This may result in a decrease in translation accuracy.
[0063] To solve this problem, the translation unit 15 calculates the attention value a of the target word among the words included in the translation range. i The attention value a of the target word is set so that the sum of i According to this configuration, the attention value a assigned to the redundant word may be adjusted. i Even if is reset to 0, the attention value a of the remaining target words i The sum of these is 1. Therefore, the context vector c j contains the hidden state vector he i Since the translation accuracy is reflected, it is possible to prevent a decrease in translation accuracy.
[0064] For example, the translation unit 15 may use the attention value a i The attention value of the target word is a i By dividing the attention value of the target word a i For example, in the example of FIG. 11, the attention value a assigned to the four redundant words Wr included in the translation range Si4 is adjusted. i If the sum of these redundant words Wr is 0.2, the attention value a i is reset to 0, and the attention values a of the remaining four words (target words) are i In this configuration, the attention value a of the target word is increased by 0.05. i While maintaining the magnitude relationship between the target words, the attention value a i The sum of the context vector c can be set to 1. j The hidden state vector he reflected in i Since the magnitude relationship between the words is maintained, a decrease in translation accuracy can be prevented.
[0065] The translation unit 15 reduces the attention value a assigned to the redundant word. i The attention value of the target word is a i By allocating it according to the ratio of i In the example of FIG. 11, attention values a assigned to four redundant words Wr included in the translation range Si4 may be adjusted. i The sum of the attention values is 0.2, and the attention values of the four target words "decide", "which", "to", and "choose" are a i Assume that the attention values a of the target words "decide", "which", and "to" are 0.1, 0.1, 0.1, and 0.5, respectively. i The attention value a of the target word "choose" is added to 0.025 (=0.2 × 0.1 / (0.1 + 0.1 + 0.1 + 0.5)). i 0.125 (=0.2×0.5 / (0.1+0.1+0.1+0.5)) is added to the target word. i While maintaining the ratio between the attention value a of the target word, i The sum of the context vector c can be set to 1. j The hidden state vector he reflected in i Since the ratio (degree of influence) is maintained, a decrease in translation accuracy can be prevented.
[0066] Another example of a method for identifying redundant words will be described. The translation unit 15 identifies, as redundant words Wr, each of two or more consecutive proper nouns that are located closer to the beginning of the original sentence than the target chunk and have the same named entity class. In this case, the translation unit 15 identifies all words in a chunk that includes the identified redundant word Wr as redundant words Wr. Furthermore, the translation unit 15 identifies, as redundant words Wr, words in chunks that are closer to the beginning of the original sentence than the target chunk and that do not include a subject, a verb, or a proper noun.
[0067] In the example shown in FIG. 12, original text So2 is divided into chunks Ch21 to Ch26. Translation ranges Si21 to Si26 are the translation ranges of chunks Ch21 to Ch26, respectively, determined by the translation range determination process shown in FIG. 7. Translation range Si25 includes chunks Ch21 to Ch24 that are different from chunk Ch25, which is the target chunk. The consecutive words "Nagoya" and "Aichi," which are located closer to the beginning of original text So2 than chunk Ch25, both belong to the "place name" class. Therefore, the translation unit 15 identifies each word included in chunk Ch23, which includes the word "Nagoya," as redundant words Wr, and each word included in chunk Ch24, which includes the word "Aichi," as redundant words Wr.
[0068] Translation range Si26 includes chunks Ch21 to Ch25 that are different from chunk Ch26, the target chunk. Ch25, which is closer to the beginning of source text So2 than chunk Ch26, does not include a subject, a verb, or a proper noun. Therefore, the translation unit 15 identifies each word included in chunk Ch25 as a redundant word Wr. Similar to translation range Si25, the translation unit 15 identifies each word included in chunks Ch23 and Ch24 as a redundant word Wr.
[0069] The above methods may be combined and used. The translation unit 15 may identify, among the words included in the translation range, words excluding words included in the target chunk and verbs as redundant words. Note that instead of the configuration in which the translation unit 15 identifies, among chunks closer to the beginning of the original sentence than the target chunk, words in chunks that do not include a subject, a verb, or a proper noun as redundant words Wr, the determination unit 14 may not include, among chunks closer to the beginning of the original sentence than the target chunk, chunks that do not include a subject, a verb, or a proper noun in the translation range.
[0070] Although the embodiments of the present disclosure have been described above, the present disclosure is not limited to the above embodiments.
[0071] The translation device 10 may be configured as a single device that is physically or logically coupled, or may be configured as multiple devices that are physically or logically separated from each other. For example, the translation device 10 may be realized by multiple computers distributed over a network, such as in cloud computing. As described above, the configuration of the translation device 10 may include any configuration that can realize the functions of the translation device 10.
[0072] The translation device 10 may not include the division unit 12. In this case, the acquisition unit 11 further acquires information indicating division points of the original text and part-of-speech information from outside the translation device 10. The translation device 10 may not include the analysis unit 13. In this case, the acquisition unit 11 further acquires dependency information from outside the translation device 10.
[0073] When the subject is a proper noun, the dividing unit 12 does not need to divide the original sentence immediately after the proper noun.
[0074] If the analysis unit 13 fails in the dependency analysis, the determination unit 14 may take the target chunk as the translation range as is.
[0075] The encoder 60 may include other recurrent computation layers instead of the LSTM layer 62. The decoder 70 may include other recurrent computation layers instead of the LSTM layer 72. Examples of other recurrent computation layers include simple RNNs and GRUs (Gated Recurrent Units).
[0076] The block diagrams used to explain the above embodiments show functional blocks. These functional blocks (components) are realized by any combination of at least one of hardware and software. The method for realizing each functional block is not particularly limited. That is, each functional block may be realized using a single device that is physically or logically coupled, or may be realized using two or more physically or logically separated devices that are connected directly or indirectly (for example, by wire, wirelessly, etc.) and these multiple devices. The functional block may also be realized by combining software with the single device or multiple devices.
[0077] Functions include, but are not limited to, judgment, determination, judgment, calculation, computation, processing, derivation, investigation, search, confirmation, receiving, transmitting, output, accessing, resolving, selection, choosing, establishing, comparing, assuming, expecting, regarding, broadcasting, notifying, communicating, forwarding, configuring, reconfiguring, allocating, mapping, and assigning. For example, a functional block (component) that performs a transmission function is called a transmitting unit or transmitter. As mentioned above, there are no particular limitations on how these functions are implemented.
[0078] For example, the translation device 10 according to an embodiment of the present disclosure may function as a computer that performs the processing of the present disclosure. The hardware configuration of the translation device 10 will be described below. FIG. 13 is a diagram illustrating an example of the hardware configuration of the translation device 10 according to an embodiment of the present disclosure. The above-described translation device 10 may be physically configured as a computer device including a processor 1001, a memory 1002, a storage 1003, a communication device 1004, an input device 1005, an output device 1006, a bus 1007, and the like.
[0079] In the following description, the term "apparatus" may be interpreted as a circuit, a device, a unit, etc. The hardware configuration of translation apparatus 10 may be configured to include one or more of the devices shown in the drawings, or may be configured to exclude some of the devices.
[0080] Each function of the translation device 10 is realized by loading predetermined software (programs) onto hardware such as the processor 1001 and memory 1002, causing the processor 1001 to perform calculations, control communication via the communication device 1004, and control at least one of reading and writing data from and to the memory 1002 and storage 1003.
[0081] The processor 1001, for example, runs an operating system to control the entire computer. The processor 1001 may be configured as a central processing unit (CPU) including an interface with peripheral devices, a control device, an arithmetic unit, and registers. For example, each function of the translation device 10 described above may be realized by the processor 1001.
[0082] The processor 1001 reads programs (program codes), software modules, data, etc. from at least one of the storage 1003 and the communication device 1004 into the memory 1002 and executes various processes in accordance with these. The programs used are those that cause a computer to execute at least some of the operations described in the above-described embodiments. For example, each function of the translation device 10 may be implemented by a control program stored in the memory 1002 and running on the processor 1001. While the above-described various processes have been described as being executed by one processor 1001, they may also be executed simultaneously or sequentially by two or more processors 1001. The processor 1001 may be implemented by one or more chips. The programs may also be transmitted from a network via a telecommunications line.
[0083] The memory 1002 is a computer-readable recording medium and may be configured by, for example, at least one of a read-only memory (ROM), an erasable programmable ROM (EPROM), an electrically erasable programmable ROM (EEPROM), and a random access memory (RAM). The memory 1002 may also be called a register, a cache, a main memory (primary storage device), or the like. The memory 1002 can store executable programs (program codes), software modules, and the like for implementing a translation method according to an embodiment of the present disclosure.
[0084] Storage 1003 is a computer-readable recording medium, and may be, for example, at least one of an optical disk such as a CD-ROM (Compact Disc ROM), a hard disk drive, a flexible disk, a magneto-optical disk (e.g., a compact disk, a digital versatile disk, and a Blu-ray disc), a smart card, a flash memory (e.g., a card, a stick, and a key drive), a floppy disk, and a magnetic strip. Storage 1003 may also be referred to as an auxiliary storage device. The above-mentioned storage medium may be, for example, a database, a server, or other suitable medium including at least one of memory 1002 and storage 1003.
[0085] The communication device 1004 is hardware (transmission / reception device) for communicating between computers via at least one of a wired network and a wireless network, and is also referred to as, for example, a network device, a network controller, a network card, or a communication module. The communication device 1004 may be configured to include a high-frequency switch, a duplexer, a filter, a frequency synthesizer, etc. to realize at least one of frequency division duplex (FDD) and time division duplex (TDD). For example, the above-mentioned acquisition unit 11 and output unit 16 may be realized by the communication device 1004.
[0086] The input device 1005 is an input device (for example, a keyboard, a mouse, a microphone, a switch, a button, a sensor, etc.) that receives input from the outside. The output device 1006 is an output device (for example, a display, a speaker, an LED lamp, etc.) that outputs to the outside. Note that the input device 1005 and the output device 1006 may be integrated into one device, such as a touch panel.
[0087] The processor 1001, memory 1002, and other devices are connected by a bus 1007 for communicating information. The bus 1007 may be configured using a single bus, or may be configured using different buses between the devices.
[0088] Translation device 10 may be configured to include hardware such as a microprocessor, a digital signal processor (DSP), an application specific integrated circuit (ASIC), a programmable logic device (PLD), and a field programmable gate array (FPGA), and some or all of the functional blocks may be realized by the hardware. For example, processor 1001 may be implemented using at least one of these pieces of hardware.
[0089] Notification of information is not limited to the aspects / embodiments described in the present disclosure, and may be performed using other methods.
[0090] In the processing procedures, sequences, flowcharts, etc. of each aspect / embodiment described in this disclosure, the order of processing may be changed unless there is a contradiction. For example, the methods described in this disclosure present elements of various steps using an example order, and are not limited to the specific order presented.
[0091] Information etc. may be output from a higher layer to a lower layer, or may be output from a lower layer to a higher layer. Information etc. may be input / output via multiple network nodes.
[0092] Input and output information may be stored in a specific location (for example, memory) or may be managed using a management table. Input and output information may be overwritten, updated, or added to. Output information may be deleted. Input information may be sent to another device.
[0093] The determination may be made based on a value represented by one bit (0 or 1), a Boolean value (true or false), or a numerical comparison (e.g., comparison with a predetermined value).
[0094] Each aspect / embodiment described in the present disclosure may be used alone, in combination, or switched depending on the implementation. Notification of predetermined information (e.g., notification that "X is true") is not limited to explicit notification, but may be performed implicitly (e.g., by not notifying the predetermined information).
[0095] Although the present disclosure has been described in detail above, it is clear to those skilled in the art that the present disclosure is not limited to the embodiments described herein. The present disclosure can be implemented in modified and altered forms without departing from the spirit and scope of the present disclosure as defined by the claims. Therefore, the description of the present disclosure is intended to be illustrative and does not have any limiting meaning on the present disclosure.
[0096] Software shall be construed broadly to mean instructions, instruction sets, code, code segments, program code, programs, subprograms, software modules, applications, software applications, software packages, routines, subroutines, objects, executable files, threads of execution, procedures, functions, etc., whether referred to as software, firmware, middleware, microcode, hardware description language, or otherwise.
[0097] Software, instructions, information, etc. may be transmitted or received over a transmission medium. For example, if software is transmitted from a website, server, or other remote source using wired technologies (such as coaxial cable, fiber optic cable, twisted pair, Digital Subscriber Line (DSL)), and / or wireless technologies (such as infrared and microwave), then these wired and / or wireless technologies are included within the definition of transmission media.
[0098] The information, signals, etc. described in this disclosure may be represented using any of a variety of different technologies. For example, data, instructions, commands, information, signals, bits, symbols, chips, etc. that may be referred to throughout the above description may be represented by voltages, currents, electromagnetic waves, magnetic fields or magnetic particles, optical fields or photons, or any combination thereof.
[0099] In addition, terms explained in this disclosure and terms necessary for understanding this disclosure may be replaced with terms having the same or similar meanings.
[0100] As used in this disclosure, the terms "system" and "network" are used interchangeably.
[0101] The information, parameters, etc. described in this disclosure may be expressed using absolute values, relative values from a predetermined value, or corresponding other information.
[0102] The names used for the parameters described above are not limiting in any way, and the formulas using these parameters may differ from those explicitly disclosed in this disclosure.
[0103] The terms "determining" and "determining" as used in this disclosure may encompass a wide variety of actions. "Determining" and "determining" may be considered, for example, judging, calculating, computing, processing, deriving, investigating, looking up, search, inquiry (e.g., looking up in a table, database, or another data structure), and ascertaining. "Determining" and "determining" may also be considered, for example, receiving (e.g., receiving information), transmitting (e.g., sending information), input, output, and accessing (e.g., accessing data in memory). "Determining" and "determining" may also be considered, for example, resolving, selecting, choosing, establishing, comparing, and the like. That is, "judgment" and "decision" may be considered as some action related to "judgment" and "decision." "Judgment (decision)" may be read as "assuming," "expecting," or "considering," etc.
[0104] The terms "connected," "coupled," or any variation thereof, refer to any direct or indirect connection or coupling between two or more elements, and may include the presence of one or more intermediate elements between two elements that are "connected" or "coupled" to each other. The coupling or connection between elements may be physical, logical, or a combination thereof. For example, "connected" may be read as "access." When "connected" or "coupled" is used in this disclosure, two elements may be considered to be "connected" or "coupled" to each other using at least one of an electrical wire, cable, and printed electrical connection, or may be considered to be "connected" or "coupled" to each other using electromagnetic energy having wavelengths in the radio frequency range, microwave range, and optical (both visible and invisible) range, as some non-limiting and non-exhaustive examples.
[0105] As used in this disclosure, the phrase "based on" does not mean "based only on," unless expressly stated otherwise. In other words, the phrase "based on" means both "based only on" and "based at least on."
[0106] Any reference to an element using designations such as "first" and "second" used in this disclosure does not generally limit the quantity or order of those elements. These designations may be used in this disclosure as a convenient method of distinguishing between two or more elements. Thus, a reference to a first and a second element does not imply either that only two elements may be employed or that the first element must in some way precede the second element.
[0107] The "unit" in the configuration of each of the above devices may be replaced with a "circuit" or a "device", etc.
[0108] When used in this disclosure, the terms "include," "including," and variations thereof are intended to be inclusive, similar to the term "comprising." Furthermore, when used in this disclosure, the term "or" is not intended to be an exclusive or.
[0109] In this disclosure, where articles are added by translation, such as "a," "an," and "the" in English, the disclosure may include that the nouns following these articles are plural.
[0110] In the present disclosure, the term "A and B are different" may mean "A and B are different from each other." The term may also mean "A and B are each different from C." Terms such as "separate" and "coupled" may also be interpreted in the same way as "different." [Explanation of symbols]
[0111] 10...translation device, 11...acquisition unit, 12...segmentation unit, 13...analysis unit, 14...determination unit, 15...translation unit, 16...output unit, 50...machine translation model.< / eos> < / eos>
Claims
1. A translation device that translates an original text in chunk units, which are processing units, an analysis unit that performs dependency analysis between words included in the original text; a determining unit that determines a translation range for translating a first chunk to be translated; a translation unit that translates the translation range; an output unit that outputs a translation result by the translation unit; Equipped with The determination unit sets only the first chunk as the translation range if the first chunk contains a verb, and if the first chunk does not contain a verb, sets the translation range from the first chunk to a second chunk that contains a verb that has a dependency relationship with a word contained in the first chunk and is closer to the beginning of the original text than the first chunk.
2. 2. The translation device according to claim 1, wherein, when the translation range does not include a subject, the determination unit further includes in the translation range a third chunk that includes a subject corresponding to the translation range and is closer to the beginning of the original sentence than the first chunk.
3. 3. The translation device according to claim 1, wherein, when the translation range includes a chunk different from the first chunk, the translation unit identifies, among the words included in the translation range, words that are closer to the beginning of the original sentence than the verb as redundant words, and translates the translation range so as not to include translation results of the redundant words.
4. the translation unit includes an encoder-decoder translation model with an attention mechanism; The translation device according to claim 3 , wherein the translation unit resets an attention value assigned to the redundant word to 0.
5. The translation device according to claim 4 , wherein the translation unit adjusts the attention values of target words that are words included in the translation range other than the redundant words so that a sum of the attention values becomes one.
6. The translation device according to claim 5 , wherein the translation unit equally allocates the attention values assigned to the redundant words to the attention values of the target words.
7. The translation device according to claim 5 , wherein the translation unit allocates the attention value assigned to the redundant word in accordance with a ratio of the attention value of the target word.
Citation Information
Patent Citations
Sentence cutting method, sentence cutting processing unit using this method, machine translation device and program
JP2003108550A
Machine translation device, method and program
JP2013206253A
Automatic dialogue response document creation artificial intelligence device
JP2018205945A
Chunk-based statistical machine translation system
US20080154577A1
Device and method of simultaneous interpretation based on real-time extraction of interpretation unit
US20180075023A1