13 lines
331 B
Python
13 lines
331 B
Python
from transformers import pipeline
|
|
import os
|
|
|
|
address = os.getcwd()
|
|
modelAddress = "~/tnlp/jokar/Flair_NER/taggers/final-model.pt"
|
|
print(modelAddress)
|
|
print('*'*100)
|
|
print('*'*100)
|
|
print('*'*100)
|
|
classifier = pipeline('ner', model=modelAddress)
|
|
from inference import read_file
|
|
input_sentence = read_file()
|
|
classifier(input_sentence) |