返回顶部
d

digital-product-builder数字产品构建器

Build and launch zero-cost digital products on Gumroad, itch.io, and DriveThruRPG. Use when: creating cover images or product art without external AI image services, generating product listing copy cheaply, building downloadable asset packs (TTRPG tokens, design kits, templates), or setting up a new digital storefront. Uses Python Pillow for images ($0, no login, no browser needed) and Groq for copy (~$0.01/product). Works on Linux, macOS, and Windows-WSL. Includes platform size presets, font di

作者: admin | 来源: ClawHub
源自
ClawHub
版本
V 1.0.3
安全检测
已通过
117
下载量
免费
免费
0
收藏
概述
安装方式
版本历史

digital-product-builder

数字产品构建器

无需在图像生成器或昂贵的AI模型上花费资金,即可为Gumroad、itch.io和DriveThruRPG构建并发布数字产品。

技术栈: Python Pillow用于图像($0)+ Groq用于文案(约$0.01/产品)+ Claude主会话仅用于编排。



快速开始

bash

检查Pillow


python3 -c from PIL import Image, ImageDraw, ImageFont; print(Pillow ready) 2>/dev/null || echo 未安装

如未安装则安装(依次尝试,直到成功)

pip3 install Pillow

或:pip install Pillow

或:python3 -m pip install Pillow


图像生成 — Pillow

切勿使用浏览器工具生成图像。 Pillow更快、不会崩溃,且无需登录或外部服务。

查找可用字体(首先运行此命令)

python import os font_dirs = [ /usr/share/fonts, # Linux /System/Library/Fonts, # macOS C:/Windows/Fonts, # Windows os.path.expanduser(~/.fonts), ] fonts = [] for d in font_dirs: if os.path.exists(d): for root, _, files in os.walk(d): for f in files: if f.endswith((.ttf, .otf)): fonts.append(os.path.join(root, f)) print(\n.join(fonts[:20]))

常见字体路径(Ubuntu/Debian)

/usr/share/fonts/truetype/liberation/LiberationSerif-Bold.ttf
/usr/share/fonts/truetype/liberation/LiberationSans-Bold.ttf
/usr/share/fonts/truetype/dejavu/DejaVuSans-Bold.ttf

常见字体路径(macOS)

/System/Library/Fonts/Helvetica.ttc
/System/Library/Fonts/Georgia.ttf
/Library/Fonts/Arial.ttf

安全后备方案(始终有效,无需字体文件)

python font = ImageFont.load_default() # 基础但可靠

平台封面尺寸
平台尺寸备注
itch.io630×500px浏览可见性必需
Gumroad
1280×720px | 16:9 |

| DriveThruRPG | 900×700px | 横向或纵向 | | 社交预览(OG/Twitter) | 1200×630px | 标准尺寸 |

封面图像模板

python from PIL import Image, ImageDraw, ImageFont import os

W, H = 630, 500
SERIF_BOLD = /usr/share/fonts/truetype/liberation/LiberationSerif-Bold.ttf

img = Image.new(RGB, (W, H), (20, 20, 40))
draw = ImageDraw.Draw(img)
font = ImageFont.truetype(SERIF_BOLD, 36)
gold = (201, 168, 76)

边框

draw.rectangle([10,10,W-10,H-10], outline=gold, width=4)

居中标题

b = draw.textbbox((0,0), 您的标题, font=font) draw.text(((W-(b[2]-b[0]))//2, (H-(b[3]-b[1]))//2), 您的标题, fill=gold, font=font)

img.save(/path/to/output.png, PNG, optimize=True)
print(f已保存({os.path.getsize(/path/to/output.png)//1024}KB))

径向渐变(暗到亮效果)

python def lerp(a, b, t): return tuple(int(a[i] + (b[i]-a[i])*t) for i in range(3))

center = (230, 180, 80) # 亮色中心
edge = (60, 30, 10) # 暗色边缘
for step in range(30, 0, -1):
t = step / 30
c = lerp(center, edge, t)
r = int(radius * step / 30)
draw.ellipse([cx-r, cy-r, cx+r, cy+r], fill=c)

RGBA透明度(用于合成)

python img = Image.new(RGBA, (W, H), (20, 20, 40, 255)) draw = ImageDraw.Draw(img, RGBA)

... 使用alpha绘制 ...

保存PNG前压平为RGB

bg = Image.new(RGB, (W, H), (20, 20, 40)) bg.paste(img, mask=img.split()[3]) bg.save(out_path, PNG)

ZIP打包

python import zipfile with zipfile.ZipFile(product.zip, w, zipfile.ZIP_DEFLATED) as z: z.writestr(README.txt, readme_text) for fp in file_list: z.write(fp, fsubfolder/{os.path.basename(fp)})

文案生成 — Groq

API密钥位置: 将您的Groq API密钥存储在~/.openclaw/workspace/dashboard/.env中,格式为GROQAPIKEY=yourkeyhere

Node.js调用模式

javascript const https = require(https); const GROQKEY = process.env.GROQAPI_KEY;

const body = JSON.stringify({
model: llama-3.3-70b-versatile,
messages: [{ role: user, content: YOUR_PROMPT }],
max_tokens: 600,
temperature: 0.7
});

const req = https.request({
hostname: api.groq.com,
path: /openai/v1/chat/completions,
method: POST,
headers: {
Authorization: Bearer ${GROQ_KEY},
Content-Type: application/json,
Content-Length: Buffer.byteLength(body)
}
}, res => {
let d = ;
res.on(data, c => d += c);
res.on(end, () => console.log(JSON.parse(d).choices[0].message.content));
});
req.write(body);
req.end();

产品列表文案提示模板

为[平台]撰写产品列表。使用平实语言。不要使用破折号。
不要使用填充性短语(提升、完美适合、优化工作流程)。

产品:[名称]
产品说明:[描述]
价格:[价格]
格式:[文件格式]

撰写:标题(不超过60字符)、标语(一句话)、描述
(3个短段落)、包含内容(最多5项)、5个搜索标签。

去AI化检查清单(保存文案前始终执行)

  • - 移除破折号 — 改用句号或逗号
  • 移除:提升、增强、无缝、完美适合、优化
  • 将长项目符号列表拆分为短段落
  • 如果听起来像新闻稿,请重写

平台操作指南

itch.io

  • - 新产品:仪表盘 → 创建新项目 → 可下载
  • 封面图像:必需630×500px — 无封面则在浏览中不可见
  • 定价:固定价格或随意付费并设置最低金额
  • 上传:多文件产品使用ZIP文件
  • 标签:使用具体术语(例如ttrpg代币而非仅游戏)

Gumroad

  • - 新产品:产品 → 新产品 → 数字产品
  • 封面:推荐1280×720
  • 描述编辑器可能需要手动粘贴 — 自动化有时被阻止
  • 在产品设置中设置发现类别以在市场中可见
  • 在账户设置中配置提现阈值

DriveThruRPG

  • - 在drivethrurpg.com/publishers注册免费发布者账户
  • 封面:900×700px
  • 代币类别:配件 > 代币/地图
  • 收入:创作者70% / DTRPG 30%
  • 提现:PayPal,最低$10

常见障碍及解决方案

障碍解决方案
Bing图像创建器需要微软账户使用Pillow — 无需外部服务
ideogram.ai / 外部生成器被Cloudflare阻止
使用Pillow | | 浏览器在画布渲染时崩溃 | 不要使用浏览器处理图像。仅用Pillow。 | | 无法从浏览器JS将画布保存到文件 | Pillow直接写入磁盘 | | 浏览器工具中file:// URL被阻止 | 通过python3 -m http.server PORT提供服务 | | Gumroad编辑器阻止自动化 | 手动粘贴产品列表文案

标签

skill ai

通过对话安装

该技能支持在以下平台通过对话安装:

OpenClaw WorkBuddy QClaw Kimi Claude

方式一:安装 SkillHub 和技能

帮我安装 SkillHub 和 digital-product-builder-1776029677 技能

方式二:设置 SkillHub 为优先技能安装源

设置 SkillHub 为我的优先技能安装源,然后帮我安装 digital-product-builder-1776029677 技能

通过命令行安装

skillhub install digital-product-builder-1776029677

下载

⬇ 下载 digital-product-builder v1.0.3(免费)

文件大小: 4.46 KB | 发布时间: 2026-4-13 10:02

v1.0.3 最新 2026-4-13 10:02
Cross-platform font discovery (Linux/macOS/Windows), improved Pillow install instructions, broader skill description for better agent triggering.

Archiver·手机版·闲社网·闲社论坛·羊毛社区· 多链控股集团有限公司 · 苏ICP备2025199260号-1

Powered by Discuz! X5.0   © 2024-2025 闲社网·线报更新论坛·羊毛分享社区·http://xianshe.com

p2p_official_large
返回顶部