Human resource intelligent reply method and system and storage medium
By generating possible second query statements by the question module and combining the query table and file search of the reply module, accurate reply to the first and second query statements is achieved, solving the problem of low intelligent reply efficiency in the existing technology and improving users Satisfaction.
Patent Information
- Application Number
- CN202411243265.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-05
- Publication Date
- 2024-12-27
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
The prior art can only provide replies to single-question information, and cannot predict and reply to subsequent inquiry statements that users may ask, resulting in low efficiency of intelligent responses and low user satisfaction.
The question module collects the user's first inquiry statement, extracts the inquiry words, and calculates the same degree value as the historical inquiry statement, generates a possible second inquiry statement, and combines the reply module to search for the corresponding reply types and files in the query table and file. , generate and transmit the first and second reply statements to realize the accurate reply to the first and second inquiry statements.
It can not only accurately respond to the user's first inquiry statement, but also predict and accurately reply to possible second inquiry statements, improving the efficiency and user satisfaction of intelligent replies.
Smart Images

Figure CN119201998A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the field of computer application technology, and specifically relates to a human resources intelligent reply method, system and storage medium. Background Art
[0002] The human resources department in an enterprise is usually responsible for answering various questions from the employees, which requires a lot of manpower from the human resources department. Therefore, it is necessary to study a method that can automatically reply to various questions.
[0003] The Chinese patent application with publication number CN104516921A provides an automatic reply method and device, the method comprising: searching for original keywords according to the information to be replied, obtaining a first original keyword matching the keyword of the information to be replied; searching for first mapping information, obtaining a first reply keyword corresponding to the first original keyword; searching for second mapping information, obtaining the category of the first original keyword; searching for third mapping information, obtaining a first sentence pattern corresponding to the category of the first original keyword; and obtaining reply information corresponding to the information to be replied according to the first reply keyword and the first sentence pattern. In addition, the Chinese patent application with publication number CN112084310A discloses a method and device for generating reply information, a method and device for automatically replying information, a reply method based on receiving emails, an automatic reply method based on receiving instant messaging information, a computer storage medium and an electronic device, wherein the generation method comprises: obtaining alternative information representing the reply content and information representing the current received content; within the range of the alternative information representing the reply content, screening the relevant reply alternative information that meets the matching requirements with the information of the current received content; generating reply information that meets the information based on the current received content according to the information representing the current received content and the relevant reply alternative information. However, the above patent applications can only provide response information to the information asked this time. Summary of the invention
[0004] The present invention collects a first inquiry statement of a user, and also generates a second inquiry statement based on the first inquiry statement, which the user may ask next, thereby achieving accurate responses not only to the first inquiry statement, but also to the second inquiry statement. The purpose of the present invention is to improve the efficiency of intelligent responses and enhance user satisfaction.
[0005] In order to achieve the above-mentioned invention object, the present invention provides a human resources intelligent reply method, which mainly includes the following steps:
[0006] S1, collecting a first query statement of a user through the questioning module, and extracting query words in the first query statement, calculating the sameness value between the first query statement and each historical query statement in a first query table stored in advance, determining a historical query statement corresponding to the largest sameness value, locating a next historical query statement based on a historical query order corresponding to the historical query statements, and the questioning module further replaces the historical query words in the next historical query statement with the query words extracted from the first query statement to generate a second query statement;
[0007] S2, the questioning module sends the first query statement and the second query statement to the reply module through the network module, and the reply module searches for the first reply type and the second reply type corresponding to the first query statement and the second query statement in a second query table stored in advance, and the reply module also searches for the first file and the second file corresponding to the first query statement and the second query statement in different pre-stored files;
[0008] S3. The reply module generates a first reply statement from the first file according to the first reply type, and generates a second reply statement from the second file according to the second reply type, and the reply module transmits the first reply statement and the second reply statement back to the questioning module through the network module, and the questioning module displays the first reply statement and the second reply statement to the user.
[0009] As a preferred technical solution of the present invention, each data record in the first query table includes: historical inquiry statements, historical reply statements, historical inquiry words, and historical inquiry order, wherein the historical inquiry order is a positive integer, and users submit corresponding historical inquiry statements in order from small to large according to the historical inquiry order; each data record in the second query table includes: inquiry statement type, and reply type.
[0010] As a preferred technical solution of the present invention, the reply module searches for a first file corresponding to the first query statement in different pre-stored files, including the following steps:
[0011] S211, the reply module generates a representative amount of the first query statement, and at the same time generates representative amounts of different files respectively, and for each file, the reply module calculates a similarity value between the representative amount of the file and the representative amount of the first query statement;
[0012] S212, the reply module performs category classification processing on different files based on the representative amounts of different files, and classifies different files into a plurality of file categories, and the reply module further classifies the first query statement into different file categories by performing the category classification processing;
[0013] S213, for each file, the reply module uses the formula Fe(m,n)=A based on different feature values set for the combination of files and file categories stored in advance. m *B m,n Calculate the feature value of the file, where m is the serial number of the file category to which the first query statement is classified, n is the file number, Fe(m,n) is the feature value of the file numbered n in the file category with serial number m, A m To classify the first query statement into the credibility value of the file category with sequence number m, B m,n is the characteristic value of the file numbered n in the file category numbered m;
[0014] S214, the reply module calculates the credit value of each data record in the third query table stored in advance, locates a number of data records whose credit value is greater than a preset credit value threshold 1, and for each file category to which the first query statement is classified, calculates the credit value of each data record in the third query table stored in advance, locates a number of data records whose credit value is greater than a preset credit value threshold 1, and calculates the credit value of each data record in the third query table stored in advance .... Calculate the credit value of the file category, where C m is the credit value of the file category with serial number m, E m is the total number of specific data records whose file numbers are the same as the file numbers corresponding to the file category with the sequence number m and whose past query statements are similar to the first query statement, D m The total number of specific data records for which the included file identifier is valid.
[0015] As a preferred technical solution of the present invention, the reply module searches for the first file corresponding to the first query statement in different pre-stored files, and further includes the following steps:
[0016] S221, the reply module is in C m If the credit value is greater than or equal to the preset credit value threshold 2, the formula H m =h m Calculate the first weight, where H m is the first weight corresponding to the file category with sequence number m, h m The key value of the file category with the preset sequence number m is one, and the reply module is in C m If the credit value is less than the preset credit value threshold value 2, the formula 4 H m =h m (PC m ) calculating a first weight, wherein P is a preset credit value threshold value 2;
[0017] S222, the reply module uses formula 5 S m =C m *Vm Calculate the second weight, where S m is the second weight corresponding to the file category with sequence number m, V m The key value 2 of the file category whose serial number is preset to be m;
[0018] S223. For each file, the reply module calculates the key value of the file by formula 6. Formula 6 is: Among them, Ma(n) is the key value of the file numbered n, U n is the value of the degree of similarity between the representative amount of the document numbered n and the representative amount of the first query statement;
[0019] S224, the reply module sorts different files in descending order according to the key values of the corresponding files, and selects a preset number of files that are ranked first.
[0020] As a preferred technical solution of the present invention, each data record in the third query table includes: a historical search sequence number, a file number, a file sequence number, a file identifier, and a past query statement, wherein the file identifier is used to mark whether the file is valid.
[0021] As a preferred technical solution of the present invention, the reply module calculates the credit value of each data record in the third query table stored in advance, including: using the data volume of the file corresponding to the file number contained in the data record divided by the time of generating a reply statement from the file corresponding to the file number contained in the data record.
[0022] As a preferred technical solution of the present invention, the reply module calculates the credit value of each data record in the third query table stored in advance, including: calculating the reciprocal of the file sequence number contained in the data record.
[0023] The present invention also provides a human resources intelligent reply system, comprising the following modules:
[0024] a questioning module, configured to collect a first query statement of a user, extract query words in the first query statement, calculate a similarity value between the first query statement and each historical query statement in a first query table stored in advance, determine a historical query statement corresponding to the largest similarity value, locate a next historical query statement based on a historical query order corresponding to the historical query statement, replace the historical query words in the next historical query statement with the query words extracted from the first query statement to generate a second query statement, and to send the first query statement and the second query statement to a reply module, and further to display the first reply statement and the second reply statement to the user;
[0025] A network module, used to send the first inquiry statement and the second inquiry statement from the questioning module to the replying module, and to transmit the first reply statement and the second reply statement from the replying module to the questioning module;
[0026] A reply module is used to search for a first reply type and a second reply type corresponding to a first query statement and a second query statement in a second query table stored in advance, and to search for a first file and a second file corresponding to the first query statement and the second query statement in different pre-stored files; and to generate a first reply statement from the first file according to the first reply type, and to generate a second reply statement from the second file according to the second reply type.
[0027] The present invention also provides a storage medium, wherein the storage medium stores program instructions, wherein when the program instructions are executed, the device where the storage medium is located is controlled to execute any one of the above methods.
[0028] Compared with the prior art, the beneficial effects of the present invention are at least as follows:
[0029] In the present invention, firstly, a question module collects a user's first query statement, extracts query words in the first query statement, calculates the sameness value between the first query statement and each historical query statement in the first query table, determines the historical query statement corresponding to the largest sameness value, locates the next historical query statement based on the historical query order corresponding to the historical query statement, and the question module also replaces the historical query words in the next historical query statement with the query words extracted from the first query statement to generate a second query statement; secondly, the reply module searches the second query table for the first reply type and the second reply type corresponding to the first query statement and the second query statement, respectively, and the reply module also searches different files for the first file and the second file corresponding to the first query statement and the second query statement, respectively; finally, the reply module generates a first reply statement from the first file according to the first reply type, and generates a second reply statement from the second file according to the second reply type, and the reply module transmits the first reply statement and the second reply statement back to the question module, and the question module displays the first reply statement and the second reply statement to the user. The present invention can not only accurately reply to the first query statement raised by the user, but also estimate the second query statement that the user may raise based on the first query statement raised by the user, and accurately reply to the second query statement, and can also improve the efficiency of intelligent reply and improve user satisfaction. BRIEF DESCRIPTION OF THE DRAWINGS
[0030] Figure 1 A flowchart of the steps of a human resources intelligent reply method of the present invention;
[0031] Figure 2The present invention is a structural diagram of a human resources intelligent response system. DETAILED DESCRIPTION
[0032] In order to make the purpose, technical solution and advantages of the present invention more clearly understood, the present invention is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present invention and are not intended to limit the present invention.
[0033] It is understood that the terms "first", "second", etc. used in this application may be used herein to describe various elements, but unless otherwise specified, these elements are not limited by these terms. These terms are only used to distinguish a first element from another element. For example, without departing from the scope of this application, a first xx script may be referred to as a second xx script, and similarly, a second xx script may be referred to as a first xx script.
[0034] The present invention provides Figure 1 The human resources intelligent reply method shown is mainly implemented by executing the following steps:
[0035] S1. Collecting a first query statement of a user through a questioning module, and extracting query words in the first query statement, calculating the sameness value between the first query statement and each historical query statement in a first query table stored in advance, determining a historical query statement corresponding to the largest sameness value, locating a next historical query statement based on a historical query order corresponding to the historical query statements, and the questioning module also replaces the historical query words in the next historical query statement with the query words extracted from the first query statement to generate a second query statement;
[0036] S2, the questioning module sends the first query statement and the second query statement to the reply module through the network module, and the reply module searches for the first reply type and the second reply type corresponding to the first query statement and the second query statement in the second query table stored in advance, and the reply module also searches for the first file and the second file corresponding to the first query statement and the second query statement in different pre-stored files;
[0037] S3. The reply module generates a first reply statement from the first file according to the first reply type, and generates a second reply statement from the second file according to the second reply type. The reply module transmits the first reply statement and the second reply statement back to the questioning module through the network module, and the questioning module displays the first reply statement and the second reply statement to the user.
[0038] Specifically, in step S1, the user inputs a first query statement in the questioning module, and the questioning module extracts query words in the first query statement. The query words refer to keywords that constitute the first query statement. For example, if the first query statement is "Who is the person in charge of the R&D department", then "R&D department" can be used as a query word, and the questioning module calculates the same degree value between the first query statement and each historical query statement in the first query table. Specifically, the first query statement and the historical query statement can be vectorized to obtain the feature vectors of the two, and then the similarity between the two is calculated. The first query table will be described below. Thereafter, the questioning module determines the historical query statement corresponding to the largest same degree value, locates the next historical query statement according to the historical query order corresponding to the historical query statement, and the questioning module replaces the historical query words in the next historical query statement with the query words extracted from the first query statement to generate a second query statement. For example, if the next historical query statement is "What is the department budget of the information management department in 2024", then "R&D department" is used to replace "information management department" to obtain the second query statement as "What is the department budget of the R&D department in 2024". In step S2, the questioning module sends the first query statement and the second query statement to the reply module through the network module. The reply module searches for the first reply type and the second reply type corresponding to the first query statement and the second query statement in the second query table, respectively. The second query table will be described below. Then the reply module searches for the first file and the second file corresponding to the first query statement and the second query statement in different files stored in advance, respectively. The specific search process will be described below, wherein the different files contain all the information required to reply to the query statement. It should be noted that the number of the first file and the second file found can be one or more. In step S3, the reply module generates a first reply statement from the first file according to the first reply type, and generates a second reply statement from the second file according to the second reply type. For example, if the first reply type corresponding to the first query statement "Who is the person in charge of the R&D department" is name, then the reply module extracts the name from the first file to generate the first reply statement. The reply module also transmits the first reply statement and the second reply statement back to the questioning module through the network module. The questioning module displays the first reply statement and the second reply statement to the user. It should be noted that if the number of the first file and the second file is multiple, then the number of the first reply statement and the second reply statement is also multiple. Through the above method, not only can a reply be made to the first query statement raised by the user, but also a second query statement that the user may raise can be estimated based on the first query statement raised by the user, and a reply can be made to the second query statement. The above method can improve the efficiency of intelligent replies.
[0039] Furthermore, each data record in the first query table includes: a historical inquiry statement, a historical reply statement, a historical inquiry word, and a historical inquiry order, wherein the historical inquiry order is a positive integer, and the user raises corresponding historical inquiry statements in order from small to large according to the historical inquiry order.
[0040] Specifically, the first query table includes multiple data records, each data record contains historical query statements, historical reply statements, historical query words, and historical query orders. Historical query statements refer to query statements that users have input into the question module in the past, historical reply statements refer to reply statements to historical query statements, historical query words refer to keywords that constitute historical query statements, and historical query orders refer to the order in which users input historical query statements into the question module, which is set to a positive integer greater than or equal to 1. For ease of understanding, for example, the first query table contains two data records, the first data record is "Who is the person in charge of the information management department, Zhang San, information management department, 1", and the second data record is "What is the department budget of the information management department in 2024, 500,000, information management department, 2".
[0041] Furthermore, each data record in the second query table includes: a query statement type, and a response type.
[0042] Specifically, the second query table includes multiple data records, each data record contains the query statement type and the reply type, wherein the query statement type is set in advance. For ease of understanding, for example, the second query table includes three data records, the first data record is "the query statement contains who, name", the second data record is "the query statement contains how much, value", and the third data record is "the query statement contains when, time".
[0043] Furthermore, the reply module searches for a first file corresponding to the first query statement in different pre-stored files, including the following steps:
[0044] S211, the reply module generates a representative amount of the first query statement, and at the same time generates representative amounts of different files respectively, and for each file, the reply module calculates a similarity value between the representative amount of the file and the representative amount of the first query statement;
[0045] S212, based on the representative amounts of different files, the reply module performs a category classification process on different files, and classifies the different files into a plurality of file categories, and the reply module further classifies the first query statement into different file categories by performing the category classification process;
[0046] S213: For each file, the reply module uses the formula Fe(m,n)=A based on different feature values set for the combination of files and file categories stored in advance. m *B m,n Calculate the feature value of the file, where m is the serial number of the file category to which the first query statement is classified, n is the file number, Fe(m,n) is the feature value of the file numbered n in the file category with serial number m, A m To classify the first query statement into the credibility value of the file category with sequence number m, B m,n is the characteristic value of the file numbered n in the file category numbered m;
[0047] S214, the reply module calculates the credit value of each data record in the third query table stored in advance, locates a number of data records whose credit value is greater than a preset credit value threshold 1, and for each file category to which the first query statement is classified, calculates the credit value of each data record in the third query table stored in advance, locates a number of data records whose credit value is greater than a preset credit value threshold 1, and calculates the credit value of each data record in the third query table stored in advance ... Calculate the credit value of the file category, where C m is the credit value of the file category with serial number m, E m is the total number of specific data records whose file numbers are the same as the file numbers corresponding to the file category with the sequence number m and whose past query statements are similar to the first query statement, D m The total number of specific data records for which the included file identifier is valid.
[0048] Specifically, the process of the reply module searching for the first file corresponding to the first query statement in different files is introduced here. The process of the reply module searching for the second file corresponding to the second query statement in different files is the same as the process, so it is not repeated here. In step S211, the reply module generates the representative amount of the first query statement and the representative amount of different files. The generation process can be specifically vectorized for the first query statement and different files, and the corresponding feature vectors, that is, the corresponding representative amount, are obtained respectively, so that the reply module can respectively calculate the same degree value between the representative amount of different files and the representative amount of the first query statement, that is, the similarity between the two feature vectors. In step S212, based on the representative amount of different files, the reply module performs category division processing for different files. The category division processing can specifically adopt the clustering algorithm in the prior art, so that different files are divided into several file categories respectively. A file can belong to multiple file categories at the same time. Then the reply module also divides the first query statement into different file categories by performing category division processing. The first query statement can also belong to multiple file categories at the same time. Before executing step S213, the reply module stores different feature values set for the combination of files and file categories in advance, that is, the feature values of each file in different file categories are stored. The larger the feature value, the better the performance of the file. In step S213, for each file, the reply module relies on formula 1: Fe(m,n)=A m *B m,n Calculate the feature value of the file. It should be noted that the file here refers to the file in the file category to which the first query statement is classified. In Formula 1, m is the serial number of the file category to which the first query statement is classified. For example, if there are three file categories to which the first query statement is classified, then m may be 1, 2, or 3. n is the file number, and the file number can uniquely identify a file. Fe(m,n) is the feature value of the file with serial number n in the file category with serial number m. A m The credibility value of classifying the first query statement into the file category with the serial number m is obtained. The greater the credibility value, the more reliable it is to classify the first query statement into the file category with the serial number m. The credibility value can be obtained by the existing technology and will not be repeated here. m,n is the characteristic value of the file numbered n in the file category numbered m. In step S214, the reply module calculates the credit value of each data record in the third query table. The third query table and the method for calculating the credit value will be described below. A number of data records whose credit values are greater than a preset credit value threshold 1 are retrieved. On this basis, the reply module calculates the credit value of each file category to which the first query statement is classified by formula 2: Calculate the credit value of the file category. In formula 2, C mis the credit value of the file category with serial number m, E m is the total number of specific data records, where a specific data record refers to a data record containing a file number that is the same as the file number corresponding to the file category with sequence number m and containing the same past query statement as the first query statement. m The total number of specific data records for which the included file identifier is valid.
[0049] Furthermore, the reply module searches for a first file corresponding to the first query statement in different pre-stored files, and further includes the following steps:
[0050] S221, reply module in C m If the credit value is greater than or equal to the preset credit value threshold 2, the formula H m =h m Calculate the first weight, where H m is the first weight corresponding to the file category with sequence number m, h m The default sequence number is m, the key value of the file category is one, and the reply module is in C m If the credit value is less than the preset credit value threshold value 2, the formula 4 H m =h m (PC m ) calculating a first weight, wherein P is a preset credit value threshold value 2;
[0051] S222, the reply module is through formula 5S m =C m *V m Calculate the second weight, where S m is the second weight corresponding to the file category with sequence number m, V m The key value 2 of the file category whose serial number is preset to be m;
[0052] S223. For each file, the reply module calculates the key value of the file using Formula 6. Formula 6 is: Among them, Ma(n) is the key value of the file numbered n, U n is the value of the degree of similarity between the representative amount of the document numbered n and the representative amount of the first query statement;
[0053] S224. The reply module sorts the different files in descending order according to the key values of the corresponding files, and selects a preset number of files that are ranked first.
[0054] Specifically, following the above step S214, the process of the reply module searching for the first file corresponding to the first query statement in different files is further described. In step S221, for each file category to which the first query statement is classified, the reply module searches for the first file corresponding to the first query statement in Cm If the credit value is greater than or equal to the preset credit value threshold 2, the formula 3 is used: H m =h m Calculate the first weight. In formula 3, H m is the first weight corresponding to the file category with sequence number m, h m The key value of the file category whose serial number is m is 1, and the reply module is in C m When the credit value is less than the preset credit value threshold 2, the formula 4 is used: H m =h m (PC m ) calculates the first weight, where P is the preset credit value threshold 2, H m ,h m , and C m This has been introduced above and will not be repeated here. In step S222, for each file category to which the first query statement is classified, the reply module uses formula 5: S m =C m *V m Calculate the second weight. In formula 5, S m is the second weight corresponding to the file category with sequence number m, V m The key value 2 of the file category whose serial number is preset to be m. It should be noted that in this embodiment, h is set m and V m So that when C m When it is larger, Fe(m,n) is more important. m When it is smaller, more attention is paid to U n In step S223, for each file, the reply module uses formula 6: Calculate the key value of the file. It should be noted that the file here refers to the file in the file category to which the first query statement is classified. In Formula 6, Ma(n) is the key value of the file numbered n, and U n is the similarity value between the representative amount of the document numbered n and the representative amount of the first query sentence, Fe(m,n), S m , H m , and A m This has been introduced above and will not be repeated here. In step S224, the reply module sorts different files in descending order according to the key values of the corresponding files, and selects a preset number of files with the highest order, thereby obtaining a preset number of first files. Through the above method, the key value of each file in the different file categories to which the first query statement is divided can be reasonably evaluated, thereby determining the file suitable for generating the reply statement, and ensuring the accuracy of the reply statement.
[0055] Furthermore, each data record in the third query table includes: a historical search sequence number, a file number, a file sequence number, a file identifier, and a past query statement, wherein the file identifier is used to mark whether the file is valid.
[0056] Specifically, the third query table includes multiple data records, and the content of each data record includes a historical search sequence number, a file number, a file sequence number, a file identifier, and a past query statement. The historical search sequence number refers to the order of search processing performed by the reply module in the past. The search processing refers to the processing of searching for files used to generate reply statements from different files. The file number refers to the number of the file found by the reply module when performing the search processing corresponding to the historical search sequence number. Multiple files can be found in one search processing. The file sequence number refers to the order of files found by the reply module when performing the search processing corresponding to the historical search sequence number. The file identifier is used to mark whether the file is valid. If the reply statement generated from the file is recognized by the user, then the file is determined to be valid. Otherwise, the file is determined to be invalid. The past query statement refers to the query statement sent from the questioning module when the reply module performs the search processing corresponding to the historical search sequence number. For ease of understanding, for example, the third query table includes two data records, the first data record is "1, A, 1, invalid, who is the person in charge of the R&D department", and the second data record is "1, B, 2, valid, who is the person in charge of the R&D department".
[0057] Further, the reply module calculates the credit value of each data record in the third query table stored in advance, including: using the data volume of the file corresponding to the file number contained in the data record divided by the time of generating the reply statement from the file corresponding to the file number contained in the data record;
[0058] Furthermore, the reply module calculating the credit value of each data record in the third query table stored in advance further includes: calculating the reciprocal of the file sequence number included in the data record.
[0059] Specifically, two methods are introduced here for the reply module to calculate the credit value of each data record in the third query table stored in advance. Method 1 is to use the data amount of the file corresponding to the file number contained in the data record divided by the time to generate a reply statement from the file corresponding to the file number contained in the data record. Method 2 is to calculate the inverse of the file sequence number contained in the data record.
[0060] According to another aspect of the embodiment of the present invention, Figure 2 As shown, a human resources intelligent reply system is also provided, including a question module, a network module, and a reply module, which is used to implement a human resources intelligent reply method as described above. The functions of each module are as follows:
[0061] a questioning module, configured to collect a first query statement of a user, extract query words in the first query statement, calculate a similarity value between the first query statement and each historical query statement in a first query table stored in advance, determine a historical query statement corresponding to the largest similarity value, locate a next historical query statement based on a historical query order corresponding to the historical query statement, replace the historical query words in the next historical query statement with the query words extracted from the first query statement to generate a second query statement, and to send the first query statement and the second query statement to a reply module, and further to display the first reply statement and the second reply statement to the user;
[0062] A network module, used to send the first inquiry statement and the second inquiry statement from the questioning module to the replying module, and to transmit the first reply statement and the second reply statement from the replying module to the questioning module;
[0063] A reply module is used to search for a first reply type and a second reply type corresponding to a first query statement and a second query statement in a second query table stored in advance, and to search for a first file and a second file corresponding to the first query statement and the second query statement in different pre-stored files; and to generate a first reply statement from the first file according to the first reply type, and to generate a second reply statement from the second file according to the second reply type.
[0064] In summary, in the present invention, first, the user's first query statement is collected through the questioning module, the query words in the first query statement are extracted, and the same degree value between the first query statement and each historical query statement in the first query table is calculated, the historical query statement corresponding to the maximum same degree value is determined, and the next historical query statement is located based on the historical query order corresponding to the historical query statement. The questioning module also replaces the historical query words in the next historical query statement with the query words extracted from the first query statement to generate a second query statement; secondly, the reply module searches for the first reply type and the second reply type corresponding to the first query statement and the second query statement in the second query table respectively, and the reply module also searches for the first file and the second file corresponding to the first query statement and the second query statement in different files respectively; finally, the reply module generates a first reply statement from the first file according to the first reply type, and generates a second reply statement from the second file according to the second reply type, and the reply module transmits the first reply statement and the second reply statement back to the questioning module, and the questioning module displays the first reply statement and the second reply statement to the user. The present invention can not only accurately reply to the first query statement raised by the user, but also estimate the second query statement that the user may raise based on the first query statement raised by the user, and accurately reply to the second query statement, and can also improve the efficiency of intelligent reply and improve user satisfaction.
[0065] According to another aspect of an embodiment of the present invention, a storage medium is provided, wherein the storage medium stores program instructions, wherein when the program instructions are executed, a device where the storage medium is located is controlled to execute any one of the above methods.
[0066] It should be understood that, although each step in the flow chart of each embodiment of the present invention is shown in sequence according to the indication of the arrow, these steps are not necessarily performed in sequence according to the order indicated by the arrow. Unless there is a clear explanation in this article, the execution of these steps does not have a strict order restriction, and these steps can be performed in other orders. Moreover, at least a portion of the steps in each embodiment may include a plurality of sub-steps or a plurality of stages, and these sub-steps or stages are not necessarily performed at the same time, but can be performed at different times, and the execution order of these sub-steps or stages is not necessarily performed in sequence, but can be performed in turn or alternately with at least a portion of other steps or sub-steps or stages of other steps.
[0067] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program. The above-mentioned program can be stored in a non-volatile computer-readable storage medium. When the program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media used in the embodiments provided in this application can include non-volatile and / or volatile memory. Non-volatile memory may include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM) or flash memory. Volatile memory may include random access memory (RAM) or external cache memory. As an illustration and not limitation, RAM is available in various forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link (Synchlink) DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM).
[0068] The technical features of the above-mentioned embodiments can be combined arbitrarily. In order to make the description concise, not all possible combinations of the technical features in the above-mentioned embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0069] The above-mentioned embodiments only express several implementation methods of the present invention, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the patent of the present invention. It should be pointed out that, for ordinary technicians in this field, several variations and improvements can be made without departing from the concept of the present invention, and these all belong to the protection scope of the present invention. Therefore, the protection scope of the patent of the present invention shall be subject to the attached claims.
[0070] The above are only preferred embodiments of the present invention and are not intended to limit the present invention. Any modifications, equivalent substitutions and improvements made within the spirit and principles of the present invention should be included in the protection scope of the present invention.
Claims
1. A human resources intelligent reply method, applied to a human resources intelligent reply system, the system includes a questioning module, a network module, and a reply module, characterized in that: The method comprises the following steps: S1, collecting a first query statement of a user through the questioning module, and extracting query words in the first query statement, calculating the sameness value between the first query statement and each historical query statement in a first query table stored in advance, determining a historical query statement corresponding to the largest sameness value, locating a next historical query statement based on a historical query order corresponding to the historical query statements, and the questioning module further replaces the historical query words in the next historical query statement with the query words extracted from the first query statement to generate a second query statement; S2, the questioning module sends the first query statement and the second query statement to the reply module through the network module, and the reply module searches for the first reply type and the second reply type corresponding to the first query statement and the second query statement in a second query table stored in advance, and the reply module also searches for the first file and the second file corresponding to the first query statement and the second query statement in different pre-stored files; S3. The reply module generates a first reply statement from the first file according to the first reply type, and generates a second reply statement from the second file according to the second reply type, and the reply module transmits the first reply statement and the second reply statement back to the questioning module through the network module, and the questioning module displays the first reply statement and the second reply statement to the user.
2. The method according to claim 1, characterized in that Each data record in the first query table includes: historical inquiry statements, historical reply statements, historical inquiry words, and historical inquiry order, wherein the historical inquiry order is a positive integer, and users submit corresponding historical inquiry statements in order from small to large according to the historical inquiry order; each data record in the second query table includes: inquiry statement type, and reply type.
3. The method according to claim 1, characterized in that The reply module searches for a first file corresponding to the first query statement in different pre-stored files, including the following steps: S211, the reply module generates a representative amount of the first query statement, and at the same time generates representative amounts of different files respectively, and for each file, the reply module calculates a similarity value between the representative amount of the file and the representative amount of the first query statement; S212, the reply module performs category classification processing on different files based on the representative amounts of different files, and classifies different files into a plurality of file categories, and the reply module further classifies the first query statement into different file categories by performing the category classification processing; S213, for each file, the reply module uses the formula Fe(m,n)=A based on different feature values set for the combination of files and file categories stored in advance. m *B m,n Calculate the feature value of the file, where m is the serial number of the file category to which the first query statement is classified, n is the file number, Fe(m,n) is the feature value of the file numbered n in the file category with serial number m, A m To classify the first query statement into the credibility value of the file category with sequence number m, B m,n is the characteristic value of the file numbered n in the file category numbered m; S214, the reply module calculates the credit value of each data record in the third query table stored in advance, locates a number of data records whose credit value is greater than a preset credit value threshold 1, and for each file category to which the first query statement is classified, calculates the credit value of each data record in the third query table stored in advance, locates a number of data records whose credit value is greater than a preset credit value threshold 1, and calculates the credit value of each data record in the third query table stored in advance .... Calculate the credit value of the file category, where C m is the credit value of the file category with serial number m, E m is the total number of specific data records whose file numbers are the same as the file numbers corresponding to the file category with the sequence number m and whose past query statements are similar to the first query statement, D m The total number of specific data records for which the included file identifier is valid.
4. The method according to claim 3, characterized in that The reply module searches for a first file corresponding to the first query statement in different pre-stored files, and further includes the following steps: S221, the reply module is in C m If the credit value is greater than or equal to the preset credit value threshold 2, the formula H m =h m Calculate the first weight, where H m is the first weight corresponding to the file category with sequence number m, h m The key value of the file category with the preset sequence number m is one, and the reply module is in C m If the credit value is less than the preset credit value threshold value 2, the formula 4 H m =h m (PC m ) calculating a first weight, wherein P is a preset credit value threshold value 2; S222, the reply module uses formula 5 S m =C m *V m Calculate the second weight, where S m is the second weight corresponding to the file category with sequence number m, V m The key value 2 of the file category whose serial number is preset to be m; S223. For each file, the reply module calculates the key value of the file by formula 6. Formula 6 is: Among them, Ma(n) is the key value of the file numbered n, U n is the value of the degree of similarity between the representative amount of the document numbered n and the representative amount of the first query statement; S224, the reply module sorts different files in descending order according to the key values of the corresponding files, and selects a preset number of files that are ranked first.
5. The method according to claim 4, characterized in that Each data record in the third query table includes: a historical search sequence number, a file number, a file sequence number, a file identifier, and a past query statement, wherein the file identifier is used to mark whether the file is valid.
6. The method according to claim 4, characterized in that The reply module calculates the credit value of each data record in the third query table stored in advance by dividing the data volume of the file corresponding to the file number contained in the data record by the time of generating the reply statement from the file corresponding to the file number contained in the data record.
7. The method according to claim 4, characterized in that The reply module calculates the credit value of each data record in the third query table stored in advance, including: calculating the reciprocal of the file sequence number included in the data record.
8. A human resources intelligent reply system, used to implement the method according to any one of claims 1 to 7, characterized in that: Includes the following modules: a questioning module, configured to collect a first query statement of a user, extract query words in the first query statement, calculate a similarity value between the first query statement and each historical query statement in a first query table stored in advance, determine a historical query statement corresponding to the largest similarity value, locate a next historical query statement based on a historical query order corresponding to the historical query statement, replace the historical query words in the next historical query statement with the query words extracted from the first query statement to generate a second query statement, and to send the first query statement and the second query statement to a reply module, and further to display the first reply statement and the second reply statement to the user; A network module, used to send the first inquiry statement and the second inquiry statement from the questioning module to the replying module, and to transmit the first reply statement and the second reply statement from the replying module to the questioning module; A reply module, used to search for a first reply type and a second reply type corresponding to the first query statement and the second query statement in a pre-stored second query table, and to search for a first file and a second file corresponding to the first query statement and the second query statement in different pre-stored files; And it is used to generate a first reply statement from a first file according to a first reply type, and to generate a second reply statement from a second file according to a second reply type.
9. A storage medium, characterized in that: The storage medium stores program instructions, wherein when the program instructions are executed, the device where the storage medium is located is controlled to execute the method according to any one of claims 1 to 7.
Citation Information
Patent Citations
Automatic response method and device
CN104516921A
Reply message generation method and device, automatic reply method and device
CN112084310A
