CN108984650A - Computer readable recording medium and computer equipment - Google Patents
Computer readable recording medium and computer equipment Download PDFInfo
- Publication number
- CN108984650A CN108984650A CN201810677005.6A CN201810677005A CN108984650A CN 108984650 A CN108984650 A CN 108984650A CN 201810677005 A CN201810677005 A CN 201810677005A CN 108984650 A CN108984650 A CN 108984650A
- Authority
- CN
- China
- Prior art keywords
- information
- semantic
- user equipment
- participle
- initial answer
- 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
Links
Landscapes
- Machine Translation (AREA)
Abstract
The present invention provides a kind of computer readable recording medium and computer equipments, software program is stored on the medium, the method for obtaining answer information is realized when the program is executed by processor, the described method comprises the following steps: obtaining the text sequence to be processed from user equipment;The text sequence is segmented, and obtains the semantic information of its at least one participle;According to institute's semantic information, matching inquiry is carried out in predetermined knowledge library, determines the corresponding initial answer information of institute's semantic information;When judging that the initial answer information cannot be provided directly to the user equipment, parameter information is obtained from institute's semantic information;According to the parameter information, the initial answer information is handled, obtains the final result information for being supplied to the user equipment.The present invention is capable of providing more accurate answer information by carrying out better semantic understanding to text sequence.
Description
It is on March 26th, 2014 that the application, which is the applying date, and application No. is 201410117635.X, invention and created name is
The divisional application of " a kind of for obtaining the method, apparatus and equipment of answer information ".
Technical field
The present invention relates to field of computer technology more particularly to a kind of computer readable recording mediums and computer equipment.
Background technique
It is in the prior art various based on the scheme for providing a user answer information the problem of user, often only carry out letter
Single problem text matches, and lack the semantic understanding to problem, so that the answer provided is not fully up to expectations.
Summary of the invention
The object of the present invention is to provide a kind of computer readable recording medium and computer equipments.
According to an aspect of the present invention, a kind of computer readable recording medium is provided, software program is stored thereon with, it should
The method for obtaining answer information is realized when program is executed by processor, and the described method comprises the following steps:
A obtains the text sequence to be processed from user equipment;
B segments the text sequence, and obtains the semantic information of its at least one participle;
C carries out matching inquiry according to institute's semantic information in predetermined knowledge library, determines that institute's semantic information is corresponding just
Beginning answer information;
Wherein, this method is further comprising the steps of:
D is when judging that the initial answer information cannot be provided directly to the user equipment, from institute's semantic information
Middle acquisition parameter information;
E is handled the initial answer information according to the parameter information, and acquisition is set for being supplied to the user
Standby final result information.
Optionally, the step c the following steps are included:
Multiple groups semantic matches information in institute's semantic information and the predetermined knowledge library is subjected to matching inquiry, and will
The obtained corresponding initial answer information of one group of semantic matches information is matched, as the corresponding initial answer letter of institute's semantic information
Breath, wherein every group of semantic matches information includes one or more semantic matches structures.
Optionally, the semantic matches structure includes at least one of the following:
The semantic information of at least one vocabulary in multiple vocabulary and multiple vocabulary;
Logical relation between the multiple vocabulary.
Optionally, the corresponding initial answer information of one group of semantic matches information have it is multiple, this method the step c it
It is further comprising the steps of afterwards:
According to the facility information of the user equipment and/or the application message for the application for sending the text sequence, from institute
It states in multiple initial answer informations and selects initial answer information;
Wherein, the step d the following steps are included:
When judging that selected initial answer information cannot be provided directly to the user equipment, from the semanteme
Parameter information is obtained in information.
Optionally, the predetermined knowledge library includes instances of ontology, each of at least one attribute of the instances of ontology
Including one group of semantic matches information and initial answer information corresponding with the semantic matches information, this method further includes following step
It is rapid:
X obtains the example item of an ontology, wherein each of at least one attribute of the ontology includes ontology answer
Information and one group of semantic matches information with default item;
Y is handled the default item in the attribute of the ontology according to the example item, is obtained and is inherited the ontology
The instances of ontology of whole attributes.
Optionally, the step c the following steps are included:
C1 obtains the historical query information of the user equipment when the text sequence meets preset trigger condition;
C2 carries out matching inquiry, really in conjunction with the historical query information and institute's semantic information in predetermined knowledge library
The fixed initial answer information.
Optionally, the historical query information includes the history semantic information of the text sequence from the user equipment,
The step c2 the following steps are included:
According to the history semantic information, semantic supplement is carried out to institute's semantic information;
According to the semantic information after semantic supplement, matching inquiry is carried out in predetermined knowledge library, determines the initial answer
Information.
Optionally, this method is further comprising the steps of:
When judging that the initial answer information can be provided directly to the user equipment, by the initial answer
Information is sent to the user equipment.
Optionally, institute's semantic information includes at least one of the following:
The synonym and/or synonymous word combination of participle;
The similar word and/or similar word combination of participle;
There is the entity of same or similar structure with participle;
The final result information includes at least one of the following:
Executable information;
Multimedia messages with extension tag.
According to another aspect of the present invention, a kind of computer equipment is additionally provided, including above-mentioned computer-readable note
Recording medium, processor and storage are on a computer readable recording medium and the software program that can run on a processor.
Compared with prior art, the invention has the following advantages that 1) by carrying out better semantic understanding to text sequence,
It is capable of providing more accurate answer information;It 2) can be according to the historical query of user to the current text sequence to be treated of user
It is supplemented, so as to which in the incomplete situation of text that user provides, automatic realization semanteme has been mended and understood, and passes through
The condition for obtaining historical query information to triggering limits, and enabling to computer equipment, just starting is literary in appropriate circumstances
The operation of this supplement, to prevent or reduce computer equipment because constantly being inquired history the possibility so as to cause collapse;
3) for a large amount of instances of ontology with like attribute, without repeatedly establishing attribute for each instances of ontology, and can lead to
The mode for inheriting all properties of ontology is crossed, new instances of ontology is easily created, significantly reduces instances of ontology creation process
In resource consumption.
Detailed description of the invention
By reading a detailed description of non-restrictive embodiments in the light of the attached drawings below, of the invention other
Feature, objects and advantages will become more apparent upon:
Fig. 1 is the method flow diagram of the acquisition answer information of a preferred embodiment of the invention;
Fig. 2 is the method flow diagram of the creation instances of ontology of a preferred embodiment of the invention;
Fig. 3 is the structural schematic diagram of the question and answer system of the acquisition answer information of a preferred embodiment of the invention;
Fig. 4 is the structural schematic diagram of the question and answer system of the creation instances of ontology of a preferred embodiment of the invention.
The same or similar appended drawing reference represents the same or similar component in attached drawing.
Specific embodiment
Present invention is further described in detail with reference to the accompanying drawing.
Fig. 1 is the method flow diagram of the acquisition answer information of a preferred embodiment of the invention.Wherein, the side of the present embodiment
Method is mainly realized by computer equipment;The computer equipment includes but is not limited to the network equipment and user equipment.It is described
The network equipment includes but is not limited to single network server, the server group of multiple network servers composition or is based on cloud computing
The cloud consisting of a large number of computers or network servers of (Cloud Computing), wherein cloud computing is distributed computing
One kind, a super virtual computer consisting of a loosely coupled set of computers;Net locating for the computer equipment
Network includes but is not limited to internet, wide area network, Metropolitan Area Network (MAN), local area network, VPN network etc..The user equipment includes but is not limited to
PC machine, tablet computer, smart phone, PDA, IPTV etc..
It should be noted that the computer equipment and network are only for example, other are existing or are likely to occur from now on
Computer equipment or network are such as applicable to the present invention, should also be included within the scope of protection of the present invention, and wrap by reference
Contained in this.
Include the following steps S1, step S2, step S3, step S4 and step S5 according to the method for the present embodiment.
In step sl, computer equipment obtains the text sequence to be processed from user equipment.
Wherein, which can be the text sequence that user directly inputs, and can also be to input to user
Voice resulting text sequence after being identified.
For example, user inputs " today, how is weather " in dialog box, and presses and send key to indicate that user equipment will
" today, how is weather " is sent to computer equipment, then " today, how is weather " is the text to be processed from user equipment
Sequence.
In another example user inputs one section of voice in some application, this section of voice is sent to by the application via internet
Computer equipment, computer equipment identify the voice and obtain text sequence " today, how is weather ", then " today, how is weather "
The as text sequence to be processed from user equipment.
It should be noted that the above-mentioned examples are merely illustrative of the technical solutions of the present invention, rather than to limit of the invention
System, it should be appreciated by those skilled in the art that any implementation for obtaining the text sequence to be processed from user equipment,
It should within the scope of the present invention.
Then, in step s 2, computer equipment segments text sequence to be processed, and obtains its at least one
The semantic information of participle.
Wherein, the semantic information of participle includes any semantic letter that can be identified by computer and be used to indicate the participle
Breath.Preferably, the semantic information of participle includes but is not limited at least one of following:
1) synonym and/or synonymous word combination segmented.
For example, the semantic information of participle " weather " includes its synonym " weather " etc..
2) the similar word and/or similar word combination segmented.
Wherein, the similar word of participle indicates to belong to same category of vocabulary with the participle.If participle belongs to place name, then should
The similar word of participle may include other place names.
For example, the semantic information of participle " Shanghai " may include " Beijing ", " Tianjin " etc..
3) there is the entity of same or similar structure with participle.
Wherein, and there is participle the entity of same or similar structure to indicate that the message structure of the entity is identical as participle or phase
Seemingly.Preferably, which can be special semantic formula.
For example, participle is specific time structure " on January 1st, 2,013 10 points 45 minutes ", then have with participle it is identical or
The entity of similar structure can be date semantic formula " XXXX XX month XX day XX point XX minutes " etc..Similar special such as this
Semantic formula may also include name, address, telephone number etc..
It should be noted that the above-mentioned examples are merely illustrative of the technical solutions of the present invention, rather than to limit of the invention
System, it should be appreciated by those skilled in the art that any semantic information that can be identified by computer and be used to indicate a participle,
It should be included in the range of the semantic information of the participle of the invention.
Specifically, various ways can be used in computer equipment, to segment to text sequence to be processed, and obtain it
The semantic information of at least one participle.
For example, various ways can be used to segment to text sequence to be processed in computer equipment, and by institute's score
Word is matched with vocabulary corresponding to preparatory acquired semantic information, so that the semantic information of the vocabulary of successful match be made
For the semantic information etc. of participle.
In another example being segmented and vocabulary progress corresponding to preparatory acquired semantic information in upper example by gained
Match, so that it is determined that after the corresponding semantic information of the vocabulary of successful match, it can also be further combined with participle in text sequence to be processed
Context in column handles the corresponding semantic information of the vocabulary of successful match, so that it is determined that the semantic information etc. of participle.
It should be noted that computer equipment can obtain the language of each participle in all participles of text sequence to be processed
Adopted information;Alternatively, computer equipment can only obtain the semantic information of each participle in the part participle of text sequence to be processed.
Especially some meaningless participles, computer equipment can not obtain the semantic information of the grade participles.
It should be noted that the above-mentioned examples are merely illustrative of the technical solutions of the present invention, rather than to limit of the invention
System it should be appreciated by those skilled in the art that any segment text sequence to be processed, and obtains its at least one participle
Semantic information implementation, should be included in the scope of the present invention.
In step s3, computer equipment carries out matching in predetermined knowledge library and looks into according to the semantic information of each participle
It askes, determines initial answer information corresponding with the semantic information of each participle.Wherein, the predetermined knowledge library include for
The semantic information of participle carries out matched match information, and match information and initial answer information have corresponding relationship.Then calculate
Machine equipment can carry out matching inquiry by the semantic information and match information that will be segmented, to determine the semantic information pair of each participle
The initial answer information answered.It should be noted that as a preferred embodiment, the match information can be formula matching letter certainly
Breath, is also possible to modus tollens match information;If the formula match information certainly indicates the semantic information and the affirmative formula of participle
Match with information or matching degree is higher, then the initial answer information of semantic information is first corresponding to the affirmative formula match information
A possibility that beginning answer information, is higher;If the modus tollens match information indicates that the semantic information of participle matches letter with the modus tollens
Manner of breathing matching or matching degree are higher, then the initial answer information of semantic information is initially to answer corresponding to the modus tollens match information
A possibility that case information, is lower.
Wherein, the initial answer information includes:
1) answer information of user can be provided directly to, can be completely, can be presented directly to user or
The answer information that person is presented to the user after user equipment is run.
For example, plain text, pure multimedia messages, the multimedia messages with extension tag, executable information etc.;Wherein,
The extension tag indicates to select (such as being clicked by user) to link the label of other information, the executable information for user
Including any information that can be run by user equipment, such as function and instruction.
2) it cannot be provided directly to the answer information of user, can be after incomplete, needs further supplement
The answer information that can be presented to the user or be presented to the user after user equipment is run.
For example, the plain text with default item, the pure multimedia messages with default item, with the more of default extensions label
Media information, executable information with default parameter etc..
It should be noted that the above-mentioned examples are merely illustrative of the technical solutions of the present invention, rather than to limit of the invention
System, it should be appreciated by those skilled in the art that any semantic information that can be identified by computer and be used to indicate a participle,
It should be included in the range of the semantic information of the participle of the invention.
Specifically, computer equipment carries out matching inquiry, really according to the semantic information of each participle in predetermined knowledge library
The mode of fixed initial answer information corresponding with the semantic information of each participle includes but is not limited to:
1) match information in predetermined knowledge library includes sentence and/or vocabulary, and multiple sentences and/or vocabulary may make up one
Group corresponds to one or more initial answer informations.Computer equipment will be in the semantic information of each participle and predetermined knowledge library
Match information carries out matching inquiry, determines initial answer information corresponding with the semantic information of each participle.
For example, obtain in step s 2 text information to be processed " 10 yuan of local flow packets how " 10 yuan of " participle
Local flow packet " and " how " and the corresponding semantic information of the two, computer equipment by the semantic information of the two with
Match information in predetermined knowledge library is matched, and determines the semantic information and three sentences " 10 yuan of local flow packets of the two
What the service of offer is ", " I want to ask, you know 10 yuan of local flow packets ", " 10 yuan of local flow packets can be assorted to me
One group of match information that service " is constituted matches, then computer equipment is by the corresponding plain text information " 10 of this group of match information
First local flow packet is the preferential activity of flow released for XX user, you only need to pay 10 yuan of monthly fees, can enjoy ... ",
As with participle " 10 yuan local flow packet " and " how " the corresponding initial answer information of semantic information.
2) match information in predetermined knowledge library includes semantic matches information, and every group of semantic matches information includes one or more
A semantic matches structure.Preferably, a semantic matches structure can also be formula semantic matches structure certainly or modus tollens semantic
Distribution structure;Semantic similarity expressed by one group of semantic matches information.Computer equipment by the semantic information of each participle with it is described
Multiple groups semantic matches information in predetermined knowledge library carries out matching inquiry, and one group of semantic matches information that matching is obtained is corresponding
Initial answer information, as the corresponding initial answer information of institute's semantic information.
Wherein, a semantic matches structure can behave as a semantic formula.Preferably, which includes
But be not limited at least one of following: a) in multiple vocabulary and multiple vocabulary at least one vocabulary semantic information, wherein one
The semantic information of a vocabulary is similar with the semantic information that one segments, and details are not described herein;B) between the multiple vocabulary
Logical relation, such as the sequencing relationship between multiple vocabulary, the qualified relation (modification that a such as vocabulary is another vocabulary
Word) etc..
For example, one group of semantic matches information includes that " [date is related ?] [rain type] is [right for following three semantic matches structures
In] [weather Netherlands] [either with or without] [influence] ", " [weather Netherlands] [weather related] [still] [rain type] " and " [look into
Ask? ] [weather Netherlands] [date is related | the@time? ] [whether? ] [need | can be with? ] [band umbrella] ".Wherein, " | " indicates logic
Or, the semantic information of one vocabulary of content representation and/or the vocabulary in each " [] ", such as " band umbrella " is a vocabulary, " day
Gas Netherlands " refers to the special expression formula etc. of regional class vocabulary.
Preferably, it can be indicated with a typical problem and all semantic matches information phases in one group of semantic matches information
Close natural language meaning, the typical problem may include in predetermined knowledge library, so that operator understands one group of semantic matches
The semanteme of information representation.For example, the typical problem of one group of semantic matches information in upper example comprising three semantic matches structures
Can be " today can rain? "
Specifically, the semantic information of each participle respectively match looking by computer equipment with multiple groups semantic matches information
The corresponding initial answer information of one group of semantic matches information ask, and matching is obtained, it is corresponding just as institute's semantic information
Beginning answer information.
For example, for each semantic matches structure in one group of semantic matches information, computer equipment is by each participle
Semantic information is matched with the semantic information of each vocabulary and/or vocabulary in the semantic matches structure respectively, and combines language
Logical relation in adopted mating structure between each vocabulary determines the semantic information of each participle and of the semantic matches structure
With degree.Similarly, the semantic information and other languages in this group of semantic matches information that computer equipment also determines each participle
Matching degree between adopted mating structure, and then determine the semantic information of each participle and the matching journey of this group of semantic matches information
Degree.Also, computer equipment determine in a similar way each participle semantic information and other multiple groups semantic matches information it
Between matching degree, to determine one group of semantic matches information according to matching degree, and by its corresponding initial answer information,
As the corresponding initial answer information of institute's semantic information.
It should be noted that match information can include semantic matches information and other matchings simultaneously in this implementation
Information, such as sentence.Computer equipment is by the multiple groups semantic matches in the semantic information of each participle and the predetermined knowledge library
Information and other match informations carry out matching inquiry, and the corresponding initial answer of one group of semantic matches information that matching is obtained
Information, as the corresponding initial answer information of institute's semantic information.
3) step S3 further comprises step S31 and step S32.
In step S31, when text sequence to be processed meets preset trigger condition, computer equipment is obtained to provide and is somebody's turn to do
The historical query information of the user equipment of text sequence to be processed.
Wherein, the preset trigger condition may include that any triggering computer equipment that can be used in obtains going through for user equipment
The condition of history query information.For example, text sequence to be processed meet predetermined format and/or text sequence to be processed meet it is pre-
Attribute justice etc..
Wherein, the historical query information of user equipment includes but is not limited to: a) according to the history text sequence of user equipment
Word segmentation result and/or history semantic information of acquisition etc.;B) the history text sequence of user equipment, as inquired before user equipment
The text sequence etc. to be processed crossed, wherein can be by being executed and the same or similar step of step S2 to the history text sequence
Suddenly, history word segmentation result and history semantic information are obtained.
Wherein, computer equipment can identify a user equipment in several ways.For example, according to the login of user or
Registration information identifies user equipment;In another example recording information according to cookie in user equipment etc. to identify that user sets
It is standby;In another example according to the cell-phone number of user equipment or hardware identifier code etc., to identify user equipment.
In step s 32, the historical query information of computer equipment combination user equipment and institute's semantic information, pre-
Determine to carry out matching inquiry in knowledge base, determines the initial answer information.
Wherein, various ways can be used in computer equipment, to combine historical query information and institute's semantic information, pre-
Determine to carry out matching inquiry in knowledge base, determines the initial answer information.
For example, computer equipment first supplements semantic information according to historical query information, such as historical query information
History text sequence comprising user, then computer equipment is included in history text sequence but is not included in currently processed
The semantic information of participle in text sequence is added in current semantic information;Then, further according to the semantic information after supplement
Carry out matching inquiry in predetermined knowledge library, and determine initial answer information etc..
As a preferred embodiment of step S32, the historical query information of user equipment includes the text from user equipment
The history semantic information of this sequence, then computer equipment is according to the history semantic information, to according to currently processed text sequence
The semantic information of the participle of column carries out semantic supplement;And according to the semantic information after semantic supplement, carried out in predetermined knowledge library
Matching inquiry determines the initial answer information.Preferably, computer equipment can also carry out according to history semantic information and work as
The semantic information (hereinafter referred to as " current semantics information ") of the participle of the text sequence of pre-treatment is to determine whether be able to carry out institute
The step of predicate justice complement operation.
For example, computer equipment judges in history semantic information and current semantics information with the presence or absence of similar semantic letter
It ceases (such as whether there are synonym, similar word or entities with similar structure etc.);When there are similar semantic informations for judgement
When, according to the semantic information for being contained in history semantic information and being not included in current semantics information, to current semantics information into
Row supplement, to carry out matching inquiry in predetermined knowledge library according to the semantic information after supplement, determines initial answer information.
Such as be used as a more specific example, history text sequence be " Shanghai rain? ", history semantic information include participle " on
Sea ", the semantic information of " rainy " and " ", currently processed text sequence for " Beijing? ", semantic information includes participle
The semantic information in " Beijing " and " ";Then computer equipment judgement participle " Shanghai " and " ", with participle and " Beijing " and " "
Semantic information participle " rainy " that is similar, and being included in history semantic information and be not included in current semantics information
Semantic information, be added in current semantics information.Then the semantic information after semantic supplement includes " Beijing ", " rainy " and " "
Semantic information.Preferably, computer equipment can also further judge in history semantic information and current semantics information whether
There are similar semantic informations, and this etc. logical relation between similar semantic information also in similar situation, just hold
The operation of row semantic supplement.
It should be noted that step S32 can be with implementation 2) it combines, namely: computer equipment combination user equipment
Historical query information, the multiple groups semantic matches information in the semantic information of each participle and the predetermined knowledge library is carried out
With inquiry, and the corresponding initial answer information of one group of semantic matches information that matching is obtained, it is corresponding as institute's semantic information
Initial answer information.It is highly preferred that computer equipment can be according to the history semantic information, to according to currently processed text
The semantic information of the participle of sequence carries out semantic supplement, and by the semantic information after semantic supplement and the multiple groups in predetermined knowledge library
Semantic matches information carries out matching inquiry, and the corresponding initial answer information of one group of semantic matches information that matching is obtained, and makees
For the corresponding initial answer information of institute's semantic information ".
This preferred embodiment can to user, currently text sequence to be treated be supplemented according to the historical query of user,
So as to which in the incomplete situation of text that user provides, automatic realization semanteme has been mended and has been understood;In addition, by triggering
The condition for obtaining historical query information is limited, and enabling to computer equipment, just starting text supplements in appropriate circumstances
Operation, to prevent or reduce computer equipment because constantly being inquired history the possibility so as to cause collapse.
It should be noted that the above-mentioned examples are merely illustrative of the technical solutions of the present invention, rather than to limit of the invention
System, it should be appreciated by those skilled in the art that any semantic information according to each participle, matching is carried out in predetermined knowledge library and is looked into
It askes, determines the implementation of initial answer information corresponding with the semantic information of each participle, should be included in of the invention
In range.
In step s 4, when the initial answer information that judgement obtains cannot be provided directly to the user equipment, meter
It calculates machine equipment and obtains parameter information from the semantic information of participle.Wherein, the parameter information can to initial answer information into
Row supplement.
Wherein, various ways can be used to judge whether initial answer information can be provided directly to use in computer equipment
Family equipment.
For example, each initial answer information can correspond to a mark, whether which is used to indicate initial answer information and can
Enough it is provided directly to user equipment.Then after computer equipment obtains initial answer information, can directly it be sentenced according to the mark
Whether initial answer information of breaking can be provided directly to user equipment.
In another example computer equipment is predetermined by judging whether the classification of the corresponding match information of initial answer information belongs to
Classification, or directly judge whether initial answer information is in predetermined classification, to judge whether initial answer information can be direct
It is supplied to user equipment.If initial answer information or its corresponding match information belong to weather classification, then judge that it cannot be by
It is supplied directly to described user equipment etc..
In another example computer equipment, which passes through, parses initial answer information, and judge whether it has default item, to judge just
Whether beginning answer information can be provided directly to user equipment.
Wherein, various ways can be used in computer equipment, to obtain parameter information from the semantic information of participle.
For example, the related letter for defining its default item in the initial answer information of user equipment cannot be provided directly to
Breath, such as the expression formula of default item, then computer equipment obtains corresponding according to the relevant information from the semantic information of participle
Parameter information.It is initial that this is defined in the initial answer information such as obtained based on text sequence " today, how is weather " to be processed
The default item of answer information is place name or time, then computer equipment inquires place name class or time class in the semantic information of participle
Participle, and from time class participle " today " semantic information in obtain required time parameter information.
It should be noted that the above-mentioned examples are merely illustrative of the technical solutions of the present invention, rather than to limit of the invention
System, it should be appreciated by those skilled in the art that any initial answer information obtained when judgement cannot be provided directly to the use
When the equipment of family, the implementation of parameter information is obtained from the semantic information of participle, should be included in the scope of the present invention.
In step s 5, computer equipment is handled the initial answer information according to the parameter information, is obtained
For being supplied to the final result information of the user equipment.
Preferably, the final result information includes that can be transmitted directly to user after handling initial answer information
The answer information of equipment.Preferably, final result information includes but is not limited at least one of following:
1) plain text information.
Such as one section of plain text description.
2) pure multimedia messages.
Such as voice, video.
3) with the multimedia messages of extension tag.
Text, video, webpage such as comprising link.
4) information can be performed.
The executable information can be run by user equipment;Preferably, it includes function and instruction etc. that information, which can be performed,.
Specifically, computer equipment can supplement initial answer information according to parameter information, and computer equipment
It can also run directly using the initial answer information after supplement as final result information by the initial answer information after supplement,
And using operation result as final result information.
For example, initial answer information includes plain text " your mood today X ", wherein X indicates the default item of adjectival,
And the parameter information obtained in step s 4 is " fine ", then computer equipment by initial answer information " your after supplement today
It is in high mood ", make final result information directly to be sent to user equipment.
In another example initial answer information includes executable information, it include the default item of time class in the executable information, and
The parameter information obtained in step s 4 is " today ", then computer equipment is according to the time parameter information to initial answer information
After being supplemented, completely executable information is obtained, and it is corresponding to time parameter " today " to obtain to run the executable information
Information final result information the most, and be sent to user equipment.
It should be noted that the above-mentioned examples are merely illustrative of the technical solutions of the present invention, rather than to limit of the invention
System obtains it should be appreciated by those skilled in the art that any handled initial answer information according to parameter information for mentioning
The implementation for supplying the final result information of user equipment, should be included in the scope of the present invention.
It should be noted that when judging that initial answer information obtained can be provided directly to the user equipment
When, initial answer information directly can be sent to the user equipment by computer equipment, so that user equipment is presented to use
Family.
One of preferred embodiment as the present embodiment, predetermined knowledge library include semantic matches information, and one group of semantic matches
The corresponding initial answer information of information can have multiple, then can comprise the further steps of: computer equipment root after step s 3
According to the application message for the application for sending text sequence to be processed in the facility information and/or user equipment of user equipment, from described
Initial answer information is selected in multiple initial answer informations;And step S4 is further are as follows: when judging selected initial answer letter
When breath cannot be provided directly to the user equipment, parameter information is obtained from the semantic information of participle.
Wherein, the facility information of the user equipment includes the facility information of any display that can influence answer information.
For example, the classification of user equipment, such as mobile phone, television set;In another example the display format information etc. that user equipment is supported;Example again
Such as, the current network information of user equipment, such as mobile network or Wi-Fi.
Wherein, the application message includes any information relevant to the display of answer information in the application.For example, using
Title or platform, such as MSN, short message, microblogging, wechat;In another example using the code format etc. of support.
Specifically, computer equipment sends text to be processed according in the facility information and/or user equipment of user equipment
The application message of the application of sequence, from the multiple initial answer information selection be suitable for user equipment and/or application just
Beginning answer information.
For example, including plain text information and the multimedia messages with extension tag in multiple initial answer informations, if then
User equipment is currently connected to Wi-Fi, and computer equipment selects the multimedia messages with extension tag to believe as initial answer
Breath, if user equipment is currently connected to mobile network, computer equipment selects plain text information as initial answer information.
In another example including using the executable information with multiple platforms, then such as sending information in multiple initial answer informations
The application of sequence is microblogging, then the executable information for selecting microblogging to support is as initial answer information etc..
It should be noted that the above-mentioned examples are merely illustrative of the technical solutions of the present invention, rather than to limit of the invention
System, it should be appreciated by those skilled in the art that being sent in any facility information and/or user equipment according to user equipment to be processed
The application message of the application of text sequence selects the implementation of initial answer information from the multiple initial answer information,
It should be included in the scope of the present invention.
In the present embodiment, by carrying out better semantic understanding to text sequence, it is capable of providing more accurate answer information.
Fig. 2 is the method flow diagram of the creation instances of ontology of a preferred embodiment of the invention.The method packet of the present embodiment
Include step S6 and step S7.In the present embodiment, predetermined knowledge library includes instances of ontology, at least one attribute of the instances of ontology
In each attribute include one group of semantic matches information and initial answer information corresponding with the semantic matches information.It needs to illustrate
, an ontology example can have multiple attributes, and each attribute may also include other information, such as typical problem, attribute type
Deng.
In step s 6, computer equipment obtains the example item of an ontology, wherein at least one attribute of the ontology
In each attribute include ontology answer information and one group of semantic matches information with default item.Preferably, ontology answer
Information can also have default item.
Wherein, the example item of ontology indicates a specific example of the default item of the ontology.For example, one group of ontology is semantic
Default item in match information is XX, and such as " [XX] rate ", then as a specific example of XX, the example item of ontology is
“3G”。
Wherein, various ways can be used to obtain the example item of ontology in computer equipment.As being manually entered or in advance
Example item first stored etc..
In the step s 7, computer equipment carries out the default item in the attribute of the ontology according to the example item of ontology
Processing obtains the instances of ontology for inheriting whole attributes of the ontology.
For example, the attribute of ontology includes ontology answer information and one group of semantic matches information, this group of semantic matches information
Comprising below with default item semantic matches structure " [XXX] [charge | payment | charging] [method] ", " [XXX] is [how many
Money] ", " [XXX] [charge | payment | rate | deduct fees | payment | charging] [standard | situation] " and sentence " XXX is expensive ", ontology
Example item be " walk in the Divine Land ", then the example item of ontology is supplemented in each default item of Noumenon property by computer equipment, is obtained
Whole attributes of ontology must be inherited, such as inherit ontology whole semantic matches information, instances of ontology, the attribute of the instances of ontology
Including as the ontology answer information of initial answer information and one group of semantic matches information, this group of semantic matches information include with
Down the semantic matches structure with default item " [walk in the Divine Land] [charge | payment | charging] [method] ", " [walk in the Divine Land] is [how many
Money] ", " [walk in the Divine Land] [and charge | payment | rate | deduct fees | payment | charging] [standard | situation] " and sentence " walk in the Divine Land is expensive
".
Preferably, if ontology answer information has default item, computer equipment can also be according to the example item of ontology, to institute
The default item stated in ontology answer information is handled, and initial answer information is obtained.
It should be noted that sub- ontology of the ontology if another ontology, then the sub- ontology can also be inherited belonging to it
The all properties of ontology.The implementation is similar to abovementioned steps S6 and S7, and so it will not be repeated.
In the present embodiment, for a large amount of instances of ontology with like attribute, without for each instances of ontology repeatability
Attribute is established on ground, and can easily be created new instances of ontology by way of inheriting all properties of ontology, be significantly reduced
Resource consumption during instances of ontology creation.
Fig. 3 is the structural schematic diagram of the question and answer system of the acquisition answer information of a preferred embodiment of the invention.This implementation
The question and answer system of example may be included in computer equipment, which includes the first acquisition device 1, semantic device 2, inquiry dress
Set the 3, second acquisition device 4 and third acquisition device 5.
First acquisition device 1 obtains the text sequence to be processed from user equipment.
Wherein, which can be the text sequence that user directly inputs, and can also be to input to user
Voice resulting text sequence after being identified.
For example, user inputs " today, how is weather " in dialog box, and presses and send key to indicate that user equipment will
" today, how is weather " is sent to computer equipment, then " today, how is weather " is the text to be processed from user equipment
Sequence.
In another example user inputs one section of voice in some application, this section of voice is sent to by the application via internet
Computer equipment, the first acquisition device 1 identify the voice simultaneously obtain text sequence " today, how is weather ", then " today weather such as
What " it is the text sequence to be processed from user equipment.
It should be noted that the above-mentioned examples are merely illustrative of the technical solutions of the present invention, rather than to limit of the invention
System, it should be appreciated by those skilled in the art that any implementation for obtaining the text sequence to be processed from user equipment,
It should within the scope of the present invention.
Then, semantic device 2 segments text sequence to be processed, and obtains the semantic letter of its at least one participle
Breath.
Wherein, the semantic information of participle includes any semantic letter that can be identified by computer and be used to indicate the participle
Breath.Preferably, the semantic information of participle includes but is not limited at least one of following:
1) synonym and/or synonymous word combination segmented.
For example, the semantic information of participle " weather " includes its synonym " weather " etc..
2) the similar word and/or similar word combination segmented.
Wherein, the similar word of participle indicates to belong to same category of vocabulary with the participle.If participle belongs to place name, then should
The similar word of participle may include other place names.
For example, the semantic information of participle " Shanghai " may include " Beijing ", " Tianjin " etc..
3) there is the entity of same or similar structure with participle.
Wherein, and there is participle the entity of same or similar structure to indicate that the message structure of the entity is identical as participle or phase
Seemingly.Preferably, which can be special semantic formula.
For example, participle is specific time structure " on January 1st, 2,013 10 points 45 minutes ", then have with participle it is identical or
The entity of similar structure can be date semantic formula " XXXX XX month XX day XX point XX minutes " etc..Similar special such as this
Semantic formula may also include name, address, telephone number etc..
It should be noted that the above-mentioned examples are merely illustrative of the technical solutions of the present invention, rather than to limit of the invention
System, it should be appreciated by those skilled in the art that any semantic information that can be identified by computer and be used to indicate a participle,
It should be included in the range of the semantic information of the participle of the invention.
Specifically, various ways can be used in semantic device 2, to segment to text sequence to be processed, and obtain it
The semantic information of at least one participle.
For example, various ways can be used to segment to text sequence to be processed in semantic device 2, and gained is segmented
Matched with vocabulary corresponding to preparatory acquired semantic information, thus using the semantic information of the vocabulary of successful match as
The semantic information etc. of participle.
In another example being segmented and vocabulary progress corresponding to preparatory acquired semantic information in upper example by gained
Match, so that it is determined that the corresponding semantic information of the vocabulary of successful match, semantic device 2 can also be further combined with participle to be processed
Context in text sequence handles the corresponding semantic information of the vocabulary of successful match, so that it is determined that the semantic letter of participle
Breath etc..
It should be noted that semantic device 2 can obtain the language of each participle in all participles of text sequence to be processed
Adopted information;Alternatively, semantic device 2 can only obtain the semantic information of each participle in the part participle of text sequence to be processed.
Especially some meaningless participles, semantic device 2 can not obtain the semantic information of the grade participles.
It should be noted that the above-mentioned examples are merely illustrative of the technical solutions of the present invention, rather than to limit of the invention
System it should be appreciated by those skilled in the art that any segment text sequence to be processed, and obtains its at least one participle
Semantic information implementation, should be included in the scope of the present invention.
Inquiry unit 3 carries out matching inquiry according to the semantic information of each participle in predetermined knowledge library, it is determining with it is each
The corresponding initial answer information of the semantic information of participle.Wherein, the predetermined knowledge library includes believing for the semanteme with participle
Breath carries out matched match information, and match information and initial answer information have corresponding relationship.Then inquiry unit 3 can pass through by
The semantic information and match information of participle carry out matching inquiry, the corresponding initial answer letter of the semantic information to determine each participle
Breath.It should be noted that as a preferred embodiment, the match information can be formula match information certainly, it is also possible to no
Fixed pattern match information;If it is described certainly formula match information indicate participle semantic information and the affirmative formula match information match or
Matching degree is higher, then the initial answer information of semantic information be the affirmative formula match information corresponding to initial answer information can
Energy property is higher;If the modus tollens match information indicates that the semantic information of participle matches or matches with the modus tollens match information
A possibility that degree is higher, then the initial answer information of semantic information is initial answer information corresponding to the modus tollens match information
It is lower.
Wherein, the initial answer information includes:
1) answer information of user can be provided directly to, can be completely, can be presented directly to user or
The answer information that person is presented to the user after user equipment is run.
For example, plain text, pure multimedia messages, the multimedia messages with extension tag, executable information etc.;Wherein,
The extension tag indicates to select (such as being clicked by user) to link the label of other information, the executable information for user
Including any information that can be run by user equipment, such as function and instruction.
2) it cannot be provided directly to the answer information of user, can be after incomplete, needs further supplement
The answer information that can be presented to the user or be presented to the user after user equipment is run.
For example, the plain text with default item, the pure multimedia messages with default item, with the more of default extensions label
Media information, executable information with default parameter etc..
It should be noted that the above-mentioned examples are merely illustrative of the technical solutions of the present invention, rather than to limit of the invention
System, it should be appreciated by those skilled in the art that any semantic information that can be identified by computer and be used to indicate a participle,
It should be included in the range of the semantic information of the participle of the invention.
Specifically, inquiry unit 3 carries out matching inquiry, really according to the semantic information of each participle in predetermined knowledge library
The mode of fixed initial answer information corresponding with the semantic information of each participle includes but is not limited to:
1) match information in predetermined knowledge library includes sentence and/or vocabulary, and multiple sentences and/or vocabulary may make up one
Group corresponds to one or more initial answer informations.Inquiry unit 3 will be in the semantic information of each participle and predetermined knowledge library
Match information carries out matching inquiry, determines initial answer information corresponding with the semantic information of each participle.
For example, semantic device 2 obtain text information to be processed " 10 yuan of local flow packets how " participle " 10 yuan of sheets
Ground flow packet " and " how " and the corresponding semantic information of the two, inquiry unit 3 is by the semantic information of the two and makes a reservation for
Match information in knowledge base is matched, and determines the semantic information and " the 10 yuan of local flow packets offers of three sentences of the two
Service what is ", " I want to ask, you know 10 yuan of local flow packets ", " 10 yuan of local flow packets can give me what clothes
One group of match information that business " is constituted matches, then inquiry unit 3 is by this group of match information corresponding plain text information " 10 yuan of sheets
Ground flow packet is the preferential activity of flow released for XX user, you only need to pay 10 yuan of monthly fees, can enjoy ... ", as
With participle " 10 yuan local flow packet " and " how " the corresponding initial answer information of semantic information.
2) match information in predetermined knowledge library includes semantic matches information, and every group of semantic matches information includes one or more
A semantic matches structure.Preferably, a semantic matches structure can also be formula semantic matches structure certainly or modus tollens semantic
Distribution structure;Semantic similarity expressed by one group of semantic matches information.Inquiry unit 3 includes the first subquery device (not shown),
The first subquery device carries out the multiple groups semantic matches information in the semantic information of each participle and the predetermined knowledge library
Matching inquiry, and the corresponding initial answer information of one group of semantic matches information that matching is obtained, as institute's semantic information pair
The initial answer information answered.
Wherein, a semantic matches structure can behave as a semantic formula.Preferably, which includes
But be not limited at least one of following: a) in multiple vocabulary and multiple vocabulary at least one vocabulary semantic information, wherein one
The semantic information of a vocabulary is similar with the semantic information that one segments, and details are not described herein;B) between the multiple vocabulary
Logical relation, such as the sequencing relationship between multiple vocabulary, the qualified relation (modification that a such as vocabulary is another vocabulary
Word) etc..
For example, one group of semantic matches information includes that " [date is related ?] [rain type] is [right for following three semantic matches structures
In] [weather Netherlands] [either with or without] [influence] ", " [weather Netherlands] [weather related] [still] [rain type] " and " [look into
Ask? ] [weather Netherlands] [date is related | the@time? ] [whether? ] [need | can be with? ] [band umbrella] ".Wherein, " | " indicates logic
Or, the semantic information of one vocabulary of content representation and/or the vocabulary in each " [] ", such as " band umbrella " is a vocabulary, " day
Gas Netherlands " refers to the special expression formula etc. of regional class vocabulary.
Preferably, it can be indicated with a typical problem and all semantic matches information phases in one group of semantic matches information
Close natural language meaning, the typical problem may include in predetermined knowledge library, so that operator understands one group of semantic matches
The semanteme of information representation.For example, the typical problem of one group of semantic matches information in upper example comprising three semantic matches structures
Can be " today can rain? "
Specifically, the first subquery device carries out the semantic information of each participle and multiple groups semantic matches information respectively
With inquiry, and the corresponding initial answer information of one group of semantic matches information that matching is obtained, it is corresponding as institute's semantic information
Initial answer information.
For example, the first subquery device is by each point for each semantic matches structure in one group of semantic matches information
The semantic information of word is matched with the semantic information of each vocabulary and/or vocabulary in the semantic matches structure respectively, and is tied
The logical relation in semantic matches structure between each vocabulary is closed, determines the semantic information and the semantic matches structure of each participle
Matching degree.Similarly, the first subquery device also determines in the semantic information and this group of semantic matches information of each participle
Other semantic matches structures between matching degree, and then determine the semantic information and this group of semantic matches information of each participle
Matching degree.Also, the first subquery device determines the semantic information and other multiple groups languages of each participle in a similar way
Matching degree between adopted match information, to determine one group of semantic matches information according to matching degree, and its is corresponding
Initial answer information, as the corresponding initial answer information of institute's semantic information.
It should be noted that match information can include semantic matches information and other matchings simultaneously in this implementation
Information, such as sentence.Computer equipment is by the multiple groups semantic matches in the semantic information of each participle and the predetermined knowledge library
Information and other match informations carry out matching inquiry, and the corresponding initial answer of one group of semantic matches information that matching is obtained
Information, as the corresponding initial answer information of institute's semantic information.
3) inquiry unit 3 further comprises history acquisition device (not shown) and the second subquery device (not shown).
When text sequence to be processed meets preset trigger condition, history acquisition device, which obtains, provides the text to be processed
The historical query information of the user equipment of this sequence.
Wherein, the preset trigger condition may include that any triggering computer equipment that can be used in obtains going through for user equipment
The condition of history query information.For example, text sequence to be processed meet predetermined format and/or text sequence to be processed meet it is pre-
Attribute justice etc..
Wherein, the historical query information of user equipment includes but is not limited to: a) according to the history text sequence of user equipment
Word segmentation result and/or history semantic information of acquisition etc.;B) the history text sequence of user equipment, as inquired before user equipment
The text sequence etc. to be processed crossed, wherein semantic device 2 can be by executing and text to be processed the history text sequence
The same or similar step of sequence obtains history word segmentation result and history semantic information.
Wherein, history acquisition device can identify a user equipment in several ways.For example, according to the login of user
Or registration information identifies user equipment;In another example recording information according to cookie in user equipment etc. to identify user
Equipment;In another example according to the cell-phone number of user equipment or hardware identifier code etc., to identify user equipment.
The historical query information and institute's semantic information of second subquery device combination user equipment, in predetermined knowledge library
Middle carry out matching inquiry, determines the initial answer information.
Wherein, various ways can be used in the second subquery device, to combine historical query information and institute's semantic information,
Matching inquiry is carried out in predetermined knowledge library, determines the initial answer information.
For example, the second subquery device first supplements semantic information according to historical query information, such as historical query
Information includes the history text sequence of user, then the second subquery device is included in history text sequence but is not included in work as
The semantic information of participle in the text sequence of pre-treatment is added in current semantic information;Then, the second subquery device
Carry out matching inquiry in predetermined knowledge library further according to the semantic information after supplement, and determine initial answer information etc..
As a preferred embodiment of the second subquery device, the second subquery device include supplementary device (not shown) and
Third subquery device (not shown).The historical query information of user equipment includes the history of the text sequence from user equipment
Semantic information, then supplementary device is according to the history semantic information, to the semanteme according to the participle of currently processed text sequence
Information carries out semantic supplement;Third subquery device is according to the semantic information after semantic supplement, the progress in predetermined knowledge library
With inquiry, the initial answer information is determined.Preferably, supplementary device can also carry out according to history semantic information and current place
The semantic information (hereinafter referred to as " current semantics information ") of the participle of the text sequence of reason is to determine whether be able to carry out institute's predicate
The step of adopted complement operation.
For example, supplementary device judges in history semantic information and current semantics information with the presence or absence of similar semantic information
(such as whether there are synonym, similar word or entities with similar structure etc.);When judgement is there are when similar semantic information,
According to the semantic information for being contained in history semantic information and being not included in current semantics information, current semantics information is mended
It fills, third subquery device carries out matching inquiry according to the semantic information after supplement in predetermined knowledge library, determines initial answer
Information.Such as be used as a more specific example, history text sequence be " Shanghai rain? ", history semantic information includes point
Word " Shanghai ", " rainy " and " " semantic information, currently processed text sequence be " Beijing? ", semantic information includes
Segment the semantic information in " Beijing " and " ";Then supplementary device judgement participle " Shanghai " and " ", with segment and " Beijing " and
The semantic information of " " is similar, and the participle for being included in history semantic information and being not included in current semantics information
The semantic information of " rainy " is added in current semantics information.Then the semantic information after semantic supplement includes " Beijing ", " rainy "
The semantic information of " ".Preferably, supplementary device can also further judge in history semantic information and current semantics information
With the presence or absence of similar semantic information, and this etc. logical relation between similar semantic information also in similar situation,
Just execute the operation of semantic supplement.
It should be noted that the first subquery device can be combined with the second subquery device, and namely: in conjunction with user equipment
Historical query information, the multiple groups semantic matches information in the semantic information of each participle and the predetermined knowledge library is carried out
With inquiry, and the corresponding initial answer information of one group of semantic matches information that matching is obtained, it is corresponding as institute's semantic information
Initial answer information.It is highly preferred that can be according to the history semantic information, to the participle according to currently processed text sequence
Semantic information carry out semantic supplement, and by after semantic supplement semantic information and predetermined knowledge library in multiple groups semantic matches believe
Breath carries out matching inquiry, and the corresponding initial answer information of one group of semantic matches information that matching is obtained, as the semanteme
The corresponding initial answer information of information ".
This preferred embodiment can to user, currently text sequence to be treated be supplemented according to the historical query of user,
So as to which in the incomplete situation of text that user provides, automatic realization semanteme has been mended and has been understood;In addition, by triggering
The condition for obtaining historical query information is limited, and enabling to computer equipment, just starting text supplements in appropriate circumstances
Operation, to prevent or reduce computer equipment because constantly being inquired history the possibility so as to cause collapse.
It should be noted that the above-mentioned examples are merely illustrative of the technical solutions of the present invention, rather than to limit of the invention
System, it should be appreciated by those skilled in the art that any semantic information according to each participle, matching is carried out in predetermined knowledge library and is looked into
It askes, determines the implementation of initial answer information corresponding with the semantic information of each participle, should be included in of the invention
In range.
When the initial answer information that judgement obtains cannot be provided directly to the user equipment, the second acquisition device 4
Parameter information is obtained from the semantic information of participle.Wherein, the parameter information can supplement initial answer information.
Wherein, various ways can be used to judge whether initial answer information can be provided directly in the second acquisition device 4
To user equipment.
For example, each initial answer information can correspond to a mark, whether which is used to indicate initial answer information and can
Enough it is provided directly to user equipment.Then after inquiry unit 3 obtains initial answer information, the second acquisition device 4 can direct root
Judge whether initial answer information can be provided directly to user equipment according to the mark.
In another example the second acquisition device 4 is by judging whether the classification of the corresponding match information of initial answer information belongs to
Predetermined classification, or directly judge whether initial answer information is in predetermined classification, to judge whether initial answer information can be by
It is supplied directly to user equipment.If initial answer information or its corresponding match information belong to weather classification, then judge it not
Described user equipment etc. can be provided directly to.
In another example the second acquisition device 4, which passes through, parses initial answer information, and judge whether it has default item, to sentence
Whether initial answer information of breaking can be provided directly to user equipment.
Wherein, various ways can be used in the second acquisition device 4, to obtain parameter information from the semantic information of participle.
For example, the related letter for defining its default item in the initial answer information of user equipment cannot be provided directly to
Breath, such as the expression formula of default item, then the second acquisition device 4 obtains phase from the semantic information of participle according to the relevant information
The parameter information answered.This is defined in the initial answer information such as obtained based on text sequence " today, how is weather " to be processed
The default item of initial answer information is place name or time, then the second acquisition device 4 inquires place name class in the semantic information of participle
Or the participle of time class, and required time parameter information is obtained from the semantic information of time class participle " today ".
It should be noted that the above-mentioned examples are merely illustrative of the technical solutions of the present invention, rather than to limit of the invention
System, it should be appreciated by those skilled in the art that any initial answer information obtained when judgement cannot be provided directly to the use
When the equipment of family, the implementation of parameter information is obtained from the semantic information of participle, should be included in the scope of the present invention.
Third acquisition device 5 is handled the initial answer information according to the parameter information, is obtained for providing
To the final result information of the user equipment.
Preferably, the final result information includes that can be transmitted directly to user after handling initial answer information
The answer information of equipment.Preferably, final result information includes but is not limited at least one of following:
1) plain text information.
Such as one section of plain text description.
2) pure multimedia messages.
Such as voice, video.
3) with the multimedia messages of extension tag.
Text, video, webpage such as comprising link.
4) information can be performed.
The executable information can be run by user equipment;Preferably, it includes function and instruction etc. that information, which can be performed,.
Specifically, third acquisition device 5 can supplement initial answer information according to parameter information, and third obtains
Device 5 can also be run directly using the initial answer information after supplement as final result information by the initial answer after supplement
Information, and using operation result as final result information.
For example, initial answer information includes plain text " your mood today X ", wherein X indicates the default item of adjectival,
And second the parameter information that obtains of acquisition device 4 be " fine ", then third acquisition device 5 is by the initial answer information after supplement
" you are in high mood today " makees final result information directly to be sent to user equipment.
In another example initial answer information includes executable information, it include the default item of time class in the executable information, and
The parameter information that second acquisition device 4 obtains is " today ", then third acquisition device 5 is according to the time parameter information to initially answering
After case information is supplemented, completely executable information is obtained, and it is " modern with time parameter to obtain to run the executable information
It " corresponding information final result information the most, and it is sent to user equipment.
It should be noted that the above-mentioned examples are merely illustrative of the technical solutions of the present invention, rather than to limit of the invention
System obtains it should be appreciated by those skilled in the art that any handled initial answer information according to parameter information for mentioning
The implementation for supplying the final result information of user equipment, should be included in the scope of the present invention.
It should be noted that when judging that initial answer information obtained can be provided directly to the user equipment
When, initial answer information directly can be sent to the user equipment by the sending device (not shown) in question and answer system, for
Family equipment is presented to user.
One of preferred embodiment as the present embodiment, predetermined knowledge library include semantic matches information, and one group of semantic matches
The corresponding initial answer information of information can have multiple, then question and answer system further includes the choosing that operation is executed after inquiry unit 3
Device (not shown) is selected, changes selection device according in the facility information and/or user equipment of user equipment and sends text to be processed
The application message of the application of sequence selects initial answer information from the multiple initial answer information;Second acquisition device 4 into
One step includes parameter obtaining device (not shown), when judging that selected initial answer information cannot be provided directly to the use
When the equipment of family, parameter obtaining device obtains parameter information from the semantic information of participle.
Wherein, the facility information of the user equipment includes the facility information of any display that can influence answer information.
For example, the classification of user equipment, such as mobile phone, television set;In another example the display format information etc. that user equipment is supported;Example again
Such as, the current network information of user equipment, such as mobile network or Wi-Fi.
Wherein, the application message includes any information relevant to the display of answer information in the application.For example, using
Title or platform, such as MSN, short message, microblogging, wechat;In another example using the code format etc. of support.
Specifically, selection device is according to sending text sequence to be processed in the facility information and/or user equipment of user equipment
The application message of the application of column, selection is suitable for the initial of user equipment and/or application from the multiple initial answer information
Answer information.
For example, including plain text information and the multimedia messages with extension tag in multiple initial answer informations, if then
User equipment is currently connected to Wi-Fi, and selection device selects the multimedia messages with extension tag as initial answer information,
If user equipment is currently connected to mobile network, selection device selects plain text information as initial answer information.
In another example including using the executable information with multiple platforms, then such as sending information in multiple initial answer informations
The application of sequence is microblogging, and the executable information that selection device selects microblogging to support is as initial answer information etc..
It should be noted that the above-mentioned examples are merely illustrative of the technical solutions of the present invention, rather than to limit of the invention
System, it should be appreciated by those skilled in the art that being sent in any facility information and/or user equipment according to user equipment to be processed
The application message of the application of text sequence selects the implementation of initial answer information from the multiple initial answer information,
It should be included in the scope of the present invention.
In the present embodiment, by carrying out better semantic understanding to text sequence, it is capable of providing more accurate answer information.
Fig. 4 is the structural schematic diagram of the question and answer system of the creation instances of ontology of a preferred embodiment of the invention.This implementation
The question and answer system of example may be included in computer equipment, which includes the 4th acquisition device 6 and example generating means 7.
In the present embodiment, predetermined knowledge library includes instances of ontology, and each attribute at least one attribute of the instances of ontology includes
One group of semantic matches information and initial answer information corresponding with the semantic matches information.It should be noted that an ontology shows
Example can have multiple attributes, and each attribute may also include other information, such as typical problem, attribute type.
4th acquisition device 6 obtains the example item of an ontology, wherein each of at least one attribute of the ontology
Attribute includes ontology answer information and one group of semantic matches information with default item.Preferably, ontology answer information can also
With default item.
Wherein, the example item of ontology indicates a specific example of the default item of the ontology.For example, one group of ontology is semantic
Default item in match information is XX, and such as " [XX] rate ", then as a specific example of XX, the example item of ontology is
“3G”。
Wherein, various ways can be used to obtain the example item of ontology in the 4th acquisition device 6.As being manually entered or
Pre-stored example item etc..
Example generating means 7 are handled the default item in the attribute of the ontology according to the example item of ontology, are obtained
Inherit the instances of ontology of whole attributes of the ontology.
For example, the attribute of ontology includes ontology answer information and one group of semantic matches information, this group of semantic matches information
Comprising below with default item semantic matches structure " [XXX] [charge | payment | charging] [method] ", " [XXX] is [how many
Money] ", " [XXX] [charge | payment | rate | deduct fees | payment | charging] [standard | situation] " and sentence " XXX is expensive ", ontology
Example item be " walk in the Divine Land ", then the example item of ontology is supplemented in each default item of Noumenon property by example generating means 7,
Obtain inherit ontology whole attributes, such as inherit ontology whole semantic matches information, instances of ontology, the category of the instances of ontology
Property includes as the ontology answer information of initial answer information and one group of semantic matches information, this group of semantic matches information includes
Below the semantic matches structure with default item " [walk in the Divine Land] [charge | payment | charging] [method] ", " [walk in the Divine Land] is [how many
Money] ", " [walk in the Divine Land] [and charge | payment | rate | deduct fees | payment | charging] [standard | situation] " and sentence " walk in the Divine Land is expensive
".
Preferably, if ontology answer information have default item, example generating means 7 can also according to the example item of ontology,
Default item in the ontology answer information is handled, initial answer information is obtained.
It should be noted that sub- ontology of the ontology if another ontology, then the sub- ontology can also be inherited belonging to it
The all properties of ontology.The implementation is similar to the operation that the 4th acquisition device 6 and example generating means 7 execute, therefore no longer
It repeats.
In the present embodiment, for a large amount of instances of ontology with like attribute, without for each instances of ontology repeatability
Attribute is established on ground, and can easily be created new instances of ontology by way of inheriting all properties of ontology, be significantly reduced
Resource consumption during instances of ontology creation.
It should be noted that the present invention can be carried out in the assembly of software and/or software and hardware, for example, this hair
Specific integrated circuit (ASIC) can be used in bright each device or any other is realized similar to hardware device.In one embodiment
In, software program of the invention can be executed to implement the above steps or functions by processor.Similarly, of the invention
Software program (including relevant data structure) can be stored in computer readable recording medium, for example, RAM memory,
Magnetic or optical driver or floppy disc and similar devices.In addition, some of the steps or functions of the present invention may be implemented in hardware, example
Such as, as the circuit cooperated with processor thereby executing each step or function.
It is obvious to a person skilled in the art that invention is not limited to the details of the above exemplary embodiments, Er Qie
In the case where without departing substantially from spirit or essential attributes of the invention, the present invention can be realized in other specific forms.Therefore, no matter
From the point of view of which point, the present embodiments are to be considered as illustrative and not restrictive, and the scope of the present invention is by appended power
Benefit requires rather than above description limits, it is intended that all by what is fallen within the meaning and scope of the equivalent elements of the claims
Variation is included in the present invention.Any reference signs in the claims should not be construed as limiting the involved claims.This
Outside, it is clear that one word of " comprising " does not exclude other units or steps, and odd number is not excluded for plural number.That states in system claims is multiple
Unit or device can also be implemented through software or hardware by a unit or device.The first, the second equal words are used to table
Show title, and does not indicate any particular order.
Claims (10)
1. a kind of computer readable recording medium, is stored thereon with software program, which is characterized in that the program is executed by processor
The method that Shi Shixian obtains answer information, the described method comprises the following steps:
A obtains the text sequence to be processed from user equipment;
B segments the text sequence, and obtains the semantic information of its at least one participle;
C carries out matching inquiry according to institute's semantic information in predetermined knowledge library, determines that institute's semantic information is corresponding and initially answers
Case information;
Wherein, this method is further comprising the steps of:
D is obtained from institute's semantic information when judging that the initial answer information cannot be provided directly to the user equipment
Obtain parameter information;
E is handled the initial answer information according to the parameter information, is obtained for being supplied to the user equipment
Final result information.
2. computer readable recording medium according to claim 1, wherein the step c the following steps are included:
Multiple groups semantic matches information in institute's semantic information and the predetermined knowledge library is subjected to matching inquiry, and will matching
The obtained corresponding initial answer information of one group of semantic matches information, as the corresponding initial answer information of institute's semantic information,
Wherein, every group of semantic matches information includes one or more semantic matches structures.
3. computer readable recording medium according to claim 2, wherein the semantic matches structure include it is following at least
One:
The semantic information of at least one vocabulary in multiple vocabulary and multiple vocabulary;
Logical relation between the multiple vocabulary.
4. computer readable recording medium according to claim 2 or 3, wherein one group of semantic matches information is corresponding just
Beginning answer information have it is multiple, this method is further comprising the steps of after the step c:
According to the facility information of the user equipment and/or the application message for the application for sending the text sequence, from described more
Initial answer information is selected in a initial answer information;
Wherein, the step d the following steps are included:
When judging that selected initial answer information cannot be provided directly to the user equipment, from institute's semantic information
Middle acquisition parameter information.
5. computer readable recording medium according to claim 2 or 3, wherein the predetermined knowledge library includes ontology reality
Example, at least one attribute of the instances of ontology each of including one group of semantic matches information and with the semantic matches information pair
The initial answer information answered, this method are further comprising the steps of:
X obtains the example item of an ontology, wherein each of at least one attribute of the ontology includes ontology answer information
And one group of semantic matches information with default item;
Y is handled the default item in the attribute of the ontology according to the example item, obtains the whole for inheriting the ontology
The instances of ontology of attribute.
6. computer readable recording medium according to claim 1, wherein the step c the following steps are included:
C1 obtains the historical query information of the user equipment when the text sequence meets preset trigger condition;
C2 carries out matching inquiry in predetermined knowledge library, determines institute in conjunction with the historical query information and institute's semantic information
State initial answer information.
7. computer readable recording medium according to claim 6, wherein the historical query information includes from described
The history semantic information of the text sequence of user equipment, the step c2 the following steps are included:
According to the history semantic information, semantic supplement is carried out to institute's semantic information;
According to the semantic information after semantic supplement, matching inquiry is carried out in predetermined knowledge library, determines the initial answer letter
Breath.
8. method according to any one of claim 1 to 7, wherein this method is further comprising the steps of:
When judging that the initial answer information can be provided directly to the user equipment, by the initial answer information
It is sent to the user equipment.
9. method according to any one of claim 1 to 8, wherein institute's semantic information includes at least one of the following:
The synonym and/or synonymous word combination of participle;
The similar word and/or similar word combination of participle;
There is the entity of same or similar structure with participle;
The final result information includes at least one of the following:
Executable information;
Multimedia messages with extension tag.
10. a kind of computer equipment, including computer readable recording medium as claimed in any one of claims 1-9 wherein, processing
Device and storage are on a computer readable recording medium and the software program that can run on a processor.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810677005.6A CN108984650B (en) | 2014-03-26 | 2014-03-26 | Computer-readable recording medium and computer device |
Applications Claiming Priority (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201410117635.XA CN104951456B (en) | 2014-03-26 | 2014-03-26 | A kind of method, apparatus and equipment for obtaining answer information |
CN201810677005.6A CN108984650B (en) | 2014-03-26 | 2014-03-26 | Computer-readable recording medium and computer device |
Related Parent Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201410117635.XA Division CN104951456B (en) | 2014-03-26 | 2014-03-26 | A kind of method, apparatus and equipment for obtaining answer information |
Publications (2)
Publication Number | Publication Date |
---|---|
CN108984650A true CN108984650A (en) | 2018-12-11 |
CN108984650B CN108984650B (en) | 2020-10-16 |
Family
ID=54166119
Family Applications (2)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201410117635.XA Active CN104951456B (en) | 2014-03-26 | 2014-03-26 | A kind of method, apparatus and equipment for obtaining answer information |
CN201810677005.6A Active CN108984650B (en) | 2014-03-26 | 2014-03-26 | Computer-readable recording medium and computer device |
Family Applications Before (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201410117635.XA Active CN104951456B (en) | 2014-03-26 | 2014-03-26 | A kind of method, apparatus and equipment for obtaining answer information |
Country Status (1)
Country | Link |
---|---|
CN (2) | CN104951456B (en) |
Families Citing this family (15)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN105653576A (en) * | 2015-12-16 | 2016-06-08 | 上海智臻智能网络科技股份有限公司 | Information searching method and apparatus, manual position service method and system |
CN105912575B (en) * | 2016-03-31 | 2020-05-15 | 百度在线网络技术(北京)有限公司 | Text information pushing method and device |
CN106095988A (en) * | 2016-06-21 | 2016-11-09 | 上海智臻智能网络科技股份有限公司 | Automatic question-answering method and device |
CN106357942A (en) * | 2016-10-26 | 2017-01-25 | 广州佰聆数据股份有限公司 | Intelligent response method and system based on context dialogue semantic recognition |
CN108154735A (en) * | 2016-12-06 | 2018-06-12 | 爱天教育科技(北京)有限公司 | Oral English Practice assessment method and device |
CN106980652B (en) * | 2017-03-03 | 2020-09-08 | 竹间智能科技(上海)有限公司 | Intelligent question and answer method and system |
CN107526827A (en) * | 2017-09-01 | 2017-12-29 | 上海连尚网络科技有限公司 | Method, equipment and computer-readable recording medium for question and answer displaying |
CN107766567B (en) * | 2017-11-08 | 2020-04-21 | 北京交通大学 | Entity extension method of network table |
CN107943896A (en) * | 2017-11-16 | 2018-04-20 | 百度在线网络技术(北京)有限公司 | Information processing method and device |
CN109903754B (en) * | 2017-12-08 | 2022-04-26 | 北京京东尚科信息技术有限公司 | Method, device and memory device for speech recognition |
CN108446322B (en) * | 2018-02-10 | 2022-03-25 | 灯塔财经信息有限公司 | Method and device for realizing intelligent question-answering system |
CN108491506A (en) * | 2018-03-22 | 2018-09-04 | 上海连尚网络科技有限公司 | Method for pushing problem answers combination |
CN112347196B (en) * | 2019-08-06 | 2023-05-23 | 上海智臻智能网络科技股份有限公司 | Entity relation extraction method and device based on neural network |
CN110929014B (en) * | 2019-12-09 | 2023-05-23 | 联想(北京)有限公司 | Information processing method, information processing device, electronic equipment and storage medium |
CN117076651A (en) * | 2023-10-16 | 2023-11-17 | 彩讯科技股份有限公司 | Method, device, equipment and computer readable storage medium for processing interaction information |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US6189002B1 (en) * | 1998-12-14 | 2001-02-13 | Dolphin Search | Process and system for retrieval of documents using context-relevant semantic profiles |
CN1928864A (en) * | 2006-09-22 | 2007-03-14 | 浙江大学 | FAQ based Chinese natural language ask and answer method |
CN101079026A (en) * | 2007-07-02 | 2007-11-28 | 北京百问百答网络技术有限公司 | Text similarity, acceptation similarity calculating method and system and application system |
CN101398835A (en) * | 2007-09-30 | 2009-04-01 | 日电(中国)有限公司 | Service selecting system and method, and service enquiring system and method based on natural language |
CN102163229A (en) * | 2011-04-13 | 2011-08-24 | 北京百度网讯科技有限公司 | Method and equipment for generating abstracts of searching results |
Family Cites Families (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20070168335A1 (en) * | 2006-01-17 | 2007-07-19 | Moore Dennis B | Deep enterprise search |
CN103177039A (en) * | 2011-12-26 | 2013-06-26 | 中国移动通信集团北京有限公司 | Data processing method and data processing device |
-
2014
- 2014-03-26 CN CN201410117635.XA patent/CN104951456B/en active Active
- 2014-03-26 CN CN201810677005.6A patent/CN108984650B/en active Active
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US6189002B1 (en) * | 1998-12-14 | 2001-02-13 | Dolphin Search | Process and system for retrieval of documents using context-relevant semantic profiles |
CN1928864A (en) * | 2006-09-22 | 2007-03-14 | 浙江大学 | FAQ based Chinese natural language ask and answer method |
CN101079026A (en) * | 2007-07-02 | 2007-11-28 | 北京百问百答网络技术有限公司 | Text similarity, acceptation similarity calculating method and system and application system |
CN101398835A (en) * | 2007-09-30 | 2009-04-01 | 日电(中国)有限公司 | Service selecting system and method, and service enquiring system and method based on natural language |
CN102163229A (en) * | 2011-04-13 | 2011-08-24 | 北京百度网讯科技有限公司 | Method and equipment for generating abstracts of searching results |
Also Published As
Publication number | Publication date |
---|---|
CN104951456A (en) | 2015-09-30 |
CN108984650B (en) | 2020-10-16 |
CN104951456B (en) | 2018-07-24 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN104951456B (en) | A kind of method, apparatus and equipment for obtaining answer information | |
CN104933084B (en) | A kind of method, apparatus and equipment for obtaining answer information | |
US20180157636A1 (en) | Methods and systems for language-agnostic machine learning in natural language processing using feature extraction | |
US20190251417A1 (en) | Artificial Intelligence System for Inferring Grounded Intent | |
CN106407178A (en) | Session abstract generation method and device | |
EP3648032A1 (en) | Information inputting method, information inputting device, and information inputting system | |
CN107784051A (en) | Online customer service answering system and method | |
CN105117387B (en) | A kind of intelligent robot interactive system | |
US20160307172A1 (en) | Method, apparatus and system for processing information | |
CN107958078A (en) | Information generating method and device | |
CN106326233B (en) | address prompting method and device | |
CN110879837A (en) | Information processing method and device | |
CN108702368A (en) | Additional information is integrated into telecommunication call | |
CN106487655B (en) | Message interaction method and device and processing server | |
CN106462564A (en) | Providing factual suggestions within a document | |
CN105183819A (en) | Method and device for providing reminding message and generating reminding setting item | |
CN107341157B (en) | Customer service conversation clustering method and device | |
CN105912575A (en) | Text information pushing method and text information pushing device | |
US20140225899A1 (en) | Method of animating sms-messages | |
CN108306813B (en) | Session message processing method, server and client | |
CN105929979A (en) | Long-sentence input method and device | |
CN106326486A (en) | Method of information push based on artificial intelligence and device thereof | |
CN110837356A (en) | Data processing method and device | |
US20170040019A1 (en) | Interaction apparatus and method | |
KR101614470B1 (en) | Apparatus for providing search word list and method using the same |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |