This commit is contained in:
Yasir Aris M 2024-08-09 10:30:25 +07:00 committed by GitHub
parent 62c4d400e3
commit 973db569fe
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -92,7 +92,9 @@ async def gpt4_chatbot(_, ctx: Message, strings):
]
}
response = await fetch.post("https://duckduckgo.com/duckchat/v1/chat", headers=headers, json=data)
self.log.info(response.text)
messages = []
self.log.info(messages)
for line in response.text.splitlines():
if line.startswith('data:'):
try: