Tools for training a Stanford NER model, based on the example in the Stanford NER FAQ.
- Install Java.
- Download Stanford NER from https://nlp.stanford.edu/software/CRF-NER.shtml#Download
- Extract it to a directory named
stanford-nerin this directory.
- Provide two sets of examples in
train.txtandtest.txtwith one example on each line. - Run
make sourcesto producetrain.tsvandtest.tsv. - Edit
train.tsvandtest.tsv, replacingOwith entity names where appropriate. This may take some time. - Run
make modelto produce the model, inner-model.ser.gz. - Run
make checkto test the model against the examples fromtest.txt.