Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -13,7 +13,7 @@ sentence_embed = pd.read_csv('Reference_file.csv')
|
|
| 13 |
|
| 14 |
# Define the backend function
|
| 15 |
def mapping_code(user_input):
|
| 16 |
-
emb1 = model.encode(user_input.lower())
|
| 17 |
similarities = []
|
| 18 |
for sentence in sentence_embed['embeds']:
|
| 19 |
similarity = util.cos_sim(sentence, emb1)
|
|
|
|
| 13 |
|
| 14 |
# Define the backend function
|
| 15 |
def mapping_code(user_input):
|
| 16 |
+
emb1 = model.encode(str(user_input).lower())
|
| 17 |
similarities = []
|
| 18 |
for sentence in sentence_embed['embeds']:
|
| 19 |
similarity = util.cos_sim(sentence, emb1)
|