karanvirsagar1998 commited on
Commit
3c0e4f9
·
verified ·
1 Parent(s): f923110

Update model.py

Browse files
Files changed (1) hide show
  1. model.py +6 -2
model.py CHANGED
@@ -1,5 +1,9 @@
1
  # Use a pipeline as a high-level helper
2
  from transformers import pipeline
 
3
 
4
- translator = pipeline("translation", model="PaulineSanchez/autotrain-translation_food_english_to_french-52830124391")
5
-
 
 
 
 
1
  # Use a pipeline as a high-level helper
2
  from transformers import pipeline
3
+ import os
4
 
5
+ HF_TOKEN = os.getenv("TOKEN")
6
+ translator = pipeline("translation",
7
+ model="PaulineSanchez/autotrain-translation_food_english_to_french-52830124391",
8
+ token = HF_TOKEN
9
+ )