Voice control method and device of intelligent device and storage medium
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- HAIER YOUJIA INTELLIGENT TECH (BEIJING) CO LTD
- Filing Date
- 2024-12-02
- Publication Date
- 2026-06-02
AI Technical Summary
[0005]本申请提供一种智能设备的语音控制方法、装置和存储介质,用以解决现有的语音控制方法无法准确命中目标设备功能,进而使得语音控制失败率高的问题
[0053]本申请提供的智能设备的语音控制方法、装置和存储介质,通过响应于用户终端发送的控制语音信息,对所述控制语音信息进行语音识别,获取所述控制语音信息对应的文本信息;根据所述文本信息,确定目标设备标识、待执行动作标识和待执行功能文本;获取所述目标设备标识对应的设备功能集合,并判断所述设备功能集合中是否存在与所述待执行功能文本相同的目标功能名称;若否,则对所述待执行功能文本进行拆分提取,获取文本要素,其中,所述文本要素包括文本读音信息和/或文本字符信息;在所述设备功能集合中确定与所述文本要素匹配的目标功能名称;根据所述目标设备标识、所述待执行动作标识和所述目标功能名称,向目标设备发送所生成的控制指令;提高了语音控制的执行效率和执行成功率,提升了用户的使用体验。
Smart Images

Figure CN122135713A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of smart home / smart family, and more specifically, to a voice control method, device, and storage medium for a smart device. Background Technology
[0002] With the development of science and technology and the continuous improvement of people's living standards, more and more smart devices with voice control functions are being widely used in people's daily lives.
[0003] Existing voice control methods for smart devices typically convert the user's voice into text and compare the text content with a preset set of function names for the smart device. When the text content contains a field that is the same as a function name in the set, the smart device is controlled to execute the function indicated by that function name.
[0004] However, compared to traditional button or interface control methods, users do not have intuitive function name options when using voice control. They often speak using function names they have memorized, which may lead to inaccuracies in the user's memory. This can result in the text content of their voice not being accurately matched, causing control failures to occur frequently. This seriously affects the normal use of smart devices and user satisfaction. Summary of the Invention
[0005] This application provides a voice control method, apparatus, and storage medium for smart devices to solve the problem that existing voice control methods cannot accurately target the functions of the target device, resulting in a high failure rate of voice control.
[0006] In a first aspect, this application provides a voice control method for a smart device, comprising:
[0007] In response to control voice information sent by a user terminal, the system performs voice recognition on the control voice information and obtains the text information corresponding to the control voice information.
[0008] Based on the text information, determine the target device identifier, the action identifier to be executed, and the function text to be executed;
[0009] Obtain the set of device functions corresponding to the target device identifier, and determine whether there is a target function name in the set of device functions that is the same as the function text to be executed;
[0010] If not, the text to be executed is split and extracted to obtain text elements, wherein the text elements include text pronunciation information and / or text character information;
[0011] Determine the target function name that matches the text element from the set of device functions;
[0012] Based on the target device identifier, the action identifier to be executed, and the target function name, the generated control command is sent to the target device.
[0013] In one possible design, determining the target function name matching the text element within the device function set includes:
[0014] Perform a fuzzy match between the text elements and each function name in the device function set;
[0015] Based on the fuzzy matching results between the text elements and each function name, the target function name is determined in the device function set.
[0016] In one possible design, performing a fuzzy match between the text element and each function name in the device function set includes:
[0017] For any function name in the device function set, the function name is split and extracted to obtain the identification elements of the function name, wherein the identification elements include identification pronunciation information and / or identification character information;
[0018] The identifier element of each function name is compared with the text element;
[0019] The step of determining the target function name in the device function set based on the fuzzy matching results between the text elements and each function name includes:
[0020] Based on the comparison results, candidate function names are determined from each of the aforementioned function names;
[0021] If only one alternative function name exists, the alternative function name shall be used as the target function name;
[0022] When multiple alternative function names exist, a function selection request is sent to the user terminal to prompt the user to select an alternative function, and the target function name is determined from the multiple alternative function names based on the return result of the function selection request.
[0023] In one possible design, the text pronunciation information is a pronunciation encoding sequence of the text to be executed, the text character information is a character encoding sequence of the text to be executed, the identifier pronunciation information is a pronunciation encoding sequence of the function name, and the identifier character information is a character encoding sequence of the function name; the step of comparing the identifier element of each function name with the text element, and determining candidate function names from each function name based on the comparison result, includes:
[0024] The pronunciation information of the identifier for each function name is compared with the pronunciation information of the text;
[0025] When there is a homophonic function name that has the same pronunciation information as the text pronunciation information, the homophonic function name shall be used as the alternative function name;
[0026] When there is no homophonous function name whose pronunciation information is the same as the pronunciation information of the text, the smallest granularity of the encoding value is read from the identifier element of each function name and compared with the text element, and a candidate function name is determined from each function name according to the comparison result.
[0027] In one possible design, the step of comparing the identifier element of each function name with the smallest granularity encoded value read from the text element, and determining candidate function names for each function name based on the comparison result, includes:
[0028] Read each first character encoding value from the character encoding sequence of the function text to be executed, and read each second character encoding value from the character encoding sequence of each function name;
[0029] Based on each first character encoding value and each second character encoding value, determine whether there is a function name with the same character as the function text to be executed in the function name, wherein at least one second character encoding value of the function name with the same character is equal to at least one first character encoding value;
[0030] When there is a function name with the same character, the function name shall be used as the alternative function name;
[0031] When no function name with the same character exists, each first pronunciation code value is read from the pronunciation code sequence of the function text to be executed, and each second pronunciation code value is read from the pronunciation code sequence of each function name.
[0032] Determine whether there is a similar homophonous function name to the function text to be executed in the function name, wherein at least one second pronunciation code value of the similar homophonous function name is equal to at least one first pronunciation code value;
[0033] When there is a similar-sounding function name, the similar-sounding function name shall be used as the alternative function name.
[0034] In one possible design, the device function set includes multiple subsets with different function priorities, and the subsets and function priorities are in one-to-one correspondence; determining the target function name matching the text element in the device function set includes:
[0035] Obtain the functional priority of each subset, and obtain the subsets of the device function set one by one as matching subsets in descending order of functional priority, and determine whether there is a function name that matches the text element in the matching subset;
[0036] If so, the function name that matches the text element will be used as the target function name;
[0037] If not, then continue to obtain the next functional priority subset as the matching subset.
[0038] In one possible design, the method further includes:
[0039] Obtain the voice control log, which includes voice control history and / or user feedback data;
[0040] Each device identifier is individually retrieved as the set of device functions to be adjusted.
[0041] Based on the voice control log, the subset to which each function name belongs in the set of device functions to be adjusted is adjusted to obtain the adjusted set of device functions.
[0042] In one possible design, the step of splitting and extracting the text of the function to be executed to obtain text elements includes:
[0043] The character encoding sequence of the text to be executed is determined based on the character encoding and sorting of each character in the text to be executed.
[0044] Semantic recognition is performed on the text to be executed to determine the syntactic structure of the text to be executed, wherein the syntactic structure includes each word of the text to be executed and its order;
[0045] Based on the syntactic structure of the text to be executed and the preset correspondence between different words and their pronunciations, the pronunciation encoding sequence of the text to be executed is obtained.
[0046] Secondly, this application provides a voice control device, comprising:
[0047] The recognition module is used to respond to control voice information sent by the user terminal, perform voice recognition on the control voice information, obtain the text information corresponding to the control voice information, and determine the target device identifier, the action identifier to be executed, and the function text to be executed based on the text information.
[0048] The matching module is used to obtain the set of device functions corresponding to the target device identifier, and determine whether there is a target function name in the set of device functions that is the same as the text of the function to be executed; if there is no target function name in the set of device functions that is the same as the text of the function to be executed, the text of the function to be executed is split and extracted to obtain text elements, wherein the text elements include text pronunciation information and / or text character information; and the target function name that matches the text elements is determined in the set of device functions.
[0049] The control module is used to send the generated control commands to the target device based on the target device identifier, the action identifier to be executed, and the target function name.
[0050] Thirdly, this application provides a computer-readable storage medium comprising a stored program, wherein the program, when executed, performs the voice control method for a smart device as described in the first aspect.
[0051] Fourthly, this application provides an electronic device including a memory and a processor, wherein the memory stores a computer program and the processor is configured to execute the voice control method of the smart device as described in the first aspect through the computer program.
[0052] Fifthly, this application provides a program product including a computer program that, when executed by a processor, implements the voice control method for a smart device as described in the first aspect.
[0053] The voice control method, apparatus, and storage medium for smart devices provided in this application, in response to control voice information sent by a user terminal, perform voice recognition on the control voice information to obtain text information corresponding to the control voice information; based on the text information, determine a target device identifier, an action identifier to be executed, and a function text to be executed; obtain a set of device functions corresponding to the target device identifier, and determine whether there is a target function name in the set of device functions that is the same as the function text to be executed; if not, split and extract the function text to be executed to obtain text elements, wherein the text elements include text pronunciation information and / or text character information; determine a target function name matching the text elements in the set of device functions; and send the generated control command to the target device based on the target device identifier, the action identifier to be executed, and the target function name; thereby improving the execution efficiency and success rate of voice control and enhancing the user experience. Attached Figure Description
[0054] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with this application and, together with the description, serve to explain the principles of this application.
[0055] To more clearly illustrate the technical solutions in the embodiments of this application or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, for those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0056] Figure 1 This is a schematic diagram of the hardware environment for a voice control method for a smart device according to an embodiment of this application;
[0057] Figure 2 This is a flowchart illustrating the voice control method for the smart device provided in this application. Figure 1 ;
[0058] Figure 3 This is a flowchart illustrating the voice control method for the smart device provided in this application. Figure 2 ;
[0059] Figure 4 This is a schematic diagram of the structure of a voice control device provided in this application;
[0060] Figure 5 This is a schematic diagram of the structure of an electronic device provided in this application. Detailed Implementation
[0061] To enable those skilled in the art to better understand the present application, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present application, and not all embodiments. Based on the embodiments in the present application, all other embodiments obtained by those of ordinary skill in the art without creative effort should fall within the scope of protection of the present application.
[0062] It should be noted that the terms "first," "second," etc., in the specification, claims, and accompanying drawings of this application 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 of this application described herein can be implemented in orders other than those illustrated or described herein. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover non-exclusive inclusion; for example, a process, method, system, product, or apparatus 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 apparatus.
[0063] With the development of science and technology and the continuous improvement of people's living standards, more and more smart devices with voice control functions are being widely used in people's daily lives.
[0064] Existing voice control methods for smart devices typically convert the user's voice into text and compare the text content with a preset set of function names for the smart device. When the text content contains a field that is the same as a function name in the set, the smart device is controlled to execute the function indicated by that function name.
[0065] However, compared to traditional button or interface control methods, users do not have intuitive function name options when using voice control. They often speak using function names they have memorized, which may lead to inaccuracies in the user's memory. This can result in the text content of their voice not being accurately matched, causing control failures to occur frequently. This seriously affects the normal use of smart devices and user satisfaction.
[0066] To address the aforementioned issues, this application proposes the following technical concept: When a user performs a function on a smart device via voice control, the user's control voice information is recognized to obtain corresponding text information; based on the text information, a target device identifier, an action identifier to be executed, and a function text to be executed are determined; a set of device functions corresponding to the target device identifier is obtained, and a target function name matching the function text to be executed is matched within the set of device functions; if no target function name matching the function text to be executed exists in the set of device functions, the function text to be executed is split and extracted to obtain text elements, which include text pronunciation information and / or text character information; a target function name matching the text elements is determined within the set of device functions; based on the target device identifier, the action identifier to be executed, and the target function name, a generated control command is sent to the target device. This improves the execution efficiency and success rate of voice control and reduces the probability of requiring multiple user questions when the user's voice command cannot accurately match the target function name.
[0067] According to one aspect of the embodiments of this application, a voice control method for a smart device is provided. This smart home device interaction method is widely applicable to whole-house intelligent digital control application scenarios such as smart homes, smart home ecosystems, and intelligence house ecosystems. Optionally, in this embodiment, the above-mentioned smart home device interaction method can be applied to, for example... Figure 1 The hardware environment shown consists of user terminal 101, server 102, and smart device 103. For example... Figure 1As shown, server 102 connects to terminal device 101 and smart device 103 via a network, and can be used to provide voice control services for the terminal or clients installed on the terminal. A database can be set up on or independently of server 102 to provide data storage services for server 102. Cloud computing and / or edge computing services can be configured on or independently of server 102 to provide data processing services for server 102. In response to control voice information sent by user terminal 101, server 102 performs voice recognition on the control voice information to obtain the corresponding text information; based on the text information, The process involves identifying the target device identifier, the action identifier to be executed, and the function text to be executed; obtaining the device function set corresponding to the target device identifier, and determining whether there is a target function name in the device function set that is the same as the function text to be executed; if not, splitting and extracting the function text to be executed to obtain text elements, wherein the text elements include text pronunciation information and / or text character information; identifying the target function name that matches the text elements in the device function set; and sending the generated control command to the smart device 103 corresponding to the target device identifier based on the target device identifier, the action identifier to be executed, and the target function name.
[0068] The aforementioned networks may include, but are not limited to, at least one of the following: wired network, wireless network. The aforementioned wired network may include, but is not limited to, at least one of the following: wide area network, metropolitan area network, local area network. The aforementioned wireless network may include, but is not limited to, at least one of the following: Wi-Fi (Wireless Fidelity), Bluetooth. User terminal 101 and smart device 103 may not be limited to PCs, mobile phones, tablets, smart air conditioners, smart range hoods, smart refrigerators, smart ovens, smart stoves, smart washing machines, smart water heaters, smart washing equipment, smart dishwashers, smart projectors, smart TVs, smart clothes racks, smart curtains, smart audio-visual equipment, smart sockets, smart speakers, smart speakers, smart fresh air systems, smart kitchen and bathroom equipment, smart bathroom equipment, smart robot vacuum cleaners, smart window cleaning robots, smart mopping robots, smart air purifiers, smart steam ovens, smart microwave ovens, smart water heaters, smart air purifiers, smart water dispensers, smart door locks, etc.
[0069] Taking the voice control method of the smart device in this embodiment, executed by the voice control device of server 102, as an example, Figure 2 A flowchart illustrating a voice control method for a smart device provided in this application embodiment. Figure 1 ;like Figure 2 As shown in the embodiments of this application, the voice control method for a smart device includes:
[0070] S201: In response to the control voice information sent by the user terminal, perform voice recognition on the control voice information and obtain the text information corresponding to the control voice information.
[0071] Specifically, when a user performs a function on a smart device via voice control, the user terminal is first awakened, and then the user speaks the corresponding control statement. After being awakened, the user terminal acquires the voice audio information corresponding to the control statement through a corresponding audio acquisition device, encodes the voice audio information to generate corresponding control voice information, and sends the control voice information to the server according to a preset communication protocol. After receiving the control voice information, the server's voice control device parses the control voice information according to preset decoding rules and voice recognition algorithms, and converts the control voice information into corresponding text information based on the parsing results.
[0072] S202: Based on the text information, determine the target device identifier, the action identifier to be executed, and the function text to be executed.
[0073] Specifically, the voice control device performs syntactic analysis and slot identification and extraction on the text information according to a preset semantic recognition algorithm, and determines the target device identifier, the action identifier to be executed, and the function text to be executed based on the slot values of the extracted slots. The specific methods for slot identification and extraction on the text information can be named entity recognition, pattern matching, or sequence labeling, etc., and this application embodiment does not impose any particular limitations on these methods.
[0074] S203: Obtain the set of device functions corresponding to the target device identifier, and determine whether there is a target function name in the set of device functions that is the same as the function text to be executed.
[0075] Specifically, the voice control device retrieves the set of device functions corresponding to the target device from the corresponding storage location, searches the set of device functions based on the text of the function to be executed, and determines whether there is a target function name in the set of device functions that is the same as the text of the function to be executed based on the search results.
[0076] S204: If not, then the text to be executed is split and extracted to obtain text elements.
[0077] The text elements include text pronunciation information and / or text character information.
[0078] Specifically, when there is no target function name in the device function set that is the same as the text to be executed, the voice control device obtains each text character in the text to be executed as the text character information; the text to be executed is input into a pre-trained text-to-speech model to obtain the pronunciation sequence of the text to be executed.
[0079] S205: Determine the target function name that matches the text element in the device function set.
[0080] Specifically, the voice control device determines the target function name that matches the text element in the device function set according to the text element and a preset matching rule. The matching rule may be, for example, calculating the similarity between the function pronunciation sequence of each function name and the text pronunciation sequence, and obtaining the function name whose similarity to the text pronunciation sequence reaches a preset threshold as the target function name; or it may be searching the device function set according to the text character information, using the function names in the search results as candidate function names, sending a function selection request including the candidate function names to the user, and using the candidate function name selected by the user as the target function name; the embodiments of this application do not impose any special restrictions on the specific content of the matching rule.
[0081] S206: Send the generated control command to the target device based on the target device identifier, the action to be executed identifier, and the target function name.
[0082] Specifically, the voice control device retrieves the set of device instructions corresponding to the target device identifier from the corresponding storage location, retrieves the control instructions corresponding to the action identifier to be executed and the target function name from the set of device instructions, and sends the control instructions to the target device.
[0083] The voice control method for smart devices provided in this application first determines the target device identifier, the action identifier to be executed, and the function text to be executed based on the text information of the user's control statement. When a direct comparison between the function text to be executed and the function names in the device function set of the target device fails to yield a match, the function text to be executed is further split and extracted to obtain the text elements of the function text to be executed. Then, the target function name matching the text elements is determined in the device function set. Based on the target device identifier, the action identifier to be executed, and the target function name, the generated control command is sent to the target device. This method enables fuzzy matching of approximate function names in the device function set by using the text elements corresponding to the user's voice when the user's voice command cannot accurately match the target function name. This effectively improves the execution efficiency and success rate of voice control and reduces the probability of requiring the user to ask multiple questions.
[0084] Taking the voice control method of the smart device in this embodiment, executed by the voice control device of server 102, as an example, Figure 3 A flowchart illustrating a voice control method for a smart device provided in this application embodiment. Figure 2 ;like Figure 3 As shown in the embodiments of this application, the voice control method for a smart device includes:
[0085] S301: In response to the control voice information sent by the user terminal, perform voice recognition on the control voice information to obtain the text information corresponding to the control voice information.
[0086] The implementation method of step S301 is similar to that of step S201, and will not be described again in this embodiment.
[0087] S302: Based on the text information, determine the target device identifier, the action identifier to be executed, and the function text to be executed.
[0088] The implementation method of step S302 is similar to that of step S202, and will not be described again in this embodiment.
[0089] S303: Obtain the set of device functions corresponding to the target device identifier, and determine whether there is a target function name in the set of device functions that is the same as the function text to be executed.
[0090] The implementation method of step S303 is similar to that of step S203, and will not be described again in this embodiment.
[0091] S304: If so, then send the generated control command to the target device according to the target device identifier, the action to be executed identifier and the target function name.
[0092] The implementation of step S304 is similar to that of step S206, and will not be described again in this embodiment.
[0093] S305: If not, then determine the character encoding sequence of the text to be executed based on the character encoding and sorting of each character in the text to be executed.
[0094] Specifically, if there is no target function name in the device function set that is the same as the function text to be executed, the voice control device reads the character code of each character in the function text to be executed, and determines the order of the character code of each character in the character code sequence according to the order of each character in the function text to be executed.
[0095] S306: Perform semantic recognition on the text to be executed to determine the syntactic structure of the text to be executed.
[0096] The syntactic structure includes each word of the text to be executed and its order.
[0097] Specifically, the voice control device performs magnetic annotation, syntactic analysis, and semantic disambiguation on the text to be executed according to preset syntactic analysis rules to determine the syntactic structure of the text to be executed.
[0098] S307: Based on the syntactic structure of the text to be executed and the preset correspondence between different words and their pronunciations, obtain the pronunciation encoding sequence of the text to be executed.
[0099] Specifically, the voice control device obtains the preset correspondence between different words and their pronunciations from the corresponding storage locations, obtains the pronunciation of each word in the text to be executed based on each word in the text and the preset correspondence between different words and their pronunciations, and determines the pronunciation encoding sequence of the text to be executed based on the order and pronunciation of each word in the text to be executed.
[0100] S308: Obtain the functional priority of each subset, and obtain the subsets of the device function set one by one as matching subsets in descending order of functional priority.
[0101] The device function set includes multiple subsets with different function priorities, and the subsets and function priorities are in one-to-one correspondence.
[0102] It is understandable that different functions of the same device may have different probabilities of being selected. To improve the efficiency and accuracy of target function matching, the corresponding function priorities of different functions of each device model can be pre-configured according to the usage of the user group of each device model. The higher the function priority, the greater the probability that the function will be selected by the user group. The function name corresponding to each function priority is taken as a subset of the function priority. In the process of matching function names according to text elements, the subset of the device function set is obtained one by one as the matching subset in descending order of function priority.
[0103] S309: Determine whether there is a function name in the matching subset that matches the text element.
[0104] Optionally, the voice control device can perform fuzzy matching between the text element and each function name in the matching subset, and determine whether there is a function name matching the text element in the matching subset based on the fuzzy matching results between the text element and each function name. Then, following the order of function priority, the target function name is determined in the device function set. The specific method steps are as follows:
[0105] Step 1: For any function name in the device function set, split and extract the function name to obtain the identification elements of the function name.
[0106] The identification elements include identification pronunciation information and / or identification character information; the identification pronunciation information is the pronunciation encoding sequence of the function name, and the identification character information is the character encoding sequence of the function name.
[0107] The implementation method of step 1 is similar to that of steps S305 to S307, and will not be described again in this embodiment.
[0108] Step 2: Compare the identifier element of each function name with the text element, and determine the candidate function name in each function name according to the comparison result.
[0109] Optionally, the specific steps for the voice control device to compare the identifier element of each function name with the text element and determine the candidate function name from each function name based on the comparison result can be as follows:
[0110] Step 2a: Compare the pronunciation information of the identifier of each function name with the pronunciation information of the text.
[0111] For example, if the user issues a control statement such as "set the air conditioner to high power", then the target device indicated by the control statement is identified as "air conditioner", the action to be executed indicated by the control statement is identified as "set", and the function text to be executed indicated by the control statement is "high power". The phonetic encoding sequence corresponding to "high power" is "qiang, li". The voice control device determines whether there is a homophone of the function text to be executed in the function name based on the phonetic encoding sequence of each function name in the device function set corresponding to "qiang, li" and "air conditioner".
[0112] Step 2b: When there is a homophonic function name that is the same as the pronunciation information of the text, the homophonic function name is used as the alternative function name.
[0113] Step 2c: When there is no homophonous function name whose identification pronunciation information is the same as the text pronunciation information, read the smallest granularity encoding value from the identification element of each function name and the text element for comparison, and determine the candidate function name in each function name according to the comparison result.
[0114] Optionally, when there is no homophonous function name whose pronunciation information is the same as the pronunciation information of the text, the specific steps for comparing the smallest granularity encoding value read from the identifier element of each function name with the text element, and determining the candidate function name in each function name based on the comparison result, can be as follows:
[0115] Step 2c.1: Read each first character encoding value from the character encoding sequence of the to-be-executed function text, and read each second character encoding value from the character encoding sequence of each of the function names.
[0116] Step 2c.2: Based on each first character encoding value and each second character encoding value, determine whether there is a same-character function name of the to-be-executed function text in the function names.
[0117] Among them, at least one second character encoding value of the same-character function name is equal to at least one first character encoding value.
[0118] Continuing to refer to the above example, when there is no homophonic function name whose identified pronunciation information is the same as the text pronunciation information, the voice control device, according to each character encoding value in the character encoding sequence of "strong power", that is, the character encoding value of "strong" and the character encoding value of "power", and the character encoding sequence of each function name in the device function set corresponding to "air conditioner", determines whether there is a same-character function name of the to-be-executed function text in the function names.
[0119] Step 2c.3: When there is a same-character function name, use the function name as the alternative function name.
[0120] Continuing to refer to the above example, assuming there are same-character function names "strong dehumidification" and "strong purification", the voice control device uses "strong dehumidification" and "strong purification" as the alternative function names.
[0121] Step 2c.4: When there is no same-character function name, read each first pronunciation encoding value from the pronunciation encoding sequence of the to-be-executed function text, and read each second pronunciation encoding value from the pronunciation encoding sequence of each of the function names.
[0122] Step 2c.5: Determine whether there is an approximately homophonic function name of the to-be-executed function text in the function names.
[0123] Among them, at least one second pronunciation encoding value of the approximately homophonic function name is equal to at least one first pronunciation encoding value.
[0124] Continuing to refer to the above example, assuming there is no same-character function name, the voice control device continues to determine whether there is an approximately homophonic function name of the to-be-executed function text in the function names according to each pronunciation encoding value in the pronunciation encoding sequence of "strong power", that is, "qiang" and "li", and each pronunciation encoding value in the pronunciation encoding sequence of each function name in the device function set corresponding to "air conditioner".
[0125] Step 2c.6: When there is a similar homophonous function name, use the similar homophonous function name as the alternative function name.
[0126] Step 3: If there is only one alternative function name, use the alternative function name as the target function name.
[0127] Step 4: If there are multiple alternative function names, send a function selection request to the user terminal to prompt the user to select an alternative function, and determine the target function name from the multiple alternative function names based on the return result of the function selection request.
[0128] Specifically, when multiple alternative function names exist, the voice control device generates a function selection request based on these alternative names and sends the request to the user terminal. The function selection request can be, for example, a collection table listing each alternative function name as a candidate option, allowing the user to select an option from the list and submit it. Alternatively, the function selection request can be a question statement including each alternative function name as a candidate option, allowing the user to select an option from the alternative function names after hearing the question statement. The user terminal then obtains the selected alternative function name through an interactive device such as a touchscreen or microphone and generates the corresponding... The returned result is sent to the voice control device on the server. The voice control device uses the candidate function name indicated by the returned result as the target function name. The function selection request may also include an option "None of the above options are the function I want to select", which is used to indicate that there is no function name matching the text element among the candidate function names. If the user selects this option, there is no function name matching the text element in the current matching subset. If the user selects one of the candidate function names as the selection result, there is a function name matching the text element in the current matching subset. This application embodiment does not impose any special restrictions on the specific form of the function selection request and its returned result.
[0129] S310: If so, the function name that matches the text element shall be used as the target function name.
[0130] Specifically, when there is only one alternative function name or the user selects one alternative function name from multiple alternative function names, the voice control device determines that there is a function name that matches the text element in the current matching subset, and uses the function name that matches the text element as the target function name.
[0131] S311: If not, continue to obtain the next functional priority subset as the matching subset.
[0132] Specifically, if there is no alternative function name in the current matching subset or no function name matching the text element among the alternative function names, the voice control device determines that there is no function name matching the text element in the current matching subset, and continues to obtain the next function priority subset as the matching subset, and then determines again whether there is a function name matching the text element in the matching subset.
[0133] S312: Send the generated control command to the target device according to the target device identifier, the action to be executed identifier and the target function name.
[0134] The implementation of step S312 is similar to that of step S206, and will not be described again in this embodiment.
[0135] Optionally, the voice control device can also periodically adjust the range of subsets of priority for each function based on usage and user feedback. Specific methods and steps can be described as follows:
[0136] Step 1: Obtain the voice control log.
[0137] The voice control log includes voice control history records and / or user feedback data. The voice control history records may include, for example, the times of each voice control operation before the current time (pre-set duration), the target device identifier, the identifier of the action to be performed, and the name of the target function. The user feedback data may include, for example, frequently used function names and family member information that the user regularly inputs, as well as regularly collected regional and climate information.
[0138] Step 2: Obtain the set of device functions corresponding to each device identifier as the set of device functions to be adjusted.
[0139] Step 3: Based on the voice control log, adjust the subset to which each function name belongs in the set of device functions to be adjusted to obtain the adjusted set of device functions.
[0140] Specifically, the voice control device retrieves voice control logs from the corresponding storage location according to a preset cycle, extracts the usage frequency of each target function, commonly used function names reported by the user, and contextual information such as time, location, and weather from the voice control logs, inputs the extracted information into a pre-established priority calculation model, obtains the priority of each function to be adjusted in the voice control logs output by the priority calculation model, and adjusts the subset to which each function name belongs in the set of device functions to be adjusted according to the priority of each function to be adjusted, thereby obtaining the adjusted set of device functions. The priority calculation model can be, for example, a preset weighted summation model or a pre-trained machine learning model, etc. This application embodiment does not impose any special restrictions on the specific type of the priority calculation model.
[0141] The voice control method for smart devices provided in this application divides the set of device functions corresponding to each device identifier into subsets with different function priorities. When performing fuzzy matching between the text of the function to be executed and the function name, each subset is obtained as a matching subset in descending order of priority. The identifier elements in the matching subset are compared with the text elements, i.e., matching is prioritized from the function names with higher matching probabilities, so as to improve the efficiency and accuracy of matching. By periodically adjusting the range of each function priority subset based on the usage of the voice control device functions and user feedback, the priority of each function is made more suitable for the current actual application scenario and user usage habits, further improving the efficiency and accuracy of matching.
[0142] Figure 4 This is a schematic diagram of the structure of a voice control device provided in an embodiment of this application; as shown below. Figure 4 As shown, the voice control device 400 provided in this application embodiment includes:
[0143] The recognition module 401 is used to respond to the control voice information sent by the user terminal, perform voice recognition on the control voice information, obtain the text information corresponding to the control voice information, and determine the target device identifier, the action identifier to be executed, and the function text to be executed based on the text information.
[0144] The matching module 402 is used to obtain the device function set corresponding to the target device identifier, and determine whether there is a target function name in the device function set that is the same as the text of the function to be executed; if there is no target function name in the device function set that is the same as the text of the function to be executed, the text of the function to be executed is split and extracted to obtain text elements, wherein the text elements include text pronunciation information and / or text character information; and the target function name that matches the text elements is determined in the device function set.
[0145] The control module 403 is used to send the generated control command to the target device according to the target device identifier, the action to be executed identifier and the target function name.
[0146] Optionally, the matching module 402 is specifically used to perform fuzzy matching between the text element and each function name in the device function set; and to determine the target function name in the device function set based on the fuzzy matching result between the text element and each function name.
[0147] Optionally, the matching module 402 is specifically configured to: for any function name in the device function set, split and extract the function name to obtain the identification elements of the function name, wherein the identification elements include identification pronunciation information and / or identification character information; compare the identification elements of each function name with the text elements, and determine candidate function names in each function name according to the comparison results; if there is only one candidate function name, use the candidate function name as the target function name; if there are multiple candidate function names, send a function selection request to the user terminal to prompt the user to select a candidate function, and determine the target function name from the multiple candidate function names according to the return result of the function selection request.
[0148] Optionally, the text pronunciation information is the pronunciation encoding sequence of the text to be executed, the text character information is the character encoding sequence of the text to be executed, the identifier pronunciation information is the pronunciation encoding sequence of the function name, and the identifier character information is the character encoding sequence of the function name; the matching module 402 is specifically used to compare the identifier pronunciation information of each function name with the text pronunciation information; when there is a homophone function name with the same identifier pronunciation information as the text pronunciation information, the homophone function name is used as the candidate function name; when there is no homophone function name with the same identifier pronunciation information as the text pronunciation information, the smallest granularity encoding value is read from the identifier element of each function name and compared with the text element, and a candidate function name is determined in each function name according to the comparison result.
[0149] Optionally, the matching module 402 is specifically configured to: read each first character encoding value from the character encoding sequence of the text to be executed, and read each second character encoding value from the character encoding sequence of each function name; determine, based on each first character encoding value and each second character encoding value, whether there exists a function name in the function name that is the same as the text to be executed, wherein at least one second character encoding value of the same function name is equal to at least one first character encoding value; when there is a function name that is the same as the text, use the function name as the candidate function name; when there is no function name that is the same as the text, read each first pronunciation encoding value from the pronunciation encoding sequence of the text to be executed, and read each second pronunciation encoding value from the pronunciation encoding sequence of each function name; determine whether there exists a function name in the function name that is approximately homophonous to the text to be executed, wherein at least one second pronunciation encoding value of the approximately homophonous function name is equal to at least one first pronunciation encoding value; when there is a function name that is approximately homophonous, use the approximately homophonous function name as the candidate function name.
[0150] Optionally, the device function set includes multiple subsets with different function priorities, and the subsets and function priorities are in one-to-one correspondence; the matching module 402 is specifically used to obtain the function priority of each subset, and obtain the subsets of the device function set one by one as matching subsets in descending order of function priority, and determine whether there is a function name matching the text element in the matching subset; when there is a function name matching the text element in the matching subset, the function name matching the text element is taken as the target function name; when there is no function name matching the text element in the matching subset, the next subset of function priority is obtained as the matching subset.
[0151] Optionally, the matching module 402 is further configured to acquire voice control logs, which include voice control history records and / or user feedback data; acquire the set of device functions corresponding to each device identifier as the set of device functions to be adjusted; and adjust the subset to which each function name in the set of device functions to be adjusted belongs according to the voice control logs to obtain the adjusted set of device functions.
[0152] Optionally, the matching module 402 is specifically configured to: determine the character encoding sequence of the text to be executed based on the character encoding and sorting of each character in the text to be executed; perform semantic recognition on the text to be executed to determine the syntactic structure of the text to be executed, wherein the syntactic structure includes each word of the text to be executed and its sorting; and obtain the pronunciation encoding sequence of the text to be executed based on the syntactic structure in the text to be executed and the preset correspondence between different words and pronunciations.
[0153] Figure 5 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. Figure 5 As shown, this application provides an electronic device 500, which includes at least one processor 501 and a memory 502; in addition, the electronic device 500 may also have a communication interface 504 for receiving and sending instructions.
[0154] The processor 501, memory 502 and communication interface 504 are connected via bus 503.
[0155] The computer program is stored in memory 502 and configured to be executed by processor 501 to implement this application. Figures 2-3 The voice control method for smart devices provided in any corresponding embodiment;
[0156] Figure 5 The electronic device shown in the embodiment can be used to execute the technical solution of the above method embodiment. Its implementation principle and technical effect are similar, and will not be repeated here.
[0157] In addition, this embodiment also provides a computer-readable storage medium storing a computer program thereon, which is executed by a processor to implement the voice control method of the smart device described above.
[0158] In the several embodiments provided by this invention, it should be understood that the disclosed apparatus and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components 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 through some interfaces; the indirect coupling or communication connection between apparatuses or units may be electrical, mechanical, or other forms.
[0159] The units described as separate components may or may not be physically separate. The components shown as units 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 units can be selected to achieve the purpose of this embodiment according to actual needs.
[0160] Furthermore, the functional units in the various embodiments of the present invention can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or in the form of hardware plus software functional units.
[0161] The integrated units implemented as software functional units described above can be stored in a computer-readable storage medium. These software functional units, 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 to execute partial steps of the methods of 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.
[0162] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the above-described division of functional modules is merely an example. In practical applications, the above functions can be assigned to different functional modules as needed, that is, the internal structure of the device can be divided into different functional modules to complete all or part of the functions described above. The specific working process of the device described above can be referred to the corresponding process in the foregoing method embodiments, and will not be repeated here.
[0163] The above description is only a preferred embodiment of this application. It should be noted that for those skilled in the art, several improvements and modifications can be made without departing from the principle of this application, and these improvements and modifications should also be considered within the scope of protection of this application.
Claims
1. A voice control method for a smart device, characterized in that, The method includes: In response to control voice information sent by a user terminal, the system performs voice recognition on the control voice information and obtains the text information corresponding to the control voice information. Based on the text information, determine the target device identifier, the action identifier to be executed, and the function text to be executed; Obtain the set of device functions corresponding to the target device identifier, and determine whether there is a target function name in the set of device functions that is the same as the function text to be executed; If not, the text to be executed is split and extracted to obtain text elements, wherein the text elements include text pronunciation information and / or text character information; Determine the target function name that matches the text element from the set of device functions; Based on the target device identifier, the action identifier to be executed, and the target function name, the generated control command is sent to the target device.
2. The method according to claim 1, characterized in that, Determining the target function name that matches the text element in the device function set includes: Perform a fuzzy match between the text elements and each function name in the device function set; Based on the fuzzy matching results between the text elements and each function name, the target function name is determined in the device function set.
3. The method according to claim 2, characterized in that, The step of performing fuzzy matching between the text elements and each function name in the device function set includes: For any function name in the device function set, the function name is split and extracted to obtain the identification elements of the function name, wherein the identification elements include identification pronunciation information and / or identification character information; The identifier element of each function name is compared with the text element; The step of determining the target function name in the device function set based on the fuzzy matching results between the text elements and each function name includes: Based on the comparison results, candidate function names are determined from each of the aforementioned function names; If only one alternative function name exists, the alternative function name shall be used as the target function name; When multiple alternative function names exist, a function selection request is sent to the user terminal to prompt the user to select an alternative function, and the target function name is determined from the multiple alternative function names based on the return result of the function selection request.
4. The method according to claim 3, characterized in that, The text pronunciation information is the pronunciation encoding sequence of the text to be executed, the text character information is the character encoding sequence of the text to be executed, the identifier pronunciation information is the pronunciation encoding sequence of the function name, and the identifier character information is the character encoding sequence of the function name; the step of comparing the identifier element of each function name with the text element, and determining the candidate function name in each function name according to the comparison result, includes: The pronunciation information of the identifier for each function name is compared with the pronunciation information of the text; When there is a homophonic function name that has the same pronunciation information as the text pronunciation information, the homophonic function name shall be used as the alternative function name; When there is no homophonous function name whose pronunciation information is the same as the pronunciation information of the text, the smallest granularity of the encoding value is read from the identifier element of each function name and compared with the text element, and a candidate function name is determined from each function name according to the comparison result.
5. The method according to claim 4, characterized in that, The step of comparing the identifier element of each function name with the smallest granularity encoded value read from the text element, and determining candidate function names for each function name based on the comparison result, includes: Read each first character encoding value from the character encoding sequence of the function text to be executed, and read each second character encoding value from the character encoding sequence of each function name; Based on each first character encoding value and each second character encoding value, determine whether there is a function name with the same character as the function text to be executed in the function name, wherein at least one second character encoding value of the function name with the same character is equal to at least one first character encoding value; When there is a function name with the same character, the function name shall be used as the alternative function name; When no function name with the same character exists, each first pronunciation code value is read from the pronunciation code sequence of the function text to be executed, and each second pronunciation code value is read from the pronunciation code sequence of each function name. Determine whether there is a similar homophonous function name to the function text to be executed in the function name, wherein at least one second pronunciation code value of the similar homophonous function name is equal to at least one first pronunciation code value; When there is a similar-sounding function name, the similar-sounding function name shall be used as the alternative function name.
6. The method according to claim 1, characterized in that, The device function set includes multiple subsets with different function priorities, and the subsets and function priorities are in one-to-one correspondence; determining the target function name that matches the text element in the device function set includes: Obtain the functional priority of each subset, and obtain the subsets of the device function set one by one as matching subsets in descending order of functional priority, and determine whether there is a function name that matches the text element in the matching subset; If so, the function name that matches the text element will be used as the target function name; If not, then continue to obtain the next functional priority subset as the matching subset.
7. The method according to claim 6, characterized in that, The method further includes: Obtain the voice control log, which includes voice control history and / or user feedback data; Each device identifier is individually retrieved as the set of device functions to be adjusted. Based on the voice control log, the subset to which each function name belongs in the set of device functions to be adjusted is adjusted to obtain the adjusted set of device functions.
8. The method according to claim 1, characterized in that, The step of splitting and extracting the text of the function to be executed to obtain text elements includes: The character encoding sequence of the text to be executed is determined based on the character encoding and sorting of each character in the text to be executed. Semantic recognition is performed on the text to be executed to determine the syntactic structure of the text to be executed, wherein the syntactic structure includes each word of the text to be executed and its order; Based on the syntactic structure of the text to be executed and the preset correspondence between different words and their pronunciations, the pronunciation encoding sequence of the text to be executed is obtained.
9. A computer-readable storage medium, characterized in that, The computer-readable storage medium includes a stored program, wherein the program, when executed, performs the voice control method of the smart device according to any one of claims 1 to 8.
10. An electronic device comprising a memory and a processor, characterized in that, The memory stores a computer program, and the processor is configured to execute the voice control method of the smart device according to any one of claims 1 to 8 through the computer program.