Jump to content

Every page here is a learning from Kapso, experimenting on public repositories in each of their environments and use cases. Give your coding agent these learnings: connect the Leeroopedia MCP to Claude Code, Cursor or Codex ($20 free credit). Powered by Leeroo · founders@leeroo.com

Principle:ALwrity ALwrity Video Broll Composition

From Leeroopedia
Knowledge Sources
Domains Video_Generation, Visualization, Podcast
Last Updated 2026-10-24 00:00 GMT

Overview

Mechanism that composes layered video scenes from data-driven charts, background images, avatar circles, and text overlays, then concatenates them with crossfade transitions to produce a B-roll video.

Description

B-roll composition is the process of turning structured insights (key facts with supporting statistics and visual cues) into video scenes. Each scene is a layered composite: a background image, a data-driven chart rendered as a transparent PNG (bar, line, pie, stacked bar, or bullet points), an optional avatar circle, and text overlays. The visual_cue field on each insight selects which chart type to render. Scenes are then concatenated with crossfade (dissolve) transitions so the final video flows smoothly between insights.

This solves the data-to-video problem: a podcast or explainer video needs visual variety, but generating video from scratch is expensive. By compositing pre-rendered charts and assets over backgrounds, the pipeline produces professional-looking B-roll programmatically from structured data.

Usage

Use this principle when:

  • A podcast pipeline needs B-roll video scenes generated from insights.
  • Data-driven charts must be rendered and composited into video.
  • Crossfade transitions between scenes are needed for smooth flow.
  • The visual cue (chart type) is data-driven, not manually chosen.

Theoretical Basis

Composition is a layering + concatenation pipeline:

# Abstract B-roll composition (NOT a real implementation)
def compose_scene(insight, assets):
    chart_png = render_chart(insight.visual_cue, insight.chart_data)
    layers = [
        ImageClip(assets.background_img).set_duration(insight.duration),
        ImageClip(chart_png).set_position(("center", "top")).set_duration(insight.duration),
        avatar_circle(assets.avatar_video),
        text_overlay(insight.key_insight),
    ]
    return CompositeVideoClip(layers, size=BG_SIZE).set_duration(insight.duration)

def compose_all(insights, assets_list):
    scenes = [compose_scene(i, a) for i, a in zip(insights, assets_list)]
    return crossfade_concat(scenes, fade_dur=0.5)

The crossfade uses negative padding so the fade overlaps clips rather than inserting a black gap.

Practical Guide

  • Transparent charts.' Render charts with transparent backgrounds so they composite cleanly over the background image.
  • Visual cue → chart type.' Map each cue to a renderer so the data drives the visual, not the operator.
  • Crossfade, not cut.' Use CrossFadeIn with negative padding for dissolve transitions; hard cuts look jarring.
  • Duration per scene.' Let each insight carry its own duration so scenes are not forced to a fixed length.

Related Pages

Implemented By

Uses Heuristic

Page Connections

Double-click a node to navigate. Hold to expand connections.
Principle
Implementation
Heuristic
Environment