Skip to main content

MCP server for the Loreto skill generation API — use generate_skills inside Claude Code

Project description

loreto-mcp

Turn any YouTube video, article, PDF, or image into a reusable Claude Code skill — without leaving your editor.


What it does

Loreto analyzes a content source and extracts structured skill packages that Claude Code can apply to future tasks. Each skill contains:

  • SKILL.md — Principles, failure modes, implementation steps, and architectural patterns
  • README.md — Overview and usage context
  • Reference files — Supporting patterns and data structures
  • Test script — Runnable validation for the skill's core concepts

Save skills to .claude/skills/ and Claude picks them up automatically on relevant tasks — reducing hallucinations, token usage, and re-explaining the same concepts over and over.


Sample skills

The sample-skills/ folder contains real skills generated by Loreto from a single technical video on hybrid AI architecture. Browse them to see exactly what you get:

Skill What it teaches
designing-hybrid-context-layers Architect hybrid retrieval systems that combine vector search, graph traversal, and structured data
temporal-reasoning-sleuth Enable agents to trace decision chains and reconstruct causal sequences across long time horizons
synthesizing-institutional-knowledge Capture and query organizational knowledge in a way AI agents can reliably reason over
diagnosing-rag-failure-modes Identify and fix the 7 most common RAG pipeline failure patterns
routing-work-across-ai-harnesses Dynamically route tasks to the right AI harness based on task type and context
evaluating-ai-harness-dimensions Score and compare AI harness options across speed, cost, accuracy, and controllability
detecting-harness-lockin Spot vendor lock-in signals early and design for portability
benchmarking-ai-agents-beyond-models Measure agent performance at the system level, not just model level
auditing-intelligence-context-fit Audit whether the right intelligence layer is solving the right problem

Each folder includes the full SKILL.md, README.md, and any reference files — ready to drop into .claude/skills/.


Setup

1. Authenticate

Two options — pick the one that fits your usage pattern.

Option A — API key (recommended for most users): Sign up at loreto.io to get your free API key (lor_...). Free tier covers 2 calls/month; Pro plan is $29/month for 100 calls.

Option B — Pay per call with x402 (for AI agents and one-off jobs): No signup. Hit the alternate endpoint /api/v1/skills/x402/generate with a wallet that holds USDC on Base mainnet; pay $0.75 per call via the x402 protocol. The MCP package above uses Option A — for Option B integrations, see https://loreto.io/docs-x402 and the official x402 Python SDK.

2. Install

pip install loreto-mcp

Or run directly without installing (requires uv):

uvx loreto-mcp

3. Configure Claude Code

User-scoped (works across all your projects) — add to ~/.claude/mcp.json:

{
  "mcpServers": {
    "loreto": {
      "command": "uvx",
      "args": ["loreto-mcp"],
      "env": {
        "LORETO_API_KEY": "lor_..."
      }
    }
  }
}

Project-scoped (shared with your team) — add to .mcp.json at your project root:

{
  "mcpServers": {
    "loreto": {
      "command": "uvx",
      "args": ["loreto-mcp"],
      "env": {
        "LORETO_API_KEY": "${LORETO_API_KEY}"
      }
    }
  }
}

4. Verify

Restart Claude Code and run /mcp — you should see loreto listed with generate_skills and get_quota.


Usage

Once connected, just ask Claude Code naturally:

Use Loreto to extract skills from https://www.youtube.com/watch?v=JYcidOS9ozU
Extract skills from this article and save them to .claude/skills/
Check my Loreto quota before we start.

Claude calls generate_skills, receives the full skill package, and can write the files directly to your project.


Available tools

Tool Description
generate_skills Extract ranked skill packages from a URL. Returns full file contents ready to save.
get_quota Check calls used, monthly limit, and plan for your API key.

generate_skills parameters

Parameter Type Default Description
source str required URL to analyze — YouTube, article, public PDF, or image
source_type str "auto" "auto" | "youtube" | "article" | "pdf" | "image"
test_language str "python" "python" | "typescript" | "javascript"
include_visuals bool true Embed Mermaid diagrams in SKILL.md
context str null 1–3 sentence hint to guide extraction (max 500 chars)
themes_to_process list[str] null Follow-up call: skill names from a previous response's queued themes

Supported sources

Source Notes
YouTube videos Up to 60 minutes
Web articles Any publicly accessible URL
PDFs Up to 100 pages
Images Diagrams, whiteboards, slides (up to 20 MB)

Configuration

Environment variable Required Default Description
LORETO_API_KEY Yes Your Loreto API key (lor_...)
LORETO_BASE_URL No https://api.loreto.io Override for local development

Plans

Free and paid plans available. See loreto.io/pricing for current limits.


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

loreto_mcp-0.2.0.tar.gz (44.9 kB view details)

Uploaded Source

Built Distribution

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

loreto_mcp-0.2.0-py3-none-any.whl (10.2 kB view details)

Uploaded Python 3

File details

Details for the file loreto_mcp-0.2.0.tar.gz.

File metadata

  • Download URL: loreto_mcp-0.2.0.tar.gz
  • Upload date:
  • Size: 44.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.4

File hashes

Hashes for loreto_mcp-0.2.0.tar.gz
Algorithm Hash digest
SHA256 88c3a5f8f4ae317528dd732b8c8ab7ee783cc1942f88b29ad5de6f702761f64e
MD5 748fddeb411f504300d08d1f6b412944
BLAKE2b-256 2135fd46b1fd065030a34789577b099cd79a6bc2003ebb68b6e3c0e313ec37a4

See more details on using hashes here.

File details

Details for the file loreto_mcp-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: loreto_mcp-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 10.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.4

File hashes

Hashes for loreto_mcp-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 f8d2f68f22c0c8558604dae98dd913f41e8fc39d7431722c13df5f68af3ea9d1
MD5 a0aa752be364bbff6178f1a70b4f0ea1
BLAKE2b-256 da57a8c1c19d605bb6afeb3e1d15d68314fc14bcd2f37a959985feac28decf25

See more details on using hashes here.

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