Add Feature provider in demo

Support default provider in DDG
Read api_key from config file
This commit is contained in:
hlohaus 2025-01-27 23:33:21 +01:00
parent 17bd3b3ac6
commit 16e5d9ee86
7 changed files with 48 additions and 12 deletions

View file

@ -239,7 +239,7 @@ class Blackbox(AsyncGeneratorProvider, ProviderModelMixin):
yield ImageResponse(images=[image_url], alt=prompt)
return
if conversation is None:
if conversation is None or not hasattr(conversation, "chat_id"):
conversation = Conversation(model)
conversation.validated_value = await cls.fetch_validated()
conversation.chat_id = cls.generate_chat_id()