A pinyin transcription-based correction method and device and storage medium

CN115831104BActive Publication Date: 2026-10-13ZHONGKE FANYU TECH
View PDF 4 Cites 0 Cited by

Patent Information

Application Number
CN202211437708.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-11-16
Publication Date
2026-10-13
Estimated Expiration
2042-11-16

AI Technical Summary

Benefits of technology

[0025]与现有技术相比,本发明的有益效果包括:将ASR识别结果的噪音词移除并抽取带数字的专有名词,并在ASR识别结果中用第一标识符代替所述专有名词;提取数字参数,同时在ASR识别结果中把提取的所述参数用第二标识符替换所述参数;将所述专有名词替换所述ASR识别结果中的第一标识符;将所述ASR识别结果转化成SSC编码,并匹配最相似的指令,得到校正结果,判断校正结果的参数数目,根据参数数目的数值,得到最终校正结果或者进行校正处理,避免了数字的专有名词的转化,另外避免了数字的校正,从而避免了数字出现同音错误。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115831104B_ABST
    Figure CN115831104B_ABST
Patent Text Reader

Abstract

The application discloses a correction method and device based on pinyin transcription and a storage medium, and belongs to the technical field of speech recognition. The correction method based on pinyin transcription comprises the following steps: S1, removing noise words of an ASR recognition result and extracting a special term with a number, and replacing the special term with a first identifier in the ASR recognition result; S2, extracting a digital parameter, and replacing the extracted parameter with a second identifier in the ASR recognition result; S3, replacing the first identifier with the special term in the ASR recognition result; S4, converting the ASR recognition result into SSC coding, matching the most similar instruction in an instruction set as the optimal instruction, and obtaining a correction result; and S5, judging the number of parameters of the correction result, and obtaining a final correction result or performing correction processing according to the value of the number of parameters. The method can avoid the occurrence of homonym errors of numbers.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of speech recognition, and in particular to a correction method, apparatus and storage medium based on Pinyin transcription. Background Art

[0002] Speech instruction recognition technology allows operators to manipulate system functions only through speech without manual operation, which can greatly improve operation efficiency. Although speech recognition technology has achieved a high accuracy rate, inaccurate recognition often occurs when speech instructions are short or in professional fields. In the actual system operation process, there is usually a specific instruction set. If the speech recognition result is limited to a limited instruction set, the most similar instruction can be selected by comparing the similarity between the recognition result and the instructions in the instruction set, so as to achieve the purpose of instruction correction. On the other hand, the instructions also contain various parameters. For example, when a speech instruction contains a digital parameter, it is difficult for the system to correct the parameter, and homophone errors are prone to occur, for example, recognizing "one" as "clothes" and "four" as "attendant". How to avoid homophone errors of numbers is a problem to be solved in the prior art. At the same time, the instruction may also have Chinese character parameters. In case of errors, it is difficult for the system to distinguish between Chinese character parameters and Chinese character instructions, which leads to interference from Chinese character parameters during the correction process, resulting in correction to an incorrect instruction. The above two situations will lead to wrong output. Instruction recognition errors or parameter recognition errors will greatly affect the accuracy of system operation and cause adverse consequences. Therefore, how to design an effective post-correction method for speech instruction recognition is of great significance for the practical application of speech instruction recognition systems. Summary of the Invention

[0003] The purpose of the present invention is to overcome the above technical deficiencies, and provide a correction method, apparatus and storage medium based on Pinyin transcription, so as to solve the technical problem of how to avoid homophone errors of numbers.

[0004] To achieve the above technical purpose, the technical solution of the present invention provides a correction method based on Pinyin transcription, comprising the following steps:

[0005] S1. Removing noise words from the ASR recognition result, extracting proper nouns with numbers, and replacing the proper nouns with a first identifier in the ASR recognition result;

[0006] S2. Extracting digital parameters, and replacing the extracted parameters with a second identifier in the ASR recognition result;

[0007] S3. Replacing the first identifier in the ASR recognition result with the proper noun;

[0008] S4. Convert the ASR recognition result processed in step S3 into SSC encoding, and match the most similar instruction in the instruction set as the optimal instruction to obtain the correction result.

[0009] S5. Determine the number of parameters in the correction result, and obtain the final correction result or perform correction processing based on the value of the number of parameters.

[0010] Furthermore, in step S5, if the number of parameters is 0, then the correction result is taken as the final correction result.

[0011] Further, in step S5, if the number of parameters is not 0, according to the optimal instruction and the ASR recognition result, the parameter part in the ASR recognition result is found, the numerical parameter of the parameter part is converted into Arabic numerals, and the corrected result is used to replace the parameter part in the optimal instruction.

[0012] Furthermore, converting the numerical parameters in the correction results into Arabic numerals includes: converting the Chinese character numerical parameters into numbers using the Hanzi2num module; using the similarity calculation module built into SSC encoding to calculate the similarity between individual Chinese characters and numerical parameters; and simultaneously using jieba word segmentation technology to identify the Chinese character parameters, thus avoiding misconversion caused by Chinese characters being identified as numerical parameters. The working process of the hanzi2num module is as follows: using word segmentation to identify the noun part of the ASR recognition result parameters; treating characters that do not form words as misidentified numerical parameters and converting them into numbers based on similarity.

[0013] Furthermore, if the number of parameters is not 0, the ASR recognition result parameter part is searched by matching the characters before and after the parameter part of the optimal instruction as markers.

[0014] Furthermore, word segmentation is used to identify nouns in the parameters of the ASR recognition results; characters that do not form words are considered as misidentifications of numerical parameters and are converted into numbers based on similarity.

[0015] Further, in step S4, the search for the most similar instruction includes:

[0016] T1. Extract the final vowel code, initial consonant code, final vowel complement code, and tone code of each Chinese character in the SSC encoding, and concatenate them into a first sequence;

[0017] T2. Compare the similarity between the first sequence and the Chinese character parts in the instruction set, and take the Chinese character part with the smallest similarity value as the correction result.

[0018] Furthermore, this invention also proposes a correction device based on Pinyin transcription, comprising:

[0019] An extraction unit is used to remove noise words from the ASR recognition results and extract proper nouns with numbers, and replace the proper nouns with a first identifier in the ASR recognition results;

[0020] An extraction unit is used to extract digital parameters and replace the extracted parameters with a second identifier in the ASR recognition result.

[0021] A replacement unit is used to replace the first identifier in the ASR recognition result with the proper noun;

[0022] The correction unit is used to convert the ASR recognition result into SSC encoding and match the most similar instruction in the instruction set as the optimal instruction to obtain the correction result;

[0023] The judgment unit is used to judge the number of parameters in the correction result, and obtain the final correction result or perform correction processing based on the value of the number of parameters.

[0024] Furthermore, the present invention also proposes a storage medium storing a computer program thereon, which, when executed by a processor, implements the steps of the post-correction method for the above-mentioned voice command recognition.

[0025] Compared with the prior art, the beneficial effects of the present invention include: removing noise words from the ASR recognition result and extracting proper nouns containing numbers, and replacing the proper nouns with a first identifier in the ASR recognition result; extracting numerical parameters, and replacing the extracted parameters with a second identifier in the ASR recognition result; replacing the first identifier in the ASR recognition result with the proper nouns; converting the ASR recognition result into SSC encoding, matching the most similar instruction to obtain the correction result, determining the number of parameters in the correction result, and obtaining the final correction result or performing correction processing based on the value of the number of parameters, thus avoiding the conversion of proper nouns containing numbers and avoiding the correction of numbers, thereby avoiding homophonic errors in numbers. Attached Figure Description

[0026] Figure 1 This is a flowchart illustrating a correction method based on pinyin transcription in a specific embodiment of the present invention;

[0027] Figure 2 This is a schematic diagram of the structure of a correction device based on Pinyin transcription according to a specific embodiment of the present invention;

[0028] Figure 3 These are examples of three recognition results in Embodiment 1 of the present invention;

[0029] Figure 4 This is an example of the correction result based on least common string recognition in Embodiment 1 of the present invention;

[0030] Figure 5 This is an example of a fuzzy matching result in Embodiment 1 of the present invention;

[0031] Figure 6 This is a correction example based on the digital parameter matching method in Embodiment 1 of the present invention. Detailed Implementation

[0032] Combination Figure 1 This specific implementation proposes a correction method based on Pinyin transcription, including the following steps:

[0033] S1. Remove noise words from the ASR recognition results and extract proper nouns with numbers, and replace the proper nouns with the first identifier in the ASR recognition results;

[0034] S2. Extract the numerical parameters, and replace the extracted parameters with the second identifier in the ASR recognition result;

[0035] S3. Replace the first identifier in the ASR identification result with the proper noun;

[0036] S4. Convert the ASR recognition result processed in step S3 into SSC encoding, and match the most similar instruction in the instruction set as the optimal instruction to obtain the correction result.

[0037] The instructions for finding the most similar item include:

[0038] T1. Extract the final vowel code, initial consonant code, final vowel complement code, and tone code of each Chinese character in the SSC encoding, and concatenate them into a first sequence;

[0039] T2. Compare the similarity between the first sequence and the Chinese character parts in the instruction set, and take the Chinese character part with the smallest similarity value as the correction result;

[0040] Step S5: Determine the number of parameters in the correction result. If the number of parameters is 0, then the correction result is taken as the final correction result. If the number of parameters is not 0, based on the optimal instruction and the ASR recognition result, find the parameter part in the ASR recognition result, convert the numerical parameters of the parameter part into Arabic numerals, and replace the parameter part in the optimal instruction with the corrected result. Converting the numerical parameters in the correction result into Arabic numerals includes: converting Chinese character numerical parameters into numbers using the Hanzi2num module, using the similarity calculation module built into SSC encoding to calculate the similarity between a single Chinese character and the numerical parameters, and using jieba word segmentation technology to identify the Chinese character parameters to avoid Chinese words being identified as numerical parameters and causing incorrect conversion. The working process of the hanzi2num module is as follows: using word segmentation to identify the nouns in the parameter part of the ASR recognition result; treating characters that do not form words as misidentified numerical parameters and converting them into numbers based on similarity.

[0041] If the number of parameters is not 0, the characters before and after the optimal instruction parameter part are used as markers for matching, and the ASR recognition result parameter part is searched; the word segmentation method is used to identify the nouns in the ASR recognition result parameter part; characters that do not form words are regarded as misidentifications of numerical parameters and converted into numbers according to similarity.

[0042] Combination Figure 2 This specific embodiment also proposes a correction device based on Pinyin transcription, including:

[0043] An extraction unit is used to remove noise words from the ASR recognition results and extract proper nouns with numbers, and replace the proper nouns with a first identifier in the ASR recognition results;

[0044] An extraction unit is used to extract digital parameters and replace the extracted parameters with a second identifier in the ASR recognition result.

[0045] A replacement unit is used to replace the first identifier in the ASR recognition result with the proper noun;

[0046] The correction unit is used to convert the ASR recognition result into SSC encoding and match the most similar instruction in the instruction set as the optimal instruction to obtain the correction result;

[0047] The judgment unit is used to judge the number of parameters in the correction result, and obtain the final correction result or perform correction processing based on the value of the number of parameters.

[0048] This specific embodiment also proposes a storage medium on which a computer program is stored, which, when executed by a processor, implements the steps of the post-correction method for the above-described voice command recognition.

[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 accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the invention.

[0050] Example 1

[0051] This embodiment proposes a correction method based on Pinyin transcription, including the following steps:

[0052] S1. First, remove noisy words such as "on" and "off" from the ASR recognition results. Then, extract some proper nouns with numbers from the ASR recognition results into the list:proper_nouns and replace them with the first identifier "+" in the ASR recognition results to prevent the proper nouns from being misidentified as numerical parameters.

[0053] S2. Extract the numerical parameters, and replace the extracted parameters with the second identifier "*" in the ASR recognition result, and output the number of parameters num_alpha;

[0054] S3. Replace the first identifier "+" in the ASR identification result with the proper noun;

[0055] S4. Convert the ASR recognition result processed in step S3 into SSC encoding, match the most similar instruction, select the instruction with the lowest similarity in the instruction set as the optimal instruction, denoted as best_str. Output best_str to obtain the correction result;

[0056] The ASR recognition result processed in step S3 is converted into SSC encoding, and the most similar instruction is matched as follows:

[0057] S41. Convert the ASR recognition result into SSC encoding. For each Chinese character, the SSC conversion program used in this embodiment converts the pronunciation of the Chinese character into a 4-character encoding, which in turn represents the vowel code, the initial code, the vowel complement code, and the tone code.

[0058] S42. Extract the vowel code, initial code, vowel complement code and tone code from the encoding obtained in step S1, and concatenate them into a first sequence list.

[0059] S43. Perform the same operation on the Chinese characters in the instruction set to concatenate them into a second sequence list;

[0060] S44. Calculate the similarity between the two instructions in steps S42 and S43. Let the ASR recognition result be asr, and its Chinese character part final vowel code, initial consonant code, final vowel complement code, and tone code be asr_ym, asr_sm, asr_ymbm, and asr_yd, respectively. Let the instruction set be str, and its corresponding Chinese character part final vowel code, initial consonant code, final vowel complement code, and tone code be str_ym, str_sm, str_ymbm, and str_yd, respectively. Let the minimum edit distance between string a and string b be edit_dist(a, b). This embodiment proposes the following similarity calculation formula:

[0061] Similarity=3*edit_dist(asr, str)+3*edit_dist(asr_ym, str_ym)+3*edit_dist(asr_sm, str_sm)+edit_dist(asr_ymbm, str_ymbm)+edit_dist(asr_yd, str_yd)

[0062] Among them, the final and initial codes are given higher weights (weight 3) for the string itself, while the final complement and tone codes are given lower weights (weight 1).

[0063] In this embodiment, step S5 is also included: determining whether the number of parameters in best_str and the number of parameters in num_alpha are both 0; if so, output best_str and end the program; this is because there are no parameters in the instruction set at this time; if not, use the longest common string matching best_str and ASR recognition result to find the parameter param (at this time, Chinese character parameters can be recognized); determine whether best_str and param meet the following three conditions: A) "*" in best_str is only located at both ends of the instruction; B) in the non-parameter part, the number of characters in best_str is equal to the number of characters in the ASR recognition result; C) the number of parameters in param is equal to the number of parameters in best_str; if the three conditions are met at the same time, use the Chinese character to number parameter conversion module (hanzi2num) to convert the number parameters in param into Arabic numerals. The corrected result is then used to replace the asterisk (*) in best_str, resulting in out_str, which is then output, ending the program. The Hanzi2num module converts Chinese character parameters to numbers. It uses SSC's built-in similarity calculation module to calculate the similarity between individual Chinese characters and number parameters, resolving the issue of homophone recognition errors in numbers. Simultaneously, it employs jieba word segmentation technology to identify the Chinese character parameters, preventing words from being mistakenly identified as parameters and leading to incorrect conversions. For example... Figure 3 As shown, Figure 3From left to right shown are the ASR recognition result, the result of correcting only digit homophone errors, and the correction result of the hanzinum module; in the ASR recognition result, "fan" (the character meaning flip) should be "san" (the character meaning three); when only homophone errors are corrected, "fan" can be correctly corrected to "san", but "ji" (the character meaning machine) is also incorrectly recognized as "yi" (the character meaning one) at the same time; while in the hanzi2num module, the word segmentation method is first used to identify the two characters "ji chang" (airport), preventing them from being incorrectly converted into numbers; and since "fan" cannot form a word, the system regards it as a misrecognition of a numeric parameter, converts it to "san" according to similarity, and finally achieves correct conversion;

[0064] An example of recognition and correction based on minimum common string recognition is as follows Figure 4 shown;

[0065] If the above three conditions cannot be met at the same time, a fuzzy matching method is used to find the fuzzy parameter fuzzy_param; the fuzzy matching method performs matching using the characters before and after "*" as markers, and an example is as follows Figure 5 shown, for example Figure 5 shown, match "she" (the character meaning set) and "yi" (the character meaning one) in the ASR recognition result with "she" and "yi" in best_str, then "ji chang 9" in the middle green box can match "*"; further, if the fuzzy matching satisfies two conditions at the same time: A) there is only one parameter in best_str, B) there is only one parameter in fuzzy_param, then the hanzi2num module is used to correct the mispronounced digit homophone in fuzzy_param, then the obtained parameter is substituted into best_str to obtain and output out_str, and the program ends; if the above two conditions cannot be met at the same time, the parameter in num_alpha is substituted into best_str to obtain and output out_str, and the program ends;

[0066] A correction example based on the numeric parameter matching method is as Figure 6 shown, it can be seen that the digit matching can accurately extract the parameter and replace the parameter identifier "*".

[0067] Advantages of the present invention:

[0068] 1. From the perspective of finding the optimal instruction:

[0069] The present invention adopts SSC code encoding, which can convert Chinese characters into a 4-character phonetic code. Meanwhile, the initial consonant, final consonant and tone are extracted separately. Compared with pinyin transcription:

[0070] 1) It can ensure that the edit distance does not change due to the length of pinyin, ensuring the uniformity of the edit distance;

[0071] 2) Easily confused sound pairs such as "zh" and "z", "ang" and "an" are assigned the same code, effectively taking into account the speaker's habits. Furthermore, the assigned codes can be modified directly in the backend to accommodate different people's speaking habits;

[0072] 3) Calculating the editing distance separately for initials, finals, final complements, and tones can effectively take into account the different weights of the four items.

[0073] Compared to Soundex transcription:

[0074] 1) The encoding of vowels is taken into consideration, and this invention is also applicable to Chinese language processing;

[0075] 2) In addition to easily confused sound pairs, different syllables are assigned different codes with numbers to effectively prevent the phenomenon of the same code but different sounds.

[0076] Compared to directly using SSC encoding:

[0077] 1) Increased the weight of initials, finals, and tones when recognizing instructions;

[0078] 2) When calculating similarity, the direct edit distance from the ASR recognition result to the correct instruction was included. Therefore, the influence of numerical values ​​was also taken into account.

[0079] II. From the perspective of parameter matching and result output:

[0080] 1) This invention integrates three matching methods: direct number extraction, longest common string matching, and fuzzy matching. By combining the strengths of each method and making up for their weaknesses, it can effectively prevent the drawbacks of any single method and achieve the highest recognition efficiency.

[0081] 2) This invention can perform special processing on certain special instructions;

[0082] 3) This invention can correctly restore numbers even when homophone errors occur during number recognition;

[0083] This invention can find the optimal instruction when ASR recognition errors occur, and combines multiple methods to find parameters before outputting the final result. This improves recognition accuracy and precision. It effectively solves the recognition error problem when the speech duration is short under a fixed instruction set. Based on actual recorded speech data, its recognition accuracy can reach 96%.

[0084] The specific embodiments of the present invention described above do not constitute a limitation on the scope of protection of the present invention. Any other corresponding changes and modifications made in accordance with the technical concept of the present invention should be included within the scope of protection of the claims of the present invention.

Claims

1. A correction method based on Pinyin transcription, characterized in that, Includes the following steps: S1. Remove noise words from the ASR recognition results and extract proper nouns with numbers, and replace the proper nouns with the first identifier in the ASR recognition results; S2. Extract the numerical parameters, and replace the extracted parameters with the second identifier in the ASR recognition result; S3. Replace the first identifier in the ASR identification result with the proper noun; S4. Convert the ASR recognition result processed in step S3 into SSC encoding, and match the most similar instruction in the instruction set as the optimal instruction to obtain the correction result. S5. Determine the number of parameters in the correction result, and obtain the final correction result or perform correction processing based on the value of the number of parameters. In step S4, finding the most similar instruction includes: T1. Extract the final vowel code, initial consonant code, final vowel complement code, and tone code of each Chinese character in the SSC encoding, and concatenate them into a first sequence; T2. Compare the similarity between the first sequence and the Chinese character parts in the instruction set, and take the Chinese character part with the smallest similarity value as the correction result; The formula for calculating similarity is: Similarity=3*edit_dist(asr, str)+3*edit_dist(asr_ym, str_ym)+3*edit_dist(asr_sm, str_sm)+edit_dist(asr_ymbm, str_ymbm)+edit_dist(asr_yd, str_yd); In the formula, Similarity represents the degree of similarity; edit_dist(a, b) is the minimum edit distance between string a and string b; asr is the ASR recognition result; str is the instruction set; asr_ym is the vowel code of the Chinese character part of the ASR recognition result; asr_sm is the initial consonant code of the Chinese character part of the ASR recognition result; asr_ymbm is the complement code of the vowel part of the Chinese character part of the ASR recognition result; asr_yd is the tone code of the Chinese character part of the ASR recognition result; str_ym is the vowel code of the Chinese character part corresponding to the instruction set; str_sm is the initial consonant code of the Chinese character part corresponding to the instruction set; str_ymbm is the complement code of the vowel part of the Chinese character part corresponding to the instruction set; str_yd is the tone code of the Chinese character part corresponding to the instruction set. In step S5, if the number of parameters is not 0, based on the optimal instruction and the ASR recognition result, the parameter part in the ASR recognition result is searched; it is determined whether the optimal instruction and the parameter part simultaneously satisfy the following three conditions: Condition A, the second identifier in the optimal instruction is only located at both ends of the instruction; Condition B, in the non-parameter part, the number of characters in the optimal instruction is equal to the number of characters in the ASR recognition result; Condition C, the number of parameters in the parameter part is equal to the number of parameters in the optimal instruction; if the three conditions are satisfied simultaneously, the numerical parameters in the parameter part are converted into Arabic numerals, and the corrected result is used to replace the parameter part in the optimal instruction. If the above three conditions cannot be met simultaneously, a fuzzy matching method is used to find fuzzy parameters. The fuzzy matching method involves matching the characters before and after the parameter part of the optimal instruction as markers, and searching the ASR recognition results to obtain the fuzzy parameters. If the fuzzy matching simultaneously meets the following two conditions: Condition D, the optimal instruction has only one parameter; Condition E, the fuzzy parameters have only one parameter; then the fuzzy parameters are converted into Arabic numerals, and the converted Arabic numerals are substituted into the optimal instruction to obtain the correction result. If conditions D and E cannot be met simultaneously, the numerical parameters extracted in step S2 are substituted into the optimal instruction to obtain the final correction result. Converting the numerical parameters in the correction results into Arabic numerals includes: converting Chinese character numerical parameters into numbers using the hanzi2num module; using the similarity calculation module built into SSC encoding to calculate the similarity between individual Chinese characters and numerical parameters; and simultaneously using word segmentation technology to identify Chinese character parameters, avoiding misconversion caused by Chinese words being identified as numerical parameters. The working process of the hanzi2num module is as follows: using word segmentation to identify nouns in the ASR recognition result parameters; treating characters that do not form words as misidentified numerical parameters and converting them into numbers based on similarity.

2. The correction method based on pinyin transcription according to claim 1, characterized in that, In step S5, if the number of parameters is 0, then the correction result is taken as the final correction result.

3. The correction method based on pinyin transcription according to claim 1, characterized in that, The word segmentation method is used to identify the noun part of the ASR recognition result parameters; characters that do not form words are regarded as misidentifications of numerical parameters and converted into numbers based on similarity.

4. A correction device based on Pinyin transcription, characterized in that, include: An extraction unit is used to remove noise words from the ASR recognition results and extract proper nouns with numbers, and replace the proper nouns with a first identifier in the ASR recognition results; An extraction unit is used to extract digital parameters and replace the extracted parameters with a second identifier in the ASR recognition result. A replacement unit is used to replace the first identifier in the ASR recognition result with the proper noun; The correction unit is used to convert the ASR recognition result into SSC encoding and match the most similar instruction in the instruction set as the optimal instruction to obtain the correction result; The judgment unit is used to judge the number of parameters in the correction result, and obtain the final correction result or perform correction processing based on the value of the number of parameters. In the correction unit, finding the most similar instruction includes: T1. Extract the final vowel code, initial consonant code, final vowel complement code, and tone code of each Chinese character in the SSC encoding, and concatenate them into a first sequence; T2. Compare the similarity between the first sequence and the Chinese character parts in the instruction set, and take the Chinese character part with the smallest similarity value as the correction result; The formula for calculating similarity is: Similarity=3*edit_dist(asr, str)+3*edit_dist(asr_ym, str_ym)+3*edit_dist(asr_sm, str_sm)+edit_dist(asr_ymbm, str_ymbm)+edit_dist(asr_yd, str_yd); In the formula, Similarity represents the degree of similarity; edit_dist(a, b) is the minimum edit distance between string a and string b; asr is the ASR recognition result; str is the instruction set; asr_ym is the vowel code of the Chinese character part of the ASR recognition result; asr_sm is the initial consonant code of the Chinese character part of the ASR recognition result; asr_ymbm is the complement code of the vowel part of the Chinese character part of the ASR recognition result; asr_yd is the tone code of the Chinese character part of the ASR recognition result; str_ym is the vowel code of the Chinese character part corresponding to the instruction set; str_sm is the initial consonant code of the Chinese character part corresponding to the instruction set; str_ymbm is the complement code of the vowel part of the Chinese character part corresponding to the instruction set; str_yd is the tone code of the Chinese character part corresponding to the instruction set. In the judgment unit, if the number of parameters is not 0, the parameter part in the ASR recognition result is searched according to the optimal instruction and the ASR recognition result; it is judged whether the optimal instruction and the parameter part simultaneously satisfy the following three conditions: Condition A, the second identifier in the optimal instruction is only located at both ends of the instruction; Condition B, in the non-parameter part, the number of characters in the optimal instruction is equal to the number of characters in the ASR recognition result; Condition C, the number of parameters in the parameter part is equal to the number of parameters in the optimal instruction; if the three conditions are satisfied at the same time, the numerical parameters in the parameter part are converted into Arabic numerals, and the corrected result is used to replace the parameter part in the optimal instruction. If the above three conditions cannot be met simultaneously, a fuzzy matching method is used to find fuzzy parameters. The fuzzy matching method involves matching the characters before and after the parameter part of the optimal instruction as markers, and searching for ASR recognition results to obtain fuzzy parameters. If the fuzzy matching simultaneously satisfies the following two conditions: Condition D, the optimal instruction contains only one parameter; Condition E, the fuzzy parameters contain only one parameter; then the fuzzy parameters are converted into Arabic numerals, and the converted Arabic numerals are substituted into the optimal instruction to obtain the correction result. If conditions D and E cannot be met simultaneously, the numerical parameters extracted by the extraction unit are substituted into the optimal instruction to obtain the final correction result. Converting the numerical parameters in the correction results into Arabic numerals includes: converting Chinese character numerical parameters into numbers using the hanzi2num module; using the similarity calculation module built into SSC encoding to calculate the similarity between individual Chinese characters and numerical parameters; and simultaneously using word segmentation technology to identify Chinese character parameters, avoiding misconversion caused by Chinese words being identified as numerical parameters. The working process of the hanzi2num module is as follows: using word segmentation to identify nouns in the ASR recognition result parameters; treating characters that do not form words as misidentified numerical parameters and converting them into numbers based on similarity.

5. A storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by the processor, it implements the steps of the correction method based on pinyin transcription as described in any one of claims 1-3.

Citation Information

Patent Citations

  • Improved character string similarity comparison method

    CN108009253A

  • Phone number error correction method and device based on data processing, and computer device

    CN109712616A

  • Corpus recognition method and device

    CN111540343A

  • Text processing method and device, electronic equipment and medium

    CN112115706A