Omar Solano
commited on
Commit
Β·
d41011f
1
Parent(s):
8043b20
remove comments
Browse files- scripts/gradio-ui.py +1 -4
scripts/gradio-ui.py
CHANGED
@@ -138,9 +138,7 @@ def format_sources(completion) -> str:
|
|
138 |
documents_answer_template: str = (
|
139 |
"π Here are the sources I used to answer your question:\n\n{documents}\n\n{footnote}"
|
140 |
)
|
141 |
-
document_template: str = (
|
142 |
-
"[π {source}: {title}]({url}), relevance: {score:2.2f}" # Adjusted to include URL and format score as relevance
|
143 |
-
)
|
144 |
|
145 |
documents = "\n".join(
|
146 |
[
|
@@ -161,7 +159,6 @@ def format_sources(completion) -> str:
|
|
161 |
|
162 |
|
163 |
def add_sources(history, completion):
|
164 |
-
# if history[-1][1] == "No sources selected. Please select sources to search.":
|
165 |
if completion is None:
|
166 |
return history
|
167 |
|
|
|
138 |
documents_answer_template: str = (
|
139 |
"π Here are the sources I used to answer your question:\n\n{documents}\n\n{footnote}"
|
140 |
)
|
141 |
+
document_template: str = "[π {source}: {title}]({url}), relevance: {score:2.2f}"
|
|
|
|
|
142 |
|
143 |
documents = "\n".join(
|
144 |
[
|
|
|
159 |
|
160 |
|
161 |
def add_sources(history, completion):
|
|
|
162 |
if completion is None:
|
163 |
return history
|
164 |
|