CN113031787A - Input method, input device and input device - Google Patents

Input method, input device and input device Download PDF

Info

Publication number
CN113031787A
CN113031787A CN201911350125.6A CN201911350125A CN113031787A CN 113031787 A CN113031787 A CN 113031787A CN 201911350125 A CN201911350125 A CN 201911350125A CN 113031787 A CN113031787 A CN 113031787A
Authority
CN
China
Prior art keywords
input
context
determining
intention
intent
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.)
Pending
Application number
CN201911350125.6A
Other languages
Chinese (zh)
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 CN201911350125.6A priority Critical patent/CN113031787A/en
Publication of CN113031787A publication Critical patent/CN113031787A/en
Pending legal-status Critical Current

Links

Images

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
    • G06F3/0233Character input methods
    • G06F3/0236Character input methods using selection techniques to select from displayed items
    • 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)
  • User Interface Of Digital Computer (AREA)

Abstract

The embodiment of the invention provides an input method, an input device and a device for inputting. The method specifically comprises the following steps: determining an input intent in accordance with the context; determining keywords from the context that match the input intent; and determining association candidates corresponding to the context according to the input intention and the keywords. The embodiment of the invention can improve the accuracy of the association candidate.

Description

Input method, input device and input device
Technical Field
The present invention relates to the field of input technologies, and in particular, to an input method, an input device, and an input device.
Background
The device is used as a bridge for the communication between the computer system and the user or other devices, is one of main devices for information interaction between the user and the computer system, and can facilitate the user to input information in various scenes. For example, a user may input a keyword in a search engine to search for a web page, may input a text in an instant messaging APP (Application) to communicate with other users, may input a text in a document APP to edit a document, and so on.
The association function of the input method is an extended function of an input method program, and the occurrence of the association function reduces the times of active input and key pressing of a user and increases the intelligence of the input method. One implementation of the association function includes: and acquiring the latest screen-on content of the user, and inquiring the multivariate relation according to the latest screen-on content to acquire the association candidate. For example, if the last on-screen content is "dog hunting", its corresponding association candidates may include: "input method", "search", "browser", etc.
The inventors have found in implementing the embodiments of the present invention that in a case where a user expresses through a long content, the input intention may not be accurately reflected by the last on-screen content, and in such a case, obtaining a suggested candidate may not accurately reflect the input intention. For example, when the user inputs "a movie is shown recently and its name is" and then, the association candidates such as "what" and "what" are obtained from the last on-screen content "name is", it is obvious that the association candidates do not accurately reflect the input intention.
Disclosure of Invention
The embodiment of the invention provides an input method, an input device and an input device, which can improve the accuracy of association candidates.
In order to solve the above problem, an embodiment of the present invention discloses an input method, including:
determining an input intent in accordance with the context;
determining keywords from the context that match the input intent;
and determining association candidates corresponding to the context according to the input intention and the keywords.
In another aspect, an embodiment of the present invention discloses an input device, including:
an intent determination module to determine an input intent as a function of context;
a keyword determination module for determining keywords matching the input intent from the context; and
and the association candidate determining module is used for determining the association candidate corresponding to the context according to the input intention and the keyword.
In yet another aspect, an embodiment of the present invention discloses an apparatus for input, 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 the one or more processors comprises instructions for:
determining an input intent in accordance with the context;
determining keywords from the context that match the input intent;
and determining association candidates corresponding to the context according to the input intention and the keywords.
In yet another aspect, embodiments of the invention disclose a machine-readable medium having instructions stored thereon, which when executed by one or more processors, cause an apparatus to perform an input method as described in one or more of the preceding.
The embodiment of the invention has the following advantages:
in the embodiment of the present invention, the input intention is determined according to the context, and the input intention may represent information of the content to be input, for example, the information of the content to be input may include: category, entity type, etc.
In addition, the keywords matched with the input intention are determined from the context, the keywords can be used as richness and supplement of the input intention, and are used for determining the association candidate together with the input intention, so that the accuracy of the association candidate can be improved.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings needed to be used in the description of the embodiments of the present invention will be briefly introduced below, and it is obvious that the drawings in the following description are only some embodiments of the present invention, and it is obvious for those skilled in the art that other drawings can be obtained according to these drawings without inventive labor.
FIG. 1 is a schematic illustration of an environment in which an input method of an embodiment of the invention may be used;
FIG. 2 is a flow chart of the steps of a first embodiment of an input method of the present invention;
FIG. 3 is a flowchart illustrating steps of a second embodiment of an input method;
FIG. 4 is a block diagram of an input device according to an embodiment of the present invention;
FIG. 5 is a block diagram of an apparatus 800 for input of the present invention; and
fig. 6 is a schematic structural diagram of a server in some embodiments of the invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are some, not all, embodiments of the present invention. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
The embodiment of the invention provides an input scheme, which can determine an input intention according to context; determining a keyword matched with the input intention from the context; and determining association candidates corresponding to the contexts according to the input intentions and the keywords.
In embodiments of the present invention, the context may include: inputting the upper text corresponding to the cursor and/or inputting the lower text corresponding to the cursor. Alternatively, the context is typically the portion before the input cursor and the context is typically the portion after the input cursor.
According to an embodiment, the above may comprise: last or most recent times of on-screen content. According to another embodiment, the above may comprise: and under the communication scene, communicating the communication content sent by the opposite end. According to yet another embodiment, the above may comprise: and in the communication scene, transmitting the communication content to the correspondent node. It is to be understood that the embodiments of the present invention are not limited to the specific context.
In the embodiment of the present invention, the input intention is determined according to the context, and the input intention may represent information of the content to be input, for example, the information of the content to be input may include: category, entity type, etc. The content to be input may characterize the content to be input, such as words to be input.
The embodiment of the invention determines the keywords matched with the input intention from the context, the keywords can be used as the richness and supplement of the input intention, and the keywords and the input intention are jointly used for determining the association candidate, so that the accuracy of the association candidate can be improved. In other words, the context may include long content, the long content may include irrelevant content that does not match the input intention, and the irrelevant content is used for determining the association candidate, which may cause a certain degree of interference and easily affect the accuracy of the association candidate. The embodiment of the invention determines the keywords matched with the input intention from the context, and uses the keywords and the input intention for determining the association candidate, so that the accuracy of the association candidate can be improved.
In an application example of the embodiment of the present invention, assuming that the above a is "a movie is recently shown and its name is" the embodiment of the present invention may determine that the input intention is "movie name" for the above a, and may determine the following keyword a from the above a: "recent", etc., further, the names of the movies recently shown, such as "player-first", "revenge alliance 3", etc., can be obtained according to the above a and the keyword a.
The embodiment of the invention can be applied to input method programs of various input modes such as keyboard symbols, handwriting and the like, namely, a user can input characters through the code character string, and the input string can refer to the code character string input by the user. In the field of input methods, for input method programs in, for example, chinese, japanese, korean, or other languages, an input string input by a user may be generally converted into a candidate for a corresponding language. Hereinafter, the description will be mainly given by taking Chinese as an example, and other languages such as Japanese and Korean may be referred to each other. It is to be understood that the chinese input method may include, but is not limited to, a full pinyin, a simple pinyin, a stroke, a five-stroke, etc., and the embodiment of the present invention is not limited to a specific input method program corresponding to a certain language.
Taking the input of chinese as an example, the types of the encoding character string may include: pinyin strings, character strings (such as pencils, etc.). Taking english input as an example, the types of the encoding strings may include: alphabetic strings, and the like.
The embodiment of the invention can be applied to an input method program of a voice input mode, and the voice input mode can give out corresponding candidates according to voice input by a user. Specifically, in the embodiment of the present invention, when the input mode of the input method program is a voice input mode, the embodiment of the present invention may provide a corresponding association candidate for the context.
For example, in a communication scenario where user a is ready to recommend a movie to a friend, but does not remember the name of the movie, only remembering the actors of the movie, the context of user a's voice input may include: "the recently shown movie, actor a shows, is good" then embodiments of the present invention may determine that the corresponding input intent is "movie" depending on the context and may provide an association candidate containing "movie name". The user may click on the association candidate to be displayed thereon, or the user may proceed with voice input.
The input method provided by the embodiment of the present invention can be applied to the application environment shown in fig. 1, as shown in fig. 1, the client 100 and the server 200 are located in a wired or wireless network, and the client 100 and the server 200 perform data interaction through the wired or wireless network.
Optionally, the client 100 may run on a terminal, which specifically includes but is not limited to: smart phones, tablet computers, electronic book readers, MP3 (Moving Picture Experts Group Audio Layer III) players, MP4 (Moving Picture Experts Group Audio Layer IV) players, laptop portable computers, car-mounted computers, desktop computers, set-top boxes, smart televisions, wearable devices, and the like. The client 100 may correspond to a website, or APP (Application).
In practical applications, for the input mode of keyboard symbols, a user may input the input string through a physical keyboard or a virtual keyboard. For example, for a terminal with a touch screen, a virtual keyboard may be set in the input interface to use input of an input string by triggering virtual keys included in the virtual keyboard. Optionally, examples of the virtual keyboard may include: a 9-key keyboard, a 26-key keyboard, etc. Moreover, it can be understood that, in addition to the virtual keys corresponding to the letters, the input interface may also be provided with symbol keys, numeric keys, and function keys such as a chinese-english switching key, or may also be provided with toolbar keys, and it can be understood that the specific keys included in the input interface are not limited in the embodiments of the present invention.
According to some embodiments, the input string may include, but is not limited to: a key symbol or a combination of a plurality of key symbols input by a user through a key. The key symbol may specifically include: pinyin, strokes, kana, etc.
In an embodiment of the invention, the candidates may be used to represent one or more characters provided by the input method program to be selected by the user. The candidates may correspond to the context, or the candidates may correspond to the input string and the context. The candidates may be characters of languages such as chinese characters, english characters, japanese characters, and the like, and the candidates may also be symbol combinations in the form of characters, pictures, and the like. The color text includes but is not limited to a drawing composed of lines, symbols and words, for example, examples of the color text may include: ": p ",": o ",": etc.
Method embodiment one
Referring to fig. 2, a flowchart illustrating steps of a first embodiment of an input method according to the present invention is shown, which may specifically include the following steps:
step 201, determining an input intention according to context;
step 202, determining keywords matched with the input intention from the context;
step 203, determining the association candidate corresponding to the context according to the input intention and the keyword.
The method embodiment shown in fig. 2 may be executed by a client and/or a server, and it is understood that the specific execution subject of the method embodiment is not limited by the embodiment of the present invention.
In step 201, the context may include: above, and/or below. Depending on the context, an input intent is determined. The input intent may characterize the information of the content to be input, for example, the information of the content to be input may include: category, entity type, etc.
The embodiment of the invention can provide the following determination mode for determining the input intention:
determining a mode 1, and determining an input intention according to the context and the mapping relation between the context and the input intention; or
And determining a mode 2, carrying out syntactic structure analysis on the context, and obtaining the input intention according to the syntactic structure analysis result.
For determining mode 1, the mapping relationship may characterize the regularity of the relationship between the context and the input intent. The above mapping relationship may be established in advance.
Optionally, the mapping relationship may be obtained according to a corpus and a label input intention corresponding to the corpus. The corpus can include a context, and an input intention corresponding to the context can be obtained through labeling.
The contextually corresponding input intent may specifically include:
the above "Zhougelong", input intent is "Song";
the above "I eat in the morning" input intent is "breakfast";
the above "go to movie theater at night", the input is intended as "movie";
the above "korean president", input intention is "person name";
the above "yaoming height" input intent is "person attribute".
In the embodiment of the present invention, optionally, the mapping relationship between the context and the input intention may be characterized by the data analyzer. Correspondingly, the method may further include: training the training data to obtain a data analyzer; the data analyzer can be used for characterizing the mapping relation between the context and the input intention; the training data may include: and the linguistic data and the label input intention corresponding to the linguistic data.
In an alternative embodiment of the invention, the mathematical model may be trained based on training data to arrive at a data analyzer that may characterize a mapping between input data (context) and output data (input intent).
The mathematical model is a scientific or engineering model constructed by using a mathematical logic method and a mathematical language, and is a mathematical structure which is generally or approximately expressed by adopting the mathematical language aiming at the characteristic or quantity dependency relationship of a certain object system, and the mathematical structure is a relational structure which is described by means of mathematical symbols. The mathematical model may be one or a set of algebraic, differential, integral or statistical equations, and combinations thereof, by which the interrelationships or causal relationships between the variables of the system are described quantitatively or qualitatively. In addition to mathematical models described by equations, there are also models described by other mathematical tools, such as algebra, geometry, topology, mathematical logic, etc. Where the mathematical model describes the behavior and characteristics of the system rather than the actual structure of the system. The method can adopt methods such as machine learning and deep learning methods to train the mathematical model, and the machine learning method can comprise the following steps: linear regression, decision trees, random forests, etc., and the deep learning method may include: convolutional Neural Networks (CNN), Long Short-Term Memory (LSTM), Gated cyclic units (GRU), and so on.
For the determination mode 2, the context may be subjected to syntactic structure analysis, and the input intention may be obtained according to the syntactic structure analysis result.
Syntactic structure analysis may be used to determine the syntactic structure of a sentence or the dependencies between words in a sentence. Alternatively, the topic information of the context may be obtained as the input intention according to the syntactic structure analysis result.
In an optional embodiment of the present invention, the determining the input intention specifically includes: an input intent is determined based on the context and the input environment characteristics.
The input environment characteristics may be used to characterize the environment information in which the terminal is located at the time of the user input. The input environment characteristics can reflect the input intention of the user to a certain extent, so that the input environment characteristics are adopted in the process of determining the input intention, and the accuracy of the input intention can be improved.
In practical applications, the input environment features may include various types of features. Optionally, the input environment feature may include: at least one of a temporal environment feature, a location environment feature, a climate environment feature, an application environment feature, and a page environment feature.
Even if the same terminal is in the environment information which is likely to change, the time environment characteristic is a typical example. Therefore, the input environment characteristics of the embodiment of the invention can have real-time performance, and the input environment characteristics corresponding to the input string can be acquired in real time in the input process.
For an input string, its reception time may be taken as a corresponding temporal environment characteristic.
Location information obtained according to an IP (Internet Protocol) address thereof, a GPS (Global Positioning System) of the terminal, or a mobile communication network may be used as a corresponding location environment characteristic.
The input method program as a hosted program can be hosted by any host program and can be invoked by the host program to realize input in the host program, for example, a user can type an input string in the host program and select a candidate item corresponding to the input string to be displayed on a screen. In the embodiment of the present invention, the application program environment characteristic corresponding to the input string may be information of a host program corresponding to the input method program.
Optionally, the application environment characteristic corresponding to the input string may be determined according to the identification characteristic of the current object being served by the input method program, for example, when the input method program is in operation, the GetModuleFilename finds a program path name "C: programfiless microsoft office 1winword.
In this embodiment of the present invention, the application environment features may include: an application identification and/or an application category. For example, "word" is an application identifier, "word" corresponds to an application category that is an office category, and so on. It is understood that one skilled in the art can classify the application programs into corresponding application program categories according to the actual application requirements, for example, examples of the application program categories may include but are not limited to: an instant messaging category, a document category, a search category, a web page category, a shopping category, a travel category, and the like.
The page environment features may be used to characterize the page environment provided by the application or website, and optionally, the page environment may include, but is not limited to: an instant messaging page environment, a document page environment, a mail page environment, a password entry page environment, a game page environment, a search page environment, a travel page environment, a shopping page environment, a social page environment, a movie page environment, a reading page environment, and the like.
Of course, the input environment features of the embodiment of the present invention may include other environment features, such as physical environment features of barometric pressure, altitude, temperature, humidity, etc., in addition to the time environment feature, the location environment feature, the application environment feature, and the page environment feature. Wherein, it is understood that the embodiment of the present invention does not impose limitation on the specific input environment features.
For example, in the case where the context is "weather today", the input intention may be determined depending on the context and the location environment characteristics. Assuming that the location environment feature is "a area", the input intention is "a area weather" to get a more accurate association candidate.
As another example, in the case of a context of "not knowing what the eating," the input intent may be determined based on the context and the characteristics of the page environment. Assuming that the page environment feature is "take out", the input intention is "take out recommendation" to get more accurate association candidates.
As another example, in the case of the context "what movie was last shown," the input intent may be determined based on the context and the characteristics of the page environment. Assuming that the page environment feature is "movie ticket", the input intention is "movie recommendation" to get more accurate association candidates.
Optionally, a mapping relationship between the context, the input environment feature and the input intention may be established in advance, so that the mapping relationship between the context, the input environment feature and the input intention may be searched according to the context and the input environment feature to obtain the input intention.
The process of determining the input intention is described in detail through the determination manner 1 and the determination manner 2, and it can be understood that a person skilled in the art may adopt any one or a combination of the determination manner 1 and the determination manner 2 according to the actual application requirement, or may also adopt other determination manners, for example, semantic analysis may be performed on the context to obtain the input intention, and the embodiment of the present invention does not limit the specific process of determining the input intention.
In step 202, keywords matching the input intent can be determined from the context.
In an optional embodiment of the present invention, the determining, from the context, a keyword that matches the input intention specifically includes: and performing word segmentation on the context, respectively determining the matching degree between the word segmentation and the input intention, and taking the word segmentation with the matching degree exceeding a threshold value of the matching degree as a keyword. Alternatively, word vectors corresponding to the participles and the input intentions may be respectively determined, and the matching degree between the participles and the input intentions may be determined by using the distances between the word vectors.
In another optional embodiment of the present invention, the determining, from the context, a keyword that matches the input intention specifically includes: and identifying the entity words in the context, respectively determining the matching degree between the entity words and the input intentions, and taking the entity words with the matching degree exceeding a threshold value of the matching degree as the keywords.
In embodiments of the invention, an entity is a particular thing or concept. Entities are generally classified into types, such as people type entities, movies type entities, animals type entities, history type entities, and the like. The same entity may correspond to multiple entity instances, and an entity instance may be a descriptive page (content) of an entity in a network (or other medium), such as a page of encyclopedia, that contains the entity instance corresponding to the entity.
Optionally, the entity may include: named entity (named entity), which may refer to a person's name, organization's name, place name, and all other entities identified by name. The broader named entities may also include: book name, song name, movie title, product name, brand name, number, date, currency, address, etc.
Optionally, the entity category may include at least one of the following categories: characters, places, fruits, vegetables, animals, plants, buildings, clothes, foods, medicines, vehicles, furniture, musical instruments, electric appliances, and natural phenomena.
In one embodiment of the present invention, an NER (Named Entity Recognition) method may be used to determine the entities in the text content.
According to an embodiment, the NER method may include: a thesaurus-based approach. The method based on the word stock can construct an entity stock for the high-frequency words according to the occurrence frequency of the word group, and directly identify the words which can be searched in the entity stock as entities. Where a phrase may refer to a combination of two or more words. In practical application, the entity related data can be captured from the internet, analyzed to obtain the corresponding entity word, and stored in the entity library.
According to another embodiment, the NER method may include: a rule-based approach. The rule-based method may label phrases satisfying the corresponding rules in the request as entities according to the composition rules of the phrases.
According to yet another embodiment, the NER method may include: a statistical learning based approach. The named entity recognition is regarded as a classification problem based on a statistical learning method, and classification methods such as a Support Vector Machine (SVM), Bayes and the like are adopted; alternatively, the named entity recognition is regarded as a sequence tagging problem, and sequence tagging models such as an HMM (Hidden Markov Model), a Maximum Entropy Model (Maximum Entropy Model), a CRF (conditional random field algorithm), and an LSTM (Long Short-Term Memory network) Model are used.
In one application example of the present invention, assuming that the input intention is "weather", keywords related to "weather", such as place name, time, and the like, can be determined from the context.
In step 203, the association candidate corresponding to the context may be determined according to the input intention and the keyword.
In an optional embodiment of the present invention, a search may be performed in the mapping relationship among the input intention, the keyword, and the element according to the input intention and the keyword, so as to obtain the association candidate corresponding to the context.
In the embodiment of the present invention, optionally, the input intention, the keyword, and the mapping relationship between the elements may be represented by the multivariate relational data.
The multivariate relational data may include binary and more than binary relational data. Binary relations, also known as 2-grams, are used to represent the probability of two elements appearing in succession, where in the field of input methods, the elements may include: at least one of words, phrases, letters, numbers, and symbols. In the embodiment of the invention, the binary relation mainly comprises the binary relation of the vocabulary, and other types of binary relations can be referred to each other. More than two-dimensional relationships are used to indicate the probability of two or more elements occurring in succession.
Binary relational data can be used to reflect the probability of two vocabulary adjacencies being used. In one aspect, the vocabulary may include language words composed of letters, which may be words, phrases, or phrases composed of letters printed on a keyboard, and may be specifically applied to english, french, german, or the like; on the other hand, the vocabulary may further include a character sequence corresponding to a text language composed of pinyin and/or strokes, where the character sequence corresponding to the text language composed of pinyin and/or strokes may include words corresponding to pinyin, words corresponding to strokes, and the like, and may be particularly applicable to chinese, japanese, korean, and the like.
In an alternative embodiment of the invention, the multivariate relational data can be characterized by a data model. Types of data models may include, but are not limited to: language models, neural network models, and the like.
The above-described multivariate relational data can obtain P (arbitrary element | input intention, keyword, …), i.e., probability of an arbitrary element under the condition of a mathematical model such as input intention and keyword. From this probability, the association candidates corresponding to the input intention and the keyword can be determined. The corpus used by the data model may include: internet corpus, user dialogue corpus, user input corpus, etc.; the dialog corpus may refer to a corpus corresponding to a dialog established by a user in a communication scenario.
Optionally, the condition of the multivariate relational data may further include: and inputting the environmental characteristics. In this case, the data model may provide P (arbitrary element | input intent, keyword, input environment feature, …).
In another optional embodiment of the invention, a query may be performed in a database corresponding to the input intention according to the input intention and the keyword to obtain the association candidate. And (4) obtaining association candidates based on database query, so as to obtain real-time data.
Alternatively, the database corresponding to the input intention may be provided by the service provider, for example, the types of the database may include: weather databases, music databases, etc.
In an application example of the embodiment of the present invention, it is assumed that the context is "weather of today", it is assumed that the input intention is determined to be "weather of a region a" according to the context and the geographic position feature, and a keyword "weather of today" corresponding to the input intention can be determined in the context; furthermore, according to the weather of the area A and the weather of the area today, a weather database is inquired, the weather of the area A today is clear, and therefore associative candidates such as clear weather, clear sky and good weather can be given.
In another application example of the present invention, assuming that the context is "a science fiction movie is to be shown recently", the input intention "movie name" can be obtained according to the context, and the following keywords matching the input intention are obtained from the context: "recent", "science fiction"; and further, according to the input intention and the keywords, the most recently shown science fiction movies are inquired to have associative candidates such as 'first player', 'revenge alliance 3' and the like.
To sum up, the input method according to the embodiment of the present invention determines the input intention according to the context, and the input intention may represent information of the content to be input, for example, the information of the content to be input may include: category, entity type, etc.
In addition, the keywords matched with the input intention are determined from the context, the keywords can be used as richness and supplement of the input intention, and are used for determining the association candidate together with the input intention, so that the accuracy of the association candidate can be improved.
Method embodiment two
Referring to fig. 3, a flowchart illustrating steps of a second embodiment of the input method of the present invention is shown, which may specifically include the following steps:
step 301, determining an input intention according to the context;
step 302, determining keywords matched with the input intention from the context;
step 303, determining association candidates corresponding to the context according to the input intention and the keyword.
With respect to the first embodiment of the method shown in fig. 2, the method of this embodiment may further include:
step 304, determining quality parameters of the association candidates according to the parameters of the input intentions, and/or the parameters of the keywords, and/or the parameters of the association candidates;
step 305, outputting the association candidate according to the quality parameter.
The embodiment of the invention can also determine the quality parameter of the association candidate, and the quality parameter can represent the quality of the association candidate. And outputting the association candidates according to the quality parameters, so that a plurality of association candidates with higher quality can be provided for the user.
In step 304, the determination factor of the quality parameter may include at least one of the following factors: parameters of the intent, parameters of the keyword, and parameters of the association candidate are input.
Wherein the parameter of the input intent may characterize the quality or accuracy of the input intent. Optionally, the parameter of the input intention may be determined according to click information of the association candidate corresponding to the input intention. Optionally, the quality of the input intention is higher as the click rate of the association candidate corresponding to the input intention is higher, and conversely, the quality of the input intention is lower as the click rate of the association candidate corresponding to the input intention is lower. The click rate may be determined according to the number of times of presentation of the association candidate corresponding to the input intention and the number of times of clicking of the association candidate corresponding to the input intention.
The parameters of the keywords can be used to characterize the importance of the keywords. According to an embodiment, the parameter of the keyword may be obtained according to a distance parameter between the keyword and the associated candidate. Generally, the closer the distance to the parameter representation, the higher the importance of the keyword, whereas the farther the distance from the parameter representation, the lower the importance of the keyword.
According to another embodiment, the attention mechanism of the neural network may be utilized to determine the importance of the keywords in context.
The parameters of the association candidates may be used to characterize the importance or quality of the association candidates. The parameters of the association candidates may include: the word frequency of the corresponding entry of the association candidate, and/or whether the word frequency of the corresponding entry of the association candidate comes from the user word stock, and/or the matching degree between the association candidate and the input intention, and the like. Whether the corresponding entry is from the user's thesaurus, etc. In general, if the word frequency of the entry corresponding to the association candidate is from the user lexicon, the quality of the association candidate is high.
In an optional embodiment of the present invention, the associative candidates may be ranked in order of the quality characterized by the quality parameter from high to low to obtain corresponding ranking results. Optionally, the N association candidates with the highest quality may be selected from the ranking results and presented to the user. Or, M association candidates with quality parameters exceeding the parameter threshold may be selected from the sorted results and presented to the user. N, M may be a natural number.
In step 305, the server may output the association candidate to the client, or the client may present the association candidate to the user.
It should be noted that, for simplicity of description, the method embodiments are described as a series of movement combinations, but those skilled in the art should understand that the present invention is not limited by the described movement sequence, because some steps can be performed in other sequences or simultaneously according to the present invention. Further, those skilled in the art will appreciate that the embodiments described in the specification are presently preferred and that no moving act is required as an embodiment of the invention.
Device embodiment
Referring to fig. 4, a block diagram of an embodiment of an input device according to the present invention is shown, which may specifically include:
an intent determination module 401 for determining an input intent depending on the context;
a keyword determination module 402 for determining keywords from the context that match the input intent; and
an association candidate determining module 403, configured to determine an association candidate corresponding to the context according to the input intention and the keyword.
Optionally, the intent determination module 401 may include:
the first intention determining module is used for determining the input intention according to the context and the mapping relation between the context and the input intention; or
And the second intention determining module is used for carrying out syntactic structure analysis on the context and obtaining the input intention according to the syntactic structure analysis result.
Optionally, the mapping relationship is obtained according to a corpus and a label input intention corresponding to the corpus.
Optionally, the intent determination module 401 may include:
and the third intention determining module is used for determining the input intention according to the context and the input environment characteristics.
Optionally, the input environment feature may include at least one of the following features:
a time environment feature, a location environment feature, a climate environment feature, an application environment feature, and a page environment feature.
Optionally, the apparatus may further include:
a quality parameter determination module, configured to determine a quality parameter of the association candidate according to the parameter of the input intention, and/or the parameter of the keyword, and/or the parameter of the association candidate;
and the association candidate output module is used for outputting the association candidates according to the quality parameters.
Optionally, the parameter of the keyword is obtained according to a distance parameter between the keyword and the associated candidate.
For the device embodiment, since it is basically similar to the method embodiment, the description is simple, and for the relevant points, refer to the partial description of the method embodiment.
The embodiments in the present specification are described in a progressive manner, each embodiment focuses on differences from other embodiments, and the same and similar parts among the embodiments are referred to each other.
With regard to the apparatus in the above-described embodiment, the specific manner in which each module performs the operation has been described in detail in the embodiment related to the method, and will not be elaborated here.
An embodiment of the present invention provides an apparatus for input, comprising a memory, and one or more programs, wherein the one or more programs are stored in the memory, and the one or more programs configured to be executed by the one or more processors include instructions for: determining an input intent in accordance with the context; determining keywords from the context that match the input intent; and determining association candidates corresponding to the context according to the input intention and the keywords.
FIG. 5 is a block diagram illustrating an apparatus 800 for input according to an example embodiment. For example, the apparatus 800 may be a mobile phone, a computer, a digital broadcast terminal, a messaging device, a game console, a tablet device, a medical device, an exercise device, a personal digital assistant, and the like.
Referring to fig. 5, the apparatus 800 may include one or more of the following components: processing component 802, memory 804, power component 806, multimedia component 808, audio component 810, input/output (I/O) interface 812, sensor component 814, and communication component 816.
The processing component 802 generally controls overall operation of the device 800, such as operations associated with display, telephone calls, data communications, camera operations, and recording operations. The processing elements 802 may include one or more processors 820 to execute instructions to perform all or a portion of the steps of the methods described above. Further, the processing component 802 can include one or more modules that facilitate interaction between the processing component 802 and other components. For example, the processing component 802 can include a multimedia module to facilitate interaction between the multimedia component 808 and the processing component 802.
The memory 804 is configured to store various types of data to support operation at the device 800. Examples of such data include instructions for any application or method operating on device 800, contact data, phonebook data, messages, pictures, videos, and so forth. The memory 804 may be implemented by any type or combination of volatile or non-volatile 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 disks.
Power components 806 provide power to the various components of device 800. The power components 806 may include a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power for the apparatus 800.
The multimedia component 808 includes a screen that provides an output interface between the device 800 and a user as described above. 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 an input signal from a user. The touch panel includes one or more touch sensors to sense touch, slide, and gestures on the touch panel. The touch sensor may not only sense the boundary of the touch or slide action but also detect the duration and pressure associated with the touch or slide operation. In some embodiments, the multimedia component 808 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 800 is in an operating 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 a focal length and optical zoom capability.
The audio component 810 is configured to output and/or input audio signals. For example, the audio component 810 includes a Microphone (MIC) configured to receive external audio signals when the apparatus 800 is in an operational mode, such as a call mode, a recording mode, and a voice input mode. The received audio signals may further be stored in the memory 804 or transmitted via the communication component 816. In some embodiments, audio component 810 also includes a speaker for outputting audio signals.
The I/O interface 812 provides an interface between the processing component 802 and peripheral interface modules, which may be keyboards, click wheels, buttons, etc. These buttons may include, but are not limited to: a home button, a volume button, a start button, and a lock button.
The sensor assembly 814 includes one or more sensors for providing various aspects of state assessment for the device 800. For example, the sensor assembly 814 may detect the open/closed state of the device 800, the relative positioning of components, such as a display and keypad of the apparatus 800, the sensor assembly 814 may also detect a change in position of the apparatus 800 or a component of the apparatus 800, the presence or absence of user contact with the apparatus 800, orientation or acceleration/deceleration of the apparatus 800, and a change in temperature of the apparatus 800. Sensor assembly 814 may include a proximity sensor configured to detect the presence of a nearby object without any physical contact. The sensor assembly 814 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 814 may also include an acceleration sensor, a gyroscope sensor, a magnetic sensor, a pressure sensor, or a temperature sensor.
The communication component 816 is configured to facilitate communications between the apparatus 800 and other devices in a wired or wireless manner. The device 800 may access a wireless network based on a communication standard, such as WiFi, 2G or 3G, or a combination thereof. In an exemplary embodiment, the communication component 816 receives a broadcast signal or broadcast related information from an external broadcast management system via a broadcast channel. In an exemplary embodiment, the above-mentioned communication component 816 further comprises a Near Field Communication (NFC) module to facilitate short-range communication. 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 800 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, micro-controllers, microprocessors or other electronic components for performing the above-described methods.
In an exemplary embodiment, a non-transitory computer-readable storage medium comprising instructions, such as the memory 804 comprising instructions, executable by the processor 820 of the device 800 to perform the above-described method is also provided. For example, the non-transitory computer readable storage medium may be a ROM, a Random Access Memory (RAM), a CD-ROM, a magnetic tape, a floppy disk, an optical data storage device, and the like.
Fig. 6 is a schematic diagram of a server in some embodiments of the invention. The server 1900 may vary widely by configuration or performance and may include one or more Central Processing Units (CPUs) 1922 (e.g., one or more processors) and memory 1932, one or more storage media 1930 (e.g., one or more mass storage devices) storing applications 1942 or data 1944. Memory 1932 and storage medium 1930 can be, among other things, transient or persistent storage. The program stored in the storage medium 1930 may include one or more modules (not shown), each of which may include a series of instructions operating on a server. Still further, a central processor 1922 may be provided in communication with the storage medium 1930 to execute a series of instruction operations in the storage medium 1930 on the server 1900.
The server 1900 may also include one or more power supplies 1926, one or more wired or wireless network interfaces 1950, one or more input-output interfaces 1958, one or more keyboards 1956, and/or one or more operating systems 1941, such as Windows Server, Mac OS XTM, UnixTM, LinuxTM, FreeBSDTM, etc.
A non-transitory computer readable storage medium, in which instructions are executed by a processor of an apparatus (server or terminal), so that the apparatus can perform the input method shown in fig. 2 or 3.
A non-transitory computer readable storage medium having instructions therein which, when executed by a processor of an apparatus (server or terminal), enable the apparatus to perform an input method, the method comprising: determining an input intent in accordance with the context; determining keywords from the context that match the input intent; and determining association candidates corresponding to the context according to the input intention and the keywords.
The embodiment of the invention discloses A1 and an input method, wherein the method comprises the following steps:
determining an input intent in accordance with the context;
determining keywords from the context that match the input intent;
and determining association candidates corresponding to the context according to the input intention and the keywords.
A2, the method of A1, the determining an input intent comprising:
determining an input intention according to the context and the mapping relation between the context and the input intention; or
And carrying out syntactic structure analysis on the context, and obtaining an input intention according to a syntactic structure analysis result.
A3, obtaining the mapping relation according to the method of A2 and the labeled input intention corresponding to the corpus.
A4, the method of A1, the determining an input intent comprising:
an input intent is determined based on the context and the input environment characteristics.
A5, the method according to A4, wherein the input environment characteristics comprise at least one of the following characteristics:
a time environment feature, a location environment feature, a climate environment feature, an application environment feature, and a page environment feature.
A6, the method of any one of A1 to A5, the method further comprising:
determining quality parameters of association candidates according to the parameters of the input intentions and/or the parameters of the keywords and/or the parameters of the association candidates;
and outputting the association candidate according to the quality parameter.
A7, according to the method in A6, the parameters of the keywords are obtained according to the distance parameters between the keywords and the associated candidates.
The embodiment of the invention discloses B8 and an input device, which comprises:
an intent determination module to determine an input intent as a function of context;
a keyword determination module for determining keywords matching the input intent from the context; and
and the association candidate determining module is used for determining the association candidate corresponding to the context according to the input intention and the keyword.
B9, the apparatus of B8, the intent determination module comprising:
the first intention determining module is used for determining the input intention according to the context and the mapping relation between the context and the input intention; or
And the second intention determining module is used for carrying out syntactic structure analysis on the context and obtaining the input intention according to the syntactic structure analysis result.
B10, according to the device of B9, the mapping relation is obtained according to the linguistic data and the labeled input intention corresponding to the linguistic data.
B11, the apparatus of B8, the intent determination module comprising:
and the third intention determining module is used for determining the input intention according to the context and the input environment characteristics.
B12, the apparatus according to B11, the input environment characteristics including at least one of:
a time environment feature, a location environment feature, a climate environment feature, an application environment feature, and a page environment feature.
B13, the apparatus according to any one of B8 to B12, further comprising:
the quality parameter determining module is used for determining the quality parameter of the association candidate according to the parameter of the input intention and/or the parameter of the keyword and/or the parameter of the association candidate;
and the association candidate output module is used for outputting the association candidates according to the quality parameters.
B14, according to the device of B13, the parameters of the keywords are obtained according to the distance parameters between the keywords and the associated candidates.
The embodiment of the invention discloses C15, a device for input, comprising a memory, and one or more programs, wherein the one or more programs are stored in the memory, and the one or more programs are configured to be executed by the one or more processors and comprise instructions for:
determining an input intent in accordance with the context;
determining keywords from the context that match the input intent;
and determining association candidates corresponding to the context according to the input intention and the keywords.
C16, the apparatus of C15, the determining an input intent comprising:
determining an input intention according to the context and the mapping relation between the context and the input intention; or
And carrying out syntactic structure analysis on the context, and obtaining an input intention according to a syntactic structure analysis result.
C17, according to the device of C16, the mapping relation is obtained according to the linguistic data and the labeled input intention corresponding to the linguistic data.
C18, the apparatus of C15, the determining an input intent comprising:
an input intent is determined based on the context and the input environment characteristics.
C19, the apparatus according to C18, the input environment characteristics including at least one of:
a time environment feature, a location environment feature, a climate environment feature, an application environment feature, and a page environment feature.
C20, the device of any of C15-C19, the device also configured to execute the one or more programs by one or more processors including instructions for:
determining quality parameters of association candidates according to the parameters of the input intentions and/or the parameters of the keywords and/or the parameters of the association candidates;
and outputting the association candidate according to the quality parameter.
C21, according to the device of C20, the parameters of the keywords are obtained according to the distance parameters between the keywords and the associated candidates.
Embodiments of the present invention disclose D22, a machine-readable medium having instructions stored thereon, which when executed by one or more processors, cause an apparatus to perform an input method as described in one or more of a 1-a 7.
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 will be understood that the invention is not limited to the precise arrangements described above and shown in the drawings and that various modifications and changes may be made without departing from the scope thereof. The scope of the invention is limited only by the appended claims.
The above description is only exemplary of the present invention and should not be taken as limiting the invention, as any modification, equivalent replacement, or improvement made within the spirit and principle of the present invention should be included in the protection scope of the present invention.
The present invention provides an input method, an input device and a device for inputting, which are described in detail above, and the principle and the implementation of the present invention are explained herein by applying specific examples, and the description of the above examples is only used to help understand the method of the present invention and the core idea thereof; meanwhile, for a person skilled in the art, according to the idea of the present invention, there may be variations in the specific embodiments and the application scope, and in view of the above, the content of the present specification should not be construed as a limitation to the present invention.

Claims (10)

1. An input method, characterized in that the method comprises:
determining an input intent in accordance with the context;
determining keywords from the context that match the input intent;
and determining association candidates corresponding to the context according to the input intention and the keywords.
2. The method of claim 1, wherein the determining an input intent comprises:
determining an input intention according to the context and the mapping relation between the context and the input intention; or
And carrying out syntactic structure analysis on the context, and obtaining an input intention according to a syntactic structure analysis result.
3. The method according to claim 2, wherein the mapping relationship is obtained according to a corpus and a labeled input intent corresponding to the corpus.
4. The method of claim 1, wherein the determining an input intent comprises:
an input intent is determined based on the context and the input environment characteristics.
5. The method of claim 4, wherein the input environmental characteristics comprise at least one of:
a time environment feature, a location environment feature, a climate environment feature, an application environment feature, and a page environment feature.
6. The method according to any one of claims 1 to 5, further comprising:
determining quality parameters of association candidates according to the parameters of the input intentions and/or the parameters of the keywords and/or the parameters of the association candidates;
and outputting the association candidate according to the quality parameter.
7. The method according to claim 6, wherein the parameter of the keyword is obtained according to a distance parameter between the keyword and the associated candidate.
8. An input device, comprising:
an intent determination module to determine an input intent as a function of context;
a keyword determination module for determining keywords matching the input intent from the context; and
and the association candidate determining module is used for determining the association candidate corresponding to the context according to the input intention and the keyword.
9. An apparatus for input, 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 the one or more processors, the one or more programs comprising instructions for:
determining an input intent in accordance with the context;
determining keywords from the context that match the input intent;
and determining association candidates corresponding to the context according to the input intention and the keywords.
10. A machine-readable medium having stored thereon instructions, which when executed by one or more processors, cause an apparatus to perform an input method as recited in one or more of claims 1-7.
CN201911350125.6A 2019-12-24 2019-12-24 Input method, input device and input device Pending CN113031787A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201911350125.6A CN113031787A (en) 2019-12-24 2019-12-24 Input method, input device and input device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201911350125.6A CN113031787A (en) 2019-12-24 2019-12-24 Input method, input device and input device

Publications (1)

Publication Number Publication Date
CN113031787A true CN113031787A (en) 2021-06-25

Family

ID=76452026

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201911350125.6A Pending CN113031787A (en) 2019-12-24 2019-12-24 Input method, input device and input device

Country Status (1)

Country Link
CN (1) CN113031787A (en)

Similar Documents

Publication Publication Date Title
US20170344224A1 (en) Suggesting emojis to users for insertion into text-based messages
CN110008401B (en) Keyword extraction method, keyword extraction device, and computer-readable storage medium
CN108304412B (en) Cross-language search method and device for cross-language search
CN108345612B (en) Problem processing method and device for problem processing
CN109101505B (en) Recommendation method, recommendation device and device for recommendation
CN109582869B (en) Data processing method and device and data processing device
CN108803890B (en) Input method, input device and input device
CN111708943B (en) Search result display method and device for displaying search result
CN109521888B (en) Input method, device and medium
CN109783244B (en) Processing method and device for processing
CN107424612B (en) Processing method, apparatus and machine-readable medium
CN110633017A (en) Input method, input device and input device
CN109814730B (en) Input method and device and input device
CN108628911B (en) Expression prediction for user input
CN111708444A (en) Input method, input device and input device
CN114610163A (en) Recommendation method, apparatus and medium
CN112306252A (en) Data processing method and device and data processing device
CN110929122B (en) Data processing method and device for data processing
CN112181163A (en) Input method, input device and input device
CN113031787A (en) Input method, input device and input device
CN114115550A (en) Method and device for processing association candidate
CN113010768B (en) Data processing method and device for data processing
CN113221030A (en) Recommendation method, device and medium
CN112214692A (en) Data processing method and device based on input method and machine readable medium
CN111103986A (en) User word stock management method and device and input method and 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