MAGENT

Emergency · LIVE

Revised Intensity Battle Score (RIBS)

RIBS

Sum Buchholz 2023 RIBS regression points from caller-assigned rib-level fracture count, chest tube, pulmonary contusions, COPD, and GCS <15, and return the integer score and the published score-12 ICU triage band.

LIVE $0.005 USDC GET /api/calc/ribs

Markdown: /docs/ribs.md · Canonical: https://magentlab.com/docs/ribs

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

What it computes

Sum Buchholz 2023 RIBS regression points from caller-assigned rib-level fracture count, chest tube, pulmonary contusions, COPD, and GCS <15, and return the integer score and the published score-12 ICU triage band.

When to use

When an agent already has caller-assigned Buchholz 2023 inputs after rib fractures and needs the published RIBS total and score-12 band, not a CT rib count, GCS exam, Chapman 2016 RibScore, Battle 2014 STUMBL, diagnosis, or surgical plan.

When not to use

  • Not a medical device. Not a diagnosis, disposition, ICU-admission, or surgical plan.
  • Not Chapman 2016 RibScore (six radiographic flags, integer 0–6 at /api/calc/ribscore). RIBS is the Buchholz 2023 Revised Intensity Battle Score.
  • Not Battle 2014 STUMBL. Age is not a component; the paper found age was not predictive.
  • magent does not read a CT, count ribs, or compute GCS. Rib count is rib level, not individual fracture count. Chest tube, pulmonary contusions, and COPD are caller-assigned flags.

Formula

RIBS = round(2.275*rib_count + 1.525*pulmonary_contusions + 2.83*copd + 4.08*chest_tube + 8.137*(gcs<15)); Buchholz 2023; rib level not fracture count; age is not a component; ICU triage cutoff 12; not Chapman 2016 RibScore; not Battle 2014 STUMBL

Citation

Title
Revised Intensity Battle Score (RIBS): Development of a Clinical Score for Predicting Poor Outcomes After Rib Fractures
Authors
Buchholz CJ, Jia L, Manea C, Petersen T, Wang H, Stright A, Young JS, Calland JF
Source
Am Surg. 2023;89(10):4668-4674
DOI
10.1177/00031348221123087

Worked example

One rib, GCS 15, no flags

Given: chest_tube=falsecopd=falsegcs=15pulmonary_contusions=falserib_count=1

  1. rib_count 1 × 2.275 = 2.275; chest_tube, pulmonary_contusions, and copd false → 0; GCS 15 → GCS <15 false → 0
  2. score = round(2.275) = 2; ribs_band below_12 (published ICU triage cutoff is 12)

Four ribs and COPD at the score-12 cutoff

Given: chest_tube=falsecopd=truegcs=15pulmonary_contusions=falserib_count=4

  1. rib_count 4 × 2.275 = 9.1; copd true → 2.83; other flags false; GCS 15 → 0
  2. score = round(11.93) = 12; ribs_band at_or_above_12

Also searched as

  • Revised Intensity Battle Score
  • RIBS
  • Buchholz RIBS
  • revised Battle score
  • rib fracture triage score
  • intensity Battle score
  • Buchholz 2023 rib score

Try

Opens the live endpoint. Unpaid browser requests show the paywall; agents should send Accept: application/json.

/api/calc/ribs?rib_count=1&chest_tube=false&pulmonary_contusions=false&copd=false&gcs=15

Full URL: https://api.magentlab.com/api/calc/ribs?rib_count=1&chest_tube=false&pulmonary_contusions=false&copd=false&gcs=15

Call

Expect HTTP 402 until you retry with PAYMENT-SIGNATURE. Incomplete query params return HTTP 400 before any quote or charge.

curl -i -H "Accept: application/json" "https://api.magentlab.com/api/calc/ribs?rib_count=1&chest_tube=false&pulmonary_contusions=false&copd=false&gcs=15"

Parameters

Name Type Required Description
rib_count integer required Caller-assigned number of fractured rib levels, integer 0–24. Buchholz 2023: 2.275 points per rib level, not per individual fracture (six fractures on three ribs is 3). magent does not read a CT or count ribs.
chest_tube boolean required Chest tube placed, present, or anticipated as assigned by the caller (Buchholz 2023). true or false. true scores 4.08 before rounding.
pulmonary_contusions boolean required Pulmonary contusions as assigned by the caller (Buchholz 2023). true or false. true scores 1.525 before rounding. magent does not read a CT.
copd boolean required History of COPD as assigned by the caller (Buchholz 2023). true or false. true scores 2.83 before rounding. Age is not a component.
gcs integer required Caller-assigned Glasgow Coma Scale total, integer 3–15. Buchholz 2023 scores 8.137 when GCS <15 and 0 when GCS is 15. magent does not compute eye, verbal, or motor.

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.

POST /api/calc/ribs Max 25 unit_amount + extra_item_amount * (n - 1) extra $0.002 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 (fixture)

{
  "items": [
    {
      "chest_tube": "false",
      "copd": "false",
      "gcs": "15",
      "pulmonary_contusions": "false",
      "rib_count": "1"
    },
    {
      "chest_tube": "false",
      "copd": "false",
      "gcs": "15",
      "pulmonary_contusions": "false",
      "rib_count": "1"
    }
  ]
}

Open bulk paywall →

Opens a two-item fixture on the API host. Unpaid browsers get the same MetaMask paywall as GET; Pay retries POST with those items.

Example 200 (fixture)

{
  "count": 2,
  "path": "/api/calc/ribs",
  "items": [
    {
      "components": [
        {
          "value": 1,
          "factor": "rib_count",
          "points": 2.275,
          "present": true
        },
        {
          "factor": "chest_tube",
          "points": 0.0,
          "present": false
        },
        {
          "factor": "pulmonary_contusions",
          "points": 0.0,
          "present": false
        },
        {
          "factor": "copd",
          "points": 0.0,
          "present": false
        },
        {
          "value": 15,
          "factor": "gcs",
          "points": 0.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": "Buchholz CJ, Jia L, Manea C, Petersen T, Wang H, Stright A, Young JS, Calland JF",
        "doi": "10.1177/00031348221123087",
        "id": "buchholz-2022",
        "pmid": "36120831",
        "source": "Am Surg. 2023;89(10):4668-4674",
        "title": "Revised Intensity Battle Score (RIBS): Development of a Clinical Score for Predicting Poor Outcomes After Rib Fractures"
      },
      "formula": "ribs",
      "formula_expression": "RIBS = round(2.275*rib_count + 1.525*pulmonary_contusions + 2.83*copd + 4.08*chest_tube + 8.137*(gcs<15)); Buchholz 2023; rib level not fracture count; age is not a component; ICU triage cutoff 12; not Chapman 2016 RibScore; not Battle 2014 STUMBL",
      "score": 2,
      "mortality_percent": 2.8,
      "gcs": 15,
      "copd": false,
      "any_complication_percent": 7.5,
      "chest_tube": false,
      "gcs_lt_15": false,
      "icu_triage_cutoff": false,
      "pneumonia_or_vap_percent": 3.0,
      "pulmonary_contusions": false,
      "rib_count": 1,
      "ribs_band": "below_12",
      "unplanned_icu_or_intubation_percent": 4.7,
      "vent_or_tracheostomy_percent": 1.9
    },
    {
      "components": [
        {
          "value": 1,
          "factor": "rib_count",
          "points": 2.275,
          "present": true
        },
        {
          "factor": "chest_tube",
          "points": 0.0,
          "present": false
        },
        {
          "factor": "pulmonary_contusions",
          "points": 0.0,
          "present": false
        },
        {
          "factor": "copd",
          "points": 0.0,
          "present": false
        },
        {
          "value": 15,
          "factor": "gcs",
          "points": 0.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": "Buchholz CJ, Jia L, Manea C, Petersen T, Wang H, Stright A, Young JS, Calland JF",
        "doi": "10.1177/00031348221123087",
        "id": "buchholz-2022",
        "pmid": "36120831",
        "source": "Am Surg. 2023;89(10):4668-4674",
        "title": "Revised Intensity Battle Score (RIBS): Development of a Clinical Score for Predicting Poor Outcomes After Rib Fractures"
      },
      "formula": "ribs",
      "formula_expression": "RIBS = round(2.275*rib_count + 1.525*pulmonary_contusions + 2.83*copd + 4.08*chest_tube + 8.137*(gcs<15)); Buchholz 2023; rib level not fracture count; age is not a component; ICU triage cutoff 12; not Chapman 2016 RibScore; not Battle 2014 STUMBL",
      "score": 2,
      "mortality_percent": 2.8,
      "gcs": 15,
      "copd": false,
      "any_complication_percent": 7.5,
      "chest_tube": false,
      "gcs_lt_15": false,
      "icu_triage_cutoff": false,
      "pneumonia_or_vap_percent": 3.0,
      "pulmonary_contusions": false,
      "rib_count": 1,
      "ribs_band": "below_12",
      "unplanned_icu_or_intubation_percent": 4.7,
      "vent_or_tracheostomy_percent": 1.9
    }
  ]
}

Response

Field Type Description
formula string ribs
formula_expression string Exact expression used
score integer Buchholz 2023 RIBS, rounded nearest integer
ribs_band string below_12 or at_or_above_12. Published ICU triage cutoff is 12. A band, not an ICU order.
icu_triage_cutoff boolean true when score ≥12 (Buchholz 2023 recommended ICU triage cutoff)
any_complication_percent number Published any-complication percent from logit 0.1879*score − 2.8823
unplanned_icu_or_intubation_percent number Published unplanned ICU-upgrade or intubation percent
vent_or_tracheostomy_percent number Published >7 ventilator-days or tracheostomy percent
pneumonia_or_vap_percent number Published pneumonia or VAP percent
mortality_percent number Published mortality percent
rib_count integer Caller rib-level count used
chest_tube boolean Caller chest-tube flag used
pulmonary_contusions boolean Caller pulmonary-contusion flag used
copd boolean Caller COPD flag used
gcs integer Caller GCS total used
gcs_lt_15 boolean true when caller GCS is 3–14
components array Per-predictor Buchholz 2023 points
citation object Buchholz 2023 Am Surg citation
disclaimer string Not-a-device notice

Example JSON

Machine form of the same example. Frozen fixture. Not a live lookup.

{
  "components": [
    {
      "value": 1,
      "factor": "rib_count",
      "points": 2.275,
      "present": true
    },
    {
      "factor": "chest_tube",
      "points": 0.0,
      "present": false
    },
    {
      "factor": "pulmonary_contusions",
      "points": 0.0,
      "present": false
    },
    {
      "factor": "copd",
      "points": 0.0,
      "present": false
    },
    {
      "value": 15,
      "factor": "gcs",
      "points": 0.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": "Buchholz CJ, Jia L, Manea C, Petersen T, Wang H, Stright A, Young JS, Calland JF",
    "doi": "10.1177/00031348221123087",
    "id": "buchholz-2022",
    "pmid": "36120831",
    "source": "Am Surg. 2023;89(10):4668-4674",
    "title": "Revised Intensity Battle Score (RIBS): Development of a Clinical Score for Predicting Poor Outcomes After Rib Fractures"
  },
  "formula": "ribs",
  "formula_expression": "RIBS = round(2.275*rib_count + 1.525*pulmonary_contusions + 2.83*copd + 4.08*chest_tube + 8.137*(gcs<15)); Buchholz 2023; rib level not fracture count; age is not a component; ICU triage cutoff 12; not Chapman 2016 RibScore; not Battle 2014 STUMBL",
  "score": 2,
  "mortality_percent": 2.8,
  "gcs": 15,
  "copd": false,
  "any_complication_percent": 7.5,
  "chest_tube": false,
  "gcs_lt_15": false,
  "icu_triage_cutoff": false,
  "pneumonia_or_vap_percent": 3.0,
  "pulmonary_contusions": false,
  "rib_count": 1,
  "ribs_band": "below_12",
  "unplanned_icu_or_intubation_percent": 4.7,
  "vent_or_tracheostomy_percent": 1.9
}

Client errors (HTTP 400)

Invalid params return 400 without charge. Shared HTTP 402 and 503 meanings: Payments.

HTTP Code When
400 invalid_rib_count rib_count must be an integer from 0 through 24 (Battle 2014 STUMBL Table 4). Returned before settlement; you are not charged.
400 invalid_gcs_total gcs must be an integer from 3 to 15. Returned before settlement; you are not charged.
400 invalid_flag boolean clinical flags must be true or false Returned before settlement; you are not charged.
400 invalid_items POST body must be a JSON object with only an items array Returned before settlement; you are not charged.
400 invalid_item_count items must be an array of 1 to 25 objects Returned before settlement; you are not charged.
400 invalid_item each items entry must be a JSON object Returned before settlement; you are not charged.

Related tools

  • RibScore — Sum the six Chapman 2016 RibScore radiographic flags and return the integer total 0-6. That paper associated the score linearly with pneumonia, respiratory failure, and tracheostomy.
  • ISS — Compute the Baker 1974 Injury Severity Score as the sum of squares of the three highest caller-assigned AIS body-region grades, or 75 if any region is AIS 6.

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. Unpaid valid requests return HTTP 402 with a base64 PAYMENT-REQUIRED header. HTTP 503 is not a new quote: retry the same PAYMENT-SIGNATURE. Full handshake and shared payment errors: Payments. Stdio MCP: /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.