Skip to content

Latest commit

 

History

History
41 lines (28 loc) · 1.16 KB

README.md

File metadata and controls

41 lines (28 loc) · 1.16 KB

Recogito Flair NER Plugin

An (experimental) plugin to the Recogito annotation platform that adds Flair by Zalando Research as a Named Entity Recognition Engine.

Screenshot

The plugin consists of two parts:

  1. a minimal Python script that takes a filename as input, runs NER with Flair, and writes JSON results to STDOUT
  2. a Scala wrapper that implements the Recogito plugin interface, and calls out to the Python script via the command line

Pre-Requisites

Make sure Flair is installed on your system: pip install flair

Testing

To run just the Python script use

python plugins/recogito.plugins.ner.flair/parse.py {filename}

To test parsing throught the Scala wrapper run

sbt test

Compile and Deploy

  • build the plugin using sbt package. This will create the .jar file target\recogito-plugin-ner-flair-0.1.jar.
  • copy the .jar into a subfolder inside the Recogito /plugins folder
  • copy the Python script to the same subfolder
  • make sure Flair is installed on the Recogito server