A text acquisition method, device, storage medium and computer equipment

By calculating the edit distance between the recognition texts of the target audio by multiple audio recognition systems and determining the target recognition text, the problem of low accuracy of speech recognition in the prior art is solved, and more efficient text acquisition is achieved.

CN115410574BActive Publication Date: 2025-04-11BEIJING XIYU JIZHI TECH CO LTD +1
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202210952021.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-08-09
Publication Date
2025-04-11
Estimated Expiration
2042-08-09

AI Technical Summary

Technical Problem

The existing automatic speech recognition technology has low accuracy and has a long recognition time, which cannot effectively solve the accuracy of speech conversion into text.

Method used

By obtaining the set of recognition texts for the target audio by multiple audio recognition systems, the editing distance between different recognition texts is calculated, and the target recognition text is determined, thereby improving the accuracy of text acquisition.

Benefits of technology

It improves the accuracy of text acquisition, reduces recognition time, and enhances the efficiency of speech recognition.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115410574B_ABST
    Figure CN115410574B_ABST
Patent Text Reader

Abstract

The present application discloses a text acquisition method, device, storage medium and electronic device, wherein the method comprises: acquiring a set of recognized texts obtained by recognizing a target audio, the recognized text set comprising a plurality of recognized texts obtained by each audio recognition system in an audio recognition system set respectively recognizing the target audio, the audio recognition system set comprising at least three audio recognition systems, the audio recognition systems in the audio recognition system set corresponding one to one to the recognized texts in the recognized text set, respectively acquiring the edit distance between two recognized texts in the recognized text set, determining a target audio recognition system in the audio recognition system set based on the plurality of edit distances, and determining the target recognized text corresponding to the target audio recognition system in the recognized text set as the output text of the target audio. By adopting the present application, the target recognized text is determined by calculating the edit distance between different recognized texts, thereby improving the accuracy of text acquisition.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of computer technology, and in particular to a text acquisition method, device, storage medium and computer equipment. Background Art

[0002] Automatic speech recognition technology is often used in the prior art to perform speech recognition and convert speech into text content. However, the existing automatic speech recognition technology mainly relies on manually set speech conversion rules, has low accuracy and long recognition time, and needs to propose a speech recognition method with higher accuracy. Summary of the invention

[0003] The embodiments of the present application provide a text acquisition method, device, storage medium and electronic device, which can determine the target recognition text by calculating the edit distance between different recognition texts, thereby improving the accuracy of text acquisition. The technical solution is as follows:

[0004] In a first aspect, an embodiment of the present application provides a text acquisition method, comprising: acquiring a recognition text set obtained by recognizing a target audio, the recognition text set comprising a plurality of recognition texts obtained by each audio recognition system in an audio recognition system set recognizing the target audio, the audio recognition system set comprising at least three audio recognition systems, and the audio recognition systems in the audio recognition system set corresponding one-to-one to the recognition texts in the recognition text set; acquiring respectively the edit distance between two recognition texts in the recognition text set, and determining a target audio recognition system in the audio recognition system set based on the plurality of edit distances; and determining in the recognition text set a target recognition text corresponding to the target audio recognition system as the output text of the target audio.

[0005] In a second aspect, an embodiment of the present application provides a text acquisition device, comprising: a text set acquisition module, used to acquire a recognition text set obtained by recognizing a target audio, the recognition text set comprising a plurality of recognition texts obtained by each audio recognition system in an audio recognition system set recognizing the target audio, the audio recognition system set comprising at least three audio recognition systems, and the audio recognition systems in the audio recognition system set corresponding one-to-one to the recognition texts in the recognition text set; a target system determination module, used to acquire the edit distance between two recognition texts in the recognition text set, and determine a target audio recognition system in the audio recognition system set based on the plurality of edit distances; an output text determination module, used to determine a target recognition text corresponding to the target audio recognition system in the recognition text set as the output text of the target audio.

[0006] In a third aspect, an embodiment of the present application provides a computer storage medium, wherein the computer storage medium stores a plurality of instructions, wherein the instructions are suitable for being loaded by a processor and executing the steps of the above-mentioned method.

[0007] In a fourth aspect, an embodiment of the present application provides an electronic device, comprising: a processor and a memory; wherein the memory stores a computer program, and the computer program is suitable for being loaded by the processor and executing the steps of the above method.

[0008] In an embodiment of the present application, a set of recognized texts obtained by recognizing a target audio is obtained, the recognized text set includes multiple recognized texts obtained by each audio recognition system in an audio recognition system set respectively recognizing the target audio, the audio recognition system set includes at least three audio recognition systems, the audio recognition systems in the audio recognition system set correspond one to one to the recognized texts in the recognized text set, the edit distance between two recognized texts is respectively obtained in the recognized text set, the target audio recognition system is determined in the audio recognition system set based on the multiple edit distances, and the target recognized text corresponding to the target audio recognition system in the recognized text set is determined as the output text of the target audio. The target recognized text is determined by calculating the edit distance between different recognized texts, thereby improving the accuracy of text acquisition. BRIEF DESCRIPTION OF THE DRAWINGS

[0009] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

[0010] Figure 1 This is an example schematic diagram of text acquisition provided in an embodiment of the present application;

[0011] Figure 2 It is a flowchart of a text acquisition method provided in an embodiment of the present application;

[0012] Figure 3 It is a flowchart of a text acquisition method provided in an embodiment of the present application;

[0013] Figure 4 This is an example schematic diagram of an editing example acquisition provided in an embodiment of the present application;

[0014] Figure 5 It is a flowchart of a text acquisition method provided in an embodiment of the present application;

[0015] Figure 6is a structural schematic diagram of a text acquisition device provided in an embodiment of the present application;

[0016] Figure 7 is a structural diagram of a target system determination module provided in an embodiment of the present application;

[0017] Figure 8 It is a structural schematic diagram of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0018] The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.

[0019] The text acquisition device can be a terminal device such as a mobile phone, a computer, a tablet computer, a smart watch or a vehicle-mounted device, or a module in the terminal device for implementing the text acquisition method. The text acquisition device can acquire the target audio and the text content corresponding to the target audio, that is, the output text of the target audio. The target audio can be the audio containing voice information recorded by the user for the terminal device, or it can be the audio locally stored in the terminal device or acquired from the network. After the text acquisition device acquires the output text of the target audio, the output text can be displayed on the terminal device.

[0020] Please also see Figure 1 , provides an example diagram of text acquisition for the embodiment of the present application. The text recognition device can obtain the target audio input by the user and use the audio recognition system to recognize the target audio. The audio recognition system is an automatic speech recognition technology (Automatic Speech Recognition, ASR) system, which can convert human speech into text. The text recognition device can use each audio recognition system in the audio recognition system set to recognize the target audio separately to obtain multiple recognized texts, such as Figure 1 In the recognition text 1, recognition text 2, ..., recognition text n, n is an integer greater than or equal to 2, the audio recognition system set includes at least three audio recognition systems, and then the text acquisition device can find a target recognition text in the multiple recognition texts based on the edit distance, determine the target recognition text as the output text, and then control the terminal device to display the output text. The edit distance is a quantitative measurement of the degree of difference between two character strings, and the measurement method is to see how many times of processing is required to transform one character string into another character string.

[0021] The text acquisition method provided by the present application is described in detail below in conjunction with specific embodiments.

[0022] See also Figure 2 , which is a flowchart of a text acquisition method provided in an embodiment of the present application. Figure 2 As shown, the method in the embodiment of the present application may include the following steps S101-S103.

[0023] S101, obtaining a recognition text set obtained by recognizing the target audio.

[0024] Specifically, the text acquisition device can use each audio recognition system in the audio recognition system set to recognize the target audio respectively, thereby obtaining multiple recognized texts and saving them in the recognized text set. It can be understood that the audio recognition systems in the audio recognition system set correspond one-to-one to the recognized texts in the recognized text set, and one audio recognition system corresponds to one recognized text.

[0025] S102: Obtain edit distances between two recognized texts in the recognized text set respectively, and determine a target audio recognition system in the audio recognition system set based on multiple edit distances.

[0026] Specifically, the text acquisition device can obtain the edit distance between two recognized texts in the text set respectively to obtain multiple edit distances. For example, if there are three recognized texts in the text set, the text acquisition device can obtain four edit distances. The text acquisition device can determine the target audio recognition system in the audio recognition system set based on these multiple edit distances. For example, if there are n audio recognition systems in total, n recognized texts of the target audio can be obtained, and the edit distance between each two recognized texts can be calculated. An audio recognition system has n-1 corresponding edit distances. The sum of the edit distances corresponding to the audio recognition system can be obtained by adding the n-1 edit distances. The edit distance reflects the difference between the recognized texts. The smaller the edit distance, the more similar the two recognized texts are, and the higher the accuracy of the recognized text. The text recognition device can identify the audio recognition system with the smallest sum of edit distances as the target audio recognition system. It can be understood that when performing text recognition on the target audio, the target audio recognition system is the audio recognition system with the highest accuracy in the audio recognition system set.

[0027] S103, determining the target recognition text corresponding to the target audio recognition system in the recognition text set as the output text of the target audio.

[0028] Specifically, the text acquisition device can determine the target recognition text corresponding to the target audio recognition system in the recognition text set as the output text of the target audio, and the text acquisition device can display the output text on the terminal device.

[0029] In an embodiment of the present application, a set of recognized texts obtained by recognizing a target audio is obtained, the recognized text set includes multiple recognized texts obtained by each audio recognition system in an audio recognition system set respectively recognizing the target audio, the audio recognition system set includes at least three audio recognition systems, the audio recognition systems in the audio recognition system set correspond one to one to the recognized texts in the recognized text set, the edit distance between two recognized texts is respectively obtained in the recognized text set, the target audio recognition system is determined in the audio recognition system set based on the multiple edit distances, and the target recognized text corresponding to the target audio recognition system in the recognized text set is determined as the output text of the target audio. The target recognized text is determined by calculating the edit distance between different recognized texts, thereby improving the accuracy of text acquisition.

[0030] See also Figure 3 , which is a flowchart of a text acquisition method provided in an embodiment of the present application. Figure 3 As shown, the method of the embodiment of the present application may include the following steps S201-S205.

[0031] S201, obtaining a recognition text set obtained by recognizing the target audio.

[0032] Specifically, the text acquisition device can use each audio recognition system in the audio recognition system set to recognize the target audio respectively, thereby obtaining multiple recognized texts and saving them in the recognized text set. It can be understood that the audio recognition systems in the audio recognition system set correspond one-to-one to the recognized texts in the recognized text set, and one audio recognition system corresponds to one recognized text.

[0033] S202: Obtain the edit distance between two recognized texts in the recognized text set.

[0034] Specifically, the text acquisition device can respectively acquire the edit distance between two recognized texts in the text set, thereby obtaining multiple edit distances. For example, if there are three recognized texts in the text set, the text acquisition device can obtain four edit distances.

[0035] Optionally, the text acquisition device can obtain the first recognized text corresponding to the first audio recognition system in the recognized text set. The first audio recognition system can be any audio recognition system in the audio recognition system set. The first recognized text is the recognized text obtained after the first audio recognition system recognizes the target audio. The text acquisition device can respectively obtain the first edit distance between the first recognized text and the second recognized text in the recognized text set. The second recognized text is the other recognized text in the recognized text set except the first recognized text. It can be understood that there can be multiple second recognized texts and multiple first edit distances. Please refer to Figure 4 , an example schematic diagram of obtaining an edit distance is provided for an embodiment of the present application. The text acquisition device can use an audio recognition system A to obtain a recognized text A corresponding to the target audio. If the audio recognition system A is a first audio recognition system, the recognized text A is the recognized text A corresponding to the first audio recognition system. In addition to the recognized text A, the text set also includes recognized text B, recognized text C, ..., recognized text N, etc., and the recognized text B, recognized text C, ..., recognized text N are the second recognized texts in the text set. The text acquisition device can calculate the edit distance between the recognized text A and other recognized texts in the text set, such as the edit distance AB between the recognized text A and the recognized text B, the edit distance AC between the recognized text A and the recognized text C, the edit distance AN between the recognized text A and the recognized text N, etc. The edit distance AB, the edit distance AC, ..., and the edit distance AN are the first edit distances corresponding to the first audio recognition system.

[0036] S203: Determine the sum of the edit distances corresponding to each audio recognition system based on the multiple edit distances.

[0037] Specifically, the text acquisition device may determine the sum of the edit distances corresponding to each audio recognition system based on multiple edit distances.

[0038] Optionally, the text acquisition device may add up all the first edit distances to obtain the sum of the edit distances corresponding to the first audio recognition system.

[0039] S204: Determine a target audio recognition system in the audio recognition system set based on the sum of the edit distances corresponding to the audio recognition systems.

[0040] Specifically, the edit distance reflects the difference between recognized texts. The smaller the edit distance, the more similar the two recognized texts are, and the higher the accuracy of the recognized texts is. The text acquisition device can determine the target audio recognition system in the audio recognition system set based on the sum of the edit distances corresponding to each audio recognition system. It can be understood that when performing text recognition on the target audio, the target audio recognition system is the audio recognition system with the highest accuracy in the audio recognition system set.

[0041] Optionally, the smaller the sum of edit distances, the higher the accuracy of the audio recognition system. The text acquisition device can determine the minimum sum of edit distances from the sums of edit distances corresponding to each audio recognition system, and determine the second audio recognition system corresponding to the minimum sum of edit distances in the audio recognition system as the target audio recognition system.

[0042] S205: Determine the target recognition text corresponding to the target audio recognition system in the recognition text set as the output text of the target audio.

[0043] Specifically, the text acquisition device can determine the target recognition text corresponding to the target audio recognition system in the recognition text set as the output text of the target audio, and the text acquisition device can display the output text on the terminal device.

[0044] In an embodiment of the present application, a set of recognized texts obtained by recognizing a target audio is obtained, the recognized text set includes multiple recognized texts obtained by each audio recognition system in an audio recognition system set respectively recognizing the target audio, the audio recognition system set includes at least three audio recognition systems, the audio recognition systems in the audio recognition system set correspond one to one to the recognized texts in the recognized text set, the edit distance between two recognized texts is respectively obtained in the recognized text set, the sum of the edit distances corresponding to each audio recognition system is respectively determined based on the multiple edit distances, the audio recognition system with the smallest sum of edit distances is determined as the target audio recognition system, and the target recognized text corresponding to the target audio recognition system is determined as the output text of the target audio in the recognized text set. The target recognized text is determined by calculating the edit distances between different recognized texts, thereby improving the accuracy of text acquisition.

[0045] See also Figure 5 , which is a flowchart of a text acquisition method provided in an embodiment of the present application. Figure 5 As shown, the method of the embodiment of the present application may include the following steps S301-S306.

[0046] S301, obtaining a recognition text set obtained by recognizing the target audio.

[0047] Specifically, the text acquisition device can use each audio recognition system in the audio recognition system set to recognize the target audio respectively, thereby obtaining multiple recognized texts and saving them in the recognized text set. It can be understood that the audio recognition systems in the audio recognition system set correspond one-to-one to the recognized texts in the recognized text set, and one audio recognition system corresponds to one recognized text.

[0048] S302: Obtain a first recognized text corresponding to the first audio recognition system in the recognized text set, and respectively obtain a first edit distance between the first recognized text and a second recognized text in the recognized text set.

[0049] Specifically, the text acquisition device can obtain the edit distance between two recognized texts in the text set respectively, thereby obtaining multiple edit distances. For example, if there are three recognized texts in the text set, the text acquisition device can obtain four edit distances. The text acquisition device can obtain the first recognized text corresponding to the first audio recognition system in the recognized text set. The first audio recognition system can be any audio recognition system in the audio recognition system set. The first recognized text is the recognized text obtained after the first audio recognition system recognizes the target audio. The text acquisition device can respectively obtain the first edit distance between the first recognized text and the second recognized text in the recognized text set. The second recognized text is the other recognized text in the recognized text set except the first recognized text. It can be understood that there can be multiple second recognized texts and multiple first edit distances.

[0050] S303: Determine the first audio recognition system as a candidate audio recognition system based on a preset threshold and a plurality of first edit distances.

[0051] Specifically, the text acquisition device may determine the first audio recognition system as a candidate audio recognition system based on a preset threshold and a plurality of first edit distances of the first audio recognition system. The preset threshold is used to determine the text recognition accuracy of the first audio recognition system and whether the first audio recognition system can be determined as a candidate audio recognition system.

[0052] Optionally, the edit distance reflects the difference between the recognized texts. The smaller the edit distance, the more similar the two recognized texts are, and the higher the accuracy of the recognized texts is. The preset threshold may be a distance threshold. When multiple first edit distances of the first audio recognition system are less than or equal to the distance threshold, the first audio recognition system is determined to be a candidate audio recognition system, wherein the distance threshold may be an initial setting of the text acquisition device, or may be set by a user or relevant staff. For example, the text acquisition device can use audio recognition system A to obtain recognized text A corresponding to the target audio. If audio recognition system A is the first audio recognition system, then the recognized text A is the recognized text A corresponding to the first audio recognition system. If there are three audio recognition systems in the audio recognition system set, namely audio recognition system A, audio recognition system B and audio recognition system C, and the corresponding recognized texts are recognized text A, recognized text B and recognized text C, respectively, the text acquisition device can calculate the first edit distance of the first audio recognition system as the edit distance AB between recognized text A and recognized text B, and the edit distance AC between recognized text A and recognized text C. Therefore, only when the edit distance AB and the edit distance AC are both less than or equal to the distance threshold, the audio recognition system A can be determined as a candidate audio recognition system. On the contrary, if the edit distance AB is greater than the distance threshold, the edit distance AC is greater than the distance threshold, or the edit distance AB and the edit distance AC are both greater than the distance threshold, it means that the audio recognition system A has low recognition accuracy for the target audio, and the audio recognition system A cannot be confirmed as a candidate audio recognition system.

[0053] Optionally, since the edit distance usually increases with the increase of the length of the recognized text, if the distance threshold is still used to determine the candidate audio recognition system when the recognized text is long, the accuracy of the candidate audio recognition system will be reduced. When the length of the recognized text is greater than the length threshold, the preset threshold can be a ratio threshold, that is, the ratio threshold is used to determine the audio recognition system. The text acquisition device can normalize all edit distances, obtain the average text length of multiple recognized texts in the recognized text set, calculate the ratio of the first edit distance and the average text length, and obtain multiple length ratios corresponding to the first audio recognition system. When all the length ratios of the first audio recognition system are less than or equal to the ratio threshold, the text acquisition device can determine that the first audio recognition system is a candidate audio recognition system. The ratio threshold can be an initial setting of the text acquisition device, and can also be set by the user or relevant staff.

[0054] S304: Determine a sum of edit distances corresponding to the candidate audio recognition systems based on the multiple first edit distances.

[0055] Specifically, the text acquisition device may add the first edit distances corresponding to the candidate audio recognition systems to obtain the sum of the edit distances corresponding to the candidate audio recognition systems.

[0056] S305: Determine a target audio recognition system from the candidate audio recognition systems based on the sum of the edit distances corresponding to the candidate audio recognition systems.

[0057] Specifically, the text acquisition device can determine the target audio recognition system among all candidate audio recognition systems based on the sum of the edit distances corresponding to the candidate audio recognition systems. It can be understood that when performing text recognition on the target audio, the target audio recognition system is the audio recognition system with the highest accuracy in the audio recognition system set.

[0058] Optionally, when there are at least two candidate audio recognition systems, the text acquisition device may determine the minimum sum of edit distances among the sums of edit distances corresponding to the candidate audio recognition systems, and determine the third audio recognition system corresponding to the minimum sum of edit distances in the audio recognition system set as the target audio recognition system; when there are at least two third audio recognition systems, that is, when there are two or more audio recognition systems with the minimum sum of edit distances, the text acquisition device may randomly determine a third audio recognition system as the target audio recognition system.

[0059] When there is no candidate audio recognition system, that is, the first edit distances of all audio recognition systems are greater than the length threshold, or the length ratios of all audio recognition systems are greater than the ratio threshold, it means that the accuracy of the recognized texts recognized by all audio recognition systems is not high, and the text acquisition device can discard the target audio and not recognize the target audio.

[0060] It is understandable that when there is no candidate audio recognition system, the text acquisition device can send the target audio to the terminal device of the staff, and the staff can manually annotate the target audio.

[0061] S306: Determine the target recognition text corresponding to the target audio recognition system in the recognition text set as the output text of the target audio.

[0062] Specifically, the text acquisition device can determine the target recognition text corresponding to the target audio recognition system in the recognition text set as the output text of the target audio, and the text acquisition device can display the output text on the terminal device.

[0063] In an embodiment of the present application, a set of recognized texts obtained by recognizing the target audio is obtained, and the recognized text set includes multiple recognized texts obtained by each audio recognition system in the audio recognition system set respectively recognizing the target audio, and the audio recognition system set includes at least three audio recognition systems. The audio recognition systems in the audio recognition system set correspond to the recognized texts in the recognized text set one by one. The first recognized text corresponding to the first audio recognition system and the first edit distance are obtained in the recognized text set. The first audio recognition system is determined as a candidate audio recognition system based on a preset threshold and multiple first edit distances. The preset threshold can be a distance threshold. When the length of the recognized text is too long, the preset threshold can be a ratio threshold. The preset threshold is used to screen the audio recognition system, which further improves the accuracy of text acquisition. Based on multiple first edit distances, the sum of the edit distances corresponding to each candidate audio recognition system is determined respectively, and the candidate audio recognition system with the smallest sum of edit distances is determined as the target audio recognition system. In the recognized text set, the target recognized text corresponding to the target audio recognition system is determined as the output text of the target audio. The target recognized text is determined by calculating the edit distances between different recognized texts, which improves the accuracy of text acquisition.

[0064] The following will be combined with the attached Figure 6 -Attached Figure 7 , the text acquisition device provided in the embodiment of the present application is introduced in detail. It should be noted that the attached Figure 6 -Attached Figure 7 The text acquisition device in the present application is used to execute Figure 2-Figure 5 For the convenience of explanation, only the part related to the embodiment of the present application is shown. For the specific technical details not disclosed, please refer to the present application. Figure 2-Figure 5 The embodiment shown.

[0065] See also Figure 6 , which shows a schematic diagram of the structure of a text acquisition device provided by an exemplary embodiment of the present application. The text acquisition device can be implemented as all or part of the device through software, hardware or a combination of both. The device 1 includes a text collection acquisition module 11, a target system determination module 12 and an output text determination module 13.

[0066] A text set acquisition module 11 is used to acquire a recognition text set obtained by recognizing a target audio, wherein the recognition text set includes a plurality of recognition texts obtained by each audio recognition system in an audio recognition system set respectively recognizing the target audio, wherein the audio recognition system set includes at least three audio recognition systems, and the audio recognition systems in the audio recognition system set correspond one to one to the recognition texts in the recognition text set;

[0067] A target system determination module 12, configured to obtain the edit distance between two recognized texts in the recognized text set, and determine a target audio recognition system in the audio recognition system set based on a plurality of the edit distances;

[0068] For details, please refer to Figure 7 , which is a schematic diagram of the structure of a target system determination module provided in an embodiment of the present application. Figure 7 As shown, the target system determination module 12 may include:

[0069] An edit distance obtaining unit 121, used to obtain the edit distance between two recognized texts in the recognized text set;

[0070] Optionally, the edit distance acquisition unit 121 is specifically used to acquire a first recognition text corresponding to a first audio recognition system in the recognition text set, where the first audio recognition system is any audio recognition system in the audio recognition system set;

[0071] A first edit distance between the first recognized text and a second recognized text in the recognized text set is obtained respectively, where the second recognized text is other recognized text in the recognized text set except the first recognized text.

[0072] A distance sum obtaining unit 122, configured to determine the sum of edit distances corresponding to each of the audio recognition systems based on the plurality of edit distances;

[0073] Optionally, the distance sum acquisition unit 122 may include:

[0074] a candidate system determination subunit 124, configured to determine the first audio recognition system as a candidate audio recognition system based on a preset threshold and a plurality of the first edit distances;

[0075] Optionally, the candidate system determination subunit 124 is specifically used to obtain an average text length of the plurality of recognized texts in the recognized text set;

[0076] Based on the average text length and the first edit distances, obtaining a plurality of length ratios corresponding to the first audio recognition system;

[0077] When the plurality of length ratios are all less than or equal to a ratio threshold, the first audio recognition system is determined to be a candidate audio recognition system.

[0078] Optionally, the candidate system determining subunit 124 is specifically configured to determine the first audio recognition system as a candidate audio recognition system when a plurality of the first edit distances are all less than or equal to a distance threshold.

[0079] a distance sum obtaining subunit 125, configured to determine a sum of edit distances corresponding to the candidate audio recognition systems based on the plurality of first edit distances;

[0080] A target system determining unit 123, configured to determine a target audio recognition system in the audio recognition system set based on the sum of the edit distances corresponding to the audio recognition systems;

[0081] Optionally, the target system determination unit 123 is specifically configured to determine a target audio recognition system among the candidate audio recognition systems based on the sum of edit distances corresponding to the candidate audio recognition systems.

[0082] Optionally, the target system determination unit 123 is specifically configured to, when there are at least two candidate audio recognition systems, determine a minimum edit distance sum among the edit distance sums corresponding to the candidate audio recognition systems, and determine a third audio recognition system corresponding to the minimum edit distance sum in the audio recognition system set as the target audio recognition system;

[0083] When the candidate audio recognition system does not exist, the target audio is discarded.

[0084] Optionally, the target system determination unit 123 is specifically configured to determine a minimum edit distance sum among the edit distance sums corresponding to the audio recognition systems, and determine a second audio recognition system corresponding to the minimum edit distance sum in the audio recognition system set as a target audio recognition system.

[0085] The output text determination module 13 is used to determine the target recognition text corresponding to the target audio recognition system in the recognition text set as the output text of the target audio.

[0086] In an embodiment of the present application, a set of recognized texts obtained by recognizing the target audio is obtained, and the recognized text set includes multiple recognized texts obtained by each audio recognition system in the audio recognition system set respectively recognizing the target audio, and the audio recognition system set includes at least three audio recognition systems. The audio recognition systems in the audio recognition system set correspond to the recognized texts in the recognized text set one by one. The first recognized text corresponding to the first audio recognition system and the first edit distance are obtained in the recognized text set. The first audio recognition system is determined as a candidate audio recognition system based on a preset threshold and multiple first edit distances. The preset threshold can be a distance threshold. When the length of the recognized text is too long, the preset threshold can be a ratio threshold. The preset threshold is used to screen the audio recognition system, which further improves the accuracy of text acquisition. Based on multiple first edit distances, the sum of the edit distances corresponding to each candidate audio recognition system is determined respectively, and the candidate audio recognition system with the smallest sum of edit distances is determined as the target audio recognition system. In the recognized text set, the target recognized text corresponding to the target audio recognition system is determined as the output text of the target audio. The target recognized text is determined by calculating the edit distances between different recognized texts, which improves the accuracy of text acquisition.

[0087] It should be noted that the text acquisition device provided in the above embodiment only uses the division of the above functional modules as an example when executing the text acquisition method. In actual applications, the above functions can be assigned to different functional modules as needed, that is, the internal structure of the device is divided into different functional modules to complete all or part of the functions described above. In addition, the text acquisition device provided in the above embodiment and the text acquisition method embodiment belong to the same concept, and the implementation process thereof is detailed in the method embodiment, which will not be repeated here.

[0088] The serial numbers of the above-mentioned embodiments of the present application are for description only and do not represent the advantages or disadvantages of the embodiments.

[0089] The present application also provides a computer storage medium, which can store multiple instructions, and the instructions are suitable for being loaded and executed by a processor as described above. Figure 1-Figure 5 The text acquisition method of the embodiment shown in the figure can be specifically executed by referring to Figure 1-Figure 5 The specific description of the illustrated embodiment will not be repeated here.

[0090] The present application also provides a computer program product, which stores at least one instruction, and the at least one instruction is loaded and executed by the processor as described above. Figure 1-Figure 5 The text acquisition method of the embodiment shown in the figure can be specifically executed by referring to Figure 1-Figure 5 The specific description of the illustrated embodiment will not be repeated here.

[0091] Please refer to Figure 8 , which shows a block diagram of the structure of an electronic device provided by an exemplary embodiment of the present application. The electronic device in the present application may include one or more of the following components: a processor 110, a memory 120, an input device 130, an output device 140, and a bus 150. The processor 110, the memory 120, the input device 130, and the output device 140 may be connected via the bus 150.

[0092] The processor 110 may include one or more processing cores. The processor 110 uses various interfaces and lines to connect various parts of the entire electronic device, and executes various functions and processes data of the terminal 100 by running or executing instructions, programs, code sets or instruction sets stored in the memory 120, and calling data stored in the memory 120. Optionally, the processor 110 can be implemented in at least one hardware form of digital signal processing (DSP), field-programmable gate array (FPGA), and programmable logic array (PLA). The processor 110 can integrate one or a combination of a central processing unit (CPU), a graphics processing unit (GPU), and a modem. Among them, the CPU mainly processes the operating system, user pages, and applications; the GPU is responsible for rendering and drawing display content; and the modem is used to process wireless communications. It can be understood that the above-mentioned modem may not be integrated into the processor 110, but may be implemented separately through a communication chip.

[0093] The memory 120 may include a random access memory (RAM) or a read-only memory (ROM). Optionally, the memory 120 includes a non-transitory computer-readable medium (Non-Transitory Computer-Readable Storage Medium). The memory 120 may be used to store instructions, programs, codes, code sets or instruction sets. The memory 120 may include a program storage area and a data storage area, wherein the program storage area may store instructions for implementing an operating system, instructions for implementing at least one function (such as a touch function, a sound playback function, an image playback function, etc.), instructions for implementing the above-mentioned various method embodiments, etc. The operating system may be an Android system, including a system deeply developed based on the Android system, an IOS system developed by Apple, including a system deeply developed based on the IOS system or other systems.

[0094] The memory 120 can be divided into an operating system space and a user space. The operating system runs in the operating system space, and native and third-party applications run in the user space. In order to ensure that different third-party applications can achieve good operating results, the operating system allocates corresponding system resources to different third-party applications. However, the requirements for system resources in different application scenarios in the same third-party application are also different. For example, in the local resource loading scenario, the third-party application has higher requirements for disk reading speed; in the animation rendering scenario, the third-party application has higher requirements for GPU performance. The operating system and third-party applications are independent of each other, and the operating system often cannot perceive the current application scenario of the third-party application in a timely manner, resulting in the operating system being unable to perform targeted system resource adaptation according to the specific application scenario of the third-party application.

[0095] In order for the operating system to distinguish the specific application scenarios of third-party applications, it is necessary to open up data communication between third-party applications and the operating system so that the operating system can obtain the current scenario information of third-party applications at any time, and then perform targeted system resource adaptation based on the current scenario.

[0096] The input device 130 is used to receive input commands or data, and includes but is not limited to a keyboard, a mouse, a camera, a microphone, or a touch device. The output device 140 is used to output commands or data, and includes but is not limited to a display device and a speaker. In one example, the input device 130 and the output device 140 can be combined, and the input device 130 and the output device 140 are touch screen displays.

[0097] The touch display screen can be designed as a full screen, a curved screen or a special-shaped screen. The touch display screen can also be designed as a combination of a full screen and a curved screen, or a combination of a special-shaped screen and a curved screen, which is not limited in the embodiments of the present application.

[0098] In addition, those skilled in the art will appreciate that the structure of the electronic device shown in the above drawings does not constitute a limitation on the electronic device, and the electronic device may include more or fewer components than shown, or combine certain components, or arrange the components differently. For example, the electronic device also includes a radio frequency circuit, an input unit, a sensor, an audio circuit, a wireless fidelity (WiFi) module, a power supply, a Bluetooth module and other components, which will not be described in detail here.

[0099] exist Figure 8 In the electronic device shown, the processor 110 may be used to call a text acquisition application stored in the memory 120, and specifically perform the following operations:

[0100] Acquire a recognition text set obtained by recognizing the target audio, the recognition text set comprising a plurality of recognition texts obtained by each audio recognition system in the audio recognition system set respectively recognizing the target audio, the audio recognition system set comprising at least three audio recognition systems, and the audio recognition systems in the audio recognition system set corresponding one to one to the recognition texts in the recognition text set;

[0101] Obtaining respectively the edit distance between two recognized texts in the recognized text set, and determining a target audio recognition system in the audio recognition system set based on a plurality of the edit distances;

[0102] The target recognition text corresponding to the target audio recognition system is determined in the recognition text set as the output text of the target audio.

[0103] In one embodiment, when the processor 110 obtains the edit distances between two recognized texts in the recognized text set respectively and determines the target audio recognition system in the audio recognition system set based on the multiple edit distances, the processor 110 specifically performs the following operations:

[0104] Obtaining the edit distance between two recognized texts in the recognized text set respectively;

[0105] Determine the sum of the edit distances corresponding to each of the audio recognition systems based on the multiple edit distances;

[0106] Based on the sum of the edit distances corresponding to the audio recognition systems, a target audio recognition system is determined in the audio recognition system set.

[0107] In one embodiment, when the processor 110 obtains the edit distance between two recognized texts in the recognized text set, the processor 110 specifically performs the following operations:

[0108] Acquire a first recognition text corresponding to a first audio recognition system in the recognition text set, where the first audio recognition system is any audio recognition system in the audio recognition system set;

[0109] A first edit distance between the first recognized text and a second recognized text in the recognized text set is obtained respectively, where the second recognized text is other recognized text in the recognized text set except the first recognized text.

[0110] In one embodiment, when determining the target audio recognition system in the audio recognition system set based on the sum of the edit distances corresponding to the audio recognition systems, the processor 110 specifically performs the following operations:

[0111] A minimum edit distance sum is determined among the edit distance sums corresponding to the audio recognition systems, and a second audio recognition system corresponding to the minimum edit distance sum is determined as a target audio recognition system in the audio recognition system set.

[0112] In one embodiment, when the processor 110 determines the sum of the edit distances corresponding to each audio recognition system based on the multiple edit distances, the processor 110 specifically performs the following operations:

[0113] determining the first audio recognition system as a candidate audio recognition system based on a preset threshold and a plurality of the first edit distances;

[0114] Determine a sum of edit distances corresponding to the candidate audio recognition systems based on the plurality of first edit distances;

[0115] When determining the target audio recognition system in the audio recognition system set based on the sum of the edit distances corresponding to the audio recognition systems, the following operations are specifically performed:

[0116] Based on the sum of the edit distances corresponding to the candidate audio recognition systems, a target audio recognition system is determined among the candidate audio recognition systems.

[0117] In one embodiment, when the processor 110 determines the first audio recognition system as a candidate audio recognition system based on a preset threshold and a plurality of the first edit distances, the processor 110 specifically performs the following operations:

[0118] When the plurality of first edit distances are all smaller than or equal to a distance threshold, the first audio recognition system is determined to be a candidate audio recognition system.

[0119] In one embodiment, when the processor 110 determines the first audio recognition system as a candidate audio recognition system based on a preset threshold and a plurality of the first edit distances, the processor 110 specifically performs the following operations:

[0120] Obtaining an average text length of the plurality of recognized texts in the recognized text set;

[0121] Based on the average text length and the first edit distances, obtaining a plurality of length ratios corresponding to the first audio recognition system;

[0122] When the plurality of length ratios are all less than or equal to a ratio threshold, the first audio recognition system is determined to be a candidate audio recognition system.

[0123] In one embodiment, when determining the target audio recognition system among the candidate audio recognition systems based on the sum of the edit distances corresponding to the candidate audio recognition systems, the processor 110 specifically performs the following operations:

[0124] When there are at least two candidate audio recognition systems, determining a minimum edit distance sum among the edit distance sums corresponding to the candidate audio recognition systems, and determining a third audio recognition system corresponding to the minimum edit distance sum in the audio recognition system set as a target audio recognition system;

[0125] When the candidate audio recognition system does not exist, the target audio is discarded.

[0126] In an embodiment of the present application, a set of recognized texts obtained by recognizing the target audio is obtained, and the recognized text set includes multiple recognized texts obtained by each audio recognition system in the audio recognition system set respectively recognizing the target audio, and the audio recognition system set includes at least three audio recognition systems. The audio recognition systems in the audio recognition system set correspond to the recognized texts in the recognized text set one by one. The first recognized text corresponding to the first audio recognition system and the first edit distance are obtained in the recognized text set. The first audio recognition system is determined as a candidate audio recognition system based on a preset threshold and multiple first edit distances. The preset threshold can be a distance threshold. When the length of the recognized text is too long, the preset threshold can be a ratio threshold. The preset threshold is used to screen the audio recognition system, which further improves the accuracy of text acquisition. Based on multiple first edit distances, the sum of the edit distances corresponding to each candidate audio recognition system is determined respectively, and the candidate audio recognition system with the smallest sum of edit distances is determined as the target audio recognition system. In the recognized text set, the target recognized text corresponding to the target audio recognition system is determined as the output text of the target audio. The target recognized text is determined by calculating the edit distances between different recognized texts, which improves the accuracy of text acquisition.

[0127] A person skilled in the art can understand that all or part of the processes in the above-mentioned embodiments can be implemented by instructing the relevant hardware through a computer program, and the program can be stored in a computer-readable storage medium, and when the program is executed, it can include the processes of the embodiments of the above-mentioned methods. The storage medium can be a disk, an optical disk, a read-only memory (ROM) or a random access memory (RAM), etc.

[0128] The above disclosure is only the preferred embodiment of the present application, which certainly cannot be used to limit the scope of rights of the present application. Therefore, equivalent changes made according to the claims of the present application are still within the scope covered by the present application.

Claims

1. A text acquisition method, characterized in that: include: Acquire a recognition text set obtained by recognizing the target audio, the recognition text set comprising a plurality of recognition texts obtained by each audio recognition system in the audio recognition system set respectively recognizing the target audio, the audio recognition system set comprising at least three audio recognition systems, and the audio recognition systems in the audio recognition system set corresponding one to one to the recognition texts in the recognition text set; Obtaining respectively the edit distance between two recognized texts in the recognized text set, and determining a target audio recognition system in the audio recognition system set based on a plurality of the edit distances; The target recognition text corresponding to the target audio recognition system is determined in the recognition text set as the output text of the target audio.

2. The method according to claim 1, characterized in that The step of respectively obtaining the edit distance between two recognized texts in the recognized text set, and determining a target audio recognition system in the audio recognition system set based on a plurality of the edit distances, comprises: Obtaining the edit distance between two recognized texts in the recognized text set respectively; Determine the sum of the edit distances corresponding to each of the audio recognition systems based on the multiple edit distances; Based on the sum of the edit distances corresponding to the audio recognition systems, a target audio recognition system is determined in the audio recognition system set.

3. The method according to claim 2, characterized in that The obtaining the edit distance between two recognized texts in the recognized text set respectively includes: Acquire a first recognition text corresponding to a first audio recognition system in the recognition text set, where the first audio recognition system is any audio recognition system in the audio recognition system set; A first edit distance between the first recognized text and a second recognized text in the recognized text set is obtained respectively, where the second recognized text is other recognized text in the recognized text set except the first recognized text.

4. The method according to claim 3, characterized in that: The determining a target audio recognition system in the audio recognition system set based on the sum of the edit distances corresponding to the audio recognition systems includes: A minimum edit distance sum is determined among the edit distance sums corresponding to the audio recognition systems, and a second audio recognition system corresponding to the minimum edit distance sum is determined as a target audio recognition system in the audio recognition system set.

5. The method according to claim 3, characterized in that: The determining the sum of the edit distances corresponding to the audio recognition systems based on the plurality of edit distances respectively includes: determining the first audio recognition system as a candidate audio recognition system based on a preset threshold and a plurality of the first edit distances; Determine a sum of edit distances corresponding to the candidate audio recognition systems based on the plurality of first edit distances; The determining a target audio recognition system in the audio recognition system set based on the sum of the edit distances corresponding to the audio recognition systems includes: Based on the sum of the edit distances corresponding to the candidate audio recognition systems, a target audio recognition system is determined among the candidate audio recognition systems.

6. The method according to claim 5, characterized in that The step of determining the first audio recognition system as a candidate audio recognition system based on a preset threshold and a plurality of the first edit distances includes: When the plurality of first edit distances are all smaller than or equal to a distance threshold, the first audio recognition system is determined to be a candidate audio recognition system.

7. The method according to claim 5, characterized in that The step of determining the first audio recognition system as a candidate audio recognition system based on a preset threshold and a plurality of the first edit distances includes: Obtaining an average text length of the plurality of recognized texts in the recognized text set; Based on the average text length and the first edit distances, obtaining a plurality of length ratios corresponding to the first audio recognition system; When the plurality of length ratios are all less than or equal to a ratio threshold, the first audio recognition system is determined to be a candidate audio recognition system.

8. The method according to claim 5, characterized in that The determining of a target audio recognition system among the candidate audio recognition systems based on the sum of the edit distances corresponding to the candidate audio recognition systems comprises: When there are at least two candidate audio recognition systems, determining a minimum edit distance sum among the edit distance sums corresponding to the candidate audio recognition systems, and determining a third audio recognition system corresponding to the minimum edit distance sum in the audio recognition system set as a target audio recognition system; When the candidate audio recognition system does not exist, the target audio is discarded.

9. A text acquisition device, characterized in that: include: A text set acquisition module, used to acquire a recognition text set obtained by recognizing a target audio, wherein the recognition text set includes a plurality of recognition texts obtained by each audio recognition system in an audio recognition system set recognizing the target audio, wherein the audio recognition system set includes at least three audio recognition systems, and the audio recognition systems in the audio recognition system set correspond one-to-one to the recognition texts in the recognition text set; A target system determination module, configured to obtain the edit distance between two recognized texts in the recognized text set, and determine a target audio recognition system in the audio recognition system set based on a plurality of the edit distances; The output text determination module is used to determine the target recognition text corresponding to the target audio recognition system in the recognition text set as the output text of the target audio.

10. A computer storage medium, characterized in that: The computer storage medium stores a plurality of instructions, and the instructions are suitable for being loaded by a processor and executing the steps of the method according to any one of claims 1 to 8.

11. An electronic device, characterized in that: include: Processor and memory; The memory stores a computer program, and the computer program is suitable for being loaded by the processor and executing the steps of the method according to any one of claims 1 to 8.

Citation Information

Patent Citations

  • Control method of speech recognition system, control device of speech recognition system and computer readable storage medium

    CN108461084A

  • Speech translation method, device and equipment and translation machine

    CN112309370A