Skip to main content

YouTube video analysis and X feed digest pipeline exposed as MCP tools

Project description

mcp-content-pipeline

PyPI version Downloads License: MIT Python

A content analysis and digest pipeline for YouTube videos and X (Twitter) feeds, exposed as MCP tools. Extract transcripts, fetch posts from curated accounts, and generate key takeaways, TLDRs, social hooks, and comic-book infographics — all callable by any MCP-compatible AI client like Claude Desktop.

Why?

Keeping up with YouTube channels and X accounts means scattered tabs, manual note-taking, and lost insights. This MCP server turns content consumption into structured, chainable tools. Analyse a Bloomberg video, digest your X feed, generate infographics, and sync everything to GitHub — all from a single conversation with Claude.

Quick Start

uvx mcp-content-pipeline

Or install explicitly:

uv tool install mcp-content-pipeline
mcp-content-pipeline

Claude Desktop Configuration

Add to your Claude Desktop MCP config (~/Library/Application Support/Claude/claude_desktop_config.json):

{
  "mcpServers": {
    "content-pipeline": {
      "command": "/usr/local/bin/uvx",
      "args": ["mcp-content-pipeline"],
      "env": {
        "MCP_CP_ANTHROPIC_API_KEY": "sk-ant-...",
        "MCP_CP_SUPADATA_API_KEY": "sd_...",
        "MCP_CP_GITHUB_TOKEN": "ghp_...",
        "MCP_CP_GITHUB_REPO": "your-username/your-repo",
        "MCP_CP_GEMINI_API_KEY": "your-gemini-api-key",
        "MCP_CP_X_BEARER_TOKEN": "your-x-bearer-token",
        "MCP_CP_X_ACCOUNTS": "karpathy,bcherny,atmoio,steipete",
        "MCP_CP_X_TOPICS": "AI,tech,engineering"
      }
    }
  }
}

Usage

Once configured in Claude Desktop, use the tools in a single conversation:

YouTube Analysis

"Analyse this video: https://www.youtube.com/watch?v=..." "Generate an image for this analysis" "Sync the analysis and image to GitHub"

Or all in one prompt:

"Analyse this video, generate the image, and sync to GitHub: https://www.youtube.com/watch?v=..."

X Feed Digest

"Analyse the X feed" "Analyse what karpathy, bcherny, atmoio, and steipete posted about AI today" "Analyse the top posts from the last week"

Or with the full pipeline:

"Analyse the X feed, generate the image, and sync to GitHub"

Tools

Tool Description Requires
analyse_video Analyse a single YouTube video — transcript, takeaways, TLDR, social hook ANTHROPIC_API_KEY, SUPADATA_API_KEY
batch_analyse Analyse multiple videos from a URL list or config file ANTHROPIC_API_KEY, SUPADATA_API_KEY
list_channel_videos Fetch recent videos from a YouTube channel YOUTUBE_API_KEY
sync_to_github Push analyses as markdown files to a GitHub repo GITHUB_TOKEN, GITHUB_REPO
analyse_x_feed Analyse recent posts from curated X accounts — daily digest X_BEARER_TOKEN
generate_image Generate comic-book infographic from analysis result GEMINI_API_KEY

Environment Variables

All prefixed with MCP_CP_:

Variable Required Description
MCP_CP_ANTHROPIC_API_KEY Yes Anthropic API key for Claude analysis
MCP_CP_SUPADATA_API_KEY Yes for YouTube Supadata API key for YouTube transcript extraction
MCP_CP_YOUTUBE_API_KEY No YouTube Data API v3 key (only for list_channel_videos)
MCP_CP_GITHUB_TOKEN For sync GitHub personal access token
MCP_CP_GITHUB_REPO For sync Target repo in owner/repo format
MCP_CP_GITHUB_BRANCH No Branch to push to (default: main)
MCP_CP_GITHUB_OUTPUT_DIR No Output directory in repo (default: content/videos)
MCP_CP_CLAUDE_MODEL No Claude model to use (default: claude-sonnet-4-20250514)
MCP_CP_MAX_TRANSCRIPT_TOKENS No Max transcript length in tokens (default: 100000)
MCP_CP_GEMINI_API_KEY For image Google AI Studio API key for image generation
MCP_CP_GEMINI_MODEL No Gemini model for images (default: gemini-3.1-flash-image-preview)
MCP_CP_X_BEARER_TOKEN For X digest X API v2 bearer token
MCP_CP_X_ACCOUNTS For X digest Comma-separated X usernames
MCP_CP_X_TOPICS No Comma-separated topics (default: AI,tech)

Cost Projections

Estimated monthly costs for two usage patterns:

Service Daily (every day) Weekly X + daily YouTube
YouTube analysis (Claude API) ~$3–5/mo (1 video/day) ~$3–5/mo (1 video/day)
X feed digest (Claude API) ~$2–3/mo ~$0.50/mo
Image generation (Gemini API) ~$2/mo ($0.067/image) ~$2/mo ($0.067/image)
X API reads ~$4/mo ($0.13/day) ~$0.60/mo ($0.15/week)
Total ~$11–14/mo ~$6–8/mo

Claude API costs depend on your Anthropic billing plan and are separate from the X API and Gemini totals shown above. The X API spending cap can be configured in the developer console.

Development

git clone https://github.com/your-username/mcp-content-pipeline.git
cd mcp-content-pipeline
uv sync
uv run pytest -v --cov=src/mcp_content_pipeline
uv run ruff check src/ tests/

Security

  • All credentials are configured via local environment variables — never committed to the repo
  • The tool is open source but your API keys, YouTube key, and GitHub token stay on your machine
  • Never create a .env file in the repo — use shell exports or Claude Desktop config instead

Contributing

  1. Fork the repository
  2. Create a feature branch (git checkout -b feat/my-feature)
  3. Commit using Conventional Commits (feat: add new feature)
  4. Push and open a Pull Request

License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

mcp_content_pipeline-0.9.0.tar.gz (131.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

mcp_content_pipeline-0.9.0-py3-none-any.whl (26.3 kB view details)

Uploaded Python 3

File details

Details for the file mcp_content_pipeline-0.9.0.tar.gz.

File metadata

  • Download URL: mcp_content_pipeline-0.9.0.tar.gz
  • Upload date:
  • Size: 131.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for mcp_content_pipeline-0.9.0.tar.gz
Algorithm Hash digest
SHA256 7e354d0c326c1ce5d02207d23280bfef1dabbb0fa74c7046b81f0efe3bbea5e5
MD5 714beeb29f6f94272483a1bcf5982540
BLAKE2b-256 4387522b50159f1453d3265fece94c670fe2dd10efa49fa6d4ea21a3bdd65adb

See more details on using hashes here.

Provenance

The following attestation bundles were made for mcp_content_pipeline-0.9.0.tar.gz:

Publisher: release.yml on berkayildi/mcp-content-pipeline

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file mcp_content_pipeline-0.9.0-py3-none-any.whl.

File metadata

File hashes

Hashes for mcp_content_pipeline-0.9.0-py3-none-any.whl
Algorithm Hash digest
SHA256 633d054282996c8a21226addfe7321ffb14da3d738c6ec54cb6d43a8a73ba96e
MD5 923736b327196a5763cd4212ddc2d98b
BLAKE2b-256 605692de5e334ced8e47d1763f4d5ccbbaf96adbaa0be30a41c734b0107584ef

See more details on using hashes here.

Provenance

The following attestation bundles were made for mcp_content_pipeline-0.9.0-py3-none-any.whl:

Publisher: release.yml on berkayildi/mcp-content-pipeline

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page