# AI models and providers, local or hosted

Which AI models Truetask uses: OpenAI, Anthropic, Gemini, OpenRouter, local models such as Ollama, managed Truetask AI, and Claude Code, Codex or Cursor.

URL: https://docs.truetask.io/agents/models

Truetask runs its AI on models from three places: the workspace's own models from a provider such as OpenAI, Anthropic, Gemini or OpenRouter or a local runtime such as Ollama or LM Studio, managed Truetask AI on Truetask Cloud, and the coding tools Claude Code, Codex and the Cursor CLI on your own computer.
An admin connects the workspace's models, and you link the coding tools your agents run on.

| Source | Who sets it up | What runs on it |
| --- | --- | --- |
| Workspace models | A workspace owner or admin, in [AI settings](https://docs.truetask.io/admin/ai) | Truetask AI, the AI assists, AI automation nodes, agent memory, and agents answering inside Truetask. |
| Truetask AI | Nobody: it comes with Truetask Cloud | The same as a workspace model, from a monthly allowance. |
| Coding tools | You, on your own computer, with Truetask Helper | Your agents' chats and runs through Claude Code, Codex or the Cursor CLI, under your own sign-in for each tool. |

A tool connected through [MCP](https://docs.truetask.io/agents/mcp), such as [ChatGPT](https://docs.truetask.io/agents/connect-chatgpt) or [Gemini CLI](https://docs.truetask.io/agents/connect-gemini-cli), brings its own model and needs none of these.

## Workspace models

Open **Settings > Integrations > AI**.
The switch at the top is **Workspace AI models**: "Lets the models below answer for everyone here, and spend what they cost. An agent someone brings themselves keeps working."

**Add model** connects a provider.

| Provider | Default API URL | Needs |
| --- | --- | --- |
| **OpenAI** | `https://api.openai.com/v1` | An API key. |
| **Anthropic** | `https://api.anthropic.com/v1` | An API key. |
| **Gemini** | `https://generativelanguage.googleapis.com/v1beta` | An API key. |
| **OpenRouter** | `https://openrouter.ai/api/v1` | An API key. |
| **Ollama** | `http://localhost:11434` | A reachable endpoint; a key is usually not required. |
| **LM Studio** | `http://localhost:1234` | A reachable endpoint; a key is usually not required. |
| **oMLX** | `http://localhost:8000/v1` | A reachable endpoint; a key is usually not required. |
| **vMLX** | `http://localhost:8000/v1` | A reachable endpoint; a key is usually not required. |
| **Custom** | You supply it | Any OpenAI-compatible endpoint. The API URL is required. |

> **Both MLX runtimes default to the same port**
>
> oMLX and vMLX both default to `localhost:8000`.
> Running both at once means remapping one of them.

OpenRouter takes more than a plain model id.
Type an id, paste a preset as `@preset/slug`, use **Pick from catalog…** to browse, or choose **Auto router - let OpenRouter pick** to let it choose a model per request.

**Routing** then decides which model serves each job: **Generate**, **Suggest**, **Summarize** and **Tool use (agent)**.
The tool-use route is what Truetask AI and agents answering inside Truetask run on, so it wants a model with strong tool calling.
See [AI settings](https://docs.truetask.io/admin/ai) for every field, the routing guidance and the feature switches.

## Truetask AI (Cloud)

On Truetask Cloud, **Truetask AI** is a managed model that is already there: "Included with your plan. No API key or setup needed."
It answers wherever a workspace model would, and the AI settings pane shows **AI usage this month** against your allowance.

When the allowance runs out, the chat says so: "This workspace has used its monthly Truetask AI allowance. It resets at the start of next month", with **Get more AI**.

> **Truetask Cloud only**
>
> Managed Truetask AI comes with monthly credits on every plan.
> Every plan, Free included, can also bring its own provider beside it.
> See [Plans and billing](https://docs.truetask.io/cloud/plans).

## An agent's models

Each agent has a **Models** page in the Agents dialog.
It lists every coding tool linked on your computers and the workspace model by its name, each with a switch.
An agent uses every model it can reach until you turn one off, and **Takes its tasks** picks the one assigned work goes to.
See [Creating an agent](https://docs.truetask.io/agents/creating#models).

The coding tools are **Claude Code**, **Codex** and the **Cursor CLI**.
You link them once per computer in Truetask Helper, and every agent you own can use them there.
See [Your agents on your computer](https://docs.truetask.io/helper/agents).

## Pick a model in a chat

In a task's **Agent** channel or the Truetask AI window, the composer's settings button holds what the chat runs on: the model, the effort, the permission level, and when it matters, the computer and the folder.

The model menu lists the agent's own models, as its **Models** page does: each coding tool it has on, then the workspace's models.
Picking a model also picks where the chat runs.
A coding tool's model runs the chat on your computer through Truetask Helper; a workspace model runs it inside Truetask.

![The Model menu in a Truetask task's Agent channel, listing Claude Code's models with the favorite starred](https://docs.truetask.io/screenshots/chat-model-menu.webp)

Each chat keeps its own coding tool and model, so one task can run on Codex while another runs on Claude Code on the same computer at the same time.
A task remembers the model you picked, even before its first message, and changing the model, the effort or the agent keeps the chat's permission level.

| Coding tool | Models | Efforts |
| --- | --- | --- |
| **Claude Code** | Fable, Opus, Sonnet and Haiku | **Auto**, then low, medium, high, xhigh and max |
| **Codex** | The models Codex itself offers, listed as soon as the chat opens | **Auto**, then minimal, low, medium, high and xhigh |
| **Cursor CLI** | The models Cursor offers | None |

### Favorites

A star on a row marks your favorite: one model and one effort per coding tool, and one permission level.
"Tasks start on your favorite unless you pick another for the task."
Starring another replaces the old favorite, and your favorites follow you to every device.

### Permission levels

The permission menu offers the same three levels on every coding tool: **Ask every time**, **Accept edits** and **Autonomous**.
Each says in a line what it means on that tool.
A tool's own extra modes stay reachable under them, marked as only on that tool.
A level a tool cannot give runs one step tighter, never looser.

### When your computer is not there

When the agent's computer cannot be reached, the chat says so, and the workspace's model answers instead if there is one: "The workspace's model answers for {name}".
Open Truetask Helper on that computer and the agent answers there again.

## When nothing is configured

The AI surfaces degrade with an explanation instead of an error.

- With no workspace model and none of your computers online, a task has no **Agent** channel, only **Team**.
  A task assigned to one of your agents then names the agent and says it "has nowhere to run yet", with **Add a model** and **Set up its computer**.
- An agent with no model reads **No model yet**: "Link a coding tool with Truetask Helper, or add a model in Settings, AI".
- With the workspace's models switched off, the assistant, task suggestions, breakdowns and AI automation nodes refuse, while a chat with an agent someone brings themselves still works under that person's own permissions.

## Frequently asked questions

### Which AI models does Truetask support?

Truetask connects to OpenAI, Anthropic, Gemini and OpenRouter, to the local runtimes Ollama, LM Studio, oMLX and vMLX, and to any OpenAI-compatible endpoint, and Truetask Cloud adds managed Truetask AI.
Agents can also run on Claude Code, Codex or the Cursor CLI on your own computer, with the models those tools offer.

### Can I use only local models with Truetask?

Yes, for the workspace's own models.
Add Ollama, LM Studio, oMLX or vMLX at an address the Truetask server can reach, and a self-hosted instance runs the assistant, the AI assists and agent memory with no prompt leaving your network.
A coding tool such as Claude Code or Codex calls its own vendor's models.
See [Run AI on local models only](https://docs.truetask.io/self-hosted/outbound-data#run-ai-on-local-models-only).

### Do I need an API key to use AI on Truetask Cloud?

No.
Managed Truetask AI is "Included with your plan. No API key or setup needed.", and every plan can also bring its own provider beside it.

### Which model does an agent use?

The one its **Takes its tasks** row picks among the models on its **Models** page, for the work it is assigned.
In a chat, the model you pick decides where that chat runs: a coding tool's model on your computer, a workspace model inside Truetask.

## Related

- [AI settings](https://docs.truetask.io/admin/ai)
- [Truetask AI](https://docs.truetask.io/agents/truetask-ai)
- [Creating an agent](https://docs.truetask.io/agents/creating)
- [AI assists on tasks](https://docs.truetask.io/agents/assists)
- [What leaves a self-hosted instance](https://docs.truetask.io/self-hosted/outbound-data)
