@synthetic-ai/premiere-mcp 2.1.0 → 2.3.0-dev.0
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/CHANGELOG.md +135 -123
- package/LICENSE +21 -21
- package/README.md +242 -242
- package/cep-plugin/.debug +8 -8
- package/cep-plugin/CSInterface.js +92 -92
- package/cep-plugin/host.jsx +7 -7
- package/cep-plugin/index.html +472 -472
- package/cep-plugin/main.js +6 -0
- package/cep-plugin/premiere.jsx +24947 -24947
- package/dist/bridge/script-builder.js +378 -378
- package/dist/index.js +103 -4
- package/dist/license.js +38 -0
- package/dist/server.js +60 -60
- package/dist/tools/advanced.js +357 -357
- package/dist/tools/audio-advanced.js +1049 -1049
- package/dist/tools/audio.js +42 -42
- package/dist/tools/captions.js +27 -27
- package/dist/tools/clipboard.js +214 -214
- package/dist/tools/color-advanced.js +253 -253
- package/dist/tools/discovery.js +291 -291
- package/dist/tools/effects.js +285 -285
- package/dist/tools/export-presets.js +206 -206
- package/dist/tools/export.js +255 -255
- package/dist/tools/health.js +10 -10
- package/dist/tools/inspection.js +885 -885
- package/dist/tools/keyframes.js +369 -369
- package/dist/tools/markers.js +89 -89
- package/dist/tools/media.js +178 -178
- package/dist/tools/metadata.js +94 -94
- package/dist/tools/multicam.js +50 -50
- package/dist/tools/playback.js +15 -15
- package/dist/tools/playhead.js +95 -95
- package/dist/tools/project-manager.js +21 -21
- package/dist/tools/project.js +149 -149
- package/dist/tools/scripting.js +319 -319
- package/dist/tools/selection.js +202 -202
- package/dist/tools/sequence-advanced.js +379 -379
- package/dist/tools/sequence-settings.js +564 -564
- package/dist/tools/sequence.js +167 -167
- package/dist/tools/source-monitor.js +68 -68
- package/dist/tools/text.js +58 -58
- package/dist/tools/timeline.js +312 -312
- package/dist/tools/track-management.js +446 -446
- package/dist/tools/track-targeting.js +635 -635
- package/dist/tools/tracks.js +87 -87
- package/dist/tools/transitions-motion.js +174 -174
- package/dist/tools/transitions.js +111 -111
- package/dist/tools/utility.js +606 -606
- package/dist/tools/workspace.js +29 -29
- package/package.json +66 -66
- package/scripts/build-chat-dmg.sh +210 -210
- package/scripts/build-chat-zip.sh +291 -291
- package/scripts/install-cep-windows.ps1 +99 -99
- package/scripts/install-cep.sh +66 -66
- package/scripts/install-chat-plugin.bat +67 -67
- package/scripts/install-chat-plugin.sh +85 -85
- package/scripts/install-windows.bat +95 -95
- package/scripts/package.mjs +254 -254
package/dist/tools/playhead.js
CHANGED
|
@@ -6,15 +6,15 @@ export function getPlayheadTools(bridgeOptions) {
|
|
|
6
6
|
description: "Get the current playhead (CTI) position in the active sequence",
|
|
7
7
|
parameters: {},
|
|
8
8
|
handler: async () => {
|
|
9
|
-
const script = buildToolScript(`
|
|
10
|
-
var seq = app.project.activeSequence;
|
|
11
|
-
if (!seq) return __error("No active sequence");
|
|
12
|
-
|
|
13
|
-
var ticks = seq.getPlayerPosition().ticks;
|
|
14
|
-
return __result({
|
|
15
|
-
seconds: __ticksToSeconds(ticks),
|
|
16
|
-
ticks: ticks
|
|
17
|
-
});
|
|
9
|
+
const script = buildToolScript(`
|
|
10
|
+
var seq = app.project.activeSequence;
|
|
11
|
+
if (!seq) return __error("No active sequence");
|
|
12
|
+
|
|
13
|
+
var ticks = seq.getPlayerPosition().ticks;
|
|
14
|
+
return __result({
|
|
15
|
+
seconds: __ticksToSeconds(ticks),
|
|
16
|
+
ticks: ticks
|
|
17
|
+
});
|
|
18
18
|
`);
|
|
19
19
|
return sendCommand(script, bridgeOptions);
|
|
20
20
|
},
|
|
@@ -32,14 +32,14 @@ export function getPlayheadTools(bridgeOptions) {
|
|
|
32
32
|
required: ["time_seconds"],
|
|
33
33
|
},
|
|
34
34
|
handler: async (args) => {
|
|
35
|
-
const script = buildToolScript(`
|
|
36
|
-
var seq = app.project.activeSequence;
|
|
37
|
-
if (!seq) return __error("No active sequence");
|
|
38
|
-
|
|
39
|
-
var ticks = __secondsToTicks(${args.time_seconds}).toString();
|
|
40
|
-
seq.setPlayerPosition(ticks);
|
|
41
|
-
|
|
42
|
-
return __result({ positionSeconds: ${args.time_seconds} });
|
|
35
|
+
const script = buildToolScript(`
|
|
36
|
+
var seq = app.project.activeSequence;
|
|
37
|
+
if (!seq) return __error("No active sequence");
|
|
38
|
+
|
|
39
|
+
var ticks = __secondsToTicks(${args.time_seconds}).toString();
|
|
40
|
+
seq.setPlayerPosition(ticks);
|
|
41
|
+
|
|
42
|
+
return __result({ positionSeconds: ${args.time_seconds} });
|
|
43
43
|
`);
|
|
44
44
|
return sendCommand(script, bridgeOptions);
|
|
45
45
|
},
|
|
@@ -61,45 +61,45 @@ export function getPlayheadTools(bridgeOptions) {
|
|
|
61
61
|
required: ["in_seconds", "out_seconds"],
|
|
62
62
|
},
|
|
63
63
|
handler: async (args) => {
|
|
64
|
-
const script = buildToolScript(`
|
|
65
|
-
var seq = app.project.activeSequence;
|
|
66
|
-
if (!seq) return __error("No active sequence");
|
|
67
|
-
|
|
68
|
-
var inOk = false;
|
|
69
|
-
var outOk = false;
|
|
70
|
-
var errMsg = null;
|
|
71
|
-
|
|
72
|
-
var inTicks = __secondsToTicks(${args.in_seconds}).toString();
|
|
73
|
-
var outTicks = __secondsToTicks(${args.out_seconds}).toString();
|
|
74
|
-
|
|
75
|
-
try {
|
|
76
|
-
if (typeof seq.setWorkAreaInPoint === "function") {
|
|
77
|
-
seq.setWorkAreaInPoint(inTicks);
|
|
78
|
-
inOk = true;
|
|
79
|
-
}
|
|
80
|
-
} catch(e1) { errMsg = (errMsg ? errMsg + "; " : "") + "in: " + e1.toString(); }
|
|
81
|
-
|
|
82
|
-
try {
|
|
83
|
-
if (typeof seq.setWorkAreaOutPoint === "function") {
|
|
84
|
-
seq.setWorkAreaOutPoint(outTicks);
|
|
85
|
-
outOk = true;
|
|
86
|
-
}
|
|
87
|
-
} catch(e2) { errMsg = (errMsg ? errMsg + "; " : "") + "out: " + e2.toString(); }
|
|
88
|
-
|
|
89
|
-
var enabled = false;
|
|
90
|
-
try {
|
|
91
|
-
if (typeof seq.isWorkAreaBarEnabled === "function") enabled = seq.isWorkAreaBarEnabled();
|
|
92
|
-
} catch(e3) {}
|
|
93
|
-
|
|
94
|
-
return __result({
|
|
95
|
-
success: (inOk && outOk),
|
|
96
|
-
workAreaIn: ${args.in_seconds},
|
|
97
|
-
workAreaOut: ${args.out_seconds},
|
|
98
|
-
inSet: inOk,
|
|
99
|
-
outSet: outOk,
|
|
100
|
-
workAreaEnabled: enabled,
|
|
101
|
-
error: errMsg
|
|
102
|
-
});
|
|
64
|
+
const script = buildToolScript(`
|
|
65
|
+
var seq = app.project.activeSequence;
|
|
66
|
+
if (!seq) return __error("No active sequence");
|
|
67
|
+
|
|
68
|
+
var inOk = false;
|
|
69
|
+
var outOk = false;
|
|
70
|
+
var errMsg = null;
|
|
71
|
+
|
|
72
|
+
var inTicks = __secondsToTicks(${args.in_seconds}).toString();
|
|
73
|
+
var outTicks = __secondsToTicks(${args.out_seconds}).toString();
|
|
74
|
+
|
|
75
|
+
try {
|
|
76
|
+
if (typeof seq.setWorkAreaInPoint === "function") {
|
|
77
|
+
seq.setWorkAreaInPoint(inTicks);
|
|
78
|
+
inOk = true;
|
|
79
|
+
}
|
|
80
|
+
} catch(e1) { errMsg = (errMsg ? errMsg + "; " : "") + "in: " + e1.toString(); }
|
|
81
|
+
|
|
82
|
+
try {
|
|
83
|
+
if (typeof seq.setWorkAreaOutPoint === "function") {
|
|
84
|
+
seq.setWorkAreaOutPoint(outTicks);
|
|
85
|
+
outOk = true;
|
|
86
|
+
}
|
|
87
|
+
} catch(e2) { errMsg = (errMsg ? errMsg + "; " : "") + "out: " + e2.toString(); }
|
|
88
|
+
|
|
89
|
+
var enabled = false;
|
|
90
|
+
try {
|
|
91
|
+
if (typeof seq.isWorkAreaBarEnabled === "function") enabled = seq.isWorkAreaBarEnabled();
|
|
92
|
+
} catch(e3) {}
|
|
93
|
+
|
|
94
|
+
return __result({
|
|
95
|
+
success: (inOk && outOk),
|
|
96
|
+
workAreaIn: ${args.in_seconds},
|
|
97
|
+
workAreaOut: ${args.out_seconds},
|
|
98
|
+
inSet: inOk,
|
|
99
|
+
outSet: outOk,
|
|
100
|
+
workAreaEnabled: enabled,
|
|
101
|
+
error: errMsg
|
|
102
|
+
});
|
|
103
103
|
`);
|
|
104
104
|
return sendCommand(script, bridgeOptions);
|
|
105
105
|
},
|
|
@@ -108,29 +108,29 @@ export function getPlayheadTools(bridgeOptions) {
|
|
|
108
108
|
description: "Get the current work area in and out points",
|
|
109
109
|
parameters: {},
|
|
110
110
|
handler: async () => {
|
|
111
|
-
const script = buildToolScript(`
|
|
112
|
-
var seq = app.project.activeSequence;
|
|
113
|
-
if (!seq) return __error("No active sequence");
|
|
114
|
-
|
|
115
|
-
var inSec = 0;
|
|
116
|
-
var outSec = 0;
|
|
117
|
-
// seq.end is already a ticks STRING, not a Time object
|
|
118
|
-
try { if (seq.end != null) outSec = __ticksToSeconds(String(seq.end)); } catch(e) {}
|
|
119
|
-
// workInPoint/workOutPoint may be Time objects or ticks strings — handle both
|
|
120
|
-
try {
|
|
121
|
-
if (seq.workInPoint != null) {
|
|
122
|
-
inSec = (seq.workInPoint.ticks != null) ? __ticksToSeconds(seq.workInPoint.ticks) : __ticksToSeconds(String(seq.workInPoint));
|
|
123
|
-
}
|
|
124
|
-
if (seq.workOutPoint != null) {
|
|
125
|
-
outSec = (seq.workOutPoint.ticks != null) ? __ticksToSeconds(seq.workOutPoint.ticks) : __ticksToSeconds(String(seq.workOutPoint));
|
|
126
|
-
}
|
|
127
|
-
} catch(e) {}
|
|
128
|
-
return __result({
|
|
129
|
-
sequenceName: seq.name,
|
|
130
|
-
inSeconds: inSec,
|
|
131
|
-
outSeconds: outSec,
|
|
132
|
-
workAreaEnabled: seq.isWorkAreaBarEnabled ? seq.isWorkAreaBarEnabled() : false
|
|
133
|
-
});
|
|
111
|
+
const script = buildToolScript(`
|
|
112
|
+
var seq = app.project.activeSequence;
|
|
113
|
+
if (!seq) return __error("No active sequence");
|
|
114
|
+
|
|
115
|
+
var inSec = 0;
|
|
116
|
+
var outSec = 0;
|
|
117
|
+
// seq.end is already a ticks STRING, not a Time object
|
|
118
|
+
try { if (seq.end != null) outSec = __ticksToSeconds(String(seq.end)); } catch(e) {}
|
|
119
|
+
// workInPoint/workOutPoint may be Time objects or ticks strings — handle both
|
|
120
|
+
try {
|
|
121
|
+
if (seq.workInPoint != null) {
|
|
122
|
+
inSec = (seq.workInPoint.ticks != null) ? __ticksToSeconds(seq.workInPoint.ticks) : __ticksToSeconds(String(seq.workInPoint));
|
|
123
|
+
}
|
|
124
|
+
if (seq.workOutPoint != null) {
|
|
125
|
+
outSec = (seq.workOutPoint.ticks != null) ? __ticksToSeconds(seq.workOutPoint.ticks) : __ticksToSeconds(String(seq.workOutPoint));
|
|
126
|
+
}
|
|
127
|
+
} catch(e) {}
|
|
128
|
+
return __result({
|
|
129
|
+
sequenceName: seq.name,
|
|
130
|
+
inSeconds: inSec,
|
|
131
|
+
outSeconds: outSec,
|
|
132
|
+
workAreaEnabled: seq.isWorkAreaBarEnabled ? seq.isWorkAreaBarEnabled() : false
|
|
133
|
+
});
|
|
134
134
|
`);
|
|
135
135
|
return sendCommand(script, bridgeOptions);
|
|
136
136
|
},
|
|
@@ -152,14 +152,14 @@ export function getPlayheadTools(bridgeOptions) {
|
|
|
152
152
|
required: ["in_seconds", "out_seconds"],
|
|
153
153
|
},
|
|
154
154
|
handler: async (args) => {
|
|
155
|
-
const script = buildToolScript(`
|
|
156
|
-
var seq = app.project.activeSequence;
|
|
157
|
-
if (!seq) return __error("No active sequence");
|
|
158
|
-
|
|
159
|
-
seq.setInPoint(__secondsToTicks(${args.in_seconds}).toString());
|
|
160
|
-
seq.setOutPoint(__secondsToTicks(${args.out_seconds}).toString());
|
|
161
|
-
|
|
162
|
-
return __result({ inSeconds: ${args.in_seconds}, outSeconds: ${args.out_seconds} });
|
|
155
|
+
const script = buildToolScript(`
|
|
156
|
+
var seq = app.project.activeSequence;
|
|
157
|
+
if (!seq) return __error("No active sequence");
|
|
158
|
+
|
|
159
|
+
seq.setInPoint(__secondsToTicks(${args.in_seconds}).toString());
|
|
160
|
+
seq.setOutPoint(__secondsToTicks(${args.out_seconds}).toString());
|
|
161
|
+
|
|
162
|
+
return __result({ inSeconds: ${args.in_seconds}, outSeconds: ${args.out_seconds} });
|
|
163
163
|
`);
|
|
164
164
|
return sendCommand(script, bridgeOptions);
|
|
165
165
|
},
|
|
@@ -168,14 +168,14 @@ export function getPlayheadTools(bridgeOptions) {
|
|
|
168
168
|
description: "Get the current sequence in and out points",
|
|
169
169
|
parameters: {},
|
|
170
170
|
handler: async () => {
|
|
171
|
-
const script = buildToolScript(`
|
|
172
|
-
var seq = app.project.activeSequence;
|
|
173
|
-
if (!seq) return __error("No active sequence");
|
|
174
|
-
|
|
175
|
-
return __result({
|
|
176
|
-
inSeconds: __ticksToSeconds(seq.getInPoint()),
|
|
177
|
-
outSeconds: __ticksToSeconds(seq.getOutPoint())
|
|
178
|
-
});
|
|
171
|
+
const script = buildToolScript(`
|
|
172
|
+
var seq = app.project.activeSequence;
|
|
173
|
+
if (!seq) return __error("No active sequence");
|
|
174
|
+
|
|
175
|
+
return __result({
|
|
176
|
+
inSeconds: __ticksToSeconds(seq.getInPoint()),
|
|
177
|
+
outSeconds: __ticksToSeconds(seq.getOutPoint())
|
|
178
|
+
});
|
|
179
179
|
`);
|
|
180
180
|
return sendCommand(script, bridgeOptions);
|
|
181
181
|
},
|
|
@@ -51,27 +51,27 @@ export function getProjectManagerTools(bridgeOptions) {
|
|
|
51
51
|
required: ["destination_path"],
|
|
52
52
|
},
|
|
53
53
|
handler: async (args) => {
|
|
54
|
-
const script = buildToolScript(`
|
|
55
|
-
var pm = app.projectManager;
|
|
56
|
-
if (!pm) return __error("Project Manager not available");
|
|
57
|
-
|
|
58
|
-
pm.destinationPath = "${escapeForExtendScript(args.destination_path)}";
|
|
59
|
-
pm.includeAllSequences = ${args.include_all_sequences !== false ? 1 : 0};
|
|
60
|
-
pm.copyToNewLocation = ${args.copy_to_new_location !== false ? 1 : 0};
|
|
61
|
-
pm.excludeUnused = ${args.exclude_unused !== false ? 1 : 0};
|
|
62
|
-
pm.transcodeMedia = ${args.transcode ? 1 : 0};
|
|
63
|
-
pm.includePreviewFiles = ${args.include_preview_files ? 1 : 0};
|
|
64
|
-
pm.renameMedia = ${args.rename_media ? 1 : 0};
|
|
65
|
-
pm.convertImageSequences = ${args.convert_image_sequences ? 1 : 0};
|
|
66
|
-
pm.convertAEComps = ${args.convert_ae_comps ? 1 : 0};
|
|
67
|
-
pm.convertSyntheticMedia = ${args.convert_synthetic ? 1 : 0};
|
|
68
|
-
|
|
69
|
-
pm.process(app.project);
|
|
70
|
-
|
|
71
|
-
return __result({
|
|
72
|
-
started: true,
|
|
73
|
-
destination: "${escapeForExtendScript(args.destination_path)}"
|
|
74
|
-
});
|
|
54
|
+
const script = buildToolScript(`
|
|
55
|
+
var pm = app.projectManager;
|
|
56
|
+
if (!pm) return __error("Project Manager not available");
|
|
57
|
+
|
|
58
|
+
pm.destinationPath = "${escapeForExtendScript(args.destination_path)}";
|
|
59
|
+
pm.includeAllSequences = ${args.include_all_sequences !== false ? 1 : 0};
|
|
60
|
+
pm.copyToNewLocation = ${args.copy_to_new_location !== false ? 1 : 0};
|
|
61
|
+
pm.excludeUnused = ${args.exclude_unused !== false ? 1 : 0};
|
|
62
|
+
pm.transcodeMedia = ${args.transcode ? 1 : 0};
|
|
63
|
+
pm.includePreviewFiles = ${args.include_preview_files ? 1 : 0};
|
|
64
|
+
pm.renameMedia = ${args.rename_media ? 1 : 0};
|
|
65
|
+
pm.convertImageSequences = ${args.convert_image_sequences ? 1 : 0};
|
|
66
|
+
pm.convertAEComps = ${args.convert_ae_comps ? 1 : 0};
|
|
67
|
+
pm.convertSyntheticMedia = ${args.convert_synthetic ? 1 : 0};
|
|
68
|
+
|
|
69
|
+
pm.process(app.project);
|
|
70
|
+
|
|
71
|
+
return __result({
|
|
72
|
+
started: true,
|
|
73
|
+
destination: "${escapeForExtendScript(args.destination_path)}"
|
|
74
|
+
});
|
|
75
75
|
`);
|
|
76
76
|
return sendCommand(script, { ...bridgeOptions, timeoutMs: 300000 }); // 5 min timeout
|
|
77
77
|
},
|