自然語言理解形式化句法_第1頁
自然語言理解形式化句法_第2頁
自然語言理解形式化句法_第3頁
自然語言理解形式化句法_第4頁
自然語言理解形式化句法_第5頁
已閱讀5頁,還剩59頁未讀, 繼續(xù)免費閱讀

下載本文檔

版權(quán)說明:本文檔由用戶提供并上傳,收益歸屬內(nèi)容提供方,若內(nèi)容存在侵權(quán),請進行舉報或認領(lǐng)

文檔簡介

自然語言理解形式化句法第1頁,課件共64頁,創(chuàng)作于2023年2月形式化語法理論

GrammarFormalism上海交通大學陳玉泉第2頁,課件共64頁,創(chuàng)作于2023年2月內(nèi)容提要概述(語法和語言)喬姆斯基(Chomsky)語法理論基于合一(Unification)的語法理論其它一些的語法理論(不基于上下文無關(guān)文法)第3頁,課件共64頁,創(chuàng)作于2023年2月一、概述第4頁,課件共64頁,創(chuàng)作于2023年2月什么是語法?AmathematicsystemDefinealanguageGivesyntax(structure)toasentence(string)第5頁,課件共64頁,創(chuàng)作于2023年2月人工語言及其語法基于符號無歧義或簡單歧義高效第6頁,課件共64頁,創(chuàng)作于2023年2月從可計算角度分類0,1,2,3UnrestrictedGrammarTuringMachine?ContextSensitiveGrammarTuringMachine?ContextFreeGrammarPushdownAutomatonO(n3)RegularExpressionFiniteStateAutomatonO(n)第7頁,課件共64頁,創(chuàng)作于2023年2月自然語言及其語法復(fù)雜歧義多樣第8頁,課件共64頁,創(chuàng)作于2023年2月形式化語法理論的目標判斷一句句子是否合法給出該句子唯一合法的結(jié)構(gòu)給出該句子中各成分(詞)之間的關(guān)系第9頁,課件共64頁,創(chuàng)作于2023年2月形式化語法理論應(yīng)具備的特性linguisticallyadequate準確描述自然語言expressive對語言世界用數(shù)學方法描述computationaleffective可計算,并且高效第10頁,課件共64頁,創(chuàng)作于2023年2月主要流派喬姆斯基語法理論基于合一的語法理論其它(不基于上下文無關(guān)文法)第11頁,課件共64頁,創(chuàng)作于2023年2月二、喬姆斯基語法理論第12頁,課件共64頁,創(chuàng)作于2023年2月NoamChomskyAmericanlinguist,writer,teacher,andpoliticalactivistPublicationsSyntacticStructuresAspectsoftheTheoryofSyntaxAmericanPowerandtheNewMandarins

PeaceintheMiddleEast

LecturesonGovernmentandBindingTheFatefulTriangle

DeterringDemocracyTheMinimalistProgram第13頁,課件共64頁,創(chuàng)作于2023年2月發(fā)展過程轉(zhuǎn)換生成語法(1957)SyntacticStructure.TheHague:Moutong&Co.管轄與約束理論(1981)LecturesonGovernmentandBinding.Foris,Dordrecht最簡方案(1992)AMinimalistProgramforLinguisticsTheory,MITOccasionalPapersinLinguistics,#1第14頁,課件共64頁,創(chuàng)作于2023年2月GB之前SurfaceStructureDeepStructureRules&LexiconTransfor-mationsSemanticInterpretationUtterance第15頁,課件共64頁,創(chuàng)作于2023年2月GB之后SurfaceStructureDeepStructureRules&LexiconLogicalFormPhonologicalFormmoveaX-Bar-SyntaxSubcategorizationSelectionalRestrictionsCaseTheoryq-CriterionBindingPrinciple第16頁,課件共64頁,創(chuàng)作于2023年2月短語結(jié)構(gòu)phrasalstructure句子的結(jié)構(gòu)是層次化的(hierarchical)Tree范疇(Category)Commoncategorialmembershipisevidencedbyintersubstitutivity中心詞(Headofaphrase)決定短語行為的詞Recursive某個類型可以包含在它自身中第17頁,課件共64頁,創(chuàng)作于2023年2月IntersubsitutivityandheadLondon,thewoman,theoldman,theproudyoungchild ------isknowntometheproudyoungchildtheproudchildtheyoungchild------childisthehead第18頁,課件共64頁,創(chuàng)作于2023年2月X-Bar理論VP?<leftarguments>V<rightarguments>VPVNP VPADVVPVPPX-BarX2

?<specifier>X1X1

?X0<complements>N的complements是形容詞,specifier是冠詞V的complements是賓語,specifier是主語這樣,V0表示單個動詞,V1表示動詞結(jié)構(gòu),V2表示句子01,12第19頁,課件共64頁,創(chuàng)作于2023年2月X-Bar理論(cont.)V1V1V0likeshisvisitthisweekinShanghaiN2N2P2V1第20頁,課件共64頁,創(chuàng)作于2023年2月題元理論q-Criterion題元理論研究各詞項之間的題元關(guān)系,即傳統(tǒng)語,即傳統(tǒng)語法中用施事、受事、工具等術(shù)語表示的概念范疇題元理論以動詞為中心,認為每一個題元角色都是由動詞分配的。agent:johnreadsabookinstrument:thekeyopensthedoorlocation:thebookcontainsgoodideas句中的每一個成分都必須有一個題元角色(coherence),同時,中心動詞的所有題元角色都已被分配(completeness)。第21頁,課件共64頁,創(chuàng)作于2023年2月格理論(CaseTheory)與語言相關(guān)。一般地,動詞,介詞賦格,名詞N2接受格X0

向N2賦格第22頁,課件共64頁,創(chuàng)作于2023年2月管轄GovernmentC-Command:ac-commandsb(a

1

b)iffeverybranchingnodeg,whichdominatesa,alsodominatesbadoesnotdominatebExample:Yc-commandsZ,C,D,EZc-commandsA,BAc-commandsBBc-commandsACc-commandsD,EXEDCBAZY第23頁,課件共64頁,創(chuàng)作于2023年2月管轄GovernmentM-Command:xm-commandyiffneitherofxandydominatestheother,andeverymaximalprojectionthatdominatesxalsodominatesy.N0dosenotc-commandsDetbutm-commandsDetXN0N1DetBAN2Y第24頁,課件共64頁,創(chuàng)作于2023年2月管轄GovernmentGovernment:xgovernsyiffx=X0xm-commandsy,andifex.zm-commandsy,zm-commandxorym-commandz.Headalwaysgoverntheircomplementsandspecifiers.動詞管轄主語和賓語,但主語不管轄賓語第25頁,課件共64頁,創(chuàng)作于2023年2月約束理論BindingPrinciple解決問題:指稱關(guān)系CompleteFunctionalComplex(CFC):AconstituentaisaCFC,ifitiscompleteandcoherent(q-criterion)原則照應(yīng)詞在CFC內(nèi)受約束,即它的先行詞必定在CFC內(nèi)。代名詞在CFC內(nèi)是自由的。指稱詞總是自由的。其中,照應(yīng)詞:包括反身代詞myself,yourself,相互代詞eachother等。代名詞:指傳統(tǒng)語法中的人稱代詞,如he,him等。指稱詞:就是通常所說的名詞短語,如theman,john等。第26頁,課件共64頁,創(chuàng)作于2023年2月約束理論BindingPrincipleJohnwantsTomtocriticizehimself.himself只能是Tom,不可能是John原則一JohnwantsTomtocriticizehim.him不能是Tom,但可能是John原則二第27頁,課件共64頁,創(chuàng)作于2023年2月TransformationSentenceWhatdidyougivetoJohn?D-Structure:[?[you[Tense[givewhattoJohn]]]]S-Structure[Whati[do+Tensej[you[tj[giveti

[toJohn]]]]]]第28頁,課件共64頁,創(chuàng)作于2023年2月轉(zhuǎn)換類型Passivizationsurfacestructure: thebookisgiventolindabyjandeepstructure: jangivesthebooktolindaAgent-Deletionsurfacestructure: thebookisgiventolindadeepstructure: someonegivesthebooktolindaEqui-NP-Deletionsurfacestructure: janpromiseslindatocomedeepstructure: janpromiseslindathatjancomes第29頁,課件共64頁,創(chuàng)作于2023年2月轉(zhuǎn)換類型Raisingsurfacestructure: janseemstocomedeepstructure: (it)seemsthatjancomesAnaphorssurfacestructure: janiwasheshimselfideepstructure: janwashesjanQuestion-Formationsurfacestructure: whatdoesjanread?deepstructure: ?janreadswhatImperatives(Agent-Deletion)surfacestructure: givethetoytoherdeepstructure: somonegivesthetoytoher第30頁,課件共64頁,創(chuàng)作于2023年2月轉(zhuǎn)換動作SubstitutionDisplaceandelementAdjunction…[Y

…X…]…[YXi[Y

…ti…]Example:[S[NPtheboy][VP[vbroke][NPthewindow]]]Theboybrokethewindow.Thewindowwasbroken(t)bytheboy.Movements:ReplacingsubjectNPbyobject;Postposingthesubjuct,addbyIntroducenewtense第31頁,課件共64頁,創(chuàng)作于2023年2月三、基于合一的語法第32頁,課件共64頁,創(chuàng)作于2023年2月基于合一的語法功能合一語法FUG廣義短語結(jié)構(gòu)語法GPSG中心詞驅(qū)動短語結(jié)構(gòu)語法HPSG詞匯功能語法LFG共同特點:引入特征和特征的合一第33頁,課件共64頁,創(chuàng)作于2023年2月特征結(jié)構(gòu)特征:[屬性:值]特征結(jié)構(gòu):特征的集合,其中任何兩個屬性不能相同一個特征結(jié)構(gòu)的例子:Num:pl|sgPer:3第34頁,課件共64頁,創(chuàng)作于2023年2月復(fù)雜特征集嵌套的特征結(jié)構(gòu)(nest),允許重入(reentrance)Cat:vSub:

Cat:rLex:heNum:sgCat:vPer:3(1)Sub:Cat:rPer:(1)Lex:he第35頁,課件共64頁,創(chuàng)作于2023年2月復(fù)雜特征集的圖形表示DAG3hervperpercatcatlexsub第36頁,課件共64頁,創(chuàng)作于2023年2月合一合一是定義在兩個特征結(jié)構(gòu)之間的一種操作合一成功:則原來的兩個獨立的特征結(jié)構(gòu)成為同一個特征結(jié)構(gòu)合一失?。翰划a(chǎn)生新的特征第37頁,課件共64頁,創(chuàng)作于2023年2月合一(cont)合一運算可遞歸定義為:如果a、b都是原子值,若a和b相等,則a?b=a,否則a、b合一失敗如果a、b均為特征結(jié)構(gòu),則對于a、b中的每一個特征f:若f(a)=v,但f(b)的值未經(jīng)定義,則<f,v>屬于a?b若f(b)=v,但f(a)的值未經(jīng)定義,則<f,v>屬于a?b若f(a)=v1,f(b)=v2,v1和v2相容,則<f,(v1∪v2)>屬于a?b,如果v1和v2不相容,則合一失敗*相容(consistent)針對兩個特征結(jié)構(gòu)而言,指存在另一個特征結(jié)構(gòu),同時包含(subsume)這兩個結(jié)構(gòu):包含:D1

íD2

?

"f?dom(D1):f(D1)íf(D2) &("p,q?dom(D1)*:p(D1)=q(D1)?p(D2)=q(D2)第38頁,課件共64頁,創(chuàng)作于2023年2月合一的算法描述D1,D2andDareconsideredassetsD:={};

while(D1!={}){

D1:=D1/(f=v);

if(f?dom(D2)){

D2:=D2/(f=v‘);

D:=Dè{f=vèv‘};

}

elseD:=Dè{f=v};

}

D:=DèD2;第39頁,課件共64頁,創(chuàng)作于2023年2月合一的例子Cat:vNum:sgCat:vNum:sgPer:3Cat:vNum:sgPer:3第40頁,課件共64頁,創(chuàng)作于2023年2月合一的例子(cont)Cat:vNum:sgCat:vNum:plPer:3第41頁,課件共64頁,創(chuàng)作于2023年2月合一的特性交換率結(jié)合率第42頁,課件共64頁,創(chuàng)作于2023年2月LFG詞匯功能語法(LexicalFunctionalGrammar)RonaldM.Kaplan,JoanBresnan

LexicalFunctionalGrammar-AFormalSystemforGrammaticalRepresentation

in:JoanBresnan(ed.),TheMentalRepresenta-tionofGrammaticalRelations,MITPress,Cambridge(MA)1982第43頁,課件共64頁,創(chuàng)作于2023年2月表示層次LexicalStructureC-structure(ConstituentStructure)F-structure(FunctionalStructure)第44頁,課件共64頁,創(chuàng)作于2023年2月LexicalStructurethe:Det, (-spec)=def

(-per)=3man:N, (-pred)=man

(-per)=3

(-num)=sgreads:V, (-pred)=read(subj,obj)

(-subjper)=3

(-subjnum)=sga:Det, (-spec)=indef

(-num)=sgbook:N, (-pred)=book

(-per)=3

(-num)=sg第45頁,課件共64頁,創(chuàng)作于2023年2月C-structureandF-structureSNPmanNVPDettheVNPbookNDetareadssubj pred read(subj,obj)objspec defper 3num sgpred manspec defper 3num sgpred book第46頁,課件共64頁,創(chuàng)作于2023年2月如何計算?詞典+上下文無關(guān)規(guī)則+f描述S? NP (-subj)=ˉ

VP -=ˉVP? V -=ˉ

NP (-obj)=ˉNP?Det -=ˉ N -=ˉ-指父節(jié)點,ˉ指當前節(jié)點第47頁,課件共64頁,創(chuàng)作于2023年2月例子 演示themanreadsabook *themanreadabook第48頁,課件共64頁,創(chuàng)作于2023年2月Coherence&CompletenessPA-StructureCoherence:任何有意義的語義結(jié)構(gòu)都必須在PA-Structure中出現(xiàn)Completeness:PA-Structure中出現(xiàn)的值都必須有與其對應(yīng)的語義結(jié)構(gòu)第49頁,課件共64頁,創(chuàng)作于2023年2月PPAttachmentsubj pred give(subj,obj,toobj)objtospec defper 3num sgpred manspec defper 3num sgpred bookprep toobjspec defper 3num sgpred womansubj pred see(subj,obj)objwith

spec defper 3num sgpred womanspec defper 3num sgpred manprep withobjspec defper 3num sgpred teles.Themangivesthebooktothewoman.thewomanseesthemanwiththetelescope第50頁,課件共64頁,創(chuàng)作于2023年2月FUGFunctionalUnificationGrammar功能合一語法MartinKay,1979,FunctionalGrammar,InProceedingsofthe4thAnnualMeetingoftheBerkeleyLinguisticsSociety.MartinKay,1985,ParsinginFunctionalGrammar,InD.Dowty,L.Karttunen,andA.Zwickyeds,NaturalLanguageParsing,CambridgeUniversityPress,Cambridge,1985.第51頁,課件共64頁,創(chuàng)作于2023年2月GPSGGeneralizedPhraseStructureGrammar廣義短語結(jié)構(gòu)語法GeraldGazdar,EwanKlein,GeoffreyPullum,IvanSagGeneralizedPhraseStructureGrammar

BasilBlackwell,Oxford1985第52頁,課件共64頁,創(chuàng)作于2023

溫馨提示

  • 1. 本站所有資源如無特殊說明,都需要本地電腦安裝OFFICE2007和PDF閱讀器。圖紙軟件為CAD,CAXA,PROE,UG,SolidWorks等.壓縮文件請下載最新的WinRAR軟件解壓。
  • 2. 本站的文檔不包含任何第三方提供的附件圖紙等,如果需要附件,請聯(lián)系上傳者。文件的所有權(quán)益歸上傳用戶所有。
  • 3. 本站RAR壓縮包中若帶圖紙,網(wǎng)頁內(nèi)容里面會有圖紙預(yù)覽,若沒有圖紙預(yù)覽就沒有圖紙。
  • 4. 未經(jīng)權(quán)益所有人同意不得將文件中的內(nèi)容挪作商業(yè)或盈利用途。
  • 5. 人人文庫網(wǎng)僅提供信息存儲空間,僅對用戶上傳內(nèi)容的表現(xiàn)方式做保護處理,對用戶上傳分享的文檔內(nèi)容本身不做任何修改或編輯,并不能對任何下載內(nèi)容負責。
  • 6. 下載文件中如有侵權(quán)或不適當內(nèi)容,請與我們聯(lián)系,我們立即糾正。
  • 7. 本站不保證下載資源的準確性、安全性和完整性, 同時也不承擔用戶因使用這些下載資源對自己和他人造成任何形式的傷害或損失。

評論

0/150

提交評論