Language-agnostic multilingual end-to-end streaming on-device automatic speech recognition (ASR) system
The multilingual ASR system addresses the challenge of large model size and management in on-device streaming by using a multilingual ASR model with multi-head attention layers and end-of-utterance token prediction, enhancing speech recognition accuracy and reducing latency.
Patent Information
- Application Number
- JP2024520915
- Authority / Receiving Office
- JP · JP
- Patent Type
- Applications
- Current Assignee / Owner
- Priority Date
- 2021-10-06
- Filing Date
- 2022-09-22
- Publication Date
- 2024-10-04
- Estimated Expiration
- 2042-09-22
AI Technical Summary
On-device end-to-end speech recognition models are unsuitable for streaming applications due to their large size and cumbersome management when recognizing multiple languages, particularly in managing the evolution and updating of such models.
A multilingual automatic speech recognition system utilizing a multilingual ASR model with a stack of multi-head attention layers, including an encoder and prediction network, to generate higher-order feature representations and probability distributions, and an end-of-utterance token prediction mechanism to manage microphone closure effectively.
The system enables accurate and efficient on-device streaming speech recognition across multiple languages by optimizing model size and latency, ensuring timely microphone closure and improved speech recognition quality.
Smart Images

Figure 2024536387000001_ABST
Abstract
Description
[Technical field]
[0001] The present disclosure relates to a language agnostic, multilingual, end-to-end streaming, on-device automatic speech recognition (ASR) system. [Background technology]
[0002] On-device end-to-end (E2E) speech recognition models exhibit improved quality over monolingual traditional speech recognition models. More specifically, the improved quality is measured by word error rate (WER) and latency, which is the delay between when a user stops speaking and when the speech recognition model produces a recognition result. E2E speech recognition models also exhibit similar improved quality over traditional speech recognition models that can recognize multilingual speech (e.g., multiple different languages). Summary of the Invention [Problem to be solved by the invention]
[0003] However, these E2E speech recognition models are not suitable for on-device streaming applications due to the large model size required to recognize multiple different languages. Moreover, developing and updating a speech recognition model that can recognize multiple different languages can be cumbersome to manage. [Means for solving the problem]
[0004] One aspect of the present disclosure provides a multilingual automatic speech recognition (ASR) system including a multilingual automatic speech recognition ASR model including an encoder with a stack of multi-head attention layers. The encoder is configured to receive as an input a sequence of acoustic frames characterizing one or more utterances to generate a high-level feature representation of a corresponding acoustic frame in the sequence of acoustic frames at each of a plurality of output steps. The multilingual automatic speech recognition ASR model also includes a prediction network configured to receive as an input a sequence of non-blank symbols output by a final softmax layer to generate a hidden representation at each of a plurality of output steps. The multilingual automatic speech recognition ASR model also includes a first joint network configured to receive as input the hidden representation generated by the prediction network at each of the plurality of output steps and the high-level feature representation generated by the encoder at each of the plurality of output steps to generate a probability distribution over possible speech recognition hypotheses at each of a plurality of output steps. The multilingual automatic speech recognition ASR model also includes a second joint network (second joint network) configured to predict as an output an end-of-utterance (EOU) token at the end of each utterance by receiving as inputs the hidden representation generated by the prediction network at each of the plurality of output steps and the high-level feature representation generated by the encoder at each of the plurality of output steps. The multilingual automatic speech recognition ASR system also includes a multilingual end pointer model configured to classify each acoustic frame in the sequence of acoustic frames as either speech, initial silence, middle silence, or final silence.
[0005] Implementations of the present disclosure may include one or more of the following optional features. In some implementations, the multilingual automatic speech recognition ASR system further comprises a microphone closer configured to trigger a microphone close event in response to each end-of-utterance EOU token predicted as an output from the second joint network. In some examples, the multilingual automatic speech recognition ASR system further comprises a microphone closer configured to trigger a microphone close event in response to the multilingual end pointer model classifying the acoustic frame as a final silence. In these examples, the multilingual end pointer model branches from the encoder and can share one computation of the multihead attention layer from the stack of multihead attention layers. In some implementations, the multilingual automatic speech recognition ASR model is trained using a two-stage training process. In these implementations, in a first stage of the two-stage training process, the encoder, the prediction network, and the first joint network are optimized for speech recognition quality, and in a second stage of the two-stage training process, the second joint network is initialized with the first joint network, and the parameters of the encoder, the prediction network, and the first joint network are fixed.
[0006] The multilingual automatic speech recognition ASR model may be trained with multilingual training utterances sampled from a plurality of different languages, where each multilingual training utterance may be linked to a corresponding domain identifier (ID). The multilingual training utterances linked to the corresponding domain IDs representing the voice search domain may include an end-of-utterance EOU training token, and the multilingual training utterances linked to the corresponding domain IDs representing domains other than the voice search domain do not include any end-of-utterance EOU training token. In some implementations, the sequence of acoustic frames characterizes a first utterance spoken in a first language, followed by a second utterance spoken in a second language different from the first language. In some examples, the stack of multi-head attention layers comprises a stack of conformer layers.
[0007] Another aspect of the present disclosure provides a computer-implemented method that, when executed on data processing hardware, performs operations for the data processing hardware to perform language agnostic multilingual end-to-end streaming on-device. The operations include receiving a sequence of acoustic frames characterizing one or more utterances as an input to a multilingual automatic speech recognition (ASR) model. The operations also include generating, at each of the multiple output steps, by an encoder of the multilingual automatic speech recognition ASR model, a high-level feature representation of a corresponding acoustic frame in the sequence of acoustic frames, where the encoder includes a stack of multi-head attention layers. The operations also include generating, at each of the multiple output steps, by a predictive network of the multilingual automatic speech recognition ASR model, a hidden representation based on the sequence of non-whitespace symbols output by the final softmax layer. The operations also include generating, at each of the multiple output steps, by a first joint network of the multilingual automatic speech recognition ASR model, a probability distribution over possible speech recognition hypotheses based on the hidden representation generated by the predictive network at each of the multiple output steps and the high-level feature representation generated by the encoder at each of the multiple output steps. The operations also include predicting, by a second joint network of the multilingual automatic speech recognition ASR model, an end-of-utterance (EOU) token at an end of each utterance based on the hidden representation generated by the prediction network at each of the plurality of output steps and the high-level feature representation generated by the encoder at each of the plurality of output steps, but with the multilingual end pointer model classifying each acoustic frame in the sequence of acoustic frames as either speech, initial silence, middle silence, or final silence.
[0008] Implementations of the present disclosure may include one or more of the following optional features. In some implementations, the operations further include triggering a microphone close event by the microphone closer in response to each end-of-utterance EOU token predicted as an output from the second joint network. In some examples, the operations further include triggering a microphone close event by the microphone closer in response to the multilingual end pointer classifying the acoustic frame as final silence. In these examples, the multilingual end pointer may branch from the encoder and share one computation of the multihead attention layer from the stack of multihead attention layers. In some implementations, the multilingual automatic speech recognition ASR model is trained using a two-stage training process. In these implementations, in a first stage of the two-stage training process, the encoder, the prediction network, and the first joint network are optimized for speech recognition quality, and in a second stage of the two-stage training process, the second joint network is initialized with the first joint network, and parameters of the encoder, the prediction network, and the first joint network are fixed.
[0009] The multilingual automatic speech recognition ASR model may be trained with multilingual training utterances sampled from a plurality of different languages, where each multilingual training utterance may be linked to a corresponding domain identifier (ID). The multilingual training utterances linked to the corresponding domain IDs representing the voice search domain may include an end-of-utterance EOU training token, and the multilingual training utterances linked to the corresponding domain IDs representing domains other than the voice search domain do not include any end-of-utterance EOU training token. In some implementations, the sequence of acoustic frames characterizes a first utterance spoken in a first language, followed by a second utterance spoken in a second language different from the first language. In some examples, the stack of multi-head attention layers comprises a stack of conformer layers.
[0010] The details of one or more embodiments of the disclosure are set forth in the accompanying drawings and the description below. Other aspects, features, and advantages will become apparent from the description and drawings, and from the claims. [Brief description of the drawings]
[0011] [Figure 1] 1 is a schematic diagram of an exemplary multilingual speech recognition system. [Diagram 2] FIG. 2 is a schematic diagram of an exemplary multilingual speech recognition model. [Diagram 3] FIG. 3 is a schematic diagram of an example prediction network of the multilingual speech recognition model of FIG. 2. [Figure 4] 13 shows a plot of sequence classification labels predicted by a multilingual end-pointer model. [Diagram 5] 1 is a flowchart illustrating an exemplary arrangement of operations of a computer-implemented method for performing language agnostic multilingual end-to-end streaming on-device. [Figure 6] FIG. 1 is a schematic diagram of an example computing device that can be used to implement the systems and methods described herein. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS
[0012] Like reference symbols in the various drawings indicate like elements. Automatic speech recognition (ASR) systems can be configured to recognize the end of an utterance, such as the end of a phrase, sentence, query, or command. Rapid and accurate determination of when an utterance has ended is often important to provide accurate results with low latency. For example, if an automatic speech recognition ASR system stops capturing and processing speech prematurely, the resulting transcription may be incomplete or inaccurate because the end of the user's utterance has been cut off. On the other hand, if an automatic speech recognition ASR system continues to wait for additional speech after an utterance has ended, the system may unnecessarily delay responding to the user. Therefore, it is desirable to close the microphone of the user device as soon as the user has finished speaking, but it is necessary to avoid interrupting the utterance midway. Furthermore, for automatic speech recognition ASR systems capable of multilingual speech recognition, this process becomes even more complicated because the languages to be supported are different from each other. Therefore, multilingual automatic speech recognition ASR systems are often very large and are not suitable for on-device streaming applications.
[0013] Accordingly, the embodiments described herein are directed to a multilingual automatic speech recognition ASR system suitable for language agnostic and on-device streaming automatic speech recognition ASR applications. More specifically, the multilingual automatic speech recognition ASR system includes an encoder that generates high-level feature representations for corresponding acoustic frames in a sequence of acoustic frames. The sequence of acoustic frames may correspond to utterances in different languages. In some cases, the sequence of acoustic frames corresponds to a single utterance in which a first portion is in a first language and a second portion is in a second language (i.e., code switching). The multilingual automatic speech recognition ASR system also includes a first joint network that generates a probability distribution over possible speech recognition hypotheses (e.g., speech recognition results) based on the high-level feature representation and the hidden representation generated by the prediction network. The second joint network predicts an end-of-utterance (EOU) token at the end of each utterance based on the high-level feature representation and the hidden representation. A microphone closer may receive the end-of-utterance EOU token and generate a microphone closing event based on the presence of the end-of-utterance EOU token.
[0014] 1 illustrates an automatic speech recognition ASR system 100 that implements a multilingual automatic speech recognition ASR model 200 that resides on a user device 102 of a user 104 and / or on a remote computing device 201 (e.g., one or more servers of a distributed system running in a cloud computing environment) that communicates with the user device 102. Although the user device 102 is illustrated as a mobile computing device (e.g., a smartphone), the user device 102 can correspond to any type of computing device, such as, without limitation, a tablet device, a laptop / desktop computer, a wearable device, a digital assistant device, a smart speaker / display, a smart appliance, an automobile infotainment system, or an Internet of Things (IoT) device, and includes data processing hardware 111 and memory hardware 113.
[0015] The user device 102 includes an audio subsystem 108 including audio capture devices (e.g., microphones) 108, 108a configured to receive speech 106 produced by a user 104 and convert the spoken speech 106 into a corresponding digital format associated with input acoustic frames 110 that can be processed by the automatic speech recognition ASR system 100. The audio subsystem 108 may also include audio output devices (e.g., speakers) 108, 108b for communicating audible audio signals as output audio data from the user device 102. In the illustrated example, the user device 102 implements a single audio capture device 108a, but the user device 102 may implement an array of audio capture devices 108a without departing from the scope of the present disclosure. In this case, one or more capture devices 108a in the array may not be physically resident on the user device 10 and may be in communication with the audio subsystem 108.
[0016] In the illustrated example, a user speaks a respective utterance 106 in the natural language of English for the phrase "What is the weather in New York City?", and the audio subsystem 108 converts the utterance 106 into corresponding acoustic frames 110 for input to the automatic speech recognition ASR system 100. A multilingual automatic speech recognition ASR model (e.g., an automatic speech recognition ASR model) 200 then receives as input the acoustic frames (i.e., a sequence of input speech frames) 110 corresponding to the utterance 106 to generate / predict as output a corresponding transcription 120 (e.g., a recognition result / hypothesis) of the utterance 106. In the illustrated example, the user device 102 and / or the remote computing device 201 also execute a user interface generator 107 configured to present a representation of the transcription 120 of the utterance 106 to the user 104 of the user device 102. In some configurations, the transcription 120 output from the automatic speech recognition ASR system 100 is processed by a natural language understanding (NLU) module, e.g., running on the user device 102 or the remote computing device 201, to execute user commands. Additionally or alternatively, a text-to-speech system (e.g., running on any combination of the user device 102 or the remote computing device 201) can convert the transcription into synthetic speech and output audibly on another device. For example, the original utterance 106 corresponds to a message the user 104 sends to a friend in which the transcription 120 has been converted into synthetic speech and is output audibly so that the friend can hear the message conveyed in the original utterance 106.
[0017] As will become apparent, the user device 102 can receive a microphone closed event 255 (FIG. 2) from the automatic speech recognition ASR model 200. In response to receiving the microphone closed event 255, the user device 102 can prevent the user device 102 from capturing any further audio data after the microphone closed event 255. For example, the user device 102 can deactivate or close one or more microphones 108a. Additionally, the user device 102 can instruct the automatic speech recognition ASR model 200 to cease any active processing on the sequence of acoustic frames 110 and in response to the microphone closed event 255, instruct the user device 102 to perform a transcription function. As a result, speech recognition accuracy is improved since no subsequent speech or background noise is captured by the microphone 108a after the microphone closed event 255.
[0018] Referring to FIG. 2, the automatic speech recognition ASR model 200 includes an encoder 202, a decoder 206, a multilingual end pointer model 210, and a microphone closer 250. The encoder 202 is configured to receive as input a sequence of acoustic frames 110 characterizing one or more utterances 106 (FIG. 1). The automatic speech recognition ASR model 200 is a multilingual automatic speech recognition ASR model configured to recognize utterances from a plurality of different languages. In particular, the automatic speech recognition ASR model 200 can be trained with multilingual training utterances sampled from a plurality of different languages. For example, a first multilingual training utterance may be spoken in English, and a second multilingual training utterance may be spoken in Dutch. In some cases, the sequence of acoustic frames 110 of the multilingual training utterance characterizes a first portion in a first language followed by a second portion spoken in a second language different from the first language. For example, the multilingual training utterance "de jager legt de roos on the chair" contains the first part in Dutch "de jager legt de roos" (the hunter shoots at the target on the chair) and the second part in English "on the chair". A single multilingual training utterance that features terms in one or more different languages is called code-switching.
[0019] In some examples, the sequence of acoustic frames 110 corresponding to each multilingual training utterance is linked to a corresponding domain identifier (ID) 112. The domain ID 112 indicates a speaking domain associated with the multilingual training utterance. For example, the domain ID 112 may represent a voice search / command domain, a videoconferencing domain, or a diarization domain. As will become apparent, the microphone closer 250 may determine whether to generate a microphone close event 255 based on an utterance end token 232, a classification 212, or some combination thereof. For example, the microphone closer 250 may generate a microphone close event 255 based on an utterance end token 232 of the sequence of acoustic frames 110 linked to a domain ID 112 indicating the voice search / command domain. In other examples, the microphone closer 250 may generate a microphone close event 255 based on a classification 212 of the sequence of acoustic frames 110 linked to any domain ID 112 other than the voice search / command domain. Thus, multilingual training utterances linked to corresponding domain IDs 112 representing the voice search / command domain may include end-of-utterance training tokens for training the automatic speech recognition ASR model 200, but multilingual training utterances linked to corresponding domain IDs 112 representing domains other than the voice search / command domain do not include any end-of-utterance training tokens 232 for training the automatic speech recognition ASR model 200.
[0020] A sequence of acoustic frames 110 may be pre-processed by the audio subsystem 108 (FIG. 1) into parameterized acoustic frames (e.g., mel-frames and / or spectral frames). In some implementations, the parameterized acoustic frames 110 correspond to log-mel filterbank energies with log-mel characteristics. For example, a parameterized input acoustic frame 110 representing speech 106 (FIG. 1) input to the encoder 202 may have a sequence of x=(x1,...,x T ), where
[0021]
number
[0022] where is the energy of the log-Mel filter bank, T is the number of frames in x, and d is the number of log-Mel features. In some examples, each parameterized acoustic frame has a 128-dimensional log-mel feature computed within a short shift window (e.g., 32 ms with shifts of 10 ms each). Each feature may be stacked with the previous frame (e.g., the previous three frames) to form a higher dimensional vector (e.g., a 512-dimensional vector using the previous three frames). The features forming the vector may then be downsampled (e.g., to the 30 ms frame rate). For each acoustic frame 110 (x 1:T ), the encoder 202 is configured to generate, at each output step, a second higher-level feature representation 204 of a corresponding acoustic frame 110 in the sequence of acoustic frames 110.
[0023] In some implementations, the encoder 202 includes a stack of multi-head attention layers, each including a multi-head (e.g., 8-head) self-attention mechanism. For example, the stack of self-attention layers may include a stack of conformer layers or transform layers. In the illustrated example, the encoder 202 includes a conformer encoder, which includes a stack of conformer layers (e.g., 12 conformer layers), each including a series of multi-head self-attention, depthwise convolution, and feedforward layers. Each conformer layer performs causal convolution and includes left context attention, constraining the encoder 202 to use future acoustic frames 110 in the sequence of acoustic frames 110 to generate the second higher-level feature representation 204.
[0024] As shown in FIG. 2, the encoder 202 includes a first sub-encoder (first sub-encoder) 202, 202a and a second sub-encoder (second sub-encoder) 202, 202b. The first sub-encoder 202a includes an input projection layer and three (3) conformer layers configured to generate a first high-order feature representation 203 of a corresponding audio frame 110 in the sequence of audio frames 110 at each output step. The second sub-encoder 202b includes a time stacking layer that forms a 60 ms frame by concatenating two (2) adjacent outputs from the first sub-encoder 202a. The second sub-encoder 202b also includes a 1024-dimensional conformer layer, a projection layer, and eight (8) conformer layers followed by layer normalization. The second sub-encoder 202b is configured to receive the first high-order feature representation 203 as an input to generate a second high-order feature representation 204 at each output step.
[0025] The multilingual end pointer model 210 (also referred to simply as "end pointer 210") is configured to generate a classification 212 for each acoustic frame 110 indicating whether the acoustic frame 110 is the end of an utterance. The end pointer 210 branches off from the encoder 202 and shares the computation of one of the multi-head attention layers from the stack of multi-head attention layers. More specifically, the end pointer 210 branches off from the encoder 202 after the first sub-encoder 202a and before the stacking layer of the second sub-encoder 202b. In some examples, the end pointer 210 resides outside the encoder 202, as shown in FIG. 2, while still sharing the computation of the first sub-encoder 202a. In other examples, the end pointer resides in the encoder 202 and shares the computation of the first sub-encoder 202a (not shown). Thus, since the end pointer 210 shares the computation with the encoder 202, both the end pointer 210 and the encoder 202 can be developed and updated synchronously.
[0026] The end pointer 210 is configured to receive as input the first high-level feature representation 203 generated by the first sub-encoder 202a at each of a plurality of output steps corresponding to the sequence of acoustic frames 110, thereby generating a classification 212 of the corresponding first high-level feature representation 203 at each output step. The end pointer 210 transmits the classification 212 of each acoustic frame 110 to the microphone closer 250. FIG. 4 illustrates a plot 400 of an example sequence of classifications 212 output by the end pointer 210 for an utterance 106 ( FIG. 1 ) represented by the sequence of acoustic frames 110. The plot 400 also illustrates a corresponding speech recognition result 222 output by the first joint network 220 at the corresponding output step. In particular, the speech recognition result 222 illustrated in the plot 400 corresponds to the utterance “distance to Boston.” Each classification 212 in the sequence of classifications 212 represents either speech ("0"), initial silence ("1"), middle silence ("2"), or final silence ("3"). When the end pointer 210 outputs a classification 212 indicating final silence of a respective audio frame 110 to the microphone closer 250, the microphone closer 250 is configured to trigger a microphone close event 255. Alternatively, when the end pointer 210 outputs any classification 212 other than final silence to the microphone closer 250, the microphone closer 250 does not trigger a microphone close event 255.
[0027] The end pointer 210 generates the classification 212 based solely on the acoustic information of the first higher-level feature representation 203 corresponding to the acoustic frame 110. That is, the end pointer 210 does not generate the classification 212 based on any information from linguistic information (e.g., the hidden representation 355). Furthermore, the end pointer 210 may determine that the probability of the classification 212 representing a final silence increases over time throughout the utterance.
[0028] The decoder 206 may include a recurrent neural network transducer (RNN-T) architecture with a first joint network 220, a second joint network 230, and a prediction network 300. The decoder 206 generates a decoder output by combining the second high-level feature representation 204 output by the encoder 202 and the hidden representation 355 output by the prediction network 300 using the joint networks 220, 230. More specifically, the first joint network 220 is configured to receive as input the hidden representation 355 generated by the prediction network 300 at each of a plurality of output steps and the high-level feature representation 204 generated by the encoder 202 at each of a plurality of output steps, and generate a probability distribution 222(y) over possible speech recognition hypotheses (e.g., output labels) at each output step.
[0029] The possible speech recognition hypotheses associated with the probability distribution 222 correspond to a set of output labels, each of which represents a symbol / character in the specified natural language. For example, when the natural language is English, the set of output labels may include 27 symbols. For example, there may be one label for each of the 26 letters of the English alphabet and one label representing a space ( <sp>, y=0, y=1, y=2, y=3, y=4, y=5, y=6, y=7, y=8, y=9, y=10, y=11, y=12, y=13, y=14, y=15, y=16, y=17, y=18, y=19, y=20, y=21, y=22, y=23, y=24, y=25, y=26, y=27, y=28, y=29, y=30, y=31, y=32, y=33, y=34, y=35, y=36, y=37, y=38, y=39, y=40, y=41, y=42, y=43, y=44, y=45, y=46, y=47, y=48, y=49, y=50, y=51, y=52, y=53, y=54, y=55, y=60, y=70, y=81, y=91, y=102, y=113, y=123, y=134, y=29, y=35, y=45, y=56, y=14, y=29, y=39, y=41, y=51, y=28, y=35, y=42, y=51, y=29, y=35, y=44, y=52, y=35, y=45, y=53, y=36, y=45 The probability distributions 222 can then be used to select candidate orthographic elements (e.g., graphemes, word fragments, and / or words) in a beam search process (e.g., by a final softmax layer of the first joint network 220) to assign scores and determine the transcription 120 (FIG. 1). That is, the first joint network 220 can output the N best speech recognition results that have the highest probabilities from the corresponding probability distributions 222 across the possible speech recognition hypotheses. Thus, the probability distributions 222 across the possible speech recognition hypotheses and the speech recognition results 222 can be used interchangeably herein.
[0030] Although not shown, the first joint network may include a final softmax layer that receives the probability distributions 222 over the possible speech recognition hypotheses and performs a beam search process to select orthographic elements from the probability distributions 222 over the possible speech recognition hypotheses. In some implementations, the final softmax layer is separate from the first joint network 220. In other implementations, the final softmax layer is integrated into the first joint network 220, such that the output of the first joint network 220 represents the output of the final softmax layer.
[0031] FIG. 3 illustrates how the prediction network 300 of the automatic speech recognition ASR model 200 receives as input a sequence of non-whitespace symbols limited to the N previous non-whitespace symbols output by the final softmax layer of the first joint network 220, thereby generating a hidden representation 355 at each output step. That is, the non-whitespace symbol sequence 222, 222a-n output by the final softmax layer of the first joint network 220 may correspond to a non-whitespace symbol 222 in the speech recognition result. Therefore, the sequence of non-whitespace symbols 222 and the second pass speech recognition hypothesis 222 may be used interchangeably herein. In some examples, N is equal to 2. In other examples, N is equal to 5, but the disclosure is non-limiting and N may be equal to any integer. In some implementations, the prediction network 300 includes a multi-head attention mechanism 302, which shares a shared embedding matrix 304 across each head 302A-302H of the multi-head attention mechanism. In one example, the multi-head attention mechanism 302 includes four heads. However, any number of heads can be used with the multi-head attention mechanism 302. In particular, the multi-head attention mechanism significantly improves performance while minimizing the increase in model size. As explained in more detail below, each head 302A-H has its own row of position vectors 308, so that rather than increasing the model size by concatenating the outputs 318A-H from all heads, the outputs 318A-H are instead averaged by a head averaging module 322.
[0032] Referring to the first head 302A of the multi-head attention mechanism 302, the head 302A uses a shared embedding matrix 304 to derive a corresponding embedding 306, 306a-n (e.g.,
[0033]
number
[0034] In particular, the shared embedding matrix 304 is shared among all heads of the multi-head attention mechanism 302, so that the other heads 302B-H all generate the same corresponding embedding 306 for each non-whitespace symbol. Head 302A also assigns a respective position vector PV Aa~An 308, 308Aa~An (e.g.
[0035]
number
[0036] ) to each non-blank symbol. Each position vector PV 308 assigned to each non-blank symbol indicates a position in the history of the sequence of non-blank symbols (e.g., the N previous non-blank symbols output by the final softmax layer of the first joint network 220). For example, the initial position vector PV Aa is assigned to the most recent position in the history, while the last position vector PV An is assigned to the last position in the history of the N previous non-empty symbols output by the final softmax layer of the first joint network 220. In particular, each of the embeddings 306 may include the same dimensionality (i.e., dimension size) as each of the position vectors PV 308.
[0037] The corresponding embedding generated by the shared embedding matrix 304 for each non-whitespace symbol 120b in the sequence of non-whitespace symbols 222 is the same for all heads 302A-H of the multi-head attention mechanism 302, but each head 302A-H defines a different set / rows of position vectors 308. For example, the first head 302A defines row PV Aa~An 308Aa to 308An, and the second head 302B defines rows PV Ba~Bn 308Ba to Bn, . . . , and the Hth head 302H defines another different row PV Ha~Hn Define 308Ha~Hn.
[0038] For each non-blank symbol 222 in the received sequence of non-blank symbols 222, the first head 302A, via the weighting layer 310, weights the corresponding embedding 306 in proportion to the similarity between the corresponding embedding and the respective position vector PV 308 assigned to it. In some examples, the similarity may include a cosine similarity (e.g., cosine distance). In the example shown, the weighting layer 310 outputs a sequence of weighted embeddings 312, 312Aa-An, each associated with a corresponding embedding 306 weighted in proportion to the respective assigned position vector PV 308. In other words, the weighted embedding 312 output by the weighting layer 310 for each embedding 306 may correspond to a dot product between the embedding 306 and the respective position vector PV 308. The weighted embedding 312 may be interpreted as focusing on the embedding in proportion to how similar it is to the position associated with the respective position vector PV 308. To increase computational speed, the prediction network 300 includes a non-recurrent layer, so that the sequence of weighted embeddings 312Aa-An are not concatenated but instead averaged by a weighted average module 316 to produce as output from the first head 302A a weighted average 318A of the weighted embeddings 312Aa-An, expressed as follows:
[0039]
number
[0040] In equation (1), h represents the index of the head 302, n represents the position in the context, and e represents the embedding dimension. e , with the size of the corresponding dimension. The position vector PV 308 does not need to be trainable and may contain random values. In particular, even if the weighted embedding 312 is averaged, the position vector PV 308 can potentially preserve position history information, alleviating the need to provide recurrent connections at each layer of the prediction network 300.
[0041] The operations described above with respect to the first head 302A are similarly performed for each of the other heads 302B-H of the multi-head attention mechanism 302. Due to the different set of position vectors PV 308 defined by each head 302, the weighting layer 310 outputs a sequence of weighted embeddings 312Ba-Bn, 312Ha-Hn for each of the other heads 302B-H that is different from the sequence of weighted embeddings 312Aa-Aa for the first head 302A. The weighted average module 316 then generates a weighted average 318B-H of each of the corresponding weighted embeddings 312 of the sequence of non-blank symbols as output from each of the other corresponding heads 302B-H.
[0042] In the illustrated example, the prediction network 300 includes a head averaging module 322 that averages the weighted averages 318A-H output from corresponding heads 302A-H. A projection layer 326 with SWISH may receive as an input an output 324 from the head averaging module 322 corresponding to the average of the weighted averages 318A-H to generate as an output a projection output 328. A final layer normalization 330 may normalize the projection output 328 to provide a single embedding vector (e.g., hidden representation) 355 at a corresponding time step from multiple time steps. The prediction network 300 generates only a single embedding vector 355 at each of multiple time steps following the initial time step.
[0043] In some configurations, the prediction network 300 does not implement a multi-head attention mechanism 302 and only performs the operations described above with respect to the first head 302A. In these configurations, the weighted average 318A of the weighted embeddings 312Aa-An is simply passed through the projection layer 326 and layer normalization 330 to provide a single embedding vector 350.
[0044] 2 , the second joint network 230 is configured to predict an end of speech (EOU) token 232 that indicates the end of an utterance. Advantageously, the second joint network 230 generates the end of speech EOU token 232 based on additional linguistic context, i.e., the hidden representation 355. In other words, the second joint network 230 processes the additional linguistic context, thereby providing a more accurate end of speech EOU prediction compared to the acoustic-based classification 212 of the end pointer 210.
[0045] The second joint network 230 is configured to predict an end-of-utterance EOU token 232 at the end of each utterance 106 by receiving as input the hidden representation 355 generated by the prediction network 300 at each of the multiple output steps and the high-level feature representation 204 generated by the encoder 202 at each of the multiple output steps (FIG. 1). The second joint network 230 may output the end-of-utterance EOU token 232 to the microphone closer 250 when the second joint network 230 determines that the second high-level feature representation 204 represents the end of the utterance 106 (FIG. 1) at each output step. That is, the second joint network 230 may determine a score indicating the likelihood that each of the second high-level feature representations 204 corresponds to the end of the utterance 106 (FIG. 1) based on the hidden representation 355 and the second high-level feature representation 204 at each output step. When the score meets the score threshold, the second joint network 230 outputs an end-of-utterance EOU token 232 to the microphone closer 250. When the score does not meet the score threshold, the second joint network 230 refrains from outputting the end-of-utterance EOU token 232 to the microphone closer 250. Thus, the microphone closer 250 triggers a microphone close event 255 in response to each end-of-utterance EOU token 232 predicted as output from the second joint network 230, and closes one or more microphones 108a (FIG. 1) by sending the microphone close event 255 to the user device 102 (FIG. 1).
[0046] The microphone closer 250 may receive the classification 212 and end of speech EOU token 232 corresponding to each acoustic frame 110 in the sequence of acoustic frames (or may not receive the end of speech EOU token 232 when the second joint network 230 does not generate the end of speech EOU token 232). The microphone closer 250 may then determine whether to generate a microphone close event 255 based on the classification 212 or end of speech EOU 232 of the acoustic frame 110. In particular, the microphone closer 250 may make the determination based on the domain ID 112 associated with the sequence of acoustic frames 110. For example, the microphone closer 250 may generate the microphone close event 255 based on the presence of the end of speech EOU token 232 when the domain ID 112 indicates a voice search / command domain. In particular, the voice search / command domain utterances of the microphone closer 250 are contingent on the end of speech EOU token 232 because these utterances do not contain the long pauses that are common in utterances associated with other domains, such as videoconferencing and diarization. In this manner, the microphone closer 250 may reduce latency in generating the microphone close event 255 for the voice search / command domain utterances by using the end of speech EOU token 232 without incurring degradation of the quality of the other domain utterances (e.g., premature generation of the microphone close event 255).
[0047] The automatic speech recognition ASR model 200 may be trained by using a two-stage training process. In the first stage of the two-stage training process, the encoder 202, the prediction network 300, and the first joint network 220 are optimized for speech recognition quality. That is, in the first stage, these components are optimized for minimum word error rate (WER) and / or minimum latency. In the second stage of the two-stage training process, the second joint network 230 is initialized with the first joint network 220, and the parameters of the encoder 202, the prediction network 300, and the first joint network 220 are fixed based on the parameters learned in the first stage. In particular, the second joint network 230 is initialized by using the parameters of the first joint network 220 learned in the first stage. Then, in the second stage, the second joint network 230 further refines the parameters.
[0048] 5 is a flow chart illustrating an example configuration of operations for a method 500 for performing language agnostic multilingual end-to-end streaming on-device. The method 500 can be performed in the data processing hardware 610 (FIG. 6) using instructions stored in the memory hardware 620 (FIG. 6). The data processing hardware 610 and the memory hardware 620 can be present in the user device 102 and / or the remote computing device 60 of FIG. 1 that corresponds to the computing device 600 (FIG. 6).
[0049] In operation 502, the method 500 includes receiving a sequence of acoustic frames 110 characterizing one or more utterances 106 as an input to an encoder 202 of the multilingual automatic speech recognition ASR model 200. In operation 504, the method 500 includes generating, by the encoder 202, a high-level feature representation (e.g., a second high-level feature representation) 204 of a corresponding acoustic frame 110 in the sequence of acoustic frames 110 in each of a plurality of output steps, where the encoder 202 includes a stack of multi-head attention layers. In operation 506, the method 500 includes generating, by the prediction network 300, a hidden representation 355 based on the sequence of non-empty symbols 222 output by the final softmax layer of the first joint network 220 in each of a plurality of output steps. At operation 508, the method 500 includes generating, at each of the plurality of output steps, by the first joint network 220, a probability distribution 222 over possible speech recognition hypotheses based on the hidden representation 355 generated by the prediction network 300 at each of the plurality of output steps and the high-level feature representation 204 generated by the encoder 202 at each of the plurality of output steps. At operation 510, the method 500 includes predicting, by the second joint network 230, an end-of-utterance (EOU) token 232 at the end of each utterance based on the hidden representation 355 generated by the prediction network 300 at each of the plurality of output steps and the high-level feature representation 204 generated by the encoder 202 at each of the plurality of output steps. At operation 512, the method 500 includes classifying, by the multilingual end pointer model 210, each acoustic frame 100 in the sequence of acoustic frames 110 as either speech, initial silence, middle silence, or final silence.
[0050] 6 is a schematic diagram of an exemplary computing device 600 that can be used to implement the systems and methods described in this document. The computing device 600 is intended to represent various forms of digital computers, such as laptops, desktops, workstations, personal digital assistants, servers, blade servers, mainframes, and other suitable computers. The components shown, their connections and relationships, and their functions are for illustrative purposes only and are not intended to limit the implementation of the invention described and / or claimed in this document.
[0051] Computing device 600 includes a processor 610, a memory 620, a storage device 630, a high-speed interface / controller 640 that connects to memory 620 and a high-speed expansion port 650, and a low-speed interface / controller 660 that connects to a low-speed bus 670 and storage device 630. Each of the components 610, 620, 630, 640, 650, and 660 are interconnected using various buses and may be mounted on a common motherboard or may exist otherwise as desired. Processor 610 may process instructions for execution within computing device 600, comprising instructions stored in memory 620 or storage device 630, to display graphical information for a graphical user interface (GUI) on an external input / output device such as a display 680 connected to high-speed interface 640. In other implementations, multiple processors and / or multiple buses may be used as desired, along with multiple memories and memory types. Also, multiple computing devices 600 may be connected, with each device performing some of the required operations (e.g., as a server bank, a group of blade servers, or a multiprocessor system).
[0052] The memory 620 stores information non-transiently within the computing device 600. The memory 620 may be a computer-readable medium, a volatile memory unit(s), or a non-volatile memory unit(s). The non-transient memory 620 may be a physical device used to temporarily or permanently store programs (e.g., sequences of instructions) or data (e.g., program state information) for use by the computing device 600. Examples of non-volatile memory include, but are not limited to, flash memory, read-only memory (ROM) / programmable read-only memory (PROM) / erasable programmable read-only memory (EPROM) / electronically erasable programmable read-only memory (EEPROM) (e.g., typically used for firmware such as boot programs). Examples of volatile memory include, but are not limited to, random access memory (RAM), dynamic random access memory (DRAM), static random access memory (SRAM), phase change memory (PCM), as well as disks, or tapes.
[0053] The storage device 630 can provide mass storage for the computing device 600. In some implementations, the storage device 630 is a computer-readable medium. In various different implementations, the storage device 630 can be an array of devices, including floppy disk devices, hard disk devices, optical disk devices, or tape devices, flash memory or other similar solid-state memory devices, or devices in a storage area network or other configuration. In additional implementations, the computer program product is tangibly embodied in an information carrier. The computer program product comprises instructions that, when executed, perform one or more methods, such as those described above. The information carrier is a computer-readable or machine-readable medium, such as the memory 620, the storage device 630, or memory on the processor 610.
[0054] The high-speed controller 640 manages more of the bandwidth-intensive operations of the computing device 600, and the low-speed controller 660 manages less of the bandwidth-intensive operations. Such an assignment of duties is merely an example. In some implementations, the high-speed controller 640 is coupled to a memory 620, a display 680 (e.g., via a graphics processor or accelerator), and a high-speed expansion port 650 that can accept various expansion cards (not shown). In some implementations, the low-speed controller 660 is coupled to a storage device 630 and a low-speed expansion port 690. The low-speed expansion port 690 may include various communication ports (USB, Bluetooth, Ethernet, wireless Ethernet, etc.) and can connect, via a network adapter or the like, to one or more input / output devices such as a keyboard, a pointing device, a scanner, or a network device such as a switch or router.
[0055] The computing device 600 can be implemented in many different forms, as shown in the figure, for example as a standard server 600a or a group of such servers 600a multiple times, as a laptop computer 600b, or as part of a rack server system 600c.
[0056] Various implementations of the systems and techniques described herein may be realized in digital electronic and / or optical circuitry, integrated circuits, specially designed ASICs (application specific integrated circuits), computer hardware, firmware, software, and / or combinations thereof. These various implementations may include implementation in one or more computer programs executable and / or interpretable by a programmable system including at least one programmable processor, which may be specialized or general purpose, coupled to receive data and instructions from the storage system and to transmit data and instructions to the storage system.
[0057] These computer programs (also known as programs, software, software applications, or codes) comprise machine instructions for a programmable processor and can be implemented in high-level procedural and / or object-oriented programming languages, and / or assembly / machine languages. As used herein, the terms "machine-readable medium" and "computer-readable medium" refer to any computer program product, non-transitory computer-readable medium, apparatus, and / or device (e.g., magnetic disk, optical disk, memory, programmable logic circuit (PLD)) used to provide machine instructions and / or data to a programmable processor comprising a machine-readable medium that receives the machine instructions as a machine-readable signal. The term "machine-readable signal" refers to any signal used to provide machine instructions and / or data to a programmable processor.
[0058] The process and logic flows described herein are performed by one or more programmable processors, also referred to as data processing hardware, which execute one or more computer programs to perform functions by performing operations on input data and generating output. The process and logic flows may also be performed by special purpose logic circuitry, such as an FPGA (field programmable gate array) or an ASIC (application specific integrated circuit). Processors suitable for executing computer programs include, by way of example, both general purpose processors and special purpose microprocessors, as well as any one or more processors of any type of digital computer. Generally, a processor may receive instructions and data from a read-only memory, a random access memory, or both. The essential elements of a computer are a processor for executing instructions and one or more memory devices for storing instructions and data. Typically, a computer also includes one or more mass storage devices for storing data, such as magnetic disks, magneto-optical disks, or optical disks, or is operatively coupled to receive data from, transfer data to, or both of these storage devices. However, such devices are not required for a computer. Computer-readable media suitable for storing computer program instructions and data include all forms of non-volatile memory, media and memory devices, including, by way of example, semiconductor memory devices, such as EPROM, EEPROM, and flash memory devices, magnetic disks, such as internal hard disks or removable disks, magneto-optical disks, and CD-ROM and DVD-ROM disks. The processor and the memory may be supplemented by, or incorporated in, special purpose logic circuitry.
[0059] To provide for user interaction, one or more aspects of the present disclosure may be implemented in a computer having a display device, such as a CRT (cathode ray tube), LCD (liquid crystal display) monitor, or touch screen, for displaying information to a user, and optionally a keyboard and a pointing device, such as a mouse or trackball, by which the user can provide input to the computer. Other types of devices may also be used to provide for user interaction. For example, feedback provided to the user may be any form of sensory feedback, such as visual feedback, auditory feedback, or tactile feedback, and input from the user may be acoustic, verbal, or tactile input. Additionally, the computer may interact with the user by sending and receiving documents to a device used by the user, for example, by sending a web page to a web browser on the user's client device in response to a request received from the web browser.
[0060] Numerous embodiments have been described. Of course, it is understood that various modifications can be made without departing from the spirit and scope of the invention. Accordingly, other embodiments are within the scope of the following claims.< / sp>
Claims
1. A multilingual automatic speech recognition (ASR) system (100), comprising a multilingual automatic speech recognition (ASR) model (200) and a multilingual end pointer model (210); The multilingual automatic speech recognition (ASR) model (200) comprises: An encoder (202) comprising a stack of multi-head attention layers, the encoder (202) comprising: receiving as input a sequence of acoustic frames (110) characterizing one or more utterances (106); the encoder (202) configured to generate, at each of a plurality of output steps, a high-level feature representation (204) of a corresponding acoustic frame (110) in the sequence of acoustic frames (110); A prediction network (300), receiving as input the sequence of non-blank symbols (222) output by the final softmax layer; the prediction network (300) configured to generate a hidden representation (355) at each of a plurality of the output steps; A first joint network (220), receiving as input the hidden representation (355) generated by the prediction network (300) in each of a plurality of output steps and the high-level feature representation (204) generated by the encoder (202) in each of a plurality of output steps; the first joint network (220) configured to generate a probability distribution (222) over possible speech recognition hypotheses at each of a plurality of the output steps; and A second joint network (230), the second joint network (230) configured to predict as an output an end of utterance (EOU) token (232) at the end of each utterance (106) by receiving as input the hidden representation (355) generated by the prediction network (300) in each of a plurality of the output steps and the high-level feature representation (204) generated by the encoder (202) in each of a plurality of the output steps; The multilingual automatic speech recognition ASR model (200), comprising: the multilingual end pointer model (210) configured to classify each of the audio frames (110) in the sequence of audio frames (110) as either speech, initial silence, middle silence, or final silence; A multilingual automatic speech recognition (ASR) system (100).
2. a microphone closer (250) configured to trigger a microphone close event (255) in response to each end-of-utterance (EOU) token (232) predicted as an output from the second joint network (230).
2. The multilingual automatic speech recognition (ASR) system (100) of claim 1.
3. a microphone closer (250) configured to trigger a microphone close event (255) in response to the multilingual end pointer model (210) classifying the audio frame (110) as the final silence. A multilingual automatic speech recognition (ASR) system (100) according to claim 1 or 2.
4. the multilingual end pointer model (210) branches off from the encoder (202) and shares one computation of the multi-head attention layer from the stack of multi-head attention layers; The multilingual automatic speech recognition (ASR) system (100) of claim 3.
5. The multilingual automatic speech recognition ASR model (200) is trained using a two-stage training process, In a first stage of the two-stage training process, the encoder (202), the predictive network (300), and the first joint network (220) are optimized for speech recognition quality; In a second stage of the two-stage training process, the second joint network (230) is initialized with the first joint network (220), and parameters of the encoder (202), the prediction network (300), and the first joint network (220) are fixed. A multilingual automatic speech recognition (ASR) system (100) according to any one of claims 1 to 4.
6. The multilingual automatic speech recognition (ASR) model (220) is trained with multilingual training utterances sampled from a plurality of different languages. A multilingual automatic speech recognition (ASR) system (100) according to any one of claims 1 to 5.
7. Each of the multilingual training utterances is associated with a corresponding domain identifier (ID) (112).
7. The multilingual automatic speech recognition (ASR) system (100) of claim 6.
8. the multilingual training utterances linked to corresponding domain IDs (112) representing voice search domains comprise end-of-utterance (EOU) training tokens (232); the multilingual training utterances linked to corresponding domain IDs (112) representing domains other than the voice search domain do not include any of the end-of-utterance EOU training tokens (232); The multilingual automatic speech recognition (ASR) system (100) of claim 7.
9. the sequence of acoustic frames (110) characterizing a first utterance spoken in a first language followed by a second utterance spoken in a second language different from the first language; A multilingual automatic speech recognition (ASR) system (100) according to any one of claims 1 to 8.
10. the stack of multi-head attention layers comprises a stack of conformer layers; A multilingual automatic speech recognition (ASR) system (100) according to any one of claims 1 to 9.
11. A computer-implemented method (500), when executed by data processing hardware (610), causing the data processing hardware (610) to: receiving a sequence of acoustic frames (110) characterizing one or more utterances (106) as input to a multilingual automatic speech recognition (ASR) model (200); generating, at each of a plurality of output steps, a high-level feature representation (204) of a corresponding acoustic frame (110) in the sequence of acoustic frames (110) by an encoder (202) of a multilingual automatic speech recognition (ASR) model (200), the encoder (202) comprising a stack of multi-head attention layers; generating, by the prediction network (300) of the multilingual automatic speech recognition (ASR) model (200), a hidden representation (355) based on the output (222) of the sequence of non-blank symbols by the final softmax layer at each of the plurality of output steps; generating, by a first joint network (220) of the multilingual automatic speech recognition (ASR) model (200), at each of the plurality of output steps, a probability distribution (222) over possible speech recognition hypotheses based on the hidden representations (255) generated by the prediction network (300) at each of the plurality of output steps and the high-level feature representations (204) generated by the encoder (204) at each of the plurality of output steps; predicting an end of utterance (EOU) token (232) at the end of each utterance (106) by a second joint network (230) of the multilingual automatic speech recognition ASR model (200) based on the hidden representations (355) generated by the prediction network (300) at each of a plurality of output steps and the high-level feature representations (204) generated by the encoder (202) at each of a plurality of output steps; and classifying each audio frame (110) in the sequence of audio frames (110) as either speech, initial silence, middle silence, or final silence using a multilingual end pointer model (210); performing an operation comprising: A computer-implemented method (500).
12. The operations further comprise triggering a microphone close event (255) by a microphone closer (250) in response to each end-of-utterance EOU token (232) predicted as output from the second joint network (230).
12. The computer-implemented method (500) of claim 11.
13. The operations further include triggering a microphone close event (255) by a microphone closer (250) in response to the multilingual end pointer model (210) classifying the audio frame (110) as the final silence.
13. A computer implemented method (500) according to claim 11 or 12.
14. the multilingual end pointer model (210) branches off from the encoder (202) and shares the computation of one of the multi-head attention layers from the stack of multi-head attention layers; 14. The computer-implemented method (500) of claim 13.
15. The multilingual automatic speech recognition ASR model (200) is trained using a two-stage training process, In a first stage of the two-stage training process, the encoder (202), the predictive network (300), and the first joint network (220) are optimized for speech recognition quality; In a second stage of the two-stage training process, the second joint network (230) is initialized with the first joint network (220), and parameters of the encoder (202), the prediction network (300), and the first joint network (220) are fixed. A computer implemented method (500) according to any one of claims 11 to 14.
16. The multilingual automatic speech recognition (ASR) model (200) is trained with multilingual training utterances sampled from a plurality of different languages. A computer implemented method (500) according to any one of claims 11 to 15.
17. Each multilingual training utterance is linked to a corresponding domain identifier (ID) (112).
20. The computer-implemented method (500) of claim 16.
18. the multilingual training utterances linked to corresponding domain IDs (112) representing voice search domains, each comprising an end-of-utterance (EOU) training token (232); the multilingual training utterances linked to corresponding domain IDs (112) representing domains other than the voice search domain do not include any end-of-utterance EOU training tokens (232); 20. The computer-implemented method (500) of claim 17.
19. the sequence of acoustic frames (110) characterizing a first utterance spoken in a first language followed by a second utterance spoken in a second language different from the first language; A computer implemented method (500) according to any one of claims 11 to 18.
20. the multi-head attention layer stack comprising a conformer layer stack; A computer implemented method (500) according to any one of claims 11 to 19.
Citation Information
Patent Citations
Voice recognition device and method and computer program
JP2023028902A
Large-Scale Multilingual Speech Recognition With A Streaming End-To-End Model
US20200380215A1
