summaryrefslogtreecommitdiffstats
path: root/g4f
diff options
context:
space:
mode:
authorkqlio67 <kqlio67@users.noreply.github.com>2024-10-17 14:47:36 +0200
committerkqlio67 <kqlio67@users.noreply.github.com>2024-10-17 14:47:36 +0200
commitd9892cebfd6ccfbb0f0e231fa8302408bea7edca (patch)
treee372492a190abfa1254e6b05afea8d154aa48225 /g4f
parentAdded new provider (g4f/Provider/Ai4Chat.py) (diff)
downloadgpt4free-d9892cebfd6ccfbb0f0e231fa8302408bea7edca.tar
gpt4free-d9892cebfd6ccfbb0f0e231fa8302408bea7edca.tar.gz
gpt4free-d9892cebfd6ccfbb0f0e231fa8302408bea7edca.tar.bz2
gpt4free-d9892cebfd6ccfbb0f0e231fa8302408bea7edca.tar.lz
gpt4free-d9892cebfd6ccfbb0f0e231fa8302408bea7edca.tar.xz
gpt4free-d9892cebfd6ccfbb0f0e231fa8302408bea7edca.tar.zst
gpt4free-d9892cebfd6ccfbb0f0e231fa8302408bea7edca.zip
Diffstat (limited to 'g4f')
-rw-r--r--g4f/Provider/Blackbox.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/g4f/Provider/Blackbox.py b/g4f/Provider/Blackbox.py
index 6c45a628..317df1d4 100644
--- a/g4f/Provider/Blackbox.py
+++ b/g4f/Provider/Blackbox.py
@@ -181,7 +181,7 @@ class Blackbox(AsyncGeneratorProvider, ProviderModelMixin):
model (str): Model to use for generating responses.
messages (Messages): Message history.
proxy (Optional[str]): Proxy URL, if needed.
- web_search_mode (bool): Enables or disables web search mode.
+ websearch (bool): Enables or disables web search mode.
**kwargs: Additional keyword arguments.
Yields:
@@ -298,7 +298,7 @@ class Blackbox(AsyncGeneratorProvider, ProviderModelMixin):
else:
yield cleaned_response
else:
- if web_search_mode:
+ if websearch:
match = re.search(r'\$~~~\$(.*?)\$~~~\$', cleaned_response, re.DOTALL)
if match:
source_part = match.group(1).strip()