Skip to main content

Release Notes Downloads GitHub CI Status License: MIT

Copilot, Cursor, Claude, etc LLM Instructions

This project makes it easy to download prompts and implode/explode them so they can be used by various providers. It's completely vibe coded, but it works.

I don't want to be tied to a specific IDE and it's a pain to have to edit instructions for various languages across a ton of different files.

Additionally, it becomes challenging to copy these prompts into various projects and contribute them back to a single location.

Some of the glob assumptions in this repo are specific to how I've chosen to organize python and typescript in the python starter template and what tooling (fastapi, etc) that I've chosen to use.

IDE Format Comparison

Different AI coding assistants use different formats for instructions and commands:

IDE type folder Notes
Cursor instructions .cursor/rules/*.mdc Multiple plain markdown files
Cursor commands .cursor/commands/*.md Plain markdown, no frontmatter
Claude Code instructions .claude/rules/**/*.md Markdown rules, optional paths: frontmatter
Claude Code commands .claude/commands/*.md Plain markdown, no frontmatter
GitHub Copilot instructions .github/copilot-instructions.md Single markdown file
GitHub Copilot instructions .github/instructions/*.instructions.md Multiple instruction files
GitHub Copilot prompts .github/prompts/*.prompt.md YAML frontmatter with mode: 'agent'
OpenCode instructions AGENTS.md Single markdown file at root
OpenCode commands .opencode/commands/*.md Plain markdown, no frontmatter
Codex instructions AGENTS.md Root and nested markdown files
Codex commands .agents/skills/*/SKILL.md YAML frontmatter with name and description

Installation

uvx llm-ide-rules@latest --help

Usage

CLI Commands

The llm-ide-rules CLI provides commands to manage LLM IDE prompts and rules:

# Convert instruction file to separate rule files.
# Defaults to already-exploded agents on disk, then the current runtime
# (e.g. Cursor Cloud, Claude Code cloud), then all supported agents.
uvx llm-ide-rules explode [agents...]
uvx llm-ide-rules explode cursor claude
uvx llm-ide-rules explode $(llm-ide-rules exploded /path/to/repo)
uvx llm-ide-rules explode cursor --input path.md

# Bundle rule files back into a single instruction file
uvx llm-ide-rules implode cursor [output_file]     # Bundle Cursor rules
uvx llm-ide-rules implode github [output_file]     # Bundle GitHub/Copilot instructions
uvx llm-ide-rules implode claude [output_file]     # Bundle Claude Code rules + commands
uvx llm-ide-rules implode opencode [output_file]   # Bundle OpenCode commands
uvx llm-ide-rules implode codex [output_file]      # Bundle Codex skills + AGENTS.md

# Download instructions.md/commands.md, then explode for the given agents.
# Defaults to already-exploded agents on disk, then the current runtime, then all.
uvx llm-ide-rules download [agents...]
uvx llm-ide-rules download cursor github
uvx llm-ide-rules download cursor,github
uvx llm-ide-rules download --repo other/repo
uvx llm-ide-rules download --inline               # Explode without saving instructions.md or commands.md

# Delete exploded agent files
uvx llm-ide-rules delete [agents...]              # Delete everything by default
uvx llm-ide-rules delete cursor claude
uvx llm-ide-rules delete cursor,claude
uvx llm-ide-rules delete --yes                    # Skip confirmation prompt

Authentication

To avoid GitHub API rate limits or to access private repositories, you can set the GITHUB_TOKEN environment variable. The download command will automatically use this token for authentication.

export GITHUB_TOKEN=your_token_here
uvx llm-ide-rules download

Customizing Instructions

If you have repository-specific instructions that you want to maintain locally while still being able to download upstream updates, you can use the <!-- END CLONED INSTRUCTIONS --> marker.

  1. Add the marker at the end of your local instructions.md.
  2. Add your custom instructions below it.

When you run llm_ide_rules download again, the tool will:

  • Extract everything after the marker in your local file.
  • Download the latest upstream instructions.md.
  • Append your local custom instructions back to the end.
# Upstream Instructions
...

<!-- END CLONED INSTRUCTIONS -->

# My Custom Local Rules
- Use tabs for indentation in this project.

Examples

# Explode instructions.md using disk/runtime detection (or all agents)
uvx llm-ide-rules explode

# Explode for a specific agent only
uvx llm-ide-rules explode opencode
uvx llm-ide-rules explode codex

# Explode for multiple agents
uvx llm-ide-rules explode cursor claude

# Explode the same agents already in use in another checkout
uvx llm-ide-rules explode $(llm-ide-rules exploded /path/to/repo)

# Explode a non-default instruction file
uvx llm-ide-rules explode cursor --input bundled-instructions.md

# Bundle Cursor rules back into a single file
uvx llm-ide-rules implode cursor bundled-instructions.md

# Bundle GitHub instructions with verbose logging
uvx llm-ide-rules implode github --verbose instructions.md

# Bundle OpenCode commands into commands.md
uvx llm-ide-rules implode opencode

# Bundle Codex skills into commands.md and AGENTS.md into instructions.md
uvx llm-ide-rules implode codex

# Download everything from default repository
uvx llm-ide-rules download

# Download only specific instruction types
uvx llm-ide-rules download cursor github
uvx llm-ide-rules download cursor,github

# Download from a different repository
uvx llm-ide-rules download --repo other-user/other-repo --target ./my-project

# Download and explode directly without saving instructions.md or commands.md
uvx llm-ide-rules download --inline

# Delete all downloaded files (with confirmation)
uvx llm-ide-rules delete

# Delete specific instruction types
uvx llm-ide-rules delete cursor claude --target ./my-project

# Delete without confirmation prompt
uvx llm-ide-rules delete --yes

Extracting Changes

The idea of this repo is you'll copy prompts into your various projects. Then, if you improve a prompt in a project, you can pull that change into this upstream repo.

Here's how to do it:

git diff .github/instructions | pbcopy
pbpaste | gpatch -p1

gpatch is an updated version of patch on macOS that seems to work much better for me.


This project was created from iloveitaly/python-package-template

Metadata

Release files for llm-ide-rules 0.20.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for llm-ide-rules 0.20.1
File Size Uploaded
llm_ide_rules-0.20.1.tar.gz 33.3 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for llm-ide-rules 0.20.1
File Interpreter ABI Platform
llm_ide_rules-0.20.1-py3-none-any.whl Python 3 none any Details

Total release size: 81.8 kB

Release files / llm_ide_rules-0.20.1.tar.gz

Download URL llm_ide_rules-0.20.1.tar.gz
Size 33.3 kB
Tags Source
SHA-256 checksum
How to use checksums
ae4c01d765c567e85661e1688efa6fefb9416e33191b025dff196a89ebf328c8
BLAKE2b-256 checksum
How to use checksums
69dcc48e246edcaa768b2a5a8317e7752fe5fa4c389978512a73b8cad9b26eb4
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.12.13 {"installer":{"name":"uv","version":"0.12.13","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release files / llm_ide_rules-0.20.1-py3-none-any.whl

Download URL llm_ide_rules-0.20.1-py3-none-any.whl
Size 48.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
bfaccaee579106e70373d2cf27d0762e9f1d2cd6cdde7df979eb3370670e153e
BLAKE2b-256 checksum
How to use checksums
3deedbc6b0e7bd7b7ac21315e71184b9160cf99dbb9582c3e85f0041b3e0dd20
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.12.13 {"installer":{"name":"uv","version":"0.12.13","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release history Release notifications | RSS feed

This release

0.20.1 This release

2 release files

0.20.0

2 release files

0.19.0

2 release files

0.18.0

2 release files

0.17.0

2 release files

0.14.0

2 release files

0.12.0

2 release files

0.11.0

2 release files

0.10.0

2 release files

0.9.0

2 release files

0.8.0

2 release files

0.7.0

2 release files

0.6.0

2 release files

0.5.0

2 release files

0.4.0

2 release files

0.3.0

2 release files

0.2.1

2 release files

0.2.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page