WO2021254251A1 - 输入显示方法、装置及电子设备 - Google Patents

输入显示方法、装置及电子设备 Download PDF

Info

Publication number
WO2021254251A1
WO2021254251A1 PCT/CN2021/099439 CN2021099439W WO2021254251A1 WO 2021254251 A1 WO2021254251 A1 WO 2021254251A1 CN 2021099439 W CN2021099439 W CN 2021099439W WO 2021254251 A1 WO2021254251 A1 WO 2021254251A1
Authority
WO
WIPO (PCT)
Prior art keywords
word
input
target
candidate
string
Prior art date
Application number
PCT/CN2021/099439
Other languages
English (en)
French (fr)
Inventor
王杰
Original Assignee
维沃移动通信有限公司
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 维沃移动通信有限公司 filed Critical 维沃移动通信有限公司
Publication of WO2021254251A1 publication Critical patent/WO2021254251A1/zh

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
    • 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/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0484Interaction techniques based on graphical user interfaces [GUI] for the control of specific functions or operations, e.g. selecting or manipulating an object, an image or a displayed text element, setting a parameter value or selecting a range
    • G06F3/04847Interaction techniques to control parameter settings, e.g. interaction with sliders or dials

Definitions

  • This application belongs to the field of communication technology, and specifically relates to an input display method, device, and electronic equipment.
  • a user can input information into an electronic device through an input method, and during the use of the input method, the electronic device can record the words entered by the user, that is, the electronic device records the overall words input by the user on the screen, so as to facilitate the user When you enter the same overall word next time, you can directly display the overall word.
  • the electronic device will display the entire word only when the word corresponding to the input string entered by the user again is a historically inputted word.
  • the device has poor flexibility in displaying the words corresponding to the input character string input by the user.
  • the purpose of the embodiments of the present application is to provide an input display method, device, and electronic device, which can solve the problem that the electronic device has poor flexibility in displaying the word corresponding to the input character string input by the user.
  • an embodiment of the present application provides an input display method.
  • the input display method includes: receiving a user's first input of a target input character string; in response to the first input, selecting the target input from at least one preset word The target word corresponding to the character string, and at least one first candidate word including the target word is displayed, the at least one preset word is an entity word used in the user history stored in the electronic device, and the at least one first candidate word is related to the target word.
  • Input string correspondence includes: receiving a user's first input of a target input character string; in response to the first input, selecting the target input from at least one preset word The target word corresponding to the character string, and at least one first candidate word including the target word is displayed, the at least one preset word is an entity word used in the user history stored in the electronic device, and the at least one first candidate word is related to the target word.
  • Input string correspondence includes: receiving a user's first input of a target input character string; in response to the first input, selecting the target input from
  • an embodiment of the present application provides an input display device.
  • the input display device includes: a receiving module, a selection module, and a display module.
  • the receiving module is used to receive the user's first input of the target input character string.
  • the selection module is configured to select the target word corresponding to the target input string from at least one preset word in response to the first input received by the receiving module, and the at least one preset word is a user history stored in the electronic device. Entity words.
  • the display module is configured to display at least one first candidate word including the target word, and the at least one first candidate word corresponds to the target input character string.
  • an embodiment of the present application provides an electronic device that includes a processor, a memory, and a program or instruction that is stored on the memory and can run on the processor.
  • the program or instruction is The processor implements the steps of the method described in the first aspect when executed.
  • an embodiment of the present application provides a readable storage medium, on which a program or instruction is stored, and when the program or instruction is executed by a processor, the steps of the method described in 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 with the processor, and the processor is used to run a program or an instruction to implement the chip as in the first aspect The method described.
  • the electronic device may determine the target word corresponding to the target input character string from at least one preset word according to the user's first input to the target input character string, and display at least one first word that includes the target word.
  • the at least one first candidate word corresponds to the target input character string.
  • the electronic device can directly select the entity word corresponding to the target input character string (ie target word) from at least one preset entity word used by the user in the history, and display the selected target input character
  • the entity word corresponding to the string does not require the user to perform repeated screening operations on the candidate words, thereby improving the input efficiency of the user, and the electronic device has better flexibility in displaying the word corresponding to the input string input by the user.
  • FIG. 1 is one of the schematic diagrams of an input display method provided by an embodiment of the present application
  • FIG. 2 is a second schematic diagram of an input display method provided by an embodiment of the present application.
  • FIG. 3 is one of the schematic diagrams of an example of an interface of a mobile phone provided by an embodiment of the present application
  • FIG. 4 is a second schematic diagram of an example of an interface of a mobile phone provided by an embodiment of the present application.
  • FIG. 5 is the third schematic diagram of an input display method provided by an embodiment of the present application.
  • Fig. 6 is a fourth schematic diagram of an input display method provided by an embodiment of the present application.
  • FIG. 7 is a schematic structural diagram of an input display device provided by an embodiment of the present application.
  • FIG. 8 is a schematic structural diagram of an electronic device provided by an embodiment of the present application.
  • FIG. 9 is a schematic diagram of hardware of an electronic device provided by an embodiment of the present application.
  • first and second in the specification and claims of this application are used to distinguish similar objects, but not to describe a specific sequence or sequence. It should be understood that the data used in this way can be interchanged under appropriate circumstances, so that the embodiments of the present application can be implemented in an order other than those illustrated or described here, and the "first", “second”, etc. are distinguished
  • the objects are usually of one type, and the number of objects is not limited.
  • the first object may be one or multiple.
  • “and/or” in the description and claims means at least one of the connected objects, and the character “/” generally means that the associated objects before and after are in an "or” relationship.
  • FIG. 1 shows a flowchart of an input display method provided in an embodiment of the present application, and the method can be applied to an electronic device.
  • the input display method provided by the embodiment of the present application may include the following steps 201 and 202.
  • Step 201 The electronic device receives a user's first input of a target input character string.
  • the user can input the target input character string through the input method (Chinese input method) in the electronic device, so that the electronic device can display the word corresponding to the target input character string to the user.
  • the input method Choinese input method
  • the input string in the embodiment of the application can be understood as: pinyin, voice, strokes, etc. input by the user through the input method, and the electronic device can recognize the input string to obtain the Chinese corresponding to the input string word.
  • the above-mentioned input method may be any one of the following: pinyin input, voice input, handwriting input, stroke input, and so on.
  • the first interface when the electronic device displays the first interface, the first interface includes a character input area, and the user can perform the first input of the target input character string in the character input area.
  • the above-mentioned first interface may be a conversation interface of a chat application or a text input interface of a document application, etc.
  • the specifics can be determined according to actual usage requirements, and the embodiments of the present application do not make limitations here.
  • Step 202 In response to the first input, the electronic device selects a target word corresponding to the target input string from at least one preset word, and displays at least one first candidate word including the target word.
  • the aforementioned at least one preset word is an entity word that has been used in the user history stored in the electronic device, and the aforementioned at least one first candidate word corresponds to the target input character string.
  • the target word corresponding to the target input string includes: the target word corresponding to the overall target input string, and the target word corresponding to part of the target input string in the target input string, that is, the The target word corresponding to the target input character string includes at least part of the target word corresponding to the target input character string.
  • the user can select and input the target word, so that the electronic device determines the target word as the word on the screen, and displays other input strings (target input string Candidate words corresponding to the input character string other than the input character string corresponding to the target word) for the user to select.
  • target input string Candidate words corresponding to the input character string other than the input character string corresponding to the target word displayed on the screen.
  • the above-mentioned at least one preset word may be obtained by the electronic device through a preset model in advance after parsing and processing the on-screen word selected by the user in history.
  • the input display method provided in the embodiment of the present application further includes the following steps 301 to 304.
  • Step 301 The electronic device receives the user's second input of the first input character string.
  • step 301 reference may be made to the description of step 201, which will not be repeated here.
  • Step 302 In response to the second input, the electronic device displays at least one second candidate word corresponding to the first input character string.
  • the electronic device may first determine at least one candidate word corresponding to each character (for example, pinyin character, stroke character, etc.) in the first input string, and display the first input first The candidate words corresponding to the input character string at the top of the character string, and then after the user selects the word required by the user from the candidate words corresponding to these input character strings, the electronic device continues to display the candidate words corresponding to other input character strings, so that the user can The selection is carried out level by level to select the word required by the user corresponding to the first input string (that is, the word on the screen).
  • each character for example, pinyin character, stroke character, etc.
  • the words on the screen can be understood as: after the user can input the character string after the input, the electronic device displays the selected word from the candidate words corresponding to the input character string.
  • Step 303 The electronic device receives the third input of the user.
  • the aforementioned third input is the user's input to N candidate words in at least one second candidate word, and N is a positive integer.
  • the above-mentioned third input may include at least one sub-input, and each sub-input is a selection input for a candidate word, that is, an input for selecting a word on the screen, and each sub-input selected
  • the input character strings corresponding to the words on the upper screen are different (that is, each sub-input corresponds to a part of the input character string in the first input character string).
  • Step 304 In response to the third input, the electronic device selects N candidate words from the at least one second candidate word, and analyzes the N candidate words based on a preset model to obtain M entity words.
  • the aforementioned at least one predetermined word includes M entity words, and M is a positive integer less than or equal to N.
  • the electronic device may select N candidate words from at least one second candidate word according to the user's input, and after the user finishes clicking the candidate word on the screen through the input (for example, the third input), the electronic device may Input the entire on-screen word (which can be understood as a whole on-screen word or a whole sentence) into the preset model to parse out the entity words contained in the overall on-screen word through the preset model, and combine these entity words with The entire upper-screen words are input into the memory module of the input method to save these entity words and the entire upper-screen words.
  • the entire on-screen word which can be understood as a whole on-screen word or a whole sentence
  • the electronic device can parse out the corresponding entity words through the preset model, so as to save these entity words and the entire on-screen word in the memory module of the input method, so as to Get at least one presupposition word.
  • the aforementioned preset model may be a named entity recognition (Named Entity Recognition, NER) model, and the NER model may be built into the input method.
  • NER named Entity Recognition
  • NER model can also be called the "proprietary name recognition” model, which refers to the identification of entities with specific meanings in the text, including the names of persons, places, institutions, book names, song names, journal names, and proper nouns. And other entities.
  • the Pinyin input method is taken as an example for description here.
  • the user can input "zhezhoumoheduanhaidiyiqiqulongyangshanzhuangdujiaba" through the Pinyin input method, and gradually filter “this/weekend/he/duan/hai/di/go together/long/yang/shanzhuang/vacation bar" through multi-level candidates, forming a whole sentence at once Screen.
  • the electronic device can add the whole sentence and input it into the NER model, so that the NER model can detect the name entity "Duan Haidi” and the location entity “Longyang Villa” contained therein, and Input the name entity, place entity, and the whole sentence into the memory module, so that the memory module will memorize these two entity words while memorizing the whole sentence.
  • the electronic device can optimize the memory strategy of the input method. In addition to memorizing the overall words on the screen, it also memorizes some entity words with clear meanings in the overall words, so that the user can use it again next time. When inputting these entity words, there is no need to select them one by one, so it has higher input efficiency.
  • the input display method provided in the embodiment of the present application further includes the following steps 401 and 402.
  • Step 401 The electronic device receives the fourth input of the user.
  • the above-mentioned fourth input is the user's input to multiple corpus data and multiple tagging information.
  • Each corpus data corresponds to a piece of tagging information, and each tagging information is used to indicate the entity word to which a piece of corpus data belongs. category.
  • a piece of corpus data may be an entity word, or may also be text content including entity words.
  • the entity word category may include at least one of the following categories: person name, place name, institution name, book name, song name, journal name, proper nouns, etc.
  • Step 402 In response to the fourth input, the electronic device uses a preset algorithm to train multiple pieces of corpus data and multiple pieces of label information to obtain a preset model.
  • the foregoing preset algorithm may be any one of the following: a rule-based method, a feature template-based method, a neural network-based method, and a BiLSTM-CRF algorithm.
  • the electronic device can pass the preset algorithm.
  • the algorithm builds the NER model.
  • BiLSTM-CRF is a relatively mature method. It does not require feature engineering and can achieve the effect by using character vectors. Electronic devices can use some corpus data with entity annotations, using BiLSTM-CRF Method to build a NER model.
  • rule-based method refers to the use of hand-written rules to match text with rules to identify named entities.
  • the method based on feature template refers to some binary feature functions that are manually defined, trying to dig out the characteristics of the structure of the named entity and the context.
  • the neural network-based method uses neural network to automatically extract features. This method makes the training of the model an end-to-end overall process.
  • step 202 may be specifically implemented by the following step 202a or step 202b.
  • Step 202a The electronic device responds to the first input, and if the target input string matches the input string corresponding to the first word in the at least one preset word, the first word is determined as the target word, and displays that include the target word At least one first candidate word.
  • the electronic device may preferentially display the first word.
  • the electronic device may display the first word in a position before other candidate words corresponding to the target input character string.
  • the electronic device is a mobile phone as an example for description.
  • the electronic device can match the target input string with at least one preset word.
  • the target input string matches one of the at least one preset word
  • the electronic device can display "Longyang Villa” in the position before other candidate words (such as "Longyang Villa", " ⁇ ”, etc.) corresponding to the target input string ( That is, the position of the first candidate word in at least one first candidate word), that is, "Longyang Villa” is displayed in the first position, so that the user can select the word on the screen.
  • the first word may be a word corresponding to the overall target input string.
  • Step 202b In response to the first input, the electronic device determines the second word as the target word if the prefix input string in the target input string matches the input string corresponding to the second word in the at least one preset word. And display at least one first candidate word including the target word.
  • the above-mentioned prefix input character string is a part of the input character string having a corresponding entity word in the target input character string, that is, the part of the target input character string corresponds to the second word.
  • the aforementioned prefix input character string may be a partial input character string that has a corresponding entity word in the target input character string and is located at a higher position.
  • the electronic device may preferentially display the second word.
  • the electronic device may display the second word in a position before the multi-level candidate word corresponding to the target input character string.
  • the electronic device displays the target word corresponding to the prefix input character string
  • the user can select and input the target word, so that the electronic device determines the target word as the word on the screen, and the target word is determined one by one.
  • the level displays the candidate words corresponding to the input string before the prefix input string.
  • the mobile phone can gradually filter, that is, determine the entire sentence as "Duanhaidi/just in/Longyang Shanzhuang/near", and set the target The input string is matched with at least one preset word.
  • the mobile phone can read " ⁇ " Displayed in the position before the multi-level candidate words (such as “short”, “terminal”, etc.) corresponding to the target input string, and after the user selects and enters "Duan Haidi", the mobile phone can continue to display the input string "jiuzai" Corresponding candidate words (such as “just in”, “just”, “ ⁇ "), and after the user selects and inputs "just in”, the candidate word " ⁇ ” corresponding to the input string “longyangshanzhuang” can continue to be displayed ", and so on, until all candidate words corresponding to the input string are selected.
  • a named entity recognition model is added to the input method to perform named entity recognition on the overall on-screen words, and these entities are also memorized on the basis of memorizing the overall on-screen words. In this way, when the user inputs these entity words in the subsequent input operation, these entity words are given in the candidate words, which prevents the user from performing repeated screening operations and improves the input efficiency of the user.
  • the above-mentioned target word is the first word.
  • the above-mentioned step 202 may be specifically implemented by the following step 202c.
  • Step 202c In response to the first input, the electronic device determines the target word corresponding to the target input string from the at least one preset word, and displays the first word and other first candidate words in the target order.
  • the above-mentioned target sequence is the position of the first word in the first candidate word among at least one first candidate word, and the above-mentioned other first candidate words are at least one first candidate word other than the first word Candidate words.
  • the electronic device can match the target input character string with at least one preset word to quickly determine the corresponding entity word from the preset word, so as to display these words in the front position so that To make a selection by the user, that is, to improve the efficiency of user input.
  • the above-mentioned target word is the second word.
  • the foregoing step 202 may be specifically implemented by the following step 202d.
  • Step 202d In response to the first input, the electronic device determines the target word corresponding to the target input string from at least one preset word, and displays the overall word and the second word corresponding to the target input string in the first order And other first candidates.
  • the above-mentioned first order is that the overall word is located at the position of the first candidate word among at least one first candidate word, and the second word is located at the position of the second candidate word among at least one first candidate word ,
  • the overall word is the entire candidate word to be displayed on the screen composed of words corresponding to the target input string, and the other first candidate words are candidate words other than the overall word and the second word among the at least one first candidate word.
  • the electronic device can display the whole word at the position of the first candidate word, and then display the whole word at the position of the first candidate word.
  • the position of the two candidate words displays the target word corresponding to the part of the input string, and other first candidate words are displayed in other positions.
  • the electronic device memorizes some entity words in the words on the screen one or more times by the user.
  • the electronic device can also memorize it. For example, if the user enters “segment”, “sea”, “di”, “just in”, “long”, “yang”, “shanzhuang”, “near”, the electronic device can recognize the “segment” through the NER model , “Hai” and “Di” can form a person's name “Duan Huan Di", and “Long”, “Yang” and “Shan Zhuang” can be combined into a place name “Longyang Mountain Villa”. Increase the user's input efficiency in the user's subsequent input.
  • An embodiment of the present application provides an input display method.
  • the electronic device can determine the target word corresponding to the target input string from at least one preset word according to the user's first input to the target input string, and display the target word that includes the target word At least one first candidate word, and the at least one first candidate word corresponds to the target input character string.
  • the electronic device can directly select the entity word corresponding to the target input character string (ie target word) from at least one preset entity word used by the user in the history, and display the selected target input character
  • the entity word corresponding to the string does not require the user to perform repeated screening operations on the candidate words, thereby improving the input efficiency of the user, and the electronic device has better flexibility in displaying the word corresponding to the input string input by the user.
  • the execution subject of the input display method provided in the embodiments of the present application may be an input display device, or a control module for executing the input display method in the input display device.
  • an input display method executed by the input display device is taken as an example to illustrate the input display device provided in the embodiment of the present application.
  • FIG. 7 shows a schematic diagram of a possible structure of the input display device involved in the embodiment of the present application.
  • the input display device 70 may include: a receiving module 71, a selection module 72 and a display module 73.
  • the receiving module 71 is configured to receive the user's first input of the target input character string.
  • the selecting module 72 is configured to select a target word corresponding to the target input string from at least one preset word in response to the first input received by the receiving module 71, and the at least one preset word is a user history stored in the electronic device.
  • the display module 73 is configured to display at least one first candidate word including the target word, and the at least one first candidate word corresponds to the target input character string.
  • the above-mentioned receiving module 71 is further configured to receive the user's second input of the first input character string before receiving the user's first input of the target input character string.
  • the display module 73 is further configured to display at least one second candidate word corresponding to the first input string in response to the second input received by the receiving module 71.
  • the above-mentioned receiving module 71 is also used to receive the third input of the user.
  • the aforementioned selection module 72 is further configured to select N candidate words from the at least one second candidate word in response to the third input received by the receiving module 71.
  • the input display device 70 provided by the embodiment of the present application further includes a processing module.
  • the processing module is configured to analyze and process the N candidate words selected by the selection module 72 based on the preset model to obtain M entity words.
  • the above-mentioned at least one preset word includes M entity words, and M is less than or equal to N is a positive integer, and N is a positive integer.
  • the above-mentioned receiving module 71 is further configured to receive a user's fourth input before receiving the user's second input of the first input character string, where the fourth input is the user's input to multiple corpus data
  • each piece of corpus data corresponds to one piece of tagging information
  • each piece of tagging information is used to indicate the entity word category to which one piece of corpus data belongs.
  • the input display device 70 provided in the embodiment of the present application further includes a training module. Among them, the training module is used to respond to the fourth input received by the receiving module 71 and use a preset algorithm to train multiple corpus data and multiple annotation information to obtain a preset model.
  • the aforementioned selection module 72 is specifically configured to determine the first word as the target word if the target input string matches the input string corresponding to the first word in the at least one preset word; Or, if the prefix input string in the target input string matches the input string corresponding to the second word in at least one preset word, the second word is determined as the target word, and the prefix input string is the target input character Part of the input string with corresponding entity words in the string.
  • the above-mentioned target word is the first word.
  • the above-mentioned display module 73 is specifically configured to display the first word and other first candidate words in a target order, where the target order is the position of the first word in the first candidate word among at least one first candidate word, and the other first candidate words
  • Candidate words are candidate words other than the first word in at least one first candidate word.
  • the above-mentioned target word is the second word.
  • the above-mentioned display module 73 is specifically configured to display the overall word, the second word, and other first candidate words corresponding to the target input string in a first order, where the overall word is located in the first candidate word among at least one first candidate word.
  • the position of the candidate word, and the second word is located at the position of the second candidate word in at least one of the first candidate words, the overall word is the entire candidate word to be displayed on the screen composed of the words corresponding to the target input string
  • a candidate word is a candidate word excluding the overall word and the second word among at least one first candidate word.
  • the embodiment of the present application provides an input display device. After the user enters the target input character string, the electronic device can directly select the entity word corresponding to the target input character string from at least one preset entity word used by the user in history (ie Target word), and display the entity word corresponding to the selected target input string, without requiring the user to perform repeated screening operations on candidate words, thus improving the input efficiency of the user, so that the electronic device displays the word corresponding to the input string input by the user The flexibility is better.
  • the input display device in the embodiment of the present application may be a device, or a component, integrated circuit, or chip in a terminal.
  • the device can 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 handheld computer, a vehicle-mounted 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 (personal digital assistant).
  • non-mobile electronic devices can be servers, network attached storage (NAS), personal computers (PC), televisions (television, TV), teller machines or self-service machines, etc., this application
  • NAS network attached storage
  • PC personal computers
  • TV televisions
  • teller machines or self-service machines etc.
  • the input display device in the embodiment of the present application may be a device with an operating system.
  • the operating system may be an Android operating system, an ios operating system, or other possible operating systems, which are not specifically limited in the embodiment of the present application.
  • the input display device provided by the embodiment of the present application can implement the various processes implemented by the foregoing method embodiment, and in order to avoid repetition, details are not described herein again.
  • an embodiment of the present application further provides an electronic device 90, including a processor 91, a memory 92, and a program or instruction that is stored in the memory 92 and can run on the processor 91,
  • the program or instruction is executed by the processor 91, each process of the foregoing method embodiment is realized, and the same technical effect can be achieved. In order to avoid repetition, it will not be repeated here.
  • the electronic devices in the embodiments of the present application include the above-mentioned mobile electronic devices and non-mobile electronic devices.
  • FIG. 9 is a schematic diagram of the hardware structure of an electronic device that implements 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, a processor 110, etc. part.
  • the electronic device 100 may also include a power source (such as a battery) for supplying power to various components.
  • 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.
  • the structure of the electronic device shown in FIG. 9 does not constitute a limitation on the electronic device.
  • the electronic device may include more or less components than those shown in the figure, or some components may be combined, or different component arrangements, which will not be repeated here. .
  • the user input unit 107 is configured to receive the user's first input of the target input character string.
  • the processor 110 is configured to, in response to the first input, select a target word corresponding to the target input string from at least one preset word, the at least one preset word being a physical word used by the user in the electronic device's history.
  • the display unit 106 is configured to display at least one first candidate word including the target word, and the at least one first candidate word corresponds to the target input character string.
  • the embodiment of the present application provides an electronic device. After the user inputs the target input string, the electronic device can directly select the entity word (ie target word) corresponding to the target input string from at least one preset entity word, and display The selected entity word corresponding to the target input string does not require the user to perform repeated screening operations on the candidate words, thereby improving the input efficiency of the user, and the electronic device has better flexibility in displaying the word corresponding to the input string input by the user.
  • entity word ie target word
  • the user input unit 107 is further configured to receive the user's second input of the first input character string before receiving the user's first input of the target input character string.
  • the display unit 106 is further configured to display at least one second candidate word corresponding to the first input string in response to the second input.
  • the user input unit 107 is also used to receive a third input from the user.
  • the processor 110 is further configured to select N candidate words from at least one second candidate word in response to the third input, and analyze the N candidate words based on a preset model to obtain M entity words.
  • At least one predetermined word includes M entity words, M is a positive integer less than or equal to N, and N is a positive integer.
  • the input unit 104 may include a graphics processing unit (GPU) 1041 and a microphone 1042.
  • the graphics processor 1041 is paired by the image capture device ( For example, the image data of the still picture or video obtained by the camera) is processed.
  • the display unit 106 may include a display panel 1061, and the display panel 1061 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, a physical keyboard, function keys (such as volume control buttons, switch buttons, etc.), trackball, mouse, and joystick, which will not be repeated here.
  • the memory 109 may be used to store software programs and various data, including but not limited to application programs and operating systems.
  • the processor 110 may integrate an application processor and a modem processor, where the application processor mainly processes an operating system, a user interface, and an application program, and the modem processor mainly processes wireless communication. It can be understood that the foregoing modem processor may not be integrated into the processor 110.
  • the embodiments of the present application also provide a readable storage medium with a program or instruction stored on the readable storage medium.
  • the program or instruction is executed by a processor, each process of the foregoing method embodiment is implemented, and the same technology can be achieved. The effect, in order to avoid repetition, will not be repeated here.
  • the processor is the processor in the electronic device described in the foregoing embodiment.
  • the readable storage medium includes a computer readable storage medium, such as a computer read-only memory (Read-Only Memory, ROM), random access memory (Random Access Memory, RAM), magnetic disks, or optical disks.
  • An embodiment of the present application further provides a chip, the chip includes a processor and a communication interface, the communication interface is coupled to the processor, and the processor is used to run a program or an instruction to implement each process of the above method embodiment , And can achieve the same technical effect, in order to avoid repetition, I will not repeat it here.
  • chips mentioned in the embodiments of the present application may also be referred to as system-level chips, system-on-chips, system-on-chips, or system-on-chips.
  • the technical solution of this application essentially or the part that contributes to the existing technology can be embodied in the form of a software product, and the computer software product is stored in a storage medium (such as ROM/RAM, magnetic disk, The optical disc) includes several instructions to make a terminal (which can 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 the present application.
  • a terminal which can be a mobile phone, a computer, a server, an air conditioner, or a network device, etc.

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)
  • Machine Translation (AREA)
  • User Interface Of Digital Computer (AREA)

Abstract

本申请公开了一种输入显示方法、装置及电子设备,该方法包括:接收用户对目标输入字符串的第一输入;响应于第一输入,从至少一个预设词中选取目标输入字符串对应的目标词,并显示包括目标词的至少一个第一候选词,至少一个预设词为电子设备中已存储的用户历史使用过的实体词,至少一个第一候选词与目标输入字符串对应。

Description

输入显示方法、装置及电子设备
相关申请的交叉引用
本申请主张在2020年06月15日在中国提交的中国专利申请号202010544431.X的优先权,其全部内容通过引用包含于此。
技术领域
本申请属于通信技术领域,具体涉及一种输入显示方法、装置及电子设备。
背景技术
通常,用户可以通过输入法将信息录入到电子设备中,并且在输入法的使用过程中,电子设备可以记录用户输入过的词语,即电子设备会记录用户输入的上屏整体词,以便于用户在下次输入相同的整体词时,可以直接显示该整体词。
然而,由于输入法只记录了上次输入的上屏整体词,因此只有当用户再次输入的输入字符串对应的词为历史输入过的整体词时,电子设备才会显示该整体词,因此电子设备显示用户输入的输入字符串对应的词的灵活性较差。
发明内容
本申请实施例的目的是提供一种输入显示方法、装置及电子设备,能够解决电子设备显示用户输入的输入字符串对应的词的灵活性较差的问题。
为了解决上述技术问题,本申请是这样实现的:
第一方面,本申请实施例提供了一种输入显示方法,该输入显示方法包括:接收用户对目标输入字符串的第一输入;响应于第一输入,从至少一个预设词中选取目标输入字符串对应的目标词,并显示包括目标词的至少一个第一候选词,该至少一个预设词为电子设备中已存储的用户历史使用过的实体词,该至少一个第一候选词与目标输入字符串对应。
第二方面,本申请实施例提供了一种输入显示装置,该输入显示装置包括:接收 模块、选取模块和显示模块。其中,接收模块,用于接收用户对目标输入字符串的第一输入。选取模块,用于响应于接收模块接收的第一输入,从至少一个预设词中选取目标输入字符串对应的目标词,该至少一个预设词为电子设备中已存储的用户历史使用过的实体词。显示模块,用于显示包括目标词的至少一个第一候选词,该至少一个第一候选词与目标输入字符串对应。
第三方面,本申请实施例提供了一种电子设备,该电子设备包括处理器、存储器及存储在所述存储器上并可在所述处理器上运行的程序或指令,所述程序或指令被所述处理器执行时实现如第一方面所述的方法的步骤。
第四方面,本申请实施例提供了一种可读存储介质,所述可读存储介质上存储程序或指令,所述程序或指令被处理器执行时实现如第一方面所述的方法的步骤。
第五方面,本申请实施例提供了一种芯片,所述芯片包括处理器和通信接口,所述通信接口和所述处理器耦合,所述处理器用于运行程序或指令,实现如第一方面所述的方法。
在本申请实施例中,电子设备可以根据用户对目标输入字符串的第一输入,从至少一个预设词中确定目标输入字符串对应的目标词,并显示包括该目标词的至少一个第一候选词,该至少一个第一候选词与目标输入字符串对应。由于用户在输入目标输入字符串之后,电子设备可以直接从用户历史使用过的至少一个预设实体词中选取与目标输入字符串对应的实体词(即目标词),并显示选取的目标输入字符串对应的实体词,而无需用户对候选词进行重复的筛选操作,因此提高了用户的输入效率,从而电子设备显示用户输入的输入字符串对应的词的灵活性较好。
附图说明
图1是本申请实施例提供的一种输入显示方法的示意图之一;
图2是本申请实施例提供的一种输入显示方法的示意图之二;
图3是本申请实施例提供的一种手机的界面的实例示意图之一;
图4是本申请实施例提供的一种手机的界面的实例示意图之二;
图5是本申请实施例提供的一种输入显示方法的示意图之三;
图6是本申请实施例提供的一种输入显示方法的示意图之四;
图7是本申请实施例提供的一种输入显示装置的结构示意图;
图8是本申请实施例提供的一种电子设备的结构示意图;
图9是本申请实施例提供的一种电子设备的硬件示意图。
具体实施方式
下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例是本申请一部分实施例,而不是全部的实施例。基于本申请中的实施例,本领域普通技术人员在没有作出创造性劳动前提下所获得的所有其他实施例,都属于本申请保护的范围。
本申请的说明书和权利要求书中的术语“第一”、“第二”等是用于区别类似的对象,而不用于描述特定的顺序或先后次序。应该理解这样使用的数据在适当情况下可以互换,以便本申请的实施例能够以除了在这里图示或描述的那些以外的顺序实施,且“第一”、“第二”等所区分的对象通常为一类,并不限定对象的个数,例如第一对象可以是一个,也可以是多个。此外,说明书以及权利要求中“和/或”表示所连接对象的至少其中之一,字符“/”,一般表示前后关联对象是一种“或”的关系。
下面结合附图,通过具体的实施例及其应用场景对本申请实施例提供的输入显示方法进行详细地说明。
本申请实施例提供一种输入显示方法,图1示出了本申请实施例提供的一种输入显示方法的流程图,该方法可以应用于电子设备。如图1所示,本申请实施例提供的输入显示方法可以包括下述的步骤201和步骤202。
步骤201、电子设备接收用户对目标输入字符串的第一输入。
本申请实施例中,用户可以在电子设备中通过输入法(中文输入法)输入目标输入字符串,以使得电子设备可以向用户展示目标输入字符串对应的词。
需要说明的是,本申请实施例中的输入字符串可以理解为:用户通过输入法输入的拼音、语音、笔画等,电子设备可以对输入字符串进行识别,以获取与输入字符串对应的中文词。
可选地,本申请实施例中,上述输入法可以为以下任一项:拼音输入、语音输入、手写输入和笔画输入等。
可选地,本申请实施例中,在电子设备显示第一界面的情况下,该第一界面中包括字符输入区域,用户可以在该字符输入区域对目标输入字符串进行第一输入。
可选地,本申请实施例中,上述第一界面可以为聊天类应用程序的会话界面或文档类应用程序的文字输入界面等。具体的可以根据实际使用需求确定,本申请实施例在此不做限制。
步骤202、电子设备响应于第一输入,从至少一个预设词中选取目标输入字符串对应的目标词,并显示包括目标词的至少一个第一候选词。
本申请实施例中,上述至少一个预设词为电子设备中已存储的用户历史使用过的实体词,上述至少一个第一候选词与目标输入字符串对应。
需要说明的是,该目标输入字符串对应的目标词,包括:整体的目标输入字符串对应的目标词,以及目标输入字符串中的部分目标输入字符串对应的目标词,也就是说,该目标输入字符串对应的目标词包括至少部分目标输入字符串对应的目标词。
本申请实施例中,电子设备在显示目标词之后,用户可以对目标词进行选择输入,以是得电子设备将目标词确定为上屏词,并逐级显示其他输入字符串(目标输入字符串中除目标词对应的输入字符串之外的输入字符串)对应的候选词,以供用户进行选择。
可选地,本申请实施例中,上述至少一个预设词可以为电子设备预先通过预设模型,对用户历史选择过的上屏词进行解析处理之后得到的。
可选地,本申请实施例中,结合图1,如图2所示,在上述步骤201之前,本申请实施例提供的输入显示方法还包括下述的步骤301至步骤304。
步骤301、电子设备接收用户对第一输入字符串的第二输入。
需要说明的是,上述第一输入字符串可以与上述目标输入字符串相同或不同。针对步骤301的说明可以参考上述步骤201的描述,此处不再赘述。
步骤302、电子设备响应于第二输入,显示第一输入字符串对应的至少一个第二候选词。
本申请实施例中,电子设备在接收到第二输入之后,可以先确定第一输入字符串中每个字符(例如拼音字符、笔画字符等)对应的至少一个候选词,并先显示第一输入字符串中靠前位置的输入字符串对应的候选词,然后在用户从这些输入字符串对应的候选词选择 用户需求的词之后,电子设备继续显示其他输入字符串对应的候选词,从而用户可以逐级进行选择,以选定第一输入字符串对应的用户需求的词(即上屏词)。
需要说明的是,上屏词可以理解为:用户在输入完后才能输入字符串之后,从电子设备显示输入字符串对应的候选词中选定的词。
步骤303、电子设备接收用户的第三输入。
本申请实施例中,上述第三输入为用户对至少一个第二候选词中的N个候选词的输入,N为正整数。
可选地,本申请实施例中,上述第三输入可以包括至少一个子输入,每个子输入分别为对一个候选词的选择输入,即选定上屏词的输入,且每个子输入选定的上屏词对应的输入字符串不同(即每个子输入分别对应第一输入字符串中的一部分输入字符串)。
步骤304、电子设备响应于第三输入,从至少一个第二候选词中选取N个候选词,并基于预设模型,对N个候选词进行解析处理,以得到M个实体词。
本申请实施例中,上述至少一个预设词包括M个实体词,M为小于或等于N的正整数。
本申请实施例中,电子设备可以根据用户的输入,从至少一个第二候选词中选取N个候选词,并在用户通过输入(例如第三输入)完成点击候选词上屏之后,电子设备可以将整个上屏词(可以理解为一个整体上屏词或整句文字)输入到预设模型中,以通过预设模型解析出整体上屏词中包含有的实体词,并将这些实体词和整个上屏词输入到输入法的记忆模块中,以保存这些实体词和整个上屏词。
可以理解,在用户每次完成点击候选词上屏之后,电子设备均可以通过预设模型解析出相应的实体词,以在输入法的记忆模块中保存这些实体词和整个上屏词,从而以得到至少一个预设词。
可选地,本申请实施例中,上述预设模型可以为命名实体识别(Named Entity Recognition,NER)模型,该NER模型可以内置到输入法中。
需要说明的是,NER模型又可以称作“专名识别”模型,是指识别文本中具有特定意义的实体,主要包括人名、地名、机构名、书名、歌曲名、期刊名、专有名词等实体。
示例性的,此处以拼音输入法为例进行说明。用户可以通过拼音输入法输入 “zhezhoumoheduanhaidiyiqiqulongyangshanzhuangdujiaba”,通过多级候选,逐步筛选“这/周末/和/段/海/迪/一起去/隆/阳/山庄/度假吧”,组成了整句一次上屏。在用户进行上屏选定操作之后,电子设备可以加个该整句话输入到NER模型中,以使得NER模型可以检测出其中包含的人名实体“段海迪”和地点实体“隆阳山庄”,并将人名实体、地点实体以及整句话输入到记忆模块中,以使得记忆模块在记忆整句话的同时也会记忆这两个实体词。
本申请实施例中,电子设备可以通过优化输入法的记忆策略,除了对上屏的整体词进行记忆之外,也对整体词中具有明确含义的一些实体词进行记忆,以便于用户下次再输入这些实体词时,无需单独逐一选定,因此具有更高的输入效率。
可选地,本申请实施例中,在上述步骤301之前,本申请实施例提供的输入显示方法还包括下述的步骤401和步骤402。
步骤401、电子设备接收用户的第四输入。
本申请实施例中,上述第四输入为用户对多个语料数据和多个标注信息的输入,每个语料数据分别对应一个标注信息,每个标注信息分别用于指示一个语料数据所属的实体词类别。
需要说明的是,一个语料数据可以为一个实体词,或者也可以为包括实体词的文字内容。
可选地,本申请实施例中,实体词类别可以包括以下至少一项:人名、地名、机构名、书名、歌曲名、期刊名和专有名词等类别。
步骤402、电子设备响应于第四输入,采用预设算法,对多个语料数据和多个标注信息进行训练,以得到预设模型。
可选地,本申请实施例中,上述预设算法可以为以下任一项:基于规则的方法、基于特征模版的方法、基于神经网络的方法和基于BiLSTM-CRF算法,电子设备可以通过该预设算法构建NER模型。
可选地,本申请实施例中,BiLSTM-CRF是一个较为成熟的方法,它不需要特征工程,使用字符向量就可以达到效果,电子设备可以使用一些具有实体标注的语料数据,采用BiLSTM-CRF方法构建一个NER模型。
需要说明的是,基于规则的方法是指利用手工编写的规则,将文本与规则进行匹配来识别出命名实体。基于特征模版的方法是指人工定义的一些二值特征函数,试图挖掘命名实体内部以及上下文的构成特点。基于神经网络的方法是用神经网络自动提取特征,这种方法使得模型的训练成为一个端到端的整体过程。
可选地,本申请实施例中,上述步骤202具体可以通过下述的步骤202a或步骤202b实现。
步骤202a、电子设备响应于第一输入,若目标输入字符串与至少一个预设词中的第一词对应的输入字符串匹配,则将第一词确定为目标词,并显示包括目标词的至少一个第一候选词。
本申请实施例中,若目标输入字符串可以匹配命中至少一个预设词(NER实体记忆词)中的某个词(例如第一词),则电子设备可以优先显示该第一词。
可选地,本申请实施例中,电子设备可以将第一词显示在目标输入字符串对应的其他候选词之前的位置。
示例性的,以电子设备为手机为例进行说明。如图3所示,用户在输入目标输入字符串“longyangshanzhuang”之后,电子设备可以将该目标输入字符串与至少一个预设词进行匹配,当目标输入字符串与至少一个预设词中的一个词(例如“隆阳山庄”)相匹配时,电子设备可以将“隆阳山庄”显示在目标输入字符串对应的其他候选词(例如“龙阳山庄”、“龙”等)之前的位置(即至少一个第一候选词中的第一个候选词的位置),即将“隆阳山庄”显示在第一个位置,以便用户进行选定上屏词。需要说明的是,该第一词可以是整体目标输入字符串对应的词。
步骤202b、电子设备响应于第一输入,若目标输入字符串中的前缀输入字符串与至少一个预设词中的第二词对应的输入字符串匹配,则将第二词确定为目标词,并显示包括目标词的至少一个第一候选词。
本申请实施例中,上述前缀输入字符串为目标输入字符串中具有对应的实体词的部分输入字符串,也就是,部分目标输入字符串对应第二词。
可选地,本申请实施例中,上述前缀输入字符串可以为目标输入字符串中具有对应的实体词、且处于靠前位置的部分输入字符串。
本申请实施例中,若目标输入字符串可以前缀匹配命中至少一个预设词中的某个词(例如第二词),则电子设备可以优先显示该第二词。
可选地,本申请实施例中,电子设备可以将第二词显示在目标输入字符串对应的多级候选词之前的位置。
可选地,本申请实施例中,在电子设备显示前缀输入字符串对应的目标词之后,用户可以对该目标词进行选择输入,以使得电子设备将该目标词确定为上屏词,并逐级显示除前缀输入字符串之前的输入字符串对应的候选词。
示例性的,如图4所示,用户在输入目标输入字符串“duanhhaidijiuzailongyangshanzhuangfujin”之后,手机可以进行逐步筛选,即确定整句为“段海迪/就在/隆阳山庄/附近”,并将该目标输入字符串与至少一个预设词进行匹配,在确定目标输入字符串的前缀输入字符串“duanhhaidi”与至少一个预设词中的第二词“段海迪”相匹配时,手机可以将“段海迪”显示在目标输入字符串对应的多级候选词(例如“短”、“端”等)之前的位置,并且,在用户对“段海迪”进行选择输入之后,手机可以继续显示输入字符串“jiuzai”对应的候选词(例如“就在”、“就”、“在”),并在用户对“就在”进行选择输入之后,可以继续显示输入字符串“longyangshanzhuang”对应的候选词“隆阳山庄”,以此类推,直至选定所有输入字符串对应的候选词。通过本申请的方案,用户只需要进行四次点选,并且“段海迪”和“隆阳山庄”都会被展示在靠前的位置。相比于只有整体记忆的方案,用户需要进行“段/海/迪/就在/隆/阳/山庄/附近”,共需要进行八次点选,本申请的方案可以提高用户输入的效率。
本申请实施例中,通过在输入法中增加命名实体识别模型,对整体上屏词进行命名实体识别,在记忆整体上屏词的基础上也对这些实体进行记忆。这样用户可以在后续输入操作中输入这些实体词时,候选词中给出这些实体词,避免用户进行重复的筛选操作,提高用户输入效率。
可选地,本申请实施例中,上述目标词为第一词。结合图1,如图5所示,上述步骤202具体可以通过下述的步骤202c实现。
步骤202c、电子设备响应于第一输入,从至少一个预设词中确定目标输入字符串对应的目标词,并按照目标顺序显示第一词和其他第一候选词。
本申请实施例中,上述目标顺序为第一词位于至少一个第一候选词中的第一个候选词的位置,上述其他第一候选词为至少一个第一候选词中除第一词之外的候选词。
本申请实施例中,电子设备可以将目标输入字符串与至少一个预设词进行匹配,以快速地从预设词中确定出相应的实体词,从而将这些词展示在靠前的位置,以便于用户进行选定,即提高用户输入的效率。
可选地,本申请实施例中,上述目标词为第二词。结合图1,如图6所示,上述步骤202具体可以通过下述的步骤202d实现。
步骤202d、电子设备响应于第一输入,从至少一个预设词中确定目标输入字符串对应的目标词,并按照第一顺序显示所述目标输入字符串对应的整体词、所述第二词和其他第一候选词。
本申请实施例中,上述第一顺序为整体词位于至少一个第一候选词中的第一个候选词的位置、且第二词位于至少一个第一候选词中的第二个候选词的位置,整体词为目标输入字符串对应的词组成的整个待上屏候选词,其他第一候选词为至少一个第一候选词中除整体词和第二词之外的候选词。
可以理解,在目标词为目标输入字符串中的部分输入字符串(例如前缀输入字符串)对应的词的情况下,电子设备可以在第一个候选词的位置显示整体词,然后再在第二个候选词的位置显示该部分输入字符串对应的目标词,并在其他位置显示其他第一候选词。
本申请实施例中,电子设备针对用户一次或多次上屏词中部分实体词进行记忆,当用户多次输入的词组合起来可以构成一个实体,电子设备也可以进行记忆。例如,用户分别输入了“段”、“海”、“迪”、“就在”、“隆”、“阳”、“山庄”、“附近”,电子设备可以通过NER模型识别到“段”、“海”、“迪”可以组成一个人名“段还迪”,“隆”、“阳”、“山庄”可以组合成一个地名“隆阳山庄”,对这两个实体词进行记忆,从而在用户后续输入中增加用户的输入效率。
本申请实施例提供一种输入显示方法,电子设备可以根据用户对目标输入字符串的第一输入,从至少一个预设词中确定目标输入字符串对应的目标词,并显示包括该目标词的至少一个第一候选词,该至少一个第一候选词与目标输入字符串对应。由于用户在输入目标输入字符串之后,电子设备可以直接从用户历史使用过的至少一个预设实体词中选取与 目标输入字符串对应的实体词(即目标词),并显示选取的目标输入字符串对应的实体词,而无需用户对候选词进行重复的筛选操作,因此提高了用户的输入效率,从而电子设备显示用户输入的输入字符串对应的词的灵活性较好。
需要说明的是,本申请实施例提供的输入显示方法,执行主体可以为输入显示装置,或者该输入显示装置中的用于执行输入显示方法的控制模块。本申请实施例中以输入显示装置执行输入显示方法为例,说明本申请实施例提供的输入显示装置。
图7示出了本申请实施例中涉及的输入显示装置的一种可能的结构示意图。如图7所示,该输入显示装置70可以包括:接收模块71、选取模块72和显示模块73。
其中,接收模块71,用于接收用户对目标输入字符串的第一输入。选取模块72,用于响应于接收模块71接收的第一输入,从至少一个预设词中选取目标输入字符串对应的目标词,至少一个预设词为电子设备中已存储的用户历史使用过的实体词。显示模块73,用于显示包括目标词的至少一个第一候选词,至少一个第一候选词与目标输入字符串对应。
在一种可能的实现方式中,上述接收模块71,还用于在接收用户对目标输入字符串的第一输入之前,接收用户对第一输入字符串的第二输入。显示模块73,还用于响应于接收模块71接收的第二输入,显示第一输入字符串对应的至少一个第二候选词。上述接收模块71,还用于接收用户的第三输入。上述选取模块72,还用于响应于接收模块71接收的第三输入,从至少一个第二候选词中选取N个候选词。本申请实施例提供的输入显示装置70还包括:处理模块。其中,处理模块,用于基于预设模型,对选取模块72选取的N个候选词进行解析处理,以得到M个实体词,上述至少一个预设词包括M个实体词,M为小于或等于N的正整数,N为正整数。
在一种可能的实现方式中,上述接收模块71,还用于在接收用户对第一输入字符串的第二输入之前,接收用户的第四输入,该第四输入为用户对多个语料数据和多个标注信息的输入,每个语料数据分别对应一个标注信息,每个标注信息分别用于指示一个语料数据所属的实体词类别。本申请实施例提供的输入显示装置70还包括:训练模块。其中,训练模块,用于响应于接收模块71接收的第四输入,采用预设算法,对多个语料数据和多个标注信息进行训练,以得到预设模型。
在一种可能的实现方式中,上述选取模块72,具体用于若目标输入字符串与至少一个预设词中的第一词对应的输入字符串匹配,则将第一词确定为目标词;或者,若目标输入字符串中的前缀输入字符串与至少一个预设词中的第二词对应的输入字符串匹配,则将第二词确定为目标词,该前缀输入字符串为目标输入字符串中具有对应的实体词的部分输入字符串。
在一种可能的实现方式中,上述目标词为第一词。上述显示模块73,具体用于按照目标顺序显示第一词和其他第一候选词,该目标顺序为第一词位于至少一个第一候选词中的第一个候选词的位置,该其他第一候选词为至少一个第一候选词中除第一词之外的候选词。
在一种可能的实现方式中,上述目标词为第二词。上述显示模块73,具体用于按照第一顺序显示目标输入字符串对应的整体词、第二词和其他第一候选词,该第一顺序为整体词位于至少一个第一候选词中的第一个候选词的位置、且第二词位于至少一个第一候选词中的第二个候选词的位置,该整体词为目标输入字符串对应的词组成的整个待上屏候选词,该其他第一候选词为至少一个第一候选词中除整体词和第二词之外的候选词。
本申请实施例提供一种输入显示装置,由于用户在输入目标输入字符串之后,电子设备可以直接从用户历史使用过的至少一个预设实体词中选取与目标输入字符串对应的实体词(即目标词),并显示选取的目标输入字符串对应的实体词,而无需用户对候选词进行重复的筛选操作,因此提高了用户的输入效率,从而电子设备显示用户输入的输入字符串对应的词的灵活性较好。
本申请实施例中的输入显示装置可以是装置,也可以是终端中的部件、集成电路、或芯片。该装置可以是移动电子设备,也可以为非移动电子设备。示例性的,移动电子设备可以为手机、平板电脑、笔记本电脑、掌上电脑、车载电子设备、可穿戴设备、超级移动个人计算机(ultra-mobile personal computer,UMPC)、上网本或者个人数字助理(personal digital assistant,PDA)等,非移动电子设备可以为服务器、网络附属存储器(Network Attached Storage,NAS)、个人计算机(personal computer,PC)、电视机(television,TV)、柜员机或者自助机等,本申请实施例不作具体限定。
本申请实施例中的输入显示装置可以为具有操作系统的装置。该操作系统可以为安卓 (Android)操作系统,可以为ios操作系统,还可以为其他可能的操作系统,本申请实施例不作具体限定。
本申请实施例提供的输入显示装置能够实现上述方法实施例实现的各个过程,为避免重复,这里不再赘述。
可选地,如图8所示,本申请实施例还提供一种电子设备90,包括处理器91,存储器92,存储在存储器92上并可在所述处理器91上运行的程序或指令,该程序或指令被处理器91执行时实现上述方法实施例的各个过程,且能达到相同的技术效果,为避免重复,这里不再赘述。
需要说明的是,本申请实施例中的电子设备包括上述所述的移动电子设备和非移动电子设备。
图9为实现本申请实施例的一种电子设备的硬件结构示意图。
该电子设备100包括但不限于:射频单元101、网络模块102、音频输出单元103、输入单元104、传感器105、显示单元106、用户输入单元107、接口单元108、存储器109、以及处理器110等部件。
本领域技术人员可以理解,电子设备100还可以包括给各个部件供电的电源(比如电池),电源可以通过电源管理系统与处理器110逻辑相连,从而通过电源管理系统实现管理充电、放电、以及功耗管理等功能。图9中示出的电子设备结构并不构成对电子设备的限定,电子设备可以包括比图示更多或更少的部件,或者组合某些部件,或者不同的部件布置,在此不再赘述。
其中,用户输入单元107,用于接收用户对目标输入字符串的第一输入。
处理器110,用于响应于第一输入,从至少一个预设词中选取目标输入字符串对应的目标词,该至少一个预设词为电子设备中已存储的用户历史使用过的实体词。
显示单元106,用于显示包括目标词的至少一个第一候选词,该至少一个第一候选词与目标输入字符串对应。
本申请实施例提供一种电子设备,由于用户在输入目标输入字符串之后,电子设备可以直接从至少一个预设实体词中选取与目标输入字符串对应的实体词(即目标词),并显示选取的目标输入字符串对应的实体词,而无需用户对候选词进行重复的筛选操作,因此 提高了用户的输入效率,从而电子设备显示用户输入的输入字符串对应的词的灵活性较好。
可选地,本申请实施例中,用户输入单元107,还用于在接收用户对目标输入字符串的第一输入之前,接收用户对第一输入字符串的第二输入。
显示单元106,还用于响应于第二输入,显示第一输入字符串对应的至少一个第二候选词。
用户输入单元107,还用于接收用户的第三输入。
处理器110,还用于响应于第三输入,从至少一个第二候选词中选取N个候选词,并基于预设模型,对N个候选词进行解析处理,以得到M个实体词,上述至少一个预设词包括M个实体词,M为小于或等于N的正整数,N为正整数。
应理解的是,本申请实施例中,输入单元104可以包括图形处理器(Graphics Processing Unit,GPU)1041和麦克风1042,图形处理器1041对在视频捕获模式或图像捕获模式中由图像捕获装置(如摄像头)获得的静态图片或视频的图像数据进行处理。显示单元106可包括显示面板1061,可以采用液晶显示器、有机发光二极管等形式来配置显示面板1061。用户输入单元107包括触控面板1071以及其他输入设备1072。触控面板1071,也称为触摸屏。触控面板1071可包括触摸检测装置和触摸控制器两个部分。其他输入设备1072可以包括但不限于物理键盘、功能键(比如音量控制按键、开关按键等)、轨迹球、鼠标、操作杆,在此不再赘述。存储器109可用于存储软件程序以及各种数据,包括但不限于应用程序和操作系统。处理器110可集成应用处理器和调制解调处理器,其中,应用处理器主要处理操作系统、用户界面和应用程序等,调制解调处理器主要处理无线通信。可以理解的是,上述调制解调处理器也可以不集成到处理器110中。
本申请实施例还提供一种可读存储介质,所述可读存储介质上存储有程序或指令,该程序或指令被处理器执行时实现上述方法实施例的各个过程,且能达到相同的技术效果,为避免重复,这里不再赘述。
其中,所述处理器为上述实施例中所述的电子设备中的处理器。所述可读存储介质,包括计算机可读存储介质,如计算机只读存储器(Read-Only Memory,ROM)、随机存取存储器(Random Access Memory,RAM)、磁碟或者光盘等。
本申请实施例另提供了一种芯片,所述芯片包括处理器和通信接口,所述通信接口和所述处理器耦合,所述处理器用于运行程序或指令,实现上述方法实施例的各个过程,且能达到相同的技术效果,为避免重复,这里不再赘述。
应理解,本申请实施例提到的芯片还可以称为系统级芯片、系统芯片、芯片系统或片上系统芯片等。
需要说明的是,在本文中,术语“包括”、“包含”或者其任何其他变体意在涵盖非排他性的包含,从而使得包括一系列要素的过程、方法、物品或者装置不仅包括那些要素,而且还包括没有明确列出的其他要素,或者是还包括为这种过程、方法、物品或者装置所固有的要素。在没有更多限制的情况下,由语句“包括一个……”限定的要素,并不排除在包括该要素的过程、方法、物品或者装置中还存在另外的相同要素。此外,需要指出的是,本申请实施方式中的方法和装置的范围不限按示出或讨论的顺序来执行功能,还可包括根据所涉及的功能按基本同时的方式或按相反的顺序来执行功能,例如,可以按不同于所描述的次序来执行所描述的方法,并且还可以添加、省去、或组合各种步骤。另外,参照某些示例所描述的特征可在其他示例中被组合。
通过以上的实施方式的描述,本领域的技术人员可以清楚地了解到上述实施例方法可借助软件加必需的通用硬件平台的方式来实现,当然也可以通过硬件,但很多情况下前者是更佳的实施方式。基于这样的理解,本申请的技术方案本质上或者说对现有技术做出贡献的部分可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储介质(如ROM/RAM、磁碟、光盘)中,包括若干指令用以使得一台终端(可以是手机,计算机,服务器,空调器,或者网络设备等)执行本申请各个实施例所述的方法。
上面结合附图对本申请的实施例进行了描述,但是本申请并不局限于上述的具体实施方式,上述的具体实施方式仅仅是示意性的,而不是限制性的,本领域的普通技术人员在本申请的启示下,在不脱离本申请宗旨和权利要求所保护的范围情况下,还可做出很多形式,均属于本申请的保护之内。

Claims (17)

  1. 一种输入显示方法,所述方法包括:
    接收用户对目标输入字符串的第一输入;
    响应于所述第一输入,从至少一个预设词中选取所述目标输入字符串对应的目标词,并显示包括所述目标词的至少一个第一候选词,所述至少一个预设词为电子设备中已存储的用户历史使用过的实体词,所述至少一个第一候选词与所述目标输入字符串对应。
  2. 根据权利要求1所述的方法,其中,所述接收用户对目标输入字符串的第一输入之前,所述方法还包括:
    接收用户对第一输入字符串的第二输入;
    响应于所述第二输入,显示所述第一输入字符串对应的至少一个第二候选词;
    接收用户的第三输入;
    响应于所述第三输入,从所述至少一个第二候选词中选取N个候选词,并基于预设模型,对所述N个候选词进行解析处理,以得到M个实体词,所述至少一个预设词包括所述M个实体词,M为小于或等于N的正整数,N为正整数。
  3. 根据权利要求2所述的方法,其中,所述接收用户对第一输入字符串的第二输入之前,所述方法还包括:
    接收用户的第四输入,所述第四输入为用户对多个语料数据和多个标注信息的输入,每个语料数据分别对应一个标注信息,每个标注信息分别用于指示一个语料数据所属的实体词类别;
    响应于所述第四输入,采用预设算法,对所述多个语料数据和所述多个标注信息进行训练,以得到所述预设模型。
  4. 根据权利要求1至3中任一项所述的方法,其中,所述从至少一个预设词中选取所述目标输入字符串对应的目标词,包括:
    若所述目标输入字符串与所述至少一个预设词中的第一词对应的输入字符串匹配,则将所述第一词确定为所述目标词;
    若所述目标输入字符串中的前缀输入字符串与所述至少一个预设词中的第二词对 应的输入字符串匹配,则将所述第二词确定为所述目标词,所述前缀输入字符串为所述目标输入字符串中具有对应的实体词的部分输入字符串。
  5. 根据权利要求4所述的方法,其中,所述目标词为所述第一词;
    所述显示包括所述目标词的至少一个第一候选词,包括:
    按照目标顺序显示所述第一词和其他第一候选词,所述目标顺序为所述第一词位于所述至少一个第一候选词中的第一个候选词的位置,所述其他第一候选词为所述至少一个第一候选词中除所述第一词之外的候选词。
  6. 根据权利要求4所述的方法,其中,所述目标词为所述第二词;
    所述显示包括所述目标词的至少一个第一候选词,包括:
    按照第一顺序显示所述目标输入字符串对应的整体词、所述第二词和其他第一候选词,所述第一顺序为所述整体词位于所述至少一个第一候选词中的第一个候选词的位置、且所述第二词位于所述至少一个第一候选词中的第二个候选词的位置,所述整体词为所述目标输入字符串对应的词组成的整个待上屏候选词,所述其他第一候选词为所述至少一个第一候选词中除所述整体词和所述第二词之外的候选词。
  7. 一种输入显示装置,所述输入显示装置包括:接收模块、选取模块和显示模块;
    所述接收模块,用于接收用户对目标输入字符串的第一输入;
    所述选取模块,用于响应于所述接收模块接收的所述第一输入,从至少一个预设词中选取所述目标输入字符串对应的目标词,所述至少一个预设词为电子设备中已存储的用户历史使用过的实体词;
    所述显示模块,用于显示包括所述目标词的至少一个第一候选词,所述至少一个第一候选词与所述目标输入字符串对应。
  8. 根据权利要求7所述的装置,其中,所述接收模块,还用于在接收用户对目标输入字符串的第一输入之前,接收用户对第一输入字符串的第二输入;
    所述显示模块,还用于响应于所述接收模块接收的所述第二输入,显示所述第一输入字符串对应的至少一个第二候选词;
    所述接收模块,还用于接收用户的第三输入;
    所述选取模块,还用于响应于所述接收模块接收的所述第三输入,从所述至少一 个第二候选词中选取N个候选词;
    所述输入显示装置还包括:处理模块;
    所述处理模块,用于基于预设模型,对所述选取模块选取的所述N个候选词进行解析处理,以得到M个实体词,所述至少一个预设词包括所述M个实体词,M为小于或等于N的正整数,N为正整数。
  9. 根据权利要求8所述的装置,其中,所述接收模块,还用于在接收用户对第一输入字符串的第二输入之前,接收用户的第四输入,所述第四输入为用户对多个语料数据和多个标注信息的输入,每个语料数据分别对应一个标注信息,每个标注信息分别用于指示一个语料数据所属的实体词类别;
    所述输入显示装置还包括:训练模块;
    所述训练模块,用于响应于所述接收模块接收的所述第四输入,采用预设算法,对所述多个语料数据和所述多个标注信息进行训练,以得到所述预设模型。
  10. 根据权利要求7至9中任一项所述的装置,其中,所述选取模块,具体用于若所述目标输入字符串与所述至少一个预设词中的第一词对应的输入字符串匹配,则将所述第一词确定为所述目标词;或者,若所述目标输入字符串中的前缀输入字符串与所述至少一个预设词中的第二词对应的输入字符串匹配,则将所述第二词确定为所述目标词,所述前缀输入字符串为所述目标输入字符串中具有对应的实体词的部分输入字符串。
  11. 根据权利要求10所述的装置,其中,所述目标词为所述第一词;
    所述显示模块,具体用于按照目标顺序显示所述第一词和其他第一候选词,所述目标顺序为所述第一词位于所述至少一个第一候选词中的第一个候选词的位置,所述其他第一候选词为所述至少一个第一候选词中除所述第一词之外的候选词。
  12. 根据权利要求10所述的装置,其中,所述目标词为所述第二词;
    所述显示模块,具体用于按照第一顺序显示所述目标输入字符串对应的整体词、所述第二词和其他第一候选词,所述第一顺序为所述整体词位于所述至少一个第一候选词中的第一个候选词的位置、且所述第二词位于所述至少一个第一候选词中的第二个候选词的位置,所述整体词为所述目标输入字符串对应的词组成的整个待上屏候选 词,所述其他第一候选词为所述至少一个第一候选词中除所述整体词和所述第二词之外的候选词。
  13. 一种电子设备,包括处理器,存储器及存储在所述存储器上并可在所述处理器上运行的程序或指令,所述程序或指令被所述处理器执行时实现如权利要求1至6中任一项所述的输入显示方法的步骤。
  14. 一种可读存储介质,所述可读存储介质上存储程序或指令,所述程序或指令被处理器执行时实现如权利要求1至6中任一项所述的输入显示方法的步骤。
  15. 一种计算机程序产品,所述程序产品被至少一个处理器执行以实现如权利要求1至6中任一项所述的输入显示方法。
  16. 一种电子设备,包括所述电子设备被配置成用于执行如权利要求1至6中任一项所述的输入显示方法。
  17. 一种芯片,所述芯片包括处理器和通信接口,所述通信接口和所述处理器耦合,所述处理器用于运行程序或指令,以实现如权利要求1至6中任一项所述的输入显示方法。
PCT/CN2021/099439 2020-06-15 2021-06-10 输入显示方法、装置及电子设备 WO2021254251A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202010544431.X 2020-06-15
CN202010544431.XA CN111880668A (zh) 2020-06-15 2020-06-15 输入显示方法、装置及电子设备

Publications (1)

Publication Number Publication Date
WO2021254251A1 true WO2021254251A1 (zh) 2021-12-23

Family

ID=73157552

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2021/099439 WO2021254251A1 (zh) 2020-06-15 2021-06-10 输入显示方法、装置及电子设备

Country Status (2)

Country Link
CN (1) CN111880668A (zh)
WO (1) WO2021254251A1 (zh)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111880668A (zh) * 2020-06-15 2020-11-03 维沃移动通信有限公司 输入显示方法、装置及电子设备
CN112764551A (zh) * 2020-12-31 2021-05-07 维沃移动通信有限公司 词汇显示方法、装置和电子设备
CN112861471A (zh) * 2021-02-10 2021-05-28 上海臣星软件技术有限公司 对象显示方法、装置、设备及存储介质

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101661331A (zh) * 2008-08-28 2010-03-03 北京搜狗科技发展有限公司 一种字词输入的方法和输入法系统
CN102012748A (zh) * 2010-11-30 2011-04-13 哈尔滨工业大学 语句级中英文混合输入方法
CN107305438A (zh) * 2016-04-21 2017-10-31 北京搜狗科技发展有限公司 候选项的排序方法和装置、用于候选项排序的装置
CN109144286A (zh) * 2017-06-27 2019-01-04 北京搜狗科技发展有限公司 一种输入方法及装置
CN109901726A (zh) * 2017-12-08 2019-06-18 北京搜狗科技发展有限公司 一种候选词生成方法、装置及用于候选词生成的装置
CN111880668A (zh) * 2020-06-15 2020-11-03 维沃移动通信有限公司 输入显示方法、装置及电子设备

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107247519B (zh) * 2017-08-16 2020-09-29 北京搜狗科技发展有限公司 一种输入方法及装置
CN110569505B (zh) * 2019-09-04 2023-07-28 平顶山学院 一种文本输入方法及装置

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101661331A (zh) * 2008-08-28 2010-03-03 北京搜狗科技发展有限公司 一种字词输入的方法和输入法系统
CN102012748A (zh) * 2010-11-30 2011-04-13 哈尔滨工业大学 语句级中英文混合输入方法
CN107305438A (zh) * 2016-04-21 2017-10-31 北京搜狗科技发展有限公司 候选项的排序方法和装置、用于候选项排序的装置
CN109144286A (zh) * 2017-06-27 2019-01-04 北京搜狗科技发展有限公司 一种输入方法及装置
CN109901726A (zh) * 2017-12-08 2019-06-18 北京搜狗科技发展有限公司 一种候选词生成方法、装置及用于候选词生成的装置
CN111880668A (zh) * 2020-06-15 2020-11-03 维沃移动通信有限公司 输入显示方法、装置及电子设备

Also Published As

Publication number Publication date
CN111880668A (zh) 2020-11-03

Similar Documents

Publication Publication Date Title
WO2021254251A1 (zh) 输入显示方法、装置及电子设备
US7764837B2 (en) System, method, and apparatus for continuous character recognition
JP2021089739A (ja) 質問応答処理、言語モデルの訓練方法、装置、機器および記憶媒体
CN113518026B (zh) 消息处理方法、装置和电子设备
CN112099704A (zh) 信息显示方法、装置、电子设备和可读存储介质
CN111984589A (zh) 文档处理方法、文档处理装置和电子设备
CN112631437A (zh) 信息推荐方法、装置及电子设备
CN102968266A (zh) 识别方法及装置
CN114374663B (zh) 消息处理方法和消息处理装置
WO2022105754A1 (zh) 输入文字的方法、装置和电子设备
CN113037925B (zh) 信息处理方法、信息处理装置、电子设备和可读存储介质
CN113869063A (zh) 数据推荐方法、装置、电子设备及存储介质
CN112764734A (zh) 代码编辑的辅助方法、装置及电子设备
CN112148135A (zh) 输入法处理方法、装置和电子设备
CN113157966B (zh) 显示方法、装置及电子设备
CN112698734A (zh) 候选词显示方法及装置、电子设备
CN112346578A (zh) 输入方法及装置
CN113905125A (zh) 视频显示方法、装置及电子设备
CN112417095A (zh) 语音消息处理方法和装置
CN113190125A (zh) 输入矫正方法和装置
CN111966267A (zh) 应用评论方法、装置和电子设备
CN113010072A (zh) 搜索方法、装置、电子设备及可读存储介质
CN112307273A (zh) 信息查询方法、装置及电子设备
CN112764551A (zh) 词汇显示方法、装置和电子设备
CN112685126B (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: 21824988

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: 21824988

Country of ref document: EP

Kind code of ref document: A1

122 Ep: pct application non-entry in european phase

Ref document number: 21824988

Country of ref document: EP

Kind code of ref document: A1