qingxu99 commited on
Commit
d52c0c4
1 Parent(s): 986653b

修改输出格式

Browse files
Files changed (1) hide show
  1. crazy_functions/图片生成.py +4 -2
crazy_functions/图片生成.py CHANGED
@@ -58,7 +58,9 @@ def 图片生成(prompt, llm_kwargs, plugin_kwargs, chatbot, history, system_pro
58
  resolution = plugin_kwargs.get("advanced_arg", '256x256')
59
  image_url, image_path = gen_image(llm_kwargs, prompt, resolution)
60
  chatbot.append([prompt,
61
- f'`{image_url}`\n\n'+
62
- f'<div align="center"><img src="file={image_path}"></div>'
 
 
63
  ])
64
  yield from update_ui(chatbot=chatbot, history=history) # 刷新界面 # 界面更新
 
58
  resolution = plugin_kwargs.get("advanced_arg", '256x256')
59
  image_url, image_path = gen_image(llm_kwargs, prompt, resolution)
60
  chatbot.append([prompt,
61
+ f'图像中转网址: <br/>`{image_url}`<br/>'+
62
+ f'中转网址预览: <br/><div align="center"><img src="{image_url}"></div>'
63
+ f'本地文件地址: <br/>`{image_path}`<br/>'+
64
+ f'本地文件预览: <br/><div align="center"><img src="file={image_path}"></div>'
65
  ])
66
  yield from update_ui(chatbot=chatbot, history=history) # 刷新界面 # 界面更新