AI setup
Point Hugin's built-in AI at a provider with your own API key — it supports Anthropic, any OpenAI-compatible endpoint, Google Gemini, and Ollama, local or hosted.
Hugin's built-in AI runs on a model you choose. You bring your own API key (BYOK): Hugin never ships one and calls the provider directly with your key, so your prompts and traffic never pass through a Hugin server. Set a key per provider; each is encrypted on disk.
Providers Hugin supports
Hugin talks to four kinds of provider:
- Anthropic — Claude models, over Anthropic's own API.
- OpenAI-compatible — any endpoint that speaks the OpenAI chat format: OpenAI, OpenRouter, Groq, Together, LM Studio, and vLLM.
- Google Gemini — Gemini models.
- Ollama — models running locally, no key. Point Hugin at
http://localhost:11434/v1and it detects Ollama on its own, with a fallback for models that lack native tool calling. For hosted models, pick the Ollama Cloud preset (https://ollama.com/v1) — it works the same way but needs anollama.comAPI key.
Set your key and pick a model
Open Settings → Agent → Provider. Choose a provider preset — claude, openai, gemini, openrouter, ollama, ollama cloud, or a custom endpoint — paste your API key, and save. Each key is stored encrypted, one per provider, so switching presets keeps every provider's own key.
The model menu fills itself from the provider's live model list when you open the tab, so retired models drop off and new ones appear without a Hugin update. Where the provider reports it, each model shows its context length and price.
A local Ollama needs no key — leave the field blank. Nothing leaves your machine and there is no per-token cost, and it counts as AI ready, so Copilot and the autonomous modes run against it with no key set. Ollama Cloud is the hosted exception: it needs an ollama.com key.
Route tasks and cap spend
Both are optional, under the same tab.
- Per-task routing — send cheap work (explaining a response, summarizing, classifying findings) to a small or local model, and keep a strong model for reasoning and payload generation. Add a route per task, or apply the Free Tier, Budget, or Premium preset.
- Spend caps — set a daily token ceiling, and give each agent run its own token, step, and request budget.
0means no cap. Track running spend — daily and monthly tokens, plus estimated cost in USD — in Settings → Agent → Usage.
Caps matter most for the autonomous Explore and Auto modes, which keep calling the model on their own — both are a Pro capability. Or skip the built-in AI and drive Hugin from your own agent over MCP.