Simon Willison’s Weblog: llm-fragments-youtube

Source URL: https://simonwillison.net/2025/Jun/14/llm-fragments-youtube/#atom-everything
Source: Simon Willison’s Weblog
Title: llm-fragments-youtube

Feedly Summary: llm-fragments-youtube
Excellent new LLM plugin by Agustin Bacigalup which lets you use the subtitles of any YouTube video as a fragment for running prompts against.
I tried it out like this:
llm install llm-fragments-youtube
llm -f youtube:dQw4w9WgXcQ \
‘summary of people and what they do’

Which returned:

The lyrics you’ve provided are from the song “Never Gonna Give You Up" by Rick Astley. The song features a narrator who is expressing unwavering love and commitment to another person. Here’s a summary of the people involved and their roles:

The Narrator (Singer): A person deeply in love, promising loyalty, honesty, and emotional support. They emphasize that they will never abandon, hurt, or deceive their partner.

The Partner (Implied Listener): The person the narrator is addressing, who is experiencing emotional pain or hesitation ("Your heart’s been aching but you’re too shy to say it"). The narrator is encouraging them to understand and trust in the commitment being offered.

In essence, the song portrays a one-sided but heartfelt pledge of love, with the narrator assuring their partner of their steadfast dedication.

The plugin works by including yt-dlp as a Python dependency and then executing it via a call to subprocess.run().
Tags: youtube, llm, plugins, generative-ai, ai, llms

AI Summary and Description: Yes

Summary: The text describes a new plugin called LLM Fragments for YouTube, developed by Agustin Bacigalup, which allows users to extract and utilize subtitles from YouTube videos for running prompts through a large language model (LLM). This tool demonstrates a significant enhancement in leveraging generative AI capabilities in practical applications.

Detailed Description: The content presents an innovative plugin that connects YouTube video subtitles with LLMs for enhanced prompt generation.

– **Plugin Overview**:
– Developed by Agustin Bacigalup, the LLM Fragments plugin provides users with the capability to harness the subtitles of YouTube videos as inputs for LLMs.

– **Functionality**:
– The CLI commands demonstrate how to install and use the plugin to extract relevant summary information from the video content.
– The example illustrates the application of the plugin to process the song “Never Gonna Give You Up” by Rick Astley, showcasing the functionality to summarize narrative roles in a lyrical context.

– **Technical Aspects**:
– The plugin utilizes the `yt-dlp` library as a dependency for fetching subtitles, indicating a blend of software development practices with generative AI.
– The integration involves creating calls to subprocesses in Python, highlighting its accessibility for developers familiar with programming in Python and AI applications.

– **Implications for Professionals**:
– This plugin exemplifies the growing intersection between AI, media, and user-generated content, opening new avenues for automated content curation and analysis.
– It emphasizes the importance of generative AI tools in enhancing user interactions with existing media, creating possibilities for more engaging and intuitive applications.

In summary, the LLM Fragments plugin serves as a notable advancement in the field of generative AI, showcasing new methods for utilizing existing video content for analytical and creative purposes.