debisoft commited on
Commit
60e455b
·
1 Parent(s): d2bfd34
Files changed (1) hide show
  1. app.py +4 -2
app.py CHANGED
@@ -126,8 +126,10 @@ Below is an instruction that describes a task, paired with an input that provide
126
  ### Response:\\n\
127
  """
128
 
129
- response = extract_json(get_completion(n_shot_learning + prompt_template), 3)
130
- return json.dumps(response)
 
 
131
 
132
  #iface = gr.Interface(fn=greet, inputs="text", outputs="text")
133
  #iface.launch()
 
126
  ### Response:\\n\
127
  """
128
 
129
+ response = get_completion(n_shot_learning + prompt_template)
130
+ gen_text = response["predictions"][0]["generated_text"]
131
+ return extract_json(gen_text, 3)
132
+ #return json.dumps(response)
133
 
134
  #iface = gr.Interface(fn=greet, inputs="text", outputs="text")
135
  #iface.launch()