Skip to content

Go to

Jump to a page, project or experiment

All posts

One protocol, two teams

Building Riverside's transcript-based video editor: four video tracks in a browser tab, and the shared format that fixed it.

RiversideVideoEditorCollaboration

Riverside records podcasts and video interviews in the browser. For a few years I was on the team that built its editor, the part where you turn a two-hour recording into something people want to watch. I asked myself the questions I would ask any engineer about a project like this. These are the answers.

The problem: three hours of tape, one good minute

Podcasters and creators used to pay video editors to cut their recordings. Editors are good with footage, but they don't live inside the content. So the step where someone has to find a moment, fix it or cut it out of a two or three hour recording was slow and painful for everyone.

An automatic transcript changes that. You read the recording instead of scrubbing through it, and the interesting moments find you.

That was the bet: if the transcript is accurate and editable, editing words can stand in for editing video.

Where it started

When I joined, the editor was simple. There was no transcript. It was closer to a form: choose a layout, choose a frame colour, export.

The goal was to grow it into an editor that could compete with heavy desktop tools like Adobe Premiere, while still running in a browser tab.

Here is a small recreation of the core idea. It is not Riverside's code, just the interaction: select words, delete them, and the clip follows.

Select words and press Backspace. The source row keeps the cuts, the edit row packs what is left.Open in Lab

The hard part: four people, four videos

The sync between text and video was mostly a technical problem. The editor has to stay smooth while you type, and video does not forgive dropped frames.

Our first version used several video players in the page. With four participants, that is four separate tracks playing in parallel, and the browser struggled to keep up.

We moved away from that quickly, to FFmpeg. To play FFmpeg's output in the editor we needed a player built on WebAssembly.

One protocol, two teams

That move changed more than the player. The Export team was the one that rendered the final video. Until then the flow was:

The Editor team builds the front end and sends a recipe to the Export team that says how to render the video.

We replaced it with a shared protocol that both teams used. That gave us two things:

  1. The video plays the same in the editor and in the exported file.
  2. A new layout is built once, not twice.

Working with design

The designers brought us very high-fidelity prototypes. The product was interesting and good-looking, and we wanted to keep it that way.

Sometimes the code changed the design. That happened where we hit technical limits, for example snapping (a "magnet") to an element that only exists virtually, or dragging on top of the player or the timeline.

A lot of the job was translation between three languages:

  • the conceptual language of the data, what a clip or a track is in the database,
  • the visual language of the design, what the user sees and touches,
  • the computational language of the code, what the browser can actually do at 60 frames a second.

Keeping the three aligned is what kept each element simple to build and simple to understand.

Small decisions in the text

Editing video through text raises questions that a normal text editor never has to answer. Three of them shaped how the editor feels:

  • Fixing a typo is not a cut. We started with text correction only. Correcting a misheard word changes the transcript, and the video stays as it was.
  • The context menu. This one was my call: a floating menu next to the selection, with an icon bar that stays in place.
  • Cut words stay visible. A cut word shows with a line through it, so you can see what you removed and bring it back. You can also choose to hide cut words. The "Show cut words" control in the experiment above works the same way.

What I would do differently

I would invest much more time, and much earlier, in a DTO contract for timelines: one agreed shape for what a timeline is, shared by every team that touches it. And I would let that contract lead, rather than letting product requests lead the data model one feature at a time.