Bluetooth earphone speech recognition method and system based on natural language processing
By combining the DTW-ECAPA-Transformer model and knowledge graph, the accuracy and robustness of voice recognition in Bluetooth headsets under complex environments are solved, achieving accurate semantic understanding and intent recognition, and adapting to diverse usage scenarios.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- SHENZHEN ASMAX INFINITE TECH CO LTD
- Filing Date
- 2026-01-20
- Publication Date
- 2026-04-17
AI Technical Summary
Bluetooth headsets struggle to balance voice recognition accuracy and robustness in complex environments. Traditional models are ill-suited to various noise scenarios and lack effective semantic understanding and contextual association mechanisms, making it impossible to accurately identify the user's deeper intentions.
The DTW-ECAPA-Transformer model is used to extract local time-frequency features by combining a lightweight front-end convolutional module and a Transformer module. The DTW algorithm is used for short-term alignment and to capture long-term global dependencies. The knowledge graph and context memory module are combined to perform semantic understanding and intent recognition.
It significantly improves the accuracy and robustness of voice recognition in Bluetooth headsets in complex environments, adapts to diverse usage scenarios, and achieves integrated optimization from signal preprocessing to intent response.
Smart Images

Figure CN121545507B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of speech recognition technology, and specifically to a Bluetooth headset speech recognition method and system based on natural language processing. Background Technology
[0002] With the widespread adoption of Bluetooth headsets, voice interaction has become a core application scenario, encompassing diverse needs such as command control, language assistance, and intelligent interaction. Bluetooth headsets are often in complex environments such as commuting and outdoors, where voice signals are easily affected by traffic noise and human voice interference. Traditional preprocessing solutions only employ single noise suppression methods, making it difficult to adapt to various noise scenarios, resulting in low feature extraction accuracy. Limited by the low computing power and low power consumption of headsets, traditional models are difficult to deploy directly. Furthermore, traditional models suffer from insufficient local feature extraction and inadequate long-term dependency capture, making it difficult to balance speech recognition accuracy and robustness. Existing technologies often lack effective semantic understanding and contextual association mechanisms, remaining only at the speech transcription level, failing to accurately identify users' deeper intentions, and exhibiting poor adaptability to multi-turn interactions. Therefore, there is an urgent need for a Bluetooth headset speech recognition solution based on natural language processing. Summary of the Invention
[0003] The purpose of this invention is to solve the above-mentioned problems by designing a Bluetooth headset voice recognition method and system based on natural language processing.
[0004] The first aspect of this invention provides a Bluetooth headset voice recognition method based on natural language processing, the method comprising the following steps:
[0005] By extracting the feature vector of the voice signal collected from the Bluetooth headset;
[0006] The feature vector is input into the DTW-ECAPA-Transformer model. Local time-frequency features are extracted through a lightweight front-end convolution module. The short-term speech frames are aligned with the standard template using the DTW algorithm. The long-term global dependencies are then captured through the lightweight Transformer module, and the fused features are output.
[0007] Based on the fusion features, semantic understanding and intent recognition are performed on the fusion features through knowledge graph and context memory modules;
[0008] The process is executed locally based on the intent recognition results, and the results are fed back via voice prompts.
[0009] Optionally, in a first implementation of the first aspect of the present invention, the step of extracting the feature vector of the voice signal collected by the Bluetooth headset includes:
[0010] The pre-emphasis process is completed by subtracting the product of the pre-emphasis coefficient and the previous sampling point value from the current sampling point value of each frame of speech signal.
[0011] According to the preset frame length and frame shift parameters, the continuous speech signal is cut into overlapping short time segments. A Hanning window is applied to each short time segment for smooth weighting. The signal within the frame is processed point by point through the window function.
[0012] The silence segment in the speech signal is located by short-time energy and zero-crossing rate analysis, and the spectrum of the silence segment is statistically analyzed.
[0013] A noise spectrum model is constructed using a Gaussian mixture model to dynamically track the energy and spectral distribution of noise. After frequency domain transformation of each frame of speech signal using spectral subtraction, the noise spectrum estimated based on the noise spectrum model is subtracted from the speech spectrum to complete the joint noise suppression process.
[0014] Multi-dimensional feature extraction and standardization are performed on the speech signal after pre-emphasis, framing, and joint noise suppression to generate feature vectors.
[0015] Optionally, in a second implementation of the first aspect of the present invention, the step of performing multi-dimensional feature extraction and standardization on the speech signal after pre-emphasis, framing, and joint noise suppression processing to generate a feature vector includes:
[0016] The time-domain signal is transformed into a frequency-domain spectrum through discrete Fourier transform, and then the energy of different frequency bands is collected by Mel filter bank and mapped to the Mel frequency scale to extract FBank features.
[0017] MFCC features are obtained by processing the Mel spectrum using discrete cosine transform.
[0018] The YIN algorithm is used to estimate the pitch period, and the short-time energy is calculated by normalizing the sum of squares of intra-frame sampling points to extract prosodic features.
[0019] The DTW inter-frame distance is calculated as an alignment auxiliary feature. The Euclidean distance between the FBank features, MFCC prosodic features and the preset standard template frame of each frame is standardized to form a multi-dimensional feature set.
[0020] The mean and standard deviation of each feature dimension in the multi-dimensional feature set are calculated. For the value of each dimension in the feature vector of each frame being processed, the mean of the corresponding dimension is subtracted and then divided by the standard deviation of the corresponding dimension. All feature dimensions are uniformly mapped to a standard normal distribution with a mean of 0 and a variance of 1 to generate a feature vector.
[0021] Optionally, in the third implementation of the first aspect of the present invention, the step of inputting the feature vector into the DTW-ECAPA-Transformer model, extracting local time-frequency features through a lightweight front-end convolutional module, aligning short-time speech frames with a standard template using the DTW algorithm, and then capturing long-term global dependencies through a lightweight Transformer module to output fused features includes:
[0022] The lightweight front-end convolutional module first expands the number of channels of the input feature vector from 1 to 16 through an initial convolutional layer, and then inputs two lightweight residual blocks. Each residual block uses a 3×3 convolutional kernel. The frequency dimension is gradually compressed through two downsampling steps. Through a 3×3 convolutional layer, the time step is compressed to 1 / 8 of the original input, and the local time-frequency features are output.
[0023] For each segment of local time-frequency features, DTW matching is performed with the corresponding template in the preset template library. The Viterbi pruning algorithm is used to optimize the optimal regular path search process, complete the alignment process, and record the positions where the inter-frame distance is greater than the set threshold to generate a deviation mask and a deviation degree vector.
[0024] The aligned local time-frequency features, along with the bias mask and the bias degree vector, are simultaneously input into a 4-layer Transformer encoder, where each encoder layer contains a 4-head self-attention mechanism and a 1024-dimensional feedforward neural network.
[0025] In the multi-head self-attention computation process, the injected bias mask and bias degree vector are used as constraints to enhance the attention weights corresponding to the bias regions, capture bias features, and finally output fused features that integrate local features and global dependencies.
[0026] Optionally, in the fourth implementation of the first aspect of the present invention, the step of performing DTW matching on each segment of the local time-frequency features with the corresponding template in the preset template library, optimizing the optimal regularization path search process using the Viterbi pruning algorithm, completing the alignment process, and recording positions where the inter-frame distance is greater than a set threshold, and generating a deviation mask and a deviation degree vector, includes:
[0027] A template library was generated by K-means clustering of standard pronunciation samples from 100 speakers of different genders and ages.
[0028] Obtain the frame number and feature dimension of the local time-frequency feature segment to be processed. Use the Euclidean distance calculation method to calculate the distance between each frame in the local time-frequency feature segment and each frame in the standard template, and construct a cost matrix. The value of each element in the cost matrix represents the similarity between the corresponding two frames.
[0029] Set an initial value for the cumulative path distance, using the starting element of the cost matrix as the initial cumulative distance;
[0030] Based on the numerical distribution of the cost matrix, a pruning threshold is set, and a path record container is created to store the effective paths and their corresponding cumulative distances.
[0031] Calculate the cumulative distance between the current frame and all frames of the template, retain paths whose cumulative distance is less than the pruning threshold, and update the path recording container in real time during the processing.
[0032] After processing the last frame of the feature segment, the path with the smallest cumulative distance is selected from the path recording container to obtain the optimal regular path.
[0033] Optionally, in a fifth implementation of the first aspect of the present invention, generating a deviation mask and a deviation degree vector at positions where the inter-frame distance is greater than a set threshold includes:
[0034] The mean and standard deviation of all inter-frame distances on the optimal regularized path are calculated, and the mean and 1.2 times the standard deviation are used as the inter-frame distance threshold.
[0035] Along the optimal regular path, check the inter-frame distance of each frame pair one by one. If the distance of a frame pair is greater than the set inter-frame distance threshold, it is determined that there is a pronunciation deviation at that position. Record the segment frame position corresponding to the current frame pair to form a deviation position list.
[0036] Create a binary vector with the same length as the number of frames in the local time-frequency feature segment. For the frame positions in the deviation position list, mark the corresponding position of the mask vector as 1 and the non-deviation positions as 0.
[0037] For each frame position in the deviation position list, calculate the ratio of the inter-frame distance to the set inter-frame distance threshold, and use it as a quantification value of the deviation degree;
[0038] For non-deviation positions, the deviation degree quantization value is set to 0, and the deviation degree quantization values of all frame positions are combined in sequence to form a deviation degree vector.
[0039] Optionally, in a sixth implementation of the first aspect of the present invention, the step of performing semantic understanding and intent recognition on the fused features based on the fused features through a knowledge graph and context memory module includes:
[0040] A knowledge graph covering Bluetooth headset voice interaction scenarios is pre-built, which includes entities, entity relationships, and intent tags;
[0041] Create a circular buffer as a context memory carrier, and set the buffer capacity to store the interaction data of the last 5 rounds;
[0042] The fused features output by the DTW-ECAPA-Transformer model are transformed into structured semantic vectors;
[0043] The cosine similarity calculation method is used to calculate the similarity between the semantic vector and all entity vectors in the knowledge graph, and the set of entities with similarity higher than a set threshold is selected.
[0044] Traverse the entity set to construct relation combinations, calculate the similarity between the semantic vector and the semantic pattern vector corresponding to each relation combination, and determine the most matching entity relation combination;
[0045] Retrieve historical interaction data stored in the context memory module, extract the semantic vector and intent label of the historical interaction, calculate the correlation between the current semantic vector and the historical semantic vector, determine whether the current voice request is related to the historical intent, and if there is a correlation, integrate the historical context information to supplement the current semantic understanding.
[0046] By combining entity relationship combinations obtained from knowledge graph matching with contextual association analysis results, the user's intent is determined, the intent tag that best fits the current semantics is selected, and the final intent recognition result is output.
[0047] A second aspect of the present invention provides a Bluetooth headset voice recognition system based on natural language processing, the system comprising:
[0048] The voice processing module is used to extract feature vectors from the voice signals collected by the Bluetooth headset;
[0049] The feature capture module is used to input feature vectors into the DTW-ECAPA-Transformer model, extract local time-frequency features through a lightweight front-end convolution module, align short-time speech frames with standard templates using the DTW algorithm, and then capture long-term global dependencies through a lightweight Transformer module to output fused features.
[0050] The intent recognition module is used to perform semantic understanding and intent recognition on the fused features based on the fused features, through the knowledge graph and context memory module;
[0051] The local execution module is used to perform local execution based on the intent recognition results and provide feedback on the results through voice prompts.
[0052] A third aspect of the present invention provides a Bluetooth headset voice recognition device based on natural language processing, the Bluetooth headset voice recognition device based on natural language processing including a memory and at least one processor, the memory storing instructions; the at least one processor calling the instructions in the memory to cause the Bluetooth headset voice recognition device based on natural language processing to perform the various steps of the Bluetooth headset voice recognition method based on natural language processing as described in any of the preceding claims.
[0053] A fourth aspect of the present invention provides a computer-readable storage medium storing instructions that, when executed by a processor, implement the steps of the Bluetooth headset voice recognition method based on natural language processing as described in any of the preceding claims.
[0054] The technical solution provided by this invention extracts feature vectors from the speech signals collected by Bluetooth headsets; inputs the feature vectors into the DTW-ECAPA-Transformer model, extracts local time-frequency features through a lightweight front-end convolution module, aligns short-time speech frames with standard templates using the DTW algorithm, and then captures long-term global dependencies through a lightweight Transformer module to output fused features; based on the fused features, semantic understanding and intent recognition are performed through a knowledge graph and context memory module; local execution is performed according to the intent recognition results, and the results are fed back through voice prompts; this invention preprocesses the speech signals through multiple steps such as pre-emphasis, frame segmentation, and joint noise suppression. The system combines multi-dimensional feature extraction and standardization to significantly improve the robustness of speech features in complex environments. The DTW-ECAPA-Transformer model features a lightweight design, accurately extracting local time-frequency features through the front-end convolutional module, achieving short-term alignment through the DTW algorithm, and capturing long-term dependencies through the Transformer module, balancing low-computing-power adaptability with recognition accuracy. The introduction of knowledge graph and context memory modules enhances the depth of semantic understanding and the accuracy of intent recognition, accurately associating users' multi-turn interaction needs. It achieves integrated optimization from signal preprocessing to intent response, significantly improving the practicality and convenience of Bluetooth headset voice recognition and adapting to diverse usage scenarios. Attached Figure Description
[0055] Various other advantages and benefits will become apparent to those skilled in the art upon reading the following detailed description of preferred embodiments. The accompanying drawings are for illustrative purposes only and are not intended to limit the invention.
[0056] Figure 1 A flowchart illustrating a Bluetooth headset voice recognition method based on natural language processing provided in an embodiment of the present invention;
[0057] Figure 2 This is a schematic diagram of the structure of a Bluetooth headset voice recognition system based on natural language processing provided in an embodiment of the present invention;
[0058] Figure 3 This is a schematic diagram of the structure of a Bluetooth headset voice recognition device based on natural language processing, provided in an embodiment of the present invention. Detailed Implementation
[0059] The terms "first," "second," "third," "fourth," etc. (if present) in the specification, claims, and accompanying drawings of this invention are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments described herein can be implemented in orders other than those illustrated or described herein. Furthermore, the terms "comprising" or "having" and any variations thereof are intended to cover a non-exclusive inclusion; for example, a process, method, apparatus, product, or device that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or devices.
[0060] For ease of understanding, the specific process of the embodiments of the present invention is described below. Please refer to [link / reference]. Figure 1 A flowchart of a Bluetooth headset voice recognition method based on natural language processing provided in this embodiment of the invention is shown. The method specifically includes the following steps:
[0061] Step 101: Extract the feature vector of the voice signal collected by the Bluetooth headset;
[0062] In this embodiment, the pre-emphasis processing is completed by subtracting the product of the pre-emphasis coefficient and the previous sampling point value from the current sampling point value of each frame of speech signal; according to the preset frame length and frame shift parameters, the continuous speech signal is cut into overlapping short-time segments, and a Hanning window is applied to each short-time segment for smooth weighting, and the signal within the frame is processed point by point through the window function; the silence segment in the speech signal is located by short-time energy and zero-crossing rate analysis, and the spectrum of the silence segment is statistically analyzed; a noise spectrum model is constructed using a Gaussian mixture model to dynamically track the energy and spectrum distribution of noise, and after frequency domain transformation of each frame of speech signal using spectral subtraction, the noise spectrum estimated based on the noise spectrum model is subtracted from the speech spectrum to complete the joint noise suppression processing; multi-dimensional feature extraction and standardization are performed on the speech signal after pre-emphasis, framing, and joint noise suppression processing to generate feature vectors.
[0063] In this embodiment, the time-domain signal is converted into a frequency-domain spectrum through Discrete Fourier Transform (DFT), and then the energy of different frequency bands is collected by the Mel filter bank and mapped to the Mel frequency scale to extract FBank features. After processing the Mel spectrum through Discrete Cosine Transform (DCT), MFCC features are obtained. The pitch period is estimated using the YIN algorithm, and the short-time energy is calculated by normalizing the sum of squares of intra-frame sampling points to extract prosodic features. The DTW inter-frame distance is calculated as an alignment auxiliary feature. The Euclidean distance between the FBank features, MFCC features, prosodic features, and the preset standard template frame of each frame is standardized to form a multi-dimensional feature set. The mean and standard deviation of each feature dimension in the multi-dimensional feature set are calculated. For the value of each dimension in the feature vector of each frame being processed, the mean of the corresponding dimension is subtracted and then divided by the standard deviation of the corresponding dimension. All feature dimensions are uniformly mapped to a standard normal distribution with a mean of 0 and a variance of 1 to generate a feature vector.
[0064] Step 102: Input the feature vector into the DTW-ECAPA-Transformer model, extract local time-frequency features through the lightweight front-end convolution module, align short-time speech frames with the standard template through the DTW algorithm, and then capture long-term global dependencies through the lightweight Transformer module to output fused features.
[0065] In this embodiment, the lightweight front-end convolutional module first expands the number of channels of the input feature vector from 1 to 16 through an initial convolutional layer, and then inputs two lightweight residual blocks. Each residual block uses a 3×3 convolutional kernel. The frequency dimension is gradually compressed through two downsampling steps. Through a 3×3 convolutional layer, the time step is compressed to 1 / 8 of the original input, and the local time-frequency features are output. Each segment of the local time-frequency features is matched with the corresponding template in the preset template library using DTW matching. The Viterbi pruning algorithm is used to optimize the optimal regularization path search process, complete the alignment process, and record the positions where the inter-frame distance is greater than a set threshold, generating a deviation mask and a deviation degree vector. The aligned local time-frequency features, deviation mask, and deviation degree vector are simultaneously input into a 4-layer Transformer encoder, where each encoder layer contains a 4-head self-attention mechanism and a 1024-dimensional feedforward neural network. During the multi-head self-attention calculation process, the deviation mask and deviation degree vector are injected as constraints to enhance the attention weights corresponding to the deviation regions, capture deviation features, and finally output a fused feature that integrates local features and global dependencies.
[0066] In this embodiment, a template library is generated from standard pronunciation samples of 100 speakers of different genders and ages using K-means clustering. The frame number and feature dimension of the local time-frequency feature segment to be processed are obtained. The Euclidean distance calculation method is used to calculate the distance between each frame in the local time-frequency feature segment and each frame in the standard template, constructing a cost matrix. The value of each element in the cost matrix represents the similarity between the corresponding two frames. An initial value for the cumulative path distance is set, using the starting element of the cost matrix as the initial cumulative distance. Based on the numerical distribution of the cost matrix, a pruning threshold is set, and a path recording container is created to store valid paths and their corresponding cumulative distances. The cumulative distance between the current frame and each frame of the template is calculated, and paths with a cumulative distance less than the pruning threshold are retained. The path recording container is updated in real time during processing. After processing the last frame of the feature segment, the path with the smallest cumulative distance is selected from the path recording container to obtain the optimal regularized path.
[0067] In this embodiment, the mean and standard deviation of all inter-frame distances along the optimal regularization path are statistically analyzed, and the mean and 1.2 times the standard deviation are used as the inter-frame distance threshold. Along the optimal regularization path, the inter-frame distance of each frame pair is checked one by one. If the distance of a frame pair is greater than the set inter-frame distance threshold, it is determined that there is a pronunciation deviation at that position. The segment frame position corresponding to the current frame pair is recorded to form a deviation position list. A binary vector with the same length as the number of frames of the local time-frequency feature segment is created. For frame positions in the deviation position list, the corresponding position of the mask vector is marked as 1, and non-deviation positions are marked as 0. For each frame position in the deviation position list, the ratio of the inter-frame distance to the set inter-frame distance threshold is calculated as the deviation degree quantization value. For non-deviation positions, the deviation degree quantization value is set to 0. The deviation degree quantization values of all frame positions are combined sequentially to form a deviation degree vector.
[0068] Step 103: Based on the fusion features, semantic understanding and intent recognition are performed on the fusion features through the knowledge graph and context memory module;
[0069] In this embodiment, a knowledge graph covering Bluetooth headset voice interaction scenarios is pre-constructed, including entities, entity relationships, and intent tags. A circular buffer is created as a context memory carrier, with a buffer capacity set to store the most recent 5 rounds of interaction data. The fusion features output by the DTW-ECAPA-Transformer model are transformed into structured semantic vectors. Using the cosine similarity calculation method, the semantic vectors are compared with all entity vectors in the knowledge graph, and a set of entities with similarity higher than a set threshold is selected. Relationship combinations are constructed by traversing the entity set, and the similarity between the semantic vectors and the semantic pattern vectors corresponding to each relationship combination is calculated to determine the most matching entity relationship combination. Historical interaction data stored in the context memory module is retrieved, and the semantic vectors and intent tags of historical interactions are extracted. The correlation between the current semantic vector and the historical semantic vector is calculated to determine whether the current voice request is related to the historical intent. If a correlation exists, historical context information is integrated to supplement the current semantic understanding. Combining the entity relationship combination obtained from the knowledge graph matching with the context association analysis results, the user intent is determined, the intent tag that best fits the current semantics is selected, and the final intent recognition result is output.
[0070] Step 104: Perform local execution based on the intent recognition results and provide feedback on the results via voice prompts.
[0071] Please see Figure 2 A schematic diagram of the structure of a Bluetooth headset voice recognition system based on natural language processing provided in this embodiment of the invention. The system includes:
[0072] The voice processing module is used to extract feature vectors from the voice signals collected by the Bluetooth headset;
[0073] The feature capture module is used to input feature vectors into the DTW-ECAPA-Transformer model, extract local time-frequency features through a lightweight front-end convolution module, align short-time speech frames with standard templates using the DTW algorithm, and then capture long-term global dependencies through a lightweight Transformer module to output fused features.
[0074] The intent recognition module is used to perform semantic understanding and intent recognition on the fused features based on the fused features, through the knowledge graph and context memory module;
[0075] The local execution module is used to perform local execution based on the intent recognition results and provide feedback on the results through voice prompts.
[0076] Figure 3This is a schematic diagram of the structure of a Bluetooth headset voice recognition device based on natural language processing (NLP) according to an embodiment of the present invention. The NLP-based Bluetooth headset voice recognition device 300 can vary significantly due to different configurations or performance. It may include one or more central processing units (CPUs) 310 (e.g., one or more processors) and a memory 320, and one or more storage media 330 (e.g., one or more mass storage devices) for storing application programs 333 or data 332. The memory 320 and storage media 330 can be temporary or persistent storage. The program stored in the storage media 330 may include one or more modules (not shown in the diagram), each module including a series of instruction operations on the NLP-based Bluetooth headset voice recognition device 300. Furthermore, the processor 310 may be configured to communicate with the storage media 330 and execute the series of instruction operations in the storage media 330 on the NLP-based Bluetooth headset voice recognition device 300 to implement the method provided in the above embodiment.
[0077] The Bluetooth headset voice recognition device 300 based on natural language processing may also include one or more power supplies 340, one or more wired or wireless network interfaces 350, one or more input / output interfaces 360, and / or one or more operating systems 331, such as Windows Server, Mac OS X, Unix, Linux, FreeBSD, etc. Those skilled in the art will understand that... Figure 3 The structure of the Bluetooth headset voice recognition device based on natural language processing shown does not constitute a limitation on the computer device provided by the present invention. It may include more or fewer components than shown, or combine certain components, or have different component arrangements.
[0078] The present invention also provides a computer-readable storage medium, which can be a non-volatile computer-readable storage medium or a volatile computer-readable storage medium, wherein the computer-readable storage medium stores instructions that, when the instructions are executed on a computer, cause the computer to perform the various steps of the Bluetooth headset voice recognition method based on natural language processing provided in the above embodiments.
[0079] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the specific working process of the above-described equipment or apparatus / unit can be referred to the corresponding process in the foregoing method embodiments, and will not be repeated here.
[0080] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of the present invention. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.
[0081] The foregoing has shown and described the basic principles, main features, and advantages of the present invention. Those skilled in the art should understand that the present invention is not limited to the above embodiments. The embodiments and descriptions in the specification are merely preferred examples and are not intended to limit the invention. Various changes and modifications can be made to the invention without departing from its spirit and scope, and all such changes and modifications fall within the scope of the present invention as claimed. The scope of protection of the present invention is defined by the appended technical solutions and their equivalents.
Claims
1. A Bluetooth headset voice recognition method based on natural language processing, characterized in that, The method includes the following steps: Extract the feature vector of the voice signal collected by the Bluetooth headset; The feature vector is input into the DTW-ECAPA-Transformer model. Local time-frequency features are extracted through a lightweight front-end convolution module. The short-term speech frames are aligned with the standard template using the DTW algorithm. The long-term global dependencies are then captured through the lightweight Transformer module, and the fused features are output. Based on the fusion features, semantic understanding and intent recognition are performed on the fusion features through knowledge graph and context memory modules; The execution is performed locally based on the intent recognition results, and the results are fed back through voice prompts. The process involves inputting feature vectors into the DTW-ECAPA-Transformer model, extracting local time-frequency features through a lightweight front-end convolutional module, aligning short-term speech frames with standard templates using the DTW algorithm, and then capturing long-term global dependencies through a lightweight Transformer module to output fused features. This includes: the lightweight front-end convolutional module first expands the number of channels in the input feature vector from 1 to 16 using an initial convolutional layer, then inputs two lightweight residual blocks, each using a 3×3 convolutional kernel. The frequency dimension is gradually compressed through two downsampling operations, and the time step is compressed to 1 / 8 of the original input using a 3×3 convolutional layer, outputting local time-frequency features; each segment of the local time-frequency features is matched with the corresponding template in a preset template library using DTW, and the Viterbi pruning algorithm is used to optimize the optimal regularization path search process to complete the alignment process. Positions where the inter-frame distance is greater than a set threshold are recorded, generating a deviation mask and a deviation degree vector. The aligned local time-frequency features, along with the bias mask and the bias degree vector, are simultaneously input into a 4-layer Transformer encoder, where each encoder layer contains a 4-head self-attention mechanism and a 1024-dimensional feedforward neural network. In the multi-head self-attention computation process, the injected bias mask and bias degree vector are used as constraints to enhance the attention weights corresponding to the bias regions, capture bias features, and finally output the fused features that integrate local features and global dependencies.
2. The Bluetooth headset voice recognition method based on natural language processing as described in claim 1, characterized in that, The extraction of feature vectors from the voice signals collected by the Bluetooth headset includes: The pre-emphasis process is completed by subtracting the product of the pre-emphasis coefficient and the previous sampling point value from the current sampling point value of each frame of speech signal. According to the preset frame length and frame shift parameters, the continuous speech signal is cut into overlapping short time segments. A Hanning window is applied to each short time segment for smooth weighting. The signal within the frame is processed point by point through the window function. The silence segment in the speech signal is located by short-time energy and zero-crossing rate analysis, and the spectrum of the silence segment is statistically analyzed. A noise spectrum model is constructed using a Gaussian mixture model to dynamically track the energy and spectral distribution of noise. After frequency domain transformation of each frame of speech signal using spectral subtraction, the noise spectrum estimated based on the noise spectrum model is subtracted from the speech spectrum to complete the joint noise suppression process. Multi-dimensional feature extraction and standardization are performed on the speech signal after pre-emphasis, framing, and joint noise suppression to generate feature vectors.
3. The Bluetooth headset voice recognition method based on natural language processing as described in claim 2, characterized in that, The process of extracting and standardizing multi-dimensional features from the speech signal after pre-emphasis, framing, and joint noise suppression to generate a feature vector includes: The time-domain signal is transformed into a frequency-domain spectrum through discrete Fourier transform, and then the energy of different frequency bands is collected by Mel filter bank and mapped to the Mel frequency scale to extract FBank features. MFCC features are obtained by processing the Mel spectrum using discrete cosine transform. The YIN algorithm is used to estimate the pitch period, and the short-time energy is calculated by normalizing the sum of squares of intra-frame sampling points to extract prosodic features. The DTW inter-frame distance is calculated as an alignment auxiliary feature. The Euclidean distance between the FBank features, MFCC prosodic features and the preset standard template frame of each frame is standardized to form a multi-dimensional feature set. The mean and standard deviation of each feature dimension in the multi-dimensional feature set are calculated. For the value of each dimension in the feature vector of each frame being processed, the mean of the corresponding dimension is subtracted and then divided by the standard deviation of the corresponding dimension. All feature dimensions are uniformly mapped to a standard normal distribution with a mean of 0 and a variance of 1 to generate a feature vector.
4. The Bluetooth headset voice recognition method based on natural language processing as described in claim 1, characterized in that, The process involves performing DTW matching on each segment of the local time-frequency features and the corresponding template in the preset template library, using the Viterbi pruning algorithm to optimize the optimal regularization path search process, completing the alignment process, recording positions where the inter-frame distance is greater than a set threshold, and generating a deviation mask and a deviation degree vector, including: A template library was generated by K-means clustering of standard pronunciation samples from 100 speakers of different genders and ages. Obtain the frame number and feature dimension of the local time-frequency feature segment to be processed. Use the Euclidean distance calculation method to calculate the distance between each frame in the local time-frequency feature segment and each frame in the standard template, and construct a cost matrix. The value of each element in the cost matrix represents the similarity between the corresponding two frames. Set an initial value for the cumulative path distance, using the starting element of the cost matrix as the initial cumulative distance; Based on the numerical distribution of the cost matrix, a pruning threshold is set, and a path record container is created to store the effective paths and their corresponding cumulative distances. Calculate the cumulative distance between the current frame and all frames of the template, retain paths whose cumulative distance is less than the pruning threshold, and update the path recording container in real time during the processing. After processing the last frame of the feature segment, the path with the smallest cumulative distance is selected from the path recording container to obtain the optimal regular path.
5. The Bluetooth headset voice recognition method based on natural language processing as described in claim 4, characterized in that, For positions where the inter-frame distance is greater than a set threshold, an offset mask and an offset degree vector are generated, including: The mean and standard deviation of all inter-frame distances on the optimal regularized path are calculated, and the mean and 1.2 times the standard deviation are used as the inter-frame distance threshold. Along the optimal regular path, check the inter-frame distance of each frame pair one by one. If the distance of a frame pair is greater than the set inter-frame distance threshold, it is determined that there is a pronunciation deviation at that position. Record the segment frame position corresponding to the current frame pair to form a deviation position list. Create a binary vector with the same length as the number of frames in the local time-frequency feature segment. For the frame positions in the deviation position list, mark the corresponding position of the mask vector as 1 and the non-deviation positions as 0. For each frame position in the deviation position list, calculate the ratio of the inter-frame distance to the set inter-frame distance threshold, and use it as a quantification value of the deviation degree; For non-deviation positions, the deviation degree quantization value is set to 0, and the deviation degree quantization values of all frame positions are combined in sequence to form a deviation degree vector.
6. The Bluetooth headset voice recognition method based on natural language processing as described in claim 1, characterized in that, The method based on fusion features, through knowledge graphs and contextual memory modules, performs semantic understanding and intent recognition on the fusion features, including: A knowledge graph covering Bluetooth headset voice interaction scenarios is pre-built, which includes entities, entity relationships, and intent tags; Create a circular buffer as a context memory carrier, and set the buffer capacity to store the interaction data of the last 5 rounds; The fused features output by the DTW-ECAPA-Transformer model are transformed into structured semantic vectors; The cosine similarity calculation method is used to calculate the similarity between the semantic vector and all entity vectors in the knowledge graph, and the set of entities with similarity higher than a set threshold is selected. Traverse the entity set to construct relation combinations, calculate the similarity between the semantic vector and the semantic pattern vector corresponding to each relation combination, and determine the most matching entity relation combination; Retrieve historical interaction data stored in the context memory module, extract the semantic vector and intent label of the historical interaction, calculate the correlation between the current semantic vector and the historical semantic vector, determine whether the current voice request is related to the historical intent, and if there is a correlation, integrate the historical context information to supplement the current semantic understanding. By combining entity relationship combinations obtained from knowledge graph matching with contextual association analysis results, the user's intent is determined, the intent tag that best fits the current semantics is selected, and the final intent recognition result is output.
7. A Bluetooth headset voice recognition system based on natural language processing, characterized in that, The system includes: The voice processing module is used to extract feature vectors from the voice signals collected by the Bluetooth headset; The feature capture module is used to input feature vectors into the DTW-ECAPA-Transformer model, extract local time-frequency features through a lightweight front-end convolution module, align short-time speech frames with standard templates using the DTW algorithm, and then capture long-term global dependencies through a lightweight Transformer module to output fused features. The intent recognition module is used to perform semantic understanding and intent recognition on the fused features based on the fused features, through the knowledge graph and context memory module; The local execution module is used to perform local execution based on the intent recognition results and provide feedback on the results through voice prompts; The process involves inputting feature vectors into the DTW-ECAPA-Transformer model, extracting local time-frequency features through a lightweight front-end convolutional module, aligning short-term speech frames with standard templates using the DTW algorithm, and then capturing long-term global dependencies through a lightweight Transformer module to output fused features. This includes: the lightweight front-end convolutional module first expands the number of channels in the input feature vector from 1 to 16 using an initial convolutional layer, then inputs two lightweight residual blocks, each using a 3×3 convolutional kernel. The frequency dimension is gradually compressed through two downsampling operations, and the time step is compressed to 1 / 8 of the original input using a 3×3 convolutional layer, outputting local time-frequency features; each segment of the local time-frequency features is matched with the corresponding template in a preset template library using DTW, and the Viterbi pruning algorithm is used to optimize the optimal regularization path search process to complete the alignment process. Positions where the inter-frame distance is greater than a set threshold are recorded, generating a deviation mask and a deviation degree vector. The aligned local time-frequency features, along with the bias mask and the bias degree vector, are simultaneously input into a 4-layer Transformer encoder, where each encoder layer contains a 4-head self-attention mechanism and a 1024-dimensional feedforward neural network. In the multi-head self-attention computation process, the injected bias mask and bias degree vector are used as constraints to enhance the attention weights corresponding to the bias regions, capture bias features, and finally output the fused features that integrate local features and global dependencies.
8. A Bluetooth headset voice recognition device based on natural language processing, characterized in that, The Bluetooth headset voice recognition device based on natural language processing includes a memory and at least one processor, wherein the memory stores instructions; the at least one processor invokes the instructions in the memory to cause the Bluetooth headset voice recognition device based on natural language processing to perform the various steps of the Bluetooth headset voice recognition method based on natural language processing as described in any one of claims 1-6.
9. A computer-readable storage medium storing instructions thereon, characterized in that, When the instructions are executed by the processor, they implement the various steps of the Bluetooth headset voice recognition method based on natural language processing as described in any one of claims 1-6.
Citation Information
Patent Citations
Bluetooth earphone AI voice control method and system
CN120375817A
Speech context semantic extraction method based on deep learning
CN120808766A