Custom Model¶
Add-on for OG AI Core. Run any model, local or remote, inside OG AI Core: Ollama, LM Studio, llama.cpp, vLLM, LocalAI, LiteLLM and any OpenAI-compatible server or gateway. No cloud, no per-token fees, and no data leaving your network when you point it at your own server.
Requires: OG AI Core active. WordPress 6.0+, PHP 8.1+ (as OG AI Core).
Install and set up¶
- Install and activate OG AI Core. Install it from OG AI Core > Manage add-ons > Get add-ons: one click if you own it, or enter its licence key. It runs from OG AI Core's add-ons folder, not from the Plugins screen.
- Go to OG AI Core > Settings > AI > Environments for AI, add an environment and choose the type OG Custom Model (Any / Local).
- Enter the server address. For Ollama that is
http://127.0.0.1:11434(/v1is added for you). - Click Refresh Models, then pick the model anywhere in OG AI Core.
- Optional: open OG AI Core > Add-ons > Custom Model to tune the environment and review each model.
What it does¶
- Works with chat, streaming, tools, vision, JSON mode and embeddings through OG AI Core's chatbots, forms and knowledge features.
- Reads what each model can really do (tools, vision, thinking, embeddings, context length) from Ollama, LM Studio or the gateway where they publish it.
- A per-model table lets you force tools, vision, reasoning or JSON mode on or off, and set context size, output limit, embedding dimensions and a notional price.
- Supports bearer tokens, a custom key header, extra headers, extra request fields (for example Ollama's
keep_alive) and a timeout for slow machines.
Good to know¶
- The address is used by your WordPress server, not your browser. "localhost" means the machine WordPress runs on.
- Ollama's default context window is small (2048 to 4096 tokens) whatever the model supports. Set "Context cap" to what your server really uses.
- A model that does not support tools or images will answer with its own error if asked. Use the per-model table to hide those options.