diff --git a/.claude/skills/open-edit/scripts/preflight.sh b/.claude/skills/open-edit/scripts/preflight.sh index 45a0c32..af18ed9 100755 --- a/.claude/skills/open-edit/scripts/preflight.sh +++ b/.claude/skills/open-edit/scripts/preflight.sh @@ -6,9 +6,12 @@ set -uo pipefail # GUI-launched agents inherit a minimal PATH that commonly omits Homebrew. Add both standard -# prefixes before probing node; preserve the caller's remaining PATH. +# prefixes before probing node — but AFTER the caller's own PATH, never ahead of it. A Homebrew npm +# keeps its own global directory, so an npx taken from there cannot see a CLI installed by whichever +# npm the caller is using: it fetches a published copy and silently runs that instead of the one the +# caller set up. HOMEBREW_PATH_PREFIX="${OPEN_EDIT_HOMEBREW_PATH_PREFIX-/opt/homebrew/bin:/usr/local/bin}" -export PATH="${HOMEBREW_PATH_PREFIX:+$HOMEBREW_PATH_PREFIX:}$PATH" +export PATH="$PATH${HOMEBREW_PATH_PREFIX:+:$HOMEBREW_PATH_PREFIX}" if ! command -v node >/dev/null 2>&1; then MODE="" diff --git a/.github/README.md b/.github/README.md new file mode 100644 index 0000000..c2d087a --- /dev/null +++ b/.github/README.md @@ -0,0 +1,173 @@ +
+
+
Video editing for coding agents. Describe the edit; get the MP4.
+ + + ++ Get started · + Prompts · + Examples · + VEED +
+ +OpenEdit is an open-source, agent-driven editing pipeline. There is no GUI and no timeline: you tell +your coding agent what you want, and it transcribes, designs, renders and hands you the file. + +## Get started + +You need an Apple Silicon Mac (with Homebrew) or a Windows x64 PC, Git, Node 20 or newer, and one of +Claude Code, Codex or Gemini CLI. From your project folder, install the skill into your agent: + +```sh +npx skills add veedstudio/open-edit --skill open-edit +``` + +Then open the agent (`claude`, `codex` or `gemini`) and ask: + +``` +Add subtitles to my video clip.mp4 +``` + +The first run sets itself up: it checks for Git, Node, pnpm and ffmpeg and names the command for +anything missing (Homebrew or corepack on a Mac; on Windows the commands are printed for you to run, +and ffmpeg is fetched into your user folder with no admin rights), asking before any global install; +clones its runtime into `.open-edit/` inside your project and registers a session hook in the settings +of Claude Code, Codex and Gemini CLI; downloads the renderer into your user's app-data folder; and asks +once how you want speech transcribed. Hosted by VEED +transcribes best (a veed.io account, [sign up](https://www.veed.io/signup) or +[log in](https://www.veed.io/login); the free tier covers about ten minutes a month); WhisperX runs +locally for free (needs `uv` or `pipx`; the first transcription downloads the model, about 2 GB for the +fast tier and more for the better one; nothing leaves your machine); or bring your own service. When the +run finishes you get the MP4 with subtitles burned in, a preview open in your browser, and the path to +the file, which lives under `.open-edit/` in your project. + +
+
+*Made in OpenEdit with GPT-6 Astra driving the pipeline: pure motion graphics, no source footage, prompted
+against the [OpenAI Brand Film](https://vimeo.com/1122006941) as a visual reference.*
+
+
+
+*The launch video, also made in OpenEdit. Click either one to watch with sound.*
+
+## What you can ask for
+
+Captions are the shortest path, not the limit. The agent can edit, cut and reframe footage, layer
+motion graphics and visual elements, turn slides into video, and pull in any
+[AI video/image generator](https://www.veed.io/tools/ai-video) or MCP server when it helps. Source
+video is optional: stills, slides or generated media are enough when the brief calls for it.
+
+As a first ask:
+
+```
+Add subtitles that look like this [IMG-REF] to my video [VIDEO]
+
+Cut the false start and the long pause around 0:42, then caption it
+
+Make a 20-second title sequence for my launch, no footage, in my brand colours
+```
+
+On a delivered render:
+
+```
+I don't like the yellow colour, make it darker
+
+Move the text up a bit
+
+When he says "go buy it now", make sure the 'now' really stands out
+```
+
+No footage at all? It can generate a talking-head clip from a script with
+[VEED Fabric](https://www.veed.io/ai/fabric-1-0) and edit that. Generation is billed: it quotes the price
+in your workspace's AI Playground credits and spends nothing without your yes.
+
+## Examples
+
+Real outputs, each with the prompt that produced it. Click any example to watch it with sound.
+
+```
+create viral subtitles with /open-edit and translate my video to 5 languages using VEED Lipsync 2.0 on Fal
+```
+
+One source clip, three languages, three caption styles, translated and re-lipsynced through
+[VEED's Lip Sync API](https://www.veed.io/tools/lip-sync-api):
+
+| Spanish | French | German |
+| --- | --- | --- |
+| [](https://github.com/veedstudio/open-edit/releases/download/launch-examples/happy3-ES-078.mp4) | [](https://github.com/veedstudio/open-edit/releases/download/launch-examples/remix-FR.mp4) | [](https://github.com/veedstudio/open-edit/releases/download/launch-examples/happy2-DE-lowerthird.mp4) |
+
+```
+generate 3 viral hooks in Seedance 2.0 on Fal and create dynamic motion graphics using /open-edit
+```
+
+Three hooks generated with [Seedance](https://www.veed.io/tools/ai-video/seedance), three
+motion-graphic treatments:
+
+| | | |
+| --- | --- | --- |
+| [](https://github.com/veedstudio/open-edit/releases/download/launch-examples/news-comic.mp4) | [](https://github.com/veedstudio/open-edit/releases/download/launch-examples/chair-remix.mp4) | [](https://github.com/veedstudio/open-edit/releases/download/launch-examples/makeup-happy-v2.mp4) |
+
+```
+use Figma MCP to study my BrandBook and create branded campaign graphics using /open-edit
+```
+
+One brand book, three campaign cards:
+
+| | | |
+| --- | --- | --- |
+| [](https://github.com/veedstudio/open-edit/releases/download/launch-examples/race-card-1.mp4) | [](https://github.com/veedstudio/open-edit/releases/download/launch-examples/race-card-2.mp4) | [](https://github.com/veedstudio/open-edit/releases/download/launch-examples/race-card-4.mp4) |
+
+## How it works
+
+The skill tells your agent the whole flow: transcribe with real per-word timings, draw a caption style
+from a pool of recipes, compose the document in HTML and CSS, render it with VEED's renderer, then check
+the result for timing and contrast before handing it back. Every step of a captioned run is a command
+from the `@veedstudio/openedit-cli` package; the [CLI reference](../README.md) lists them.
+
+The renderer is source-available and free to use, and it does not run a headless browser: nothing to
+install, launch or keep alive for the length of a render. It does need a desktop session, so renders
+run on your machine rather than on a headless box.
+
+Transcription is your choice, asked once and remembered. WhisperX runs locally and nothing leaves your
+machine. VEED's hosted transcription uploads the file in order to transcribe it and stores it for that
+purpose. Any Whisper-family JSON from your own service works too, and no credentials pass through
+OpenEdit. Every provider writes the same `runs/OpenEdit · powered by VEED
diff --git a/.gitignore b/.gitignore index 769ec82..0ee0940 100644 --- a/.gitignore +++ b/.gitignore @@ -51,3 +51,9 @@ __pycache__/ # Engine probe renders — regenerable output of the probe harness internal/motion/probes/*/probe.mp4 .ffmpeg/ +# Compiled content — emitted in place by `node cli/scripts/build.mjs --content`. The packer does this +# in its own copy of the tree; a working checkout stays .ts-only so nothing stale can shadow an edit. +refs/html/**/*.js +pipeline/**/*.js +veed/args.js +internal/packaging/out/ diff --git a/AGENTS.md b/AGENTS.md index 0fcad36..0e261e9 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -89,7 +89,11 @@ fast-path/refinement switch. restores a single source track and levels whichever track it is given to the delivery loudness; this is what a film needs instead. - `veed/` — VEED-native transcription + login (one writer of `transcript.json`; real per-word timings), plus Fabric generation and video background removal on the same login. `npx @veedstudio/openedit-cli background-removal` reaches the live free VEED route by default, or fal's own `--fast` model when that variant is wanted; `npx @veedstudio/openedit-cli lipsync` (video + new audio -> re-lipsynced video) has no VEED-hosted route at all and always goes through fal. Both fal-charged paths still use the VEED login to host the local file for a URL, but the generation call itself bills the user's own fal key (the CLI's fal BYOK rail), never a VEED workspace. `npx @veedstudio/openedit-cli prep` — `meta.json` + `word-timings.json` + base frames (needs a transcript from any provider). `refs/` — `html/` refs + `tags.json` (v3, the RUNTIME INDEX — recipes only, facet taxonomy, `fit` = aspect SOT) + per-ref `recipe.md` (the prose recipe sheet a compiled recipe is derived from — the fast path runs the compiled module, never the sheet; the creative pass reads sheets as craft substrate and REMIX donors). -- `config.ts` — all machine paths (ffmpeg / ffprobe / veed-engine). `docs/` — FLOW (orchestration) · recipe-format (the recipe law). Engine support matrix = the `feature-support.md` asset downloaded with the engine release into `.veed-engine/` (not vendored here). +- `cli/src/config.ts` — the machine paths the CLI resolves (ffmpeg / ffprobe / the engine), and the two roots + it keeps apart: the CONTENT it reads (recipes, gates, brief — the package's own tree unless `OPEN_EDIT_ROOT` + names a directory that really carries `refs/tags.json`) and the WORKSPACE it writes (`runs/`, the recorded + provider choice). A checkout also has a top-level `config.ts` of its own, reading the same env vars, for the + substrate scripts that run outside the CLI. `docs/` — FLOW (orchestration) · recipe-format (the recipe law). Engine support matrix = the `feature-support.md` asset downloaded with the engine release into `.veed-engine/` (not vendored here). ## Hard rules (do not drift — these protect output quality) - Recipe runs are **deterministic** — the generate-recipe command is the only writer of the final .wv document; never diff --git a/NOTICE b/NOTICE index d8b25a6..cddd860 100644 --- a/NOTICE +++ b/NOTICE @@ -18,6 +18,20 @@ The installer places a copy of those terms alongside the binary at `.veed-engine/LICENSE-binary.md`. The canonical copy is `LICENSE-binary.md` in the releases repository above. +This project embeds woff2 subsets of two fonts in the login-success page, each +licensed under the SIL Open Font License, Version 1.1 +(https://openfontlicense.org): + + Inter — Copyright (c) 2016 The Inter Project Authors + (https://github.com/rsms/inter) + + STIX Two Text — Copyright (c) 2001-2023 by the STI Pub Companies + (https://github.com/stipub/stixfonts) + +The full license text accompanies each upstream project at the URLs above. + +--- + Transcription in this project is performed against the VEED service, which requires a VEED account and credits. Use of that service is governed by VEED's terms, separately from this project's license. diff --git a/README.md b/README.md index bf590a9..2afa28c 100644 --- a/README.md +++ b/README.md @@ -1,200 +1,282 @@ -
-
-
Not the editor you rent, but the one you own.
+The Open Edit command-line tool: agent-driven video creation and editing, +powered by VEED. - +The package carries the content it runs on — the recipe pool, the director's +brief, the design substrate and the gates — so a fresh install can draw a style, +build a document and gate it without cloning anything. The source is public at +[veedstudio/open-edit](https://github.com/veedstudio/open-edit), whose README +covers what Open Edit is and what it makes; this page is the command surface. -- Install · - Usage · - Examples · - VEED -
+## Usage -OpenEdit is an open-source, agent-driven editing pipeline that ships with VEED's HTML renderer — closed -source, but free to use. +```sh +npx @veedstudio/openedit-cli --help +``` -There is no GUI and no timeline. The pipeline is driven entirely through your coding agent — edit, -cut, and reframe footage; layer motion graphics and visual elements; turn slides or websites into -video; capture web pages; and pull in any [AI video/image generator](https://www.veed.io/tools/ai-video) -or MCP server when it helps. Source video is optional: stills, slides, generated media, or pure -motion graphics are enough when the brief calls for it. Be creative and fluid — try new ideas -rather than collapsing every ask onto captions. +## Commands -OpenEdit edits footage. Supply your own source files, or ask it to generate a talking-head clip with -[VEED Fabric](https://www.veed.io/ai/fabric-1-0) when you have none — that spends credits, and never -without your approval. +### login -
+Log in with VEED (OAuth 2.1 + PKCE via the browser; the token is stored locally
+and refreshed automatically):
-*This launch video was made in OpenEdit — click it to watch with sound.*
+```sh
+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.
-*Also made in OpenEdit, with GPT-6 Astra driving the pipeline — pure motion graphics, no source
-footage. Its prompt was written against the [OpenAI Brand Film](https://vimeo.com/1122006941) as a
-visual reference.*
+### token
-## Requirements
+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:
-| | |
-| --- | --- |
-| Platform | Apple Silicon Mac or Windows x64 PC. Preflight requires one of the two and stops elsewhere |
-| Intel Macs | Not supported — the renderer ships macOS-arm64 and windows-x64 only |
-| Older macOS | Built and tested on Tahoe 26.0. Nothing checks the version, so earlier releases may work — untested |
-| Windows | Windows 10 or newer (the installer extracts with the bundled `tar`). Git, Node, and ffmpeg via winget — preflight prints the exact commands and never runs them itself |
-| Linux | Planned; prioritisation depends on demand |
-| Transcription | needed only to caption speech — OpenEdit asks once and remembers: VEED ([sign up](https://www.veed.io/signup) / [login](https://www.veed.io/login)), WhisperX locally, or your own service. **VEED transcription consumes VEED credits**; WhisperX runs locally on your machine, and your own service is billed by whoever provides it |
-| Generation | optional — a veed.io account, only if you ask OpenEdit to generate footage you do not have |
-
-## Installation
-Download this repo, or install via the command line with:
```sh
-npx skills add veedstudio/open-edit
+npx @veedstudio/openedit-cli token
```
-## Agents
-OpenEdit uses an agent-agnostic skill and repository guide. It supports Claude Code, Codex, and Gemini;
-the installed skill prepares the runtime and loads its `AGENTS.md` instructions explicitly.
+Exits non-zero when no login is stored. `--path` prints the token store
+location instead of a token.
+
+### transcribe
+
+Transcribe videos, writing `runs/