guychuk commited on
Commit
4cb7bfd
1 Parent(s): 486b768

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +5 -0
app.py CHANGED
@@ -1,6 +1,11 @@
1
  import gradio as gr
2
  import fasttext
3
  from huggingface_hub import hf_hub_download
 
 
 
 
 
4
 
5
  model_path = hf_hub_download(repo_id="LuminAISecurity/fasttext-english-nearest-neighbors-demo", filename="model.bin")
6
  model = fasttext.load_model(model_path)
 
1
  import gradio as gr
2
  import fasttext
3
  from huggingface_hub import hf_hub_download
4
+ from huggingface_hub import login
5
+ import os
6
+
7
+ login(token=os.environ["HF_TOKEN"])
8
+
9
 
10
  model_path = hf_hub_download(repo_id="LuminAISecurity/fasttext-english-nearest-neighbors-demo", filename="model.bin")
11
  model = fasttext.load_model(model_path)