CN108733341B - Voice interaction method and device - Google Patents

Voice interaction method and device Download PDF

Info

Publication number
CN108733341B
CN108733341B CN201810479491.0A CN201810479491A CN108733341B CN 108733341 B CN108733341 B CN 108733341B CN 201810479491 A CN201810479491 A CN 201810479491A CN 108733341 B CN108733341 B CN 108733341B
Authority
CN
China
Prior art keywords
volume
feedback
voice
environment
time interval
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.)
Active
Application number
CN201810479491.0A
Other languages
Chinese (zh)
Other versions
CN108733341A (en
Inventor
付忠鑫
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Mobvoi Information Technology Co Ltd
Original Assignee
Mobvoi Information Technology Co Ltd
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by Mobvoi Information Technology Co Ltd filed Critical Mobvoi Information Technology Co Ltd
Priority to CN201810479491.0A priority Critical patent/CN108733341B/en
Publication of CN108733341A publication Critical patent/CN108733341A/en
Application granted granted Critical
Publication of CN108733341B publication Critical patent/CN108733341B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/16Sound input; Sound output
    • G06F3/167Audio in a user interface, e.g. using voice commands for navigating, audio feedback

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Multimedia (AREA)
  • Health & Medical Sciences (AREA)
  • Audiology, Speech & Language Pathology (AREA)
  • General Health & Medical Sciences (AREA)
  • Human Computer Interaction (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Telephone Function (AREA)

Abstract

The embodiment of the invention provides a voice interaction method and a voice interaction device, wherein the method comprises the following steps: when voice information input by a user is detected, acquiring environment volume information; determining a feedback time interval and feedback volume according to the environment volume information; and performing voice feedback on the voice information according to the feedback time interval and the feedback volume. Therefore, the scheme provided by the invention can improve the self-adaptive adjustment capability of the voice interaction along with the change of the environment.

Description

Voice interaction method and device
Technical Field
The invention relates to the technical field of computers, in particular to a voice interaction method and device.
Background
Because intelligent equipment (such as intelligent toys, intelligent televisions, intelligent sound boxes and the like) can perform voice interaction with users and is high in technological sense, the intelligent equipment is more and more widely applied to daily life of people.
Currently, when a smart device performs voice interaction with a user, the smart device generally feeds back voice according to a preset feedback mode (a set feedback volume or a set feedback duration) after receiving the voice of the user. However, when the smart device is applied, there may be noise such as music playing, user speech conversation, etc. in the environment where the smart device is located. When the voice is fed back in a preset feedback manner, the user may hear the feedback less effectively due to the presence of noise in the environment.
Disclosure of Invention
In view of this, the present invention provides a voice interaction method and device, and mainly aims to improve the capability of performing adaptive adjustment on voice interaction along with the change of the environment.
In a first aspect, the present invention provides a voice interaction method, including:
when voice information input by a user is detected, acquiring environment volume information;
determining a feedback time interval and feedback volume according to the environment volume information;
and performing voice feedback on the voice information according to the feedback time interval and the feedback volume.
Alternatively to this, the first and second parts may,
the ambient volume information comprises a first ambient volume;
before the collecting the environment volume information when the voice information input by the user is detected, further comprising:
setting at least one volume interval, wherein each volume interval corresponds to a sample volume and a sample time interval respectively;
the determining the feedback time interval and the feedback volume according to the environment volume information includes:
selecting a target volume interval including the first ambient volume from the at least one volume interval;
determining the sample volume corresponding to the target volume interval as the feedback volume;
and determining a sample time interval corresponding to the target volume interval as the feedback time interval.
Alternatively to this, the first and second parts may,
the performing voice feedback on the voice information according to the feedback time interval and the feedback volume includes:
recording the duration of the voice information from the detection of the voice information;
determining feedback voice corresponding to the voice information;
and judging whether the duration is equal to the feedback time interval or not, if so, playing the feedback voice, and setting the volume of the played feedback voice as the feedback volume.
Alternatively to this, the first and second parts may,
the collecting environment volume information comprises:
a1: acquiring the current second environment volume in the environment when the voice information is acquired;
a2: judging whether the volume of the current second environment is larger than a preset volume threshold, if so, executing A3; otherwise, a4 is executed;
a3: after a preset time interval, continuously acquiring the volume of the next second environment, judging whether the accumulated acquisition times reach a preset time threshold value, and if so, executing A4; otherwise, taking the currently acquired second environment volume as the current second environment volume, and executing A2;
a4: and determining the second environment volume collected currently as the environment volume information.
Alternatively to this, the first and second parts may,
the performing voice feedback on the voice information according to the feedback time interval and the feedback volume includes:
recording the accumulated duration of the environment volume information after the environment volume information is determined;
determining feedback voice corresponding to the voice information;
and judging whether the accumulated duration is equal to the feedback time interval or not, if so, playing the feedback voice, and setting the volume of the played feedback voice as the feedback volume.
In a second aspect, the present invention provides a voice interaction apparatus, including:
the acquisition module is used for acquiring environment volume information when voice information input by a user is detected;
the determining module is used for determining a feedback time interval and feedback volume according to the environment volume information acquired by the acquiring module;
and the feedback module is used for performing voice feedback on the voice information acquired by the acquisition module according to the feedback time interval and the feedback volume determined by the determination module.
Alternatively to this, the first and second parts may,
the ambient volume information comprises a first ambient volume;
further comprising: setting a module;
the setting module is used for setting at least one volume interval, wherein each volume interval corresponds to a sample volume and a sample time interval respectively;
the determining module is configured to select a target volume interval including the first ambient volume from the at least one volume interval set by the setting module; determining the sample volume corresponding to the target volume interval as the feedback volume; and determining a sample time interval corresponding to the target volume interval as the feedback time interval.
Alternatively to this, the first and second parts may,
the feedback module comprises: a first recording submodule and a first feedback submodule;
the first recording submodule is used for recording the duration of the voice information from the detection of the voice information;
the first feedback submodule is used for determining feedback voice corresponding to the voice information; and judging whether the duration recorded by the first recording submodule is equal to the feedback time interval or not, if so, playing the feedback voice, and the volume of playing the feedback voice is the feedback volume.
In a third aspect, the present invention provides a storage medium, where the storage medium includes a stored program, and when the program runs, a device in which the storage medium is located is controlled to execute the voice interaction method described in any one of the above.
In a fourth aspect, the present invention provides an electronic device, including a processor, a memory, and a bus; the processor and the memory complete mutual communication through the bus; the processor is configured to call program instructions in the memory to perform the voice interaction method of any one of the above.
The embodiment of the invention provides a voice interaction method and a voice interaction device, which are used for collecting environment volume information (the environment volume information can comprise environment volume) in the environment when voice information input by a user is detected. And then determining a feedback time interval and a feedback volume according to the collected environment volume information. And finally, performing voice feedback on the voice information input by the user according to the determined feedback time interval and the feedback volume. As can be seen from the above description, in the embodiment of the present invention, the feedback time interval and the feedback volume required for performing the voice feedback on the user voice information are changed according to the environment volume information, and are not fixed. Therefore, the scheme provided by the embodiment of the invention can improve the self-adaptive adjustment capability of the voice interaction along with the change of the environment.
The foregoing description is only an overview of the technical solutions of the present invention, and the embodiments of the present invention are described below in order to make the technical means of the present invention more clearly understood and to make the above and other objects, features, and advantages of the present invention more clearly understandable.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below, and it is obvious that the drawings in the following description are some embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to these drawings without creative efforts.
FIG. 1 is a flow chart illustrating a method of voice interaction according to an embodiment of the present invention;
FIG. 2 is a flow chart illustrating a method of voice interaction according to another embodiment of the present invention;
FIG. 3 is a schematic structural diagram of a voice interaction apparatus according to an embodiment of the present invention;
FIG. 4 is a schematic structural diagram of a voice interaction apparatus including a setup module according to an embodiment of the present invention;
FIG. 5 is a schematic structural diagram of a voice interaction apparatus including a first recording sub-module and a first feedback sub-module according to an embodiment of the present invention;
FIG. 6 is a schematic structural diagram of a voice interaction apparatus including a second recording sub-module and a second feedback sub-module according to an embodiment of the present invention;
fig. 7 is a schematic structural diagram of an electronic device according to an embodiment of the present invention.
Detailed Description
Exemplary embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. While exemplary embodiments of the present disclosure are shown in the drawings, it should be understood that the present disclosure may be embodied in various forms and should not be limited to the embodiments set forth herein. Rather, these embodiments are provided so that this disclosure will be thorough and complete, and will fully convey the scope of the disclosure to those skilled in the art.
As shown in fig. 1, an embodiment of the present invention provides a voice interaction method, which may include the following steps:
step 101: when voice information input by a user is detected, acquiring environment volume information;
step 102: determining a feedback time interval and feedback volume according to the environment volume information;
step 103: and performing voice feedback on the voice information according to the feedback time interval and the feedback volume.
According to the embodiment shown in fig. 1, the environmental volume information (which may include the environmental volume) in the environment is collected when the voice information input by the user is detected. And then determining a feedback time interval and a feedback volume according to the collected environment volume information. And finally, performing voice feedback on the voice information input by the user according to the determined feedback time interval and the feedback volume. As can be seen from the above description, in the embodiment of the present invention, the feedback time interval and the feedback volume required for performing the voice feedback on the user voice information are changed according to the environment volume information, and are not fixed. Therefore, the scheme provided by the embodiment of the invention can improve the self-adaptive adjustment capability of the voice interaction along with the change of the environment.
In one embodiment of the invention, when a user needs to perform voice interaction with the intelligent device, voice information can be input into the intelligent device. The input method of the voice information may include, but is not limited to: the user provides a voice signal (for example, speaking) within the voice recognition range of the smart device, and then the smart device performs voice recognition on the voice signal (the voice recognition process may be converting the voice recognition into a text and then determining a valid keyword in the text), so as to obtain the voice information input by the user.
In one embodiment of the present invention, the environmental volume information related in step 101 of the flowchart shown in fig. 1 may include, but is not limited to, environmental volume. The ambient volume may reflect the magnitude of the noise in the environment.
In one embodiment of the invention, the environmental volume information in the environment can be collected through the sound collector.
In an embodiment of the present invention, when the environmental volume information related in step 101 in the flowchart shown in fig. 1 includes a first environmental volume, before collecting the environmental volume information when the voice information input by the user is detected in step 101 in the flowchart shown in fig. 1, the following steps may be further included:
setting at least one volume interval, wherein each volume interval corresponds to a sample volume and a sample time interval respectively;
then, the step 102 in the flowchart shown in fig. 1 determines the feedback time interval and the feedback volume according to the environment volume information, which may include:
selecting a target volume interval including the first ambient volume from the at least one volume interval;
determining the sample volume corresponding to the target volume interval as the feedback volume;
and determining a sample time interval corresponding to the target volume interval as the feedback time interval.
In this embodiment, the number of volume intervals and the range of each volume interval may be determined according to the service requirement. Moreover, the sample volume and the sample time interval corresponding to each volume interval may be determined according to the following rules: the higher the volume corresponding to the volume interval, the higher the volume of the corresponding sample, and the longer the time interval of the corresponding sample.
Specifically, when the volume of the first environment is high, which indicates that the environment is noisy, a high feedback volume and a long feedback time interval are required. The higher feedback volume is to allow the user to clearly hear the voice feedback even in a noisy environment. The longer feedback time interval is to consider the probability that noise in the environment may be less noisy after the feedback time interval so that the user may hear the voice feedback in a less noisy environment.
Specifically, when the first ambient volume is low, which indicates that the environment is quiet, a low feedback volume and a short feedback time interval are required. The lower feedback volume is to allow the user to clearly hear the voice feedback in a less noisy environment, and to avoid the occurrence of ear discomfort due to loud sound. The shorter feedback time interval is to enable the user to quickly obtain voice feedback, and reduce the time for the user to wait for the voice feedback.
In the present embodiment, the following are exemplified: volume intervals 1[0, 40], 2[41, 60], 3[61, 90] are set. And the unit of each numerical value in each volume interval is decibel. The sample time interval corresponding to the volume interval 1 is 2S and the sample volume is 30 db, the sample time interval corresponding to the volume interval 2 is 3S and the sample volume is 50 db, the sample time interval corresponding to the volume interval 3 is 4S and the sample volume is 70 db. For example, the determined ambient volume is 45 db, and since the volume interval 2 includes 45 db, the sample time interval 3S corresponding to the volume interval 2 is determined as the feedback volume and the sample volume is determined as 50 db as the feedback time interval.
According to the embodiment, one or more volume intervals are set, so that after the ambient volume is determined, the volume interval including the ambient volume can be quickly selected, and the sample volume and the sample time interval corresponding to the selected volume are respectively determined as the feedback volume and the feedback time interval. Therefore, the feedback volume and the feedback time interval corresponding to the environment volume can be quickly determined when the voice information is received.
In an embodiment of the present invention, the step 103 in the flowchart shown in fig. 1 performs voice feedback on the voice information according to the feedback time interval and the feedback volume, and may include:
recording the duration of the voice information from the detection of the voice information;
determining feedback voice corresponding to the voice information;
and judging whether the duration is equal to the feedback time interval or not, if so, playing the feedback voice, and setting the volume of the played feedback voice as the feedback volume.
In this embodiment, when the voice information input by the user is acquired, the duration of acquiring the voice information is recorded. Recording the duration of the voice message can determine whether to play the feedback response. And when the duration is judged not to be equal to the feedback time interval, indicating that the current time does not reach the playing time of the feedback voice. And when the duration is judged to be equal to the feedback time interval, indicating that the current time reaches the playing time of the feedback voice, and playing the feedback voice. It should be noted that the volume of playing the feedback voice should be the feedback volume so that the user can clearly hear the feedback voice.
In this embodiment, the method for determining the feedback voice corresponding to the voice information may include at least the following two methods:
first, in the voice repetition mode, a voice included in the voice information is directly determined as a feedback voice. For example, the voice message is hello, and the hello is used as the feedback voice due to the voice repetition mode.
Secondly, in the voice conversation mode, keywords in the voice information are analyzed, sample voice corresponding to the keywords is determined in a preset sample voice library according to the determined keywords, and feedback voice is determined according to the sample voice. For example, if the voice information is what the remaining power is, the determined keyword is the remaining power. The corresponding sample voice is the remaining power. And then obtaining that the remaining percentage of the current electric quantity is 80%, and determining that the feedback voice is 80% of the remaining electric quantity according to the sample voice.
In the present embodiment, the following are exemplified: the feedback time interval is 2S, the feedback volume is 30 decibels, and the feedback voice is hello. And if the duration of the acquired voice information is judged to be equal to the feedback time interval 2S, playing the feedback voice 'hello', wherein the volume of playing the 'hello' is 30 decibels.
According to the embodiment, the duration of acquiring the voice information is recorded when the voice information is acquired. And playing feedback voice corresponding to the voice information by the feedback volume when the duration is judged to be equal to the feedback time interval. Therefore, the feedback voice can be ensured to be accurately played according to the feedback time interval.
In an embodiment of the present invention, the acquiring the environmental volume information related to step 101 in the flowchart shown in fig. 1 may include:
a1: acquiring the current second environment volume in the environment when the voice information is acquired;
a2: judging whether the volume of the current second environment is larger than a preset volume threshold, if so, executing A3; otherwise, a4 is executed;
a3: after a preset time interval, continuously acquiring the volume of the next second environment, judging whether the accumulated acquisition times reach a preset time threshold value, and if so, executing A4; otherwise, taking the currently acquired second environment volume as the current second environment volume, and executing A2;
a4: and determining the second environment volume collected currently as the environment volume information.
In this embodiment, the volume threshold may be determined according to the service requirement. For example, the volume threshold may be a volume value (e.g., 60 decibels) that defines the ambient noise.
In this embodiment, the threshold of times may be determined according to the service requirement. For example, the threshold number of times may be determined according to the speed of voice feedback. When the voice feedback speed is required to be high, the time threshold is small. The number threshold may be set larger when a slower speed of voice feedback is required.
In this embodiment, when the voice information is acquired, the current environment volume in the environment is collected, and whether the current environment volume is greater than a volume threshold is determined.
When the sound volume is judged to be not larger than the sound volume threshold value, the environment is quite quiet, and the user can clearly receive the feedback voice when performing the related operation of the feedback voice at the moment.
And when the sound volume is judged to be larger than the volume threshold value, the environment is noisy, and if the relevant operation of feeding back the voice is carried out at the moment, the effect of receiving the feedback voice by the user is not good enough. At this time, the environmental volume in the environment should be continuously collected after a preset time interval, and whether the currently collected environmental volume reaches a time threshold is judged. If the time threshold is reached, the description time is too long, and the feedback speed is directly used as the ambient volume information. If not, the above-mentioned relative process for judging whether the current environment volume is greater than the volume threshold value is executed circularly.
In the present embodiment, the following are exemplified: the volume threshold is 60 db, the number threshold is 2, and the time interval is 0.5S. When the voice information is acquired, the current environment volume in the acquisition environment is 70 decibels. And judging that the current environment volume is 70 decibels greater than the volume threshold value 60 decibels, and continuing to acquire the next environment volume of 59 decibels after 0.5S. And determining 59 decibels as the environment volume information if the accumulated collection times 2 reach the time threshold value 2.
According to the embodiment, the collected environment volumes are preliminarily screened by using conditions such as the volume threshold value, the frequency threshold value and the like, so that the determined environment volume information can better meet the requirement of voice feedback.
In an embodiment of the present invention, the step 103 in the flowchart shown in fig. 1 performs voice feedback on the voice information according to the feedback time interval and the feedback volume, and may include:
recording the accumulated duration of the environment volume information after the environment volume information is determined;
determining feedback voice corresponding to the voice information;
and judging whether the accumulated duration is equal to the feedback time interval or not, if so, playing the feedback voice, and setting the volume of the played feedback voice as the feedback volume.
In this embodiment, the method for determining the feedback voice corresponding to the voice information is substantially the same as that described in the above embodiment, and will not be described herein again.
In this embodiment, when determining the environmental volume information, the accumulated duration of the determined environmental volume information is recorded.
In the present embodiment, the following are exemplified: the feedback time interval is 2S, the feedback volume is 30 decibels, and the feedback voice is hello. And when the judgment shows that the accumulated duration of the environment volume information is equal to the feedback time interval 2S, playing the feedback voice 'hello', wherein the volume for playing the 'hello' is 30 decibels.
According to the embodiment, when the environment volume information is determined, the accumulated duration of the determined environment volume information is recorded, and when the accumulated duration is judged to be equal to the feedback time interval, the feedback voice corresponding to the voice information is played at the feedback volume. Therefore, the feedback voice can be ensured to be accurately played according to the feedback time interval.
In an embodiment of the present invention, it can be seen from the above embodiments that the voice interaction method can be applied to various intelligent devices. The smart device may not include, but is not limited to, a smart television, a smart refrigerator, a smart robot, a smart watch, a smart speaker, a smart air conditioner, and a smart toy.
The following describes a voice interaction method by taking an intelligent device as a sound box as an example. As shown in fig. 2, the voice interaction method may include the steps of:
step 201: and setting at least one volume interval, wherein each volume interval corresponds to a sample volume and a sample time interval respectively.
In this step, the volume sections 1[0, 40], 2[41, 60], and 3[61, 90] are set. And the unit of each numerical value in each volume interval is decibel. The sample time interval corresponding to the volume interval 1 is 2S and the sample volume is 30 db, the sample time interval corresponding to the volume interval 2 is 3S and the sample volume is 50 db, the sample time interval corresponding to the volume interval 3 is 4S and the sample volume is 70 db.
Step 202: detecting whether voice information input by a user exists, if so, executing step 203; otherwise, the step is continuously executed.
In this step, the voice information input by the user is acquired as "what the remaining power is now".
Step 203: and when the voice information is detected, acquiring the current environment volume in the environment.
In this step, when the voice information is acquired, the current environment volume in the environment where the sound box is located is collected to be 70 decibels.
Step 204: judging whether the current environment volume is larger than a preset volume threshold value, if so, executing step 205; otherwise, step 206 is performed.
In this step, if the volume threshold is 60 db, it is determined that the current environmental volume is 70 db greater than the volume threshold by 60 db, and step 205 is executed.
Step 205: after the preset time interval, continuing to collect the next environment volume, and judging whether the accumulated collection times reach a preset time threshold value, if so, executing step 206; otherwise, the currently collected ambient volume is used as the current ambient volume, and step 204 is executed.
In this step, the number threshold is 2 and the time interval is 0.5S.
In this step, the next environmental volume is collected at 59 db after 0.5S, and it is determined that the cumulative collection number 2 has reached the number threshold 2, and step 206 is executed.
Step 206: and determining the currently collected environment volume as environment volume information.
In this step, 59 decibels are determined as the environmental volume information.
Step 207: and selecting a target volume interval comprising the environment volume in each volume interval.
In this step, a target volume interval including 59 db of the ambient volume is selected as the volume interval 2 in each volume interval.
Step 208: and determining the sample volume corresponding to the target volume interval as the feedback volume.
In this step, the sample volume 50 db corresponding to the volume interval 2 is determined as the feedback volume.
Step 209: and determining a sample time interval corresponding to the target volume interval as a feedback time interval.
In this step, the sample time interval 3S corresponding to the volume section 2 is determined as the feedback time interval.
Step 210: and recording the accumulated duration of the environment volume information after the environment volume information is determined.
In this step, the cumulative duration of the environmental volume information of 50 db is recorded and determined.
Step 211: and determining the feedback voice corresponding to the voice information.
In this step, it is determined that the feedback voice corresponding to the voice information is "the remaining power is 80%".
Step 212: judging whether the accumulated duration is equal to the feedback time interval, if so, executing step 213; otherwise, execution continues at step 210.
In this step, when it is determined that the accumulated duration is equal to the feedback time interval 3S, step 213 is performed.
Step 213: and playing the feedback voice, wherein the volume of playing the feedback voice is the feedback volume.
In this step, the feedback voice "remaining power is 80%" is played, and the volume during playing is the feedback volume of 50 db.
As shown in fig. 3, an embodiment of the present invention provides a voice interaction apparatus, including:
the acquisition module 301 is configured to acquire environment volume information when voice information input by a user is detected;
a determining module 302, configured to determine a feedback time interval and a feedback volume according to the environment volume information acquired by the acquiring module 301;
a feedback module 303, configured to perform voice feedback on the voice information acquired by the acquisition module 301 according to the feedback time interval and the feedback volume determined by the determination module 302.
According to the embodiment shown in fig. 3, the collection module starts to collect the ambient volume information (which may include the ambient volume) in the environment where the collection module is located when detecting the voice information input by the user. And then the determining module determines a feedback time interval and a feedback volume according to the collected environment volume information. And finally, the feedback module carries out voice feedback on the voice information input by the user according to the determined feedback time interval and the feedback volume. As can be seen from the above description, in the embodiment of the present invention, the feedback time interval and the feedback volume required by the feedback module to perform the voice feedback on the user voice information are changed according to the environment volume information, and are not fixed. Therefore, the scheme provided by the embodiment of the invention can improve the self-adaptive adjustment capability of the voice interaction along with the change of the environment.
In an embodiment of the present invention, the specific type of the collection module 301 may be determined according to the service requirement, for example, it may be a sound collector.
In an embodiment of the present invention, as shown in fig. 4, when the environment volume information includes the first environment volume, the voice interaction apparatus may further include a setting module 304;
the setting module 304 is configured to set at least one volume interval, where each volume interval corresponds to a sample volume and a sample time interval;
the determining module 302 is configured to select a target volume interval including the first ambient volume from the at least one volume interval set by the setting module 304; determining the sample volume corresponding to the target volume interval as the feedback volume; and determining a sample time interval corresponding to the target volume interval as the feedback time interval.
In an embodiment of the present invention, as shown in fig. 5, the feedback module 303 may include: a first recording submodule 3031 and a first feedback submodule 3032;
the first recording submodule 3031 is configured to record a duration of the voice information after the voice information is detected;
the first feedback submodule 3032 is configured to determine a feedback voice corresponding to the voice information; and judging whether the duration recorded by the first recording submodule 3031 is equal to the feedback time interval, if so, playing the feedback voice, and setting the volume of the played feedback voice as the feedback volume.
In an embodiment of the present invention, the acquisition module 301 is configured to execute a1 to a 4:
a1: acquiring the current second environment volume in the environment when the voice information is acquired;
a2: judging whether the volume of the current second environment is larger than a preset volume threshold, if so, executing A3; otherwise, a4 is executed;
a3: after a preset time interval, continuously acquiring the volume of the next second environment, judging whether the accumulated acquisition times reach a preset time threshold value, and if so, executing A4; otherwise, taking the currently acquired second environment volume as the current second environment volume, and executing A2;
a4: and determining the second environment volume collected currently as the environment volume information.
In an embodiment of the present invention, as shown in fig. 6, the feedback module 303 may include: a second recording submodule 3033 and a second feedback submodule 3034;
the second recording submodule 3033 is configured to record the accumulated duration of the environmental volume information after the environmental volume information is determined;
the second feedback submodule 3034 is configured to determine a feedback voice corresponding to the voice information; and judging whether the accumulated duration recorded by the second recording submodule 3033 is equal to the feedback time interval, if so, playing the feedback voice, and setting the volume of the played feedback voice as the feedback volume.
An embodiment of the present invention provides a storage medium, where the storage medium includes a stored program, where when the program runs, a device in which the storage medium is located is controlled to execute the voice interaction method described in any one of the foregoing items.
In an embodiment of the present invention, an electronic device is provided, as shown in fig. 7, which includes a processor 401, a memory 402, and a bus 403; the processor 401 and the memory 402 complete communication with each other through the bus 403; the processor 401 is configured to call program instructions in the memory 403 to execute any one of the above-mentioned voice interaction methods.
Because the information interaction, execution process, and other contents between the units in the device are based on the same concept as the method embodiment of the present invention, specific contents may refer to the description in the method embodiment of the present invention, and are not described herein again.
The embodiments of the invention have at least the following beneficial effects:
1. in the embodiment of the invention, the environment volume information (which may include the environment volume) in the environment is collected when the voice information input by the user is detected. And then determining a feedback time interval and a feedback volume according to the collected environment volume information. And finally, performing voice feedback on the voice information input by the user according to the determined feedback time interval and the feedback volume. As can be seen from the above description, in the embodiment of the present invention, the feedback time interval and the feedback volume required for performing the voice feedback on the user voice information are changed according to the environment volume information, and are not fixed. Therefore, the scheme provided by the embodiment of the invention can improve the self-adaptive adjustment capability of the voice interaction along with the change of the environment.
2. In the embodiment of the present invention, one or more volume intervals are set, so that after the ambient volume is determined, a volume interval including the ambient volume can be quickly selected, and the sample volume and the sample time interval corresponding to the selected volume are determined as the feedback volume and the feedback time interval, respectively. Therefore, the feedback volume and the feedback time interval corresponding to the environment volume can be quickly determined when the voice information is received.
3. In the embodiment of the invention, the duration of acquiring the voice information is recorded when the voice information is acquired. And playing feedback voice corresponding to the voice information by the feedback volume when the duration is judged to be equal to the feedback time interval. Therefore, the feedback voice can be ensured to be accurately played according to the feedback time interval.
4. In the embodiment of the invention, the collected environment volumes are preliminarily screened by using conditions such as the volume threshold, the frequency threshold and the like, so that the determined environment volume information can better meet the requirement of voice feedback.
5. In the embodiment of the invention, when the environment volume information is determined, the accumulated duration of the determined environment volume information is recorded, and when the accumulated duration is judged to be equal to the feedback time interval, the feedback voice corresponding to the voice information is played with the feedback volume. Therefore, the feedback voice can be ensured to be accurately played according to the feedback time interval.
6. In the embodiment of the present invention, when the obtaining module obtains the voice information input by the user, the collecting module starts to collect environment volume information (the environment volume information may include environment volume) in the environment where the obtaining module is located. And then the determining module determines a feedback time interval and a feedback volume according to the collected environment volume information. And finally, the feedback module carries out voice feedback on the voice information input by the user according to the determined feedback time interval and the feedback volume. Therefore, in the scheme, the feedback time interval and the feedback volume required by the feedback module for performing voice feedback on the user voice information are changed along with the environment volume information and are not fixed. Therefore, the scheme provided by the invention can improve the self-adaptive adjustment capability of the voice interaction along with the change of the environment.
It is noted that, herein, relational terms such as first and second, and the like may be used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Also, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising a" does not exclude the presence of other similar elements in a process, method, article, or apparatus that comprises the element.
Those of ordinary skill in the art will understand that: all or part of the steps for realizing the method embodiments can be completed by hardware related to program instructions, the program can be stored in a computer readable storage medium, and the program executes the steps comprising the method embodiments when executed; and the aforementioned storage medium includes: various media that can store program codes, such as ROM, RAM, magnetic or optical disks.
Finally, it is to be noted that: the above description is only a preferred embodiment of the present invention, and is only used to illustrate the technical solutions of the present invention, and not to limit the protection scope of the present invention. Any modification, equivalent replacement, or improvement made within the spirit and principle of the present invention shall fall within the protection scope of the present invention.

Claims (8)

1. A method of voice interaction, comprising:
when voice information input by a user is detected, acquiring environment volume information;
determining a feedback time interval and feedback volume according to the environment volume information;
performing voice feedback on the voice information according to the feedback time interval and the feedback volume;
the ambient volume information comprises a first ambient volume;
before the collecting the environment volume information when the voice information input by the user is detected, further comprising:
setting at least one volume interval, wherein each volume interval corresponds to a sample volume and a sample time interval, and the higher the volume corresponding to the volume interval is, the higher the sample volume corresponding to the volume interval is, and the longer the corresponding sample time interval is;
the determining the feedback time interval and the feedback volume according to the environment volume information includes:
selecting a target volume interval including the first ambient volume from the at least one volume interval;
determining the sample volume corresponding to the target volume interval as the feedback volume;
and determining a sample time interval corresponding to the target volume interval as the feedback time interval.
2. The method of claim 1,
the performing voice feedback on the voice information according to the feedback time interval and the feedback volume includes:
recording the duration of the voice information from the detection of the voice information;
determining feedback voice corresponding to the voice information;
and judging whether the duration is equal to the feedback time interval or not, if so, playing the feedback voice, and setting the volume of the played feedback voice as the feedback volume.
3. The method of claim 1,
the collecting environment volume information comprises:
a1: acquiring the current second environment volume in the environment when the voice information is acquired;
a2: judging whether the volume of the current second environment is larger than a preset volume threshold, if so, executing A3; otherwise, a4 is executed;
a3: after a preset time interval, continuously acquiring the volume of the next second environment, judging whether the accumulated acquisition times reach a preset time threshold value, and if so, executing A4; otherwise, taking the currently acquired second environment volume as the current second environment volume, and executing A2;
a4: and determining the second environment volume collected currently as the environment volume information.
4. The method of claim 3,
the performing voice feedback on the voice information according to the feedback time interval and the feedback volume includes:
recording the accumulated duration of the environment volume information after the environment volume information is determined;
determining feedback voice corresponding to the voice information;
and judging whether the accumulated duration is equal to the feedback time interval or not, if so, playing the feedback voice, and setting the volume of the played feedback voice as the feedback volume.
5. A voice interaction apparatus, comprising:
the acquisition module is used for acquiring environment volume information when voice information input by a user is detected;
the determining module is used for determining a feedback time interval and feedback volume according to the environment volume information acquired by the acquiring module;
the feedback module is used for performing voice feedback on the voice information acquired by the acquisition module according to the feedback time interval and the feedback volume determined by the determination module;
the ambient volume information comprises a first ambient volume;
further comprising: setting a module;
the setting module is used for setting at least one volume interval, wherein each volume interval corresponds to a sample volume and a sample time interval, and the higher the volume corresponding to the volume interval is, the higher the sample volume corresponding to the volume interval is, and the longer the corresponding sample time interval is;
the determining module is configured to select a target volume interval including the first ambient volume from the at least one volume interval set by the setting module; determining the sample volume corresponding to the target volume interval as the feedback volume; and determining a sample time interval corresponding to the target volume interval as the feedback time interval.
6. The apparatus of claim 5,
the feedback module comprises: a first recording submodule and a first feedback submodule;
the first recording submodule is used for recording the duration of the voice information from the detection of the voice information;
the first feedback submodule is used for determining feedback voice corresponding to the voice information; and judging whether the duration recorded by the first recording submodule is equal to the feedback time interval or not, if so, playing the feedback voice, and the volume of playing the feedback voice is the feedback volume.
7. A storage medium, characterized in that the storage medium comprises a stored program, wherein when the program runs, a device in which the storage medium is located is controlled to execute the voice interaction method according to any one of claims 1 to 4.
8. An electronic device, wherein the electronic device comprises a processor, a memory and a bus; the processor and the memory complete mutual communication through the bus; the processor is configured to call program instructions in the memory to perform the voice interaction method of any one of claims 1 to 4.
CN201810479491.0A 2018-05-18 2018-05-18 Voice interaction method and device Active CN108733341B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810479491.0A CN108733341B (en) 2018-05-18 2018-05-18 Voice interaction method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810479491.0A CN108733341B (en) 2018-05-18 2018-05-18 Voice interaction method and device

Publications (2)

Publication Number Publication Date
CN108733341A CN108733341A (en) 2018-11-02
CN108733341B true CN108733341B (en) 2021-09-14

Family

ID=63937655

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810479491.0A Active CN108733341B (en) 2018-05-18 2018-05-18 Voice interaction method and device

Country Status (1)

Country Link
CN (1) CN108733341B (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110113497B (en) * 2019-04-12 2022-01-11 深圳壹账通智能科技有限公司 Voice call-out method, device, terminal and storage medium based on voice interaction
CN115482806A (en) * 2019-06-06 2022-12-16 腾讯科技(深圳)有限公司 Voice processing system, method, device, storage medium and computer equipment
CN112162639B (en) * 2020-10-12 2021-11-30 上海大学 Electronic warfare equipment simulation training man-machine interaction collaboration system
CN112447181A (en) * 2020-11-16 2021-03-05 珠海格力电器股份有限公司 Voice interaction method and device, storage medium and electronic device

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105227741A (en) * 2015-08-19 2016-01-06 上海海漾软件技术有限公司 A kind of smart machine carries out method and the device of volume prompting
CN106970774A (en) * 2017-03-29 2017-07-21 广州阿里巴巴文学信息技术有限公司 A kind of volume adjustment device and method, a kind of terminal
CN107301030A (en) * 2017-06-21 2017-10-27 深圳天珑无线科技有限公司 A kind of method for controlling volume, device and a kind of terminal
CN107766030A (en) * 2017-11-13 2018-03-06 百度在线网络技术(北京)有限公司 Volume adjusting method, device, equipment and computer-readable medium
CN107908388A (en) * 2017-11-17 2018-04-13 珠海市魅族科技有限公司 Method for controlling volume and device, computer installation and computer-readable recording medium

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102075606A (en) * 2010-12-09 2011-05-25 深圳桑菲消费通信有限公司 Method for automatically changing mobile phone ring volume according to environment noise volume
CN102761721A (en) * 2011-04-27 2012-10-31 海尔集团公司 Volume control method and system for TV
KR101978209B1 (en) * 2012-09-24 2019-05-14 엘지전자 주식회사 Mobile terminal and controlling method thereof

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105227741A (en) * 2015-08-19 2016-01-06 上海海漾软件技术有限公司 A kind of smart machine carries out method and the device of volume prompting
CN106970774A (en) * 2017-03-29 2017-07-21 广州阿里巴巴文学信息技术有限公司 A kind of volume adjustment device and method, a kind of terminal
CN107301030A (en) * 2017-06-21 2017-10-27 深圳天珑无线科技有限公司 A kind of method for controlling volume, device and a kind of terminal
CN107766030A (en) * 2017-11-13 2018-03-06 百度在线网络技术(北京)有限公司 Volume adjusting method, device, equipment and computer-readable medium
CN107908388A (en) * 2017-11-17 2018-04-13 珠海市魅族科技有限公司 Method for controlling volume and device, computer installation and computer-readable recording medium

Also Published As

Publication number Publication date
CN108733341A (en) 2018-11-02

Similar Documents

Publication Publication Date Title
CN108733341B (en) Voice interaction method and device
CN106898348B (en) Dereverberation control method and device for sound production equipment
US10522164B2 (en) Method and device for improving audio processing performance
CN111883156B (en) Audio processing method and device, electronic equipment and storage medium
CN110970057B (en) Sound processing method, device and equipment
CN110347367B (en) Volume adjusting method, terminal device, storage medium and electronic device
JP2019117623A (en) Voice dialogue method, apparatus, device and storage medium
CN103871408B (en) Method and device for voice identification and electronic equipment
JP6844608B2 (en) Voice processing device and voice processing method
CN103886731A (en) Noise control method and equipment
CN106356070A (en) Audio signal processing method and device
CN103886857A (en) Method and device for controlling noise
CN109903758B (en) Audio processing method and device and terminal equipment
CN109166571B (en) Household appliance awakening word training method and device and household appliance
CN110347366B (en) Volume adjusting method, terminal device, storage medium and electronic device
CN110875045A (en) Voice recognition method, intelligent device and intelligent television
CN103903606A (en) Noise control method and device
CN112687286A (en) Method and device for adjusting noise reduction model of audio equipment
CN111837179A (en) System and method for capturing noise for pattern recognition processing
CN105872205A (en) Information processing method and device
JP2022554219A (en) How to switch the human-machine interaction mode
CN105719672A (en) Recording scene mode switching method and recording scene mode switching mode device
CN109686372B (en) Resource playing control method and device
CN111028838A (en) Voice wake-up method, device and computer readable storage medium
CN109584877B (en) Voice interaction control method and device

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
GR01 Patent grant
GR01 Patent grant