Rahmat82 commited on
Commit
8ed4a0b
·
verified ·
1 Parent(s): 0312423

refactoring

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -10,7 +10,7 @@ SECRET_KEY = os.environ.get("summarizer")
10
  # asynchronous function
11
  async def summarize(text, retries=5):
12
  if len(text) < 264:
13
- return "⛔ You input is too short! Please input a longer text for summarization."
14
  headers = {"Authorization": f"Bearer {SECRET_KEY}"}
15
  data = {
16
  "inputs": text,
 
10
  # asynchronous function
11
  async def summarize(text, retries=5):
12
  if len(text) < 264:
13
+ return "⛔ You text is too short! Please input a longer text for summarization."
14
  headers = {"Authorization": f"Bearer {SECRET_KEY}"}
15
  data = {
16
  "inputs": text,