CN110471538B - Input prediction method and device - Google Patents

Input prediction method and device Download PDF

Info

Publication number
CN110471538B
CN110471538B CN201810443612.6A CN201810443612A CN110471538B CN 110471538 B CN110471538 B CN 110471538B CN 201810443612 A CN201810443612 A CN 201810443612A CN 110471538 B CN110471538 B CN 110471538B
Authority
CN
China
Prior art keywords
input content
question
input
answer
sequence
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.)
Active
Application number
CN201810443612.6A
Other languages
Chinese (zh)
Other versions
CN110471538A (en
Inventor
陈小帅
臧娇娇
张扬
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Sogou Technology Development Co Ltd
Original Assignee
Beijing Sogou Technology Development Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Sogou Technology Development Co Ltd filed Critical Beijing Sogou Technology Development Co Ltd
Priority to CN201810443612.6A priority Critical patent/CN110471538B/en
Priority to PCT/CN2018/121233 priority patent/WO2019214234A1/en
Publication of CN110471538A publication Critical patent/CN110471538A/en
Application granted granted Critical
Publication of CN110471538B publication Critical patent/CN110471538B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/02Input arrangements using manually operated switches, e.g. using keyboards or dials
    • G06F3/023Arrangements for converting discrete items of information into a coded form, e.g. arrangements for interpreting keyboard generated codes as alphanumeric codes, operand codes or instruction codes
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/02Input arrangements using manually operated switches, e.g. using keyboards or dials
    • G06F3/023Arrangements for converting discrete items of information into a coded form, e.g. arrangements for interpreting keyboard generated codes as alphanumeric codes, operand codes or instruction codes
    • G06F3/0233Character input methods
    • G06F3/0237Character input methods using prediction or retrieval techniques

Landscapes

  • Engineering & Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Human Computer Interaction (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Information Transfer Between Computers (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The embodiment of the invention provides an input prediction method and device, wherein the method comprises the following steps: acquiring first input content and second input content; determining a scene category corresponding to the first input content; according to the first input content, the scene category and the second input content, predicting to obtain third input content which accords with a preset condition with the partial order relation of the first input content; the partial order relation is used for describing the sequence of each input content. The embodiment of the invention can improve the accuracy of input prediction and effectively improve the input efficiency.

Description

Input prediction method and device
Technical Field
The embodiment of the invention relates to the technical field of computers, in particular to an input prediction method and device.
Background
At present, an intelligent reply method exists, which can predict the content possibly replied by the user of the current communication terminal according to the above content sent by the opposite communication terminal and display the content to the user, so that the user can screen-output the predicted content through triggering operation. For example, when a user communicates with a seller using a shopping class application, the user asks the seller: "is this book a legal version? ". Vendor reply: "our books are all genuine. ". At this time, the intelligent reply device predicts that the user may reply as a candidate according to the content replied by the seller, for example, "good", "very good", and the user may directly select the candidate to screen. However, in this way, possible input content of the user is predicted based on the content of the opposite communication end, the predicted input content has a strong limitation, and the possible output content of the user cannot be effectively predicted.
Disclosure of Invention
The embodiment of the invention provides an input prediction method and device, which aim to solve the technical problems of strong input prediction limitation and inaccuracy in the prior art.
Therefore, the embodiment of the invention provides the following technical scheme:
in a first aspect, an embodiment of the present invention provides an input prediction method, including: acquiring first input content and second input content; determining a scene category corresponding to the first input content; according to the first input content, the scene category and the second input content, predicting to obtain third input content which accords with a preset condition with the partial order relation of the first input content; the partial order relation is used for describing the sequence of each input content.
In a second aspect, an embodiment of the present invention provides an input prediction apparatus, including: the receiving unit is used for acquiring the first input content and the second input content; the acquisition unit is used for determining a scene category corresponding to the first input content; the prediction unit is used for predicting and obtaining third input content which accords with a preset condition with the partial order relation of the first input content according to the first input content, the scene category and the second input content; the partial order relation is used for describing the sequence of each input content.
In a third aspect, embodiments of the present invention provide an apparatus for input prediction, comprising a memory, and one or more programs, wherein the one or more programs are stored in the memory and configured to be executed by one or more processors, the one or more programs comprising instructions for:
in a fourth aspect, embodiments of the present invention provide a machine-readable medium having instructions stored thereon, which when executed by one or more processors, cause an apparatus to perform the input prediction method as described in the first aspect.
The input prediction method and the input prediction device provided by the embodiment of the invention can acquire the first input content and the second input content; determining a scene category corresponding to the first input content; and predicting to obtain third input content which accords with a preset condition with the partial order relation of the first input content according to the first input content, the scene category and the second input content. Because the embodiment of the invention establishes the partial sequence relation of each input content in advance and is used for describing the sequence of each input content, the input of the user after the first input content can be predicted and obtained according to the first input content and the reply aiming at the first input content so as to be selected by the user. The embodiment of the invention can effectively improve the accuracy of input prediction and effectively improve the input efficiency.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings that are required to be used in the embodiments or the description of the prior art will be briefly described below, and it is obvious that the drawings in the following description are only some embodiments described in the present invention, and other drawings may be obtained according to the drawings without inventive effort to those skilled in the art.
FIG. 1 is a flowchart of an input prediction method according to an embodiment of the present invention;
FIG. 2 is a schematic diagram of an input prediction apparatus according to an embodiment of the present invention;
FIG. 3 is a block diagram illustrating an apparatus for input prediction according to an exemplary embodiment;
FIG. 4 is a block diagram of a server shown according to an example embodiment;
fig. 5 is a probability transition directed graph, shown in accordance with an exemplary embodiment.
Detailed Description
The embodiment of the invention provides an input prediction method and device, which can effectively improve the accuracy of input prediction and effectively improve the input efficiency.
In order to make the technical solution of the present invention better understood by those skilled in the art, the technical solution of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention, and it is apparent that the described embodiments are only some embodiments of the present invention, not all embodiments. All other embodiments, which can be made by those skilled in the art based on the embodiments of the present invention without making any inventive effort, shall fall within the scope of the present invention.
The idea of the invention is first elucidated. The inventor finds that the scheme for predicting possible input content of a user based on the content of the communication opposite end has strong limitation in the process of implementing the invention. For example, if a user communicates with a seller using a shopping class application, the user asks the seller: "is this book a legal version? "vendor reply: "our books are all genuine. ". At this point, the user may desire to continue the query: is "there a good" or "is a new book? ". However, according to the existing intelligent reply method, only "good" waiting options of the user can be given, and contents possibly input by the user cannot be effectively predicted. The user can only input manually, and the input efficiency of the user is reduced. In addition, an intelligent question-answering system exists at present, and corresponding answers can be given according to questions presented by users. The intelligent question-answering system is generally constructed based on a knowledge base that holds "question-answer" pairs. After the user inputs the questions, the corresponding answers can be obtained through the query of the knowledge base. For example, when the user inputs "is the location of the winter olympic of 2022? The automatic question-answering system returns "Beijing and Zhangjia Kong in China". However, the existing automatic question-answering system generally gives a preset answer matched with the question based on the question, and cannot obtain a progressive question matched with the input scene of the user based on the question proposed by the user and the reply prediction of the other party, and also cannot provide candidates of the progressive question, so that the user can conveniently input the progressive question. In an application scene, the embodiment of the invention can solve the technical problems of strong input prediction limitation and inaccuracy in the prior art, and the problem of further input of a user is obtained through the input problem of the user and the input scene prediction, so that the accuracy of the input prediction is improved, and the input efficiency of the user is improved.
An input prediction method according to an exemplary embodiment of the present invention will be described with reference to fig. 1 to 2.
Referring to fig. 1, a flowchart of an input prediction method according to an embodiment of the present invention is provided. As shown in fig. 1, may include:
s101, acquiring first input content and second input content.
In a specific implementation, the first input content is specifically a first question, and the second input content is specifically a reply to the first question. For example, the first user and the second user chat using the instant messaging tool, and the first user inputs the first input content as follows: "is this book a genuine version? ". The second user inputs the second input content as: "is a master. ". According to the embodiment of the invention, the third input content to be input by the first user can be obtained by prediction according to the acquired first input content and second input content. In the embodiment of the present invention, the third input content may be predicted based on a plurality of questions and answers that have been presented before. That is, the first input content may be specifically one or more questions, and the second input content may be specifically a reply to the one or more questions. For example, in a shopping scenario, questions that a user may raise include: is "is a master? "isthere? Is the "package post? "," can be shipped on the same day? "and the like. If the user has entered "is a legal? ", the counterpart replies" yes. Is the user continue to enter the shipment? ", answer to each other: "there is goods". At this time, the user's possible future input may be predicted based on the first two questions entered by the user and the affirmative answer to the questions: "do package mail? ".
S102, determining a scene category corresponding to the first input content.
It should be noted that, in the specific implementation of the present invention, a correspondence between question-answer sentences and scene categories and a partial order relationship between question-answer sentences may be established in advance. Specifically, a question-answer sentence can be obtained, scene clustering processing is carried out on the question-answer sentence, and the corresponding relation between the question-answer sentence and the scene category is saved; the question-answer sentence includes a question and/or answer. And then, acquiring the sequence of the occurrence of the question-answer sentences in the same scene category, and establishing the partial sequence relation of each question-answer sentence according to the sequence of the occurrence of the question-answer sentences.
For example, question-answer sentences can be collected according to user history input data, and clustering is carried out according to scenes, so that the corresponding relation between the question-answer sentences and scene categories is established. It should be noted that the scenario categories may include application categories, and/or topic categories. After the corpus of question-answer sentences is collected, the types of the questions can be counted. Since the types of the application programs are different, the question-answer sentences which may be input by the user are also different, and thus the collected question-answer sentences can be classified according to the types of the application programs. By way of example, application types may include shopping, social, music, literature, etc., and application types may be preset. Question-answer sentences that appear for the same application are considered to belong to the same application type. In particular, common applications may be categorized to determine their application type. For example, QQ, weChat, etc. all belong to social applications; panning and micro-shop belong to shopping class applications. For example, in shopping applications, problems typically occur: is "genuine", "is there a large number? Is the "package post? "," can be reached for several days? These problems are categorized into shopping applications.
In addition, since the user may discuss various topics under the same application, for example, various types of topics such as book type problems, clothing type problems, etc. may be discussed in shopping type applications. And the corresponding input content may be different for different topic types. In specific implementation, topic types can be predefined, and then the trained topic classification model is adopted to classify topic types of the data. For example, a problem A may occur with a corresponding shopping class application: is "is a master? "; problem B: is "new book? "; problem C: "do there a large number? "; problem D: "is there red? ". Wherein, problem A and problem B are of book type, problem C and problem D are of clothing type.
After the application scene category of the question-answer sentences is determined, the sequence of the occurrence of the question-answer sentences in the same scene category can be obtained, and the partial sequence relation of each question-answer sentence is established according to the sequence of the occurrence of the question-answer sentences. The partial order relation is used for describing the sequence of the occurrence of each input content (such as question and answer sentences). For example, when a user asks questions, the questions generally have a progressive relationship, that is, the order in which the questions appear has a certain rule. For example, in shopping, the general order of questions is: is genuine? Is there XL? Is? - > a few days. Therefore, the partial order relation of the question-answer sentences can be established according to the sequence of the questions input by the user. In addition, when the user inputs in a certain communication environment, an offset relation topological graph of the question-answer sentence is established based on the positive or negative answer of the last question of the user and the other party.
Specifically, the following scene classification and partial order relation can be established according to the statistical analysis of the corpus of question-answer sentences.
Question 11 application type 1 topic type 1
Question 12 application type 1 topic type 1 previous question answer case
Question 13 application type 1 topic type 1 previous question reply case
……
Question 1k application type 1 topic type 1 previous question answer case
……
Question C1 application type C topic type t
Question C2 application type C topic type t last question answer case
....
Question CK application type C topic type t last question answer case
It should be noted that, after a user inputs a question, the next question input is often different according to the reply of the other party. For example, when the user enters the question "package mail? ", if the other party is positively answered: and yes, package post. ", then the user may further enter a question: "can be reached for several days? ". If the other party is negative reply: "do not cover mail". "the user may not enter a question: "can be reached for several days? ", but rather input questions: "do there a coupon? ". Therefore, after classifying the question-answer sentences, a partial order relationship topological graph can be established corresponding to the question-answer sentences in the same application scene, namely according to the questions and the answers to the questions. Note that, if the probability that the problem q1 occurs before the problem q2 is greater than the first set threshold under the same application scenario type, the problem q2 is considered to be a progressive problem of q1. In other words, if the probability that the problem q2 appears after the problem q1 is greater than the second set threshold, the partial order relationship of the problem q2 is considered to be greater than the problem q1.
It should be noted that, in some embodiments, a probability transition directed graph may also be established according to the partial order relationship of the question-answer sentences to describe the relationship of each question-answer sentence. As shown in fig. 5, when there are a plurality of questions, a probability transition directed graph may be established according to the order of occurrence of the plurality of questions and the probability that the question a occurs before or after the question B. As shown in FIG. 5, each problem in the graph can be regarded as a node, and the directed edges between nodes are used for describing the sequence or the transfer direction of the nodes. The values on the directed edges are used to indicate probability values. For example, the arrows and numbers present between problem a and problem B are used to indicate that the probability that problem B occurs after problem a is 0.5. In other words, after problem a, the probability of transition to problem B is 0.5. In specific implementation, the problem that the probability is larger than the set threshold value or the N problems of which the probability values are ordered from large to small and ranked in the top N bits can be determined by querying the probability transition directed graph. It should be noted that the probability transition directed graph shown in fig. 5 only describes transition relationships between partial nodes, and is only illustrative and not considered as limiting the present invention.
After the first input content and the second input content are acquired, the scene category corresponding to the first input content can be acquired according to the corresponding relation between the pre-established question-answer sentence and the scene category. In a specific implementation, the determining the scene category corresponding to the first input content includes: acquiring a question-answer sentence matched with the first input content; and determining the scene category of the first input content according to the corresponding relation between the question-answer sentence and the scene category. When the question-answer sentence matching the first input content is acquired, the comparison may be performed based on the content or the similarity. For example, the questions input by the user can be compared with the questions in the question-answer sentence library, the similarity of the questions is compared, and when the similarity is greater than a first threshold value, the questions are determined to be matched. It should be noted that the similarity comparison method may be very flexible and various, and may adopt a word Bag (english is called Bag of Words, english is called BoW for short) model, neural network similarity calculation, vector similarity comparison, and the like. The following description will take vector similarity comparison as an example. Specifically, a vector representation of each sentence may be calculated, and then a similarity between the vectors is calculated, and when the similarity is greater than a certain threshold, the same problem is considered. The similarity based on the vector representation may be achieved by, for example, word segmentation of the sentence, then querying the vector representation of each term, and summing the vectors of the terms in the sentence to obtain a mean value. For example: the user input question a is: "do this packet mail? ", a question B exists in a pre-established question-answer sentence library: "do this schoolbag mail? ". Firstly, word segmentation processing is carried out on two problems: "do this book/package mail/is/? "do this/data/package mail/is/? ". Then, the term vector of each term is searched, and the vector representation of the two sentences is calculated, for example, the term vector is represented by 50-dimensional floating point numbers. The similarity between two sentence vectors is calculated and can be represented by calculating the cosine value of the included angle between the two vectors.
In some implementations, the determining the scene category to which the first input content corresponds includes: determining the category of the application program corresponding to the first input content; and/or determining the category of the topic corresponding to the first input content. For example, after acquiring a question-answer sentence matching the first input content, a category of an application program corresponding to the question-answer sentence and/or a topic category may be acquired. For example, the question a entered by the user is: "do this packet mail? ", the question-answer sentence matched with it is: "do this schoolbag mail? ", the corresponding scene categories are: shopping class applications, book topic categories.
S103, predicting to obtain third input content which accords with a preset condition with the partial sequence relation of the first input content according to the first input content, the scene category and the second input content; the partial order relation is used for describing the sequence of each input content.
In some embodiments, predicting, according to the first input content, the scene category, and the second input content, a third input content that meets a preset condition according to a partial order relationship of the first input content includes: acquiring a type of second input content, and acquiring input content with a partial order relation larger than that of the first input content under the scene category according to the type of the second input content as third input content; the second input content is different in type, and the acquired third input content is different. The input content with the partial order relation larger than the first input content specifically comprises the following components: the probability that the input content appears after the first input content is greater than a set threshold.
In the same application scenario, if the probability that the problem q2 appears after the problem q1 is greater than the second set threshold, the partial order relationship of the problem q2 is considered to be greater than the problem q1. In addition, the type of the second input content may also affect the determination of the third input content. Generally, the second input content is different in type and the third input content is different. The type of second input content may be, for example, a positive answer or a negative answer. Depending on whether the type of the second content is a positive type or a negative type, a different third input content may be determined. Of course, the type of the second input content may be other types.
Taking instant messaging software chat for example, the first user and the second user are described. In specific implementation, the content of the last question input by the user and the answer situation of the other party to the last question can be obtained, the topic type classification of the last question is carried out by combining the current application program type and using the trained topic classification model, a pre-constructed question database is queried, and N questions with the partial order relation larger than that of the last question are used as questions possibly questioned by the user in the next step. As one example illustration, when the first user asks the seller at application A whether the book is genuine, the seller reply is genuine. ". At this time, the type of application a that can be used by the first user is acquired as a shopping-type application. And classifying topics to obtain the topic types of book shopping. Based on the questions input by the user and the affirmative answers of the opposite party to the questions, K questions with the partial order relation larger than the current questions under the same scene category are queried. And prompting the K progressive questions to a user as third input content so as to facilitate the user to select and further consult. By way of further example, user a enters question 1: "do package mail? ", answer to each other: and yes, package post. "at this time, the scene category of question 1 is determined to be shopping category. Corresponding to the affirmative answer type, after the occurrence of the question 1 in the shopping scene, the questions that may occur next are respectively: "can be reached for several days? "," is it now shipped? "etc., at this time, K questions having a partial order relation larger than the current question under the same category may be determined as the third input content. If user a inputs question 1: "do package mail? ", answer to each other: "do not cover mail". "then, corresponding to question 1 and negative answer type, after question 1 appears in the shopping scenario, the following questions may appear: "do there a coupon? "," can be discounted? "etc. It follows that the third input content thus determined may be different for different reply types.
In the embodiment of the invention, a question-answer sentence library can be constructed in advance, and the relation between the question-answer sentences and the application scene categories is established. And constructing partial order relations of the question-answer sentences according to the appearance sequence of the question-answer sentences under the same application scene category. When receiving the input content, the method can acquire the third input content with the partial order relation meeting the preset condition according to the input content of the user and the reply to the input content, the scene category and the partial order relation, and prompt the user, so that the user can quickly acquire candidates, quick input is realized, and the input efficiency of the user is improved.
Referring to fig. 2, a schematic diagram of an input prediction apparatus according to an embodiment of the invention is provided.
An input prediction apparatus 200, comprising:
an acquisition unit 201 is configured to acquire a first input content and a second input content. The specific implementation of the obtaining unit 201 may be implemented with reference to step 101 of the embodiment shown in fig. 1.
A determining unit 202, configured to determine a scene category corresponding to the first input content. The specific implementation of the determining unit 202 may be implemented with reference to step 102 of the embodiment shown in fig. 1.
A prediction unit 203, configured to predict, according to the first input content, the scene category, and the second input content, a third input content that meets a preset condition with a partial order relation of the first input content; the partial order relation is used for describing the sequence of each input content. The specific implementation of the determining unit 203 may be implemented with reference to step 103 of the embodiment shown in fig. 1.
In some embodiments, the apparatus further comprises:
the clustering processing unit is used for acquiring question-answer sentences, carrying out scene clustering processing on the question-answer sentences and storing the corresponding relation between the question-answer sentences and scene categories; the question-answer sentence comprises a question and/or a answer;
the system comprises a question-answer sentence generation unit, a question-answer sentence generation unit and a question-answer sentence generation unit, wherein the question-answer sentence generation unit is used for generating a question-answer sentence generation sequence according to the question-answer sentence generation sequence.
In some embodiments, the determining unit is specifically configured to: acquiring a question-answer sentence matched with the first input content; and determining the scene category of the first input content according to the corresponding relation between the question-answer sentence and the scene category.
In some embodiments, the determining unit specifically includes:
a first determining subunit, configured to determine a class of an application program corresponding to the first input content; and/or the number of the groups of groups,
and the second determining subunit is used for determining the category of the topic corresponding to the first input content.
In some embodiments, the prediction unit is specifically configured to: acquiring a type of second input content, and acquiring input content with a partial order relation larger than that of the first input content under the scene category according to the type of the second input content as third input content; the second input content is different in type, and the acquired third input content is different.
In some embodiments, the prediction unit is specifically configured to: and acquiring the type of the second input content, and acquiring the input content with the probability of being more than a set threshold value after the first input content in the scene category according to the type of the second input content as third input content.
In some embodiments, the arrangement of each unit or module of the apparatus of the present invention may be implemented by referring to the method shown in fig. 1, which is not described herein.
Referring to fig. 3, a block diagram for an input prediction apparatus is shown according to an exemplary embodiment. Referring to fig. 3, a block diagram for an input prediction apparatus is shown according to an exemplary embodiment. For example, apparatus 300 may be a mobile phone, computer, digital broadcast terminal, messaging device, game console, tablet device, medical device, exercise device, personal digital assistant, or the like.
Referring to fig. 3, apparatus 300 may include one or more of the following components: a processing component 302, a memory 304, a power supply component 306, a multimedia component 308, an audio component 310, an input/output (I/O) interface 312, a sensor component 314, and a communication component 316.
The processing component 302 generally controls overall operation of the apparatus 300, such as operations associated with display, telephone calls, data communications, camera operations, and recording operations. The processing component 302 may include one or more processors 320 to execute instructions to perform all or part of the steps of the methods described above. Further, the processing component 302 can include one or more modules that facilitate interactions between the processing component 302 and other components. For example, the processing component 302 may include a multimedia module to facilitate interaction between the multimedia component 308 and the processing component 302.
Memory 304 is configured to store various types of data to support operations at device 300. Examples of such data include instructions for any application or method operating on the device 300, contact data, phonebook data, messages, pictures, videos, and the like. The memory 304 may be implemented by any type or combination of volatile or nonvolatile memory devices such as Static Random Access Memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic or optical disk.
The power supply component 306 provides power to the various components of the device 300. The power supply components 306 may include a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power for the device 300.
The multimedia component 308 includes a screen between the device 300 and the user that provides an output interface. In some embodiments, the screen may include a Liquid Crystal Display (LCD) and a Touch Panel (TP). If the screen includes a touch panel, the screen may be implemented as a touch screen to receive input signals from a user. The touch panel includes one or more touch sensors to sense touches, swipes, and gestures on the touch panel. The touch sensor may sense not only the boundary of a touch or slide action, but also the duration and pressure associated with the touch or slide operation. In some embodiments, the multimedia component 308 includes a front-facing camera and/or a rear-facing camera. The front-facing camera and/or the rear-facing camera may receive external multimedia data when the device 300 is in an operational mode, such as a shooting mode or a video mode. Each front camera and rear camera may be a fixed optical lens system or have focal length and optical zoom capabilities.
The audio component 310 is configured to output and/or input audio signals. For example, the audio component 310 includes a Microphone (MIC) configured to receive external audio signals when the device 300 is in an operational mode, such as a call mode, a recording mode, and a voice recognition mode. The received audio signals may be further stored in the memory 304 or transmitted via the communication component 316. In some embodiments, audio component 310 further comprises a speaker for outputting audio signals.
The I/O interface 312 provides an interface between the processing component 302 and peripheral interface modules, which may be a keyboard, click wheel, buttons, etc. These buttons may include, but are not limited to: homepage button, volume button, start button, and lock button.
The sensor assembly 314 includes one or more sensors for providing status assessment of various aspects of the apparatus 300. For example, the sensor assembly 314 may detect the on/off state of the device 300, the relative positioning of the components, such as the display and keypad of the apparatus 300, the sensor assembly 314 may also detect a change in position of the apparatus 300 or one component of the apparatus 300, the presence or absence of user contact with the apparatus 300, the orientation or acceleration/deceleration of the apparatus 300, and a change in temperature of the apparatus 300. The sensor assembly 314 may include a proximity sensor configured to detect the presence of nearby objects in the absence of any physical contact. The sensor assembly 314 may also include a light sensor, such as a CMOS or CCD image sensor, for use in imaging applications. In some embodiments, the sensor assembly 314 may also include an acceleration sensor, a gyroscopic sensor, a magnetic sensor, a pressure sensor, or a temperature sensor.
The communication component 316 is configured to facilitate communication between the apparatus 300 and other devices, either wired or wireless. The device 300 may access a wireless network based on a communication standard, such as WiFi,2G or 3G, or a combination thereof. In one exemplary embodiment, the communication part 314 receives a broadcast signal or broadcast-related information from an external broadcast management system via a broadcast channel. In an exemplary embodiment, the communication component 314 further includes a Near Field Communication (NFC) module to facilitate short range communications. For example, the NFC module may be implemented based on Radio Frequency Identification (RFID) technology, infrared data association (IrDA) technology, ultra Wideband (UWB) technology, bluetooth (BT) technology, and other technologies.
In an exemplary embodiment, the apparatus 300 may be implemented by one or more Application Specific Integrated Circuits (ASICs), digital Signal Processors (DSPs), digital Signal Processing Devices (DSPDs), programmable Logic Devices (PLDs), field Programmable Gate Arrays (FPGAs), controllers, microcontrollers, microprocessors, or other electronic elements for executing the methods described above.
Specifically, an embodiment of the present invention provides an input prediction device 300, including a memory 304, and one or more programs, wherein the one or more programs are stored in the memory 304, and configured to be executed by the one or more processors 320, the one or more programs include instructions for: acquiring first input content and second input content; determining a scene category corresponding to the first input content; according to the first input content, the scene category and the second input content, predicting to obtain third input content which accords with a preset condition with the partial order relation of the first input content; the partial order relation is used for describing the sequence of each input content.
Further, the processor 320 is specifically configured to execute the one or more programs including instructions for: acquiring a question-answer sentence, performing scene clustering processing on the question-answer sentence, and storing the corresponding relation between the question-answer sentence and scene category; the question-answer sentence comprises a question and/or a answer; acquiring the sequence of the occurrence of the question-answer sentences in the same scene category, and establishing the partial sequence relation of each question-answer sentence according to the sequence of the occurrence of the question-answer sentences.
Further, the processor 320 is specifically configured to execute the one or more programs including instructions for: acquiring a question-answer sentence matched with the first input content; and determining the scene category of the first input content according to the corresponding relation between the question-answer sentence and the scene category.
Further, the processor 320 is specifically configured to execute the one or more programs including instructions for: determining the category of the application program corresponding to the first input content; and/or determining the category of the topic corresponding to the first input content.
Further, the processor 320 is specifically configured to execute the one or more programs including instructions for: acquiring a type of second input content, and acquiring input content with a partial order relation larger than that of the first input content under the scene category according to the type of the second input content as third input content; the second input content is different in type, and the acquired third input content is different.
Further, the processor 320 is specifically configured to execute the one or more programs including instructions for: and acquiring the type of the second input content, and acquiring the input content with the probability of being more than a set threshold value after the first input content in the scene category according to the type of the second input content as third input content.
In an exemplary embodiment, a non-transitory computer readable storage medium is also provided, such as memory 304, including instructions executable by processor 320 of apparatus 300 to perform the above-described method. For example, the non-transitory computer readable storage medium may be ROM, random Access Memory (RAM), CD-ROM, magnetic tape, floppy disk, optical data storage device, etc.
A machine-readable medium, for example, the machine-readable medium may be a non-transitory computer-readable storage medium, which when executed by a processor of an apparatus (terminal or server) causes the apparatus to perform an input prediction method, the method comprising: acquiring first input content and second input content; determining a scene category corresponding to the first input content; according to the first input content, the scene category and the second input content, predicting to obtain third input content which accords with a preset condition with the partial order relation of the first input content; the partial order relation is used for describing the sequence of each input content.
Fig. 4 is a schematic structural diagram of a server according to an embodiment of the present invention. The server 400 may vary considerably in configuration or performance and may include one or more central processing units (central processing units, CPU) 422 (e.g., one or more processors) and memory 432, one or more storage media 430 (e.g., one or more mass storage devices) storing applications 442 or data 444. Wherein memory 432 and storage medium 430 may be transitory or persistent storage. The program stored on the storage medium 430 may include one or more modules (not shown), each of which may include a series of instruction operations on a server. Still further, the central processor 422 may be configured to communicate with the storage medium 430 and execute a series of instruction operations in the storage medium 430 on the server 400.
The server 400 may also include one or more power supplies 426, one or more wired or wireless network interfaces 440, one or more input/output interfaces 448, one or more keyboards 446, and/or one or more operating systems 441, such as Windows ServerTM, mac OS XTM, unixTM, linuxTM, freeBSDTM, or the like.
Other embodiments of the invention will be apparent to those skilled in the art from consideration of the specification and practice of the invention disclosed herein. This invention is intended to cover any variations, uses, or adaptations of the invention following, in general, the principles of the invention and including such departures from the present disclosure as come within known or customary practice within the art to which the invention pertains. It is intended that the specification and examples be considered as exemplary only, with a true scope and spirit of the invention being indicated by the following claims.
It is to be understood that the invention is not limited to the precise arrangements and instrumentalities shown in the drawings, which have been described above, and that various modifications and changes may be effected without departing from the scope thereof. The scope of the invention is limited only by the appended claims
The foregoing description of the preferred embodiments of the invention is not intended to limit the invention to the precise form disclosed, and any such modifications, equivalents, and alternatives falling within the spirit and scope of the invention are intended to be included within the scope of the invention.
It is noted that relational terms such as first and second, and the like are used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Moreover, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising one … …" does not exclude the presence of other like elements in a process, method, article, or apparatus that comprises the element. The invention may be described in the general context of computer-executable instructions, such as program modules, being executed by a computer. Generally, program modules include routines, programs, objects, components, data structures, etc. that perform particular tasks or implement particular abstract data types. The invention may also be practiced in distributed computing environments where tasks are performed by remote processing devices that are linked through a communications network. In a distributed computing environment, program modules may be located in both local and remote computer storage media including memory storage devices.
In this specification, each embodiment is described in a progressive manner, and identical and similar parts of each embodiment are all referred to each other, and each embodiment mainly describes differences from other embodiments. In particular, for the device embodiments, since they are substantially similar to the method embodiments, the description is relatively simple, and reference is made to the description of the method embodiments for relevant points. The apparatus embodiments described above are merely illustrative, wherein the elements illustrated as separate elements may or may not be physically separate, and the elements shown as elements may or may not be physical elements, may be located in one place, or may be distributed over a plurality of network elements. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of this embodiment. Those of ordinary skill in the art will understand and implement the present invention without undue burden. The foregoing is merely illustrative of the embodiments of this invention and it will be appreciated by those skilled in the art that variations and modifications may be made without departing from the principles of the invention, and it is intended to cover all modifications and variations as fall within the scope of the invention.

Claims (13)

1. An input prediction method, comprising:
acquiring first input content and second input content; the first input content is a first question, and the second input content is a reply to the first question;
determining a scene category corresponding to the first input content;
acquiring a type of second input content, and acquiring input content with a partial order relation larger than that of the first input content under the scene category according to the type of the second input content as third input content; wherein the types of the second input contents are different, and the acquired third input contents are different; the partial sequence relation is used for describing the sequence of each input content; the type of the second input content is a positive type or a negative type; the third input content is a progressive question of the first input content;
the determining mode of the partial sequence relation comprises the following steps: carrying out statistical analysis on the corpus of question-answer sentences to obtain the sequence of the occurrence of the question-answer sentences in the same scene category, and establishing a partial sequence relation of each question-answer sentence according to the sequence of the occurrence of the question-answer sentences; the sequence of the questions and the answers is determined according to the progressive relation among the questions in the corpus of the questions and the answers;
The partial order relation of each question-answer sentence is also used for establishing a probability transition directed graph, nodes in the probability transition directed graph are used for representing problems, directed edges among the nodes are used for describing the sequence or the transition direction of the nodes, and numerical values on the directed edges are used for representing transition probabilities among the nodes; the third input content includes: the probability of the input content appearing after the first input content is larger than the set threshold value, or the probability of the input content appearing after the first input content is ranked from big to small and then the N input contents of the first N bits are ranked.
2. The method according to claim 1, wherein the method further comprises:
acquiring a question-answer sentence, performing scene clustering processing on the question-answer sentence, and storing the corresponding relation between the question-answer sentence and scene category; the question-answer sentence comprises a question and/or a answer;
acquiring the sequence of the occurrence of the question-answer sentences in the same scene category, and establishing the partial sequence relation of each question-answer sentence according to the sequence of the occurrence of the question-answer sentences.
3. The method according to claim 1 or 2, wherein the determining a scene category to which the first input content corresponds comprises:
Acquiring a question-answer sentence matched with the first input content;
and determining the scene category of the first input content according to the corresponding relation between the question-answer sentence and the scene category.
4. The method according to claim 1 or 2, wherein the determining a scene category to which the first input content corresponds comprises:
determining the category of the application program corresponding to the first input content; and/or the number of the groups of groups,
and determining the category of the topic corresponding to the first input content.
5. An input prediction apparatus, comprising:
the acquisition unit is used for acquiring the first input content and the second input content; the first input content is a first question, and the second input content is a reply to the first question;
the determining unit is used for determining a scene category corresponding to the first input content;
the prediction unit is used for obtaining the type of the second input content, and obtaining the input content with the partial order relation larger than that of the first input content under the scene category according to the type of the second input content as a third input content; wherein the types of the second input contents are different, and the acquired third input contents are different; the partial sequence relation is used for describing the sequence of each input content; the type of the second input content is a positive type or a negative type; the third input content is a progressive question of the first input content;
The determining mode of the partial sequence relation comprises the following steps: carrying out statistical analysis on the corpus of question-answer sentences to obtain the sequence of the occurrence of the question-answer sentences in the same scene category, and establishing a partial sequence relation of each question-answer sentence according to the sequence of the occurrence of the question-answer sentences; the sequence of the questions and the answers is determined according to the progressive relation among the questions in the corpus of the questions and the answers;
the partial order relation of each question-answer sentence is also used for establishing a probability transition directed graph, nodes in the probability transition directed graph are used for representing problems, directed edges among the nodes are used for describing the sequence or the transition direction of the nodes, and numerical values on the directed edges are used for representing transition probabilities among the nodes; the third input content includes: the probability of the input content appearing after the first input content is larger than the set threshold value, or the probability of the input content appearing after the first input content is ranked from big to small and then the N input contents of the first N bits are ranked.
6. The apparatus of claim 5, wherein the apparatus further comprises:
the clustering processing unit is used for acquiring question-answer sentences, carrying out scene clustering processing on the question-answer sentences and storing the corresponding relation between the question-answer sentences and scene categories; the question-answer sentence comprises a question and/or a answer;
The system comprises a question-answer sentence generation unit, a question-answer sentence generation unit and a question-answer sentence generation unit, wherein the question-answer sentence generation unit is used for generating a question-answer sentence generation sequence according to the question-answer sentence generation sequence.
7. The apparatus according to claim 5 or 6, wherein the determining unit is specifically configured to: acquiring a question-answer sentence matched with the first input content; and determining the scene category of the first input content according to the corresponding relation between the question-answer sentence and the scene category.
8. The apparatus according to claim 5 or 6, wherein the determining unit specifically comprises:
a first determining subunit, configured to determine a class of an application program corresponding to the first input content; and/or the number of the groups of groups,
and the second determining subunit is used for determining the category of the topic corresponding to the first input content.
9. An apparatus for input prediction comprising a memory, and one or more programs, wherein the one or more programs are stored in the memory and configured to be executed by one or more processors, the one or more programs comprising instructions for:
Acquiring first input content and second input content; the first input content is a first question, and the second input content is a reply to the first question;
determining a scene category corresponding to the first input content;
acquiring a type of second input content, and acquiring input content with a partial order relation larger than that of the first input content under the scene category according to the type of the second input content as third input content; wherein the types of the second input contents are different, and the acquired third input contents are different; the partial sequence relation is used for describing the sequence of each input content; the type of the second input content is a positive type or a negative type; the third input content is a progressive question of the first input content;
the determining mode of the partial sequence relation comprises the following steps: carrying out statistical analysis on the corpus of question-answer sentences to obtain the sequence of the occurrence of the question-answer sentences in the same scene category, and establishing a partial sequence relation of each question-answer sentence according to the sequence of the occurrence of the question-answer sentences; the sequence of the questions and the answers is determined according to the progressive relation among the questions in the corpus of the questions and the answers;
The partial order relation of each question-answer sentence is also used for establishing a probability transition directed graph, nodes in the probability transition directed graph are used for representing problems, directed edges among the nodes are used for describing the sequence or the transition direction of the nodes, and numerical values on the directed edges are used for representing transition probabilities among the nodes; the third input content includes: the probability of the input content appearing after the first input content is larger than the set threshold value, or the probability of the input content appearing after the first input content is ranked from big to small and then the N input contents of the first N bits are ranked.
10. The apparatus of claim 9, wherein the processor is further specifically configured to execute the one or more programs comprising instructions for: acquiring a question-answer sentence, performing scene clustering processing on the question-answer sentence, and storing the corresponding relation between the question-answer sentence and scene category; the question-answer sentence comprises a question and/or a answer; acquiring the sequence of the occurrence of the question-answer sentences in the same scene category, and establishing the partial sequence relation of each question-answer sentence according to the sequence of the occurrence of the question-answer sentences.
11. The apparatus of claim 9 or 10, wherein the processor is further specifically configured to execute the one or more programs comprising instructions for: acquiring a question-answer sentence matched with the first input content; and determining the scene category of the first input content according to the corresponding relation between the question-answer sentence and the scene category.
12. The apparatus of claim 9 or 10, wherein the processor is further specifically configured to execute the one or more programs comprising instructions for: determining the category of the application program corresponding to the first input content; and/or determining the category of the topic corresponding to the first input content.
13. A machine readable medium having instructions stored thereon that, when executed by one or more processors, cause an apparatus to perform the input prediction method of one or more of claims 1-4.
CN201810443612.6A 2018-05-10 2018-05-10 Input prediction method and device Active CN110471538B (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN201810443612.6A CN110471538B (en) 2018-05-10 2018-05-10 Input prediction method and device
PCT/CN2018/121233 WO2019214234A1 (en) 2018-05-10 2018-12-14 Input prediction method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810443612.6A CN110471538B (en) 2018-05-10 2018-05-10 Input prediction method and device

Publications (2)

Publication Number Publication Date
CN110471538A CN110471538A (en) 2019-11-19
CN110471538B true CN110471538B (en) 2023-11-03

Family

ID=68467768

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810443612.6A Active CN110471538B (en) 2018-05-10 2018-05-10 Input prediction method and device

Country Status (2)

Country Link
CN (1) CN110471538B (en)
WO (1) WO2019214234A1 (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111339280A (en) * 2020-03-23 2020-06-26 上海奔影网络科技有限公司 Question and answer sentence processing method, device, equipment and storage medium

Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CA2813393A1 (en) * 2012-04-30 2013-10-30 Research In Motion Limited Touchscreen keyboard providing word predictions at locations in association with candidate letters
CN103853842A (en) * 2014-03-20 2014-06-11 百度在线网络技术(北京)有限公司 Automatic question and answer method and system
CN104102720A (en) * 2014-07-18 2014-10-15 上海触乐信息科技有限公司 Efficient input prediction method and device
CN104268182A (en) * 2014-09-16 2015-01-07 百度在线网络技术(北京)有限公司 Candidate word sorting method and device and word input method and device
CN105068661A (en) * 2015-09-07 2015-11-18 百度在线网络技术(北京)有限公司 Man-machine interaction method and system based on artificial intelligence
CN105094357A (en) * 2014-05-15 2015-11-25 阿里巴巴集团控股有限公司 Input method and device as well as electronic equipment
CN105912138A (en) * 2016-04-06 2016-08-31 百度在线网络技术(北京)有限公司 Phrase input method and device
CN107168546A (en) * 2017-03-27 2017-09-15 上海奔影网络科技有限公司 Input reminding method and device
CN107479726A (en) * 2017-09-27 2017-12-15 联想(北京)有限公司 A kind of data inputting method and electronic equipment

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105989040B (en) * 2015-02-03 2021-02-09 创新先进技术有限公司 Intelligent question and answer method, device and system
CN106774969B (en) * 2015-11-20 2021-12-14 北京搜狗科技发展有限公司 Input method and device
CN106469212B (en) * 2016-09-05 2019-10-15 北京百度网讯科技有限公司 Man-machine interaction method and device based on artificial intelligence
CN107193883B (en) * 2017-04-27 2020-06-02 北京拓尔思信息技术股份有限公司 Data processing method and system

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CA2813393A1 (en) * 2012-04-30 2013-10-30 Research In Motion Limited Touchscreen keyboard providing word predictions at locations in association with candidate letters
CN103853842A (en) * 2014-03-20 2014-06-11 百度在线网络技术(北京)有限公司 Automatic question and answer method and system
CN105094357A (en) * 2014-05-15 2015-11-25 阿里巴巴集团控股有限公司 Input method and device as well as electronic equipment
CN104102720A (en) * 2014-07-18 2014-10-15 上海触乐信息科技有限公司 Efficient input prediction method and device
CN104268182A (en) * 2014-09-16 2015-01-07 百度在线网络技术(北京)有限公司 Candidate word sorting method and device and word input method and device
CN105068661A (en) * 2015-09-07 2015-11-18 百度在线网络技术(北京)有限公司 Man-machine interaction method and system based on artificial intelligence
CN105912138A (en) * 2016-04-06 2016-08-31 百度在线网络技术(北京)有限公司 Phrase input method and device
CN107168546A (en) * 2017-03-27 2017-09-15 上海奔影网络科技有限公司 Input reminding method and device
CN107479726A (en) * 2017-09-27 2017-12-15 联想(北京)有限公司 A kind of data inputting method and electronic equipment

Also Published As

Publication number Publication date
CN110471538A (en) 2019-11-19
WO2019214234A1 (en) 2019-11-14

Similar Documents

Publication Publication Date Title
CN109800325B (en) Video recommendation method and device and computer-readable storage medium
CN109089133B (en) Video processing method and device, electronic equipment and storage medium
CN109243430B (en) Voice recognition method and device
CN108073303B (en) Input method and device and electronic equipment
CN111968640B (en) Voice control method, voice control device, electronic equipment and storage medium
CN110019885B (en) Expression data recommendation method and device
US11335348B2 (en) Input method, device, apparatus, and storage medium
CN105376412A (en) Information processing method and device
CN112307281A (en) Entity recommendation method and device
CN112784142A (en) Information recommendation method and device
CN113609380B (en) Label system updating method, searching device and electronic equipment
CN109901726B (en) Candidate word generation method and device and candidate word generation device
CN111797746B (en) Face recognition method, device and computer readable storage medium
CN110929122A (en) Data processing method and device and data processing device
CN110471538B (en) Input prediction method and device
CN110147426B (en) Method for determining classification label of query text and related device
CN109144286B (en) Input method and device
CN107515853B (en) Cell word bank pushing method and device
CN110020153B (en) Searching method and device
CN113807540A (en) Data processing method and device
CN110069669B (en) Keyword marking method and device
CN111611339B (en) Recommendation method and related device for inputting related users
CN109729215B (en) Address book processing method and device
CN107688400B (en) Input error correction method and device for input error correction
CN110765338A (en) Data processing method and device and data processing device

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