This repo contains the source code and the user evaluation data for TagRuler, a data programming by demonstration system for span-level annotation. Check out our demo video to see TagRuler in action!
Demonstration Video: https://youtu.be/MRc2elPaZKs
TagRuler synthesizes labeling functions based on your annotations, allowing you to quickly and easily generate large amounts of training data for span annotation, without the need to program.
In 2020, we introduced Ruler, a novel data programming by demonstration system that allows domain experts to leverage data programming without the need for coding. Ruler generates document classification rules, but we knew that there was a bigger challenge left to tackle: span-level annotations. This is one of the more time-consuming labelling tasks, and creating a DPBD system for this proved to be a challenge because of the sheer magnitude of the space of labeling functions over spans.
We feel that this is a critical extension of the DPBD paradigm, and that by open-sourcing it, we can help with all kinds of labelling needs.
Follow these instructions to run the system on your own, where you can plug in your own data and save the resulting labels, models, and annotations.
cd server
pip install -r requirements.txt
python -m spacy download en_core_web_sm
-
BC5CDR (Download Preprocessed Data): PubMed articles for Chemical-Disease annotation Li, Jiao & Sun, Yueping & Johnson, Robin & Sciaky, Daniela & Wei, Chih-Hsuan & Leaman, Robert & Davis, Allan Peter & Mattingly, Carolyn & Wiegers, Thomas & lu, Zhiyong. (2016). Original database URL: http://www.biocreative.org/tasks/biocreative-v/track-3-cdr/
-
Your Own Data See instructions in server/datasets
python api/server.py
You can download node.js here.
To confirm that you have node.js installed, run node - v
cd ui
npm install
npm start
By default, the app will make calls to localhost:5000
, assuming that you have the server running on your machine. (See the instructions above).
Once you have both of these running, navigate to localhost:3000
.
...or other inquiries, contact [email protected] and/or [email protected].