TubeKiroku
Fetches publicly available YouTube captions and oEmbed metadata for a video, stores immutable transcript versions in a local library, and returns the full transcript page by page as timestamped paragraphs or timed segments with jump links, plus the passage around a given moment for verifying quotes before citing them.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@TubeKiroku what's said around 12:34 in https://youtu.be/dQw4w9WgXcQ?"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
TubeKiroku
A self-hosted MCP server for YouTube transcripts. Connect it to Claude, ChatGPT or any other Model Context Protocol client, then ask for a video's transcript, read it page by page, and cite the exact moment behind an answer.
Kiroku (記録) is Japanese for "record".
You: What command does this tutorial use to deploy? https://youtu.be/...
Assistant: (calls get_transcript) At 12:34 the presenter runs `docker stack deploy ...`
▶ https://www.youtube.com/watch?v=...&t=754sWhy
Pasting a YouTube link into an assistant identifies the video, but the assistant still needs the spoken words to answer questions about what was actually said. TubeKiroku fetches the captions, keeps them in a local library, and returns them with timestamps so every claim can be checked.
Full text, not a summary. Transcripts are returned verbatim, in pages, with an explicit continuation cursor. Summarizing is the assistant's job, and it can tell when it has not read everything.
Citations that hold. Every segment has a jump link. Transcript versions are immutable, so a citation still points to the same words after the captions change.
Honest failures. No captions, wrong language, blocked network: each is a distinct error code. An empty or failed fetch is never presented as a complete transcript.
Runs on your machine. Transcripts are fetched from your own connection and stored in a local SQLite file. No account, no hosted service, no telemetry.
Related MCP server: Capslane YouTube transcript MCP server
Status
Early development. Working today: single videos and channel imports. In progress:
Single videos: metadata, caption languages, paginated transcripts, timed passages
Channel imports as resumable background jobs
Full-text search across your library with timestamped results
Export (TXT / Markdown / ZIP), file import (SRT / VTT / TXT), deletion
Docker image with HTTP transport, local setup page, and a tunnel profile for ChatGPT
PyPI release and MCP Registry listing
Install
Requires uv. TubeKiroku is not on PyPI yet, so run it from GitHub.
Claude Code
claude mcp add tubekiroku -- uvx --from git+https://github.com/chethankailash/tubekiroku tubekirokuClaude Desktop, Cursor, VS Code and other stdio clients: add to the client's MCP config
(for Claude Desktop, claude_desktop_config.json):
{
"mcpServers": {
"tubekiroku": {
"command": "uvx",
"args": ["--from", "git+https://github.com/chethankailash/tubekiroku", "tubekiroku"]
}
}
}Streamable HTTP (for clients that connect by URL):
uvx --from git+https://github.com/chethankailash/tubekiroku tubekiroku --transport http --port 8000
# MCP endpoint: http://127.0.0.1:8000/mcpChatGPT and claude.ai on the web reach MCP servers from their own cloud, so they cannot see
localhost. A Docker setup with a protected tunnel is planned for them.
Tools
Tool | What it does |
| Resolve any YouTube link to its ID, title, channel and saved transcript versions. |
| List caption tracks: language, origin (creator or automatic), saved or not. |
| The full transcript, one page at a time, as timestamped paragraphs or timed segments with jump links. |
| The passage around a moment, with surrounding context, to verify a quote before citing it. |
| Resolve a channel URL, |
| A channel's uploads, newest first (Shorts and past streams included), paged. |
| Save transcripts for the latest N or all uploads as a background job. Previews first; starts only with |
| Re-run a channel's last import to pick up new uploads; saved transcripts are reused. |
| Phase, totals per outcome (ready, absent, unavailable, retry, failed), per-video results and next steps. |
| Follow, stop and resume imports. |
| Channels in your library with their saved transcript counts. |
| Version, health and library location. |
Errors are returned as JSON with a stable code (invalid_input, no_captions,
language_unavailable, video_unavailable, empty_track, blocked, network_error,
upstream_error, cursor_invalid) and a retryable flag.
Channel imports
An import is saved in the library before any work starts, so it survives a closed chat or a restart: with stdio clients the server stops when the client closes, and the job picks up where it left off the next time the server starts. Each video ends in one of these states:
ready: transcript saved (or an existing saved transcript reused)
absent: YouTube confirmed there are no usable captions
unavailable: private, removed or otherwise unplayable
failed: a temporary error persisted after 3 attempts with backoff (
retry_jobtries again)
If YouTube starts rate-limiting your network, the whole job pauses with growing backoff instead of
burning through attempts, and stops after repeated blocks so you can resume it later. Fetches are spaced
out (TUBEKIROKU_FETCH_DELAY) to keep the load on YouTube light.
Configuration
Variable | Default | Purpose |
|
| Where the SQLite library lives. |
| unset | HTTP(S) proxy for YouTube requests, if your network is blocked. |
|
| Seconds to wait between transcript fetches during imports. |
|
| Upper limit on videos per channel import. |
|
|
|
|
| HTTP bind address. |
How it works
MCP client ──tools──▶ server.py ──┬──▶ library.py ───▶ SQLite: videos, transcript versions, cues
├──▶ channels.py channels, channel membership
└──▶ jobs.py ◀── worker import jobs and per-video items
│
sources/youtube.py ◀────────┴──▶ sources/channels.py
(captions + oEmbed) (channel page + yt-dlp upload listing)library.py, channels.py and jobs.py hold the logic and know nothing about MCP, so other interfaces
can reuse them. Jobs advance one unit of work at a time (list the uploads, or fetch one video), commit
after each, and hold a short lease so two server processes sharing a library never work on the same job.
Sources sit behind small adapter interfaces; file imports and the official YouTube Data API are planned
as additional adapters.
Personal use and YouTube's terms
TubeKiroku is a tool you run yourself, for your own use. It retrieves captions that YouTube shows publicly, from your own network, and stores them only on your machine. You are responsible for how you use it and for complying with YouTube's Terms of Service and the rights of video creators. The project does not operate a public instance and does not redistribute transcripts. Do not deploy it as a public service that fetches transcripts on behalf of others.
TubeKiroku is not affiliated with or endorsed by YouTube or Google.
Development
git clone https://github.com/chethankailash/tubekiroku && cd tubekiroku
uv sync
uv run pytest # tests use a fake source and never touch the network
uv run ruff check . && uv run ruff format --check .
npx @modelcontextprotocol/inspector uv run tubekiroku # try the tools interactivelyLicense
Available Tools
14 toolscancel_jobAIdempotent
Stop a running import. Transcripts already saved are kept; retry_job resumes it later.
Inputs: job_id (required). Returns: kind, items, limit, scope, +14 more
get_channel_infoBRead-only
Resolve a channel: ID, title, handle, estimated uploads, and how much of it is already saved.
Inputs: channel (required). Returns: url, title, handle, last_job, +5 more
get_job_statusBRead-only
Report an import job's phase, totals per outcome, per-video results and what to do next.
Inputs: job_id (required), limit, cursor, item_status. Returns: kind, items, limit, scope, +14 more
get_transcriptARead-only
Return the full transcript of a YouTube video, one page at a time.
The transcript is saved to the local library on first fetch, so later reads are instant.
A page with a non-null next_cursor is only part of the transcript: call again with that cursor
to read the rest. Summarizing is up to you; this tool always returns the original words.
Inputs: video, cursor, format, origin, +3 more. Returns: text, title, offset, origin, +10 more
get_transcript_segmentARead-only
Return the timed passage around a moment in a video, with nearby context and jump links.
Use it to verify or expand a quote before citing it.
Inputs: start_ms (required), video, end_ms, version, +2 more. Returns: title, end_ms, origin, version, +5 more
get_video_infoBRead-only
Resolve a YouTube video: canonical ID, title, channel, and any transcript versions already saved.
Inputs: video (required), refresh. Returns: url, title, video_id, channel_url, +2 more
import_channelAIdempotent
Save transcripts for a channel's uploads into the library, as a resumable background job.
Call first without confirm to preview the scope and show it to the user. With confirm=true the
job starts and returns a job_id; it keeps running if the chat ends. Already saved transcripts are
reused. Use get_job_status to follow progress.
Inputs: channel (required), limit, scope, confirm, +2 more. Returns: limit, scope, job_id, status, +5 more
list_channel_videosARead-only
List a channel's uploads, newest first (Shorts and past streams included), marking saved transcripts.
Inputs: limit, cursor, channel. Returns: offset, videos, channel, next_cursor, +1 more
list_jobsBRead-only
List recent import jobs, newest first, with their totals.
Inputs: limit. Returns: jobs
list_languagesBRead-only
List the caption tracks a video offers: language, origin (creator or auto) and whether it is saved.
Inputs: video (required). Returns: tracks, video_id
list_saved_channelsBRead-only
List channels in the library with known videos, saved transcripts and their latest import.
Inputs: no named parameters. Returns: channels
refresh_channelAIdempotent
Re-run a channel's last import to pick up new uploads. Saved transcripts are reused, not refetched.
Inputs: channel (required), confirm, request_key. Returns: limit, scope, job_id, status, +5 more
retry_jobAIdempotent
Resume a stopped, cancelled or finished job, giving failed videos a fresh set of attempts.
Inputs: job_id (required). Returns: kind, items, limit, scope, +14 more
server_infoARead-only
Report the TubeKiroku server version, health and where the library is stored.
Inputs: no named parameters. Returns: name, status, version, data_dir
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 14 tools
Most tools target clearly distinct resources: videos, channels, jobs, and per-video metadata. The only real overlap is the trio import_channel / refresh_channel / retry_job, which all (re)start transcript imports and could be misselected, though the descriptions do differentiate preview, increment, and resume semantics. get_transcript vs get_transcript_segment are well separated by scope.
Nearly all tools follow a clean verb_noun snake_case pattern (list_jobs, get_video_info, import_channel, cancel_job). The single outlier is server_info, which breaks the verb-first convention but is still perfectly readable. Overall very predictable.
14 tools is well within the sweet spot for a server covering video metadata, transcripts, channel imports, and job lifecycle. Each tool maps to a distinct operation with no filler.
The lifecycle is well covered: resolve, list, import (with preview/confirm), monitor, cancel, retry, and refresh. Gaps are minor but real: there is no way to delete or prune saved transcripts/channels, and no cross-library search beyond listing, which are likely asks given the server explicitly maintains a persistent local library.
Maintenance
Related MCP Connectors
Transcripts, translations, summaries, subtitles, and search for public YouTube videos.
Transcripts, on-screen text, timelines, key moments, summary and cited answers from your video, audio, images and documents, callable from any MCP client
YouTube transcript API: batch video captions, timestamps, metadata and SRT/VTT subtitles.
Extract YouTube transcripts, search what was said, and read on-screen frames with cited timestamps.
Related MCP Servers
- AlicenseNot gradedqualityCmaintenanceFetches YouTube video subtitles (transcripts) over MCP, enabling clients like Claude to retrieve and summarize video content.MIT
- AlicenseAqualityDmaintenanceEnables MCP clients such as Claude Code, Codex and Cursor to retrieve timestamped transcripts of public YouTube videos, either from cache, from native captions, or via asynchronous audio-generation jobs that are polled by job ID. It returns the source URL, selected language and millisecond-offset segments without summarizing the video itself.389 npm1MIT
- AlicenseAqualityBmaintenanceEnables MCP clients to list available caption languages, fetch publicly available YouTube caption tracks with timestamps, and request client-assisted summaries without transcribing audio.23269 npmMIT
- AlicenseNot gradedqualityBmaintenanceEnables MCP clients to fetch and read YouTube captions in chunks, inspect available languages and video info, and save full transcripts or generated notes as Markdown.MIT