Update pages/3_Earnings_Semantic_Search_π_.py
Browse files
pages/3_Earnings_Semantic_Search_π_.py
CHANGED
@@ -35,7 +35,7 @@ if any(st.session_state["sen_df"]) or st.session_state["earnings_passages"]:
|
|
35 |
|
36 |
##### Re-Ranking #####
|
37 |
# Now, score all retrieved passages with the cross_encoder
|
38 |
-
cross_inp = [[
|
39 |
cross_scores = cross_encoder.predict(cross_inp)
|
40 |
|
41 |
# Sort results by the cross-encoder scores
|
|
|
35 |
|
36 |
##### Re-Ranking #####
|
37 |
# Now, score all retrieved passages with the cross_encoder
|
38 |
+
cross_inp = [[search_input, passages[hit['corpus_id']]] for hit in hits]
|
39 |
cross_scores = cross_encoder.predict(cross_inp)
|
40 |
|
41 |
# Sort results by the cross-encoder scores
|