Device control method and server

By using codeword library and scoring mechanisms in smart home systems to identify user intentions and generate target control instructions, the problem of privacy leakage in voice control is solved, and security and entertainment are improved.

CN115701562BActive Publication Date: 2025-08-12HUAWEI TECH CO LTD
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202110882844.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-08-02
Publication Date
2025-08-12
Estimated Expiration
2041-08-02

AI Technical Summary

Technical Problem

In the process of voice-controlling smart homes, user privacy information is easily leaked and lacks entertainment and playability, resulting in low security.

Method used

Obtain user voice through sound pickup devices, use codeword database and scoring mechanism to identify user intentions, generate target control instructions, and ensure privacy protection and security during voice control.

Benefits of technology

Improves the security of smart home control, protects user privacy, and increases the entertainment and playability of voice control.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115701562B_ABST
    Figure CN115701562B_ABST
Patent Text Reader

Abstract

Embodiments of the present application provide a device control method and server. This method can pre-set a first number of codewords, and after obtaining a first voice containing a second number of codewords through a sound pickup device, the method can determine the intention expressed by the first voice, i.e., the target domain, based on the first voice. When the target domain is the home domain, the second number of codewords are matched with a pre-configured codeword library to obtain target control instructions, and the target control instructions are output to control the corresponding devices. In this way, the smart home is controlled through codewords, thereby protecting user privacy during the voice control process and improving the security of smart home control.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of information processing, and in particular to a device control method and a server. Background Art

[0002] With the application and development of intelligent voice control in the Internet of Things (IoT) home sector, users can control smart home devices through voice commands. Although voice control of smart homes brings great convenience to the user interaction experience, it is currently prone to leaking user privacy information during the voice control process, resulting in low security of voice-controlled smart homes. In addition, it does not provide users with entertainment and playability. Summary of the Invention

[0003] In order to achieve the above technical objectives, the present application provides a device control method, electronic device, computer-readable storage medium and computer program product, which can protect user privacy during voice control and improve the security of smart home control.

[0004] In a first aspect, the present application provides a device control method, which is applied to a server. The method may include: obtaining a first voice emitted by a user through at least one sound pickup device, processing the first voice, and obtaining m scores for m fields, where the m fields are fields corresponding to the intention expressed by the first voice, the m fields include the home field, and m is a positive integer greater than or equal to 1; correcting the score of the home field according to the first voice; determining the target field according to the corrected score of the home field and the scores of m-1 fields other than the home field; when the target field is the home field, obtaining the target control instruction according to the first voice and a pre-configured codeword library; and outputting the target control instruction. In this way, the smart home is controlled by codewords, so that the user privacy is protected during the voice control process, thereby improving the security of smart home control.

[0005] According to the first aspect, based on the first speech, the score for the home domain is modified, specifically comprising: matching p words contained in the first speech with code words in a code word library to obtain the number of code words contained in the first speech, where p is a positive integer greater than or equal to 1; and modifying the score for the home domain based on the number of code words contained in the first speech. In this way, by matching the words contained in the target speech with the hot words in the hot word library, the score of the corresponding skill can be determined, and further, based on the score of each skill, it can be determined whether the user's intention is home skills.

[0006] According to the first aspect, or any implementation of the first aspect, a target domain is determined based on the corrected score for the home domain and the scores for m-1 domains other than the home domain. This specifically includes selecting the domain with the highest score as the target domain. In this way, the scores for home skills are corrected based on the number of code words, making it easier for code words to be matched to home skills, thus preventing code word control failure.

[0007] According to the first aspect, or according to any implementation manner of the first aspect, obtaining a target control instruction based on a first voice and a preconfigured codeword library specifically includes: determining j codewords contained in the first voice, where j is a positive integer greater than or equal to 1; matching the j codewords with the codeword library to obtain the target control instruction, where the codeword library includes a correspondence between the codewords and target data, and the target data includes one or more of devices, functions, services, and scenarios.

[0008] According to the first aspect, or according to any implementation method of the first aspect, j code words are matched with the code word library to obtain target control instructions, specifically including: according to the correspondence between the code words and the target data in the code word library, the words corresponding to the j code words are matched to the home skill slots corresponding to the home field to obtain home skill slot information; according to the home skill slot information, the target control instruction is obtained.

[0009] According to the first aspect, or according to any implementation of the first aspect, before acquiring a first voice uttered by a user through at least one sound pickup device, the method further includes: acquiring n code words configured by the user through an electronic device, where n is a positive integer greater than or equal to 1; detecting the legitimacy of the n code words and storing the legal code words in a code word library; and if k code words among the n code words are illegal, outputting the k code words. In this way, the code words are matched to the slots corresponding to the home skills, thereby obtaining corresponding control instructions.

[0010] According to the first aspect, or according to any implementation of the first aspect, for the i-th codeword among n codewords, checking the legitimacy of the i-th codeword specifically includes: checking whether the i-th codeword meets preset conditions, where the preset conditions are one or more of the following: the codeword is polysyllabic, the codeword is different from the wake-up word, or the codeword is different from a hot word in a preset hot word library; if the i-th codeword meets the preset conditions, the i-th codeword is legal; if the i-th codeword does not meet the preset conditions, the i-th codeword is illegal. In this way, n codewords are pre-configured, and the legitimacy of each codeword is checked, thereby determining legal codewords, and prompting the user if an illegal codeword exists so that the user can reset the codeword.

[0011] According to the first aspect, or according to any implementation manner of the first aspect, the first voice includes an identity identifier of the controlled device and at least one codeword.

[0012] According to the first aspect, or according to any implementation of the first aspect, the identity of the controlled device is represented by a code word.

[0013] In a second aspect, the present application provides a server. The server includes at least one memory for storing programs; and at least one processor for executing the programs stored in the memory. When the programs stored in the memory are executed, the processor is configured to perform the method of the first aspect or any embodiment of the first aspect.

[0014] In a third aspect, the present application provides a computer-readable storage medium storing a computer program, which, when executed on an electronic device, causes the electronic device to perform the first aspect or any one of the methods of the first aspect.

[0015] In a fourth aspect, the present application provides a computer program product. When the computer program product is run on an electronic device, the electronic device executes the method of the first aspect or any one of the aspects of the first aspect.

[0016] The second aspect and any implementation of the second aspect, the third aspect and any implementation of the third aspect, and the fourth aspect and any implementation of the fourth aspect correspond to the first aspect and any implementation of the first aspect, respectively. The technical effects corresponding to the second aspect and any implementation of the second aspect can be referred to the technical effects corresponding to the first aspect and any implementation of the first aspect, and will not be repeated here. BRIEF DESCRIPTION OF THE DRAWINGS

[0017] Figure 1 This is a schematic diagram of the relationship between intent and slots provided in an embodiment of the present application;

[0018] Figure 2 This is a schematic diagram of a scenario provided by an embodiment of the present application;

[0019] Figure 3 This is a schematic diagram of the hardware structure of a sound pickup device provided in an embodiment of the present application;

[0020] Figure 4 This is a schematic diagram of the hardware structure of a server provided in an embodiment of the present application;

[0021] Figure 5 This is a flow chart of a device control method provided in an embodiment of the present application;

[0022] Figure 6This is a flowchart of the codeword configuration step in the device control method provided in an embodiment of the present application;

[0023] Figure 7 This is a schematic diagram of the interface changes of an electronic device during the codeword configuration process provided by an embodiment of the present application;

[0024] Figure 8 This is a flowchart of the steps of identifying and responding to a collected audio signal containing a codeword in the device control method provided in an embodiment of the present application;

[0025] Figure 9 This is a schematic diagram of an application process in a scenario provided by an embodiment of the present application;

[0026] Figure 10 This is a schematic diagram of an application process in another scenario provided by an embodiment of the present application;

[0027] Figure 11 This is a schematic diagram of the structure of a chip provided in an embodiment of the present application. DETAILED DESCRIPTION

[0028] The terms used in the following embodiments are only for the purpose of describing specific embodiments and are not intended to be limiting of the present application. As used in the specification and appended claims of the present application, the singular expressions "one", "a kind of", "said", "above", "the" and "this" are intended to also include expressions such as "one or more", unless there is a clear contrary indication in the context. It should also be understood that in the following embodiments of the present application, "at least one", "one or more" refer to one or more (including two). The term "and / or" is used to describe the association relationship of associated objects, indicating that three relationships can exist; for example, A and / or B can represent: the existence of A alone, the existence of A and B at the same time, and the existence of B alone, where A and B can be singular or plural. The character " / " generally indicates that the related objects before and after are in an "or" relationship.

[0029] References to "one embodiment" or "some embodiments" etc. described in this specification mean that a particular feature, structure or characteristic described in conjunction with the embodiment is included in one or more embodiments of the present application. Thus, the phrases "in one embodiment", "in some embodiments", "in some other embodiments", "in some other embodiments", etc. appearing in different places in this specification do not necessarily refer to the same embodiment, but mean "one or more but not all embodiments", unless otherwise specifically emphasized. The terms "including", "comprising", "having" and their variations all mean "including but not limited to", unless otherwise specifically emphasized. The term "connected" includes direct and indirect connections, unless otherwise stated.

[0030] In the following, the terms "first" and "second" are used for descriptive purposes only and should not be understood to indicate or imply relative importance or implicitly specify the quantity of the technical features indicated. Therefore, a feature specified as "first" or "second" may explicitly or implicitly include one or more of the features.

[0031] In the embodiments of this application, words such as "exemplarily" or "for example" are used to indicate examples, illustrations, or explanations. Any embodiment or design described as "exemplarily" or "for example" in the embodiments of this application should not be interpreted as being preferred or advantageous over other embodiments or designs. Rather, the use of words such as "exemplarily" or "for example" is intended to present the relevant concepts in a concrete manner.

[0032] To facilitate understanding, the following first introduces the relevant terms and concepts involved in the embodiments of this application.

[0033] (1) Intention and slot

[0034] Intent refers to an electronic device's ability to identify a user's actual or potential needs. Fundamentally, intent recognition is a classifier that categorizes user needs into specific types, or a sorter that ranks a user's potential needs by likelihood.

[0035] Intents and slots together constitute "user actions". Electronic devices cannot directly understand natural language, so the role of intent recognition is to map natural language or operations into structured semantic representations that machines can understand.

[0036] Spoken utterance classification (SUC), as the name implies, is the classification of natural language conversations input by users, and the divided categories correspond to user intentions. For example, "How is the weather today?" has the intention of "asking about the weather." Naturally, intent recognition can be regarded as a typical classification problem. For example, the classification and definition of intent can refer to the ISO-24617-2 standard, which has a total of 56 detailed definitions. The definition of intent has a lot to do with the positioning of the system itself and the knowledge base it possesses, that is, the definition of intent has a very strong domain relevance. It can be understood that in the embodiments of the present application, the classification and definition of intent are not limited to the ISO-24617-2 standard.

[0037] Slots are the parameters of an intent. One intent may correspond to several slots. For example, when asking for bus routes, you need to provide necessary parameters such as the departure point, destination, and time. These parameters are the slots corresponding to the intent "Ask for bus routes."

[0038] For example, the main goal of the semantic slot filling task is to extract the value of a predefined semantic slot in a given domain or intent-specific semantic frame from the input sentence. This task can be transformed into a sequence labeling task, using the classic IOB tagging method to mark whether a word is the beginning (begin), continuation (inside), or non-semantic slot (outside) of a semantic slot.

[0039] To make a system work properly, you first need to design intents and slots. Intents and slots allow the system to know which specific task to perform and give the types of parameters required to perform the task.

[0040] Taking the specific requirement of "asking about the weather" as an example, this article introduces the design of intents and slots in a task-oriented dialogue system:

[0041] User input example: "What's the weather like in Shanghai today?"

[0042] User intent definition: Ask for weather, Ask_Weather;

[0043] Slot definition: Slot 1: Time, Date; Slot 2: Location, Location.

[0044] For example, Figure 1 As shown in the example, two necessary slots are defined for the "Ask Weather" task, namely "Time" and "Location".

[0045] (2) Intent Recognition and Slot Filling

[0046] After defining the intent and slots, you can identify the user intent and the corresponding slot value from the user input.

[0047] The goal of intent recognition is to identify user intent from input. A single task can be simply modeled as a binary classification problem. For example, the intent "ask about the weather" can be modeled as a binary classification problem: "Is it asking about the weather?" or "Is it not asking about the weather?" When a system needs to handle multiple tasks, it needs to be able to distinguish between different intents. In this case, the binary classification problem becomes a multi-classification problem.

[0048] The task of slot filling is to extract information from the data and fill it into pre-defined slots, such as Figure 1 The intent and corresponding slots have been defined in the system. For the user input "What's the weather like in Shanghai today", the system should be able to extract "today" and "Shanghai" and fill them into the "time" and "place" slots respectively.

[0049] For example, for the sake of convenience, the following takes the sound pickup device 100 as a smart speaker, the controlled device 200 as a smart door lock, and the smart speaker with a sound pickup as an example. Figure 2 To illustrate the application scenario of this application. It should be noted that the sound pickup device 100 in this application is not limited to smart speakers, and other sound pickup devices with a pickup are all within the scope of the sound pickup device of this application. In addition, the controlled device 200 in this application is not limited to smart door locks, and other controlled devices that can be controlled are all within the scope of the controlled devices of this application.

[0050] For example, Figure 2 A schematic diagram of a scenario provided in an embodiment of the present application. Figure 2 As shown, the sound pickup device 100 is provided with a sound pickup 11. The number of sound pickups 11 can be any number and is not limited here. The sound pickup inlet of the sound pickup 11 can be located on the upper surface of the sound pickup device 100. Alternatively, the sound pickup inlet of the sound pickup 11 can also be located on other surfaces of the sound pickup device 100 and is not limited here.

[0051] For example, a user can control the controlled device 200 through voice control. When the user performs voice control on the controlled device 200, the sound pickup device 100 can collect an audio signal containing the control command through the microphone 11. The sound pickup device 100 can then send the audio signal containing the control command to the server 300. After analyzing and processing the audio signal containing the control command, the server 300 can determine the control command for the controlled device 200 and send the control command to the controlled device 200. The controlled device 200 can then perform the corresponding operation (e.g., unlocking, locking, etc.) according to the control command.

[0052] Optionally, after analyzing and processing the sound signal containing the control instruction, the sound pickup device 100 may determine the control instruction for the controlled device 200 and directly send the control instruction to the controlled device 200. Thereafter, the controlled device 200 may perform a corresponding operation (e.g., unlocking, locking, etc.) according to the control instruction.

[0053] For example, if a criminal learns of the interaction between the user and the controlled device 200 while the user is performing voice control on the controlled device 200, the criminal can then break into the home and steal after learning that the user has left, thereby posing a significant security risk to the user. Furthermore, if the user's home is intruded upon and the user requires the smart device to execute an alarm command, the user must accurately pronounce a clear alarm phrase (e.g., "xx, please help me call the police"), which is bound to anger the criminal, thereby posing a significant security risk to the user.

[0054] In order to reduce the security risks caused by the interaction process between users and smart devices and protect the privacy of users, this application provides a device control method.

[0055] For example, Figure 3 FIG. 1 shows a hardware structure diagram of a sound pickup device 100 provided in an embodiment of the present application. For example, Figure 3 As shown, the sound pickup device 100 can be a smart home device such as a smart speaker, smart TV, smart air conditioner, smart refrigerator, smart light, smart door, smart lock, smart curtain, etc., a wearable electronic device such as smart glasses, smart watch, smart bracelet, etc., a smart phone, tablet computer, laptop computer, personal digital assistant (PDA), in-vehicle device, virtual reality device, augmented reality device, etc., and other electronic devices with sound pickup entrances, etc. This application does not impose any restrictions on this.

[0056] like Figure 3 As shown, the sound pickup device 100 may include a processor 110 , a memory 120 , an audio module 130 , a sound pickup 140 and a communication module 150 .

[0057] The processor 110 may be a general-purpose processor or a dedicated processor. For example, the processor 110 may include a central processing unit (CPU) and / or a baseband processor. The baseband processor may be used to process communication data, and the CPU may be used to implement corresponding control and processing functions, execute software programs, and process data in the software programs.

[0058] Exemplarily, the processor 110 may include one or more processing units. For example, the processor 110 may include one or more of an application processor (AP), a modem, a graphics processing unit (GPU), an image signal processor (ISP), a controller, a video codec, a digital signal processor (DSP), a baseband processor, and / or a neural-network processing unit (NPU). In some embodiments, the sound pickup device 100 may include one or more processors 110. Among them, different processing units may be independent devices or integrated into one or more processors. Exemplarily, the processor 110 may include an application processor AP and a digital signal processor DSP. Among them, the data output by the audio module 130 may first be transmitted to the digital signal processor DSP for processing, and then transmitted to the application processor AP for processing. Thus, the data is pre-processed by the digital signal processor DSP, such as noise reduction, to improve the processing speed.

[0059] The memory 120 may store programs that can be executed by the processor 110. The memory 120 may also store data. The processor 110 may read the data stored in the memory 120. The memory 120 and the processor 110 may be provided separately. Alternatively, the memory 120 may be integrated into the processor 110.

[0060] The sound pickup 140 can also be called a "microphone" or a "microphone" and is used to convert sound signals into electrical signals. The sound pickup device 100 may include one or more sound pickups 140. The sound pickup 140 can collect sounds in the environment in which the sound pickup device 100 is located. Optionally, when the sound pickup device 100 includes multiple sound pickups 140, some of the multiple sound pickups 140 are microphones and another part are microphone arrays. Optionally, all of the multiple sound pickups 140 can be microphones or microphone arrays. Optionally, the sound pickup inlets of the multiple sound pickups 140 can be located on the upper surface, lower surface or side surface of the sound pickup device 100. Optionally, some of the sound pickup inlets of the multiple sound pickups 24 are located on the upper surface, lower surface or side surface of the sound pickup device 100, and another part of the sound pickup inlets are located on other surfaces of the sound pickup device 100.

[0061] The audio module 130 is used to sample the analog sound signal collected by the pickup 140 according to a preset sampling frequency (which can be set by the processor, or set or defaulted at the factory), and convert the sampled analog sound signal into a digital audio signal, and then input the digital audio signal to the processor 110. Optionally, the audio module 130 can also convert the digital audio signal into an analog sound signal and output the analog sound signal to the speaker 150. The audio module 130 is also used to encode and decode the audio signal. In some examples, the audio module 130 can be integrated into the processor 110, or some functions of the audio module 130 can be integrated into the processor 110. In some examples, the audio module 130 may include an analog to digital converter (ADC), i.e., an A / D converter.

[0062] The communication module 150 may include at least one of a mobile communication module and a wireless communication module. When the communication module 150 includes a mobile communication module, the communication module 150 may provide solutions for wireless communications including 2G / 3G / 4G / 5G applied to electronic devices. For example, global system for mobile communications (GSM), general packet radio service (GPRS), code division multiple access (CDMA), wideband code division multiple access (WCDMA), time-division code division multiple access (TD-SCDMA), long term evolution (LTE), new radio (NR), etc.

[0063] The communication module 150 may include at least one filter, a switch, a power amplifier, a low noise amplifier (LNA), etc. The communication module 150 may receive electromagnetic waves through at least one antenna, filter, amplify, and perform other processing on the received electromagnetic waves, and transmit them to the modem for demodulation. The communication module 150 may also amplify the signal modulated by the modem and convert it into electromagnetic waves for radiation through the antenna. In some examples, at least some functional modules of the communication module 150 may be set in the processor 110. In some examples, at least some functional modules of the communication module 150 may be set in the same device as at least some modules of the processor 110. When the communication module 150 includes a wireless communication module, the communication module 150 can provide wireless communication solutions including wireless local area networks (WLAN) (such as wireless fidelity (Wi-Fi) networks), Bluetooth (BT), global navigation satellite system (GNSS), frequency modulation (FM), near field communication (NFC), infrared technology (IR), etc., which are applied to the sound pickup device 100. The communication module 150 can be one or more devices integrating at least one communication processing module. The communication module 150 receives electromagnetic waves via an antenna, frequency modulates and filters the electromagnetic wave signals, and sends the processed signals to the processor 110. The communication module 150 can also receive the signal to be sent from the processor 110, frequency modulate it, amplify it, and convert it into electromagnetic waves for radiation through the antenna. Exemplarily, the communication module 150 can send the digital audio signal converted by the audio module 130 to the server 300.

[0064] Optionally, the sound pickup device 100 can communicate with external devices through various interfaces, such as a universal serial bus (USB) interface, an Ethernet interface, a FireWire interface, etc.

[0065] It is understood that the structure illustrated in the embodiments of the present application does not constitute a specific limitation on the sound pickup device 100. In other embodiments of the present application, the sound pickup device 100 may include more or fewer components than shown, or may combine or separate certain components, or may have different component arrangements. The illustrated components may be implemented in hardware, software, or a combination of software and hardware. In some embodiments, the hardware structure of the controlled device 200 may be the same as that of the sound pickup device 100, or may have more or fewer components than the sound pickup device 100, without limitation herein.

[0066] For example, Figure 4 FIG. 1 shows a hardware structure diagram of a server 300 provided in an embodiment of the present application. Figure 4 As shown, Figure 4 As shown, the server 300 may include: a processor 310 , a network interface 320 , and a memory 330 .

[0067] The processor 310 may be a general-purpose processor or a dedicated processor. For example, the processor 210 may include a central processing unit (CPU) and / or a baseband processor. The baseband processor may be used to process communication data, and the CPU may be used to implement corresponding control and processing functions, execute software programs, and process data of software programs. Exemplarily, the processor 310 may perform speech-to-text (STT), natural language understanding (NLU) on the audio signal received by the network interface 320, and determine the controlled device to be controlled, the function to be performed, and / or the action to be performed, and generate control instructions, etc.

[0068] The network interface 320 may optionally include a standard wired interface, a wireless interface (such as Wi-Fi, a mobile communication interface, etc.), and is controlled by the processor 310 to send and receive data, for example, receiving a digital audio signal sent by the communication module 150 in the sound pickup device 100 from the network, or sending a control instruction to the controlled device 200, etc.

[0069] The memory 330 may store a program that can be executed by the processor 310, so that the processor 310 performs the method provided in this application. The memory 330 may also store data (for example, a secret code library pre-set by the user, a domain hot word library, etc.). The processor 310 may read the data stored in the memory 330. The memory 330 and the processor 310 may be set separately. Alternatively, the memory 330 may also be integrated into the processor 310.

[0070] It should be understood that the structure illustrated in the embodiments of the present application does not constitute a specific limitation on the server 300. In other embodiments of the present application, the server 300 may include more or fewer components than shown, or may combine or separate certain components, or arrange the components differently. The illustrated components may be implemented in hardware, software, or a combination of software and hardware.

[0071] The following combination Figure 5 , the technical solution provided by this application is described in detail. For example, Figure 5 FIG. 1 shows a flow chart of a device control method provided in an embodiment of the present application. Figure 5 As shown, the method may include the following steps:

[0072] S1. Codeword configuration steps.

[0073] Specifically, a codeword refers to a secret phrase agreed upon for interacting with a smart device. The codeword configuration step is primarily used to configure the secret phrase for interacting with the smart device. For example, the codeword "sesame" can represent "smart door lock," the codeword "flowers bloom" can represent "unlock," and the codeword "flowers fall" can represent "lock." The codeword "sesame flowers bloom" represents "smart door lock unlock," while the codeword "sesame flowers fall" represents "smart door lock lock lock."

[0074] It should be noted that S1 is not a necessary step of the method, that is, S1 does not need to be executed every time the method is executed.

[0075] After the codeword is configured, you can execute S2.

[0076] S2: Steps of identifying and responding to the collected audio signal containing the codeword.

[0077] Specifically, the steps for identifying and responding to the collected audio signal containing the coded message are used to detect control information corresponding to the collected audio signal containing the coded message and respond accordingly after the user utters a voice message containing the coded message. For example, the control information may include the controlled device to be controlled, the function to be executed, and / or the action to be performed. For example, after detecting the control information corresponding to the collected audio signal containing the coded message, an operation instruction may be sent to the controlled device.

[0078] The following combination Figure 6 , the codeword configuration step in the device control method provided by this application is described in detail. For example, Figure 6 This is a flow chart of the codeword configuration steps in the device control method provided in the embodiment of this application. Figure 6In the process shown, the electronic device may have a display screen, and a smart home client may be installed on the electronic device. The smart home client may be software running on the electronic device and a unified management platform for smart devices, which can achieve interconnection between smart devices; wherein the smart home client may correspond to a server. For example, the smart home client may be a Huawei Smart Life client. In addition, Figure 6 In the process shown, the number of codewords set by the user is n, where n is a positive integer greater than or equal to 1.

[0079] like Figure 6 As shown in (A), the codeword configuration step may include:

[0080] S11. The electronic device receives a user's configuration operation on n code words.

[0081] Specifically, the user can open a smart home client on the electronic device and configure the codeword in the smart home client. When the user configures the codeword, the electronic device can receive the user's configuration operations on n codewords.

[0082] For example, Figure 7 As shown in (A), the user can select the smart home application on the electronic device a. Figure 7 As shown in (B), the main interface of the smart home application can be displayed on the electronic device a. Figure 7 In the interface shown in (B), the user can select "My" below the main interface of the smart home application. Figure 7 As shown in (C), the electronic device a may display a sub-page of "My", in which the user may select a "Settings" button. Subsequently, the electronic device a may display a sub-page of "My". Figure 7 The interface shown in (D). Figure 7 In the interface shown in (D), the user can select "Codeword Settings" to enter the codeword settings interface, that is, Figure 7 The interface shown in (F). Figure 7 In the interface shown in (F), the user can set the codeword. After the setting is completed, select the "Save" button in area b to complete the codeword configuration operation. Figure 7 In the interface shown in (F), the user can choose to delete the set codeword or add a new codeword. Figure 7 In the interface shown in (F), users can associate code words with devices, functions, actions, scenarios, etc.

[0083] For example, as shown in Table 1, the code word can be "Sesame", the corresponding target device can be "Smart Desk Lamp", the corresponding target function can be "Empty" (i.e., it does not correspond to any target function), the corresponding target action can be "Empty" (i.e., it does not correspond to any target action), and the corresponding target scene can be "Empty" (i.e., it does not correspond to any target scene). The code word can be "Flowers Bloom", the corresponding target device can be "Empty" (i.e., it does not correspond to any target device), the corresponding target function can be "Switch", the corresponding target action can be "Turn on", and the corresponding target scene can be "Empty".

[0084] Table 1

[0085] code word Target device Target function Target Action Target scenario Sesame Smart desk lamp null null null bloom null switch Open null Flowers fall null switch closure null My mother security equipment null null null Buy fruit null Call the police null null Going out null null Open null go home null null closure null Oyeye null null null Leaving home O'lala null null null go home

[0086] S12. The electronic device sends n code words to the server.

[0087] Specifically, after receiving the user's configuration operation on n code words, the electronic device can send the n code words to the server corresponding to the smart client. The server can be a cloud server or a local server.

[0088] S13. The server checks the validity of the n codewords and stores the valid codewords in the codeword database.

[0089] Specifically, after receiving n code words sent by the electronic device, the server may detect the n code words to determine whether the n code words are legal, and store the legal code words in a code word library.

[0090] For example, a codeword may have the following restrictions: 1) it must be greater than or equal to 2 syllables; 2) it cannot use a smart wake-up word; 3) it cannot use a hot word from a hot word library in a mainstream field, where mainstream fields may include home, music, audio, calls, alarm clocks, encyclopedias, etc. Since monosyllabic codewords are prone to mismatching, codewords must be greater than or equal to 2 syllables. Since the codeword is a smart wake-up word, it is easy to confuse the codeword with the wake-up word, resulting in mismatching, the codeword cannot be the same as the smart wake-up word. In addition, since words in the hot word library of mainstream fields are used more frequently, mismatching is also likely to occur. Therefore, codewords cannot be words from the mainstream hot word library.

[0091] After receiving the secret phrases, the server can detect each secret phrase based on the above - mentioned restrictive conditions to determine whether each secret phrase is legal. For example, when the secret phrase is a monosyllabic word such as "sky", "earth" or "person", it can be determined that the secret phrase is illegal; when the intelligent wake - up word is "Xiaoyi", if the secret phrase is "Xiaoyi", it can be determined that the secret phrase is illegal; when the hot words in the mainstream field hot - word library are "play" and "listen to music", if the secret phrase is "play", it can be determined that the secret phrase is illegal.

[0092] In one example, the server can also send the detected legal secret phrases to the local device so that the local device stores the legal secret phrases in the secret - phrase library on the local device; at the same time, the server deletes the information related to the legal secret phrases on it, thereby enhancing data security. Exemplarily, the local device can be a local server or other devices such as a sound - picking device.

[0093] S14. The server sends information that k out of n secret phrases are illegal to the electronic device, where 0 ≤ k ≤ n; and stores (n - k) legal secret phrases.

[0094] Specifically, when the server detects that k out of n secret phrases are illegal, it can send the information that these k secret phrases are illegal to the electronic device. In addition, the server can also store the (n - k) legal secret phrases except for the k secret phrases.

[0095] S15. The electronic device outputs that k secret phrases are illegal.

[0096] Specifically, after receiving the information that k secret phrases are illegal, the electronic device can output that k secret phrases are illegal. Exemplarily, the electronic device can present the information that k secret phrases are illegal to the user in text form or broadcast the information that k secret phrases are illegal by voice, etc.

[0097] Exemplarily, the specific steps of S13 can be as Figure 6 shown in (B) of

[0098] S131. Detect whether the i - th secret phrase among the n secret phrases is monosyllabic, and the initial value of i is 1.

[0099] Specifically, the server can detect the syllables of the i - th secret phrase among the n secret phrases through automatic speech recognition (ASR) technology, and then determine whether the i - th secret phrase among the n secret phrases is monosyllabic, where the initial value of i can be 1. If the i - th secret phrase is not monosyllabic, then execute S132; otherwise, execute S135.

[0100] S132. Detect whether the i - th secret phrase is a wake - up word.

[0101] Specifically, the server may compare the ith codeword with the wake-up word to detect whether the ith codeword is the wake-up word. If the ith codeword is not the wake-up word, then execute S133; otherwise, execute S135.

[0102] S133: Detect whether the i-th codeword is a hot word in a preset hot word library.

[0103] Specifically, the server may compare the i-th codeword with the hotwords in the hotword library of the threshold value to detect whether the i-th codeword is a hotword in the preset hotword library. If the i-th codeword is not a hotword in the preset hotword library, then execute S134; otherwise, execute S135.

[0104] S134. The i-th codeword is legal; i=i+1, and it is determined whether the updated i is less than or equal to n.

[0105] Specifically, when the i-th cipher satisfies all conditions in S131-133, the i-th cipher is legal. At this point, i can be updated, i.e., i=i+1, to determine whether the next cipher is legal. At the same time, it is determined whether the updated i is less than or equal to n. If the updated i is less than or equal to n, the process returns to S131. Otherwise, the process ends, resulting in k illegal ciphers and (nk) legal ciphers, where 0≤k≤n.

[0106] S135. The i-th codeword is illegal; i=i+1, and it is determined whether the updated i is less than or equal to n.

[0107] Specifically, if the i-th ciphertext does not meet any of the conditions in S131-133, the i-th ciphertext is invalid. At this point, i can be updated, i.e., i=i+1, to determine whether the next ciphertext is valid. At the same time, it is determined whether the updated i is less than or equal to n. If the updated i is less than or equal to n, the process returns to S131. Otherwise, the process ends, resulting in k illegal ciphertexts and (nk) valid ciphertexts, where 0≤k≤n.

[0108] It should be noted that Figure 6 The execution order of S131, S132, and S133 shown in (B) can be arbitrarily selected and is not limited here. For example, S132 may be executed first, then S131, and finally S133; or S133 may be executed first, then S132, and finally S131; or S133 may be executed first, then S131, and finally S132, and so on.

[0109] The following combination Figure 8, the steps of identifying and responding to the collected audio signal containing the codeword in the device control method provided by this application are described in detail. For example, Figure 8 This is a flow chart of the steps of identifying and responding to the collected audio signal containing the codeword in the device control method provided in the embodiment of the present application. Figure 8 In the process shown, the sound pickup device may be the sound pickup device 100 described above; the controlled device may be the controlled device 200 described above; and the server may be the server 300 described above, wherein the server may be the server corresponding to the smart home client described above.

[0110] like Figure 8 As shown in (A), the steps of identifying and responding to the collected audio signal containing the codeword may include:

[0111] S21. A sound pickup device receives a first voice message including a code word sent by a user.

[0112] Specifically, the sound pickup device can continuously or periodically pick up sounds in the environment. When the user sends a first voice containing a codeword, the sound pickup device can receive the first voice containing the codeword sent by the user and convert the first voice from an analog sound signal into a digital sound signal.

[0113] It is understood that the first voice may include the identity of the controlled device that the user intends to control, and the identity may be represented by, but is not limited to, a code word. For example, referring to Table 1 above, the code word "sesame" may represent "smart desk lamp," in which case "sesame" is the identity of "smart desk lamp."

[0114] S22: The sound pickup device sends a first voice to the server.

[0115] Specifically, after the sound pickup device receives the first voice sent by the user, the first voice can be sent to the server for analysis and processing by the server. For example, the first voice can be a digital sound signal.

[0116] S23: The server recognizes the first voice and determines a control instruction.

[0117] Specifically, after receiving the first voice, the server can recognize the first voice, determine the user's intention and the code words contained in the first voice, and when the user's intention is to control the smart home, match each code word to the home domain slot corresponding to the home domain, and then determine the corresponding control instructions and the controlled device that the user intends to control.

[0118] S24. The server sends a control instruction to the controlled device.

[0119] Specifically, after the server determines the control instruction, it can send the control instruction to the controlled device.

[0120] S25. The controlled device executes the control instruction.

[0121] Specifically, after the controlled device receives the control instruction, it can execute the control instruction. For example, when the controlled device is an intelligent door lock, if the control instruction is to unlock, the intelligent door lock will open.

[0122] Exemplarily, the specific steps of S23 can be as Figure 8 shown in (B). Specifically, S23 may include:

[0123] S231. Convert the first voice into a text sentence.

[0124] Specifically, after the server receives the first voice, it can perform a speech-to-text (STT) operation on the first voice, thereby converting the first voice into a text sentence.

[0125] S232. Segment the converted text sentence to obtain p words, where p≥1 and p is a positive integer.

[0126] Specifically, after the server obtains the text sentence corresponding to the first voice, it can segment the text sentence through natural language understanding (NLU) to divide the text sentence into p words.

[0127] S233. Perform an encrypted phrase association match on the p words to obtain the words corresponding to j encrypted phrases, where 0≤j≤p.

[0128] Specifically, after the server obtains the p words, it can match the p words with the encrypted phrases in the encrypted phrase library pre-configured by the user respectively, thereby obtaining the words corresponding to j encrypted phrases.

[0129] Exemplarily, taking the encrypted phrase library pre-configured by the user as Table 1 above, when the first voice is "Sesame flowers bloom", after segmenting "Sesame flowers bloom", two words "sesame" and "bloom" are obtained. Both of these two words are in Table 1, so both of these two words are encrypted phrases, that is, the words corresponding to 2 encrypted phrases are obtained.

[0130] When the first voice is "My mom went out to buy fruits", after segmenting "My mom went out to buy fruits", five words "I", "mom", "went out", "buy fruits" and "了" are obtained. It can be known from Table 1 that "My mom", "went out" and "buy fruits" are all encrypted phrases. Therefore, at this time, the words corresponding to 3 encrypted phrases can be obtained.

[0131] S234. Perform domain hot word matching scores on the p words to obtain scores for m domains including the home furnishing domain, where m≥1.

[0132] Specifically, by matching p words with domain hot words respectively, the scores of m domains including the home furnishing domain can be obtained.

[0133] For example, the scores of m domains including the home domain can be determined based on the number of domain hot words matched by p words. For example, when the p words are "nearby," "where," and "buy," and the domain hot words corresponding to the shopping domain are "nearby," "where," and "buy," the score of the shopping domain can be determined to be a full score (e.g., 10 points), and the scores of other domains can be determined to be 0. For example, the m domains can include: home domain, music domain, shopping domain, alarm clock domain, or encyclopedia domain, etc.

[0134] S235. According to the size of j, the score of the home area is modified.

[0135] Specifically, after obtaining j words in S233, it can be known that the first speech contains j code words. At this time, the score of the home field can be corrected according to the size of j and the pre-set home field correction rules.

[0136] For example, the pre-set home domain correction rules may be:

[0137] a. Matching a home codeword keyword: Home domain score × 2;

[0138] b. Matching two home codeword keywords: Home domain score × 5;

[0139] c. Matching three or more home code keywords: Home domain score × 10.

[0140] If the score of the home area obtained in S2324 is 0.2 and j is 2, the corrected score of the home area is 0.2×5=1.

[0141] S236. Determine the field with the highest score based on the scores of the m fields, and obtain the target field.

[0142] Specifically, after obtaining the scores of the m domains and the revised score of the home domain, the domain with the highest score can be selected to obtain the target domain. For example, this step can be understood as the process of determining the user's intention, that is, the target domain is regarded as the user's intention.

[0143] S237: Determine whether the target domain is the home domain.

[0144] Specifically, after obtaining the target domain, it can be determined whether the target domain is the home domain. If not, S238 is executed, that is, skills corresponding to non-home domains, such as shopping skills, are executed; otherwise, the scene corresponding to the home domain is executed, that is, S239 is executed. For example, if the target domain obtained is the encyclopedia domain, it can be determined that the target domain is not the home domain, and S238 is executed. If the target domain obtained is the home domain, it can be determined that the target domain is the home domain, and S239 is executed.

[0145] S238. Perform non-home skills.

[0146] Specifically, when it is determined that the target domain is not the home domain, the skills corresponding to the non-home domain are executed. For example, when the target domain is the shopping domain, the shopping skills corresponding to the shopping domain are executed.

[0147] S239. According to the pre-configured codeword library, the words corresponding to the j codewords are matched to the home skill slots to obtain the home skill slot information.

[0148] Specifically, after determining that the skills corresponding to the home field need to be executed, the words corresponding to the j codes can be matched to the home skill slots according to the pre-configured code library to obtain the home skill slot information.

[0149] For example, if the user's pre-configured codeword library can be Table 1 above, and the slots of the home skill are: <target device><target action><target function>, when j words are "sesame" and "flowers bloom", "sesame" can be matched to "smart desk lamp", and the target device slot matching in the home skill is completed; "flowers bloom" can be matched to "switch", and the target function slot matching in the home skill is completed; "flowers bloom" can be matched to "turn on", and the target action slot matching in the home skill is completed. At this time, the home skill slot information is: the target device is a smart desk lamp, the target function is a switch, and the target action is turn on. Among them, the process of matching the words corresponding to the j codewords to the home skill slots can be understood as the process of filling the slots.

[0150] S2310: Convert the obtained home skill slot information into control instructions.

[0151] Specifically, after obtaining the home skill slot information, the home skill slot information can be converted into a control instruction. For example, when the home skill slot information is "target device is smart desk lamp, target function is switch, and target action is turn on", the control instruction can be "turn on the smart desk lamp".

[0152] It is understandable that the above S233 and S234 can be performed simultaneously or in different time periods, which is not limited here. In addition, in the embodiment of the present application, each field can have a corresponding skill slot.

[0153] It is understandable that after using code words to express smart home operations, there may be multiple code words in a complete home control expression, which may result in an expression that no longer contains hot word information in the smart home field. The speech recognition system scores the field to which a sentence belongs based on the probability of hot words in different fields, thereby determining which field a sentence should ultimately be identified as. In this way, when a complete home control expression contains multiple code words, it is easy to give priority to matching to fields such as chatting and encyclopedias, which will cause the code word home control field function to fail. This application introduces a home field scoring correction mechanism. When the user's first voice containing a code word matches the code word, the server can score and correct the text sentence corresponding to the first voice according to the rules for the home field, making the expression of the code word easier to match to the home field and avoiding the failure of the code word control.

[0154] It should be noted that, when the server corresponding to the smart home client sends the qualified codeword to the local device during the codeword configuration phase, Figure 8 The server described in the above can be replaced by a local device, such as a local server. In addition, if the local device is a sound pickup device, then Figure 8 After the sound pickup device obtains the first voice, the sound pickup device can recognize the first voice, determine the control instruction, and send the control instruction to the controlled device.

[0155] The above is an introduction to the device control method provided by this application. To facilitate understanding, the following scenarios are used to illustrate.

[0156] Scene 1

[0157] In this scenario, the first voice message received by the sound pickup device is: "Where can I buy fruit nearby?" The pre-configured codeword library is as shown in Table 1 above. The home domain correction rule is the rule described in S235 above.

[0158] like Figure 9 As shown, after receiving the first voice sent by the sound pickup device, the server can perform the following steps:

[0159] S901. Convert the first speech "Where can I buy fruit nearby" into a text sentence.

[0160] S902. Break down the sentence into five words: “nearby”, “where”, “can”, “buy” and “fruit”.

[0161] S903. Call the pre-configured codeword library and find the definition of the word "buy fruit" in the word library. The codeword can be matched with the text word decomposition results of "buy" and "fruit". The number of codeword matches is counted as 1.

[0162] S904. Hot word scoring is performed on the segmented words generated in S902. Among them, "nearby", "where" and "buy" are combined into hot words in the shopping field, with a score of 0.8. The matching degree of hot words in other fields is not strong, with an average score of no more than 0.2. There are no matching hot words in the home furnishing field, with a score of 0.1.

[0163] S905. Correct the score of the home furnishing domain. Since there is a code word match, according to the score correction formula: 0.1×2=0.2, the score of the home furnishing domain is corrected to 0.2.

[0164] S906. Decision is made based on the scoring results of each field. The shopping field has a score of 0.8, which is the highest value.

[0165] S907. Execute shopping skills.

[0166] Specifically, the server can pass the parsed related words to the shopping skill for further processing. The shopping skill may call the system of a third-party product operator to query the distribution address of fruit suppliers, and then push a list of nearby fruit suppliers to the user based on the user's home location information.

[0167] Scene 2

[0168] In this scenario, the first voice message received by the user is: "My mother went out to buy fruit." The pre-configured codeword library is as shown in Table 1 above. The home domain correction rule is the rule described in S235 above.

[0169] like Figure 10 As shown, after receiving the first voice sent by the sound pickup device, the server can perform the following steps:

[0170] S1001. Convert the first speech “My mother went out to buy fruit” into a text sentence.

[0171] S1002. Break down the sentence into six words: "I", "Mom", "go out", "buy", "fruit", and "go".

[0172] S1003. Call the pre-configured codeword library and find the definitions of the three words "my mother", "going out", and "buying fruit" in the word library. The three words "I", "mother", "going out", "buying", and "fruit" can be matched with the text word decomposition results. At this time, the number of codeword matches is counted as 3.

[0173] S1004. Score the hot words for the segmented words generated in S1002. No key hot words from any field appear in this expression, and the scores for common fields are no higher than 0.2. In this case, the system defaults to the chat field score with the highest confidence score, which is about 0.4 to 0.5. There are no matching hot words in the home field, and the score is 0.1.

[0174] S1005. Correct the home domain score. Since there are three codeword matches, the home domain score is corrected to 1 according to the score correction formula: 0.1×10=1.

[0175] S1006. Decision is made based on the scoring results of each field, with the home field scoring 1 being the highest value.

[0176] S1007. Execute the home skill and replace the result of the codeword matching to the home skill slot.

[0177] Specifically, the matching information based on the household codeword database is as follows:

[0178] "My Mom" matches "Security Equipment", and the target device slot in the Home Skill is matched;

[0179] "Buy Fruit" matches "Alarm", and the target function slot in the home skill is matched;

[0180] "Go out" is matched to "Turn on", and the target action slot in the home skill is matched.

[0181] S1008. The expression after completing the codeword slot matching is: <target device><target action><target function> "went".

[0182] S1009: Convert the extracted home control slot information into a smart home control command and issue it for execution.

[0183] Specifically, the converted control command can be "activate the security device alarm." Thus, if the user's first voice message is "My mom is out buying fruit," the security device can activate the alarm, thus enabling a family code alarm. After an unexpected home invasion, a code alarm can be issued using a common code to avoid alerting criminals.

[0184] Based on the method in the above embodiment, the present application embodiment also provides a chip. Figure 11 , Figure 11 This is a schematic diagram of the structure of a chip provided in an embodiment of the present application. Figure 11 As shown, the chip 1100 includes one or more processors 1101 and an interface circuit 1102. Optionally, the chip 1100 may also include a bus 1103.

[0185] The processor 1101 may be an integrated circuit chip with signal processing capabilities. During implementation, each step of the above method can be completed by an integrated logic circuit of the hardware in the processor 1101 or an instruction in the form of software. The above-mentioned processor 1101 can be a general-purpose processor, a digital communicator (DSP), an application-specific integrated circuit (ASIC), a field programmable gate array (FPGA) or other programmable logic device, a discrete gate or transistor logic device, or a discrete hardware component. The various methods and steps disclosed in the embodiments of the present application can be implemented or executed. The general-purpose processor can be a microprocessor or the processor can also be any conventional processor, etc. The interface circuit 1102 can be used for sending or receiving data, instructions or information. The processor 1101 can use the data, instructions or other information received by the interface circuit 1102 to process, and the processing completion information can be sent out through the interface circuit 1102.

[0186] Optionally, the chip also includes a memory, which may include a read-only memory and a random access memory, and provides operating instructions and data to the processor. A portion of the memory may also include non-volatile random access memory (NVRAM). Optionally, the memory stores executable software modules or data structures, and the processor can perform corresponding operations by calling operating instructions stored in the memory (the operating instructions may be stored in the operating system).

[0187] Optionally, the interface circuit 1102 may be configured to output the execution result of the processor 1101 .

[0188] It should be noted that the corresponding functions of the processor 1101 and the interface circuit 1102 can be implemented through hardware design, software design, or a combination of hardware and software, and there is no limitation here.

[0189] It should be understood that each step of the above method embodiment can be completed by a hardware-based logic circuit or a software-based instruction in a processor. In particular, the chip can be applied to the above server 300 to implement the method provided in the embodiment of the present application.

[0190] It is understood that the processor in the embodiments of the present application may be a central processing unit (CPU), or may be other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field programmable gate arrays (FPGA), or other programmable logic devices, transistor logic devices, hardware components, or any combination thereof. The general-purpose processor may be a microprocessor or any conventional processor.

[0191] The method steps in the embodiments of the present application can be implemented by hardware or by a processor executing software instructions. The software instructions can be composed of corresponding software modules, which can be stored in random access memory (RAM), flash memory, read-only memory (ROM), programmable read-only memory (PROM), erasable programmable read-only memory (EPROM), electrically erasable programmable read-only memory (EEPROM), registers, hard disks, mobile hard disks, CD-ROMs or any other form of storage medium known in the art. An exemplary storage medium is coupled to a processor so that the processor can read information from the storage medium and write information to the storage medium. Of course, the storage medium can also be a component of the processor. The processor and the storage medium can be located in an ASIC.

[0192] In the above embodiments, it can be implemented in whole or in part by software, hardware, firmware or any combination thereof. When implemented using software, it can be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, the process or function described in the embodiment of the present application is generated in whole or in part. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions can be stored in a computer-readable storage medium or transmitted via the computer-readable storage medium. The computer instructions can be transmitted from one website, computer, server or data center to another website, computer, server or data center via a wired (e.g., coaxial cable, optical fiber, digital subscriber line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) method. The computer-readable storage medium can be any available medium that a computer can access or a data storage device such as a server or data center that includes one or more available media integrated. The available medium can be a magnetic medium (e.g., a floppy disk, a hard disk, a tape), an optical medium (e.g., a DVD), or a semiconductor medium (e.g., a solid state drive (SSD)).

[0193] It will be understood that the various numerical numbers involved in the embodiments of the present application are merely distinctions for the convenience of description and are not intended to limit the scope of the embodiments of the present application.

Claims

1. A device control method, applied to a server, characterized in that: The method comprises: Obtaining n code words configured by the user through the electronic device, where n is a positive integer greater than or equal to 1; Detecting the legitimacy of the n codewords and storing the legal codewords in a codeword library; When k of the ciphers are illegal among the n ciphers, outputting the k ciphers; Acquiring, through at least one sound pickup device, a first voice uttered by a user, wherein the first voice contains an identity identifier of a controlled device and at least one codeword; Processing the first speech to obtain m scores for m domains, where the m domains are domains corresponding to the intent expressed by the first speech, the m domains include a home domain, and m is a positive integer greater than or equal to 1; Modifying the score of the home domain according to the first speech; determining a target domain according to the corrected score of the home domain and the scores of m-1 domains other than the home domain; When the target domain is a home domain, obtaining a target control instruction according to the first voice and the pre-configured codeword library; outputting the target control instruction; The step of modifying the score of the home domain according to the first speech specifically includes: Matching the p words contained in the first speech with the code words in the code word library respectively to obtain the number of code words contained in the first speech, where p is a positive integer greater than or equal to 1; The score of the home domain is modified according to the number of code words contained in the first speech.

2. The method according to claim 1, characterized in that The target domain is determined based on the revised score of the home domain and the scores of m-1 domains other than the home domain, specifically including: The field with the highest score is selected as the target field.

3. The method according to claim 1 or 2, characterized in that Obtaining a target control instruction according to the first voice and the pre-configured codeword library specifically includes: Determining j code words contained in the first speech, where j is a positive integer greater than or equal to 1; The j code words are matched with the code word library to obtain the target control instruction, wherein the code word library includes a correspondence between code words and target data, and the target data includes one or more of equipment, functions, services and scenarios.

4. The method according to claim 3, characterized in that Matching the j codewords with the codeword library to obtain the target control instruction specifically includes: According to the correspondence between the code words in the code word library and the target data, the words corresponding to the j code words are matched to the home skill slots corresponding to the home field to obtain the home skill slot information; The target control instruction is obtained according to the home skill slot information.

5. The method according to claim 4, characterized in that For the i-th cipher among the n ciphers, detecting the legitimacy of the i-th cipher specifically includes: Detecting whether the i-th codeword satisfies a preset condition, wherein the preset condition is one or more of the following: the codeword is polysyllabic, the codeword is different from the wake-up word, or the codeword is different from a hot word in a preset hot word library; If the i-th codeword meets the preset conditions, the i-th codeword is legal; If the i-th cipher does not meet the preset condition, the i-th cipher is illegal.

6. The method according to claim 5, characterized in that The identity of the controlled device is represented by a code word.

7. A server, characterized in that: include: at least one memory for storing a program; At least one processor is used to execute the program stored in the memory. When the program stored in the memory is executed, the processor is used to execute the method according to any one of claims 1 to 6.

8. A computer-readable storage medium storing a computer program, wherein when the computer program is executed on an electronic device, the electronic device is caused to execute the method according to any one of claims 1 to 6.

9. A computer program product, characterized in that When the computer program product is run on an electronic device, the electronic device is enabled to perform the method according to any one of claims 1 to 6.

Citation Information

Patent Citations

  • Speech recognition method and device, computer readable storage medium and computer device

    CN108711422A

  • Terminal control method and device, intelligent terminal and computer readable storage medium

    CN111933135A

  • Voice understanding method and device

    CN112740323A