skip to navigation
skip to content

pylinkgrammar 0.1.9

Python bindings for Link Grammar system

Latest Version: 0.2.14

LinkGrammar is a sentence parsing system developed at Carnegie Melon University by John Lafferty, Daniel Sleator, Davy Temperley and others

LinkGrammar is written in C. This package contains a Pythonic interface to the C library.

You'll need to build and install linkgrammar before running

On Debian and ubuntu systems you:::
sudo apt-get install link-grammar

Then to install pylinkgrammar:::
pip install pylinkgrammar

How to use
Parsing simple sentences:::
>>> from linkgrammar import Parser
>>> p = Parser()
>>> linkages = p.parse_sent("This is a simple sentence.")
>>> len(linkages)
>>> print linkages[0].diagram

| +--------Ost-------+ |
| | +-------Ds------+ |
+---Wd---+-Ss*b+ | +----A----+ |
| | | | | | |
LEFT-WALL this.p is.v a simple.a sentence.n .  
File Type Py Version Uploaded on Size
pylinkgrammar-0.1.9.tar.gz (md5) Source 2012-01-12 11KB