# SETscore tracheostomy need

SETscore

Status: LIVE
Price: $0.005 USDC
`GET /api/calc/setscore`
HTML: https://magentlab.com/docs/setscore
Markdown: https://magentlab.com/docs/setscore.md

Not a medical device. Not a diagnosis, dose, or listing recommendation.

## What it computes

Sum the fifteen Schönenberger 2016 SETscore items from caller-assigned flags and return whether the total is elevated (score ≥ 8).

## When to use

When an agent already has the fifteen Schönenberger 2016 Table 1 items assigned as present or absent and needs the published 0–48 total and the 2016 ROC cut-off of 8, not a tracheostomy order, NIHSS total, APACHE II computation, or SETPOINT2 enrollment threshold.

## When not to use

- Not a medical device. Not a tracheostomy order, timing decision, or airway procedure. magent does not examine the patient, read imaging, or compute APACHE II, lung injury score, or PaO2/FiO2.
- Each of the 15 items is a caller-assigned boolean from Schönenberger 2016 Table 1. magent does not invent extra weights or probabilities.
- elevated and setscore_ge_8 are true iff score ≥ 8, the 2016 ROC cut-off for prolonged NICU stay, ventilation time, and tracheostomy need. This is not the SETPOINT2 enrollment threshold of >10 and not NIHSS.

## Formula

```
SETscore = 4*dysphagia + 3*observed_aspiration + 3*gcs_lt_10 + 4*brainstem_lesion + 3*space_occupying_cerebellar + 4*mca_infarct_gt_two_thirds + 4*ich_volume_gt_25_ml + 3*diffuse_lesion + 4*hydrocephalus + 2*neurosurgical_intervention + 3*additional_respiratory_disease + 2*pao2_fio2_lt_150 + 4*apache_ii_gt_20 + 2*lung_injury_score_gt_1 + 3*sepsis; max 48; elevated / setscore_ge_8 iff score >= 8 (Schönenberger 2016)
```

## Citation

[The SETscore to Predict Tracheostomy Need in Cerebrovascular Neurocritical Care Patients](https://doi.org/10.1007/s12028-015-0235-5)
Schönenberger S, Al-Suwaidan F, Kieser M, Uhlmann L, Bösel J
Neurocrit Care. 2016;25(1):94-104
DOI: [10.1007/s12028-015-0235-5](https://doi.org/10.1007/s12028-015-0235-5)

## Worked example

### All fifteen flags false

Given: `additional_respiratory_disease=false, apache_ii_gt_20=false, brainstem_lesion=false, diffuse_lesion=false, dysphagia=false, gcs_lt_10=false, hydrocephalus=false, ich_volume_gt_25_ml=false, lung_injury_score_gt_1=false, mca_infarct_gt_two_thirds=false, neurosurgical_intervention=false, observed_aspiration=false, pao2_fio2_lt_150=false, sepsis=false, space_occupying_cerebellar=false`

1. All 15 Schönenberger 2016 Table 1 flags false → 0 each
2. Score = 0 (max 48); elevated and setscore_ge_8 are false because score < 8


### Dysphagia and ICH volume >25 mL (cut-off 8)

Given: `additional_respiratory_disease=false, apache_ii_gt_20=false, brainstem_lesion=false, diffuse_lesion=false, dysphagia=true, gcs_lt_10=false, hydrocephalus=false, ich_volume_gt_25_ml=true, lung_injury_score_gt_1=false, mca_infarct_gt_two_thirds=false, neurosurgical_intervention=false, observed_aspiration=false, pao2_fio2_lt_150=false, sepsis=false, space_occupying_cerebellar=false`

1. dysphagia true → +4; ich_volume_gt_25_ml true → +4; remaining flags false → 0
2. Score = 8 (max 48); elevated and setscore_ge_8 are true because score >= 8


### Dysphagia and space-occupying cerebellar lesion (below cut-off)

Given: `additional_respiratory_disease=false, apache_ii_gt_20=false, brainstem_lesion=false, diffuse_lesion=false, dysphagia=true, gcs_lt_10=false, hydrocephalus=false, ich_volume_gt_25_ml=false, lung_injury_score_gt_1=false, mca_infarct_gt_two_thirds=false, neurosurgical_intervention=false, observed_aspiration=false, pao2_fio2_lt_150=false, sepsis=false, space_occupying_cerebellar=true`

1. dysphagia true → +4; space_occupying_cerebellar true → +3; remaining flags false → 0
2. Score = 7 (max 48); elevated and setscore_ge_8 are false because score < 8


## Also searched as

- SETscore
- stroke-related early tracheostomy score
- SET score tracheostomy
- Schönenberger tracheostomy score
- cerebrovascular tracheostomy score
- neurocritical tracheostomy prediction
- early tracheostomy stroke score
- NICU tracheostomy SETscore

## Parameters

- `dysphagia` (boolean, required): Dysphagia (Schönenberger 2016 Table 1, +4 if true). true or false as assigned by the caller. magent does not examine swallow.
- `observed_aspiration` (boolean, required): Observed aspiration (Schönenberger 2016 Table 1, +3 if true). true or false as assigned by the caller. magent does not examine the patient.
- `gcs_lt_10` (boolean, required): GCS on admission <10 (Schönenberger 2016 Table 1, +3 if true). true or false as assigned by the caller. magent does not compute GCS.
- `brainstem_lesion` (boolean, required): Brainstem lesion (Schönenberger 2016 Table 1, +4 if true). true or false as assigned by the caller. magent does not read imaging.
- `space_occupying_cerebellar` (boolean, required): Space-occupying cerebellar lesion (Schönenberger 2016 Table 1, +3 if true). true or false as assigned by the caller. magent does not read imaging.
- `mca_infarct_gt_two_thirds` (boolean, required): Ischemic infarct >2/3 MCA territory (Schönenberger 2016 Table 1, +4 if true). true or false as assigned by the caller. magent does not read imaging.
- `ich_volume_gt_25_ml` (boolean, required): ICH volume >25 mL (Schönenberger 2016 Table 1, +4 if true). true or false as assigned by the caller. magent does not measure hematoma volume.
- `diffuse_lesion` (boolean, required): Diffuse lesion (Schönenberger 2016 Table 1, +3 if true). true or false as assigned by the caller. magent does not read imaging.
- `hydrocephalus` (boolean, required): Hydrocephalus (Schönenberger 2016 Table 1, +4 if true). true or false as assigned by the caller. magent does not read imaging.
- `neurosurgical_intervention` (boolean, required): (Neuro)surgical intervention (Schönenberger 2016 Table 1, +2 if true). true or false as assigned by the caller. magent does not record procedures.
- `additional_respiratory_disease` (boolean, required): Additional respiratory disease (Schönenberger 2016 Table 1, +3 if true). true or false as assigned by the caller. magent does not diagnose lung disease.
- `pao2_fio2_lt_150` (boolean, required): PaO2/FiO2 <150 (Schönenberger 2016 Table 1, +2 if true). true or false as assigned by the caller. magent does not compute the P/F ratio.
- `apache_ii_gt_20` (boolean, required): APACHE II acute physiology score >20 (Schönenberger 2016 Table 1, +4 if true). true or false as assigned by the caller. magent does not compute APACHE II.
- `lung_injury_score_gt_1` (boolean, required): Lung injury score >1 (Schönenberger 2016 Table 1, +2 if true). true or false as assigned by the caller. magent does not compute LIS.
- `sepsis` (boolean, required): Sepsis (Schönenberger 2016 Table 1, +3 if true). true or false as assigned by the caller. magent does not diagnose sepsis.

## Bulk (POST)

POST the same path with a JSON items array. The first item is the GET unit; each additional item is $0.002. Invalid items return HTTP 400 before settlement.

Method: `POST /api/calc/setscore`
Max items: 25
Price: unit_amount + extra_item_amount * (n - 1) (unit 5000 atomic, extra 2000 atomic)
Status: PREVIEW

- 1 to 25 items. Each item uses the same keys as the GET query parameters.
- POST of 1 item costs the same as GET. Lists longer than 25: chunk into multiple POSTs. Extra items still execute; do not pad dummy rows.
- The first invalid item fails the whole request (index in the 400 JSON). You are not charged.
- HTTP 200 is {count, path, items}. Each items[i] is the GET 200 body for that row.
- Catalog misses (empty matches, found=false) stay paid 200s inside that slot.
- x402 resource URL is this path plus n and body_sha256. Browsers that prefer text/html get the same paywall as GET; Pay retries POST with the same items.

Example request:

```json
{
  "items": [
    {
      "additional_respiratory_disease": "false",
      "apache_ii_gt_20": "false",
      "brainstem_lesion": "false",
      "diffuse_lesion": "false",
      "dysphagia": "false",
      "gcs_lt_10": "false",
      "hydrocephalus": "false",
      "ich_volume_gt_25_ml": "false",
      "lung_injury_score_gt_1": "false",
      "mca_infarct_gt_two_thirds": "false",
      "neurosurgical_intervention": "false",
      "observed_aspiration": "false",
      "pao2_fio2_lt_150": "false",
      "sepsis": "false",
      "space_occupying_cerebellar": "false"
    },
    {
      "additional_respiratory_disease": "false",
      "apache_ii_gt_20": "false",
      "brainstem_lesion": "false",
      "diffuse_lesion": "false",
      "dysphagia": "false",
      "gcs_lt_10": "false",
      "hydrocephalus": "false",
      "ich_volume_gt_25_ml": "false",
      "lung_injury_score_gt_1": "false",
      "mca_infarct_gt_two_thirds": "false",
      "neurosurgical_intervention": "false",
      "observed_aspiration": "false",
      "pao2_fio2_lt_150": "false",
      "sepsis": "false",
      "space_occupying_cerebellar": "false"
    }
  ]
}
```

Human paywall (two-item fixture): https://api.magentlab.com/paywall/bulk/setscore

Example 200:

```json
{
  "count": 2,
  "path": "/api/calc/setscore",
  "items": [
    {
      "components": [
        {
          "factor": "dysphagia",
          "points": 0,
          "present": false
        },
        {
          "factor": "observed_aspiration",
          "points": 0,
          "present": false
        },
        {
          "factor": "gcs_lt_10",
          "points": 0,
          "present": false
        },
        {
          "factor": "brainstem_lesion",
          "points": 0,
          "present": false
        },
        {
          "factor": "space_occupying_cerebellar",
          "points": 0,
          "present": false
        },
        {
          "factor": "mca_infarct_gt_two_thirds",
          "points": 0,
          "present": false
        },
        {
          "factor": "ich_volume_gt_25_ml",
          "points": 0,
          "present": false
        },
        {
          "factor": "diffuse_lesion",
          "points": 0,
          "present": false
        },
        {
          "factor": "hydrocephalus",
          "points": 0,
          "present": false
        },
        {
          "factor": "neurosurgical_intervention",
          "points": 0,
          "present": false
        },
        {
          "factor": "additional_respiratory_disease",
          "points": 0,
          "present": false
        },
        {
          "factor": "pao2_fio2_lt_150",
          "points": 0,
          "present": false
        },
        {
          "factor": "apache_ii_gt_20",
          "points": 0,
          "present": false
        },
        {
          "factor": "lung_injury_score_gt_1",
          "points": 0,
          "present": false
        },
        {
          "factor": "sepsis",
          "points": 0,
          "present": false
        }
      ],
      "disclaimer": "Not a medical device. Deterministic published-formula or published-code output for autonomous agents. A licensed clinician remains responsible for patient care and billing submissions.",
      "citation": {
        "authors": "Schönenberger S, Al-Suwaidan F, Kieser M, Uhlmann L, Bösel J",
        "doi": "10.1007/s12028-015-0235-5",
        "id": "schoenenberger-2016",
        "pmid": "26842719",
        "source": "Neurocrit Care. 2016;25(1):94-104",
        "title": "The SETscore to Predict Tracheostomy Need in Cerebrovascular Neurocritical Care Patients"
      },
      "formula": "setscore",
      "formula_expression": "SETscore = 4*dysphagia + 3*observed_aspiration + 3*gcs_lt_10 + 4*brainstem_lesion + 3*space_occupying_cerebellar + 4*mca_infarct_gt_two_thirds + 4*ich_volume_gt_25_ml + 3*diffuse_lesion + 4*hydrocephalus + 2*neurosurgical_intervention + 3*additional_respiratory_disease + 2*pao2_fio2_lt_150 + 4*apache_ii_gt_20 + 2*lung_injury_score_gt_1 + 3*sepsis; max 48; elevated / setscore_ge_8 iff score >= 8 (Schönenberger 2016)",
      "max_score": 48,
      "score": 0,
      "elevated": false,
      "setscore_ge_8": false
    },
    {
      "components": [
        {
          "factor": "dysphagia",
          "points": 0,
          "present": false
        },
        {
          "factor": "observed_aspiration",
          "points": 0,
          "present": false
        },
        {
          "factor": "gcs_lt_10",
          "points": 0,
          "present": false
        },
        {
          "factor": "brainstem_lesion",
          "points": 0,
          "present": false
        },
        {
          "factor": "space_occupying_cerebellar",
          "points": 0,
          "present": false
        },
        {
          "factor": "mca_infarct_gt_two_thirds",
          "points": 0,
          "present": false
        },
        {
          "factor": "ich_volume_gt_25_ml",
          "points": 0,
          "present": false
        },
        {
          "factor": "diffuse_lesion",
          "points": 0,
          "present": false
        },
        {
          "factor": "hydrocephalus",
          "points": 0,
          "present": false
        },
        {
          "factor": "neurosurgical_intervention",
          "points": 0,
          "present": false
        },
        {
          "factor": "additional_respiratory_disease",
          "points": 0,
          "present": false
        },
        {
          "factor": "pao2_fio2_lt_150",
          "points": 0,
          "present": false
        },
        {
          "factor": "apache_ii_gt_20",
          "points": 0,
          "present": false
        },
        {
          "factor": "lung_injury_score_gt_1",
          "points": 0,
          "present": false
        },
        {
          "factor": "sepsis",
          "points": 0,
          "present": false
        }
      ],
      "disclaimer": "Not a medical device. Deterministic published-formula or published-code output for autonomous agents. A licensed clinician remains responsible for patient care and billing submissions.",
      "citation": {
        "authors": "Schönenberger S, Al-Suwaidan F, Kieser M, Uhlmann L, Bösel J",
        "doi": "10.1007/s12028-015-0235-5",
        "id": "schoenenberger-2016",
        "pmid": "26842719",
        "source": "Neurocrit Care. 2016;25(1):94-104",
        "title": "The SETscore to Predict Tracheostomy Need in Cerebrovascular Neurocritical Care Patients"
      },
      "formula": "setscore",
      "formula_expression": "SETscore = 4*dysphagia + 3*observed_aspiration + 3*gcs_lt_10 + 4*brainstem_lesion + 3*space_occupying_cerebellar + 4*mca_infarct_gt_two_thirds + 4*ich_volume_gt_25_ml + 3*diffuse_lesion + 4*hydrocephalus + 2*neurosurgical_intervention + 3*additional_respiratory_disease + 2*pao2_fio2_lt_150 + 4*apache_ii_gt_20 + 2*lung_injury_score_gt_1 + 3*sepsis; max 48; elevated / setscore_ge_8 iff score >= 8 (Schönenberger 2016)",
      "max_score": 48,
      "score": 0,
      "elevated": false,
      "setscore_ge_8": false
    }
  ]
}
```

## Response fields

- `formula` (string): setscore
- `formula_expression` (string): Exact expression used
- `score` (integer): SETscore points 0-48 (Schönenberger 2016 Table 1)
- `max_score` (integer): 48
- `elevated` (boolean): true iff score >= 8 (Schönenberger 2016 ROC cut-off). Not a tracheostomy order.
- `setscore_ge_8` (boolean): true iff score >= 8 (Schönenberger 2016 ROC cut-off). Same as elevated. Not SETPOINT2 enrollment >10.
- `components` (array): Per-item points
- `citation` (object): Schönenberger et al. Neurocrit Care 2016 citation
- `disclaimer` (string): Not-a-device notice

## Example JSON

Frozen fixture. Not a live lookup.

```json
{
  "components": [
    {
      "factor": "dysphagia",
      "points": 0,
      "present": false
    },
    {
      "factor": "observed_aspiration",
      "points": 0,
      "present": false
    },
    {
      "factor": "gcs_lt_10",
      "points": 0,
      "present": false
    },
    {
      "factor": "brainstem_lesion",
      "points": 0,
      "present": false
    },
    {
      "factor": "space_occupying_cerebellar",
      "points": 0,
      "present": false
    },
    {
      "factor": "mca_infarct_gt_two_thirds",
      "points": 0,
      "present": false
    },
    {
      "factor": "ich_volume_gt_25_ml",
      "points": 0,
      "present": false
    },
    {
      "factor": "diffuse_lesion",
      "points": 0,
      "present": false
    },
    {
      "factor": "hydrocephalus",
      "points": 0,
      "present": false
    },
    {
      "factor": "neurosurgical_intervention",
      "points": 0,
      "present": false
    },
    {
      "factor": "additional_respiratory_disease",
      "points": 0,
      "present": false
    },
    {
      "factor": "pao2_fio2_lt_150",
      "points": 0,
      "present": false
    },
    {
      "factor": "apache_ii_gt_20",
      "points": 0,
      "present": false
    },
    {
      "factor": "lung_injury_score_gt_1",
      "points": 0,
      "present": false
    },
    {
      "factor": "sepsis",
      "points": 0,
      "present": false
    }
  ],
  "disclaimer": "Not a medical device. Deterministic published-formula or published-code output for autonomous agents. A licensed clinician remains responsible for patient care and billing submissions.",
  "citation": {
    "authors": "Schönenberger S, Al-Suwaidan F, Kieser M, Uhlmann L, Bösel J",
    "doi": "10.1007/s12028-015-0235-5",
    "id": "schoenenberger-2016",
    "pmid": "26842719",
    "source": "Neurocrit Care. 2016;25(1):94-104",
    "title": "The SETscore to Predict Tracheostomy Need in Cerebrovascular Neurocritical Care Patients"
  },
  "formula": "setscore",
  "formula_expression": "SETscore = 4*dysphagia + 3*observed_aspiration + 3*gcs_lt_10 + 4*brainstem_lesion + 3*space_occupying_cerebellar + 4*mca_infarct_gt_two_thirds + 4*ich_volume_gt_25_ml + 3*diffuse_lesion + 4*hydrocephalus + 2*neurosurgical_intervention + 3*additional_respiratory_disease + 2*pao2_fio2_lt_150 + 4*apache_ii_gt_20 + 2*lung_injury_score_gt_1 + 3*sepsis; max 48; elevated / setscore_ge_8 iff score >= 8 (Schönenberger 2016)",
  "max_score": 48,
  "score": 0,
  "elevated": false,
  "setscore_ge_8": false
}
```

## Errors

- HTTP 400 `invalid_flag`: boolean clinical flags must be true or false Returned before settlement; you are not charged.
- HTTP 400 `invalid_items`: POST body must be a JSON object with only an items array Returned before settlement; you are not charged.
- HTTP 400 `invalid_item_count`: items must be an array of 1 to 25 objects Returned before settlement; you are not charged.
- HTTP 400 `invalid_item`: each items entry must be a JSON object Returned before settlement; you are not charged.

Shared HTTP 402 and 503: https://magentlab.com/docs/payments

## Related tools

- [Glasgow Coma Scale](https://magentlab.com/docs/gcs) — Compute the Glasgow Coma Scale as the sum of caller-assigned eye, verbal, and motor integers. The 1974 or 1976 edition is required.
- [NIHSS](https://magentlab.com/docs/nihss) — Sum Brott 1989 NIH stroke scale points from 15 caller-assigned examination integers, including pupillary response and plantar reflex. Weaker-limb motor arm and leg. Does not apply later total-score severity bands.
- [APACHE II](https://magentlab.com/docs/apache-ii) — Compute the Knaus 1985 APACHE II integer from 12 Acute Physiology Score items, age points, and chronic-health points.

## Payment

Unpaid requests return HTTP 402 even if query parameters or POST items are missing or invalid, so CDP and agents can index the path. After a PAYMENT-SIGNATURE, invalid params return HTTP 400 JSON before settlement. magent does not charge. Fix the params, then request a new 402 quote for that complete URL. Catalog misses (empty matches, found=false) are valid paid 200s.

- GET the tool with Accept: application/json (do not send Accept: text/html unless you want the human paywall).
- HTTP 402 means you have not paid. Decode the base64 PAYMENT-REQUIRED header. HTTP 503 is not a new quote.
- Sign accepts[0] (exact, EIP-3009) with validBefore = now + maxTimeoutSeconds (600 seconds), or accepts[1] (batch-settlement deposit/voucher) on product GET. Ping and POST {items} stay exact. Magent retries transient facilitator 429/5xx before answering.
- Retry the same URL with PAYMENT-SIGNATURE (base64 JSON of accepted and payload). Magent attaches canonical extensions.bazaar on CDP verify/settle; echoing 402 bazaar is optional.
- Success is HTTP 200 JSON plus PAYMENT-RESPONSE. exact settles before the tool. batch-settlement verifies (and deposit-settles) before the tool and commits the charge after HTTP 2xx. HTTP 503: retry the same PAYMENT-SIGNATURE. Mint a new exact nonce only after a new HTTP 402.

- offered `exact` on eip155:8453: Fixed-price USDC on Base. The buyer authorizes the advertised amount (EIP-3009). magent settles before the tool runs (paymentFlow upfront). extra.assetTransferMethod=eip3009 extra.paymentFlow=upfront.
- offered `batch-settlement` on eip155:8453: Payment-channel vouchers claimed later in batches. Exact stays accepts[0]. Same-path POST {items} is still exact. extra.assetTransferMethod=eip3009 extra.paymentFlow=authorization.

- not offered `upto`: Not offered. Usage-based: buyer authorizes a ceiling, seller settles the actual amount after work. Reserved for a future metered tool. Not for current calculators or code search.

Same-path POST {items} is still scheme exact: one EIP-3009 authorization for GET unit plus $0.002 per extra item. That is not x402 batch-settlement (payment channels / vouchers).

Shared HTTP 402 and 503 table: https://magentlab.com/docs/payments

Stdio MCP (one process per host): https://magentlab.com/docs/mcp

## Guarantees

- HTTP 402 is unpaid, including a missing query. After PAYMENT-SIGNATURE, invalid parameters return HTTP 400 before settlement. You are not charged. HTTP 402 never includes the tool JSON.
- exact: settlement finishes before the tool (paymentFlow upfront). batch-settlement: verify/deposit before the tool; chargedCumulativeAmount commits after HTTP 2xx. Uncertain or failed settlement fails closed (HTTP 503). Retry the same PAYMENT-SIGNATURE.
- HTTP 402 is unpaid only. Do not sign a second authorization because of a 503.
- Execution is timeout-bounded and concurrency-capped.
- Calculator inputs are stored encrypted for allowlisted operators (Magent Console). They are not in public logs, SSH lookups, catalog, or rollups. Request logs store path without query.
