CN108983992B - Candidate item display method and device with punctuation marks - Google Patents

Candidate item display method and device with punctuation marks Download PDF

Info

Publication number
CN108983992B
CN108983992B CN201710414527.2A CN201710414527A CN108983992B CN 108983992 B CN108983992 B CN 108983992B CN 201710414527 A CN201710414527 A CN 201710414527A CN 108983992 B CN108983992 B CN 108983992B
Authority
CN
China
Prior art keywords
candidate
candidate item
punctuation
character string
item
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201710414527.2A
Other languages
Chinese (zh)
Other versions
CN108983992A (en
Inventor
侯柏岑
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Sogou Technology Development Co Ltd
Original Assignee
Beijing Sogou Technology Development Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Sogou Technology Development Co Ltd filed Critical Beijing Sogou Technology Development Co Ltd
Priority to CN201710414527.2A priority Critical patent/CN108983992B/en
Publication of CN108983992A publication Critical patent/CN108983992A/en
Application granted granted Critical
Publication of CN108983992B publication Critical patent/CN108983992B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/02Input arrangements using manually operated switches, e.g. using keyboards or dials
    • G06F3/023Arrangements for converting discrete items of information into a coded form, e.g. arrangements for interpreting keyboard generated codes as alphanumeric codes, operand codes or instruction codes
    • G06F3/0233Character input methods
    • G06F3/0236Character input methods using selection techniques to select from displayed items

Abstract

The embodiment of the application discloses a candidate item display method and device with punctuation marks, wherein the method comprises the following steps: acquiring a character string input by a user; judging whether the candidate items corresponding to the character strings comprise candidate items meeting punctuation mark use rules or not; if a first candidate item in the candidate items corresponding to the character string is a candidate item which accords with a punctuation mark using rule, generating a second candidate item, wherein the second candidate item is the first candidate item which uses punctuation marks in the punctuation mark using rule; and displaying the second candidate item in a candidate item display position corresponding to the character string. The method and the device for inputting the punctuation mark can prompt the user that the candidate item needs to be used together with the punctuation mark in the punctuation mark using rule by showing the second candidate item to the user, and the user can directly select the second candidate item to input on a screen, so that the complicated operation of selecting the first candidate item and then inputting the punctuation mark is avoided, and the input experience of the user is improved.

Description

Candidate item display method and device with punctuation marks
Technical Field
The present application relates to the field of input methods, and in particular, to a candidate item display method and apparatus with punctuation marks.
Background
Punctuation marks are symbols of a secondary script language, and punctuation marks in different languages may be distinguished, for example punctuation marks common in chinese may include periods. "double quotation marks", "book title number", etc.
The standard use of punctuation marks can make the readability of written text better, but in the case of text input using the input method, the use of punctuation marks by many users is not completely standard. The reason is that the use specification of punctuation marks by some users is not clear, so that the nonstandard use condition of the punctuation marks occurs when inputting characters; some users know how to standardize the punctuation, but they are reluctant to standardize the punctuation because some punctuation is cumbersome to input when inputting using the input method.
Therefore, how to help users to use punctuation marks in a standard way when inputting characters by using an input method is an urgent problem to be solved.
Disclosure of Invention
In order to solve the above technical problem, embodiments of the present application provide a candidate item display method and apparatus with a punctuation mark, which avoid the complicated operation of selecting a first candidate item and then inputting the punctuation mark, and improve the input experience of a user.
In a first aspect, an embodiment of the present application provides a candidate item display method with punctuation marks, where the method includes:
acquiring a character string input by a user;
judging whether the candidate items corresponding to the character strings comprise candidate items meeting punctuation mark use rules or not;
if a first candidate item in the candidate items corresponding to the character string is a candidate item which accords with a punctuation mark using rule, generating a second candidate item, wherein the second candidate item is the first candidate item which uses punctuation marks in the punctuation mark using rule;
and displaying the second candidate item in a candidate item display position corresponding to the character string.
Optionally, the displaying the second candidate item in the candidate item display position corresponding to the character string includes:
and simultaneously displaying the first candidate item and the second candidate item in a candidate item display page corresponding to the character string, wherein the candidate item display page comprises a plurality of candidate item display positions.
Optionally, the candidate item presentation page that simultaneously presents the first candidate item and the second candidate item is a first page of the candidate item presentation page corresponding to the character string.
Optionally, the method further includes:
judging whether candidate items corresponding to the character strings comprise candidate items input in the historical input data or not according to the historical input data, wherein the historical input data comprise input punctuation marks and candidate item combinations;
if a third candidate item in the candidate items corresponding to the character string is a candidate item in the historical input data, generating a fourth candidate item, wherein the fourth candidate item is a combination of a punctuation mark in the historical input data and the third candidate item;
and displaying the fourth candidate item in a candidate item display position corresponding to the character string.
Optionally, the historical input data includes a combination of punctuation marks and candidate items input by the user and/or the group in which the user is located.
Optionally, before the step of displaying the fourth candidate in the candidate display position corresponding to the character string, the method further includes:
judging whether the fourth candidate item and the second candidate item are consistent;
and if the character string is consistent with the second candidate item, the step of displaying the second candidate item in the candidate item display position corresponding to the character string is executed.
Optionally, the method further includes:
counting the occurrence times of the combination of the punctuation marks and the candidate items in the historical input data in unit time;
combining punctuation marks and candidate items, the occurrence times of which meet preset conditions in unit time, to establish a punctuation word library;
the judging whether the candidate items corresponding to the character strings include the candidate items input in the historical input data according to the historical input data includes:
judging whether the candidate items corresponding to the character strings comprise the candidate items in the punctuation word library or not according to the punctuation word library;
if the third candidate item in the candidate items corresponding to the character string is the candidate item in the historical input data, generating a fourth candidate item, including:
and if the third candidate item in the candidate items corresponding to the character string is the candidate item in the punctuation word library, generating a fourth candidate item.
Optionally, the method further includes:
periodically updating the punctuation word library according to the unit time, wherein the updating comprises the following steps: and if the appearance times of the punctuation marks and the candidate item combinations in the punctuation word library in the updating period do not meet the preset condition, deleting the punctuation marks and the candidate item combinations which do not meet the preset condition from the punctuation word library.
In a second aspect, an embodiment of the present application provides a candidate item presentation apparatus with punctuation marks, including: the display device comprises a first acquisition unit, a first judgment unit, a first generation unit and a first display unit:
the first acquisition unit is used for acquiring a character string input by a user;
the first judging unit is used for judging whether the candidate items corresponding to the character strings comprise candidate items meeting the punctuation mark using rule; if a first candidate item in the candidate items corresponding to the character string is a candidate item with a punctuation mark using rule, triggering a first generating unit;
the first generating unit is configured to generate a second candidate, where the second candidate is the first candidate using punctuation marks in the punctuation mark usage rule;
the first presentation unit is configured to present the second candidate item in a candidate item presentation position corresponding to the character string.
Optionally, the first display unit includes:
and the second presentation subunit is used for simultaneously presenting the first candidate item and the second candidate item in a candidate item presentation page corresponding to the character string, and the candidate item presentation page comprises a plurality of candidate item presentation positions.
Optionally, the second presentation subunit is further configured to present the candidate item presentation pages of the first candidate item and the second candidate item at the same time as the first page of the candidate item presentation page corresponding to the character string.
Optionally, the display device further includes a second judging unit, a second generating unit, and a third displaying unit:
the second judging unit is used for judging whether the candidate items corresponding to the character string comprise the candidate items input in the historical input data or not according to the historical input data, and the historical input data comprises input punctuation marks and candidate item combinations; if a third candidate item in the candidate items corresponding to the character string is a candidate item in the historical input data, triggering a second generation unit;
the second generating unit is configured to generate a fourth candidate, where the fourth candidate is a combination of a punctuation mark in the history input data and the third candidate;
the third display unit is configured to display the fourth candidate in a candidate display position corresponding to the character string.
Optionally, the historical input data includes a combination of punctuation marks and candidate items input by the user and/or the group in which the user is located.
Optionally, the apparatus further includes a third determining unit:
the third judging unit is used for judging whether the fourth candidate item and the second candidate item are consistent; and if the display units are consistent, triggering the first display unit.
Optionally, the method further includes:
the statistical unit is used for counting the occurrence times of the combination of the punctuation marks and the candidate items in the historical input data in unit time;
the device comprises an establishing unit, a searching unit and a searching unit, wherein the establishing unit is used for establishing a punctuation word library by combining punctuation marks and candidate items, the occurrence times of which in unit time meet preset conditions;
the second determination unit includes:
a fourth judging subunit, configured to judge, according to the punctuation word library, whether the candidate items corresponding to the character string include a candidate item in the punctuation word library;
the second generation unit includes:
and the third generating subunit is configured to generate a fourth candidate item if a third candidate item in the candidate items corresponding to the character string is a candidate item in the punctuation word library.
Optionally, the method further includes an updating unit and a deleting unit:
the updating unit is configured to update the punctuation thesaurus periodically according to the unit time, where the updating unit includes: if the appearance times of the punctuation mark and candidate item combination in the punctuation word library in the updating period do not meet the preset condition, triggering the deleting unit;
and the deleting unit is used for deleting the punctuation marks and candidate item combinations which do not meet the preset conditions from the punctuation word library.
In a third aspect, an embodiment of the present application provides a candidate item presentation apparatus with punctuation marks, including: memory, and one or more programs, wherein the one or more programs are stored in the memory and configured to be executed by the one or more processors the one or more programs including instructions for:
acquiring a character string input by a user;
judging whether candidate items corresponding to the character strings comprise candidate items meeting punctuation mark use rules or not;
if a first candidate item in the candidate items corresponding to the character string is a candidate item which accords with a punctuation mark using rule, generating a second candidate item, wherein the second candidate item is the first candidate item which uses punctuation marks in the punctuation mark using rule;
and displaying the second candidate item in a candidate item display position corresponding to the character string.
In a fourth aspect, embodiments of the present application provide a machine-readable medium having stored thereon instructions, which when executed by one or more processors, cause an apparatus to perform the method described in the first aspect.
It can be seen from the above technical solutions that, by means of the punctuation mark usage rules obtained in advance and aimed at the candidate items, when a user inputs a character string, it can be determined whether the candidate items corresponding to the character string have punctuation mark usage rules that are in accordance with the punctuation mark usage rules, if there is a first candidate item in the candidate items that is in accordance with the punctuation mark usage rules, a second candidate item can be generated according to the punctuation mark that is in combination with the first candidate item in the punctuation mark usage rules, that is, the first candidate item that includes the corresponding punctuation mark is included, and the second candidate item is displayed in the candidate item display position corresponding to the character string, the second candidate item is displayed to the user to prompt the user that the candidate item needs to be used together with the punctuation mark in the punctuation mark usage rules, and the user can directly select the second candidate item for screen entry, avoiding the complicated operation of selecting the first candidate item and then inputting the punctuation mark, the input experience of the user is improved.
Drawings
In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings needed to be used in the description of the embodiments or the prior art will be briefly introduced below, and it is obvious that the drawings in the following description are only some embodiments of the present application, and it is obvious for those skilled in the art that other drawings can be obtained according to the drawings without inventive exercise.
Fig. 1 is a flowchart of a method for displaying candidate items with punctuation marks according to an embodiment of the present disclosure;
fig. 2 is a flowchart of a method for displaying candidate items with punctuation marks according to an embodiment of the present disclosure;
fig. 3 is a schematic structural diagram of a candidate item display apparatus with punctuation marks according to an embodiment of the present application;
fig. 4 is a block diagram illustrating a structure of a device with candidate items of punctuation marks as a terminal according to an embodiment of the present application;
fig. 5 is a schematic structural diagram of a server in some embodiments provided by the embodiments of the present application.
Detailed Description
Embodiments of the present application are described below with reference to the accompanying drawings.
The user can use the input method to input characters to the terminal, punctuation marks are needed to be used in writing written characters under general conditions, and the punctuation marks used in a standard way can effectively improve the readability of the written characters. However, due to the fact that some users wrongly know the using mode of the punctuation marks or the punctuation marks are input simply because the punctuation marks are input in a troublesome way, the using mode of the punctuation marks in written characters input by the users through an input method is irregular.
In order to help a user input punctuation marks in a normative way in the process of inputting characters, the embodiment of the application provides a candidate item display method and a candidate item display device with punctuation marks, whether candidate items corresponding to character strings meet punctuation mark use rules can be judged when the user inputs the character strings through pre-obtained punctuation mark use rules aiming at the candidate items, if a first candidate item in the candidate items meets the punctuation mark use rules, a second candidate item can be generated according to punctuation marks used in combination with the first candidate item in the punctuation mark use rules, namely a first candidate item comprising the corresponding punctuation marks is included, the second candidate item is displayed in a display position corresponding to the character strings, the second candidate item is displayed to the user, and the user can be prompted that the candidate item needs to be used together with the punctuation marks in the punctuation mark use rules, and the user can directly select the second candidate item for on-screen input, so that the complex operation of selecting the first candidate item and then inputting punctuation marks is avoided, and the input experience of the user is improved.
The embodiment of the application can be applied to an input method installed in a terminal, the terminal can comprise a mobile terminal, a computer and other intelligent equipment which can be provided with the input method, and the input method can be used for inputting characters of different languages into the terminal and can also be a specific input method of different languages, such as a Chinese input method, a Japanese input method and the like.
The input method may display corresponding candidate items according to a character string input by a user, and the character string input by the user may be related to an input rule of the input method, for example, in a chinese pinyin input method, the character string input by the user may include a pinyin string. The candidate item selected by the user on the screen can be understood as a character input into the terminal, and the language of the input character can be the same as or related to the input language of the input method, for example, the character input by the Chinese input method can be Chinese, English, and the like.
The written text presented in the embodiment of the present application includes any language expression form described in text, for example, the written text may include text content expressed in written language, such as legal documents, treatises, etc., and may also include text content expressed in spoken language, such as chat content in social software, etc.
Since the rules of using punctuations in different languages may be different and the compositions of the punctuations are different, for the sake of clarity, the following embodiments will mainly use the chinese input method as an example for description.
Fig. 1 is a flowchart of a method for displaying candidate items with punctuation marks according to an embodiment of the present disclosure, where the method includes:
s101: and acquiring the character string input by the user.
For example, in the Chinese input method, the character string may be a pinyin string or a character string with other components. Through the character string, the input method can determine at least one corresponding candidate item.
The user may input the character string in various ways, for example, inputting the character string through an input device such as a keyboard, inputting the character string through voice, and in the case of voice input, the input method may determine the content of the user input from the voice through voice recognition.
S102: and judging whether the candidate items corresponding to the character strings comprise the candidate items meeting the punctuation mark use rule.
The punctuation mark usage rules may refer to a canonical usage form for punctuation marks in the languages that the input method may input. The punctuation marks may be various punctuation marks used by inputting languages, for example, the chinese language may include book title numbers, double quotation marks, etc., and may also include special expression forms for characters, such as italics, bolding, etc. It should be noted that the same type of punctuation may be represented differently in different languages, for example, the title number in Chinese may be "and the title number in English may be the whole title italicized or underlined.
In addition to punctuation marks represented by a single symbol, punctuation marks represented by a plurality of symbols, such as various brackets [ c ] { } (), book title numbers [ e ] < >, quotation marks "", and the like, are included, such punctuation marks represented by a plurality of symbols require a plurality of inputs at the time of input, and it is also necessary to input corresponding characters, such as book title, between such punctuation marks in most cases: harry potter, project name: intelligent adding picture, etc., so when the written characters are input and the characters used by combining with the punctuation marks are needed, the user either enters punctuation symbols first, then moves the input focus between punctuation symbols, then enters text, or first enter punctuation, then enter text, then move text in its entirety (e.g., by cut-and-copy) between punctuation, then either first enter a portion of punctuation such as, then inputting the text and inputting another part of punctuation marks, for example, in any case, the input complexity is increased, so that some users do not input punctuation marks when inputting the text directly, the irregular use of punctuation marks appears in the written text, it can be seen that, in the process of inputting written characters, the punctuation marks represented by a plurality of symbols are also the problem of irregular use of the punctuation marks.
Therefore, when the using rule of the punctuation mark is obtained in advance, the characters which are clear of the fixed using method of the punctuation mark can be collected, for example, the name of the published book needs to be combined with the name of the book in the written characters, so that the published name of the book and the name of the book can be used as one of the using rules of the punctuation mark, and similarly, the name of the song, the name of a paper, the name of the drawing, the name of the movie and the like also need to be combined with the name of the book in the written characters, and therefore, the name of the song, the name of the paper, the name of the drawing, the name of the movie and the like can also be used as one of the using rules of the punctuation mark. Besides the book name number, the fixed combination of other punctuations (including punctuations represented by a single symbol and punctuations represented by a plurality of symbols) and characters can also be used as punctuation usage rules, and the description is omitted. The method for obtaining the punctuation mark use rule can be performed by a web crawler technology or a machine learning method, and is not limited in the embodiment of the application.
That is, the punctuation mark usage rules mainly include some proprietary texts and the specific usage of punctuation marks, which can effectively increase the readability of written texts if the usage can be embodied in the written texts.
In the embodiment of the application, the input method can provide at least one corresponding candidate item according to the character string input by the user, and before the candidate item is displayed, whether the candidate item belongs to the characters which need to be combined with the punctuation mark in the punctuation mark using rule or not can be judged through the punctuation mark using rule obtained in advance, so that the punctuation mark can be assisted and input for the user when the candidate item which meets the punctuation mark using rule is determined.
S103: and if a first candidate item in the candidate items corresponding to the character string is a candidate item which accords with the punctuation mark using rule, generating a second candidate item, wherein the second candidate item is the first candidate item which uses punctuation marks in the punctuation mark using rule.
If it is determined that there is a candidate item that meets the punctuation mark usage rule, such as a first candidate item, in the candidate items corresponding to the character string, it may be determined that the first candidate item generally needs to be used in combination with punctuation marks, or in general, the first candidate item needs to be used in combination with a specific punctuation mark to meet the punctuation mark usage rule.
Since the punctuation mark usage rule records which punctuation mark or punctuation marks the first candidate is combined with, and how to use the punctuation mark in combination, a second candidate can be generated according to the combined usage mode for the first candidate and the punctuation mark recorded in the punctuation mark usage rule, the second candidate includes the first candidate and the punctuation mark used in combination with the first candidate, for example, the punctuation mark usage rule records characters: harry baud is the sum of punctuation: the book title number "is used in combination, the combined use mode is to put the harry baud between book title numbers, so when the candidate item corresponding to the character string input by the user includes the harry baud candidate item, a new candidate item, such as the second candidate item, can be generated for the character string: harry potter.
S104: and displaying the second candidate item in a candidate item display position corresponding to the character string.
Because the generated second candidate item includes, in addition to the first candidate item, a punctuation symbol used in combination with the first candidate item in the punctuation symbol usage rule, if the user sees that the candidate item corresponding to the input character string includes the second candidate item, it can be understood that the original first candidate item can be used or needs to be used in combination with the punctuation symbol, and secondly, if the first candidate item needs to be used in combination with the punctuation symbol shown in the second candidate item according to the input environment or context, the user can also directly select the second candidate item to display the second candidate item, that is, the correct combination of the punctuation symbol and the first candidate item is directly input into the terminal, for example, the direct input: the Harry Baud avoids the complex operation of inputting punctuation marks after selecting a first candidate item in the traditional mode, such as inputting the Harry Baud first and then inputting the Harry Baud, and then adjusting the Harry Baud to the middle of the book.
In the embodiment of the present application, which candidate item display position corresponding to the character string the second candidate item is displayed at is not limited, but in order to enable the user to have a chance to see the second candidate item as much as possible, that is, to see the second candidate item before selecting the candidate item upper screen, the second candidate item is not displayed at a particularly rear position generally, for example, a position that the user needs to turn back the candidate item display page multiple times to see the second candidate item, where the candidate item display page may be understood as an interface or a window of the displayed candidate item, and at least one candidate item display position in one candidate item display page, how many candidate item display positions included in one candidate item display page are related to the candidate item length or the page setting.
However, in some input situations or context, what the user actually wants to input through the string is the first candidate, but not the second candidate, for example, a book named "true good for this cake" in this book, if the user chats with other users in the social software, he wants to express that today a good cake is eaten, and inputs the string corresponding to the true good for this cake, which has the first candidate: if the cake is really delicious, the second candidate item is generated according to the punctuation mark using rule: in the cake, the second candidate item is placed in a candidate item display position prior to the first candidate item and is positioned in a different candidate item display page from the first candidate item, so that the user can see the second candidate item first and can see the first candidate item after turning pages, namely the candidate item which is actually required to be input, thereby influencing the input experience of the user.
Therefore, optionally, the embodiment of the present application provides a manner of presenting a first candidate item and a second candidate item, and when the second candidate item is presented in a candidate item presentation position corresponding to the character string, the first candidate item and the second candidate item may be presented in a candidate item presentation page corresponding to the character string at the same time.
That is to say, the first candidate item and the second candidate item are displayed in the same page of the candidate item display page, and accordingly, the candidate item display page needs to have at least two candidate item display positions for respectively displaying the first candidate item and the second candidate item. The first candidate may be presented in a more advanced position, e.g. to the left of the second candidate, which may also be presented in a more advanced position, e.g. to the left of the first candidate. The first candidate item and the second candidate item may be adjacently presented in the candidate item presentation page, or may not be adjacently presented in the candidate item presentation page. The embodiment of the present application does not limit the relative positions of the first candidate item and the second candidate item, however, alternatively, the input method may be determined by combining the context of the input, and what the character string input by the current user should be related to is exemplified by the aforementioned "this cake is really good at eat", and the first candidate item: this cake is really delicious, the second candidate: if the content of the discussion is found to be related to the food according to the context, the candidate item which the user wants to input the character string to be displayed on the screen is more likely to be related to the first candidate item, the first candidate item can be placed at a position higher than the second candidate item, if the content of the discussion is found to be related to the reading book according to the context, the candidate item which the user wants to input the character string to be displayed on the screen is more likely to be related to the second candidate item, and the second candidate item can be placed at a position higher than the first candidate item.
Under the display mode, the user can see the first candidate item and the second candidate item simultaneously, namely, the punctuation mark using rule prompting the user for the first candidate item is provided, the selection right is provided for the user, the user can conveniently select the required candidate item according to the actual input context, and the input experience of the user is improved.
In order to make the second candidate item visible to the user for the first time, the first candidate item and the second candidate item may be displayed in the first page of the candidate item display page corresponding to the character string, that is, the priority display page. After the user inputs the character string, the first candidate item and the second candidate item can be directly seen from the first displayed candidate items, so that the user can conveniently select the character string, and the input efficiency is improved to a certain extent.
In addition to the standard input of the punctuation marks in the input process of the user can be assisted by the pre-acquired punctuation mark use rules, the input of the punctuation marks in the input process of the user can also be assisted according to historical input data input by using an actual input method. The use of historical input data to assist the entry of punctuation marks in the user input process can be implemented as a stand-alone implementation or as a further improvement over the use of pre-derived punctuation mark usage rules to assist the canonical entry of punctuation marks in the user input process.
The historical input data may be data formed by inputting characters through an input method, and the input method mentioned here may include the input method applied in the embodiment of the present application, and may also include other input methods. According to different application scenarios or use requirements, input data of different intervals can be selected as the historical input data, for example, the historical input data may be input data in a short period of time, such as input data acquired in the last week, or may be input data in a longer period of time.
In the embodiment of the application, the input data is mainly concerned with the relevant data of the combination of the input punctuation marks and the candidate items, and the input data can be obtained by the input behavior of the characters and the punctuation marks input by a user.
Taking punctuation marks represented by a single symbol as an example, when a punctuation mark is input next to a character, the character and the punctuation mark can be considered to have an association relationship, and the association relationship can be used as historical input data. Taking punctuation marks represented by a plurality of symbols as an example, when a user inputs characters first, then inputs punctuation marks, and then adjusts the input characters to be among the punctuation marks, the characters and the punctuation marks can be considered to have an association relationship, and the association relationship can be used as historical input data, or the user inputs punctuation marks first, then inputs characters, and then adjusts the input characters to be among the punctuation marks, and the characters and the punctuation marks can also be considered to have an association relationship, and the association relationship can be used as historical input data.
The punctuation mark usage rule mainly embodies a standard usage mode of punctuation marks, for example, a title number needs to be added to a title, and since the historical input data is mainly generated in the process of using an input method by a user, compared with the punctuation mark usage rule, the historical input data can embody an input habit or an input mode of the user, for example, an engineer who does a project is used to add a bracket [ when inputting a project name, and if the project name is an intelligent charting, the engineer always inputs the project in a [ intelligent charting ] mode, if the input habit is used as the historical input data, when a user inputs a character string corresponding to the intelligent charting, a fourth candidate item can be generated by the historical input data for a third candidate item which is the intelligent charting: [ INTELLIGENT ADD PICTURE ].
The range of users covered by the historical input data may also be different according to different application scenarios or usage requirements, for example, the historical input data may include combinations of punctuation marks and candidates input by a single user, such as the user inputting the character string, and/or a group in which the single user is located, such as the user inputting the character string.
That is, under the condition of a small number of users or surplus system processing capacity, a group of corresponding historical input data can be collected for each user, wherein the historical input data of one user comes from the user, the historical input data can well reflect the input habit of the user, and the characters and punctuations input by the user can be applied to the current input of the user in a using mode of combining the characters and punctuations input by the user, when the user inputs: the term "argumentation", when the user inputs the character string corresponding to the term again, the term "argumentation" can be directly presented to the user, so that the input steps of the user are simplified, and the fourth shown term is more consistent with the input habit of the user.
In the case of a large number of users, the historical input data corresponding to one user may include input data of each user in a user group where the user is located, and the user group mentioned here may be some users having common characteristics, such as friends having common interests and hobbies, colleagues working in the same work unit, members of a community responsible for the same project, residents living in the same district, and the like. The number of the groups where one user is located can be multiple, so that when the historical input data is determined, the input data generated by part or all of the groups where one user is located can be used as the historical input data.
Users with common characteristics may have a certain similarity in their input habits on punctuation, or the desired input text may have some particular punctuation usage that is common in groups. For example, when a user in a project group inputs a special vocabulary related to a project, the special vocabulary may be used in combination with a specific punctuation mark, and when the combination is used as historical input data, and the user in the group performs character input, and when a character string showing the special vocabulary is input, the special vocabulary used in combination with the specific punctuation mark may be shown at a candidate item showing position, so that the input efficiency of the user in the group is improved, an effect adapted to the input habit of the specific punctuation mark in the group is achieved, and the input experience of the user is improved.
Next, how to apply the historical input data to help the user input punctuation marks in the process of inputting characters is described with reference to the accompanying drawings, fig. 2 is a flowchart of a method for displaying candidate items with punctuation marks according to an embodiment of the present disclosure, where the method includes:
s201: and judging whether the candidate items corresponding to the character strings comprise the candidate items input in the historical input data or not according to the historical input data.
For example, before the step is executed, a character string input by a user may be obtained, which is not limited in the embodiment of the present application, and on the premise that the embodiment corresponding to fig. 2 is improved on the basis of the embodiment corresponding to fig. 1, the character string may be obtained through the step S101 in the embodiment corresponding to fig. 1, and on the premise that the embodiment corresponding to fig. 2 is implemented independently, the character string may also be obtained separately.
S202: and if a third candidate item in the candidate items corresponding to the character string is the candidate item in the historical input data, generating a fourth candidate item, wherein the fourth candidate item is a combination of a punctuation mark in the historical input data and the third candidate item.
If it can be determined that there is a candidate item in the candidate items corresponding to the character string, for example, the third candidate item is a candidate item in the history input data, the fourth candidate item may be generated according to a combined use mode of the third candidate item and the punctuation mark in the history input data. For example, when the historical input data includes a combined use mode of characters and punctuation marks of ' Harry Baud ', if the candidate item corresponding to the character string input by the user includes the Harry Baud ', the ' Harry Baud ' can be generated according to the historical input data.
S203: and displaying the fourth candidate item in a candidate item display position corresponding to the character string.
For the similar presentation manner of the fourth candidate item to that of the second candidate item, the detailed description may refer to the related description of how the second candidate item is presented in the embodiment corresponding to fig. 1. The third candidate and the fourth candidate are presented in a similar manner to the first candidate and the second candidate, and the detailed description may refer to the related description of how the first candidate and the second candidate are presented in the embodiment corresponding to fig. 1.
In some cases, the historical input data and the punctuation mark usage rules may include the same combined usage mode of the characters and the punctuation marks, so that on the premise that the embodiment corresponding to fig. 2 is improved on the basis of the embodiment corresponding to fig. 1, a situation may occur that the second candidate item generated by the punctuation mark usage rules is the same as the fourth candidate item generated by the historical input data, and in this case, if both the second candidate item and the fourth candidate item are displayed, repeated display may be caused, which not only wastes display positions, but also reduces the user experience,
therefore, the embodiment of the present application further provides a pre-display deduplication method, and before the fourth candidate is displayed in the candidate display position corresponding to the character string, it may also be determined whether the fourth candidate is consistent with the second candidate. If the second candidate item and the fourth candidate item are judged to be consistent, it is not necessary to present the same candidate items, and one of the candidate items may be selected to be presented, for example, the second candidate item is presented in a candidate item display position corresponding to the character string.
It should be noted that the text input by the user may be related to the current affair hotspot, and the current affair hotspot has timeliness, which is characterized in that the frequency of inputting the text related to the current affair hotspot by the user in a period of time is high, but the frequency of inputting the text related to the current affair hotspot is suddenly reduced after the period of time elapses.
In order to adapt the input effect of the input method to the situation, the collected historical input data can also comprise a combined usage of relevant characters and punctuations in the current affair hot spot. The embodiment of the application provides a mode for determining the combined usage of relevant characters and punctuation marks in a current affair hot spot from historical input data.
The method can calculate the occurrence frequency of the punctuation mark and candidate item combination in the historical input data in unit time according to the time of the acquired historical input data, and establish a punctuation word library by the punctuation mark and candidate item combination with the occurrence frequency meeting the preset conditions in unit time.
The unit time may be a preset period of time, such as a day, a week, a month, etc. If a large number of punctuation marks and candidate items are combined in historical input data in unit time, it can be determined that the candidate items combined with the punctuation marks can belong to characters related to temporal hot spots, for example, in the period of tropical storm 'el nino', a large number of users can discuss data related to el nino, disasters and the like on the internet, and since el nino belongs to the exclusive naming of typhoon, double quotation marks are generally needed to be added, a large amount of input data referring to el nino can appear in the period, that is, the number of occurrences of character of 'el nino' and punctuation marks are large.
In order to determine the combination of the relevant characters and punctuation marks in the current hotspot as accurately as possible, a preset condition can be preset, and the preset condition can be specific occurrence times or the first few with the highest occurrence times in the statistical data. Generally, when the preset condition is more strict, the more likely that a candidate belongs to the relevant characters of the current hotspot in the combination of the candidate satisfying the preset condition and the punctuation mark.
For convenience of use, a punctuation word library can be established by combining punctuation marks and candidate items, wherein the occurrence times in unit time meet preset conditions. Therefore, when S201 in the embodiment corresponding to fig. 2 is executed, whether the candidate item corresponding to the character string includes a candidate item in the punctuation word library may be determined according to the punctuation word library. When S202 is executed, a fourth candidate may be generated if a third candidate in the candidates corresponding to the character string is a candidate in the punctuation word library.
By establishing the punctuation word stock, the user can see the candidate items used by combining punctuation marks when inputting the characters related to the current affair hotspot by using the input method, thereby improving the input speed during discussion.
The current hotspot is time-efficient, and one current hotspot may not be mentioned again by a user after a period of time, so that the established symbol lexicon needs to be updated, and besides a newly appeared combination of the current hotspot related characters and punctuation marks, the outdated combination of the current hotspot related characters and punctuation marks needs to be deleted, thereby avoiding the waste of resources.
Therefore, the punctuation word library can be periodically updated according to the unit time, wherein the punctuation word library comprises the following steps: and if the appearance times of the punctuation mark and candidate item combination in the punctuation word library in the updating period do not meet the preset condition, deleting the punctuation mark and candidate item combination which do not meet the preset condition from the punctuation word library.
Referring to fig. 3, a candidate item display apparatus with punctuation marks provided in an embodiment of the present application, the apparatus includes: first acquiring unit 301, first judging unit 302, first generating unit 303, and first presenting unit 304:
the first obtaining unit 301 is configured to obtain a character string input by a user;
the first judging unit 302 is configured to judge whether a candidate item corresponding to the character string includes a candidate item having a usage rule meeting a punctuation mark; if the first candidate item in the candidate items corresponding to the character string is a candidate item having a usage rule meeting the punctuation mark, triggering a first generation unit 303;
the first generating unit 303, configured to generate a second candidate, where the second candidate is the first candidate using punctuation marks in the punctuation mark usage rule;
the first presentation unit 304 is configured to present the second candidate in a candidate presentation position corresponding to the character string.
In an embodiment of the present application, the first display unit 304 includes:
and the second presentation subunit is used for simultaneously presenting the first candidate item and the second candidate item in a candidate item presentation page corresponding to the character string, and the candidate item presentation page comprises a plurality of candidate item presentation positions.
In an embodiment of the present application, the second presenting subunit is further configured to present, at the same time, a candidate item presenting page of the first candidate item and a candidate item presenting page of the second candidate item as a first page of the candidate item presenting page corresponding to the character string.
In an embodiment of the present application, the display device further includes a second judging unit, a second generating unit, and a third displaying unit:
the second judging unit is used for judging whether the candidate items corresponding to the character string comprise the candidate items input in the historical input data or not according to the historical input data, and the historical input data comprises input punctuation marks and candidate item combinations; if a third candidate item in the candidate items corresponding to the character string is a candidate item in the historical input data, triggering a second generation unit;
the second generating unit is configured to generate a fourth candidate, where the fourth candidate is a combination of a punctuation mark in the history input data and the third candidate;
the third presentation unit is configured to present the fourth candidate in a candidate presentation position corresponding to the character string.
In one embodiment of the present application, the historical input data includes a combination of punctuation marks and candidate items input by the user and/or a group in which the user is located.
In one embodiment of the present application, the apparatus further includes a third determining unit:
the third judging unit is used for judging whether the fourth candidate item and the second candidate item are consistent; if so, the first presentation unit 304 is triggered.
In one embodiment of the present application, the method further includes:
the statistical unit is used for counting the occurrence times of the combination of the punctuation marks and the candidate items in the historical input data in unit time;
the establishing unit is used for establishing a punctuation word library by combining punctuation marks and candidate items, the occurrence times of which meet preset conditions in unit time;
the second determination unit includes:
a fourth judging subunit, configured to judge, according to the punctuation word library, whether the candidate items corresponding to the character string include a candidate item in the punctuation word library;
the second generation unit includes:
and the third generating subunit is configured to generate a fourth candidate item if a third candidate item in the candidate items corresponding to the character string is a candidate item in the punctuation word library.
In one embodiment of the present application, the method further includes an updating unit and a deleting unit:
the updating unit is configured to update the punctuation thesaurus periodically according to the unit time, where the updating unit includes: if the appearance times of the punctuation mark and candidate item combination in the punctuation word library in the updating period do not meet the preset condition, triggering the deleting unit;
and the deleting unit is used for deleting the punctuation marks and candidate item combinations which do not meet the preset conditions from the punctuation word library.
The embodiments of the present application also provide an apparatus for candidate presentation with punctuation marks, the apparatus may include a memory, and one or more programs, wherein the one or more programs are stored in the memory and configured to be executed by the one or more processors, the one or more programs including instructions for:
acquiring a character string input by a user;
judging whether candidate items corresponding to the character strings comprise candidate items meeting punctuation mark use rules or not;
if a first candidate item in the candidate items corresponding to the character string is a candidate item which accords with a punctuation mark using rule, generating a second candidate item, wherein the second candidate item is the first candidate item which uses punctuation marks in the punctuation mark using rule;
and displaying the second candidate item in a candidate item display position corresponding to the character string.
In one embodiment of the present application, the processor is further configured to invoke the program instructions stored in the memory to perform the following operations: the displaying the second candidate item in the candidate item display position corresponding to the character string includes:
and simultaneously displaying the first candidate item and the second candidate item in a candidate item display page corresponding to the character string, wherein the candidate item display page comprises a plurality of candidate item display positions.
In one embodiment of the present application, the processor is further configured to invoke the program instructions stored in the memory to perform the following operations: and the candidate item display page for simultaneously displaying the first candidate item and the second candidate item is the first page of the candidate item display page corresponding to the character string.
In one embodiment of the present application, the processor is further configured to invoke the program instructions stored in the memory to perform the following operations: further comprising:
judging whether candidate items corresponding to the character strings comprise candidate items input in the historical input data or not according to the historical input data, wherein the historical input data comprise input punctuation marks and candidate item combinations;
if a third candidate item in the candidate items corresponding to the character string is a candidate item in the historical input data, generating a fourth candidate item, wherein the fourth candidate item is a combination of a punctuation mark in the historical input data and the third candidate item;
and displaying the fourth candidate item in a candidate item display position corresponding to the character string.
In one embodiment of the present application, the processor is further configured to invoke the program instructions stored in the memory to perform the following operations: the historical input data comprises a combination of punctuation marks and candidate items input by the user and/or a group in which the user is located.
In one embodiment of the present application, the processor is further configured to invoke the program instructions stored in the memory to perform the following operations: before the step of presenting the fourth candidate in the candidate display position corresponding to the character string, the method further includes:
judging whether the fourth candidate item and the second candidate item are consistent;
and if the character string is consistent with the second candidate item, the step of displaying the second candidate item in the candidate item display position corresponding to the character string is executed.
In one embodiment of the present application, the processor is further configured to invoke the program instructions stored in the memory to perform the following operations: further comprising:
counting the occurrence times of the combination of the punctuation marks and the candidate items in the historical input data in unit time;
combining punctuation marks and candidate items, the occurrence times of which meet preset conditions in unit time, to establish a punctuation word library;
the judging whether the candidate items corresponding to the character strings include the candidate items input in the historical input data according to the historical input data includes:
judging whether the candidate items corresponding to the character strings comprise the candidate items in the punctuation word library or not according to the punctuation word library;
if the third candidate item in the candidate items corresponding to the character string is the candidate item in the historical input data, generating a fourth candidate item, including:
and if the third candidate item in the candidate items corresponding to the character string is the candidate item in the punctuation word library, generating a fourth candidate item.
In one embodiment of the present application, the processor is further configured to invoke the program instructions stored in the memory to perform the following operations: further comprising:
periodically updating the punctuation thesaurus according to the unit time, wherein the updating comprises the following steps: and if the appearance times of the punctuation marks and the candidate item combinations in the punctuation word library in the updating period do not meet the preset condition, deleting the punctuation marks and the candidate item combinations which do not meet the preset condition from the punctuation word library.
Fig. 4 is a block diagram illustrating an apparatus 400 for text pronunciation as a terminal according to an exemplary embodiment. For example, the apparatus 400 may be a mobile phone, a computer, a digital broadcast terminal, a messaging device, a game console, a tablet device, a medical device, an exercise device, a personal digital assistant, and the like.
Referring to fig. 4, the apparatus 400 may include one or more of the following components: processing components 402, memory 404, power components 406, multimedia components 408, audio components 410, input/output (I/O) interfaces 412, sensor components 414, and communication components 416.
The processing component 402 generally controls overall operation of the apparatus 400, such as operations associated with display, telephone calls, data communications, camera operations, and recording operations. The processing element 402 may include one or more processors 420 to execute instructions to perform all or part of the steps of the methods described above. Further, the processing component 402 can include one or more modules that facilitate interaction between the processing component 402 and other components. For example, the processing component 402 can include a multimedia module to facilitate interaction between the multimedia component 408 and the processing component 402.
The memory 404 is configured to store various types of data to support operations at the device 400. Examples of such data include instructions for any application or method operating on the device 400, contact data, phonebook data, messages, pictures, videos, and so forth. The memory 404 may be implemented by any type or combination of volatile or non-volatile memory devices such as Static Random Access Memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic or optical disks.
The power supply component 406 provides power to the various components of the device 400. The power components 406 may include a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power for the apparatus 400.
The multimedia component 408 includes a screen that provides an output interface between the device 400 and the user. In some embodiments, the screen may include a Liquid Crystal Display (LCD) and a Touch Panel (TP). If the screen includes a touch panel, the screen may be implemented as a touch screen to receive an input signal from a user. The touch panel includes one or more touch sensors to sense touch, slide, and gestures on the touch panel. The touch sensor may not only sense the boundary of a touch or slide motion action, but also detect the duration and pressure associated with the touch or slide operation. In some embodiments, the multimedia component 408 includes a front facing camera and/or a rear facing camera. The front-facing camera and/or the rear-facing camera may receive external multimedia data when the device 400 is in an operational mode, such as a shooting mode or a video mode. Each front camera and rear camera may be a fixed optical lens system or have a focal length and optical zoom capability.
The audio component 410 is configured to output and/or input audio signals. For example, audio component 410 includes a Microphone (MIC) configured to receive external audio signals when apparatus 400 is in an operational mode, such as a call mode, a recording mode, and a voice recognition mode. The received audio signals may further be stored in the memory 404 or transmitted via the communication component 416. In some embodiments, audio component 410 also includes a speaker for outputting audio signals.
The I/O interface 412 provides an interface between the processing component 402 and peripheral interface modules, which may be keyboards, click wheels, buttons, etc. These buttons may include, but are not limited to: a home button, a volume button, a start button, and a lock button.
The sensor component 414 includes one or more sensors for providing various aspects of state assessment for the apparatus 400. For example, the sensor component 414 can detect the open/closed state of the device 400, the relative positioning of components, such as a display and keypad of the apparatus 400, the sensor component 414 can also detect a change in the position of the apparatus 400 or a component of the apparatus 400, the presence or absence of user contact with the apparatus 400, orientation or acceleration/deceleration of the apparatus 400, and a change in the temperature of the apparatus 400. The sensor assembly 414 may include a proximity sensor configured to detect the presence of nearby items without any physical contact. The sensor assembly 414 may also include a light sensor, such as a CMOS or CCD image sensor, for use in imaging applications. In some embodiments, the sensor assembly 414 may also include an acceleration sensor, a gyroscope sensor, a magnetic sensor, a pressure sensor, or a temperature sensor.
The communication component 416 is configured to facilitate wired or wireless communication between the apparatus 400 and other devices. The apparatus 400 may access a wireless network based on a communication standard, such as WiFi, 2G or 4G, or a combination thereof. In an exemplary embodiment, the communication component 416 receives broadcast signals or broadcast related information from an external broadcast management system via a broadcast channel. In an exemplary embodiment, the communication component 416 further includes a Near Field Communication (NFC) module to facilitate short-range communications. For example, the NFC module may be implemented based on Radio Frequency Identification (RFID) technology, infrared data association (IrDA) technology, Ultra Wideband (UWB) technology, Bluetooth (BT) technology, and other technologies.
In an exemplary embodiment, the apparatus 400 may be implemented by one or more Application Specific Integrated Circuits (ASICs), Digital Signal Processors (DSPs), Digital Signal Processing Devices (DSPDs), Programmable Logic Devices (PLDs), Field Programmable Gate Arrays (FPGAs), controllers, micro-controllers, microprocessors or other electronic components for performing the above-described methods.
In an exemplary embodiment, a non-transitory computer-readable storage medium comprising instructions, such as the memory 404 comprising instructions, executable by the processor 420 of the apparatus 400 to perform the above-described method is also provided. For example, the non-transitory computer readable storage medium may be a ROM, a Random Access Memory (RAM), a CD-ROM, a magnetic tape, a floppy disk, an optical data storage device, and the like.
Fig. 5 is a schematic diagram of a server in some embodiments of the present application. The server 500 may vary widely in configuration or performance and may include one or more Central Processing Units (CPUs) 522 (e.g., one or more processors) and memory 532, one or more storage media 530 (e.g., one or more mass storage devices) storing applications 552 or data 555. Memory 532 and storage media 530 may be, among other things, transient storage or persistent storage. The program stored on the storage medium 530 may include one or more modules (not shown), each of which may include a series of instruction operations for the server. Still further, the central processor 522 may be configured to communicate with the storage medium 530, and execute a series of instruction operations in the storage medium 530 on the server 500.
The server 500 may also include one or more power supplies 526, one or more wired or wireless network interfaces 550, one or more input-output interfaces 558, one or more keyboards 556, and/or one or more operating systems 551, such as Windows Server, Mac OS XTM, UnixTM, LinuxTM, FreeBSDTM, etc.
A non-transitory computer-readable storage medium in which instructions, when executed by a processor of an apparatus (terminal or server), enable the apparatus to perform a method of generating a video, the method comprising:
acquiring a character string input by a user;
judging whether the candidate items corresponding to the character strings comprise candidate items meeting punctuation mark use rules or not;
if a first candidate item in the candidate items corresponding to the character string is a candidate item which accords with a punctuation mark using rule, generating a second candidate item, wherein the second candidate item is the first candidate item which uses punctuation marks in the punctuation mark using rule;
and displaying the second candidate item in a candidate item display position corresponding to the character string.
Other embodiments of the present application will be apparent to those skilled in the art from consideration of the specification and practice of the application disclosed herein. This application is intended to cover any variations, uses, or adaptations of the invention following, in general, the principles of the application and including such departures from the present disclosure as come within known or customary practice in the art to which the invention pertains. It is intended that the specification and examples be considered as exemplary only, with a true scope and spirit of the application being indicated by the following claims.
It will be understood that the present application is not limited to the precise arrangements described above and shown in the drawings and that various modifications and changes may be made without departing from the scope thereof. The scope of the application is limited only by the attached claims
The above description is only a preferred embodiment of the present application and should not be taken as limiting the present application, and any modifications, equivalents, improvements and the like that are made within the spirit and principle of the present application should be included in the protection scope of the present application.
The text pronunciation device provided by the present application is introduced in detail, and a specific example is applied in the text to explain the principle and the implementation of the present application, and the description of the above example is only used to help understand the method and the core idea of the present application; meanwhile, for a person skilled in the art, according to the idea of the present application, there may be variations in the specific embodiments and the application scope, and in summary, the content of the present specification should not be construed as a limitation to the present application.

Claims (10)

1. A method for presenting candidate items with punctuation marks, the method comprising:
acquiring a character string input by a user;
judging whether the candidate items corresponding to the character strings comprise candidate items meeting punctuation mark use rules or not;
if a first candidate item in the candidate items corresponding to the character string is a candidate item which accords with a punctuation mark using rule, generating a second candidate item, wherein the second candidate item is the first candidate item which uses punctuation marks in the punctuation mark using rule;
displaying the second candidate item in a candidate item display position corresponding to the character string;
judging whether candidate items corresponding to the character strings comprise candidate items input in the historical input data or not according to the historical input data, wherein the historical input data comprise input punctuation marks and candidate item combinations;
if a third candidate item in the candidate items corresponding to the character string is a candidate item in the historical input data, generating a fourth candidate item, wherein the fourth candidate item is a combination of a punctuation mark in the historical input data and the third candidate item;
and displaying the fourth candidate item in a candidate item display position corresponding to the character string.
2. The method of claim 1, wherein said presenting the second candidate in a candidate display position corresponding to the character string comprises:
and simultaneously displaying the first candidate item and the second candidate item in a candidate item display page corresponding to the character string, wherein the candidate item display page comprises a plurality of candidate item display positions.
3. The method of claim 2, wherein the candidate presentation page that simultaneously presents the first candidate and the second candidate is a first page of the candidate presentation page corresponding to the character string.
4. The method of claim 1, wherein the historical input data comprises a combination of punctuation marks and candidates entered by the user and/or a group in which the user is located.
5. The method of claim 1, wherein prior to said step of presenting said fourth candidate in a candidate display position corresponding to said character string, further comprising:
judging whether the fourth candidate item and the second candidate item are consistent;
and if the character string is consistent with the second candidate item, the step of displaying the second candidate item in the candidate item display position corresponding to the character string is executed.
6. The method of claim 1, further comprising:
counting the occurrence times of the combination of the punctuation marks and the candidate items in the historical input data in unit time;
combining punctuation marks and candidate items, the occurrence times of which meet preset conditions in unit time, to establish a punctuation word library;
the judging whether the candidate items corresponding to the character strings include the candidate items input in the historical input data according to the historical input data includes:
judging whether the candidate items corresponding to the character strings comprise the candidate items in the punctuation word library or not according to the punctuation word library;
if the third candidate item in the candidate items corresponding to the character string is a candidate item in the historical input data, generating a fourth candidate item, including:
and if the third candidate item in the candidate items corresponding to the character string is the candidate item in the punctuation word library, generating a fourth candidate item.
7. The method of claim 6, further comprising:
periodically updating the punctuation thesaurus according to the unit time, wherein the updating comprises the following steps: and if the appearance times of the punctuation marks and the candidate item combinations in the punctuation word library in the updating period do not meet the preset condition, deleting the punctuation marks and the candidate item combinations which do not meet the preset condition from the punctuation word library.
8. A candidate item display device with punctuation marks is characterized by comprising a first acquisition unit, a first judgment unit, a first generation unit, a first display unit, a second judgment unit, a second generation unit and a third display unit:
the first acquisition unit is used for acquiring a character string input by a user;
the first judging unit is used for judging whether the candidate items corresponding to the character strings comprise candidate items meeting the punctuation mark using rule; if a first candidate item in the candidate items corresponding to the character string is a candidate item which meets the punctuation mark use rule, triggering a first generation unit;
the first generating unit is configured to generate a second candidate, where the second candidate is the first candidate using punctuation marks in the punctuation mark usage rule;
the first display unit is used for displaying the second candidate item in a candidate item display position corresponding to the character string;
the second judging unit is used for judging whether the candidate items corresponding to the character string comprise the candidate items input in the historical input data or not according to the historical input data, and the historical input data comprises input punctuation marks and candidate item combinations; if a third candidate item in the candidate items corresponding to the character string is a candidate item in the historical input data, triggering a second generation unit;
the second generating unit is used for generating a fourth candidate item, wherein the fourth candidate item is a combination of a punctuation mark in the historical input data and the third candidate item;
the third presentation unit is configured to present the fourth candidate in a candidate presentation position corresponding to the character string.
9. A presentation apparatus with punctuation candidates, comprising a memory, and one or more programs, wherein the one or more programs are stored in the memory and configured to be executed by one or more processors, the one or more programs comprising instructions for:
acquiring a character string input by a user;
judging whether candidate items corresponding to the character strings comprise candidate items meeting punctuation mark use rules or not;
if a first candidate item in the candidate items corresponding to the character string is a candidate item which accords with a punctuation mark using rule, generating a second candidate item, wherein the second candidate item is the first candidate item which uses punctuation marks in the punctuation mark using rule;
and displaying the second candidate item in a candidate item display position corresponding to the character string.
10. A machine-readable medium having a candidate presentation of punctuation marks stored thereon instructions which, when executed by one or more processors, cause an apparatus to perform the method of candidate presentation of punctuation marks as recited in one or more of claims 1-7.
CN201710414527.2A 2017-06-05 2017-06-05 Candidate item display method and device with punctuation marks Active CN108983992B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710414527.2A CN108983992B (en) 2017-06-05 2017-06-05 Candidate item display method and device with punctuation marks

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710414527.2A CN108983992B (en) 2017-06-05 2017-06-05 Candidate item display method and device with punctuation marks

Publications (2)

Publication Number Publication Date
CN108983992A CN108983992A (en) 2018-12-11
CN108983992B true CN108983992B (en) 2022-07-08

Family

ID=64502682

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710414527.2A Active CN108983992B (en) 2017-06-05 2017-06-05 Candidate item display method and device with punctuation marks

Country Status (1)

Country Link
CN (1) CN108983992B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112328097A (en) * 2020-11-16 2021-02-05 维沃移动通信有限公司 Input control method and device

Family Cites Families (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS62237565A (en) * 1986-04-08 1987-10-17 Seiko Epson Corp Sentence input device
JP2009116716A (en) * 2007-11-08 2009-05-28 Sharp Corp Character input device
CN101493729B (en) * 2008-01-24 2011-01-12 普天信息技术研究院有限公司 Multi-type character mixing input method
CN101655846A (en) * 2008-08-21 2010-02-24 联想移动通信科技有限公司 Punctuation correlation method and punctuation correlation device of Chinese input method
CN101727201A (en) * 2009-12-14 2010-06-09 北京搜狗科技发展有限公司 Method and device for automatically adjusting symbol rank and input method system
CN102445994B (en) * 2010-09-30 2018-05-04 北京搜狗科技发展有限公司 A kind of intelligent input method and input method system
US8782550B1 (en) * 2013-02-28 2014-07-15 Google Inc. Character string replacement
CN106648134A (en) * 2016-10-14 2017-05-10 北京搜狗科技发展有限公司 Input method and device
CN106484138B (en) * 2016-10-14 2019-11-19 北京搜狗科技发展有限公司 A kind of input method and device
CN106774977A (en) * 2016-12-14 2017-05-31 北京小米移动软件有限公司 Punctuation mark automatic matching method, device and terminal device

Also Published As

Publication number Publication date
CN108983992A (en) 2018-12-11

Similar Documents

Publication Publication Date Title
US10296201B2 (en) Method and apparatus for text selection
EP3173948A1 (en) Method and apparatus for recommendation of reference documents
CN108121736B (en) Method and device for establishing subject term determination model and electronic equipment
CN112291614A (en) Video generation method and device
CN107564526B (en) Processing method, apparatus and machine-readable medium
CN107784037B (en) Information processing method and device, and device for information processing
CN108983992B (en) Candidate item display method and device with punctuation marks
CN109799916B (en) Candidate item association method and device
CN108108356B (en) Character translation method, device and equipment
CN110781689B (en) Information processing method, device and storage medium
CN110780749B (en) Character string error correction method and device
CN113589956A (en) Commonly used word processing method and device, mobile terminal and storage medium
CN109308126B (en) Candidate word display method and device
CN109753205B (en) Display method and device
CN109144286B (en) Input method and device
CN107977089B (en) Input method and device and input device
CN111178086A (en) Data processing method, apparatus and medium
CN107870932B (en) User word stock optimization method and device and electronic equipment
US10423706B2 (en) Method and device for selecting information
CN110765338A (en) Data processing method and device and data processing device
CN112083811B (en) Candidate item display method and device
CN110716653B (en) Method and device for determining association source
CN112905079B (en) Data processing method, device and medium
WO2022105229A1 (en) Input method and apparatus, and apparatus for inputting
CN111460836B (en) Data processing method and device for data processing

Legal Events

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