video-editing
affaan-m/ECC
Edita material de vídeo real utilizando un flujo de trabajo que incluye FFmpeg, Remotion, ElevenLabs, fal.ai y editores tradicionales para cortar, estructurar y mejorar las grabaciones sin procesar.
...Expandir todoEdición de vídeo
Edición asistida por IA para material de vídeo real. No se trata de la generación a partir de indicaciones. Edición rápida de vídeos existentes.
Cuándo activarla
- El usuario quiere editar, recortar o estructurar material de vídeo
- Convertir grabaciones largas en contenido de formato corto
- Crear vlogs, tutoriales o vídeos de demostración a partir de material sin editar
- Añadir superposiciones, subtítulos, música o voz en off a un vídeo ya existente
- Reajustar el vídeo para diferentes plataformas (YouTube, TikTok, Instagram)
- El usuario dice «editar vídeo», «recortar este material», «hacer un vlog» o «flujo de trabajo de vídeo»
Tesis principal
La edición de vídeo con IA resulta útil cuando dejas de pedirle que cree el vídeo completo y empiezas a utilizarla para comprimir, estructurar y mejorar el metraje real. El valor no está en la generación. El valor está en la compresión.
El proceso
Screen Studio / metraje sin editar
→ Claude / Codex
→ FFmpeg
→ Remotion
→ ElevenLabs / fal.ai
→ Descript o CapCut
Cada capa tiene una función específica. No te saltes capas. No intentes que una sola herramienta lo haga todo.
Capa 1: Captura (Screen Studio / material en bruto)
Recopila el material de origen:
- Screen Studio: grabaciones de pantalla pulidas para demostraciones de aplicaciones, sesiones de programación y flujos de trabajo en el navegador
- Material de cámara sin editar: material de vlogs, entrevistas, grabaciones de eventos
- Captura de escritorio a través de VideoDB: grabación de sesiones con contexto en tiempo real (véase la habilidad
«videodb»)
Resultado: archivos sin editar listos para su organización.
Nivel 2: Organización (Claude / Codex)
Utiliza Claude Code o Codex para:
- Transcribir y etiquetar: generar transcripciones, identificar temas y asuntos
- Planificar la estructura: decidir qué se mantiene, qué se elimina y qué orden funciona
- Identificar secciones prescindibles: localizar pausas, digresiones y tomas repetidas
- Generar una lista de decisiones de montaje: marcas de tiempo para los cortes y segmentos que hay que conservar
- Crear el código base para FFmpeg y Remotion: generar los comandos y las composiciones
Ejemplo de indicación:
«Aquí tienes la transcripción de una grabación de 4 horas. Identifica los 8 segmentos más destacados
para un vlog de 24 minutos. Dame los comandos de corte de FFmpeg para cada segmento».
Esta fase se centra en la estructura, no en el gusto creativo final.
Nivel 3: Cortes determinísticos (FFmpeg)
FFmpeg se encarga del trabajo tedioso pero fundamental: dividir, recortar, concatenar y preprocesar.
Extraer un segmento por marca de tiempo
ffmpeg -i raw.mp4 -ss 00:12:30 -to 00:15:45 -c copy segment_01.mp4
Corte por lotes a partir de la lista de decisiones de edición
#!/bin/bash
# cuts.txt: inicio, fin, etiqueta
while IFS=, read -r inicio fin etiqueta; do
ffmpeg -i raw.mp4 -ss "$inicio" -to "$fin" -c copy "segments/${etiqueta}.mp4"
done < cuts.txt
Concatena segmentos
# Crear lista de archivos
for f in segments/*.mp4; do echo "archivo '$f'"; done > concat.txt
ffmpeg -f concat -safe 0 -i concat.txt -c copy assembled.mp4
Crear un archivo proxy para una edición más rápida
ffmpeg -i raw.mp4 -vf "scale=960:-2" -c:v libx264 -preset ultrafast -crf 28 proxy.mp4
Extraer el audio para la transcripción
ffmpeg -i raw.mp4 -vn -acodec pcm_s16le -ar 16000 audio.wav
Normalizar los niveles de audio
ffmpeg -i segment.mp4 -af loudnorm=I=-16:TP=-1.5:LRA=11 -c:v copy normalized.mp4
Capa 4: Composición programable (Remotion)
Remotion convierte los problemas de edición en código componible. Úsalo para aquellas tareas que los editores tradicionales hacen que resulten complicadas:
Cuándo utilizar Remotion
- Superposiciones: texto, imágenes, logotipos, tercios inferiores
- Visualizaciones de datos: gráficos, estadísticas, números animados
- Gráficos en movimiento: transiciones, animaciones explicativas
- Escenas modulables: plantillas reutilizables en distintos vídeos
- Demostraciones de productos: capturas de pantalla con anotaciones, aspectos destacados de la interfaz de usuario
Composición básica de Remotion
import { AbsoluteFill, Sequence, Video, useCurrentFrame } from "remotion";
export const VlogComposition: React.FC = () => {
const frame = useCurrentFrame();
return (
{/* Metraje principal */}
{/* Superposición del título */}
El conjunto de herramientas de edición con IA
{/* Siguiente segmento */}
);
};
Resultado del renderizado
npx remotion render src/index.ts VlogComposition output.mp4
Consulta la documentación de Remotion para ver patrones detallados y la referencia de la API.
Capa 5: Recursos generados (ElevenLabs / fal.ai)
Genera solo lo que necesites. No generes el vídeo completo.
Voz en off con ElevenLabs
import os
import requests
resp = requests.post(
f"https://api.elevenlabs.io/v1/text-to-speech/{voice_id}",
headers={
"xi-api-key": os.environ["ELEVENLABS_API_KEY"],
"Content-Type": "application/json"
},
json={
"text": "Tu texto de narración aquí",
"model_id": "eleven_turbo_v2_5",
"voice_settings": {"stability": 0.5, "similarity_boost": 0.75}
}
)
with open("voiceover.mp3", "wb") as f:
f.write(resp.content)
Música y efectos de sonido con fal.ai
Utiliza la habilidad fal-ai-media para:
- Generar música de fondo
- Efectos de sonido (modelo ThinkSound para convertir vídeo en audio)
- Sonidos de transición
Imágenes generadas con fal.ai
Úsala para insertar tomas, miniaturas o material de archivo que no exista:
generate(app_id: "fal-ai/nano-banana-pro", input_data: {
"prompt": "miniatura profesional para un vlog tecnológico, fondo oscuro, código en pantalla",
"image_size": "landscape_16_9"
})
Audio generativo de VideoDB
Si VideoDB está configurado:
voiceover = coll.generate_voice(text="Narración aquí", voice="alloy")
music = coll.generate_music(prompt="música de fondo lo-fi para vlog de programación", duration=120)
sfx = coll.generate_sound_effect(prompt="transición sutil con un silbido")
Capa 6: Toques finales (Descript / CapCut)
La última capa es humana. Utiliza un editor tradicional para:
- Ritmo: ajustar los cortes que parezcan demasiado rápidos o lentos
- Subtítulos: generados automáticamente y luego revisados manualmente
- Corrección de color: corrección básica y ambiente
- Mezcla de audio final: equilibra los niveles de voz, música y efectos de sonido
- Exportación: formatos específicos para cada plataforma y ajustes de calidad
Aquí es donde entra en juego el gusto personal. La IA se encarga del trabajo repetitivo. Tú tomas las decisiones finales.
Reajuste para redes sociales
Las diferentes plataformas requieren diferentes relaciones de aspecto:
| Plataforma | Relación de aspecto | Resolución |
|---|---|---|
| YouTube | 16:9 | 1920 x 1080 |
| TikTok / Reels | 9:16 | 1080 x 1920 |
| Feed de Instagram | 1:1 | 1080 x 1080 |
| X / Twitter | 16:9 o 1:1 | 1280 x 720 o 720 x 720 |
Recortar con FFmpeg
# De 16:9 a 9:16 (recorte central)
ffmpeg -i input.mp4 -vf "crop=ih*9/16:ih,scale=1080:1920" vertical.mp4
# De 16:9 a 1:1 (recorte central)
ffmpeg -i input.mp4 -vf "crop=ih:ih,scale=1080:1080" square.mp4
Recorte con VideoDB
from videodb import ReframeMode
# Reencuadre inteligente (seguimiento del sujeto guiado por IA)
reframed = video.reframe(start=0, end=60, target="vertical", mode=ReframeMode.smart)
Detección de escenas y corte automático
Detección de escenas con FFmpeg
# Detectar cambios de escena (umbral 0,3 = sensibilidad moderada)
ffmpeg -i input.mp4 -vf "select='gt(scene,0.3)',showinfo" -vsync vfr -f null - 2>&1 | grep showinfo
Detección de silencio para el corte automático
# Buscar segmentos de silencio (útil para eliminar los silencios)
ffmpeg -i input.mp4 -af silencedetect=noise=-30dB:d=2 -f null - 2>&1 | grep silence
Extracción de momentos destacados
Utiliza Claude para analizar la transcripción y las marcas de tiempo de las escenas:
«Dada esta transcripción con marcas de tiempo y estos puntos de cambio de escena,
identifica los 5 clips de 30 segundos más atractivos para las redes sociales».
Lo que mejor hace cada herramienta
| Herramienta | Punto fuerte | Punto débil |
|---|---|---|
| Claude / Codex | Organización, planificación, generación de código | No es el ámbito de la creatividad |
| FFmpeg | Cortes determinísticos, procesamiento por lotes, conversión de formatos | Sin interfaz de usuario para la edición visual |
| Remotion | Superposiciones programables, escenas combinables, plantillas reutilizables | Curva de aprendizaje para usuarios sin conocimientos de programación |
| Screen Studio | Grabaciones de pantalla pulidas al instante | Solo captura de pantalla |
| ElevenLabs | Voz, narración, música, efectos de sonido | No es el centro del flujo de trabajo |
| Descript / CapCut | Ritmo final, subtítulos, pulido | Manual, no automatizable |
Principios clave
- Edita, no generes. Este flujo de trabajo sirve para editar material real, no para crear a partir de indicaciones.
- La estructura antes que el estilo. Asegúrate de que la historia quede bien en la Capa 2 antes de tocar nada visual.
- FFmpeg es la columna vertebral. Aburrido, pero fundamental. Es donde el metraje largo se vuelve manejable.
- Remotion para la repetibilidad. Si vas a hacerlo más de una vez, conviértelo en un componente de Remotion.
- Genera de forma selectiva. Utiliza la generación por IA solo para recursos que no existen, no para todo.
- El gusto es la última capa. La IA elimina el trabajo repetitivo. Tú tomas las decisiones creativas finales.
Habilidades relacionadas
fal-ai-media— Generación de imágenes, vídeo y audio mediante IAvideodb— Procesamiento, indexación y transmisión de vídeo del lado del servidorcontent-engine— Distribución de contenido nativa de la plataforma
---
name: video-editing
description: Edit real video footage using a pipeline of FFmpeg, Remotion, ElevenLabs, fal.ai, and traditional editors for cutting, structuring, and augmenting raw captures.
---
# Video Editing
AI-assisted editing for real footage. Not generation from prompts. Editing existing video fast.
## When to Activate
- User wants to edit, cut, or structure video footage
- Turning long recordings into short-form content
- Building vlogs, tutorials, or demo videos from raw capture
- Adding overlays, subtitles, music, or voiceover to existing video
- Reframing video for different platforms (YouTube, TikTok, Instagram)
- User says "edit video", "cut this footage", "make a vlog", or "video workflow"
## Core Thesis
AI video editing is useful when you stop asking it to create the whole video and start using it to compress, structure, and augment real footage. The value is not generation. The value is compression.
## The Pipeline
```
Screen Studio / raw footage
→ Claude / Codex
→ FFmpeg
→ Remotion
→ ElevenLabs / fal.ai
→ Descript or CapCut
```
Each layer has a specific job. Do not skip layers. Do not try to make one tool do everything.
## Layer 1: Capture (Screen Studio / Raw Footage)
Collect the source material:
- **Screen Studio**: polished screen recordings for app demos, coding sessions, browser workflows
- **Raw camera footage**: vlog footage, interviews, event recordings
- **Desktop capture via VideoDB**: session recording with real-time context (see `videodb` skill)
Output: raw files ready for organization.
## Layer 2: Organization (Claude / Codex)
Use Claude Code or Codex to:
- **Transcribe and label**: generate transcript, identify topics and themes
- **Plan structure**: decide what stays, what gets cut, what order works
- **Identify dead sections**: find pauses, tangents, repeated takes
- **Generate edit decision list**: timestamps for cuts, segments to keep
- **Scaffold FFmpeg and Remotion code**: generate the commands and compositions
```
Example prompt:
"Here's the transcript of a 4-hour recording. Identify the 8 strongest segments
for a 24-minute vlog. Give me FFmpeg cut commands for each segment."
```
This layer is about structure, not final creative taste.
## Layer 3: Deterministic Cuts (FFmpeg)
FFmpeg handles the boring but critical work: splitting, trimming, concatenating, and preprocessing.
### Extract segment by timestamp
```bash
ffmpeg -i raw.mp4 -ss 00:12:30 -to 00:15:45 -c copy segment_01.mp4
```
### Batch cut from edit decision list
```bash
#!/bin/bash
# cuts.txt: start,end,label
while IFS=, read -r start end label; do
ffmpeg -i raw.mp4 -ss "$start" -to "$end" -c copy "segments/${label}.mp4"
done < cuts.txt
```
### Concatenate segments
```bash
# Create file list
for f in segments/*.mp4; do echo "file '$f'"; done > concat.txt
ffmpeg -f concat -safe 0 -i concat.txt -c copy assembled.mp4
```
### Create proxy for faster editing
```bash
ffmpeg -i raw.mp4 -vf "scale=960:-2" -c:v libx264 -preset ultrafast -crf 28 proxy.mp4
```
### Extract audio for transcription
```bash
ffmpeg -i raw.mp4 -vn -acodec pcm_s16le -ar 16000 audio.wav
```
### Normalize audio levels
```bash
ffmpeg -i segment.mp4 -af loudnorm=I=-16:TP=-1.5:LRA=11 -c:v copy normalized.mp4
```
## Layer 4: Programmable Composition (Remotion)
Remotion turns editing problems into composable code. Use it for things that traditional editors make painful:
### When to use Remotion
- Overlays: text, images, branding, lower thirds
- Data visualizations: charts, stats, animated numbers
- Motion graphics: transitions, explainer animations
- Composable scenes: reusable templates across videos
- Product demos: annotated screenshots, UI highlights
### Basic Remotion composition
```tsx
import { AbsoluteFill, Sequence, Video, useCurrentFrame } from "remotion";
export const VlogComposition: React.FC = () => {
const frame = useCurrentFrame();
return (
<AbsoluteFill>
{/* Main footage */}
<Sequence from={0} durationInFrames={300}>
<Video src="/segments/intro.mp4" />
</Sequence>
{/* Title overlay */}
<Sequence from={30} durationInFrames={90}>
<AbsoluteFill style={{
justifyContent: "center",
alignItems: "center",
}}>
<h1 style={{
fontSize: 72,
color: "white",
textShadow: "2px 2px 8px rgba(0,0,0,0.8)",
}}>
The AI Editing Stack
</h1>
</AbsoluteFill>
</Sequence>
{/* Next segment */}
<Sequence from={300} durationInFrames={450}>
<Video src="/segments/demo.mp4" />
</Sequence>
</AbsoluteFill>
);
};
```
### Render output
```bash
npx remotion render src/index.ts VlogComposition output.mp4
```
See the [Remotion docs](https://www.remotion.dev/docs) for detailed patterns and API reference.
## Layer 5: Generated Assets (ElevenLabs / fal.ai)
Generate only what you need. Do not generate the whole video.
### Voiceover with ElevenLabs
```python
import os
import requests
resp = requests.post(
f"https://api.elevenlabs.io/v1/text-to-speech/{voice_id}",
headers={
"xi-api-key": os.environ["ELEVENLABS_API_KEY"],
"Content-Type": "application/json"
},
json={
"text": "Your narration text here",
"model_id": "eleven_turbo_v2_5",
"voice_settings": {"stability": 0.5, "similarity_boost": 0.75}
}
)
with open("voiceover.mp3", "wb") as f:
f.write(resp.content)
```
### Music and SFX with fal.ai
Use the `fal-ai-media` skill for:
- Background music generation
- Sound effects (ThinkSound model for video-to-audio)
- Transition sounds
### Generated visuals with fal.ai
Use for insert shots, thumbnails, or b-roll that doesn't exist:
```
generate(app_id: "fal-ai/nano-banana-pro", input_data: {
"prompt": "professional thumbnail for tech vlog, dark background, code on screen",
"image_size": "landscape_16_9"
})
```
### VideoDB generative audio
If VideoDB is configured:
```python
voiceover = coll.generate_voice(text="Narration here", voice="alloy")
music = coll.generate_music(prompt="lo-fi background for coding vlog", duration=120)
sfx = coll.generate_sound_effect(prompt="subtle whoosh transition")
```
## Layer 6: Final Polish (Descript / CapCut)
The last layer is human. Use a traditional editor for:
- **Pacing**: adjust cuts that feel too fast or slow
- **Captions**: auto-generated, then manually cleaned
- **Color grading**: basic correction and mood
- **Final audio mix**: balance voice, music, and SFX levels
- **Export**: platform-specific formats and quality settings
This is where taste lives. AI clears the repetitive work. You make the final calls.
## Social Media Reframing
Different platforms need different aspect ratios:
| Platform | Aspect Ratio | Resolution |
|----------|-------------|------------|
| YouTube | 16:9 | 1920x1080 |
| TikTok / Reels | 9:16 | 1080x1920 |
| Instagram Feed | 1:1 | 1080x1080 |
| X / Twitter | 16:9 or 1:1 | 1280x720 or 720x720 |
### Reframe with FFmpeg
```bash
# 16:9 to 9:16 (center crop)
ffmpeg -i input.mp4 -vf "crop=ih*9/16:ih,scale=1080:1920" vertical.mp4
# 16:9 to 1:1 (center crop)
ffmpeg -i input.mp4 -vf "crop=ih:ih,scale=1080:1080" square.mp4
```
### Reframe with VideoDB
```python
from videodb import ReframeMode
# Smart reframe (AI-guided subject tracking)
reframed = video.reframe(start=0, end=60, target="vertical", mode=ReframeMode.smart)
```
## Scene Detection and Auto-Cut
### FFmpeg scene detection
```bash
# Detect scene changes (threshold 0.3 = moderate sensitivity)
ffmpeg -i input.mp4 -vf "select='gt(scene,0.3)',showinfo" -vsync vfr -f null - 2>&1 | grep showinfo
```
### Silence detection for auto-cut
```bash
# Find silent segments (useful for cutting dead air)
ffmpeg -i input.mp4 -af silencedetect=noise=-30dB:d=2 -f null - 2>&1 | grep silence
```
### Highlight extraction
Use Claude to analyze transcript + scene timestamps:
```
"Given this transcript with timestamps and these scene change points,
identify the 5 most engaging 30-second clips for social media."
```
## What Each Tool Does Best
| Tool | Strength | Weakness |
|------|----------|----------|
| Claude / Codex | Organization, planning, code generation | Not the creative taste layer |
| FFmpeg | Deterministic cuts, batch processing, format conversion | No visual editing UI |
| Remotion | Programmable overlays, composable scenes, reusable templates | Learning curve for non-devs |
| Screen Studio | Polished screen recordings immediately | Only screen capture |
| ElevenLabs | Voice, narration, music, SFX | Not the center of the workflow |
| Descript / CapCut | Final pacing, captions, polish | Manual, not automatable |
## Key Principles
1. **Edit, don't generate.** This workflow is for cutting real footage, not creating from prompts.
2. **Structure before style.** Get the story right in Layer 2 before touching anything visual.
3. **FFmpeg is the backbone.** Boring but critical. Where long footage becomes manageable.
4. **Remotion for repeatability.** If you'll do it more than once, make it a Remotion component.
5. **Generate selectively.** Only use AI generation for assets that don't exist, not for everything.
6. **Taste is the last layer.** AI clears repetitive work. You make the final creative calls.
## Related Skills
- `fal-ai-media` — AI image, video, and audio generation
- `videodb` — Server-side video processing, indexing, and streaming
- `content-engine` — Platform-native content distribution
Todos los archivos
1 archivosInstalar video-editing
Descarga y descomprime los archivos de habilidades en tu directorio .claude/skills/.
Descargar ZIPClona el repositorio y copia los archivos de la habilidad a tu proyecto.
git clone https://github.com/affaan-m/ECC/tree/main/skills/video-editing # Copy SKILL.md to your .claude/skills/ directory
Copiar





Hogar
