Joaoffg commited on
Commit
2074c5b
·
1 Parent(s): 41102b8

Update space

Browse files
Files changed (1) hide show
  1. app.py +24 -16
app.py CHANGED
@@ -113,22 +113,30 @@ def evaluate(instruction):
113
  return(f' {prompter.get_response(output)}')
114
 
115
 
116
- gr.Interface(
 
117
  fn=evaluate,
118
  inputs=[
119
- gr.components.Textbox(
120
- lines=2,
121
- label="Instruction",
122
- placeholder="Explain economic growth.",
123
- ),
124
- ],
125
- outputs=[
126
- gr.components.Textbox(
127
- lines=5,
128
- label="Output",
129
- )
130
- ],
131
  title="🌲 ELM - Erasmian Language Model",
132
- description="ELM is a 900M parameter language model finetuned to follow instruction. It is trained on Erasmus University academic outputs and the [Stanford Alpaca](https://github.com/tatsu-lab/stanford_alpaca) dataset. For more information, please visit [the GitHub repository](https://github.com/Joaoffg/ELM).", # noqa: E501
133
- ).queue().launch(server_name="0.0.0.0", share=True)
134
- # Old testing code follows.
 
 
 
 
 
 
 
 
113
  return(f' {prompter.get_response(output)}')
114
 
115
 
116
+ # Define the Gradio interface
117
+ interface = gr.Interface(
118
  fn=evaluate,
119
  inputs=[
120
+ gr.components.Textbox(
121
+ lines=2,
122
+ label="Instruction",
123
+ placeholder="Explain economic growth.",
124
+ ),
125
+ ],
126
+ outputs=[
127
+ gr.components.Textbox(
128
+ lines=5,
129
+ label="Output",
130
+ )
131
+ ],
132
  title="🌲 ELM - Erasmian Language Model",
133
+ description=(
134
+ "ELM is a 900M parameter language model finetuned to follow instruction. "
135
+ "It is trained on Erasmus University academic outputs and the "
136
+ "[Stanford Alpaca](https://github.com/tatsu-lab/stanford_alpaca) dataset. "
137
+ "For more information, please visit [the GitHub repository](https://github.com/Joaoffg/ELM)."
138
+ ),
139
+ )
140
+
141
+ # Launch the Gradio interface
142
+ interface.queue().launch()