Sagi Polaczek commited on
Commit
3766d91
·
1 Parent(s): 08a8622

basic skelaton for solubility task

Browse files
Files changed (1) hide show
  1. app.py +17 -4
app.py CHANGED
@@ -1,7 +1,20 @@
1
  import gradio as gr
 
2
 
3
- def greet(name):
4
- return "Hello " + name + "!!"
5
 
6
- demo = gr.Interface(fn=greet, inputs="text", outputs="text")
7
- demo.launch()
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
  import gradio as gr
2
+ import random
3
 
 
 
4
 
5
+
6
+ pipeline = lambda x: random.randint(0, 1)
7
+
8
+ def predict(protein_sequence: str) -> dict[str, float]:
9
+ predictions = dict(soluble=0.42, insoluble=0.58)
10
+ return predictions
11
+
12
+ gradio_app = gr.Interface(
13
+ predict,
14
+ inputs="text",
15
+ outputs="label",
16
+ title="Soluble or insoluble, that is the question meme",
17
+ )
18
+
19
+ if __name__ == "__main__":
20
+ gradio_app.launch()