From f6fe114ba5123b21327fb28759f1c11507cbaba6 Mon Sep 17 00:00:00 2001 From: Charlene Leong Date: Thu, 24 Feb 2022 05:13:39 +0000 Subject: [PATCH] Fixing lru cache --- zeroshot_topics/utils.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/zeroshot_topics/utils.py b/zeroshot_topics/utils.py index e5bfc9b..4e11a4e 100644 --- a/zeroshot_topics/utils.py +++ b/zeroshot_topics/utils.py @@ -2,7 +2,7 @@ from transformers import pipeline -@lru_cache +@lru_cache() def load_zeroshot_model(model_name="valhalla/distilbart-mnli-12-6"): classifier = pipeline("zero-shot-classification", model=model_name) return classifier