Specific embodiment
Example embodiments are described in detail here, and the example is illustrated in the accompanying drawings.Following description is related to
When attached drawing, unless otherwise indicated, the same numbers in different drawings indicate the same or similar elements.Following exemplary embodiment
Described in embodiment do not represent all embodiments consistent with this specification.On the contrary, they are only and such as institute
The example of the consistent device and method of some aspects be described in detail in attached claims, this specification.
It is only to be not intended to be limiting this explanation merely for for the purpose of describing particular embodiments in the term that this specification uses
Book.The "an" of used singular, " described " and "the" are also intended to packet in this specification and in the appended claims
Most forms are included, unless the context clearly indicates other meaning.It is also understood that term "and/or" used herein is
Refer to and includes that one or more associated any or all of project listed may combine.
It will be appreciated that though various information may be described using term first, second, third, etc. in this specification, but
These information should not necessarily be limited by these terms.These terms are only used to for same type of information being distinguished from each other out.For example, not taking off
In the case where this specification range, the first information can also be referred to as the second information, and similarly, the second information can also be claimed
For the first information.Depending on context, word as used in this " if " can be construed to " ... when " or
" when ... " or " in response to determination ".
This specification provides a kind of public sentiment method for early warning, can extract key sentence from original public sentiment text, then adopt
Predict that the key sentence extracted, the early warning for obtaining the key sentence is general with Early-warning Model corresponding with business object
Rate, and can be when the pre- alarm probability meets early-warning conditions, it is believed that original public sentiment text meets early-warning conditions, and then to original carriage
Feelings text issues early warning, which is directed toward the business object.
Above-mentioned original public sentiment text may include the text issued in the media such as internet.
For example, user issues the text in network forum, microblogging, community.
Above-mentioned original public sentiment text may also comprise voice that user is uploaded by the channels such as voice customer service it is converted after obtain
Text.
For example, recording content described in user after user dials service calls, audio being obtained, then by the audio conversion
It is changed to text.
Above-mentioned business object may include user carry out line on business operation when by APP (Application, using journey
Sequence), the function in APP, the page in APP, the interactive controls in APP, the small routine in APP etc..
For example, above-mentioned business object can be user when carrying out delivery operation by Third-party payment software.
For another example above-mentioned business object can also be user when carrying out delivery operation by Third-party payment software in
The credit payment function of offer.
In another example above-mentioned business object can also be user when carrying out information search by third party's search software mention
Search entrance of confession etc..
Above-mentioned business object may also include user and provide tissue, the group or a of business handling in business under handling line
People.
For example, above-mentioned business object can be user it is online under social security center when handling social security business.
For another example hospital, department, doctor etc. when above-mentioned business object is seen a doctor under can also be user online.
The realization of this specification is described by two aspects of the training of Early-warning Model and public sentiment method for early warning separately below
Process.
One, the training of Early-warning Model
In the present embodiment, for each business object, can train with the unique corresponding Early-warning Model of the business object,
It is subsequently used for the public sentiment text that the business object is directed toward in early warning.
Referring to FIG. 1, the training method of Early-warning Model can comprise the following steps that
Step 102, the original public sentiment text of sample is obtained, the original public sentiment text of sample has one or more and business
The one-to-one early warning label of object.
In the present embodiment, the original public sentiment text of the sample is the original public sentiment text with early warning label, described pre-
Alert label is corresponding with business object, is directed toward the pre- of the business object for indicating whether to issue the original public sentiment text of the sample
It is alert.Wherein, the early warning label can be marked artificially, can also machine mark, this specification is not particularly limited this.
Business object |
Early warning label |
Business object 1 |
L1 |
Business object 2 |
L2 |
Business object 3 |
L3 |
Business object 4 |
L4 |
Business object 5 |
L5 |
Table 1
Please refer to the example of table 1, it is assumed that the quantity of business object is 5, then the sample public sentiment text there can be 5 early warning
Label: L1, L2, L3, L4, L5, this 5 early warning labels are corresponding to business object 5 with business object 1 respectively.The value of early warning label
It can be 0 or 1, wherein 0 can indicate not carry out the early warning for being directed toward corresponding business object to the original public sentiment text of the sample, 1 can table
Show and the early warning for being directed toward corresponding business object is carried out to the original public sentiment text of the sample.
It is assumed that the early warning label L of some this original public sentiment text1=0, L2=1, then it represents that not to the original public sentiment of the sample
Text carries out the early warning for being directed toward business object 1, but the early warning for being directed toward business object 2 is carried out to the original public sentiment text of the sample.
In conjunction with concrete instance, it is assumed that the original public sentiment text of sample is " there are the money in B stored value card is stolen ", business pair
As 1 is A stored value card, business object 2 is B stored value card, then in this example, the original public sentiment text of the sample and business pair
As 1 corresponding early warning label L1=0, early warning label L corresponding with business object 22=1, i.e., not to the original public sentiment text of the sample
The early warning for being directed toward A stored value card is carried out, the early warning for being directed toward B stored value card is carried out to the original public sentiment text of the sample, because of the sample
This original public sentiment text is related with B stored value card.
It is worth noting that, in the present embodiment, the quantity of the original public sentiment text early warning label of sample can be with business pair
The quantity of elephant is identical, might be less that the quantity of business object.
Still by taking the example of table 1 as an example, in the case where there is 5 business objects, some this original public sentiment text can also be only
There are two early warning labels, such as L for tool1And L2, this specification is not particularly limited this.
Step 104, sample key sentence is extracted from the original public sentiment text of the sample.
In the present embodiment, it for the original public sentiment text of every galley proof sheet, can be extracted from the original public sentiment text of the sample
Sample key sentence out.The sample key sentence is the sentence to the semantic important in inhibiting of the original public sentiment text of sample.
In one example, sentence conduct relevant to business object can be extracted from the original public sentiment text of the sample
The sample key sentence.
Below by taking training Early-warning Model corresponding with business object 1 as an example, several samples relevant to business object 1 are introduced
The extracting method of key sentence.
1) it for each sentence in the original public sentiment text of the sample, whether can determine whether in the sentence comprising the industry
Business object 1.
For example, can determine whether in the sentence whether include the business object 1 Chinese.
For another example can determine whether in the sentence whether include the business object 1 English name.
In another example can determine whether in the sentence whether include the business object 1 abbreviation.
In another example can determine whether in the sentence whether include the business object 1 alias etc..
If including the business object 1 in the sentence, the sentence can extract as sample relevant to business object 1
This key sentence.
2) for each sentence in the original public sentiment text of the sample, whether can first judge in the sentence comprising described
Business object 1, if comprising that can continue to judge whether can mention comprising preset early warning word if also including in the sentence
Take the sentence as sample key sentence relevant to business object 1.
Wherein, the early warning word can include: " robber ", " surreptitiously ", " loss ", " loss ", " safety ", " reliable ", " uneasiness
Entirely ", " unreliable " etc..
Certainly, can also first judge whether comprising preset early warning word in the sentence, if comprising, then judge the sentence
In whether include the business object 1, this specification is not particularly limited this.
3) for each sentence in the original public sentiment text of the sample, whether can first judge in the sentence comprising described
Business object 1, if comprising that whether can continue to judge behind business object 1 described in the sentence comprising preset early warning
Word can extract the sentence as sample key sentence relevant to business object 1 if also including.
In this example, the appearance position of early warning word can be limited to after business object 1.
When judging, the text after business object 1, where the business object 1 can be included in determining sentence
Whether this position starts, along semantic sequence, continue to judge in sentence comprising the early warning word.
As an example it is assumed that some sentence is " there are the money in business object 1 is stolen ", then in judging this sentence
After business object 1, along semantic sequence, whether continue in judgement " inner money is stolen " comprising preset early warning word
Language.Include early warning word " robber " through judgement, then can extract this sentence as sample key sentence relevant to business object 1.
It is worth noting that, carry out sample key sentence relevant to business object extract when, the business object and
The corresponding business object of Early-warning Model is consistent.
For example, being extracted and business pair in the original public sentiment text of sample in training 1 corresponding Early-warning Model of business object
As 1 relevant sentence is as sample key sentence.
For another example in training 2 corresponding Early-warning Model of business object, extraction and business in the original public sentiment text of sample
The relevant sentence of object 2 is as sample key sentence.
In another example, also specified sentence can be extracted as the sample from the original public sentiment text of the sample
Key sentence.
The specified sentence may include one or more of: title, first sentence and the tail of the original public sentiment text of sample
Sentence etc..
Certainly, the specified sentence is also possible to second in the original public sentiment text of sample, sentence second from the bottom etc., this theory
Bright book is not particularly limited this.
In the present embodiment, the extraction that above-mentioned one or more extracting methods carry out sample key sentence can be chosen, thus
One or more sample key sentences are extracted from the original public sentiment text of the sample.
In the present embodiment, CNN (Convolutional Neural Networks, convolutional neural networks) mould can be used
The models such as type, LSTM model (Long Short Term Memory Model, shot and long term memory network model) carry out sample pass
The extraction of key sentence, this specification are not particularly limited this.
It is worth noting that, may go out when carrying out the extraction of sample key sentence using above two method at the same time
Existing repeat statement, for example, the first sentence of the original public sentiment text of sample is also simultaneously sentence relevant to business object, and then in sample
Key sentence also needs to carry out duplicate removal processing after extracting.
Step 106, for each business object, using the sample key sentence and the corresponding sample of the business object
Original public sentiment text early warning label is trained Early-warning Model, obtains Early-warning Model corresponding with the business object.
In the present embodiment, sentiment classification model Aspect Level model based on particular aspects etc. can be used as pre-
Alert model, this specification are not particularly limited this.
In the present embodiment, for training the corresponding Early-warning Model of business object 1, it can be used and mentioned in abovementioned steps 104
The original public sentiment text of the sample key sentence and sample of taking-up early warning label corresponding with business object 1 instructs Early-warning Model
Practice, obtains Early-warning Model corresponding with business object 1.
In one example, insertion processing (Embedding) first can be carried out to sample key sentence, generates the sample and closes
Then the sampling feature vectors are inputted Early-warning Model, export the sample key sentence by the sampling feature vectors of key sentence
Pre- alarm probability, and can the Early-warning Model according to the discrepancy adjustment between the pre- alarm probability and early warning label model ginseng
Number.
Wherein, insertion is carried out to sample key sentence and handles the method that following example can be used:
For example, can be carried out to the sample key sentence random when for trained sample key sentence corpus abundance
It is vector initialising, and then generate the sampling feature vectors of the sample key sentence.
For another example the methods of word2vec can be used and generate institute when for trained sample key sentence corpus deficiency
State the sampling feature vectors of sample key sentence.
The above-mentioned exemplary only explanation of embedding grammar can also be used other methods and generate the sample in other examples
The sampling feature vectors of this key sentence, this specification are not particularly limited this.
In another example, when Early-warning Model has the function of text insertion, sample key sentence can be directly inputted
Early-warning Model exports the pre- alarm probability of the sample key sentence, then according to the difference between the pre- alarm probability and early warning label
The model parameter of the different adjustment Early-warning Model.
The present embodiment is trained Early-warning Model using the key sentence extracted it can be seen from above description, phase
It is trained compared with using original public sentiment text, can effectively avoid too long caused model accuracy difference of original public sentiment text etc. and ask
Topic.Meanwhile the Early-warning Model that the present embodiment trains is corresponded with business object, is supervised convenient for the public sentiment of different business object
Control.
Two, public sentiment method for early warning
Referring to FIG. 2, public sentiment method for early warning can comprise the following steps that
Step 202, original public sentiment text is obtained.
In the present embodiment, the original public sentiment text for needing to carry out public sentiment monitoring is obtained.
In one example, the original public sentiment text can be the urtext of user's publication, untreated.
In another example, first the urtext of user's publication can also be pre-processed, is filtered out described original
The noise of text obtains original public sentiment text.For example, may filter that unnecessary HTML (Hyper in the urtext
Text Markup Language, HyperText Markup Language) etc..
In the present embodiment, the urtext that user issues can be obtained from network platforms such as network forum, microblogging, communities.
Step 204, key sentence is extracted from the original public sentiment text.
In the present embodiment, for every original public sentiment text, Key Words can be extracted from the original public sentiment text
Sentence.The key sentence is the sentence to the semantic important in inhibiting of original public sentiment text.
In one example, it can be extracted from the original public sentiment text described in sentence conduct relevant to business object
Key sentence.
For carrying out public sentiment monitoring below for business object 1, several key sentences relevant to business object 1 are introduced
Extracting method.
1) it for each sentence in the original public sentiment text, whether can determine whether in the sentence comprising the business pair
As 1.
For example, can determine whether in the sentence whether include the business object 1 Chinese.
For another example can determine whether in the sentence whether include the business object 1 English name.
In another example can determine whether in the sentence whether include the business object 1 abbreviation.
In another example can determine whether in the sentence whether include the business object 1 alias etc..
If including the business object 1 in the sentence, the sentence can extract as pass relevant to business object 1
Key sentence.
2) for each sentence in the original public sentiment text, whether can first judge in the sentence comprising the business
Object 1, if comprising that can continue to judge, if also including, to can extract institute whether comprising preset early warning word in the sentence
Sentence is stated as key sentence relevant to business object 1.
Wherein, the early warning word can include: " robber ", " surreptitiously ", " loss ", " loss ", " safety ", " reliable ", " uneasiness
Entirely ", " unreliable " etc..
Certainly, can also first judge whether comprising preset early warning word in the sentence, if comprising, then judge the sentence
In whether include the business object 1, this specification is not particularly limited this.
3) for each sentence in the original public sentiment text, whether can first judge in the sentence comprising the business
Object 1, if comprising, it can continue to judge behind business object 1 described in the sentence whether to include preset early warning word,
If also including, the sentence can extract as key sentence relevant to business object 1.
In this example, the appearance position of early warning word can be limited to after business object 1.
When judging, the text after business object 1, where the business object 1 can be included in determining sentence
Whether this position starts, along semantic sequence, continue to judge in sentence comprising the early warning word.
As an example it is assumed that some sentence is " there are the money in business object 1 is stolen ", then in judging this sentence
After business object 1, along semantic sequence, whether continue in judgement " inner money is stolen " comprising preset early warning word
Language.Include early warning word " robber " through judgement, then can extract this sentence as key sentence relevant to business object 1.
It is worth noting that, when carrying out key sentence relevant to business object extraction, the business object and needs
The business object for carrying out public sentiment monitoring is consistent.
For example, being extracted and 1 phase of business object in original public sentiment text when carrying out public sentiment monitoring for business object 1
The sentence of pass is as key sentence.
For another example being extracted and business object 2 in original public sentiment text when carrying out public sentiment monitoring for business object 2
Relevant sentence is as key sentence.
In another example, also specified sentence can be extracted as the Key Words from the original public sentiment text
Sentence.
The specified sentence may include one or more of: title, first sentence and the tail sentence etc. of the original public sentiment text.
Certainly, the specified sentence is also possible to second in original public sentiment text, sentence second from the bottom etc., this specification
This is not particularly limited.
In the present embodiment, the extraction that above-mentioned one or more extracting methods carry out key sentence can be chosen, thus from institute
It states in original public sentiment text and extracts one or more key sentences.
In the present embodiment, CNN (Convolutional Neural Networks, convolutional neural networks) mould can be used
The models such as type, LSTM model (Long Short Term Memory Model, shot and long term memory network model) carry out sample pass
The extraction of key sentence, this specification are not particularly limited this.
It is worth noting that, when carrying out the extraction of key sentence using above two method at the same time, it is possible that weight
Multiple sentence for example, the first sentence of original public sentiment text is also simultaneously sentence relevant to business object, and then is extracted in key sentence
It also needs to carry out duplicate removal processing afterwards.
Step 206, the key sentence is predicted using Early-warning Model corresponding with business object, obtains the pass
The pre- alarm probability of key sentence.
In the present embodiment, it for each business object for needing to carry out public sentiment monitoring, can be respectively adopted and the business
Object corresponding Early-warning Model is predicted.
It is assumed that there is 5 business objects for needing to carry out public sentiment monitoring, respectively business object 1 to business object 5, then needle
To the every original public sentiment text got, can be respectively adopted with business object 1 to the corresponding prediction model 1 of business object 5 to
Prediction model 5 is predicted.
It is described for carrying out public sentiment monitoring to business object 1 below.
In the present embodiment, when Early-warning Model 1 corresponding with business object 1 using sample key sentence sample characteristics to
When amount is trained as input, in this step, first the key sentence that abovementioned steps 204 extract can be carried out at insertion
Reason, generates corresponding feature vector, feature vector is then inputted trained Early-warning Model 1, exports the key sentence
Pre- alarm probability.
Wherein, insertion is carried out to key sentence and handles the method that following example can be used:
For example, random vector initialization can be carried out to the key sentence, so generate the feature of the key sentence to
Amount.
For another example the feature vector that the methods of word2vec generates the key sentence can be used.
The above-mentioned exemplary only explanation of embedding grammar can also be used other methods and generate the pass in other examples
The feature vector of key sentence, this specification are not particularly limited this.
When Early-warning Model 1 corresponding with business object 1 is trained using sample key sentence as input, in this step
In rapid, the key sentence extracted in abovementioned steps 204 can be directly inputted to trained Early-warning Model 1, export the key
The pre- alarm probability of sentence.
Step 208, when the pre- alarm probability meets predetermined early-warning conditions, institute is directed toward to the original public sentiment text publication
State the early warning of business object.
In the present embodiment, it is pre- to can determine whether the pre- alarm probability for the key sentence that abovementioned steps 206 obtain meets
Early-warning conditions are determined, if satisfied, being then believed that the corresponding original public sentiment text of key sentence meets early-warning conditions, and then to original carriage
Feelings text issues early warning, which is directed toward the business object.
Wherein, the early-warning conditions can be more than or equal to threshold value of warning, less than or equal to threshold value of warning etc. for early warning probability, can
It is determined in Early-warning Model training, and the corresponding early-warning conditions of different business object may be identical, it is also possible to different, this specification
This is not particularly limited.
Key sentence can be extracted from original public sentiment text by the present embodiment it can be seen from above description, then used
Early-warning Model corresponding with business object predicts that the key sentence extracted, the early warning for obtaining the key sentence is general
Rate, and can be when the pre- alarm probability meets early-warning conditions, it is believed that original public sentiment text meets early-warning conditions, and then to original carriage
Feelings text issues early warning, which is directed toward the business object.The present embodiment is using Early-warning Model to the key sentence extracted
It is predicted, is predicted compared to using original public sentiment text, can effectively avoid the too long caused prediction of original public sentiment text
The problems such as poor accuracy.Meanwhile being predicted using Early-warning Model corresponding with business object, corresponding business pair can be directly obtained
The public sentiment monitored results of elephant, it is convenient and efficient, substantially increase public sentiment early warning efficiency.
Corresponding with the embodiment of aforementioned public sentiment method for early warning, this specification additionally provides the implementation of public sentiment prior-warning device
Example.
The embodiment of this specification public sentiment prior-warning device can be using on the server.Installation practice can pass through software
It realizes, can also be realized by way of hardware or software and hardware combining.Taking software implementation as an example, as on a logical meaning
Device, be to be read computer program instructions corresponding in nonvolatile memory by the processor of server where it
Operation is formed in memory.For hardware view, as shown in figure 3, the server where this specification public sentiment prior-warning device
A kind of hardware structure diagram is implemented other than processor shown in Fig. 3, memory, network interface and nonvolatile memory
Server in example where device can also include other hardware generally according to the actual functional capability of the server, no longer superfluous to this
It states.
Fig. 4 is a kind of block diagram of public sentiment prior-warning device shown in one exemplary embodiment of this specification.
Referring to FIG. 4, the public sentiment prior-warning device 300 can be applied in aforementioned server shown in Fig. 3, include:
Text acquiring unit 301, sentence extraction unit 302, text prediction unit 303 and public sentiment prewarning unit 304.
Wherein, text acquiring unit 301 obtains original public sentiment text;
Sentence extraction unit 302 extracts key sentence from the original public sentiment text;
Text prediction unit 303 is predicted the key sentence using Early-warning Model corresponding with business object, is obtained
To the pre- alarm probability of the key sentence;
Public sentiment prewarning unit 304 sends out the original public sentiment text when the pre- alarm probability meets predetermined early-warning conditions
Cloth is directed toward the early warning of the business object.
Optionally, the sentence extraction unit 302 extracts and the business object phase from the original public sentiment text
The sentence of pass is as the key sentence.
Optionally, the sentence extraction unit 302, for each sentence in the original public sentiment text, described in judgement
It whether include the business object in sentence;If comprising extracting the sentence as the key sentence.
Optionally, the sentence extraction unit 302, for each sentence in the original public sentiment text, described in judgement
It whether include the business object in sentence;
If comprising whether judging in the sentence comprising preset early warning word;
If comprising extracting the sentence as the key sentence.
Optionally, the sentence extraction unit 302, since the text position where the business object, along semanteme
Whether sequence judges in the sentence comprising preset early warning word;If comprising executing and extracting the sentence as the pass
The step of key sentence.
Optionally, the sentence extraction unit 302 is extracted from the original public sentiment text described in specified sentence conduct
Key sentence.
Optionally, the specified sentence includes one or more of:
Title, first sentence and the tail sentence of the original public sentiment text.
Optionally, the text prediction unit 303, when the Early-warning Model is carried out using sample key sentence as input
When training, the key sentence is inputted into Early-warning Model corresponding with business object, exports the pre- alarm probability of the key sentence.
Optionally, the text prediction unit 303, when the Early-warning Model using sample key sentence sample characteristics to
When amount is trained as input, feature vector is generated for the key sentence;Described eigenvector is inputted into the early warning mould
Type exports the pre- alarm probability of the key sentence.
Corresponding with the embodiment of training method of aforementioned public sentiment Early-warning Model, this specification additionally provides public sentiment early warning mould
The embodiment of the training device of type.
The embodiment of the training device of this specification public sentiment Early-warning Model can be using on the server.Installation practice can
Can also be realized by way of hardware or software and hardware combining by software realization.Taking software implementation as an example, as one
Device on logical meaning is by the processor of server where it by computer program corresponding in nonvolatile memory
Instruction is read into memory what operation was formed.For hardware view, as shown in figure 5, for this specification public sentiment Early-warning Model
A kind of hardware structure diagram of server where training device, in addition to processor shown in fig. 5, memory, network interface and it is non-easily
Except the property lost memory, the server in embodiment where device can also include generally according to the actual functional capability of the server
Other hardware repeat no more this.
Fig. 6 is a kind of block diagram of the training device of public sentiment Early-warning Model shown in one exemplary embodiment of this specification.
Referring to FIG. 6, the training device 500 of the public sentiment Early-warning Model can be applied in aforementioned server shown in fig. 5
In, include: sample acquisition unit 501, sample sentence extraction unit 502 and model training unit 503.
Sample acquisition unit 501, obtains the original public sentiment text of sample, and the original public sentiment text of sample has one or more
A and one-to-one early warning label of business object;
Sample sentence extraction unit 502 extracts sample key sentence from the original public sentiment text of the sample;
Model training unit 503, for each business object, using the sample key sentence and the business object pair
The original public sentiment text early warning label of the sample answered is trained Early-warning Model, obtains early warning mould corresponding with the business object
Type.
The function of each unit and the realization process of effect are specifically detailed in the above method and correspond to step in above-mentioned apparatus
Realization process, details are not described herein.
For device embodiment, since it corresponds essentially to embodiment of the method, so related place is referring to method reality
Apply the part explanation of example.The apparatus embodiments described above are merely exemplary, wherein described be used as separation unit
The unit of explanation may or may not be physically separated, and component shown as a unit can be or can also be with
It is not physical unit, it can it is in one place, or may be distributed over multiple network units.It can be according to actual
The purpose for needing to select some or all of the modules therein to realize this specification scheme.Those of ordinary skill in the art are not
In the case where making the creative labor, it can understand and implement.
System, device, module or the unit that above-described embodiment illustrates can specifically realize by computer chip or entity,
Or it is realized by the product with certain function.A kind of typically to realize that equipment is computer, the concrete form of computer can
To be personal computer, laptop computer, cellular phone, camera phone, smart phone, personal digital assistant, media play
In device, navigation equipment, E-mail receiver/send equipment, game console, tablet computer, wearable device or these equipment
The combination of any several equipment.
Corresponding with the embodiment of aforementioned public sentiment method for early warning, this specification also provides a kind of public sentiment prior-warning device, the dress
Set includes: processor and the memory for storing machine-executable instruction.Wherein, processor and memory are usually by interior
Portion's bus is connected with each other.In other possible implementations, the equipment is also possible that external interface, with can be with other
Equipment or component are communicated.
It in the present embodiment, can by reading and executing the machine corresponding with public sentiment early warning logic of the memory storage
It executes instruction, the processor is prompted to:
Obtain original public sentiment text;
Key sentence is extracted from the original public sentiment text;
The key sentence is predicted using Early-warning Model corresponding with business object, obtains the key sentence
Pre- alarm probability;
When the pre- alarm probability meets predetermined early-warning conditions, the business pair is directed toward to the original public sentiment text publication
The early warning of elephant.
It is optionally, described to extract key sentence from the original public sentiment text, comprising:
Sentence relevant to the business object is extracted from the original public sentiment text as the key sentence.
Optionally, described to be extracted from the original public sentiment text described in sentence conduct relevant to the business object
Key sentence includes:
For each sentence in the original public sentiment text, whether judge in the sentence comprising the business object;
If comprising extracting the sentence as the key sentence.
Optionally, described to be extracted from the original public sentiment text described in sentence conduct relevant to the business object
Key sentence includes:
For each sentence in the original public sentiment text, whether judge in the sentence comprising the business object;
If comprising whether judging in the sentence comprising preset early warning word;
If comprising extracting the sentence as the key sentence.
It is optionally, described whether to judge in the sentence comprising preset early warning word, comprising:
Since the text position where the business object, whether judge in the sentence along semantic sequence comprising pre-
If early warning word;
If comprising executing and extracting the step of sentence is as the key sentence.
It is optionally, described to extract key sentence from the original public sentiment text, comprising:
Specified sentence is extracted as the key sentence from the original public sentiment text.
Optionally, the specified sentence includes one or more of:
Title, first sentence and the tail sentence of the original public sentiment text.
Optionally, described that the key sentence is predicted using Early-warning Model corresponding with business object, obtain institute
State the pre- alarm probability of key sentence, comprising:
When the Early-warning Model using sample key sentence as input be trained when, by the key sentence input with
The corresponding Early-warning Model of business object exports the pre- alarm probability of the key sentence.
Optionally, described that the key sentence is predicted using Early-warning Model corresponding with business object, obtain institute
State the pre- alarm probability of key sentence, comprising:
It is described when the Early-warning Model is trained using the sampling feature vectors of sample key sentence as input
Key sentence generates feature vector;
Described eigenvector is inputted into the Early-warning Model, exports the pre- alarm probability of the key sentence.
Corresponding with the embodiment of training method of aforementioned public sentiment Early-warning Model, this specification also provides a kind of public sentiment early warning
The training device of model, the device include: processor and the memory for storing machine-executable instruction.Wherein, it handles
Device and memory are usually connected with each other by internal bus.In other possible implementations, the equipment is also possible that
External interface, can be communicated with other equipment or component.
In the present embodiment, the training logic pair with public sentiment Early-warning Model stored by reading and executing the memory
The machine-executable instruction answered, the processor are prompted to:
The original public sentiment text of sample is obtained, the original public sentiment text of sample has one or more and business object one by one
Corresponding early warning label;
Sample key sentence is extracted from the original public sentiment text of the sample;
For each business object, using the sample key sentence and the original public sentiment of the corresponding sample of the business object
Text early warning label is trained Early-warning Model, obtains Early-warning Model corresponding with the business object.
Corresponding with the embodiment of aforementioned public sentiment method for early warning, this specification also provides a kind of computer-readable storage medium
Matter is stored with computer program on the computer readable storage medium, which performs the steps of when being executed by processor
Obtain original public sentiment text;
Key sentence is extracted from the original public sentiment text;
The key sentence is predicted using Early-warning Model corresponding with business object, obtains the key sentence
Pre- alarm probability;
When the pre- alarm probability meets predetermined early-warning conditions, the business pair is directed toward to the original public sentiment text publication
The early warning of elephant.
It is optionally, described to extract key sentence from the original public sentiment text, comprising:
Sentence relevant to the business object is extracted from the original public sentiment text as the key sentence.
Optionally, described to be extracted from the original public sentiment text described in sentence conduct relevant to the business object
Key sentence includes:
For each sentence in the original public sentiment text, whether judge in the sentence comprising the business object;
If comprising extracting the sentence as the key sentence.
Optionally, described to be extracted from the original public sentiment text described in sentence conduct relevant to the business object
Key sentence includes:
For each sentence in the original public sentiment text, whether judge in the sentence comprising the business object;
If comprising whether judging in the sentence comprising preset early warning word;
If comprising extracting the sentence as the key sentence.
It is optionally, described whether to judge in the sentence comprising preset early warning word, comprising:
Since the text position where the business object, whether judge in the sentence along semantic sequence comprising pre-
If early warning word;
If comprising executing and extracting the step of sentence is as the key sentence.
It is optionally, described to extract key sentence from the original public sentiment text, comprising:
Specified sentence is extracted as the key sentence from the original public sentiment text.
Optionally, the specified sentence includes one or more of:
Title, first sentence and the tail sentence of the original public sentiment text.
Optionally, described that the key sentence is predicted using Early-warning Model corresponding with business object, obtain institute
State the pre- alarm probability of key sentence, comprising:
When the Early-warning Model using sample key sentence as input be trained when, by the key sentence input with
The corresponding Early-warning Model of business object exports the pre- alarm probability of the key sentence.
Optionally, described that the key sentence is predicted using Early-warning Model corresponding with business object, obtain institute
State the pre- alarm probability of key sentence, comprising:
It is described when the Early-warning Model is trained using the sampling feature vectors of sample key sentence as input
Key sentence generates feature vector;
Described eigenvector is inputted into the Early-warning Model, exports the pre- alarm probability of the key sentence.
Corresponding with the embodiment of training method of aforementioned public sentiment Early-warning Model, this specification also provides a kind of computer can
Storage medium is read, is stored with computer program on the computer readable storage medium, realization when which is executed by processor
Following steps:
The original public sentiment text of sample is obtained, the original public sentiment text of sample has one or more and business object one by one
Corresponding early warning label;
Sample key sentence is extracted from the original public sentiment text of the sample;
For each business object, using the sample key sentence and the original public sentiment of the corresponding sample of the business object
Text early warning label is trained Early-warning Model, obtains Early-warning Model corresponding with the business object.
It is above-mentioned that this specification specific embodiment is described.Other embodiments are in the scope of the appended claims
It is interior.In some cases, the movement recorded in detail in the claims or step can be come according to the sequence being different from embodiment
It executes and desired result still may be implemented.In addition, process depicted in the drawing not necessarily require show it is specific suitable
Sequence or consecutive order are just able to achieve desired result.In some embodiments, multitasking and parallel processing be also can
With or may be advantageous.
The foregoing is merely the preferred embodiments of this specification, all in this explanation not to limit this specification
Within the spirit and principle of book, any modification, equivalent substitution, improvement and etc. done should be included in the model of this specification protection
Within enclosing.