Skip to main content

Convert llms.txt to Claude Code Skill format

Project description

llmstxt2skill

Convert llms.txt files to Claude Code Skill format.

Installation

pip install llmstxt2skill

For development:

git clone https://github.com/akuwano/llmstxt2skill.git
cd llmstxt2skill
uv pip install -e ".[dev]"

Usage

# Basic usage
llmstxt2skill https://docs.databricks.com/llms.txt

# Preview without writing (dry-run)
llmstxt2skill https://docs.databricks.com/llms.txt --dry-run

# Custom skill name
llmstxt2skill https://docs.databricks.com/llms.txt --name databricks

# Custom output directory
llmstxt2skill https://docs.databricks.com/llms.txt -o ./skills

# Overwrite existing skill
llmstxt2skill https://docs.databricks.com/llms.txt --force

Options

Option Description
--name Custom skill name (defaults to kebab-case of title)
-o, --output Output directory (defaults to ~/.claude/skills)
--dry-run Preview output without writing files
--force Overwrite existing skill
--enrich Use LLM to generate enriched skill with curation and localization
--provider LLM provider: databricks, openai, anthropic, openai-compatible (default: databricks)
--lang Target language for enriched skill (default: ja)
--model Model identifier (defaults to provider's default model)

LLM Enrichment

Use --enrich to generate high-quality skills with:

  • Localized content (Japanese by default)
  • Curated and categorized links
  • Trigger conditions for when to use the skill
  • Capabilities and limitations
  • Usage instructions

Note: The --enrich option calls external LLM APIs, which may incur costs depending on your provider and usage.

Supported Providers

Provider Environment Variables Default Model
databricks DATABRICKS_HOST, DATABRICKS_TOKEN databricks-gemini-3-pro
openai OPENAI_API_KEY gpt-4o-mini
anthropic ANTHROPIC_API_KEY claude-3-5-sonnet-20241022
openai-compatible OPENAI_BASE_URL, OPENAI_API_KEY (optional) default

Note: The openai-compatible provider is intended for local LLM servers (vLLM, Ollama, llama.cpp) and uses HTTP by default. For production use with remote endpoints, ensure HTTPS is configured.

Examples

# Databricks (default provider)
export DATABRICKS_HOST="https://your-workspace.cloud.databricks.com"
export DATABRICKS_TOKEN="your-token"
llmstxt2skill https://docs.databricks.com/llms.txt --enrich

# OpenAI
export OPENAI_API_KEY="sk-..."
llmstxt2skill https://example.com/llms.txt --enrich --provider openai

# Anthropic
export ANTHROPIC_API_KEY="sk-ant-..."
llmstxt2skill https://example.com/llms.txt --enrich --provider anthropic

# Local LLM (vLLM, Ollama, llama.cpp server)
export OPENAI_BASE_URL="http://localhost:8000"
llmstxt2skill https://example.com/llms.txt --enrich --provider openai-compatible --model llama3

# Specify model explicitly
llmstxt2skill https://example.com/llms.txt --enrich --provider openai --model gpt-4o

# English output
llmstxt2skill https://example.com/llms.txt --enrich --lang en

Output

By default, skills are written to ~/.claude/skills/{skill-name}/SKILL.md

Use -o or --output to specify a custom output directory:

llmstxt2skill https://example.com/llms.txt -o ./my-skills
# Output: ./my-skills/{skill-name}/SKILL.md

Example

Input (llms.txt):

# Databricks Documentation

> Comprehensive documentation for the Databricks platform.

## Overview
- [Main docs](https://docs.databricks.com/) - How-to guides

Output (SKILL.md):

---
name: databricks-documentation
description: Comprehensive documentation for the Databricks platform.
---

# Databricks Documentation

Comprehensive documentation for the Databricks platform.

## Overview
- [Main docs](https://docs.databricks.com/) - How-to guides

Development

# Install dev dependencies
uv pip install -e ".[dev]"

# Run tests
uv run pytest tests/ -v

# Run linter
uv run ruff check src/ tests/

License

Apache License 2.0 - see LICENSE for details.

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

llmstxt2skill-0.2.2.tar.gz (15.4 kB view details)

Uploaded Source

Built Distribution

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

llmstxt2skill-0.2.2-py3-none-any.whl (22.5 kB view details)

Uploaded Python 3

File details

Details for the file llmstxt2skill-0.2.2.tar.gz.

File metadata

  • Download URL: llmstxt2skill-0.2.2.tar.gz
  • Upload date:
  • Size: 15.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.1

File hashes

Hashes for llmstxt2skill-0.2.2.tar.gz
Algorithm Hash digest
SHA256 c287c77dff37f3a821740936277218064fca8518578aa2f2d3ed610a31421a1f
MD5 691621d4e1c3dd6f2492aa704426c568
BLAKE2b-256 1685f2026a7534630967ca214f60ecc9a979a299b24cb4b7d722f682990d528c

See more details on using hashes here.

File details

Details for the file llmstxt2skill-0.2.2-py3-none-any.whl.

File metadata

  • Download URL: llmstxt2skill-0.2.2-py3-none-any.whl
  • Upload date:
  • Size: 22.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.1

File hashes

Hashes for llmstxt2skill-0.2.2-py3-none-any.whl
Algorithm Hash digest
SHA256 de22b37d109417ef0c739832e74ff54225d6819c573be02ef2e8edeb62c9e409
MD5 311c3816aefe1d642d84b397a181714d
BLAKE2b-256 a71d62901a1fb1b58395db53912ef613b29174801fc2731ab59219885dbbf958

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