changes
Browse files
app.py
CHANGED
|
@@ -882,15 +882,13 @@ with gr.Blocks(title="🎭 Consilium: Visual AI Consensus Platform", theme=gr.th
|
|
| 882 |
)
|
| 883 |
|
| 884 |
# Event handlers
|
| 885 |
-
def on_start_discussion(
|
| 886 |
# Start discussion immediately for both modes
|
| 887 |
-
enable_step = args[-2] # Second to last argument is enable_step_by_step
|
| 888 |
-
request = args[-1] # Last argument is request
|
| 889 |
|
| 890 |
if enable_step:
|
| 891 |
# Step-by-step mode: Start discussion in background thread
|
| 892 |
def run_discussion():
|
| 893 |
-
run_consensus_discussion_session(
|
| 894 |
|
| 895 |
discussion_thread = threading.Thread(target=run_discussion)
|
| 896 |
discussion_thread.daemon = True
|
|
@@ -910,7 +908,7 @@ with gr.Blocks(title="🎭 Consilium: Visual AI Consensus Platform", theme=gr.th
|
|
| 910 |
)
|
| 911 |
else:
|
| 912 |
# Normal mode - start immediately and hide step controls
|
| 913 |
-
result = run_consensus_discussion_session(
|
| 914 |
return result + (gr.update(visible=False), gr.update(visible=False))
|
| 915 |
|
| 916 |
# Function to toggle step controls visibility
|
|
|
|
| 882 |
)
|
| 883 |
|
| 884 |
# Event handlers
|
| 885 |
+
def on_start_discussion(question, rounds, protocol, roles, topology, moderator, enable_step, session_id_state, request: gr.Request = None):
|
| 886 |
# Start discussion immediately for both modes
|
|
|
|
|
|
|
| 887 |
|
| 888 |
if enable_step:
|
| 889 |
# Step-by-step mode: Start discussion in background thread
|
| 890 |
def run_discussion():
|
| 891 |
+
run_consensus_discussion_session(question, rounds, protocol, roles, topology, moderator, enable_step, session_id_state, request)
|
| 892 |
|
| 893 |
discussion_thread = threading.Thread(target=run_discussion)
|
| 894 |
discussion_thread.daemon = True
|
|
|
|
| 908 |
)
|
| 909 |
else:
|
| 910 |
# Normal mode - start immediately and hide step controls
|
| 911 |
+
result = run_consensus_discussion_session(question, rounds, protocol, roles, topology, moderator, enable_step, session_id_state, request)
|
| 912 |
return result + (gr.update(visible=False), gr.update(visible=False))
|
| 913 |
|
| 914 |
# Function to toggle step controls visibility
|