onsider the following positive examples: Bart giggles Homer giggled In this practical, we don't consider ellipsis, nor do we consider uncommon usage of words that would require a stretch of imagination to justify.) Once more run /usr/local/python/bin/python3 P2.py. Bart and Lisa drank milk Bart vears blue shoes Step 3: feature grammar Homer serves Lisa and Bart a healthy green salad Bart always drinks milk The grammar you wrote in Step 1 will likely accept some of the negative examples. This is because the following have not been modelled: Lisa thinks Homer thinks Bart drinks milk • number agreement, Homer and Bart never drink milk in the kitchen after lunch when does Lisa drink milk in the kitchen when Homer drinks milk Bart giggles • subcategorisation. when do Lisa and Bart wear shoes For number agreement, first remember that English has five verb forms for ordinary verbs (and a few more for to be): Lisa puts the milk in the kitchen • base form: to write, you write Note that all punctuation has been removed in order to avoid complications, and we do not enforce capitalisation at the beginning of sentences. Extend P2.fcfg with more rules so that all words from the above sentences are included. You will need to introduce more parts of speech such as Det (e.g. 'the'), Prep (e.g. 'in', 'after'), Adj (e.g. 'green'), and a few more. Note that the two occurrences of "when' have different functions, so need to be associated with different parts of speech. At this point, you may not want to distinguish between singular and plural noun • third person singular present: he writes • preterite (a.k.a. simple past): wrote • past participle: written • present participle (a.k.a. gerund if used as noun): writing phrases, nor between different verb forms, nor between verbs with different subcate- gorisation frames. Also add more context-free rules, so that the above sentences can be derived. Make sure the rules defining the start symbol (S) come first. (NLTK by default assumes that the first mentioned nonterminal is the start symbol.) When designing your grammar, beware of the distinction between argument and adiunct In the ahove example sentences PP in the kitchen' is once an adiunct and For our simple examples, we only need the first form (used for third person plural present, and infinitive) and the second (third person singular present) and the third (preterite). Features can be added to the grammar to ensure that only the correct verb forms are allowed, and that there is number agreement for those verb forms where it is relevant. Subcategorisation should be imnlemented as illustrated by the following example
onsider the following positive examples: Bart giggles Homer giggled In this practical, we don't consider ellipsis, nor do we consider uncommon usage of words that would require a stretch of imagination to justify.) Once more run /usr/local/python/bin/python3 P2.py. Bart and Lisa drank milk Bart vears blue shoes Step 3: feature grammar Homer serves Lisa and Bart a healthy green salad Bart always drinks milk The grammar you wrote in Step 1 will likely accept some of the negative examples. This is because the following have not been modelled: Lisa thinks Homer thinks Bart drinks milk • number agreement, Homer and Bart never drink milk in the kitchen after lunch when does Lisa drink milk in the kitchen when Homer drinks milk Bart giggles • subcategorisation. when do Lisa and Bart wear shoes For number agreement, first remember that English has five verb forms for ordinary verbs (and a few more for to be): Lisa puts the milk in the kitchen • base form: to write, you write Note that all punctuation has been removed in order to avoid complications, and we do not enforce capitalisation at the beginning of sentences. Extend P2.fcfg with more rules so that all words from the above sentences are included. You will need to introduce more parts of speech such as Det (e.g. 'the'), Prep (e.g. 'in', 'after'), Adj (e.g. 'green'), and a few more. Note that the two occurrences of "when' have different functions, so need to be associated with different parts of speech. At this point, you may not want to distinguish between singular and plural noun • third person singular present: he writes • preterite (a.k.a. simple past): wrote • past participle: written • present participle (a.k.a. gerund if used as noun): writing phrases, nor between different verb forms, nor between verbs with different subcate- gorisation frames. Also add more context-free rules, so that the above sentences can be derived. Make sure the rules defining the start symbol (S) come first. (NLTK by default assumes that the first mentioned nonterminal is the start symbol.) When designing your grammar, beware of the distinction between argument and adiunct In the ahove example sentences PP in the kitchen' is once an adiunct and For our simple examples, we only need the first form (used for third person plural present, and infinitive) and the second (third person singular present) and the third (preterite). Features can be added to the grammar to ensure that only the correct verb forms are allowed, and that there is number agreement for those verb forms where it is relevant. Subcategorisation should be imnlemented as illustrated by the following example
Computer Networking: A Top-Down Approach (7th Edition)
7th Edition
ISBN:9780133594140
Author:James Kurose, Keith Ross
Publisher:James Kurose, Keith Ross
Chapter1: Computer Networks And The Internet
Section: Chapter Questions
Problem R1RQ: What is the difference between a host and an end system? List several different types of end...
Related questions
Question
100%
Expert Solution
This question has been solved!
Explore an expertly crafted, step-by-step solution for a thorough understanding of key concepts.
This is a popular solution!
Trending now
This is a popular solution!
Step by step
Solved in 2 steps
Recommended textbooks for you
Computer Networking: A Top-Down Approach (7th Edi…
Computer Engineering
ISBN:
9780133594140
Author:
James Kurose, Keith Ross
Publisher:
PEARSON
Computer Organization and Design MIPS Edition, Fi…
Computer Engineering
ISBN:
9780124077263
Author:
David A. Patterson, John L. Hennessy
Publisher:
Elsevier Science
Network+ Guide to Networks (MindTap Course List)
Computer Engineering
ISBN:
9781337569330
Author:
Jill West, Tamara Dean, Jean Andrews
Publisher:
Cengage Learning
Computer Networking: A Top-Down Approach (7th Edi…
Computer Engineering
ISBN:
9780133594140
Author:
James Kurose, Keith Ross
Publisher:
PEARSON
Computer Organization and Design MIPS Edition, Fi…
Computer Engineering
ISBN:
9780124077263
Author:
David A. Patterson, John L. Hennessy
Publisher:
Elsevier Science
Network+ Guide to Networks (MindTap Course List)
Computer Engineering
ISBN:
9781337569330
Author:
Jill West, Tamara Dean, Jean Andrews
Publisher:
Cengage Learning
Concepts of Database Management
Computer Engineering
ISBN:
9781337093422
Author:
Joy L. Starks, Philip J. Pratt, Mary Z. Last
Publisher:
Cengage Learning
Prelude to Programming
Computer Engineering
ISBN:
9780133750423
Author:
VENIT, Stewart
Publisher:
Pearson Education
Sc Business Data Communications and Networking, T…
Computer Engineering
ISBN:
9781119368830
Author:
FITZGERALD
Publisher:
WILEY