1 / 21

CS 182 Sections 103 - 104

CS 182 Sections 103 - 104. Eva Mok (emok@icsi.berkeley.edu) April 21, 2004. Announcements. a9 out sometime Thursday, due Wednesday April 22nd, 11:59pm How’s your progress on the BBS articles?. Schedule. Last Week SHRUTI Formal Grammar and Parsing This Week Construction Grammar, ECG

svea
Download Presentation

CS 182 Sections 103 - 104

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. CS 182Sections 103 - 104 Eva Mok (emok@icsi.berkeley.edu) April 21, 2004

  2. Announcements • a9 out sometime Thursday, due Wednesday April 22nd, 11:59pm • How’s your progress on the BBS articles?

  3. Schedule • Last Week • SHRUTI • Formal Grammar and Parsing • This Week • Construction Grammar, ECG • Psychological model of sentence processing • Next Week • Language learning • Learning ECG

  4. Quiz • What is top-down parsing? Using a plausible CFG grammar, what is the top down parse of “Pat ate the kiwi”? • How well can CFGs represent English? What are some mechanisms for improvement? • What are constructions? • What is the difference between subcasing and evoking another schema or construction?

  5. Quiz • What is top-down parsing? Using a plausible CFG grammar, what is the top down parse of “Harry likes the cafe”? • How well can CFGs represent English? What are some mechanisms for improvement? • What are constructions? • What is the difference between subcasing and evoking another schema or construction?

  6. Grammar • A grammar is a set of rules defining a formal language • an example is right-regular grammar • a more common example is Context-Free Grammar   β •  : single non-terminal • β : any combination of terminals and non-terminals S  NP VP NP  Det Noun | ProperNoun VP  Verb NP | Verb PP PP  Preposition NP Noun  kiwi | orange | store ProperNoun  Pat | I Det  a | an | the Verb  ate | went | shop Preposition  to | at

  7. Top Down Parsing: Pat ate the kiwi • start from S and apply all applicable rules • forward search (use your favorite search algorithm…) S S  NP VP NP  Det Noun | ProperNoun VP  Verb NP | Verb PP PP  Preposition NP NP VP Det Noun VP ProperNoun VP Noun  kiwi | orange | store ProperNoun  Pat | I Det  a | an | the Verb  ate | went | shop Preposition  to | at a Noun VP an Noun VP the Noun VP … a kiwi VP a orange VP a store VP succeed when you encounter Pat ate the kiwiin a state without any non-terminals (DFS)

  8. Bottom Up Parsing: Pat ate the kiwi • start from the sentence and try to match non-teriminals to it • backward search (use your favorite search algorithm…) S S  NP VP NP  Det Noun | ProperNoun VP  Verb NP | Verb PP PP  Preposition NP NP VP NP Verb NP Noun  kiwi | orange | store ProperNoun  Pat | I Det  a | an | the Verb  ate | went | shop Preposition  to | at NP Verb DetNoun NP Verb Det kiwi NP Verb the kiwi NP ate the kiwi succeed when you encounter Sin a state by itself ProperNoun ate the kiwi Pat ate the kiwi (DFS)

  9. Quiz • What is top-down parsing? Using a plausible CFG grammar, what is the top down parse of “Harry likes the cafe”? • How well can CFGs represent English? What are some mechanisms for improvement? • What are constructions? • What is the difference between subcasing and evoking another schema or construction?

  10. Notice the ungrammatical and/or odd sentences that we can generate? • * Pat ate a orange • *Pat shop at the store • *Pat went a store • ?Pat ate a store • ?The kiwi went to an orange S  NP VP NP  Det Noun | ProperNoun VP  Verb NP | Verb PP PP  Preposition NP Noun  kiwi | orange | store ProperNoun  Pat | I Det  a | an | the Verb  ate | went | shop Preposition  to | at need to capture agreement, subcategorization, etc you could make many versions of verbs, nouns, dets  cumbersome

  11. Pat number : SG person : 3rd agreement I number : SG person : 1st agreement Went agreement Shop number : person : 1st agreement Unification Grammar • Basic idea: capture these agreement features for each non-terminal in feature structures • Enforce constraints on these features using unification rules • VP  Verb NP • VP.agreement ↔ Verb.agreement • S  NP VP • NP.agreement ↔ VP.agreement

  12. Quiz • What is top-down parsing? Using a plausible CFG grammar, what is the top down parse of “Harry likes the cafe”? • How well can CFGs represent English? What are some mechanisms for improvement? • What are constructions? • What is the difference between subcasing and evoking another schema or construction?

  13. CAFE Embodied constructions ECG Notation Form Meaning constructionHARRY form : /hEriy/ meaning : Harry Harry constructionCAFE form : /khaefej/ meaning : Cafe cafe Constructions have form and meaning poles that are subject to type constraints.

  14. Quiz • What is top-down parsing? Using a plausible CFG grammar, what is the top down parse of “Harry likes the cafe”? • How well can CFGs represent English? What are some mechanisms for improvement? • What are constructions? • What is the difference between subcasing and evoking another schema or construction?

  15. A schema hierarchy of objects (Nomi) schema Entity schema Physical-Object subcase of Object, Place schema Human subcase of Animate roles sex schema Place schema Animate subcase of Physical-Object roles animacy constraints animacy ← true schema Object subcase of Entity schema Nomi subcase of Human sex ← female slot filler schema Referent subcase of Entity roles category distribution boundedness number gender accessibility resolved-ref schema Toy subcase of Manipulable-Object schema Manipulable-Object subcase of Physical-Object schema Cup subcase of Manipulable- Object schema Ball subcase of Toy

  16. The schemas we just defined Entity Place Referent Object Physical-Object Food Manipulable-Object Animate Cup Toy Human Cake Juice Ball Book Block Doll Bed Nomi Mother Father

  17. A schema hierarchy of actions (Nomi) schema Action roles agent : Entity schema CauseMove subcase of DirectedAction, Move roles causer : Human mover : Physical-Object motion : Move constraints motion.mover ↔ mover motion.agent ↔ causer motion.direction ↔ direction agent ↔ causer patient ↔ mover type constraint schema DirectedAction subcase of Action roles patient : Entity identification constraint schema Move subcase of Action roles mover : Entity direction : Place

  18. The schemas we just defined Action Directed Action Move Cause-Move Transfer JointMove

  19. Constructions, finally (Nomi) construction Ref-Expr form : Schematic-Form meaning : Referent construction Cup-Cn level 0 subcase of Ref-Expr form : Word self.f.orth ← “cup" meaning evokes Cup as n self.m.category ↔ n self.m.resolved-ref ↔ n construction Nomi-Cn level 0 subcase of Ref-Expr form : Word self.f.orth ← "Nomi" meaning evokes Nomi as n self.m.category ↔ n self.m.resolved-ref ↔ n local name fancy way of saying that the category of the referent is Nomi

  20. Constructions, finally (Nomi) construction Motion-Verb meaning : Move construction Cause-Motion-Verb subcase of Motion-Verb meaning : CauseMove construction Get-Cn level 0 subcase of Cause-Motion-Verb form : Word self.f.orth ← "get" lexical construction

  21. Constructions, finally (Nomi) construction Transitive-Cn level 2 constructional constituents agt : Ref-Expr v : Cause-Motion-Verb obj : Ref-Expr form agt.f before v.f v.f before obj.f meaning v.m.agent ↔ agt.m.resolved-ref v.m.patient ↔ obj.m.resolved-ref smaller constructions that it takes ordering constraints on the constituents

More Related