Update app.py
Browse files
app.py
CHANGED
|
@@ -162,7 +162,7 @@ def convert_openai_to_reka(messages: list[dict]) -> list[dict]:
|
|
| 162 |
|
| 163 |
def format_part(current_text: str, previous_text: str, finish_reason: str):
|
| 164 |
logger.debug(f'форматирование сообщения: {current_text}')
|
| 165 |
-
return f"
|
| 166 |
'id': 'chatcmpl-0',
|
| 167 |
'object': 'chat.completion.chunk',
|
| 168 |
'created': int(datetime.now().timestamp()),
|
|
|
|
| 162 |
|
| 163 |
def format_part(current_text: str, previous_text: str, finish_reason: str):
|
| 164 |
logger.debug(f'форматирование сообщения: {current_text}')
|
| 165 |
+
return f"{dumps({
|
| 166 |
'id': 'chatcmpl-0',
|
| 167 |
'object': 'chat.completion.chunk',
|
| 168 |
'created': int(datetime.now().timestamp()),
|