vlff李飞飞
update md
2319518
raw
history blame
288 Bytes
import json
import urllib.parse
import json5
def image_gen(plugin_args):
prompt = json5.loads(plugin_args)['prompt']
prompt = urllib.parse.quote(prompt)
return json.dumps(
{'image_url': f'https://image.pollinations.ai/prompt/{prompt}'},
ensure_ascii=False)