Archive for February, 2010

The Power of the Human Mind

Monday, February 22nd, 2010

I received this text in an email.  It pretty much says it all.

i cdnuolt blveiee taht I cluod aulaclty uesdnatnrd waht I was rdanieg. The phaonmneal pweor of the hmuan mnid, aoccdrnig to a rscheearch at Cmabrigde Uinervtisy, it dseno’t mtaetr in waht oerdr the ltteres in a wrod are, the olny iproamtnt tihng is taht the frsit and lsat ltteer be in the rghit pclae. The rset can be a taotl mses and you can sitll raed it whotuit a pboerlm. Tihs is bcuseae the huamn mnid deos not raed ervey lteter by istlef, but the wrod as a wlohe. Azanmig huh? yaeh and I awlyas tghuhot slpeling was ipmorantt!

More Ideas from Yoav Seginer

Saturday, February 6th, 2010

Yoav Seginer wrote his dissertation on the Incremental Parser.  The paper is pretty easy to read – accessible.  The introduction is an especially well written introduction to unsupervised grammar induction.

I was surprised to read what he had to say about substitutability.   Substitutability is the capacity to replace phrases with other phrases that are of the same type.  For example ‘the dog’ in ‘the dog ran to town’ can be replaced with ‘it’.   So in some sense, the phrase ‘the dog’ and ‘it’ can be substituted for each other.  This is one of the cornerstones of linguistic theory and is used as a basis of many parsing techniques.  The PCFG parser uses probabilities for a phrase type that can be traded out in a given context.

However, Seginer makes the claim that substitutability is not required for his incremental parser.

Substitutability, the essential idea of the Harris method, which has been seen as a starting point for the induction process for so long, turns out to be unnecessary in unsupervised parsing.

 …unlabeled parsing which only requires the parser to identify the constituents (or dependency links) but does not require them to be labeled, is purely syntagmatic (by definition).   A parser induction algorithm can therefore focus on learning to detect syntactic units while ignoring substitutability. (p20)

Another fresh idea (to me) from Seginer’s paper is the skewness of language structure.

The syntactic structure of natural language is skewed. This simply means that when the syntactic structure of an utterance is represented by a tree, each node in the tree has at least one short branch. The shorter the shortest branch is, the greater the skewness.  (p22)

Essentially how the incremental parser takes advantage of skewness is to expect skewness in the parse result.  This reduces the search size and thereby make the parsing process more efficient.

…context free grammars, allow (a-priori) any tree structure and, therefore, a learning algorithm for such representations must discover by itself the skewness property of syntactic trees. However, if this property is indeed universal, there is no need to burden the learning algorithm with its discovery and it is possible to code skewness directly into the parser.  (p23)

He claims that ‘coding the skewness’ into the syntactic representation and the parser, i.e., expecting branches to be of mixed depths, does not retract from the accuracy of the parse result.

Here is a link to Yoav’s dissertation.  Dissertation

Since graduating in 2007, it looks like Yoav Seginer is working at a  small company in Amsterdam, Mondria Technologies Ltd (according to LinkedIn.com).  The company website doesn’t say anything yet.  I wonder if they are working on a project that uses the incremental parser.

Incremental Unsupervised Grammar Learning

Friday, February 5th, 2010

This paper by Yoav Seginer is very exciting.  It covers a method of learning a language grammar that resonates with my mental model of how a young child learns language.  These are some aspects of the Seginer algorithm.

Incremental Learning.  The system adds information to the grammar with each new sentence.  In other approaches (CCM by Manning and Klein, UDOP by Bod), the entire corpus is processed as a block to collect the parameters of the grammar and the entire corpus is repeatedly processed until the learning converges on final result.  In Seginer’s approach, the corpus is processed one sentence at a time.  After each sentence, the grammar weights are updated.  That sentence is not revisited for further training.

Simpler Math.  The approach by Seginer uses much simpler math for computing the parameters of the resulting grammar.   There are a few ratios, some accumulation of values into other, and some comparison of weights to choose which one to apply for a given step.  There are no long chains of probabilities to compute the best parse.  I don’t have any principled reason why this makes more sense for a model of how the brain works – it just fits my gut feeling better.

Not Restricted to Binary Trees.  The CMM approach and others approaches that are referenced in Seginer’s paper all give binary parse trees as the result.  But natural languages aren’t limited to binary trees.  Although it is possible to represent any non-binary tree as a binary tree, forcing a binary representation onto natural language is not adding to the value of the result.  Seginer’s process gives parse trees that include constructions of more than two nodes.

Exocentric Constructions.   A phrase like ‘the boy’ has links going both directions between the two words.  Either word can be considered the head of the phrase – which in some way matches the disagreement between linguists about which word is actually the head of the phrase.

Link depths.  His algorithm result include a depth value on dependency links.  This value can be used to distinguish between internal and external arguments to a phrase.

Incremental Parsing.  For each word read into the sentence, links can only be added to or from the new word.

             I know the boy (sleeps)

When the algorithm encounters the word sleeps it can only add a link to or from this word.  No links that were generated at earlier steps can be affected.   This reduces the search space and contributes to the overall speed of the parser.  Another advantage is that the links in ‘I know the boy’ are an exact subset of the links in ‘I know the boy sleeps’.  There is no decision necessary about dropping links that were previously discovered.

No Clustering.  Seginer’s approach groups words with class labels that in some respect are part of speech classes.  However, the approach does not require clustering of words into specific classes.  It finds similarities between the and a but it does not require that all determiners are grouped together in a well defined class.  This makes the approach better able to deal with noise in the training data.

Homophony.  When a word has more than one meaning, it can confuse any machine algorithm.  Seginer’s algorithm deals with homophony by comparing labels between target pairs of words.  In the example that follows, words in brackets are possible labels for the target words.  When an underscore appears in the label, it means look at  the label of the preceding or following word.

             This[the] year[_the]    (this is a determiner)

            This[is_] was [is]          (this is a pronoun).

In the example given above, in one case this is a determiner.  One of its labels is [the] because this and the occur in similar places.  In the second line a label for this is [is_] which means that this is frequently followed by is.  The algorithm finds pairs of labels such as [the] and [_the] or [is_] and [is] to decide where to put links.

I think Seginer’s approach has some real merit.  It is a greedy algorithm – it learns as it goes and does not need to revisit previous sentences.  It uses simple math.  It has results that seem to match psycholinguistic models.   It would be great to see this approach extended to take advantage of other linguistic phenomena such as morphology.

 A link to the paper can be found here.  Paper

 A link to a video presentation on the approach can be found here.    Video