CN107247519B - Input method and device - Google Patents

Input method and device Download PDF

Info

Publication number
CN107247519B
CN107247519B CN201710702660.8A CN201710702660A CN107247519B CN 107247519 B CN107247519 B CN 107247519B CN 201710702660 A CN201710702660 A CN 201710702660A CN 107247519 B CN107247519 B CN 107247519B
Authority
CN
China
Prior art keywords
candidate
input
word
character string
words
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201710702660.8A
Other languages
Chinese (zh)
Other versions
CN107247519A (en
Inventor
涂畅
张扬
王砚峰
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Sogou Technology Development Co Ltd
Original Assignee
Beijing Sogou Technology Development Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Sogou Technology Development Co Ltd filed Critical Beijing Sogou Technology Development Co Ltd
Priority to CN201710702660.8A priority Critical patent/CN107247519B/en
Publication of CN107247519A publication Critical patent/CN107247519A/en
Application granted granted Critical
Publication of CN107247519B publication Critical patent/CN107247519B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

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/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)
  • Document Processing Apparatus (AREA)

Abstract

The embodiment of the invention provides an input method and a device, wherein the method comprises the following steps: receiving a first code character string input by a user, wherein the first code character string comprises at least two code character units; when the first coded character string contains preset characters, determining a candidate coded character string matched with the first coded character string; wherein the preset characters are used for replacing one or more coding character units; and determining candidate input words corresponding to the candidate code character strings according to the candidate code character strings. The embodiment of the invention can ensure that when a user inputs a Chinese character with unknown pronunciation, the user replaces the coded character string of the Chinese character by the preset character and determines the corresponding candidate input word, so that the user can simply, conveniently and quickly input the Chinese character, the user operation is reduced, and the input efficiency is improved.

Description

Input method and device
Technical Field
The embodiment of the invention relates to the technical field of computers, in particular to an input method and device.
Background
In the existing input method technology, a user can input a coded character string, and candidate items corresponding to the coded character string are displayed by an input method application. After the user selects the required candidate item, the input method applies the candidate item which can be selected on the screen. The user can input pinyin to input corresponding Chinese characters, but if the user does not know the pronunciation of a certain character or characters in the words to be input, it is very difficult to input the words correctly. For example, if a user wants to input the idiom "chi mei \3957; \39535" without knowing the pronunciation of the "chi" word, correct input cannot be achieved using the pinyin input method. The user can only switch the input method from pinyin input to other types of input methods, such as a wubi input method or a stroke input method. For users who are not familiar with other types of input methods, the input can be completed correctly only by learning a new type of input method, which causes the problems of high learning cost, complex operation, low input efficiency and the like.
Disclosure of Invention
The embodiment of the invention provides an input method and device, and aims to solve the problems that an input method provided by the prior art cannot conveniently, quickly and accurately realize input under the condition that a user does not know the pronunciation of a Chinese character, and the input efficiency is low.
Therefore, the embodiment of the invention provides the following technical scheme:
in a first aspect, an embodiment of the present invention provides an input method, including: receiving a first code character string input by a user, wherein the first code character string comprises at least two code character units; when the first coded character string contains preset characters, determining a candidate coded character string matched with the first coded character string; wherein the preset characters are used for replacing one or more coding character units; and determining candidate input words corresponding to the candidate code character strings according to the candidate code character strings.
In a second aspect, an embodiment of the present invention provides an input device, including: the device comprises a receiving unit, a processing unit and a display unit, wherein the receiving unit is used for receiving a first code character string input by a user, and the first code character string comprises at least two code character units; the matching unit is used for determining a candidate code character string matched with the first code character string when the first code character string contains preset characters; wherein the preset characters are used for replacing one or more coding character units; and the determining unit is used for determining candidate input words corresponding to the candidate code character strings according to the candidate code character strings.
In a third aspect, 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 configured to be executed by the one or more processors comprises instructions for: receiving a first code character string input by a user, wherein the first code character string comprises at least two code character units; when the first coded character string contains preset characters, determining a candidate coded character string matched with the first coded character string; wherein the preset characters are used for replacing one or more coding character units; and determining candidate input words corresponding to the candidate code character strings according to the candidate code character strings.
In a fourth aspect, an embodiment of the present invention provides a machine-readable medium on which instructions are stored, which when executed by one or more processors, cause an apparatus to perform the input method as shown in the first aspect.
According to the input method and the input device provided by the embodiment of the invention, when a user inputs a Chinese character with unknown pronunciation, the user is allowed to use the preset character to replace the coded character string of the Chinese character, when the coded character string input by the user is judged to contain the preset character, the candidate coded character string matched with the coded character string is determined, and then the candidate input word is determined according to the candidate coded character string for the user to select to screen. Therefore, when the pronunciation of the Chinese character is unknown, the user can still simply, conveniently and quickly input the Chinese character, the user operation is reduced, and the input efficiency is improved.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only some embodiments described in the present invention, and for those skilled in the art, other drawings can be obtained according to the drawings without creative efforts.
FIG. 1 is a flow chart of an input method according to an embodiment of the present invention;
FIG. 2 is a flow chart of an input method according to another embodiment of the present invention;
FIG. 3 is a schematic diagram of an input device according to an embodiment of the present invention;
FIG. 4 is a block diagram illustrating an input device according to an exemplary embodiment.
Detailed Description
The embodiment of the invention provides an input method and device, which can replace the coding character string of a Chinese character by a preset character and determine a corresponding candidate input word when a user inputs the Chinese character with unknown pronunciation, so that the user can simply, conveniently and quickly input the Chinese character, the user operation is reduced, and the input efficiency is improved.
In order to make those skilled in the art better understand the technical solution of the present invention, the technical solution in the embodiment of the present invention will be clearly and completely described below with reference to the drawings in the embodiment of the present invention, and it is obvious that the described embodiment is only a part of the embodiment of the present invention, and not all embodiments. 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.
It should be noted that, in the embodiment of the present invention, chinese is taken as an example for description.
The technical term "user input" may include, among other things, a code string that is manually entered by a user, or may include voice input.
The technical term "code string editing area" generally refers to an area for displaying a code string input by a user.
The technical term "character on-screen area" generally refers to an area for outputting a candidate item selected by a user on a screen, such as an input box.
The technical term "candidate area" generally refers to an area for presenting candidates, which may include candidate input words and candidate input words.
An input method according to an exemplary embodiment of the present invention will be described with reference to fig. 1 to 2.
Referring to fig. 1, a flowchart of an input method according to an embodiment of the present invention is provided. As shown in fig. 1, may include:
s101, receiving a first code character string input by a user.
In a specific implementation, the first encoded string includes, but is not limited to, a pinyin string, a word string, a five-stroke font encoded string, and the like. Wherein the first encoding character string comprises at least two encoding character units. Taking the input of Chinese characters as an example, a code character unit generally corresponds to a Pinyin code character string, and a Pinyin code character unit may include one or more code characters. For example, the input word "chimeiwanglang", the first code string "chimeiwanglang" includes 4 code character units, respectively "chi", "mei", "wang", "liang".
When the user does not know the pronunciation of one or more Chinese characters in a certain word, the preset characters can be used for replacing the code character string of the Chinese character. For example, the user may input the first code string ". chi \3957; \3953," meiwangliang ", without knowing the pronunciation of the first word. The first encoded string includes a predetermined character "", which may be used to replace one or more encoded character units, and also includes 3 encoded character units "mei", "wang", "liang". It should be noted that the preset character may also be other characters, such as "#"? "etc., as long as they can be distinguished from the characters of the code string normally input by the user.
For example, the user wants to input "chi mei \3957; \3953", he may input ". about. wangliang" when the reading of the first two words is unknown, at which time one preset character ". about. corresponds to one coded character unit. Of course, the user may also input ". wanglang" in which case the preset character ". may replace two code character units. If the user wants to input a word containing N Chinese characters, the user can input 1 or M preset characters to replace M Chinese characters, wherein M is smaller than N. Specifically, M is equal to or less than (N-1).
In other application scenarios, if a user uses a five-stroke character shape input method and does not know the character shape of a certain Chinese character or the input of the certain Chinese character is too complicated, the preset character can be used for replacing the character shape coding string of the Chinese character; if the user uses voice input, a preset pronunciation or a pronunciation corresponding to a symbol can be used to replace the input of a certain voice.
In addition, the invention can also provide a personalized input mode for the user, and is not limited to the scene that the user does not know the pronunciation or the font of uncommon words. For example, when considering the used words, the user can provide possible candidates for the user to refer to by inputting a coded character string containing preset characters. For example, the user enters ". about.solid", words such as "tangible", "tamped", "true", etc. may appear for the user to select.
S102, when the first code character string is judged to contain preset characters, determining candidate code character strings matched with the first code character string.
When the first code character string is judged to contain the preset character, the special processing aiming at the first code character string is triggered. Specifically, the candidate encoding character string matching the first encoding character string may be determined by searching for a match in a system lexicon or a user lexicon. The candidate code character string and the candidate input word have a corresponding relation.
In some embodiments, a candidate input word library may be established in advance, and the candidate input word library may store correspondence between candidate input words and candidate encoding character strings, where the correspondence may be one-to-one or one-to-many. For example, the words "chi mei \3957; \3953", their corresponding encoding strings include, but are not limited to, "chimeiwangliang" and "cmwl". By pre-establishing a candidate input word bank and storing the corresponding relation between the words added into the candidate input word bank and the code character strings corresponding to the words, when the candidate code character strings matched with the first code character strings are searched, the candidate code character strings matched with the first code characters can be searched in the established candidate input word bank. The processing can improve the speed of determining the first coding character string, reduce the searching range and reduce the complexity of data processing.
When constructing the candidate input word library, one or more of the following ways may be included:
(1) determining a target word; adding a first target word containing the target word into a candidate input word bank, and storing the corresponding relation between the first target word and a coding character string corresponding to the first target word; and/or the presence of a gas in the gas,
(2) determining a second target word; adding the second target word into a candidate input word library, and storing the corresponding relation between the second target word and the coding character string corresponding to the second target word; and/or the presence of a gas in the gas,
(3) acquiring historical input data of a user; and adding the on-screen input words corresponding to the code character strings containing the preset characters into a candidate input word library in the historical input data, and storing the corresponding relation between the on-screen input words and the code character strings corresponding to the on-screen input words.
The following description will be made separately. In the first implementation, the target word may be a word including uncommon words, difficult-to-pronounce words, cumbersome-to-input words, confusing pronunciations, and the like. In determining the uncommon word, the word with the user input frequency lower than a first set threshold or the total number of strokes greater than a second set threshold may be determined as the uncommon word. For example, for the Chinese character "ramming", many users do not know the correct pronunciation, the input frequency is low, the user can consider the word as a rare word, the words containing the "ramming" word can include "ramming", and the like, and then the words containing the rare word can be added into the candidate input word library. In addition, the method can also be used for counting characters with difficult pronunciation, characters with easy confusion pronunciation, input complicated characters and the like based on the user history input, sample labeling and other modes, taking the characters of the types as target characters, and adding the words comprising the target characters into a candidate input word bank.
In a second implementation, the second target word may be, for example, a rare word, and the recognition of the rare word or the rare word by different users is different, so the second target word may be determined in the following manner. For example, the second target word may be a word whose word input frequency is less than a third set threshold. Generally, the input frequency of a common word, namely a word, is high, and the pronunciation of the word is usually simple and well known to a user. And some words with lower input frequency are also uncommon words, and the pronunciation of the words is not well known by the user, so that whether the words are the second target words or not can be determined through the word input frequency. In addition, the second target word may also be a word composed of a word with a complex font style, such as a word with a large stroke number. In particular, the word with the total number of strokes greater than the fourth set threshold may be determined as a rare word. For example, the idiom "chi \3957; \39535358" has a larger total number of strokes, reflecting that the font structure is more complicated and the pronunciation is not easily known by the user, and thus can be added to the candidate input lexicon, compared with the idiom "one thousand miles per day".
In a third implementation manner, historical input data of a user may be acquired, and in the historical input data, an on-screen input word corresponding to a code character string including the preset character is added to a candidate input word library. It should be noted that the words added into the candidate input lexicon may not be limited to the words with low input frequency or with more total strokes, but may also be common words or words in all system lexicons or all user lexicons, so as to facilitate the personalized input of the user. For example, if the user wants to input "cheerful", the pinyin strings "ruhuoru", ". about. huo. tu", etc. may be input, and if the user selects the on-screen input candidate "cheerful", then "cheerful" may be added to the candidate input lexicon. For example, for the idiom "gulucohengyan", the user often does not know the pronunciations of the first two characters, and when the user inputs the encoded character string "or" what feast "by voice input, and finally inputs the word" gulucohengyan "on the screen, the word" gulhengyan "on the screen may be added to the candidate input thesaurus, and the correspondence between" gulhengyan "and the encoded character string" taotoshengyan "or" what feast "by voice recognition may be stored. Of course, if the code string input by the user is "#sy" and finally the word "gulosity feast" is input on the screen, the correspondence relationship between "gulosity feast" and the code string "taotiesy" or "ttsy" may be stored. It should be noted that the user history input data may be data of one user, data of a large-data-based, network-wide user, or data collected based on a specific group of people. The data collected based on a specific population may be collected for people with different dimensions, such as a specific occupation, a specific gender, and a specific age group. For example, the input method may obtain the gender, age, occupation, preference, etc. of the current user, and accordingly obtain the data of the corresponding population.
Several ways of constructing the candidate input lexicon are introduced above, and it should be noted that the above embodiments can be applied alone or in combination. For example, the library of candidate input words may be established by determining a first target word, a second target word, and determining candidate input words from the user historical input data. Of course, the above is only an exemplary description, and is not to be considered as a limitation of the present invention, and the candidate input word library may be constructed in other manners. The specific implementation is very flexible and is not limited herein.
When the first code character string input by the user is judged to contain the preset characters, the first code character string can be matched with the candidate code character string, and the matched candidate code character string is determined. When matching, methods such as regular matching and fuzzy matching can be adopted. For example, if the user inputs the first code string as ". times.. meiwanglang", it can be matched with the candidate code string "chimeiwanglang". For another example, if the user inputs the first code string as ". times.zhinian", it may be matched with the code string "maodiezhinian". In some embodiments, a user-entered encoding string may be matched against a plurality of candidate encoding strings. It should be noted that the candidate code strings generally include no less characters than the number of character strings included in the first code string.
S103, determining candidate input words corresponding to the candidate code character strings according to the candidate code character strings.
After the candidate code character string is determined, the candidate input word matched with the candidate code character string can be determined according to the corresponding relation between the candidate code character string and the candidate input word. If the candidate input word library is established, the candidate input words can be determined according to the corresponding relation between the candidate encoding character strings and the candidate input words stored in the word library. After determining the candidate input words corresponding to the candidate encoding character strings, if the candidate input words are multiple, the candidate input words may be further subjected to sorting processing, and the sorted candidate input words are displayed.
In some embodiments, word input frequencies of the candidate input words may be obtained, and the candidate input words may be sorted in ascending order according to the word input frequencies. For example, assuming that for the coding character string "cand" input by the user, the finally determined candidate input words include "pale vault", "shikimic" and "pale", and the word input frequencies are determined from high to low as "pale", "shikimic" and "pale vault", respectively, when the candidate input words are displayed in a sorted manner, the candidate input words may be sorted in an ascending order according to the input frequency, that is, "pale vault" is arranged in front of "pale vault" and "pale vault", because the words with lower word input frequencies have a greater probability of being rare words than the words with higher word input frequencies, and the user is more likely not to know the pronunciation thereof.
In some embodiments, the ranking the candidate input words comprises: and acquiring the total stroke number of the candidate input words, and arranging the candidate input words in a descending order according to the total stroke number of the candidate input words. Generally, the total number of strokes of a word is large, which reflects that the glyph structure is complex, and the pronunciation is not easy to be known by the user, so that the word can be arranged in the front of the candidate input word.
In some further embodiments, the ranking the candidate input words comprises: the candidate input words are ranked based on a user's previous input prior to the input of the first encoded string. The above input may include one or more words or one or more sentences. For example, the candidate input words may be ordered based on the on-screen input word preceding the user input encoding string. It should be noted that the binary relation between words may be saved in the application of the input method, and is used to describe the adhesion degree or tightness degree between words. For example, there is a binary relationship between the words "go" and "eat", indicating that if the user enters "go", it is likely that "eat" will be entered next. Thus, the candidate "eat" with a binary relationship to "go" may be ranked based on the user's previous on-screen input "go". Based on a similar principle, candidate input words having an association or correspondence with the on-screen text input may be ranked in the top based on the previous on-screen text input by the user.
In the sorting, the sorting methods described above may be applied alone or in combination. For example, different weights may be set for different sorting modes, and the final sorting result is obtained by weighting. For example, the sum value between the product of the word input frequency score of the candidate input word multiplied by the first weight and the product of the stroke total score of the candidate input word multiplied by the second weight may be obtained, and the sorting may be performed in a descending order according to the magnitude of the sum value. The word input frequency score and the word input frequency are in an inverse proportional relation, and the higher the word input frequency is, the lower the score is; the total number of strokes score is proportional to the total number of strokes, with the more total number of strokes, the higher the score. In sorting, the higher the sum, the higher the rank. The values of the first weight and the second weight may be set empirically.
By way of further example, the rank score of a candidate input word may be obtained by:
candidate input word ═ X1Word input frequency score + X of candidate input word2Total number of strokes score + X of candidate input word3The candidates are based on the language model scores of the above content. Wherein, X1、X2、X3Respectively, the weighted values are [ 0,1 ] and X1+X2+X31. The specific value can be set as required.
In some embodiments, the candidate input words may also be displayed in an input method application. Further, according to the position or the sequence of the preset character in the first coded character string, determining a candidate input word corresponding to the preset character in the candidate input words; and acquiring the description information of the candidate input words and displaying the description information of the candidate input words. The description information includes, but is not limited to, the pronunciation, font code, paraphrase, etc. of the candidate input word. In displaying the description information, the description information may be displayed simultaneously with displaying the candidate input word. The description information may be displayed in response to a trigger operation by a user. For example, when the user inputs the first code string ". times. meiwanglang", the candidate input word may be displayed as "chi's charm 3957; \3953" for the user to know his pronunciation. For another example, when the user does not know the five-stroke character shape input code of a certain character, the character shape code may be displayed after the candidate input word is displayed. Alternatively, the glyph encoding information may be displayed in response to a user's trigger operation. For another example, meanings, explanations and the like of certain words can be given, so that the user can conveniently obtain corresponding information.
In other embodiments, the method further comprises: receiving selection operation of a user for the candidate input words, and displaying the candidate input words corresponding to the selection operation on a screen; adding the candidate input words on the screen into the candidate input word library, and storing the corresponding relation between the candidate input words on the screen and the coded character strings corresponding to the candidate input words on the screen. In specific implementation, the number of times of inputting the candidate input word in a mode of replacing a code character with a preset character can be counted based on big data, such as the whole-network user data, and when the number of times is larger than a set threshold value, the candidate input word is added into a candidate input word bank. Of course, the candidate input word library may also be constructed based on input data of a certain user or a certain type of user. The data collected based on the specific category of users may be collected for people with different dimensions, such as a specific occupation, a specific gender, and a specific age group. For example, the input method may obtain the gender, age, occupation, preference, etc. of the current user, and accordingly obtain the data of the corresponding population.
In the embodiment of the invention, when a user inputs a Chinese character with unknown pronunciation, the user is allowed to use the preset character to replace the coded character string of the Chinese character, when the coded character input by the user is judged to contain the preset character, the candidate coded character string matched with the coded character string is determined, and then the candidate input word is determined according to the candidate coded character string for the user to select and screen. Therefore, when the pronunciation of the Chinese character is unknown, the user can still simply, conveniently and quickly input the Chinese character, the user operation is reduced, and the input efficiency is improved.
In order to facilitate those skilled in the art to more clearly understand the embodiments of the present application in a specific context, the following describes the embodiments of the present application with a specific example. It should be noted that the specific example is only to make the present invention more clearly understood by those skilled in the art, but the embodiments of the present invention are not limited to the specific example.
Referring to fig. 2, a flowchart of an input method according to another embodiment of the present invention is provided. The method may include:
s201, constructing a candidate input word bank, and storing the corresponding relation between the words in the candidate input word bank and the coding character strings corresponding to the words.
Referring to the implementation of S102 in the embodiment shown in fig. 1, the following implementation manners may be provided for constructing the candidate input word library:
(1) determining a target word; adding a first target word containing the target word into a candidate input word bank, and storing the corresponding relation between the first target word and a coding character string corresponding to the first target word; and/or the presence of a gas in the gas,
(2) determining a second target word; adding the second target word into a candidate input word library, and storing the corresponding relation between the second target word and the coding character string corresponding to the second target word; and/or the presence of a gas in the gas,
(3) acquiring historical input data of a user; and adding the on-screen input words corresponding to the code character strings containing the preset characters into a candidate input word library in the historical input data, and storing the corresponding relation between the on-screen input words and the code character strings corresponding to the on-screen input words.
Specific implementation can be realized by referring to the description of the embodiment shown in fig. 1, and is not described herein again. It should be noted that, the above-mentioned several implementations can be applied individually or in combination.
S202, receiving a first code character string input by a user.
S203, judging whether the first code character string contains preset characters.
S204, if the first code character string is judged to contain the preset characters, determining candidate code character strings matched with the first code character string.
S205, determining candidate input words corresponding to the candidate code character strings according to the candidate code character strings.
And S206, sequencing the candidate input words and displaying the sequenced candidate input words.
S207, determining candidate input words corresponding to the preset characters in the candidate input words, and obtaining pinyin pronunciation of the candidate input words.
And S208, displaying the pinyin pronunciation of the candidate input character.
S209, receiving the selection operation of the user aiming at the candidate input word, and displaying the candidate input word corresponding to the selection operation on a screen.
S210, adding the candidate input words on the screen into the candidate input word library, and storing the corresponding relation between the candidate input words on the screen and the candidate code character strings corresponding to the candidate input words on the screen.
Referring to fig. 3, a schematic diagram of an input device according to an embodiment of the invention is shown.
An input device 300 comprising:
the receiving unit 301 is configured to receive a first encoded character string input by a user, where the first encoded character string includes at least two encoded character units.
A matching unit 302, configured to determine a candidate encoded character string that matches the first encoded character string when the first encoded character string includes a preset character; wherein the preset characters are used to replace one or more code character units.
A determining unit 303, configured to determine, according to the candidate encoding character string, a candidate input word corresponding to the candidate encoding character string.
In some embodiments, the apparatus further comprises:
and the word stock construction unit is used for constructing a candidate input word stock.
The matching unit is specifically configured to: and searching a candidate code character string matched with the first code character in the candidate input word bank.
In some embodiments, the word stock construction unit specifically includes:
a first construction unit for determining a target word; adding a first target word containing the target word into a candidate input word bank, and storing the corresponding relation between the first target word and a coding character string corresponding to the first target word; and/or the presence of a gas in the gas,
the second construction unit is used for determining a second target word; adding the second target word into a candidate input word library, and storing the corresponding relation between the second target word and the coding character string corresponding to the second target word; and/or the presence of a gas in the gas,
the third construction unit is used for acquiring historical input data of a user; and adding the on-screen input words corresponding to the code character strings containing the preset characters into a candidate input word library in the historical input data, and storing the corresponding relation between the on-screen input words and the code character strings corresponding to the on-screen input words.
In some embodiments, the apparatus further comprises:
and the sorting unit is used for sorting the candidate input words after the candidate input words corresponding to the candidate coding character strings are determined, and displaying the sorted candidate input words.
In some embodiments, the sorting unit may specifically include:
the first ordering unit is used for acquiring word input frequency of the candidate input words and ordering the candidate input words in an ascending manner according to the word input frequency; and/or the presence of a gas in the gas,
the second sorting unit is used for acquiring the total number of strokes of the candidate input words and sorting the candidate input words in a descending order according to the total number of strokes of the candidate input words; and/or the presence of a gas in the gas,
and the third sorting unit is used for sorting the candidate input words based on the previous input of the user before the first code character string is input.
In some embodiments, the apparatus further comprises:
the obtaining unit is used for determining candidate input words corresponding to the preset characters in the candidate input words and obtaining description information of the candidate input words;
and the display unit is used for displaying the description information of the candidate input words.
The input device provided by the embodiment of the present invention is specifically configured to execute the method provided by the embodiment shown in fig. 1 and fig. 2, and the implementation principle, the method, the functional purpose, and the like of the input device are similar to those of the embodiment shown in fig. 1 and fig. 2, and are not described herein again. Referring to FIG. 4, a block diagram for an input device is shown, according to an exemplary embodiment. Referring to FIG. 4, a block diagram for an input device is shown, according to an exemplary embodiment. For example, the apparatus 400 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. 4, the apparatus 400 may include one or more of the following components: processing components 402, memory 404, power components 406, multimedia components 408, audio components 410, input/output (I/O) interfaces 412, sensor components 414, and communication components 416.
The processing component 402 generally controls overall operation of the apparatus 400, such as operations associated with display, telephone calls, data communications, camera operations, and recording operations. The processing component 402 may include one or more processors 420 to execute instructions to perform all or a portion of the steps of the methods described above. Further, the processing component 402 can include one or more modules that facilitate interaction between the processing component 402 and other components. For example, the processing component 402 can include a multimedia module to facilitate interaction between the multimedia component 408 and the processing component 402.
The memory 404 is configured to store various types of data to support operations at the device 400. Examples of such data include instructions for any application or method operating on the device 400, contact data, phonebook data, messages, pictures, videos, and so forth. The memory 404 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 supply components 406 provide power to the various components of device 400. The power components 406 may include a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power for the apparatus 400.
The multimedia component 408 includes a screen that provides an output interface between the device 400 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 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 a touch or slide action, but also detect the duration and pressure associated with the touch or slide operation. In some embodiments, the multimedia component 408 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 400 is in an operational mode, such as a shooting mode or a video mode. Each front camera and rear camera may be a fixed optical lens system or have a focal length and optical zoom capability.
The audio component 410 is configured to output and/or input audio signals. For example, audio component 410 includes a Microphone (MIC) configured to receive external audio signals when apparatus 400 is in an operational mode, such as a call mode, a recording mode, and a voice recognition mode. The received audio signals may further be stored in the memory 404 or transmitted via the communication component 416. In some embodiments, audio component 410 also includes a speaker for outputting audio signals.
The I/O interface 412 provides an interface between the processing component 402 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 component 414 includes one or more sensors for providing various aspects of status assessment for the apparatus 400. For example, the sensor component 414 can detect the open/closed state of the device 400, the relative positioning of components, such as a display and keypad of the apparatus 400, the sensor component 414 can also detect a change in the position of the apparatus 400 or a component of the apparatus 400, the presence or absence of user contact with the apparatus 400, orientation or acceleration/deceleration of the apparatus 400, and a change in the temperature of the apparatus 400. The sensor assembly 414 may include a proximity sensor configured to detect the presence of a nearby object without any physical contact. The sensor assembly 414 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 414 may also include an acceleration sensor, a gyroscope sensor, a magnetic sensor, a pressure sensor, or a temperature sensor.
The communication component 416 is configured to facilitate wired or wireless communication between the apparatus 400 and other devices. The apparatus 400 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 414 receives a broadcast signal or broadcast associated information from an external broadcast management system via a broadcast channel. In an exemplary embodiment, the communication component 414 further includes a Near Field Communication (NFC) module to facilitate short-range communications. For example, the NFC module may be implemented based on Radio Frequency Identification (RFID) technology, infrared data association (IrDA) technology, Ultra Wideband (UWB) technology, Bluetooth (BT) technology, and other technologies.
In an exemplary embodiment, the apparatus 400 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.
Specifically, the embodiment of the present application provides an input device 400, which includes a memory 404, and one or more programs, wherein the one or more programs are stored in the memory 404, and configured to be executed by the one or more processors 420, and the one or more programs include instructions for: receiving a first code character string input by a user, wherein the first code character string comprises at least two code character units; when the first coded character string contains preset characters, determining a candidate coded character string matched with the first coded character string; wherein the preset characters are used for replacing one or more coding character units; and determining candidate input words corresponding to the candidate code character strings according to the candidate code character strings.
Further, the processor 420 is specifically configured to execute the one or more programs including instructions for: constructing a candidate input word library;
the operation performed by the processor 420 to determine the candidate code character string matching the first code character specifically includes: and searching a candidate code character string matched with the first code character in the candidate input word bank.
Further, the operation of the processor 420 for constructing the candidate input word library specifically includes: determining a target word; adding a first target word containing the target word into a candidate input word bank, and storing the corresponding relation between the first target word and a coding character string corresponding to the first target word; and/or, determining a second target word; adding the second target word into a candidate input word library, and storing the corresponding relation between the second target word and the coding character string corresponding to the second target word; and/or acquiring historical input data of a user; adding the on-screen input words corresponding to the code character strings containing the preset characters into a candidate input word library in the historical input data, and storing the corresponding relation between the on-screen input words and the code character strings corresponding to the on-screen input words
Further, the processor 420 is specifically configured to execute the one or more programs including instructions for: after the candidate input words corresponding to the candidate coding character strings are determined, the candidate input words are ranked, and the ranked candidate input words are displayed.
Further, the operation of the processor 420 performing the sorting process on the candidate input words specifically includes:
acquiring word input frequency of the candidate input words, and arranging the candidate input words in an ascending order according to the word input frequency; and/or the presence of a gas in the gas,
acquiring the total number of strokes of the candidate input words, and arranging the candidate input words in a descending order according to the total number of strokes of the candidate input words; and/or the presence of a gas in the gas,
the candidate input words are ranked based on a user's previous input prior to the input of the first encoded string.
Further, the processor 420 is specifically configured to execute the one or more programs including instructions for: determining candidate input words corresponding to the preset characters in the candidate input words, and acquiring description information of the candidate input words; and displaying the description information of the candidate input word.
In an exemplary embodiment, a non-transitory computer-readable storage medium comprising instructions, such as the memory 404 comprising instructions, executable by the processor 420 of the apparatus 400 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.
A machine-readable medium, which may be, for example, a non-transitory computer-readable storage medium, in which instructions, when executed by a processor of an apparatus (terminal or server), enable the apparatus to perform an input method, the method comprising: receiving a first code character string input by a user, wherein the first code character string comprises at least two code character units; when the first coded character string contains preset characters, determining a candidate coded character string matched with the first coded character string; wherein the preset characters are used for replacing one or more coding character units; and determining candidate input words corresponding to the candidate code character strings according to the candidate code character strings.
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 only limited by the appended claims
The above description is only for the purpose of illustrating the preferred embodiments of the present invention and is not to be construed as limiting the invention, and any modifications, equivalents, improvements and the like that fall within the spirit and principle of the present invention are intended to be included therein.
It is noted that, herein, relational terms such as first and second, and the like may be used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Also, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other identical elements in a process, method, article, or apparatus that comprises the element. The invention may be described in the general context of computer-executable instructions, such as program modules, being executed by a computer. Generally, program modules include routines, programs, objects, components, data structures, etc. that perform particular tasks or implement particular abstract data types. The invention may also be practiced in distributed computing environments where tasks are performed by remote processing devices that are linked through a communications network. In a distributed computing environment, program modules may be located in both local and remote computer storage media including memory storage devices.
The embodiments in the present specification are described in a progressive manner, and the same and similar parts among the embodiments are referred to each other, and each embodiment focuses on the differences from the other embodiments. In particular, for the apparatus embodiment, since it is substantially similar to the method embodiment, it is relatively simple to describe, and reference may be made to some descriptions of the method embodiment for relevant points. The above-described embodiments of the apparatus are merely illustrative, and the units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of the present embodiment. One of ordinary skill in the art can understand and implement it without inventive effort. The foregoing is directed to embodiments of the present invention, and it is understood that various modifications and improvements can be made by those skilled in the art without departing from the spirit of the invention.

Claims (9)

1. An input method is characterized in that a candidate input word library is constructed, the candidate input word library comprises the corresponding relation between candidate input words and candidate coding character strings, and the method comprises the following steps:
receiving a first code character string input by a user, wherein the first code character string comprises at least two code character units;
when the first coded character string contains preset characters, searching a candidate coded character string matched with the first coded character string in the candidate input word library; wherein the preset characters are used for replacing one or more coding character units;
and determining candidate input words corresponding to the candidate code character strings according to the candidate code character strings.
2. The method of claim 1, wherein constructing the library of candidate input words comprises:
determining a target word;
adding a first target word containing the target word into a candidate input word bank, and storing the corresponding relation between the first target word and a coding character string corresponding to the first target word; and/or the presence of a gas in the gas,
determining a second target word;
adding the second target word into a candidate input word library, and storing the corresponding relation between the second target word and the coding character string corresponding to the second target word; and/or the presence of a gas in the gas,
acquiring historical input data of a user;
and adding the on-screen input words corresponding to the code character strings containing the preset characters into a candidate input word library in the historical input data, and storing the corresponding relation between the on-screen input words and the code character strings corresponding to the on-screen input words.
3. The method of claim 1, wherein after said determining the candidate input word corresponding to the candidate encoded string, the method further comprises:
and sequencing the candidate input words, and displaying the sequenced candidate input words.
4. The method of claim 3, wherein the ranking the candidate input words comprises:
acquiring word input frequency of the candidate input words, and arranging the candidate input words in an ascending order according to the word input frequency; and/or the presence of a gas in the gas,
acquiring the total number of strokes of the candidate input words, and arranging the candidate input words in a descending order according to the total number of strokes of the candidate input words; and/or the presence of a gas in the gas,
the candidate input words are ranked based on a user's previous input prior to the input of the first encoded string.
5. The method according to any one of claims 1-4, further comprising:
determining candidate input words corresponding to the preset characters in the candidate input words, and acquiring description information of the candidate input words;
and displaying the description information of the candidate input word.
6. An input device, comprising:
the word stock construction unit is used for constructing a candidate input word stock, and the candidate input word stock comprises the corresponding relation between candidate input words and candidate coding character strings;
the device comprises a receiving unit, a processing unit and a display unit, wherein the receiving unit is used for receiving a first code character string input by a user, and the first code character string comprises at least two code character units;
the matching unit is used for searching a candidate code character string matched with the first code character in the candidate input word library when the first code character string contains preset characters; wherein the preset characters are used for replacing one or more coding character units;
and the determining unit is used for determining candidate input words corresponding to the candidate code character strings according to the candidate code character strings.
7. The apparatus of claim 6, further comprising:
the obtaining unit is used for determining candidate input words corresponding to the preset characters in the candidate input words and obtaining description information of the candidate input words;
and the display unit is used for displaying the description information of the candidate input words.
8. 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:
constructing a candidate input word bank, wherein the candidate input word bank comprises a corresponding relation between candidate input words and candidate coding character strings;
receiving a first code character string input by a user, wherein the first code character string comprises at least two code character units;
when the first coded character string contains preset characters, searching a candidate coded character string matched with the first coded character string in the candidate input word library; wherein the preset characters are used for replacing one or more coding character units;
and determining candidate input words corresponding to the candidate code character strings according to the candidate code character strings.
9. 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-5.
CN201710702660.8A 2017-08-16 2017-08-16 Input method and device Active CN107247519B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710702660.8A CN107247519B (en) 2017-08-16 2017-08-16 Input method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710702660.8A CN107247519B (en) 2017-08-16 2017-08-16 Input method and device

Publications (2)

Publication Number Publication Date
CN107247519A CN107247519A (en) 2017-10-13
CN107247519B true CN107247519B (en) 2020-09-29

Family

ID=60012830

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710702660.8A Active CN107247519B (en) 2017-08-16 2017-08-16 Input method and device

Country Status (1)

Country Link
CN (1) CN107247519B (en)

Families Citing this family (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109669549B (en) * 2017-10-16 2023-04-28 北京搜狗科技发展有限公司 Candidate content generation method and device for candidate content generation
CN109901726B (en) * 2017-12-08 2022-08-02 北京搜狗科技发展有限公司 Candidate word generation method and device and candidate word generation device
CN109976548B (en) * 2017-12-28 2022-07-19 北京搜狗科技发展有限公司 Input method and input device
CN108345391B (en) * 2018-01-22 2020-06-26 平安科技(深圳)有限公司 Character sorting method, character input method and terminal equipment
CN108399013B (en) * 2018-03-16 2022-08-09 北京搜狗科技发展有限公司 User word adding method and device
CN110580103A (en) * 2018-06-11 2019-12-17 阿里巴巴集团控股有限公司 data processing method, device and machine readable medium
CN109144290B (en) * 2018-08-17 2023-07-25 科大讯飞股份有限公司 Candidate entry adjustment method, device, equipment and readable storage medium
JP7243106B2 (en) * 2018-09-27 2023-03-22 富士通株式会社 Correction candidate presentation method, correction candidate presentation program, and information processing apparatus
CN109493848A (en) * 2018-12-17 2019-03-19 深圳市沃特沃德股份有限公司 Audio recognition method, system and electronic device
CN109799917A (en) * 2019-02-19 2019-05-24 天津字节跳动科技有限公司 Character input method and device
CN111158500A (en) * 2019-12-18 2020-05-15 河南芯盾网安科技发展有限公司 Method and device for improving input efficiency by using wildcard
CN111880668A (en) * 2020-06-15 2020-11-03 维沃移动通信有限公司 Input display method and device and electronic equipment

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1920827A (en) * 2006-08-23 2007-02-28 北京搜狗科技发展有限公司 Method for obtaining newly encoded character string, input method system and word stock generation device
CN101183281A (en) * 2007-12-26 2008-05-21 腾讯科技(深圳)有限公司 Method for inputting word related to candidate word in input method and system
WO2008135585A1 (en) * 2007-05-07 2008-11-13 Ford-Werke Gmbh Method and device for selecting designations from at least one predetermined word pool
CN102346561A (en) * 2010-07-30 2012-02-08 腾讯科技(深圳)有限公司 Method and device for adding user words in input method
CN102646022A (en) * 2012-04-10 2012-08-22 北京搜狗科技发展有限公司 Method and device for obtaining candidate
CN102866781A (en) * 2011-07-06 2013-01-09 哈尔滨工业大学 Pinyin-to-character conversion method and pinyin-to-character conversion system
CN105094368A (en) * 2015-07-24 2015-11-25 上海二三四五网络科技有限公司 Control method and control device for frequency modulation ordering of input method candidate item
CN105607757A (en) * 2015-12-28 2016-05-25 北京搜狗科技发展有限公司 Input method and device and device used for input

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1920827A (en) * 2006-08-23 2007-02-28 北京搜狗科技发展有限公司 Method for obtaining newly encoded character string, input method system and word stock generation device
WO2008135585A1 (en) * 2007-05-07 2008-11-13 Ford-Werke Gmbh Method and device for selecting designations from at least one predetermined word pool
CN101183281A (en) * 2007-12-26 2008-05-21 腾讯科技(深圳)有限公司 Method for inputting word related to candidate word in input method and system
CN102346561A (en) * 2010-07-30 2012-02-08 腾讯科技(深圳)有限公司 Method and device for adding user words in input method
CN102866781A (en) * 2011-07-06 2013-01-09 哈尔滨工业大学 Pinyin-to-character conversion method and pinyin-to-character conversion system
CN102646022A (en) * 2012-04-10 2012-08-22 北京搜狗科技发展有限公司 Method and device for obtaining candidate
CN105094368A (en) * 2015-07-24 2015-11-25 上海二三四五网络科技有限公司 Control method and control device for frequency modulation ordering of input method candidate item
CN105607757A (en) * 2015-12-28 2016-05-25 北京搜狗科技发展有限公司 Input method and device and device used for input

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
《汉字编码输入法研究》;戴石鳞;《中国优秀博硕士学位论文全文数据库(硕士) 信息科技辑》;20051215(第08期);I138-699 *

Also Published As

Publication number Publication date
CN107247519A (en) 2017-10-13

Similar Documents

Publication Publication Date Title
CN107247519B (en) Input method and device
CN109243430B (en) Voice recognition method and device
CN107844199B (en) Input method, system and device for inputting
CN107544684B (en) Candidate word display method and device
CN109799916B (en) Candidate item association method and device
CN109144286B (en) Input method and device
CN109901726B (en) Candidate word generation method and device and candidate word generation device
CN108108356B (en) Character translation method, device and equipment
CN111831132A (en) Information recommendation method and device and electronic equipment
CN109388252B (en) Input method and device
CN109032374B (en) Candidate display method, device, medium and equipment for input method
CN113589949A (en) Input method and device and electronic equipment
CN111103986A (en) User word stock management method and device and input method and device
CN113515618A (en) Voice processing method, apparatus and medium
CN107665206B (en) Method and system for cleaning user word stock and device for cleaning user word stock
CN110413133B (en) Input method and device
CN112083811B (en) Candidate item display method and device
CN108874170B (en) Input method and device
CN110580126B (en) Virtual keyboard and input method based on virtual keyboard
CN113703590A (en) Input method, input device and input device
CN110780750A (en) Input method and device
CN109213799B (en) Recommendation method and device for cell word bank
CN113703588A (en) Input method, input device and input device
CN109213332B (en) Input method and device of expression picture
CN114594861A (en) Recommendation method and device and electronic equipment

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant