running-claude-code-via-litellm-copilot

Community

Proxy Claude Code to GitHub Copilot locally

Authorxixu-me
Version1.0.0
Installs0

System Documentation

What problem does it solve?

This skill guides engineers through routing Claude Code traffic via a local LiteLLM proxy to the GitHub Copilot Chat API, reducing direct Anthropic spend and preserving the Claude Code client behavior while forwarding requests to Copilot. It helps users create the necessary LiteLLM model mappings, set temporary or persistent environment keys, and verify the request chain end-to-end.

Core Features & Use Cases

  • Local Proxy Configuration: Create a LiteLLM config.yaml that maps a Claude-facing model_name to a github_copilot/<model> provider and uses drop_params to strip Anthropic-specific fields.
  • Temporary and Persistent Setup: Provide shell-appropriate temporary environment exports for quick tests and safe merge rules for updating ~/.claude/settings.json when persistence is requested.
  • Verification & Troubleshooting: Walk through running litellm, initiating device authorization, confirming logs show inbound requests, and diagnosing model-not-found, no-localhost-traffic, and GitHub 401/403 errors in realistic scenarios.

Quick Start

Provide a minimal LiteLLM config.yaml that maps a logical model_name to github_copilot/<model>, the single command to start litellm on port 4000, and the one-line temporary environment exports needed to point Claude Code at http://localhost:4000.

Dependency Matrix

Required Modules

None required

Components

references

💻 Claude Code Installation

Recommended: Let Claude install automatically. Simply copy and paste the text below to Claude Code.

Please help me install this Skill:
Name: running-claude-code-via-litellm-copilot
Download link: https://github.com/xixu-me/skills/archive/main.zip#running-claude-code-via-litellm-copilot

Please download this .zip file, extract it, and install it in the .claude/skills/ directory.
View Source Repository

Agent Skills Search Helper

Install a tiny helper to your Agent, search and equip skill from 471,000+ vetted skills library on demand.