CN115810356A - Voice control method, device, storage medium and electronic equipment - Google Patents
Voice control method, device, storage medium and electronic equipment Download PDFInfo
- Publication number
- CN115810356A CN115810356A CN202211443786.5A CN202211443786A CN115810356A CN 115810356 A CN115810356 A CN 115810356A CN 202211443786 A CN202211443786 A CN 202211443786A CN 115810356 A CN115810356 A CN 115810356A
- Authority
- CN
- China
- Prior art keywords
- equipment
- voice
- current
- interaction
- state
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
- 238000000034 method Methods 0.000 title claims abstract description 99
- 230000003993 interaction Effects 0.000 claims abstract description 309
- 230000002452 interceptive effect Effects 0.000 claims description 44
- 238000004891 communication Methods 0.000 claims description 20
- 238000004590 computer program Methods 0.000 claims description 2
- 238000012544 monitoring process Methods 0.000 claims 3
- 238000012545 processing Methods 0.000 description 14
- 230000006870 function Effects 0.000 description 13
- 238000010586 diagram Methods 0.000 description 10
- 230000008569 process Effects 0.000 description 6
- 230000007613 environmental effect Effects 0.000 description 4
- 238000005286 illumination Methods 0.000 description 4
- 230000002829 reductive effect Effects 0.000 description 4
- 230000001133 acceleration Effects 0.000 description 3
- 230000009471 action Effects 0.000 description 3
- 230000008878 coupling Effects 0.000 description 3
- 238000010168 coupling process Methods 0.000 description 3
- 238000005859 coupling reaction Methods 0.000 description 3
- 238000001514 detection method Methods 0.000 description 3
- 238000005516 engineering process Methods 0.000 description 3
- 230000001360 synchronised effect Effects 0.000 description 3
- 230000005540 biological transmission Effects 0.000 description 2
- 238000011161 development Methods 0.000 description 2
- 238000001228 spectrum Methods 0.000 description 2
- 238000013459 approach Methods 0.000 description 1
- 238000013473 artificial intelligence Methods 0.000 description 1
- 230000002238 attenuated effect Effects 0.000 description 1
- 238000013475 authorization Methods 0.000 description 1
- 230000006399 behavior Effects 0.000 description 1
- 230000009286 beneficial effect Effects 0.000 description 1
- 230000008859 change Effects 0.000 description 1
- 238000013500 data storage Methods 0.000 description 1
- 230000000694 effects Effects 0.000 description 1
- 230000010354 integration Effects 0.000 description 1
- 230000000670 limiting effect Effects 0.000 description 1
- 230000003287 optical effect Effects 0.000 description 1
- 239000013307 optical fiber Substances 0.000 description 1
- 230000003068 static effect Effects 0.000 description 1
Images
Classifications
-
- G—PHYSICS
- G10—MUSICAL INSTRUMENTS; ACOUSTICS
- G10L—SPEECH ANALYSIS TECHNIQUES OR SPEECH SYNTHESIS; SPEECH RECOGNITION; SPEECH OR VOICE PROCESSING TECHNIQUES; SPEECH OR AUDIO CODING OR DECODING
- G10L15/00—Speech recognition
- G10L15/22—Procedures used during a speech recognition process, e.g. man-machine dialogue
Landscapes
- Engineering & Computer Science (AREA)
- Computational Linguistics (AREA)
- Health & Medical Sciences (AREA)
- Audiology, Speech & Language Pathology (AREA)
- Human Computer Interaction (AREA)
- Physics & Mathematics (AREA)
- Acoustics & Sound (AREA)
- Multimedia (AREA)
- Selective Calling Equipment (AREA)
- Telephone Function (AREA)
Abstract
本申请实施例公开了一种语音控制方法、装置、存储介质以及电子设备。首先监测到用户语音满足语音唤醒条件时,若确定当前设备处于第一预设设备状态,则将第一预设设备状态对应的第一设备状态信息发送至候选设备;若接收到候选设备发送的第二设备状态信息,则根据第一预设设备状态以及第二设备状态信息对应的第二预设设备状态,确定当前设备是否进行语音交互。监测到用户语音满足语音唤醒条件时,可以获取当前设备的第一预设设备状态与候选设备的第二预设设备状态,由于设备状态可以代表用户对设备的使用情况,因此根据各设备的设备状态可以确定用户具体想要使用哪个设备进行语音交互,有效提升了语音控制的准确性。
The embodiment of the present application discloses a voice control method, device, storage medium and electronic equipment. First, when it is detected that the user's voice meets the voice wake-up condition, if it is determined that the current device is in the first preset device state, then the first device state information corresponding to the first preset device state is sent to the candidate device; The second device state information determines whether the current device performs voice interaction according to the first preset device state and the second preset device state corresponding to the second device state information. When the user's voice is detected to meet the voice wake-up condition, the first preset device status of the current device and the second preset device status of the candidate device can be obtained. Since the device status can represent the user's usage of the device, according to the device status of each device The status can determine which device the user wants to use for voice interaction, which effectively improves the accuracy of voice control.
Description
技术领域technical field
本申请涉及语音控制技术领域,尤其涉及一种语音控制方法、装置、存储介质以及电子设备。The present application relates to the technical field of voice control, and in particular to a voice control method, device, storage medium and electronic equipment.
背景技术Background technique
随着语音技术的发展以及人们对智能化生活的追求,人们对电子设备的依赖性日益增强。其中,具备语音控制功能的电子设备常常出现语音交互的场景,即用户发出语音控制指令,电子设备根据该控制指令执行相关操作。但是当用户拥有多个具备语音控制功能的电子设备时,需要确定具体由哪个电子设备来执行语音指令。With the development of voice technology and people's pursuit of intelligent life, people's dependence on electronic devices is increasing. Among them, an electronic device with a voice control function often has a scene of voice interaction, that is, a user issues a voice control command, and the electronic device performs a related operation according to the control command. However, when the user has multiple electronic devices with voice control functions, it is necessary to determine which electronic device will execute the voice command.
发明内容Contents of the invention
本申请实施例提供一种语音控制方法、装置、存储介质以及电子设备,可以实现当用户拥有多个具备语音控制功能的电子设备时,准确确定具体由哪个电子设备来执行语音指令。Embodiments of the present application provide a voice control method, device, storage medium, and electronic device, which can accurately determine which electronic device will execute a voice command when a user owns multiple electronic devices with a voice control function.
第一方面,本申请实施例提供一种语音控制方法,所述方法包括:In the first aspect, the embodiment of the present application provides a voice control method, the method comprising:
监测到用户语音满足语音唤醒条件时,判断当前设备是否处于第一预设设备状态;When it is detected that the user's voice meets the voice wake-up condition, it is determined whether the current device is in the first preset device state;
若所述当前设备处于所述第一预设设备状态,则将所述第一预设设备状态对应的第一设备状态信息发送至候选设备,所述候选设备与所述当前设备处于同一多设备场景中;If the current device is in the first preset device state, the first device state information corresponding to the first preset device state is sent to a candidate device, and the candidate device is in the same multiple as the current device. In the equipment scene;
若接收到所述候选设备发送的第二设备状态信息,则根据所述第一预设设备状态以及所述第二设备状态信息对应的第二预设设备状态,确定所述当前设备是否进行语音交互。If the second device state information sent by the candidate device is received, determine whether the current device performs voice according to the first preset device state and the second preset device state corresponding to the second device state information interact.
第二方面,本申请实施例提供一种语音控制方法,所述方法包括:In a second aspect, the embodiment of the present application provides a voice control method, the method comprising:
监测到用户语音满足语音唤醒条件时,判断当前主设备是否处于第一预设设备状态;When it is detected that the user's voice meets the voice wake-up condition, it is judged whether the current master device is in the first preset device state;
若所述当前主设备处于所述第一预设设备状态,且接收到从属设备发送的第二设备状态信息,则根据第一预设设备状态对应的第一设备状态信息以及所述第二设备状态信息,从所述当前主设备以及所述从属设备中确定进行语音交互的目标交互设备;If the current master device is in the first preset device state and receives the second device state information sent by the slave device, according to the first device state information corresponding to the first preset device state and the second device State information, determining a target interactive device for voice interaction from the current master device and the slave device;
基于交互指令控制所述目标交互设备进行语音交互。The target interaction device is controlled to perform voice interaction based on the interaction instruction.
第三方面,本申请实施例提供一种语音控制方法,所述方法包括:In a third aspect, the embodiment of the present application provides a voice control method, the method comprising:
监测到用户语音满足语音唤醒条件时,判断当前从属设备是否处于第二预设设备状态;When it is detected that the user's voice meets the voice wake-up condition, it is determined whether the current slave device is in the second preset device state;
若所述当前从属设备处于所述第二预设设备状态,则将所述当前设备的第二设备状态信息发送至主设备;If the current slave device is in the second preset device state, sending the second device state information of the current device to the master device;
若接收到所述主设备发送的交互指令,则控制所述当前从属设备进行语音交互,其中,所述交互指令为所述主设备根据所述主设备的第一设备状态信息、所述当前从属设备的第二设备状态信息以及其他从属设备的第二设备状态信息生成。If the interaction instruction sent by the master device is received, the current slave device is controlled to perform voice interaction, wherein the interaction instruction is that the master device according to the first device status information of the master device, the current slave device Second device state information of the device and second device state information of other slave devices are generated.
第四方面,本申请实施例提供一种语音控制装置,所述装置包括:In a fourth aspect, the embodiment of the present application provides a voice control device, the device comprising:
语音唤醒模块,用于监测到用户语音满足语音唤醒条件时,判断当前设备是否处于第一预设设备状态;The voice wake-up module is used to determine whether the current device is in the first preset device state when it is detected that the user's voice meets the voice wake-up condition;
设备状态发送模块,用于若所述当前设备处于所述第一预设设备状态,则将所述第一预设设备状态对应的第一设备状态信息发送至候选设备,所述候选设备与所述当前设备处于同一多设备场景中;A device state sending module, configured to send the first device state information corresponding to the first preset device state to a candidate device if the current device is in the first preset device state, and the candidate device is the same as the first preset device state The current device is in the same multi-device scenario;
语音交互确定模块,用于若接收到所述候选设备发送的第二设备状态信息,则根据所述第一预设设备状态以及所述第二设备状态信息对应的第二预设设备状态,确定所述当前设备是否进行语音交互。A voice interaction determining module, configured to determine, according to the first preset device status and the second preset device status corresponding to the second device status information, if the second device status information sent by the candidate device is received Whether the current device performs voice interaction.
第五方面,本申请实施例提供一种语音控制装置,所述装置包括:In a fifth aspect, the embodiment of the present application provides a voice control device, the device comprising:
主设备语音唤醒模块,用于监测到用户语音满足语音唤醒条件时,判断当前主设备是否处于第一预设设备状态;The master device voice wake-up module is used to determine whether the current master device is in the first preset device state when the user's voice meets the voice wake-up condition;
主设备语音交互确定模块,用于若所述当前主设备处于所述第一预设设备状态,且接收到从属设备发送的第二设备状态信息,则根据第一预设设备状态对应的第一设备状态信息以及所述第二设备状态信息,从所述当前主设备以及所述从属设备中确定进行语音交互的目标交互设备;The master device voice interaction determination module is configured to: if the current master device is in the first preset device state and receives the second device state information sent by the slave device, according to the first preset device state corresponding to the first The device state information and the second device state information determine the target interaction device for voice interaction from the current master device and the slave device;
指令控制模块,用于基于交互指令控制所述目标交互设备进行语音交互。An instruction control module, configured to control the target interaction device to perform voice interaction based on the interaction instruction.
第六方面,本申请实施例提供一种语音控制装置,所述装置包括:In a sixth aspect, the embodiment of the present application provides a voice control device, the device comprising:
从属设备语音唤醒模块,用于监测到用户语音满足语音唤醒条件时,判断当前从属设备是否处于第二预设设备状态;The slave device voice wake-up module is used to determine whether the current slave device is in the second preset device state when the user's voice meets the voice wake-up condition;
从属设备状态发送模块,用于若所述当前从属设备处于所述第二预设设备状态,则将所述当前设备的第二设备状态信息发送至主设备;A slave device status sending module, configured to send second device status information of the current device to a master device if the current slave device is in the second preset device status;
从属设备语音交互模块,用于若接收到所述主设备发送的交互指令,则控制所述当前从属设备进行语音交互,其中,所述交互指令为所述主设备根据所述主设备的第一设备状态信息、所述当前从属设备的第二设备状态信息以及其他从属设备的第二设备状态信息生成。The voice interaction module of the slave device is configured to control the current slave device to perform voice interaction if an interaction instruction sent by the master device is received, wherein the interaction instruction is the master device according to the first Device status information, second device status information of the current slave device, and second device status information of other slave devices are generated.
第七方面,本申请实施例提供一种计算机存储介质,所述计算机存储介质存储有多条指令,所述指令适于由处理器加载并执行上述的方法的步骤。In a seventh aspect, the embodiment of the present application provides a computer storage medium, where a plurality of instructions are stored in the computer storage medium, and the instructions are suitable for being loaded by a processor and executing the steps of the above method.
第八方面,本申请实施例提供一种电子设备,包括存储器、处理器及存储在存储器上并可在处理器上运行的计算机程序。In an eighth aspect, the embodiment of the present application provides an electronic device, including a memory, a processor, and a computer program stored in the memory and operable on the processor.
本申请实施例一些实施例提供的技术方案带来的有益效果至少包括:The beneficial effects brought by the technical solutions provided by some embodiments of the embodiments of the present application at least include:
在本申请实施例中,首先监测到用户语音满足语音唤醒条件时,判断当前设备是否处于第一预设设备状态;然后若当前设备处于第一预设设备状态,则将第一预设设备状态对应的第一设备状态信息发送至候选设备,候选设备与当前设备处于同一多设备场景中;最后若接收到候选设备发送的第二设备状态信息,则根据第一预设设备状态以及第二设备状态信息对应的第二预设设备状态,确定当前设备是否进行语音交互。监测到用户语音满足语音唤醒条件时,可以获取当前设备的第一预设设备状态与候选设备的第二预设设备状态,由于设备状态可以代表用户对设备的使用情况,因此根据各设备的设备状态可以确定用户具体想要使用哪个设备进行语音交互,有效提升了语音控制的准确性。In this embodiment of the application, firstly, when the user's voice is detected to meet the voice wake-up condition, it is judged whether the current device is in the first preset device state; then if the current device is in the first preset device state, the first preset device state is set to The corresponding first device state information is sent to the candidate device, and the candidate device and the current device are in the same multi-device scene; finally, if the second device state information sent by the candidate device is received, according to the first preset device state and the second The second preset device state corresponding to the device state information determines whether the current device performs voice interaction. When the user's voice is detected to meet the voice wake-up condition, the first preset device status of the current device and the second preset device status of the candidate device can be obtained. Since the device status can represent the user's usage of the device, according to the device status of each device The status can determine which device the user wants to use for voice interaction, which effectively improves the accuracy of voice control.
附图说明Description of drawings
为了更清楚地说明本申请实施例或现有技术中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请实施例的一些实施例,对于本领域技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。In order to more clearly illustrate the technical solutions in the embodiments of the present application or the prior art, the following will briefly introduce the drawings that need to be used in the description of the embodiments or the prior art. Obviously, the accompanying drawings in the following description are only These are some embodiments of the embodiments of the present application. For those skilled in the art, other drawings can also be obtained according to these drawings without creative work.
图1为本申请实施例提供的相关技术中的一种设备交互方法;FIG. 1 is a device interaction method in the related art provided by the embodiment of the present application;
图2为本申请实施例提供的一种语音控制方法的示例性系统架构图;FIG. 2 is an exemplary system architecture diagram of a voice control method provided by an embodiment of the present application;
图3为本申请实施例提供的一种语音控制方法的流程示意图;FIG. 3 is a schematic flowchart of a voice control method provided in an embodiment of the present application;
图4为本申请实施例提供的一种设备交互方法;FIG. 4 is a device interaction method provided by an embodiment of the present application;
图5为本申请另一实施例提供的一种语音控制方法的流程示意图;FIG. 5 is a schematic flowchart of a voice control method provided by another embodiment of the present application;
图6为本申请另一实施例提供的一种语音控制方法的流程示意图;FIG. 6 is a schematic flowchart of a voice control method provided by another embodiment of the present application;
图7为本申请另一实施例提供的一种语音控制装置的结构框图;FIG. 7 is a structural block diagram of a voice control device provided by another embodiment of the present application;
图8为本申请另一实施例提供的一种语音控制方法的流程示意图;FIG. 8 is a schematic flowchart of a voice control method provided by another embodiment of the present application;
图9为本申请另一实施例提供的一种语音控制装置的结构框图;FIG. 9 is a structural block diagram of a voice control device provided by another embodiment of the present application;
图10为本申请另一实施例提供的一种语音控制方法的流程示意图;FIG. 10 is a schematic flowchart of a voice control method provided in another embodiment of the present application;
图11为本申请另一实施例提供的一种语音控制装置的结构框图;FIG. 11 is a structural block diagram of a voice control device provided by another embodiment of the present application;
图12为本申请实施例提供的一种电子设备的结构示意图。FIG. 12 is a schematic structural diagram of an electronic device provided by an embodiment of the present application.
具体实施方式Detailed ways
为使得本申请的特征和优点能够更加的明显和易懂,下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅仅是本申请一部分实施例,而非全部实施例。基于本申请中的实施例,本领域技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都属于本申请保护的范围。In order to make the features and advantages of the present application more obvious and understandable, the technical solutions in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments It is only a part of the embodiments of the present application, but not all the embodiments. Based on the embodiments in this application, all other embodiments obtained by those skilled in the art without making creative efforts belong to the scope of protection of this application.
下面的描述涉及附图时,除非另有表示,不同附图中的相同数字表示相同或相似的要素。以下示例性实施例中所描述的实施方式并不代表与本申请相一致的所有实施方式。相反,它们仅是如所附权利要求书中所详述的、本申请的一些方面相一致的装置和方法的例子。When the following description refers to the accompanying drawings, the same numerals in different drawings refer to the same or similar elements unless otherwise indicated. The implementations described in the following exemplary embodiments do not represent all implementations consistent with this application. Rather, they are merely examples of apparatuses and methods consistent with aspects of the present application as recited in the appended claims.
另外需要说明的是,本申请实施例所涉及的信息(包括但不限于用户设备信息、用户个人信息等)、数据(包括但不限于用于分析的数据、存储的数据、展示的数据等)以及信号,均为经用户授权或者经过各方充分授权的,且相关数据的收集、使用和处理需要遵守相关国家和地区的相关法律法规和标准。例如,本申请中涉及的对象特征、交互行为特征以及用户信息等都是在充分授权的情况下获取的。In addition, it should be noted that the information (including but not limited to user equipment information, user personal information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in the embodiments of this application and signals are authorized by users or fully authorized by all parties, and the collection, use and processing of relevant data need to comply with relevant laws, regulations and standards of relevant countries and regions. For example, the object characteristics, interaction behavior characteristics and user information involved in this application are all obtained under the condition of full authorization.
语音助手是人工智能在电子设备上的重要应用。电子设备通过语音助手可以与用户进行智能对话和即时问答的智能交互。还可以识别用户输入的语音命令,并触发电子设备自动执行该语音命令对应的事件。通常情况下,语音助手是处于休眠状态的,用户在使用语音助手前,可以对语音助手进行语音唤醒。只有在语音助手被唤醒后,才可以接收并识别用户输入的语音命令。用于唤醒的语音数据可以称为唤醒词,例如,以唤醒词为“小布小布”为例,如果用户想要使用语音助手查询A地的天气,则可说出“小布小布,A地的天气”的语音命令,在语音助手接收到该语义命令之后,可以基于唤醒词“小布小布”被唤醒,进而电子设备利用语音助手可以识别该语音命令,并触发电子设备查询A地的天气,并通过语音或者文字向用户播报A地的天气。Voice assistants are an important application of artificial intelligence in electronic devices. Electronic devices can interact intelligently with users through intelligent dialogue and instant question-and-answer through voice assistants. It is also possible to recognize the voice command input by the user, and trigger the electronic device to automatically execute the event corresponding to the voice command. Usually, the voice assistant is in a dormant state, and the user can wake up the voice assistant before using the voice assistant. Only after the voice assistant is woken up can it receive and recognize voice commands input by the user. The voice data used for wake-up can be called a wake-up word. For example, if the wake-up word is "Xiaobu Xiaobu" as an example, if the user wants to use the voice assistant to inquire about the weather in place A, he can say "Xiaobu Xiaobu, After the voice assistant receives the semantic command, the voice command of "weather in place A" can be awakened based on the wake-up word "Xiaobu Xiaobu", and then the electronic device can use the voice assistant to recognize the voice command and trigger the electronic device to query A The weather of the place A, and broadcast the weather of the place A to the user through voice or text.
在相关技术中,随着技术的发展语音控制的应用越来越广泛。如,很多家居设备目前都支持语音控制功能。如可以通过在家居设备中安装语音助手来实现语音控制功能。这样,便会存在用户所处环境中(如用户家中)包括多个支持语音控制功能的设备的场景,即多设备场景。在该多设备场景下,如果这多个设备中存在唤醒词相同的设备,则在用户说出唤醒词后,具有相同唤醒词的设备的语音助手均会被唤醒,并都会对用户后续说出的语音命令进行识别并作出响应。In related technologies, voice control is more and more widely used with the development of technology. For example, many home appliances now support voice control. For example, the voice control function can be realized by installing a voice assistant in the household equipment. In this way, there will be a scenario where the user's environment (such as the user's home) includes multiple devices supporting the voice control function, that is, a multi-device scenario. In this multi-device scenario, if there are devices with the same wake-up word among the multiple devices, after the user speaks the wake-up word, the voice assistants of the devices with the same wake-up word will all be woken up, and they will all follow up with the user. recognizes and responds to voice commands.
请参阅图1,图1为本申请实施例提供的相关技术中的一种设备交互方法。Please refer to FIG. 1 . FIG. 1 is a device interaction method in the related art provided by the embodiment of the present application.
如图1所示,将用户的客厅作为多设备场景,其中,用户家客厅有音箱101,电视机102、手机103以及穿戴手表104四个设备,这四个设备均安装有语音助手,且唤醒词均为“小布小布"。那么当用户说出包含唤醒词“小布小布”的语音控制命令之后,音箱101,电视机102、手机103以及穿戴手表104的语音助手均会被唤醒并识别该语音命令,并对语音命令进行识别并作出响应。As shown in Figure 1, the user's living room is considered as a multi-device scenario. In the living room of the user's home, there are four devices: a
用户在多设备场景中,往往用户可能只需要某一个设备进行响应,例如,当用户正在使用手机时,此时若需要与语音助手进行语音交互时,由于与手机进行交互更加便捷,那么用户往往更加希望手机中的语音助手可以被唤醒并响应用户的控制命令进行语音交互,而如多个设备同时响应,给用户带来的体验较差。In a multi-device scenario, the user may only need a certain device to respond. For example, when the user is using a mobile phone and needs to interact with the voice assistant at this time, since the interaction with the mobile phone is more convenient, the user often It is more hoped that the voice assistant in the mobile phone can be awakened and respond to the user's control commands for voice interaction, but if multiple devices respond at the same time, the experience brought to the user is poor.
针对上述技术问题,在本申请实施例中,首先监测到用户语音满足语音唤醒条件时,判断当前设备是否处于第一预设设备状态;然后若当前设备处于第一预设设备状态,则将第一预设设备状态对应的第一设备状态信息发送至候选设备,候选设备与当前设备处于同一多设备场景中;最后若接收到候选设备发送的第二设备状态信息,则根据第一预设设备状态以及第二设备状态信息对应的第二预设设备状态,确定当前设备是否进行语音交互。监测到用户语音满足语音唤醒条件时,可以获取当前设备的第一预设设备状态与候选设备的第二预设设备状态,由于设备状态可以代表用户对设备的使用情况,因此根据各设备的设备状态可以确定用户具体想要使用哪个设备进行语音交互,有效提升了语音控制的准确性。In view of the above technical problems, in the embodiment of the present application, firstly, when it is detected that the user's voice meets the voice wake-up condition, it is judged whether the current device is in the first preset device state; and then if the current device is in the first preset device state, the second The first device state information corresponding to a preset device state is sent to the candidate device, and the candidate device and the current device are in the same multi-device scene; finally, if the second device state information sent by the candidate device is received, the first preset The device state and the second preset device state corresponding to the second device state information determine whether the current device performs voice interaction. When the user's voice is detected to meet the voice wake-up condition, the first preset device status of the current device and the second preset device status of the candidate device can be obtained. Since the device status can represent the user's usage of the device, according to the device status of each device The status can determine which device the user wants to use for voice interaction, which effectively improves the accuracy of voice control.
请参阅图2,图2为本申请实施例提供的一种语音控制方法的示例性系统架构图。Please refer to FIG. 2 . FIG. 2 is an exemplary system architecture diagram of a voice control method provided by an embodiment of the present application.
如图2所示,系统架构可以包括电子设备201、网络202和服务器203。网络202用于在电子设备201和服务器203之间提供通信链路的介质。网络202可以包括各种类型的有线通信链路或无线通信链路,例如:有线通信链路包括光纤、双绞线或同轴电缆的,无线通信链路包括蓝牙通信链路、无线保真(Wireless-Fidelity,Wi-Fi)通信链路或微波通信链路等。As shown in FIG. 2 , the system architecture may include an
电子设备201可以通过网络202与服务器203交互,以接收来自服务器203的消息或向服务器203发送消息,或者电子设备201可以通过网络202与服务器203交互,进而接收其他用户向服务器203发送的消息或者数据。电子设备201可以是硬件,也可以是软件。当电子设备201为硬件时,可以是各种电子设备,包括但不限于智能手表、智能手机、平板电脑、智能电视、膝上型便携式计算机和台式计算机等。当电子设备201为软件时,可以是安装在上述所列举的电子设备中,其可以实现呈多个软件或软件模块(例如:用来提供分布式服务),也可以实现成单个软件或软件模块,在此不作具体限定。The
服务器203可以是提供各种服务的业务服务器。需要说明的是,服务器203可以是硬件,也可以是软件。当服务器203为硬件时,可以实现成多个服务器组成的分布式服务器集群,也可以实现成单个服务器。当服务器203为软件时,可以实现成多个软件或软件模块(例如用来提供分布式服务),也可以实现成单个软件或软件模块,在此不做具体限定。The
在本申请实施例中,电子设备201的数量可以是多个,多个电子设备201可以处于同一多设备场景,且处于同一多设备场景的多个电子设备201也可以直接通过网络202进行连接,也即多个电子设备201也可以直接基于网络202进行数据传输。因此该系统架构还可以不包括服务器203,换言之,服务器203可以为本说明书实施例中可选的设备,即本说明书实施例提供的方法可以应用于仅包括电子设备201的系统结构中,本申请实施例对此不做限定。In this embodiment of the application, the number of
在本申请实施例中,如果将系统架构中的某一电子设备201作为当前设备时,若当前设备监测到用户语音满足语音唤醒条件时,判断当前设备是否处于第一预设设备状态,若当前设备处于第一预设设备状态,则将第一预设设备状态对应的第一设备状态信息发送至候选设备,候选设备与当前设备处于同一多设备场景中;若接收到候选设备发送的第二设备状态信息,则根据第一预设设备状态以及第二设备状态信息对应的第二预设设备状态,确定当前设备是否进行语音交互。In the embodiment of the present application, if a certain
应理解,图2中的电子设备、网络以及服务器的数目仅是示意性的,根据实现需要,可以是任意数量的电子设备、网络以及服务器。It should be understood that the numbers of electronic devices, networks, and servers in FIG. 2 are only illustrative, and may be any number of electronic devices, networks, and servers according to implementation requirements.
请参阅图3,图3为本申请实施例提供的一种语音控制方法的流程示意图。本申请实施例的执行主体可以是执行语音控制的电子设备,也可以是执行语音控制方法的电子设备中的处理器,还可以是执行语音控制方法的电子设备中的语音控制服务。为方便描述,下面以执行主体是电子设备中的处理器为例,介绍语音控制方法的具体执行过程。Please refer to FIG. 3 . FIG. 3 is a schematic flowchart of a voice control method provided by an embodiment of the present application. The executor of this embodiment of the present application may be an electronic device that executes voice control, a processor in an electronic device that executes a voice control method, or a voice control service in an electronic device that executes a voice control method. For the convenience of description, the specific execution process of the voice control method is introduced below by taking the execution subject as an example of a processor in an electronic device.
如图3所示,语音控制方法至少可以包括:As shown in Figure 3, the voice control method may at least include:
S302、监测到用户语音满足语音唤醒条件时,判断当前设备是否处于第一预设设备状态。S302. When it is detected that the user's voice meets the voice wake-up condition, determine whether the current device is in the first preset device state.
可以理解的,在本申请实施例中,语音控制方法主要应用于多设备场景中,多设备场景中存在至少两个电子设备,处于同一多设备场景中的各电子设备属于同一设备组中,同一设备组中的电子设备具有相同设备等级(也即同一设备组中的电子设备不区分从属关系或者主次关系)且各电子设备之间可以直接进行数据传输或者基于服务器的数据转发进行数据传输。进一步地,各电子设备可以通过连接同一个无线接入点(如WiFi接入点)、登录了同一个用户账号等方式,以使得各电子设备处于同一多设备场景中。It can be understood that in the embodiment of the present application, the voice control method is mainly applied in a multi-device scenario, where there are at least two electronic devices, and each electronic device in the same multi-device scenario belongs to the same device group, Electronic devices in the same device group have the same device level (that is, electronic devices in the same device group do not distinguish between affiliation or primary and secondary relationships), and data transmission between electronic devices can be performed directly or based on server-based data forwarding. . Further, each electronic device may be connected to the same wireless access point (such as a WiFi access point), log in to the same user account, etc., so that each electronic device is in the same multi-device scene.
进一步地,处于同一多设备场景中的各电子设备中均设置有类似语音助手的程序,该程序可以基于麦克风采集的语音数据实时监听电子设备周围的用户发出的用户语音,判断用户是否需要进行语音交互。Furthermore, each electronic device in the same multi-device scene is equipped with a program similar to a voice assistant, which can monitor the voices of users around the electronic device in real time based on the voice data collected by the microphone, and determine whether the user needs to perform voice interaction.
一种判断用户是否需要进行语音交互的方式是,可以提前在各电子设备中设置语音唤醒条件,若监测到用户语音满足语音唤醒条件时,就可以确认用户需要进行语音交互。在本申请实施例中,语音唤醒条件可以是用户语音中包括预设的唤醒词和/或用户语音对应的声纹为预设声纹,因此当语音助手通过麦克风采集到用户语音之后,可以基于用户语音进行唤醒词检测和/或声纹检测,当用户语音中包括预设的唤醒词和/或用户语音对应的声纹为预设声纹时,就可以认为检测到用户语音满足语音唤醒条件。语音唤醒条件还可以是电子设备处于预设状态,例如,若电子设备为智能手表,为了减少功耗,大部分时间智能手表都是处于熄屏状态,那么如果智能手表处于亮屏状态,则可以确定智能手表满足语音唤醒条件。One way of judging whether the user needs to perform voice interaction is to set the voice wake-up condition in each electronic device in advance, and if it is detected that the user's voice meets the voice wake-up condition, it can be confirmed that the user needs to perform voice interaction. In this embodiment of the application, the voice wake-up condition may be that the user's voice includes a preset wake-up word and/or the voiceprint corresponding to the user's voice is a preset voiceprint. Therefore, after the voice assistant collects the user's voice through the microphone, it can The user's voice performs wake-up word detection and/or voiceprint detection. When the user's voice includes a preset wake-up word and/or the voiceprint corresponding to the user's voice is a preset voiceprint, it can be considered that the detected user's voice meets the voice wake-up condition . The voice wake-up condition can also be that the electronic device is in a preset state. For example, if the electronic device is a smart watch, in order to reduce power consumption, the smart watch is in the off-screen state most of the time, then if the smart watch is in the bright screen state, you can Make sure the smart watch meets the voice wake-up conditions.
由于用户在使用电子设备或者对电子设备进行相关操作时,电子设备的设备状态会发生变化,例如,设备状态可以是指设备放置状态、屏幕点亮状态、待机状态、播放视频状态等静态或者动态的状态,因此电子设备的设备状态与用户的操作是关联的,因此当用户在多设备场景中需要进行语音交互时,往往更加希望自己正在操作的电子设备进行响应。When the user uses the electronic device or performs related operations on the electronic device, the device status of the electronic device will change. For example, the device status can refer to static or dynamic status such as device placement status, screen lighting status, standby status, and video playback status. Therefore, the device state of the electronic device is associated with the user's operation. Therefore, when the user needs to perform voice interaction in a multi-device scenario, he often wants the electronic device he is operating to respond more.
基于上述思路,在本申请实施例中,可以在处于同一多设备场景中的各电子设备在检测到用户语音满足语音唤醒条件时,都可以首先判断自身设备是否处于预设设备状态中。Based on the above idea, in the embodiment of the present application, when each electronic device in the same multi-device scene detects that the user's voice satisfies the voice wake-up condition, it may first determine whether its own device is in the preset device state.
具体地,处于同一多设备场景中的各电子设备,若电子设备的类型不同,则其对应的预设状态也不同,因此可以提前根据每个电子设备的设备类型分别设置不同电子设备对应的预设设备状态,那么若电子设备处于预设设备状态也就代表电子设备可能正在被用户操作或者使用,进而用户需要与该电子设备进行交互的可能性也就越大,为了便于将不同设备的预设设备状态进行区分,在本申请实施例中,将当前设备对应的预设设备状态确定为第一预设设备状态。Specifically, if the electronic devices in the same multi-device scene are of different types, their corresponding preset states are also different. Therefore, the corresponding preset states of different electronic devices can be set in advance according to the device type of each electronic device. If the electronic device is in the preset device state, it means that the electronic device may be being operated or used by the user, and the user is more likely to need to interact with the electronic device. In order to facilitate the integration of different devices The preset device status is distinguished. In the embodiment of the present application, the preset device status corresponding to the current device is determined as the first preset device status.
对于当前设备来说,若当前设备监测到用户语音满足语音唤醒条件时,可以判断当前设备是否处于第一预设设备状态,其中,判断前设备是否处于第一预设设备状态的方式可以不做限定,例如,可以通过获取当前设备中预设传感器采集的数据进而判断当前设备是否处于第一预设设备状态。For the current device, if the current device detects that the user's voice meets the voice wake-up condition, it can determine whether the current device is in the first preset device state, wherein the method of judging whether the previous device is in the first preset device state can be omitted For example, it may be determined whether the current device is in the first preset device state by acquiring data collected by a preset sensor in the current device.
S304、若当前设备处于第一预设设备状态,则将第一预设设备状态对应的第一设备状态信息发送至候选设备,候选设备与当前设备处于同一多设备场景中。S304. If the current device is in the first preset device state, send the first device state information corresponding to the first preset device state to the candidate device, where the candidate device and the current device are in the same multi-device scenario.
若判断当前设备处于第一预设设备状态,则可以确定当前设备可能是为用户正在使用或者操作的设备,但是由于多设备场景中存在多个电子设备,因此多设备场景中还可能存在其他也处于预设设备状态的电子设备,那么为了便于从多个处于预设设备状态的电子设备中确定出用户想要进行语音交互的电子设备,处于同一多设备场景中的电子设备在确定自身处于预设设备状态之后,都可以将自身处于的预设设备状态对应的状态信息同步至其他电子设备。If it is judged that the current device is in the first preset device state, it can be determined that the current device may be a device being used or operated by the user, but since there are multiple electronic devices in the multi-device scene, there may also be other Electronic devices in the preset device state, in order to facilitate determining the electronic device that the user wants to perform voice interaction from multiple electronic devices in the preset device state, the electronic devices in the same multi-device scene determine that they are in the After the device state is preset, the state information corresponding to the preset device state can be synchronized to other electronic devices.
进一步地,由于预设设备状态并不是实体数据,不能直接进行传输,因此当前设备可以获取代表第一预设设备状态的第一设备状态信息,并将第一设备状态发送至与当前设备处于同一多设备场景的至少一个候选设备,其中,候选设备可以是与当前设备处于同一多设备场景的所有电子设备,也可以是与当前设备处于同一多设备场景中用户指定的电子设备。Furthermore, since the preset device status is not entity data, it cannot be directly transmitted, so the current device can acquire the first device status information representing the first preset device status, and send the first device status to the At least one candidate device in a multi-device scenario, where the candidate device may be all electronic devices in the same multi-device scenario as the current device, or may be an electronic device specified by the user in the same multi-device scenario as the current device.
S306、若接收到候选设备发送的第二设备状态信息,则根据第一预设设备状态以及第二设备状态信息对应的第二预设设备状态,确定当前设备是否进行语音交互。S306. If the second device state information sent by the candidate device is received, determine whether the current device performs voice interaction according to the first preset device state and the second preset device state corresponding to the second device state information.
由于多设备场景中存在多个电子设备,因此多设备场景中还可能存在其他也处于预设设备状态的电子设备,也即当前设备将第一设备状态对应的第一设备状态信息发送至候选设备时,有可能候选设备也会发送其对应的预设设备状态的设备状态信息,这里为了与当前设备处于的第一预设设备状态进行区分,在本申请实施例中,将候选设备处于的预设设备状态记为第二预设设备状态,那么在当前设备第一预设设备状态对应的第一设备状态信息发送至候选设备之后,当前设备可以等待第一预设时间,若在第一预设时间内接收到至少一个候选设备发送的第二设备状态信息,则代表多设备场景中还可能存在其他也处于预设设备状态的电子设备。Since there are multiple electronic devices in the multi-device scenario, there may also be other electronic devices in the preset device state in the multi-device scenario, that is, the current device sends the first device state information corresponding to the first device state to the candidate device , it is possible that the candidate device will also send the device state information of its corresponding preset device state. Here, in order to distinguish it from the first preset device state that the current device is in, in this embodiment of the application, the Assuming that the device state is recorded as the second preset device state, then after the first device state information corresponding to the first preset device state of the current device is sent to the candidate device, the current device can wait for the first preset time. Assuming that the second device state information sent by at least one candidate device is received within a certain period of time, it means that there may be other electronic devices that are also in the preset device state in the multi-device scenario.
进一步地,在接收到至少一个候选设备发送的第二设备状态信息之后,可以根据第二设备状态信息分别确定各候选设备对应的第二预设设备状态,然后根据将第一预设设备状态与各第二预设设备状态进行比较,然后确定当前设备是否进行语音交互。其中,将第一预设设备状态与各第二预设设备状态进行比较的方式可以不做限定,可以是根据用户或者电子设备出厂时设置的规则进行比较,以确定比较结果。其中,若确定当前设备进行语音交互,则可以解析用户语音对应的语音控制命令,并响应该语音控制命令。Further, after receiving the second device state information sent by at least one candidate device, the second preset device state corresponding to each candidate device can be determined respectively according to the second device state information, and then according to the combination of the first preset device state and The states of the second preset devices are compared, and then it is determined whether the current device performs voice interaction. Wherein, the manner of comparing the first preset device state with each second preset device state is not limited, and may be compared according to rules set by the user or when the electronic device leaves the factory to determine the comparison result. Wherein, if it is determined that the current device is performing voice interaction, it may analyze the voice control command corresponding to the user's voice, and respond to the voice control command.
由于处于多设备场景中的每个电子设备都会执行上述语音控制方法,因此可以从处于多设备场景中的多个电子设备中确定一个进行语音交互的电子设备,提什么了用户进行语音交互时的体验。Since each electronic device in the multi-device scenario will execute the above-mentioned voice control method, it is possible to determine an electronic device for voice interaction from among the multiple electronic devices in the multi-device scenario, so as to improve the voice interaction of the user. experience.
请参阅图4,图4为本申请实施例提供的一种设备交互方法。Please refer to FIG. 4 . FIG. 4 is a device interaction method provided by an embodiment of the present application.
如图4所示,将用户的客厅作为多设备场景,其中,用户家客厅有音箱101,电视机102、手机103以及穿戴手表104四个设备,这四个设备均安装有语音助手,且唤醒词均为“小布小布"。那么当用户说出包含唤醒词“小布小布”的用户语音之后,音箱101,电视机102、手机103以及穿戴手表104的语音助手均可能都会监测到用户语音满足语音唤醒条件,那么音箱101,电视机102、手机103以及穿戴手表104会分别判断各自是否处于预设设备状态,如果手机103均判断自身处于第一预设设备状态,则会将第一预设设备状态对应的第一设备状态信息发送至音箱101,电视机102以及穿戴手表104,如果手机103接收到音箱101,电视机102以及穿戴手表104的第二设备状态信息,那么手机103会比较手机103的第一预设设备状态以及其他设备的第二设备状态信息对应的第二预设设备状态,进而确定手机103是否进行语音交互,那么音箱101,电视机102以及穿戴手表104也会确定自身是否进行语音交互,最终从音箱101,电视机102、手机103以及穿戴手表104确定出一个电子设备进行交互。As shown in Figure 4, the user's living room is used as a multi-device scene, wherein the user's living room has four devices: a
在图4中,手机103确定进行语音交互,那么手机103可以解析用户语音对应的语音控制命令,并影响该语音控制命令。In FIG. 4 , the
由于与手机进行交互更加便捷,那么用户往往更加希望手机中的语音助手可以被唤醒并响应用户的控制命令进行语音交互,而如多个设备同时响应,给用户带来的体验较差。Since it is more convenient to interact with the mobile phone, users often hope that the voice assistant in the mobile phone can be awakened and respond to the user's control commands for voice interaction, and if multiple devices respond at the same time, the experience brought to the user is poor.
在本申请实施例中,首先监测到用户语音满足语音唤醒条件时,判断当前设备是否处于第一预设设备状态;然后若当前设备处于第一预设设备状态,则将第一预设设备状态对应的第一设备状态信息发送至候选设备,候选设备与当前设备处于同一多设备场景中;最后若接收到候选设备发送的第二设备状态信息,则根据第一预设设备状态以及第二设备状态信息对应的第二预设设备状态,确定当前设备是否进行语音交互。监测到用户语音满足语音唤醒条件时,可以获取当前设备的第一预设设备状态与候选设备的第二预设设备状态,由于设备状态可以代表用户对设备的使用情况,因此根据各设备的设备状态可以确定用户具体想要使用哪个设备进行语音交互,有效提升了语音控制的准确性。In this embodiment of the application, firstly, when the user's voice is detected to meet the voice wake-up condition, it is judged whether the current device is in the first preset device state; then if the current device is in the first preset device state, the first preset device state is set to The corresponding first device state information is sent to the candidate device, and the candidate device and the current device are in the same multi-device scene; finally, if the second device state information sent by the candidate device is received, according to the first preset device state and the second The second preset device state corresponding to the device state information determines whether the current device performs voice interaction. When the user's voice is detected to meet the voice wake-up condition, the first preset device status of the current device and the second preset device status of the candidate device can be obtained. Since the device status can represent the user's usage of the device, according to the device status of each device The status can determine which device the user wants to use for voice interaction, which effectively improves the accuracy of voice control.
请参阅图5,图5为本申请另一实施例提供的一种语音控制方法的流程示意图。如图5所示,语音控制方法至少可以包括:Please refer to FIG. 5 . FIG. 5 is a schematic flowchart of a voice control method provided by another embodiment of the present application. As shown in Figure 5, the voice control method may at least include:
S502、监测到用户语音满足语音唤醒条件时,判断当前设备是否处于第一预设设备状态。S502. When it is detected that the user's voice meets the voice wake-up condition, determine whether the current device is in the first preset device state.
由于用户在使用电子设备或者对电子设备进行相关操作时,对不同类型的电子设备进行使用或者操作的方式也不同,进而导致不同类型的电子设备所处的预设设备状态不同,因此在判断当前设备是否处于第一预设设备状态的过程中,一种可行的实施方式是,可以先获取当前设备的设备类型,设备类型用于区分不同设备的类别,例如,设备类型可以分为手持设备、穿戴设备、音箱设备以及电视设备等,设备类型可以根据用户需要进行划分,也可以直接在出厂时进行划分;那么不同设备类型的电子设备对应的预设设备状态也是不同的,例如,当电子设备的设备类型为手持设备时,其对应的预设设备状态可以是手持状态;当电子设备的设备类型为穿戴设备时,其对应的预设设备状态可以是肢体抬起状态;当电子设备的设备类型为音箱设备时,其对应的预设设备状态可以是播放音乐状态;当电子设备的设备类型为电视设备时,其对应的预设设备状态可以是播放视频状态等。Since users use or operate different types of electronic devices in different ways when using electronic devices or performing related operations on electronic devices, resulting in different preset device states for different types of electronic devices, so when judging the current In the process of whether the device is in the first preset device state, a feasible implementation method is to obtain the device type of the current device first, and the device type is used to distinguish different types of devices. For example, the device types can be divided into handheld devices, Wearable devices, speaker devices, and TV devices, etc., the device types can be divided according to user needs, or can be divided directly at the factory; then the preset device states corresponding to different types of electronic devices are also different, for example, when the electronic device When the device type of the electronic device is a handheld device, its corresponding preset device state can be a handheld state; when the device type of an electronic device is a wearable device, its corresponding preset device state can be a limb-lifted state; When the type is a sound box device, its corresponding preset device state may be a music playing state; when the device type of the electronic device is a TV device, its corresponding preset device state may be a video playing state, etc.
进一步地,不同设备状态下设备中某些状态参数是不同的,那么可以根据当前设备的设备类型获取当前设备对应的指定状态参数,其中,指定状态参数可以通过指定的传感器等器件获取,最后根据指定状态参数判断当前设备是否处于第一预设设备状态。Furthermore, some state parameters in the device are different under different device states, then the specified state parameters corresponding to the current device can be obtained according to the device type of the current device, wherein the specified state parameters can be obtained through specified sensors and other devices, and finally according to The specified state parameter determines whether the current device is in the first preset device state.
例如,若当前设备的设备类型为手持设备,例如,当前设备为智能手机,那么对于手持设备来说如果用户正在使用或者操作手持设备,手持设备一般不会被口袋等物体遮挡,手持设备也并不会完全水平,并且手持设备不会非常平稳,因此若当前设备的设备类型为手持设备,则可以获取当前设备对应的遮挡状态参数、放置角度状态参数以及抖动状态参数中的至少一种,以便于根据遮挡参数、放置角度参数以及抖动参数中的至少一种判断当前设备是否处于手持状态。For example, if the device type of the current device is a handheld device, for example, the current device is a smart phone, then for the handheld device, if the user is using or operating the handheld device, the handheld device will generally not be blocked by objects such as pockets, and the handheld device will not be blocked. It will not be completely level, and the handheld device will not be very stable, so if the device type of the current device is a handheld device, at least one of the occlusion state parameters, placement angle state parameters, and shaking state parameters corresponding to the current device can be obtained, so that The method is to determine whether the current device is in a hand-held state according to at least one of the occlusion parameter, the placement angle parameter, and the shaking parameter.
具体地,如果根据遮挡参数、放置角度参数以及抖动参数判断当前设备是否处于手持状态时,那么首先可以基于遮挡状态参数判断当前设备是否被遮挡,其中,遮挡状态参数可以包括光照传感器采集的光照数值以及接近传感器采集的接近距离数值,如果光照数值小于预设光照数值,且接近距离数值小于预设接近距离数值,则可以确定当前设备被遮挡,也即确定当前设备不处于手持状态(第一预设设备状态);否则可以确定当前设备没有被遮挡,那么可以基于放置角度状态参数判断当前设备是否处于平放状态,其中,放置角度参数可以包括地磁传感器采集的地磁数值以及加速度传感器采集的加速度数值,如果基于地磁数值以及加速度数值计算出的角度小于预设平放角度,则可以确定当前设备处于平放状态,也即确定当前设备不处于手持状态(第一预设设备状态);否则可以确定当前设备不处于平放状态,可以基于抖动状态参数判断当前设备是否处于抖动状态,其中,抖动状态参数可以包括角速度传感器采集的角速度数值,根据角速度数值可以计算出时间滑动窗口内平均角速度值,若当前实时的角速度数值大于预设最大角速度值,或者当前实时的角速度数值大于预设最小角速度值、小于预设最大角速度值且平均角速度值大于预设平均角速度数值,则可以确定当前设备处于抖动状态,那么也就可以确定当前设备处于手持状态(第一预设设备状态),否则可以确定当前设备不处于抖动状态,那么也就可以确定当前设备不处于手持状态(第一预设设备状态)。Specifically, if it is judged whether the current device is in a hand-held state according to the occlusion parameter, the placement angle parameter, and the shaking parameter, then firstly, it can be judged whether the current device is occluded based on the occlusion state parameter, wherein the occlusion state parameter can include the illumination value collected by the illumination sensor And the proximity distance value collected by the proximity sensor, if the illumination value is less than the preset illumination value, and the proximity distance value is less than the preset proximity distance value, it can be determined that the current device is blocked, that is, it is determined that the current device is not in the handheld state (the first preset device state); otherwise, it can be determined that the current device is not blocked, then it can be determined whether the current device is in a flat state based on the placement angle state parameter, wherein the placement angle parameter can include geomagnetic values collected by the geomagnetic sensor and acceleration values collected by the acceleration sensor , if the angle calculated based on the geomagnetic value and the acceleration value is less than the preset horizontal angle, it can be determined that the current device is in the horizontal state, that is, it is determined that the current device is not in the handheld state (the first preset device state); otherwise, it can be determined The current device is not in the flat state. It can be judged whether the current device is in the shaking state based on the shaking state parameter. The shaking state parameter can include the angular velocity value collected by the angular velocity sensor. According to the angular velocity value, the average angular velocity value in the time sliding window can be calculated. If The current real-time angular velocity value is greater than the preset maximum angular velocity value, or the current real-time angular velocity value is greater than the preset minimum angular velocity value, less than the preset maximum angular velocity value and the average angular velocity value is greater than the preset average angular velocity value, then it can be determined that the current device is in a shaking state , then it can be determined that the current device is in the handheld state (the first preset device state), otherwise it can be determined that the current device is not in the shaking state, then it can be determined that the current device is not in the handheld state (the first preset device state).
S504、若当前设备处于第一预设设备状态,则将第一预设设备状态对应的第一设备状态信息发送至候选设备,候选设备与当前设备处于同一多设备场景中。S504. If the current device is in the first preset device state, send the first device state information corresponding to the first preset device state to the candidate device, where the candidate device and the current device are in the same multi-device scenario.
关于步骤S504,可以参阅上述步骤S304中的记载,此处不在赘述。Regarding step S504, reference may be made to the description in the above step S304, which will not be repeated here.
S506、若接收到候选设备发送的第二设备状态信息,则比较第一预设设备状态的优先级与第二设备状态信息对应的第二预设设备状态的优先级,根据优先级比较结果确定当前设备是否进行语音交互。S506. If the second device state information sent by the candidate device is received, compare the priority of the first preset device state with the priority of the second preset device state corresponding to the second device state information, and determine according to the priority comparison result Whether the current device performs voice interaction.
在本申请实施例中,在接收到候选设备发送的第二设备状态信息之后,可以对第一预设设备状态与第二设备状态信息对应的第二预设设备状态的进行比较,在比较过程中,一种可行的实施方式是,可以分别确定第一预设设备状态与以及各第二预设设备状态优先级,然后根据优先级比较结果确定当前设备是否进行语音交互。In the embodiment of the present application, after receiving the second device state information sent by the candidate device, the first preset device state can be compared with the second preset device state corresponding to the second device state information. During the comparison process Among them, a feasible implementation manner is to determine the priorities of the first preset device state and the second preset device states respectively, and then determine whether the current device performs voice interaction according to the priority comparison result.
具体地,可以根据用户的指示或者在设备出厂时预设设置处于同一多设备场景中各电子设备对应的预设设备状态的优先级顺序,然后预先设置的设备状态优先级顺序确定第一预设设备状态对应的第一状态优先级,以及确定第二设备状态信息对应的第二预设设备状态对应的第二状态优先级,若第一状态优先级大于第二状态优先级,代表当前设备拥有更高优先级的语音交互控制权,则确定当前设备进行语音交互;若第一状态优先级小于第二状态优先级,代表其他候选设备拥有更高优先级的语音交互控制权,则确定当前设备不进行语音交互。Specifically, the priority order of the preset device states corresponding to each electronic device in the same multi-device scene can be set according to the user's instruction or preset when the device leaves the factory, and then the preset priority order of the device states determines the first preset priority order. Set the first state priority corresponding to the device state, and determine the second state priority corresponding to the second preset device state corresponding to the second device state information. If the first state priority is greater than the second state priority, it means that the current device If you have a higher priority voice interaction control right, then determine the current device to perform voice interaction; if the first state priority is less than the second state priority, it means that other candidate devices have a higher priority voice interaction control right, then determine the current device The device does not have voice interaction.
S508、若未接收到候选设备发送的第二设备状态信息,则确定当前设备进行语音交互。S508. If the second device state information sent by the candidate device is not received, determine that the current device performs voice interaction.
若当前设备在第一预设时间内未接收到候选设备发送的第二设备状态信息,代表多设备场景中不存在也处于预设设备状态的候选设备,此时可以直接确定当前设备的语音交互优先级最高,以及控制当前设备进行语音交互。If the current device does not receive the second device state information sent by the candidate device within the first preset time, it means that there is no candidate device that is also in the preset device state in the multi-device scenario. At this time, the voice interaction of the current device can be directly determined It has the highest priority and controls the current device for voice interaction.
S510、若当前设备未处于第一预设设备状态且接收到候选设备发送的第二设备状态信息,则确定当前设备不进行语音交互。S510. If the current device is not in the first preset device state and the second device state information sent by the candidate device is received, determine that the current device does not perform voice interaction.
如果当前设备未处于第一预设设备状态,但是却接收到候选设备发送的第二设备状态信息,代表多设备场景中存在也处于预设设备状态的候选设备,那么候选设备的语音交互优先级高,此时可以控制当前设备不进行语音交互。If the current device is not in the first preset device state, but receives the second device state information sent by the candidate device, which means that there are candidate devices that are also in the preset device state in the multi-device scenario, then the voice interaction priority of the candidate device High, at this time, the current device can be controlled not to perform voice interaction.
若当前设备未处于第一预设设备状态且未接收到候选设备发送的第二设备状态信息,代表多设备场景中的所有电子设备的交互优先级都较低,则各电子设备可以不进行语音交互,继续监听用户的语音是否满足唤醒条件,也可以通过其他判定条件从多设备场景中的所有电子设备继续筛选进行语音交互的电子设备。If the current device is not in the first preset device state and has not received the second device state information sent by the candidate device, it means that the interaction priority of all electronic devices in the multi-device scene is low, and each electronic device may not make a voice Interaction, continue to monitor whether the user's voice meets the wake-up condition, or continue to screen electronic devices for voice interaction from all electronic devices in the multi-device scene through other judgment conditions.
在本申请实施例中,通过比较多设备场景中各电子设备的设备类型,确定各电子设备是否满足预设设备状态,进而确定多设备场景中各电子设备的预设设备状态的优先级,以确定当前设备是否进行语音交互,可以提高判断语音交互设备的准确性。In the embodiment of the present application, by comparing the device types of each electronic device in a multi-device scenario, it is determined whether each electronic device meets the preset device status, and then the priority of the preset device status of each electronic device in a multi-device scenario is determined, so as to Determining whether the current device performs voice interaction can improve the accuracy of judging the voice interaction device.
请参阅图6,图6为本申请另一实施例提供的一种语音控制方法的流程示意图。如图6所示,语音控制方法至少可以包括:Please refer to FIG. 6 . FIG. 6 is a schematic flowchart of a voice control method provided by another embodiment of the present application. As shown in Figure 6, the voice control method may at least include:
S602、监测到用户语音满足语音唤醒条件时,判断当前设备是否处于第一预设设备状态。S602. When it is detected that the user's voice meets the voice wake-up condition, determine whether the current device is in the first preset device state.
S604、若当前设备处于第一预设设备状态,则将第一预设设备状态对应的第一设备状态信息发送至候选设备,候选设备与当前设备处于同一多设备场景中。S604. If the current device is in the first preset device state, send the first device state information corresponding to the first preset device state to the candidate device, where the candidate device and the current device are in the same multi-device scenario.
S606、若接收到候选设备发送的第二设备状态信息,则根据第一预设设备状态以及第二设备状态信息对应的第二预设设备状态,确定当前设备是否进行语音交互。S606. If the second device state information sent by the candidate device is received, determine whether the current device performs voice interaction according to the first preset device state and the second preset device state corresponding to the second device state information.
关于步骤S602至S606,可以参阅上述实施例中的描述,此处不在赘述。Regarding steps S602 to S606, reference may be made to the descriptions in the foregoing embodiments, and details are not repeated here.
S608、若当前设备未处于第一预设设备状态且未接收到候选设备发送的第二设备状态信息,则根据用户语音获取当前设备对应的第一通用语音特征值,以及将第一通用语音特征值发送至候选设备。S608. If the current device is not in the first preset device state and has not received the second device state information sent by the candidate device, obtain the first general speech characteristic value corresponding to the current device according to the user voice, and convert the first general speech characteristic value to The value is sent to the candidate device.
如果当前设备未处于第一预设设备状态且未接收到候选设备发送的第二设备状态信息,代表多设备场景中的所有电子设备的交互优先级都较低,如果此时仍然需要选出一个电子设备进行语音交互,可以通过各电子设备对应的通用语音特征值选择出进行语音交互的电子设备。If the current device is not in the first preset device state and has not received the second device state information sent by the candidate device, it means that all electronic devices in the multi-device The electronic device performs voice interaction, and the electronic device for voice interaction can be selected according to the general voice feature value corresponding to each electronic device.
其中,通用语音特征值用于表示发声源与设备之间的唤醒优先级,而表示发声源与设备之间的唤醒优先级的因素很多,那么可以使用通用语音特征参数来表征发声源与设备之间的唤醒优先级,也即通用语音特征值可以使用多种通用语音特征参数进行表示。容易理解地,由于用户与设备进行语音交互时,往往会靠近该设备并面向该设备发出用户语音,因此通用语音特征参数可以包括但不限于:发声源与设备之间的距离参数以及设备相对于发声源的方位参数。Among them, the general speech feature value is used to represent the wake-up priority between the sound source and the device, and there are many factors that represent the wake-up priority between the sound source and the device, so the general speech feature parameter can be used to represent the wake-up priority between the sound source and the device. The wake-up priority between the two, that is, the general speech feature value may be represented by various general speech feature parameters. It is easy to understand that since the user tends to approach the device and utters the user's voice towards the device when performing voice interaction with the device, the general voice feature parameters may include but not limited to: the distance parameter between the sound source and the device and the relative distance between the device and the device. The orientation parameter of the sound source.
具体地,发声源与设备之间的距离参数可以通过用户语音中唤醒词音频能量来计算,能量越大表示距离越近,发声源与设备之间的距离参数也就越小,唤醒优先级也越高。具体地,唤醒词音频能量需要尽可能降低环境噪声的影响,可以使用语音活动检测(VoiceActivityDetection,VAD)的方法在包含有唤醒词的用户语音基础上切分出唤醒词和环境噪声,进一步地可以得到唤醒词的能量和时长以及环境噪声的能量和时长,那么去除噪声影响的唤醒词能量可以如下计算:Specifically, the distance parameter between the sound source and the device can be calculated based on the audio energy of the wake-up word in the user's voice. The greater the energy, the closer the distance, the smaller the distance parameter between the sound source and the device, and the higher the wake-up priority. higher. Specifically, the audio energy of the wake-up word needs to reduce the impact of environmental noise as much as possible. The voice activity detection (VoiceActivityDetection, VAD) method can be used to segment the wake-up word and environmental noise based on the user's voice containing the wake-up word, and further can The energy and duration of the wake-up word and the energy and duration of the environmental noise are obtained, then the energy of the wake-up word after removing the influence of noise can be calculated as follows:
其中,唤醒词的能量和时长分别计为es、ts,以及环境噪声的能量和时长分别计为en、tn,那么可以看做是唤醒词的功率,可以看做是环境噪声的功率,那么与之差可以认为是去除噪声影响的唤醒词的功率,进而可以通过去除噪声影响的唤醒词的功率去表示去除噪声影响的唤醒词能量。Among them, the energy and duration of the wake-up word are counted as es and ts respectively, and the energy and duration of the environmental noise are counted as en and tn respectively, then It can be regarded as the power of the wake-up word, can be regarded as the power of ambient noise, then and The difference can be considered as the power of the wake-up word without the influence of noise, and then the power of the wake-up word without the influence of noise can be used to represent the energy of the wake-up word without the influence of noise.
进一步地,当前设备相对于发声源的方位参数的计算方法可以通过预先录制的音频数据训练出声音朝向的决策模型,然后将用户语音输入至该决策模型以得到声音朝向结果也即当前设备相对于发声源的方位参数,其中预先录制的音频数据可以包括:1、频谱特征数据,选择频谱特征数据的原因是发声源对于发声源的方位参数增大,声音会更多的经过反射到达当前设备,那么当前设备接收到的用户语音中高频部分相较于低频部分会衰减的更多。2、混响特征数据,选择混响特征数据的原因是如果发声源对于发声源的方位参数增大,混响能量越大,那么当前设备可以计算用户语音的语音直混比以及自相关特征,如果混响越大,自相关结果的峰值也会越多越大。3、多麦特征数据,选择多麦特征数据的原因是如果当前设备有多个麦克风参与语音的控制,还可以计算多个麦克风的声音方向特征,辅助决策当前设备相对于发声源的方位参数。Furthermore, the method for calculating the orientation parameters of the current device relative to the sound source can train a sound orientation decision model through pre-recorded audio data, and then input the user's voice into the decision model to obtain the sound orientation result, that is, the current device relative to the sound source. The orientation parameters of the sound source, where the pre-recorded audio data may include: 1. Spectrum feature data. The reason for selecting the spectrum feature data is that the orientation parameter of the sound source to the sound source increases, and more sound will reach the current device through reflection. Then the high-frequency part of the user's voice received by the current device will be attenuated more than the low-frequency part. 2. Reverberation feature data. The reason for choosing reverberation feature data is that if the direction parameter of the sound source relative to the sound source increases, the reverberation energy will be greater, then the current device can calculate the voice direct-mixing ratio and autocorrelation features of the user's voice. If the reverberation is larger, the peak of the autocorrelation result will be more and larger. 3. Multi-microphone feature data. The reason for choosing multi-microphone feature data is that if the current device has multiple microphones participating in voice control, the sound direction characteristics of multiple microphones can also be calculated to assist in determining the orientation parameters of the current device relative to the sound source.
进一步地,由于第一通用语音特征参数的数量可以是多个,那么不同的第一通用语音特征参数对发声源与设备之间的唤醒优先级的影响是不同的,因此预设对各第一通用语音特征参数对应的第一通用语音特征权值进行设置,其中,第一通用语音特征参数对发声源与设备之间的唤醒优先级的影响越大,则其对应的第一通用语音特征权值也就越大。例如,如果第一通用语音特征参数包括:发声源与当前设备之间的距离参数以及当前设备相对于发声源的方位参数,那么可以设置发声源与当前设备之间的距离参数对应的第一通用语音特征权值为0.6,以及设置当前设备相对于发声源的方位参数对应的第一语音特征权值为0.4。Further, since there may be multiple first general speech characteristic parameters, different first general speech characteristic parameters have different influences on the wake-up priority between the sound source and the device, so preset The first general speech feature weight corresponding to the general speech feature parameter is set, wherein, the greater the impact of the first general speech feature parameter on the wake-up priority between the sound source and the device, the corresponding first general speech feature weight The value is also larger. For example, if the first general speech characteristic parameter includes: the distance parameter between the sound source and the current device and the orientation parameter of the current device relative to the sound source, then the first general speech feature parameter corresponding to the distance parameter between the sound source and the current device can be set The voice feature weight is 0.6, and the first voice feature weight corresponding to the orientation parameter of the current device relative to the sound source is set to 0.4.
那么在获取到当前设备对应第一通用语音特征参数之后,还可以获取各第一通用语音特征参数对应的第一通用语音特征权值,进而基于各第一通用语音特征参数以及各第一通用语音特征权值,计算当前设备对应的第一通用语音特征值,也即各第一通用语音特征参数与其对应的第一通用语音特征权值相乘,并将各乘积结果相加作为当前设备对应的第一通用语音特征值。Then, after obtaining the first general speech characteristic parameters corresponding to the current device, the first general speech characteristic weights corresponding to each first general speech characteristic parameter can also be obtained, and then based on each first general speech characteristic parameter and each first general speech characteristic weight Feature weights, calculating the first general speech feature value corresponding to the current device, that is, multiplying each first general speech feature parameter with its corresponding first general speech feature weight, and adding the product results as the current device corresponding The first common speech feature value.
进一步地,在根据用户语音获取当前设备对应的第一通用语音特征值之后,需要将第一通用语音特征值同步给多设备场景中的其他电子设备,同样的,多设备场景中的其他电子设备也会使用与当前设备相同的方法获取用户语音对应的第二通用语音特征值,并将第二通用语音特征值同步给当前设备。Further, after obtaining the first universal speech feature value corresponding to the current device according to the user voice, it is necessary to synchronize the first universal speech feature value to other electronic devices in the multi-device scene. Similarly, other electronic devices in the multi-device scene The same method as that of the current device is also used to obtain the second common speech feature value corresponding to the user's voice, and the second common speech feature value is synchronized to the current device.
S610、若接收到候选设备发送的第二通用语音特征值,则根据第一通用语音特征值以及第二通用语音特征值,确定当前设备是否进行语音交互。S610. If the second common voice feature value sent by the candidate device is received, determine whether the current device performs voice interaction according to the first common voice feature value and the second common voice feature value.
在本申请实施例中,当前设备将第一通用语音特征值发送至多设备场中的所有候选设备之后,可以等待第二预设时间,若在第二预设时间内至少一个候选设备接收到候选设备发送的第二通用语音特征值,则可以根据第一通用语音特征值以及第二通用语音特征值,也即比较第一通用语音特征值以及第二通用语音特征值,根据比较结果确定当前设备是否进行语音交互。In the embodiment of the present application, after the current device sends the first universal voice feature value to all candidate devices in the multi-device field, it may wait for the second preset time, if at least one candidate device receives the candidate The second general speech characteristic value sent by the device can be based on the first general speech characteristic value and the second general speech characteristic value, that is, compare the first general speech characteristic value and the second general speech characteristic value, and determine the current device according to the comparison result Whether to perform voice interaction.
具体地,可以比较第一通用语音特征值以及第二通用语音特征值,若第一通用语音特征值大于第二通用语音特征值,代表当前设备具有与用户更高的交互优先权,则确定当前设备进行语音交互;若第一通用语音特征值小于第二通用语音特征值,代表当前设备不具有与用户更高的交互优先权,也即其他候选设备具有与用户更高的交互优先权,则确定当前设备不进行语音交互;若第一通用语音特征值等于第二通用语音特征值,代表当前设备和其他候选设备都不具有更高的交互优先权,此时可以判断当前设备是否为预先设置的优先交互设备,其中,优先交互设备为用户自定义设置或者电子设备出厂时设置的,以便于在多个设备的通用语音特征值相同时,选择其中一个电子设备进行交互,避免出现用户语音交互失败的情况,那么如果确定当前设备为预先设置的优先交互设备,则确定当前设备进行语音交互。Specifically, the first common speech feature value and the second common speech feature value may be compared, and if the first common speech feature value is greater than the second common speech feature value, it means that the current device has a higher interaction priority with the user, and the current The device performs voice interaction; if the first common voice feature value is smaller than the second common voice feature value, it means that the current device does not have a higher interaction priority with the user, that is, other candidate devices have a higher interaction priority with the user, then Determine that the current device does not perform voice interaction; if the first common voice feature value is equal to the second common voice feature value, it means that the current device and other candidate devices do not have a higher interaction priority, and at this time it can be judged whether the current device is preset Priority interaction devices, wherein the priority interaction devices are user-defined settings or electronic devices are set at the factory, so that when multiple devices have the same general voice feature value, one of the electronic devices is selected for interaction to avoid user voice interaction In case of failure, if it is determined that the current device is the preset priority interaction device, it is determined that the current device performs voice interaction.
S612、若未接收到候选设备发送的第二通用语音特征值,则确定当前设备进行语音交互。S612. If the second common voice characteristic value sent by the candidate device is not received, determine that the current device performs voice interaction.
在本申请实施例中,当前设备将第一通用语音特征值发送至多设备场中的所有候选设备之后,可以等待第二预设时间,若在第二预设时间内未接收到候选设备发送的第二通用语音特征值,代表多场景设备中除了当前设备没有其他候选设备获取到通用语音特征值,此时可以直接确定当前设备进行语音交互。In the embodiment of the present application, after the current device sends the first universal voice feature value to all candidate devices in the multi-device field, it may wait for the second preset time, and if it does not receive the message sent by the candidate device within the second preset time The second general speech feature value means that no other candidate devices in the multi-scenario device have obtained the general speech feature value except the current device. At this time, the current device can be directly determined to perform voice interaction.
在本申请实施例中,在确定多设备场景中的各电子设备均不处于预设状态时,可以分别获取各电子设备针对用户语音获取的通用语音特征,进而根据通用语音特征选择进行语音交互的电子设备,有效提升了确定进行语音交互的设备的准确性。In the embodiment of the present application, when it is determined that each electronic device in the multi-device scene is not in the preset state, the general voice characteristics acquired by each electronic device for the user's voice can be obtained respectively, and then the user for voice interaction can be selected according to the general voice characteristics. The electronic device effectively improves the accuracy of determining the device for voice interaction.
请参阅图7,图7为本申请另一实施例提供的一种语音控制装置的结构框图。如图7所示,语音控制装置700包括:Please refer to FIG. 7 . FIG. 7 is a structural block diagram of a voice control device provided by another embodiment of the present application. As shown in Figure 7, the
语音唤醒模块710,用于监测到用户语音满足语音唤醒条件时,判断当前设备是否处于第一预设设备状态;The voice wake-up
设备状态发送模块720,用于若当前设备处于第一预设设备状态,则将第一预设设备状态对应的第一设备状态信息发送至候选设备,候选设备与当前设备处于同一多设备场景中;The device
第一语音交互确定模块730,用于若接收到候选设备发送的第二设备状态信息,则根据第一预设设备状态以及第二设备状态信息对应的第二预设设备状态,确定当前设备是否进行语音交互。The first voice
可选地,第一语音交互确定模块730,还用于比较第一预设设备状态的优先级与第二设备状态信息对应的第二预设设备状态的优先级,根据优先级比较结果确定当前设备是否进行语音交互。Optionally, the first voice
可选地,第一语音交互确定模块730,还用于根据预先设置的设备状态优先级顺序确定第一预设设备状态对应的第一状态优先级,以及确定第二设备状态信息对应的第二预设设备状态对应的第二状态优先级;若第一状态优先级大于第二状态优先级,则确定当前设备进行语音交互;若第一状态优先级小于第二状态优先级,则确定当前设备不进行语音交互。Optionally, the first voice
可选地,语音唤醒模块710,还用于获取当前设备的设备类型,根据设备类型获取当前设备对应的指定状态参数;根据指定状态参数判断当前设备是否处于第一预设设备状态。Optionally, the voice wake-up
可选地,语音唤醒模块710,还用于若设备类型为手持设备,则获取当前设备对应的遮挡状态参数、放置角度状态参数以及抖动状态参数;根据遮挡参数、放置角度参数以及抖动参数判断当前设备是否处于手持状态。Optionally, the voice wake-up
可选地,语音控制装置700还包括:第二语音交互确定模块,用于若未接收到候选设备发送的第二设备状态信息,则确定当前设备进行语音交互。Optionally, the
可选地,语音控制装置700还包括:第三语音交互确定模块,用于若当前设备未处于第一预设设备状态且接收到候选设备发送的第二设备状态信息,则确定当前设备不进行语音交互。Optionally, the
可选地,语音控制装置700还包括:第四语音交互确定模块,用于若当前设备未处于第一预设设备状态且未接收到候选设备发送的第二设备状态信息,则根据用户语音获取当前设备对应的第一通用语音特征值,以及将第一通用语音特征值发送至候选设备;若接收到候选设备发送的第二通用语音特征值,则根据第一通用语音特征值以及第二通用语音特征值,确定当前设备是否进行语音交互。Optionally, the
可选地,第四语音交互确定模块,还用于根据用户语音获取当前设备对应第一通用语音特征参数以及各第一通用语音特征参数对应的第一通用语音特征权值;基于各第一通用语音特征参数以及各第一通用语音特征权值,计算当前设备对应的第一通用语音特征值。Optionally, the fourth voice interaction determination module is also used to obtain the first general voice feature parameters corresponding to the current device and the first general voice feature weights corresponding to each first general voice feature parameter according to the user voice; The speech feature parameters and the first general speech feature weights are used to calculate the first general speech feature value corresponding to the current device.
可选地,第一通用语音特征参数包括但不限于:发声源与当前设备之间的距离参数以及当前设备相对于发声源的方位参数。Optionally, the first general voice feature parameter includes, but is not limited to: a distance parameter between the sound source and the current device, and an orientation parameter of the current device relative to the sound source.
可选地,第四语音交互确定模块,还用于若第一通用语音特征值大于第二通用语音特征值,则确定当前设备进行语音交互;若第一通用语音特征值小于第二通用语音特征值,则确定当前设备不进行语音交互;若第一通用语音特征值等于第二通用语音特征值,且确定当前设备为预先设置的优先交互设备,则确定当前设备进行语音交互。Optionally, the fourth voice interaction determination module is also used to determine that the current device performs voice interaction if the first common voice feature value is greater than the second common voice feature value; if the first common voice feature value is smaller than the second common voice feature value value, it is determined that the current device does not perform voice interaction; if the first common voice feature value is equal to the second common voice feature value, and it is determined that the current device is a preset priority interaction device, then it is determined that the current device performs voice interaction.
可选地,语音控制装置700还包括:第五语音交互确定模块,用于若未接收到候选设备发送的第二通用语音特征值,则确定当前设备进行语音交互。Optionally, the
在本申请实施例中,语音控制装置包括:语音唤醒模块,用于监测到用户语音满足语音唤醒条件时,判断当前设备是否处于第一预设设备状态;设备状态发送模块,用于若当前设备处于第一预设设备状态,则将第一预设设备状态对应的第一设备状态信息发送至候选设备,候选设备与当前设备处于同一多设备场景中;语音交互确定模块,用于若接收到候选设备发送的第二设备状态信息,则根据第一预设设备状态以及第二设备状态信息对应的第二预设设备状态,确定当前设备是否进行语音交互。监测到用户语音满足语音唤醒条件时,可以获取当前设备的第一预设设备状态与候选设备的第二预设设备状态,由于设备状态可以代表用户对设备的使用情况,因此根据各设备的设备状态可以确定用户具体想要使用哪个设备进行语音交互,有效提升了语音控制的准确性。In the embodiment of the present application, the voice control device includes: a voice wake-up module, configured to determine whether the current device is in the first preset device state when detecting that the user's voice meets the voice wake-up condition; In the first preset device state, the first device state information corresponding to the first preset device state is sent to the candidate device, and the candidate device and the current device are in the same multi-device scene; the voice interaction determination module is used to determine if received To the second device state information sent by the candidate device, determine whether the current device performs voice interaction according to the first preset device state and the second preset device state corresponding to the second device state information. When the user's voice is detected to meet the voice wake-up condition, the first preset device status of the current device and the second preset device status of the candidate device can be obtained. Since the device status can represent the user's usage of the device, according to the device status of each device The status can determine which device the user wants to use for voice interaction, which effectively improves the accuracy of voice control.
请参阅图8,图8为本申请另一实施例提供的一种语音控制方法的流程示意图。Please refer to FIG. 8 . FIG. 8 is a schematic flowchart of a voice control method provided by another embodiment of the present application.
如图8所示,语音控制方法包括:As shown in Figure 8, voice control methods include:
S802、监测到用户语音满足语音唤醒条件时,判断当前主设备是否处于第一预设设备状态。S802. When it is detected that the user's voice meets the voice wake-up condition, determine whether the current master device is in the first preset device state.
在本申请实施例中,多设备场景中存在至少两个电子设备,处于同一多设备场景中的各电子设备属于同一设备组中,同一设备组中的电子设备具有从属关系或者主次关系,也即多设备场景中至少存在一个主设备以及至少一个从属设备,例如,多设备环境中包括音箱,电视机、手机以及穿戴手表,那么可以将数据处理性能较好的手机作为主设备,而将数据处理性能较差的音箱,电视机以及穿戴手表作为从属设备。为了方便描述,先以语音控制方法应用于主设备进行描述。In the embodiment of the present application, there are at least two electronic devices in the multi-device scene, and the electronic devices in the same multi-device scene belong to the same device group, and the electronic devices in the same device group have a subordinate relationship or a primary and secondary relationship. That is to say, there is at least one master device and at least one slave device in a multi-device scenario. For example, a multi-device environment includes speakers, TVs, mobile phones, and wearable watches. Then the mobile phone with better data processing performance can be used as the master device, and the Speakers with poor data processing performance, TV sets, and wearable watches are used as slave devices. For the convenience of description, the voice control method is firstly applied to the master device for description.
当主设备监测到用户语音满足语音唤醒条件时,可以先判断当前主设备自身是否处于第一预设设备状态。When the main device detects that the user's voice meets the voice wake-up condition, it may first determine whether the current main device itself is in the first preset device state.
S804、若当前主设备处于第一预设设备状态,且接收到从属设备发送的第二设备状态信息,则根据第一预设设备状态对应的第一设备状态信息以及第二设备状态信息,从当前主设备以及从属设备中确定进行语音交互的目标交互设备。S804. If the current master device is in the first preset device state and receives the second device state information sent by the slave device, according to the first device state information and the second device state information corresponding to the first preset device state, slave A target interactive device for voice interaction is determined among the current master device and the slave device.
若当前设备处于第一预设设备状态,则可以确定当前设备可能是为用户正在使用或者操作的设备,但是由于多设备场景中存在多个电子设备,因此多设备场景中还可能存在其他也处于预设设备状态的电子设备,那么为了便于从多个处于预设设备状态的电子设备中确定出用户想要进行语音交互的电子设备,处于同一多设备场景中的从属设备在确定自身处于预设设备状态之后,都可以将自身处于的预设设备状态对应的状态信息同步至主设备。If the current device is in the first preset device state, it can be determined that the current device may be a device being used or operated by the user. However, since there are multiple electronic devices in the multi-device scene, there may be other electronic devices in the multi-device scene. If the electronic device is in the preset device state, in order to facilitate the determination of the electronic device that the user wants to perform voice interaction from among the multiple electronic devices in the preset device state, the slave devices in the same multi-device scene determine that they are in the preset state After the device state is set, the state information corresponding to the preset device state that it is in can be synchronized to the master device.
因此在主设备接收到从属设备发送的第二设备状态信息之后,可以根据第一预设设备状态对应的第一设备状态信息以及第二设备状态信息,从当前主设备以及从属设备中确定进行语音交互的目标交互设备。具体根据设备状态信息确定目标交互设备的方法可以参阅上述实施例中的描述,此处不在赘述。Therefore, after the master device receives the second device state information sent by the slave device, it can determine the voice from the current master device and the slave device according to the first device state information and the second device state information corresponding to the first preset device state. The target interaction device for the interaction. For a specific method of determining the target interactive device according to the device state information, reference may be made to the description in the foregoing embodiments, and details are not repeated here.
S806、基于交互指令控制目标交互设备进行语音交互。S806. Control the target interaction device to perform voice interaction based on the interaction instruction.
在确定目标交互设备之后,主设备可以生成交互指令,若目标交互设备为当前主设备,则直接基于交互指令控制当前主设备进行语音交互;若目标交互设备为从属设备,则将交互指令发送至目标交互设备,交互指令用于指示目标交互设备进行语音交互,也即目标交互设备接收到交互指令之后控制目标交互设备本身进行语音交互。After determining the target interactive device, the master device can generate an interaction command. If the target interactive device is the current master device, it will directly control the current master device to perform voice interaction based on the interaction command; if the target interactive device is a slave device, the interaction command will be sent to For the target interaction device, the interaction instruction is used to instruct the target interaction device to perform voice interaction, that is, the target interaction device controls the target interaction device itself to perform voice interaction after receiving the interaction instruction.
进一步地,若当前主设备处于第一预设设备状态,且未接收到从属设备发送的第二设备状态信息,则控制当前主设备进行语音交互。Further, if the current master device is in the first preset device state and has not received the second device state information sent by the slave device, the current master device is controlled to perform voice interaction.
可选地,若当前主设备未处于第一预设设备状态,那么代表当前主设备不具备设备状态方面的语音交互优先级,此时若接收到从属设备发送的第二设备状态信息,则可以根据第二设备状态信息从从属设备中确定进行语音交互的目标交互设备,并基于交互指令控制目标交互设备进行语音交互。Optionally, if the current master device is not in the first preset device state, it means that the current master device does not have voice interaction priority in terms of device status. At this time, if the second device status information sent by the slave device is received, you can Determine the target interactive device for voice interaction from the slave devices according to the state information of the second device, and control the target interactive device to perform voice interaction based on the interaction instruction.
可选地,若当前主设备未处于第一预设设备状态且未接收到从属设备发送的第二设备状态信息,代表多设备场景中的所有电子设备的交互优先级都较低,如果此时仍然需要选出一个电子设备进行语音交互,可以通过各电子设备对应的通用语音特征值选择出进行语音交互的电子设备,此时可以根据用户语音获取当前主设备对应的第一通用语音特征值;若接收到从属设备发送的第二通用语音特征值,则根据第一通用语音特征值以及第二通用语音特征值,从当前主设备以及从属设备中确定进行语音交互的目标交互设备,以及基于交互指令控制目标交互设备进行语音交互。Optionally, if the current master device is not in the first preset device state and has not received the second device state information sent by the slave device, it means that the interaction priority of all electronic devices in the multi-device scenario is low, if at this time It is still necessary to select an electronic device for voice interaction. The electronic device for voice interaction can be selected through the universal voice feature value corresponding to each electronic device. At this time, the first universal voice feature value corresponding to the current main device can be obtained according to the user voice; If the second universal voice feature value sent by the slave device is received, then according to the first universal voice feature value and the second universal voice feature value, determine the target interactive device for voice interaction from the current master device and the slave device, and based on the interaction The command controls the target interactive device to perform voice interaction.
可选地,若当前主设备未监测到用户语音满足语音唤醒条件,且接收到从属设备发送的第二设备状态信息时,则根据第二设备状态信息从从属设备中确定进行语音交互的目标交互设备,以及基于交互指令控制目标交互设备进行语音交互。Optionally, if the current master device does not detect that the user's voice meets the voice wake-up condition, and receives the second device status information sent by the slave device, then determine the target interaction for voice interaction from the slave device according to the second device status information device, and control the target interaction device to perform voice interaction based on the interaction instruction.
可选地,若当前主设备未监测到用户语音满足语音唤醒条件且接收到从属设备发送的第二通用语音特征值,则根据第二通用语音特征值从从属设备中确定进行语音交互的目标交互设备,以及基于交互指令控制目标交互设备进行语音交互。Optionally, if the current master device does not detect that the user's voice meets the voice wake-up condition and receives the second general voice feature value sent by the slave device, then determine the target interaction for voice interaction from the slave device according to the second general voice feature value device, and control the target interaction device to perform voice interaction based on the interaction instruction.
在本申请实施例中,将根据状态信息确定目标交互设备或者根据语音特征值确定目标交互设备的工作均设置在主设备中,一方面,由于主设备的性能较好,因此可以提高确定目标交互设备的速度,另一方面,由于从属设备的性能较差,那么可以减少从属设备的数据处理量,降低从属设备的功耗。In the embodiment of this application, the work of determining the target interaction device according to the state information or the target interaction device according to the voice feature value is set in the master device. On the one hand, because the performance of the master device is better, it can improve the determination of the target interaction The speed of the device, on the other hand, because the performance of the slave device is poor, then the data processing amount of the slave device can be reduced, and the power consumption of the slave device can be reduced.
请参阅图9,图9为本申请另一实施例提供的一种语音控制装置的结构框图。如图9所示,语音控制装置900包括:Please refer to FIG. 9 . FIG. 9 is a structural block diagram of a voice control device provided by another embodiment of the present application. As shown in Figure 9, the
主设备语音唤醒模块910,用于监测到用户语音满足语音唤醒条件时,判断当前主设备是否处于第一预设设备状态;The master device voice wake-up
主设备语音交互确定模块920,用于若当前主设备处于第一预设设备状态,且接收到从属设备发送的第二设备状态信息,则根据第一预设设备状态对应的第一设备状态信息以及第二设备状态信息,从当前主设备以及从属设备中确定进行语音交互的目标交互设备;The master device voice
指令控制模块930,用于基于交互指令控制目标交互设备进行语音交互。The
可选地,主设备语音交互确定模块920,还用于若目标交互设备为当前主设备,则基于交互指令控制当前主设备进行语音交互;若目标交互设备为从属设备,则将交互指令发送至目标交互设备,交互指令用于指示目标交互设备进行语音交互。Optionally, the master device voice
可选地,主设备语音交互确定模块920,还用于若当前主设备处于第一预设设备状态,且未接收到从属设备发送的第二设备状态信息,则控制当前主设备进行语音交互。Optionally, the master device voice
可选地,主设备语音交互确定模块920,还用于若当前主设备未处于第一预设设备状态,且接收到从属设备发送的第二设备状态信息,则根据第二设备状态信息从从属设备中确定进行语音交互的目标交互设备;基于交互指令控制目标交互设备进行语音交互。Optionally, the voice
可选地,主设备语音交互确定模块920,还用于若当前主设备未处于第一预设设备状态且未接收到从属设备发送的第二设备状态信息,则根据用户语音获取当前主设备对应的第一通用语音特征值;若接收到从属设备发送的第二通用语音特征值,则根据第一通用语音特征值以及第二通用语音特征值,从当前主设备以及从属设备中确定进行语音交互的目标交互设备;基于交互指令控制目标交互设备进行语音交互。Optionally, the voice
可选地,主设备语音交互确定模块920,还用于若未监测到用户语音满足语音唤醒条件,且接收到从属设备发送的第二设备状态信息时,则根据第二设备状态信息从从属设备中确定进行语音交互的目标交互设备;基于交互指令控制目标交互设备进行语音交互。Optionally, the voice
可选地,主设备语音交互确定模块920,还用于若未监测到用户语音满足语音唤醒条件且接收到从属设备发送的第二通用语音特征值,则根据第二通用语音特征值从从属设备中确定进行语音交互的目标交互设备;基于交互指令控制目标交互设备进行语音交互。Optionally, the voice
请参阅图10,图10为本申请另一实施例提供的一种语音控制方法的流程示意图。Please refer to FIG. 10 , which is a schematic flowchart of a voice control method provided by another embodiment of the present application.
如图10所示,语音控制方法包括:As shown in Figure 10, the voice control method includes:
S1002、监测到用户语音满足语音唤醒条件时,判断当前从属设备是否处于第二预设设备状态。S1002. When it is detected that the user's voice meets the voice wake-up condition, determine whether the current slave device is in the second preset device state.
在本申请实施例中,多设备场景中存在至少两个电子设备,处于同一多设备场景中的各电子设备属于同一设备组中,同一设备组中的电子设备具有从属关系或者主次关系,也即多设备场景中至少存在一个主设备以及至少一个从属设备,例如,多设备环境中包括音箱,电视机、手机以及穿戴手表,那么可以将数据处理性能较好的手机作为主设备,而将数据处理性能较差的音箱,电视机以及穿戴手表作为从属设备。为了方便描述,先以语音控制方法应用于从属设备进行描述。In the embodiment of the present application, there are at least two electronic devices in the multi-device scene, and the electronic devices in the same multi-device scene belong to the same device group, and the electronic devices in the same device group have a subordinate relationship or a primary and secondary relationship. That is to say, there is at least one master device and at least one slave device in a multi-device scenario. For example, a multi-device environment includes speakers, TVs, mobile phones, and wearable watches. Then the mobile phone with better data processing performance can be used as the master device, and the Speakers with poor data processing performance, TV sets, and wearable watches are used as slave devices. For the convenience of description, the voice control method is firstly applied to the slave device for description.
S1004、若当前从属设备处于第二预设设备状态,则将当前设备的第二设备状态信息发送至主设备。S1004. If the current slave device is in the second preset device state, send the second device state information of the current device to the master device.
S1006、若接收到主设备发送的交互指令,则控制当前从属设备进行语音交互,其中,交互指令为主设备根据主设备的第一设备状态信息、当前从属设备的第二设备状态信息以及其他从属设备的第二设备状态信息生成。S1006. If the interaction instruction sent by the master device is received, control the current slave device to perform voice interaction, wherein the interaction instruction is based on the first device status information of the master device, the second device status information of the current slave device, and other slave devices. Second device state information of the device is generated.
可选地,若当前从属设备不处于第二预设设备状态,且未接收到主设备发送的交互指令,则根据用户语音获取当前从属设备对应的第二通用语音特征值,以及将第二通用语音特征值发送至主设备;若接收到主设备发送的交互指令,则控制当前从属设备进行语音交互,其中交互指令为主设备根据主设备对应的第二语音特征值、当前从属设备的第二语音特征值以及其他从属设备的第二语音特征值生成。Optionally, if the current slave device is not in the second preset device state, and does not receive the interaction instruction sent by the master device, then obtain the second general speech feature value corresponding to the current slave device according to the user voice, and set the second general The voice feature value is sent to the master device; if the interaction command sent by the master device is received, the current slave device is controlled to perform voice interaction, wherein the interaction command is based on the second voice feature value corresponding to the master device and the second voice feature value of the current slave device. Voice feature values and second voice feature values of other slave devices are generated.
在本申请实施例中,将根据状态信息确定目标交互设备或者根据语音特征值确定目标交互设备的工作均设置在主设备中,一方面,由于主设备的性能较好,因此可以提高确定目标交互设备的速度,另一方面,由于从属设备的性能较差,那么可以减少从属设备的数据处理量,降低从属设备的功耗。In the embodiment of this application, the work of determining the target interaction device according to the state information or the target interaction device according to the voice feature value is set in the master device. On the one hand, because the performance of the master device is better, it can improve the determination of the target interaction The speed of the device, on the other hand, because the performance of the slave device is poor, then the data processing amount of the slave device can be reduced, and the power consumption of the slave device can be reduced.
请参阅图11,图11为本申请另一实施例提供的一种语音控制装置的结构框图。如图11所示,语音控制装置1100包括:Please refer to FIG. 11 . FIG. 11 is a structural block diagram of a voice control device provided by another embodiment of the present application. As shown in Figure 11, the
从属设备语音唤醒模块1110,用于监测到用户语音满足语音唤醒条件时,判断当前从属设备是否处于第二预设设备状态;The voice wake-
从属设备状态发送模块1120,用于若当前从属设备处于第二预设设备状态,则将当前设备的第二设备状态信息发送至主设备;The slave device
从属设备语音交互模块1130,用于若接收到主设备发送的交互指令,则控制当前从属设备进行语音交互,其中,交互指令为主设备根据主设备的第一设备状态信息、当前从属设备的第二设备状态信息以及其他从属设备的第二设备状态信息生成。The
可选地,从属设备语音交互模块1130,还用于若当前从属设备不处于第二预设设备状态,且未接收到主设备发送的交互指令,则根据用户语音获取当前从属设备对应的第二通用语音特征值,以及将第二通用语音特征值发送至主设备。Optionally, the
可选地,从属设备语音交互模块1130,还用于若接收到主设备发送的交互指令,则控制当前从属设备进行语音交互,其中交互指令为主设备根据主设备对应的第二语音特征值、当前从属设备的第二语音特征值以及其他从属设备的第二语音特征值生成。Optionally, the
本申请实施例还提供了一种计算机存储介质,计算机存储介质可以存储有多条指令,指令适于由处理器加载并执行如上述实施例中的任一项的方法的步骤。The embodiment of the present application also provides a computer storage medium, and the computer storage medium can store a plurality of instructions, and the instructions are suitable for being loaded by a processor and executing the steps of any one of the methods in the foregoing embodiments.
请参见图12,图12为本申请实施例提供的一种电子设备的结构示意图。如图12所示,电子设备1200可以包括:至少一个电子设备处理器1201,至少一个网络接口1204,用户接口1203,存储器1205,至少一个通信总线1202。Please refer to FIG. 12 , which is a schematic structural diagram of an electronic device provided by an embodiment of the present application. As shown in FIG. 12 , an
其中,通信总线1202用于实现这些组件之间的连接通信。Wherein, the
其中,用户接口1203可以包括显示屏(Display)、摄像头(Camera),可选用户接口1203还可以包括标准的有线接口、无线接口。Wherein, the
其中,网络接口1204可选的可以包括标准的有线接口、无线接口(如WI-FI接口)。Wherein, the
其中,电子设备处理器1201可以包括一个或者多个处理核心。电子设备处理器1201利用各种接口和线路连接整个电子设备1200内的各个部分,通过运行或执行存储在存储器1205内的指令、程序、代码集或指令集,以及调用存储在存储器1205内的数据,执行电子设备1200的各种功能和处理数据。可选的,电子设备处理器1201可以采用数字信号处理(Digital Signal Processing,DSP)、现场可编程门阵列(Field-Programmable GateArray,FPGA)、可编程逻辑阵列(Programmable Logic Array,PLA)中的至少一种硬件形式来实现。电子设备处理器1201可集成中央处理器(Central Processing Unit,CPU)、图像处理器(Graphics Processing Unit,GPU)和调制解调器等中的一种或几种的组合。其中,CPU主要处理操作系统、用户界面和应用程序等;GPU用于负责显示屏所需要显示的内容的渲染和绘制;调制解调器用于处理无线通信。可以理解的是,上述调制解调器也可以不集成到电子设备处理器1201中,单独通过一块芯片进行实现。Wherein, the
其中,存储器1205可以包括随机存储器(Random Access Memory,RAM),也可以包括只读存储器(Read-Only Memory,ROM)。可选的,该存储器1205包括非瞬时性计算机可读介质(non-transitory computer-readable storage medium)。存储器1205可用于存储指令、程序、代码、代码集或指令集。存储器1205可包括存储程序区和存储数据区,其中,存储程序区可存储用于实现操作系统的指令、用于至少一个功能的指令(比如触控功能、声音播放功能、图像播放功能等)、用于实现上述各个方法实施例的指令等;存储数据区可存储上面各个方法实施例中涉及到的数据等。存储器1205可选的还可以是至少一个位于远离前述电子设备处理器1201的存储装置。如图12所示,作为一种计算机存储介质的存储器1205中可以包括操作系统、网络通信模块、用户接口模块以及语音控制程序。Wherein, the
在图12所示的电子设备1200中,用户接口1203主要用于为用户提供输入的接口,获取用户输入的数据;而电子设备处理器1201可以用于调用存储器1205中存储的语音控制程序,并具体执行以下操作:In the
监测到用户语音满足语音唤醒条件时,判断当前设备是否处于第一预设设备状态;When it is detected that the user's voice meets the voice wake-up condition, it is determined whether the current device is in the first preset device state;
若当前设备处于第一预设设备状态,则将第一预设设备状态对应的第一设备状态信息发送至候选设备,候选设备与当前设备处于同一多设备场景中;If the current device is in the first preset device state, sending the first device state information corresponding to the first preset device state to the candidate device, where the candidate device and the current device are in the same multi-device scenario;
若接收到候选设备发送的第二设备状态信息,则根据第一预设设备状态以及第二设备状态信息对应的第二预设设备状态,确定当前设备是否进行语音交互。If the second device state information sent by the candidate device is received, it is determined whether the current device performs voice interaction according to the first preset device state and the second preset device state corresponding to the second device state information.
在一个实施例中,根据第一预设设备状态以及第二设备状态信息对应的第二预设设备状态,确定当前设备是否进行语音交互,包括:比较第一预设设备状态的优先级与第二设备状态信息对应的第二预设设备状态的优先级,根据优先级比较结果确定当前设备是否进行语音交互。In one embodiment, according to the first preset device state and the second preset device state corresponding to the second device state information, determining whether the current device performs voice interaction includes: comparing the priority of the first preset device state with the priority of the second preset device state For the priority of the second preset device state corresponding to the device state information, determine whether the current device performs voice interaction according to the priority comparison result.
在一个实施例中,比较第一预设设备状态的优先级与第二设备状态信息对应的第二预设设备状态的优先级,根据优先级比较结果确定当前设备是否进行语音交互,包括:根据预先设置的设备状态优先级顺序确定第一预设设备状态对应的第一状态优先级,以及确定第二设备状态信息对应的第二预设设备状态对应的第二状态优先级;若第一状态优先级大于第二状态优先级,则确定当前设备进行语音交互;若第一状态优先级小于第二状态优先级,则确定当前设备不进行语音交互。In one embodiment, comparing the priority of the first preset device state with the priority of the second preset device state corresponding to the second device state information, and determining whether the current device performs voice interaction according to the priority comparison result includes: according to The preset device state priority order determines the first state priority corresponding to the first preset device state, and determines the second state priority corresponding to the second preset device state corresponding to the second device state information; if the first state If the priority is greater than the second state priority, it is determined that the current device performs voice interaction; if the first state priority is less than the second state priority, it is determined that the current device does not perform voice interaction.
在一个实施例中,判断当前设备是否处于第一预设设备状态,包括:获取当前设备的设备类型,根据设备类型获取当前设备对应的指定状态参数;根据指定状态参数判断当前设备是否处于第一预设设备状态。In one embodiment, judging whether the current device is in the first preset device state includes: obtaining the device type of the current device, and obtaining specified state parameters corresponding to the current device according to the device type; judging whether the current device is in the first preset state according to the specified state parameters. Preset device state.
在一个实施例中,根据设备类型获取当前设备对应的指定状态参数,包括:若设备类型为手持设备,则获取当前设备对应的遮挡状态参数、放置角度状态参数以及抖动状态参数;根据设备状态参数判断当前设备是否处于第一预设设备状态,包括:根据遮挡参数、放置角度参数以及抖动参数判断当前设备是否处于手持状态。In one embodiment, obtaining specified state parameters corresponding to the current device according to the device type includes: if the device type is a handheld device, obtaining the occlusion state parameters, placement angle state parameters, and shaking state parameters corresponding to the current device; according to the device state parameters Judging whether the current device is in the first preset device state includes: judging whether the current device is in the handheld state according to the occlusion parameter, the placement angle parameter and the shaking parameter.
在一个实施例中,方法还包括:若未接收到候选设备发送的第二设备状态信息,则确定当前设备进行语音交互。In an embodiment, the method further includes: if the second device state information sent by the candidate device is not received, determining that the current device performs voice interaction.
在一个实施例中,方法还包括:若当前设备未处于第一预设设备状态且接收到候选设备发送的第二设备状态信息,则确定当前设备不进行语音交互。In an embodiment, the method further includes: if the current device is not in the first preset device state and the second device state information sent by the candidate device is received, determining that the current device does not perform voice interaction.
在一个实施例中,方法还包括:若当前设备未处于第一预设设备状态且未接收到候选设备发送的第二设备状态信息,则根据用户语音获取当前设备对应的第一通用语音特征值,以及将第一通用语音特征值发送至候选设备;若接收到候选设备发送的第二通用语音特征值,则根据第一通用语音特征值以及第二通用语音特征值,确定当前设备是否进行语音交互。In one embodiment, the method further includes: if the current device is not in the first preset device state and the second device state information sent by the candidate device has not been received, acquiring the first universal voice characteristic value corresponding to the current device according to the user voice , and send the first general speech feature value to the candidate device; if the second general speech feature value sent by the candidate device is received, then according to the first general speech feature value and the second general speech feature value, determine whether the current device performs speech interact.
在一个实施例中,根据用户语音获取当前设备对应的第一通用语音特征值,包括:根据用户语音获取当前设备对应第一通用语音特征参数以及各第一通用语音特征参数对应的第一通用语音特征权值;基于各第一通用语音特征参数以及各第一通用语音特征权值,计算当前设备对应的第一通用语音特征值。In one embodiment, obtaining the first general speech feature value corresponding to the current device according to the user voice includes: obtaining the first general speech feature parameter corresponding to the current device and the first general speech feature value corresponding to each first general speech feature parameter according to the user voice Feature weights: based on each first general speech feature parameter and each first general speech feature weight, calculate a first general speech feature value corresponding to the current device.
在一个实施例中,第一通用语音特征参数包括但不限于:发声源与当前设备之间的距离参数以及当前设备相对于发声源的方位参数。In one embodiment, the first general voice feature parameter includes, but is not limited to: a distance parameter between the sound source and the current device, and an orientation parameter of the current device relative to the sound source.
在一个实施例中,根据第一通用语音特征值以及第二通用语音特征值,确定当前设备是否进行语音交互,包括:若第一通用语音特征值大于第二通用语音特征值,则确定当前设备进行语音交互;若第一通用语音特征值小于第二通用语音特征值,则确定当前设备不进行语音交互;若第一通用语音特征值等于第二通用语音特征值,且确定当前设备为预先设置的优先交互设备,则确定当前设备进行语音交互。In one embodiment, determining whether the current device performs voice interaction according to the first common voice feature value and the second common voice feature value includes: if the first common voice feature value is greater than the second common voice feature value, then determining whether the current device Carry out voice interaction; if the first common voice feature value is less than the second common voice feature value, then determine that the current device does not perform voice interaction; if the first common voice feature value is equal to the second common voice feature value, and determine that the current device is preset If the priority interaction device is selected, it is determined that the current device performs voice interaction.
在一个实施例中,方法还包括:若未接收到候选设备发送的第二通用语音特征值,则确定当前设备进行语音交互。In an embodiment, the method further includes: determining that the current device performs voice interaction if the second common voice characteristic value sent by the candidate device is not received.
在图12所示的电子设备1200中,用户接口1203主要用于为用户提供输入的接口,获取用户输入的数据;而电子设备处理器1201可以用于调用存储器1205中存储的语音控制程序,并具体执行以下操作:In the
监测到用户语音满足语音唤醒条件时,判断当前主设备是否处于第一预设设备状态;若当前主设备处于第一预设设备状态,且接收到从属设备发送的第二设备状态信息,则根据第一预设设备状态对应的第一设备状态信息以及第二设备状态信息,从当前主设备以及从属设备中确定进行语音交互的目标交互设备;基于交互指令控制目标交互设备进行语音交互。When it is detected that the user's voice meets the voice wake-up condition, it is judged whether the current master device is in the first preset device state; if the current master device is in the first preset device state, and the second device state information sent by the slave device is received, the The first device state information and the second device state information corresponding to the first preset device state determine the target interactive device for voice interaction from the current master device and the slave device; control the target interactive device to perform voice interaction based on the interaction instruction.
在一个实施例中,若目标交互设备为当前主设备,则基于交互指令控制当前主设备进行语音交互;若目标交互设备为从属设备,则将交互指令发送至目标交互设备,交互指令用于指示目标交互设备进行语音交互。In one embodiment, if the target interaction device is the current master device, the current master device is controlled to perform voice interaction based on the interaction instruction; if the target interaction device is the slave device, the interaction instruction is sent to the target interaction device, and the interaction instruction is used to indicate The target interaction device performs voice interaction.
在一个实施例中,语音控制方法还包括:若当前主设备处于第一预设设备状态,且未接收到从属设备发送的第二设备状态信息,则控制当前主设备进行语音交互。In one embodiment, the voice control method further includes: if the current master device is in the first preset device state and has not received the second device state information sent by the slave device, controlling the current master device to perform voice interaction.
在一个实施例中,语音控制方法还包括:若当前主设备未处于第一预设设备状态,且接收到从属设备发送的第二设备状态信息,则根据第二设备状态信息从从属设备中确定进行语音交互的目标交互设备;基于交互指令控制目标交互设备进行语音交互。In one embodiment, the voice control method further includes: if the current master device is not in the first preset device state and receives the second device state information sent by the slave device, determining from the slave device according to the second device state information The target interactive device for voice interaction; based on the interactive command, the target interactive device is controlled to perform voice interaction.
在一个实施例中,语音控制方法还包括:若当前主设备未处于第一预设设备状态且未接收到从属设备发送的第二设备状态信息,则根据用户语音获取当前主设备对应的第一通用语音特征值;若接收到从属设备发送的第二通用语音特征值,则根据第一通用语音特征值以及第二通用语音特征值,从当前主设备以及从属设备中确定进行语音交互的目标交互设备;基于交互指令控制目标交互设备进行语音交互。In one embodiment, the voice control method further includes: if the current master device is not in the first preset device state and has not received the second device state information sent by the slave device, acquiring the first device corresponding to the current master device according to the user voice. General voice feature value; if the second general voice feature value sent by the slave device is received, then according to the first general voice feature value and the second general voice feature value, determine the target interaction for voice interaction from the current master device and the slave device Device; based on the interactive command, the target interactive device is controlled to perform voice interaction.
在一个实施例中,语音控制方法还包括:若未监测到用户语音满足语音唤醒条件,且接收到从属设备发送的第二设备状态信息时,则根据第二设备状态信息从从属设备中确定进行语音交互的目标交互设备;基于交互指令控制目标交互设备进行语音交互。In one embodiment, the voice control method further includes: if it is not detected that the user's voice meets the voice wake-up condition, and the second device status information sent by the slave device is received, determining from the slave device according to the second device status information The target interactive device for voice interaction; control the target interactive device to perform voice interaction based on the interactive command.
在一个实施例中,语音控制方法还包括:若未监测到用户语音满足语音唤醒条件且接收到从属设备发送的第二通用语音特征值,则根据第二通用语音特征值从从属设备中确定进行语音交互的目标交互设备;基于交互指令控制目标交互设备进行语音交互。In one embodiment, the voice control method further includes: if it is not detected that the user's voice satisfies the voice wake-up condition and the second universal voice characteristic value sent by the slave device is received, determining from the slave device according to the second universal voice characteristic value The target interactive device for voice interaction; control the target interactive device to perform voice interaction based on the interactive command.
在图12所示的电子设备1200中,用户接口1203主要用于为用户提供输入的接口,获取用户输入的数据;而电子设备处理器1201可以用于调用存储器1205中存储的语音控制程序,并具体执行以下操作:In the
监测到用户语音满足语音唤醒条件时,判断当前从属设备是否处于第二预设设备状态;若当前从属设备处于第二预设设备状态,则将当前设备的第二设备状态信息发送至主设备;若接收到主设备发送的交互指令,则控制当前从属设备进行语音交互,其中,交互指令为主设备根据主设备的第一设备状态信息、当前从属设备的第二设备状态信息以及其他从属设备的第二设备状态信息生成。When it is detected that the user's voice meets the voice wake-up condition, it is judged whether the current slave device is in the second preset device state; if the current slave device is in the second preset device state, then the second device state information of the current device is sent to the master device; If the interaction command sent by the master device is received, the current slave device is controlled to perform voice interaction. Second device status information is generated.
在一个实施例中,语音控制方法还包括:若当前从属设备不处于第二预设设备状态,且未接收到主设备发送的交互指令,则根据用户语音获取当前从属设备对应的第二通用语音特征值,以及将第二通用语音特征值发送至主设备;若接收到主设备发送的交互指令,则控制当前从属设备进行语音交互,其中交互指令为主设备根据主设备对应的第二语音特征值、当前从属设备的第二语音特征值以及其他从属设备的第二语音特征值生成。In one embodiment, the voice control method further includes: if the current slave device is not in the second preset device state and has not received the interaction instruction sent by the master device, acquiring the second general voice corresponding to the current slave device according to the user voice feature value, and send the second universal voice feature value to the master device; if the interaction command sent by the master device is received, the current slave device is controlled to perform voice interaction, wherein the interaction command is based on the second voice feature corresponding to the master device value, the second voice feature value of the current slave device, and the second voice feature value of other slave devices.
在本申请实施例所提供的几个实施例中,应该理解到,所揭露的装置和方法,可以通过其它的方式实现。例如,以上所描述的装置实施例仅仅是示意性的,例如,模块的划分,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式,例如多个模块或组件可以结合或者可以集成到另一个系统,或一些特征可以忽略,或不执行。另一点,所显示或讨论的相互之间的耦合或直接耦合或通信连接可以是通过一些接口,装置或模块的间接耦合或通信连接,可以是电性,机械或其它的形式。In the several embodiments provided in the embodiments of the present application, it should be understood that the disclosed devices and methods may be implemented in other ways. For example, the device embodiments described above are only illustrative. For example, the division of modules is only a logical function division. In actual implementation, there may be other division methods. For example, multiple modules or components can be combined or integrated. to another system, or some features may be ignored, or not implemented. In another point, the mutual coupling or direct coupling or communication connection shown or discussed may be through some interfaces, and the indirect coupling or communication connection of devices or modules may be in electrical, mechanical or other forms.
作为分离部件说明的模块可以是或者也可以不是物理上分开的,作为模块显示的部件可以是或者也可以不是物理模块,即可以位于一个地方,或者也可以分布到多个网络模块上。可以根据实际的需要选择其中的部分或者全部模块来实现本实施例方案的目的。A module described as a separate component may or may not be physically separated, and a component shown as a module may or may not be a physical module, that is, it may be located in one place, or may also be distributed to multiple network modules. Part or all of the modules can be selected according to actual needs to achieve the purpose of the solution of this embodiment.
另外,在本申请实施例各个实施例中的各功能模块可以集成在一个处理模块中,也可以是各个模块单独物理存在,也可以两个或两个以上模块集成在一个模块中。上述集成的模块既可以采用硬件的形式实现,也可以采用软件功能模块的形式实现。In addition, each functional module in each embodiment of the embodiment of the present application may be integrated into one processing module, each module may exist separately physically, or two or more modules may be integrated into one module. The above-mentioned integrated modules can be implemented in the form of hardware or in the form of software function modules.
集成的模块如果以软件功能模块的形式实现并作为独立的产品销售或使用时,可以存储在一个计算机可读取存储介质中。基于这样的理解,本申请实施例的技术方案本质上或者说对现有技术做出贡献的部分或者该技术方案的全部或部分可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储介质中,包括若干指令用以使得一台计算机设备(可以是个人计算机,服务器,或者网络设备等)执行本申请实施例各个实施例方法的全部或部分步骤。而前述的存储介质包括:U盘、移动硬盘、只读存储器(ROM,Read-OnlyMemory)、随机存取存储器(RAM,Random Access Memory)、磁碟或者光盘等各种可以存储程序代码的介质。If the integrated modules are realized in the form of software function modules and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the embodiment of the present application is essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage The medium includes several instructions to enable a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods in the embodiments of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), magnetic disk or optical disk, and other media that can store program codes.
需要说明的是,对于前述的各方法实施例,为了简便描述,故将其都表述为一系列的动作组合,但是本领域技术人员应该知悉,本申请实施例并不受所描述的动作顺序的限制,因为依据本申请实施例,某些步骤可以采用其它顺序或者同时进行。其次,本领域技术人员也应该知悉,说明书中所描述的实施例均属于优选实施例,所涉及的动作和模块并不一定都是本申请实施例所必须的。It should be noted that, for the sake of simplicity of description, the aforementioned method embodiments are all expressed as a series of action combinations, but those skilled in the art should know that the embodiments of the present application are not limited by the described action sequence. Because according to the embodiment of the present application, certain steps may be performed in other orders or simultaneously. Secondly, those skilled in the art should also know that the embodiments described in the specification belong to preferred embodiments, and the actions and modules involved are not necessarily required by the embodiments of the present application.
在上述实施例中,对各个实施例的描述都各有侧重,某个实施例中没有详述的部分,可以参见其它实施例的相关描述。In the foregoing embodiments, the descriptions of each embodiment have their own emphases, and for parts not described in detail in a certain embodiment, reference may be made to relevant descriptions of other embodiments.
以上为对本申请实施例所提供的语音控制方法、装置、存储介质以及电子设备的描述,对于本领域的技术人员,依据本申请实施例实施例的思想,在具体实施方式及应用范围上均会有改变之处,综上,本说明书内容不应理解为对本申请实施例的限制。The above is the description of the voice control method, device, storage medium and electronic equipment provided by the embodiment of the present application. For those skilled in the art, based on the idea of the embodiment of the present application, they will understand both the specific implementation and the scope of application. There are changes. In summary, the contents of this specification should not be understood as limiting the embodiments of this application.
Claims (26)
Priority Applications (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202211443786.5A CN115810356A (en) | 2022-11-17 | 2022-11-17 | Voice control method, device, storage medium and electronic equipment |
PCT/CN2023/117319 WO2024103926A1 (en) | 2022-11-17 | 2023-09-06 | Voice control methods and apparatuses, storage medium, and electronic device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202211443786.5A CN115810356A (en) | 2022-11-17 | 2022-11-17 | Voice control method, device, storage medium and electronic equipment |
Publications (1)
Publication Number | Publication Date |
---|---|
CN115810356A true CN115810356A (en) | 2023-03-17 |
Family
ID=85483428
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202211443786.5A Pending CN115810356A (en) | 2022-11-17 | 2022-11-17 | Voice control method, device, storage medium and electronic equipment |
Country Status (2)
Country | Link |
---|---|
CN (1) | CN115810356A (en) |
WO (1) | WO2024103926A1 (en) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN117133282A (en) * | 2023-03-27 | 2023-11-28 | 荣耀终端有限公司 | Voice interaction method and electronic equipment |
WO2024103926A1 (en) * | 2022-11-17 | 2024-05-23 | Oppo广东移动通信有限公司 | Voice control methods and apparatuses, storage medium, and electronic device |
Family Cites Families (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US10643609B1 (en) * | 2017-03-29 | 2020-05-05 | Amazon Technologies, Inc. | Selecting speech inputs |
CN109391528A (en) * | 2018-08-31 | 2019-02-26 | 百度在线网络技术(北京)有限公司 | Awakening method, device, equipment and the storage medium of speech-sound intelligent equipment |
CN111276139B (en) * | 2020-01-07 | 2023-09-19 | 百度在线网络技术(北京)有限公司 | Voice wake-up method and device |
CN113241068A (en) * | 2021-03-26 | 2021-08-10 | 青岛海尔科技有限公司 | Voice signal response method and device, storage medium and electronic device |
CN114627871A (en) * | 2022-03-22 | 2022-06-14 | 北京小米移动软件有限公司 | Method, device, equipment and storage medium for waking up equipment |
CN115810356A (en) * | 2022-11-17 | 2023-03-17 | Oppo广东移动通信有限公司 | Voice control method, device, storage medium and electronic equipment |
-
2022
- 2022-11-17 CN CN202211443786.5A patent/CN115810356A/en active Pending
-
2023
- 2023-09-06 WO PCT/CN2023/117319 patent/WO2024103926A1/en unknown
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2024103926A1 (en) * | 2022-11-17 | 2024-05-23 | Oppo广东移动通信有限公司 | Voice control methods and apparatuses, storage medium, and electronic device |
CN117133282A (en) * | 2023-03-27 | 2023-11-28 | 荣耀终端有限公司 | Voice interaction method and electronic equipment |
Also Published As
Publication number | Publication date |
---|---|
WO2024103926A1 (en) | 2024-05-23 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN111192591B (en) | Awakening method and device of intelligent equipment, intelligent sound box and storage medium | |
US12118999B2 (en) | Reducing the need for manual start/end-pointing and trigger phrases | |
US11443744B2 (en) | Electronic device and voice recognition control method of electronic device | |
CN112863547B (en) | Virtual resource transfer processing method, device, storage medium and computer equipment | |
JP7348288B2 (en) | Voice interaction methods, devices, and systems | |
CN106847298B (en) | Pickup method and device based on diffuse type voice interaction | |
US20160162469A1 (en) | Dynamic Local ASR Vocabulary | |
WO2024103926A1 (en) | Voice control methods and apparatuses, storage medium, and electronic device | |
CN108681440A (en) | A kind of smart machine method for controlling volume and system | |
JP7694968B2 (en) | Audio signal processing method, device, electronic device, and computer program | |
CN109616135B (en) | Audio processing method, device and storage medium | |
CN109982228B (en) | Microphone fault detection method and mobile terminal | |
CN107919138B (en) | Emotion processing method in voice and mobile terminal | |
JP2009518662A (en) | Determining audio device quality | |
CN109284080B (en) | Sound effect adjusting method and device, electronic equipment and storage medium | |
EP3846020A1 (en) | Sound effect adjusting method and apparatus, electronic device, and storage medium | |
US20150310878A1 (en) | Method and apparatus for determining emotion information from user voice | |
CN106940997B (en) | Method and device for sending voice signal to voice recognition system | |
WO2016094418A1 (en) | Dynamic local asr vocabulary | |
CN114360527A (en) | Vehicle-mounted voice interaction method, device, equipment and storage medium | |
CN106126179B (en) | Information processing method and electronic equipment | |
WO2022068694A1 (en) | Electronic device and wake-up method thereof | |
CN114694661A (en) | A first terminal device, a second terminal device and a voice wake-up method | |
CN111833883B (en) | Voice control method, device, electronic device and storage medium | |
US20160349722A1 (en) | Systems and methods for dynamic operation of electronic devices based on detection of one or more events |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination |