Relay Setup
Relay is the preferred inference path for Hamr. Hamr expects an OpenAI-compatible API rooted at a base URL such as:
http://127.0.0.1:1234/v1The important endpoints are:
GET /modelsPOST /chat/completions
Local Relay Profile
Use .hamr.toml:
[active]
provider = "relay"
model = "Qwen3.6-35B-A3B-UD-IQ3_XXS.gguf"
thinking = "off"
[providers.relay]
enabled = true
name = "Relay"
compatibility = "openai-compatible"
base_url = "http://127.0.0.1:1234/v1"
[[providers.relay.models]]
id = "Qwen3.6-35B-A3B-UD-IQ3_XXS.gguf"
display_name = "Qwen3.6 35B"
context_window = 131072
supports_thinking = falseSet model to the exact ID Relay reports from /models.
Provider Presets
Hamr normalizes these provider presets:
| Preset | Use |
|---|---|
relay | Default local Relay endpoint at 127.0.0.1:1234 |
deepseek | DeepSeek API |
openai | OpenAI API |
anthropic | Anthropic API (anthropic-compatible format) |
openrouter | OpenRouter API |
custom | Any custom OpenAI-compatible server |
Normal local use should not require cloud-hosted APIs.
Headers And Keys
Use api_key_env to reference an environment variable holding your API key:
[providers.deepseek]
api_key_env = "DEEPSEEK_API_KEY"For endpoints requiring custom headers, use the [providers.<id>.headers] section:
[providers.relay.headers]
"CF-Access-Client-Id" = "your-id.access"
"CF-Access-Client-Secret" = "your-secret"Tool-Call Parsing
For local models emitting non-standard tool calls, set tool_call_parser in .hamr.toml:
[providers.relay]
tool_call_parser = "qwen3_xml"Hamr auto-detects the parser from your model name when not set explicitly. See Tool-Call Parsing for the full parser matrix.
Verification
Hamr runs your verification command after completing tasks in run mode. Set it in .hamr.toml:
[verification]
defaultCommand = "bun run typecheck"Testing Relay
Once Relay is running:
hamr doctor --fullThis probes /models and sends a small /chat/completions request to confirm end-to-end connectivity.