frankai98 commited on
Commit
a4c7cd3
·
verified ·
1 Parent(s): 1d9c203

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -56,10 +56,10 @@ st.header("Review Scorer & Report Generator")
56
  st.write("This model will score your reviews in your CSV file and generate a report based on those results.")
57
 
58
  # Load models with caching to avoid reloading on every run
59
- # @st.cache_resource
60
  def load_models():
61
  try:
62
- score_pipe = pipeline("text-classification", model="Alibaba-NLP/gte-multilingual-reranker-base", trust_remote_code=True, device=0)
63
  except Exception as e:
64
  st.error(f"Error loading score model: {e}")
65
  score_pipe = None
 
56
  st.write("This model will score your reviews in your CSV file and generate a report based on those results.")
57
 
58
  # Load models with caching to avoid reloading on every run
59
+ @st.cache_resource
60
  def load_models():
61
  try:
62
+ score_pipe = pipeline("text-classification", model="meta-llama/Prompt-Guard-86M", device=0)
63
  except Exception as e:
64
  st.error(f"Error loading score model: {e}")
65
  score_pipe = None