premiere-pro-mcp 1.0.0 → 1.1.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/README.md CHANGED
@@ -8,7 +8,9 @@
8
8
 
9
9
  [![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](LICENSE)
10
10
  [![Node.js](https://img.shields.io/badge/Node.js-18%2B-green.svg)](https://nodejs.org)
11
- [![MCP](https://img.shields.io/badge/MCP-1.12-purple.svg)](https://modelcontextprotocol.io)
11
+ [![MCP](https://img.shields.io/badge/MCP-1.27-purple.svg)](https://modelcontextprotocol.io)
12
+ [![npm](https://img.shields.io/npm/v/premiere-pro-mcp.svg)](https://www.npmjs.com/package/premiere-pro-mcp)
13
+ [![Fly.io](https://img.shields.io/badge/Fly.io-deployed-7C3AED.svg)](https://premiere-pro-mcp.fly.dev)
12
14
  [![Premiere Pro](https://img.shields.io/badge/Premiere%20Pro-2020--2025%2B-9999FF.svg)](https://www.adobe.com/products/premiere.html)
13
15
 
14
16
  </div>
@@ -162,6 +164,7 @@ Add to `.cursor/mcp.json` in your project or global config:
162
164
 
163
165
  ## Architecture
164
166
 
167
+ **Local (stdio):**
165
168
  ```
166
169
  ┌───────────────┐ stdio (MCP) ┌──────────────┐ File-based IPC ┌──────────────┐
167
170
  │ AI Client │ ◄──────────────► │ MCP Server │ ◄────────────────► │ CEP Plugin │
@@ -177,6 +180,15 @@ Add to `.cursor/mcp.json` in your project or global config:
177
180
  └──────────────┘
178
181
  ```
179
182
 
183
+ **Remote (HTTP/SSE — Fly.io):**
184
+ ```
185
+ ┌───────────────┐ HTTP+SSE (MCP) ┌─────────────────────┐ File-based IPC ┌──────────────┐
186
+ │ AI Client │ ◄───────────────► │ MCP Server │ ◄────────────────► │ CEP Plugin │
187
+ │ (any MCP │ │ premiere-pro-mcp │ .jsx / .json │ (Premiere) │
188
+ │ client) │ │ .fly.dev │ shared volume └──────────────┘
189
+ └───────────────┘ └─────────────────────┘
190
+ ```
191
+
180
192
  1. AI client invokes an MCP tool (e.g., `add_to_timeline`)
181
193
  2. MCP server generates ES3-compatible ExtendScript with helper functions prepended
182
194
  3. Script is written to a `.jsx` command file in a shared temp directory
@@ -332,12 +344,63 @@ These are automatically available to MCP clients that support resources, giving
332
344
 
333
345
  ---
334
346
 
347
+ ## Remote Deployment (Fly.io)
348
+
349
+ The server includes an HTTP/SSE transport (`src/http-server.ts`) for remote access via [mcp-remote](https://github.com/geelen/mcp-remote) or any MCP client that supports Streamable HTTP.
350
+
351
+ A live instance is running at **https://premiere-pro-mcp.fly.dev**.
352
+
353
+ ### Connect via mcp-remote
354
+
355
+ ```json
356
+ {
357
+ "mcpServers": {
358
+ "premiere-pro": {
359
+ "command": "npx",
360
+ "args": ["mcp-remote", "https://premiere-pro-mcp.fly.dev/mcp"]
361
+ }
362
+ }
363
+ }
364
+ ```
365
+
366
+ ### Self-host on Fly.io
367
+
368
+ ```bash
369
+ # Clone and deploy your own instance
370
+ git clone https://github.com/ppmcp/premiere-pro-mcp.git
371
+ cd premiere-pro-mcp
372
+ fly apps create your-app-name
373
+ fly deploy --remote-only
374
+
375
+ # Optional: add bearer token auth
376
+ fly secrets set MCP_AUTH_TOKEN=your-secret-token
377
+ ```
378
+
379
+ Then connect with:
380
+ ```json
381
+ {
382
+ "mcpServers": {
383
+ "premiere-pro": {
384
+ "command": "npx",
385
+ "args": ["mcp-remote", "https://your-app-name.fly.dev/mcp",
386
+ "--header", "Authorization: Bearer your-secret-token"]
387
+ }
388
+ }
389
+ }
390
+ ```
391
+
392
+ > **Note:** The file bridge still requires the CEP plugin to share the same `PREMIERE_TEMP_DIR`. For cloud deployments this means running a sync agent or using `fly proxy` / WireGuard to reach your local machine.
393
+
394
+ ---
395
+
335
396
  ## Environment Variables
336
397
 
337
398
  | Variable | Description | Default |
338
- |----------|-------------|---------|
399
+ |----------|-------------|--------|
339
400
  | `PREMIERE_TEMP_DIR` | Shared temp directory for MCP ↔ CEP communication | OS temp dir + `/premiere-mcp-bridge` |
340
401
  | `PREMIERE_TIMEOUT_MS` | Command timeout in milliseconds | `30000` |
402
+ | `PORT` | HTTP port (HTTP/SSE transport only) | `3000` |
403
+ | `MCP_AUTH_TOKEN` | Bearer token for HTTP transport auth (optional) | unset |
341
404
 
342
405
  ---
343
406
 
@@ -347,6 +410,7 @@ These are automatically available to MCP clients that support resources, giving
347
410
  premiere-pro-mcp/
348
411
  ├── src/
349
412
  │ ├── index.ts # Entry point — stdio transport setup
413
+ │ ├── http-server.ts # Entry point — HTTP/SSE transport (Fly.io / remote)
350
414
  │ ├── server.ts # MCP server — registers all 269 tools + 2 resources
351
415
  │ ├── bridge/
352
416
  │ │ ├── file-bridge.ts # File-based IPC (write .jsx, poll .json)
@@ -390,6 +454,8 @@ premiere-pro-mcp/
390
454
  │ └── CSInterface.js # Adobe CEP interface library
391
455
  ├── scripts/
392
456
  │ └── install-cep.sh # CEP plugin installer (symlink + debug mode)
457
+ ├── Dockerfile # Multi-stage Docker build for Fly.io
458
+ ├── fly.toml # Fly.io deployment config
393
459
  ├── RESEARCH.md # API research and implementation status
394
460
  ├── CONTRIBUTING.md # Contribution guidelines
395
461
  ├── CHANGELOG.md # Version history
@@ -0,0 +1,21 @@
1
+ #!/usr/bin/env node
2
+ /**
3
+ * HTTP/SSE transport entry point for remote deployment (e.g. Fly.io).
4
+ *
5
+ * The MCP server is identical to the stdio version — only the transport differs.
6
+ * Clients connect via the MCP Streamable HTTP transport:
7
+ * POST /mcp — send JSON-RPC messages
8
+ * GET /mcp — open SSE stream
9
+ *
10
+ * The bridge still uses the local filesystem temp directory, so the CEP plugin
11
+ * must be reachable from the same machine OR you must set PREMIERE_TEMP_DIR to
12
+ * a shared volume mount that the CEP plugin also writes to.
13
+ *
14
+ * Environment variables:
15
+ * PORT HTTP port to listen on (default: 3000)
16
+ * PREMIERE_TEMP_DIR Shared temp directory for the file bridge
17
+ * PREMIERE_TIMEOUT_MS Command timeout in ms (default: 30000)
18
+ * MCP_AUTH_TOKEN Optional bearer token to require on all requests
19
+ */
20
+ export {};
21
+ //# sourceMappingURL=http-server.d.ts.map
@@ -0,0 +1,98 @@
1
+ #!/usr/bin/env node
2
+ /**
3
+ * HTTP/SSE transport entry point for remote deployment (e.g. Fly.io).
4
+ *
5
+ * The MCP server is identical to the stdio version — only the transport differs.
6
+ * Clients connect via the MCP Streamable HTTP transport:
7
+ * POST /mcp — send JSON-RPC messages
8
+ * GET /mcp — open SSE stream
9
+ *
10
+ * The bridge still uses the local filesystem temp directory, so the CEP plugin
11
+ * must be reachable from the same machine OR you must set PREMIERE_TEMP_DIR to
12
+ * a shared volume mount that the CEP plugin also writes to.
13
+ *
14
+ * Environment variables:
15
+ * PORT HTTP port to listen on (default: 3000)
16
+ * PREMIERE_TEMP_DIR Shared temp directory for the file bridge
17
+ * PREMIERE_TIMEOUT_MS Command timeout in ms (default: 30000)
18
+ * MCP_AUTH_TOKEN Optional bearer token to require on all requests
19
+ */
20
+ import http from "node:http";
21
+ import { StreamableHTTPServerTransport } from "@modelcontextprotocol/sdk/server/streamableHttp.js";
22
+ import { createServer } from "./server.js";
23
+ import { cleanupTempDir, getTempDir } from "./bridge/file-bridge.js";
24
+ const PORT = parseInt(process.env.PORT ?? "3000", 10);
25
+ const AUTH_TOKEN = process.env.MCP_AUTH_TOKEN;
26
+ const bridgeOptions = {
27
+ tempDir: process.env.PREMIERE_TEMP_DIR,
28
+ timeoutMs: process.env.PREMIERE_TIMEOUT_MS
29
+ ? parseInt(process.env.PREMIERE_TIMEOUT_MS, 10)
30
+ : undefined,
31
+ };
32
+ const tempDir = getTempDir(bridgeOptions);
33
+ console.error(`[premiere-pro-mcp] Starting HTTP server on port ${PORT}...`);
34
+ console.error(`[premiere-pro-mcp] Temp directory: ${tempDir}`);
35
+ cleanupTempDir(bridgeOptions);
36
+ // Each request gets its own transport+server instance (stateless per-request model)
37
+ const httpServer = http.createServer(async (req, res) => {
38
+ // Health check
39
+ if (req.method === "GET" && req.url === "/health") {
40
+ res.writeHead(200, { "Content-Type": "application/json" });
41
+ res.end(JSON.stringify({ status: "ok", service: "premiere-pro-mcp" }));
42
+ return;
43
+ }
44
+ // Only handle /mcp endpoint
45
+ if (!req.url?.startsWith("/mcp")) {
46
+ res.writeHead(404);
47
+ res.end("Not found");
48
+ return;
49
+ }
50
+ // Optional bearer token auth
51
+ if (AUTH_TOKEN) {
52
+ const authHeader = req.headers["authorization"] ?? "";
53
+ const provided = authHeader.startsWith("Bearer ") ? authHeader.slice(7) : "";
54
+ if (provided !== AUTH_TOKEN) {
55
+ res.writeHead(401, { "Content-Type": "application/json" });
56
+ res.end(JSON.stringify({ error: "Unauthorized" }));
57
+ return;
58
+ }
59
+ }
60
+ const mcpServer = createServer(bridgeOptions);
61
+ const transport = new StreamableHTTPServerTransport({
62
+ sessionIdGenerator: undefined, // stateless
63
+ });
64
+ res.on("close", () => {
65
+ transport.close().catch(() => { });
66
+ mcpServer.close().catch(() => { });
67
+ });
68
+ try {
69
+ await mcpServer.connect(transport);
70
+ await transport.handleRequest(req, res);
71
+ }
72
+ catch (err) {
73
+ console.error("[premiere-pro-mcp] Request error:", err);
74
+ if (!res.headersSent) {
75
+ res.writeHead(500, { "Content-Type": "application/json" });
76
+ res.end(JSON.stringify({ error: "Internal server error" }));
77
+ }
78
+ }
79
+ });
80
+ httpServer.listen(PORT, "0.0.0.0", () => {
81
+ console.error(`[premiere-pro-mcp] HTTP server listening on 0.0.0.0:${PORT}`);
82
+ console.error(`[premiere-pro-mcp] MCP endpoint: http://0.0.0.0:${PORT}/mcp`);
83
+ if (AUTH_TOKEN) {
84
+ console.error(`[premiere-pro-mcp] Auth: Bearer token required`);
85
+ }
86
+ else {
87
+ console.error(`[premiere-pro-mcp] Auth: none (set MCP_AUTH_TOKEN to enable)`);
88
+ }
89
+ });
90
+ process.on("SIGTERM", () => {
91
+ console.error("[premiere-pro-mcp] SIGTERM received, shutting down...");
92
+ httpServer.close(() => process.exit(0));
93
+ });
94
+ process.on("SIGINT", () => {
95
+ console.error("[premiere-pro-mcp] SIGINT received, shutting down...");
96
+ httpServer.close(() => process.exit(0));
97
+ });
98
+ //# sourceMappingURL=http-server.js.map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "premiere-pro-mcp",
3
- "version": "1.0.0",
3
+ "version": "1.1.0",
4
4
  "description": "MCP server for controlling Adobe Premiere Pro via CEP/ExtendScript — 269 tools for AI-driven video editing",
5
5
  "main": "dist/index.js",
6
6
  "type": "module",
@@ -20,6 +20,10 @@
20
20
  "build": "tsc",
21
21
  "dev": "tsc --watch",
22
22
  "start": "node dist/index.js",
23
+ "start:http": "node dist/http-server.js",
24
+ "test": "vitest run",
25
+ "test:watch": "vitest",
26
+ "test:coverage": "vitest run --coverage",
23
27
  "install-cep": "bash scripts/install-cep.sh"
24
28
  },
25
29
  "repository": {
@@ -55,6 +59,7 @@
55
59
  },
56
60
  "devDependencies": {
57
61
  "@types/node": "^22.10.0",
58
- "typescript": "^5.7.0"
62
+ "typescript": "^5.7.0",
63
+ "vitest": "^4.0.18"
59
64
  }
60
65
  }
@@ -0,0 +1,210 @@
1
+ #!/usr/bin/env bash
2
+ # Build a macOS DMG for the Premiere Pro AI Chat plugin.
3
+ # The DMG contains the plugin folder + an installer script.
4
+
5
+ set -e
6
+
7
+ SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
8
+ PROJECT_ROOT="$(dirname "$SCRIPT_DIR")"
9
+ PLUGIN_SRC="$PROJECT_ROOT/chat-plugin"
10
+ BUILD_DIR="$PROJECT_ROOT/build"
11
+ DMG_NAME="Premiere-Pro-AI-Chat"
12
+ DMG_VOLUME="Premiere Pro AI Chat"
13
+ VERSION="1.0.0"
14
+
15
+ echo "========================================"
16
+ echo " Building DMG: $DMG_NAME v$VERSION"
17
+ echo "========================================"
18
+ echo ""
19
+
20
+ # Clean previous DMG staging (preserve other build artifacts)
21
+ rm -rf "$BUILD_DIR/dmg-staging"
22
+ mkdir -p "$BUILD_DIR/dmg-staging"
23
+
24
+ STAGING="$BUILD_DIR/dmg-staging"
25
+
26
+ # ---- Copy plugin files ----
27
+ echo "Copying plugin files..."
28
+ mkdir -p "$STAGING/Premiere Pro AI Chat.cep"
29
+ cp -R "$PLUGIN_SRC/"* "$STAGING/Premiere Pro AI Chat.cep/"
30
+ echo "✓ Plugin files copied"
31
+
32
+ # ---- Create installer script inside DMG ----
33
+ cat > "$STAGING/Install Plugin.command" << 'INSTALLER_EOF'
34
+ #!/usr/bin/env bash
35
+ # Premiere Pro AI Chat — One-click Installer
36
+
37
+ set -e
38
+
39
+ SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
40
+ PLUGIN_NAME="com.ppro.ai.chat"
41
+ PLUGIN_SRC="$SCRIPT_DIR/Premiere Pro AI Chat.cep"
42
+ CEP_DIR="$HOME/Library/Application Support/Adobe/CEP/extensions"
43
+
44
+ echo ""
45
+ echo "╔══════════════════════════════════════════╗"
46
+ echo "║ Premiere Pro AI Chat — Installer ║"
47
+ echo "╚══════════════════════════════════════════╝"
48
+ echo ""
49
+
50
+ # Verify source
51
+ if [ ! -d "$PLUGIN_SRC" ]; then
52
+ echo "✗ Error: Plugin files not found."
53
+ echo " Make sure you're running this from the DMG."
54
+ exit 1
55
+ fi
56
+
57
+ # Create CEP directory
58
+ mkdir -p "$CEP_DIR"
59
+
60
+ # Remove old installation
61
+ if [ -d "$CEP_DIR/$PLUGIN_NAME" ] || [ -L "$CEP_DIR/$PLUGIN_NAME" ]; then
62
+ echo "Removing previous installation..."
63
+ rm -rf "$CEP_DIR/$PLUGIN_NAME"
64
+ fi
65
+
66
+ # Copy plugin
67
+ echo "Installing plugin..."
68
+ cp -R "$PLUGIN_SRC" "$CEP_DIR/$PLUGIN_NAME"
69
+ echo "✓ Plugin installed to: $CEP_DIR/$PLUGIN_NAME"
70
+
71
+ # Enable unsigned extensions
72
+ echo "Enabling unsigned CEP extensions..."
73
+ for ver in 9 10 11 12; do
74
+ defaults write com.adobe.CSXS.$ver PlayerDebugMode 1 2>/dev/null || true
75
+ done
76
+ echo "✓ Debug mode enabled"
77
+
78
+ echo ""
79
+ echo "════════════════════════════════════════════"
80
+ echo " ✓ Installation complete!"
81
+ echo ""
82
+ echo " Next steps:"
83
+ echo " 1. Restart Premiere Pro (if running)"
84
+ echo " 2. Go to: Window → Extensions → AI Chat"
85
+ echo " 3. Enter your Claude or Gemini API key"
86
+ echo " 4. Start chatting!"
87
+ echo "════════════════════════════════════════════"
88
+ echo ""
89
+ echo "Press any key to close..."
90
+ read -n 1 -s
91
+ INSTALLER_EOF
92
+
93
+ chmod +x "$STAGING/Install Plugin.command"
94
+ echo "✓ Installer script created"
95
+
96
+ # ---- Create README ----
97
+ cat > "$STAGING/README.txt" << 'README_EOF'
98
+ Premiere Pro AI Chat Plugin
99
+ ============================
100
+
101
+ An embedded AI chat panel for Adobe Premiere Pro.
102
+ Control your edits with natural language using Claude or Gemini.
103
+
104
+ INSTALLATION
105
+ ============
106
+
107
+ Option 1: Double-click "Install Plugin.command"
108
+ - This will copy the plugin to your Adobe CEP extensions folder
109
+ - It will enable unsigned extensions automatically
110
+
111
+ Option 2: Manual Install
112
+ - Copy the "Premiere Pro AI Chat.cep" folder to:
113
+ ~/Library/Application Support/Adobe/CEP/extensions/com.ppro.ai.chat
114
+ - Enable unsigned extensions by running in Terminal:
115
+ defaults write com.adobe.CSXS.11 PlayerDebugMode 1
116
+
117
+ USAGE
118
+ =====
119
+
120
+ 1. Open Premiere Pro
121
+ 2. Go to: Window → Extensions → AI Chat
122
+ 3. Choose Claude or Gemini as your AI provider
123
+ 4. Enter your API key
124
+ 5. Start chatting! The AI can:
125
+ - Query your project (clips, sequences, tracks)
126
+ - Edit your timeline (add clips, effects, transitions)
127
+ - Export sequences
128
+ - And much more
129
+
130
+ REQUIREMENTS
131
+ ============
132
+
133
+ - macOS 10.14+
134
+ - Adobe Premiere Pro 2020 (v14.0) or later
135
+ - Claude API key (console.anthropic.com) or
136
+ Gemini API key (aistudio.google.com)
137
+
138
+ SUPPORT
139
+ =======
140
+
141
+ GitHub: https://github.com/ppmcp/premiere-pro-mcp
142
+ Issues: https://github.com/ppmcp/premiere-pro-mcp/issues
143
+ README_EOF
144
+
145
+ echo "✓ README created"
146
+
147
+ # ---- Create Uninstaller ----
148
+ cat > "$STAGING/Uninstall Plugin.command" << 'UNINSTALL_EOF'
149
+ #!/usr/bin/env bash
150
+ set -e
151
+
152
+ PLUGIN_NAME="com.ppro.ai.chat"
153
+ CEP_DIR="$HOME/Library/Application Support/Adobe/CEP/extensions"
154
+
155
+ echo ""
156
+ echo "Uninstalling Premiere Pro AI Chat..."
157
+
158
+ if [ -d "$CEP_DIR/$PLUGIN_NAME" ] || [ -L "$CEP_DIR/$PLUGIN_NAME" ]; then
159
+ rm -rf "$CEP_DIR/$PLUGIN_NAME"
160
+ echo "✓ Plugin removed."
161
+ else
162
+ echo "Plugin not found — nothing to remove."
163
+ fi
164
+
165
+ echo ""
166
+ echo "Press any key to close..."
167
+ read -n 1 -s
168
+ UNINSTALL_EOF
169
+
170
+ chmod +x "$STAGING/Uninstall Plugin.command"
171
+ echo "✓ Uninstaller created"
172
+
173
+ # ---- Build DMG ----
174
+ echo ""
175
+ echo "Building DMG..."
176
+
177
+ DMG_PATH="$BUILD_DIR/$DMG_NAME-v$VERSION.dmg"
178
+ TEMP_DMG="$BUILD_DIR/temp.dmg"
179
+
180
+ # Create a temporary DMG
181
+ hdiutil create -srcfolder "$STAGING" \
182
+ -volname "$DMG_VOLUME" \
183
+ -format UDRW \
184
+ -fs HFS+ \
185
+ -size 20m \
186
+ "$TEMP_DMG" \
187
+ -quiet
188
+
189
+ # Convert to compressed read-only DMG
190
+ hdiutil convert "$TEMP_DMG" \
191
+ -format UDZO \
192
+ -imagekey zlib-level=9 \
193
+ -o "$DMG_PATH" \
194
+ -quiet
195
+
196
+ rm -f "$TEMP_DMG"
197
+
198
+ echo "✓ DMG built: $DMG_PATH"
199
+
200
+ # Get file size
201
+ DMG_SIZE=$(du -h "$DMG_PATH" | cut -f1 | xargs)
202
+
203
+ echo ""
204
+ echo "========================================"
205
+ echo " ✓ Build complete!"
206
+ echo ""
207
+ echo " File: $DMG_PATH"
208
+ echo " Size: $DMG_SIZE"
209
+ echo "========================================"
210
+ echo ""
@@ -0,0 +1,291 @@
1
+ #!/usr/bin/env bash
2
+ # Build a cross-platform ZIP for the Premiere Pro AI Chat plugin.
3
+ # The ZIP contains the plugin folder + installers for macOS and Windows.
4
+
5
+ set -e
6
+
7
+ SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
8
+ PROJECT_ROOT="$(dirname "$SCRIPT_DIR")"
9
+ PLUGIN_SRC="$PROJECT_ROOT/chat-plugin"
10
+ BUILD_DIR="$PROJECT_ROOT/build"
11
+ ZIP_NAME="Premiere-Pro-AI-Chat"
12
+ VERSION="1.0.0"
13
+
14
+ echo "========================================"
15
+ echo " Building ZIP: $ZIP_NAME v$VERSION"
16
+ echo "========================================"
17
+ echo ""
18
+
19
+ # Clean previous build
20
+ rm -rf "$BUILD_DIR/zip-staging"
21
+ mkdir -p "$BUILD_DIR/zip-staging"
22
+
23
+ STAGING="$BUILD_DIR/zip-staging/$ZIP_NAME-v$VERSION"
24
+ mkdir -p "$STAGING"
25
+
26
+ # ---- Copy plugin files ----
27
+ echo "Copying plugin files..."
28
+ mkdir -p "$STAGING/com.ppro.ai.chat"
29
+ cp -R "$PLUGIN_SRC/"* "$STAGING/com.ppro.ai.chat/"
30
+ echo "✓ Plugin files copied"
31
+
32
+ # ---- Create Windows installer (.bat) ----
33
+ cat > "$STAGING/Install-Windows.bat" << 'BAT_EOF'
34
+ @echo off
35
+ REM Premiere Pro AI Chat — Windows Installer
36
+
37
+ setlocal enabledelayedexpansion
38
+
39
+ echo.
40
+ echo ==========================================
41
+ echo Premiere Pro AI Chat - Windows Installer
42
+ echo ==========================================
43
+ echo.
44
+
45
+ set "SCRIPT_DIR=%~dp0"
46
+ set "PLUGIN_SRC=%SCRIPT_DIR%com.ppro.ai.chat"
47
+ set "PLUGIN_NAME=com.ppro.ai.chat"
48
+ set "CEP_DIR=%APPDATA%\Adobe\CEP\extensions"
49
+
50
+ if not exist "%PLUGIN_SRC%" (
51
+ echo [ERROR] Plugin files not found.
52
+ echo Make sure you extracted the ZIP first.
53
+ pause
54
+ exit /b 1
55
+ )
56
+
57
+ REM Create CEP directory
58
+ if not exist "%CEP_DIR%" mkdir "%CEP_DIR%"
59
+
60
+ REM Remove old installation
61
+ if exist "%CEP_DIR%\%PLUGIN_NAME%" (
62
+ echo Removing previous installation...
63
+ rmdir /s /q "%CEP_DIR%\%PLUGIN_NAME%"
64
+ )
65
+
66
+ REM Copy plugin
67
+ echo Installing plugin...
68
+ xcopy /s /e /i /q "%PLUGIN_SRC%" "%CEP_DIR%\%PLUGIN_NAME%"
69
+ echo [OK] Plugin installed to: %CEP_DIR%\%PLUGIN_NAME%
70
+
71
+ REM Enable unsigned extensions (CSXS 9-12)
72
+ echo Enabling unsigned CEP extensions...
73
+ for %%v in (9 10 11 12) do (
74
+ reg add "HKCU\SOFTWARE\Adobe\CSXS.%%v" /v PlayerDebugMode /t REG_SZ /d 1 /f >nul 2>&1
75
+ )
76
+ echo [OK] Debug mode enabled
77
+
78
+ echo.
79
+ echo ==========================================
80
+ echo [OK] Installation complete!
81
+ echo.
82
+ echo Next steps:
83
+ echo 1. Restart Premiere Pro (if running)
84
+ echo 2. Go to: Window ^> Extensions ^> AI Chat
85
+ echo 3. Enter your Claude or Gemini API key
86
+ echo 4. Start chatting!
87
+ echo ==========================================
88
+ echo.
89
+ pause
90
+ BAT_EOF
91
+
92
+ echo "✓ Windows installer created"
93
+
94
+ # ---- Create Windows uninstaller (.bat) ----
95
+ cat > "$STAGING/Uninstall-Windows.bat" << 'UNBAT_EOF'
96
+ @echo off
97
+ REM Premiere Pro AI Chat — Windows Uninstaller
98
+
99
+ set "PLUGIN_NAME=com.ppro.ai.chat"
100
+ set "CEP_DIR=%APPDATA%\Adobe\CEP\extensions"
101
+
102
+ echo.
103
+ echo Uninstalling Premiere Pro AI Chat...
104
+
105
+ if exist "%CEP_DIR%\%PLUGIN_NAME%" (
106
+ rmdir /s /q "%CEP_DIR%\%PLUGIN_NAME%"
107
+ echo [OK] Plugin removed.
108
+ ) else (
109
+ echo Plugin not found - nothing to remove.
110
+ )
111
+
112
+ echo.
113
+ pause
114
+ UNBAT_EOF
115
+
116
+ echo "✓ Windows uninstaller created"
117
+
118
+ # ---- Create macOS installer (.command) ----
119
+ cat > "$STAGING/Install-macOS.command" << 'MAC_EOF'
120
+ #!/usr/bin/env bash
121
+ # Premiere Pro AI Chat — macOS Installer
122
+
123
+ set -e
124
+
125
+ SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
126
+ PLUGIN_NAME="com.ppro.ai.chat"
127
+ PLUGIN_SRC="$SCRIPT_DIR/com.ppro.ai.chat"
128
+ CEP_DIR="$HOME/Library/Application Support/Adobe/CEP/extensions"
129
+
130
+ echo ""
131
+ echo "╔══════════════════════════════════════════╗"
132
+ echo "║ Premiere Pro AI Chat — Installer ║"
133
+ echo "╚══════════════════════════════════════════╝"
134
+ echo ""
135
+
136
+ if [ ! -d "$PLUGIN_SRC" ]; then
137
+ echo "✗ Error: Plugin files not found."
138
+ exit 1
139
+ fi
140
+
141
+ mkdir -p "$CEP_DIR"
142
+
143
+ if [ -d "$CEP_DIR/$PLUGIN_NAME" ] || [ -L "$CEP_DIR/$PLUGIN_NAME" ]; then
144
+ echo "Removing previous installation..."
145
+ rm -rf "$CEP_DIR/$PLUGIN_NAME"
146
+ fi
147
+
148
+ echo "Installing plugin..."
149
+ cp -R "$PLUGIN_SRC" "$CEP_DIR/$PLUGIN_NAME"
150
+ echo "✓ Plugin installed to: $CEP_DIR/$PLUGIN_NAME"
151
+
152
+ echo "Enabling unsigned CEP extensions..."
153
+ for ver in 9 10 11 12; do
154
+ defaults write com.adobe.CSXS.$ver PlayerDebugMode 1 2>/dev/null || true
155
+ done
156
+ echo "✓ Debug mode enabled"
157
+
158
+ echo ""
159
+ echo "════════════════════════════════════════════"
160
+ echo " ✓ Installation complete!"
161
+ echo ""
162
+ echo " Next steps:"
163
+ echo " 1. Restart Premiere Pro (if running)"
164
+ echo " 2. Go to: Window → Extensions → AI Chat"
165
+ echo " 3. Enter your Claude or Gemini API key"
166
+ echo " 4. Start chatting!"
167
+ echo "════════════════════════════════════════════"
168
+ echo ""
169
+ echo "Press any key to close..."
170
+ read -n 1 -s
171
+ MAC_EOF
172
+
173
+ chmod +x "$STAGING/Install-macOS.command"
174
+ echo "✓ macOS installer created"
175
+
176
+ # ---- Create macOS uninstaller ----
177
+ cat > "$STAGING/Uninstall-macOS.command" << 'UNMAC_EOF'
178
+ #!/usr/bin/env bash
179
+ set -e
180
+
181
+ PLUGIN_NAME="com.ppro.ai.chat"
182
+ CEP_DIR="$HOME/Library/Application Support/Adobe/CEP/extensions"
183
+
184
+ echo ""
185
+ echo "Uninstalling Premiere Pro AI Chat..."
186
+
187
+ if [ -d "$CEP_DIR/$PLUGIN_NAME" ] || [ -L "$CEP_DIR/$PLUGIN_NAME" ]; then
188
+ rm -rf "$CEP_DIR/$PLUGIN_NAME"
189
+ echo "✓ Plugin removed."
190
+ else
191
+ echo "Plugin not found — nothing to remove."
192
+ fi
193
+
194
+ echo ""
195
+ echo "Press any key to close..."
196
+ read -n 1 -s
197
+ UNMAC_EOF
198
+
199
+ chmod +x "$STAGING/Uninstall-macOS.command"
200
+ echo "✓ macOS uninstaller created"
201
+
202
+ # ---- Create README ----
203
+ cat > "$STAGING/README.txt" << 'README_EOF'
204
+ Premiere Pro AI Chat Plugin
205
+ ============================
206
+
207
+ An embedded AI chat panel for Adobe Premiere Pro.
208
+ Control your edits with natural language using Claude or Gemini.
209
+
210
+ INSTALLATION
211
+ ============
212
+
213
+ Windows:
214
+ 1. Extract this ZIP file
215
+ 2. Right-click "Install-Windows.bat" → Run as administrator
216
+ 3. Restart Premiere Pro
217
+ 4. Go to: Window → Extensions → AI Chat
218
+
219
+ macOS:
220
+ 1. Extract this ZIP file
221
+ 2. Double-click "Install-macOS.command"
222
+ 3. Restart Premiere Pro
223
+ 4. Go to: Window → Extensions → AI Chat
224
+
225
+ Manual Install (any OS):
226
+ - Copy the "com.ppro.ai.chat" folder to your CEP extensions folder:
227
+ Windows: %APPDATA%\Adobe\CEP\extensions\
228
+ macOS: ~/Library/Application Support/Adobe/CEP/extensions/
229
+ - Enable unsigned extensions:
230
+ Windows: Set registry key HKCU\SOFTWARE\Adobe\CSXS.11 → PlayerDebugMode = "1"
231
+ macOS: Run: defaults write com.adobe.CSXS.11 PlayerDebugMode 1
232
+
233
+ UNINSTALL
234
+ =========
235
+
236
+ Windows: Run "Uninstall-Windows.bat"
237
+ macOS: Double-click "Uninstall-macOS.command"
238
+
239
+ USAGE
240
+ =====
241
+
242
+ 1. Open Premiere Pro
243
+ 2. Go to: Window → Extensions → AI Chat
244
+ 3. Choose Claude or Gemini as your AI provider
245
+ 4. Enter your API key
246
+ 5. Start chatting! The AI can:
247
+ - Query your project (clips, sequences, tracks)
248
+ - Edit your timeline (add clips, effects, transitions)
249
+ - Export sequences
250
+ - And much more
251
+
252
+ REQUIREMENTS
253
+ ============
254
+
255
+ - Windows 10+ or macOS 10.14+
256
+ - Adobe Premiere Pro 2020 (v14.0) or later
257
+ - Claude API key (console.anthropic.com) or
258
+ Gemini API key (aistudio.google.com)
259
+
260
+ SUPPORT
261
+ =======
262
+
263
+ GitHub: https://github.com/ppmcp/premiere-pro-mcp
264
+ Issues: https://github.com/ppmcp/premiere-pro-mcp/issues
265
+ README_EOF
266
+
267
+ echo "✓ README created"
268
+
269
+ # ---- Build ZIP ----
270
+ echo ""
271
+ echo "Building ZIP..."
272
+
273
+ ZIP_PATH="$BUILD_DIR/$ZIP_NAME-v$VERSION.zip"
274
+ rm -f "$ZIP_PATH"
275
+
276
+ cd "$BUILD_DIR/zip-staging"
277
+ zip -r -q "$ZIP_PATH" "$ZIP_NAME-v$VERSION/"
278
+
279
+ ZIP_SIZE=$(du -h "$ZIP_PATH" | cut -f1 | xargs)
280
+
281
+ echo "✓ ZIP built: $ZIP_PATH"
282
+
283
+ echo ""
284
+ echo "========================================"
285
+ echo " ✓ Build complete!"
286
+ echo ""
287
+ echo " File: $ZIP_PATH"
288
+ echo " Size: $ZIP_SIZE"
289
+ echo " Works on: macOS + Windows"
290
+ echo "========================================"
291
+ echo ""
@@ -0,0 +1,67 @@
1
+ @echo off
2
+ REM Premiere Pro AI Chat — Windows Installer
3
+ REM Copies the plugin to the Adobe CEP extensions folder
4
+ REM and enables unsigned extensions via registry.
5
+
6
+ setlocal enabledelayedexpansion
7
+
8
+ echo ========================================
9
+ echo Premiere Pro AI Chat — Plugin Installer
10
+ echo ========================================
11
+ echo.
12
+
13
+ REM Resolve paths
14
+ set "SCRIPT_DIR=%~dp0"
15
+ set "PROJECT_ROOT=%SCRIPT_DIR%.."
16
+ set "PLUGIN_SRC=%PROJECT_ROOT%\chat-plugin"
17
+ set "PLUGIN_NAME=com.ppro.ai.chat"
18
+ set "CEP_DIR=%APPDATA%\Adobe\CEP\extensions"
19
+
20
+ echo Plugin source: %PLUGIN_SRC%
21
+ echo CEP target: %CEP_DIR%\%PLUGIN_NAME%
22
+ echo.
23
+
24
+ REM Verify source exists
25
+ if not exist "%PLUGIN_SRC%" (
26
+ echo [ERROR] Plugin source not found at %PLUGIN_SRC%
27
+ pause
28
+ exit /b 1
29
+ )
30
+
31
+ REM Create CEP extensions directory if needed
32
+ if not exist "%CEP_DIR%" (
33
+ echo Creating CEP extensions directory...
34
+ mkdir "%CEP_DIR%"
35
+ )
36
+
37
+ REM Remove existing installation
38
+ if exist "%CEP_DIR%\%PLUGIN_NAME%" (
39
+ echo Removing existing installation...
40
+ rmdir /s /q "%CEP_DIR%\%PLUGIN_NAME%"
41
+ )
42
+
43
+ REM Copy plugin
44
+ echo Installing plugin...
45
+ xcopy /s /e /i /q "%PLUGIN_SRC%" "%CEP_DIR%\%PLUGIN_NAME%"
46
+ echo [OK] Plugin installed
47
+
48
+ REM Enable unsigned extensions (CSXS 9-12)
49
+ echo.
50
+ echo Enabling unsigned CEP extensions...
51
+ for %%v in (9 10 11 12) do (
52
+ reg add "HKCU\SOFTWARE\Adobe\CSXS.%%v" /v PlayerDebugMode /t REG_SZ /d 1 /f >nul 2>&1
53
+ )
54
+ echo [OK] Debug mode enabled (CSXS 9-12)
55
+
56
+ echo.
57
+ echo ========================================
58
+ echo [OK] Installation complete!
59
+ echo ========================================
60
+ echo.
61
+ echo Next steps:
62
+ echo 1. Restart Premiere Pro (if running)
63
+ echo 2. Open: Window ^> Extensions ^> AI Chat
64
+ echo 3. Enter your Claude or Gemini API key
65
+ echo 4. Start chatting to control Premiere Pro!
66
+ echo.
67
+ pause
@@ -0,0 +1,85 @@
1
+ #!/usr/bin/env bash
2
+ # Install the Premiere Pro AI Chat CEP plugin
3
+ # Creates a symlink (or copies) from the chat-plugin/ directory
4
+ # into the Adobe CEP extensions folder.
5
+
6
+ set -e
7
+
8
+ PLUGIN_NAME="com.ppro.ai.chat"
9
+ SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
10
+ PROJECT_ROOT="$(dirname "$SCRIPT_DIR")"
11
+ PLUGIN_SRC="$PROJECT_ROOT/chat-plugin"
12
+
13
+ echo "========================================"
14
+ echo " Premiere Pro AI Chat — Plugin Installer"
15
+ echo "========================================"
16
+ echo ""
17
+
18
+ # Detect OS
19
+ if [[ "$OSTYPE" == "darwin"* ]]; then
20
+ CEP_DIR="$HOME/Library/Application Support/Adobe/CEP/extensions"
21
+ elif [[ "$OSTYPE" == "linux-gnu"* ]]; then
22
+ CEP_DIR="$HOME/.config/Adobe/CEP/extensions"
23
+ else
24
+ echo "⚠ Windows detected. Please manually copy:"
25
+ echo " From: $PLUGIN_SRC"
26
+ echo " To: %APPDATA%\\Adobe\\CEP\\extensions\\$PLUGIN_NAME"
27
+ echo ""
28
+ echo "Then set registry key to enable unsigned extensions:"
29
+ echo ' HKEY_CURRENT_USER\SOFTWARE\Adobe\CSXS.11'
30
+ echo ' PlayerDebugMode = "1" (String)'
31
+ exit 0
32
+ fi
33
+
34
+ echo "Plugin source: $PLUGIN_SRC"
35
+ echo "CEP target: $CEP_DIR/$PLUGIN_NAME"
36
+ echo ""
37
+
38
+ # Verify source exists
39
+ if [ ! -d "$PLUGIN_SRC" ]; then
40
+ echo "✗ Error: Plugin source not found at $PLUGIN_SRC"
41
+ exit 1
42
+ fi
43
+
44
+ # Create CEP extensions directory if needed
45
+ if [ ! -d "$CEP_DIR" ]; then
46
+ echo "Creating CEP extensions directory..."
47
+ mkdir -p "$CEP_DIR"
48
+ fi
49
+
50
+ # Remove existing installation
51
+ if [ -L "$CEP_DIR/$PLUGIN_NAME" ] || [ -d "$CEP_DIR/$PLUGIN_NAME" ]; then
52
+ echo "Removing existing installation..."
53
+ rm -rf "$CEP_DIR/$PLUGIN_NAME"
54
+ fi
55
+
56
+ # Create symlink
57
+ echo "Creating symlink..."
58
+ ln -s "$PLUGIN_SRC" "$CEP_DIR/$PLUGIN_NAME"
59
+ echo "✓ Symlink created"
60
+
61
+ # Enable unsigned extensions (macOS)
62
+ if [[ "$OSTYPE" == "darwin"* ]]; then
63
+ echo ""
64
+ echo "Enabling unsigned CEP extensions..."
65
+ # Support CSXS versions 9-12 for various Premiere Pro versions
66
+ for ver in 9 10 11 12; do
67
+ defaults write com.adobe.CSXS.$ver PlayerDebugMode 1 2>/dev/null || true
68
+ done
69
+ echo "✓ Debug mode enabled (CSXS 9-12)"
70
+ fi
71
+
72
+ echo ""
73
+ echo "========================================"
74
+ echo " ✓ Installation complete!"
75
+ echo "========================================"
76
+ echo ""
77
+ echo "Next steps:"
78
+ echo " 1. Restart Premiere Pro (if running)"
79
+ echo " 2. Open: Window → Extensions → AI Chat"
80
+ echo " 3. Enter your Claude or Gemini API key"
81
+ echo " 4. Start chatting to control Premiere Pro!"
82
+ echo ""
83
+ echo "Note: The AI Chat panel and MCP Bridge panel"
84
+ echo "can run side by side if you have both installed."
85
+ echo ""