CN104516921A - Automatic response method and device - Google Patents

Automatic response method and device Download PDF

Info

Publication number
CN104516921A
CN104516921A CN201310464118.5A CN201310464118A CN104516921A CN 104516921 A CN104516921 A CN 104516921A CN 201310464118 A CN201310464118 A CN 201310464118A CN 104516921 A CN104516921 A CN 104516921A
Authority
CN
China
Prior art keywords
information
classification
primary keys
return information
return
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN201310464118.5A
Other languages
Chinese (zh)
Other versions
CN104516921B (en
Inventor
张�杰
张轶博
李航
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Huawei Technologies Co Ltd
Original Assignee
Huawei Technologies Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Huawei Technologies Co Ltd filed Critical Huawei Technologies Co Ltd
Priority to CN201310464118.5A priority Critical patent/CN104516921B/en
Priority to PCT/CN2014/083701 priority patent/WO2015043318A1/en
Publication of CN104516921A publication Critical patent/CN104516921A/en
Application granted granted Critical
Publication of CN104516921B publication Critical patent/CN104516921B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/903Querying
    • G06F16/9032Query formulation
    • G06F16/90332Natural language query formulation or dialogue systems
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/30Information retrieval; Database structures therefor; File system structures therefor of unstructured textual data
    • G06F16/33Querying
    • G06F16/3331Query processing
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F40/00Handling natural language data
    • G06F40/30Semantic analysis

Abstract

The invention provides an automatic response method and device. The method includes that according to to-be-responded information, original key words are searched to obtain a first original key word which is matched with a key word of the to-be-responded information; first mapping information is searched to obtain a first response key word which the first original key word corresponds to; second mapping information is searched to obtain the category of the first original key word; third mapping information is searched to obtain a first sentence pattern that the category of the first original key word corresponds to; response information that the to-be-responded information corresponds to is obtained according to the first response key word and the first sentence pattern. By means of the automatic response method and device, reliability of automatic response can be effectively improved.

Description

Automatic reply method and device
Technical field
The present invention relates to computer realm, particularly relate to a kind of automatic reply method and device.
Background technology
At present, automatically replying in user's chat process can be realized by natural language generation system.This technology effectively can save the time that user edits return information.Concrete, the existing scheme of automatically replying is, receive after return information, in the corpus set up in advance, search and treat with described the original sentence that return information mates, and the reply sentence using this original sentence corresponding treats as described the return information that return information is corresponding, wherein, described corpus comprises multiple original sentence and the reply sentence corresponding respectively with described multiple original sentence.
Automatically reply in scheme above-mentioned, can realize automatically replying and depend in corpus whether to exist and treat with described the original sentence that return information mates, that is, can realize automatically replying, depend on the quantity of original sentence in corpus to a great extent, and the scale of corpus is normally limited, this just limits the realization automatically replied to a certain extent, causes the reliability automatically replied to reduce.
Summary of the invention
The invention provides a kind of automatic reply method and device, for solving the not high problem of the existing reliability automatically replying scheme.
First aspect, the invention provides a kind of automatic reply method, comprising: treat return information according to what receive, search the primary keys of raw information in history chat record, obtains and described the first primary keys treating the Keywords matching of return information; Search the first map information, described first map information comprises described primary keys and reply keyword corresponding to described primary keys, obtain described first primary keys corresponding first reply keyword; Search the second map information, described second map information comprises the classification of described primary keys and described primary keys, obtains the classification of described first primary keys; Search the 3rd map information, described 3rd map information comprises clause corresponding to the classification of the classification of described primary keys and described primary keys, obtains the first clause that the classification of described first primary keys is corresponding; Reply keyword and described first clause according to described first, described in acquisition, treat the return information that return information is corresponding.
According to first aspect, in the first embodiment of first aspect, described search the first map information before, also comprise: for each raw information in described history chat record, by the keyword of return information corresponding for described raw information, the reply keyword that the primary keys as described raw information is corresponding; By described primary keys, and reply keyword corresponding to described primary keys is stored to described first map information.
According to the first embodiment of first aspect or first aspect, in the second embodiment of first aspect, described search the second map information before, also comprise: according to the keyword of return information corresponding to raw information in described history chat record, obtained the classification of the keyword of return information corresponding to described raw information by cluster; For each raw information in described history chat record, by the classification of the keyword of return information corresponding for described raw information, as the classification of the primary keys of described raw information; By described primary keys, and the classification of described primary keys is stored to described second map information.
According to one of first two embodiment of first aspect or first aspect, in the third embodiment of first aspect, described search the 3rd map information before, also comprise: for the classification of often kind of primary keys, obtain the return information that described classification is corresponding, return information corresponding to described classification comprises, the return information corresponding with the raw information of classification belonging to the primary keys of described classification; If the number of the return information that described classification is corresponding is one, then using the clause of return information corresponding for described classification as clause corresponding to described classification; If the number of the return information that described classification is corresponding is multiple, then using in the clause of return information corresponding for described classification by the maximum clause of access times as clause corresponding to described classification; By described classification and clause corresponding to described classification, be stored to described 3rd map information.
One of embodiment is planted according to first three of first aspect or first aspect, in the 4th kind of embodiment of first aspect, what described basis received treats return information, search the primary keys of the raw information in history chat record, obtain and described the first primary keys treating the Keywords matching of return information, comprise: treat return information according to described, search the corpus set up in advance, described corpus comprises multiple original sentence and reply sentence corresponding to described multiple original sentence; Treat with described the original sentence that return information mates if do not exist in described multiple original sentence, then treat return information described in basis, search the primary keys of the raw information in history chat record, obtain and described the first primary keys treating the Keywords matching of return information.
Second aspect, the invention provides one and automatically reply device, comprising: first searches module, for treating return information according to what receive, search the primary keys of raw information in history chat record, obtain and described the first primary keys treating the Keywords matching of return information; Second searches module, and for searching the first map information, described first map information comprises described primary keys and reply keyword corresponding to described primary keys, obtain described first primary keys corresponding first reply keyword; 3rd searches module, and for searching the second map information, described second map information comprises the classification of described primary keys and described primary keys, obtains the classification of described first primary keys; 4th searches module, and for searching the 3rd map information, described 3rd map information comprises clause corresponding to the classification of the classification of described primary keys and described primary keys, obtains the first clause that the classification of described first primary keys is corresponding; Processing module, for replying keyword and described first clause according to described first, treats the return information that return information is corresponding described in acquisition.
According to second aspect, in the first embodiment of second aspect, described device also comprises: the first acquisition module, for described search the first map information before, for each raw information in described history chat record, by the keyword of return information corresponding for described raw information, the reply keyword that the primary keys as described raw information is corresponding; First memory module, for by described primary keys, and reply keyword corresponding to described primary keys is stored to described first map information.
According to the first embodiment of second aspect or second aspect, in the second embodiment of second aspect, described device also comprises: the second acquisition module, for before searching the second map information, according to the keyword of return information corresponding to raw information in described history chat record, obtained the classification of the keyword of return information corresponding to described raw information by cluster; Described second acquisition module, also for for each raw information in described history chat record, by the classification of the keyword of return information corresponding for described raw information, as the classification of the primary keys of described raw information; Second memory module, for by described primary keys, and the classification of described primary keys is stored to described second map information.
According to one of first two embodiment of second aspect or second aspect, in the third embodiment of second aspect, described device also comprises: the 3rd acquisition module, for before searching the 3rd map information, for the classification of often kind of primary keys, obtain the return information that described classification is corresponding, return information corresponding to described classification comprises, the return information corresponding with the raw information of classification belonging to the primary keys of described classification; Described 3rd acquisition module, if be also one for the number of return information corresponding to described classification, then using the clause of return information corresponding for described classification as clause corresponding to described classification; Described 3rd acquisition module, if be also multiple for the number of return information corresponding to described classification, then using in the clause of return information corresponding for described classification by the maximum clause of access times as clause corresponding to described classification; 3rd memory module, for by described classification and clause corresponding to described classification, is stored to described 3rd map information.
One of embodiment is planted according to first three of second aspect or second aspect, in the 4th kind of embodiment of second aspect, described first searches module, comprise: first searches unit, return information is treated for described in basis, search the corpus set up in advance, described corpus comprises multiple original sentence and reply sentence corresponding to described multiple original sentence; Second searches unit, if treat with described the original sentence that return information mates for not existing in described multiple original sentence, then treat return information described in basis, search the primary keys of the raw information in history chat record, obtain and described the first primary keys treating the Keywords matching of return information.
Automatic reply method provided by the invention and device, the keyword of return information is treated by basis, treat the reply clause that return information is corresponding described in determining and describedly treat the reply keyword that return information is corresponding, thus described in obtaining, treat the technical scheme of the return information that return information is corresponding, effectively improve the reliability automatically replied.
Accompanying drawing explanation
In order to be illustrated more clearly in the embodiment of the present invention or technical scheme of the prior art, be briefly described to the accompanying drawing used required in embodiment or description of the prior art below, apparently, accompanying drawing in the following describes is some embodiments of the present invention, for those of ordinary skill in the art, under the prerequisite not paying creative work, other accompanying drawing can also be obtained according to these accompanying drawings.
The schematic flow sheet of a kind of automatic reply method that Fig. 1 provides for the embodiment of the present invention one;
A kind of structural representation automatically replying device that Fig. 2 provides for the embodiment of the present invention two;
Fig. 3 automatically replies the structural representation of device for another kind that the embodiment of the present invention three provides.
Embodiment
For making the object of the embodiment of the present invention, technical scheme and advantage clearly, below in conjunction with the accompanying drawing in the embodiment of the present invention, technical scheme in the embodiment of the present invention is clearly and completely described, obviously, described embodiment is the present invention's part embodiment, instead of whole embodiments.Based on the embodiment in the present invention, those of ordinary skill in the art, not making the every other embodiment obtained under creative work prerequisite, belong to the scope of protection of the invention.
The schematic flow sheet of a kind of automatic reply method that Fig. 1 provides for the embodiment of the present invention one, as shown in Figure 1, described method comprises:
101, treat return information according to what receive, search the primary keys of raw information in history chat record, obtain and described the first primary keys treating the Keywords matching of return information.
Concrete, the executive agent of the present embodiment can for automatically replying device, described in automatically reply device and can be arranged in the chat software of user.Then concrete further, described raw information is specifically as follows the chat message that in the history chat record of described user, other users send.Concrete, described user can possess the equipment transmission chat message of communication function by mobile phone, PC, panel computer etc.The primary keys of described raw information is the keyword of described raw information, concrete, and the method for the keyword of information extraction does not repeat them here.
In actual applications, the primary keys of raw information in described history chat record can be recorded in primary keys storehouse, thus when receiving until return information, by searching described primary keys storehouse, obtain described first primary keys.Concrete, described search described with the described method treating the first primary keys of the Keywords matching of return information, can comprise: by described primary keys storehouse, treat with described the primary keys that the keyword of return information is identical, as described first primary keys.
Concrete, it can be treat return information if receive that the one of 101 implements scene, then directly treat return information described in basis, search the primary keys of raw information in history chat record, obtain described first primary keys.Optionally, it can be treat return information if receive that the another kind of 101 implements scene, then first automatically reply based on corpus, if when cannot realize automatically replying based on corpus, then realizes automatically replying according to the automatic reply method that the present embodiment provides.Accordingly, implement in scene in rear one, 101 specifically can comprise:
Treat return information according to described, search the corpus set up in advance, described corpus comprises multiple original sentence and reply sentence corresponding to described multiple original sentence;
Treat with described the original sentence that return information mates if do not exist in described multiple original sentence, then treat return information described in basis, search the primary keys of the raw information in history chat record, obtain and described the first primary keys treating the Keywords matching of return information.
Optionally, after the primary keys searching raw information in history chat record described in 101, described method can also comprise: if there is not described first primary keys in described primary keys, then process ends export the first error information.By present embodiment, automatically reply if cannot realize, then can determine reason quickly and easily according to error information, to safeguard.
102, search the first map information, described first map information comprises described primary keys and reply keyword corresponding to described primary keys, obtain described first primary keys corresponding first reply keyword.
Concrete, in order to set up described first map information in advance, before 102, described method can also comprise:
For each raw information in described history chat record, by the keyword of return information corresponding for described raw information, the reply keyword that the primary keys as described raw information is corresponding;
By described primary keys, and reply keyword corresponding to described primary keys is stored to described first map information.
Optionally, after searching the first map information described in 102, described method can also comprise: if there is described first primary keys in described primary keys, and in described first map information, do not have described first and reply keyword, then process ends export the second error information.By present embodiment, automatically reply if cannot realize, then can determine reason quickly and easily according to error information, to safeguard.
103, search the second map information, described second map information comprises the classification of described primary keys and described primary keys, obtains the classification of described first primary keys.
Wherein, 102 can perform before 103, performed with 103 simultaneously, or performed after 103, the just wherein a kind of concrete embodiment provided in figure, and were not limited.
Concrete, in order to set up described second map information in advance, before 103, described method can also comprise:
According to the keyword of return information corresponding to raw information in described history chat record, obtained the classification of the keyword of return information corresponding to described raw information by cluster;
For each raw information in described history chat record, by the classification of the keyword of return information corresponding for described raw information, as the classification of the primary keys of described raw information;
By described primary keys, and the classification of described primary keys is stored to described second map information.
Optionally, after searching the second map information described in 103, can also comprise: if there is described first primary keys in described primary keys, and there is not the classification of described first primary keys in described second map information, then process ends export the 3rd error information.By present embodiment, automatically reply if cannot realize, then can determine reason quickly and easily according to error information, to safeguard.
104, search the 3rd map information, described 3rd map information comprises clause corresponding to the classification of the classification of described primary keys and described primary keys, obtains the first clause that the classification of described first primary keys is corresponding.
Concrete, in order to set up described 3rd map information in advance, before 104, described method can also comprise:
For the classification of often kind of primary keys, obtain the return information that described classification is corresponding, return information corresponding to described classification comprises, the return information corresponding with the raw information of classification belonging to the primary keys of described classification;
If the number of the return information that described classification is corresponding is one, then using the clause of return information corresponding for described classification as clause corresponding to described classification;
If the number of the return information that described classification is corresponding is multiple, then using in the clause of return information corresponding for described classification by the maximum clause of access times as clause corresponding to described classification;
By described classification and clause corresponding to described classification, be stored to described 3rd map information.
Optionally, after searching the 3rd map information in 104, can also comprise: if there is described first primary keys in described primary keys, the classification of described first primary keys is there is in described second map information, and there is not described first clause in described 3rd map information, then process ends export the 4th error information.By present embodiment, automatically reply if cannot realize, then can determine reason quickly and easily according to error information, to safeguard.
105, reply keyword and described first clause according to described first, described in acquisition, treat the return information that return information is corresponding.
Optionally, the foundation of described first map information, the second map information and the 3rd map information also manually arranges realization by user, and not concrete to it method for building up of the present embodiment limits.
Wherein, the concrete grammar of replying keyword and described first clause acquisition return information according to first repeats no more.Concrete, automatically reply to realize further, after 105, described method can also comprise: to the equipment treating return information described in transmission, treat the return information that return information is corresponding described in transmission.Same, described equipment can include but not limited to: mobile phone, PC, panel computer and other possess the equipment of communication function.
The automatic reply method that the present embodiment provides, the keyword of return information is treated by basis, treat the reply clause that return information is corresponding described in determining and describedly treat the reply keyword that return information is corresponding, thus described in obtaining, treat the technical scheme of the return information that return information is corresponding, effectively improve the reliability automatically replied.
A kind of structural representation automatically replying device that Fig. 2 provides for the embodiment of the present invention two, as shown in Figure 2, described device comprises: first searches module 21, second searches module 22, the 3rd and search module 23, the 4th and search module 24 and processing module 25; Wherein,
First searches module 21, for treating return information according to what receive, searching the primary keys of raw information in history chat record, obtaining and described the first primary keys treating the Keywords matching of return information;
Second searches module 22, and for searching the first map information, described first map information comprises described primary keys and reply keyword corresponding to described primary keys, obtain described first primary keys corresponding first reply keyword;
3rd searches module 23, and for searching the second map information, described second map information comprises the classification of described primary keys and described primary keys, obtains the classification of described first primary keys;
4th searches module 24, and for searching the 3rd map information, described 3rd map information comprises clause corresponding to the classification of the classification of described primary keys and described primary keys, obtains the first clause that the classification of described first primary keys is corresponding;
Processing module 25, for replying keyword and described first clause according to described first, treats the return information that return information is corresponding described in acquisition.
Concrete, it can be treat return information if receive that the one of the present embodiment implements scene, then directly treat return information described in basis, search the primary keys of raw information in history chat record, obtain described first primary keys.Optionally, it can be treat return information if receive that the another kind of the present embodiment implements scene, then first automatically reply based on corpus, if when cannot realize automatically replying based on corpus, then realize automatically replying based on the device that automatically replies that the present embodiment provides.Accordingly, implement in scene in rear one, first searches module 21, specifically can comprise:
First searches unit, treats return information for described in basis, searches the corpus set up in advance, and described corpus comprises multiple original sentence and reply sentence corresponding to described multiple original sentence;
Second searches unit, if treat with described the original sentence that return information mates for not existing in described multiple original sentence, then treat return information described in basis, search the primary keys of the raw information in history chat record, obtain and described the first primary keys treating the Keywords matching of return information.
Concrete, in order to set up described first map information in advance, described device can also comprise:
First acquisition module, for described search the first map information before, for each raw information in described history chat record, by the keyword of return information corresponding for described raw information, the reply keyword that the primary keys as described raw information is corresponding;
First memory module, for by described primary keys, and reply keyword corresponding to described primary keys is stored to described first map information.
Concrete again, in order to set up described second map information in advance, described device can also comprise:
Second acquisition module, for before searching the second map information, according to the keyword of return information corresponding to raw information in described history chat record, obtains the classification of the keyword of return information corresponding to described raw information by cluster;
Described second acquisition module, also for for each raw information in described history chat record, by the classification of the keyword of return information corresponding for described raw information, as the classification of the primary keys of described raw information;
Second memory module, for by described primary keys, and the classification of described primary keys is stored to described second map information.
Concrete again, in order to set up described 3rd map information in advance, described device can also comprise:
3rd acquisition module, for before searching the 3rd map information, for the classification of often kind of primary keys, obtain the return information that described classification is corresponding, return information corresponding to described classification comprises, the return information corresponding with the raw information of classification belonging to the primary keys of described classification;
Described 3rd acquisition module, if be also one for the number of return information corresponding to described classification, then using the clause of return information corresponding for described classification as clause corresponding to described classification;
Described 3rd acquisition module, if be also multiple for the number of return information corresponding to described classification, then using in the clause of return information corresponding for described classification by the maximum clause of access times as clause corresponding to described classification;
3rd memory module, for by described classification and clause corresponding to described classification, is stored to described 3rd map information.
Optionally, in above-mentioned arbitrary embodiment of the present embodiment, there is not described first primary keys if can also be used in processing module 25 in described primary keys, then process ends export the first error information; Or,
If there is described first primary keys in described primary keys, and in described first map information, do not have described first and reply keyword, then process ends export the second error information; Or,
If there is described first primary keys in described primary keys, and there is not the classification of described first primary keys in described second map information, then process ends export the 3rd error information; Or,
If there is described first primary keys in described primary keys, in described second map information, there is the classification of described first primary keys, and there is not described first clause in described 3rd map information, then process ends export the 4th error information.
Concrete, automatically reply to realize further, described device can also comprise: communication module, for the equipment treating return information described in transmission, treats the return information that return information is corresponding described in transmission.
What the present embodiment provided automatically replies device, the keyword of return information is treated by basis, treat the reply clause that return information is corresponding described in determining and describedly treat the reply keyword that return information is corresponding, thus described in obtaining, treat the technical scheme of the return information that return information is corresponding, effectively improve the reliability automatically replied.
Fig. 3 automatically replies the structural representation of device for another kind that the embodiment of the present invention three provides.As shown in Figure 3, automatically reply device described in comprise: communication interface 31, storer 32 and processor 33.
Communication interface 31, treats return information for receiving.
Storer 32, for depositing program.Particularly, program can comprise program code, and described program code comprises computer-managed instruction.Storer 32 may comprise high-speed RAM storer, still may comprise nonvolatile memory (non-volatile memory), such as at least one magnetic disk memory.
Processor 33, for the program that execute store 32 is deposited, for: treat return information according to what receive, search the primary keys of raw information in history chat record, obtain and described the first primary keys treating the Keywords matching of return information; Search the first map information, described first map information comprises described primary keys and reply keyword corresponding to described primary keys, obtain described first primary keys corresponding first reply keyword; Search the second map information, described second map information comprises the classification of described primary keys and described primary keys, obtains the classification of described first primary keys; Search the 3rd map information, described 3rd map information comprises clause corresponding to the classification of the classification of described primary keys and described primary keys, obtains the first clause that the classification of described first primary keys is corresponding; Reply keyword and described first clause according to described first, described in acquisition, treat the return information that return information is corresponding.
Optionally, implement, in scene, to treat return information if receive, then can first automatically reply based on corpus in the one of the present embodiment, if when cannot realize automatically replying based on corpus, then realize automatically replying based on the device that automatically replies that the present embodiment provides.Accordingly, implement in scene in rear one, processor 33, specifically may be used for according to described in treat return information, search the corpus set up in advance, described corpus comprises multiple original sentence and reply sentence corresponding to described multiple original sentence; Treat with described the original sentence that return information mates if do not exist in described multiple original sentence, then treat return information described in basis, search the primary keys of the raw information in history chat record, obtain and described the first primary keys treating the Keywords matching of return information.
Wherein, processor 33 may be a central processing unit (Central Processing Unit, referred to as CPU), or specific integrated circuit (Application Specific Integrated Circuit, referred to as ASIC), or be configured to the one or more integrated circuit implementing the embodiment of the present invention.
Concrete, based on the program that storer 32 is deposited, in order to set up described first map information in advance, processor 33, also for described search the first map information before, for each raw information in described history chat record, by the keyword of return information corresponding for described raw information, the reply keyword that the primary keys as described raw information is corresponding; By described primary keys, and reply keyword corresponding to described primary keys is stored to described first map information.
Concrete again, based on the program that storer 32 is deposited, in order to set up described second map information in advance, processor 33, also for before searching the second map information, according to the keyword of return information corresponding to raw information in described history chat record, obtained the classification of the keyword of return information corresponding to described raw information by cluster; For each raw information in described history chat record, by the classification of the keyword of return information corresponding for described raw information, as the classification of the primary keys of described raw information; By described primary keys, and the classification of described primary keys is stored to described second map information.
Concrete again, based on the program that storer 32 is deposited, in order to set up described 3rd map information in advance, processor 33, also for before searching the 3rd map information, for the classification of often kind of primary keys, obtain the return information that described classification is corresponding, return information corresponding to described classification comprises, the return information corresponding with the raw information of classification belonging to the primary keys of described classification; If the number of the return information that described classification is corresponding is one, then using the clause of return information corresponding for described classification as clause corresponding to described classification; If the number of the return information that described classification is corresponding is multiple, then using in the clause of return information corresponding for described classification by the maximum clause of access times as clause corresponding to described classification; By described classification and clause corresponding to described classification, be stored to described 3rd map information.
Optionally, based on the program that storer 32 is deposited, in above-mentioned arbitrary embodiment of the present embodiment, there is not described first primary keys if can also be used in processor 33 in described primary keys, then process ends export the first error information; Or, if there is described first primary keys in described primary keys, and in described first map information, do not have described first and reply keyword, then process ends export the second error information; Or, if there is described first primary keys in described primary keys, and there is not the classification of described first primary keys in described second map information, then process ends export the 3rd error information; Or, if there is described first primary keys in described primary keys, there is the classification of described first primary keys in described second map information, and there is not described first clause in described 3rd map information, then process ends export the 4th error information.
Concrete, automatically replying to realize further, communication interface 31, also for the equipment treating return information described in transmission, described in transmission, treating the return information that return information is corresponding.
Optionally, in specific implementation, realize if communication interface 31, processor 33 and storer 32 are independent, then communication interface 31, storer 32 and processor 33 can be interconnected by bus and complete mutual communicating.Described bus can be industry standard architecture (Industry StandardArchitecture, referred to as ISA) bus, peripheral component interconnect (Peripheral Component, referred to as PCI) bus or extended industry-standard architecture (Extended Industry StandardArchitecture, referred to as EISA) bus etc.Described bus can be divided into address bus, data bus, control bus etc.For ease of representing, only representing with a thick line in Fig. 3, but not representing the bus only having a bus or a type.
Optionally, in specific implementation, if communication interface 31, storer 32 and processor 33 is integrated realizes on one chip, then communication interface 31, storer 32 and processor 33 can complete identical communicating by internal interface.
What the present embodiment provided automatically replies device, the keyword of return information is treated by basis, treat the reply clause that return information is corresponding described in determining and describedly treat the reply keyword that return information is corresponding, thus described in obtaining, treat the technical scheme of the return information that return information is corresponding, effectively improve the reliability automatically replied.
Those skilled in the art can be well understood to, and for convenience and simplicity of description, the specific works process of the device of foregoing description, with reference to the corresponding process in preceding method embodiment, can not repeat them here.
One of ordinary skill in the art will appreciate that: all or part of step realizing above-mentioned each embodiment of the method can have been come by the hardware that programmed instruction is relevant.Aforesaid program can be stored in a computer read/write memory medium.This program, when performing, performs the step comprising above-mentioned each embodiment of the method; And aforesaid storage medium comprises: ROM, RAM, magnetic disc or CD etc. various can be program code stored medium.
Last it is noted that above each embodiment is only in order to illustrate technical scheme of the present invention, be not intended to limit; Although with reference to foregoing embodiments to invention has been detailed description, those of ordinary skill in the art is to be understood that: it still can be modified to the technical scheme described in foregoing embodiments, or carries out equivalent replacement to wherein some or all of technical characteristic; And these amendments or replacement, do not make the essence of appropriate technical solution depart from the scope of various embodiments of the present invention technical scheme.

Claims (10)

1. an automatic reply method, is characterized in that, comprising:
Treat return information according to what receive, search the primary keys of raw information in history chat record, obtain and described the first primary keys treating the Keywords matching of return information;
Search the first map information, described first map information comprises described primary keys and reply keyword corresponding to described primary keys, obtain described first primary keys corresponding first reply keyword;
Search the second map information, described second map information comprises the classification of described primary keys and described primary keys, obtains the classification of described first primary keys;
Search the 3rd map information, described 3rd map information comprises clause corresponding to the classification of the classification of described primary keys and described primary keys, obtains the first clause that the classification of described first primary keys is corresponding;
Reply keyword and described first clause according to described first, described in acquisition, treat the return information that return information is corresponding.
2. method according to claim 1, is characterized in that, described in search the first map information before, also comprise:
For each raw information in described history chat record, by the keyword of return information corresponding for described raw information, the reply keyword that the primary keys as described raw information is corresponding;
By described primary keys, and reply keyword corresponding to described primary keys is stored to described first map information.
3. method according to claim 1 and 2, is characterized in that, described in search the second map information before, also comprise:
According to the keyword of return information corresponding to raw information in described history chat record, obtained the classification of the keyword of return information corresponding to described raw information by cluster;
For each raw information in described history chat record, by the classification of the keyword of return information corresponding for described raw information, as the classification of the primary keys of described raw information;
By described primary keys, and the classification of described primary keys is stored to described second map information.
4. the method according to any one of claim 1-3, is characterized in that, described in search the 3rd map information before, also comprise:
For the classification of often kind of primary keys, obtain the return information that described classification is corresponding, return information corresponding to described classification comprises, the return information corresponding with the raw information of classification belonging to the primary keys of described classification;
If the number of the return information that described classification is corresponding is one, then using the clause of return information corresponding for described classification as clause corresponding to described classification;
If the number of the return information that described classification is corresponding is multiple, then using in the clause of return information corresponding for described classification by the maximum clause of access times as clause corresponding to described classification;
By described classification and clause corresponding to described classification, be stored to described 3rd map information.
5. the method according to any one of claim 1-4, it is characterized in that, what described basis received treats return information, searches the primary keys of the raw information in history chat record, obtain and described the first primary keys treating the Keywords matching of return information, comprising:
Treat return information according to described, search the corpus set up in advance, described corpus comprises multiple original sentence and reply sentence corresponding to described multiple original sentence;
Treat with described the original sentence that return information mates if do not exist in described multiple original sentence, then treat return information described in basis, search the primary keys of the raw information in history chat record, obtain and described the first primary keys treating the Keywords matching of return information.
6. automatically reply a device, it is characterized in that, comprising:
First searches module, for treating return information according to what receive, searching the primary keys of raw information in history chat record, obtaining and described the first primary keys treating the Keywords matching of return information;
Second searches module, and for searching the first map information, described first map information comprises described primary keys and reply keyword corresponding to described primary keys, obtain described first primary keys corresponding first reply keyword;
3rd searches module, and for searching the second map information, described second map information comprises the classification of described primary keys and described primary keys, obtains the classification of described first primary keys;
4th searches module, and for searching the 3rd map information, described 3rd map information comprises clause corresponding to the classification of the classification of described primary keys and described primary keys, obtains the first clause that the classification of described first primary keys is corresponding;
Processing module, for replying keyword and described first clause according to described first, treats the return information that return information is corresponding described in acquisition.
7. device according to claim 6, is characterized in that, described device also comprises:
First acquisition module, for described search the first map information before, for each raw information in described history chat record, by the keyword of return information corresponding for described raw information, the reply keyword that the primary keys as described raw information is corresponding;
First memory module, for by described primary keys, and reply keyword corresponding to described primary keys is stored to described first map information.
8. the device according to claim 6 or 7, is characterized in that, described device also comprises:
Second acquisition module, for before searching the second map information, according to the keyword of return information corresponding to raw information in described history chat record, obtains the classification of the keyword of return information corresponding to described raw information by cluster;
Described second acquisition module, also for for each raw information in described history chat record, by the classification of the keyword of return information corresponding for described raw information, as the classification of the primary keys of described raw information;
Second memory module, for by described primary keys, and the classification of described primary keys is stored to described second map information.
9. the device according to any one of claim 6-8, is characterized in that, described device also comprises:
3rd acquisition module, for before searching the 3rd map information, for the classification of often kind of primary keys, obtain the return information that described classification is corresponding, return information corresponding to described classification comprises, the return information corresponding with the raw information of classification belonging to the primary keys of described classification;
Described 3rd acquisition module, if be also one for the number of return information corresponding to described classification, then using the clause of return information corresponding for described classification as clause corresponding to described classification;
Described 3rd acquisition module, if be also multiple for the number of return information corresponding to described classification, then using in the clause of return information corresponding for described classification by the maximum clause of access times as clause corresponding to described classification;
3rd memory module, for by described classification and clause corresponding to described classification, is stored to described 3rd map information.
10. the device according to any one of claim 6-9, is characterized in that, described first searches module, comprising:
First searches unit, treats return information for described in basis, searches the corpus set up in advance, and described corpus comprises multiple original sentence and reply sentence corresponding to described multiple original sentence;
Second searches unit, if treat with described the original sentence that return information mates for not existing in described multiple original sentence, then treat return information described in basis, search the primary keys of the raw information in history chat record, obtain and described the first primary keys treating the Keywords matching of return information.
CN201310464118.5A 2013-09-30 2013-09-30 Automatic reply method and device Active CN104516921B (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN201310464118.5A CN104516921B (en) 2013-09-30 2013-09-30 Automatic reply method and device
PCT/CN2014/083701 WO2015043318A1 (en) 2013-09-30 2014-08-05 Automatic reply method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201310464118.5A CN104516921B (en) 2013-09-30 2013-09-30 Automatic reply method and device

Publications (2)

Publication Number Publication Date
CN104516921A true CN104516921A (en) 2015-04-15
CN104516921B CN104516921B (en) 2018-02-06

Family

ID=52742003

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201310464118.5A Active CN104516921B (en) 2013-09-30 2013-09-30 Automatic reply method and device

Country Status (2)

Country Link
CN (1) CN104516921B (en)
WO (1) WO2015043318A1 (en)

Cited By (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105912734A (en) * 2016-06-22 2016-08-31 北京金山安全软件有限公司 User feedback automatic reply method and device
CN106383590A (en) * 2016-09-06 2017-02-08 珠海格力电器股份有限公司 Intelligent input method and apparatus
CN106649280A (en) * 2017-02-13 2017-05-10 长沙军鸽软件有限公司 Method for creating shared corpus
CN107766416A (en) * 2017-09-08 2018-03-06 阿里巴巴集团控股有限公司 Data analysing method, apparatus and system
CN108062388A (en) * 2017-12-15 2018-05-22 北京百度网讯科技有限公司 Interactive reply generation method and device
CN108769408A (en) * 2018-05-28 2018-11-06 维沃移动通信有限公司 A kind of message method and terminal device
CN109670155A (en) * 2018-11-08 2019-04-23 龙马智声(珠海)科技有限公司 A method of automatically replying the communication information
CN112784030A (en) * 2021-01-28 2021-05-11 北京三快在线科技有限公司 Method and device for generating sample, storage medium and electronic equipment
CN112818109A (en) * 2021-02-25 2021-05-18 网易(杭州)网络有限公司 Intelligent reply method, medium, device and computing equipment for mail

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109067643B (en) * 2018-09-26 2022-07-29 中国平安财产保险股份有限公司 Reply method and device based on keywords, computer equipment and storage medium
CN112202661A (en) * 2020-09-11 2021-01-08 腾讯科技(深圳)有限公司 Session message processing method and device, computer equipment and storage medium

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6029171A (en) * 1997-02-10 2000-02-22 Actioneer, Inc. Method and apparatus for group action processing between users of a collaboration system
CN101178711A (en) * 2006-11-30 2008-05-14 腾讯科技(深圳)有限公司 Chinese auto-answer method and system
CN101232532A (en) * 2007-12-11 2008-07-30 中兴通讯股份有限公司 Apparatus and method for realizing short message intelligent revert in mobile terminal
CN102035868A (en) * 2009-09-28 2011-04-27 上海智臻网络科技有限公司 Method and device for implementing webpage automatic customer service
CN102289431A (en) * 2011-06-24 2011-12-21 华南理工大学 Method for providing short message reply options based on natural language understanding
CN103200550A (en) * 2013-04-26 2013-07-10 上海华勤通讯技术有限公司 Mobile terminal and method for replaying messages automatically

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101233532B (en) * 2005-08-02 2011-04-06 Nxp股份有限公司 Antenna structure, transponder and method of manufacturing an antenna structure

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6029171A (en) * 1997-02-10 2000-02-22 Actioneer, Inc. Method and apparatus for group action processing between users of a collaboration system
CN101178711A (en) * 2006-11-30 2008-05-14 腾讯科技(深圳)有限公司 Chinese auto-answer method and system
CN101232532A (en) * 2007-12-11 2008-07-30 中兴通讯股份有限公司 Apparatus and method for realizing short message intelligent revert in mobile terminal
CN102035868A (en) * 2009-09-28 2011-04-27 上海智臻网络科技有限公司 Method and device for implementing webpage automatic customer service
CN102289431A (en) * 2011-06-24 2011-12-21 华南理工大学 Method for providing short message reply options based on natural language understanding
CN103200550A (en) * 2013-04-26 2013-07-10 上海华勤通讯技术有限公司 Mobile terminal and method for replaying messages automatically

Cited By (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105912734A (en) * 2016-06-22 2016-08-31 北京金山安全软件有限公司 User feedback automatic reply method and device
CN106383590A (en) * 2016-09-06 2017-02-08 珠海格力电器股份有限公司 Intelligent input method and apparatus
CN106649280A (en) * 2017-02-13 2017-05-10 长沙军鸽软件有限公司 Method for creating shared corpus
CN106649280B (en) * 2017-02-13 2019-07-09 长沙军鸽软件有限公司 A method of creating shared corpus
CN107766416A (en) * 2017-09-08 2018-03-06 阿里巴巴集团控股有限公司 Data analysing method, apparatus and system
CN108062388A (en) * 2017-12-15 2018-05-22 北京百度网讯科技有限公司 Interactive reply generation method and device
CN108062388B (en) * 2017-12-15 2021-09-17 北京百度网讯科技有限公司 Reply generation method and device for man-machine conversation
CN108769408A (en) * 2018-05-28 2018-11-06 维沃移动通信有限公司 A kind of message method and terminal device
CN109670155A (en) * 2018-11-08 2019-04-23 龙马智声(珠海)科技有限公司 A method of automatically replying the communication information
CN112784030A (en) * 2021-01-28 2021-05-11 北京三快在线科技有限公司 Method and device for generating sample, storage medium and electronic equipment
CN112784030B (en) * 2021-01-28 2022-08-26 北京三快在线科技有限公司 Method and device for generating sample, storage medium and electronic equipment
CN112818109A (en) * 2021-02-25 2021-05-18 网易(杭州)网络有限公司 Intelligent reply method, medium, device and computing equipment for mail

Also Published As

Publication number Publication date
CN104516921B (en) 2018-02-06
WO2015043318A1 (en) 2015-04-02

Similar Documents

Publication Publication Date Title
CN104516921A (en) Automatic response method and device
CN107729251A (en) Testing case management and device
CN104750705A (en) Information returning method and device
CN105224237A (en) A kind of date storage method and device
CN105095287A (en) LSM (Log Structured Merge) data compact method and device
CN103218555A (en) Logging-in method and device for application program
CN103885966A (en) Question and answer interaction method and system of electronic commerce transaction platform
CN105099729A (en) User ID (Identification) recognition method and device
CN104598161B (en) Digital independent, wiring method and device and data store organisation
CN103744896A (en) Method and device for data processing
CN112015806A (en) Method and device for storing data by block chain
CN105159884A (en) Method and device for establishing industry dictionary and industry identification method and device
CN104408183B (en) The data lead-in method and device of data system
CN102959548A (en) Data storage method, search method and device
CN101963993B (en) Method for fast searching database sheet table record
CN106649210A (en) Data conversion method and device
CN104182479B (en) A kind of method and device handling information
CN104573112A (en) Page query method and data processing node for OLTP cluster database
CN106202440A (en) Data processing method, device and equipment
CN104216834A (en) Internal storage assess method, buffering scheduler and internal storage module
CN106815232A (en) Catalog management method, apparatus and system
CN103530345A (en) Short text characteristic extension and fitting characteristic library building method and device
CN110263104A (en) JSON character string processing method and device
CN102902701A (en) Information inquiry system and information inquiry method
CN104573098A (en) Large-scale object recognition method based on Spark system

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant