add-video
Skill488 starsChanged 6 months agoMITView on GitHub
Add a new YouTube video to the LazyPi videos page. Use when given a YouTube URL to add to the site. Fetches title, channel, duration, and publish date automatically via agent-browser; Shorts are placed in Short Pi automatically, while regular videos ask for a category.
1 other project uses a version of this.
Adopted by
Most recently taken up by
- ir0nfelix/study_materialstheir own version, first seen Oct 4, 2026
Other versions1 project uses a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 1
- ir0nfelix/study_materials★ 0same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository3 other files it gives its agents.
- AGENTS.mdAGENTS.md
- add-packageSkill
- find-videosSkill
The file
We split this skill into the rules it gives an agent
10 rules. About 0 are common, 2 are distinctive, and 8 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈2
Distinctive · estimate
This author's own choices. Worth a look.
8
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 8
Use this skill for this repository only.
- Very specific: line 20
Add a YouTube video to docs/_data/videos.yml with all metadata fetched automatically, inserted in the correct category and sorted in …
- Very specific: line 31
If the provided URL path contains /shorts/VIDEO_ID, mark the video as a Short.
- Very specific: line 35
Use agent-browser to open the YouTube watch page and extract all four fields in a single session:
- Very specific: line 56
If the provided URL is a Short, set the category to Short Pi and skip the user prompt.
- Very specific: line 71
Use AskUserQuestion (or equivalent interactive prompt) to get the user's choice.
- Very specific: line 75
Read docs/_data/videos.yml.
- Very specific: line 86
Do not quote channel unless it contains a colon or special character.
- Very specific: line 101
Do not add a video that already exists in the YAML (check by id before inserting).
- Distinctive: line 102
If agent-browser cannot fetch a field, ask the user for it rather than leaving it blank.
≈ “Common” is an estimate: at least 1 in 5 of the 364,980 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Add Video to LazyPi
Use this skill for this repository only.
Invoke it with:
/skill:add-video <youtube-url>Pi appends the command arguments to this skill as User: <args>.
Goal
Add a YouTube video to docs/_data/videos.yml with all metadata fetched automatically, inserted in the correct category and sorted in reverse chronological order. YouTube Shorts belong in the Short Pi category at the bottom of the videos page.
Step 1: Extract the video ID and detect Shorts
Parse the YouTube URL to extract the video ID.
Supported formats:
https://www.youtube.com/watch?v=VIDEO_IDhttps://youtu.be/VIDEO_IDhttps://www.youtube.com/shorts/VIDEO_ID
If the provided URL path contains /shorts/VIDEO_ID, mark the video as a Short. Shorts always go in the Short Pi category and do not require a category prompt.
Step 2: Fetch metadata via agent-browser
Use agent-browser to open the YouTube watch page and extract all four fields in a single session:
agent-browser open "https://www.youtube.com/watch?v=VIDEO_ID"
agent-browser eval "JSON.stringify({ title: document.querySelector('meta[name=title]')?.content || document.title.replace(/ - YouTube$/, ''), channel: document.querySelector('span[itemprop=author] link[itemprop=name]')?.getAttribute('content') || document.querySelector('meta[itemprop=channelId]')?.content, duration: document.querySelector('meta[itemprop=duration]')?.content, published: document.querySelector('meta[itemprop=datePublished]')?.content })"The oEmbed API (https://www.youtube.com/oembed?url=URL&format=json) is a reliable fallback for title and author_name (channel) if agent-browser returns unexpected values. Use the original Shorts URL for the oEmbed URL when the provided URL was a Short.
Convert the raw values
duration — YouTube returns ISO 8601 (e.g. PT34M48S). Convert to M:SS or H:MM:SS:
PT9M24S→9:24PT1H33M56S→1:33:56PT0M38S→0:38- Pad seconds to two digits always.
published — YouTube returns a full ISO 8601 timestamp (e.g. 2026-04-18T04:03:51-07:00). Truncate to the date portion only: 2026-04-18.
Step 3: Choose the category
If the provided URL is a Short, set the category to Short Pi and skip the user prompt.
For regular YouTube videos, read docs/_data/videos.yml to get the current categories in order, excluding Short Pi. Present them as a numbered list:
Which category should this video go in?
1. Intro to Pi
2. Full Course Pi
3. Advanced Pi
4. Slice of Pi
Enter a number:Use AskUserQuestion (or equivalent interactive prompt) to get the user's choice. Accept the number only.
Step 4: Insert into the YAML
Read docs/_data/videos.yml. Find the chosen category block and insert the new video entry at the top of that category's videos: list (newest-first ordering). For Shorts, find the Short Pi category block.
Entry format:
- id: VIDEO_ID
title: "Video title here"
channel: Channel Name
duration: "M:SS"
published: "YYYY-MM-DD"Do not quote channel unless it contains a colon or special character. Always quote title and duration. Always quote published.
Preserve all existing entries, whitespace style, and ordering in the file.
Step 5: Confirm
Tell the user what was added:
- video title
- channel
- duration
- publish date
- which category it was placed in
Notes
- Do not add a video that already exists in the YAML (check by
idbefore inserting). - If agent-browser cannot fetch a field, ask the user for it rather than leaving it blank.
- The YAML file is the single source of truth — no other files need updating when adding a video.
Short Pishould stay as the final category indocs/_data/videos.ymlso it appears at the bottom of the videos page.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

