feat: 新增 gen-image 生图技能
通过大模型中转站调用 OpenAI 图片接口生图(文生图/图生图/局部重绘/透明背景),零第三方依赖。 含可安装 zip 与可浏览源码。 Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
Executable
+13
@@ -0,0 +1,13 @@
|
||||
#!/usr/bin/env bash
|
||||
# gen.sh — 生图快捷入口。用法:
|
||||
# ./gen.sh "提示词" # 文生图,默认 1024x1024
|
||||
# ./gen.sh "提示词" --size 1536x1024 # 透传任意 gen_image.py 参数
|
||||
# ./gen.sh "换成雪山背景" --edit in.png # 图生图
|
||||
# 无论从哪个目录调用都能正确定位脚本与 .env。
|
||||
set -euo pipefail
|
||||
DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
||||
if [ "$#" -eq 0 ]; then
|
||||
echo "用法: ./gen.sh \"提示词\" [--size 1024x1024] [--quality high] [--edit 图.png] ..." >&2
|
||||
exit 1
|
||||
fi
|
||||
exec python3 "$DIR/scripts/gen_image.py" "$@"
|
||||
Reference in New Issue
Block a user