@starreel/mcp 0.1.15 → 0.1.16

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -200,9 +200,18 @@ export function registerProduceTools(server, client) {
200
200
  return jsonResult({ image_url: url });
201
201
  });
202
202
  server.tool('set_character_portrait', '用客户自有图片作为角色定妆图(身份锚,优先级高于 AI 生成;之后 AI 重生默认不覆盖)。' +
203
- '自动上传本地图 + 登记。免费。', { character_id: z.number().int().positive(), file_path: z.string().describe('本地定妆图路径') }, async ({ character_id, file_path }) => {
204
- const image_url = await client.uploadLocalFile(file_path, 'image');
205
- return jsonResult(await client.producePost(`/characters/${character_id}/portrait`, { image_url }));
203
+ '换图会自动失效并重建派生资产(三视图设定图/发型·身材参考)、重建人脸锁。' +
204
+ '传本地文件(file_path,自动上传 COS)或已托管的图片 URL(image_url),二选一。免费。', {
205
+ character_id: z.number().int().positive(),
206
+ file_path: z.string().optional().describe('本地定妆图路径(与 image_url 二选一;自动上传 COS)'),
207
+ image_url: z.string().optional().describe('已上传的定妆图 URL(与 file_path 二选一)'),
208
+ }, async ({ character_id, file_path, image_url }) => {
209
+ const url = image_url && image_url.trim()
210
+ ? image_url.trim()
211
+ : (file_path ? await client.uploadLocalFile(file_path, 'image') : '');
212
+ if (!url)
213
+ throw new Error('file_path 或 image_url 至少提供一个');
214
+ return jsonResult(await client.producePost(`/characters/${character_id}/portrait`, { image_url: url }));
206
215
  });
207
216
  server.tool('upload_shot_frame', '用客户自有图片作为某镜的首帧(first_frame)或尾帧(last_frame)。尾帧可选、系统不自动生成——仅在想固定某镜结尾画面(大运镜/揭示镜)时传;常规只需首帧。会把该镜已有视频标为过期待重生。自动上传+登记。免费。', {
208
217
  storyboard_id: z.number().int().positive(),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@starreel/mcp",
3
- "version": "0.1.15",
3
+ "version": "0.1.16",
4
4
  "mcpName": "ai.starreel/starreel",
5
5
  "description": "StarReel MCP server — drive the AI short-drama production pipeline (script → storyboards → frames → video → final cut) from Claude, Cursor, or any MCP client",
6
6
  "license": "MIT",