Spaces:
Runtime error
Runtime error
Danil commited on
Commit ·
2515070
1
Parent(s): 63ca2f2
Fix
Browse files7 unmodified lines8910111213142 unmodified lines1718192021222318 unmodified lines42434445467 unmodified linesdef happytt(temperature,max_tokens,text,stop):stop = stop.split(';')response = openai.Completion.create(engine=engine,prompt=text,2 unmodified linestop_p=1,frequency_penalty=0,presence_penalty=0,stop=stop)return response.choices[0].text18 unmodified linesgr.inputs.Textbox(type='str',label="input prompt"),gr.inputs.Textbox(type='str',label='Tokens that indicate the end of the generation. (use ";" for several)')],"text", title = title, description = description )iface.launch(debug=True)7 unmodified lines89101112132 unmodified lines161718192021222318 unmodified lines42434445467 unmodified linesdef happytt(temperature,max_tokens,text,stop):response = openai.Completion.create(engine=engine,prompt=text,2 unmodified linestop_p=1,frequency_penalty=0,presence_penalty=0,stop=[stop]))return response.choices[0].text18 unmodified linesgr.inputs.Textbox(type='str',label="input prompt"),gr.inputs.Textbox(type='str',label='token that indicate the end of the generation')],"text", title = title, description = description )iface.launch(debug=True)
app.py+3-3