Skip to content

PaedScale

PaedScale — a starting pediatric dose from adult pharmacokinetics, with a cited rationale Most drugs are never trialed in children, so when a kid needs one that has no pediatric label, clinicians extrapolate the dose by

Core trick

Python computes weight^0.75 allometric scaling times an organ-maturation factor for the drug's elimination pathway, while Claude selects that pathway and cites PubMed and openFDA sources.

Tags

Description

PaedScale — a starting pediatric dose from adult pharmacokinetics, with a cited rationale Most drugs are never trialed in children, so when a kid needs one that has no pediatric label, clinicians extrapolate the dose by hand, usually by scaling the adult dose down by body weight. The problem is that a young child's liver and kidneys aren't finished maturing, so they clear drugs more slowly than their weight suggests. Scale linearly, and you overdose the child. That gap between "weight-proportional" and "what the body actually does" is where many pediatric medication errors occur. I built PaedScale to close that gap in a defensible way. You give it a drug, the child's weight, and their age, and it returns a starting-dose estimate built on the Anderson–Holford model: allometric scaling (weight^0.75) multiplied by an organ-maturation curve for whichever pathway actually eliminates that drug (a specific CYP enzyme, renal filtration, glucuronidation, etc.). The split I cared about was keeping the math and the judgment separate — Python does the pharmacokinetic arithmetic deterministically, and Claude does the part a calculator can't: figuring out which elimination pathway a given drug maps to, pulling the adult PK numbers live from PubMed and openFDA, checking the result against real dosing guidelines, and writing out the reasoning. It's a multi-agent setup — an orchestrator agent driving a cheaper retrieval subagent — and the same retrieval tools are exposed over MCP. The rule I held to throughout is cite-or-abstain. Every number that drives the estimate has to trace back to a source; if the data can't be retrieved, the engine refuses to invent a maturation curve, and the whole result drops to a "grade D — insufficient data" instead of producing a confident-looking guess. Each answer is graded A–D by evidence strength, with a guideline concordance ratio and flags for clinically important factors (narrow therapeutic index drugs that require blood-level monitoring, active metabolites, oral bioavailability gaps). What I found building it: the approach genuinely works for drugs whose pediatric dosing is really about matching adult exposure — I validated it across ~20 drugs (midazolam, vancomycin, morphine, the aminoglycosides, several others), and the estimates landed within guideline range for the ones with a guideline to check against. Just as useful was learning where it breaks. Concentration-dependent aminoglycosides get underdosed by the exposure-matching math, so the agent has to guideline-anchor and flag that mismatch rather than trust its own number. And some drugs (digoxin, acetaminophen) are empirically de-linked from adult PK altogether, so I deliberately excluded them — forcing a single-pathway extrapolation there would just produce a confident wrong answer, which is exactly the failure mode this project exists to avoid. Why it matters: This isn't meant to replace a prescriber, and I've been careful to frame it as decision support, not prescribing. But the honest reality is that a neonatologist facing an off-label drug at 3 am is doing this extrapolation by hand from sparse references anyway. PaedScale gives them a starting point that's transparent about its own uncertainty — you can see the pathway it assumed, the sources it used, and how far it sits from the nearest guideline — instead of a black-box number. In a domain where the tolerance for a silent error is basically zero, making the reasoning auditable is the whole point. Live at paedscale.by-dhruvik.in.
heyiamnotacoder/paedscale★ 21 forksPythonMITCreated Jul 11, 2026 · last push Oct 5, 2026

README excerpt

![PaedScale](docs/banner.png)

# PaedScale

[![Live demo](https://img.shields.io/badge/live-paedscale.by--dhruvik.in-0E7A6B?logo=safari&logoColor=white)](https://paedscale.by-dhruvik.in)
![Claude Life Sciences Hackathon 2026](https://img.shields.io/badge/Claude%20Life%20Sciences-Hackathon%202026-0E7A6B)
![License: MIT](https://img.shields.io/badge/license-MIT-1a6ee0)
![Python 3.11+](https://img.shields.io/badge/python-3.11%2B-3776AB)
![FastAPI](https://img.shields.io/badge/FastAPI-async-009688)
![Decision support](https://img.shields.io/badge/status-decision%20support-B9760A)

### A pediatric dose, extrapolated from adult pharmacokinetics — with a cited, graded, auditable rationale.

> 🔗 **Live at [paedscale.by-dhruvik.in](https://paedscale.by-dhruvik.in)** — built at the **2026 Claude: Life Sciences Hackathon**.

PaedScale derives a defensible **starting** dose for a child from published adult PK, using
**allometry × organ maturation** (Anderson–Holford), and returns a graded A→D recommendation with the
reasoning, the guideline concordance, and every uncertainty made explicit — not a black-box number.

> **Medication errors harm an estimated 1.5 million people a year in the United States alone**, and
> children are disproportionately exposed — because nearly every pediatric dose is a weight-based
> calculation done by hand, for a body whose organs are still maturing.
> <br><sub>Sources: Institute of Medicine, *Preventing Medication Errors* (2006); Kaushal et al., *JAMA* 2001

Team