DhaneshV commited on
Commit
bb39afc
·
1 Parent(s): 7f561eb

Update testing.py

Browse files
Files changed (1) hide show
  1. testing.py +3 -3
testing.py CHANGED
@@ -2,10 +2,10 @@ from transformers import Pipeline
2
  import torch
3
 
4
  class DeclarativePipeline(Pipeline):
5
- def _sanitize_parameters(self, *args):
6
- return args, {}, {}
7
 
8
- def preprocess(self, inputs, question, answer):
 
 
9
  return self.tokenizer(
10
  question,
11
  answer,
 
2
  import torch
3
 
4
  class DeclarativePipeline(Pipeline):
 
 
5
 
6
+ def preprocess(self, inputs):
7
+ question = inputs.split("#")[0]
8
+ answer = inputs.split("#")[1]
9
  return self.tokenizer(
10
  question,
11
  answer,