store stack and some other properties for generations on prod
This commit is contained in:
parent
df5f954ee2
commit
ae08466405
@ -363,6 +363,9 @@ async def stream_code(websocket: WebSocket):
|
||||
completion,
|
||||
payment_method=payment_method,
|
||||
llm_version=exact_llm_version,
|
||||
stack=valid_stack,
|
||||
is_imported_from_code=bool(params.get("isImportedFromCode", False)),
|
||||
includes_result_image=bool(params.get("resultImage", False)),
|
||||
auth_token=params["authToken"],
|
||||
)
|
||||
except Exception as e:
|
||||
|
||||
@ -6,6 +6,7 @@ import json
|
||||
|
||||
from config import BACKEND_SAAS_URL, IS_PROD
|
||||
from llm import Llm
|
||||
from prompts.types import Stack
|
||||
|
||||
|
||||
class PaymentMethod(Enum):
|
||||
@ -21,6 +22,9 @@ async def send_to_saas_backend(
|
||||
completion: str,
|
||||
payment_method: PaymentMethod,
|
||||
llm_version: Llm,
|
||||
stack: Stack,
|
||||
is_imported_from_code: bool,
|
||||
includes_result_image: bool,
|
||||
auth_token: str | None = None,
|
||||
):
|
||||
if IS_PROD:
|
||||
@ -33,6 +37,9 @@ async def send_to_saas_backend(
|
||||
"completion": completion,
|
||||
"payment_method": payment_method.value,
|
||||
"llm_version": llm_version.value,
|
||||
"stack": stack,
|
||||
"is_imported_from_code": is_imported_from_code,
|
||||
"includes_result_image": includes_result_image,
|
||||
}
|
||||
)
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user