bilibili-to-doc

bilibili-to-doc is a skill for Claude Code, Codex from programmerloverun/bilibili-to-doc. It costs 93 tokens per session (892 once invoked), scanned A, original, MIT.

A workflow for turning a Bilibili video—a video-hosting site popular in China—into a structured Markdown document using its Chinese subtitles.

In plain words
What is it for?
Downloading AI-generated subtitles, extracting the transcript, and arranging it into sections, tables, and code blocks.
Why use it?
It saves you from manually transcribing and organizing a video. Access may require browser cookies, and the workflow needs yt-dlp and Python 3.10 or newer.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Downloading AI-generated subtitles, extracting the transcript, and arranging it into sections, tables, and code blocks.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/programmerloverun/bilibili-to-doc/bilibili-to-doc
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add programmerloverun/bilibili-to-doc --skill bilibili-to-doc
Clone the repo
git clone --depth 1 https://github.com/programmerloverun/bilibili-to-doc

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for bilibili-to-doc

README.md
[![agentmods](https://agentmods.dev/badge/skills/programmerloverun/bilibili-to-doc/bilibili-to-doc/github.svg)](https://agentmods.dev/skills/programmerloverun/bilibili-to-doc/bilibili-to-doc)
Your own site
<a href="https://agentmods.dev/skills/programmerloverun/bilibili-to-doc/bilibili-to-doc"><img src="https://agentmods.dev/badge/skills/programmerloverun/bilibili-to-doc/bilibili-to-doc/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for bilibili-to-doc

Your own site · 80×15
<a href="https://agentmods.dev/skills/programmerloverun/bilibili-to-doc/bilibili-to-doc"><img src="https://agentmods.dev/badge/skills/programmerloverun/bilibili-to-doc/bilibili-to-doc.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 93 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 892 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00093 $0.00892
Opus 5 $0.00046 $0.00446
Sonnet 5 $0.00019 $0.00178
Haiku 4.5 $0.00009 $0.00089

Measured 12d ago against content hash f2b5e4cddad7, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-11, from the pricing page.

Security

Grade A, and why

bilibili-to-doc scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 12d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

SKILL.md · 109 lines

How it starts

The opening of the file, as written. The whole thing — 109 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Bilibili Video to Document (B站视频提取文档)

Overview

Extract Bilibili video content into a structured Markdown document by: (1) downloading AI-generated subtitles via yt-dlp with browser cookies, (2) parsing the SRT subtitle file, (3) reorganizing the transcript into a logical, well-structured document with sections, tables, and code blocks.

When to Use

Trigger this skill when the user:

  • Provides a bilibili.com video URL and asks to extract/converter it to a document
  • "提取B站视频内容" / "B站视频转文档" / "将视频转成文章"
  • "把这个B站视频整理成笔记"
  • "generate document from Bilibili video"

Prerequisites

  • yt-dlp must be installed: pip3 install yt-dlp
  • Browser cookies are needed for Bilibili access (Chrome or other browser)
  • Python 3.10+ for subtitle processing

Workflow

Step 1: Download Subtitles

Use yt-dlp with browser cookies to download the AI Chinese subtitles:

yt-dlp --cookies-from-browser chrome "<BILIBILI_URL>" \
  --write-subs --sub-lang ai-zh \
  --skip-download \
  -o "/tmp/bilibili_output"

Also get the video title:

yt-dlp --cookies-from-browser chrome "<BILIBILI_URL>" \
  --print "%(title)s" --skip-download 2>&1 | tail -1

If chrome browser cookies are not available, try safari, firefox, or edge.

Step 2: Parse SRT and Generate Document

Read the downloaded .ai-zh.srt file, then:

  1. Strip SRT formatting: Remove sequence numbers, timestamps, empty lines
  2. Merge consecutive lines: Combine fragmented subtitle lines into complete sentences
  3. Identify logical sections: The AI should read through the full transcript and identify:
    • Topic/theme divisions
    • Step-by-step procedures
    • Key concepts and definitions
    • Configuration examples / code blocks
  4. Structure the document with proper heading hierarchy

Step 3: Document Structure

Generate a Markdown document following this structure (from reference template):

# {Video Title}

> 来源:B站视频 {BV号} | 主讲:{author}

---

## 一、{Topic Overview}

{Summary of what the video covers}

## 二、{Main Content Sections}

{Organized by logical topic divisions}

## N、总结

{Key takeaways}

Read the full file on GitHub · 109 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 12d ago First seen · 109 lines · 93 tokens per session scan A f2b5e4cddad7

Subscribe to this mod's changes

bilibili-to-doc is a skill published in the GitHub repository programmerloverun/bilibili-to-doc (96 stars, last pushed 2mo ago), licensed MIT. It adds 93 tokens to every session and 892 once invoked, about $0.0005 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

youtube-fetcher

Retrieve YouTube transcripts and subtitles, summarize or analyze what was said, or save an Obsidian-ready Markdown knowledge-base note with captions, creator metadata, chapters, language, and source provenance. Use for a YouTube URL or video ID when the request needs spoken content or an archival note. A bare YouTube…

JimmySadek/youtube-fetcher-to-markdown · 74 tokens

larksnap-fetch

A bridge for downloading Feishu/Lark documents or ordinary webpages into local files, with options such as Markdown, HTML, or PDF. Feishu, also called Lark, is a workplace collaboration platform.

AmbroseX/larksnap · 111 tokens

bili-note

A tool for turning Bilibili videos and posts into readable Markdown notes. Bilibili is a Chinese video and social-content platform; the tool can work with subtitles, article text, images, code, and selected comments.

Rimagination/bili-note · 86 tokens

install-by2kb

Install, configure, update, or diagnose by2kb for an Agent user. Defaults to local faster-whisper and local Markdown; use a cloud ASR provider only when the user explicitly chooses one.

Charlesmpc/by2kb · 45 tokens

obsidian-cli

Interact with Obsidian vaults using the Obsidian CLI to read, create, search, and manage notes, tasks, properties, and more. Also supports plugin and theme development with commands to reload plugins, run JavaScript, capture errors, take screenshots, and inspect the DOM. Use when the user asks to interact with their…

michaeljauk/brain-starter · 102 tokens

anything-to-md

Universal document to Markdown converter. Convert any file (PDF, Word, Excel, PPT, images, audio, video, YouTube URLs) to clean LLM-ready Markdown. Use when: User wants to convert documents to Markdown User needs to process entire directories of files User has YouTube videos or audio files to transcribe User wants to…

1596941391qq/anything-to-md · 265 tokens