Autoregressive Structured Prediction with Language Models
Paper • 2210.14698 • Published
How to use tliu/flan-t5-base-conll03-ner with Transformers:
# Load model directly
from transformers import AutoTokenizer, T5NER
tokenizer = AutoTokenizer.from_pretrained("tliu/flan-t5-base-conll03-ner")
model = T5NER.from_pretrained("tliu/flan-t5-base-conll03-ner", device_map="auto")This model is initialized from flan-t5-base and finetuned for named entity recognition task. The model structure is described in the paper Autoregressive Structured Prediction with Language Models, Github repo.
CUDA_VISIBLE_DEVICES=0 python evaluate_ner.py flant5_base tliu/flan-t5-base-conll03-ner 0