A speech recognition method, apparatus, device, and storage medium
By segmenting long word lists into short word lists and training a speech recognition model, and combining Viterbi decoding and long word list matching, the problem of different users' speaking habits affecting speech recognition is solved, achieving higher accuracy and success rate.
Patent Information
- Application Number
- CN202211619425.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-12-14
- Publication Date
- 2025-10-31
- Estimated Expiration
- 2042-12-14
AI Technical Summary
Existing speech recognition systems for smart devices cannot predict each person's speaking habits, resulting in inaccurate speech recognition when there is a discrepancy between the actual spoken content and the preset vocabulary.
The long word list is divided into short word lists, and the speech recognition model is trained using the short word lists. The posterior data is decoded using the Viterbi decoding algorithm, and the recognition results are combined with the long word list to remove interjections or irrelevant words, so as to ensure that speech recognition can be completed even for users with different speaking habits.
It improves the accuracy and success rate of speech recognition, ensures that different users' speaking habits do not affect the recognition results, and enhances the efficiency and flexibility of speech recognition.
Smart Images

Figure CN116129879B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of artificial intelligence technology, and in particular to a speech recognition method, apparatus, device, and storage medium. Background Technology
[0002] With the advancement of technology, intelligent voice technology is also constantly developing. For example, voice recognition technology is becoming increasingly widespread, and various smart devices now basically include voice recognition technology. However, low-power devices such as smart wearable devices, due to limited resources, generally have a certain number of pre-prepared recognition words for support, thus limiting the number of recognition words they can support.
[0003] Currently, most offline speech recognition on smart devices relies on the product's pre-set vocabulary. A speech recognition model is trained using this pre-defined vocabulary, and the audio is then fed into the model to output a posterior probability, which is used to determine the recognition result. However, during model training, it's highly likely that the model cannot predict whether the speaker has unique speaking habits or idiomatic expressions. Because everyone's speaking habits differ, if the actual spoken content deviates from the pre-set vocabulary, recognition may fail, thus affecting the speech recognition result.
[0004] Therefore, there is an urgent need in this field for a speech recognition solution that can improve the accuracy of speech recognition results. Summary of the Invention
[0005] In view of this, embodiments of the present invention provide a speech recognition method, apparatus, device, and storage medium to eliminate or improve one or more defects existing in the prior art.
[0006] One aspect of the present invention provides a speech recognition method, the method comprising the following steps:
[0007] Receive the voice information to be recognized;
[0008] The speech recognition model is used to perform speech recognition on the speech information to be recognized, and the posterior data corresponding to each frame of the speech information to be recognized is obtained; wherein, the speech recognition model is trained based on a short word vocabulary, and the short word vocabulary is obtained by semantically segmenting each long word in the long word vocabulary;
[0009] The posterior data is decoded using the short word vocabulary to sequentially obtain multiple recognition short words corresponding to the speech information to be recognized;
[0010] Based on the long word list and the multiple short words to be identified, the speech recognition result of the speech information to be recognized is determined.
[0011] In some embodiments of the present invention, the training method of the speech recognition model includes:
[0012] Obtain the long word list of the original speech recognition model;
[0013] The long words in the long word list are semantically segmented, and each long word in the long word list is segmented into multiple short words to obtain the short word list;
[0014] Short word speech samples are collected based on the short word vocabulary, and the speech recognition model is obtained by training the model using the short word speech samples.
[0015] In some embodiments of the present invention, the method further includes:
[0016] Based on the source of each short word in the short word list, a mapping relationship is established between each short word in the short word list and each long word in the long word list;
[0017] The step of determining the speech recognition result of the speech information to be recognized based on the long word list and the plurality of short words to be recognized includes:
[0018] Based on the recognition order corresponding to the multiple recognition words, the multiple recognition words are combined to obtain combined words;
[0019] Based on the mapping relationship between each identified short word in the combined words and the long word list, the combined words are matched with the long word list to obtain the speech recognition result.
[0020] In some embodiments of the present invention, the posterior data is the probability of the phoneme corresponding to the speech information to be identified in each frame;
[0021] The step of decoding the posterior data using the short word vocabulary to sequentially obtain multiple recognition short words corresponding to the speech information to be recognized includes:
[0022] Based on the ranking of the probabilities of the phonemes corresponding to the speech information to be recognized in each frame of the posterior data, a set of filtered phonemes whose ranking is within a specified rank is obtained for each frame of the speech information to be recognized.
[0023] The short word list is used to sequentially match and decode the set of filtered phonemes corresponding to the speech information to be identified in each frame, thereby obtaining multiple short words corresponding to the speech information to be identified.
[0024] In some embodiments of the present invention, decoding the posterior data using the short word vocabulary includes:
[0025] The posterior data is decoded using the Viterbi decoding algorithm based on the short word vocabulary.
[0026] In some embodiments of the present invention, determining the speech recognition result of the speech information to be recognized based on the long word list and the plurality of short words includes:
[0027] The multiple short words to be identified are matched with the long word list. If the match fails, the speech recognition model is used to continue to identify the speech information to be identified and to determine the new short words to be identified corresponding to the speech information to be identified.
[0028] The new recognition word is combined with the plurality of recognition words, and the combined recognition word is matched with the long word list until the speech recognition result of the speech information to be recognized is determined in the long word list.
[0029] Another aspect of the present invention provides a voice recognition device, the device comprising:
[0030] The voice receiving module is used to receive the voice information to be recognized;
[0031] The posterior data acquisition module is used to perform speech recognition on the speech information to be recognized using a speech recognition model, and obtain the posterior data corresponding to each frame of the speech information to be recognized; wherein, the speech recognition model is trained based on a short word vocabulary, and the short word vocabulary is obtained by semantically segmenting each long word in the long word vocabulary;
[0032] The short word decoding module is used to decode the posterior data using the short word vocabulary to sequentially obtain multiple recognition short words corresponding to the speech information to be recognized;
[0033] The recognition result determination module is used to determine the speech recognition result of the speech information to be recognized based on the long word list and the multiple short words to be recognized.
[0034] In some embodiments of the present invention, the device further includes a word list mapping module for: establishing a mapping relationship between each short word in the short word list and each long word in the long word list according to the source of each short word in the short word list;
[0035] The identification result determination module is specifically used for:
[0036] Based on the recognition order corresponding to the multiple recognition words, the multiple recognition words are combined to obtain combined words;
[0037] Based on the mapping relationship between each identified short word in the combined words and the long word list, the combined words are matched with the long word list to obtain the speech recognition result.
[0038] Another aspect of the present invention provides a speech recognition device, including a processor and a memory, wherein the memory stores computer instructions, and the processor is used to execute the computer instructions stored in the memory. When the computer instructions are executed by the processor, the device implements the above-described speech recognition method.
[0039] Another aspect of the present invention provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the above-described speech recognition method.
[0040] This invention provides a speech recognition method, apparatus, device, and storage medium. It segments a long word list into a short word list for speech recognition, trains a speech recognition model using the short word list, and then uses this new model to identify the speech information to be recognized. This identifies multiple short words corresponding to the speech information. Based on the combination of these short words and the original long word list, the speech recognition result can be accurately determined. When the speech recognition model trained with the short word list performs speech recognition on the speech information to be recognized, it can remove interjections or other irrelevant words, ensuring that different users' speaking habits can all complete the speech recognition process, thus guaranteeing the accuracy and success rate of the speech recognition results.
[0041] Additional advantages, objects, and features of the invention will be set forth in part in the description which follows, and will also become apparent in part to those skilled in the art upon studying the description, or may be learned by practice of the invention. The objects and other advantages of the invention can be realized and obtained by means of the structures specifically pointed out in the description and drawings.
[0042] Those skilled in the art will understand that the objectives and advantages achievable with the present invention are not limited to those specifically described above, and that the above and other objectives achievable with the present invention will become clearer from the following detailed description. Attached Figure Description
[0043] The accompanying drawings, which are included to provide a further understanding of the invention and form part of this application, are not intended to limit the scope of the invention. The components in the drawings are not drawn to scale but are merely illustrative of the principles of the invention. For ease of illustration and description of certain parts of the invention, corresponding portions in the drawings may be enlarged, i.e., may appear larger relative to other components in an exemplary device actually manufactured according to the invention. In the drawings:
[0044] Figure 1 This is a schematic flowchart of a speech recognition method provided in one embodiment of this specification;
[0045] Figure 2This is a schematic diagram of the training process of the speech recognition model in some embodiments of this specification;
[0046] Figure 3 This is a flowchart illustrating the speech recognition process in another embodiment of this specification;
[0047] Figure 4 This is a schematic diagram of the module structure of one embodiment of the speech recognition device provided in this specification;
[0048] Figure 5 This is a hardware structure block diagram of a speech recognition server in one embodiment of this specification. Detailed Implementation
[0049] To make the objectives, technical solutions, and advantages of this invention clearer, the invention will be further described in detail below with reference to the embodiments and accompanying drawings. Here, the illustrative embodiments and descriptions of this invention are used to explain the invention, but are not intended to limit the invention.
[0050] It should also be noted that, in order to avoid obscuring the invention with unnecessary details, only the structures and / or processing steps closely related to the solution according to the invention are shown in the accompanying drawings, while other details that are not closely related to the invention are omitted.
[0051] It should be emphasized that the term "including / comprises" as used herein refers to the presence of a feature, element, step, or component, but does not exclude the presence or addition of one or more other features, elements, steps, or components.
[0052] It should also be noted that, unless otherwise specified, the term "connection" in this article can refer not only to a direct connection, but also to an indirect connection involving an intermediary.
[0053] In the following description, embodiments of the invention will be illustrated with reference to the accompanying drawings. In the drawings, the same reference numerals represent the same or similar parts, or the same or similar steps.
[0054] Typical speech recognition devices, especially low-power speech recognition devices, are equipped with preset recognition words. During speech recognition, the user's input is matched with these preset words to identify the correct speech. However, speech recognition devices may be used by a variety of users, some of whom have their own speaking habits that may differ from the preset recognition words. For example, the preset recognition word might be "turn on the air conditioner," but in real life, users might say things like "turn on the air conditioner briefly" or "turn on the air conditioner a little later." In this case, "turn on the air conditioner" might not be successfully recognized. Moreover, these situations vary greatly, and the differences in speaking habits across different regions are too numerous to list exhaustively, making it impossible to add all these cases to the vocabulary list.
[0055] This specification provides a speech recognition method that segments a long word list into a short word list. A speech recognition model is trained using this short word list. During speech recognition, the new model identifies multiple short words corresponding to the speech information. Based on the combination of these short words and the original long word list, the speech recognition result can be accurately determined. When the speech recognition model trained with the short word list performs speech recognition on the speech information, it can remove interjections or other irrelevant words, ensuring that different users' speaking habits can all complete the speech recognition process, thus guaranteeing the accuracy and success rate of the speech recognition results.
[0056] Figure 1 Figure 1 is a schematic flowchart of a speech recognition method provided in one embodiment of this specification. In one embodiment of the speech recognition method provided in this specification, the method can be applied to terminal devices such as computers, tablets, servers, smartphones, and smart wearable devices. The method may include the following steps:
[0057] Step 102: Receive the voice information to be recognized.
[0058] In the specific implementation process, during voice recognition, users can speak their requests to voice recognition devices such as smart wearable devices or smart speakers. After recognizing the user's intent, the voice recognition device can output the corresponding result based on the user's request. For example, in a typical smart home, the voice recognition device can connect to the network to control home appliances such as air conditioners and televisions. The user can say "turn on the air conditioner" to the voice recognition device, and the device will recognize and turn on the air conditioner. The voice information to be recognized can be the user's spoken voice to the voice recognition device. It can be Mandarin, a dialect, or other languages, and can be set according to actual needs. This specification does not impose specific limitations on the embodiments; in this specification, the voice information to be recognized is generally Chinese.
[0059] Step 104: Use a speech recognition model to perform speech recognition on the speech information to be recognized, and obtain the posterior data corresponding to each frame of the speech information to be recognized; wherein, the speech recognition model is trained based on a short word vocabulary, and the short word vocabulary is obtained by semantically segmenting each long word in the long word vocabulary.
[0060] In the specific implementation process, after receiving the speech information to be recognized, a speech recognition model can be used to perform speech recognition on the speech information to be recognized. The speech recognition model is an intelligent learning model that can identify words or related information in the speech information to be recognized. The speech recognition model in the embodiments of this specification can be a neural network model. The specific model structure can be set according to actual needs, and this specification does not impose specific limitations. The speech recognition model using a neural network can identify the posterior data corresponding to each frame of the speech information to be recognized. The posterior data can generally be the probability of what pronunciation, word, or recognition result the speech information to be recognized is. In addition, the difference between the speech recognition model in the embodiments of this specification and existing speech recognition models is that the embodiments of this specification are trained using a short word vocabulary. The short word vocabulary is obtained by semantically segmenting each long word in the long word vocabulary of existing speech recognition devices. This avoids the step of reconfiguring the vocabulary, improves the efficiency of speech recognition model training, and lays a data foundation for subsequent speech recognition. In other words, long words in the pre-built long word list of existing voice devices can be segmented into shorter words to obtain a short word list. This short word list can then be used to train and build a new speech recognition model, which is then used for speech recognition. This process removes filler words and other irrelevant words from the speech information to be recognized, ensuring that speech recognition can be completed regardless of the user's speaking habits, thus guaranteeing the accuracy and success rate of the speech recognition results.
[0061] In some embodiments of this specification, the training method of the speech recognition model includes:
[0062] Obtain the long word list of the original speech recognition model;
[0063] The long words in the long word list are semantically segmented, and each long word in the long word list is segmented into multiple short words to obtain the short word list;
[0064] Short word speech samples are collected based on the short word vocabulary, and the speech recognition model is obtained by training the model using the short word speech samples.
[0065] In the specific implementation process Figure 2 This is a schematic diagram illustrating the training process of the speech recognition model in some embodiments of this specification, such as... Figure 2As shown, first, a pre-set long word list from an existing speech recognition device is obtained, such as the long word list used during the training of the original speech recognition model. The long words in the long word list are then semantically segmented into multiple shorter words that conform to semantic meaning. For example, verbs and nouns from long words in the long word list can be extracted; for instance, the long word "turn on the air conditioner" can be segmented into the two shorter words "turn on" and "air conditioner". In practical use, the long word list can be split using a semantic module or a semantic segmentation algorithm. The specific segmentation method is not specifically limited in this embodiment. After splitting the long words in the long word list into shorter words, these shorter words constitute a short word list. Short word speech samples are then collected based on the short word list, for example, by having relevant personnel record the speech corresponding to each short word in the short word list sequentially to obtain short word speech samples. As described in the above embodiments, the model structure of the speech recognition model can be set according to actual needs. This specification does not impose specific limitations on the embodiments. After obtaining short word speech samples, the model structure is set, and the short word speech samples are used for model training to construct a speech recognition model.
[0066] It should be noted that when cutting a long word list to obtain a short word list, only one of the repeated short words needs to be kept.
[0067] This specification's embodiments utilize a short word vocabulary to train and construct a speech recognition model. This allows the trained speech recognition model to identify short words in the speech information being recognized, while interjections or irrelevant words not found in the vocabulary will not be recognized. This allows for the removal of habitual interjections and other words that users frequently use, preventing speech recognition failures due to these unrelated words. Combining the identified short words allows for accurate and rapid determination of the speech recognition result, improving accuracy and success rate.
[0068] Step 106: Decode the posterior data using the short word vocabulary to sequentially obtain multiple recognition short words corresponding to the speech information to be recognized.
[0069] In the specific implementation process, after the speech recognition model recognizes the speech information to be recognized, the model outputs posterior data for each frame of the speech information to be recognized. Then, the short word vocabulary used for training the speech recognition model is used to match and decode the posterior data to obtain multiple recognition short words corresponding to the speech information to be recognized. In some embodiments of this specification, during decoding, the Viterbi decoding algorithm can be used to decode the posterior data using the short word vocabulary. The Viterbi decoding algorithm is a general dynamic programming algorithm for finding the shortest path in a sequence. Using the Viterbi decoding algorithm, the short words that match the short word vocabulary in the posterior data output by the speech recognition model can be quickly and accurately determined, thereby improving the efficiency and accuracy of speech recognition.
[0070] In some embodiments of this specification, the posterior data is the probability of the phoneme corresponding to the speech information to be recognized in each frame;
[0071] The step of decoding the posterior data using the short word vocabulary to sequentially obtain multiple recognition short words corresponding to the speech information to be recognized includes:
[0072] Based on the ranking of the probabilities of the phonemes corresponding to the speech information to be recognized in each frame of the posterior data, a set of filtered phonemes whose ranking is within a specified rank is obtained for each frame of the speech information to be recognized.
[0073] The short word list is used to sequentially match and decode the set of filtered phonemes corresponding to the speech information to be identified in each frame, thereby obtaining multiple short words corresponding to the speech information to be identified.
[0074] In a specific implementation process, when usually performing speech recognition, it is necessary to first extract features from the speech information to be recognized, such as: extracting pronunciation features in the speech information to be recognized, etc., and inputting the extracted features into the speech recognition model, and the model may output the corresponding recognition result. As recorded in the above embodiments, the speech recognition model in the embodiments of this specification can select a neural network model. When using the speech recognition model with this neural network structure to perform speech recognition on the speech information to be recognized, the model can output the probability of the phoneme corresponding to each frame of the speech information to be recognized. That is to say, the speech recognition model can output the probability of the pronunciation corresponding to each frame of the speech information to be recognized. Among them, a phoneme is the smallest speech unit divided according to the natural attributes of speech. Analyzing according to the pronunciation actions in a syllable, one action constitutes one phoneme. For example: when the speech information to be recognized is "Turn on the air conditioner", when the speech recognition model performs speech recognition, it can output that the probability of the phonemes "d, a" corresponding to the first character "dǎ" is 90%. Among them, the speech corresponding to one character of the speech information to be recognized can be one frame or multiple frames of audio, which is specifically determined according to the actual situation, and the embodiments of this specification do not make specific limitations. There can be one or more phonemes corresponding to each frame of the speech information to be recognized output by the speech recognition model, and each phoneme corresponds to a posterior probability. According to the ranking of the probabilities of the phonemes corresponding to each frame of the speech information to be recognized output by the speech recognition model, the phonemes ranked within the specified ranking for each frame can be screened out to obtain the set of screened phonemes corresponding to each frame of the speech information to be recognized. Then, the short word vocabulary is used to sequentially match and decode the set of screened phonemes corresponding to each frame of the speech information to be recognized, and then multiple recognized short words corresponding to the speech information to be recognized are obtained in sequence.
[0075] For example: when the speech information to be recognized is "Turn on the air conditioner", based on the output during speech recognition by the speech recognition model, the set of screened phonemes corresponding to the first frame is obtained as: "d, t", the set of screened phonemes corresponding to the second frame is: "a, ai, ao", there may be some irrelevant frames in the middle, and then the set of screened phonemes corresponding to the fifth frame is: "k, g, l", and the set of screened phonemes corresponding to the sixth frame is: "ai, ao, i, a". After combining the sets of screened phonemes corresponding to these multiple frames of speech and searching in the short word vocabulary, it is found that the short word "Turn on" in the short word vocabulary matches the "d, a", "k, a, i" combined from the sets of screened phonemes of multiple frames of speech, then it can be determined that a short word corresponding to the speech information to be recognized is "Turn on".
[0076] In the embodiments of this specification, the pronunciation and its posterior probability corresponding to each frame of the speech information to be recognized are recognized by using the speech recognition model, and then the phoneme corresponding to each frame of the speech information to be recognized is determined. Then, the short word vocabulary is used to match and decode the phonemes, and the short words in the speech information to be recognized are recognized, laying a data foundation for subsequent speech recognition.
[0077] Step 108: Determine the speech recognition result of the speech information to be recognized based on the long word list and the multiple short words to be recognized.
[0078] In the specific implementation process, after identifying multiple short words corresponding to the speech information to be recognized, a long word list can be used to match the identified short words, thereby determining the speech recognition result of the speech information to be recognized. For example, the identified short words can be combined, and the combined short words can be matched with the long word list to determine the speech recognition result. The short word list in the embodiments of this specification is obtained by splitting the long word list, while the speech recognition model is obtained by training based on the short word list. The identified short words based on the speech recognition model belong to the short word list, and the short words in the short word list can all be obtained in the long word list. Therefore, matching multiple identified short words with the long word list can accurately and quickly obtain the speech recognition result of the speech information to be recognized.
[0079] In some embodiments of this specification, the method further includes:
[0080] Based on the source of each short word in the short word list, a mapping relationship is established between each short word in the short word list and each long word in the long word list;
[0081] The step of determining the speech recognition result of the speech information to be recognized based on the long word list and the plurality of short words to be recognized includes:
[0082] Based on the recognition order corresponding to the multiple recognition words, the multiple recognition words are combined to obtain combined words;
[0083] Based on the mapping relationship between each identified short word in the combined words and the long word list, the combined words are matched with the long word list to obtain the speech recognition result.
[0084] In the specific implementation process, after obtaining the short word list, a mapping relationship can be established between the short words in the short word list and the long words in the long word list, based on the source of each short word in the short word list—that is, from which long word it was derived. For example, if the short word list contains "open," and the long word list contains "open the air conditioner," "open the television," and "open the master bedroom light," it is clear that all three long words in the long word list include "open." Therefore, the source of the short word "open" in the short word list can be derived from these three long words, and a mapping relationship can be established between "open" in the short word list and "open the air conditioner," "open the television," and "open the master bedroom light" in the long word list. After identifying multiple recognition short words in the speech information to be recognized, these multiple recognition short words can be combined according to their order in the speech information or the recognition order of the multiple recognition short words to obtain combined words. Then, based on the mapping relationship of each recognition short word in the combined words in the long word list, the combined words can be quickly matched with the long word list to obtain the speech recognition result.
[0085] For example, multiple short words identified based on the speech information to be recognized include "open" and "air conditioner," which, when combined, form "open the air conditioner." When matching with a long word list, it is found that the short words "open" and "air conditioner" have a mapping relationship with the long word "open the air conditioner" in the long word list, and the combined word is the same as the word in the long word list. Therefore, the speech recognition result can be determined to be "open the air conditioner."
[0086] In the embodiments of this specification, when splitting a long word list to obtain a short word list, a mapping relationship between each word in the short word list and the long word list is established based on the splitting process. When determining the recognition result, the result in the long word list can be quickly and accurately found based on the mapping relationship between the two word lists, thereby quickly obtaining the speech recognition result and improving the efficiency of speech recognition.
[0087] Figure 3 This is a flowchart illustrating the speech recognition process in another embodiment of this specification, such as... Figure 3 As shown in some embodiments of this specification, determining the speech recognition result of the speech information to be recognized based on the long word list and the plurality of short words includes:
[0088] The multiple short words to be identified are matched with the long word list. If the match fails, the speech recognition model is used to continue to identify the speech information to be identified and to determine the new short words to be identified corresponding to the speech information to be identified.
[0089] The new recognition word is combined with the plurality of recognition words, and the combined recognition word is matched with the long word list until the speech recognition result of the speech information to be recognized is determined in the long word list.
[0090] In the specific implementation process, referring to the description of the above embodiments, when performing speech recognition, the speech recognition model can first be used to identify and decode the short words in the speech information to be recognized. The short words are then combined and matched with a long word list. If the matching fails, that is, no long word matching the combination of multiple short words is found in the long word list, the speech recognition model continues to identify and decode the speech information to be recognized to obtain new short words. The new short words are then combined with the previously identified short words, and the combined words are matched with a long word list. If the matching is successful, the speech recognition result is output. If the matching fails, the speech recognition model continues to identify and decode the speech information to be recognized, and the above actions are repeated until the combined short words match the long words in the long word list, thus completing the speech recognition.
[0091] This specification's embodiments analyze the content of recognition words in a long word list through semantic analysis, segmenting these recognition words into shorter ones. During speech recognition, upon recognizing such segmented words, no recognition result is output. Instead, a certain period is waited to see if the latter half of the segmented word appears in subsequent audio. If the latter half of the recognition word appears in subsequent audio, the original, unsegmented recognition word is output, thus obtaining the speech recognition result. This avoids the problem of speech recognition failure due to mismatches between the speech to be recognized and the word list content caused by different users' speaking habits, improving the accuracy and success rate of speech recognition.
[0092] As mentioned above Figures 1-3 As shown, the speech recognition process in the embodiments of this specification can be referred to as follows:
[0093] Step 1. When the long word list is obtained, the long word list is split by the semantic module, and the long words are cut into multiple short words that conform to the semantic situation.
[0094] Step 2. Create a new short word vocabulary using these short words and establish a mapping relationship between it and the original long word vocabulary.
[0095] Step 3. Train the speech recognition model using a short word vocabulary.
[0096] Step 4. Decode the posterior data output by the speech recognition model with a short word vocabulary to obtain the recognition short words.
[0097] Step 5. Record the short word recognition results each time, and combine the subsequent recognition results with the previous recognition results to search in the long word list.
[0098] Step 6. After finding the recognition words in the long word list that meets the requirements, output the final speech recognition result.
[0099] The speech recognition method provided in this specification addresses existing speech recognition devices. While different people may have different speaking habits, they all essentially contain pre-set recognition words, with some grammatical structures added to these words. This specification's embodiments break down longer recognition words into smaller elements based on semantics, further dividing the vocabulary into smaller basic vocabulary elements. Recognition results are also performed based on these smallest word elements. This skips over speaker-specific habitual words, matching the speaker's actual content with the vocabulary content, thereby improving the accuracy and success rate of speech recognition.
[0100] The various embodiments of the methods described in this specification are presented in a progressive manner. Similar or identical parts between the embodiments can be referred to interchangeably. Each embodiment focuses on highlighting the differences from other embodiments. Relevant details can be found in the descriptions of the method embodiments.
[0101] Based on the speech recognition method described above, one or more embodiments of this specification also provide a speech recognition apparatus. The apparatus may include devices (including distributed systems), software (applications), modules, components, servers, clients, etc., using the methods described in the embodiments of this specification, combined with necessary hardware implementations. Based on the same innovative concept, the apparatuses in one or more embodiments provided in this specification are as described in the following embodiments. Since the implementation schemes and methods for solving the problem are similar, the implementation of specific apparatuses in the embodiments of this specification can refer to the implementation of the foregoing methods, and repeated details will not be elaborated further. As used below, the terms "unit" or "module" can refer to a combination of software and / or hardware that implements a predetermined function. Although the apparatuses described in the following embodiments are preferably implemented in software, hardware implementations, or combinations of software and hardware, are also possible and contemplated.
[0102] Specifically, Figure 4 This is a schematic diagram of the module structure of one embodiment of the speech recognition device provided in this specification, as shown below. Figure 4 As shown, the apparatus provided in this specification may include:
[0103] Voice receiving module 41 is used to receive voice information to be recognized;
[0104] The posterior data acquisition module 42 is used to perform speech recognition on the speech information to be recognized using a speech recognition model, and obtain the posterior data corresponding to each frame of the speech information to be recognized; wherein, the speech recognition model is trained based on a short word vocabulary, and the short word vocabulary is obtained by semantically segmenting each long word in the long word vocabulary;
[0105] The short word decoding module 43 is used to decode the posterior data using the short word vocabulary to sequentially obtain multiple recognition short words corresponding to the speech information to be recognized.
[0106] The recognition result determination module 44 is used to determine the speech recognition result of the speech information to be recognized based on the long word list and the multiple short words to be recognized.
[0107] In some embodiments of this specification, the device further includes a word list mapping module, used to: establish a mapping relationship between each short word in the short word list and each long word in the long word list according to the source of each short word in the short word list;
[0108] The identification result determination module is specifically used for:
[0109] Based on the recognition order corresponding to the multiple recognition words, the multiple recognition words are combined to obtain combined words;
[0110] Based on the mapping relationship between each identified short word in the combined words and the long word list, the combined words are matched with the long word list to obtain the speech recognition result.
[0111] The speech recognition device provided in the embodiments of this specification can perform speech recognition of target text in multiple languages, realize cross-language transfer, and allow for flexible combination of language and timbre, thereby improving the flexibility and accuracy of speech recognition and reducing the cost of speech recognition.
[0112] In some embodiments of this specification, a speech synthesis device is also provided, including a processor and a memory. The memory stores computer instructions, and the processor executes the computer instructions stored in the memory. When the computer instructions are executed by the processor, the device implements the speech recognition method described in the above embodiments, such as:
[0113] Receive the voice information to be recognized;
[0114] The speech recognition model is used to perform speech recognition on the speech information to be recognized, and the posterior data corresponding to each frame of the speech information to be recognized is obtained; wherein, the speech recognition model is trained based on a short word vocabulary, and the short word vocabulary is obtained by semantically segmenting each long word in the long word vocabulary;
[0115] The posterior data is decoded using the short word vocabulary to sequentially obtain multiple recognition short words corresponding to the speech information to be recognized;
[0116] Based on the long word list and the multiple short words to be identified, the speech recognition result of the speech information to be recognized is determined.
[0117] It should be noted that the apparatus and equipment described above, based on the method embodiments, may also include other implementation methods. Specific implementation methods can be found in the descriptions of the relevant method embodiments, and will not be elaborated upon here.
[0118] The methods and embodiments provided in this specification can be executed on mobile terminals, computer terminals, servers, or similar computing devices. Taking execution on a server as an example... Figure 5 This is a hardware structure block diagram of a speech recognition server in one embodiment of this specification. The computer terminal can be the speech recognition server or speech recognition device described in the above embodiments. Figure 5 The server 10 shown may include one or more (only one is shown in the figure) processors 100 (processors 100 may include, but are not limited to, microprocessors MCUs or programmable logic devices FPGAs), non-volatile memory 200 for storing data, and a transmission module 300 for communication functions. Those skilled in the art will understand that... Figure 5 The structure shown is for illustrative purposes only and does not limit the structure of the aforementioned electronic device. For example, server 10 may also include components that are more... Figure 5 The components shown may include more or fewer components, and may also include other processing hardware such as databases or multi-level caches, GPUs, or components with similar capabilities. Figure 5 The different configurations shown.
[0119] The non-volatile memory 200 can be used to store software programs and modules of application software, such as the program instructions / modules corresponding to the speech recognition method in the embodiments of this specification. The processor 100 executes various functional applications and resource data updates by running the software programs and modules stored in the non-volatile memory 200. The non-volatile memory 200 may include high-speed random access memory, and may also include non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some instances, the non-volatile memory 200 may further include memory remotely located relative to the processor 100, and these remote memories can be connected to a computer terminal via a network. Examples of such networks include, but are not limited to, the Internet, corporate intranets, local area networks, mobile communication networks, and combinations thereof.
[0120] The transmission module 300 is used to receive or send data via a network. Specific examples of the network described above may include a wireless network provided by the computer terminal's communication provider. In one example, the transmission module 300 includes a Network Interface Controller (NIC), which can connect to other network devices via a base station to communicate with the Internet. In another example, the transmission module 300 may be a Radio Frequency (RF) module, used for wireless communication with the Internet.
[0121] Corresponding to the above method, the present invention also provides an apparatus comprising a computer device including a processor and a memory, the memory storing computer instructions, the processor executing the computer instructions stored in the memory, and the apparatus performing the steps of the method as described above when the computer instructions are executed by the processor.
[0122] This invention also provides a computer-readable storage medium storing a computer program thereon, which, when executed by a processor, implements the steps of the aforementioned edge computing server deployment method. The computer-readable storage medium can be a tangible storage medium, such as random access memory (RAM), main memory, read-only memory (ROM), electrically programmable ROM, electrically erasable programmable ROM, registers, floppy disks, hard disks, removable storage disks, CD-ROMs, or any other form of storage medium known in the art.
[0123] Those skilled in the art will understand that the exemplary components, systems, and methods described in conjunction with the embodiments disclosed herein can be implemented in hardware, software, or a combination of both. Whether implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this invention. When implemented in hardware, it can be, for example, electronic circuits, application-specific integrated circuits (ASICs), appropriate firmware, plug-ins, function cards, etc. When implemented in software, the elements of this invention are programs or code segments used to perform the desired tasks. The programs or code segments can be stored in a machine-readable medium or transmitted over a transmission medium or communication link via data signals carried in a carrier wave.
[0124] It should be clarified that the present invention is not limited to the specific configurations and processes described above and shown in the figures. For the sake of brevity, detailed descriptions of known methods are omitted here. In the above embodiments, several specific steps are described and shown as examples. However, the method process of the present invention is not limited to the specific steps described and shown. Those skilled in the art can make various changes, modifications, and additions, or change the order of steps, after understanding the spirit of the present invention.
[0125] In this invention, features described and / or illustrated for one embodiment may be used in the same or similar manner in one or more other embodiments, and / or combined with or in place of features of other embodiments.
[0126] The above description is merely a preferred embodiment of the present invention and is not intended to limit the present invention. For those skilled in the art, various modifications and variations of the embodiments of the present invention are possible. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the protection scope of the present invention.
Claims
1. A speech recognition method, characterized in that, The method includes: Receive the voice information to be recognized; The speech recognition model is used to perform speech recognition on the speech information to be recognized, and posterior data corresponding to each frame of the speech information to be recognized is obtained; wherein, the speech recognition model is trained based on a short word vocabulary, and the short word vocabulary is obtained by semantic segmentation of each long word in the long word vocabulary; the posterior data is the probability of the phoneme corresponding to each frame of the speech information to be recognized. Based on the probability ranking of the phonemes corresponding to the speech information to be recognized in each frame of the posterior data, a set of filtered phonemes whose ranking is within a specified rank is obtained for each frame of the speech information to be recognized; the short word list is used to sequentially match and decode the set of filtered phonemes corresponding to the speech information to be recognized in each frame, thereby obtaining multiple recognition short words corresponding to the speech information to be recognized. Based on the source of each short word in the short word list, a mapping relationship is established between each short word in the short word list and each long word in the long word list; Based on the recognition order corresponding to the multiple recognition short words, the multiple recognition short words are combined to obtain a combined word; based on the mapping relationship of each recognition short word in the combined word in the long word list, the combined word is matched with the long word list to obtain the speech recognition result.
2. The method according to claim 1, characterized in that, The training method for the speech recognition model includes: Obtain the long word list of the original speech recognition model; The long words in the long word list are semantically segmented, and each long word in the long word list is segmented into multiple short words to obtain the short word list; Short word speech samples are collected based on the short word vocabulary, and the speech recognition model is obtained by training the model using the short word speech samples.
3. The method according to claim 1, characterized in that, Decoding the posterior data using the short word vocabulary includes: The posterior data is decoded using the Viterbi decoding algorithm based on the short word vocabulary.
4. The method according to any one of claims 1-3, characterized in that, The step of determining the speech recognition result of the speech information to be recognized based on the long word list and the plurality of short words to be recognized includes: The multiple short words to be identified are matched with the long word list. If the match fails, the speech recognition model is used to continue to identify the speech information to be identified and to determine the new short words to be identified corresponding to the speech information to be identified. The new recognition word is combined with the plurality of recognition words, and the combined recognition word is matched with the long word list until the speech recognition result of the speech information to be recognized is determined in the long word list.
5. A voice recognition device, characterized in that, The device includes: The voice receiving module is used to receive the voice information to be recognized; The posterior data acquisition module is used to perform speech recognition on the speech information to be recognized using a speech recognition model, and obtain posterior data corresponding to each frame of the speech information to be recognized; wherein, the speech recognition model is trained based on a short word vocabulary, and the short word vocabulary is obtained by semantically segmenting each long word in a long word vocabulary; the posterior data is the probability of the phoneme corresponding to each frame of the speech information to be recognized. The short word decoding module is used to obtain a set of filtered phonemes whose ranking is within a specified rank for each frame of the speech information to be recognized, based on the probability ranking of the phonemes corresponding to each frame of the speech information to be recognized in the posterior data; and to sequentially match and decode the set of filtered phonemes corresponding to each frame of the speech information to be recognized using the short word vocabulary, thereby obtaining multiple recognition short words corresponding to the speech information to be recognized. The recognition result determination module is used to establish a mapping relationship between each short word in the short word list and each long word in the long word list based on the source of each short word in the short word list; to combine the multiple short words according to the recognition order corresponding to the multiple short words to obtain a combined word; and to match the combined word with the long word list according to the mapping relationship of each short word in the combined word in the long word list to obtain the speech recognition result.
6. A voice recognition device, comprising a processor and a memory, characterized in that, The memory stores computer instructions, and the processor executes the computer instructions stored in the memory. When the computer instructions are executed by the processor, the device implements the steps of the method as described in any one of claims 1 to 4.
7. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the program is executed by the processor, it implements the steps of the method as described in any one of claims 1 to 4.
Citation Information
Patent Citations
Equipment and method for detecting key word in continuous speech
CN102194454A
Voice recognition method and system
CN110223678A