stefan-it commited on
Commit
dc1ac33
1 Parent(s): a27215a

pipeline: fix split call

Browse files
Files changed (1) hide show
  1. pipeline.py +1 -1
pipeline.py CHANGED
@@ -6,4 +6,4 @@ class PreTrainedPipeline:
6
  self.model = WtP(model_name_or_model="wtp-canine-s-de-hist-12l", hub_prefix="stefan-it")
7
 
8
  def __call__(self, inputs: str) -> List[Dict]:
9
- return [{"generated_text": "</s>\n".join(sent.strip() for sent in wtp.split(text, lang_code="de", style="ud"))}]
 
6
  self.model = WtP(model_name_or_model="wtp-canine-s-de-hist-12l", hub_prefix="stefan-it")
7
 
8
  def __call__(self, inputs: str) -> List[Dict]:
9
+ return [{"generated_text": "</s>\n".join(sent.strip() for sent in self.model.split(text, lang_code="de", style="ud"))}]