@veedstudio/openedit-cli
The Open Edit command-line tool: agent-driven video creation and editing,
powered by VEED.
Prefer a browser? OpenEdit runs at
veed.ai.
The package carries the agent skill that init installs into a workspace;
everything else is a command below. The source is public at
veedstudio/open-edit, whose README
covers what Open Edit is and what it makes; this page is the command surface.
Usage
npx @veedstudio/openedit-cli --help
Commands
login
Log in with VEED (OAuth 2.1 + PKCE via the browser; the token is stored locally
and refreshed automatically):
npx @veedstudio/openedit-cli login
Pass --manual (or set VEED_LOGIN_MANUAL=1) when no reachable browser exists:
the URL is printed, and the redirect is pasted back instead of caught on a
localhost loopback.
token
Print a valid VEED access token for other tools to consume, refreshing it
first when stale (VEED_ACCESS_TOKEN, when set, is passed through as-is). The
value is printed only when the output is captured; run it straight in a terminal
and it reports that a token exists without putting one in your scrollback:
npx @veedstudio/openedit-cli token
Exits non-zero when no login is stored. --path prints the token store
location instead of a token.
transcribe
Transcribe videos, writing runs/<key>/transcript.json. The provider is the
user's choice, recorded once with --record: a bare transcribe video.mp4 runs
the recorded one (and refuses, saying why, when nothing usable is recorded), and
--provider names another for one run. Locally with WhisperX (free, offline,
nothing billed anywhere):
npx @veedstudio/openedit-cli transcribe --provider whisperx video.mp4 [...] [--model medium] [--language de] [--force]
A transcript already on disk is left alone (it may have been retimed onto an
edit); --force transcribes it again.
Or hosted by VEED (premium quality; requires the one-time login, and spends
the workspace's VEED transcription credits — --workspace <id> names which,
required only when the account has several):
npx @veedstudio/openedit-cli transcribe --provider veed video.mp4 [...]
--record <veed|whisperx|custom> [--model <id>] records the transcription
provider choice in .open-edit-prefs.json instead of running anything.
whisper
Map a speech-to-text JSON produced by your own service or a fal model into the
same runs/<key>/transcript.json: Whisper's segments with word times
(WhisperX, openai-whisper, whisper-timestamped, mlx-whisper), the OpenAI API's
verbose_json with word granularity, whisper.cpp -oj -ml 1, a timed word
list, fal's whisper and wizper chunks, a voice model's character timestamps, or
the fal-result.json that fal run keeps a model's answer in:
npx @veedstudio/openedit-cli whisper transcription.json media.mp4 [...] [--force]
Word timestamps are required; the media argument may be a video or an audio
file. Every command that reads a transcript (review, retime-transcript,
shots, veed-project, words) takes the same formats, mapped in memory, and
prints one line naming the format it read.
words
Print a transcript as timed lines, one per word with its start and end in
seconds, or one per cue with --cues; --from/--to keep the lines that
overlap that stretch. It reads a transcript.json or any format whisper maps,
and writes nothing:
npx @veedstudio/openedit-cli words runs/<key>/transcript.json [--from <sec>] [--to <sec>] [--cues]
generate / generate-set / sample-presenter
Fabric generation — source footage from a script, when there is no video to
caption. Generating draws the named workspace's AI Playground credits twice —
the speech is synthesized, then lip-synced — so it is two commands: the first
quotes the sum and records the approval, the second
spends exactly what was approved (no --script on the spend pass — the
recorded, hashed script is what bills):
npx @veedstudio/openedit-cli generate --script "spoken words" --key my-run --workspace <id>
npx @veedstudio/openedit-cli generate --key my-run --yes
--resume collects a job already created and paid for; --abandon <sessionId>
clears one abandoned charge record. generate-set --shots shots.json covers
several shots under one approval, and sample-presenter proposes a
deterministic character/voice pair for a run key (listing costs nothing).
background-removal / lipsync
Remove a video's background, or re-lipsync a video to a new audio track.
Background removal tries VEED's free route first; when that route cannot run,
it stops having spent nothing and prints what fal's model would cost and the
command to run with --fal. Only --fal (the full model, uploaded to fal's own
storage) or --fast (fal's fast model) buys anything, and lipsync always goes
through fal. Every fal call bills your own fal key, never a VEED workspace; a
re-run of the same inputs resumes the paid job instead of buying it again. A
page that lays a graphic behind the speaker needs no whole-clip cut-out where
the environment has render make one for the seconds the graphic is up (see
render); without that, this command makes the cut-out the page's stage names:
npx @veedstudio/openedit-cli background-removal video.mp4 [--fal|--fast] [--mask-only] [--no-refine] [--out <path>]
npx @veedstudio/openedit-cli lipsync video.mp4 narration.mp3 [--out <path>]
The fal key comes from FAL_KEY, or OPEN_EDIT_FAL_KEY_FILE pointing at a
file that holds it.
veed-project / veed-pull
Hand a finished edit to VEED's editor as a project a person can take apart:
footage cuts, text, captions, images and each audio track become the editor's
own items, and each page element the plan names becomes a transparent clip cut
to its box. It uses your VEED login and spends no VEED credits and nothing on your
fal key. The last step runs in
your browser: click the "OpenEdit to VEED" bookmark on VEED. The way back is the
"Send to Claude" bookmark on a project open in the editor, and veed-pull:
npx @veedstudio/openedit-cli veed-project --install-bookmark
npx @veedstudio/openedit-cli veed-project plan.json [--workspace <id>] [--local]
npx @veedstudio/openedit-cli veed-pull ~/Downloads/openedit-<project id>.json --out <dir>
veed-project --help lists the plan's fields; veed-pull writes the project
back as such a plan.
fal
Run any fal model on your own key. Local file paths inside the input are
uploaded for you (multipart above 90 MB), outputs are downloaded, and each job
ends with a cost line: the billed figure when your key can read fal's billing,
otherwise cost: unknown beside fal's listed price. An identical request is
bought once, even across processes and crashes:
npx @veedstudio/openedit-cli fal schema <model>
npx @veedstudio/openedit-cli fal run <model> --input '{"prompt":"…"}' [--out <dir>]
npx @veedstudio/openedit-cli fal run --batch jobs.json [--concurrency N] # [{model, input, name?}]
install-ffmpeg / install-whisperx
install-ffmpeg looks for an existing FFmpeg first (OPENEDIT_FFMPEG and
OPENEDIT_FFPROBE, then a previous install, then PATH) and only downloads when
there is none — a checksum-verified static build into the app-data dir (the
download route is Windows-only; macOS points at brew install ffmpeg, Linux at
apt). A set OPENEDIT_FFMPEG or OPENEDIT_FFPROBE is run first, and fails
the command, naming the variable, when its binary does not start, since nothing
else is used while it is set; --check runs whichever pair every command would.
--force reinstalls the app-data copy, and is refused while either override is
set, since no command would run the copy it installs.
install-whisperx installs the local transcription provider into an isolated
uv/pipx tool environment; it never touches the system Python.
npx @veedstudio/openedit-cli install-ffmpeg [--check|--force]
npx @veedstudio/openedit-cli install-whisperx [<version>]
brief
Record what the user asked of a piece once, in its folder: how long it runs,
where it is posted and their own words. review compares the video's length
with it and the numbers on screen with the words, render and apply-edl print
a line when what they made misses that length, safe-zone takes its zone from
the platform, render gives that zone to a page that links none, and reframe
takes its shape; a value given to the tool itself wins, and the tool says which
it used. A tool finds
brief.json from the file it works on, in that file's folder or the nearest
one above it inside the workspace. Each call sets the fields it is given and
keeps the others:
npx @veedstudio/openedit-cli brief runs/<key> --length 60 --platform tiktok --words "Doors open at 7"
npx @veedstudio/openedit-cli brief runs/<key> --platform "linkedin 1:1"
npx @veedstudio/openedit-cli brief runs/<key> # prints the brief that applies there
render / fonts / safe-zone / install-browser
Render an HTML page to video in headless Chrome, frame-exact. The page runs on a
virtual clock (timers, requestAnimationFrame, Date.now and a seeded
Math.random advance one frame per frame); CSS and Web Animations, GSAP's
global timeline and an optional window.__seek(t) are set to each frame's time,
and <video> elements show the picture at that time. The output is silent H.264
(or ProRes 4444 with --transparent), identical whatever the worker count:
npx @veedstudio/openedit-cli render page.html --out out.mp4 --fps 30000/1001 --duration 12 [--workers N]
npx @veedstudio/openedit-cli render page.html --out out.mp4 --footage clip.mp4 # the clip's rate and length
npx @veedstudio/openedit-cli render page.html --out out.mp4 --from 4 --to 6 # re-render only that stretch
npx @veedstudio/openedit-cli render page.html --out stills --stills 0.5,2,4 --sheet sheet.jpg
Segments and a manifest are cached in <out>.render/, so --from/--to
re-renders the segments it overlaps, and any other whose page or files changed
since it was drawn (a cue that moved, a clip replaced at its path), and rejoins
the rest by stream copy; every frame of the joined file is checked against its
time. A page marked
data-stateless is checked on one frame before the workers start, and rendered
as an unmarked page, with a line saying why, when the mark does not hold.
A page's long-GOP videos, and any in a codec Chrome has no decoder for (HEVC
or ProRes, say), are served from all-intra copies, made once per source, keyed
by its content, in the workspace's runs/.media, which stills into any
directory, renders and patches share (render --help says how much it keeps).
It fails naming the cause when Chrome does not start or stops answering, the
page throws, or every frame is one flat colour, and a signal stops it with the
Chromes and ffmpegs it started. A video render then looks at what it made, as the
review's blank-frames and dead-air checks do, and prints a line, failing
nothing, for a first frame that is blank, near-black or partway into a fade-in,
and for each still held longer than its words allow; a patch looks only near
the range it re-rendered.
A page can lay a graphic behind the speaker: its stage holds three layers,
<div data-layer="footage">, <div data-layer="behind"> with each graphic
marked data-behind, and <div data-layer="front">, and render draws a
cut-out of the speaker between behind and front. The stage names that cut-out
(data-cutout="<file>", what background-removal writes), or names none.
With none, or one that is not there, and OPEN_EDIT_SPEAKER_CUTOUT=1 in the
environment, render makes it: it finds the frames a data-behind graphic is
on screen in, and draws the cut-out in those frames alone. What it has not
kept of the clip's frames under them (the --footage file, else the one video
the footage layer plays) it buys with a quarter second more either side, never
less than a second a stretch, from fal's fast background-removal model, at most
12 stretches and 60 s of the clip in one render. That is a generation on the
fal account of the fal key the CLI reads, never on a VEED workspace, or, with
no key, through the fal command an environment gives in place of one, which
prices and approves it and bills as that environment arranges. One line before
the call says for how many seconds of the clip, on which route, and what it is
estimated to cost at fal's listed rate; an estimate, not a charge. Each stretch is kept in the clip's own folder under runs/<key>/,
named for the clip's bytes and its frames, so a second render makes no call, a
render that needs one more stretch buys only that one, and a clip replaced at
its path is cut out again. Without the variable render spends nothing: it
says in one line which background-removal command makes the cut-out, and
draws the page with no speaker layer, as it does when there is no fal to run
on, or the model refuses, fails, is not answered in 15 minutes or answers with
something that is not a cut-out of the stretch; a stage that names a cut-out
file that is not there still fails. behind <page> reports how much of each
graphic the speaker leaves showing, frame by frame, and gets the cut-out the
same way, so where the variable is set it needs no step before it. A cut-out
made this way is drawn in renders, not in a browser preview (render --help
and behind --help have the rest).
fonts downloads Google Fonts as local woff2 files
with a fonts.css; install-browser fetches the pinned Chrome Headless Shell,
which render also does on first use. safe-zone writes the stylesheet for where
a video will be posted: the stage at its shape's size, and a [data-safe]
container on that platform's safe zone as the page's text layer. With no zone
named, it takes the platform in the piece's brief. A zone is the app the user
names (tiktok, reels, shorts, youtube, x, linkedin, facebook).
With none named, or several, it is the shape: 9:16, 1:1 and 4:5 are each clear
of every app's UI listed for them, while 16:9 is YouTube's player, so a 16:9 piece
for a feed names that feed's app (4:3 has one zone). For Instagram, name where it
goes: reels for a 9:16 Reel, the feed shape (1:1 or 4:5) or the app with its
shape (instagram 4:5), or pass the canvas with --canvas; LinkedIn and Facebook
are named or take --canvas the same way. Add
--ad when a 9:16 video is an ad: ads reserve more of the frame than an ordinary
post's UI takes. Ordinary posts and feeds are kept clear of the UI each app draws
over them, ads of the platforms' published ad safe zones, and 4:3 has television
title-safe sides (safe-zone --help says exactly what each zone keeps clear). The
container is a size container, so cqw and cqh measure the zone for what is
inside it. Its other defaults lose to any rule the page writes: text inside starts
at the shape's minimum (and so do small, sub, sup, h5, h6 and form
controls), a word too long for its line breaks, boxes inside keep within its width
unless they set max-width: none (a ticker's track also sets width: max-content), and nothing is clipped:
npx @veedstudio/openedit-cli fonts "Inter:wght@400;700" Anton --out fonts
npx @veedstudio/openedit-cli safe-zone --out runs/<key> # the platform in the piece's brief
npx @veedstudio/openedit-cli safe-zone tiktok --out runs/<key>
npx @veedstudio/openedit-cli safe-zone 9:16 --ad --out runs/<key>
npx @veedstudio/openedit-cli safe-zone instagram --canvas 1080x1350 --out runs/<key>
npx @veedstudio/openedit-cli install-browser [--check|--force]
captions