mariagrandury commited on
Commit
dfe62aa
1 Parent(s): be89af9

First version

Browse files
Files changed (2) hide show
  1. README.md +4 -32
  2. app.py +20 -0
README.md CHANGED
@@ -1,37 +1,9 @@
1
  ---
2
- title: Bertin Sqac
3
- emoji: 😻
4
- colorFrom: red
5
- colorTo: red
6
  sdk: gradio
7
  app_file: app.py
8
  pinned: false
9
  ---
10
-
11
- # Configuration
12
-
13
- `title`: _string_
14
- Display title for the Space
15
-
16
- `emoji`: _string_
17
- Space emoji (emoji-only character allowed)
18
-
19
- `colorFrom`: _string_
20
- Color for Thumbnail gradient (red, yellow, green, blue, indigo, purple, pink, gray)
21
-
22
- `colorTo`: _string_
23
- Color for Thumbnail gradient (red, yellow, green, blue, indigo, purple, pink, gray)
24
-
25
- `sdk`: _string_
26
- Can be either `gradio` or `streamlit`
27
-
28
- `sdk_version` : _string_
29
- Only applicable for `streamlit` SDK.
30
- See [doc](https://hf.co/docs/hub/spaces) for more info on supported versions.
31
-
32
- `app_file`: _string_
33
- Path to your main application file (which contains either `gradio` or `streamlit` Python code).
34
- Path is relative to the root of the repository.
35
-
36
- `pinned`: _boolean_
37
- Whether the Space stays on top of your list.
 
1
  ---
2
+ title: BERTIN SQAC
3
+ emoji:
4
+ colorFrom: yellow
5
+ colorTo: orange
6
  sdk: gradio
7
  app_file: app.py
8
  pinned: false
9
  ---
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
app.py ADDED
@@ -0,0 +1,20 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import gradio as gr
2
+
3
+ title = "BERTIN SQAC"
4
+ description = "BERTIN large fine-tuned con el corpus SQAC (Spanish Question Answering Corpus)"
5
+ article = "<p style='text-align: center'><a href='https://huggingface.co/nlp-en-es/bertin-large-finetuned-sqac'>BERTIN fine-tuned con el corpus SQAC (Spanish Question Answering Corpus)</a> | <a href='https://nlp-en-es.org'>NLP en ES 🤗</a></p>"
6
+ examples = [
7
+ ["Mi nombre es María y vivo en Berlín.", "¿Dónde vivo?"],
8
+ ["La capital de Paraguay es Asunción.", "¿Cuál es la capital de Paraguay?"]
9
+ ]
10
+
11
+ gr.Interface.load(
12
+ name="huggingface/nlp-en-es/bertin-large-finetuned-sqac",
13
+ inputs=[gr.inputs.Textbox(label="contexto"), gr.inputs.Textbox(label="pregunta")],
14
+ outputs=gr.outputs.Textbox(label="respuesta"),
15
+ title=title,
16
+ description=description,
17
+ article=article,
18
+ examples=examples,
19
+ enable_queue=True
20
+ ).launch()