neuralworm commited on
Commit
09d65a8
·
1 Parent(s): 16e19a3

add control experiments

Browse files
Files changed (1) hide show
  1. app.py +26 -1
app.py CHANGED
@@ -69,7 +69,32 @@ with gr.Blocks(theme=theme, title="Cognitive Seismograph 2.3") as demo:
69
 
70
  with gr.Tabs():
71
  with gr.TabItem("🔬 Manual Single Run"):
72
- # (UI bleibt unverändert)
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
73
 
74
  with gr.TabItem("🚀 Automated Suite"):
75
  gr.Markdown("Run a predefined, curated suite of experiments and visualize the results comparatively.")
 
69
 
70
  with gr.Tabs():
71
  with gr.TabItem("🔬 Manual Single Run"):
72
+ gr.Markdown("Run a single experiment with manual parameters to explore specific hypotheses.")
73
+ with gr.Row(variant='panel'):
74
+ with gr.Column(scale=1):
75
+ gr.Markdown("### 1. General Parameters")
76
+ manual_model_id = gr.Textbox(value="google/gemma-3-1b-it", label="Model ID")
77
+ manual_prompt_type = gr.Radio(choices=list(RESONANCE_PROMPTS.keys()), value="resonance_prompt", label="Prompt Type")
78
+ manual_seed = gr.Slider(1, 1000, 42, step=1, label="Seed")
79
+ manual_num_steps = gr.Slider(50, 1000, 300, step=10, label="Number of Internal Steps")
80
+
81
+ gr.Markdown("### 2. Modulation Parameters")
82
+ manual_concept = gr.Textbox(label="Concept to Inject", placeholder="e.g., 'calmness'")
83
+ manual_strength = gr.Slider(0.0, 5.0, 1.5, step=0.1, label="Injection Strength")
84
+ manual_run_btn = gr.Button("Run Single Analysis", variant="primary")
85
+
86
+ with gr.Column(scale=2):
87
+ gr.Markdown("### Single Run Results")
88
+ manual_verdict = gr.Markdown("Analysis results will appear here.")
89
+ manual_plot = gr.LinePlot(x="Internal Step", y="State Change (Delta)", title="Internal State Dynamics", show_label=True, height=400)
90
+ with gr.Accordion("Raw JSON Output", open=False):
91
+ manual_raw_json = gr.JSON()
92
+
93
+ manual_run_btn.click(
94
+ fn=run_single_analysis_display,
95
+ inputs=[manual_model_id, manual_prompt_type, manual_seed, manual_num_steps, manual_concept, manual_strength],
96
+ outputs=[manual_verdict, manual_plot, manual_raw_json]
97
+ )
98
 
99
  with gr.TabItem("🚀 Automated Suite"):
100
  gr.Markdown("Run a predefined, curated suite of experiments and visualize the results comparatively.")