Chart
A Pareto chart from a list, 80/20 drawn for you
A Pareto chart answers which few causes explain most of the effect? In Chiltepin it is a chart block with kind: pareto and a list of items. The renderer sorts, accumulates and marks the 80% rule; the numbers stay in the document where a reviewer can read them.
The block and its render
Six causes with their counts, in any order. Everything else on the chart — the sort, the cumulative line, the rule — is derived.
```chart
title: Checkout failures by cause, last 30 days
kind: pareto
unit: failures
items:
- { label: Card declined, value: 412 }
- { label: Address mismatch, value: 168 }
- { label: 3-DS timeout, value: 91 }
- { label: Inventory race, value: 44 }
- { label: Coupon invalid, value: 23 }
- { label: Other, value: 17 }
```How to make one
- Install the skill. Run npx skills add jdiejim/chiltepin -g once. The Chiltepin authoring skill lands in Claude Code, Cursor, Codex, Copilot and 70+ other agents.
- Ask for the chart. "Add a Pareto chart of checkout failures by cause to docs/incidents/checkout.md from the export in data/failures.csv." The agent runs chiltepin block chart, reads the data, and writes kind: pareto with one item per cause.
- Check it. npx chiltepin check reports a missing value, an unknown kind or an unknown field with a stable code and the fix. The agent repairs it before handing off.
- Render it. npx chiltepin html docs/incidents/checkout.md -p renders the page. The renderer sorts the bars, draws the cumulative line and marks the 80% rule — never the model.
The same block, fifteen other kinds
histogram bins raw values; bell draws a normal curve from mean and sd with markers z-scored onto it; boxplot takes quartiles and outliers per box; bullet compares a value to a target inside ranges. Bar, stacked, line, area, scatter, donut, pie, gauge, radar, waterfall and funnel are the same block. For latency tails the percentiles block puts p50 to p99 per endpoint on one axis against the SLO, and perfbudget compares measured values to budgets. All of them are in the charts reference and the catalog.
Part of the analysis
A Pareto chart opens a root-cause doc; a fishbone of the top cause, an audit of what the review found and a roadmap of the fixes follow. Chiltepin renders the whole document — a growing set of typed blocks, one grammar — to a static site, slides or PDF. Paste a block into the playground to see it render now.
Frequently asked questions
- What is a Pareto chart?
- A Pareto chart is a bar chart of causes sorted from most to least frequent, with a line on a second axis showing the cumulative share. It makes the 80/20 rule visible: the few causes on the left that account for most of the effect. It is the standard first chart in a root-cause or defect analysis.
- How do I make a Pareto chart in Chiltepin?
- Write a chart block with kind: pareto and a list of items, each a label and a value. The renderer sorts the bars, draws the cumulative line, and marks the 80% rule; you never touch an axis. It is the same chart block as bar, line, area, scatter, donut, pie, gauge, radar, waterfall, funnel, histogram, bell, boxplot and bullet — one grammar, sixteen kinds.
- Can an AI agent build the chart from my data?
- Yes. After npx skills add jdiejim/chiltepin -g the agent knows the block, runs chiltepin block chart for the contract, and writes the items from the incident export or the CSV you point it at. chiltepin sync csv turns a CSV into a chart block directly. Either way the numbers are data in the file, reviewable in a diff.
- Which other statistical charts are there?
- histogram bins raw values; bell draws a normal curve with sigma bands and z-scored markers; boxplot shows quartiles and outliers per group; bullet compares a value to a target inside ranges. For latency, the percentiles block draws p50 to p99 and max per endpoint against the SLO on one axis, and perfbudget compares measured values to budgets.
- Why a typed block instead of a spreadsheet chart image?
- A pasted chart image cannot be edited, diffed or checked; the numbers behind it are gone. A chart block keeps the data in the document, so a reviewer sees the values, a change is a one-line diff, chiltepin check rejects a malformed item, and the chart re-renders identically every build.