Ultron

Video Editor

Edit video clips with AI instructions using a non-linear timeline editor powered by ffmpeg.

Next.jsTypeScriptffmpeg

Capabilities

Edit video clips through natural language instructions
Non-linear timeline with multi-track video and audio
Trim, move, overlay, adjust volume, and add text overlays
Preview renders and full exports via ffmpeg
System Prompt
You are a non-linear video editor assistant. You operate a timeline editor that runs ffmpeg in the sandbox.

Every user message is prefixed with:
[[[SYSTEM NOTE: PROJECT: <JSON> ]]]

That JSON has { tracks, clips, assets, output }. Treat it as source of truth.

WORKFLOW:
1. Read the SYSTEM NOTE to understand the current timeline.
2. If new URL provided, call probe_asset to learn duration/dimensions.
3. Plan edits as small ops (add_clip, move_clip, trim_clip, set_volume, set_text_overlay). Emit all in ONE update_timeline call.
4. Only call render_project when user asks to render/export.

RULES:
- Never guess asset duration. Probe first if unknown.
- Video tracks stack bottom-to-top. Higher tracks overlay lower ones.
- Keep timelines under 60s unless asked otherwise.
- Be concise. One short sentence + one tool call.
Agent Source
import { agent } from "@agent-sdk"
import { videoEditorTools } from "./lib/tools"

export default agent({
  model: "claude-sonnet-4-6",
  runtime: "claude-code",
  permissionMode: "bypassPermissions",
  maxTurns: 25,
  systemPrompt: `...`, // see System Prompt above
  tools: videoEditorTools,
  onError: async ({ error }) => {
    console.error("[video-editor] error:", error)
  },
  onFinish: async ({ cost, duration, turns }) => {
    console.log(`Done: ${turns} turns, ${duration}ms, $${cost.toFixed(4)}`)
  },
})

File Structure

agents/
video-editor.ts
agents/lib/
tools.ts
storage.ts
project-schema.ts
agents/lib/ffmpeg/
compile.ts
download.ts
run.ts
app/
page.tsx
layout.tsx
globals.css
app/api/agent/
sandbox/route.ts
threads/route.ts
token/route.ts
app/components/
asset-panel.tsx
chat-panel.tsx
timeline-editor.tsx
Setup
$ npm install
$ cp .env.example .env.local
# Add AGENT_API_KEY to .env.local
$ npm run deploy
$ npm run dev

Environment Variables

AGENT_API_KEYServer-side API key for token exchange

Sell This Agent

Edit videos by describing what you want. Video agencies spending $50/hr on editors can automate 60% of cuts, trims, and overlays.

Setup fee
$4,000
Monthly retainer
$600/mo
Target marketContent creators, Marketing teams, Video agencies

Included

Full agent source code
ffmpeg integration
Timeline editor UI
Connect to Ultron pipelineUnlock
Cloud render pipelineUnlock
Turn views into income.Drop your video link, get paid as the view count climbs.
Submit a video