Skip to content

Third-Party Models

AllySec Forge runs on any model provider that exposes an API. You control the backend. The platform is model-agnostic -- it sends prompts, receives completions, and adapts tool use to whatever model responds.

OpenCode Go provides the strongest offensive security reasoning at a cost ceiling. Models use the :opencode-go suffix for routing.

env
CLAUDE_CODE_USE_OPENAI=1
OPENAI_BASE_URL=https://opencode.ai/zen/go/v1
OPENAI_API_KEY=your-key
OPENAI_MODEL=deepseek-v4-pro:opencode-go

Anthropic (Native)

Direct Anthropic API. No translation layer. Use when you have an Anthropic subscription.

env
ANTHROPIC_AUTH_TOKEN=sk-ant-api03-...
ANTHROPIC_BASE_URL=https://api.anthropic.com
ANTHROPIC_MODEL=claude-sonnet-4-20250514

OpenAI

Standard OpenAI API. Any model in the catalog.

env
CLAUDE_CODE_USE_OPENAI=1
OPENAI_BASE_URL=https://api.openai.com/v1
OPENAI_API_KEY=sk-...
OPENAI_MODEL=gpt-4o

OpenRouter

Unified API with access to hundreds of models. Uses the Anthropic path with OpenRouter's base URL.

env
ANTHROPIC_AUTH_TOKEN=your-openrouter-key
ANTHROPIC_BASE_URL=https://openrouter.ai/api/v1
ANTHROPIC_MODEL=openrouter/auto

Ollama Cloud

Ollama's hosted API for open-weight models.

env
CLAUDE_CODE_USE_OPENAI=1
OPENAI_BASE_URL=https://ollama.com/v1
OPENAI_API_KEY=your-ollama-key
OPENAI_MODEL=llama4

LM Studio (Local)

Run models entirely on your machine. No API costs, no network egress. Useful for air-gapped engagements.

env
CLAUDE_CODE_USE_OPENAI=1
OPENAI_BASE_URL=http://localhost:1234/v1
OPENAI_API_KEY=not-needed
OPENAI_MODEL=local-model

Start LM Studio, load a model, and enable the local server. The platform connects over localhost.

Model Tier Overrides

Fine-tune which model handles each operational tier.

env
ANTHROPIC_DEFAULT_OPUS_MODEL=deepseek-v4-pro:opencode-go
ANTHROPIC_DEFAULT_SONNET_MODEL=deepseek-v4-pro:opencode-go
ANTHROPIC_DEFAULT_HAIKU_MODEL=deepseek-v4-pro:opencode-go

Opus-tier handles heavy reasoning (chain composition, attack planning). Sonnet handles routine operations. Haiku handles lightweight parallel tasks.

Switching Models at Runtime

Use the /model command during an active session to switch providers without restarting.

/model opencode-go
/model anthropic
/model openai
/model local

Credential Pooling

For teams running multiple API accounts, define a credential pool.

env
ALLYSEC_CREDENTIAL_POOL='[
  {"provider":"opencode","key":"key-1","base_url":"https://opencode.ai/zen/go/v1"},
  {"provider":"opencode","key":"key-2","base_url":"https://opencode.ai/zen/go/v1"},
  {"provider":"anthropic","key":"sk-ant-..."}
]'
ALLYSEC_CREDENTIAL_STRATEGY=round_robin

Strategies:

  • fill_first -- exhaust account 1 before switching
  • round_robin -- rotate evenly across all accounts
  • random -- random selection per request
  • least_used -- prefer the account with the fewest recent requests

Environment Variables -- FAQ

Released under the MIT License.