<<<<<<< HEAD
=======
>>>>>>> a6f660b (nav: update feature page links)

AIプロバイダー

8つのプロバイダー、各々にC言語ブリッジ。設定キー1つで切替。ストリーミング・シンキング・ツール使用 — プロバイダー別機能マトリクスは下記。

概要

scorpiox codeはプロバイダー固有のCブリッジを通じてAIバックエンドに接続します。各プロバイダーは独立した変換レイヤーです。scorpiox-env.txtSX_PROVIDERで切替。

プロバイダー詳細

Scorpiox Router scorpiox
APIエンドポイントhttps://scorpiox.net:5175
認証方式Anthropic-style headers via router
ソースファイルsx_provider_scorpiox.c

モデル

opussonnethaiku

機能

streamingthinkingtool_usetraffic_loggingretry_with_backoffmulti_backend

設定キー

ROUTER_URLAPI_BACKENDMODELSTREAMINGTHINKINGTHINKING_BUDGETTOOLS

Meta-provider that routes through scorpiox.net. API_BACKEND selects upstream: claude, gemini, gemini-internal, glm, llamacpp.

Claude Code claude_code
APIエンドポイントhttps://api.anthropic.com/v1/messages?beta=true
認証方式OAuth Bearer token (auto-fetched)
ソースファイルsx_provider_claude_code.c

モデル

claude-opus-4-6claude-sonnet-4-6claude-haiku-4-5-20251001

機能

streamingthinkingtool_usetraffic_loggingretry_with_backoffproxy_supporttoken_auto_refreshinterleaved_thinking

設定キー

CLAUDE_CODE_TOKEN_SOURCECLAUDE_CODE_REMOTE_URLCLAUDE_CODE_SSH_HOSTCLAUDE_CODE_SSH_PORTCLAUDE_CODE_SSH_USERCLAUDE_CODE_SSH_PASSCLAUDE_CODE_API_URLCLAUDE_CODE_PROXY_URLCLAUDE_CODE_PROXY_ENABLEDCLAUDE_CODE_PROXY_STRICTMODELSTREAMINGTHINKINGTHINKING_BUDGETTOOLSCLAUDE_MODEL_OPUS_ID_OVERRIDECLAUDE_MODEL_SONNET_ID_OVERRIDECLAUDE_MODEL_HAIKU_ID_OVERRIDE

Native Claude Code CLI emulation. User-Agent: claude-cli/2.0.51. Beta flags: claude-code-20250219, oauth-2025-04-20, interleaved-thinking-2025-05-14.

OpenAI Codex codex
APIエンドポイントhttps://chatgpt.com/backend-api/codex/responses
認証方式OAuth Bearer token (auto-fetched)
ソースファイルsx_provider_codex.c

モデル

gpt-5.5gpt-5.4gpt-5.4-minigpt-5.3-codexgpt-5.2codex-auto-review

機能

streamingthinkingtool_usefunction_callingtraffic_loggingretry_with_backoffsse_parsingtoken_auto_refresh

設定キー

CODEX_TOKEN_SOURCECODEX_REMOTE_URLCODEX_SSH_HOSTCODEX_SSH_PORTCODEX_SSH_USERCODEX_SSH_PASSMODELTOOLS

OpenAI Codex via chatgpt.com backend-api. Always streams internally. Maps opus/sonnet/haiku to gpt-5.5/gpt-5.4/gpt-5.4-mini.

OpenAI-Compatible openai
APIエンドポイントConfigurable via OPENAI_BASE_URL
認証方式Bearer token (optional, for local servers)
ソースファイルsx_provider_openai.c

モデル

Configurable via OPENAI_MODEL

機能

tool_usethinkingtraffic_loggingretry_with_backoffhttp_relay_support

設定キー

OPENAI_API_KEYOPENAI_BASE_URLOPENAI_API_BASEOPENAI_MODELOPENAI_TIMEOUTOPENAI_TRAFFIC_DIROPENAI_TRAFFIC_SEQ

Generic OpenAI-compatible provider. Works with llama.cpp, Ollama, vLLM, etc. Translates Anthropic Messages API to OpenAI Chat Completions via scorpiox-openai binary.

Anthropic API anthropic
APIエンドポイントhttps://api.anthropic.com/v1/messages
認証方式x-api-key header (official, antigravity, zai, custom)
ソースファイルsx_provider_anthropic.c

モデル

claude-opus-4-6claude-sonnet-4-6claude-haiku-4-5-20251001

機能

streamingthinkingtool_usetraffic_loggingretry_with_backoffmulti_auth_providermodel_name_mapping

設定キー

ANTHROPIC_API_KEYANTHROPIC_API_URLANTHROPIC_AUTH_PROVIDERANTHROPIC_ANTIGRAVITY_KEYANTHROPIC_ANTIGRAVITY_URLANTHROPIC_ZAI_KEYANTHROPIC_ZAI_URLMODELSTREAMINGTHINKINGTOOLS

Direct Anthropic API with x-api-key. Auth providers: official, antigravity (proxy with model mapping), zai (api.z.ai proxy), custom.

Gemini Vertex AI gemini_vertex
APIエンドポイントhttps://aiplatform.googleapis.com/v1/publishers/google/models
認証方式API key via VERTEX_API_KEY
ソースファイルsx_provider_gemini_vertex.c

モデル

gemini-3.1-pro-previewgemini-3.1-flash-lite-previewgemini-3-flash-previewgemini-2.5-progemini-2.5-flash

機能

streamingthinkingtool_usetraffic_loggingretry_with_backoff

設定キー

VERTEX_API_KEYVERTEX_MODELTRAFFIC_DIR

Google Gemini via Vertex AI with API key auth. Maps opus→gemini-3.1-pro-preview, sonnet→gemini-3-flash-preview, haiku→gemini-3.1-flash-lite-preview.

Google Gemini (Cloud Code) google_gemini
APIエンドポイントhttps://cloudcode-pa.googleapis.com/v1internal:streamGenerateContent
認証方式OAuth Bearer token (auto-fetched)
ソースファイルsx_provider_google_gemini.c

モデル

gemini-3.1-pro-previewgemini-3-flash-previewgemini-3.1-flash-lite-previewgemini-2.5-progemini-2.5-flash

機能

streamingsse_parsingthinkingtool_usetraffic_loggingretry_with_backoffmulti_endpoint_failovertoken_auto_refresh

設定キー

GOOGLE_GEMINI_MODELGOOGLE_ACCOUNTGOOGLE_TOKEN_SOURCEGOOGLE_REMOTE_URLTCP_HOSTTCP_PORTTCP_API_KEY

Google Gemini via cloudcode-pa API with SSE streaming. Failover: cloudcode-pa.googleapis.com, daily-cloudcode-pa.googleapis.com.

Google Claude (Cloud Code) google_claude
APIエンドポイントhttps://cloudcode-pa.googleapis.com/v1internal:generateContent
認証方式OAuth Bearer token (auto-fetched)
ソースファイルsx_provider_google_claude.c

モデル

claude-sonnet-4-6claude-opus-4-6-thinking

機能

thinkingtool_usetraffic_loggingretry_with_backoffmulti_endpoint_failovertoken_auto_refresh

設定キー

GOOGLE_CLAUDE_MODELGOOGLE_ACCOUNTGOOGLE_TOKEN_SOURCEGOOGLE_REMOTE_URLTCP_HOSTTCP_PORTTCP_API_KEY

Claude models via Google cloudcode-pa API. Non-streaming (requestType: claude). Failover endpoints supported.

機能マトリクス

機能scorpioxclaude_codecodexopenaianthropicgemini_vertexgoogle_geminigoogle_claude
function calling
http relay support
interleaved thinking
model name mapping
multi auth provider
multi backend
multi endpoint failover
proxy support
retry with backoff
sse parsing
streaming
thinking
token auto refresh
tool use
traffic logging

設定

# scorpiox-env.txt — provider selection
SX_PROVIDER=claude_code

# Model tier (mapped per-provider)
MODEL=opus

# Enable streaming + thinking
STREAMING=true
THINKING=true
THINKING_BUDGET=10000

# Provider-specific: Claude Code token source
CLAUDE_CODE_TOKEN_SOURCE=local
# Provider-specific: Anthropic API key
ANTHROPIC_API_KEY=sk-ant-...
# Provider-specific: OpenAI-compatible endpoint
OPENAI_BASE_URL=http://localhost:8080/v1
# Provider-specific: Vertex AI
VERTEX_API_KEY=AIza...

プロバイダーの切替

# Switch to Codex
SX_PROVIDER=codex

# Switch to local llama.cpp via OpenAI-compatible
SX_PROVIDER=openai
OPENAI_BASE_URL=http://localhost:8080/v1
OPENAI_MODEL=qwen2.5-coder-32b

# Switch to Gemini via Vertex AI
SX_PROVIDER=gemini_vertex
VERTEX_API_KEY=AIza...

# Switch to Google Gemini (Cloud Code)
SX_PROVIDER=google_gemini
GOOGLE_TOKEN_SOURCE=local

# Switch to Google Claude (Cloud Code)
SX_PROVIDER=google_claude
GOOGLE_TOKEN_SOURCE=local

認証

OAuth Token (Auto-Refresh)

Used by: claude_code, codex, google_gemini, google_claude. Tokens are fetched automatically via helper binaries (scorpiox-claudecode-fetchtoken, scorpiox-codex-fetchtoken). Token sources: local, remote (SSH), TCP.

API Key (Static)

Used by: anthropic (x-api-key), gemini_vertex (query param), openai (Bearer). Set the key in scorpiox-env.txt and it's passed through on every request.

Router Passthrough

Used by: scorpiox. Sends Anthropic-style headers to the scorpiox.net router, which selects the upstream backend via API_BACKEND (claude, gemini, gemini-internal, glm, llamacpp).