auto-save 2026-05-19 11:58 (~3)

This commit is contained in:
2026-05-19 11:58:55 +08:00
parent e761e72e21
commit a1063b6774
3 changed files with 11 additions and 2 deletions

View File

@@ -582,6 +582,13 @@
"message": "auto-save 2026-05-19 11:53 (~3)",
"hash": "2c2d11b",
"files_changed": 4
},
{
"ts": "2026-05-19T11:53:58+08:00",
"type": "commit",
"message": "fix: prevent duplicate pack generation",
"hash": "e761e72",
"files_changed": 1
}
]
}

View File

@@ -231,7 +231,9 @@ export async function inferCharacterSpecFromImage(opts: {
'根据上传图片推断 CharacterSpec严格输出 JSON不要 markdown不要解释。',
'字段必须完整匹配name, oneLiner, targetUser, speciesShape, bodyRatio, faceFeatures, colorPalette, materials, accessories, signatureElements, manufacturingNotes, patentFocus, marketingAngle, negativePrompt, sourceImageId, sourceImageUrl, lockedAt。',
'数组字段必须为字符串数组。',
'不要把已知商业 IP 当成可用授权素材;若图像疑似迪士尼、三丽鸥、泡泡玛特等已注册 IP在 negativePrompt 中明确提示需替换为原创元素。',
'如果图像中存在用户上传的原创品牌名、角色名、服装字样、帽标、面罩图案或配件图形,必须作为角色识别元素保留,不要改名、翻译、替换或弱化。',
'不要把已知第三方商业 IP 当成可用授权素材;只有图像明显疑似迪士尼、三丽鸥、泡泡玛特等已注册第三方 IP 时,才在 negativePrompt 中提示替换为原创元素。',
'negativePrompt 只能禁止无关品牌、水印、真实明星肖像、第三方已注册 IP 和偏离源图的元素;不要要求替换用户上传图中的原创品牌/主标识。',
opts.userHint?.trim() ? `用户提示:${opts.userHint.trim()}` : '用户没有提供命名提示,请根据图像生成一个中性原创名称。',
`当前时间戳:${Date.now()}`,
`源图 URL${opts.imageUrl}`,

View File

@@ -1137,6 +1137,6 @@ export function renderCharacterSummary(spec: CharacterSpec): string {
`识别元素:${spec.signatureElements.join('、')}`,
`专利重点:${spec.patentFocus.join('、')}`,
`营销角度:${spec.marketingAngle.join('、')}`,
`不要出现${spec.negativePrompt}`,
`生成约束${spec.negativePrompt}`,
].join('');
}