mwitiderrick commited on
Commit
6d0b4f5
1 Parent(s): 4f86e8d

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -8,7 +8,7 @@ DeepSparse is sparsity-aware inference runtime offering GPU-class performance on
8
  The text classification Pipeline, for example, wraps an NLP model with the proper preprocessing and postprocessing pipelines, such as tokenization. Here is sample code for a text classification pipeline:
9
  ```
10
  from deepsparse import Pipeline
11
- pipeline = Pipeline.create(task=task, model_path="zoo:nlp/text_classification/distilbert-none/pytorch/huggingface/mnli/pruned80_quant-none-vnni",model_scheme="mnli",model_config={"hypothesis_template": "This text is related to {}"},)
12
  inference = pipeline(sequences= text,labels=['politics', 'public health', 'Europe'],)
13
  print(inference)
14
  ```
 
8
  The text classification Pipeline, for example, wraps an NLP model with the proper preprocessing and postprocessing pipelines, such as tokenization. Here is sample code for a text classification pipeline:
9
  ```
10
  from deepsparse import Pipeline
11
+ pipeline = Pipeline.create(task="zero_shot_text_classification", model_path="zoo:nlp/text_classification/distilbert-none/pytorch/huggingface/mnli/pruned80_quant-none-vnni",model_scheme="mnli",model_config={"hypothesis_template": "This text is related to {}"},)
12
  inference = pipeline(sequences= text,labels=['politics', 'public health', 'Europe'],)
13
  print(inference)
14
  ```