Pool chemical doses from a water test
plan_pool_chemical_dosesHow much pool chemical to add after a water test: liquid chlorine, bleach, cal-hypo, dichlor or trichlor to raise free chlorine (FC); muriatic acid or dry acid to lower pH; soda ash or borax to raise pH; baking soda to raise total alkalinity (TA); calcium chloride for calcium hardness (CH); stabilizer for cyanuric acid (CYA); and salt for a salt water chlorine generator (SWG). Doses come in the order to add them, each worked out on the water the one before it leaves (baking soda nudges pH up, acid lowers TA), for the strength on the user's own label. ppm × litres ÷ 1000 = grams of pure chemical; pH doses from a carbonate model that counts TA, CYA and borates; chlorine targets from TFP's FC/CYA chart (or pool-store levels); CSI and LSI before and after. Checked against TFP Pool Math.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"pool_volume": "<pool_volume>"
},
"name": "plan_pool_chemical_doses"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| ph | No | ||
| salt | No | ppm, salt water pools | |
| slam | No | SLAM (shock) mode: chlorine to TFP's SLAM level for the CYA | |
| units | No | us: gallons, °F, fl oz and oz; metric: litres, °C, mL and g | us |
| borates | No | ppm as boron | |
| surface | No | plaster | |
| approach | No | tfp: Trouble Free Pool levels, chlorine tied to CYA; store: pool-store / health-code levels, FC 1.5–3 ppm at any CYA | tfp |
| products | No | The user's own products, one per job; any job not listed uses liquid chlorine 10 %, muriatic acid 31.45 %, borax, baking soda, calcium chloride 77 % flake, granular stabilizer, pool salt | |
| sanitizer | No | liquid: liquid chlorine or bleach; swg: salt water chlorine generator; tablets: trichlor | liquid |
| target_ch | No | Default 350 plaster (store 300), 0 vinyl (never dosed) | |
| target_fc | No | Empty = top of the FC/CYA chart range (bottom for SWG) | |
| target_ph | No | Default 7.5 | |
| target_ta | No | Default 70 (store 100) | |
| target_cya | No | Default 40, salt pool 70 | |
| pool_volume | Yes | Pool volume in US gallons (units=us) or litres (units=metric) | |
| target_salt | No | Default 3,200 ppm | |
| cyanuric_acid | No | CYA (stabilizer, conditioner), ppm | |
| free_chlorine | No | FC, ppm | |
| calcium_hardness | No | CH, ppm | |
| total_alkalinity | No | TA, ppm | |
| combined_chlorine | No | CC, ppm | |
| water_temperature | No | °F (units=us) or °C (metric); 80 °F when not given | |
| fill_water_calcium | No | CH of the fill water, ppm, for the drain-and-refill share | |
| chlorine_stored_hot | No | Jug kept somewhere hot (about 35 °C / 95 °F) | |
| liquid_chlorine_age_days | No | Days since the liquid chlorine jug was bought |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| more | Yes | ||
| doses | Yes | In the order to add them, each worked out on the water the one before it leaves | |
| units | Yes | ||
| advice | Yes | ||
| levels | Yes | Each reading against the chosen standard: very_low, low, ok, high, very_high | |
| method | Yes | ||
| safety | Yes | ||
| csi_now | Yes | ||
| lsi_now | Yes | ||
| csi_after | Yes | ||
| lsi_after | Yes | ||
| pool_litres | Yes | ||
| cya_used_ppm | Yes | ||
| pool_gallons | Yes | ||
| fc_target_ppm | Yes | ||
| free_chlorine_levels | Yes |