Files
anyllm-proxy/docs/providers/github.md
T
whit3rabbitandClaude Sonnet 4.6 545bdbbbd3 feat: add bedrock native passthrough, generic passthrough, provider docs, and managed backend fixes
Adds bedrock_native.rs (Converse/InvokeModel with SigV4) and
generic_passthrough.rs catch-all for Translate mode. Adds comprehensive
provider reference docs (docs/providers/, docs/ENDPOINTS.md). Fixes
managed backend admin UI (BackendForm, ManagedBackendsSection) and
admin route/model handler issues. Adds automated model pricing update
workflow (scripts/update_pricing.py, .github/workflows/update-pricing.yml).

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-08 16:36:16 -05:00

2.4 KiB

GitHub Models

Azure-hosted OpenAI-compatible inference endpoint accessible with a GitHub personal access token, free tier included.

LiteLLM prefix: github/
Status: Stub — routes through OpenAI-compatible client
Docs: https://docs.github.com/en/github-models

Authentication

Variable Required Description
GITHUB_TOKEN Yes GitHub personal access token (PAT) with no special scopes required

Quick Start

Single-Backend (env vars)

BACKEND=github GITHUB_TOKEN=your-pat cargo run -p anyllm_proxy
# Docker:
docker run -e BACKEND=github -e GITHUB_TOKEN=your-pat -e PROXY_OPEN_RELAY=true -p 3000:3000 followthewhit3rabbit/anyllm-proxy

LiteLLM YAML Config

model_list:
  - model_name: gpt-4o
    litellm_params:
      model: github/gpt-4o
      api_key: "env:GITHUB_TOKEN"
  - model_name: llama-3.3-70b
    litellm_params:
      model: github/Llama-3.3-70B-Instruct
      api_key: "env:GITHUB_TOKEN"

Usage Examples

Anthropic Messages API

curl http://localhost:3000/v1/messages \
  -H "x-api-key: $PROXY_API_KEYS" \
  -H "Content-Type: application/json" \
  -d '{"model": "gpt-4o", "max_tokens": 1024, "messages": [{"role": "user", "content": "Hello"}]}'

OpenAI Chat Completions API

curl http://localhost:3000/v1/chat/completions \
  -H "Authorization: Bearer $PROXY_API_KEYS" \
  -H "Content-Type: application/json" \
  -d '{"model": "gpt-4o", "messages": [{"role": "user", "content": "Hello"}]}'

Capabilities

Feature Supported
Chat Completions
Streaming
Tool Use
Embeddings
Vision
Batch

Notable Models

Model ID Context Notes
gpt-4o 128k OpenAI GPT-4o
gpt-4o-mini 128k OpenAI GPT-4o Mini, low-cost
Llama-3.3-70B-Instruct 128k Meta Llama 3.3 70B
Phi-4 16k Microsoft Phi-4
Mistral-Nemo 128k Mistral Nemo
text-embedding-3-small OpenAI embedding model

Notes

GitHub Models is backed by Azure AI and uses the endpoint https://models.inference.ai.azure.com. A standard GitHub PAT (classic or fine-grained) with no additional scopes is sufficient. The free tier has strict rate limits: check https://docs.github.com/en/github-models/prototyping-with-ai-models#rate-limits for current limits. Not intended for production traffic.