Summary of the invention
The proposition of the technical program is exactly in order to solve above-mentioned these problems that occurs.The technical program technology of calling the device of computer program operation by a kind of Chinese language text solves the problem of above-mentioned appearance specifically:
The device that the technical program adopts comprise Chinese language text load module 1, computer system 2, Chinese language text word-dividing mode 3, Chinese character and Chinese phonetics codes modular converter 7, in advance be stored in the computer program module 4 of the keyword binding in the computing machine and Chinese phonetics codes that import or the Chinese character, by the priority logical order arrangement program module of carrying out of binding 5, be stored in the program execution module 6 in the computing machine, be connected in series successively with the order of upper module according to computer treatmenting information.
The method of its operation of said apparatus and the feature of step are: at first by Chinese language text load module 1 Chinese language text is imported computer system 2, computer system 2 is carried out participle with the Chinese language text that receives by Chinese language text word-dividing mode 3, and then by being stored in the computer program module 4 of the keyword binding in the computing machine and Chinese phonetics codes that import or the Chinese character in advance, Chinese phonetics codes or the keyword in the Chinese character imported are carried out the binding of computer program, correctly arrange and be connected by arrange computer program that the program module of bind 5 will carry out by the priority logical order of carrying out at last, and be transferred to program execution module 6 friendship computer systems 2 execution that are stored in the computing machine.
If what computer program was only bound with Chinese phonetics codes and computer system 2 receives is Chinese-character text, at first by Chinese language text load module 1 Chinese language text is imported computer system 2, computer system 2 is carried out participle with the Chinese language text that receives by Chinese language text word-dividing mode 3, and then will divide the Chinese character of word to convert the Chinese phonetics codes of forming with ASCII character to by Chinese character and Chinese phonetics codes modular converter 7, and then by being stored in the computer program module 4 of the keyword binding in the computing machine and Chinese phonetics codes that import or the Chinese character in advance, keyword in the Chinese phonetics codes that converts to is carried out the binding of computer program, correctly arrange and be connected by arrange computer program that link block 5 will carry out by the priority logical order of carrying out at last, and be transferred to the program execution modules 6 that are stored in the computer system 2 and hand over computer systems 2 to carry out.
Above-mentioned Chinese language text load module can be the specific input keyboard load module of standard English keyboard module or Chinese character, perhaps handwriting input module, perhaps optical scanning load module, perhaps cable network load module, perhaps wireless network load module, perhaps less radio-frequency load module, computer stored EM equipment module.
Above-mentioned computer system 2 can be desktop computer or notebook computer or server or cloud computing machine system, also can be embedded computer system.
Computer system 2 is when the commencement of commercial operation program, be divided into two kinds of mode operations, a kind of is automatic operational mode, this pattern is carried out the operation of program according to computing machine automatically to the understanding of receiving Chinese language text, and the function that the program that brings into operation will reach is exported with the phonetic synthesis form of Chinese language text or this Chinese language text; Another kind is the inquiry affirmation mode, under this pattern 2 pairs of computer systems the Chinese language text of receiving correctly proofread and correct optimization with executive routine earlier, and feed back that a process is correct proofreaies and correct and the Chinese language text of executive routine optimization, this Chinese language text also can be carried out after confirming through the form output of phonetic synthesis module with voice.
Above-mentioned Chinese phonetics codes is to be unit spelling with the word with 26 Latin alphabets, here regard single Chinese character as monosyllable, according to the phonetic in " Scheme for the Chinese Phonetic Alphabet " of each syllable of forming this word, with and only use 26 Latin alphabets to the initial consonant of the Chinese phonetic alphabet, referral letter, simple or compound vowel of a Chinese syllable, tone is taked to encode earlier and is spelt by the sequential encoding of " the sign indicating number+sign indicating number+rhythm sign indicating number that is situated between+double sound insulation of accent sign indicating number saves symbol " successively, and directly express Chinese information by the coding of the phonetic code that obtains, when direct term syllable code is represented Chinese information, its usage in punctuation is identical with English usage in punctuation, a plurality of syllables of same word will have the space to separate without the space continuous programming code during coding between word and the word.
Because the Chinese phonetics codes that the technical program adopts 26 Latin alphabets to represent is expressed Chinese information, and when direct term syllable code is represented Chinese information, its usage in punctuation is identical with English usage in punctuation, like this with regard to the expression punctuation mark that guaranteed Chinese information interior all in full accord with ASCII character, also namely with ASCII character 100% compatibility, so just guaranteed that total system can move in the computing machine of ASCII character system.
Because the running environment of computer programming language generally is the ASCII character environment, therefore had after the technical program, Chinese language text information can be as the English computer program that calls easily on the one hand, make things convenient for the non-computer programming personnel to call computer program with the mode of nature text language on the other hand, thereby these computer programs that call are realized various Computerized intelligent controls by computer run.
Embodiment
Be further described below in conjunction with the specific embodiment of the present invention of embodiment.
(1) following method is adopted in the coding method of each syllable sound, rhyme, tone of the Chinese phonetics codes that adopts of the technical program:
Annotate: the symbol behind the dash "-" is Chinese phonetic symbols, and the preceding letter of dash "-" is the coding of each syllable sound, rhyme, tone of Chinese of adopting, below all with, below abbreviate the following table of comparisons as code table.
Here it is worthy of note: when keying in the punctuation mark of Chinese phonetics codes and Chinese phonetics codes statement with keyboard, 26 Latin alphabets forming the Chinese phonetics codes coding are identical corresponding fully one by one with 26 letter keys of western language QWERTY keyboard, the punctuation mark key of Chinese phonetics codes statement is also identical corresponding one by one with the punctuation mark key of western language QWERTY keyboard, when input Chinese speech code letter and punctuation mark, the corresponding same keys position that only need impact the western language QWERTY keyboard gets final product.
1, the coded identification of sound sign indicating number adopts the letter character with the initial consonant of Scheme for the Chinese Phonetic Alphabet basically identical, such as the coding form of this sound sign indicating number below adopting:
b—b ; p—p ; m—m ; f—f ; d—d ; t—t ;
n—n ; l—l ; g—g ; k—k ; h—h ;
j—zh,?j?; q—ch,q ; x—sh,x ;r—r ;
z—z ; c—c ; s—s ; y—y ; w—w 。
2, Chinese phonetic alphabet referral letter (ü) adopts a letter representation in 26 Latin alphabets, such as the coding form of this sign indicating number that is situated between below adopting:
i—i ; u—u ; y—ü 。
3, the coding of rhythm sign indicating number, to the letter representation of single vowel in 26 Latin alphabets of (ü) employing, other adopts the letter character identical with the Chinese phonetic alphabet, the composite vowel of the Chinese phonetic alphabet can adopt " Scheme for the Chinese Phonetic Alphabet " identical form, also can adopt a consonant to encode, come the simple or compound vowel of a Chinese syllable of the Chinese phonetic alphabet is encoded such as this letter character below adopting:
a—a ; o—o ; e—e ; i—i ; u—u ; y—ü ;
k—ao?; c—?ai ; s—an ; x—ou?; w—ei ; n—en ;
z—ua ; l—uo ; b—ang ; d—ong ; p—eng ;
q—ing ;?g—ng ; er—er ;
R-i; " when i only pieced together mutually with Chinese Pin Yin pseudonym zh, ch, sh, the i of the Chinese phonetic alphabet represented with the coding r of phonetic code ".That is: the zhi of the Chinese phonetic alphabet, chi, shi represent with jr, qr, the xr of phonetic code respectively.Press two key position inputs of J and R or Q and R or X and R and E and R when jr or qr or xr and the input of er keyboard respectively.
4, the coding of transferring sign indicating number is except adopting a no consonant v of Chinese to represent going up the sound (∨) of the Chinese phonetic alphabet, and other adopts vowel to represent the tone of Chinese, comes the tone of the Chinese phonetic alphabet is encoded such as the letter below adopting:
A---, high and level tone; E-/, rising tone; V-∨, last sound; U-, falling tone;
O-phonetic is not marked tone mark softly, softly.
(2) utilize the Chinese phonetics codes Chinese information of above-mentioned coding to represent to adopt following method:
Be unit with the word, here regard single Chinese character as monosyllable, according to the phonetic in " Scheme for the Chinese Phonetic Alphabet " of each syllable of forming this word, press the sequential encoding of " the sound sign indicating number+sign indicating number+rhythm sign indicating number that is situated between+double sound insulation of accent sign indicating number saves symbol " successively, a plurality of syllables of same word separate write the two or more syllables of a word together without the space, and the coding between word and the word separates with the space, when Chinese information represents to be in the Chinese phonetics codes state, its six kinds of periods, seven kinds of labels adopt and English identical form with the number of dividing a word with a hyphen at the end of a line;
Here owing to regard the independent Chinese character that uses as monosyllable, therefore, the method of encode Chinese characters for computer of the present invention is identical with Chinese single syllable Methods for Coding, adopt the single syllable coding by obtaining the word coding behind the word write the two or more syllables of a word together in the present invention, we will be called phrase by one group of word that several words are formed, the coding of phrase that the present invention adopts is identical with the coding of Chinese sentence, because phrase and Chinese sentence can be represented in word, therefore the coding of the coding of the phrase that adopts in the present invention and Chinese sentence can be realized by the coding of word, and do not need the special coding of a cover formulated in addition in phrase and Chinese sentence, generally when whole sentence entire chapter is the unit representation Chinese information with the word, when understanding, generally do not need to carry out the selection of unisonance words, sound the sentence that can not produce ambiguity in principle, also can not produce ambiguity when expressing with coding.
Text with the Chinese sentence of an input computing machine is the specific implementation step that example illustrates the technical program below:
Such as at first by Chinese language text load module 1 we to the Chinese language text of the following Chinese-character text content of computer system 2 inputs of a control air-conditioning:
" this afternoon 2 the meeting room air-conditioning of naming a person for a particular job open, at first ventilated 10 minutes, then room temperature is remained on 25 degree.”
After the above-mentioned Chinese language text input computer system 2, computer system 2 is carried out participle with the Chinese language text that receives by Chinese language text word-dividing mode 3, obtains the text of the good word of following branch:
" this afternoon 2 the meeting room air-conditioning of naming a person for a particular job open, at first ventilated 10 minutes, then room temperature is remained on 25 degree.”
Above-mentioned Chinese sentence with the Chinese speech representation is:
Zcu jinatisa xiauwuv 2disv jiba huiuyiuxru kdatikv davkca, xxvxisa tdafpa 10 fnajda, rxvhxu jiba xruwna bkvqre zcu 25?duu.
And then by being stored in the computer program module 4 of the keyword binding in the computing machine and Chinese phonetics codes that import or the Chinese character in advance, Chinese phonetics codes or the keyword in the Chinese character imported are carried out the binding of computer program, and concrete binding procedure is as follows:
Here the Chinese meaning represented with Chinese character of jinatisa is " today ", after this keyword is extracted out, computing machine can remove to look into calendar, find the date of today such as being on February 1st, 2013, computing machine will extract this date the program date parameter that starts as air conditioner ventilation and join in the program of air conditioner ventilation startup, in like manner " xiauwuv 2 disv " Chinese meaning of representing with Chinese character is " 2 pm ", after this keyword sets is extracted out, if computing machine is can automatically it be converted into 14 points by 24 hours computer chronographs, and this time is extracted the program time parameter of opening as air-conditioning join in the program of opening air-conditioning, if by timing in 12 o'clock, then computing machine this directly this time is extracted as the program time parameter of opening air-conditioning and joins in the program of opening air-conditioning, here the Chinese meaning represented with Chinese character of huiuyiuxru kdatikv is " meeting room air-conditioning ", after these two keywords are extracted out, computing machine can go to look into " meeting room air-conditioning " address, after finding this " meeting room air-conditioning " address, the destination address parameter that computing machine will extract this address as the opertaing device in the air conditioner ventilation start-up routine joins in the program of air conditioner ventilation startup, here the Chinese meaning represented with Chinese character of davkca is " opening ", after this keyword is extracted out, computing machine can go to look into " opening " air-conditioning program, after finding this program of " opening " air-conditioning, computing machine will extract this program by arrange computer program that the program module of binding 5 will carry out by the priority logical order of carrying out and correctly arrange and be connected, here will " open " foremost that this section of air-conditioning program module is placed on whole procedure, as the program of at first carrying out, because logically, if air-conditioning is not opened, other ventilates and the temperature control supervisor is that air-conditioning is to carry out, so the program module that here this section air-conditioning is opened will be placed on the foremost of whole procedure, as the program of at first carrying out, in like manner, if other program is not prescribed their priority executive routine, also be according to the sequencing of this logic judgment criteria by auto arrangement program module after the computer discriminant, rxvhxu jiba. the Chinese meaning represented with Chinese character of xxvxisa and rxvhxu is respectively " at first " and " then " here, because these two words do not have corresponding computer program corresponding with them, therefore, we claim that this word is non-key word, in Chinese, belong to conjunction, the implication of these two non-key words is will come front immediately following rxvhxu back program immediately following program behind xxvxisa, carry out earlier than the program that comes immediately following the rxvhxu back immediately following the program behind xxvxisa during execution, here the Chinese meaning represented with Chinese character of tdafpa is " ventilation ", after this keyword is extracted out, computing machine can remove to look into the computer program of binding with tdafpa, and the execution sequence that the computer program with the tdafpa binding that will find extracts according to last surface analysis comes the program module back of opening air-conditioning with it, and then carry out after opening the air-conditioning program, 10 fnajda here are immediately following ventilating at tdafpa() afterwards, computing machine can be judged accordingly and refers to ventilation time " 10 minutes ", the ventilation duration parameters that computing machine will extract it as the air conditioner ventilation program joins in the air conditioner ventilation program, here the Chinese meaning represented with Chinese character of xruwna bkvqre is " room temperature maintenance ", after these two keywords are extracted out, computing machine can remove to look into the computer program of binding with xruwna bkvqre, and the computer program with xruwna bkvqre binding that will find extracts, and according to the execution sequence of last surface analysis it is come tdafpa(and ventilates) the program module back, and then tdafpa(ventilates) back that finishes after the program carries out, zcu 25 duu(here are at 25 degree) immediately following keeping in xruwna bkvqre(room temperature) afterwards, computing machine can judge that accordingly the temperature that refers to " room temperature maintenance " is " 25 degree ", computing machine will extract it as air-conditioning xruwna bkvqre(room temperature and keep) temperature parameter of " room temperature maintenances " of program joins the maintenance of air-conditioning xruwna bkvqre(room temperature) in the program program, so far, Chinese-character text has been finished the computer program that whole text need be transferred, and has carried out correct procedure parameter assignment and program successively being connected of execution sequence.At last the above-mentioned program that connects being transferred to the program execution module 6 that is stored in the computing machine hands over computer system 2 to carry out.
When above-mentioned whole procedure is carried out, COMPUTER DETECTION current time at first, when current time arrival program begins the execution time: 1 day 14 February in 2013, point was when (2 pm), meeting room air-conditioning address is effective, effective meeting room air-conditioning sends the control command of opening air-conditioning to computer program to the address, the meeting room air-conditioning is opened, after the meeting room air-conditioning is opened, and then computing machine moves the air conditioner ventilation program, computing machine can be controlled air-conditioning and open and the outdoor ventilating duct that links to each other, scavenger fan in the air-conditioning can be started working simultaneously, this is that room air and outdoor air can flow, realize the exchange of indoor and outdoor air, in this process, calculate chance and constantly detect the stand-by time whether ventilation time has arrived program setting, in case detecting ventilation time is to the stand-by time of program setting, be 10 minutes in present case, computing machine can send instruction to air-conditioning and cut out and outdoor ventilating opening, stop and outdoor ventilation, so just stopped the ventilation operation of air-conditioning, and then computing machine is carried out the xruwna bkvqre(room temperature maintenance of back) program, this is that computing machine at first detects indoor environment temperature, if be lower than predefined maintenance temperature, be 25 degree in present case, then computer program starts the heating arrangement in the air-conditioning, making air-conditioning be discharged to indoor circulating air temperature rises, in this process, computing machine keeps in xruwna bkvqre(room temperature) constantly detect indoor environment temperature under the control of program, if indoor environment temperature reaches the indoor environment temperature of program setting in advance, computing machine sends the instruction that stops to heat to air-conditioning, the heating of air-conditioning heater stop; If be higher than predefined maintenance temperature, be 25 degree in present case, then computer program starts the refrigerating plant in the air-conditioning, making air-conditioning be discharged to indoor circulating air temperature descends, in this process, computing machine keeps in xruwna bkvqre(room temperature) constantly detect indoor environment temperature under the control of program, if indoor environment temperature reaches the indoor environment temperature of program setting in advance, computing machine sends the instruction that stops to freeze to air-conditioning, air-conditioning refrigeration plant stops refrigeration, and the computing machine that like this goes round and begins again is just controlled indoor environment temperature about 25 degree.So also just finished Chinese-character text to the calling of computer program, realized that Chinese-character text calls the method for computer program operation.
Because the difference of everyone word custom, some people's possibility word is standard not necessarily, at this moment can in computing machine, store synonym and the near synonym table of comparisons in advance, and by synonym and the near synonym table of comparisons next standard word that automatically nonstandard word converted computing machine approval of computing machine by setting, keyword in the computing machine must be the standard word of computing machine approval, such as: " opening; open; open " can unify " opening " this word by the table of comparisons, again such as: " turning off; close; close " can unify " closing " this word by the table of comparisons, and binds in advance with corresponding computer program module.
By that analogy, since in this example because the object of control, therefore the action of time, control object can change by the change of Chinese language text, can adopt said method to carry out computer program to the action of other control object, time and control object and call and realize wanting the control of control object.
Because after Chinese-character text is changed by Chinese character and Chinese voice code bidirectional modular converter, Chinese character and Chinese phonetics codes can be changed mutually, therefore in the narration of the technical program, every information of representing with Chinese character can be used the Chinese speech representation, vice versa, here in the narration of the technical program just not tired stating respectively.
Because computer programming language is when calling program module, often use by the English written program of 26 Latin alphabet spellings and call, 26 Latin alphabets belong to the ASCII character scope, the normal operation of computer system is no problem, because the interior code system of Chinese character does not belong to the ASCII character scope, if directly adopt the Chinese character statement to call computer program, in some computer system, can not guarantee normal operation, therefore, the technical program has designed two sets of plan, one cover computer program and Chinese character keyword are bound as Fig. 1, when computer testing can not normally move in computing machine to this mode, move as Fig. 2 with regard to the mode that adopts another set of computer program and Chinese phonetics codes keyword to bind, because Chinese phonetics codes is the same as with English 26 Latin alphabet spellings, and punctuation mark is with English consistent, guaranteed the ISN of the Chinese information that moves like this in the ASCII character scope, thereby guarantees that the technical program can normally move in computer system.
If what computer program was only bound with Chinese phonetics codes and computer system 2 receives is the situation of Chinese-character text such as Fig. 2, then at first by Chinese language text load module 1 Chinese language text is imported computer system 2, computer system 2 is carried out participle with the Chinese language text that receives by Chinese language text word-dividing mode 3, such as: the above-mentioned text of mentioning:
" this afternoon 2 the meeting room air-conditioning of naming a person for a particular job open, at first ventilated 10 minutes, then room temperature is remained on 25 degree." carry out participle through Chinese language text word-dividing mode 3, obtain the text of the good word of following branch:
" this afternoon 2 the meeting room air-conditioning of naming a person for a particular job open, at first ventilated 10 minutes, then room temperature is remained on 25 degree.”
And then will divide the Chinese character of word to convert the Chinese phonetics codes of forming with ASCII character to by Chinese character and Chinese phonetics codes modular converter 7, the sentence of above-mentioned Chinese-character text has converted the Chinese sentence of following Chinese speech representation to:
Zcu jinatisa xiauwuv 2?disv jiba huiuyiuxru kdatikv davkca, xxvxisa tdafpa 10 fnajda, rxvhxu jiba xruwna bkvqre zcu 25?duu.
And then the process above repeating is namely by being stored in the computer program module 4 of the keyword binding in the computing machine and Chinese phonetics codes that import or the Chinese character in advance, keyword in the Chinese phonetics codes that converts to is carried out the binding of computer program, correctly arrange and be connected by arrange computer program that link block 5 will carry out by the priority logical order of carrying out at last, and be transferred to the program execution modules 6 that are stored in the computer system 2 and hand over computer systems 2 to carry out, above concrete narration had been arranged, just be not repeated here.
Above-mentioned Chinese language text load module can be the specific input keyboard load module of standard English keyboard module or Chinese character, perhaps handwriting input module, perhaps optical scanning load module, perhaps cable network load module, perhaps wireless network load module, perhaps less radio-frequency load module, computer stored EM equipment module.
Above-mentioned computer system 2 can be desktop computer or notebook computer or server or cloud computing machine system, also can be embedded computer system.
Computer system 2 is when the commencement of commercial operation program, be divided into two kinds of mode operations, a kind of is automatic operational mode, this pattern is carried out the operation of program according to computing machine automatically to the understanding of receiving Chinese language text, and the function that the program that brings into operation will reach is exported with the phonetic synthesis form of Chinese language text or this Chinese language text; Another kind is the inquiry affirmation mode, under this pattern 2 pairs of computer systems the Chinese language text of receiving correctly proofread and correct optimization with executive routine earlier, and feed back that a process is correct proofreaies and correct and the Chinese language text of executive routine optimization, this Chinese language text also can be carried out after confirming through the form output of phonetic synthesis module with voice.
Such as, in the top example, computer system 2 is being understood after the Chinese speech information translation of receiving becomes Chinese language text information, is correctly being called program that the keyword in the text binds and carry out according to correct actuating logic on the basis that execution sequence arranges, can export: " this afternoon, 2 meeting room air-conditionings were opened; at first ventilated 10 minutes, then room temperature were remained on 25 degree." Chinese-character text information or the voice after this Chinese-character text phonetic synthesis, this Chinese-character text information also can convert to Chinese phonetics codes or foreign language or minority language output.
Another kind is the inquiry affirmation mode, the Chinese language text that 2 pairs of Chinese speechs of receiving of computer system are converted under this pattern is correctly proofreaied and correct the optimization with executive routine earlier, and feed back that a process is correct proofreaies and correct and the Chinese language text of executive routine optimization, this Chinese language text also can be carried out after confirming through the form output of phonetic synthesis module and voice.Such as: computer system 2 is received the Chinese-character text that is converted with next section Chinese speech information: " today 2 the meeting room air-conditioning of naming a person for a particular job open, at first ventilated 10 minutes, then room temperature is remained on 25 degree." computer system 2 detects and passed through point in the mornings 2 this moment; can will the time be arranged on 2 pm automatically; in the Chinese language text that computer system 2 stores in advance, detect with this Chinese language text simultaneously and make the more optimal Chinese language text of calling program for immediate one section; at this moment computer system 2 can be exported: " this afternoon 2 the meeting room air-conditioning of naming a person for a particular job open, at first ventilated 10 minutes, then
With air-conditioning meeting room is sterilized andRoom temperature is remained on 25 degree." you confirm? the literal of noting the part of computer optimization here will underline and wait sign to send; after sending affirmation Chinese speechs or Chinese language text or other confirmations to computer system 2; computer system 2 just with this Chinese language text as the Chinese language text that finally receives;, add that " air-conditioning sterilizing program " brings into operation when satisfying predetermined conditions according to the step in the top case.
Same above this Chinese language text information can be exported with speech form after phonetic synthesis module phonetic synthesis, and this Chinese-character text information also can convert the output of Chinese phonetics codes or foreign language or minority language to.
It is pointed out that at last the Chinese language text in above-mentioned narration refers to the text that all characters of representing Chinese informations are formed, and comprise Chinese character, the Chinese phonetic alphabet, Chinese phonetics codes etc., and Chinese-character text refers to the Chinese information text of being made up of Chinese character.
We have realized calling with Chinese language text the purpose of computer program operation device by above the technical program.