p-christ commited on
Commit
4ef3fc4
·
1 Parent(s): f3beae7

Update pipeline.py

Browse files
Files changed (1) hide show
  1. pipeline.py +2 -7
pipeline.py CHANGED
@@ -6,11 +6,8 @@ class PreTrainedPipeline():
6
  # Preload all the elements you are going to need at inference.
7
  # For instance your model, processors, tokenizer that might be needed.
8
  # This function is only called once, so do all the heavy processing I/O here"""
9
- raise NotImplementedError(
10
- "Please implement PreTrainedPipeline __init__ function"
11
- )
12
 
13
- def __call__(self, inputs: str) -> List[float]:
14
  """
15
  Args:
16
  inputs (:obj:`str`):
@@ -19,6 +16,4 @@ class PreTrainedPipeline():
19
  A :obj:`list` of floats: The features computed by the model.
20
  """
21
  # IMPLEMENT_THIS
22
- raise NotImplementedError(
23
- "Please implement PreTrainedPipeline __call__ function"
24
- )
 
6
  # Preload all the elements you are going to need at inference.
7
  # For instance your model, processors, tokenizer that might be needed.
8
  # This function is only called once, so do all the heavy processing I/O here"""
 
 
 
9
 
10
+ def __call__(self, inputs: str) -> str:
11
  """
12
  Args:
13
  inputs (:obj:`str`):
 
16
  A :obj:`list` of floats: The features computed by the model.
17
  """
18
  # IMPLEMENT_THIS
19
+ return "hello"