yt-mcp-agent
A YouTube video agent built using a custom MCP server and OpenAI's Agent's SDK. It can extract video transcripts given link fetch specialized instructions for things like: writing blog posts, video chapters, and social posts.
Resources:
This example is a prelude to Cohort 7 of the AI Builders Bootcamp.
Requirements
- Python 3.13+
- OpenAI API key
uvpackage manager (recommended)
How to run this example
uv (recommended)
-
Clone the repository
git clone <repository-url> cd yt-mcp-agent
-
Install dependencies with uv
uv sync -
Set up your OpenAI API key
Create a
.envfile in the root directory:echo "OPENAI_API_KEY=your_api_key_here" > .env
-
Run the agent
uv run main.py
-
Interact with agent
Once running, you can ask the agent to analyze YouTube videos. Try prompts like:
- "Summarize this: https://youtu.be/N3vHJcHBS-w?si=aw8PV0acYHJGPy7R"
- "Generate chapter timestamps with links"
- "Write me a LinkedIn post about the video"
Base Python/pip
-
Clone the repository
git clone <repository-url> cd yt-mcp-agent
-
Create a virtual environment
python -m venv venv source venv/bin/activate # On Windows: venv\Scripts\activate
-
Install dependencies
pip install -e .
-
Set up your OpenAI API key
Create a
.envfile in the root directory:echo "OPENAI_API_KEY=your_api_key_here" > .env
-
Run the agent
python main.py -
Interact with agent
Metadata
Release files for iflow-mcp_shawhint-yt-mcp-agent 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| iflow_mcp_shawhint_yt_mcp_agent-0.1.0.tar.gz | 7.3 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| iflow_mcp_shawhint_yt_mcp_agent-0.1.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 15.5 kB
Release files / iflow_mcp_shawhint_yt_mcp_agent-0.1.0.tar.gz
| Download URL | iflow_mcp_shawhint_yt_mcp_agent-0.1.0.tar.gz |
|---|---|
| Size | 7.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
2578030f2ff8c57068e720b2311c083db6f8240a368072b23e5439de3986df7b
|
|
BLAKE2b-256 checksum How to use checksums |
1aef5e76877ee6a5a213992b1891c4d75bc9a012e7dd3179dc61b20136f69636
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.10.2 {"installer":{"name":"uv","version":"0.10.2","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Debian GNU/Linux","version":"13","id":"trixie","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Release files / iflow_mcp_shawhint_yt_mcp_agent-0.1.0-py3-none-any.whl
| Download URL | iflow_mcp_shawhint_yt_mcp_agent-0.1.0-py3-none-any.whl |
|---|---|
| Size | 8.1 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
2ae311d1b49a7e7b0a9e3b5d7be363ca6fefb0f5a56a14341417c47287eab6b2
|
|
BLAKE2b-256 checksum How to use checksums |
8d1012a7e037b2c2a5dbceab413c3a0b3c5ad02a81c226db1d2908c8661ba174
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.10.2 {"installer":{"name":"uv","version":"0.10.2","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Debian GNU/Linux","version":"13","id":"trixie","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|