Spaces:
Running
on
Zero
Running
on
Zero
increase max_chars_per_result to 600
Browse files
app.py
CHANGED
@@ -29,7 +29,7 @@ ul.think-list li { margin-bottom: 0.5em; }
|
|
29 |
REQUIRED_SPACE_BYTES = 5 * 1024 ** 3 # 5 GB
|
30 |
|
31 |
# ---- Function to retrieve web search context ----
|
32 |
-
def retrieve_context(query, max_results=6, max_chars_per_result=
|
33 |
try:
|
34 |
with DDGS() as ddgs:
|
35 |
results = list(islice(ddgs.text(query, region="wt-wt", safesearch="off", timelimit="y"), max_results))
|
|
|
29 |
REQUIRED_SPACE_BYTES = 5 * 1024 ** 3 # 5 GB
|
30 |
|
31 |
# ---- Function to retrieve web search context ----
|
32 |
+
def retrieve_context(query, max_results=6, max_chars_per_result=600):
|
33 |
try:
|
34 |
with DDGS() as ddgs:
|
35 |
results = list(islice(ddgs.text(query, region="wt-wt", safesearch="off", timelimit="y"), max_results))
|