An intelligent response device based on websocket
Through the intelligent response device based on websocket, voice data is collected and processed in real time, and office instructions are automatically recognized and executed, which solves the problem of low office operation efficiency in the existing technology and realizes efficient and intelligent voice interactive control.
Patent Information
- Application Number
- CN202411103357.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-13
- Publication Date
- 2024-10-22
- Estimated Expiration
- 2044-08-13
AI Technical Summary
Existing voice interaction technology is inefficient in office operations and requires manual triggering of interface requests and waiting for responses, resulting in low production efficiency.
Design an intelligent response device based on websocket, including a collection module, a listening module, a transmission module, a conversion module, an instruction recognition module and an operation response module. Through real-time collection and processing of voice data, it can identify instructions and perform automatic operation responses, combined with intelligent monitoring The module monitors and resumes module operation in real time.
It realizes efficient real-time collection and processing of voice data, automatically converts it into control instructions, improves office efficiency, and has higher real-time performance, low resource consumption, concurrent processing capabilities and data security.
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of voice control, in particular to a websocket-based intelligent response device. Background Art
[0002] With the continuous updating of technology, more and more companies are beginning to use artificial intelligence to improve production efficiency and liberate productivity. As an important means of human-computer interaction, voice recognition has received widespread attention and application from all walks of life. Voice interaction technology is widely used in various smart terminals, enabling users to control smart terminals in a contactless manner. In the existing technology, when performing office operations, operations such as querying the number of to-do items require manual triggering of interface requests and waiting for the interface response to return. In actual life use, office efficiency is low. Summary of the invention
[0003] The purpose of the present invention is to provide a websocket-based intelligent response device to solve the problems raised in the above background technology.
[0004] To achieve the above object, the present invention provides the following technical solution: a websocket-based intelligent response device, comprising a collection module, a monitoring module, a transmission module, a conversion module, a command recognition module, an operation response module, and an intelligent monitoring module.
[0005] The acquisition module is used to collect audio data from the device in real time and put the collected audio buffer in the buffer queue, waiting to be sent;
[0006] The monitoring module is used to monitor the data in the buffer queue and push it to the transmission module for audio data packaging;
[0007] The transmission module is used to reassemble the received buffer and transmit it to the conversion module in real time through the communication tunnel;
[0008] The conversion module is used to identify and convert the data received in real time, and return the generated text results to the transmission module;
[0009] The instruction recognition module is used to extract text and perform semantic analysis based on the text results recognized in the conversion module, and convert them into recognized instructions;
[0010] The operation response module is used to perform corresponding interface request operations according to the specific instructions identified, and open the corresponding display page to achieve different functions.
[0011] The intelligent monitoring module is used to monitor the operation of each of the above modules. If there is a problem with the module, an automatic alarm will be issued.
[0012] Preferably, the acquisition module dynamically configures the audio sampling rate, channel configuration, sampling accuracy, audio format and buffer size of the audio data by acquiring audio data of the device, and places the audio buffer acquired in real time in a buffer queue, waiting to be sent.
[0013] Preferably, the monitoring module establishes a connection with the conversion service, shakes hands to reach a protocol exchange, and pushes new buffer data in the buffer queue after monitoring to the transmission module for packaging of the audio data.
[0014] Preferably, the specific process of the transmission module is to reassemble the received buffer, add four bytes in front to store the length of the buffer, append a self-stored end identifier at the end of the buffer, and then reassemble the entire complete buffer through an encryption algorithm to generate a new newbuffer, and transmit it to the conversion service in real time using the communication tunnel established by the websocket protocol.
[0015] Preferably, after receiving the real-time audio stream data, the conversion module performs anti-shake check on the audio data, reorganizes the audio with packet loss and disorder, and then identifies and converts the reorganized normal audio data packets, and finally generates a text result and returns it to the transmission module.
[0016] Preferably, the specific operations of the conversion module are:
[0017] a. Voice endpoint detection, which is used to distinguish the language and non-language parts of the audio, ignore the background noise, and extract the voice signal;
[0018] b. Based on the deep full-sequence convolutional neural network framework, process the continuous audio stream content and convert it into a text stream;
[0019] c. Punctuation prediction is added during the recognition process to insert appropriate punctuation marks based on speech pauses and changes in intonation.
[0020] Preferably, the specific operations of the instruction recognition module are:
[0021] a. Parse the swapped text and identify keywords or phrases with specific meanings. Keywords or phrases correspond to specific control instructions.
[0022] b. Map the parsed keywords or phrases to specific control instructions according to pre-defined rules or patterns.
[0023] Preferably, a dynamic two-way binding method is used among the control instructions, operation requests, and page jumps, and an observer mode is used to monitor the control instructions, and the corresponding operation request is automatically awakened when the instruction is triggered.
[0024] Preferably, the intelligent monitoring module performs real-time monitoring during operation, and if an abnormality occurs during the communication process, it is detected and restored in a timely manner.
[0025] Compared with the prior art, the present invention has the following beneficial effects:
[0026] (1) The present invention intelligently monitors the operation process of each module in the acquisition module, monitoring module, transmission module, conversion module, instruction recognition module, and operation response module. When an abnormality occurs during the communication process, it can be detected and restored in time. In addition, the efficient coordination of these modules makes the device more intelligent, with higher real-time performance, lower resource consumption, and stronger concurrent processing capability.
[0027] (2) The present invention can collect audio data in real time, convert it into control instructions, and make effective response operations.
[0028] (3) The present invention utilizes intelligent transmission, so that the data transmitted intelligently has higher security. DETAILED DESCRIPTION
[0029] The following will be combined with the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of the present invention. Example
[0030] The present invention provides a websocket-based intelligent response device, comprising a collection module, a monitoring module, a transmission module, a conversion module, an instruction recognition module, an operation response module, and an intelligent monitoring module.
[0031] Specifically, in the field of intelligent OA office, if you want to check my to-do list, the user issues a voice command "check my to-do list". During this process, the office equipment receives the voice input of "check my to-do list", and the acquisition module collects the audio data of the equipment in real time. When the acquisition module collects the audio data of "check my to-do list", the collected audio buffer of "check my to-do list" is placed in the buffer queue, waiting to be sent. When collecting, the audio data of the acquisition device can be used to dynamically configure the audio sampling rate, channel configuration, sampling accuracy, audio format, and buffer size, and set the quality parameters of the audio data, so that the voice command "check my to-do list" has high quality, is easy to collect and use, and avoids voice reception errors.
[0032] In the process of receiving voice commands, the monitoring module monitors the data in the buffer queue in real time. When receiving the voice command of "query my to-do", the data about "query my to-do" in the buffer queue is pushed to the transmission module for packaging of audio data. Specifically, the monitoring module establishes a connection with the conversion service, shakes hands to reach an agreement exchange, and after monitoring that there is new buffer data about "query my to-do" in the buffer queue, it is pushed to the transmission module for packaging of audio data;
[0033] The transmission module reassembles the received buffer about "Query My To-Do", adds four bytes to the front to store the length of the buffer, appends a self-stored end identifier to the back of the buffer, and then reassembles the entire complete buffer through the encryption algorithm to generate a new newbuffer, which is transmitted to the conversion service in real time using the communication tunnel established by the websocket protocol;
[0034] The conversion module recognizes and converts the data received in real time, and returns the generated text results to the transmission module. During the conversion process, the audio data is anti-shake checked to improve the quality of the audio data. At the same time, if there is audio packet loss and disorder, it will be reorganized, and then the reorganized normal audio data packets are recognized and converted. The specific process of recognition and conversion is as follows: a. Detect the voice endpoint, distinguish the language and non-language parts in the audio, ignore the background noise, and extract the voice signal; b. Based on the deep full-sequence convolutional neural network framework, process the continuous audio stream content and convert it into a text stream; c. Add punctuation prediction during the recognition process, insert appropriate punctuation marks according to the pauses and changes in voice intonation, and finally generate the text result and return it to the transmission module. During the voice recognition process, if the user continuously issues the voice command "check my to-do list, call xx", punctuation marks will be inserted according to the user's pause between "check my to-do list" and "call xx", and the generated text will be returned to the transmission module;
[0035] The instruction recognition module extracts text and performs semantic analysis based on the text results recognized in the conversion module, and converts it into recognized instructions. The specific operations are as follows: a. parse the converted text to identify keywords or phrases with specific meanings, where the keywords or phrases correspond to specific control instructions. For example, the instruction recognition module recognizes the text result of "query my to-do list", parses it, and identifies the keywords of "query", "to-do list" or "my to-do list". b. According to pre-defined rules or patterns, the parsed keywords or phrases are mapped to specific control instructions, where a dynamic two-way binding method is adopted between control instructions, operation requests, and page jumps, and the observer mode is adopted to monitor control instructions, and the corresponding operation request is automatically awakened when the instruction is triggered; the operation response module performs corresponding interface request operations according to the recognized specific instructions, and opens the corresponding display page to realize different functions; specifically, the operation response module recognizes the specific operation request of "query my to-do list", and then opens "my to-do list" on the operating device, and the data of the to-do list page automatically pops up, or the operation instruction issued by the user is "call xx", then the information interface of xx's personnel will automatically pop up, and the telephone number displayed on the personnel information page will be automatically called when the dialing is confirmed.
[0036] During the entire operation process, the intelligent monitoring module monitors the operation of the above modules all the time. If there is a problem with a module, it will automatically alarm, and detect and restore in time, so that each module can operate normally.
[0037] It will be apparent to those skilled in the art that the present invention is not limited to the details of the exemplary embodiments described above and that the present invention can be implemented in other specific forms without departing from the spirit or essential features of the present invention. Therefore, the embodiments are to be considered exemplary and non-restrictive in all respects, and the scope of the present invention is defined by the appended claims rather than the foregoing description, and it is intended that all variations falling within the meaning and scope of the equivalent elements of the claims be included in the present invention.
Claims
1. A websocket-based intelligent response device, characterized in that: It includes acquisition module, monitoring module, transmission module, conversion module, instruction recognition module, operation response module and intelligent monitoring module; The acquisition module is used to collect audio data from the device in real time and put the collected audio buffer in the buffer queue, waiting to be sent; The monitoring module is used to monitor the data in the buffer queue and push it to the transmission module for audio data packaging; The transmission module is used to reassemble the received audio buffer and transmit it to the conversion module in real time through the communication tunnel. The transmission module reassembles the received audio buffer, adds four bytes to the front to store the length of the audio buffer, and appends a self-stored end identifier to the back of the audio buffer. Then, the entire complete audio buffer is reassembled through an encryption algorithm to generate a new newbuffer, and the communication tunnel established by the websocket protocol is used to transmit it to the conversion service in real time; The conversion module is used to identify and convert the data received in real time, and send the generated text results back to the transmission module; the specific operations of the conversion module are: a. Voice endpoint detection, which is used to distinguish the language and non-language parts in the audio, ignore the background noise, and extract the voice signal; b. Based on the deep full-sequence convolutional neural network framework, the continuous audio stream content is processed and converted into a text stream; c. Punctuation prediction is added during the recognition process to insert appropriate punctuation marks according to the pauses and intonation changes of the speech; The instruction recognition module is used to extract text and perform semantic analysis based on the text results recognized in the conversion module, and convert them into recognized instructions; the specific operations of the instruction recognition module are: a. parse the converted text to identify keywords or phrases with specific meanings, and the keywords or phrases correspond to specific control instructions; b. map the parsed keywords or phrases to specific control instructions according to predefined rules or patterns; The operation response module is used to perform corresponding interface request operations according to the specific instructions identified, and open the corresponding display page to achieve different functions; dynamic two-way binding is adopted between control instructions, operation requests and page jumps, and the observer mode is used to monitor control instructions, and the corresponding operation request is automatically awakened when the instruction is triggered; The intelligent monitoring module is used to monitor the operation of each of the above modules. If there is a problem with the module, an alarm will be automatically triggered.
2. According to claim 1, a websocket-based intelligent response device is characterized in that: The acquisition module dynamically configures the audio sampling rate, channel, sampling accuracy, audio format, and sets the buffer size and quality parameters of the audio data by acquiring audio data of the device.
3. The websocket-based intelligent response device according to claim 1, characterized in that: After receiving the real-time audio stream data, the conversion module performs anti-shake check on the audio data, reorganizes the audio with packet loss and disorder, and then identifies and converts the reorganized normal audio data packets, and finally generates a text result and returns it to the transmission module.
4. The websocket-based intelligent response device according to claim 1, characterized in that: The intelligent monitoring module performs real-time monitoring during operation, and if an abnormality occurs during the communication process, it will be detected and restored in time.
