{"id":42804939,"url":"https://github.com/dudarev/ytt","last_synced_at":"2026-01-30T03:54:14.398Z","repository":{"id":292733431,"uuid":"971803294","full_name":"dudarev/ytt","owner":"dudarev","description":"Command-line tool for fetching YouTube video transcripts with preferred languages, caching, and clipboard-friendly output.","archived":false,"fork":false,"pushed_at":"2026-01-02T12:18:26.000Z","size":165,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2026-01-08T14:47:40.694Z","etag":null,"topics":["caching","cli","clipboard","python","transcript","transcription","uv","youtube","youtube-transcript-api"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/dudarev.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":"AGENTS.md","dco":null,"cla":null}},"created_at":"2025-04-24T04:50:20.000Z","updated_at":"2026-01-02T12:18:30.000Z","dependencies_parsed_at":"2025-10-01T20:06:09.872Z","dependency_job_id":"2236afa6-d521-48c5-8cfa-4168ec95db63","html_url":"https://github.com/dudarev/ytt","commit_stats":null,"previous_names":["dudarev/ytt"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/dudarev/ytt","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dudarev%2Fytt","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dudarev%2Fytt/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dudarev%2Fytt/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dudarev%2Fytt/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dudarev","download_url":"https://codeload.github.com/dudarev/ytt/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dudarev%2Fytt/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28900390,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-30T03:36:35.398Z","status":"ssl_error","status_checked_at":"2026-01-30T03:36:34.949Z","response_time":66,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["caching","cli","clipboard","python","transcript","transcription","uv","youtube","youtube-transcript-api"],"created_at":"2026-01-30T03:54:13.792Z","updated_at":"2026-01-30T03:54:14.392Z","avatar_url":"https://github.com/dudarev.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# YouTube Transcript Tool (ytt)\n\nA simple command-line interface (CLI) tool to fetch and display the transcript of a YouTube video using pre-configured preferred languages.\n\nThis tool wraps the [youtube-transcript-api](https://github.com/jdepoix/youtube-transcript-api) Python library, simplifying the process of fetching YouTube video transcripts.\n\n\n## Features\n- Automatically extracts video ID from multiple YouTube URL formats (including Shorts)\n- Outputs video title and description along with the transcript in Markdown format\n- Automatically copies the output to the clipboard\n- Prioritizes manually created transcripts based on preferred languages\n- Falls back to automatically generated transcripts if no manual ones are available\n- Caches previously fetched transcripts and metadata to speed up repeated requests\n\n\n## Installation\n\n### Try it instantly with `uvx`\n\n[`uvx`](https://docs.astral.sh/uv/concepts/tools/#uvx) lets you run tools directly from a repository without installing them permanently:\n\n```bash\nuvx --from git+https://github.com/dudarev/ytt.git ytt --help\n```\n\nThis downloads and executes the latest version of `ytt`. You can swap `--help` for any other command arguments.\n\n### Global installs with `uv`\n\nInstall the CLI globally when you want it always available on your PATH:\n\n```bash\nuv tool install --force --from git+https://github.com/dudarev/ytt.git ytt\n```\n\nThe `--force` flag ensures you always get the latest version, even if the tool is already installed.\n\nIf you prefer to install from a local checkout (for example, after building release artifacts), run the following from inside the repository directory:\n\n```bash\nuv tool install --force --from . ytt\n```\n\nYou can remove a global installation at any time with:\n\n```bash\nuv tool uninstall ytt\n```\n\n### Develop from a local checkout\n\n1.  **Clone the repository (or download the source code):**\n    ```bash\n    git clone https://github.com/dudarev/ytt.git\n    cd ytt\n    ```\n\n2.  **Install the project along with its optional test dependencies:**\n\n    ```bash\n    uv pip install --reinstall -e .[test]\n    ```\n\n    The `--reinstall` flag forces `uv` to refresh the editable install so you always develop against the current source. The `[test]` extra pulls in the tools required to run the test suite.\n\n    Alternatively, you can use the provided `Makefile` helpers:\n\n    ```bash\n    make            # shows available commands\n    make install-local       # installs the package in editable mode with test dependencies (forced reinstall)\n    make install-global      # installs the current checkout globally (forced reinstall)\n    make uninstall-global    # removes the globally installed ytt tool\n    make test                # runs the test suite via pytest\n    ```\n\n\n## Usage\n\nThere are two main commands: `config` and `fetch` (which is the default).\n\n### 1. Configure Preferred Languages (Required First Step)\n\nBefore fetching any transcripts, you **must** configure your preferred language codes. The tool will try these languages in the order you specify.\n\nRun the `config` command:\n\n```bash\nytt config languages \u003clang1\u003e,\u003clang2\u003e,...\n```\n\n**Example:** Set English, then Spanish, then French as preferred languages:\n\n```bash\nytt config languages en,es,fr\n```\n\nThis saves your preferences to a configuration file (e.g., `~/.config/ytt/config.json` on Linux/macOS).\n\n### 2. Fetch Transcript\n\nOnce languages are configured, run the tool providing the URL of the YouTube video. If you omit the URL entirely, YTT will try to read a YouTube link from your clipboard:\n\n```bash\nytt \"\u003cyoutube_url\u003e\"\n```\n*(This implicitly uses the `fetch` command)*\n\nTip: Always wrap the YouTube URL in quotes in your shell (this avoids issues with characters like `\u0026`).\n\n```bash\nytt  # Uses clipboard contents when no URL is supplied\n```\n\nBy default, the tool will output the canonical video URL as the first line, followed by the video's title and description, and then the transcript, all formatted in Markdown. The output is also automatically copied to your clipboard.\n\n**Example:**\n\n```bash\nytt \"https://www.youtube.com/watch?v=dQw4w9WgXcQ\"\n```\n\nOutput:\n```\nhttps://www.youtube.com/watch?v=dQw4w9WgXcQ\n\n# Video Title\n\n## Description\nDescription text here...\n\n## Transcript\n[transcript lines]\n```\n\nThe tool prioritizes manually created transcripts and will attempt your preferred languages in the given order.\nIf successful, it will print the URL, title, description and the transcript text to standard output. Errors will be printed to standard error.\n\n**Controlling Output:**\n\nYou can control the output with the following flags:\n\n*   `--no-url`: Suppress the video URL line.\n*   `--no-title`: Suppress the video title.\n*   `--no-description`: Suppress the video description.\n*   `--no-metadata`: Suppress the URL, title, and description.\n*   `--no-copy`: Do not copy the output to the clipboard.\n\n**Redirecting Output:**\n\nEven though the output is automatically copied to the clipboard, you can still redirect it to a file:\n\n```bash\nytt \"\u003cyoutube_url\u003e\" \u003e transcript.md\n```\n\n## Supported URL Formats\n\nThe tool attempts to extract the video ID from common YouTube URL formats, including:\n\n*   `https://www.youtube.com/watch?v=VIDEO_ID`\n*   `https://youtu.be/VIDEO_ID`\n*   `https://www.youtube.com/embed/VIDEO_ID`\n*   `https://www.youtube.com/v/VIDEO_ID`\n*   `https://www.youtube.com/shorts/VIDEO_ID`\n\n## License\n\n[MIT License](LICENSE.md)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdudarev%2Fytt","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdudarev%2Fytt","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdudarev%2Fytt/lists"}