YouTube Transcript Tool
from abilities import llm
from flask import Flask, render_template, request, jsonify
from gunicorn.app.base import BaseApplication
app = Flask(__name__, static_folder='static')
@app.route("/")
def home_route():
return render_template("home.html")
@app.route("/api/transcript", methods=["POST"])
def get_transcript():
from youtube_transcript_api import YouTubeTranscriptApi
import re
import openai
video_url = request.json.get('url', '')
try:
# Extract video ID from URL
video_id_match = re.search(r'(?:v=|\/)([0-9A-Za-z_-]{11}).*', video_url)
if not video_id_match:
return jsonify({"error": "Invalid YouTube URL"}), 400
video_id = video_id_match.group(1)
Created: | Last Updated:
Here's a guide for using the YouTube Transcript Tool template:
Introduction
The YouTube Transcript Tool is a web application that helps you extract transcripts from YouTube videos and converts them into structured, step-by-step instructions. It provides both the raw transcript and an AI-processed version that breaks down the content into clear, numbered steps.
Getting Started
- Click "Start with this Template" to begin using the YouTube Transcript Tool template
Test the Application
- Click the "Test" button in the Lazy Builder interface
- Lazy will provide you with a server link where you can access the web interface
Using the Application
- Open the provided server link in your browser
- You'll see a simple interface with a URL input field
- Paste a valid YouTube video URL into the input field
- Click "Get Transcript" to process the video
- The tool will display:
- Structured instructions extracted from the video content
- The complete transcript text
- You can download the results as a Markdown file using the "Download as Markdown" button
Technical Requirements
- The video must have closed captions or subtitles available
- The YouTube URL must be in one of these formats:
https://www.youtube.com/watch?v=VIDEO_ID
https://youtu.be/VIDEO_ID
The application will automatically handle the transcript extraction and processing, providing you with both the raw transcript and structured instructions derived from the video content.
Template Benefits
- Enhanced Content Accessibility
- Transforms video content into searchable, readable text
- Makes educational content more accessible to users with hearing impairments
-
Enables quick scanning of video content without watching the entire video
-
Educational Resource Development
- Automatically converts video lectures into structured written materials
- Creates step-by-step instruction guides from tutorial videos
-
Facilitates the creation of study materials and course content
-
Content Research & Analysis
- Enables efficient research of video content for market analysis
- Helps content creators analyze competitor videos
-
Supports data mining from video transcripts for trend analysis
-
Time & Cost Efficiency
- Eliminates manual transcription costs
- Reduces time spent on converting video content to text
-
Automates the process of extracting key instructions from videos
-
Content Repurposing & Marketing
- Facilitates the conversion of video content into blog posts or articles
- Enables creation of multi-format content from single video source
- Supports SEO efforts by providing text-based content from videos
Technologies


