一种基于规则的英语作文语法错误纠正方法
技术领域
本发明涉及自然语言处理技术、英语作文语法分析技术,具体是一种基于规则的英语作文语法错误纠正方法。
背景技术
现有的英语作文语法错误纠正方法主要有统计分析方法,统计分析方法通过大量的英语语言文本来训练设计的英语语法统计语法模型,然后使用英语语法统计模型对英语作文中的语法错误进行纠正处理。由于统计分析方法纠错的正确率受到训练文本集大小和训练设计的英语语法统计纠错模型好坏的影响,在使用统计分析方法分析不同的英语语法错误时需要设计不同的英语语法统计模型,而收集大量的英语语言文本较为耗时耗力,所以存在纠错精度不高和纠错类型少的缺点。因此针对上述问题,本发明专利提供了一种基于规则的英语语法错误纠正方法。
本发明所采用语法纠错模型能够纠正英语作文中冠词错误、形容词短语错误、介词短语错误、代词错误、动词时态错误、动词语态错误、不规则动词错误、助动词和情态动词错误、主谓不一致错误、单复数不一致错误、固定搭配错误、连词错误、词性混淆错误、单词重复使用错误、标点符号错误、缩写错误、句子首字母大小写错误。
发明内容
1.本发明的一种基于规则的英语作文语法错误纠正方法,其特征是:包括一个由顺序连接的英语作文预处理模块、规则语法纠错处理模块和生成语法纠错结果模块组成的英语作文语法错误纠正模型,该纠正模型总体处理步骤如图1所示。
在纠正模型中,第一步英语作文预处理模块读入一篇英语作文,对它进行分句、分词,词性标注、短语切块、词性消歧、添加句子开始标志与结束标志,输出英语作文的预处理结果;第二步规则语法纠错处理模块读入英语作文预处理结果中句子,对读入句子与提取语法规则进行匹配处理,并找到一个适合读入句子的语法规则,用该语法规则去检查读入句子的语法错误,输出英语作文语法错误纠正结果;第三步生成语法纠错结果模块读入英语作文语法错误纠正结果,提取英语作文中每个句子的语法错误位置,并给每个有语法错误的句子的语法错误位置做上标注;下面是该纠正模型中每个模块的处理步骤:
(1)所述的英语作文预处理模块处理步骤如下,如图2所示:
P201 开始;
P202 读入英语作文;
P203 对英语作文进行分句与分词处理;
P204 基于字典的词性标注,根据字典查找单词的词性而进行标注,并输出英语作文词性标注结果;
P205 读入短语切块模型,利用该短语切块模型对英语作文进行短语切块处理,并输出英语作文短语切块结果;
P206 在英语作文中添加句子的开始标志与结束标志;
P207 读入英语词性消歧规则库,根据规则去除单词的不正确词性,并输出英语作文词性消歧结果;
P208 结束;
(2)所述的规则语法纠错处理模块处理步骤如下,如图3所示:
P301 开始;
P302 读入英语作文预处理结果中一个句子;
P303 读入英语语法规则库中一个英语语法规则并解析出该英语语法规则中各元素的内容;
P304 利用上述公式(1)计算句子最大匹配次数;
P305 如果句子最大匹配次数大于0,取值为句子最大匹配次数;否则句子最大匹配次数取值为0;
P306 设置句子匹配次数计数器初始值为0;
P307 如果句子匹配计数器值小于句子最大匹配次数,则转P308操作;否则转P321操作;
P308 设置句子匹配的开始位置为-1,设置句子匹配的结束位置为-1;
P309 设置单词匹配状态为失败;
P310 读入英语语法规则中的一个词条内容;
P311 读入英语作文预处理结果中一个句子的一个单词结果(包含单词的词性标注、词性消歧与短语切块结果);
P312 如果该词条中内容和该单词结果相同,则转P313操作;否则转P311操作;
P313 设置该单词匹配状态为成功;
P314 如果句子匹配的开始位置为-1,则转P315操作;否则转P316操作;
P315 句子匹配的开始位置取值为单词匹配的开始位置;
P316 如果英语语法规则中还有下一个词条,则转P309操作;否则转P317操作;
P317 如果单词的匹配状态为成功,则转P318操作;否则转P320操作;
P318 句子的匹配的结束位置取值为句子匹配的开始位置加上该英语语法规则中词条的个数;
P319 保存该英语语法规则、句子匹配的开始位置和结束位置到英语作文的语法错误纠正结果中;
P320 句子匹配计数器加1;
P321 如果有下一条英语语法规则,则转P303操作;否则转P322操作;
P322 如果有两个规则的匹配位置有重叠,则只保留那些重叠匹配的规则中具有最长匹配的规则。
P323 如果有下一句,则转P302操作,否则转P324操作;
P324 输出英语作文的语法错误纠正结果;
P325 结束;
(3)所述的生成语法纠错结果模块具体处理步骤如下,如图4所示:
P401 开始;
P402 读入英语作文的语法错误纠正结果;
P403 根据规则中的匹配开始和结束位置进行句子语法错误标记;
P404 提取出规则信息元素中的内容并输出;
P405 提取出规则建议元素中的内容并输出;
P406 提取出规则正确例句元素中的内容并输出;
P407 结束。
2.本发明方法的定义如下:
(1)单词词性标注集
单词词性标注集采用美国宾州大学宾州树库词性标注集,它用于对英语作文中单词进行词性标注。
(2)词性标注结构
词性标注是指对英语作文中的单词进行词性标注的处理,下面是一篇英语作文进行词性标注后的保存格式:
英语作文的第1个句子:单词1[单词1/词性1,单词1/词性2,……]单词2[单词2/词性1,单词2/词性2,……]……单词i[单词i/词性1,单词i/词性2,……]<回车>
英语作文的第2个句子:单词1[单词1/词性1,单词1/词性2,……]单词2[单词2/词性1,单词2/词性2,……]……单词i[单词i/词性1,单词i/词性2,……]<回车>
…
英语作文的第n个句子:单词1[单词1/词性1,单词1/词性2,……]单词2[单词2/词性1,单词2/词性2,……]……单词i[单词i/词性1,单词i/词性2,……]<回车>
(3)短语切块结构
短语切块是指对英语作文中的名词短语和动词短语进行切分并输出名词短语和动词短语的处理,下面是一篇英语作文进行短语切块后的保存格式:
英语作文的第1个句子:单词1[短语切块1] 单词2[短语切块2]……单词i[短语切块i]<回车>
英语作文的第2个句子:单词1[短语切块1] 单词2[短语切块2]……单词i[短语切块i]<回车>
…
英语作文的第n个句子:单词1[短语切块1] 单词2[短语切块2]……单词i[短语切块i]<回车>
(4)词性消歧结构
词性消歧是指从英语作文的单词词性结果中剔除那些单词词性标注不正确的单词词性,下面是一篇英语作文进行词性消歧后的保存格式:
英语作文的第1个句子:单词1[单词1/词性1] 单词2[单词2/词性2]……单词i[单词i/词性i]<回车>
英语作文的第2个句子:单词1[单词1/词性1] 单词2[单词2/词性2]……单词i[单词i/词性i]<回车>
…
英语作文的第n个句子:单词1[单词1/词性1] 单词2[单词2/词性2]……单词i[单词i/词性i]<回车>
(5)英语字典结构
英语字典的结构用于保存单词词性的标注结果,它的保存格式如下:
单词1 词性1
单词1 词性2
……
单词1 词性n
单词2 词性1
单词2 词性2
……
单词2 词性n
单词n 词性1
单词n 词性2
……
单词n 词性n
(6)短语切块模型训练文本集结构
英语短语切块模型训练文本集结构是用于保存短语切块模型训练结果,它的保存格式如下:
单词1 词性1 短语切块1
单词2 词性2 短语切块2
……
单词n 词性n 短语切块n
(7)英语作文预处理结果结构
英语作文预处理结果结构用于保存英语作文分句、分词,词性标注、短语切块、词性消歧、添加句子开始标志与结束标志的处理结果,它的保存格式如下:
英语作文的第1个句子:句子开始标志单词1[单词1/词性1,短语切块1]单词2[单词2/词性2,短语切块2]……单词i[单词i/词性i,短语切块i]句子结束标志<回车>
英语作文的第2个句子:句子开始标志单词1[单词1/词性1,短语切块1]单词2[单词2/词性2,短语切块2]……单词i[单词i/词性i,短语切块i]句子结束标志<回车>
…
英语作文的第n个句子:句子开始标志单词1[单词1/词性1,短语切块1]单词2[单词2/词性2,短语切块2]……单词i[单词i/词性i,短语切块i]句子结束标志<回车>
(8)英语作文的语法错误纠正结果结构
英语作文的语法错误纠正结果结构用于保存英语作文经过待批英语作文预处理模块与规则语法纠错处理模块的处理结果,它的保存格式如下:
英语语法错误规则名称:句子语法错误开始位置-句子语法错误结束位置:英语语法错误规则信息
(9)英语语法规则库结构
英语语法规则库是对学生英语写作中语法错误的归纳总结,它的结构如下:
下面是上述英语语法错误规则结构中基本元素的说明。
标识:用来标记一条英语语法错误规则,具有唯一性。标识取名为词条的内容,词条的内容之间用下划线分隔。
语法错误规则名称:是一条英语语法错误规则的名称。语法错误规则名称取名为词条的内容,词条的内容之间用空格分隔。
词条:用来保存所要匹配的单词、词性标注或短语切块结果。
模式:用来标注英语作文句子中所要匹配的语法规则。
标记:用来标注英语作文句子中存在语法错误的部分。
信息:用来保存英语语法错误规则匹配的结果。
建议:用来保存英语语法错误规则纠错的建议。
错误例句:用来保存含有英语语法错误的例句。
正确例句:用来保存英语语法错误纠正的例句。
(10)英语词性消歧规则库结构
英语词性消歧规则库是用于对英语作文的单词进行词性消岐的规则集合,它的结构如下:
下面是上述英语词性消歧规则结构中基本元素的说明。
消歧规则:用来标注一个英语词性消歧规则的开始和结束。
模式:用来标注英语作文句子中所要匹配的部分。
标记:用来标注英语作文句子中有词性标注错误的部分。
消歧:用来保存用于替换标记内词性的词性。
(11)句子最大匹配次数计算公式
句子最大匹配次数是英语作文预处理结果中一个句子对应英语语法规则库中该句子的一个英语语法规则的最大匹配次数,它的计算公式如下:
句子最大匹配次数=句子长度-句子对应英语语法规则库中词条个数+1(1)
附图说明
图1是本发明方法的总体处理步骤图;
图2是本发明方法的英语作文预处理模块处理步骤图;
图3是本发明方法的规则语法纠错处理模块处理步骤图;
图4是本发明方法的生成语法纠错结果模块处理步骤图。
具体实施方式
本发明的一种基于规则的英语作文语法错误纠正方法的具体实施方式分为如下三个步骤。
第一步骤:执行“英语作文预处理模块”
本发明实施方式中输入的英语作文的题目为“The employment of collegestudents”,其实施结果如下所述:
(1)下面是一篇英语作文内容:
Nowadays,the employment of college students are becoming more andmore of a problem,even for the students of MAT.About a decade ago,universitystudents could find satisfice and enviable jobs after graduation,while atcurrent situation,about 30%and even worst of graduate students can’t finds ajob and stay at home after graduation.Employment difficulty of collegestudents was due to the following reasons.Among these;the increasingrecruitment of colleges and universities play a vital role.On addition,manycolleges and universities fail to adapted them courses to the development ofeconomy.Considering such a rough job market,I think it is high time that wetaked effective measures to solve the problem.Above all,college studentsshould realize their own defects and further improve themselves to to keeptheir competitive edge in society.Moreover,colleges or university shouldprovide more trainings and internship opportunities before the students enterthe society.besides,college students should hold a right attitude towardsjobs and set their job expectations at a suitable level.Only through theseways can the college students find a satisfactory job and have brighterfuture.
(2)对上述英语作文进行单词词性标注后,生成单词词性标注如下所示:
Nowadays[nowadays/NN,nowadays/RB],[,/,]the[the/DT]employment[employment/NN]of[of/IN]college[college/NN]students[student/NNS]are[are/NN,be/VBP]becoming[becoming/JJ,becoming/NN,become/VBG]more[more/RP,many/JJR,much/JJR]and[and/CC]more[more/RP,many/JJR,much/JJR]of[of/IN]a[a/DT]problem[problem/NN],[,/,]even[even/JJ,even/NN,even/RB,even/VB,even/VBP]for[for/CC,for/IN,for/RP]the[the/DT]students[student/NNS]of[of/IN]MAT[MAT/NNP,mat/JJ,mat/NN].[./.]
About[about/IN,about/RP]a[a/DT]decade[decade/NN]ago[ago/IN,ago/JJ,ago/RB],[,/,]university[university/NN]students[student/NNS]could[can/MD]find[find/NN,find/VB,find/VBP]satisfice[satisfice/null]and[and/CC]enviable[enviable/JJ]jobs[job/NNS,job/VBZ]after[after/CC,after/IN,after/RB]graduation[graduation/NN],[,/,]while[while/IN,while/NN,while/VB,while/VBP]at[at/IN,at/RP]current[current/JJ,current/NN]situation[situation/NN],[,/,]about[about/IN,about/RP]30%[30%/null]and[and/CC]even[even/JJ,even/NN,even/RB,even/VB,even/VBP]worst[worst/NN,worst/VB,worst/VBP,bad/JJS,ill/JJS]of[of/IN]graduate[graduate/JJ,graduate/NN,graduate/VB,graduate/VBP]students[student/NNS]can[can/MD,can/NN,can/VB,can/VBP]’[’/null]t[t/null]finds[find/NNS,find/VBZ]a[a/DT]job[job/NN,job/VB,job/VBP]and[and/CC]stay[stay/NN,stay/VB,stay/VBP]at[at/IN,at/RP]home[home/JJ,home/NN,home/VB,home/VBP]after[after/CC,after/IN,after/RB]graduation[graduation/NN].[./.]
Employment[employment/NN]difficulty[difficulty/NN]of[of/IN]college[college/NN]students[student/NNS]was[be/VBD]due[due/JJ,due/NN]to[to/IN,to/TO]the[the/DT]following[following/IN,following/JJ,following/NN,follow/VBG]reasons[reason/NNS,reason/VBZ].[./.]
Among[among/IN]these[these/DT];[;/:]the[the/DT]increasing[increasing/JJ,increasing/NN,increase/VBG]recruitment[recruitment/NN]of[of/IN]colleges[college/NNS]and[and/CC]universities[university/NNS]play[play/NN,play/VB,play/VBP]a[a/DT]vital[vital/JJ,vital/NN]role[role/NN].[./.]
On[On/NNP,on/IN,on/JJ,on/RP]addition[addition/NN],[,/,]many[many/DT,many/PDT]colleges[college/NNS]and[and/CC]universities[university/NNS]fail[fail/NN,fail/VB,fail/VBP]to[to/IN,to/TO]adapted[adapted/JJ,adapt/VBD,adapt/VBN]them[them/PRP]courses[course/NNS,course/VBZ]to[to/IN,to/TO]the[the/DT]development[development/NN]of[of/IN]economy[economy/NN].[./.]
Considering[considering/NN,consider/VBG]such[such/DT,such/PDT]a[a/DT]rough[rough/JJ,rough/NN,rough/VB,rough/VBP]job[job/NN,job/VB,job/VBP]market[market/NN,market/VB,market/VBP],[,/,]I[I/PRP]think[think/VB,think/VBP]it[it/PRP]is[be/VBZ]high[high/JJ,high/NN,high/RP]time[time/JJ,time/NN,time/VB,time/VBP]that[that/DT,that/RP,that/WDT,that/WP]we[we/PRP]taked[taked/null]effective[effective/JJ]measures[measure/NNS,measure/VBZ]to[to/IN,to/TO]solve[solve/VB,solve/VBP]the[the/DT]problem[problem/NN].[./.]
Above[above/IN,above/JJ,above/NN]all[all/DT,all/JJ,all/NN,all/PDT],[,/,]college[college/NN]students[student/NNS]should[should/JJ,should/MD]realize[realize/VB,realize/VBP]their[their/PRP$]own[own/JJ,own/VB,own/VBP]defects[defect/NNS,defect/VBZ]and[and/CC]further[further/RB,further/VB,further/VBP,far/JJR]improve[improve/VB,improve/VBP]themselves[themselves/PRP]to[to/IN,to/TO]to[to/IN,to/TO]keep[keep/NN,keep/VB,keep/VBP]their[their/PRP$]competitive[competitive/JJ]edge[edge/JJ,edge/NN,edge/VB,edge/VBP]in[in/IN,in/NN,in/RP]society[society/NN].[./.]
Moreover[moreover/CC,moreover/RB],[,/,]colleges[college/NNS]or[or/CC,or/JJ,or/NN]university[university/NN]should[should/JJ,should/MD]provide[provide/VB,provide/VBP]more[more/RP]trainings[training/NNS]and[and/CC]internship[internship/NN]opportunities[opportunity/NNS]before[before/IN,before/RP]the[the/DT]students[student/NNS]enter[enter/VB,enter/VBP]the[the/DT]society[society/NN].[./.]
besides[besides/IN],[,/,]college[college/NN]students[student/NNS]should[should/JJ,should/MD]hold[hold/NN,hold/VB,hold/VBP]a[a/DT]right[right/JJ,right/NN,right/UH,right/VB,right/VBP]attitude[attitude/NN]towards[towards/IN]jobs[job/NNS,job/VBZ]and[and/CC]set[set/NN,set/VB,set/VBD,set/VBN,set/VBP]their[their/PRP$]job[job/NN,job/VB,job/VBP]expectations[expectation/NNS]at[at/IN,at/RP]a[a/DT]suitable[suitable/JJ]level[level/JJ,level/NN,level/VB,level/VBP].[./.]
Only[only/JJ,only/RB]through[through/IN,through/JJ,through/RP]these[these/DT]ways[way/NNS]can[can/MD,can/NN,can/VB,can/VBP]the[the/DT]college[college/NN]students[student/NNS]find[find/NN,find/VB,find/VBP]a[a/DT]satisfactory[satisfactory/JJ]job[job/NN,job/VB,job/VBP]and[and/CC]have[have/NN,have/VB,have/VBP]brighter[bright/JJR]future[future/JJ,future/NN].[./.]
(3)然后对上述词性标注后的英语作文进行短语切块并添加句子开始与结束标志后,生成短语切块格式如下所示:
<S>Nowadays[nowadays/NN,nowadays/RB,B-ADVP],[,/,,O]the[the/DT,B-NP-singular]employment[employment/NN,E-NP-singular]of[of/IN,B-PP]college[college/NN,B-NP-plural]students[student/NNS,E-NP-plural]are[are/NN,be/VBP,B-VP]becoming[becoming/JJ,becoming/NN,become/VBG,I-VP]more[more/RP,many/JJR,much/JJR,B-ADVP]and[and/CC,I-ADVP]more[more/RP,many/JJR,much/JJR,I-ADVP]of[of/IN,B-PP]a[a/DT,B-NP-singular]problem[problem/NN,E-NP-singular],[,/,,O]even[even/JJ,even/NN,even/RB,even/VB,even/VBP,B-PP]for[for/CC,for/IN,for/RP,I-PP]the[the/DT,B-NP-plural]students[student/NNS,E-NP-plural]of[of/IN,B-PP]MAT[MAT/NNP,mat/JJ,mat/NN].[./.,</S>]
<S>About[about/IN,about/RP,B-PP]a[a/DT,B-NP-singular]decade[decade/NN,E-NP-singular]ago[ago/IN,ago/JJ,ago/RB,B-ADVP],[,/,,O]university[university/NN,B-NP-plural]students[student/NNS,E-NP-plural]could[can/MD,B-VP]find[find/NN,find/VB,find/VBP,I-VP]satisfice[satisfice/null,B-NP-plural]and[and/CC,I-NP-plural]enviable[enviable/JJ,I-NP-plural]jobs[job/NNS,job/VBZ,E-NP-plural]after[after/CC,after/IN,after/RB,B-PP]graduation[graduation/NN,B-NP-singular|E-NP-singular],[,/,,O]while[while/IN,while/NN,while/VB,while/VBP,B-ADVP]at[at/IN,at/RP,B-PP]current[current/JJ,current/NN,B-NP-singular]situation[situation/NN,E-NP-singular],[,/,,O]about[about/IN,about/RP,B-NP-singular]30%[30%/null]and[and/CC,O]even[even/JJ,even/NN,even/RB,even/VB,even/VBP,B-ADVP]worst[worst/NN,worst/VB,worst/VBP,bad/JJS,ill/JJS,B-NP-singular|E-NP-singular]of[of/IN,B-PP]graduate[graduate/JJ,graduate/NN,graduate/VB,graduate/VBP,B-NP-plural]students[student/NNS,E-NP-plural]can[can/MD,can/NN,can/VB,can/VBP]’[’/null]t[t/null]finds[find/NNS,find/VBZ,I-VP]a[a/DT,B-NP-singular]job[job/NN,job/VB,job/VBP,E-NP-singular]and[and/CC,O]stay[stay/NN,stay/VB,stay/VBP,B-VP]at[at/IN,at/RP,B-PP]home[home/JJ,home/NN,home/VB,home/VBP,B-NP-singular|E-NP-singular]after[after/CC,after/IN,after/RB,B-PP]graduation[graduation/NN,B-NP-singular|E-NP-singular].[./.,</S>,O]
<S>Employment[employment/NN,B-NP-singular]difficulty[difficulty/NN,E-NP-singular]of[of/IN,B-PP]college[college/NN,B-NP-plural]students[student/NNS,E-NP-plural]was[be/VBD,B-VP]due[due/JJ,due/NN,B-ADJP]to[to/IN,to/TO,B-PP]the[the/DT,B-NP-plural]following[following/IN,following/JJ,following/NN,follow/VBG,I-NP-plural]reasons[reason/NNS,reason/VBZ,E-NP-plural].[./.,</S>,O]
<S>Among[among/IN,B-PP]these[these/DT,B-NP-singular|E-NP-singular];[;/:,O]the[the/DT,B-NP-singular]increasing[increasing/JJ,increasing/NN,increase/VBG,I-NP-singular]recruitment[recruitment/NN,E-NP-singular]of[of/IN,B-PP]colleges[college/NNS,B-NP-plural]and[and/CC,I-NP-plural]universities[university/NNS,E-NP-plural]play[play/NN,play/VB,play/VBP,B-VP]a[a/DT,B-NP-singular]vital[vital/JJ,vital/NN,I-NP-singular]role[role/NN,E-NP-singular].[./.,</S>,O]
<S>On[On/NNP,on/IN,on/JJ,on/RP,B-PP]addition[addition/NN,B-NP-singular|E-NP-singular],[,/,,O]many[many/DT,many/PDT,B-NP-plural]colleges[college/NNS,I-NP-plural]and[and/CC,I-NP-plural]universities[university/NNS,E-NP-plural]fail[fail/NN,fail/VB,fail/VBP,B-VP]to[to/IN,to/TO,I-VP]adapted[adapted/JJ,adapt/VBD,adapt/VBN,I-VP]them[them/PRP,B-NP-singular|E-NP-singular]courses[course/NNS,course/VBZ,B-ADJP]to[to/IN,to/TO,B-PP]the[the/DT,B-NP-singular]development[development/NN,E-NP-singular]of[of/IN,B-PP]economy[economy/NN,B-NP-singular|E-NP-singular].[./.,</S>,O]
<S>Considering[considering/NN,consider/VBG,B-VP]such[such/DT,such/PDT,B-NP-singular]a[a/DT,I-NP-singular]rough[rough/JJ,rough/NN,rough/VB,rough/VBP,I-NP-singular]job[job/NN,job/VB,job/VBP,I-NP-singular]market[market/NN,market/VB,market/VBP,E-NP-singular],[,/,,O]I[I/PRP,B-NP-singular|E-NP-singular]think[think/VB,think/VBP,B-VP]it[it/PRP,B-NP-singular|E-NP-singular]is[be/VBZ,B-VP]high[high/JJ,high/NN,high/RP,B-NP-singular]time[time/JJ,time/NN,time/VB,time/VBP,E-NP-singular]that[that/DT,that/RP,that/WDT,that/WP,B-SBAR]we[we/PRP,B-NP-singular|E-NP-singular]taked[taked/null,B-VP]effective[effective/JJ,B-NP-plural]measures[measure/NNS,measure/VBZ,E-NP-plural]to[to/IN,to/TO,B-VP]solve[solve/VB,solve/VBP,I-VP]the[the/DT,B-NP-singular]problem[problem/NN,E-NP-singular].[./.,</S>,O]
<S>Above[above/IN,above/JJ,above/NN,B-PP]all[all/DT,all/JJ,all/NN,all/PDT,B-NP-singular|E-NP-singular],[,/,,O]college[college/NN,B-NP-plural]students[student/NNS,E-NP-plural]should[should/JJ,should/MD,B-VP]realize[realize/VB,realize/VBP,I-VP]their[their/PRP$,B-NP-plural]own[own/JJ,own/VB,own/VBP,I-NP-plural]defects[defect/NNS,defect/VBZ,E-NP-plural]and[and/CC,O]further[further/RB,further/VB,further/VBP,far/JJR,B-VP]improve[improve/VB,improve/VBP,I-VP]themselves[themselves/PRP,B-NP-singular|E-NP-singular]to[to/IN,to/TO,B-VP]to[to/IN,to/TO,I-VP]keep[keep/NN,keep/VB,keep/VBP,I-VP]their[their/PRP$,B-NP-singular]competitive[competitive/JJ,I-NP-singular]edge[edge/JJ,edge/NN,edge/VB,edge/VBP,E-NP-singular]in[in/IN,in/NN,in/RP,B-PP]society[society/NN,B-NP-singular|E-NP-singular].[./.,</S>,O]
<S>Moreover[moreover/CC,moreover/RB,B-ADVP],[,/,,O]colleges[college/NNS,B-NP-plural|E-NP-plural]or[or/CC,or/JJ,or/NN,O]university[university/NN,B-NP-singular|E-NP-singular]should[should/JJ,should/MD,B-VP]provide[provide/VB,provide/VBP,I-VP]more[more/RP,B-NP-plural]trainings[training/NNS,E-NP-plural]and[and/CC,O]internship[internship/NN,B-NP-plural]opportunities[opportunity/NNS,E-NP-plural]before[before/IN,before/RP,B-PP]the[the/DT,B-NP-plural]students[student/NNS,E-NP-plural]enter[enter/VB,enter/VBP,B-VP]the[the/DT,B-NP-singular]society[society/NN,E-NP-singular].[./.,</S>,O]
<S>besides[besides/IN,B-PP],[,/,,O]college[college/NN,B-NP-plural]students[student/NNS,E-NP-plural]should[should/JJ,should/MD,B-VP]hold[hold/NN,hold/VB,hold/VBP,I-VP]a[a/DT,B-NP-singular]right[right/JJ,right/NN,right/UH,right/VB,right/VBP,I-NP-singular]attitude[attitude/NN,E-NP-singular]towards[towards/IN,B-PP]jobs[job/NNS,job/VBZ,B-NP-plural|E-NP-plural]and[and/CC,O]set[set/NN,set/VB,set/VBD,set/VBN,set/VBP,B-VP]their[their/PRP$,B-NP-plural]job[job/NN,job/VB,job/VBP,I-NP-plural]expectations[expectation/NNS,E-NP-plural]at[at/IN,at/RP,B-PP]a[a/DT,B-NP-singular]suitable[suitable/JJ,I-NP-singular]level[level/JJ,level/NN,level/VB,level/VBP,E-NP-singular].[./.,</S>,O]
<S>Only[only/JJ,only/RB,B-ADVP]through[through/IN,through/JJ,through/RP,B-PP]these[these/DT,B-NP-plural]ways[way/NNS,E-NP-plural]can[can/MD,can/NN,can/VB,can/VBP,B-VP]the[the/DT,B-NP-plural]college[college/NN,I-NP-plural]students[student/NNS,E-NP-plural]find[find/NN,find/VB,find/VBP,B-VP]a[a/DT,B-NP-singular]satisfactory[satisfactory/JJ,I-NP-singular]job[job/NN,job/VB,job/VBP,E-NP-singular]and[and/CC,O]have[have/NN,have/VB,have/VBP,B-VP]brighter[bright/JJR,B-NP-singular]future[future/JJ,future/NN,E-NP-singular].[./.,</S>,O]
(4)然后对上述短语切块后的英语作文进行词性消歧,生成英语作文词性消歧格式如下所示:
<S>Nowadays[nowadays/NN,nowadays/RB,B-ADVP],[,/,,O]the[the/DT,B-NP-singular]employment[employment/NN,E-NP-singular]of[of/IN,B-PP]college[college/NN,B-NP-plural]students[student/NNS,E-NP-plural]are[be/VBP,B-VP]becoming[become/VBG,I-VP]more[more/RP,many/JJR,much/JJR,B-ADVP]and[and/CC,I-ADVP]more[more/RP,many/JJR,much/JJR,I-ADVP]of[of/IN,B-PP]a[a/DT,B-NP-singular]problem[problem/NN,E-NP-singular],[,/,,O]even[even/RB,B-PP]for[for/CC,for/IN,for/RP,I-PP]the[the/DT,B-NP-plural]students[student/NNS,E-NP-plural]of[of/IN,B-PP]MAT[MAT/NNP,mat/JJ,mat/NN].[./.,</S>]
<S>About[about/IN,about/RP,B-PP]a[a/DT,B-NP-singular]decade[decade/NN,E-NP-singular]ago[ago/IN,ago/JJ,ago/RB,B-ADVP],[,/,,O]university[university/NN,B-NP-plural]students[student/NNS,E-NP-plural]could[can/MD,B-VP]find[find/VB,I-VP]satisfice[satisfice/null,B-NP-plural]and[and/CC,I-NP-plural]enviable[enviable/JJ,I-NP-plural]jobs[job/NNS,job/VBZ,E-NP-plural]after[after/CC,after/IN,after/RB,B-PP]graduation[graduation/NN,B-NP-singular|E-NP-singular],[,/,,O]while[while/IN,while/NN,while/VB,while/VBP,B-ADVP]at[at/IN,at/RP,B-PP]current[current/JJ,B-NP-singular]situation[situation/NN,E-NP-singular],[,/,,O]about[about/IN,about/RP,B-NP-singular]30%[30%/null]and[and/CC,O]even[even/RB,B-ADVP]worst[worst/NN,worst/VB,worst/VBP,bad/JJS,ill/JJS,B-NP-singular|E-NP-singular]of[of/IN,B-PP]graduate[graduate/JJ,graduate/NN,graduate/VB,graduate/VBP,B-NP-plural]students[student/NNS,E-NP-plural]can[can/MD]’[’/null]t[not/RB]finds[find/VBZ,I-VP]a[a/DT,B-NP-singular]job[job/NN,E-NP-singular]and[and/CC,O]stay[stay/NN,stay/VB,stay/VBP,B-VP]at[at/IN,at/RP,B-PP]home[home/NN,B-NP-singular|E-NP-singular]after[after/CC,after/IN,after/RB,B-PP]graduation[graduation/NN,B-NP-singular|E-NP-singular].[./.,</S>,O]
<S>Employment[employment/NN,B-NP-singular]difficulty[difficulty/NN,E-NP-singular]of[of/IN,B-PP]college[college/NN,B-NP-plural]students[student/NNS,E-NP-plural]was[be/VBD,B-VP]due[due/JJ,due/NN,B-ADJP]to[to/IN,to/TO,B-PP]the[the/DT,B-NP-plural]following[following/IN,following/JJ,follow/VBG,I-NP-plural]reasons[reason/NNS,E-NP-plural].[./.,</S>,O]
<S>Among[among/IN,B-PP]these[these/DT,B-NP-singular|E-NP-singular];[;/:,O]the[the/DT,B-NP-singular]increasing[increasing/JJ,increasing/NN,increase/VBG,I-NP-singular]recruitment[recruitment/NN,E-NP-singular]of[of/IN,B-PP]colleges[college/NNS,B-NP-plural]and[and/CC,I-NP-plural]universities[university/NNS,E-NP-plural]play[play/VBP,B-VP]a[a/DT,B-NP-singular]vital[vital/JJ,I-NP-singular]role[role/NN,E-NP-singular].[./.,</S>,O]
<S>On[On/NNP,on/IN,on/JJ,on/RP,B-PP]addition[addition/NN,B-NP-singular|E-NP-singular],[,/,,O]many[many/DT,B-NP-plural]colleges[college/NNS,I-NP-plural]and[and/CC,I-NP-plural]universities[university/NNS,E-NP-plural]fail[fail/NN,fail/VB,fail/VBP,B-VP]to[to/IN,to/TO,I-VP]adapted[adapted/JJ,adapt/VBD,adapt/VBN,I-VP]them[them/PRP,B-NP-singular|E-NP-singular]courses[course/NNS,course/VBZ,B-ADJP]to[to/IN,to/TO,B-PP]the[the/DT,B-NP-singular]development[development/NN,E-NP-singular]of[of/IN,B-PP]economy[economy/NN,B-NP-singular|E-NP-singular].[./.,</S>,O]
<S>Considering[considering/NN,consider/VBG,B-VP]such[such/PDT,B-NP-singular]a[a/DT,I-NP-singular]rough[rough/JJ,rough/NN,I-NP-singular]job[job/NN,I-NP-singular]market[market/NN,E-NP-singular],[,/,,O]I[I/PRP,B-NP-singular|E-NP-singular]think[think/VBP,B-VP]it[it/PRP,B-NP-singular|E-NP-singular]is[be/VBZ,B-VP]high[high/JJ,high/NN,high/RP,B-NP-singular]time[time/NN,E-NP-singular]that[that/DT,that/RP,that/WDT,that/WP,B-SBAR]we[we/PRP,B-NP-singular|E-NP-singular]taked[taked/null,B-VP]effective[effective/JJ,B-NP-plural]measures[measure/NNS,E-NP-plural]to[to/TO,B-VP]solve[solve/VB,I-VP]the[the/DT,B-NP-singular]problem[problem/NN,E-NP-singular].[./.,</S>,O]
<S>Above[above/IN,above/JJ,above/NN,B-PP]all[all/DT,all/JJ,all/NN,all/PDT,B-NP-singular|E-NP-singular],[,/,,O]college[college/NN,B-NP-plural]students[student/NNS,E-NP-plural]should[should/JJ,should/MD,B-VP]realize[realize/VB,realize/VBP,I-VP]their[their/PRP$,B-NP-plural]own[own/JJ,I-NP-plural]defects[defect/NNS,E-NP-plural]and[and/CC,O]further[further/RB,B-VP]improve[improve/VB,improve/VBP,I-VP]themselves[themselves/PRP,B-NP-singular|E-NP-singular]to[to/IN,to/TO,B-VP]to[to/TO,I-VP]keep[keep/VB,I-VP]their[their/PRP$,B-NP-singular]competitive[competitive/JJ,I-NP-singular]edge[edge/NN,E-NP-singular]in[in/IN,B-PP]society[society/NN,B-NP-singular|E-NP-singular].[./.,</S>,O]
<S>Moreover[moreover/CC,moreover/RB,B-ADVP],[,/,,O]colleges[college/NNS,B-NP-plural|E-NP-plural]or[or/CC,O]university[university/NN,B-NP-singular|E-NP-singular]should[should/JJ,should/MD,B-VP]provide[provide/VB,provide/VBP,I-VP]more[more/RP,B-NP-plural]trainings[training/NNS,E-NP-plural]and[and/CC,O]internship[internship/NN,B-NP-plural]opportunities[opportunity/NNS,E-NP-plural]before[before/IN,before/RP,B-PP]the[the/DT,B-NP-plural]students[student/NNS,E-NP-plural]enter[enter/VB,enter/VBP,B-VP]the[the/DT,B-NP-singular]society[society/NN,E-NP-singular].[./.,</S>,O]
<S>besides[besides/IN,B-PP],[,/,,O]college[college/NN,B-NP-plural]students[student/NNS,E-NP-plural]should[should/JJ,should/MD,B-VP]hold[hold/VB,I-VP]a[a/DT,B-NP-singular]right[right/JJ,right/NN,right/UH,right/VB,right/VBP,I-NP-singular]attitude[attitude/NN,E-NP-singular]towards[towards/IN,B-PP]jobs[job/NNS,job/VBZ,B-NP-plural|E-NP-plural]and[and/CC,O]set[set/NN,set/VB,set/VBD,set/VBN,set/VBP,B-VP]their[their/PRP$,B-NP-plural]job[job/NN,I-NP-plural]expectations[expectation/NNS,E-NP-plural]at[at/IN,at/RP,B-PP]a[a/DT,B-NP-singular]suitable[suitable/JJ,I-NP-singular]level[level/NN,E-NP-singular].[./.,</S>,O]
<S>Only[only/JJ,only/RB,B-ADVP]through[through/IN,through/JJ,through/RP,B-PP]these[these/DT,B-NP-plural]ways[way/NNS,E-NP-plural]can[can/VBP,B-VP]the[the/DT,B-NP-plural]college[college/NN,I-NP-plural]students[student/NNS,E-NP-plural]find[find/VBP,B-VP]a[a/DT,B-NP-singular]satisfactory[satisfactory/JJ,I-NP-singular]job[job/NN,E-NP-singular]and[and/CC,O]have[have/VB,B-VP]brighter[bright/JJR,B-NP-singular]future[future/JJ,future/NN,E-NP-singular].[./.,</S>,O]
第二步骤:执行“规则语法纠错处理模块”,生成的规则语法纠错处理结果格式如下所示:
规则语法纠错处理模块是利用上述第一步骤生成的待批作文预处理模块处理结果和上述定义中的英语语法规则库,对待纠错英语作文进行语法检查与纠正,最后输出待纠错英语作文的语法错误纠正结果,本实施方式的英语作文的语法错误纠正结果格式如下所示:
[IN_NN_NNS:45-48:主谓不一致错误,建议改为“is”。,MAT_MIT:111-114:单词缩写错误,建议改为“MIT”。]
[VB_AND_JJ_NNS:51-60:词性混淆错误,建议改为“satisfactory”。,EVEN_WORST:142-147:形容词短语错误,建议改为“worse”。,MB_VBZ:175-180:情态动词后面接动词原形,建议改为“find”。,AND_BUT:187-190:连词错误,建议改为“but”。]
[WAS_IS:42-45:动词语态错误,建议改为“is”。]
[PUNCTUATION_ERROR:12-13:标点符号错误,建议改为“,”。,IN_NNS_AND_NNS_VBP:73-77:主谓不一致错误,建议改为“plays”。]
[IN_ADDTION:0-2:介词错误错误,建议改为“In”。,TO_VBD:53-60:动词时态错误,建议改为“adapt”。,PRONOUN_ERROR:54-58:代词错误,建议改为“their”。]
[IRREGULAR_VERB_ERROR:58-63:不规则动词错误,建议改为“took”。]
[WORD_REPETITION_ERROR:92-97:单词重复使用错误,建议改为“to”。]
[NNS_OR_NN:22-32:单复数不一致错误,建议改为“universities”。]
[UPPERCASE_SENTENCE_START:0-7:句子首字母大小写错误,建议改为“Besides”。]
[VB_JJR_NN:82-98:冠词缺失,建议改为“a brighter future”。]
第三步骤:执行“生成语法纠错结果模块”,生成的语法批改结果格式如下所示:
生成语法批改结果模块是利用上述第二步骤生成的英语作文的语法错误纠正结果,对英语作文的语法错误纠正结果进行提取分析,最后输出的待批作文语法错误批改结果格式如下所示:
(1)主谓不一致错误
错误句子:Nowadays,the employment of college students are becomingmore and more of a problem,even for the students of MAT.
纠错提示:主谓不一致错误,建议改为“is”。
建议表达:is
例句:The number of college students is increasing.
(2)缩写错误
错误句子:Nowadays,the employment of college students are becomingmore and more of a problem,even for the students of MAT.
纠错提示:单词缩写错误,建议改为“MIT”。
建议表达:MIT
例句:When I was a student at MIT I used to eat at a certainrestaurant in Boston.
(3)词性混淆错误
错误句子:About a decade ago,university students could find satisficeand enviable jobs after graduation,while at current situation,about 30%andeven worst of graduate students can’t finds a job but stay at home aftergraduation.
纠错提示:词性混淆错误,建议改为“satisfactory”。
建议表达:satisfactory
例句:Eventually it was possible to find a really satisfactorysolution.
(4)形容词短语错误
错误句子:About a decade ago,university students could find satisficeand enviable jobs after graduation,while at current situation,about 30%andeven worst of graduate students can’t finds a job and stay at home aftergraduation.
纠错提示:形容词短语错误,建议改为“worse”。
建议表达:worse
例句:I'd never been to that city before,and even worse,I couldn'tspeak a word of the language.
(5)助动词和情态动词错误
错误句子:About a decade ago,university students could find satisficeand enviable jobs after graduation,while at current situation,about 30%andeven worst of graduate students can’t finds a job and stay at home aftergraduation.
纠错提示:情态动词后面接动词原形,建议改为“find”。
建议表达:find
例句:I can't live in a place where I can't find a job.
(6)连词错误
错误句子:About a decade ago,university students could find satisficeand enviable jobs after graduation,while at current situation,about 30%andeven worst of graduate students can’t finds a job and stay at home aftergraduation.
纠错提示:连词错误,建议改为“but”。
建议表达:but
例句:He not only has a job but does the housework.
(7)动词语态错误
错误句子:Employment difficulty of college students was due to thefollowing reasons.
纠错提示:动词语态错误,建议改为“is”。
建议表达:is
例句:Three Chinese students were admitted to the college.
(8)标点符号错误
错误句子:Among these;the increasing recruitment of colleges anduniversities play a vital role.
纠错提示:标点符号错误,建议改为“,”。
建议表达:,
例句:The more,the better.
(9)主谓不一致错误
错误句子:Among these,the increasing recruitment of colleges anduniversities play a vital role.
纠错提示:主谓不一致错误,建议改为“plays”。
建议表达:plays
例句:The private colleges and universities of the united states areautonomous.
(10)固定搭配错误、介词错误
错误句子:On addition,many colleges and universities fail to adaptedthem courses to the development of economy.
纠错提示:介词错误,建议改为“In”。
建议表达:In
例句:I had to pay 5 dollars in addition.
(11)动词时态错误
错误句子:On addition,many colleges and universities fail to adaptedthem courses to the development of economy.
纠错提示:动词时态错误,建议改为“adapt”。
建议表达:adapt
例句:Many politicians fail to keep their word.
(12)代词错误
错误句子:On addition,many colleges and universities fail to adaptedthem courses to the development of economy.
纠错提示:代词错误,建议改为“their”。
建议表达:their
例句:Many politicians fail to keep their promises.
(13)不规则动词错误
错误句子:Considering such a rough job market,I think it is high timethat we taked effective measures to solve the problem.
纠错提示:不规则动词错误,建议改为“took”。。
建议表达:took
例句:It took him ten minutes to solve the problem.
(14)单词重复使用错误
错误句子:Above all,college students should realize their own defectsand further improve themselves to to keep their competitive edge in society.
纠错提示:单词重复使用错误,建议改为“to”。
建议表达:to
例句:Some students devote themselves to sports and neglect theirstudies.
(15)单复数不一致错误
错误句子:Moreover,colleges or university should provide moretrainings and internship opportunities before the students enter the society.
纠错提示:单复数不一致错误,建议改为“universities”。
建议表达:universities
例句:The private colleges and universities of the united states areautonomous.
(16)句子首字母大小写错误
错误句子:besides,college students should hold a right attitudetowards jobs and set their job expectations at a suitable level.
纠错提示:句子首字母大小写错误,建议改为“Besides”。
建议表达:Besides
例句:He's looking for a suitable job.
(17)冠词错误
错误句子:Only through these ways can the college students find asatisfactory job and have brighter future.
纠错提示:冠词缺失,建议改为“a brighter future”。
建议表达:a brighter future
例句:You have a bright future.