Chris4K commited on
Commit
299669a
1 Parent(s): 3a5fb85

Update text_generator.py

Browse files
Files changed (1) hide show
  1. text_generator.py +3 -3
text_generator.py CHANGED
@@ -26,9 +26,9 @@ class TextGenerationTool(Tool):
26
  }
27
 
28
  #def query(payload):
29
- response = requests.post(API_URL, headers=headers, json=payload)
30
- print(response)
31
- return response.json()
32
 
33
 
34
 
 
26
  }
27
 
28
  #def query(payload):
29
+ generated_text = requests.post(API_URL, headers=headers, json=payload).json()
30
+ print(generated_text)
31
+ return generated_text["generated_text"]
32
 
33
 
34