Summary of the invention
Just must in user's input process, can upgrade the problem that can't when browsing, therefrom upgrade interim dictionary that interim dictionary causes in order to solve in the prior art, the embodiment of the invention has proposed a kind of user's speech adding method and device of input method.Said technical scheme is following:
The embodiment of the invention has proposed a kind of user's speech adding method of input method, it is characterized in that, comprising:
When the user carried out replicate run, the content record that the user is duplicated arrived in the interim dictionary; And write down said content corresponding codes character string of duplicating;
When user's input coding character string, read said interim dictionary, will show with the corresponding words of said coded string in the said interim dictionary; When the user selects this words, this words and corresponding codes character string are added in the user thesaurus.
Preferred as technique scheme, said when the user carries out replicate run, the content record that the user is duplicated comprises in interim dictionary:
When said system clipboard content increases, the content that increases in the said system clipboard is added in the said interim dictionary.
Preferred as technique scheme, said method also comprises: when meeting prerequisite, said interim dictionary is emptied.
Preferred as technique scheme, said when meeting prerequisite, said interim dictionary being emptied comprises:
When said system clipboard content increases, judge the preset registry entry that whether has the volatile type in the registration table, if then said content is added in the said interim dictionary; If not, then in registration table, add said preset registry entry, and said interim dictionary is emptied; Said content is increased in the said interim dictionary.
Preferred as technique scheme, said method also comprises:
Judge whether the content of said increase all is made up of Chinese character, and wherein the length of Chinese character whether less than preset length; If then the content of said increase is added in the said interim dictionary.
Preferred as technique scheme, said method also comprises:
When comprising polyphone in the said words, all coded strings that this words is corresponding add in the said user thesaurus.
The embodiment of the invention has also proposed a kind of user's speech adding set of input method, comprising:
Add module, be used for when the user carries out replicate run, the content record that the user is duplicated arrives in the interim dictionary;
Logging modle is used to write down said content corresponding codes character string of duplicating;
Display module is used for when user's input coding character string, reading said interim dictionary, will show with the corresponding words of said coded string in the said interim dictionary; When the user selects this words, this words and corresponding codes character string are added in the user thesaurus.
Preferred as technique scheme, said interpolation module comprises:
The content adding device is used for when said system clipboard content increases, the content that increases in the said system clipboard being added in the said interim dictionary.
Preferred as technique scheme empties said interim dictionary when meeting prerequisite.
Preferred as technique scheme, said content adding device comprises:
Judgment sub-unit is used for judging whether registration table exists the preset registry entry of volatile type, if not, then in registration table, adds said preset registry entry, and said interim dictionary is emptied;
Add subelement, be used for the content that increases in the said system clipboard is added in the said interim dictionary.
Preferred as technique scheme, said device also comprises:
Matching module judges whether the content of said increase all is made up of Chinese character, and wherein the length of Chinese character whether less than preset length; If then the content of said increase is added in the said interim dictionary.
Preferred as technique scheme, when comprising polyphone in the said words, all coded strings that said display module is corresponding with this words add in the said user thesaurus.
The beneficial effect of the technical scheme that the embodiment of the invention provides is: the embodiment of the invention can will make the user when carrying out files such as network browsing or browsing document, and wherein words is added in the interim dictionary.When the user imports through input method, words in this interim dictionary and the words in the user thesaurus are shown to the user, and the words of selecting according to the user upgrades to user thesaurus.Can make the user need not complicated input process like this, can from the content of duplicating, select words, and user thesaurus is upgraded.Simultaneously, can not make interim dictionary too too fat to move again.
Embodiment
For making the object of the invention, technical scheme and advantage clearer, will combine accompanying drawing that embodiment of the present invention is done to describe in detail further below.
The mentality of designing of the embodiment of the invention is: user for ease, the content stores that the user is duplicated is in interim dictionary.When the user imports through input method, words in this interim dictionary and the words in the user thesaurus are shown to the user.Like this, just can upgrade user thesaurus, that is: receive the coded string of user's input and the words of the correspondence that the user selects, if this words not in the user thesaurus then adds this words in the interim dictionary to through mode of the prior art.
Below through embodiment the present invention is further illustrated.
Embodiment 1
First embodiment of the invention has proposed a kind of user's speech adding method of input method, and its flow process comprises as shown in Figure 1:
Step 101, when the user carries out replicate run, the content record that the user is duplicated is in interim dictionary;
Step 102, the said content corresponding codes character string of duplicating of record;
Step 103, when user's input coding character string, read said interim dictionary, will be in the said interim dictionary show with the corresponding words of said coded string; When the user selects this words, this words and corresponding codes character string are added in the user thesaurus.
The embodiment of the invention can will make the user when carrying out files such as network browsing or browsing document, and wherein words is added in the interim dictionary.When the user imports through input method, words in this interim dictionary and the words in the user thesaurus are shown to the user, and the words of selecting according to the user upgrades to user thesaurus.Can make the user need not complicated input process like this, can from the content of duplicating, select words, and user thesaurus is upgraded.Simultaneously, can not make interim dictionary too too fat to move again.
Wherein, coded string is meant the Chinese phonetic alphabet corresponding with words; For example: the pairing coded string of words " University Of Chongqing " is " Chong qing da xue ".
Embodiment 2
Second embodiment of the invention has proposed a kind of user's speech adding method of input method, is on the first embodiment basis, to improve, and comprising:
Step 201, when the user carries out replicate run, the content record that the user is duplicated is in interim dictionary.
Wherein, existing words compares in the words in order to prevent to duplicate in the interim dictionary in the step 201, the content that the user can be duplicated and interim dictionary, if not then this content is added in the interim dictionary; If? Then do not handle.Can prevent that so interim dictionary is too too fat to move.
Wherein, in the step 201, can obtain the content that the user duplicates through system clipboard.That is: when said system clipboard content increases, the content that increases in the said system clipboard is added in the said interim dictionary.
In one embodiment of the invention, what step 201 can be as shown in Figure 2, be specially:
Step 2011, supervisory system clipbook;
Step 2012, when the content of said system clipboard increases, the content that increases in the said system clipboard is added in the said interim dictionary.
Certainly, obtaining the content that the user duplicates through the mode of supervisory system clipbook is a concrete embodiment of the present invention.Those skilled in that art are appreciated that and can also adopt other to obtain the content that increases in the system clipboard, come system clipboard is monitored and need not to be provided with step 2011, in the embodiment of the invention not as limit.
System clipboard is a prior art.Selected the words in the files such as browser or document as the user, and through the right mouse button menu or through " Ctrl+C " when shortcut duplicates, system with this words content stores of duplicating in this system clipboard.Can obtain the content that the user duplicates through monitoring existing systems clipbook in the embodiment of the invention.Certainly, this just illustrates, and can also adopt other modes to obtain the content that the user duplicates, and the embodiment of the invention is not as limit.
Wherein, the interim dictionary described in the step 201 is an independently dictionary of the embodiment of the invention be provided with, when meeting prerequisite, said interim dictionary is emptied.Interim dictionary adopts and same file layout and the internal memory form of user thesaurus.Need not independent exploitation like this can use, and interim dictionary is easy to from interim dictionary, obtain words to be shown to the user as alternative word with the identical input method that can make of form of user thesaurus.Wherein, prerequisite can for: when the system start-up; Or, when logging off; Or, when starting input method; Or, when the user carries out replicate run for the first time.Mode to interim dictionary empties can freely be set as required, and the embodiment of the invention is not made qualification to this.Doing like this is to cause a large amount of rubbish speech to add interim dictionary to for fear of some replicate run of not planning to add user's speech, thereby influences user's normal input.Simultaneously, can reduce the capacity of interim dictionary, prevent the unwanted speech of user is added in the interim dictionary.
Wherein, to be that example is elaborated when the user carries out replicate run for the first time, then step 2012 can be specially:
When said system clipboard content increases, judge the preset registry entry that whether has the volatile type in the registration table; If then said content is added in the said interim dictionary; Otherwise in registration table, add said preset registry entry, and said interim dictionary is emptied; Said content is increased in the said interim dictionary.
Wherein, the registry entry of volatile type can restarted back deletion automatically.The present invention adopts the registry entry of a volatile type, and system can will delete to registry entry after restarting.Therefore, whether when the content of reading system clipbook, reading earlier has this preset registry entry in the registration table, if not then explanation is for the first time this system clipboard to be operated, should empty by interim dictionary earlier.In the time of can after restarting, using interim dictionary for the first time like this, reduce system load, prevent that the interim dictionary of the embodiment of the invention is too too fat to move.
Certainly, the registry entry that adopts the volatile type just illustrates restarting the mode that the back empties this interim dictionary, can also adopt other modes that interim dictionary is emptied, in the embodiment of the invention not as limit.Simultaneously, can not adopt interim dictionary in the embodiment of the invention, or interim dictionary not emptied.
Further, can also further filter this interim dictionary in the step 201, that is: said method also comprises again:
Judge whether the content of said increase all is made up of Chinese character, and wherein the length of Chinese character whether less than preset length; If then the content of said increase is added in the said interim dictionary.
Be owing to comprise the content of non-Chinese character or the content that length surpasses predetermined length like this, need not to add and advance in the interim dictionary, in case major structure becomes interim dictionary too too fat to move.
Step 202, the said content corresponding codes character string of duplicating of record.
Interim dictionary of the prior art all is that words and words corresponding codes character string are stored together, to show corresponding words when user's input coding character string.In the step 202 of the embodiment of the invention, also with the content stores that the user duplicated in the step 201, the words of correspondence is shown when user's input coding character string.Need carry out backward process to existing dictionary like this, to inquire each word corresponding codes character string.
Owing to can have polyphone, so in the embodiment of the invention, when comprising polyphone in the said words, all coded strings that this words is corresponding add in the said user thesaurus to.For example:
The user copies a speech " University Of Chongqing ", and wherein the pronunciation of each word is following
Heavy (zh ò ng, ch ó ng)
Celebrating (q ì ng)
(d à, d à i) greatly
Learn (xu é)
All coded string combinations all can be stored in the embodiment of the invention.That is: will
Zhong qing da xue University Of Chongqing
Zhong qing dai xue University Of Chongqing
Chong qing da xue University Of Chongqing
Chong qing dai xue University Of Chongqing
These four coded strings all store in the interim dictionary of step 201.
Step 203, when user's input coding character string, read said interim dictionary, will be in the said interim dictionary show with the corresponding words of said coded string; When the user selects this words, this words is added in the user thesaurus.
Can make the user need not the input of Chinese character one by one like this, only need input coding character string (for example foregoing " chong qing da xue "), can with " University Of Chongqing " be shown to user through this interim dictionary this moment.When the user has selected " University Of Chongqing " this words, this words is added in the user thesaurus.
Further, when adding user thesaurus to, can mate user thesaurus earlier,, then not handle if this words has been arranged in the user thesaurus; If this words does not then add this words in the user thesaurus to.
User's speech adding method that the method for the step 201-step 203 of the embodiment of the invention has proposed a kind of input method can obtain the content that the user duplicates through the mode of supervisory system clipbook, and this mode is simple, can not cause system overhead to increase.Proposed a kind of mode that interim dictionary is emptied simultaneously, caused too too fat to move to prevent the long-time use in temporary word storehouse.Because the user may carry out replicate run for various purposes, therefore need judge judge wherein whether include only Chinese character and be no more than preset length to the content of duplicating.The embodiment of the invention adopts aforesaid way to reduce the complexity of interim dictionary.Because the user need be mated this interim dictionary when the input coding character string, is shown to the user to search alternative word.Reduce the complexity of interim dictionary, can improve the efficient of coupling.
Embodiment 3
Third embodiment of the invention has proposed a kind of user's speech adding set of input method, and its structure comprises as shown in Figure 3:
Add module 1, be used for when the user carries out replicate run, the content record that the user is duplicated arrives in the interim dictionary;
Logging modle 2 is used to write down said content corresponding codes character string of duplicating;
Display module 3, be used for when the user when the input method input of character string, read said interim dictionary determining whether the corresponding words of character string with user's input, if having then show said words.
The embodiment of the invention can will make the user when carrying out files such as network browsing or browsing document, and wherein words is added in the interim dictionary.When the user imports through input method, words in this interim dictionary and the words in the user thesaurus are shown to the user, and the words of selecting according to the user upgrades to user thesaurus.Can make the user need not complicated input process like this, can from the content of duplicating, select words, and user thesaurus is upgraded.Simultaneously, can not make interim dictionary too too fat to move again.
Embodiment 4
Fourth embodiment of the invention has proposed a kind of user's speech adding set of input method, is on the basis of aforesaid the 3rd embodiment, to improve, and its structure comprises as shown in Figure 4:
Add module 1, be used for when the user carries out replicate run, the content record that the user is duplicated arrives in the interim dictionary.
Wherein, add module 1 and be content record that all users are duplicated in interim dictionary, can make the temporary word storehouse as far as possible in detail and the use of being close to the users like this.Add the words in order to prevent to duplicate in the interim dictionary in the module 1, existing words compares in the content that the user can be duplicated and the interim dictionary, if not then this content is added in the interim dictionary; If? Then do not handle.
Wherein, add module 1 and can obtain the content that the user duplicates through system clipboard.That is: when said system clipboard content increases, the content that increases in the said system clipboard is added in the said interim dictionary.
In one embodiment of the invention, adding module 1 can be specially:
Monitoring unit 11 is used for the supervisory system clipbook;
Content adding device 12 is used for when said system clipboard content increases, the content that increases in the said system clipboard being added in the said interim dictionary.
Certainly, obtaining the content that the user duplicates through the mode of supervisory system clipbook is a concrete embodiment of the present invention.Those skilled in that art are appreciated that and can also adopt other to obtain the content that increases in the system clipboard, and need not to be provided with monitoring unit 11, in the embodiment of the invention not as limit.
System clipboard is a prior art.When the user has selected the words in the file, and adopt the right mouse button menu or through " Ctrl+V " when shortcut duplicates, system with this words content stores of duplicating in this system clipboard.Can obtain the content that the user duplicates through the supervisory system clipbook in the embodiment of the invention.Certainly, this just illustrates, and the embodiment of the invention is not as limit.
Wherein, add the interim dictionary described in the module 1 and be the embodiment of the invention is provided with a dictionary independently, when meeting prerequisite, said interim dictionary is emptied.Interim dictionary adopts and same file layout and the internal memory form of user thesaurus.Need not independent exploitation like this can use, and interim dictionary is easy to from interim dictionary, obtain words to be shown to the user as alternative word with the identical input method that can make of form of user thesaurus.Wherein, prerequisite can for: when the system start-up; Or, when logging off; Or, when starting input method; Or, when the user carries out replicate run for the first time.Mode to interim dictionary empties can freely be set as required, and the embodiment of the invention is not made qualification to this.Doing like this is to cause a large amount of rubbish speech to add interim dictionary to for fear of some replicate run of not planning to add user's speech, thereby influences user's normal input.Simultaneously, can reduce the capacity of interim dictionary, prevent the unwanted speech of user is added in the interim dictionary.
Wherein, to be that example is elaborated when the user carries out replicate run for the first time, content adding device 12 can be specially:
Judgment sub-unit 121 is used for judging whether registration table exists the preset registry entry of volatile type, if otherwise in registration table, add said preset registry entry, and said interim dictionary is emptied;
Add subelement 122, be used for the content that increases in the said system clipboard is added in the said interim dictionary.
Wherein, the registry entry of volatile type can restarted back deletion automatically.The present invention adopts the registry entry of a volatile type, and system can will delete to registry entry after restarting.Therefore, whether when the content of reading system clipbook, reading earlier has this preset registry entry in the registration table, if not then explanation is for the first time this system clipboard to be operated, should empty by interim dictionary earlier.In the time of can after restarting, using interim dictionary for the first time like this, reduce system load, prevent that the interim dictionary of the embodiment of the invention is too too fat to move.
Certainly, the registry entry that adopts the volatile type just illustrates restarting the mode that the back empties this interim dictionary, can also adopt other modes that interim dictionary is emptied, in the embodiment of the invention not as limit.Simultaneously, can not adopt interim dictionary in the embodiment of the invention, or interim dictionary not emptied.
Further, add in the module 1 and can also further filter this interim dictionary again, said device also comprises:
Matching module 4 judges whether the content of said increase all is made up of Chinese character, and wherein the length of Chinese character whether less than preset length; If then the content of said increase is added in the said interim dictionary.
Be owing to comprise the content of non-Chinese character or the content that length surpasses predetermined length like this, need not to add and advance in the interim dictionary.
Logging modle 2 is used to write down said content corresponding codes character string of duplicating.
Interim dictionary of the prior art all is that words and words corresponding codes character string are stored together, to show corresponding words when user's input coding character string.Owing to can have polyphone, so all coded strings that polyphone is corresponding store all in the embodiment of the invention.
Display module 3, be used for when the user when the input method input of character string, read said interim dictionary determining whether the corresponding words of character string with user's input, if having then show said words.
Owing to can have polyphone, so in the embodiment of the invention, when comprising polyphone in the said words, all coded strings that said display module 3 is corresponding with this words add in the said user thesaurus to.
The device of the embodiment of the invention can obtain the content that the user duplicates through the mode of supervisory system clipbook, and this mode is simple, can not cause system overhead to increase.Proposed a kind of mode that interim dictionary is emptied simultaneously, caused too too fat to move to prevent the long-time use in temporary word storehouse.Because the user may carry out replicate run for various purposes, therefore need judge judge wherein whether include only Chinese character and be no more than preset length to the content of duplicating.The embodiment of the invention adopts aforesaid way to reduce the complexity of interim dictionary.Because the user need be mated this interim dictionary when the input coding character string, is shown to the user to search alternative word.Reduce the complexity of interim dictionary, can improve the efficient of coupling.
The device of the embodiment of the invention third and fourth embodiment, identical with the design of the method for aforesaid first and second embodiment with principle, so in third and fourth embodiment to first and second embodiment in identical part repeat no more.
In above-mentioned each embodiment of the present invention, this user thesaurus and system's dictionary can be same dictionary, also can be different dictionaries, and the embodiment of the invention is not made qualification to this.
If the said integrated unit of the embodiment of the invention is realized with the form of SFU software functional unit and during as independently production marketing or use, also can be stored in the computer read/write memory medium.Based on such understanding; The part that technical scheme of the present invention contributes to prior art in essence in other words can be come out with the embodied of software product; This computer software product is stored in the storage medium; Comprise that some instructions are with so that a computer equipment (can be a personal computer; Server, the perhaps network equipment etc.) carry out all or part of of the said method of each embodiment of the present invention.And aforesaid storage medium comprises: various media that can be program code stored such as USB flash disk, portable hard drive, ROM (read-only memory) (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), magnetic disc or CD.
Below only be preferred embodiment of the present invention, or not all within spirit of the present invention and principle in order to restriction the present invention, any modification of being done, be equal to replacement, improvement etc., all should be included within protection scope of the present invention.