Voiceprint recognition method and device based on historical dialogue voiceprint library and dynamic threshold

By constructing a historical dialogue voiceprint database and a dynamic threshold voiceprint recognition method, the problems of accuracy and time-varying robustness in short speech recognition are solved, adapting to environmental changes and achieving efficient voiceprint recognition results.

CN123161579APending Publication Date: 2026-11-24XIAMEN KUAISHANGTONG TECH CORP LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611026906.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Priority Date
2026-06-04
Filing Date
2026-07-10
Publication Date
2026-11-24

AI Technical Summary

Technical Problem

Existing voiceprint recognition technologies have shortcomings in short speech recognition accuracy, time-varying robustness, environmental differences and channel mismatch, and fixed threshold decision-making, resulting in decreased recognition accuracy and poor user experience.

Method used

A voiceprint recognition method based on a historical dialogue voiceprint database and dynamic thresholds is adopted. By constructing a registered voiceprint database and a historical dialogue voiceprint database, and dynamically adjusting the threshold by combining speech duration and environmental signal-to-noise ratio, a voiceprint score is calculated to determine identity.

Benefits of technology

It improves the accuracy of short speech recognition, adapts to changes in user voice and environment, achieves a dynamic balance between security and convenience, and enhances the system's usability in real-world dialogue scenarios.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN123161579A_ABST
    Figure CN123161579A_ABST
Patent Text Reader

Abstract

This invention discloses a voiceprint recognition method and apparatus based on a historical dialogue voiceprint database and a dynamic threshold. The method includes: calculating the similarity between the current voiceprint feature and each registered voiceprint feature in the registered voiceprint database to obtain a first similarity sequence; assuming the identity of the current voiceprint feature matches a second speaker label, calculating the similarity between the current voiceprint feature and the speaker voiceprint features of each speech segment corresponding to the second speaker label in the historical dialogue voiceprint database to obtain a second similarity sequence for the corresponding second speaker label and a historical consistency score for the second speaker label; for cases where the second speaker label matches the first speaker label, calculating a voiceprint score based on the first similarity, the second similarity sequence for the corresponding second speaker label, and the historical consistency score; and comparing all voiceprint scores with a dynamic threshold to determine the identity of the current speaker. This invention can significantly improve the accuracy of voiceprint recognition.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of voiceprint recognition, specifically to a voiceprint recognition method and apparatus based on a historical dialogue voiceprint database and dynamic thresholds. Background Technology

[0002] Voiceprint recognition (VCR) is a biometric technology that verifies identity by analyzing an individual's voice characteristics. It has been widely applied in scenarios such as financial payments, intelligent customer service, and remote identity authentication. Current mainstream technologies include methods based on Gaussian Mixture Model-Universal Background Model (GMM-UBM) and deep neural network embeddings (x-vector, ECAPA-TDNN).

[0003] Existing voiceprint recognition systems mainly suffer from the following technical shortcomings:

[0004] (1) Bottleneck of accuracy in short speech recognition: In real-world dialogue scenarios, users’ speech is often short (1-3 seconds), and the recognition accuracy of existing technologies based on short speech is significantly reduced. Traditional methods rely on speech of sufficient duration to extract stable voiceprint features. Short speech results in insufficient feature dimensions and unstable statistical properties, leading to an increased false rejection rate (FRR).

[0005] (2) Insufficient time-varying robustness: Voiceprint recognition faces a serious challenge of "time-varying robustness", that is, the user's voice will change over time (such as when they have a cold, get older, or experience emotional fluctuations), causing the registered voice template to mismatch with the current voice. Existing systems usually require users to re-register their voiceprints periodically (such as every 3-6 months), which seriously affects the user experience.

[0006] (3) Environmental differences and channel mismatch: The registration environment and the usage environment are often different (e.g., registration in a quiet office and use in a noisy home environment). The "channel mismatch" caused by different microphone types and transmission channels significantly reduces the recognition accuracy. Existing technologies mostly use channel compensation algorithms (such as NAP and WCCN), but they cannot adapt to the dynamic changes in the environment during the dialogue.

[0007] (4) Limitations of fixed threshold decision-making: Existing systems generally use fixed thresholds for voiceprint matching, which cannot adapt to the confidence requirements in different scenarios. During the dialogue, voice quality, environmental noise, and speaker status are constantly changing. Fixed thresholds result in either being too strict (high FRR) or too lenient (high FAR), failing to balance security and user experience. Summary of the Invention

[0008] The purpose of this application is to propose a voiceprint recognition method and apparatus based on a historical dialogue voiceprint database and dynamic thresholds to address the aforementioned technical problems.

[0009] In a first aspect, the present invention provides a voiceprint recognition method based on a historical dialogue voiceprint database and a dynamic threshold, comprising the following steps:

[0010] A registered voiceprint database is constructed, which stores different first speaker labels and their corresponding registered voiceprint features.

[0011] During a voice dialogue, the current speech segment data of the current speaker is acquired, preprocessed, and voiceprint features are extracted to obtain the current voiceprint features; the similarity between the current voiceprint features and each registered voiceprint feature in the registered voiceprint database is calculated to obtain the first similarity sequence.

[0012] In response to the determination that historical dialogue voice data exists before the current voice segment data, a historical dialogue voiceprint database constructed based on the historical dialogue voice data is obtained. The historical dialogue voiceprint database stores the speaker voiceprint features corresponding to each voice segment data in the historical dialogue voice data and its corresponding second speaker label. Assuming that the identity of the current voiceprint feature is consistent with the second speaker label, the similarity between the current voiceprint feature and the speaker voiceprint features of each voice segment data corresponding to the second speaker label in the historical dialogue voiceprint database is calculated to obtain the second similarity sequence of the corresponding second speaker label. The historical consistency score of the corresponding second speaker label is calculated based on the second similarity sequence of the corresponding second speaker label. In the case where the second speaker label is consistent with the first speaker label, the voiceprint score is calculated based on the first similarity corresponding to the first speaker label that is consistent with the second speaker label in the first similarity sequence, the second similarity sequence of the corresponding second speaker label, and the historical consistency score.

[0013] The dynamic threshold is determined based on the speech duration and environmental signal-to-noise ratio of the current speech segment data; all voiceprint scores are compared with the dynamic threshold, and the identity of the current speaker is determined based on the comparison result.

[0014] Preferably, the historical dialogue voice data includes several voice segment data, each voice segment data consists of voice data generated by a single speaker within a continuous time period; the set of all first speaker tags includes at least all second speaker tags.

[0015] As a preferred embodiment, the calculation process for the second similarity sequence of one of the second speaker tags is as follows:

[0016] S hist ={sim(V current V i )};

[0017] Among them, S hist V represents the second similarity sequence of one of the second speaker labels. currentThis represents the current voiceprint features, sim represents the similarity calculation function, and DVC represents the similarity calculation function. confirmed V represents the set of speaker voiceprint features for all speech segments corresponding to one of the second speaker tags in the historical dialogue voiceprint database. i ∈DVC confirmed V i The speaker voiceprint feature represents the speaker voiceprint feature of the i-th speech segment in the set of all speech segment data corresponding to one of the second speaker tags in the historical dialogue voiceprint database.

[0018] The calculation process for the historical consistency score of one of the second speaker labels is as follows:

[0019] S consistency =mean(S hist );

[0020] Where mean represents the average of the elements in the set, S consistency This represents the historical consistency score of one of the second speaker labels.

[0021] As a preferred option, for the case where the second speaker label is the same as the first speaker label, the voiceprint score is calculated as follows:

[0022] S final =(S reg + N(S hist )* S consistency ) / ( N(S hist )+1);

[0023] Among them, S final S represents the voiceprint score. reg N(S) represents the first similarity in the first similarity sequence. hist ) represents the total number of elements in the second similarity sequence of one of the second speaker labels.

[0024] Preferably, a dynamic threshold is determined based on the speech duration and environmental signal-to-noise ratio of the current speech segment data, specifically including:

[0025] Establish the first mapping relationship between different duration threshold ranges and their corresponding speech duration factors;

[0026] Establish a second mapping relationship between different signal-to-noise ratio threshold ranges and their corresponding environmental stability factors;

[0027] The speech duration of the current speech segment data is compared with different duration threshold ranges to determine the duration threshold range in which the current speech segment data falls, and the value of the corresponding speech duration factor is determined according to the first mapping relationship.

[0028] The environmental signal-to-noise ratio of the current speech segment data is compared with different signal-to-noise ratio threshold ranges to determine the signal-to-noise ratio threshold range in which the current speech segment data is located, and the corresponding environmental stability factor value is determined according to the second mapping relationship.

[0029] The dynamic threshold is obtained by multiplying the base threshold by the values ​​of the speech duration factor corresponding to the speech duration of the current speech segment data and the environmental stability factor.

[0030] As a preferred option, it also includes:

[0031] In response to determining that there is no historical dialogue speech data before the current speech segment data, the first similarity in the first similarity sequence is used as the voiceprint score;

[0032] In cases where the second speaker label is inconsistent with the first speaker label, the first similarity score corresponding to the first speaker label that is inconsistent with the second speaker label in the first similarity sequence is taken as the voiceprint score.

[0033] The identity of the current speaker is used as the second speaker label and stored in the historical dialogue voiceprint database along with the voiceprint features of the current speech segment data.

[0034] At preset intervals, the voiceprint features in the registered voiceprint database are softly updated using an exponentially weighted moving average method based on the voiceprint score.

[0035] Secondly, the present invention provides a voiceprint recognition device based on a historical dialogue voiceprint database and a dynamic threshold, comprising:

[0036] The registered voiceprint database construction module is configured to build a registered voiceprint database, which stores different first speaker tags and their corresponding registered voiceprint features.

[0037] The voiceprint extraction module is configured to acquire the current speech segment data emitted by the current speaker during the voice dialogue, perform preprocessing and voiceprint feature extraction to obtain the current voiceprint feature; calculate the similarity between the current voiceprint feature and each registered voiceprint feature in the registered voiceprint database to obtain the first similarity sequence.

[0038] The voiceprint score calculation module is configured to, in response to determining that historical dialogue voice data exists before the current speech segment data, obtain a historical dialogue voiceprint database constructed based on the historical dialogue voice data. The historical dialogue voiceprint database stores the speaker voiceprint features corresponding to each speech segment in the historical dialogue voice data and its corresponding second speaker label. Assuming that the identity of the current voiceprint feature is consistent with the second speaker label, the similarity between the current voiceprint feature and the speaker voiceprint features of each speech segment corresponding to the second speaker label in the historical dialogue voiceprint database is calculated to obtain a second similarity sequence for the corresponding second speaker label. The historical consistency score of the corresponding second speaker label is calculated based on the second similarity sequence of the corresponding second speaker label. In the case where the second speaker label is consistent with the first speaker label, the voiceprint score is calculated based on the first similarity corresponding to the first speaker label that is consistent with the second speaker label in the first similarity sequence, the second similarity sequence of the corresponding second speaker label, and the historical consistency score.

[0039] The comparison module is configured to determine a dynamic threshold based on the speech duration and environmental signal-to-noise ratio of the current speech segment data; compare all voiceprint scores with the dynamic threshold, and determine the identity of the current speaker based on the comparison result.

[0040] Thirdly, the present invention provides an electronic device including one or more processors; and a storage device for storing one or more programs, wherein when the one or more programs are executed by the one or more processors, the one or more processors implement the method as described in any implementation of the first aspect.

[0041] Fourthly, the present invention provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the method as described in any of the implementations of the first aspect.

[0042] Fifthly, the present invention provides a computer program product, including a computer program that, when executed by a processor, implements the method as described in any of the implementations in the first aspect.

[0043] Compared with the prior art, the present invention has the following beneficial effects:

[0044] (1) The voiceprint recognition method based on historical dialogue voiceprint database and dynamic threshold mentioned in this invention introduces a historical consistency score. Even if a single speech segment is short (1-2 seconds) and its similarity to the registered voiceprint is slightly lower than a fixed threshold, it can still be correctly recognized as long as it has a high voiceprint similarity to the voiceprint features of the speaker confirmed in the real-time dialogue. This significantly improves the voiceprint recognition accuracy of short speech segments. This effectively solves the problem of increased missed recognition rate caused by insufficient features of short speech segments, and greatly improves the usability of the system in actual dialogue scenarios.

[0045] (2) The voiceprint recognition method based on historical dialogue voiceprint database and dynamic threshold mentioned in this invention can tolerate the slow changes in user voice by adaptively tracking the historical dialogue voiceprint database in real time. Based on the first similarity, the historical consistency score is calculated by using the voiceprint similarity of continuous speech segments in the dialogue process, and the total number of elements in the second similarity sequence of each speaker's label is counted. Finally, the voiceprint score is calculated, which is adapted to the actual dialogue scenario and reduces the influence of factors such as environment, time variation, and voice state on voiceprint comparison.

[0046] (3) The voiceprint recognition method based on historical dialogue voiceprint database and dynamic threshold mentioned in this invention dynamically evaluates the voiceprint variance of the current dialogue through environmental stability factors, and can perceive environmental changes (such as moving from a quiet room to a noisy street). When environmental instability is detected, the requirement for matching degree between single voice segment and registered template is automatically reduced, and instead the historical consistency of voiceprints within the dialogue is relied upon for judgment, effectively alleviating the channel mismatch problem. The dynamic threshold is obtained by using voice duration and environmental signal-to-noise ratio, which can be adaptively adjusted according to the dialogue state. In scenarios with high security requirements (such as payment confirmation), a strict threshold is maintained, while in ordinary dialogue scenarios, the threshold is appropriately relaxed by utilizing historical consistency, achieving a dynamic balance between security and convenience. Attached Figure Description

[0047] To more clearly illustrate the technical solutions in the embodiments of the present invention, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0048] Figure 1 This is a flowchart illustrating the voiceprint recognition method based on a historical dialogue voiceprint database and dynamic threshold, as an embodiment of this application.

[0049] Figure 2 This is a schematic diagram of a voiceprint recognition device based on a historical dialogue voiceprint database and dynamic thresholds, which is an embodiment of this application.

[0050] Figure 3 This is a schematic diagram of the hardware structure of an electronic device provided in an embodiment of the present invention. Detailed Implementation

[0051] To make the objectives, technical solutions, and advantages of this invention clearer, the invention will be further described in detail below with reference to the accompanying drawings. Obviously, the described embodiments are only a part of the embodiments of this invention, and not all of them. Based on the embodiments of this invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this invention.

[0052] Figure 1 The illustration shows an embodiment of this application providing a voiceprint recognition method based on a historical dialogue voiceprint database and a dynamic threshold, comprising the following steps:

[0053] S1. Construct a registered voiceprint database, which stores different first speaker labels and their corresponding registered voiceprint features.

[0054] Specifically, in the embodiments of this application, a registered voiceprint database is first constructed. This database stores several first speaker tags and their corresponding registered voiceprint features. These registered voiceprint features are voiceprint features obtained by preprocessing and extracting voice data collected during each speaker's voice registration process, and each corresponds one-to-one with the first speaker tag of that speaker. The first speaker tag corresponds to the speaker's identity tag.

[0055] S2, during the voice dialogue, acquire the current speech segment data of the current speaker and perform preprocessing and voiceprint feature extraction to obtain the current voiceprint feature; calculate the similarity between the current voiceprint feature and each registered voiceprint feature in the registered voiceprint database to obtain the first similarity sequence.

[0056] Specifically, during a voice dialogue, the current speech segment data emitted by the current speaker is acquired in real time and preprocessed and its voiceprint features are extracted to obtain the current voiceprint features. The preprocessing includes endpoint detection (VAD), speech segmentation, noise reduction, pre-emphasis, and framing. The voiceprint feature extraction process uses existing voiceprint feature extraction models such as ResNet and ECAPA-TDNN. Then, the similarity between the current voiceprint features and each registered voiceprint feature in the registered voiceprint database is calculated to obtain a first similarity sequence. This first similarity sequence contains the first similarity between the current voiceprint features and each registered voiceprint feature, as shown in the following formula:

[0057] S reg =sim(V current V reg );

[0058] Among them, S reg V represents one of the first similarity scores in the first similarity sequence. current V represents the current voiceprint characteristics. reg This represents one of the registered voiceprint features, and sim represents the similarity calculation function.

[0059] In the embodiments of this application, the similarity calculation function may be the cosine similarity function, or other suitable similarity calculation functions may be used.

[0060] S3, in response to determining that historical dialogue voice data exists before the current voice segment data, a historical dialogue voiceprint database constructed based on the historical dialogue voice data is obtained. The historical dialogue voiceprint database stores the speaker voiceprint features corresponding to each voice segment data in the historical dialogue voice data and its corresponding second speaker label. Assuming that the identity of the current voiceprint feature is consistent with the second speaker label, the similarity between the current voiceprint feature and the speaker voiceprint features of each voice segment data corresponding to each second speaker label in the historical dialogue voiceprint database is calculated to obtain the second similarity sequence of the corresponding second speaker label. The historical consistency score of the corresponding second speaker label is calculated based on the second similarity sequence of the corresponding second speaker label. For the case where the second speaker label is consistent with the first speaker label, the voiceprint score is calculated based on the first similarity corresponding to the first speaker label consistent with the second speaker label in the first similarity sequence, the second similarity sequence of the corresponding second speaker label, and the historical consistency score.

[0061] In a specific embodiment, the historical dialogue voice data includes several voice segment data, each voice segment data consists of voice data generated by a single speaker within a continuous time period; the set of all first speaker tags includes at least all second speaker tags.

[0062] Specifically, the embodiments of this application can be applied to voiceprint recognition scenarios in online dialogues. This involves identifying the speaker's identity in real-time during a voice dialogue, recording it as a second speaker tag, and constructing a historical dialogue voiceprint library based on the progress of the voice dialogue, using voice segments from various historical time periods and their corresponding second speaker tags. Historical dialogue data refers to all voice segments preceding the current voice segment, and the second speaker tag is also included in the set of all first speaker tags in the registered voiceprint library. Furthermore, this historical dialogue voiceprint library is dynamically maintained for each current voice segment during the voice dialogue, represented as DVC={V1,V2,...,V...}. n}, V j This represents the speaker's voiceprint features in the j-th speech segment data of the historical dialogue voiceprint database.

[0063] In a specific embodiment, the calculation process for the second similarity sequence of one of the second speaker tags is as follows:

[0064] S hist ={sim(V current V i )};

[0065] Among them, S hist V represents the second similarity sequence of one of the second speaker labels. currentThis represents the current voiceprint features, sim represents the similarity calculation function, and DVC represents the similarity calculation function. confirmed V represents the set of speaker voiceprint features for all speech segments corresponding to one of the second speaker tags in the historical dialogue voiceprint database. i ∈DVC confirmed V i The speaker voiceprint feature represents the speaker voiceprint feature of the i-th speech segment in the set of all speech segment data corresponding to one of the second speaker tags in the historical dialogue voiceprint database.

[0066] The calculation process for the historical consistency score of one of the second speaker labels is as follows:

[0067] S consistency =mean(S hist );

[0068] Where mean represents the average of the elements in the set, S consistency This represents the historical consistency score of one of the second speaker labels.

[0069] In a specific embodiment, for the case where the second speaker label is the same as the first speaker label, the voiceprint score is calculated as follows:

[0070] S final =(S reg + N(S hist )* S consistency ) / ( N(S hist )+1);

[0071] Among them, S final S represents the voiceprint score. reg N(S) represents the first similarity in the first similarity sequence. hist ) represents the total number of elements in the second similarity sequence of one of the second speaker labels.

[0072] Specifically, if historical dialogue voice data exists before the current voice segment data, meaning the current voice segment data is not the first voice segment data in the voice dialogue process, then the historical consistency score is calculated by identifying the temporal continuity of the "same speaker". The specific process is as follows: assuming the identity of the current voiceprint feature matches the second speaker label, the speaker voiceprint features of each voice segment data corresponding to each second speaker label in the historical dialogue voiceprint database are extracted and constructed into a set, represented as DVC. confirmedTaking a historical dialogue voiceprint database containing 9 speech segments and 2 second speaker labels A and B as an example, if the second speaker labels corresponding to V1, V2, V3, V4, V5, V6, V7, V8, and V9 in the historical dialogue voiceprint database DVC are A, B, B, A, B, A, B, A, A, then the DVC corresponding to the second speaker label A is... confirmed ={V1,V4,V6,V8,V9}, the DVC corresponding to the second speaker's label B. confirmed ={V2, V3, V5, V7}. During real-time dialogue, even if the speaker's voiceprint features belong to the same speaker, there are subtle fluctuations and differences in the voiceprint features of each speech segment in the historical dialogue voiceprint database.

[0073] Calculate the similarity between the current voiceprint feature and the speaker voiceprint features of each speech segment corresponding to each second speaker tag in the historical dialogue voiceprint database, obtaining the second similarity sequence for the corresponding second speaker tag; calculate the historical consistency score for the corresponding second speaker tag based on the second similarity sequence. In the example, for second speaker tag A, calculate V... current The similarity to V1, V4, V6, V8, and V9 is denoted as the second similarity. All the second similarities constitute the second similarity sequence of the second speaker label A. The second similarity sequence of the second speaker label B can be calculated in the same way. Then, the average of all the second similarities in the second similarity sequence of each second speaker label is taken to obtain the historical consistency score of each second speaker label.

[0074] Furthermore, for cases where the second speaker label matches the first speaker label, the voiceprint score S can be calculated based on the first similarity score corresponding to the first speaker label that matches the second speaker label in the first similarity sequence, combined with the total number of all second similarities in the second similarity sequence for each second speaker label and the historical consistency score. final Through the above processing, the voiceprint score is gradually shifted to the actual scene, reducing the impact of factors such as environment, time variation, and voice state on voiceprint comparison.

[0075] In specific embodiments, it also includes:

[0076] In response to determining that there is no historical dialogue speech data before the current speech segment data, the first similarity in the first similarity sequence is used as the voiceprint score;

[0077] In cases where the second speaker label is inconsistent with the first speaker label, the first similarity score corresponding to the first speaker label that is inconsistent with the second speaker label in the first similarity sequence is taken as the voiceprint score.

[0078] The identity of the current speaker is used as the second speaker label and stored in the historical dialogue voiceprint database along with the voiceprint features of the current speech segment data.

[0079] At preset intervals, the voiceprint features in the registered voiceprint database are soft-updated using an exponentially weighted moving average method based on the voiceprint score.

[0080] Specifically, if there is no historical dialogue voice data before the current voice segment data, that is, the current voice segment data is the first voice segment data in the voice dialogue process, in this case, the first similarity in the first similarity sequence is directly used as the voiceprint score, and then compared with the dynamic threshold. The identity of the current speaker is determined based on the comparison result.

[0081] In cases where the second speaker's label is inconsistent with the first speaker's label, the first similarity score corresponding to the first speaker's label that is inconsistent with the second speaker's label in the first similarity sequence is taken as the voiceprint score. This score is then compared with a dynamic threshold, and the identity of the current speaker is determined based on the comparison result.

[0082] S4. Determine the dynamic threshold based on the speech duration and environmental signal-to-noise ratio of the current speech segment data; compare all voiceprint scores with the dynamic threshold, and determine the identity of the current speaker based on the comparison result.

[0083] In a specific embodiment, a dynamic threshold is determined based on the speech duration of the current speech segment data and the environmental signal-to-noise ratio, specifically including:

[0084] Establish the first mapping relationship between different duration threshold ranges and their corresponding speech duration factors;

[0085] Establish a second mapping relationship between different signal-to-noise ratio threshold ranges and their corresponding environmental stability factors;

[0086] The speech duration of the current speech segment data is compared with different duration threshold ranges to determine the duration threshold range in which the current speech segment data falls, and the value of the corresponding speech duration factor is determined according to the first mapping relationship.

[0087] The environmental signal-to-noise ratio of the current speech segment data is compared with different signal-to-noise ratio threshold ranges to determine the signal-to-noise ratio threshold range in which the current speech segment data is located, and the corresponding environmental stability factor value is determined according to the second mapping relationship.

[0088] The dynamic threshold is obtained by multiplying the base threshold by the values ​​of the speech duration factor corresponding to the speech duration of the current speech segment data and the environmental stability factor.

[0089] Specifically, in the embodiments of this application, a dynamic threshold is adaptively adjusted based on the speech duration and environmental signal-to-noise ratio of the current speech segment data. First, a first mapping relationship is established between different duration threshold ranges and corresponding speech duration factors. The larger the duration threshold range, the larger the corresponding speech duration factor. Shorter speech segments can have lower threshold requirements, which are then compensated for using historical consistency scores. Longer speech segments have higher thresholds to ensure safety. A second mapping relationship is established between different signal-to-noise ratio threshold ranges and corresponding environmental stability factors. The larger the signal-to-noise ratio threshold range, the larger the corresponding environmental stability factor. A speech duration factor α is set for the speech duration of the current speech segment data. duration The value of the speech duration factor is determined based on the duration threshold range of the current speech segment data and the first mapping relationship; an environmental stability factor α is set for the environmental signal-to-noise ratio of the current speech segment data. env The value of the environmental stability factor is determined based on the environmental signal-to-noise ratio (SNR) threshold range of the current speech segment data and the second mapping relationship. The environmental SNR of the current speech segment data in the embodiments of this application can be evaluated using existing algorithms, and is not limited thereto.

[0090] In one example, if the duration of the current speech segment is greater than 5 seconds, then α duration The value is 1.0; if the duration of the current speech segment is between 2 and 5 seconds, then α is... duration The value is 0.97; if the duration of the current speech segment is less than 2 seconds, then α... duration It is 0.95.

[0091] In one example, if the ambient signal-to-noise ratio of the current speech segment data is greater than 20 dB, then α env The value is 1.0; if the environmental signal-to-noise ratio of the current speech segment data is between 10-20 dB, then α is... env The value is 0.97; if the environmental signal-to-noise ratio of the current speech segment data is less than 10dB, then α... env It is 0.95.

[0092] The formula for calculating the dynamic threshold is as follows:

[0093] Threshold adaptive =Threshold base ×α duration ×α env ;

[0094] Among them, Threshold baseThreshold represents the basic threshold. adaptive This indicates a dynamic threshold.

[0095] Furthermore, the voiceprint scores corresponding to all first speaker tags are compared with dynamic thresholds to obtain comparison results. The identity of the current speaker is determined based on these comparison results, specifically including:

[0096] If at least one voiceprint score is greater than or equal to the dynamic threshold in the comparison results, the first speaker label corresponding to the highest value among the voiceprint scores greater than or equal to the dynamic threshold will be used as the identity of the current speaker, and the voiceprint features of the current speech segment data will be added to the historical dialogue voiceprint database.

[0097] If none of the voiceprint scores in the comparison results are greater than or equal to the dynamic threshold, the current speaker's identity is determined to be unknown.

[0098] At preset intervals, the identity of the current speaker in a voice dialogue is determined using the above method, and it is determined whether the voiceprint score corresponding to the identity of the current speaker is greater than the score threshold. If so, the voiceprint features with the same first speaker label in the registered voiceprint database are softly updated using an exponentially weighted moving average method to adapt to the slow time-varying process and avoid re-registration.

[0099] This invention transforms single-speechprint recognition from an "isolated event" into a "temporal process," achieving adaptive speaker identity verification by establishing an in-dialogue speechprint association network.

[0100] The steps S1-S4 above do not necessarily represent the order of the steps, but rather are indicated by step symbols, and the order of the steps can be adjusted. The data mentioned in the embodiments of this application were all obtained in a legal and compliant manner, and their application scenarios are also legal and compliant.

[0101] Further reference Figure 2 As an implementation of the methods shown in the above figures, this application provides an embodiment of a voiceprint recognition device based on a historical dialogue voiceprint database and a dynamic threshold. This device embodiment is similar to... Figure 1 Corresponding to the method embodiments shown, this device can be specifically applied to various electronic devices.

[0102] This application provides a voiceprint recognition device based on a historical dialogue voiceprint database and a dynamic threshold, including:

[0103] The registered voiceprint database construction module 1 is configured to build a registered voiceprint database, which stores different first speaker tags and their corresponding registered voiceprint features.

[0104] Voiceprint extraction module 2 is configured to acquire the current speech segment data emitted by the current speaker during the voice dialogue, perform preprocessing and voiceprint feature extraction to obtain the current voiceprint feature; calculate the similarity between the current voiceprint feature and each registered voiceprint feature in the registered voiceprint database to obtain the first similarity sequence.

[0105] The voiceprint score calculation module 3 is configured to, in response to determining that historical dialogue voice data exists before the current speech segment data, acquire a historical dialogue voiceprint database constructed based on the historical dialogue voice data. The historical dialogue voiceprint database stores the speaker voiceprint features corresponding to each speech segment data in the historical dialogue voice data and its corresponding second speaker label. Assuming that the identity of the current voiceprint feature is consistent with the second speaker label, the similarity between the current voiceprint feature and the speaker voiceprint features of each speech segment data corresponding to each second speaker label in the historical dialogue voiceprint database is calculated to obtain the second similarity sequence of the corresponding second speaker label. The historical consistency score of the corresponding second speaker label is calculated based on the second similarity sequence of the corresponding second speaker label. In the case where the second speaker label is consistent with the first speaker label, the voiceprint score is calculated based on the first similarity corresponding to the first speaker label consistent with the second speaker label in the first similarity sequence, the second similarity sequence of the corresponding second speaker label, and the historical consistency score.

[0106] The comparison module 4 is configured to determine a dynamic threshold based on the speech duration and environmental signal-to-noise ratio of the current speech segment data; compare all voiceprint scores with the dynamic threshold, and determine the identity of the current speaker based on the comparison result.

[0107] Figure 3 This is a schematic diagram of the hardware structure of an electronic device provided in an embodiment of the present invention. For example... Figure 3 As shown, the electronic device in this embodiment includes a processor 301 and a memory 302; wherein the memory 302 is used to store computer execution instructions; and the processor 301 is used to execute the computer execution instructions stored in the memory to implement the various steps performed by the electronic device in the above embodiment. For details, please refer to the relevant descriptions in the foregoing method embodiments.

[0108] Alternatively, the memory 302 can be either standalone or integrated with the processor 301.

[0109] When the memory 302 is set up independently, the electronic device also includes a bus 303 for connecting the memory 302 and the processor 301.

[0110] This invention also provides a computer storage medium storing computer execution instructions, which, when executed by processor 301, implement the above method.

[0111] This invention also provides a computer program product, including a computer program that, when executed by a processor 301, implements the above-described method.

[0112] In the embodiments provided by this invention, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are merely illustrative; for instance, the division of modules is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple modules may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be indirect coupling or communication connection through some interfaces, devices, or modules, and may be electrical, mechanical, or other forms.

[0113] The modules described as separate components may or may not be physically separate. The components shown as modules may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to implement the solution of this embodiment according to actual needs.

[0114] Furthermore, the functional modules in the various embodiments of this invention can be integrated into one processing unit, or each module can exist physically separately, or two or more modules can be integrated into one unit. The unit formed by the above modules can be implemented in hardware or in the form of hardware plus software functional units.

[0115] The integrated modules implemented as software functional modules described above can be stored in a computer-readable storage medium. These software functional modules, stored in a storage medium, include several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) or processor 301 to execute some steps of the methods of the various embodiments of this application.

[0116] It should be understood that the processor 301 described above can be a Central Processing Unit (CPU), or other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), etc. The general-purpose processor can be a microprocessor, or the processor 301 can be any conventional processor 301. The steps of the method disclosed in this invention can be directly manifested as the hardware processor 301 executing the steps, or as a combination of hardware and software modules within the processor 301 executing the steps.

[0117] The memory 302 may include high-speed RAM memory, and may also include non-volatile memory (NVM), such as at least one disk storage device, and may also be a USB flash drive, portable hard drive, read-only memory, disk or optical disc, etc.

[0118] Bus 303 can be an Industry Standard Architecture (ISA), a Peripheral Component Interconnect (PCI) bus, or an Extended Industry Standard Architecture (EISA) bus, etc. Bus 303 can be divided into address bus, data bus, control bus, etc. For ease of illustration, the bus 303 in the accompanying drawings of this application is not limited to only one bus 303 or one type of bus 303.

[0119] The aforementioned storage medium can be implemented from any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic storage, flash memory, magnetic disk, or optical disk. The storage medium can be any available medium accessible to general-purpose or special-purpose computers.

[0120] An exemplary storage medium is coupled to a processor 301, enabling the processor 301 to read information from and write information to the storage medium. Alternatively, the storage medium can be an integral part of the processor 301. The processor 301 and the storage medium can reside in an application-specific integrated circuit (ASIC). Alternatively, the processor 301 and the storage medium can exist as discrete components in an electronic device or a host device.

[0121] Those skilled in the art will understand that all or part of the steps of the above-described method embodiments can be implemented by hardware related to program instructions. The aforementioned program can be stored in a computer-readable storage medium. When executed, the program performs the steps of the above-described method embodiments; and the aforementioned storage medium includes various media capable of storing program code, such as ROM, RAM, magnetic disks, or optical disks.

[0122] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, and not to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some or all of the technical features; and these modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of the present invention.

Claims

1. A voiceprint recognition method based on a historical dialogue voiceprint database and dynamic thresholds, characterized in that, Includes the following steps: A registered voiceprint database is constructed, which stores different first speaker tags and their corresponding registered voiceprint features; During a voice dialogue, the current speech segment data of the current speaker is acquired, preprocessed, and voiceprint features are extracted to obtain the current voiceprint features. Calculate the similarity between the current voiceprint feature and each registered voiceprint feature in the registered voiceprint database to obtain the first similarity sequence; In response to the determination that historical dialogue voice data exists before the current voice segment data, a historical dialogue voiceprint database constructed based on the historical dialogue voice data is obtained. The historical dialogue voiceprint database stores the speaker voiceprint features corresponding to each voice segment data in the historical dialogue voice data and its corresponding second speaker label. Assuming that the identity of the current voiceprint feature is consistent with the second speaker label, the similarity between the current voiceprint feature and the speaker voiceprint features of each voice segment data corresponding to the second speaker label in the historical dialogue voiceprint database is calculated to obtain a second similarity sequence for the corresponding second speaker label. The historical consistency score of the corresponding second speaker label is calculated based on the second similarity sequence of the corresponding second speaker label. For the case where the second speaker label is consistent with the first speaker label, the voiceprint score is calculated based on the first similarity corresponding to the first speaker label consistent with the second speaker label in the first similarity sequence, the second similarity sequence of the corresponding second speaker label, and the historical consistency score. A dynamic threshold is determined based on the speech duration and environmental signal-to-noise ratio of the current speech segment data; all voiceprint scores are compared with the dynamic threshold, and the identity of the current speaker is determined based on the comparison result.

2. The voiceprint recognition method based on a historical dialogue voiceprint database and dynamic threshold as described in claim 1, characterized in that, The historical dialogue voice data includes several voice segment data, each voice segment data consists of voice data generated by a single speaker within a continuous time period; the set of all first speaker tags includes at least all second speaker tags.

3. The voiceprint recognition method based on a historical dialogue voiceprint database and dynamic threshold as described in claim 1, characterized in that, The calculation process for the second similarity sequence of one of the second speaker tags is as follows: S hist ={sim(V current ,V i )}; Among them, S hist V represents the second similarity sequence of one of the second speaker labels. current This represents the current voiceprint features, sim represents the similarity calculation function, and DVC represents the similarity calculation function. confirmed V represents the set of speaker voiceprint features for all speech segments corresponding to one of the second speaker tags in the historical dialogue voiceprint database. i ∈DVC confirmed V i The speaker voiceprint feature represents the speaker voiceprint feature of the i-th speech segment in the set of speaker voiceprint features of all speech segment data corresponding to one of the second speaker tags in the historical dialogue voiceprint database. The calculation process for the historical consistency score of one of the second speaker labels is as follows: S consistency =mean(S hist ); Where mean represents the average of the elements in the set, S consistency This represents the historical consistency score of one of the second speaker labels.

4. The voiceprint recognition method based on a historical dialogue voiceprint database and dynamic threshold as described in claim 3, characterized in that, In the case where the second speaker label matches the first speaker label, the voiceprint score is calculated as follows: S final =(S reg + N(S hist )* S consistency ) / ( N(S hist )+1); Among them, S final S represents the voiceprint score. reg N(S) represents the first similarity in the first similarity sequence. hist ) represents the total number of elements in the second similarity sequence of one of the second speaker labels.

5. The voiceprint recognition method based on a historical dialogue voiceprint database and dynamic threshold as described in claim 1, characterized in that, The dynamic threshold is determined based on the speech duration and environmental signal-to-noise ratio of the current speech segment data, specifically including: Establish the first mapping relationship between different duration threshold ranges and their corresponding speech duration factors; Establish a second mapping relationship between different signal-to-noise ratio threshold ranges and their corresponding environmental stability factors; The speech duration of the current speech segment data is compared with different duration threshold ranges to determine the duration threshold range in which the current speech segment data is located, and the value of the corresponding speech duration factor is determined according to the first mapping relationship. The environmental signal-to-noise ratio of the current speech segment data is compared with different signal-to-noise ratio threshold ranges to determine the signal-to-noise ratio threshold range in which the current speech segment data is located, and the corresponding environmental stability factor value is determined according to the second mapping relationship. The dynamic threshold is obtained by multiplying the base threshold by the values ​​of the speech duration factor corresponding to the speech duration of the current speech segment data and the environmental stability factor.

6. The voiceprint recognition method based on a historical dialogue voiceprint database and dynamic threshold as described in claim 1, characterized in that, Also includes: In response to determining that there is no historical dialogue speech data before the current speech segment data, the first similarity in the first similarity sequence is used as the voiceprint score; In cases where the second speaker label is inconsistent with the first speaker label, the first similarity corresponding to the first speaker label that is inconsistent with the second speaker label in the first similarity sequence is taken as the voiceprint score; The identity of the current speaker is used as a second speaker tag and stored in the historical dialogue voiceprint database along with the voiceprint features of the current speech segment data. At preset intervals, the voiceprint features in the registered voiceprint database are soft-updated using an exponentially weighted moving average method based on the voiceprint score.

7. A voiceprint recognition device based on a historical dialogue voiceprint database and dynamic thresholds, characterized in that, include: The registered voiceprint database construction module is configured to construct a registered voiceprint database, which stores different first speaker tags and their corresponding registered voiceprint features. The voiceprint extraction module is configured to acquire the current speech segment data emitted by the current speaker during a voice dialogue, and to perform preprocessing and voiceprint feature extraction to obtain the current voiceprint features. Calculate the similarity between the current voiceprint feature and each registered voiceprint feature in the registered voiceprint database to obtain the first similarity sequence; The voiceprint score calculation module is configured to, in response to determining that historical dialogue voice data exists before the current voice segment data, acquire a historical dialogue voiceprint database constructed based on the historical dialogue voice data. The historical dialogue voiceprint database stores the speaker voiceprint features corresponding to each voice segment data in the historical dialogue voice data and its corresponding second speaker label. Assuming that the identity of the current voiceprint feature is consistent with the second speaker label, the module calculates the similarity between the current voiceprint feature and the speaker voiceprint features of each voice segment data corresponding to the second speaker label in the historical dialogue voiceprint database, obtaining a second similarity sequence for the corresponding second speaker label. Based on the second similarity sequence for the corresponding second speaker label, the module calculates the historical consistency score for the corresponding second speaker label. For cases where the second speaker label is consistent with the first speaker label, the module calculates the voiceprint score based on the first similarity corresponding to the first speaker label consistent with the second speaker label in the first similarity sequence, the second similarity sequence for the corresponding second speaker label, and the historical consistency score. The comparison module is configured to determine a dynamic threshold based on the speech duration and environmental signal-to-noise ratio of the current speech segment data; compare all voiceprint scores with the dynamic threshold, and determine the identity of the current speaker based on the comparison result.

8. An electronic device, comprising: One or more processors; A storage device for storing one or more programs, characterized in that, when the one or more programs are executed by the one or more processors, the one or more processors implement the method as described in any one of claims 1-6.

9. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the program is executed by the processor, it implements the method as described in any one of claims 1-6.

10. A computer program product, comprising a computer program, characterized in that, When the computer program is executed by a processor, it implements the method as described in any one of claims 1-6.