---
title: Set the agent's model
description: Set the model and reasoning effort that an agent runs with.
---
> ## Documentation Index
> Fetch the complete documentation index at: https://docs.reeval.ai/llms.txt
> Use this file to discover all available pages before exploring further.

Each harness factory takes a `model`. All but `fx` also take an optional `effort`. In the `reeval.config.ts` file, set both on the factory:

```ts title="reeval.config.ts"
import { defineConfig } from '{{ pkg }}'
import { claudeCode } from '{{ pkg }}/harness'

export default defineConfig({
  harness: claudeCode({ model: '<model>', effort: 'high' }),
})
```

With `effort` set and `id` unset, the cell id ends in `[effort=<value>]`, so one harness at two efforts is two cells. For a runnable project, see [`with-reasoning-effort`](https://github.com/invertase/reeval/tree/main/examples/with-reasoning-effort).

## `model`

`model` is the id the harness's own CLI or SDK accepts, and the harness's key follows from it. For more information about the key each harness reads, see [Harness behavior](/reference/options#harness-behavior). For more information about how a key stays on the host, see [Keep API keys on the host](/configuration/environments/secrets#keep-api-keys-on-the-host).

reeval refuses a prefixed id on a harness that takes a bare id, or a bare id on `opencode`, at plan time with exit code 2. The `model` entries in [Harness factory options](/reference/options#harness-factory-options) name the ids a harness accepts. For more information about the providers `opencode` supports, see [OpenCode providers](/reference/options#opencode-providers).

## `effort`

`effort` is a reasoning-effort value that reeval passes to the harness's own CLI or SDK. It records the value as `effort` on the cell. Only `claudeCode` checks the value at plan time. The `effort` entries in [Harness factory options](/reference/options#harness-factory-options) name the values a harness takes and where reeval sets them.

`fx` has no `effort`, and reeval refuses one at plan time with exit code 2. Cursor's fast mode is `params.fast`, not `effort`.

## Through a gateway

A gateway replaces the harness's own key with the gateway's key, such as `AI_GATEWAY_API_KEY` on `vercel()`, and some gateways refuse `effort` on some harnesses. With `effort` set, a harness a gateway only partly serves takes the next gateway in the config's `gateway` list, and a harness that names its gateway stops the plan with exit code 2.

```bash
npx reeval run --dry-run
```

The plan shows the gateway each harness resolved to. For the harnesses and efforts each gateway serves, see [Harness support](/configuration/gateways#harness-support).

## Check the model that served

The record keeps the configured `model` and `effort` beside what ran. `turns[].model` is the model the harness says served each turn, and null when it reports none. `servedModels` is the models the egress gateway observed in the harness's API calls, and it is null for Cursor and Claude Code, whose API requests name no model. `servedEffort` is the level those labels name. For more information about those fields, and each harness's `resolvedModels` and `resolvedEffort`, see [Run record reference](/reference/run-record).

## Next

For more information about running one task on several harnesses, see [Compare harnesses](/evaluations/recipes/compare-harnesses).
