# POMPE-C (Kline 2012)

POMPE-C

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

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

## What it computes

Compute the Kline 2012 POMPE-C 30-day mortality probability for a caller who already has active cancer and acute pulmonary embolism, from five dichotomous findings plus respiratory rate, room-air SpO2, and weight in pounds.

## When to use

When an agent already has active cancer and image-proven acute PE as in the paper and needs the published logistic 30-day mortality percent and low/intermediate/high band, not a PE or cancer diagnosis, not integer points, and not a treatment or dose order.

## When not to use

- Not a medical device. magent does not diagnose pulmonary embolism or cancer and does not recommend a dose or disposition.
- Derivation and validation were patients with active cancer and acute PE. This is not a PE diagnostic tool and not a cancer-screening tool.
- This is the Kline 2012 web-prototype logistic (intercept 3.718). magent does not emit integer points or a survival percent other than this 30-day mortality estimate.
- Dichotomous inputs are caller-assigned. magent does not examine the patient, read a DNR order, take a pulse, or measure saturation or weight.
- SpO2 is room-air pulse oximetry as in the paper. Weight is pounds. Bands are the paper's 5% and 50% validation cutoffs, not treatment thresholds.

## Formula

```
mortality_pct = 100 * (1 - 1 / (1 + exp(3.718 + 1.551*dnr + 0.800*respiratory_distress + 0.734*unilateral_leg_swelling + 1.473*altered_mental_status + 1.027*heart_rate_gt_99 + 0.044*respiratory_rate + (-0.063)*spo2_percent + (-0.012)*weight_lb))); Kline 2012 web-prototype logistic (intercept 3.718); heart_rate_gt_99 coefficient 1.027 from Table 2 (OR 2.8) because the manuscript prototype line-wraps as + HR; flags 1 if true else 0; low if mortality_pct <= 5, high if > 50, else intermediate; 30-day all-cause mortality probability for active cancer + acute PE; not integer points
```

## Citation

[Derivation and validation of a multivariate model to predict mortality from pulmonary embolism with cancer: The POMPE-C tool](https://doi.org/10.1016/j.thromres.2012.03.015)
Kline JA, Roy PM, Than MP, Hernandez J, Courtney DM, Jones AE, Penaloza A, Pollack CV Jr
Thromb Res. 2012;129(5):e194-e199
DOI: [10.1016/j.thromres.2012.03.015](https://doi.org/10.1016/j.thromres.2012.03.015)

## Worked example

### No flags, RR 18, SpO2 97, weight 170 lb

Given: `altered_mental_status=false, dnr=false, heart_rate_gt_99=false, respiratory_distress=false, respiratory_rate=18, spo2_percent=97, unilateral_leg_swelling=false, weight_lb=170`

1. logit = 3.718 + 0.044×18 + (−0.063)×97 + (−0.012)×170 = −3.641
2. mortality_pct = 100 × (1 − 1 / (1 + exp(−3.641))) = 2.6
3. risk_band low (mortality_pct <= 5)


### All flags present, RR 28, SpO2 88, weight 120 lb

Given: `altered_mental_status=true, dnr=true, heart_rate_gt_99=true, respiratory_distress=true, respiratory_rate=28, spo2_percent=88, unilateral_leg_swelling=true, weight_lb=120`

1. logit = 3.718 + 1.551 + 0.800 + 0.734 + 1.473 + 1.027 + 0.044×28 + (−0.063)×88 + (−0.012)×120 = 3.551
2. mortality_pct from the prototype logistic is > 50
3. risk_band high


## Also searched as

- POMPE-C
- Kline POMPE-C
- PE cancer mortality
- pulmonary embolism cancer
- POMPE C
- Kline 2012 PE mortality
- cancer PE 30-day mortality

## Parameters

- `dnr` (boolean, required): Do-not-resuscitate status as assigned by the caller (Kline 2012: new or existing verbal or written desire not to be resuscitated). true or false. magent does not read an advance directive.
- `respiratory_distress` (boolean, required): Respiratory distress as assigned by the caller (Kline 2012: obvious anxiety from dyspnea or increased work of breathing). true or false. magent does not examine the patient.
- `unilateral_leg_swelling` (boolean, required): Unilateral limb swelling as assigned by the caller (Kline 2012: new noticeable arm or leg asymmetry). true or false. magent does not examine the limbs.
- `altered_mental_status` (boolean, required): Altered mental status as assigned by the caller (Kline 2012: acute impairment in consciousness, new disorientation, delirium, or confusion). true or false. magent does not examine the patient.
- `heart_rate_gt_99` (boolean, required): Heart rate documented over 99 beats/min in the previous six hours, as assigned by the caller. true or false. magent does not take a pulse.
- `respiratory_rate` (integer, required): Highest documented respiratory rate in breaths/min within the previous six hours (integer 4-80). Continuous predictor in the Kline 2012 prototype logistic.
- `spo2_percent` (number, required): Most recent pulse oximetry on room air, percent (50-100). Continuous predictor in the Kline 2012 prototype logistic. magent does not measure saturation.
- `weight_lb` (number, required): Body weight in pounds (2-1100), measured or by patient estimate as in Kline 2012. Pounds enter the logistic directly. magent does not convert from kilograms.

## 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/pompe_c`
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": [
    {
      "altered_mental_status": "false",
      "dnr": "false",
      "heart_rate_gt_99": "false",
      "respiratory_distress": "false",
      "respiratory_rate": "18",
      "spo2_percent": "97",
      "unilateral_leg_swelling": "false",
      "weight_lb": "170"
    },
    {
      "altered_mental_status": "false",
      "dnr": "false",
      "heart_rate_gt_99": "false",
      "respiratory_distress": "false",
      "respiratory_rate": "18",
      "spo2_percent": "97",
      "unilateral_leg_swelling": "false",
      "weight_lb": "170"
    }
  ]
}
```

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

Example 200:

```json
{
  "count": 2,
  "path": "/api/calc/pompe_c",
  "items": [
    {
      "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": "Kline JA, Roy PM, Than MP, Hernandez J, Courtney DM, Jones AE, Penaloza A, Pollack CV Jr",
        "doi": "10.1016/j.thromres.2012.03.015",
        "id": "kline-2012",
        "pmid": "22475313",
        "source": "Thromb Res. 2012;129(5):e194-e199",
        "title": "Derivation and validation of a multivariate model to predict mortality from pulmonary embolism with cancer: The POMPE-C tool"
      },
      "formula": "pompe_c",
      "formula_expression": "mortality_pct = 100 * (1 - 1 / (1 + exp(3.718 + 1.551*dnr + 0.800*respiratory_distress + 0.734*unilateral_leg_swelling + 1.473*altered_mental_status + 1.027*heart_rate_gt_99 + 0.044*respiratory_rate + (-0.063)*spo2_percent + (-0.012)*weight_lb))); Kline 2012 web-prototype logistic (intercept 3.718); heart_rate_gt_99 coefficient 1.027 from Table 2 (OR 2.8) because the manuscript prototype line-wraps as + HR; flags 1 if true else 0; low if mortality_pct <= 5, high if > 50, else intermediate; 30-day all-cause mortality probability for active cancer + acute PE; not integer points",
      "risk_band": "low",
      "logit": -3.641,
      "spo2_percent": 97.0,
      "respiratory_rate": 18,
      "altered_mental_status": false,
      "dnr": false,
      "heart_rate_gt_99": false,
      "mortality_pct": 2.6,
      "respiratory_distress": false,
      "unilateral_leg_swelling": false,
      "weight_lb": 170.0
    },
    {
      "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": "Kline JA, Roy PM, Than MP, Hernandez J, Courtney DM, Jones AE, Penaloza A, Pollack CV Jr",
        "doi": "10.1016/j.thromres.2012.03.015",
        "id": "kline-2012",
        "pmid": "22475313",
        "source": "Thromb Res. 2012;129(5):e194-e199",
        "title": "Derivation and validation of a multivariate model to predict mortality from pulmonary embolism with cancer: The POMPE-C tool"
      },
      "formula": "pompe_c",
      "formula_expression": "mortality_pct = 100 * (1 - 1 / (1 + exp(3.718 + 1.551*dnr + 0.800*respiratory_distress + 0.734*unilateral_leg_swelling + 1.473*altered_mental_status + 1.027*heart_rate_gt_99 + 0.044*respiratory_rate + (-0.063)*spo2_percent + (-0.012)*weight_lb))); Kline 2012 web-prototype logistic (intercept 3.718); heart_rate_gt_99 coefficient 1.027 from Table 2 (OR 2.8) because the manuscript prototype line-wraps as + HR; flags 1 if true else 0; low if mortality_pct <= 5, high if > 50, else intermediate; 30-day all-cause mortality probability for active cancer + acute PE; not integer points",
      "risk_band": "low",
      "logit": -3.641,
      "spo2_percent": 97.0,
      "respiratory_rate": 18,
      "altered_mental_status": false,
      "dnr": false,
      "heart_rate_gt_99": false,
      "mortality_pct": 2.6,
      "respiratory_distress": false,
      "unilateral_leg_swelling": false,
      "weight_lb": 170.0
    }
  ]
}
```

## Response fields

- `formula` (string): pompe_c
- `formula_expression` (string): Kline 2012 web-prototype logistic expression
- `dnr` (boolean): Do-not-resuscitate flag used
- `respiratory_distress` (boolean): Respiratory-distress flag used
- `unilateral_leg_swelling` (boolean): Unilateral limb-swelling flag used
- `altered_mental_status` (boolean): Altered-mental-status flag used
- `heart_rate_gt_99` (boolean): Heart-rate-over-99 flag used
- `respiratory_rate` (integer): Respiratory rate in breaths/min used
- `spo2_percent` (number): Room-air pulse oximetry percent used
- `weight_lb` (number): Body weight in pounds used
- `logit` (number): Kline 2012 prototype linear predictor, 4 decimal places
- `mortality_pct` (number): Estimated 30-day all-cause mortality probability in percent (0-100), 1 decimal. Not a survival percent.
- `risk_band` (string): Kline 2012 validation cutoffs: low if mortality_pct <= 5, high if > 50, else intermediate. A band, not a treatment order.
- `citation` (object): Kline et al. Thromb Res 2012 citation
- `disclaimer` (string): Not-a-device notice

## Example JSON

Frozen fixture. Not a live lookup.

```json
{
  "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": "Kline JA, Roy PM, Than MP, Hernandez J, Courtney DM, Jones AE, Penaloza A, Pollack CV Jr",
    "doi": "10.1016/j.thromres.2012.03.015",
    "id": "kline-2012",
    "pmid": "22475313",
    "source": "Thromb Res. 2012;129(5):e194-e199",
    "title": "Derivation and validation of a multivariate model to predict mortality from pulmonary embolism with cancer: The POMPE-C tool"
  },
  "formula": "pompe_c",
  "formula_expression": "mortality_pct = 100 * (1 - 1 / (1 + exp(3.718 + 1.551*dnr + 0.800*respiratory_distress + 0.734*unilateral_leg_swelling + 1.473*altered_mental_status + 1.027*heart_rate_gt_99 + 0.044*respiratory_rate + (-0.063)*spo2_percent + (-0.012)*weight_lb))); Kline 2012 web-prototype logistic (intercept 3.718); heart_rate_gt_99 coefficient 1.027 from Table 2 (OR 2.8) because the manuscript prototype line-wraps as + HR; flags 1 if true else 0; low if mortality_pct <= 5, high if > 50, else intermediate; 30-day all-cause mortality probability for active cancer + acute PE; not integer points",
  "risk_band": "low",
  "logit": -3.641,
  "spo2_percent": 97.0,
  "respiratory_rate": 18,
  "altered_mental_status": false,
  "dnr": false,
  "heart_rate_gt_99": false,
  "mortality_pct": 2.6,
  "respiratory_distress": false,
  "unilateral_leg_swelling": false,
  "weight_lb": 170.0
}
```

## Errors

- HTTP 400 `invalid_flag`: boolean clinical flags must be true or false Returned before settlement; you are not charged.
- HTTP 400 `invalid_respiratory_rate`: respiratory_rate must be an integer from 4 to 80. Returned before settlement; you are not charged.
- HTTP 400 `invalid_spo2`: spo2_percent must be a number from 50 to 100. Returned before settlement; you are not charged.
- HTTP 400 `invalid_weight`: weight_kg (1-500) or weight_lb (2-1100) is required 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

- [PESI](https://magentlab.com/docs/pesi) — Compute the Aujesky 2005 Pulmonary Embolism Severity Index (PESI) from age, sex, comorbidities, vital signs, and altered mental status.
- [sPESI](https://magentlab.com/docs/spesi) — Compute the Jiménez 2010 simplified Pulmonary Embolism Severity Index (sPESI) from age and five caller-assigned findings.

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