Voice real-time recognition method, electronic equipment and storage medium

By introducing multi-level time queues and dynamic error correction algorithms in speech recognition technology, the problem of low latency and high accuracy cannot be met in real-time interactive applications in the prior art, and the efficient, accurate and suitable speech recognition effect for complex scenarios is achieved.

CN119920255APending Publication Date: 2025-05-02BEIJING TONGXIANG QIANFANG TECHNOLOGY CO LTD
View PDF 13 Cites 0 Cited by

Patent Information

Application Number
CN202510081290.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-01-17
Publication Date
2025-05-02

AI Technical Summary

Technical Problem

Existing voice recognition technologies cannot meet the requirements of low latency and high accuracy in real-time interactive applications, especially in medical scenarios.

Method used

By introducing multi-level time queues (3 seconds, 9 seconds, 24 seconds) for layered recognition, combining dynamic error correction and context optimization algorithms, real-time and accurate speech recognition is achieved.

Benefits of technology

It improves the accuracy and semantic coherence of speech recognition, achieves a balance between real-time and accuracy, and is suitable for speech recognition requirements in complex scenarios.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119920255A_ABST
    Figure CN119920255A_ABST
Patent Text Reader

Abstract

The invention discloses a voice real-time recognition method, electronic equipment and a storage medium, and belongs to the technical field of voice processing, and the method comprises the steps: obtaining a real-time original audio data stream from voice collection equipment; the preprocessing module performs primary processing on the original audio data stream to obtain three to-be-processed audio data streams; performing multi-level real-time identification on the three to-be-processed audio data streams by using a voice model to obtain an identification result; obtaining a target text based on the recognition result; and displaying the target text to a user through an output module. According to the method, a layered recognition processing mechanism is adopted, and a dynamic error correction algorithm and a real-time interaction function are combined, so that a real-time and accurate recognition result is obtained, and the voice recognition requirement in a complex scene can be met.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application belongs to the field of speech processing technology, and in particular relates to a real-time speech recognition method, an electronic device and a storage medium. Background Art

[0002] Automatic Speech Recognition (ASR) technology has been widely used in smart assistants, conference records, subtitle generation and other fields. Existing speech recognition systems usually rely on deep learning models, such as Transformer, LSTM or CNN-LSTM, to extract and recognize audio signals. While achieving basic functions, these systems still face some key technical challenges, including real-time performance, accuracy and context processing.

[0003] Most existing speech recognition technologies use a sliding time window mechanism to process continuous audio streams, segmenting the audio signal and inputting it into the model piece by piece to generate real-time text results. In addition, in real-time interactive applications, such as medical scenarios, doctors not only require low latency for speech-to-text conversion, but also have high requirements for transcription accuracy. The current sliding time window recognition method cannot meet the higher requirements of real-time and accuracy. Summary of the invention

[0004] In order to solve the deficiencies of the prior art, the present application provides a real-time speech recognition method, an electronic device and a storage medium, which can solve the technical problem that the sliding time window recognition method for speech in the prior art cannot meet the higher requirements of real-time and accuracy.

[0005] The technical effects to be achieved by this application are achieved through the following solutions:

[0006] In a first aspect, the present application provides a real-time speech recognition method, comprising:

[0007] Get real-time raw audio data stream from the voice acquisition device;

[0008] The preprocessing module performs preliminary processing on the original audio data stream to obtain three audio data streams to be processed;

[0009] Using the speech model to perform multi-level real-time recognition on the three audio data streams to be processed to obtain recognition results;

[0010] Obtaining a target text based on the recognition result;

[0011] The target text is displayed to the user through an output module.

[0012] In some embodiments, the preprocessing module performs preliminary processing on the original audio data stream to obtain three audio data streams to be processed, including:

[0013] The original audio data stream is copied into three copies, each of which is used as a to-be-processed audio data stream, and there are three to-be-processed audio data streams in total.

[0014] In some embodiments, the three audio data streams to be processed are respectively a first data stream to be processed, a second data stream to be processed and a third data stream to be processed, wherein the first data stream to be processed includes an audio queue of a first duration, the second data stream to be processed includes an audio queue of a second duration, and the third data stream to be processed includes an audio queue of a third duration; wherein the first duration is smaller than the second duration, and the second duration is smaller than the third duration.

[0015] In some embodiments, the method of performing multi-level real-time recognition on the three audio data streams to be processed using a speech model to obtain a recognition result includes:

[0016] Using a speech model to perform real-time recognition on the first duration audio queue to obtain a first recognition result;

[0017] Using the speech model to perform real-time recognition on the second duration audio queue to obtain a second recognition result;

[0018] The speech model is used to perform real-time recognition on the first duration audio queue to obtain a third recognition result.

[0019] In some embodiments, obtaining the target text based on the recognition result includes:

[0020] Using the second recognition result to adjust the first recognition result, correct the erroneous content in the first recognition result, and obtain a preliminary text;

[0021] The preliminary text is screened and deduplicated using the third recognition result to obtain a target text.

[0022] In some embodiments, the first duration is 3 seconds, the second duration is 9 seconds, and the third duration is 24 seconds; or,

[0023] The first duration, the second duration and the third duration are adjusted dynamically.

[0024] In some embodiments, the voice collection device includes any one of a microphone, a voice recorder, a USB microphone and a smart phone.

[0025] In some embodiments, the speech model includes Whisper or XTTS-v2.

[0026] In a second aspect, the present application provides an electronic device, comprising: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements any of the aforementioned methods when executing the computer program.

[0027] In a third aspect, the present application provides a computer-readable storage medium, wherein the computer-readable storage medium stores one or more programs, and the one or more programs can be executed by one or more processors to implement any of the aforementioned methods.

[0028] Through the real-time speech recognition method, electronic device and storage medium provided in this application, combined with the processing mechanism of layered recognition, combined with the dynamic error correction algorithm and real-time interactive function, real-time and accurate recognition results can be obtained, which can meet the speech recognition needs in complex scenarios. BRIEF DESCRIPTION OF THE DRAWINGS

[0029] In order to more clearly illustrate the embodiments of the present application or the existing technical solutions, 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 recorded in the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.

[0030] Figure 1 A flowchart of a real-time speech recognition method in an embodiment of the present application;

[0031] Figure 2 A schematic diagram of the relationship between voice queues in a real-time voice recognition method in an embodiment of the present application;

[0032] Figure 3 This is a schematic diagram of a specific implementation of a real-time speech recognition method in an embodiment of the present application;

[0033] Figure 4 It is a schematic block diagram of an electronic device in an embodiment of the present application. DETAILED DESCRIPTION

[0034] In order to make the purpose, technical solution and advantages of the present application clearer, the technical solution of the present application will be clearly and completely described below in conjunction with specific embodiments and corresponding drawings. 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 the field without creative work are within the scope of protection of the present application.

[0035] It should be noted that, unless otherwise defined, the technical terms or scientific terms used in one or more embodiments of the present application should be understood by people with ordinary skills in the field to which the present application belongs. The "first", "second" and similar words used in one or more embodiments of the present application do not indicate any order, quantity or importance, but are only used to distinguish different components. "Include" or "comprise" and similar words mean that the elements or objects appearing before the word cover the elements or objects listed after the word and their equivalents, without excluding other elements or objects. "Connect" or "connected" and similar words are not limited to physical or mechanical connections, but may include electrical connections, whether direct or indirect. "Up", "down", "left", "right" and the like are only used to indicate relative positional relationships. When the absolute position of the described object changes, the relative positional relationship may also change accordingly.

[0036] In the related art, a fixed time window is used as the single-step recognition interval of speech, and the audio stream is processed piece by piece through a sliding time window. A preliminary text result is generated in combination with a speech model, and then the text is secondary checked and corrected using an asynchronous correction algorithm, and finally a real-time high-quality text output is generated. The fixed time window recognition method has the following problems:

[0037] 1) Insufficient recognition accuracy.

[0038] Current technologies mainly rely on sliding a single fixed window to gradually recognize audio clips. However, the results of the recognition model in a short time window are easily affected by the lack of context, especially when it comes to speech content with long-term dependencies, the semantic information across windows cannot be fully utilized. Although an asynchronous correction algorithm has been introduced, it only corrects the recognition results based on a single window, lacks analysis of the correlation between texts across windows, and results in limited context consistency.

[0039] 2) The speech coherence of the recognition results is insufficient.

[0040] Related technologies process the gradually generated text independently, and lack the integration of context and logic between speech segments, resulting in poor performance of the generated text paragraphs in terms of semantic fluency and logical consistency.

[0041] In response to the above-mentioned deficiencies in the prior art, this application proposes a new algorithm for speech recognition. Specifically, it maintains multiple queues of different durations, performs independent analysis on each queue, and finally applies the analysis results to the final recognized text through calculation, thereby making up for the problems of insufficient accuracy and insufficient contextual coherence of the prior art.

[0042] The technical solution of this application aims to effectively solve the shortcomings of the existing technology in real-time, context processing, dynamic update and scene adaptability through a hierarchical queue processing mechanism, combined with dynamic error correction and context optimization algorithms and real-time interactive functions.

[0043] The overall idea of ​​this application is as follows:

[0044] 1) Hierarchical queue processing mechanism.

[0045] Introducing multi-level time queues (such as 3-second queues, 9-second queues, and 24-second queues), the three time queues can correspond to real-time processing, short-time period optimization, and long-time period in-depth analysis. Each queue runs independently, combined with precise time partitioning and the "remove overlap" algorithm, through segment calibration and cross-interval conflict resolution, to ensure the balance between real-time and accuracy of speech-to-text conversion.

[0046] 2) Dynamic error correction and context integration.

[0047] On the basis of real-time processing, the contextual relationship of the speech content is analyzed through a long-term queue (such as a 24-second queue) to dynamically adjust the previous recognition results. Through semantic conflict detection and overlapping interval optimization, the semantic coherence of the text is ensured, and redundant and inconsistent content is eliminated in the recognition results.

[0048] This application innovatively combines hierarchical processing, dynamic optimization and multi-speaker support to achieve an efficient, accurate speech-to-text method suitable for complex scenarios, effectively solving the shortcomings of the existing technology.

[0049] Various non-limiting implementations of the present application are described in detail below in conjunction with the accompanying drawings.

[0050] First, refer to Figure 1 , the real-time speech recognition method of this application is described in detail:

[0051] S100: obtaining a real-time raw audio data stream from a voice acquisition device;

[0052] S200: The preprocessing module performs preliminary processing on the original audio data stream to obtain three audio data streams to be processed;

[0053] S300: Perform multi-level real-time recognition on the three audio data streams to be processed using a speech model to obtain a recognition result;

[0054] S400: Obtaining a target text based on the recognition result;

[0055] S500: Displaying the target text to the user through an output module.

[0056] The real-time speech recognition method of the present application adopts a layered recognition processing mechanism, combined with a dynamic error correction algorithm and a real-time interactive function, to obtain real-time and accurate recognition results, which can meet the speech recognition needs in complex scenarios.

[0057] In some embodiments, the preprocessing module performs preliminary processing on the original audio data stream to obtain three audio data streams to be processed, including:

[0058] The original audio data stream is copied into three copies, each of which is used as a to-be-processed audio data stream, and there are three to-be-processed audio data streams in total.

[0059] Exemplarily, obtaining the original audio data stream includes:

[0060] The recognition system or electronic device receives a real-time raw audio data stream from a voice acquisition device (such as a microphone) as input. The raw audio data stream can be a continuous voice signal or a segmented audio data fragment. The raw audio data stream serves as the input of the preprocessing module.

[0061] Exemplarily, the input raw audio data stream is preliminarily processed by the preprocessing module to ensure that the subsequent model can efficiently and accurately recognize the data. The main function is to copy the received raw audio data stream three times and cache them into 3 seconds, 9 seconds and 24 seconds of audio data streams to be processed respectively.

[0062] In some embodiments, the three audio data streams to be processed are respectively a first data stream to be processed, a second data stream to be processed and a third data stream to be processed, wherein the first data stream to be processed includes an audio queue of a first duration, the second data stream to be processed includes an audio queue of a second duration, and the third data stream to be processed includes an audio queue of a third duration; wherein the first duration is smaller than the second duration, and the second duration is smaller than the third duration.

[0063] For example, the first duration is 3 seconds, the second duration is 9 seconds, and the third duration is 24 seconds. This is only an example, and those skilled in the art can also determine other first durations, second durations, and third durations according to actual conditions. Figure 2 The relationship between the 3-second audio queue, the 9-second audio queue and the 24-second audio queue is shown, wherein the first audio segment of the 24-second audio queue is 27 seconds, and the 21st second is used as the starting point of the second audio segment, so that the second audio segment overlaps with the first audio segment by 6 seconds, or each 24-second audio queue overlaps with the previous queue by 6 seconds, and the last 6 seconds of the current queue is also the first 6 seconds of the next 24-second queue, which facilitates screening and deduplication through the recognition results of the 24-second audio queue.

[0064] Exemplarily, the first duration, the second duration and the third duration are dynamically adjusted, and the lengths of the first duration, the second duration and the third duration can be adjusted according to actual circumstances, which can achieve real-time speech recognition more effectively and accurately.

[0065] In some embodiments, the method of performing multi-level real-time recognition on the three audio data streams to be processed using a speech model to obtain a recognition result includes:

[0066] Using a speech model to perform real-time recognition on the first duration audio queue to obtain a first recognition result;

[0067] Using the speech model to perform real-time recognition on the second duration audio queue to obtain a second recognition result;

[0068] The speech model is used to perform real-time recognition on the first duration audio queue to obtain a third recognition result.

[0069] Exemplarily, the 3-second audio queue is mainly used for real-time processing: the segmented 3-second audio queue is input into the speech model.

[0070] Use the speech model to process the audio queue of a short period of time to generate original text.

[0071] The voice model includes Whisper or XTTS-v2, and may also be other voice models known to those skilled in the art, which are not limited here.

[0072] Exemplarily, the 9-second audio queue and the 24-second audio queue are used to obtain the second recognition result and the third recognition result, respectively, so as to optimize the original text and obtain a more accurate recognition result.

[0073] In some embodiments, obtaining the target text based on the recognition result includes:

[0074] Using the second recognition result to adjust the first recognition result, correct the erroneous content in the first recognition result, and obtain a preliminary text;

[0075] The preliminary text is screened and deduplicated using the third recognition result to obtain a target text.

[0076] In some embodiments, the voice collection device includes any one of a microphone, a voice recorder, a USB microphone and a smart phone.

[0077] This application achieves real-time, accurate and long-term context processing through hierarchical queue design combined with voice model. The independent operation of different time queues ensures real-time output while taking into account subsequent dynamic optimization, which is suitable for complex interactive scenarios.

[0078] According to the following Figure 3 Another example of the present application is described in detail, such as Figure 3 As shown:

[0079] S1: Input (raw audio data stream)

[0080] S2: The preprocessing function performs preliminary processing on the original audio data stream to ensure that the subsequent model can efficiently and accurately recognize the data. The received original audio data stream is copied three times and cached into 3 seconds, 9 seconds and 24 seconds of audio data streams to be processed respectively.

[0081] Specifically, the 3-second audio queue is mainly used for real-time processing, and the first recognition result obtained can be directly fed back to the output text (ie, S4 recognition result splicing) and displayed on the user interface to meet real-time display requirements.

[0082] Specifically, the 9-second audio queue is used for precision optimization. The voice model is called every 9 seconds to comprehensively process the past three 3-second audio data. The optimization algorithm adjusts the results of the previous 3 seconds based on context information to correct possible misrecognition content.

[0083] The optimized result overwrites the original text corresponding to the first recognition result of the 3-second audio comparison to obtain the initial text to improve the accuracy and update it to the final text output.

[0084] The voice model is called every 24 seconds to separate and recognize longer audio content to obtain the third recognition result.

[0085] The initial text is filtered and deduplicated through a redundancy removal algorithm, and the previous initial text is overwritten as the target text, while the final output text is updated.

[0086] S3: The speech model realizes speech-to-text processing.

[0087] This speech model runs through the speech recognition stage of the 3-second, 9-second, and 24-second audio queues, and uses a language model to convert audio data into text data.

[0088] S4: Recognition result splicing

[0089] 1. Splicing (short-term optimization): Splice the results of the 3-second audio queue and the 9-second audio queue to ensure the completeness and coherence of the transcribed content in a short time. For example, based on the context model (such as the second recognition result corresponding to the 9-second audio queue), dynamically correct the text content recognized in the first 3 seconds.

[0090] 2. Remove redundancy (long-term optimization): Combined with the in-depth analysis results of the 24-second audio queue, optimize the overlapping intervals: delete duplicate text or semantically conflicting paragraphs, retain content with a longer time span or more accurate content. Finally, update the final output text to obtain the target text.

[0091] The spliced ​​and optimized target text is displayed to the user through the output module, which displays the updated speech transcription content in real time. Combined with the multi-level processing results of different queues, the final output text is accurate and clear, suitable for real-time interactive scenarios.

[0092] The real-time speech recognition method of the present application can achieve the following technical effects:

[0093] 1. Improve the accuracy of speech recognition.

[0094] This application introduces a multi-layer queue optimization mechanism to divide voice processing into three levels: short time window (such as 3 seconds), medium time window (such as 9 seconds) and long time window (such as 24 seconds). Queues at different levels are responsible for real-time response, semantic integration and global context optimization respectively.

[0095] In a long time window, combined with an asynchronous correction algorithm, not only the text in a single window is corrected, but also the contextual information across windows is fully utilized to optimize semantic consistency.

[0096] 2. Solve the problem of lack of semantic coherence.

[0097] This application utilizes a method that combines sliding windows with multi-level queues to not only process the audio within each window independently, but also generate coherent text results through comparative analysis and context integration across windows.

[0098] 3. Achieve a balance between real-time and accuracy.

[0099] This application uses short time windows to achieve rapid response to audio, while gradually covering and correcting preliminary results through medium and long time windows, taking into account both real-time and accuracy.

[0100] A dynamic window adjustment mechanism is provided, which can flexibly adjust the window length and processing strategy according to scenario requirements (such as speech complexity or network status), thereby improving recognition effect while ensuring low latency.

[0101] 4. Improve adaptability to multiple scenarios.

[0102] In the case of poor network conditions, the sliding window size and transmission parameters are adaptively adjusted to reduce the impact of packet loss and delay.

[0103] It should be noted that the method of one or more embodiments of the present application can be performed by a single device, such as a computer or server. The method of this embodiment can also be applied to a distributed scenario and completed by multiple devices cooperating with each other. In the case of such a distributed scenario, one of the multiple devices can only perform one or more steps in the method of one or more embodiments of the present application, and the multiple devices will interact with each other to complete the described method.

[0104] It should be noted that the above describes specific embodiments of the present application. Other embodiments are within the scope of the appended claims. In some cases, the actions or steps recorded in the claims can be performed in an order different from that in the embodiments and still achieve the desired results. In addition, the processes depicted in the accompanying drawings do not necessarily require the specific order or continuous order shown to achieve the desired results. In some embodiments, multitasking and parallel processing are also possible or may be advantageous.

[0105] Based on the same inventive concept, corresponding to any of the above-mentioned embodiments and methods, the present application also discloses an electronic device;

[0106] Specifically, Figure 4 The hardware structure diagram of an electronic device for a real-time speech recognition method provided in this embodiment is shown, and the device may include: a processor 410, a memory 420, an input / output interface 430, a communication interface 440, and a bus 450. The processor 410, the memory 420, the input / output interface 430, and the communication interface 440 are connected to each other in communication within the device through the bus 450.

[0107] The processor 410 can be implemented by a general-purpose CPU (Central Processing Unit), a microprocessor, an application-specific integrated circuit (ASIC), or one or more integrated circuits, and is used to execute relevant programs to implement the technical solutions provided in the embodiments of the present application.

[0108] The memory 420 can be implemented in the form of ROM (Read Only Memory), RAM (Random Access Memory), static storage device, dynamic storage device, etc. The memory 420 can store an operating system and other application programs. When the technical solution provided in the embodiment of the present application is implemented by software or firmware, the relevant program code is stored in the memory 420 and called and executed by the processor 410.

[0109] The input / output interface 430 is used to connect the input / output module to realize information input and output. The input / output module can be configured in the device as a component (not shown in the figure), or it can be externally connected to the device to provide corresponding functions. The input device may include a keyboard, a mouse, a touch screen, a microphone, various sensors, etc., and the output device may include a display, a speaker, a vibrator, an indicator light, etc.

[0110] The communication interface 440 is used to connect a communication module (not shown) to realize communication interaction between the device and other devices. The communication module can realize communication through a wired mode (for example, USB, network cable, etc.) or a wireless mode (for example, mobile network, WIFI, Bluetooth, etc.).

[0111] The bus 450 includes a path that transmits information between the various components of the device (eg, the processor 410 , the memory 420 , the input / output interface 430 , and the communication interface 440 ).

[0112] It should be noted that, although the above device only shows the processor 410, the memory 420, the input / output interface 430, the communication interface 440 and the bus 450, in the specific implementation process, the device may also include other components necessary for normal operation. In addition, it can be understood by those skilled in the art that the above device may also only include the components necessary for implementing the embodiment of the present application, and does not necessarily include all the components shown in the figure.

[0113] The electronic device of the above embodiment is used to implement the corresponding real-time speech recognition method in any of the above embodiments, and has the beneficial effects of the corresponding method embodiment, which will not be described in detail here.

[0114] Based on the same inventive concept, corresponding to any of the above-mentioned embodiments and methods, one or more embodiments of the present application also provide a computer-readable storage medium, wherein the computer-readable storage medium stores computer instructions, and the computer instructions are used to enable the computer to execute the real-time speech recognition method as described in any of the above embodiments.

[0115] The computer-readable medium of this embodiment includes permanent and non-permanent, removable and non-removable media, and information storage can be implemented by any method or technology. Information can be computer-readable instructions, data structures, modules of programs, or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technology, read-only compact disk read-only memory (CD-ROM), digital versatile disk (DVD) or other optical storage, magnetic cassettes, tape disk storage or other magnetic storage devices or any other non-transmission media that can be used to store information that can be accessed by a computing device.

[0116] The computer instructions stored in the storage medium of the above embodiment are used to enable the computer to execute the real-time speech recognition method described in any of the above embodiments, and have the beneficial effects of the corresponding method embodiments, which will not be repeated here.

[0117] Those skilled in the art should understand that the discussion of any of the above embodiments is merely illustrative and is not intended to imply that the scope of the present application (including the claims) is limited to these examples. In line with the concept of the present application, the technical features in the above embodiments or different embodiments may be combined, the steps may be implemented in any order, and there are many other variations of different aspects of one or more embodiments of the present application as described above, which are not provided in detail for the sake of simplicity.

[0118] In addition, to simplify the description and discussion, and in order not to make one or more embodiments of the present application difficult to understand, the known power / ground connections to the integrated circuit (IC) chip and other components may or may not be shown in the provided drawings. In addition, the device can be shown in the form of a block diagram to avoid making one or more embodiments of the present application difficult to understand, and this also takes into account the fact that the details of the implementation of these block diagram devices are highly dependent on the platform on which one or more embodiments of the present application will be implemented (that is, these details should be fully within the scope of understanding of those skilled in the art). In the case of elaborating specific details (e.g., circuits) to describe exemplary embodiments of the present application, it is obvious to those skilled in the art that one or more embodiments of the present application can be implemented without these specific details or when these specific details are changed. Therefore, these descriptions should be considered illustrative rather than restrictive.

[0119] Although the present application has been described in conjunction with specific embodiments of the present application, many replacements, modifications and variations of these embodiments will be apparent to those skilled in the art from the foregoing description. For example, other memory architectures (e.g., dynamic RAM (DRAM)) may use the embodiments discussed.

[0120] One or more embodiments of the present application are intended to cover all such substitutions, modifications and variations that fall within the broad scope of the appended claims. Therefore, any omissions, modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of one or more embodiments of the present application should be included in the scope of protection of the present application.

Claims

1. A real-time speech recognition method, characterized in that: include: Get real-time raw audio data stream from the voice acquisition device; The preprocessing module performs preliminary processing on the original audio data stream to obtain three audio data streams to be processed; Using the speech model to perform multi-level real-time recognition on the three audio data streams to be processed to obtain recognition results; Obtaining a target text based on the recognition result; The target text is displayed to the user through an output module.

2. The real-time speech recognition method according to claim 1, characterized in that: The preprocessing module performs preliminary processing on the original audio data stream to obtain three audio data streams to be processed, including: The original audio data stream is copied into three copies, each of which is used as a to-be-processed audio data stream, and there are three to-be-processed audio data streams in total.

3. The real-time speech recognition method according to claim 2, characterized in that: The three audio data streams to be processed are respectively the first data stream to be processed, the second data stream to be processed and the third data stream to be processed. The first data stream to be processed includes an audio queue of a first duration, the second data stream to be processed includes an audio queue of a second duration, and the third data stream to be processed includes an audio queue of a third duration; wherein the first duration is smaller than the second duration, and the second duration is smaller than the third duration.

4. The real-time speech recognition method according to claim 3, characterized in that: The method of using the speech model to perform multi-level real-time recognition on the three audio data streams to be processed to obtain recognition results includes: Using a speech model to perform real-time recognition on the first duration audio queue to obtain a first recognition result; Using the speech model to perform real-time recognition on the second duration audio queue to obtain a second recognition result; The speech model is used to perform real-time recognition on the first duration audio queue to obtain a third recognition result.

5. The real-time speech recognition method according to claim 4, characterized in that: The obtaining of the target text based on the recognition result comprises: Using the second recognition result to adjust the first recognition result, correct the erroneous content in the first recognition result, and obtain a preliminary text; The preliminary text is screened and deduplicated using the third recognition result to obtain a target text.

6. The real-time speech recognition method according to claim 3 or 5, characterized in that: The first duration is 3 seconds, the second duration is 9 seconds, and the third duration is 24 seconds; or, The first duration, the second duration and the third duration are adjusted dynamically.

7. The real-time speech recognition method according to claim 1, characterized in that: The voice collection device includes any one of a microphone, a voice recorder, a USB microphone and a smart phone.

8. The real-time speech recognition method according to claim 6, characterized in that: The voice model includes Whisper or XTTS-v2.

9. An electronic device, comprising: A memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the method according to any one of claims 1 to 8 when executing the computer program.

10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores one or more programs, and the one or more programs can be executed by one or more processors to implement the method according to any one of claims 1 to 8.

Citation Information

Patent Citations

  • Distributed speech recognition error correction device and method based on position and time

    CN110534112A

  • Multi-scale audio scene recognition method based on attention mechanism

    CN110782878A

  • Voice lip reading method and system based on multi-scale video feature fusion

    CN113450824A

  • Voice recognition method and device, electronic equipment and storage medium

    CN113920998A

  • Voice recognition method and device, and electronic equipment

    CN114067800A