template
U09:%x[0,0]/%x[1,0]
U10:%x[-2,1]/%x[0,1]
U19:%x[2,0]/%x[2,1]
U20:%x[-1,2]
You were debugging in the right direction. The issue is indeed with your template file.
Your training data has 3 columns (column 0:word
, column 1:pos-tag
and column 2:tag
).
You cannot use the tag
as feature, but your template file has reference to it (i.e, column 2) in many feature definitions (see, U20 to U29). Your training should work after removing/correcting these.
Hope this helps :)
You can also checkout these video tutorials for better understanding of Template Files and Training NER with CRF++ :