Spaces:
Runtime error
Runtime error
chore: customize
Browse files
README.md
CHANGED
@@ -1,13 +1,11 @@
|
|
1 |
---
|
2 |
-
title:
|
3 |
-
emoji:
|
4 |
-
colorFrom:
|
5 |
-
colorTo:
|
6 |
sdk: gradio
|
7 |
sdk_version: 3.16.2
|
8 |
app_file: app.py
|
9 |
-
pinned:
|
10 |
-
license:
|
11 |
---
|
12 |
-
|
13 |
-
Check out the configuration reference at <https://huggingface.co/docs/hub/spaces-config-reference>
|
|
|
1 |
---
|
2 |
+
title: prompt-generator
|
3 |
+
emoji: π€
|
4 |
+
colorFrom: yellow
|
5 |
+
colorTo: blue
|
6 |
sdk: gradio
|
7 |
sdk_version: 3.16.2
|
8 |
app_file: app.py
|
9 |
+
pinned: true
|
10 |
+
license: mit
|
11 |
---
|
|
|
|
app.py
CHANGED
@@ -11,8 +11,8 @@ def generate(prompt):
|
|
11 |
output = tokenizer.batch_decode(generated_ids, skip_special_tokens=True)
|
12 |
return output[0]
|
13 |
|
14 |
-
input_component = gr.Textbox(label = "Input a persona, e.g.
|
15 |
output_component = gr.Textbox(label = "Prompt")
|
16 |
-
examples = [["
|
17 |
-
description = "This app generates ChatGPT prompts, it's based on a BART model trained on [this dataset](https://huggingface.co/datasets/
|
18 |
-
gr.Interface(generate, inputs = input_component, outputs=output_component, examples=examples, title = "
|
|
|
11 |
output = tokenizer.batch_decode(generated_ids, skip_special_tokens=True)
|
12 |
return output[0]
|
13 |
|
14 |
+
input_component = gr.Textbox(label = "Input a persona, e.g. web developer", value = "prompt generator")
|
15 |
output_component = gr.Textbox(label = "Prompt")
|
16 |
+
examples = [["developer"], ["prompt generator"]]
|
17 |
+
description = "This app generates ChatGPT prompts, it's based on a BART model trained on [this dataset](https://huggingface.co/datasets/njfamirm/prompt). Simply enter a persona that you want the prompt to be generated based on."
|
18 |
+
gr.Interface(generate, inputs = input_component, outputs=output_component, examples=examples, title = "Prompt Generator", description=description).launch()
|