Sie sind auf Seite 1von 12

Link Grammar

A link grammar consists of a set of words, each of which has a


linking requirement (also called its formula) :

Notation:
D: determiner, looking for a noun to link with to the right
S: subject
O: object, a noun can be the subject of a verb to its right,
or object of transitive verb to its left.

Diagram to show how linking requirements are satisfied.


This is a linkage, or parse.

The following sentence cannot be properly parsed.


The links cross.

Grammaticality conditions
Planarity: Links dont cross when drawn above words
Connectivity: All the words in a sentence must be connected.
Satisfaction: The link satisfies the linking requirements of each word
in the sentence.
Exclusion: No two links connect the same pair of words.

Using a simpler convention to display a linkage.


D: determiner
S: subject
O: object

The dictionary entries

To the right: +
To the left:

Experimenting with the Link Parser on line


Go to http://www.link.cs.cmu.edu/link/
Select parser
select Show constituent tree
Allow null links
Show all linkages (omit for long sentences)
Consult Documentation to find out meaning of any
links you do not know.

Output from the parser - see next slides too


Found 1 linkage (1 with no P.P. violations)
Unique linkage.
+-------------Xp------------+
+-----Wd----+
|
|
+-Ds-+---Ss--+--Ox-+ |
|
|
|
|
| |
LEFT-WALL the dog.n chased.v me .
Constituent tree:
(S (NP The dog)
(VP chased
(NP me))
.)

Notation
Xp: link to punctuation
Wd: link from wall to head of subject
Ds: link from determiner to singular noun
Ss: link from singular subject to verb
Ox: link from transitive verb to singular object
dog.n shows dog is used as a noun
chased.v shows chased is used as a verb

10

Interpreting output of parser


Ignore time
Ignore cost vector
P.P. stands for post processing - a final extra stage.There
should be no P.P. violations.
A null link means the parser cannot find a linkage
unless it drops a word.
Found 1 linkage (1 with no P.P. violations) means one parse
has been found. Often more than one is found.
The LEFT-WALL just marks the start of the sentence.
11

Experiments with Link Grammar


Before experimenting with the Link parse, decide what you think the
parse should be for each sentence. Is the sentence grammatical?
Should a linkage be found ?
Does the Link parser find just one linkage or more ?
How does the parser deal with features that might be expected to
confuse it ? E.g words with more than one part-of-speech, idioms,
idiosyncratic use, common words that are known to cause problems
like and.
What does it do well, and what can you trip it up on ?

12

Das könnte Ihnen auch gefallen