Systems, methods, apparatuses, and media for voice interaction

By dividing the voice interaction system into a voice architecture layer, a voice central control layer, a business central control layer, and a business processing layer, the problems of chaotic development and slow iteration speed of existing systems are solved, achieving efficient system iteration and accurate dialogue response, and supporting the needs of multiple product lines.

CN114512125BActive Publication Date: 2025-12-09BEIJING BAIDU NETCOM SCI & TECH CO LTD
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202111535752.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-12-15
Publication Date
2025-12-09
Estimated Expiration
2041-12-15

AI Technical Summary

Technical Problem

In existing voice interaction systems, the cloud architecture and cloud central control are responsible for speech recognition, semantic parsing, speech synthesis, and specific business logic processing functions, resulting in chaotic system development, slow iteration speed, and inability to effectively support the needs of multiple product lines.

Method used

The voice interaction system is divided into a voice architecture layer, a voice control layer, a business control layer, and a business processing layer according to its functions. Each layer corresponds to a different stage in the voice interaction process, with clear tasks and functions. By implementing semantic parsing and interaction optimization in the voice control layer, the difficulty of system development is reduced, and the iteration speed and efficiency are improved.

Benefits of technology

It enables more efficient system iteration and development, supports the needs of multiple product lines, provides more accurate dialogue response results, and enhances the user's business experience in various fields.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114512125B_ABST
    Figure CN114512125B_ABST
Patent Text Reader

Abstract

The disclosure provides a system, method, device and medium for voice interaction, relates to the technical field of computers, and in particular to the technical field of artificial intelligence such as voice technology and natural language processing. A specific implementation scheme is as follows: a voice framework layer receives a request sentence, performs voice recognition, obtains a voice recognition result, and sends the voice recognition result to a voice control layer; the voice control layer returns a dialogue reply result to the voice framework layer; the voice framework layer performs voice synthesis on the dialogue reply result returned by the voice control layer, and obtains a reply sentence; the voice control layer performs semantic analysis on the voice recognition result, obtains a semantic analysis result, and sends the semantic analysis result to a business control layer; the business control layer forwards the dialogue reply result returned by the business processing layer to the voice control layer; the business processing layer calls a dialogue service resource corresponding to a field of the semantic analysis result, obtains a dialogue reply result, and returns the dialogue reply result to the business control layer.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present disclosure relates to the technical field of computers, in particular to the technical field of artificial intelligence such as voice technology and natural language processing, and more particularly to a system, method, device and medium for voice interaction. BACKGROUND

[0002] With the progress of artificial intelligence technology, human-computer voice interaction (referred to as voice interaction) has also been rapidly developed and widely applied. For example, it can be widely applied to smart devices such as smart televisions, smart sound boxes, virtual reality (VR) glasses, and various voice assistant applications (APPs).

[0003] In the existing voice interaction process, the client uploads the request audio sent by the user to the cloud architecture, the cloud architecture performs voice recognition on the request audio, sends the obtained recognition result text to the cloud central control, performs semantic analysis and specific business logic processing in the cloud central control, obtains a dialogue reply result, returns the dialogue reply result to the cloud architecture, and then the cloud architecture performs voice synthesis on the text of the dialogue reply result to generate the final reply audio to be played. The reply audio stream is finally transmitted back to the client through the network and played on the client. SUMMARY

[0004] The present disclosure provides a system, method, device and medium for voice interaction.

[0005] According to an aspect of the present disclosure, a system for voice interaction is provided, comprising:

[0006] a voice architecture layer configured to receive a request sentence, perform voice recognition on the request sentence, obtain a voice recognition result and send it to a voice central control layer, and perform voice synthesis on a dialogue reply result returned by the voice central control layer to obtain a reply sentence;

[0007] the voice central control layer configured to perform semantic analysis on the voice recognition result, obtain a semantic analysis result and send it to a business central control layer, and forward the dialogue reply result returned by the business central control layer to the voice architecture layer;

[0008] the business central control layer configured to distribute the semantic analysis result to a business processing layer, and forward the dialogue reply result returned by the business processing layer to the voice central control layer;

[0009] the business processing layer configured to call a dialogue service resource corresponding to the semantic analysis result, obtain the dialogue reply result and return it to the business central control layer.

[0010] According to another aspect of the present disclosure, a method for voice interaction is provided, comprising:

[0011] receiving a request sentence, performing speech recognition on the request sentence to obtain a speech recognition result;

[0012] performing semantic analysis on the speech recognition result to obtain a semantic analysis result;

[0013] calling a dialog service resource in a field corresponding to the semantic analysis result to obtain the dialog reply result;

[0014] performing speech synthesis on the dialog reply result to obtain a reply sentence.

[0015] According to yet another aspect of the present disclosure, an electronic device is provided, comprising:

[0016] at least one processor; and

[0017] a memory in communication with the at least one processor; wherein

[0018] the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to perform the method of the above aspects and any possible implementation.

[0019] According to yet another aspect of the present disclosure, a non-transitory computer-readable storage medium storing computer instructions is provided, the computer instructions being used to cause the computer to perform the method of the above aspects and any possible implementation.

[0020] According to yet another aspect of the present disclosure, a computer program product is provided, comprising a computer program which, when executed by a processor, implements the method of the above aspects and any possible implementation.

[0021] According to yet another aspect of the present disclosure, an artificial intelligence device is provided, comprising the electronic device as described above.

[0022] According to the above technical solution, the present disclosure divides the system of voice interaction into a voice architecture layer, a voice central control layer, a business central control layer, and a business processing layer according to functions, different levels correspond to different links in the voice interaction process, the internal tasks and the functions to be achieved of each level are clear, which can reduce the product development difficulty of the system, when a certain function or its specific implementation logic needs to be updated, only the level of the function needs to be iterated, which helps to improve the iteration speed and efficiency, has better scalability, and can well support the needs of multiple product lines.

[0023] In addition, the business processing layer can call a dialog service resource corresponding to the domain of the semantic parsing result, and can distinguish the domain to provide business logic at the level of the dialog service resource, so that the business logic of each domain can be polished in depth and detail, and more accurate and precise dialog reply results can be obtained, which helps to improve the business experience of users in each domain.

[0024] It should be understood that the content described in this part is not intended to identify key or important features of the embodiments of the present disclosure, nor to limit the scope of the present disclosure. Other features of the present disclosure will become apparent from the following description. BRIEF DESCRIPTION OF DRAWINGS

[0025] The accompanying drawings are used to better understand the present scheme and do not constitute a limitation on the present disclosure. Among them:

[0026] Figure 1 is a schematic diagram according to a first embodiment of the present disclosure;

[0027] Figure 2 is a schematic diagram according to a second embodiment of the present disclosure;

[0028] Figure 3 is a schematic diagram according to a third embodiment of the present disclosure;

[0029] Figure 4 is a block diagram of an electronic device for implementing the method of voice interaction according to the embodiments of the present disclosure. DETAILED DESCRIPTION

[0030] Exemplary embodiments of the present disclosure are described below with reference to the accompanying drawings, which include various details of the embodiments of the present disclosure to help understanding, and should be considered as merely exemplary. Therefore, those of ordinary skill in the art should recognize that various changes and modifications can be made to the embodiments described herein without departing from the scope and spirit of the present disclosure. Also, in order to be clear and concise, descriptions of well-known functions and structures are omitted in the following description.

[0031] Obviously, the described embodiments are part of the embodiments of the present disclosure, not all. Based on the embodiments in the present disclosure, all other embodiments obtained by those of ordinary skill in the art without creative labor are within the scope of protection of the present disclosure.

[0032] It should be noted that the terminal device involved in the embodiments of the present disclosure can include but is not limited to a mobile phone, a personal digital assistant (PDA), a wireless handheld device, a tablet computer, a computing device on a vehicle, and the like. The display device can include but is not limited to a personal computer, a television, a display coupled to a vehicle, and the like.

[0033] In addition, the term "and / or" in this document is only a description of the association relationship of the associated objects, which means that there can be three relationships, for example, A and / or B can represent the existence of A alone, the existence of A and B at the same time, and the existence of B alone. In addition, the character " / " in this document generally represents an "or" relationship between the front and rear associated objects.

[0034] The human-computer interaction mode is gradually improving in efficiency and convenience, from the keyboard and mouse interaction in the PC era, to the touch screen interaction in the mobile era, to the voice interaction in the artificial intelligence era. The effect of voice interaction needs to be further improved to provide users with a better human-computer interaction experience.

[0035] The inventor of the present disclosure found through research that in the existing voice interaction system architecture, the cloud architecture and the cloud central control need to be responsible for voice recognition, semantic analysis, speech synthesis and specific business logic processing functions, both voice recognition level functions and dialogue service resource level business logic are mixed together, which can easily lead to system development confusion, slow iteration speed and other problems, and cannot well support the needs of multiple product lines.

[0036] Therefore, it is urgent to provide a voice interaction system to reduce the difficulty of system development, improve the iteration speed and efficiency, and support the needs of multiple product lines.

[0037] Figure 1 is a schematic diagram according to the first embodiment of the present disclosure, as Figure 1 shown. The voice interaction system 100 of the present embodiment can include a voice architecture layer 101, a voice central control layer 102, a business central control layer 103 and a business processing layer 104. Among them:

[0038] The voice architecture layer 101 is configured to receive a request sentence, perform voice recognition on the request sentence, obtain a voice recognition result and send it to the voice central control layer 102, and perform voice synthesis on a dialogue reply result returned by the voice central control layer 102 to obtain a reply sentence. Optionally, the request sentence can be sent by a client, and correspondingly, the voice architecture layer 101 can send the reply sentence to the client after obtaining the reply sentence.

[0039] Among them, the request sentence is a sentence that a user sends and wants to get a reply, for example, it can be a speech of different needs such as "play children's songs" and "I want to listen to rice fragrance", and the present embodiment does not limit this.

[0040] Among them, the reply sentence is a sentence generated for the request sentence sent by the user and to be played to the user, for example, for the request sentence "play children's songs", the reply sentence can be "OK" or "Which children's song do you want to listen to?".

[0041] The voice control layer 102 is configured to perform semantic analysis on the voice recognition result, to obtain a semantic analysis result and send the semantic analysis result to the service control layer 103; and forward a dialogue reply result returned by the service control layer 103 to the voice architecture layer 101.

[0042] The service control layer 103 is configured to distribute the semantic analysis result to the service processing layer 104; and forward a dialogue reply result returned by the service processing layer 104 to the voice control layer 102.

[0043] The service processing layer 104 is configured to call a dialogue service resource of a field corresponding to the semantic analysis result, to obtain a dialogue reply result and return the dialogue reply result to the service control layer 103.

[0044] The dialogue reply result is obtained by calling, by the service processing layer 104, the dialogue service resource of the field corresponding to the semantic analysis result, determining an intention of the user according to the semantic analysis result and a current dialogue state, performing dialogue model calculation and resource acquisition, and generating a text of a reply sentence to be played to the user.

[0045] It should be noted that part or all of the voice interaction system 100 in the embodiment can be an application of a terminal device of a local terminal, i.e., a terminal device of a service provider, or can also be a plug-in or a software development kit (SDK) and the like in the application of the local terminal, which is not particularly limited in the embodiment.

[0046] It can be understood that the application can be a native application (nativeApp) installed on the terminal, or can also be a web application (webApp) of a browser on the terminal, which is not particularly limited in the embodiment.

[0047] According to the embodiment, the voice interaction system is divided into a voice architecture layer, a voice control layer, a service control layer and a service processing layer according to functions, different levels correspond to different links in the voice interaction process, the internal tasks and the functions to be implemented of each level are clear, the product development difficulty of the system can be reduced, when a certain function or a specific implementation logic thereof needs to be updated, only the level of the function needs to be iterated, which helps to improve the iteration speed and efficiency, has better scalability, and can well support the needs of multiple product lines. In addition, the dialogue service resource of the field corresponding to the semantic analysis result can be called in the service processing layer, the business logic at the level of the dialogue service resource can be provided according to the field, the business logic of each field can be polished in depth and in detail, more accurate and precise dialogue reply results can be obtained, and the business experience of the user in each field can be improved.

[0048] Figure 2is a schematic diagram according to a second embodiment of the present disclosure, as Figure 2 In one possible implementation of the voice interaction system 200 of the present embodiment, the voice architecture layer 101 can include a voice architecture unit 1011, a voice recognition unit 1012, and a voice synthesis unit 1013. The voice architecture unit 1011 is configured to receive a request sentence, which can be sent by a client, invoke the voice recognition unit 1012 to perform voice recognition on the request sentence, obtain a voice recognition result, and send the voice recognition result to a voice control unit 1021 in a voice control layer 102; invoke the voice synthesis unit 1013 to perform voice synthesis on a dialogue reply result returned by the voice control unit 1021, obtain a reply audio, and then send the reply audio to the client.

[0049] Based on the present embodiment, the voice architecture layer serves as a general entrance of the voice interaction system and provides a technical implementation architecture for voice processing (including voice recognition and voice synthesis); in addition, based on the technical implementation architecture, only audio is exchanged between the client and the voice interaction system, and input and output between different layers in the voice interaction system are all in text, so that seamless connection with other functional layers or functional modules in the present or future can be achieved in dialogue management.

[0050] Optionally, referring back to Figure 2 In one possible implementation of the present embodiment, the voice control layer 102 can include a voice control unit 1021 and a semantic analysis unit 1022. The voice control unit 1021 is configured to invoke the semantic analysis unit 1022 to perform semantic analysis on a voice recognition result sent by the voice architecture unit 1011 in the voice architecture layer 101, obtain a semantic analysis result, and send the semantic analysis result to a business control unit 1031 in a business control layer 103; and forward a dialogue reply result returned by the business control unit 1031 to the voice architecture unit 1011.

[0051] Optionally, in one possible implementation of the present embodiment, the semantic analysis result can include a domain, an intent, and slot information.

[0052] The domain is a domain to which the request sentence belongs, such as an alarm clock, weather, music, etc. The intent is a specific intent of the request sentence in the current domain, such as setting an alarm clock, deleting an alarm clock, etc. in the alarm clock domain. The slot is specific slot information of the request sentence in the current domain and intent, such as the request sentence "How is the weather in Beijing?", the domain is weather, the intent is to query the weather, and the slot information includes a slot "city" and a slot value "Beijing"; the request sentence "I want to listen to the songs of Zhou Someone", the domain is music, the intent is music search, and the slot information is a slot "singer" and a slot value "Zhou Someone".

[0053] Optionally, in a possible implementation of the embodiment, a pre-trained semantic parsing model can be used as the semantic parsing unit 1022 to perform semantic parsing on the speech recognition result to obtain a semantic parsing result. The semantic parsing model in the embodiment of the disclosure can be implemented based on a neural network model in a deep learning manner, for example, a DNN, an LSTM, an LSTM+CRF model, a transformer, and the like, which are not limited in the embodiment of the disclosure.

[0054] Based on the embodiment, a specific architecture of a voice control layer is provided, and semantic parsing of a speech recognition result can be implemented in the voice control layer to determine domain, intent, and slot information of the speech recognition result, so as to subsequently distribute and call a dialog service resource corresponding to the semantic parsing result to determine a dialog reply result.

[0055] Optionally, referring back to Figure 2 In a possible implementation of the embodiment, the voice control layer 102 can further include an interaction optimization unit 1023. The voice control unit 1021 is further configured to call the interaction optimization unit 1023 to reject the speech recognition result with a confidence less than a first preset threshold; and / or generate a clarification question text for the speech recognition result with a confidence greater than the first preset threshold and less than a second preset threshold and send the clarification question text to the voice architecture unit 1011, so that the voice architecture unit 1011 calls the speech synthesis unit 1013 to perform speech synthesis on the clarification question text to obtain a clarification question sentence and send the clarification question sentence to the client; or cache the speech recognition result with the confidence greater than the first preset threshold and less than the second preset threshold and the clarification question text, wherein the first preset threshold and the second preset threshold are both preset real numbers greater than 0, and the first preset threshold is less than the second preset threshold.

[0056] The voice architecture unit 1011 is further configured to perform speech synthesis on the clarification question text to obtain a clarification question sentence and send the clarification question sentence to the client.

[0057] Based on the embodiment, by setting the interaction optimization unit in the voice middle control layer, the speech recognition result with the confidence not greater than the first preset threshold can be rejected, and the speech recognition result with the confidence greater than the first preset threshold and not greater than the second preset threshold can be clarified and questioned, thereby avoiding subsequent processing based on the speech recognition result with low confidence, consumption of computing resources of the business middle control layer and the business processing layer caused thereby, improving the accuracy and reliability of the reply result through clarification and questioning, and thereby improving the voice interaction experience. In addition, the rejection and clarification and questioning of the speech recognition result are implemented by setting the interaction optimization unit in the voice middle control layer, which is completely decoupled from other functional layers (the voice architecture layer 101, the business middle control layer 103, and the business processing layer 104), and other functional layers do not need to be modified, thereby avoiding problems such as high workload and slow iteration speed caused by associated development, and improving the product development efficiency.

[0058] Optionally, referring again to Figure 2 In one possible implementation of the embodiment, the interaction optimization unit 1023 can include at least one of an auxiliary recognition module and a semantic clarification module. The voice middle control unit 1021 is configured to call the auxiliary recognition module to confirm whether to receive or reject the speech recognition result, and / or call the semantic clarification module to generate a clarification and questioning text for the speech recognition result with the confidence greater than the first preset threshold and not greater than the second preset threshold. Correspondingly, the auxiliary recognition module is configured to identify whether the confidence of the speech recognition result is greater than the first preset threshold and the second preset threshold, confirm to reject the speech recognition result if the confidence of the speech recognition result is not greater than the first preset threshold, and confirm to receive the speech recognition result if the confidence of the speech recognition result is greater than the first preset threshold, so that the voice middle control unit 1021 calls the semantic analysis unit 1022 to perform semantic analysis on the speech recognition result. The semantic clarification module is configured to generate a clarification and questioning text for the speech recognition result based on a preset clarification and questioning logic if the confidence of the speech recognition result is greater than the first preset threshold and not greater than the second preset threshold.

[0059] Based on the embodiment, the rejection / reception and clarification and questioning of the speech recognition result are implemented by the interaction optimization unit, the confidence of the speech recognition result can be identified by setting the auxiliary recognition module, and only when the confidence of the speech recognition result is greater than the first preset threshold, the speech recognition result is confirmed to be received, so that subsequent processing is performed on the speech recognition result, the accuracy and reliability of the reply result are improved, and thereby the voice interaction experience is improved.

[0060] Optionally, in one possible implementation of the embodiment, the speech recognition result obtained by the speech architecture unit 1011 can include at least one intermediate recognition result obtained by the speech architecture layer 101 within a first preset time after receiving the request sentence, and a final recognition result obtained within a second preset time after receiving the request sentence.

[0061] The end time of the first preset time is earlier than the tail point time (VAD end) of the voice activity detection of the request sentence. The first preset time refers to a time period starting from the tail sound of the request sentence sent by the user falling. The first preset time is the duration of the silence state detected by the voice interaction system. The length of the first preset time can be set as needed. In actual use, in order to reduce the waiting time of the user, the length of the first preset time can be set to 5ms, 10ms, 20ms, etc. This is only an example and cannot be regarded as a limitation of the length of the first preset time in the present disclosure. The end time of the second preset time is later than the tail point time of the voice activity detection of the request sentence. The intermediate recognition result is the recognition result obtained by performing speech recognition on the request sentence within the first preset time after the tail sound of the request sentence sent by the user falls.

[0062] The second preset time is a time period starting from the tail sound of the request sentence sent by the user falling. The length of the time period is greater than the length of the first preset time. It can be understood that the second preset time is also the duration of the silence state detected by the voice interaction device.

[0063] For example, for the request sentence "I want to listen to the fragrance of rice" of the user, the speech architecture unit 1011 can obtain the following intermediate recognition results within the first preset time after receiving the request sentence: A. I; B. I want; C. I want to listen; D. I want to listen to the fragrance of rice; and E. I want to listen to the fragrance of rice. The final recognition result F. I want to listen to the fragrance of rice can be obtained within the second preset time after receiving the request sentence.

[0064] Optionally, referring back to Figure 2In a possible implementation of the embodiment, the interaction optimization unit 1023 can further include a speed optimization module configured to: in response to obtaining a first intermediate recognition result from the at least one intermediate recognition result, sequentially identify whether the semantics of the at least one intermediate recognition result is complete in the time sequence in which the intermediate recognition results are obtained; in response to identifying a first intermediate recognition result with complete semantics, taking the first intermediate recognition result with complete semantics as the speech recognition result, calling the semantic analysis unit 1022 to perform semantic analysis on the speech recognition result sent by the speech architecture unit 1011, obtaining a semantic analysis result and sending the semantic analysis result to the service control unit 1031; or, in response to identifying two adjacent speech recognition results with complete semantics and the same semantic analysis result from the at least one intermediate recognition result, taking the previous speech recognition result in the two adjacent speech recognition results as the speech recognition result, calling the semantic analysis unit 1022 to perform semantic analysis on the speech recognition result sent by the speech architecture unit 1011, obtaining a semantic analysis result and sending the semantic analysis result to the service control unit 1031.

[0065] wherein the semantics of the intermediate recognition result is complete, indicating that the intermediate recognition result has complete semantics and can completely express the user's intention. For example, for the user's request sentence "I want to listen to the fragrance of rice", the semantics of the intermediate recognition results A, B, C, and D are not complete, i.e., they are incomplete requests, and the semantics of the intermediate recognition result E is complete, i.e., it is a complete request.

[0066] Based on the embodiment, by performing streaming speech recognition in advance, when the first intermediate recognition result with complete semantics is identified, the first intermediate recognition result with complete semantics is taken as the speech recognition result, so as to determine the reply sentence, which can not only reduce the response time of the speech interaction by pulling the dialogue resource in advance, but also avoid a large number of calls to the dialogue service for computing and resource pulling of the dialogue model based on the intermediate recognition result with incomplete semantics, thereby greatly reducing the invalid calls to the dialogue service and reducing the request amount of the dialogue service, thereby saving the computing resources and storage resources of the dialogue service, as well as the charging resource service, thereby reducing the cost.

[0067] In the embodiment of the disclosure, the speed optimization module can identify whether the semantics of each intermediate recognition result is complete in multiple ways.

[0068] For example, in a possible implementation of the embodiment, the speed optimization module can identify whether the semantics of each intermediate recognition result is complete in the following way:

[0069] In sequence for each intermediate recognition result in the at least one intermediate recognition result, a semantic integrity model is used to obtain a first probability of each intermediate recognition result as a prefix of a historical final recognition result and a second probability of each intermediate recognition result as the historical final recognition result, and then a third probability of semantic integrity of each intermediate recognition result is determined based on the first probability and the second probability; further, whether the semantic of each intermediate recognition result is complete is determined according to whether the third probability is greater than a preset threshold.

[0070] The semantic integrity model is obtained by statistical calculation based on the final recognition results in the user log. For example, the total number of times that the final recognition result "I want to listen to the scent of rice" appears in the large-scale online user log is counted, the total number of times that the final recognition result "I want to order a 6:50 alarm clock for tomorrow morning" appears is counted, and so on. The total number of times that each final recognition result in the large-scale online user log appears is counted to obtain the semantic integrity model. The semantic integrity model can be updated based on the update of the online user log according to a certain update period, for example, one week. The disclosure does not limit whether the semantic integrity model is updated and the update period.

[0071] In the disclosure, the historical final recognition result is the final recognition result in the large-scale online user log. When each user performs voice interaction to issue a request sentence, at least one intermediate recognition result and one final recognition result are obtained. The server for implementing the disclosure generates a user log for each user to record at least one intermediate recognition result and one final recognition result in each voice interaction of the user.

[0072] In the disclosure, the first probability of the intermediate recognition result as a prefix of the historical final recognition result is the probability that the intermediate recognition result only appears as a part of the historical final recognition result, but not the complete historical final recognition result. The second probability of the intermediate recognition result as the historical final recognition result is the probability that the intermediate recognition result appears alone as the historical final recognition result (i.e., as a complete historical final recognition result).

[0073] The higher the first probability is, the lower the second probability is, and the lower the third probability of the intermediate recognition result being semantically complete is. For example, for the intermediate result "I want to listen", in the user's expression, it is rarely used as a request sentence alone and is almost used as a prefix of a request sentence, and thus the third probability of the intermediate result "I want to listen" is relatively low, so that the intermediate result "I want to listen" is determined to be semantically incomplete. In the embodiment of the present disclosure, when the third probability is greater than a preset threshold, it is determined that the intermediate recognition result is semantically complete, the meaning expressed is relatively complete, and it is a complete sentence, so that the intermediate recognition result can be used as a complete sentence, and then a first reply sentence is determined according to the intermediate recognition result. Otherwise, when the third probability is less than or equal to the preset threshold, it is determined that the intermediate recognition result is semantically incomplete, the meaning expressed is not complete enough, and it may not be a complete sentence, and the intermediate recognition result is unreliable. The preset threshold can be set according to actual needs, for example, it can be set to 0.5, and can be adjusted according to actual needs.

[0074] Based on the embodiment, the semantic completeness model can be obtained by statistically calculating the final recognition results in a large-scale online user log in advance. Then, by using the semantic completeness model, the first probability of each intermediate recognition result being a prefix of a historical final recognition result and the second probability of each intermediate recognition result being a historical final recognition result can be quickly obtained. The third probability of each intermediate recognition result being semantically complete is accurately determined according to the first probability and the second probability, so that whether the semantics of each intermediate recognition result is complete is quickly and objectively determined by using the historical statistical calculation method.

[0075] Alternatively, in another possible implementation manner of the embodiment, the speed optimization module can also identify whether the semantics of each intermediate recognition result is complete in the following manner:

[0076] In sequence, for each intermediate recognition result in the at least one intermediate recognition result, a word vector of the intermediate recognition result is obtained. For example, the intermediate recognition result can be converted from text to a word vector by a word-to-vector (Word to the vector) manner;

[0077] The first probability of each intermediate recognition result being a prefix of a historical final recognition result and the second probability of each intermediate recognition result being a historical final recognition result are obtained. For example, the first probability of each intermediate recognition result being a prefix of a historical final recognition result and the second probability of each intermediate recognition result being a historical final recognition result can be obtained by using the above-mentioned semantic completeness model;

[0078] obtain the hotness of each intermediate recognition result. The hotness of an intermediate recognition result, that is, the usage degree of a request sentence containing the intermediate recognition result sent by a user through a server for implementing the embodiments of the present disclosure within a time period or all historical times in the past, can be obtained through statistical calculation of the intermediate recognition result and the final recognition result in a large-scale online user log.

[0079] input the word vector, the first probability, the second probability, and the hotness into a neural network model pre-trained, and output a fourth probability of semantic completeness of each intermediate recognition result through the neural network model.

[0080] determine whether the semantics of each intermediate recognition result is complete according to whether the fourth probability is greater than a preset threshold.

[0081] In the embodiments of the present disclosure, when the fourth probability is greater than the preset threshold, it can be determined that the semantics of the intermediate recognition result is complete, and the meaning expressed is relatively complete, which is a complete sentence, so that the intermediate recognition result can be used as a complete sentence, and then a first reply sentence is determined according to the intermediate recognition result; otherwise, when the fourth probability is less than or equal to the preset threshold, it is determined that the semantics of the intermediate recognition result is not complete, and the meaning expressed is not complete enough, which may not be a complete sentence, and the intermediate recognition result is unreliable. The preset threshold can be set according to actual needs, for example, it can be set to 0.5, and can be adjusted according to actual needs.

[0082] The neural network model in the embodiments of the present disclosure can be any neural network model based on deep learning, such as a deep neural network (DNN), a long short-term memory (LSTM), a model based on a multi-head attention mechanism (transformer), etc., and the embodiments of the present disclosure do not limit this.

[0083] Based on the embodiments, based on the word vector of the intermediate recognition result, the first probability of the intermediate recognition result as a prefix in the historical final recognition result, and the second probability of the intermediate recognition result as a historical final recognition result, and the hotness, the fourth probability of semantic completeness of the intermediate recognition result is predicted through the neural network model based on the deep learning manner, which can avoid the problem that the intermediate recognition result cannot be determined to be complete in semantics or the determination result is inaccurate due to data sparseness in the statistical calculation manner, can solve the generalization problem of each intermediate recognition result, determine whether the semantics of the intermediate recognition result is complete, and improve the accuracy of the determination result of whether the semantics of the intermediate recognition result is complete.

[0084] In the embodiments of the present disclosure, the semantic analysis unit 1022 can use various ways to perform semantic analysis on the speech recognition result to obtain a semantic analysis result.

[0085] For example, in one possible implementation of the embodiment, the semantic parsing unit 1022 can utilize a pre-trained semantic parsing model to perform semantic parsing on the speech recognition result to obtain a semantic parsing result. The semantic parsing model in the embodiment of the disclosure can be implemented based on a neural network model in a deep learning manner, such as a deep neural network (DNN), a long short-term memory (LSTM), an LSTM+CRF model composed of an LSTM and a conditional random field (CRF), a model based on a multi-head attention mechanism (transformer), and the like, which are not limited in the embodiment of the disclosure.

[0086] Based on the embodiment, the semantic parsing model pre-trained based on the deep learning manner has a certain generalization, and can accurately and comprehensively perform semantic parsing on various speech recognition results, and quickly and accurately obtain semantic parsing results of each input information.

[0087] wherein the semantic parsing results of the two speech recognition results are the same means that the domain, intent and slot information in the semantic parsing results of the two speech recognition results correspond to the same, respectively, if any one or more of the domain, intent and slot information in the semantic parsing results of the two speech recognition results are different, it is considered that the semantic parsing results of the two speech recognition results are different.

[0088] The inventors of the disclosure found through research that the execution result of the task-oriented dialogue processing (such as music on-demand, setting an alarm reminder) strongly depends on the semantic parsing result: that is, if the semantic parsing results of two request sentences are the same, the reply of the dialogue is also the same.

[0089] Based on the embodiment, when the two adjacent speech recognition results with complete semantics and the same semantic parsing result are identified from the at least one intermediate recognition result, the previous speech recognition result in the two adjacent speech recognition results is directly taken as a speech recognition result for subsequent processing to obtain a corresponding reply sentence, and the corresponding reply sentence is no longer obtained for the latter intermediate recognition result, which can reduce the response time of the voice interaction by pulling the dialogue resources in advance, and further reduce the repeated calling of the dialogue service, thereby reducing the request amount of the dialogue service, saving the computing resources and storage resources of the dialogue service, and the required calling of the charged resource service (such as calling the interface of the weather service provider and the audio content provider to obtain the response resource, which is charged by time), thereby reducing the cost.

[0090] Optionally, referring back to Figure 2In a possible implementation of the embodiment, the service processing layer 104 can include at least one service processing unit 1041 corresponding to different domains respectively. The service processing unit 1041 is also referred to as a skill bot. The service processing unit 1041 can be configured to call a domain corresponding dialog service resource in the semantic analysis result to obtain a dialog reply result and return the dialog reply result to the service control layer 103.

[0091] Based on the embodiment, at least one service processing unit corresponding to different domains respectively can be arranged in the service processing layer, for example, a music domain skill bot (muscibot), a weather domain skill bot (weatherbot), a map domain skill bot (map bot), and the like. The service control layer can distribute a semantic analysis result to a service processing unit corresponding to a domain in the semantic analysis result according to the domain in the semantic analysis result, and the service processing unit corresponding to the domain can call a domain corresponding dialog service resource to obtain a dialog reply result. Since the service processing units of different domains are deeply rooted in a specific domain and focus on the service processing of the specific domain, the service processing units can continuously polish details to provide professional and meticulous services. For example, the musci bot can be deeply polished for music related experiences to obtain more accurate and precise dialog reply results, which helps to improve the service experience of users in different domains.

[0092] Optionally, referring back to Figure 2 In a possible implementation of the embodiment, the service control layer 103 can include a service control unit 1031, and can further include at least one of a general unit 1032 and a customized unit 1033.

[0093] The service control unit 1031 can be configured to distribute a semantic analysis result to a service processing unit 1041 corresponding to a domain in the semantic analysis result in the service processing layer 104 according to the domain in the semantic analysis result, and forward a dialog reply result returned by the service processing unit 1041 to the voice control unit 1021.

[0094] The general unit 1032 is configured to implement preset general functions, which can include, but are not limited to, a multi-turn dialogue function based on preset dialogue counter-question logic. For example, based on the preset dialogue counter-question logic, a counter-question sentence is generated in text and returned to the voice central control unit 1021 in voice, in combination with a current semantic analysis result and stored historical information of the request sentence, and is forwarded to the voice framework unit 1011 by the voice central control unit 1021, and the voice synthesis unit 1013 is invoked by the voice framework unit 1011 to perform voice synthesis on the text of the counter-question sentence, to obtain the counter-question sentence and send it to the client. After the client receives a reply sentence of the user to the counter-question sentence, the reply sentence can be processed based on a processing flow consistent with the request sentence. The multi-turn dialogue function can store multi-turn dialogue information in the current session.

[0095] For example, a user wants to set an alarm, but only says to the electronic device, “Help me set an alarm”, which is a request sentence. At this time, the specific alarm time is unknown, and the necessary information (for example, which day, morning or afternoon, etc.) for setting the alarm can be obtained by counter-questioning the user through the multi-turn dialogue function. The multi-turn dialogue function can support setting the counter-question logic of the electronic device to the user in a similar scenario by preconfiguring a dialogue counter-question logic file.

[0096] The customization unit 1033 is configured to implement an extension function of a preset service. The customization unit 1033 is configured to implement a reserved function, and can be used as a customization function module for different service requirements, and reserves a corresponding interface.

[0097] Based on the embodiment, the preset general functions can be implemented by setting the general unit in the service central control layer. Different services can directly invoke the general unit to implement corresponding functions, without repeated development, thereby improving resource utilization and avoiding resource waste caused by repeated development. By setting the customization unit in the service central control layer, the corresponding function implementation interface can be reserved for individual needs of different services, to support individual function extension of different services.

[0098] Optionally, in one possible implementation manner of the embodiment, the request sentence can include a service ID (ID), and the service ID is configured to uniquely identify a type of service. One type of service can be a service provided by one product, and therefore, the service ID can also be understood as a product ID. Accordingly, referring back to Figure 2The service control layer 103 can specifically include a plurality of service control units 1031 corresponding to different types of services. The voice control layer 102 specifically distributes the semantic analysis result to the service control unit 1031 corresponding to the service ID in the request sentence according to the service ID. For example, a correspondence between the service ID and the address of the service control unit can be preconfigured in the voice control layer 102, the address of the service control unit corresponding to the service ID in the request sentence is queried from the correspondence, and the semantic analysis result is distributed to the corresponding service control unit.

[0099] Different types of services, for example, services provided by different product lines, usually have different functions (such as maps, search, etc.) and different service logics. In this embodiment, the service control layer 103 provides a plurality of service control units, which can process different types of services using corresponding service logics, thereby realizing personalized processing of different types of products and services and supporting the needs of multiple product lines.

[0100] In this embodiment, the voice interaction system is divided into a voice architecture layer, a voice control layer, a service control layer, and a service processing layer according to functions. Different levels correspond to different links in the voice interaction process, the tasks and functions to be implemented in each level are clear, the product development difficulty of the system can be reduced, when a certain function or its specific implementation logic needs to be updated, only the level of the function needs to be iterated, which helps to improve the iteration speed and efficiency, has better scalability, and can well support the needs of multiple product lines.

[0101] In addition, the service processing layer can call the dialog service resource corresponding to the semantic analysis result, and the service logic at the level of the dialog service resource can be provided according to the field, thereby the service logic of each field can be polished in depth and detail, more accurate and precise dialog reply results can be obtained, and the service experience of users in each field can be improved.

[0102] Figure 3 is a schematic diagram according to the third embodiment of the present disclosure, and the voice interaction method of this embodiment can be implemented based on the voice interaction system of the above-mentioned embodiments of the present disclosure. As shown in Figure 3 The voice interaction method of this embodiment includes:

[0103] 301. For example, the voice architecture layer receives a request sentence, performs voice recognition on the request sentence, and obtains a voice recognition result.

[0104] Then, the voice recognition result can be sent to the voice control layer.

[0105] 302. performing semantic analysis on the voice recognition result to obtain a semantic analysis result, for example, by a voice control layer.

[0106] The semantic analysis result can be sent to a service control layer.

[0107] Optionally, the semantic analysis result can be distributed to a service processing layer, for example, by the service control layer.

[0108] 303. invoking a dialogue service resource corresponding to a field of the semantic analysis result to obtain a dialogue reply result, for example, by the service processing layer.

[0109] 304. performing voice synthesis on the dialogue reply result to obtain a reply sentence, for example, by a voice architecture layer.

[0110] The reply sentence can be sent to a client.

[0111] It should be noted that part or all of the execution subjects of 301-304 can be an application located in a terminal device of a local terminal, i.e., a terminal device of a service provider, or can also be a functional unit such as a plug-in or a software development kit (SDK) arranged in the application located in the local terminal, and the present embodiment does not make a special limitation thereon.

[0112] It can be understood that the application can be a native application (nativeApp) installed on the terminal, or can also be a web application (webApp) of a browser on the terminal, and the present embodiment does not make a special limitation thereon.

[0113] Optionally, in a possible implementation manner of the present embodiment, after 301, voice recognition results with a confidence degree not greater than a first preset threshold value can be rejected, for example, by the voice control layer; and / or a clarification question text can be generated for voice recognition results with a confidence degree greater than the first preset threshold value and not greater than a second preset threshold value, or the voice recognition results with the confidence degree greater than the first preset threshold value and not greater than the second preset threshold value and the clarification question text can be further cached, the first preset threshold value and the second preset threshold value are both preset real numbers greater than 0, and the first preset threshold value is less than the second preset threshold value. Then, the clarification question text can be voice synthesized to obtain a clarification question sentence, for example, by the voice architecture layer, and the clarification question sentence can be sent to the client. After receiving the clarification question sentence, the client can play the clarification question sentence and receive a clarification reply sentence made by a user in response to the clarification question sentence. Subsequent voice interaction processes for the clarification reply sentence can refer to the voice interaction processes for the request sentence, which will not be described herein again.

[0114] Optionally, in one possible implementation manner of the embodiment, whether the confidence of the speech recognition result is greater than the first preset threshold and the second preset threshold can be identified, for example, by the speech control layer; if the confidence of the speech recognition result is not greater than the first preset threshold, it is determined that the speech recognition result is rejected, that is, no subsequent speech interaction process is performed; if the confidence of the speech recognition result is greater than the first preset threshold, it is determined that the speech recognition result is received, so as to perform semantic analysis on the speech recognition result and subsequent speech interaction process. And / or, if the confidence of the speech recognition result is greater than the first preset threshold and not greater than the second preset threshold, a clarification question text is generated based on a preset clarification question logic, for the speech recognition result.

[0115] Optionally, in one possible implementation manner of the embodiment, the speech recognition result can include at least one intermediate recognition result obtained by the speech architecture layer within a first preset time after receiving the request sentence, and a final recognition result obtained within a second preset time after receiving the request sentence, wherein the end time of the first preset time is earlier than the tail point time of the voice activity detection of the request sentence; and the end time of the second preset time is later than the tail point time of the voice activity detection of the request sentence.

[0116] Correspondingly, in response to obtaining the first intermediate recognition result in the at least one intermediate recognition result, for example, by the speech architecture layer, the semantics of the at least one intermediate recognition result can be sequentially identified, for example, by the speech control layer, according to the time sequence of obtaining the intermediate recognition result; in response to identifying the first intermediate recognition result with complete semantics, the first intermediate recognition result with complete semantics is taken as the speech recognition result, and the operation of performing semantic analysis on the speech recognition result is performed; or, in response to identifying two adjacent speech recognition results with complete semantics and same semantic analysis result from the at least one intermediate recognition result, the previous speech recognition result in the two adjacent speech recognition results is taken as the speech recognition result, and the operation of performing semantic analysis on the speech recognition result is performed.

[0117] Optionally, in one possible implementation manner of the embodiment, after 302, the semantic analysis result can be distributed according to the domain in the semantic analysis result, for example, the semantic analysis result is distributed to the business processing unit corresponding to the domain in the semantic analysis result in the business processing layer. Correspondingly, in 303, the dialog reply result can be obtained by calling the dialog service resource corresponding to the domain in the semantic analysis result, for example, by the business processing unit corresponding to the domain in the semantic analysis result.

[0118] Optionally, in a possible implementation of the embodiment, the request statement can include a business ID, the business ID being used to uniquely identify a type of business. Accordingly, after 302, the semantic analysis result can be distributed according to the business ID, for example, the semantic analysis result can be distributed to a business control unit corresponding to the business ID in the business control layer according to the business ID.

[0119] In the embodiments of the present disclosure, different links in the voice interaction process can be realized by different levels in the voice interaction system. In this way, the internal tasks and the functions to be realized of each level are clear, which can reduce the product development difficulty of the system. When a certain function or the specific implementation logic thereof needs to be updated, only the level of the function needs to be iterated, which helps to improve the iteration speed and efficiency, has better scalability, and can well support the needs of multiple product lines.

[0120] In addition, the business processing layer can call the dialog service resource of the field corresponding to the semantic analysis result, and the business logic at the level of the dialog service resource can be provided according to the field, so that the business logic of each field can be polished in depth and in detail, and more accurate and precise dialog reply results can be obtained, which helps to improve the business experience of users in each field.

[0121] In addition, it should be noted that, for the foregoing method embodiments, in order to simply describe, they are all described as a series of action combinations, but those skilled in the art should know that the present disclosure is not limited to the order of the actions described, because according to the present disclosure, certain steps can be performed in other order or at the same time. Secondly, those skilled in the art should know that the embodiments described in the specification all belong to preferred embodiments, and the actions and modules involved are not necessarily essential to the present disclosure.

[0122] In the above embodiments, the description of each embodiment has its own focus, and the parts not described in detail in a certain embodiment can be referred to the related description of other embodiments.

[0123] In the technical solutions of the present disclosure, the acquisition, storage and application of user personal information comply with relevant laws and regulations and do not violate public order and good customs.

[0124] According to the embodiments of the present disclosure, the present disclosure further provides an electronic device, a readable storage medium and a computer program product.

[0125] Figure 4A schematic block diagram of an example electronic device 400 that can be used to implement embodiments of the present disclosure is shown. The electronic device is intended to represent various forms of digital computers, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device may also represent various forms of mobile devices, such as personal digital processors, cellular phones, smartphones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely illustrative and are not intended to limit the implementation of the present disclosure described and / or claimed herein.

[0126] like Figure 4 As shown, device 400 includes a computing unit 401, which can perform various appropriate actions and processes based on a computer program stored in read-only memory (ROM) 402 or a computer program loaded from storage unit 408 into random access memory (RAM) 403. RAM 403 may also store various programs and data required for the operation of device 400. The computing unit 401, ROM 402, and RAM 403 are interconnected via bus 404. Input / output (I / O) interface 405 is also connected to bus 404.

[0127] Multiple components in device 400 are connected to I / O interface 405, including: input unit 406, such as keyboard, mouse, etc.; output unit 407, such as various types of monitors, speakers, etc.; storage unit 408, such as disk, optical disk, etc.; and communication unit 409, such as network card, modem, wireless transceiver, etc. Communication unit 409 allows device 400 to exchange information / data with other devices through computer networks such as the Internet and / or various telecommunications networks.

[0128] The computing unit 401 can be various general and / or special purpose processing components with processing and computing capabilities. Some examples of the computing unit 401 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various specialized artificial intelligence (AI) computing chips, various computing units running machine learning model algorithms, a digital signal processor (DSP), and any appropriate processor, controller, microcontroller, etc. The computing unit 401 performs various methods and processes described above, such as the method of voice interaction. For example, in some embodiments, the method of voice interaction can be implemented as a computer software program tangibly embodied in a machine-readable medium, such as the storage unit 408. In some embodiments, part or all of the computer program can be loaded and / or installed onto the device 400 via the ROM 402 and / or the communication unit 409. When the computer program is loaded onto the RAM 403 and executed by the computing unit 401, one or more steps of the method of voice interaction described above can be performed. Alternatively, in other embodiments, the computing unit 401 can be configured to perform the method of voice interaction by any other appropriate means, such as by means of firmware.

[0129] Various implementations of the systems and techniques described above can be realized in digital electronic circuitry, integrated circuitry, a field programmable gate array (FPGA), an application specific integrated circuit (ASIC), a system on a chip (SOC), a programmable logic device (PLD), a computer hardware, firmware, software, and / or combinations thereof. These various implementations can include implementation in one or more computer programs that are executable and / or interpretable on a programmable system including at least one programmable processor, which can be special or general purpose, coupled to receive data and instructions from, and to transmit data and instructions to, a storage system, at least one input device, and at least one output device.

[0130] Program code for carrying out methods of the present disclosure can be written in any combination of one or more programming languages. The program code can be provided to a processor or controller of a general purpose computer, special purpose computer, or other programmable data processing apparatus to produce a machine, such that the program code, when executed by the processor or controller, produces the functions / operations specified in the flowcharts and / or the block diagrams. The program code can be executed entirely on a machine, partially on a machine, partially on a machine as a stand-alone software package, partially on a machine and partially on a remote machine or entirely on a remote machine or server.

[0131] In the context of this disclosure, a machine-readable medium can be a tangible medium that contains or stores a program for use by or in connection with an instruction execution system, apparatus, or device. The machine-readable medium can be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium can include but is not limited to an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any suitable combination of the foregoing. More specific examples of the machine-readable storage medium would include an electrical connection based on one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or Flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.

[0132] To provide for interaction with a user, the systems and techniques described here can be implemented on a computer having a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user and a keyboard and a pointing device (e.g., a mouse or a trackball) by which the user can provide input to the computer. Other kinds of devices can be used to provide for interaction with a user as well; for example, feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form, including acoustic, speech, or tactile input.

[0133] The systems and techniques described here can be implemented in a computing system that includes a back end component (e.g., as a data server), or that includes a middleware component (e.g., an application server), or that includes a front end component (e.g., a user computer having a graphical user interface or a Web browser through which a user can interact with an implementation of the systems and techniques described here), or any combination of such back end, middleware, or front end components. The components of the system can be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include a local area network (LAN), a wide area network (WAN), and the Internet.

[0134] The computer system can include clients and servers. A client and server are generally remote from each other and typically interact through a communication network. The relationship of client and server arises by virtue of computer programs running on the respective computers and having a client-server relationship to each other. The server can be a cloud server, a server of a distributed system, or a server combined with a blockchain.

[0135] It should be understood that the various forms of flow shown above can be used to reorder, add, or remove steps. For example, the steps described in the present disclosure can be performed in parallel, in series, or in a different order, without limitation herein, so long as the desired results of the technology described in the present disclosure are achieved.

[0136] The specific implementation described above does not constitute a limitation on the protection scope of the present disclosure. Those skilled in the art should understand that various modifications, combinations, sub-combinations, and substitutions can be made according to design requirements and other factors. Any modifications, equivalent replacements, and improvements made within the spirit and principles of the present disclosure shall be included in the protection scope of the present disclosure.

Claims

1. A system of voice interaction, comprising: a voice architecture layer, configured to receive a request sentence, perform voice recognition on the request sentence, obtain a voice recognition result and send the voice recognition result to a voice central control layer, the voice recognition result comprising a plurality of intermediate recognition results obtained within a first preset time after the request sentence is received; perform voice synthesis on a dialogue reply result returned by the voice central control layer to obtain a reply sentence; the voice central control layer, configured to perform semantic analysis on the voice recognition result to obtain a semantic analysis result and send the semantic analysis result to a service central control layer, the semantic analysis result comprising domain, intent and slot information, the voice recognition result subjected to semantic analysis being a first intermediate recognition result with complete semantics; and forward the dialogue reply result returned by the service central control layer to the voice architecture layer; the service central control layer, configured to distribute the semantic analysis result to a service processing layer; and forward the dialogue reply result returned by the service processing layer to the voice central control layer; the service processing layer, configured to call a dialogue service resource corresponding to a domain of the semantic analysis result, obtain the dialogue reply result and return the dialogue reply result to the service central control layer; wherein the service processing layer comprises at least one service processing unit corresponding to different domains respectively; the service central control layer, configured to distribute the semantic analysis result to a service processing unit corresponding to a domain of the semantic analysis result in the service processing layer according to the domain in the semantic analysis result; and forward the dialogue reply result returned by the service processing unit to a voice central control unit in the voice central control layer; the service processing unit, configured to call a dialogue service resource corresponding to the domain in the semantic analysis result, obtain the dialogue reply result and return the dialogue reply result to the service central control layer; the voice central control layer comprises an interaction optimization unit, and the interaction optimization unit comprises a speed optimization module; the speed optimization module, configured to, in response to obtaining a first intermediate recognition result in the plurality of intermediate recognition results, sequentially identify whether the semantics of the plurality of intermediate recognition results are complete according to a time sequence in which the intermediate recognition results are obtained, based on a first probability that each intermediate recognition result is a prefix of a historical final recognition result and a second probability that each intermediate recognition result is a historical final recognition result.

2. The system of claim 1, wherein, the voice architecture layer comprises a voice architecture unit, a voice recognition unit and a voice synthesis unit; the voice architecture unit, configured to receive the request sentence, call the voice recognition unit to perform voice recognition on the request sentence, obtain the voice recognition result and send the voice recognition result to a voice central control unit in the voice central control layer; and call the voice synthesis unit to perform voice synthesis on a dialogue reply result returned by the voice central control unit, obtain a reply audio and send the reply audio to a client.

3. The system of claim 2, wherein, the voice central control layer comprises a voice central control unit and a semantic analysis unit; The voice control unit is configured to invoke the semantic analysis unit to perform semantic analysis on the voice recognition result sent by the voice architecture unit in the voice architecture layer, to obtain the semantic analysis result and send the semantic analysis result to a service control unit in the service control layer, and to forward the dialogue reply result returned by the service control unit to the voice architecture unit.

4. The system of claim 3, wherein, The voice control unit is further configured to invoke the interaction optimization unit to reject the voice recognition result with a confidence level not greater than a first preset threshold, and / or to generate a clarification question text for the voice recognition result with a confidence level greater than the first preset threshold and not greater than a second preset threshold and send the clarification question text to the voice architecture unit, or to cache the voice recognition result with the confidence level greater than the first preset threshold and not greater than the second preset threshold and the clarification question text, the first preset threshold being less than the second preset threshold. The voice architecture unit is further configured to perform voice synthesis on the clarification question text to obtain a clarification question sentence.

5. The system of claim 4, wherein, The interaction optimization unit includes at least one of an auxiliary recognition module and a semantic clarification module. The voice control unit is configured to invoke the auxiliary recognition module to confirm whether to receive or reject the voice recognition result, and / or to invoke the semantic clarification module to generate a clarification question text for the voice recognition result with a confidence level greater than the first preset threshold and not greater than the second preset threshold. The auxiliary recognition module is configured to identify whether the confidence level of the voice recognition result is greater than a first preset threshold and a second preset threshold. If the confidence level of the voice recognition result is not greater than the first preset threshold, it is confirmed that the voice recognition result is rejected. If the confidence level of the voice recognition result is greater than the first preset threshold, it is confirmed that the voice recognition result is received, so that the voice control unit invokes the semantic analysis unit to perform semantic analysis on the voice recognition result. The semantic clarification module is configured to generate a clarification question text for the voice recognition result based on a preset clarification question logic if the confidence level of the voice recognition result is greater than the first preset threshold and not greater than the second preset threshold.

6. The system of claim 4 or 5, wherein, The voice recognition result includes a final recognition result obtained by the voice architecture layer within a second preset time after the voice architecture layer receives the request sentence, wherein an end time of the first preset time is earlier than an end time of voice activity detection of the request sentence, and an end time of the second preset time is later than the end time of the voice activity detection of the request sentence. The speed optimization module is further configured to, in response to identifying a first semantically complete intermediate recognition result, take the first semantically complete intermediate recognition result as the voice recognition result, call the semantic analysis unit to perform semantic analysis on the voice recognition result sent by the voice architecture unit in the voice architecture layer, obtain the semantic analysis result, and send the semantic analysis result to the service control unit; or, in response to identifying two adjacent voice recognition results that are semantically complete and have the same semantic analysis result from the multiple intermediate recognition results, take a previous voice recognition result in the two adjacent voice recognition results as the voice recognition result, call the semantic analysis unit to perform semantic analysis on the voice recognition result sent by the voice architecture unit in the voice architecture layer, obtain the semantic analysis result, and send the semantic analysis result to the service control unit.

7. The system of claim 1, wherein, The service control layer comprises a service control unit and at least one of a general unit and a customized unit. The service control unit is configured to distribute the semantic analysis result to a service processing unit corresponding to a domain in the semantic analysis result in the service processing layer according to the domain in the semantic analysis result, and forward the conversation reply result returned by the service processing unit to a voice control unit in the voice control layer. The general unit is configured to implement a preset general function, and the preset general function comprises a multi-round conversation function based on a preset conversation counter-question logic. The customized unit is configured to implement an extended function of a preset service.

8. The system of claim 1, wherein, The request sentence comprises a service identifier, and the service identifier is used for uniquely identifying a type of service. The service control layer comprises a plurality of service control units corresponding to different types of services. The voice control layer is specifically configured to distribute the semantic analysis result to a service control unit corresponding to the service identifier in the service control layer according to the service identifier.

9. A voice interaction method, comprising: receiving a request sentence, performing voice recognition on the request sentence to obtain a voice recognition result, the voice recognition result comprising a plurality of intermediate recognition results obtained within a first preset time after receiving the request sentence; performing semantic analysis on the voice recognition result to obtain a semantic analysis result, the semantic analysis result comprising a domain, an intent, and slot information, and the voice recognition result subjected to semantic analysis being a first semantically complete intermediate recognition result; calling a conversation service resource corresponding to the domain of the semantic analysis result to obtain a conversation reply result; performing voice synthesis on the conversation reply result to obtain a reply sentence; The method further comprises: ​ ​ In response to obtaining a first intermediate recognition result of the plurality of intermediate recognition results, in a time sequence of obtaining the intermediate recognition results, whether semantics of the plurality of intermediate recognition results are complete is identified in sequence based on a first probability of each intermediate recognition result as a prefix of a historical final recognition result and a second probability of each intermediate recognition result as the historical final recognition result.

10. The method of claim 9, further comprising: rejecting the speech recognition result whose confidence is not greater than a first preset threshold value; and / or, generating a clarification question text for the speech recognition result whose confidence is greater than the first preset threshold value and not greater than a second preset threshold value, or caching the speech recognition result whose confidence is greater than the first preset threshold value and not greater than the second preset threshold value and the clarification question text, the first preset threshold value being less than the second preset threshold value; performing speech synthesis on the clarification question text to obtain a clarification question sentence.

11. The method of claim 10, wherein, The rejecting the speech recognition result whose confidence is not greater than a first preset threshold value; and / or, generating a clarification question text for the speech recognition result whose confidence is greater than the first preset threshold value and not greater than a second preset threshold value, comprises: identifying whether the confidence of the speech recognition result is greater than the first preset threshold value and the second preset threshold value; if the confidence of the speech recognition result is not greater than the first preset threshold value, confirming to reject the speech recognition result; if the confidence of the speech recognition result is greater than the first preset threshold value, confirming to receive the speech recognition result so as to perform semantic analysis on the speech recognition result; and / or, if the confidence of the speech recognition result is greater than the first preset threshold value and not greater than the second preset threshold value, generating a clarification question text for the speech recognition result based on a preset clarification question logic.

12. The method of any one of claims 9-11, wherein, The speech recognition result comprises a final recognition result obtained within a second preset time after the request sentence is received, wherein an end time of the first preset time is earlier than a tail point time of voice activity detection of the request sentence; an end time of the second preset time is later than the tail point time of the voice activity detection of the request sentence. The method further comprises: in response to identifying a first semantically complete intermediate recognition result, taking the first semantically complete intermediate recognition result as the speech recognition result, and performing the operation of performing semantic analysis on the speech recognition result; or, in response to identifying two adjacent speech recognition results which are semantically complete and have the same semantic analysis result from the plurality of intermediate recognition results, taking a previous speech recognition result of the two adjacent speech recognition results as the speech recognition result, and performing the operation of performing semantic analysis on the speech recognition result.

13. The method of claim 9, wherein, after the performing semantic analysis on the speech recognition result to obtain a semantic analysis result, the method further comprises: distributing the semantic analysis result according to a field in the semantic analysis result.

14. The method of claim 13, wherein, The request sentence comprises a business identifier, the business identifier being used to uniquely identify a type of business; The semantic analysis on the speech recognition result to obtain a semantic analysis result further includes: Distributing the semantic analysis result according to the service identifier.

15. An electronic device, comprising: at least one processor; and a memory connected to the at least one processor in communication; wherein the memory stores instructions executable by the at least one processor, the instructions being executed by the at least one processor to enable the at least one processor to perform the method of any one of claims 9-14.

16. A non-transitory computer readable storage medium having stored thereon computer instructions, wherein, The computer instructions are used to enable the computer to perform the method according to any one of claims 9-14.

17. A computer program product comprising a computer program which, when executed by a processor, implements the method according to any one of claims 9-14.

Citation Information

Patent Citations

  • Human-computer interaction-based natural language processing method, device, apparatus and medium

    CN109101545A

  • Voice interaction method and device, electronic equipment and storage medium

    CN112466302A

  • Voice confidence detection method and device, electronic equipment and storage medium

    CN113674732A