Cachoups commited on
Commit
aecb436
·
verified ·
1 Parent(s): dba8c4a

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -1
app.py CHANGED
@@ -13,6 +13,7 @@ For more information on `huggingface_hub` Inference API support, please check th
13
  """
14
  client = InferenceClient("HuggingFaceH4/zephyr-7b-beta")
15
  df1 = pd.read_csv("./data/champions_data_lol.csv")
 
16
  # Pre-processing
17
  def preprocess_for_bm25(text):
18
  # Replace "..." with a unique placeholder
@@ -28,7 +29,7 @@ def preprocess_for_bm25(text):
28
  text = re.sub(r'\s+', ' ', text).strip()
29
  text = text.lower()
30
  return text
31
- print(df1.isnull().count())
32
  """Pre-processing"""
33
  # Convert DataFrame to documents
34
  documents = []
 
13
  """
14
  client = InferenceClient("HuggingFaceH4/zephyr-7b-beta")
15
  df1 = pd.read_csv("./data/champions_data_lol.csv")
16
+ df1['Story'] = df1['Story'].astype(str)
17
  # Pre-processing
18
  def preprocess_for_bm25(text):
19
  # Replace "..." with a unique placeholder
 
29
  text = re.sub(r'\s+', ' ', text).strip()
30
  text = text.lower()
31
  return text
32
+
33
  """Pre-processing"""
34
  # Convert DataFrame to documents
35
  documents = []