joaomorossini commited on
Commit
4be6783
·
1 Parent(s): 4782bb5

Update app.py

Browse files

Format outpout

Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -73,9 +73,9 @@ def captioner(image):
73
  captions = []
74
  for endpoint, result in results.items():
75
  if "error" not in result:
76
- caption = (f"### [{endpoint}]({hf_base_url+endpoint}): \n {result[0]['generated_text']} \n {'-' * 50} \n ")
77
  else:
78
- caption = f"### [{endpoint}]({hf_base_url+endpoint}): \n Error - {result['error']} \n {'-' * 50} \n "
79
  captions.append(caption)
80
  return "".join(captions) # Join all captions into a single string
81
 
 
73
  captions = []
74
  for endpoint, result in results.items():
75
  if "error" not in result:
76
+ caption = (f"**[{endpoint}]({hf_base_url+endpoint})**: \n {result[0]['generated_text']} \n {'-' * 50} \n ")
77
  else:
78
+ caption = f"**[{endpoint}]({hf_base_url+endpoint})**: \n Error - {result['error']} \n {'-' * 50} \n "
79
  captions.append(caption)
80
  return "".join(captions) # Join all captions into a single string
81