Skip to main content

Your own providers and local models

Besides Explyt models, Explyt CLI can work through your corporate gateway, a local model, or your own provider API keys.

Why it matters​

  • Corporate gateway. Requests go through your company's infrastructure instead of directly to the provider.
  • Local model. The code never leaves your machine or internal network.
  • Your own keys. You can use the CLI with OpenAI, DeepSeek, Anthropic, or Gemini keys, or with Ollama, without an Explyt account.
No Explyt account needed

With your own OpenAI, Anthropic, Gemini, or DeepSeek API key, a local Ollama, or your own gateway added through /custom-provider, Explyt CLI works without signing in, and these requests do not spend Explyt credits. An Explyt account and a plan are needed only for Explyt models, see Plans and balance.

Ways to connect​

The /login command shows the ways to connect a model provider:

OptionWhen to choose it
AccountExplyt models on your Explyt plan
Built-in providersYou have a key from a well-known provider
Your own providerA corporate gateway or a server with an OpenAI-compatible API

Your own provider: /custom-provider​

/custom-provider is a wizard that adds, edits, and removes your own providers.

  1. Type /custom-provider.
  2. Choose the connection type:
    • any compatible endpoint: the wizard finds the server's model list itself or lets you enter models by hand;
    • a known API provider (OpenRouter, DeepSeek, and others): the model list and model parameters come from the models.dev catalog.
  3. Enter the address, for example https://api.example.com/v1 or http://localhost:11434/v1.
  4. Enter an API key or a reference to an environment variable such as $MY_API_KEY. If no key is needed, leave it empty.
  5. Select the models to add.
  6. Choose the new model in /model.

The wizard supports these API formats: OpenAI Chat Completions, OpenAI Responses, Anthropic Messages, and Gemini. For each model, you can set the context size, maximum answer length, image support, reasoning level, and extra HTTP headers.

/custom-provider connects Ollama, LM Studio, vLLM, and any other server with an OpenAI-compatible API. Later, the same wizard can request the model list from the server again: it adds new models and marks the ones that disappeared.

note

A !command in place of a key is not supported. Enter the key itself or an environment variable as $NAME.

Local models with llama.cpp: /llama​

The CLI supports the llama.cpp router, which finds GGUF models in a folder and loads them on demand.

  1. Start the router without the --model parameter:

    llama-server --models-dir ~/models --no-models-autoload --jinja --host 127.0.0.1 --port 8080 -ngl 999 -c 32768
  2. In the CLI, run /login llama.cpp and enter the router address (http://127.0.0.1:8080 by default) and a key if the router runs with --api-key. Alternatively, set the LLAMA_BASE_URL and LLAMA_API_KEY environment variables.

  3. Type /llama to load a model or download one from Hugging Face.

  4. Choose the model in /model.

In /llama, choosing a model that isn't loaded loads it, and choosing a loaded one unloads it. The command doesn't delete model files.

If something doesn't work, check the router first:

curl http://127.0.0.1:8080/health
curl http://127.0.0.1:8080/models

An empty list in /llama means the --models-dir path or the folder structure is wrong. If a model doesn't load or memory runs out, lower -c or unload another model.

Limitations​

  • Cache warming doesn't work for your own providers: they have no cache lifetime or price set. See Model cache.
  • The agent's quality depends on the model: small local models handle tool calls and long contexts worse.