with open('./literary_form_classifier/model.pkl', 'rb') as fin:
    model = pickle.load(fin)

with open('./literary_form_classifier/vectorizer.pkl', 'rb') as fin:
    vectorizer = pickle.load(fin)

texts = ...
X_infer = vectorizer.transform(texts)
preds = model.predict(X_infer)

Model performance on test set:

Predicted
Actual
Skjønnlitteratur Faglitteratur Sum
Skjønnlitteratur 12 141 79 12 220
Faglitteratur 804 27 611 28 415
Sum 12 945 27 690 40 635

Accuracy: 97.83%, F1 Score: 96.49%, Precision: 99.35%, Specificity: 99.71%, Sensitivity: 93.79%, MCC: 95.00%

Downloads last month

-

Downloads are not tracked for this model. How to track
Inference Providers NEW
This model is not currently available via any of the supported Inference Providers.
The model cannot be deployed to the HF Inference API: The model has no library tag.