-
-
Notifications
You must be signed in to change notification settings - Fork 7
Dependency parsing
Mika Hämäläinen edited this page Mar 8, 2019
·
8 revisions
UralicNLP provides a Python binding to Turku Finnish Dependency Parser and Turku Neural Parser.
UralicNLP currently supports only Finnish for dependency parsing. It requires the Turku Dependency Parser Docker to be configured and running.
If you want to use the latest neural parser, make sure you run it on docker like so
docker run -d -p 9876:7689 turkunlp/turku-neural-parser:finnish-cpu-plaintext-server
from uralicNLP import dependency
ud = dependency.parse_text("kissa nauroi kovaa\nLehmä lauloi", "fin")
The result will be returned as a UD_collection object. If the docker is running in some other port than 9876 or on another server, you can specify that in the url parameter dependency.parse_text(text, "fin", url="http://localhost:9876")
.
UralicNLP is an open-source Python library by Mika Hämäläinen