Azizahalq commited on
Commit
1c0675f
·
verified ·
1 Parent(s): 64f1fa4

Create app.py

Browse files
Files changed (1) hide show
  1. app.py +19 -0
app.py ADDED
@@ -0,0 +1,19 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Tiny runner so Spaces can start; immediately run and exit.
2
+ import gradio as gr
3
+ import threading, time, sys
4
+ from builder import run
5
+
6
+ def _bg():
7
+ try:
8
+ run()
9
+ except Exception as e:
10
+ print("Builder failed:", e, flush=True)
11
+
12
+ t = threading.Thread(target=_bg, daemon=True)
13
+ t.start()
14
+
15
+ def status():
16
+ return "Builder running... Check logs. It will stop when finished."
17
+
18
+ demo = gr.Interface(fn=status, inputs=None, outputs="text", title="MaterialMind – Builder")
19
+ demo.queue().launch()