Input method, device and device for input

By finding the context of the input string in the multivariate relationship data and determining the target hit element to provide the first candidate, the problem that long word association function in the prior art is difficult to provide is solved, and an efficient input experience in the case of short input strings is achieved.

CN112181163BActive Publication Date: 2024-11-15BEIJING SOGOU TECHNOLOGY DEVELOPMENT CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN201910605239.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2019-07-05
Publication Date
2024-11-15
Estimated Expiration
2039-07-05

AI Technical Summary

Technical Problem

When the existing input methods face a large number of Internet corpus and short input strings, the long word association function is difficult to provide, resulting in excessive consumption of equipment resources and low input efficiency.

Method used

By finding the context of the input string in the multivariate relationship data, the target hit element is determined to provide the first candidate, reducing the amount of operations, and supporting the long word association function of the short input string.

Benefits of technology

In the case of reducing device resource consumption, the input efficiency and user experience are improved, and the long word association function of short input strings is provided to improve input efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN112181163B_ABST
    Figure CN112181163B_ABST
Patent Text Reader

Abstract

The embodiment of the present invention provides an input method, device and device for input. The method specifically includes: searching in multivariate relational data according to the context corresponding to the input string to obtain a hit element corresponding to the context; determining a target hit element corresponding to the input string from the hit element; and determining a first candidate corresponding to the input string according to the target hit element corresponding to the input string. The embodiment of the present invention can provide a long word association function corresponding to the input string while reducing the consumption of device resources, thereby improving input efficiency.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of input technology, and in particular to an input method, an input device and a device for input. Background Art

[0002] As a bridge for computer systems to communicate with users or other devices, devices are one of the main means for information exchange between users and computer systems. They can facilitate users to input information in a variety of scenarios. For example, users can enter keywords in search engines to search web pages, enter text in instant messaging apps (applications) to communicate with other users, and enter text in document apps to edit documents, etc.

[0003] The association function of the input method is an extended function of the input method program. Its appearance reduces the number of times the user actively inputs and the number of keystrokes, and increases the intelligence of the input method. An implementation process of the long word association function includes: first, according to the user's input string, the corresponding common candidate is searched in the word library; then, the above-mentioned common candidate is matched with the left element in the binary library, and the first candidate is obtained according to the successfully matched right element. For example, if the input string is "jinttq", the first candidate "Today's weather is good" can be obtained by the above implementation process, where "good" is the successfully matched right element obtained according to "jinttq".

[0004] With the growth of Internet corpus, the number of entries in the vocabulary is also gradually increasing, which leads to a large number of common candidates corresponding to the input string, and then leads to a large amount of calculation corresponding to the matching of the binary library, which will increase the resource consumption of the device. In particular, when the input string is a simplified pinyin string and / or the input string is input through the nine-square grid key, the number of common candidates corresponding to the input string is particularly large. For example, when the nine-square grid key "9" is pressed, all entries starting with wxyz meet the conditions of common candidates, which will lead to a huge amount of calculation corresponding to the matching of the binary library. Therefore, in order to reduce the resource consumption of the device, the long word association function is not provided when the input string is short. The word length corresponding to the input string required by the long word association function is generally 4, that is, the input string matches 4 words in the vocabulary before the long word association function is provided. Otherwise, if the word length corresponding to the input string is less than 4, the long word candidate function is not provided. For example, if the input string is "w" or "jint", the current input method cannot provide the corresponding long word candidate. Summary of the invention

[0005] The embodiments of the present invention provide an input method, an apparatus and a device for input, which can provide a long word association function corresponding to an input string while reducing the consumption of device resources, thereby improving input efficiency.

[0006] In order to solve the above problem, an embodiment of the present invention discloses an input method, including:

[0007] Searching in the multivariate relational data according to the context corresponding to the input string to obtain a hit element corresponding to the context;

[0008] Determine a target hit element corresponding to the input string from the hit elements;

[0009] According to the target hit element corresponding to the input string, a first candidate corresponding to the input string is determined.

[0010] On the other hand, an embodiment of the present invention discloses an input device, comprising:

[0011] A search module, used to search in the multivariate relational data according to the context corresponding to the input string, so as to obtain a hit element corresponding to the context;

[0012] a target hit element determination module, used to determine a target hit element corresponding to the input string from the hit elements; and

[0013] The first candidate determination module is used to determine the first candidate corresponding to the input string according to the target hit element corresponding to the input string.

[0014] In another aspect, an embodiment of the present invention discloses a device for input, comprising a memory and one or more programs, wherein the one or more programs are stored in the memory and are configured to be executed by one or more processors, and the one or more programs include instructions for performing the following operations:

[0015] Searching in the multivariate relational data according to the context corresponding to the input string to obtain a hit element corresponding to the context;

[0016] Determine a target hit element corresponding to the input string from the hit elements;

[0017] According to the target hit element corresponding to the input string, a first candidate corresponding to the input string is determined.

[0018] On the other hand, an embodiment of the present invention discloses a machine-readable medium having instructions stored thereon, which, when executed by one or more processors, causes a device to perform one or more of the input methods described above.

[0019] The embodiments of the present invention include the following advantages:

[0020] The embodiment of the present invention searches for multi-relational data based on context, which can reduce the amount of calculation corresponding to the search compared to searching for multi-relational data based on entries corresponding to an input string, thereby reducing the consumption of device resources.

[0021] Furthermore, the embodiment of the present invention obtains a hit element based on the context, and determines a first candidate corresponding to the input string based on a target hit element corresponding to the input string. The process of obtaining the above-mentioned first candidate does not limit the character length corresponding to the input string. Even if the character length corresponding to the input string is shorter (for example, 1), the embodiment of the present invention can still obtain the corresponding first candidate; therefore, the embodiment of the present invention can provide a long word association function corresponding to the input string while reducing the consumption of device resources, thereby improving input efficiency; and, the embodiment of the present invention can provide users with available long word associations when the input string is shorter, thereby improving the input experience and improving input efficiency. BRIEF DESCRIPTION OF THE DRAWINGS

[0022] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the accompanying drawings required for use in the description of the embodiments of the present invention will be briefly introduced below. Obviously, the accompanying drawings in the following description are only some embodiments of the present invention. For ordinary technicians in this field, other accompanying drawings can be obtained based on these accompanying drawings without paying creative labor.

[0023] Figure 1 is a schematic diagram of an application environment of an input method according to an embodiment of the present invention;

[0024] Figure 2 is a flow chart of steps of an input method embodiment 1 of the present invention;

[0025] Figure 3 is a flow chart of steps of Embodiment 2 of an input method of the present invention;

[0026] Figure 4 is a flow chart of steps of Embodiment 3 of an input method of the present invention;

[0027] Figure 5 is a structural block diagram of an input device embodiment of the present invention;

[0028] Figure 6 is a block diagram of a device 800 for inputting according to the present invention; and

[0029] Figure 7 It is a schematic diagram of the structure of the server in some embodiments of the present invention. DETAILED DESCRIPTION

[0030] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0031] An embodiment of the present invention provides an input scheme, which can search in multi-relational data based on the context corresponding to the input string to obtain a hit element corresponding to the context; determine a target hit element corresponding to the input string from the hit element; and determine a first candidate corresponding to the input string based on the target hit element corresponding to the input string.

[0032] In the embodiment of the present invention, the context may include: the preceding text corresponding to the input string, and / or the following text corresponding to the input string. Optionally, the preceding text is usually the part before the input cursor, and the following text is usually the part after the input cursor.

[0033] According to one embodiment, the above context may include: the most recent or most recent on-screen content. According to another embodiment, the above context may include: the communication content sent by the communication peer in a communication scenario. According to yet another embodiment, the above context may include: the communication content sent to the communication peer in a communication scenario. It is understood that the embodiments of the present invention are not limited to the specific context.

[0034] Multivariate relational data may include binary and more than binary relational data. A binary relation, also known as a 2-gram, is used to represent the probability of two elements appearing one after another. In the field of input methods, the elements here may include at least one of: vocabulary, phrases, short sentences, letters, numbers, and symbols. In an embodiment of the present invention, the binary may mainly include binary relations of vocabulary, and other types of binary relations may refer to each other. Relations of more than two elements are used to represent the probability of more than two elements appearing one after another.

[0035] According to the position of the word in the multi-element relation data, the binary relation data may include: left element and right element, and the ternary relation data may include: left element, middle element and right element. Therefore, in the embodiment of the present invention, the type of the hit element may include: left element, middle element or right element.

[0036] For example, if the input string corresponds to a preceding context but not a following context, the type of the hit element may include: right element. For example, the preceding context corresponding to the input string includes: "you have", "iQiyi", and the input string is "h", then the hit element (right element) obtained based on the multivariate relationship data may include: "member", "video", "?", where the target hit element corresponding to the input string "h" may be "member", thereby providing the first candidate "member".

[0037] For another example, if the input string corresponds to a preceding context and a following context, the type of the hit element may include: middle element. For example, if the preceding context is "weather", the following context is "good scenery everywhere", and the input string is "h", then the hit element (middle element) obtained based on the multivariate relationship data may include: "good sunny", thereby providing the first candidate "good sunny".

[0038] For another example, if the input string corresponds to a context but not to a previous context, the type of the hit element may include: left element. For example, if the context corresponding to the input string includes: "Republic", and the input string is "z", the hit element (left element) obtained based on the multivariate relational data may include: "People's Republic of China", thereby providing the first candidate "People's Republic of China".

[0039] The embodiment of the present invention first searches in multivariate relational data based on the context corresponding to the input string to obtain a hit element corresponding to the context, then determines a target hit element corresponding to the input string from the hit elements, and then determines the first candidate corresponding to the input string based on the target hit element corresponding to the input string.

[0040] The embodiment of the present invention searches for multi-relational data based on context, which can reduce the amount of calculation corresponding to the search compared to searching for multi-relational data based on entries corresponding to an input string, thereby reducing the consumption of device resources.

[0041] Furthermore, the embodiment of the present invention obtains a hit element based on the context, and determines a first candidate corresponding to the input string based on a target hit element corresponding to the input string. The process of obtaining the above-mentioned first candidate does not limit the length of the word corresponding to the input string. Even if the length of the word corresponding to the input string is shorter (for example, 1), the embodiment of the present invention can still obtain the corresponding first candidate. Therefore, the embodiment of the present invention can provide a long word association function corresponding to the input string while reducing the consumption of device resources, thereby improving input efficiency.

[0042] The embodiment of the present invention can be applied to input method programs of various input methods such as keyboard symbols and handwriting, that is, users can input text through coded character strings, and the input string can refer to the coded character string input by the user. In the field of input methods, for input method programs such as Chinese, Japanese, Korean, or other languages, the input string input by the user can usually be converted into candidate items of the corresponding language. The following is mainly explained by taking Chinese as an example, and other languages ​​such as Japanese and Korean can be referenced to each other. It can be understood that the Chinese input method can include but is not limited to full spelling, simplified spelling, strokes, Wubi, etc., and the embodiment of the present invention does not limit the specific input method program corresponding to a certain language.

[0043] Taking Chinese input as an example, the types of encoded character strings may include: Pinyin string, character string (such as Wubi string, etc.) Taking English input as an example, the types of encoded character strings may include: letter string, etc.

[0044] The input method provided by the embodiment of the present invention can be applied to Figure 1 In the application environment shown, Figure 1 As shown, 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 exchange through the wired or wireless network.

[0045] Optionally, the client 100 may be run on a terminal, which specifically includes but is not limited to: a smart phone, a tablet computer, an e-book reader, an MP3 (Moving Picture Experts Group Audio Layer III) player, an MP4 (Moving Picture Experts Group Audio Layer IV) player, a laptop computer, a car computer, a desktop computer, a set-top box, a smart TV, a wearable device, etc. The client 100 may correspond to a website or an APP (Application).

[0046] In actual applications, for the input method of keyboard symbols, the user can input the above input string through a physical keyboard or a virtual keyboard. For example, for a terminal with a touch screen, a virtual keyboard can be set in the input interface to input the input string by triggering the virtual keys included in the above virtual keyboard. Optionally, examples of the above virtual keyboard may include: a 9-key keyboard and a 26-key keyboard. In addition, it can be understood that in addition to the virtual keys corresponding to letters, the above input interface can also be provided with symbol keys, number keys, such as function keys for switching between Chinese and English, or toolbar keys, etc. It can be understood that the embodiment of the present invention does not limit the specific keys included in the input interface.

[0047] According to some embodiments, the input string may include, but is not limited to, a key symbol or a combination of multiple key symbols input by a user through a key. The key symbol may specifically include: pinyin, strokes, kana, and the like.

[0048] In an embodiment of the present invention, a candidate may be used to represent one or more characters provided by an input method program to be selected by a user. A candidate may correspond to a context, or a candidate may correspond to an input string, or a candidate may correspond to an input string and a context. A candidate may be a character in a language such as Chinese characters, English characters, Japanese characters, or a combination of symbols in the form of emoticons, pictures, and the like. The emoticons include, but are not limited to, pictures composed of lines, symbols, and words. For example, examples of the emoticons may include: “:P”, “:-o”, “:-)”, and the like.

[0049] The binary relationship data can be used to reflect the probability of two words being used adjacently. On the one hand, the vocabulary can include language characters composed of letters, which can be words, phrases, and short phrases composed of letters printed on a keyboard, and can be specifically applicable to English, French, German, etc. On the other hand, the vocabulary can also include character sequences corresponding to text languages ​​composed of pinyin and / or strokes. Here, the character sequences corresponding to text languages ​​composed of pinyin and / or strokes can include words corresponding to pinyin, words corresponding to strokes, etc., and can be specifically applicable to Chinese, Japanese, Korean, etc.

[0050] In an optional embodiment of the present invention, multivariate relational data can be represented by a data model. The types of data models may include, but are not limited to, language models, neural network models, etc. The above data model can provide P (any element | context, ...), that is, the probability of any element under certain context and other conditions. Based on this probability, the hit element corresponding to the context can be determined. Among them, the corpus used by the data model may include: corpus under context and other conditions, and the above corpus includes, but is not limited to: Internet corpus, user's chat corpus, user's input corpus, etc.

[0051] Mathematical model is a scientific or engineering model constructed by mathematical logic methods and mathematical language. Mathematical model is a mathematical structure that is expressed in general or approximate terms using mathematical language with reference to the characteristics or quantitative dependencies of a certain system of things. This mathematical structure is a relational structure depicted with the help of mathematical symbols. Mathematical model can be one or a group of algebraic equations, differential equations, difference equations, integral equations or statistical equations and their combinations, which quantitatively or qualitatively describe the mutual relationship or causal relationship between the variables of the system. 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. Among them, mathematical models describe the behavior and characteristics of the system rather than the actual structure of the system. Among them, machine learning, deep learning methods and other methods can be used to train mathematical models. Machine learning methods may include: linear regression, decision tree, random forest, etc. Deep learning methods may include: convolutional neural networks (CNN), long short-term memory networks (LSTM), gated recurrent units (GRU), etc.

[0052] Optionally, the conditions of the data model may further include: input environment characteristics. In this case, the data model may provide P (any element|context, input environment characteristics, ...).

[0053] In the embodiment of the present invention, the input environment feature can be used to characterize the environment information of the terminal when the user inputs. The input environment feature can reflect the user's input intention to a certain extent. Therefore, by establishing a connection between the input environment feature and the user's input intention, the user's input intention can be indirectly identified, thereby improving the user's input efficiency.

[0054] In practical applications, the input environment features may include various types of features. Optionally, the input environment features may include at least one of time environment features, location environment features, climate environment features, application environment features, and page environment features.

[0055] Even for the same terminal, the environment information is likely to change, and the time environment feature is a typical example. Therefore, the input environment feature of the embodiment of the present invention can be real-time, and the input environment feature corresponding to the input string can be obtained in real time during the input process.

[0056] For an input string, its receiving time can be used as the corresponding time environment feature.

[0057] The location information obtained according to its IP (Internet Protocol) address, the GPS (Global Positioning System) of the terminal or the mobile communication network can be used as the corresponding location environment feature.

[0058] As a host program, the input method program can be hosted in any host program and can be called by the host program to implement 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. In the embodiment of the present invention, the application environment feature corresponding to the input string can be information of the host program corresponding to the input method program.

[0059] Optionally, the application environment characteristics corresponding to the input string can be determined based on the identification characteristics of the current object being served by the input method program. For example, when the input method program is running, it calls GetModuleFilename to find the program path name "C:ProgramFilesMicrosoftOfficeOFFICE11WINWORD.EXE", and the corresponding application environment characteristics can be determined to be "WinWord.exe", that is, the input string is entered in "word". Of course, the embodiment of the present invention does not limit the specific method for obtaining the application environment characteristics corresponding to the input string.

[0060] In an embodiment of the present invention, the application environment feature may include: an application identifier and / or an application category. For example, "word" is an application identifier, and the application category corresponding to "word" is an office category, etc. It can be understood that those skilled in the art can classify applications into corresponding application categories according to actual application requirements. For example, examples of application categories may include but are not limited to: instant messaging category, document category, search category, web page category, shopping category, travel category, etc.

[0061] Page environment features can be used to characterize the page environment provided by an application or website. Optionally, the above-mentioned page environment may include but is not limited to: instant messaging page environment, document page environment, email page environment, password input page environment, game page environment, search page environment, travel page environment, shopping page environment, social page environment, film and television page environment, reading page environment, etc.

[0062] Of course, in addition to time environment features, location environment features, application environment features and page environment features, the input environment features of the embodiment of the present invention may also include other environment features, for example, physical environment features such as air pressure, altitude, temperature, humidity, etc. It can be understood that the embodiment of the present invention does not limit the specific input environment features.

[0063] Method Example 1

[0064] Reference Figure 2 , shows a flow chart of the steps of an input method embodiment 1 of the present invention, which may specifically include the following steps:

[0065] Step 201: Search in the multivariate relational data according to the context corresponding to the input string to obtain a hit element corresponding to the context;

[0066] Step 202: Determine a target hit element corresponding to the input string from the hit elements;

[0067] Step 203: Determine the first candidate corresponding to the input string based on the target hit element corresponding to the input string.

[0068] Figure 2 The method embodiment shown may be executed by a client and / or a server. It is to be understood that the embodiment of the present invention does not limit the specific execution subject of the method embodiment.

[0069] In step 201, the context may be matched with the structural field at the corresponding position in the multi-relational data to obtain a hit element corresponding to the context. The hit element may refer to the structural field for the search hit.

[0070] For example, if the context includes: previous text, then the previous text can be matched with the left element in the multi-relational data, and the hit element obtained can be the right element. For another example, if the context includes: following text, then the following text can be matched with the right element in the multi-relational data, and the hit element obtained can be the left element. Alternatively, if the context includes: previous text and following text, then the previous text and following text can be matched with the left element and the right element in the multi-relational data respectively, and the hit element obtained can be the middle element.

[0071] In step 202, the hit elements may be screened to obtain the target hit element corresponding to the input string.

[0072] In an optional embodiment of the present invention, the hit element may be matched with the input string to obtain a target hit element.

[0073] According to an embodiment, the above-mentioned determining the target hit element corresponding to the input string from the hit element may specifically include: matching the encoded character string corresponding to the hit element with the input string to obtain the target hit element corresponding to the input string.

[0074] The embodiment of the present invention may adopt a string matching method, specifically, the encoded string corresponding to the hit element may be matched with the input string.

[0075] Optionally, the input string may be part of the encoding string corresponding to the target hit element. For example, the input string is "h", and the encoding string corresponding to the target hit element is "huiyuan".

[0076] Optionally, the input string may be a prefix of the encoding string corresponding to the target hit element. The prefix may refer to the part located in the front. For example, the input string is "hui", and the encoding string corresponding to the target hit element is "huiyuan".

[0077] According to another embodiment, the above-mentioned determining the target hit element corresponding to the input string from the hit element may specifically include: matching the matching sequence corresponding to the hit element with the matching sequence corresponding to the input string to obtain the target hit element corresponding to the input string.

[0078] The matching sequence may be an intermediate structure between the encoding string and the word entry, which can be used to match the word entry in the word library. The matching sequence may include: a syllable sequence, a shape code sequence, a digital sequence, a symbol sequence, etc. It is understood that the embodiment of the present invention does not limit the specific matching sequence.

[0079] The embodiment of the present invention may adopt a matching method of a matching sequence, specifically, matching the matching sequence corresponding to the hit element with the matching sequence corresponding to the input string.

[0080] For example, the input string is "h", the syllable sequence corresponding to "h" is [h], the encoding string corresponding to the target hit element is "huiyuan", and the syllable sequence corresponding to "huiyuan" is [hui][yuan]. [h] and [hui] match, that is, the simplified pinyin syllable can be matched with the corresponding full pinyin syllable.

[0081] In an optional embodiment of the present invention, the corresponding encoding string or matching sequence can be saved for the structure field in the multi-relational data, that is, the mapping relationship between the structure field and the encoding string or matching sequence can be saved, so that the encoding string or matching sequence corresponding to the hit element can be determined based on the mapping relationship.

[0082] It can be understood that the above-mentioned matching of the hit element with the input string is only an example of a method for determining the target hit element. In fact, those skilled in the art can use other determination methods to determine the target hit element according to actual application requirements.

[0083] In one embodiment of the present invention, the target hit element can be determined based on the conditional probability corresponding to the hit element, thereby improving the quality of the target hit element, and the conditional probability is used to characterize the probability of occurrence of the hit element under the condition of the context. Optionally, the hit element whose conditional probability exceeds the probability threshold can be used as the target hit element, and accordingly, the conditional probability of the target hit element exceeds the probability threshold; the conditional probability is used to characterize the probability of occurrence of the target hit element under the condition of the context.

[0084] Optionally, the conditional probability can be obtained based on the corpus. For example, the corpus can be statistically analyzed, or the corpus can be trained to obtain the conditional probability. The range of the conditional probability can be [0, 1].

[0085] The above probability threshold may be determined by those skilled in the art according to actual application requirements. For example, the above probability threshold may be a value such as 0.6.

[0086] In step 203, the target hit element corresponding to the input string can be directly used as the first candidate corresponding to the input string.

[0087] Alternatively, the target hit element corresponding to the input string may be further processed to obtain the first candidate corresponding to the input string. For example, the target hit element may be further processed by association. For example, based on the target hit element, a search may be performed in the multivariate relational data to obtain the right element corresponding to the target hit element, and based on the target hit element and its corresponding right element, the first candidate may be obtained.

[0088] In summary, the input method of the embodiment of the present invention searches for multi-relational data based on the context, which can reduce the amount of corresponding search operations compared to searching for multi-relational data based on the entries corresponding to the input string, thereby reducing the consumption of device resources.

[0089] Furthermore, the embodiment of the present invention obtains a hit element based on the context, and determines a first candidate corresponding to the input string based on a target hit element corresponding to the input string. The process of obtaining the above-mentioned first candidate does not limit the length of the word corresponding to the input string. Even if the length of the word corresponding to the input string is shorter (for example, 1), the embodiment of the present invention can still obtain the corresponding first candidate. Therefore, the embodiment of the present invention can provide a long word association function corresponding to the input string while reducing the consumption of device resources, thereby improving input efficiency.

[0090] Method Example 2

[0091] Reference Figure 3 , shows a flow chart of the steps of Embodiment 2 of an input method of the present invention, which may specifically include the following steps:

[0092] Step 301: Search in the multi-relationship data according to the context corresponding to the input string to obtain the hit element corresponding to the context.

[0093] Step 302: Determine the target hit element corresponding to the input string from the hit elements.

[0094] Step 303: Determine the first candidate corresponding to the input string according to the target hit element corresponding to the input string.

[0095] Relative to Figure 2 The method of this embodiment may further include, compared with the first method embodiment shown:

[0096] Step 304: Determine the sorting parameter of the first candidate according to the conditional probability of the first candidate, the number of characters of the target hit element, and the number of characters of the entry corresponding to the input string in the thesaurus.

[0097] The conditional probability is used to represent the occurrence probability of the target hit element under the context.

[0098] Step 305: Determine the position of the first candidate in the candidate list according to the sorting parameter of the first candidate.

[0099] The embodiment of the present invention can determine the sorting parameter of the first candidate and determine the position of the first candidate in the candidate list according to the sorting parameter of the first candidate, which can improve the rationality of the position of the first candidate.

[0100] The candidate list corresponds to the input string. The candidate list usually includes multiple candidates. The candidate list may include: Figure 2 The obtained first candidate and second candidates. The second candidates may include: candidates found according to the input string in the thesaurus. The types of thesauruses may include: system thesaurus, user thesaurus, or cloud thesaurus, etc. For example, according to the input string "h", the following second candidates can be found in the thesaurus: "will", "and", "good", "also", etc.

[0101] In an alternative embodiment of the present invention, the associated number of characters corresponding to the first candidate may be determined according to the number of characters of the target hit element and the number of characters of the entry corresponding to the input string in the thesaurus. Optionally, the associated number of characters may be determined according to the difference between the number of characters of the target hit element and the number of characters of the entry corresponding to the input string in the thesaurus. For example, if the first candidate is "member" and the number of characters of the entry corresponding to the input string "h" in the thesaurus is 1, the associated number of characters may be 1.

[0102] The embodiment of the present invention can penalize the conditional probability corresponding to the first candidate according to the associated number of characters. Specifically, the conditional probability corresponding to the first candidate can be reduced according to the associated number of characters.

[0103] Optionally, a penalty value corresponding to the number of associated words can be preset, and the reduction value of the conditional probability corresponding to the first candidate can be: the product of the penalty value corresponding to the number of associated words and the number of associated words. Further, the product can be subtracted from the conditional probability corresponding to the first candidate to obtain the ranking parameter of the first candidate.

[0104] It can be understood that the above-mentioned subtraction of the product from the conditional probability corresponding to the first candidate is only an optional embodiment for reducing the conditional probability corresponding to the first candidate based on the number of associated words. In fact, those skilled in the art can adopt other methods to reduce the conditional probability corresponding to the first candidate based on the number of associated words according to actual application requirements. For example, the reduction ratio is determined based on the number of associated words, and the conditional probability corresponding to the first candidate is reduced based on the reduction ratio, and so on.

[0105] The ranking parameter of the first candidate can be used to determine the position of the first candidate in the candidate list. Optionally, the first candidate and the second candidate in the candidate list can be ranked according to the ranking parameter. Generally, the larger the value corresponding to the ranking parameter, the higher the position of the candidate in the candidate list.

[0106] The ranking parameters of the second candidate may include: the frequency of the word corresponding to the second candidate, whether the word corresponding to the second candidate comes from the user's word library, etc. Generally, if the word corresponding to the second candidate comes from the user's word library, the value corresponding to the ranking parameter of the second candidate is set to a larger value so that the second candidate is ranked first in the candidate list.

[0107] Method Example 3

[0108] Reference Figure 4 , shows a flow chart of steps of a third embodiment of an input method of the present invention, which may specifically include:

[0109] Step 401: Search in the multivariate relational data according to the context corresponding to the input string to obtain a hit element corresponding to the context;

[0110] Step 402: Determine a target hit element corresponding to the input string from the hit elements;

[0111] Step 403: Determine a first candidate corresponding to the input string according to the target hit element corresponding to the input string;

[0112] Relative to Figure 2 The method of the first embodiment shown in the figure may further include:

[0113] Step 404: display a candidate list corresponding to the input string; the candidate list may include: the first candidate and the second candidate, and the second candidate may include: a candidate obtained based on a vocabulary.

[0114] In practical applications, the input method can display the above candidate list through the interface for the user to select.

[0115] Optionally, the candidate list can be displayed according to the sorting result of the candidates in the candidate list. Specifically, the candidate list can be displayed in the order from largest to smallest according to the numerical value corresponding to the sorting parameter.

[0116] To enable those skilled in the art to better understand the embodiments of the present invention, here a specific example is used to illustrate the input method of the embodiments of the present invention. This example may specifically include the following steps:

[0117] Step S1: Determine the input string and its corresponding context.

[0118] The input string is "h", and there are two previous texts corresponding to the input string: "你有 (You have)" and "爱奇艺 (IQIYI)".

[0119] Step S2: Search in the thesaurus according to the input string to obtain the corresponding second candidates.

[0120] For example, according to "h", second candidates such as "会 (will)", "好 (good)", and "还 (also)" are obtained by searching in the thesaurus.

[0121] Step S3: Search in the multi - relationship data according to the above previous texts to obtain the corresponding hit elements.

[0122] By querying the multi - relationship data, the right elements corresponding to the two previous texts "你有 (You have)" and "爱奇艺 (IQIYI)" include: "会员0.76 (member 0.76)", "视频0.13 (video 0.13)", "吗0.09 (right particle 0.09)". In "会员0.76 (member 0.76)", the former represents the word entry and the latter represents the conditional probability.

[0123] Step S4: Match the above hit elements with the input string to obtain the target hit element "会员0.76 (member 0.76)".

[0124] Step S5: Determine the sorting parameter of the target hit element "会员0.76 (member 0.76)".

[0125] Through the conditional probability of 0.76, adding some penalties for long words, such as "联想字数1*惩罚值0.1 (penalty value 0.1 for the length of the associated word 1)", the corrected conditional probability of 0.76 - 1*0.1 = 0.66 is obtained as the sorting parameter.

[0126] Step S6: Determine the order of the candidate list, such as "会 (will)", "会员 (member)", "好 (good)", and "还 (also)", etc.

[0127] Step S7: Display the candidate list in the above order.

[0128] It should be noted that, for the method embodiments, for the sake of simplicity of description, they are all described as a series of motion combinations, but those skilled in the art should know that the embodiments of the present invention are not limited by the described sequence of actions, because according to the embodiments of the present invention, certain steps can be performed in other sequences or simultaneously. Secondly, those skilled in the art should also know that the embodiments described in the specification are all preferred embodiments, and the motions involved are not necessarily required by the embodiments of the present invention.

[0129] Device Embodiment

[0130] Reference Figure 5 , shows a structural block diagram of an input device embodiment of the present invention, which may specifically include:

[0131] A search module 501 is used to search in the multivariate relational data according to the context corresponding to the input string, so as to obtain a hit element corresponding to the context;

[0132] A target hit element determination module 502 is used to determine a target hit element corresponding to the input string from the hit elements; and

[0133] The first candidate determination module 503 is used to determine the first candidate corresponding to the input string according to the target hit element corresponding to the input string.

[0134] Optionally, the target hit element determination module 502 includes:

[0135] A first matching module is used to match the encoded character string corresponding to the hit element with the input string to obtain a target hit element corresponding to the input string; or

[0136] The second matching module is used to match the matching sequence corresponding to the hit element with the matching sequence corresponding to the input string to obtain the target hit element corresponding to the input string.

[0137] Optionally, the input string may be a portion of an encoded string corresponding to the target hit element.

[0138] Optionally, the input string may be a prefix of an encoded string corresponding to the target hit element.

[0139] Optionally, the conditional probability of the target hit element may exceed a probability threshold; the conditional probability is used to characterize the probability of occurrence of the target hit element under the condition of the context.

[0140] Optionally, the device may further include:

[0141] A sorting parameter determination module, used to determine the sorting parameter of the first candidate according to the conditional probability of the first candidate, the number of characters of the target hit element, and the number of characters of the entry corresponding to the input string in the vocabulary; the conditional probability is used to represent the probability of occurrence of the target hit element under the condition of the context;

[0142] A position determination module is used to determine the position of the first candidate in the candidate list according to the ranking parameter of the first candidate.

[0143] Optionally, the device may further include:

[0144] A display module is used to display a candidate list corresponding to the input string; the candidate list may include: the first candidate and a second candidate, and the second candidate may include: a candidate obtained according to a vocabulary.

[0145] As for the device embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the partial description of the method embodiment.

[0146] The various embodiments in this specification are described in a progressive manner, and each embodiment focuses on the differences from other embodiments. The same or similar parts between the various embodiments can be referenced to each other.

[0147] Regarding the device in the above embodiment, the specific manner in which each module performs operations has been described in detail in the embodiment of the method, and will not be elaborated here.

[0148] An embodiment of the present invention provides a device for input, including a memory and one or more programs, wherein the one or more programs are stored in the memory and are configured to be executed by one or more processors, wherein the one or more programs include instructions for performing the following operations: searching in multivariate relational data based on a context corresponding to an input string to obtain a hit element corresponding to the context; determining a target hit element corresponding to the input string from the hit elements; and determining a first candidate corresponding to the input string based on the target hit element corresponding to the input string.

[0149] Figure 6 8 is a block diagram of an input device 800 according to an exemplary embodiment. For example, the device 800 may be a mobile phone, a computer, a digital broadcast terminal, a messaging device, a game console, a tablet device, a medical device, a fitness device, a personal digital assistant, etc.

[0150] Reference Figure 6, the device 800 may include one or more of the following components: a processing component 802 , a memory 804 , a power component 806 , a multimedia component 808 , an audio component 810 , an input / output (I / O) interface 812 , a sensor component 814 , and a communication component 816 .

[0151] The processing component 802 generally controls the overall operation of the device 800, such as operations associated with display, phone calls, data communications, camera operations, and recording operations. The processing component 802 may include one or more processors 820 to execute instructions to complete all or part of the steps of the above-mentioned method. In addition, the processing component 802 may include one or more modules to facilitate the interaction between the processing component 802 and other components. For example, the processing component 802 may include a multimedia module to facilitate the interaction between the multimedia component 808 and the processing component 802.

[0152] The memory 804 is configured to store various types of data to support operations on the device 800. Examples of such data include instructions for any application or method operating on the device 800, contact data, phone book data, messages, pictures, videos, etc. The memory 804 can be implemented by any type of volatile or non-volatile storage device or a combination thereof, 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 disk or optical disk.

[0153] The power supply component 806 provides power to the various components of the device 800. The power supply component 806 may include a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power for the device 800.

[0154] The multimedia component 808 includes a screen that provides an output interface between the device 800 and the user. 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 the 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 boundaries 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 camera and / or a rear camera. When the device 800 is in an operating mode, such as a shooting mode or a video mode, the front camera and / or the rear camera may receive external multimedia data. Each front camera and rear camera may be a fixed optical lens system or have a focal length and optical zoom capability.

[0155] The audio component 810 is configured to output and / or input audio signals. For example, the audio component 810 includes a microphone (MIC), and when the device 800 is in an operating mode, such as a call mode, a recording mode, and a voice input mode, the microphone is configured to receive an external audio signal. The received audio signal can be further stored in the memory 804 or sent via the communication component 816. In some embodiments, the audio component 810 also includes a speaker for outputting audio signals.

[0156] I / O interface 812 provides an interface between processing component 802 and peripheral interface modules, such as keyboards, click wheels, buttons, etc. These buttons may include but are not limited to: home button, volume button, start button, and lock button.

[0157] The sensor assembly 814 includes one or more sensors for providing various aspects of status assessment for the device 800. For example, the sensor assembly 814 can detect the open / closed state of the device 800, the relative positioning of components, such as the display and keypad of the device 800, and the sensor assembly 814 can also detect the position change of the device 800 or a component of the device 800, the presence or absence of user contact with the device 800, the orientation or acceleration / deceleration of the device 800, and the temperature change of the device 800. The 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 an optical 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 accelerometer, a gyroscope sensor, a magnetic sensor, a pressure sensor, or a temperature sensor.

[0158] The communication component 816 is configured to facilitate wired or wireless communication between the device 800 and other devices. The device 800 can 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 communication component 816 also includes a near field communication (NFC) module to facilitate short-range communication. For example, the NFC module can be implemented based on radio frequency identification (RFID, Radio Frequency Identification) technology, infrared data association (IrDA) technology, ultra-wideband (UWB) technology, Bluetooth (BT) technology and other technologies.

[0159] 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, microcontrollers, microprocessors or other electronic components to perform the above method.

[0160] In an exemplary embodiment, a non-transitory computer-readable storage medium including instructions is also provided, such as a memory 804 including instructions, and the instructions can be executed by the processor 820 of the device 800 to perform the above method. For example, the non-transitory computer-readable storage medium can be a ROM, a random access memory (RAM), a CD-ROM, a magnetic tape, a floppy disk, an optical data storage device, etc.

[0161] Figure 7 1 is a schematic diagram of the structure of the server in some embodiments of the present invention. The server 1900 may have relatively large differences due to different configurations or performances, and may include one or more central processing units (CPU) 1922 (for example, one or more processors) and memory 1932, and one or more storage media 1930 (for example, one or more mass storage devices) storing application programs 1942 or data 1944. Among them, the memory 1932 and the storage medium 1930 can be short-term storage or permanent storage. The program stored in the storage medium 1930 may include one or more modules (not shown in the figure), and each module may include a series of instruction operations in the server. Furthermore, the central processing unit 1922 can be configured to communicate with the storage medium 1930 and execute a series of instruction operations in the storage medium 1930 on the server 1900.

[0162] 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 and output interfaces 1958, one or more keyboards 1956, and / or, one or more operating systems 1941, such as Windows ServerTM, Mac OS XTM, UnixTM, LinuxTM, FreeBSDTM, etc.

[0163] A non-transitory computer-readable storage medium, when the instructions in the storage medium are executed by a processor of a device (server or terminal), enables the device to perform Figure 2 or Figure 3 or Figure 4 Input method shown.

[0164] A non-temporary computer-readable storage medium, when the instructions in the storage medium are executed by the processor of a device (server or terminal), enables the device to execute an input method, the method comprising: searching in multivariate relational data based on the context corresponding to an input string to obtain a hit element corresponding to the context; determining a target hit element corresponding to the input string from the hit elements; and determining a first candidate corresponding to the input string based on the target hit element corresponding to the input string.

[0165] The embodiment of the present invention discloses A1, an input method, the method comprising:

[0166] Searching in the multivariate relational data according to the context corresponding to the input string to obtain a hit element corresponding to the context;

[0167] Determine a target hit element corresponding to the input string from the hit elements;

[0168] According to the target hit element corresponding to the input string, a first candidate corresponding to the input string is determined.

[0169] A2. The method according to A1, characterized in that determining the target hit element corresponding to the input string from the hit elements comprises:

[0170] Matching the encoded character string corresponding to the hit element with the input string to obtain a target hit element corresponding to the input string; or

[0171] The matching sequence corresponding to the hit element is matched with the matching sequence corresponding to the input string to obtain the target hit element corresponding to the input string.

[0172] A3. The method according to A1 is characterized in that the input string is a part of the encoded string corresponding to the target hit element.

[0173] A4. The method according to A1 is characterized in that the input string is a prefix of the encoded string corresponding to the target hit element.

[0174] A5. The method according to A1 is characterized in that the conditional probability of the target hit element exceeds a probability threshold; the conditional probability is used to characterize the probability of occurrence of the target hit element under the condition of the context.

[0175] A6. The method according to any one of A1 to A5, characterized in that the method further comprises:

[0176] Determine the ranking parameter of the first candidate according to the conditional probability of the first candidate, the number of characters of the target hit element, and the number of characters of the entry corresponding to the input string in the vocabulary; the conditional probability is used to characterize the probability of occurrence of the target hit element under the condition of the context;

[0177] A position of the first candidate in the candidate list is determined according to the ranking parameter of the first candidate.

[0178] A7. The method according to any one of A1 to A5, characterized in that the method further comprises:

[0179] A candidate list corresponding to the input string is displayed; the candidate list includes: the first candidate and the second candidate, and the second candidate includes: a candidate obtained according to a vocabulary.

[0180] The embodiment of the present invention discloses B8, an input device, characterized in that it includes:

[0181] A search module, used to search in the multivariate relational data according to the context corresponding to the input string, so as to obtain a hit element corresponding to the context;

[0182] a target hit element determination module, used to determine a target hit element corresponding to the input string from the hit elements; and

[0183] The first candidate determination module is used to determine the first candidate corresponding to the input string according to the target hit element corresponding to the input string.

[0184] B9. The device according to B8, characterized in that the target hit element determination module comprises:

[0185] A first matching module is used to match the encoded character string corresponding to the hit element with the input string to obtain a target hit element corresponding to the input string; or

[0186] The second matching module is used to match the matching sequence corresponding to the hit element with the matching sequence corresponding to the input string to obtain the target hit element corresponding to the input string.

[0187] B10. The device according to B8 is characterized in that the input string is a part of the encoded string corresponding to the target hit element.

[0188] B11. The device according to B8 is characterized in that the input string is a prefix of the encoded string corresponding to the target hit element.

[0189] B12. The device according to B8 is characterized in that the conditional probability of the target hit element exceeds a probability threshold; the conditional probability is used to characterize the probability of occurrence of the target hit element under the condition of the context.

[0190] B13. The device according to any one of B8 to B12, characterized in that the device further comprises:

[0191] A sorting parameter determination module, used to determine the sorting parameter of the first candidate according to the conditional probability of the first candidate, the number of characters of the target hit element, and the number of characters of the entry corresponding to the input string in the vocabulary; the conditional probability is used to represent the probability of occurrence of the target hit element under the condition of the context;

[0192] A position determination module is used to determine the position of the first candidate in the candidate list according to the ranking parameter of the first candidate.

[0193] B14. The device according to any one of B8 to B12, characterized in that the device further comprises:

[0194] A display module is used to display a candidate list corresponding to the input string; the candidate list includes: the first candidate and the second candidate, and the second candidate includes: a candidate obtained according to a vocabulary.

[0195] The embodiment of the present invention discloses C15, a device for input, characterized in that it includes a memory and one or more programs, wherein the one or more programs are stored in the memory and are configured to be executed by one or more processors. The one or more programs include instructions for performing the following operations:

[0196] Searching in the multivariate relational data according to the context corresponding to the input string to obtain a hit element corresponding to the context;

[0197] Determine a target hit element corresponding to the input string from the hit elements;

[0198] According to the target hit element corresponding to the input string, a first candidate corresponding to the input string is determined.

[0199] C16. The device according to C15, characterized in that the step of determining the target hit element corresponding to the input string from the hit elements comprises:

[0200] Matching the encoded character string corresponding to the hit element with the input string to obtain a target hit element corresponding to the input string; or

[0201] The matching sequence corresponding to the hit element is matched with the matching sequence corresponding to the input string to obtain the target hit element corresponding to the input string.

[0202] C17. The device according to C15 is characterized in that the input string is a part of the encoded string corresponding to the target hit element.

[0203] C18. The device according to C15 is characterized in that the input string is a prefix of the encoded string corresponding to the target hit element.

[0204] C19. The device according to C15 is characterized in that the conditional probability of the target hit element exceeds a probability threshold; the conditional probability is used to characterize the probability of occurrence of the target hit element under the condition of the context.

[0205] C20. The device according to any one of C15 to C19, wherein the device is further configured to execute, by one or more processors, the one or more programs including instructions for performing the following operations:

[0206] Determine the ranking parameter of the first candidate according to the conditional probability of the first candidate, the number of characters of the target hit element, and the number of characters of the entry corresponding to the input string in the vocabulary; the conditional probability is used to characterize the probability of occurrence of the target hit element under the condition of the context;

[0207] A position of the first candidate in the candidate list is determined according to the ranking parameter of the first candidate.

[0208] C21. The device according to any one of C15 to C19, wherein the device is further configured to execute, by one or more processors, the one or more programs including instructions for performing the following operations:

[0209] A candidate list corresponding to the input string is displayed; the candidate list includes: the first candidate and the second candidate, and the second candidate includes: a candidate obtained according to a vocabulary.

[0210] An embodiment of the present invention discloses D22, a machine-readable medium having instructions stored thereon, which, when executed by one or more processors, enables a device to execute an input method as described in one or more of A1 to A7.

[0211] Those skilled in the art will readily appreciate other embodiments of the invention after considering the specification and practicing the invention disclosed herein. The present invention is intended to cover any variations, uses or adaptations of the present invention that follow the general principles of the present invention and include common knowledge or customary techniques in the art that are not disclosed in this disclosure. The description and examples are to be considered exemplary only, and the true scope and spirit of the present invention are indicated by the following claims.

[0212] It should be understood that the present invention is not limited to the exact construction that has been 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 present invention is limited only by the appended claims.

[0213] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principle of the present invention should be included in the protection scope of the present invention.

[0214] The above is a detailed introduction to an input method, an input device and a device for input provided by the present invention. Specific examples are used in this article to illustrate the principles and implementation methods of the present invention. The description of the above embodiments is only used to help understand the method of the present invention and its core idea. At the same time, for those skilled in the art, according to the idea of ​​the present invention, there will be changes in the specific implementation method and application scope. In summary, the content of this specification should not be understood as a limitation on the present invention.

Claims

1. An input method, characterized in that: The method comprises: Searching in the multivariate relational data according to the context corresponding to the input string to obtain a hit element corresponding to the context; Determine a target hit element corresponding to the input string from the hit elements; Determine a first candidate corresponding to the input string according to the target hit element corresponding to the input string; Determine the ranking parameter of the first candidate according to the conditional probability of the first candidate, the number of characters of the target hit element, and the number of characters of the entry corresponding to the input string in the vocabulary; the conditional probability is used to characterize the probability of occurrence of the target hit element under the condition of the context; According to the sorting parameters of the first candidate, the position of the first candidate in the candidate list is determined, including: presetting a penalty value corresponding to the number of associated words, adjusting the conditional probability of the first candidate based on the penalty value, and determining the sorting parameters of the first candidate based on the adjusted conditional probability of the first candidate.

2. The method according to claim 1, characterized in that The step of determining a target hit element corresponding to the input string from the hit elements includes: Matching the encoded character string corresponding to the hit element with the input string to obtain a target hit element corresponding to the input string; or The matching sequence corresponding to the hit element is matched with the matching sequence corresponding to the input string to obtain the target hit element corresponding to the input string.

3. The method according to claim 1, characterized in that The input string is the portion of the encoded string corresponding to the target hit element.

4. The method according to claim 1, characterized in that: The input string is a prefix of the encoding string corresponding to the target hit element.

5. The method according to claim 1, characterized in that The conditional probability of the target hit element exceeds the probability threshold; the conditional probability is used to characterize the probability of occurrence of the target hit element under the condition of the context.

6. The method according to any one of claims 1 to 5, characterized in that: The method further comprises: A candidate list corresponding to the input string is displayed; the candidate list includes: the first candidate and the second candidate, and the second candidate includes: a candidate obtained according to a vocabulary.

7. An input device, characterized in that: include: A search module, used to search in the multivariate relational data according to the context corresponding to the input string, so as to obtain a hit element corresponding to the context; A target hit element determination module, used to determine a target hit element corresponding to the input string from the hit elements; as well as A first candidate determination module, used to determine a first candidate corresponding to the input string according to a target hit element corresponding to the input string; A sorting parameter determination module, used to determine the sorting parameter of the first candidate according to the conditional probability of the first candidate, the number of characters of the target hit element, and the number of characters of the entry corresponding to the input string in the vocabulary; The conditional probability is used to characterize the probability of occurrence of the target hit element under the condition of the context; A position determination module is used to determine the position of the first candidate in the candidate list according to the sorting parameters of the first candidate, including: presetting a penalty value corresponding to the number of associated words, adjusting the conditional probability of the first candidate based on the penalty value, and determining the sorting parameters of the first candidate based on the adjusted conditional probability of the first candidate.

8. The device according to claim 7, characterized in that The target hit element determination module comprises: A first matching module is used to match the encoded character string corresponding to the hit element with the input string to obtain a target hit element corresponding to the input string; or The second matching module is used to match the matching sequence corresponding to the hit element with the matching sequence corresponding to the input string to obtain the target hit element corresponding to the input string.

9. The device according to claim 7, characterized in that The input string is the portion of the encoded string corresponding to the target hit element.

10. The device according to claim 7, characterized in that The input string is a prefix of the encoding string corresponding to the target hit element.

11. The device according to claim 7, characterized in that The conditional probability of the target hit element exceeds the probability threshold; the conditional probability is used to characterize the probability of occurrence of the target hit element under the condition of the context.

12. The device according to any one of claims 7 to 11, characterized in that The device also includes: A display module is used to display a candidate list corresponding to the input string; the candidate list includes: the first candidate and the second candidate, and the second candidate includes: a candidate obtained according to a vocabulary.

13. A device for input, characterized in that The system comprises a memory and one or more programs, wherein the one or more programs are stored in the memory and are configured to be executed by one or more processors, and the one or more programs include instructions for performing the following operations: Searching in the multivariate relational data according to the context corresponding to the input string to obtain a hit element corresponding to the context; Determine a target hit element corresponding to the input string from the hit elements; Determine a first candidate corresponding to the input string according to the target hit element corresponding to the input string; Determining a ranking parameter of the first candidate according to the conditional probability of the first candidate, the number of characters of the target hit element, and the number of characters of the entry corresponding to the input string in the vocabulary; The conditional probability is used to characterize the probability of occurrence of the target hit element under the condition of the context; According to the sorting parameters of the first candidate, the position of the first candidate in the candidate list is determined, including: presetting a penalty value corresponding to the number of associated words, adjusting the conditional probability of the first candidate based on the penalty value, and determining the sorting parameters of the first candidate based on the adjusted conditional probability of the first candidate.

14. The device according to claim 13, characterized in that The step of determining a target hit element corresponding to the input string from the hit elements includes: Matching the encoded character string corresponding to the hit element with the input string to obtain a target hit element corresponding to the input string; or The matching sequence corresponding to the hit element is matched with the matching sequence corresponding to the input string to obtain the target hit element corresponding to the input string.

15. The device according to claim 13, characterized in that The input string is the portion of the encoded string corresponding to the target hit element.

16. The device according to claim 13, characterized in that The input string is a prefix of the encoding string corresponding to the target hit element.

17. The device according to claim 13, characterized in that The conditional probability of the target hit element exceeds the probability threshold; the conditional probability is used to characterize the probability of occurrence of the target hit element under the condition of the context.

18. The device according to any one of claims 13 to 17, characterized in that The device is also configured to execute, by one or more processors, the one or more programs including instructions for performing the following operations: displaying a candidate list corresponding to the input string; The candidate list includes: the first candidate and the second candidate, and the second candidate includes: candidates obtained according to the vocabulary.

19. A machine-readable medium having instructions stored thereon, which, when executed by one or more processors, causes a device to perform the input method according to any one of claims 1 to 6.