Method and device for guiding user replies, electronic device and storage medium

By judging the completeness and characteristics of the user's request information and generating guiding sentences, the problems of incomplete requests and single responses in smart home voice interaction are solved, and a diversified voice interaction experience is achieved.

CN114944158BActive Publication Date: 2025-09-12GREE ELECTRIC APPLIANCE INC OF ZHUHAI +1
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202210700477.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-06-20
Publication Date
2025-09-12
Estimated Expiration
2042-06-20

AI Technical Summary

Technical Problem

In smart home voice interaction, the user's request information may be incomplete, resulting in the inability to execute the command, and the response sentence structure in the existing technology is single and lacks diversity.

Method used

By obtaining user request information, judging its completeness, determining missing entities and user characteristics, generating guiding sentences containing missing entities, and providing feedback in combination with user characteristic information, we can achieve complete and diverse responses.

Benefits of technology

It improves the diversity of voice interaction, solves the problem of single reply sentence structure, makes replies more in line with user habits, and improves the interactive experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114944158B_ABST
    Figure CN114944158B_ABST
Patent Text Reader

Abstract

The present application relates to a method and device, electronic device and storage medium for guiding user replies. The method includes: obtaining target request information from a target user; determining whether the target request information meets a preset request integrity requirement; if the target request information does not meet the request integrity requirement, determining the missing entities missing in the target request information, as well as the user feature information corresponding to the target user; based on the missing entities and the user feature information, determining a target guiding sentence for guiding the user to reply; and feeding back the target guiding sentence to the target user. The method provided by the embodiment of the present application solves the problem in the related art that the same sentence pattern is replied to all users, resulting in a single interactive sentence pattern during the voice interaction process.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of artificial intelligence technology, and in particular to a method and device for guiding user replies, an electronic device, and a storage medium. Background Art

[0002] With the development of smart home technology and voice interaction technology, more and more smart home devices can support voice interaction with users.

[0003] During smart home voice interaction, due to varying language conventions and cultural backgrounds, users may express requests that are not supported by the interaction semantics. For example, a typical request to turn on the air conditioner's heating function would be "Turn on the heating function." However, users often receive multiple requests during interaction, such as "Turn on the heating function," "Is the heating on?", and "Turn on the heating." Many industry approaches address this issue by extracting entities, identifying the objects, and then executing the corresponding functions. For example, in the example above, the extracted information would indicate the object "heating function" and the action "turn on." This is a common scenario and use case, but in real-world data, we also see situations where users pause or wait to wake the air conditioner before they finish speaking. In this case, commands like "Set the temperature to," "Heating function," and "Set the windshield to" appear. These commands have objects but no action extracted, making them unexecuted.

[0004] In the related art, the same sentence pattern is used to answer all users. Therefore, there is a problem of a single reply sentence pattern during voice interaction.

[0005] There is currently no effective solution to the problem of a single reply sentence structure in the voice interaction process in related technologies. Summary of the Invention

[0006] In order to solve the technical problem of a single reply sentence in the above-mentioned voice interaction process, the present application provides a method and device for guiding user replies, an electronic device and a storage medium.

[0007] In a first aspect, an embodiment of the present application provides a method for guiding a user to reply, comprising:

[0008] Obtain target request information from target users;

[0009] Determining whether the target request information meets a preset request integrity requirement, wherein the request integrity requirement is used to indicate whether the request information fully expresses the intent;

[0010] If the target request information does not meet the request completeness requirement, determining missing entities missing from the target request information and user feature information corresponding to the target user, wherein the missing entities are entity content that needs to be added to make the target request information complete, and the user feature information includes at least one target feature type;

[0011] Based on the missing entity and the user characteristic information, determining a target guiding sentence for guiding the user to reply, wherein the target guiding sentence includes the missing entity and the characteristic information of the target guiding sentence is related to the user characteristic information;

[0012] Feedback the target guidance sentence to the target user.

[0013] Optionally, as in the aforementioned method, determining whether the target request information meets a preset request integrity requirement includes:

[0014] Performing entity extraction on the target request information to obtain a target entity included in the target request information;

[0015] In a case where it is determined that all the target entities include all the designated entities indicated by the request integrity requirement, determining that the target request information meets the request integrity requirement;

[0016] When it is determined that at least one designated entity is missing from all the target entities, it is determined that the target request information does not meet the request integrity requirement, and the missing entities that are missing from all the target entities are determined from among all the designated entities.

[0017] Optionally, as in the aforementioned method, determining a target guiding sentence for guiding the user to reply based on the missing entity and the user characteristic information includes:

[0018] Determine a preset target feature matrix, wherein the target feature matrix is ​​used to indicate the importance relationship between different feature types; determine a target feature level corresponding to each target feature type in the user feature information, wherein, for each target feature type, the target feature level corresponding to the target feature type is used to indicate the level corresponding to the target user under the target feature type;

[0019] Determining the missing feature type of the missing entity by performing feature analysis on the target request information;

[0020] Determining a candidate guiding sentence matching the target request information according to the missing feature type of the missing entity and the target feature level corresponding to each target feature type;

[0021] An evaluation value of each candidate guidance sentence is determined according to the target feature matrix, and the candidate guidance sentence with the highest evaluation value is determined as the target guidance sentence.

[0022] Optionally, as in the aforementioned method, determining a preset target feature matrix includes:

[0023] Determining a candidate importance level corresponding to each of the feature types and a candidate weight matrix composed of all the candidate importance levels;

[0024] Performing consistency testing on all candidate importance levels and obtaining a test result;

[0025] When it is determined that the inspection result meets the preset consistency requirement, the candidate weight matrix is ​​determined as the target feature matrix.

[0026] Optionally, as in the aforementioned method, determining the target feature level corresponding to each feature type in the user feature information includes:

[0027] Determining a level division scheme corresponding to each of the feature types, wherein, for each of the feature types, the level division scheme corresponding to the feature type is used to indicate a correspondence between different parameter value ranges and feature levels under the feature type;

[0028] In the user characteristic information, determining a user parameter value corresponding to each characteristic type;

[0029] By determining the target feature level corresponding to the user parameter value of each feature type according to the level division scheme corresponding to each feature type, the target feature level corresponding to each feature type is determined, wherein, for each feature type, the parameter value range corresponding to the target feature level includes the user parameter value of the feature type.

[0030] Optionally, as in the aforementioned method, determining a candidate guiding sentence matching the target request information according to the entity type of the missing entity and the target feature level corresponding to each target feature type includes:

[0031] Determining a preliminary screening guide sentence including the missing feature type in a preset guide sentence database;

[0032] According to the target feature level corresponding to each target feature type, a candidate guide sentence matching the target request information is determined from all the preliminary screening guide sentences, wherein, for any target feature type, the feature level corresponding to the target feature type in the candidate guide sentence is equal to the target feature level corresponding to the target feature type in the user feature information.

[0033] Optionally, as in the aforementioned method, before determining the evaluation value of each candidate guiding sentence according to the target feature matrix and determining the candidate guiding sentence with the highest evaluation value as the target guiding sentence, the method further includes:

[0034] Determine an intermediate matrix by calculating the geometric mean of the elements in each row of the target feature matrix;

[0035] Normalizing the intermediate matrix to obtain feature weights corresponding to each feature type;

[0036] Determining the evaluation value of each candidate guiding sentence according to the target feature matrix includes:

[0037] Determining a candidate feature level for each feature type in the candidate guidance sentence;

[0038] Weighting the candidate feature levels of each feature type according to the feature weight corresponding to each feature type to obtain a weighted value for each feature type;

[0039] All the weighted values ​​are summed to obtain the evaluation value of the candidate guiding sentence.

[0040] In a second aspect, an embodiment of the present application provides a device for guiding a user to reply, comprising:

[0041] An acquisition module is used to obtain target request information from a target user;

[0042] A judgment module, configured to judge whether the target request information satisfies a preset request integrity requirement, wherein the request integrity requirement is used to indicate whether the request information fully expresses the intent;

[0043] a first determining module, configured to determine, when the target request information does not meet the request completeness requirement, missing entities missing from the target request information and user feature information corresponding to the target user, wherein the missing entities are entity content that needs to be added to complete the target request information, and the user feature information includes at least one target feature type;

[0044] a second determining module, configured to determine, based on the missing entity and the user characteristic information, a target guiding sentence for guiding the user to reply, wherein the target guiding sentence includes the missing entity, and the characteristic information of the target guiding sentence is related to the user characteristic information;

[0045] A feedback module is used to feed back the target guiding sentence to the target user.

[0046] In a third aspect, an embodiment of the present application provides an electronic device, comprising: a processor, a communication interface, a memory, and a communication bus, wherein the processor, the communication interface, and the memory communicate with each other via the communication bus;

[0047] The memory is used to store computer programs;

[0048] The processor is configured to implement any of the aforementioned methods when executing the computer program.

[0049] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium, wherein the storage medium includes a stored program, wherein the program executes the method as described in any of the preceding items when running.

[0050] The above technical solution provided by the embodiment of the present application has the following advantages compared with the prior art:

[0051] The method provided in the embodiment of the present application adopts a method of obtaining the final target guidance sentence based on the missing entity and user feature information. The missing entity can be determined so that the obtained target guidance sentence can include the missing entity, thereby achieving the purpose of making the target guidance sentence complete in intent. The target guidance sentence is obtained by combining the user feature information of the target user, so that the final target guidance sentence can be suitable for the user's habitual reply method, thereby improving the diversity of voice interaction, and solving the problem in related technologies of replying the same sentence pattern to all users, resulting in a single interactive sentence pattern during the voice interaction process. BRIEF DESCRIPTION OF THE DRAWINGS

[0052] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the invention and, together with the description, serve to explain the principles of the invention.

[0053] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the following briefly introduces the drawings required for use in the embodiments or the description of the prior art. Obviously, for ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative labor.

[0054] Figure 1A flowchart of a method for guiding user replies provided in an embodiment of the present application;

[0055] Figure 2 A flowchart of a method for guiding user replies provided in another embodiment of the present application;

[0056] Figure 3 A block diagram of a device for guiding user replies provided in an embodiment of the present application;

[0057] Figure 4 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0058] To make the purpose, technical solutions, and advantages of the embodiments of this application more clear, the technical solutions in the embodiments of this application will be clearly and completely described below in conjunction with the drawings in the embodiments of this application. Obviously, the described embodiments are part of the embodiments of this application, not all of the embodiments. Based on the embodiments in this application, all other embodiments obtained by ordinary technicians in this field without making creative efforts are within the scope of protection of this application.

[0059] According to one aspect of an embodiment of the present application, a method for guiding a user to reply is provided. Optionally, in this embodiment, the method for guiding a user to reply can be applied to a hardware environment consisting of a terminal and a server. The server is connected to the terminal via a network and can be used to provide services (such as advertising push services, application services, etc.) for the terminal or a client installed on the terminal. A database can be set up on the server or independently of the server to provide data storage services for the server.

[0060] The aforementioned network may include, but is not limited to, at least one of the following: a wired network and a wireless network. The aforementioned wired network may include, but is not limited to, at least one of the following: a wide area network, a metropolitan area network, or a local area network. The aforementioned wireless network may include, but is not limited to, at least one of the following: Wi-Fi (Wireless Fidelity) and Bluetooth. The terminal may be, but is not limited to, a PC, a mobile phone, a tablet computer, or the like.

[0061] The method for guiding user replies in the embodiment of the present application can be executed by a server, a terminal, or both. The terminal can also execute the method for guiding user replies in the embodiment of the present application by a client installed thereon.

[0062] Taking the method of guiding the user to reply in this embodiment executed by the server as an example, Figure 1 A method for guiding a user to reply provided in an embodiment of the present application includes the following steps:

[0063] Step S101: Acquire target request information from a target user.

[0064] The method of guiding the user to reply in this embodiment can be applied to scenarios where the intention of the target request information sent by the user is incomplete, guiding the user to send a request information with complete intention, for example: a scenario where the intention of the control voice sent by the user to control the air conditioner is incomplete, a scenario where the intention of the control voice sent by the user to control the TV is incomplete, a scenario where the intention of the control gesture sent by the user to control the projector is incomplete, etc. It can also be a scenario where other types of request information are sent to control other devices. In the embodiment of the present application, the method of guiding the user to reply is explained by taking the user interacting with the air conditioner through control voice as an example. For other types of request information or other types of devices, the above-mentioned abnormal media resource detection method is also applicable if there is no contradiction.

[0065] Taking the example of a user interacting with an air conditioner through control voice, the target user can control the air conditioner by issuing control voice. After the air conditioner receives the control voice, it can perform semantic recognition on the control voice and obtain the corresponding target request information.

[0066] Optionally, the control voice can be obtained by a voice acquisition device set on the target user side (which can be integrated into the air conditioner or a separate device), and semantic recognition can be performed, and then converted into target request information and sent to the server. The control voice can also be sent directly to the server for semantic recognition by the server side.

[0067] Step S102: determine whether the target request information meets a preset request integrity requirement, wherein the request integrity requirement is used to indicate whether the request information fully expresses the intent.

[0068] After obtaining the target request information, in order to determine whether a guided reply is required, it is necessary to determine whether the target request information meets the preset request integrity requirements.

[0069] The target request information may be text information, and semantic analysis may be performed on the target request to determine whether the target request information includes all conditions for controlling the air conditioner.

[0070] For example, if the target request information is "adjust the temperature to," it can only be determined that the target user wants to adjust the temperature, but it cannot determine the specific temperature the target user actually wants to adjust to. Therefore, there is only the object (temperature) and no specific action to be performed (for example, adjust the temperature to 26 degrees).

[0071] Step S103, when the target request information does not meet the request completeness requirements, determine the missing entities missing in the target request information and the user feature information corresponding to the target user, wherein the missing entity is the entity content that needs to be added to make the target request information complete, and the user feature information includes at least one target feature type.

[0072] When it is determined that the target request information does not meet the request completeness requirement, it is necessary to determine the missing entities that are missing from the target request information.

[0073] A missing entity may be an entity content that is used to indicate that the target request information is missing and that causes the target request information to be incomplete.

[0074] For example, in the aforementioned example, when the target request information is "adjust the temperature to", the missing entity is the action.

[0075] In order to achieve diverse responses during voice interaction, it is also necessary to obtain user feature information corresponding to the target user. The target feature types included in the user feature information include but are not limited to one or more of the following: region, function, model, and air conditioner price (the higher the price, the more functions, and the more refined the adjustability).

[0076] Step S104 : determining a target guiding sentence for guiding the user to reply based on the missing entity and the user characteristic information, wherein the target guiding sentence includes the missing entity, and the characteristic information of the target guiding sentence is related to the user characteristic information.

[0077] After determining the user characteristic information, a target guiding sentence for guiding the user to reply is determined based on the missing entity and the user characteristic information. The target guiding sentence can include the missing entity and integrate the user characteristic information, thereby achieving the ability to control the air conditioner while taking into account the conversation habits of the target user.

[0078] Step S105: Feedback the target guidance sentence to the target user.

[0079] After the target guiding sentence is determined, the target guiding sentence can be fed back to the target user. Optionally, the target guiding sentence can be converted into a voice and played back to achieve the purpose of feeding back to the target user.

[0080] Through the method in this embodiment, the final target guidance sentence is obtained based on the missing entity and user feature information. The missing entity can be determined so that the obtained target guidance sentence can include the missing entity, thereby achieving the purpose of making the target guidance sentence complete. In addition, the target guidance sentence is obtained in combination with the user feature information of the target user, so that the final target guidance sentence can be suitable for the user's habitual reply method, thereby improving the diversity of voice interaction, and solving the problem in related technologies that the same sentence pattern is replied to all users, resulting in a single voice interaction process.

[0081] like Figure 2 As shown, as an optional implementation, as in the above method, step S102 determines whether the target request information meets the preset request integrity requirement, including the following steps:

[0082] Step S201: extract entity from target request information to obtain target entity included in the target request information.

[0083] After obtaining the target request information, semantic recognition may be performed on the target request information, and then entity extraction may be performed to obtain all target entities included in the target request information. The target entity may include one or more types.

[0084] Step S202: When it is determined that all target entities include all designated entities indicated by the request integrity requirement, it is determined that the target request information meets the preset request integrity requirement.

[0085] Step S203: when it is determined that at least one designated entity is missing from all target entities, it is determined that the target request information does not meet the preset request integrity requirement, and missing entities that are missing from all target entities are determined from all designated entities.

[0086] After all target entities are determined, it can be determined whether the target entities meet the request integrity requirements.

[0087] Optionally, the request integrity requirements generally need to include actions and objects; therefore, the specified entities may include actions and objects; and then it can be determined whether all target entities include all specified entities at the same time. If all target entities include all specified entities, it is determined that the target request information meets the preset request integrity requirements. If all target entities fail to include all specified entities, it is determined that the target request information does not meet the preset request integrity requirements, and among all specified entities, the missing entities that are missing from all target entities are determined.

[0088] Through the method in this embodiment, it is possible to determine whether the target request information can fully express the intention, and also to determine the missing entities missing from the target request information when the target request information does not meet the preset request completeness requirements.

[0089] As an optional implementation, as in the aforementioned method, step S104 determines a target guiding sentence for guiding the user to reply based on the missing entity and user feature information, including the following steps:

[0090] Step S301: Determine a preset target feature matrix, where the target feature matrix is ​​used to indicate the importance relationship between different feature types; in the user feature information, determine the target feature level corresponding to each target feature type, where, for each target feature type, the target feature level corresponding to the target feature type is used to indicate the level corresponding to the target user under the target feature type.

[0091] Optionally, the importance relationship between different feature types (for example, regional level, function frequency level, model frequency level, air conditioner price level) can be determined in advance. For example, when the corresponding numerical value of the feature type is larger, the importance is higher. The following settings can be made: regional level is 1, function frequency level is 3, model frequency level is 5, and air conditioner price level is 1.

[0092] Regional level: Since different regions use different devices to purchase air conditioners (the interaction here occurs on voice air conditioners), they are divided into 5 levels according to the purchase volume. Level 1 means that the province is in the first tier in terms of the number of air conditioners purchased, and level 5 means that the province is in the fifth tier in terms of the number of air conditioners purchased. This means that the total number of air conditioners purchased in this province is the least compared to other provinces.

[0093] Function frequency level: There are many functions in the air conditioner, such as adjusting the temperature, adjusting the mode, and adjusting the wind direction. Each function corresponds to a different form. For example, the temperature can be controlled from 16-30 degrees. The frequency level is calculated based on the frequency of daily use by users. For example, most people like to use 26 degrees, so 26 degrees belongs to level one in the level, and the frequency of use is high.

[0094] Frequency level of model: Different air conditioners prefer different temperatures. According to the frequency of the temperature used by the model, the frequency of temperature use is arranged into levels. Level 1 is the most frequently used and level 5 is the least frequently used.

[0095] Air conditioner price level: According to the price of the air conditioner, the levels are arranged from expensive to cheap, with level one being the most expensive and level five being the cheapest.

[0096] Then we can get the following as shown in Table 1:

[0097] Regional level Function frequency level Model frequency level Air conditioning price level Regional level 1 1 / 3 1 / 5 1 Function frequency level 3 1 1 5 Model frequency level 5 1 1 5 Air conditioning price level 1 5 5 1

[0098] The target feature matrix that can be obtained is:

[0099]

[0100] As an optional implementation, as in the above method, the step S301 of determining a preset target feature matrix includes the following steps:

[0101] Step S601 : determining a candidate importance level corresponding to each feature type and a candidate weight matrix composed of all candidate importance levels.

[0102] Optionally, the candidate importance level corresponding to each feature type may be set based on empirical data, and then the candidate weight matrix may be obtained according to the above description.

[0103] Step S602: Perform consistency check on all candidate importance levels and obtain a check result.

[0104] After obtaining the candidate importance levels, we can perform consistency testing on all candidate importance levels. For example, if the region level is 1, the function frequency level is 3, the model frequency level is 5, and the air conditioner price level is 1, the testing method is:

[0105] 1:. Find the geometric mean of each row element of the judgment matrix:

[0106]

[0107] Will w i Normalization obtains the relative weight of factors:

[0108]

[0109] Get A and weight w i 0 The matrix dot multiplication result is:

[0110]

[0111] λ mi is used to calculate λ max The middle value of λ max Used for consistency checking.

[0112]

[0113] Each row calculates a λ mi ;

[0114] Substituting into the formula:

[0115]

[0116] Get λ max ;

[0117] In this matrix Therefore, the consistency check is passed, that is, the test result is passed the consistency check.

[0118] The value of RI is determined by referring to the average random consistency index. RI is determined by n, the order of the judgment matrix, which can be obtained by looking up the following table:

[0119] n 1 2 3 4 5 6 7 8 9 10 11 12 13 14 RI 0 0 0.52 0.89 1.12 1.26 1.36 1.41 1.46 1.49 1.52 1.54 1.56 1.58

[0120] In this example, n=4, then RI=0.89.

[0121] Step S603: When it is determined that the inspection result meets the preset consistency requirement, the candidate weight matrix is ​​determined as the target feature matrix.

[0122] Optionally, if the verification results do not meet the preset consistency requirements, a new candidate importance level corresponding to each feature type and a new candidate weight matrix composed of all the new candidate importance levels can be reset. The consistency requirements are then re-determined using the same method as steps S601 to S603. Step S302: Determine the missing feature type of the missing entity by performing feature analysis on the target request information.

[0123] After determining the target request information, feature analysis can be performed on the target request information to determine the missing feature type corresponding to the missing entity, thereby achieving the missing entity. For example, when the target request information is "adjust the temperature to", if the missing entity is an action, the missing feature type can be "adjust temperature" in the function frequency.

[0124] Furthermore, both missing entities and user characteristic information can be represented by features.

[0125] Step S303 : determining candidate guiding sentences that match the target request information according to the missing feature type of the missing entity and the target feature level corresponding to each target feature type.

[0126] As an optional implementation, as in the aforementioned method, determining a candidate guiding statement that matches the target request information according to the entity type of the missing entity and the target feature level corresponding to each target feature type includes the following steps:

[0127] Step S401: determining a preliminary screening guidance sentence including a missing feature type in a preset guidance sentence database.

[0128] After the missing feature type is determined, a first screening of guide sentences can be performed in a preset guide sentence database based on the missing feature type to obtain a preliminary screening guide sentence.

[0129] The guidance statement database may be a database storing guidance statements for different control targets and different expression habits.

[0130] For example, when it is determined that the missing feature type is adjusting temperature, all guiding sentences including adjusting temperature can be matched in the guiding sentence database and used as the initial screening guiding sentences.

[0131] Step S402: According to the target feature level corresponding to each target feature type, candidate guide sentences that match the target request information are determined from all the pre-screened guide sentences, wherein, for any target feature type, the feature level corresponding to the target feature type in the candidate guide sentence is equal to the target feature level corresponding to the target feature type in the user feature information.

[0132] After determining all preliminary screening guidance sentences and the target feature levels corresponding to the target feature types, as well as the target feature levels corresponding to each target feature type, a match can be performed on all preliminary screening guidance sentences based on the target feature levels corresponding to each target feature type. Optionally, a match can be performed on all preliminary screening guidance sentences one by one based on the target feature levels corresponding to each target feature type to obtain candidate guidance sentences.

[0133] For example, when the regional level is 1, the model frequency level is 5, and the air conditioner price level is 1, the first guide sentence can be matched in all the preliminary screening guide sentences according to the regional level of 1 (the regional level of the first guide sentence is also 1); then the second guide sentence can be matched in all the first guide sentences according to the model frequency level of 5 (the model frequency level of the second guide sentence is also 5); finally, the candidate guide sentence can be matched in all the second guide sentences according to the air conditioner price level of 1 (the model frequency level of the candidate guide sentence is also 1); and the candidate guide sentence can then simultaneously meet the requirements of regional level 1, model frequency level 5, and air conditioner price level 1.

[0134] Step S304: determining the evaluation value of each candidate guidance sentence according to the target feature matrix, and determining the candidate guidance sentence with the highest evaluation value as the target guidance sentence.

[0135] As an optional implementation, as in the aforementioned method, before determining the evaluation value of each candidate guide sentence according to the target feature matrix and determining the candidate guide sentence with the highest evaluation value as the target guide sentence, the method further includes the following steps:

[0136] Step S501, determining an intermediate matrix by calculating the geometric mean of the elements in each row of the target feature matrix;

[0137] Step S502: normalize the intermediate matrix to obtain feature weights corresponding to each feature type.

[0138] Based on the example shown in Table 1, the geometric mean of the elements in each row of the target feature matrix can be calculated according to the following formula to determine the intermediate matrix W:

[0139]

[0140] Based on the example shown in Table 2, the intermediate matrix is ​​normalized to obtain the feature weights corresponding to each feature type;

[0141]

[0142] That is, the feature weight of the region level is 0.099, the feature weight of the function frequency level is 0.381, the feature weight of the model frequency level is 0.433, and the feature weight of the air conditioner price level is 0.087.

[0143] The step S304 determines the evaluation value of each candidate guiding sentence according to the target feature matrix, including the following steps:

[0144] Step S503: Determine the candidate feature level of each feature type in the candidate guide sentence. Step S504: Weight the candidate feature level of each feature type according to the feature weight corresponding to each feature type to obtain a weighted value for each feature type.

[0145] Step S505: sum up all weighted values ​​to obtain the evaluation value of the candidate guidance sentence.

[0146] After determining the feature weights corresponding to each feature type and all candidate guide sentences, the evaluation value of each candidate guide sentence can be determined as follows:

[0147] Determine the candidate feature level of each feature type in the candidate guide sentence.

[0148] Since each feature type has a corresponding feature weight, we can weight the candidate feature levels of each feature type by multiplying the feature weight corresponding to the same feature type by the candidate feature level to obtain a weighted value for each feature type. Finally, we can calculate the evaluation value of the candidate guide sentence by summing up the weighted values.

[0149] For example, based on the aforementioned example where the feature weight of the region level is 0.099, the feature weight of the function frequency level is 0.381, the feature weight of the model frequency level is 0.433, and the feature weight of the air conditioner price level is 0.087, the evaluation value is: t1×0.099+t2×0.381+t3×0.433+t4×0.087, where t1 is the region level, t2 is the function frequency level, t3 is the model frequency level, and t4 is the air conditioner price level; therefore, when the region level of a candidate guide sentence is 1 (i.e., the level is 1 when the feature type is the region level), when the function frequency level is 2 (i.e., the level is 2 when the feature type is the function frequency level), when the model frequency level is 5 (i.e., the level is 5 when the feature type is the model frequency level), and when the air conditioner price level is 2 (i.e., the level is 2 when the feature type is the air conditioner price level), the evaluation value is:

[0150] 1×0.099+2×0.381+5×0.433+2×0.087=3.157.

[0151] As an optional implementation, as in the aforementioned method, step S301 determines the target feature level corresponding to each feature type in the user feature information, including the following steps:

[0152] Step S701 : determining a level division scheme corresponding to each feature type, wherein for each feature type, the level division scheme corresponding to the feature type is used to indicate the correspondence between different parameter value ranges and feature levels under the feature type.

[0153] A level division scheme corresponding to each feature type can be preset, and the level division scheme can be divided into multiple feature levels. For the same feature type, there is no intersection of parameter values ​​in different feature levels.

[0154] For example, when the feature type is adjusting temperature in the function frequency level, most people like to use 26 degrees, so 26 degrees belongs to the first level in the level, 25 degrees belongs to the second level, and 24 degrees belongs to the third level.

[0155] Step S702: Determine the user parameter value corresponding to each feature type in the user feature information.

[0156] Step S703: Determine the target feature level corresponding to the user parameter value of each feature type according to the level division scheme corresponding to each feature type, and determine the target feature level corresponding to each feature type, wherein, for each feature type, the parameter value range corresponding to the target feature level includes the user parameter value of the feature type.

[0157] After determining the user feature information, the user parameter value corresponding to each feature type in the user feature information can be determined, and then for each feature type, the target feature level to which the determined user parameter value belongs in the feature type can be determined as the target feature level corresponding to the feature type.

[0158] As described below, an application example of any of the above embodiments is provided:

[0159] For example, if a user says, "Adjust the temperature to," our approach to guided responses requires us to guide them to specify the desired temperature. Should we respond with, "Please tell me to adjust the temperature to 25 degrees," "Please tell me to adjust the temperature to 26 degrees," or "Please tell me to adjust the temperature to 27 degrees?" We hope to guide users to responses that are relevant to their thinking, allowing them to repeat the original command without hesitation.

[0160] According to the calculation formula in the third point, assuming the price of this air conditioner is known (level 2), the location is known (level 1), and the model is known (level 3), the possible sentences include "Please tell me to adjust the temperature to 25 degrees," "Please tell me to adjust the temperature to 26 degrees," and "Please tell me to adjust the temperature to 27 degrees." Based on the function frequency level corresponding to temperature, the highest-scoring sentence among these responses is calculated using the evaluation value calculation formula and is used as the final response. The missing entity in this example is the action, and the missing feature type of this missing entity is "adjust temperature" in the function frequency level.

[0161] For example, a user asks, "What's the weather like today?" but doesn't specify a specific region. In this case, the missing instance is an object, and the missing feature type is the region level. Possible responses include, "What's the weather like in Zhuhai today?", "What's the weather like in Zhongshan today?", "What's the weather like in Beijing today?", and "What's the weather like in Hebei today?" The scores of the potential responses are determined based on the different levels corresponding to the regions and the known items that issued the request. In practical applications, the dimensionality matrix is ​​much larger than the distance matrix to ensure that it covers a wide range of user requests and is compatible with cases where objects or operation items are missing.

[0162] like Figure 3 As shown, according to an embodiment of another aspect of the present application, a device for guiding a user to reply is also provided, comprising:

[0163] Acquisition module 1, used to obtain target request information from the target user;

[0164] Determination module 2, used to determine whether the target request information meets the preset request integrity requirement, wherein the request integrity requirement is used to indicate whether the request information fully expresses the intent;

[0165] A first determining module 3 is configured to determine missing entities missing from the target request information and user feature information corresponding to the target user when the target request information does not meet the request completeness requirement, wherein the user feature information includes at least one target feature type;

[0166] A second determining module 4 is configured to determine a target guiding sentence for guiding the user to reply based on the user characteristic information, wherein the target guiding sentence includes a missing entity and the characteristic information of the target guiding sentence is related to the user characteristic information;

[0167] Feedback module 5 is used to feed back the target guidance sentence to the target user.

[0168] Specifically, the specific process of each module in the device of the embodiment of the present invention realizing its function can be referred to the relevant description in the method embodiment, which will not be repeated here.

[0169] According to another embodiment of the present application, there is also provided an electronic device, including: Figure 4 As shown, the electronic device may include: a processor 1501 , a communication interface 1502 , a memory 1503 and a communication bus 1504 , wherein the processor 1501 , the communication interface 1502 , and the memory 1503 communicate with each other via the communication bus 1504 .

[0170] Memory 1503, used for storing computer programs;

[0171] The processor 1501 is configured to implement the steps of the above method embodiment when executing the program stored in the memory 1503 .

[0172] The bus mentioned in the electronic device mentioned above may be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus. This bus can be divided into address buses, data buses, control buses, etc. For ease of illustration, only one thick line is used in the figure, but this does not mean that there is only one bus or only one type of bus.

[0173] The communication interface is used for communication between the above electronic device and other devices.

[0174] The memory may include random access memory (RAM) or non-volatile memory (NVM), such as at least one disk storage. Alternatively, the memory may be at least one storage device located away from the processor.

[0175] The above-mentioned processor can be a general-purpose processor, including a central processing unit (CPU), a network processor (NP), etc.; it can also be a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a field-programmable gate array (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, and discrete hardware components.

[0176] An embodiment of the present application further provides a computer-readable storage medium, the storage medium including a stored program, wherein the method steps of the above method embodiment are executed when the program is run.

[0177] It should be noted that, in this document, relational terms such as "first" and "second" are used only to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any actual relationship or order between these entities or operations. Moreover, the terms "comprises," "comprising," or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, article, or device comprising a series of elements includes not only those elements, but also other elements not explicitly listed, or elements inherent to such process, method, article, or device. In the absence of further limitations, an element defined by the phrase "comprising a ..." does not exclude the presence of other identical elements in the process, method, article, or device comprising the element.

[0178] The foregoing description is intended only to provide specific embodiments of the present invention, which will enable those skilled in the art to understand and implement the present invention. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the present invention. Therefore, the present invention is not intended to be limited to the embodiments shown herein, but is intended to be accorded the widest scope consistent with the principles and novel features claimed herein.

Claims

1. A method for guiding user replies, characterized in that: include: Obtain target request information from target users; Determining whether the target request information meets a preset request integrity requirement, wherein the request integrity requirement is used to indicate whether the request information fully expresses the intent; If the target request information does not meet the request completeness requirement, determining missing entities missing from the target request information and user feature information corresponding to the target user, wherein the missing entities are entity content that needs to be added to make the target request information complete, and the user feature information includes at least one target feature type; Based on the missing entity and the user characteristic information, determining a target guiding sentence for guiding the user to reply, wherein the target guiding sentence includes the missing entity and the characteristic information of the target guiding sentence is related to the user characteristic information; Feedback the target guiding sentence to the target user; The determining, based on the missing entity and the user characteristic information, a target guiding sentence for guiding the user to reply includes: Determine a preset target feature matrix, wherein the target feature matrix is ​​used to indicate the importance relationship between different feature types; determine a target feature level corresponding to each target feature type in the user feature information, wherein, for each target feature type, the target feature level corresponding to the target feature type is used to indicate the level corresponding to the target user under the target feature type; Determining the missing feature type of the missing entity by performing feature analysis on the target request information; Determining a candidate guiding sentence matching the target request information according to the missing feature type of the missing entity and the target feature level corresponding to each target feature type; An evaluation value of each candidate guidance sentence is determined according to the target feature matrix, and the candidate guidance sentence with the highest evaluation value is determined as the target guidance sentence.

2. The method according to claim 1, characterized in that Determining whether the target request information meets a preset request integrity requirement includes: Performing entity extraction on the target request information to obtain a target entity included in the target request information; In a case where it is determined that all the target entities include all the designated entities indicated by the request integrity requirement, determining that the target request information meets the request integrity requirement; When it is determined that at least one designated entity is missing from all the target entities, it is determined that the target request information does not meet the request integrity requirement, and the missing entities that are missing from all the target entities are determined from among all the designated entities.

3. The method according to claim 1, characterized in that Determining a preset target feature matrix includes: Determining a candidate importance level corresponding to each of the feature types and a candidate weight matrix composed of all the candidate importance levels; Performing consistency testing on all candidate importance levels and obtaining a test result; When it is determined that the inspection result meets the preset consistency requirement, the candidate weight matrix is ​​determined as the target feature matrix.

4. The method according to claim 1, wherein Determining the target feature level corresponding to each feature type in the user feature information includes: Determining a level division scheme corresponding to each of the feature types, wherein, for each of the feature types, the level division scheme corresponding to the feature type is used to indicate a correspondence between different parameter value ranges and feature levels under the feature type; In the user characteristic information, determining a user parameter value corresponding to each characteristic type; By determining the target feature level corresponding to the user parameter value of each feature type according to the level division scheme corresponding to each feature type, the target feature level corresponding to each feature type is determined, wherein, for each feature type, the parameter value range corresponding to the target feature level includes the user parameter value of the feature type.

5. The method according to claim 1, wherein The determining, according to the entity type of the missing entity and the target feature level corresponding to each target feature type, a candidate guiding sentence matching the target request information includes: Determining a preliminary screening guide sentence including the missing feature type in a preset guide sentence database; According to the target feature level corresponding to each target feature type, a candidate guide sentence matching the target request information is determined from all the preliminary screening guide sentences, wherein, for any target feature type, the feature level corresponding to the target feature type in the candidate guide sentence is equal to the target feature level corresponding to the target feature type in the user feature information.

6. The method according to claim 1, characterized in that Before determining the evaluation value of each candidate guidance sentence according to the target feature matrix and determining the candidate guidance sentence with the highest evaluation value as the target guidance sentence, the method further includes: Determine an intermediate matrix by calculating the geometric mean of the elements in each row of the target feature matrix; Normalizing the intermediate matrix to obtain feature weights corresponding to each feature type; Determining the evaluation value of each candidate guiding sentence according to the target feature matrix includes: Determining a candidate feature level for each feature type in the candidate guidance sentence; Weighting the candidate feature levels of each feature type according to the feature weight corresponding to each feature type to obtain a weighted value for each feature type; All the weighted values ​​are summed to obtain the evaluation value of the candidate guiding sentence.

7. A device for guiding user replies, characterized in that: include: An acquisition module is used to obtain target request information from a target user; A judgment module, configured to judge whether the target request information satisfies a preset request integrity requirement, wherein the request integrity requirement is used to indicate whether the request information fully expresses the intent; a first determining module, configured to determine, when the target request information does not meet the request completeness requirement, missing entities missing from the target request information and user feature information corresponding to the target user, wherein the missing entities are entity content that needs to be added to complete the target request information, and the user feature information includes at least one target feature type; a second determining module, configured to determine, based on the missing entity and the user characteristic information, a target guiding sentence for guiding the user to reply, wherein the target guiding sentence includes the missing entity, and the characteristic information of the target guiding sentence is related to the user characteristic information; A feedback module, configured to feed back the target guiding sentence to the target user; The second determining module is used for: Determine a preset target feature matrix, wherein the target feature matrix is ​​used to indicate the importance relationship between different feature types; determine a target feature level corresponding to each target feature type in the user feature information, wherein, for each target feature type, the target feature level corresponding to the target feature type is used to indicate the level corresponding to the target user under the target feature type; Determining the missing feature type of the missing entity by performing feature analysis on the target request information; Determining a candidate guiding sentence matching the target request information according to the missing feature type of the missing entity and the target feature level corresponding to each target feature type; An evaluation value of each candidate guidance sentence is determined according to the target feature matrix, and the candidate guidance sentence with the highest evaluation value is determined as the target guidance sentence.

8. An electronic device, characterized in that: include: A processor, a communication interface, a memory, and a communication bus, wherein the processor, the communication interface, and the memory communicate with each other via the communication bus; The memory is used to store computer programs; The processor is configured to implement the method according to any one of claims 1 to 6 when executing the computer program.

9. A computer-readable storage medium, characterized in that The storage medium includes a stored program, wherein the program executes the method according to any one of claims 1 to 6 when executed.

Citation Information

Patent Citations

  • Interactive method and apparatus

    CN108881466A

  • Dialogue processing method and device

    CN112735407A