Skip to content
TheThinkLoop

Template - Support

Score

SLA breach risk

How likely a ticket is to breach its response-time commitment.

A score decision that flags tickets drifting toward an SLA breach, using the ticket text together with timing and tier.

The decision

ScoreA position on the ordered levels (0 = first level), a confidence value, and a probability for every level.

How likely is this ticket to breach its response-time SLA?

Levels, lowest to highest

  1. 0Unlikely: Well inside the response window, or low priority with a long target.
  2. 1Possible: A meaningful share of the window has passed, or the ticket is complex.
  3. 2Likely: Close to or past the target with no response, especially on a high-priority ticket.

Evidence checks (asked in the same request)

  • High-value account: The request comes from an enterprise or high-value account.
  • Wide customer impact: Multiple users or production systems are affected.

Expected output: A score from 0 to 2, a probability for each level, and a confidence value, plus one probability per evidence check.

Input

The Decisions API reads one input. Combine these fields into it as labeled text so the model sees the facts the decision depends on.

Input fields
FieldTypeRequiredDescription
ticket_summarystringYesThe ticket text plus its priority, age, and SLA target, written as a sentence.

Worked examples

  1. P1 near its window with no response

    P1 ticket opened 3 hours 30 minutes ago with no response yet. Enterprise customer, production API is down, 4-hour response SLA.

    A careful reviewer would say: Likely. Thirty minutes left on a four-hour target, with no response, on a top-priority enterprise ticket.

    Run this example
  2. Fresh, low-priority question

    Low-priority question opened 20 minutes ago, not urgent. Customer says no rush. Response SLA is 2 business days.

    A careful reviewer would say: Unlikely. Twenty minutes into a two-day window.

    Run this example

Expected answers are human judgments written for this template, not model output.

How it works

Whether a ticket has breached is arithmetic, and your help desk already does it. This template is for the earlier question: which open tickets are likely to breach, given their complexity and how much of the window remains?

Write the timing facts into the input as plain sentences. Models handle "opened 3 hours ago, 4-hour SLA" better than a raw timestamp pair.

Human review and thresholds

Recommended review policy

The action is an alert to a queue manager, which is safe to automate. Avoid alert fatigue by notifying only on the top level.

Choosing thresholds

If breaches carry contractual penalties, alert early and accept false alarms. If they are internal targets, alert only at high probability so the alerts keep their meaning.

Starting automation threshold
80%
Starting don’t-decide threshold
50%

Starting points for the playground, not recommendations. The right values depend on your costs and on how the model’s confidence tracks accuracy on your data. Calibrate them.

Limitations

  • If you only need to know whether the deadline has passed, use a timestamp comparison. It is exact and free.
  • The model doesn't know your queue depth or staffing, which often decide breaches more than the ticket does.
  • Business-hours SLAs need the remaining working time calculated before it reaches the model.

Use it in your code

The template definition is plain JSON: the question, the evidence checks, the input fields, and the starting policy. The SDK call below sends the same question and checks to the Decisions API from your server.

sla-breach-risk.jsonjson
{
  "$format": "thethinkloop.template/v1",
  "slug": "sla-breach-risk",
  "title": "SLA breach risk",
  "decides": "How likely a ticket is to breach its response-time commitment.",
  "question": {
    "name": "decision",
    "type": "score",
    "instructions": "How likely is this ticket to breach its response-time SLA?",
    "levels": [
      {
        "label": "Unlikely",
        "description": "Well inside the response window, or low priority with a long target."
      },
      {
        "label": "Possible",
        "description": "A meaningful share of the window has passed, or the ticket is complex."
      },
      {
        "label": "Likely",
        "description": "Close to or past the target with no response, especially on a high-priority ticket."
      }
    ]
  },
  "evidenceChecks": [
    {
      "name": "factor_1",
      "label": "High-value account",
      "type": "predicate",
      "instructions": "The request comes from an enterprise or high-value account."
    },
    {
      "name": "factor_2",
      "label": "Wide customer impact",
      "type": "predicate",
      "instructions": "Multiple users or production systems are affected."
    }
  ],
  "inputs": [
    {
      "name": "ticket_summary",
      "type": "string",
      "required": true,
      "description": "The ticket text plus its priority, age, and SLA target, written as a sentence."
    }
  ],
  "expectedOutput": "A score from 0 to 2, a probability for each level, and a confidence value, plus one probability per evidence check.",
  "examples": [
    {
      "title": "P1 near its window with no response",
      "input": "P1 ticket opened 3 hours 30 minutes ago with no response yet. Enterprise customer, production API is down, 4-hour response SLA.",
      "expected": "Likely"
    },
    {
      "title": "Fresh, low-priority question",
      "input": "Low-priority question opened 20 minutes ago, not urgent. Customer says no rush. Response SLA is 2 business days.",
      "expected": "Unlikely"
    }
  ],
  "startingPolicy": {
    "automateAt": 0.8,
    "abstainBelow": 0.5,
    "note": "A starting point for exploration, not a recommendation. Calibrate against your own labeled examples."
  }
}
Equivalent SDK calljavascript
import OpenAI from "openai"; // openai >= 7.30.0

const client = new OpenAI(); // reads OPENAI_API_KEY on the server

const decision = await client.decisions.create({
  model: "gpt-6-luna",
  input: "P1 ticket opened 3 hours 30 minutes ago with no response yet. Enterprise customer, production API is down, 4-hour response SLA.",
  questions: [
    {
      type: "score",
      name: "decision",
      instructions: "How likely is this ticket to breach its response-time SLA?",
      levels: [
        {
          label: "Unlikely",
          description: "Well inside the response window, or low priority with a long target."
        },
        {
          label: "Possible",
          description: "A meaningful share of the window has passed, or the ticket is complex."
        },
        {
          label: "Likely",
          description: "Close to or past the target with no response, especially on a high-priority ticket."
        }
      ]
    },
    {
      type: "predicate",
      name: "factor_1",
      instructions: "The request comes from an enterprise or high-value account."
    },
    {
      type: "predicate",
      name: "factor_2",
      instructions: "Multiple users or production systems are affected."
    }
  ],
});

// Answers come back in question order. A question can also be refused.
const [main, ...checks] = decision.answers;
if (main.type === "refusal") throw new Error("The model declined to answer.");
if (main.type === "score") {
  console.log(main.score, main.confidence, main.probabilities);
}

Download it as sla-breach-risk.json, or browse all developer resources.

Need this decision tuned to your policy?

We are running a small number of pilots with B2B teams: your policy, your examples, your thresholds. Request early access.