From xixu-me-skills-3
Routes Claude Code through local LiteLLM proxy to GitHub Copilot for reduced Anthropic costs; configures ANTHROPIC_BASE_URL/MODEL overrides and troubleshoots errors like model-not-found, no localhost traffic, or 401/403 auth failures.
npx claudepluginhub joshuarweaver/cascade-ai-ml-engineering --plugin xixu-me-skills-3This skill uses the workspace's default tool permissions.
Use this skill for the specific workaround where Claude Code keeps its Anthropic-shaped client behavior, but the actual backend traffic is sent to a local LiteLLM proxy and then forwarded to GitHub Copilot.
Guides Next.js Cache Components and Partial Prerendering (PPR) with cacheComponents enabled. Implements 'use cache', cacheLife(), cacheTag(), revalidateTag(), static/dynamic optimization, and cache debugging.
Guides building MCP servers enabling LLMs to interact with external services via tools. Covers best practices, TypeScript/Node (MCP SDK), Python (FastMCP).
Generates original PNG/PDF visual art via design philosophy manifestos for posters, graphics, and static designs on user request.
Use this skill for the specific workaround where Claude Code keeps its Anthropic-shaped client behavior, but the actual backend traffic is sent to a local LiteLLM proxy and then forwarded to GitHub Copilot.
Treat this as an advanced workaround, not an officially guaranteed GitHub workflow. Help the user succeed technically, but do not promise GitHub support, policy approval, or long-term compatibility.
This skill is guidance-first but execution-aware:
~/.claude/settings.json or shell profile files.Read references/doc-verified-notes.md before answering if you need to justify which parts come from the article and which parts were tightened against current LiteLLM docs.
Use this skill when the user wants any of the following:
config.yaml for LiteLLM's GitHub Copilot providerANTHROPIC_BASE_URL, ANTHROPIC_MODEL, or CLAUDE_CODE_DISABLE_NONESSENTIAL_TRAFFIC setupDo not use this skill for:
config.yaml unless the user explicitly wants a persistent setup.ANTHROPIC_MODEL and LiteLLM model_name identical.
Exact string match matters more than clever explanation.ANTHROPIC_AUTH_TOKEN as a local placeholder.
Claude Code expects a non-empty value locally, but it is not the GitHub Copilot credential and should not be presented as a reusable secret.~/.claude/settings.json wholesale.
Merge only the needed env keys and preserve unrelated settings.Check these first when the user wants real setup work:
claude --help succeedsuv --version or pip --version succeeds4000If the user only wants instructions, state the prerequisites instead of running them.
Use this rule:
For persistent setup, confirm the target file and then merge keys into ~/.claude/settings.json. Do not replace the file contents.
config.yamlStart from the article's flow, but keep the provider naming aligned with LiteLLM docs:
model_list:
- model_name: claude-opus-4.5
litellm_params:
model: github_copilot/claude-opus-4.5
drop_params: true
Explain the fields:
model_name: the logical name Claude Code will requestmodel: the LiteLLM provider route, using github_copilot/<model>drop_params: true: strips unsupported Anthropic-specific fields before forwarding to CopilotIf the user wants a different Copilot-backed model, keep the same pattern:
model_list:
- model_name: <logical-name>
litellm_params:
model: github_copilot/<copilot-model>
drop_params: true
Do not hardcode extra headers into the default path unless the user already hit a rejection that suggests header overrides are needed.
Preferred install:
uv tool install "litellm[proxy]"
Fallback:
pip install "litellm[proxy]"
Start the proxy from the directory containing config.yaml:
litellm --config config.yaml --port 4000
Tell the user to keep that terminal open because the logs are the fastest truth source during verification.
On the first successful request to the GitHub Copilot provider, LiteLLM may open a device authorization flow:
Optional token-location overrides exist:
GITHUB_COPILOT_TOKEN_DIRGITHUB_COPILOT_ACCESS_TOKEN_FILEOnly mention these when the user needs custom token storage, shared environments, or troubleshooting around expired or misplaced credentials.
For a temporary PowerShell session:
$env:ANTHROPIC_AUTH_TOKEN = "sk-any-string"
$env:ANTHROPIC_BASE_URL = "http://localhost:4000"
$env:ANTHROPIC_MODEL = "claude-opus-4.5"
$env:CLAUDE_CODE_DISABLE_NONESSENTIAL_TRAFFIC = "1"
claude
For a temporary Bash or Zsh session:
export ANTHROPIC_AUTH_TOKEN="sk-any-string"
export ANTHROPIC_BASE_URL="http://localhost:4000"
export ANTHROPIC_MODEL="claude-opus-4.5"
export CLAUDE_CODE_DISABLE_NONESSENTIAL_TRAFFIC=1
claude
For persistent configuration, merge these keys into ~/.claude/settings.json:
{
"env": {
"ANTHROPIC_AUTH_TOKEN": "sk-any-string",
"ANTHROPIC_BASE_URL": "http://localhost:4000",
"ANTHROPIC_MODEL": "claude-opus-4.5",
"CLAUDE_CODE_DISABLE_NONESSENTIAL_TRAFFIC": "1"
}
}
Merge-safe behavior:
env entries that are unrelated to this workflowUse two terminals when possible:
claudeAsk for one small prompt such as a short script or code review request, then verify:
github_copilot/<model>The healthy path is:
Claude Code -> LiteLLM -> GitHub Copilot -> LiteLLM -> Claude Code
If Claude Code reports model-not-found, 404-like failures, or LiteLLM says the model does not exist:
ANTHROPIC_MODEL to model_name exactlyIf LiteLLM never receives a request:
ANTHROPIC_BASE_URL points to http://localhost:4000claudeIf LiteLLM reaches GitHub Copilot but gets 401 or 403 responses:
The article uses explicit Copilot-style headers. Current LiteLLM docs expose GitHub Copilot as a provider and also document header override support.
Only reach for explicit extra_headers when:
Example fallback:
model_list:
- model_name: claude-opus-4.5
litellm_params:
model: github_copilot/claude-opus-4.5
drop_params: true
extra_headers:
editor-version: "vscode/1.85.1"
editor-plugin-version: "copilot/1.155.0"
Copilot-Integration-Id: "vscode-chat"
user-agent: "GithubCopilot/1.155.0"
Present this as an advanced fallback, not the universal default.
When answering a real user request with this skill, include:
config.yaml or the delta to applyANTHROPIC_AUTH_TOKEN is a real Copilot credential.~/.claude/settings.json wholesale.github_copilot/<model> pattern and note that Copilot-exposed model availability may change.