Spaces:
Runtime error
Runtime error
Commit
·
bff03f4
1
Parent(s):
74151e9
initial add app.py.
Browse files
app.py
ADDED
@@ -0,0 +1,13 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
import gradio as gr
|
2 |
+
|
3 |
+
description = "Code generation with GPT-2"
|
4 |
+
title = "Generate your Python code"
|
5 |
+
examples = [["# import random forest regressor from scikit-learn from sklearn.ensemble import RandomForestRegressor.# fit random forest model with 300 estimators on X, y:"]]
|
6 |
+
|
7 |
+
interface = gr.Interface.load("huggingface/michaelhhl/code-gen-accelerate",
|
8 |
+
description=description,
|
9 |
+
title = title,
|
10 |
+
examples=examples
|
11 |
+
)
|
12 |
+
|
13 |
+
interface.launch()
|