running-claude-code-via-litellm-copilot
Skill by xixu-me
Routes Claude Code through a local LiteLLM proxy to GitHub Copilot. It is for developers who want to lower direct Anthropic spending and fix proxy setup failures.
Install running-claude-code-via-litellm-copilot
Built from the published package, never by AI.
git clone --depth 1 https://github.com/xixu-me/skills /tmp/skills && mkdir -p ~/.claude/skills && cp -r /tmp/skills/skills/running-claude-code-via-litellm-copilot ~/.claude/skills/running-claude-code-via-litellm-copilotRun in your terminal. Claude Code loads skills from ~/.claude/skills automatically.
Step-by-step: install running-claude-code-via-litellm-copilot in Claude Code
git clone --depth 1 https://github.com/xixu-me/skills /tmp/skills && mkdir -p ~/.gemini/antigravity-cli/skills && cp -r /tmp/skills/skills/running-claude-code-via-litellm-copilot ~/.gemini/antigravity-cli/skills/running-claude-code-via-litellm-copilotAntigravity CLI loads skills from ~/.gemini/antigravity-cli/skills, or .agents/skills for one project.
Step-by-step: install running-claude-code-via-litellm-copilot in Antigravity CLI
Skills can run scripts on your machine. Some need an API key: check the README.
About
This agent skill guides a workaround where Claude Code keeps its Anthropic-shaped client behavior, but backend traffic goes to a local LiteLLM proxy that forwards it to GitHub Copilot. It covers a LiteLLM config.yaml using the github_copilot/<model> provider route, installing and starting LiteLLM on port 4000, and setting ANTHROPIC_BASE_URL, ANTHROPIC_MODEL, and related environment variables.
It also covers GitHub device authorization on the first request, checking the request chain, and troubleshooting model-not-found errors, missing localhost traffic, and GitHub 401 or 403 failures. The source calls it an advanced workaround, not an officially guaranteed GitHub workflow. It is aimed at users who want to reduce direct Anthropic API spending while keeping the Claude Code workflow.
Written from the project's SKILL.md and checked against it.
What it can do
- Proxy configurationWrites a LiteLLM config.yaml that maps a logical Claude model name to a github_copilot route.
- Claude Code environment setupSets ANTHROPIC_BASE_URL, ANTHROPIC_MODEL, and related variables for temporary or persistent use.
- Merge-safe settings editsMerges only the needed env keys into ~/.claude/settings.json and preserves unrelated settings.
- Setup troubleshootingHelps diagnose model-not-found errors, missing proxy requests, and GitHub 401 or 403 failures.
- Header override fallbackDescribes optional extra_headers for cases where the basic Copilot provider flow is rejected.
What you need
- GitHub Copilot access
- Claude Code CLI installed
- uv or pip available
- LiteLLM proxy port available, usually 4000
Try asking
- Set up Claude Code to use GitHub Copilot through a local LiteLLM proxy
- Help me fix a model-not-found error between Claude Code and LiteLLM
- Merge the proxy env keys into my Claude settings without overwriting them
Good to know
- Described as an advanced workaround, not an officially guaranteed GitHub workflow.
- Does not promise GitHub support, policy approval, or long-term compatibility.
- Availability of Copilot-exposed models may change.
Security check
ANo download-and-run commands, hidden instructions or signs of sending keys out were found.
Checked automatically: skills/running-claude-code-via-litellm-copilot/SKILL.md. This looks for known risky patterns and is not a full audit. How grades work
Alternatives to running-claude-code-via-litellm-copilot
All alternatives →Aligns a Qwen Code feature with a Codex or Claude Code reference agent. It runs both under the same scenario, captures HTTP and terminal traces, and compares them until behavior matches.
Searches, views, creates, updates, and deletes the user's Google Contacts from an AI assistant. It is for people who want to manage their address book through conversation. A one-time Google connect is required before it returns data.
Guides an AI assistant on error handling choices. It covers when to use Result, Option, ? propagation, unwrap, expect and panic, plus anyhow and thiserror.
Caveman is an agent skill that makes an AI assistant reply in a terse style. It cuts filler and keeps technical facts, code, commands and errors exact. It is built for users who want shorter, cheaper replies.
docs-sync audits or updates English SDK documentation against the requested implementation scope. It is for maintainers who want docs to match main branch features, configuration options, and defaults.
Guides an AI assistant through setting up and running monorepos with pnpm workspaces, Turborepo and Nx. Aimed at developers who need faster builds, shared code and managed dependencies across multiple packages.
Compare with agent-reproduce-align, google_contacts or m06-error-handling
running-claude-code-via-litellm-copilot: common questions
Does GitHub officially support this setup?
No. The source says it is a workaround based on a local proxy path, not a GitHub-promoted workflow. Users should check the latest Copilot terms themselves.
Is the ANTHROPIC_AUTH_TOKEN value a real Copilot key?
No. The source says Claude Code expects a non-empty local value, but it is a placeholder and not the GitHub Copilot credential.
What must ANTHROPIC_MODEL match?
It must match the LiteLLM model_name exactly, including case, punctuation, and hyphens.
How do I install running-claude-code-via-litellm-copilot?
Run the command above to copy the skill into ~/.claude/skills/. Claude Code picks it up automatically.
Is running-claude-code-via-litellm-copilot free?
The code is published under the MIT licence. The service it connects to may have its own pricing.
Is running-claude-code-via-litellm-copilot safe to use?
It scores 76 of 100. Grades: maintenance A, licence A, quality B. Security check: grade A, no risky patterns found in the files checked. Review the code before you install. How grades work.
What are alternatives to running-claude-code-via-litellm-copilot?
Similar skills: agent-reproduce-align, google_contacts, m06-error-handling, caveman.
