Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -620,13 +620,16 @@ def on_regenerate(
|
|
620 |
print("Regen Final Prompt 2:", final_prompt_2)
|
621 |
|
622 |
sms_1 = generate_sms_with_timer(final_prompt_1, product_name, key_message)
|
623 |
-
sms_2 = generate_sms_with_timer(final_prompt_2, product_name, key_message)
|
624 |
|
625 |
# Проверяем заново:
|
626 |
cut_sms_1 = cut_message(sms_1)
|
627 |
checks_1 = perform_checks(cut_sms_1, key_message)
|
628 |
checks_formatted_1 = format_checks(checks_1)
|
629 |
|
|
|
|
|
|
|
|
|
630 |
cut_sms_2 = cut_message(sms_2)
|
631 |
checks_2 = perform_checks(cut_sms_2, key_message)
|
632 |
checks_formatted_2 = format_checks(checks_2)
|
@@ -642,7 +645,7 @@ def on_regenerate(
|
|
642 |
chosen_sms="none" # <-- признак, что ни одно SMS не выбрано
|
643 |
)
|
644 |
|
645 |
-
|
646 |
|
647 |
def on_load_previous():
|
648 |
loaded_data = load_previous_user_request_from_github()
|
|
|
620 |
print("Regen Final Prompt 2:", final_prompt_2)
|
621 |
|
622 |
sms_1 = generate_sms_with_timer(final_prompt_1, product_name, key_message)
|
|
|
623 |
|
624 |
# Проверяем заново:
|
625 |
cut_sms_1 = cut_message(sms_1)
|
626 |
checks_1 = perform_checks(cut_sms_1, key_message)
|
627 |
checks_formatted_1 = format_checks(checks_1)
|
628 |
|
629 |
+
yield sms_1, "", checks_formatted_1, ""
|
630 |
+
|
631 |
+
sms_2 = generate_sms_with_timer(final_prompt_2, product_name, key_message)
|
632 |
+
|
633 |
cut_sms_2 = cut_message(sms_2)
|
634 |
checks_2 = perform_checks(cut_sms_2, key_message)
|
635 |
checks_formatted_2 = format_checks(checks_2)
|
|
|
645 |
chosen_sms="none" # <-- признак, что ни одно SMS не выбрано
|
646 |
)
|
647 |
|
648 |
+
yield sms_1, sms_2, checks_formatted_1, checks_formatted_2
|
649 |
|
650 |
def on_load_previous():
|
651 |
loaded_data = load_previous_user_request_from_github()
|