# Murray lung injury score (LIS)

Murray lung injury score

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

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

## What it computes

Mean the four Murray 1988 lung injury score components (chest radiograph quadrants, PaO2/FiO2, PEEP, and compliance), each 0–4, and return LIS and injury_band.

## When to use

When an agent has caller-assigned chest radiograph quadrants and the three physiologic components and needs the published Murray LIS mean, not a Berlin ARDS diagnosis and not a ventilator order.

## When not to use

- Not a medical device.
- Not a Berlin ARDS diagnosis. injury_band is Murray 1988 none / mild_moderate / severe from the LIS mean, not the Berlin definition.
- Not a ventilator order. magent does not set PEEP or measure compliance.
- magent does not interpret imaging; the caller assigns chest radiograph quadrants (0–4). All four components are required; missing components are not dropped.

## Formula

```
LIS = mean of chest_radiograph_quadrants (0–4) + PaO2/FiO2 (≥300→0, 225–299→1, 175–224→2, 100–174→3, <100→4) + PEEP cm H2O (≤5→0, 6–8→1, 9–11→2, 12–14→3, ≥15→4) + compliance mL/cm H2O (≥80→0, 60–79→1, 40–59→2, 20–39→3, ≤19→4); Murray 1988; none if LIS=0, mild_moderate if 0<LIS≤2.5, severe if LIS>2.5
```

## Citation

[An expanded definition of the adult respiratory distress syndrome](https://doi.org/10.1164/ajrccm/138.3.720)
Murray JF, Matthay MA, Luce JM, Flick MR
Am Rev Respir Dis. 1988;138(3):720-723
DOI: [10.1164/ajrccm/138.3.720](https://doi.org/10.1164/ajrccm/138.3.720)

## Worked example

### All components 0

Given: `chest_radiograph_quadrants=0, compliance_ml_cm_h2o=90, peep_cm_h2o=5, pf_ratio=400`

1. chest_radiograph_quadrants 0 → 0
2. pf_ratio 400 ≥300 → 0
3. peep_cm_h2o 5 ≤5 → 0
4. compliance_ml_cm_h2o 90 ≥80 → 0
5. LIS = (0+0+0+0)/4 = 0.0; injury_band none


### LIS 2.5 mild_moderate

Given: `chest_radiograph_quadrants=2, compliance_ml_cm_h2o=20, peep_cm_h2o=12, pf_ratio=175`

1. chest_radiograph_quadrants 2 → 2
2. pf_ratio 175 → 2
3. peep_cm_h2o 12 → 3
4. compliance_ml_cm_h2o 20 → 3
5. LIS = (2+2+3+3)/4 = 2.5; injury_band mild_moderate (2.5 is not severe)


## Also searched as

- Murray LIS
- lung injury score
- Murray lung injury score
- LIS Murray 1988
- acute lung injury score
- Murray 1988 LIS

## Parameters

- `chest_radiograph_quadrants` (integer, required): Caller-assigned alveolar consolidation quadrants 0-4 (Murray 1988). 0 none, 1 one quadrant, 2 two quadrants, 3 three quadrants, 4 four quadrants. The integer is that component's points. magent does not interpret imaging.
- `pf_ratio` (number, required): PaO2/FiO2 ratio (20-800). Murray 1988: ≥300 → 0, 225-299 → 1, 175-224 → 2, 100-174 → 3, <100 → 4. magent does not read an ABG.
- `peep_cm_h2o` (number, required): PEEP in cm H2O (0-40). Murray 1988: ≤5 → 0, 6-8 → 1, 9-11 → 2, 12-14 → 3, ≥15 → 4. Not a ventilator order. magent does not set PEEP.
- `compliance_ml_cm_h2o` (number, required): Respiratory system compliance in mL/cm H2O (5-200). Murray 1988: ≥80 → 0, 60-79 → 1, 40-59 → 2, 20-39 → 3, ≤19 → 4. magent does not measure compliance.

## 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/murray`
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": [
    {
      "chest_radiograph_quadrants": "0",
      "compliance_ml_cm_h2o": "90",
      "peep_cm_h2o": "5",
      "pf_ratio": "400"
    },
    {
      "chest_radiograph_quadrants": "0",
      "compliance_ml_cm_h2o": "90",
      "peep_cm_h2o": "5",
      "pf_ratio": "400"
    }
  ]
}
```

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

Example 200:

```json
{
  "count": 2,
  "path": "/api/calc/murray",
  "items": [
    {
      "components": [
        {
          "value": 0,
          "factor": "chest_radiograph_quadrants",
          "points": 0,
          "present": false
        },
        {
          "value": 400.0,
          "factor": "pf_ratio",
          "points": 0,
          "present": false
        },
        {
          "value": 5.0,
          "factor": "peep_cm_h2o",
          "points": 0,
          "present": false
        },
        {
          "value": 90.0,
          "factor": "compliance_ml_cm_h2o",
          "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": "Murray JF, Matthay MA, Luce JM, Flick MR",
        "doi": "10.1164/ajrccm/138.3.720",
        "id": "murray-1988",
        "pmid": "3202424",
        "source": "Am Rev Respir Dis. 1988;138(3):720-723",
        "title": "An expanded definition of the adult respiratory distress syndrome"
      },
      "formula": "murray",
      "formula_expression": "LIS = mean of chest_radiograph_quadrants (0–4) + PaO2/FiO2 (≥300→0, 225–299→1, 175–224→2, 100–174→3, <100→4) + PEEP cm H2O (≤5→0, 6–8→1, 9–11→2, 12–14→3, ≥15→4) + compliance mL/cm H2O (≥80→0, 60–79→1, 40–59→2, 20–39→3, ≤19→4); Murray 1988; none if LIS=0, mild_moderate if 0<LIS≤2.5, severe if LIS>2.5",
      "pf_ratio": 400.0,
      "chest_radiograph_quadrants": 0,
      "compliance_ml_cm_h2o": 90.0,
      "injury_band": "none",
      "lis": 0.0,
      "peep_cm_h2o": 5.0
    },
    {
      "components": [
        {
          "value": 0,
          "factor": "chest_radiograph_quadrants",
          "points": 0,
          "present": false
        },
        {
          "value": 400.0,
          "factor": "pf_ratio",
          "points": 0,
          "present": false
        },
        {
          "value": 5.0,
          "factor": "peep_cm_h2o",
          "points": 0,
          "present": false
        },
        {
          "value": 90.0,
          "factor": "compliance_ml_cm_h2o",
          "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": "Murray JF, Matthay MA, Luce JM, Flick MR",
        "doi": "10.1164/ajrccm/138.3.720",
        "id": "murray-1988",
        "pmid": "3202424",
        "source": "Am Rev Respir Dis. 1988;138(3):720-723",
        "title": "An expanded definition of the adult respiratory distress syndrome"
      },
      "formula": "murray",
      "formula_expression": "LIS = mean of chest_radiograph_quadrants (0–4) + PaO2/FiO2 (≥300→0, 225–299→1, 175–224→2, 100–174→3, <100→4) + PEEP cm H2O (≤5→0, 6–8→1, 9–11→2, 12–14→3, ≥15→4) + compliance mL/cm H2O (≥80→0, 60–79→1, 40–59→2, 20–39→3, ≤19→4); Murray 1988; none if LIS=0, mild_moderate if 0<LIS≤2.5, severe if LIS>2.5",
      "pf_ratio": 400.0,
      "chest_radiograph_quadrants": 0,
      "compliance_ml_cm_h2o": 90.0,
      "injury_band": "none",
      "lis": 0.0,
      "peep_cm_h2o": 5.0
    }
  ]
}
```

## Response fields

- `formula` (string): murray
- `formula_expression` (string): Exact expression used
- `lis` (number): Murray lung injury score: mean of the four 0-4 components, 2 decimals
- `injury_band` (string): Murray 1988: none if LIS=0, mild_moderate if 0<LIS≤2.5, severe if LIS>2.5. Not a Berlin ARDS diagnosis.
- `chest_radiograph_quadrants` (integer): Caller-assigned quadrants 0-4 used
- `pf_ratio` (number): PaO2/FiO2 used
- `peep_cm_h2o` (number): PEEP in cm H2O used
- `compliance_ml_cm_h2o` (number): Respiratory system compliance in mL/cm H2O used
- `components` (array): Per-component Murray 1988 points
- `citation` (object): Murray et al. Am Rev Respir Dis 1988 citation
- `disclaimer` (string): Not-a-device notice

## Example JSON

Frozen fixture. Not a live lookup.

```json
{
  "components": [
    {
      "value": 0,
      "factor": "chest_radiograph_quadrants",
      "points": 0,
      "present": false
    },
    {
      "value": 400.0,
      "factor": "pf_ratio",
      "points": 0,
      "present": false
    },
    {
      "value": 5.0,
      "factor": "peep_cm_h2o",
      "points": 0,
      "present": false
    },
    {
      "value": 90.0,
      "factor": "compliance_ml_cm_h2o",
      "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": "Murray JF, Matthay MA, Luce JM, Flick MR",
    "doi": "10.1164/ajrccm/138.3.720",
    "id": "murray-1988",
    "pmid": "3202424",
    "source": "Am Rev Respir Dis. 1988;138(3):720-723",
    "title": "An expanded definition of the adult respiratory distress syndrome"
  },
  "formula": "murray",
  "formula_expression": "LIS = mean of chest_radiograph_quadrants (0–4) + PaO2/FiO2 (≥300→0, 225–299→1, 175–224→2, 100–174→3, <100→4) + PEEP cm H2O (≤5→0, 6–8→1, 9–11→2, 12–14→3, ≥15→4) + compliance mL/cm H2O (≥80→0, 60–79→1, 40–59→2, 20–39→3, ≤19→4); Murray 1988; none if LIS=0, mild_moderate if 0<LIS≤2.5, severe if LIS>2.5",
  "pf_ratio": 400.0,
  "chest_radiograph_quadrants": 0,
  "compliance_ml_cm_h2o": 90.0,
  "injury_band": "none",
  "lis": 0.0,
  "peep_cm_h2o": 5.0
}
```

## Errors

- HTTP 400 `invalid_murray`: chest_radiograph_quadrants must be an integer 0, 1, 2, 3, or 4 (Murray 1988). Returned before settlement; you are not charged.
- HTTP 400 `invalid_pf_ratio`: pf_ratio must be a number from 20 to 800. Returned before settlement; you are not charged.
- HTTP 400 `invalid_peep_cm_h2o`: peep_cm_h2o must be a number from 0 to 40 (Murray 1988). Returned before settlement; you are not charged.
- HTTP 400 `invalid_compliance_ml_cm`: compliance_ml_cm_h2o must be a number from 5 to 200 (Murray 1988). 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

- [PaO2/FiO2 ratio](https://magentlab.com/docs/pf-ratio) — Compute the PaO2/FiO2 ratio as arterial PO2 in mm Hg divided by inspired oxygen fraction.

## 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.
