WO2022105754A1 - 输入文字的方法、装置和电子设备 - Google Patents
输入文字的方法、装置和电子设备 Download PDFInfo
- Publication number
- WO2022105754A1 WO2022105754A1 PCT/CN2021/130961 CN2021130961W WO2022105754A1 WO 2022105754 A1 WO2022105754 A1 WO 2022105754A1 CN 2021130961 W CN2021130961 W CN 2021130961W WO 2022105754 A1 WO2022105754 A1 WO 2022105754A1
- Authority
- WO
- WIPO (PCT)
- Prior art keywords
- target
- word
- text
- input
- 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.)
- Ceased
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F3/00—Input 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/01—Input arrangements or combined input and output arrangements for interaction between user and computer
- G06F3/02—Input arrangements using manually operated switches, e.g. using keyboards or dials
- G06F3/023—Arrangements 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/0233—Character input methods
- G06F3/0237—Character input methods using prediction or retrieval techniques
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/90—Details of database functions independent of the retrieved data types
- G06F16/903—Querying
- G06F16/90335—Query processing
- G06F16/90344—Query processing by using string matching techniques
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F40/00—Handling natural language data
- G06F40/20—Natural language analysis
- G06F40/237—Lexical tools
- G06F40/242—Dictionaries
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F40/00—Handling natural language data
- G06F40/20—Natural language analysis
- G06F40/279—Recognition of textual entities
- G06F40/289—Phrasal analysis, e.g. finite state techniques or chunking
Definitions
- the present application belongs to the field of communication technologies, and in particular relates to a method, an apparatus and an electronic device for inputting text.
- the electronic device when a user uses an electronic device to input content, if the above-mentioned input content happens to have corresponding text content in the first thesaurus of the electronic device, it can be directly displayed in the electronic device for the user to select.
- the electronic device When there is no corresponding text content in the first lexicon of the electronic device, in order to improve the efficiency of the user inputting text, the electronic device usually records the final on-screen vocabulary when the user enters the content, and when the user enters the input content again, you can Displayed directly in the electronic device for user selection.
- the electronic device since the electronic device records all the characters on the screen, when the user inputs part of the characters in the whole sentence, the electronic device still cannot directly output the characters required by the user. In this way, the vocabulary recorded by the electronic device cannot meet the actual needs of the user and conform to the actual input habit of the user, which in turn makes the user need to use the electronic device to repeatedly input text, which increases the steps of text input, resulting in low efficiency when the user enters text. .
- the purpose of the embodiments of the present application is to provide a method, device and electronic device for inputting text, which can solve the problem that the vocabulary recorded by the electronic device cannot meet the actual needs of the user and conform to the actual input habit of the user, thereby making the user need to use the electronic device.
- the device repeatedly enters text, adding steps to enter text, which leads to a problem of low efficiency when the user enters text.
- an embodiment of the present application provides a method for inputting text.
- the method includes: an electronic device receives a first character string input by a user, and displays a first text corresponding to the first character string;
- the text includes the target word
- the above target word and the corresponding relationship between the above target word and the target character string are stored in the target thesaurus; wherein, the above-mentioned first character string includes the above-mentioned target character string, and the above-mentioned target word is semantic complete words.
- an embodiment of the present application provides a device for inputting text
- the device includes a display module and a storage module
- the display module is configured to receive a first character string input by a user, and display the first character string corresponding to the first character string.
- a text the above-mentioned storage module is configured to store the above-mentioned target word and the corresponding relationship between the above-mentioned target word and the target character string in the target vocabulary when the above-mentioned first text displayed by the above-mentioned display module includes the target word; wherein , the first character string includes the target character string, and the target word is the semantically complete word.
- embodiments of the present application provide an electronic device, the electronic device includes a processor, a memory, and a program or instruction stored on the memory and executable on the processor, the program or instruction being The processor implements the steps of the method according to the first aspect when executed.
- an embodiment of the present application provides a readable storage medium, where a program or an instruction is stored on the readable storage medium, and when the program or instruction is executed by a processor, the steps of the method according to the first aspect are implemented .
- an embodiment of the present application provides a chip, the chip includes a processor and a communication interface, the communication interface is coupled to the processor, and the processor is configured to run a program or an instruction, and implement the first aspect the method described.
- the electronic device after receiving the first character string input by the user, displays the first text corresponding to the first character string, and if the first text includes a target word, the target word, And the corresponding relationship between the target word and the target character string is stored in the target lexicon, the first character string includes the target character string, and the target word is a word with complete semantics. It can be seen from the above process that after the electronic device displays the first text, the electronic device can extract the target word in the first text, and store the target word and the target character string corresponding to the target word in the target vocabulary.
- the device enables the user to directly output the target word for the user to use when inputting the target string corresponding to the target word when the user needs to use the target word on the electronic device in the future, saving user input.
- the time and steps for selecting the final word after the character string corresponding to the target word improves the efficiency of the user using the electronic device.
- FIG. 1 is a schematic flowchart of a method for inputting text provided by an embodiment of the present application
- FIG. 2 is one of the schematic diagrams of an interface to which a method for inputting text provided by an embodiment of the present application is applied;
- FIG. 3 is a second schematic diagram of an interface to which a method for inputting text provided by an embodiment of the present application is applied;
- FIG. 4 is a schematic structural diagram of a device for inputting text according to an embodiment of the present application.
- FIG. 5 is one of the schematic structural diagrams of an electronic device provided by an embodiment of the present invention.
- FIG. 6 is a second schematic structural diagram of an electronic device according to an embodiment of the present invention.
- first, second and the like in the description and claims of the present application are used to distinguish similar objects, and are not used to describe a specific order or sequence. It is to be understood that the data so used are interchangeable under appropriate circumstances so that the embodiments of the present application can be practiced in sequences other than those illustrated or described herein, and distinguish between “first”, “second”, etc.
- the objects are usually of one type, and the number of objects is not limited.
- the first object may be one or more than one.
- “and/or” in the description and claims indicates at least one of the connected objects, and the character “/" generally indicates that the associated objects are in an "or” relationship.
- the method for inputting text provided by the embodiments of the present application can be applied to a scenario where a user inputs text on the upper screen.
- the user may have the following two input situations:
- the first input case is a first input case
- the electronic device will record the sentence "Do you like Xiao Ming” in the thesaurus.
- the user needs to use the electronic device "Xiao Ming” since the electronic device records the sentence "Do you like Xiao Ming", the user needs to filter "Xiao” and "Ming” in turn after entering "xiaoming" on the screen.
- the electronic equipment can only record a complete sentence that is displayed on the screen at one time, but cannot record other words in the sentence that are not in the electronic equipment thesaurus.
- the user needs other words in the sentence
- the vocabulary is displayed on the screen, the user will actually be caused to repeatedly input the words that have been entered and displayed on the screen, which increases the steps for the user to input characters, and reduces the efficiency of the user in using the electronic device.
- the second input case is a first input case
- This embodiment provides a method for inputting text. As shown in FIG. 1 , this embodiment is applied to a first electronic device, and the electronic device positioning method includes the following steps 201 and 202
- Step 201 The device for inputting text receives a first character string input by a user, and displays a first text corresponding to the first character string.
- the above-mentioned first text may be a candidate word selected by the user and displayed in the candidate word display area to be displayed on the screen.
- the above-mentioned first text may be the first text consisting of X words, or may be the first text consisting of X words corresponding to one word.
- the above process of displaying the first text may be: displaying the candidate words to be displayed on the screen in other areas of the interface except the candidate word display area.
- the current display interface is a dialog window interface of a chat application
- the user can display the first text displayed in the candidate word display area in the dialog window interface through the first input, as shown in FIG. 2 , except for the above-mentioned dotted line
- the area other than the area where the frame 11 is located, and the remaining areas are the display areas after the screen is displayed.
- the above-mentioned process of displaying the first text may be: after the above-mentioned X words are displayed in the candidate word display area, the electronic device receives the input on the upper screen. On the screen together.
- the above-mentioned process of displaying the first text may be: the Y-th word in the above-mentioned X words is displayed in the candidate word display area. After the electronic device receives the input from the screen, the screen is displayed.
- the process of displaying the first text may be: after the first character in the above-mentioned X characters is displayed in the candidate word display area, the electronic device receives the input from the screen; then, the first character in the above-mentioned X characters is displayed on the screen; After the two characters are displayed in the candidate word display area, they are displayed on the screen after the electronic device receives the input on the upper screen; until the Xth character in the above X characters is displayed in the candidate word display area, after the electronic device receives the input on the upper screen screen.
- the Y-th word in the above-mentioned X words may be one word in the X words, or may be a plurality of words, but not all the words in the X words.
- Example 1 When the user needs the first text displayed on the electronic device to be "Fuding Community”, the user can first enter “Blessing”, go to the screen, delete “Wish”, then enter “Ding”, go to the screen, and finally enter " Community” on the screen, then the final first text on the screen is "Fuding Community”.
- Step 202 In the case where the first text includes the target word, the device for inputting the text stores the target word and the corresponding relationship between the target word and the target character string in the target vocabulary.
- the first character string includes the target character string
- the target word is a word with complete semantics.
- the above-mentioned words with complete semantics are words that can express complete and independent meanings
- the above-mentioned target thesaurus may be an overall thesaurus pre-stored in the electronic device, that is, a thesaurus containing all words in the electronic device; it may also be a user-defined thesaurus; it may also be a pre-stored thesaurus in the electronic device
- a sub-thesaurus, the sub-thesaurus can be a thesaurus corresponding to one or several applications.
- the device for inputting text after receiving the first character string input by the user, the device for inputting text displays the first text corresponding to the first character string, and the first text includes the text of the target word.
- the target word and the corresponding relationship between the target word and the target character string are stored in the target lexicon
- the first character string includes the target character string
- the target word is a word with complete semantics.
- the device for inputting text can directly output the target word when inputting the target string corresponding to the target word when the user needs to use the target word on the electronic device through this intelligent learning method.
- the time and steps for selecting the final word after the user enters the character string corresponding to the target word is saved, and the efficiency of the user using the electronic device is improved.
- the method for inputting text in this embodiment of the present application may include the following step A:
- Step A The device for inputting text performs word segmentation processing on the first text, and extracts N words in the first text.
- the above target words are: words that are not stored in the target word database among the above N words.
- the above word segmentation process may be a process of performing word recognition on the first text.
- the electronic device may use an application tool or a plug-in including a natural language processing (Natural Language Processing, NLP) function to perform word segmentation processing on the above-mentioned first text.
- NLP Natural Language Processing
- the above-mentioned word segmentation processing is a process of identifying and extracting N words from the first text.
- the word segmentation process is a process of identifying the three words "you", “like” and "Xiaoming" from the first text "you like Xiaoming”.
- the electronic device can recognize N word segments, that is, N words, in the first text through the recognition process of the word segmentation process.
- the electronic device may compare the above N words with all the words stored in the target thesaurus. For the repeated words, only words that are not stored in the target thesaurus are stored.
- Example 1 Suppose the user uses the Pinyin input method to input "nixihuanxiaoming" (ie the first string above) in the chat interface while using the chat application, and selects the corresponding Chinese “You like Huawei", as shown in Figure 3 As shown in (a) of the above, the user clicks the “send” control 21 to input the input, and after the electronic device receives the input, as shown in (b) of FIG. That is, the above-mentioned first text) is displayed in the dialog interface 22 . At this time, the electronic device performs word segmentation processing on "you like Huaweing", and extracts 3 word segmentations (that is, the above N words), which are "you", “like” and "Xiaoming”.
- the electronic device compares the above three segmented words with the thesaurus in the electronic device (that is, the above-mentioned target thesaurus). If the word database does not contain "Xiao Ming", the electronic device stores "Xiao Ming" (that is, the above target word) in the word database.
- the method for inputting text may further include the following steps B1 and B2:
- Step B1 The apparatus for inputting text receives the first input of the above-mentioned first text sent by the user.
- Step B2 In response to the above-mentioned first input, the apparatus for inputting text displays the above-mentioned first text on the screen.
- the method for inputting text may include the following step B3:
- Step B3 The device for inputting text performs word segmentation processing on the above-mentioned first text after being displayed on the screen.
- first input can be used to trigger the candidate word to be displayed on the screen, that is, the first text to be displayed on the screen.
- the device for inputting text displays the first text on the screen.
- relevant operations of word segmentation processing are started.
- the above-mentioned first input may be a touch input, for example, a click input, a voice input, or an input of a special gesture, which is not limited in this embodiment of the present application.
- the method for inputting text may further include the following steps C1 and C2:
- Step C1 The device for inputting text receives the user's input for deleting the target character in the first text.
- Step C2 The device for inputting characters integrates the characters before and after the target character, and determines the integrated word as the target word if the word obtained after integration satisfies the condition.
- the above target characters are part of the characters in the first text.
- the above-mentioned target character can be located in the middle position of the first text, that is, there are characters before and after the target character; the above-mentioned target character can be located in the front position of the first text, that is, there is no character in front of the target character;
- the target character may be located behind the first text, that is, there are no characters behind the target character.
- the input device automatically combines the remaining characters after receiving the deleted input, and generates words correspondingly.
- the above conditions are: the generated words are words not included in the target vocabulary, that is, if the words obtained after integration are not in the target vocabulary, the integrated words are determined as target words and stored.
- Example 2 Combined with the above example 1, suppose the user uses the Pinyin input method to input “qinshui”, “wanliu” and “huayuan” in the input box successively, and selects the corresponding Chinese “hydrophilic”, “Gulf stream” and “garden”.
- the input device After entering the box, delete and input the middle character "flow" in the string, then the remaining "hydrophilic bay garden", the input device will compare "hydrophilic bay garden" with the thesaurus in the electronic device (that is, the above-mentioned target thesaurus ) to compare the words in the thesaurus in the electronic device, if the word is not included in the thesaurus in the electronic device (that is, if the above conditions are met), determine "Hyridic Bay Garden” as the target word and store it in the thesaurus.
- the user can display the characters containing the words required by the user in the input box by spelling the commonly used vocabulary, and when the user deletes the redundant characters,
- the electronic device can automatically integrate the remaining characters, and store the word in the thesaurus if the target vocabulary does not contain the word, so as to be used for the next use, and improve the efficiency of the user's use of the electronic device to input characters.
- performing word segmentation processing on the first text in the above step A, and extracting N words in the first text may include the following steps D1 and D2:
- Step D1 In the case where there is a deletion input of the target character in the first text, the device for inputting text detects the first substring before the target position where the target character is located, and detects the first substring in the first subcharacter. When the string satisfies the predetermined word segmentation condition, the word matching the above-mentioned first substring is determined as the target word.
- Step D2 In the presence of deletion input of the target character in the first text, the device for inputting text detects the second substring after the target position where the target character is located, and performs When the string satisfies the predetermined word segmentation condition, the word matching the above-mentioned second substring is determined as the target word.
- the predetermined word segmentation condition is: words matching the first substring and words matching the second substring are words not included in the target vocabulary.
- the above-mentioned first substring may contain multiple characters
- the above-mentioned second substring may also contain multiple characters
- the device for inputting text can automatically traverse the target lexicon of the electronic device to inquire whether it contains words that match the first substring and words that match the second substring. Words, in the case that the words matching the first substring and the words matching the second substring are not included, the words matching the first substring and the words matching the second substring can be automatically combined.
- the words are stored in the target thesaurus.
- the electronic device can automatically detect the words formed by the strings before and after the redundant characters, and compare it with its own target thesaurus.
- the words formed by the above strings are not included, the words formed by the strings before and after the above redundant characters are stored in the thesaurus for memory, which is convenient for users to use later.
- the detection time improves the efficiency of the user inputting text using the electronic device.
- the above-mentioned first character string includes M substrings.
- the method for inputting text in this embodiment of the present application may include the following step E:
- Step E The device for inputting text determines the target candidate words corresponding to each substring, and displays the M target candidate words on the screen, where M is a positive integer.
- the above-mentioned first character string is a character string corresponding to the characters or words that the user needs to display on the screen.
- the characters in the above-mentioned first character string may correspond to different character types. For example, Pinyin characters, or Wubi characters.
- the above-mentioned M substrings may correspond to a single character, or a word, or a phrase, or an entire sentence. where each substring corresponds to a character type.
- the above-mentioned M substrings may correspond to a single character or a word containing a single character, that is, the above-mentioned 1 substring corresponds to a single character or a word that includes a single character string.
- the above-mentioned X single characters as described in the foregoing content, may form a word, and the word corresponds to the first text.
- the substring corresponding to the character "Fu” in the above example 1 may be "fu", or the character string "zhufu" corresponding to the word "blessing" containing the character "Fu”.
- the above-mentioned M sub-strings may correspond to phrases or whole sentences, that is, the above-mentioned M sub-strings correspond to a phrase composed of N words or a whole sentence composed of N words. String.
- One substring corresponds to one word, and the above-mentioned N words can form the first text as described in the foregoing content.
- a candidate word corresponding to the substring will be displayed on the interface displaying the substring for the user to select, and the user selects the target candidate corresponding to the substring.
- the screen input can be performed on the electronic device, and the M target candidate words can be displayed on the screen.
- Example 3 Suppose the user wants to use the pinyin input method to output "hydrophilic bay garden" in the dialog box of the chat interface during the process of using the chat application, then the user first uses the pinyin input method to input "qin” in the chat interface, and then In the candidate words, select “pro” (that is, the above-mentioned target candidate word) on the screen; then enter “shui” in the chat interface, select “water” (that is, the above-mentioned target candidate word) on the screen; then enter “wanliu” in the chat interface , select “Gulfstream” (that is, the target candidate word above) on the screen, delete the word “Flow” in “Gulfstream”; finally, enter “huayuan” in the chat interface, select “Garden” (that is, the target candidate word above) on the screen , and finally output "Hybrid Bay Garden” in the dialog 22 of the chat interface.
- select "pro” that is, the above-mentioned target candidate word
- water
- the word segmentation process is performed on the first text to extract the N words in the first text
- the method for inputting text in the embodiment of the present application may include: Step F as follows:
- Step F When the duration of the above-mentioned first text on the screen reaches a predetermined duration, the device for inputting text performs word segmentation processing on the above-mentioned first text to obtain N words.
- the above-mentioned predetermined duration may be preset by the electronic device, or may be user-defined and set, which is not limited in this embodiment of the present application.
- Example 4 Combined with the above example 1, when the electronic device displays "You like Huawei” (that is, the first text above) in the dialog interface (that is, the above-mentioned upper screen), after the predetermined time period arrives, the electronic device displays "Do you like Huawei” "Xiao Ming" (that is, the first text above) is subjected to word segmentation processing to obtain 3 word segmentations (that is, the above N words). For specific word segmentation processing, please refer to Example 1.
- Example 5 Combined with the above example 3, when "Hydromic Bay Garden” is output in the dialog box 31 of the chat interface, after the predetermined time period arrives, the electronic device will perform an operation on the "Hyridic Bay Garden" (that is, the above-mentioned first text). After word segmentation processing, 1 word segmentation (that is, the above-mentioned N words) is obtained, and the electronic device compares the above-mentioned 1 word segmentation with the thesaurus in the electronic device (that is, the above-mentioned target thesaurus). If the "hydrophilic bay garden” is not stored in the thesaurus, the electronic device stores the "hydrophilic bay garden” (ie, the above target word) in the thesaurus.
- 1 word segmentation that is, the above-mentioned N words
- the electronic device compares the above-mentioned 1 word segmentation with the thesaurus in the electronic device (that is, the above-mentioned target thesaurus). If the "hydrophilic bay garden”
- the electronic device can perform word segmentation processing after combining the content input by the user for a period of time, and even the words output by the user through multiple screen display processes can also be learned and stored in the target vocabulary, that is, it is not only It can memorize and store long sentences or phrases in segments, and can also memorize and store words composed of single characters by themselves. Therefore, it is convenient for the user to use the word again and directly generate the word, so that the way that the electronic device learns and stores the text input by the user is more in line with the actual input habit of the user, enhances the ability of the electronic device to learn and store words, and improves the efficiency of the user using the electronic device.
- the method for inputting text in the embodiment of the present application may include the following step G1:
- Step G1 The device for inputting characters receives the first character string input by the user when the target interface of the target application is displayed.
- step G2 Based on above-mentioned step G1, in above-mentioned step 202 with above-mentioned target word, and the correspondence relation of above-mentioned target word and target character string is stored in the target vocabulary, the method for inputting text in the embodiment of the present application can comprise following step G2:
- Step G2 The device for inputting characters stores the N target words and the corresponding relationship between the target words and the target character string in the target vocabulary corresponding to the target application.
- the above-mentioned target application may be any application in the electronic device that includes a text-based interaction function.
- chat application video application.
- the above-mentioned target interface may be any interface in the above-mentioned target application in which the user can input text.
- chat interface in chat application video search interface in video application.
- the above target thesaurus may be: a thesaurus composed of words related to the content in the target application.
- the above-mentioned target thesaurus may be a thesaurus carried by the target application.
- the target thesaurus may be the thesaurus corresponding to the thesaurus data package pre-stored in the data package of the target application when the user downloads the target application.
- the above-mentioned relationship between the target application and the target vocabulary may be a one-to-one correspondence, that is, one target application corresponds to one target vocabulary; it may also be a corresponding relationship in which multiple applications correspond to one target vocabulary.
- the electronic device may set the vocabulary according to the functional characteristics of the application. For example: when the target application is a shopping application of daily necessities, the words contained in the thesaurus of the shopping application of life are words of daily necessities; when the application is a shopping application of food, the thesaurus of the shopping application of food contains words The words are food words.
- the electronic device may set the thesaurus according to the type of the application. For example, when both the lifestyle shopping application and the food shopping application are shopping applications, the above-mentioned life shopping application and food shopping correspond to the same thesaurus, and the words contained in the thesaurus are shopping words, which can satisfy the The needs of life shopping applications can also meet the needs of food shopping applications.
- the electronic device may store the target word segment in the target word database.
- the electronic device can classify the target word segmentation according to the word segmentation type, and store it in the target thesaurus corresponding to the target application.
- the electronic device Words that match the application scenario can be accurately retrieved from the target thesaurus corresponding to the target application for the user to filter and use.
- the method for inputting text provided by the embodiment of the present application further includes the following steps H1 and H2:
- Step H1 The device for inputting text receives the second input of the second character string.
- the second character string includes a start character of the character string corresponding to the target word segment and some characters after the start character.
- the target participle is "qinshuiwanhuayuan”
- the above second string can be: “qinshuiw”.
- the above-mentioned second character string does not include the complete character string corresponding to the above-mentioned target word segmentation.
- Step H2 In response to the second input, the device for inputting text displays a list of candidate words corresponding to the second character string.
- the above-mentioned second input is an input for inputting a second character string.
- the above-mentioned second input may be a touch input, such as a click input, a voice input, or an input of a specific gesture. , which is not limited in the embodiments of the present application.
- the above-mentioned candidate word list may include all candidate words that conform to the above-mentioned second character string spelling rule, and the above-mentioned candidate word list includes the above-mentioned target word.
- the electronic device may adjust the display priority order of the target word within a predetermined time after the electronic device stores the target word, and within the predetermined time, if the user inputs the second character string, the electronic device may In the candidate word list, adjust the display order of the target word to the first display.
- Example 6 Before “Xiao Ming" is stored, when the user inputs the partial string “xiao” corresponding to “Xiao Ming", the display order of the candidate words in the candidate word list is "Xiaohua”, “Xiaohong”.
- the user after the target word is stored in the thesaurus of the electronic device, the user only needs to input some characters corresponding to the target word, and then the target word can be found in the candidate word list and used, which improves the user's ability to input text using the electronic device. efficiency.
- the execution body may be a device for inputting characters, or a control module in the device for inputting characters for executing the method for inputting characters.
- the device for inputting characters provided by the embodiments of the present application is described by taking the method for inputting characters performed by the device for inputting characters as an example.
- FIG. 4 is a schematic structural diagram of a possible structure of the apparatus for implementing the text input provided by the embodiment of the present application.
- the above-mentioned apparatus 600 for inputting text includes: a display module 601 and a storage module 602; the above-mentioned display module 601 is used for receiving a first character string input by a user, and displaying the first text corresponding to the above-mentioned first character string;
- the above-mentioned storage module 602 is configured to store the above-mentioned target word and the corresponding relationship between the above-mentioned target word and the target character string in the target vocabulary when the above-mentioned first text displayed by the above-mentioned display module 601 includes the target word; wherein,
- the above-mentioned first character string includes the above-mentioned target character string, and the above-mentioned target word is the above-mentioned semantically complete word.
- the device for inputting text provided by the embodiment of the present application, after receiving the first character string input by the user, the device for inputting text displays the first text corresponding to the first character string, in the case that the target word is included in the first text , the target word and the corresponding relationship between the target word and the target character string are stored in the target lexicon, the first character string includes the target character string, and the target word is a word with complete semantics. It can be seen from the above process that when the device for inputting text displays the first text, the device for inputting text can extract the target word in the first text, and store the target word and the target character string corresponding to the target word in the target thesaurus.
- the device for inputting text can directly output the target word when inputting the target string corresponding to the target word when the user needs to use the target word on the electronic device through this intelligent learning method.
- the time and steps for selecting the final word after the user enters the character string corresponding to the target word is saved, and the efficiency of the user using the electronic device is improved.
- the above-mentioned apparatus 600 further includes an extraction module 603; the above-mentioned extraction module 603 is configured to perform word segmentation processing on the above-mentioned first text, and extract N words in the above-mentioned first text; wherein, the above-mentioned The target words are: words that are not stored in the target thesaurus among the above M words.
- the above-mentioned apparatus 600 further includes: a first receiving module 604, a screen-up module 605, and a processing module 606; the above-mentioned first receiving module 604 is configured to receive the first text sent by the user. an input; the above-mentioned screen-up module 605 is used to display the above-mentioned first text in response to the above-mentioned first input received by the above-mentioned first receiving module 604; the above-mentioned processing module 606 is used for the above-mentioned screen-up module 605 after the screen is displayed The above-mentioned first text is subjected to word segmentation processing.
- the above-mentioned apparatus 600 further includes: a second receiving module 607 and a first determining module 608; the above-mentioned second receiving module 607 is configured to receive the user's deletion of the target characters in the above-mentioned first text Input; The first determining module 608 is configured to integrate the characters before and after the target character, and determine the integrated word as the target word if the word obtained after integration satisfies the condition.
- the above-mentioned apparatus 600 further includes a second determination module 609; the above-mentioned second determination module 609 is configured to, when there is a deletion input to the target character in the first text, The first substring before the target position where the target character is located is detected, and when the above-mentioned first substring satisfies the predetermined word segmentation condition, the word matching the above-mentioned first substring is determined as the target word; the above-mentioned The second determination module 609 is further configured to detect the second substring after the target position where the target character is located in the case where there is an input to delete the target character in the first text, and perform the detection in the second substring after the target position of the target character. When the substring satisfies the predetermined word segmentation condition, the word matching the second substring is determined as the target word.
- the device for inputting text in this embodiment of the present application may be a device, or may be a component, an integrated circuit, or a chip in a terminal.
- the apparatus may be a mobile electronic device or a non-mobile electronic device.
- the mobile electronic device may be a mobile phone, a tablet computer, a notebook computer, a palmtop computer, an in-vehicle electronic device, a wearable device, an ultra-mobile personal computer (UMPC), a netbook, or a personal digital assistant (personal digital assistant).
- UMPC ultra-mobile personal computer
- netbook or a personal digital assistant
- non-mobile electronic devices can be servers, network attached storage (Network Attached Storage, NAS), personal computer (personal computer, PC), television (television, TV), teller machine or self-service machine, etc., this application Examples are not specifically limited.
- Network Attached Storage NAS
- personal computer personal computer, PC
- television television
- teller machine or self-service machine etc.
- the device for inputting text in this embodiment of the present application may be a device having an operating system.
- the operating system may be an Android (Android) operating system, an ios operating system, or other possible operating systems, which are not specifically limited in the embodiments of the present application.
- the apparatus for inputting text provided in this embodiment of the present application can implement each process implemented by the method embodiments in FIG. 1 to FIG. 2 , and in order to avoid repetition, details are not repeated here.
- the modules that must be included in the text input device 600 are indicated by solid line boxes, such as the display module 601 ; the modules that may or may not be included in the text input device 600 are indicated by dotted line boxes , such as the extraction module 603 .
- an embodiment of the present application further provides an electronic device 700, including a processor 701, a memory 702, a program or instruction stored in the memory 702 and executable on the processor 701,
- an electronic device 700 including a processor 701, a memory 702, a program or instruction stored in the memory 702 and executable on the processor 701,
- the program or instruction is executed by the processor 701
- each process of the above-mentioned method for inputting text is implemented, and the same technical effect can be achieved. In order to avoid repetition, details are not repeated here.
- the electronic devices in the embodiments of the present application include the aforementioned mobile electronic devices and non-mobile electronic devices.
- FIG. 6 is a schematic diagram of a hardware structure of an electronic device implementing an embodiment of the present application.
- the electronic device 100 includes but is not limited to: a radio frequency unit 101, a network module 102, an audio output unit 103, an input unit 104, a sensor 105, a display unit 106, a user input unit 107, an interface unit 108, a memory 109, and a processor 110, etc. part.
- the user input unit 107 includes a touch panel 1071 and other input devices 1072
- the display unit 106 includes a display panel 1061
- the input unit 104 includes an image processor 1041 and a microphone 1042
- the memory 109 can be used to store software programs (eg, an operating system). , applications required for at least one function) and various data.
- the electronic device 100 may also include a power source (such as a battery) for supplying power to various components, and the power source may be logically connected to the processor 110 through a power management system, so as to manage charging, discharging, and power management through the power management system. consumption management and other functions.
- a power source such as a battery
- the structure of the electronic device shown in FIG. 6 does not constitute a limitation on the electronic device, and the electronic device may include more or less components than those shown in the figure, or combine some components, or arrange different components, which will not be repeated here. .
- the display unit 106 is configured to receive the first character string input by the user, and display the first text corresponding to the first character string; the memory 109 is configured to display the target word in the first text
- the words, and the correspondence between the target words and the target character string are stored in the target thesaurus; wherein, the first character string includes the target character string, and the target word is a word with complete semantics.
- the electronic device after receiving the first character string input by the user, the electronic device displays the first text corresponding to the first character string, and if the first text includes the target word, the target word is displayed in the electronic device.
- the words and the corresponding relationship between the target word and the target character string are stored in the target thesaurus, the first character string includes the target character string, and the target word is a word with complete semantics. It can be seen from the above process that after the electronic device displays the first text, the electronic device can extract the target word in the first text, and store the target word and the target character string corresponding to the target word in the target vocabulary.
- the device enables the user to directly output the target word for the user to use when inputting the target string corresponding to the target word when the user needs to use the target word on the electronic device in the future, saving user input.
- the time and steps for selecting the final word after the character string corresponding to the target word improves the efficiency of the user using the electronic device.
- the above-mentioned processor 110 is configured to perform word segmentation processing on the above-mentioned first text, and extract N words in the above-mentioned first text; wherein, the above-mentioned target words are: among the above-mentioned N words, the target thesaurus does not store words. .
- the above-mentioned user input unit 107 is configured to receive the first input of the user sending the above-mentioned first text; the above-mentioned processor 110 is further configured to display the above-mentioned first text on the screen in response to the above-mentioned first input; the above-mentioned processor 110, which is specifically configured to perform word segmentation processing on the above-mentioned first text after the screen is displayed.
- the above-mentioned user input unit 107 is also used to receive the deletion input of the target character in the above-mentioned first text by the user; the above-mentioned processor 110 is also used to integrate the characters before and after the above-mentioned target character, and the words obtained after the integration. When the conditions are met, the above-mentioned integrated words are determined as target words.
- the above-mentioned processor 110 is specifically configured to detect the first substring before the target position where the above-mentioned target character is located in the presence of a deletion input to the target character in the first text, and in the In the case that the above-mentioned first substring satisfies the predetermined word segmentation condition, the word matching the above-mentioned first substring is determined as the target word; the above-mentioned processor 110 is specifically configured to delete the target character in the first text when there is a In the case of input, the second substring after the target position where the target character is located is detected, and if the second substring satisfies the predetermined word segmentation condition, the second substring matching the second substring is selected. The word is determined as the target word.
- the input unit 104 may include a graphics processor (Graphics Processing Unit, GPU) 1041 and a microphone 1042. Such as camera) to obtain still pictures or video image data for processing.
- the display unit 106 may include a display panel 1061, which may be configured in the form of a liquid crystal display, an organic light emitting diode, or the like.
- the user input unit 107 includes a touch panel 1071 and other input devices 1072 .
- the touch panel 1071 is also called a touch screen.
- the touch panel 1071 may include two parts, a touch detection device and a touch controller.
- Other input devices 1072 may include, but are not limited to, physical keyboards, function keys (such as volume control keys, switch keys, etc.), trackballs, mice, and joysticks, which are not described herein again.
- Memory 109 may be used to store software programs as well as various data including, but not limited to, application programs and operating systems.
- the processor 110 may integrate an application processor and a modem processor, wherein the application processor mainly processes an operating system, a user interface, and an application program, and the like, and the modem processor mainly processes wireless communication. It can be understood that, the above-mentioned modulation and demodulation processor may not be integrated into the processor 110 .
- Embodiments of the present application further provide a readable storage medium, where a program or an instruction is stored on the readable storage medium, and when the program or instruction is executed by a processor, each process of the above-mentioned method for inputting text is implemented, and can achieve The same technical effect, in order to avoid repetition, will not be repeated here.
- the processor is the processor in the electronic device described in the foregoing embodiments.
- the readable storage medium includes a computer-readable storage medium, such as a computer read-only memory (Read-Onl Memory, ROM), a random access memory (Random Access Memory, RAM), a magnetic disk or an optical disk, and the like.
- An embodiment of the present application further provides a chip, where the chip includes a processor and a communication interface, the communication interface is coupled to the processor, and the processor is configured to run a program or an instruction to implement the above method embodiments for inputting text and can achieve the same technical effect, in order to avoid repetition, it will not be repeated here.
- the chip mentioned in the embodiments of the present application may also be referred to as a system-on-chip, a system-on-chip, a system-on-a-chip, or a system-on-a-chip, or the like.
- the method of the above embodiment can be implemented by means of software plus a necessary general hardware platform, and of course can also be implemented by hardware, but in many cases the former is better implementation.
- the technical solution of the present application can be embodied in the form of a software product in essence or in a part that contributes to the prior art, and the computer software product is stored in a storage medium (such as ROM/RAM, magnetic disk, CD-ROM), including several instructions to make a terminal (which may be a mobile phone, a computer, a server, an air conditioner, or a network device, etc.) execute the methods described in the various embodiments of this application.
- a storage medium such as ROM/RAM, magnetic disk, CD-ROM
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- General Engineering & Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Computational Linguistics (AREA)
- General Health & Medical Sciences (AREA)
- Health & Medical Sciences (AREA)
- Audiology, Speech & Language Pathology (AREA)
- Artificial Intelligence (AREA)
- Databases & Information Systems (AREA)
- Human Computer Interaction (AREA)
- Data Mining & Analysis (AREA)
- Machine Translation (AREA)
Abstract
Description
Claims (17)
- 一种输入文字的方法,所述方法包括:接收用户输入的第一字符串,显示所述第一字符串对应的第一文本;在所述第一文本中包括目标词语的情况下,将所述目标词语,以及所述目标词语与目标字符串的对应关系存入目标词库中;其中,所述第一字符串包括所述目标字符串,所述目标词语为语义完整的词语。
- 根据权利要求1所述的方法,其中,所述将所述目标词语,以及所述目标词语与目标字符串的对应关系存入目标词库中之前,所述方法还包括:对所述第一文本进行分词处理,提取所述第一文本中的N个词语;其中,所述目标词语为:所述N个词语中,目标词库中未存储的词语。
- 根据权利要求2所述的方法,其中,所述显示所述第一字符串对应的第一文本之前,所述方法包括:接收用户发送所述第一文本的第一输入;响应于所述第一输入,将所述第一文本上屏;所述对所述第一文本进行分词处理,包括:对上屏后的所述第一文本进行分词处理。
- 根据权利要求1所述的方法,其中,所述显示所述第一字符串对应的第一文本之后,还包括:接收用户对所述第一文本中目标字符的删除输入;将所述目标字符前后的字符整合,在整合后得到的词语满足条件的情况下,将所述整合后的词语确定为目标词语。
- 根据权利要求4所述的方法,其中,所述在整合后得到的词语满足条件的情况下,将所述整合后的词语确定为目标词语,包括:在所述整合后得到的词语未在所述目标词库中的情况下,将所述整合后的词语确定为目标词语并保存。
- 根据权利要求2所述的方法,其中,所述对所述第一文本进行分词处理,提取所述第一文本中的N个词语,包括:在存在对第一文本中的目标字符的删除输入的情况下,对所述目标字符所处的目标位置之前的第一子字符串进行检测,并在所述第一子字符串满足预定分词条件的情况下,将与所述第一子字符串匹配的词语确定为目标词语;在存在对第一文本中的目标字符的删除输入的情况下,对所述目标字符所处的目标位置之后的第二子字符串进行检测,并在所述第二子字符串满足预定分词条件的情况下,将与所述第二子字符串匹配的词语确定为目标词语。
- 一种输入文字的装置,所述装置包括显示模块和存储模块;所述显示模块,用于接收用户输入的第一字符串,显示所述第一字符串对应的第一文本;所述存储模块,用于在所述显示模块显示的所述第一文本中包括目标词语的情况下,将所述目标词语,以及所述目标词语与目标字符串的对应关系存入目标词库;其中,所述第一字符串包括所述目标字符串,所述目标词语为所述语义完整的词语。
- 根据权利要求7所述的装置,其中,所述装置还包括提取模块;所述提取模块,用于对所述第一文本进行分词处理,提取所述第一文本中的N个词语;其中,所述目标词语为:所述M个词语中,目标词库中未存储的词语。
- 根据权利要求8所述的装置,其中,所述装置还包括:第一接收模块、上屏模块和处理模块;所述第一接收模块,用于接收用户发送所述第一文本的第一输入;所述上屏模块,用于响应于所述第一接收模块接收的所述第一输入,将所述第一文本上屏;所述处理模块,用于对所述上屏模块上屏后的所述第一文本进行分词处理。
- 根据权利要求7所述的装置,其中,所述装置还包括:第二接收模块和第一确定模块;所述第二接收模块,用于接收用户对所述第一文本中目标字符的删除输入;所述第一确定模块,用于将所述目标字符前后的字符整合,在整合后得到的词语 满足条件的情况下,将所述整合后的词语确定为目标词语。
- 根据权利要求10所述的装置,其中,所述第一确定模块具体用于:在所述整合后得到的词语未在所述目标词库中的情况下,将所述整合后的词语确定为目标词语并保存。
- 根据权利要求8所述的装置,其中,所述装置还包括第二确定模块;所述第二确定模块,用于在存在对第一文本中的目标字符的删除输入的情况下,对所述目标字符所处的目标位置之前的第一子字符串进行检测,并在所述第一子字符串满足预定分词条件的情况下,将与所述第一子字符串匹配的词语确定为目标词语;所述第二确定模块,还用于在存在对第一文本中的目标字符的删除输入的情况下,对所述目标字符所处的目标位置之后的第二子字符串进行检测,并在所述第二子字符串满足预定分词条件的情况下,将与所述第二子字符串匹配的词语确定为目标词语。
- 一种电子设备,包括处理器,存储器及存储在所述存储器上并可在所述处理器上运行的程序或指令,所述程序或指令被所述处理器执行时实现如权利要求1-6任一项所述的输入文字的方法的步骤。
- 一种可读存储介质,所述可读存储介质上存储程序或指令,所述程序或指令被处理器执行时实现如权利要求1-6任一项所述的输入文字的方法的步骤。
- 一种计算机程序产品,所述程序产品被至少一个处理器执行以实现如权利要求1至6中任一项所述的输入文字的方法。
- 一种芯片,所述芯片包括处理器和通信接口,所述通信接口和所述处理器耦合,所述处理器用于运行程序或指令,实现如权利要求1至6中任一项所述的输入文字的方法。
- 一种电子设备,包括所述电子设备被配置成用于执行如权利要求1至6中任一项所述的输入文字的方法。
Applications Claiming Priority (2)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN202011306337.7A CN112558784A (zh) | 2020-11-20 | 2020-11-20 | 输入文字的方法、装置和电子设备 |
| CN202011306337.7 | 2020-11-20 |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| WO2022105754A1 true WO2022105754A1 (zh) | 2022-05-27 |
Family
ID=75044380
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| PCT/CN2021/130961 Ceased WO2022105754A1 (zh) | 2020-11-20 | 2021-11-16 | 输入文字的方法、装置和电子设备 |
Country Status (2)
| Country | Link |
|---|---|
| CN (1) | CN112558784A (zh) |
| WO (1) | WO2022105754A1 (zh) |
Families Citing this family (2)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN112558784A (zh) * | 2020-11-20 | 2021-03-26 | 维沃移动通信有限公司 | 输入文字的方法、装置和电子设备 |
| CN113641252B (zh) * | 2021-07-06 | 2024-03-29 | 维沃移动通信有限公司 | 文本输入方法、装置及电子设备 |
Citations (6)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN101661331A (zh) * | 2008-08-28 | 2010-03-03 | 北京搜狗科技发展有限公司 | 一种字词输入的方法和输入法系统 |
| WO2013029239A1 (zh) * | 2011-08-30 | 2013-03-07 | 宇龙计算机通信科技(深圳)有限公司 | 词库更新装置、输入系统和输入方法及终端 |
| CN104699809A (zh) * | 2015-03-20 | 2015-06-10 | 广东睿江科技有限公司 | 一种优选词库的控制方法及装置 |
| CN106933382A (zh) * | 2017-03-17 | 2017-07-07 | 北京小米移动软件有限公司 | 更新输入法词库的方法及装置 |
| KR20180007183A (ko) * | 2016-07-12 | 2018-01-22 | (주) 리얼밸류 | 대표문자와 공백 입력을 통한 둘 이상의 단어로 구성된 문장입력방법 및 장치 |
| CN112558784A (zh) * | 2020-11-20 | 2021-03-26 | 维沃移动通信有限公司 | 输入文字的方法、装置和电子设备 |
-
2020
- 2020-11-20 CN CN202011306337.7A patent/CN112558784A/zh active Pending
-
2021
- 2021-11-16 WO PCT/CN2021/130961 patent/WO2022105754A1/zh not_active Ceased
Patent Citations (6)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN101661331A (zh) * | 2008-08-28 | 2010-03-03 | 北京搜狗科技发展有限公司 | 一种字词输入的方法和输入法系统 |
| WO2013029239A1 (zh) * | 2011-08-30 | 2013-03-07 | 宇龙计算机通信科技(深圳)有限公司 | 词库更新装置、输入系统和输入方法及终端 |
| CN104699809A (zh) * | 2015-03-20 | 2015-06-10 | 广东睿江科技有限公司 | 一种优选词库的控制方法及装置 |
| KR20180007183A (ko) * | 2016-07-12 | 2018-01-22 | (주) 리얼밸류 | 대표문자와 공백 입력을 통한 둘 이상의 단어로 구성된 문장입력방법 및 장치 |
| CN106933382A (zh) * | 2017-03-17 | 2017-07-07 | 北京小米移动软件有限公司 | 更新输入法词库的方法及装置 |
| CN112558784A (zh) * | 2020-11-20 | 2021-03-26 | 维沃移动通信有限公司 | 输入文字的方法、装置和电子设备 |
Also Published As
| Publication number | Publication date |
|---|---|
| CN112558784A (zh) | 2021-03-26 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| CN112631437B (zh) | 信息推荐方法、装置及电子设备 | |
| CN108369580B (zh) | 针对屏幕上项目选择的基于语言和域独立模型的方法 | |
| US8370143B1 (en) | Selectively processing user input | |
| US20170270092A1 (en) | System and method for predictive text entry using n-gram language model | |
| US20140214405A1 (en) | Character and word level language models for out-of-vocabulary text input | |
| WO2018045646A1 (zh) | 基于人工智能的人机交互方法和装置 | |
| CN107092424B (zh) | 一种纠错项的显示方法、装置和用于纠错项的显示的装置 | |
| CN110858100B (zh) | 联想候选词生成方法及装置 | |
| WO2022083750A1 (zh) | 文字显示方法、装置和电子设备 | |
| CN111898388A (zh) | 视频字幕翻译编辑方法、装置、电子设备及存储介质 | |
| WO2024036616A1 (zh) | 一种基于终端的问答方法及装置 | |
| CN112562684B (zh) | 一种语音识别方法、装置和电子设备 | |
| WO2021254251A1 (zh) | 输入显示方法、装置及电子设备 | |
| WO2022143341A1 (zh) | 输入法候选词显示方法、装置及电子设备 | |
| CN108292324A (zh) | 内容创作内联命令 | |
| CN112149403A (zh) | 一种确定涉密文本的方法和装置 | |
| CN107797676B (zh) | 一种单字输入方法及装置 | |
| CN112148135A (zh) | 输入法处理方法、装置和电子设备 | |
| WO2022105754A1 (zh) | 输入文字的方法、装置和电子设备 | |
| CN112383662B (zh) | 信息显示方法、装置和电子设备 | |
| WO2022135294A1 (zh) | 候选词显示方法及装置、电子设备 | |
| CN104731766A (zh) | 拼音文字词库构建方法和装置及输入方法和系统 | |
| CN112764734B (zh) | 代码编辑的辅助方法、装置及电子设备 | |
| CN113157966B (zh) | 显示方法、装置及电子设备 | |
| WO2024179519A1 (zh) | 语义识别方法及其装置 |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| 121 | Ep: the epo has been informed by wipo that ep was designated in this application |
Ref document number: 21893901 Country of ref document: EP Kind code of ref document: A1 |
|
| NENP | Non-entry into the national phase |
Ref country code: DE |
|
| 122 | Ep: pct application non-entry in european phase |
Ref document number: 21893901 Country of ref document: EP Kind code of ref document: A1 |
|
| 32PN | Ep: public notification in the ep bulletin as address of the adressee cannot be established |
Free format text: NOTING OF LOSS OF RIGHTS PURSUANT TO RULE 112(1) EPC (EPO FORM 1205A DATED 03.11.2023) |
|
| 122 | Ep: pct application non-entry in european phase |
Ref document number: 21893901 Country of ref document: EP Kind code of ref document: A1 |