iimran commited on
Commit
795f70c
·
verified ·
1 Parent(s): 16ab585

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -1,8 +1,8 @@
1
  import gradio as gr
2
  from transformers import BartTokenizer, BartForConditionalGeneration
 
 
3
  hf_token = os.getenv("HF_TOKEN")
4
- if hf_token is None:
5
- raise ValueError("HF_TOKEN environment variable is not set.")
6
 
7
  # Load model and tokenizer from Hugging Face hub using the provided model name
8
  model_name = "iimran/SAM-TheSummariserV2"
 
1
  import gradio as gr
2
  from transformers import BartTokenizer, BartForConditionalGeneration
3
+ from huggingface_hub import hf_hub_download
4
+
5
  hf_token = os.getenv("HF_TOKEN")
 
 
6
 
7
  # Load model and tokenizer from Hugging Face hub using the provided model name
8
  model_name = "iimran/SAM-TheSummariserV2"