Skip to main content

Model Override

By default, Logic automatically routes your agent execution to the optimal model based on your agent’s requirements. However, you can bypass this routing and explicitly specify which model and reasoning level to use by adding the model query parameter.
Model overrides are an advanced feature. In most cases, Logic’s automatic model routing will select the best model for your use case. Only use model overrides when you have specific requirements around model selection.

Available Models

The model parameter accepts a model identifier in the format {model}:{reasoning_level}.
ProviderModel Overrides
OpenAI GPT-5.1gpt-5.1:none, gpt-5.1:minimal, gpt-5.1:low, gpt-5.1:medium, gpt-5.1:high
OpenAI GPT-5.2gpt-5.2:none, gpt-5.2:minimal, gpt-5.2:low, gpt-5.2:medium, gpt-5.2:high
OpenAI GPT-5.4gpt-5.4:none, gpt-5.4:minimal, gpt-5.4:low, gpt-5.4:medium, gpt-5.4:high
OpenAI GPT-5.5gpt-5.5:none, gpt-5.5:minimal, gpt-5.5:low, gpt-5.5:medium, gpt-5.5:high
Gemini 3 Flashgemini-3-flash:default, gemini-3-flash:low, gemini-3-flash:medium, gemini-3-flash:high
Gemini 3.1 Progemini-3.1-pro:default, gemini-3.1-pro:low, gemini-3.1-pro:high
Groqgroq-gpt-oss:default
Cerebrascerebras-gpt-oss:default, cerebras-gpt-oss:low, cerebras-gpt-oss:medium, cerebras-gpt-oss:high

Reasoning Levels

The reasoning level controls how much “thinking” the model does before responding:
  • none/default — Standard response without extended reasoning
  • minimal — Light reasoning for simple tasks
  • low — Basic reasoning for straightforward problems
  • medium — Moderate reasoning for complex tasks
  • high — Maximum reasoning for the most challenging problems
Higher reasoning levels may increase latency and cost but can improve accuracy for complex tasks.

Capability Validation

When using a model override, Logic validates that your chosen model supports your agent’s requirements. If your agent requires capabilities the model doesn’t support, you’ll receive a 400 InvalidModelOverride error.
CapabilityOpenAIGeminiGroqCerebras
PDF ProcessingSupportedSupportedNot supportedNot supported
Office DocumentsSupportedSupportedNot supportedNot supported
Image ProcessingSupportedSupportedNot supportedNot supported
Audio ProcessingNot supportedSupportedNot supportedNot supported
HIPAA ComplianceNot supportedSupportedNot supportedNot supported
Tool UsageSupportedNot supportedSupportedSupported
For example, if your agent processes audio input and you specify ?model=gpt-5.1:low, the request will fail because OpenAI models don’t support audio processing.

Example Usage

Below are examples showing how to specify a model override when executing an agent.
curl -X POST 'https://api.logic.inc/v1/agents/{agent_id}/executions?model=gpt-5.1:low'
    -H "Authorization: Bearer $LOGIC_API_TOKEN"
    -H "Content-Type: application/json"
    -d '{
        /* your input JSON here */
    }'
http -A bearer -a $LOGIC_API_TOKEN POST 'https://api.logic.inc/v1/agents/{agent_id}/executions?model=gpt-5.1:low'
    --raw '{
      {YOUR INPUT JSON HERE}
    }'
import requests

LOGIC_API_TOKEN = "ls-xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"

headers = {
    "Authorization": f"Bearer {LOGIC_API_TOKEN}",
    "Content-Type": "application/json"
}

response = requests.post(
    "https://api.logic.inc/v1/agents/{agent_id}/executions?model=gpt-5.1:low",
    headers=headers,
    json={
        # Your input fields here
    }
)

print(response.json())
require 'net/http'
require 'json'

uri = URI('https://api.logic.inc/v1/agents/{agent_id}/executions?model=gpt-5.1:low')
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = uri.scheme == 'https'

LOGIC_API_TOKEN = 'ls-xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx'
request = Net::HTTP::Post.new(uri)
request['Authorization'] = "Bearer #{LOGIC_API_TOKEN}"
request['Content-Type'] = 'application/json'
request.body = '{
  /* your input here */
}'

response = http.request(request)
puts response.body
const LOGIC_API_TOKEN = "ls-xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx";

const response = await fetch(
  "https://api.logic.inc/v1/agents/{agent_id}/executions?model=gpt-5.1:low",
  {
    method: "POST",
    headers: {
      Authorization: `Bearer ${LOGIC_API_TOKEN}`,
      "Content-Type": "application/json",
    },
    body: JSON.stringify({
      // Your input fields here
    }),
  },
);

const data = await response.json();
console.log(data);
package main

import (
    "bytes"
    "encoding/json"
    "fmt"
    "net/http"
    "io/ioutil"
)

const (
    LOGIC_API_TOKEN = "ls-xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
)

func main() {
    jsonStr := `{
      {YOUR INPUT JSON HERE}
    }`

    // Create request
    req, err := http.NewRequest("POST", "https://api.logic.inc/v1/agents/{agent_id}/executions?model=gpt-5.1:low", bytes.NewBufferString(jsonStr))
    if err != nil {
        panic(err)
    }

    // Add headers
    req.Header.Set("Content-Type", "application/json")
    req.Header.Set("Authorization", "Bearer " + LOGIC_API_TOKEN)

    // Send request
    client := &http.Client{}
    resp, err := client.Do(req)
    if err != nil {
        panic(err)
    }
    defer resp.Body.Close()

    // Read response
    body, err := ioutil.ReadAll(resp.Body)
    if err != nil {
        panic(err)
    }

    fmt.Println(string(body))
}
// Java requires the OkHttp library. You can add it to your project using Maven or Gradle. Learn more in the Java Quick Start section of the API reference.


import okhttp3.*;
import java.io.IOException;

public class ApiClient {
    private static final String LOGIC_API_TOKEN = "ls-xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx";

    public static void main(String[] args) {
        OkHttpClient client = new OkHttpClient();


        MediaType JSON = MediaType.get("application/json; charset=utf-8");
        String jsonBody = """
        {
            // Your input fields here
        }
        """;

        RequestBody body = RequestBody.create(jsonBody, JSON);
        Request request = new Request.Builder()
            .url("https://api.logic.inc/v1/agents/{agent_id}/executions?model=gpt-5.1:low")
            .post(body)
            .addHeader("Authorization", "Bearer " + LOGIC_API_TOKEN)

            .addHeader("Content-Type", "application/json")
            .build();

        try (Response response = client.newCall(request).execute()) {
            String responseBody = response.body().string();
            System.out.println(responseBody);
        } catch (IOException e) {
            e.printStackTrace();
        }
    }
}

Error Handling

If you specify an invalid model or a model that doesn’t support your agent’s requirements, you’ll receive a 400 InvalidModelOverride error:
{
  "error": {
    "code": "InvalidModelOverride",
    "message": "The specified model 'gpt-5.1:low' does not support audio processing required by this agent"
  }
}