yourusername commited on
Commit
c27acdb
0 Parent(s):

:tada: init

Browse files
.github/workflows/check_size.yaml ADDED
@@ -0,0 +1,17 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ name: Check file size
2
+
3
+ on:
4
+ pull_request:
5
+ branches: [main]
6
+
7
+ # to run this workflow manually from the Actions tab
8
+ workflow_dispatch:
9
+
10
+ jobs:
11
+ sync-to-hub:
12
+ runs-on: ubuntu-latest
13
+ steps:
14
+ - name: Check large files
15
+ uses: ActionsDesk/lfs-warning@v2.0
16
+ with:
17
+ filesizelimit: 10485760 # = 10MB, so we can sync to HF spaces
.github/workflows/sync_to_hub.yaml ADDED
@@ -0,0 +1,20 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ name: Sync to Hugging Face hub
2
+
3
+ on:
4
+ push:
5
+ branches: [main]
6
+
7
+ # to run this workflow manually from the Actions tab
8
+ workflow_dispatch:
9
+
10
+ jobs:
11
+ sync-to-hub:
12
+ runs-on: ubuntu-latest
13
+ steps:
14
+ - uses: actions/checkout@v2
15
+ with:
16
+ fetch-depth: 0
17
+ - name: Push to hub
18
+ env:
19
+ HF_TOKEN: ${{ secrets.HF_TOKEN }}
20
+ run: git push https://nateraw:$HF_TOKEN@huggingface.co/spaces/nateraw/spaces-template-gradio main --force
README.md ADDED
@@ -0,0 +1,19 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ title: Spaces Template Gradio
3
+ emoji: 🤗
4
+ colorFrom: blue
5
+ colorTo: red
6
+ sdk: gradio
7
+ app_file: app.py
8
+ pinned: false
9
+ ---
10
+
11
+ # Spaces Template Gradio
12
+
13
+ [![Generic badge](https://img.shields.io/badge/🤗-Open%20In%20Spaces-blue.svg)](https://huggingface.co/spaces/nateraw/spaces-template-gradio)
14
+
15
+ A template app for Hugging Face Spaces
16
+
17
+ ---
18
+
19
+ Autogenerated using [this template](https://github.com/nateraw/spaces-template)
app.py ADDED
@@ -0,0 +1,18 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import gradio as gr
2
+
3
+
4
+ def main(text):
5
+ # A gradio function that lowercases text and returns it
6
+ return text.lower()
7
+
8
+
9
+ # A simple gradio app for text
10
+ app = gr.Interface(
11
+ main,
12
+ inputs="text",
13
+ outputs="text",
14
+ title="Spaces Template Gradio",
15
+ description="A template app for Hugging Face Spaces",
16
+ )
17
+ app.launch(debug=True)
18
+
packages.txt ADDED
File without changes
requirements.txt ADDED
@@ -0,0 +1,2 @@
 
 
1
+ gradio
2
+