3

I know there are CoNLL-U parsers in Python. I would just like to get confirmation that NLTK does not have a native routine to parse CoNLL-U (or other CoNLL formats with dependency syntax).

Looking at the code, it seems HEAD and DEP are not among the permitted column types of conll. This is very unexpected because CoNLL-U is very popular nowadays, dependency syntax has been a core feature of many CoNLL formats since about 15 years, and this gap is not documented anywhere, so I'm pretty sure I'm overlooking something.

Geremia
  • 4,745
  • 37
  • 43
Chiarcos
  • 324
  • 1
  • 10
  • Hm. I take the lack of responses to mean that I've not been overlooking anything. NLTK doesn't do CoNLL-U. – Chiarcos Apr 08 '21 at 09:41

1 Answers1

2

The Python library conllu can.

courtesy: this answer to "Why can't I read in .conll file with Python (confusing parse-error)?"

Geremia
  • 4,745
  • 37
  • 43
  • And so does https://pypi.org/project/pyconll/, but not NLTK per se ... In fact most libraries for "CoNLL" formats are problematic in that they don't properly document which dialect they actually support. NLTK is nice because it supports a broad band-width of CoNLL formats, just primarily old ones, and CoNLL-U not being among them. – Chiarcos Sep 30 '21 at 14:09
  • Hopefully someone updates NLTK to support CoNLL-U. – Geremia Sep 30 '21 at 17:49