@starreel/mcp 0.1.6 → 0.1.8
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.
- package/dist/tools/produce.js +12 -10
- package/package.json +1 -1
- package/server.json +2 -2
package/dist/tools/produce.js
CHANGED
|
@@ -29,6 +29,11 @@ const ETHNICITY_CODES = [
|
|
|
29
29
|
'caucasian', 'middle_eastern', 'african', 'latin_american',
|
|
30
30
|
'native_american', 'aboriginal_australian', 'mixed', 'custom',
|
|
31
31
|
];
|
|
32
|
+
// 画幅/分辨率的可选值 —— create_drama 与 update_project_settings **共用同一源**,防两处漂移。
|
|
33
|
+
// 与后端发现接口 produce-options.ts 的 ASPECT_RATIO_OPTIONS / VIDEO_RESOLUTION_OPTIONS 键集一致
|
|
34
|
+
// (video_resolution 与后端 VIDEO_RES_WHITELIST 钉死;aspect_ratio 后端柔性,这里给同一策展集)。
|
|
35
|
+
const ASPECT_RATIOS = ['9:16', '16:9', '1:1', '4:5', '4:3', '21:9'];
|
|
36
|
+
const VIDEO_RESOLUTIONS = ['480p', '720p', '1080p', '4k'];
|
|
32
37
|
/** 把友好 ethnicity 枚举 + note 组装成后端认的结构化族裔锁 { code, note? }。 */
|
|
33
38
|
function buildEthnicityLock(ethnicity, note) {
|
|
34
39
|
if (!ethnicity)
|
|
@@ -36,6 +41,9 @@ function buildEthnicityLock(ethnicity, note) {
|
|
|
36
41
|
return ethnicity === 'custom' ? { code: 'custom', note: note ?? '' } : { code: ethnicity };
|
|
37
42
|
}
|
|
38
43
|
export function registerProduceTools(server, client) {
|
|
44
|
+
// ---------- 建剧前:列可选项 ----------
|
|
45
|
+
server.tool('list_project_options', '列出建剧的全部可选项:项目类型(短剧/广告/MV/品牌片)、画幅比例、视频分辨率(带中英标签+说明+默认值)。' +
|
|
46
|
+
'建剧前先调它,把选项给用户挑,再照 key 传给 create_drama。免费。', {}, async () => jsonResult(await client.produceGet('/project-options')));
|
|
39
47
|
// ---------- 建剧 ----------
|
|
40
48
|
// 参数=「项目设定 / 新建项目」页对外能设的全部通用字段(不含内部产线开关)。
|
|
41
49
|
// 尤其 setting_brief(世界观 Brief)与 ethnicity:它们是全链 ERA LOCK / 族裔单一真相源,
|
|
@@ -46,14 +54,8 @@ export function registerProduceTools(server, client) {
|
|
|
46
54
|
genre: z.string().optional().describe('题材,如 都市/悬疑/古装'),
|
|
47
55
|
style: z.string().optional().describe('风格描述'),
|
|
48
56
|
description: z.string().optional(),
|
|
49
|
-
aspect_ratio: z
|
|
50
|
-
|
|
51
|
-
.optional()
|
|
52
|
-
.describe('画幅比例(默认 9:16 竖屏短剧)'),
|
|
53
|
-
video_resolution: z
|
|
54
|
-
.enum(['480p', '720p', '1080p', '4k'])
|
|
55
|
-
.optional()
|
|
56
|
-
.describe('视频分辨率(默认 720p;成本随分辨率上升)'),
|
|
57
|
+
aspect_ratio: z.enum(ASPECT_RATIOS).optional().describe('画幅比例(默认 9:16 竖屏短剧)'),
|
|
58
|
+
video_resolution: z.enum(VIDEO_RESOLUTIONS).optional().describe('视频分辨率(默认 720p;成本随分辨率上升)'),
|
|
57
59
|
setting_brief: z
|
|
58
60
|
.string()
|
|
59
61
|
.optional()
|
|
@@ -126,8 +128,8 @@ export function registerProduceTools(server, client) {
|
|
|
126
128
|
style: z.string().optional(),
|
|
127
129
|
description: z.string().optional(),
|
|
128
130
|
tags: z.array(z.string()).optional(),
|
|
129
|
-
aspect_ratio: z.enum(
|
|
130
|
-
video_resolution: z.enum(
|
|
131
|
+
aspect_ratio: z.enum(ASPECT_RATIOS).optional(),
|
|
132
|
+
video_resolution: z.enum(VIDEO_RESOLUTIONS).optional(),
|
|
131
133
|
setting_brief: z.string().optional().describe('世界观 Brief(ERA LOCK)'),
|
|
132
134
|
ethnicity: z.enum(ETHNICITY_CODES).optional().describe('角色族裔锁'),
|
|
133
135
|
ethnicity_note: z.string().optional(),
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@starreel/mcp",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.8",
|
|
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",
|
package/server.json
CHANGED
|
@@ -2,13 +2,13 @@
|
|
|
2
2
|
"$schema": "https://static.modelcontextprotocol.io/schemas/2025-09-29/server.schema.json",
|
|
3
3
|
"name": "ai.starreel/starreel",
|
|
4
4
|
"description": "Turn a script into a finished, downloadable short-drama episode — via MCP or REST.",
|
|
5
|
-
"version": "0.1.
|
|
5
|
+
"version": "0.1.8",
|
|
6
6
|
"websiteUrl": "https://starreel.ai",
|
|
7
7
|
"packages": [
|
|
8
8
|
{
|
|
9
9
|
"registryType": "npm",
|
|
10
10
|
"identifier": "@starreel/mcp",
|
|
11
|
-
"version": "0.1.
|
|
11
|
+
"version": "0.1.8",
|
|
12
12
|
"transport": { "type": "stdio" },
|
|
13
13
|
"environmentVariables": [
|
|
14
14
|
{
|