Add some arguments to chat completion api, update discord links

This commit is contained in:
Heiner Lohaus
2024-11-27 14:44:24 +01:00
parent abd94c1174
commit 651df0cf82
9 changed files with 15 additions and 14 deletions

View File

@@ -108,11 +108,9 @@ class Api:
}
def _create_response_stream(self, kwargs: dict, conversation_id: str, provider: str, download_images: bool = True) -> Iterator:
debug.logs = []
print_callback = debug.log_handler
def log_handler(text: str):
debug.logs.append(text)
print_callback(text)
print(text)
debug.log_handler = log_handler
try:
result = ChatCompletion.create(**kwargs)