Shreyas094
commited on
Commit
•
c17888a
1
Parent(s):
6057fe5
Update app.py
Browse files
app.py
CHANGED
@@ -41,8 +41,8 @@ similarity_model = SentenceTransformer('all-MiniLM-L6-v2')
|
|
41 |
|
42 |
# Set up a session with retry mechanism
|
43 |
def requests_retry_session(
|
44 |
-
retries=
|
45 |
-
backoff_factor=0.
|
46 |
status_forcelist=(500, 502, 504),
|
47 |
session=None,
|
48 |
):
|
@@ -476,7 +476,7 @@ iface = gr.ChatInterface(
|
|
476 |
additional_inputs=[
|
477 |
gr.Slider(5, 20, value=10, step=1, label="Number of initial results"),
|
478 |
gr.Dropdown(["bs4", "trafilatura"], value="trafilatura", label="Scraping Method"),
|
479 |
-
gr.Slider(500, 10000, value=
|
480 |
gr.Dropdown(["", "day", "week", "month", "year"], value="year", label="Time Range"),
|
481 |
gr.Dropdown(["all", "en", "fr", "de", "es", "it", "nl", "pt", "pl", "ru", "zh"], value="en", label="Language"),
|
482 |
gr.Dropdown(["", "general", "news", "images", "videos", "music", "files", "it", "science", "social media"], value="", label="Category"),
|
|
|
41 |
|
42 |
# Set up a session with retry mechanism
|
43 |
def requests_retry_session(
|
44 |
+
retries=0,
|
45 |
+
backoff_factor=0.1,
|
46 |
status_forcelist=(500, 502, 504),
|
47 |
session=None,
|
48 |
):
|
|
|
476 |
additional_inputs=[
|
477 |
gr.Slider(5, 20, value=10, step=1, label="Number of initial results"),
|
478 |
gr.Dropdown(["bs4", "trafilatura"], value="trafilatura", label="Scraping Method"),
|
479 |
+
gr.Slider(500, 10000, value=1500, step=100, label="Max characters to retrieve"),
|
480 |
gr.Dropdown(["", "day", "week", "month", "year"], value="year", label="Time Range"),
|
481 |
gr.Dropdown(["all", "en", "fr", "de", "es", "it", "nl", "pt", "pl", "ru", "zh"], value="en", label="Language"),
|
482 |
gr.Dropdown(["", "general", "news", "images", "videos", "music", "files", "it", "science", "social media"], value="", label="Category"),
|