dmcc / PyStanfordDependencies

Python interface for converting Penn Treebank trees to Stanford Dependencies and Universal Depenencies
https://pypi.python.org/pypi/PyStanfordDependencies
68 stars 17 forks source link

Add shortcut method to StanfordDependencies #2

Closed dmcc closed 9 years ago

dmcc commented 9 years ago

Bad:

from StanfordDependencies import StanfordDependencies
sd = StanfordDependencies.get_instance()

Better:

import StanfordDependencies
sd = StanfordDependencies.get_instance()

StanfordDependencies.py should have a get_instance() method that forwards to StanfordDependencies.get_instance().