- Status
- Draft
- Kata ID
- AGR-001
- Maintainer
- Agriculture pathway maintainer
- Last verified
- Not available. Built and checked by the Dojo maintainers and CI; no independent, agronomic or engineering review yet.
- Found a problem?
- Report it
The outcome
An inspection record of the weather file, with every claim traced to a column, row or flag.
For: Learners who have done the foundations and want to treat weather data as evidence rather than as a chart.
Done when
- You name the station, its coordinates and elevation, and the first and last date
- You count the days expected and present, and list any missing dates as unavailable, never as zero
- For each element you give the unit, the count, the range and every flag with its count
- Your counts match /examples/agriculture-pathway/generated/inspection.json
You make: Weather inspection. Outcome: Inspect weather record.
Showcase and provenance
The Dojo’s worked example, made by the maintainers rather than by a learner: one year of NOAA daily weather for a California station, FAO-56 reference evapotranspiration and a maize irrigation estimate, every number computed by the site’s CI.
- Made by
- NOAA National Centers for Environmental Information (weather record); Developer Dojo maintainers (script and results)
- Source
- NOAA GHCN-Daily station USW00093193, 2023; method from FAO Irrigation and Drainage Paper 56; results from /examples/agriculture-pathway/tools/agri_pathway.py
- Licence
- Weather record is a US government work (no US copyright, 17 U.S.C. 105); script and outputs MIT
- Date
Brief, inputs and constraints
Inputs
- noaa-ghcnd-USW00093193-2023.csv. Source: noaa/ghcn-daily (copy on /examples/agriculture-pathway/inputs/). Terms: US government work from NOAA NCEI; cite the dataset as NCEI asks.
Constraints
- No paid tools
- Offline capable
- No personal data
Capabilities practised
- Analyze data
- Verify evidence
Stack, permissions and cost
| Part | Component | Version | Permissions | Cost |
|---|---|---|---|---|
| Runtime | Python, standard library only | 3.12 | Reads the files you give it and writes only the output folder you name | Free |
| Tool | Any spreadsheet | Not available. Not fixed; any spreadsheet that opens CSV works | Opens a copy of the CSV files | Not available. Depends on the spreadsheet you use; free ones work |
| Data | NOAA GHCN-Daily record, station USW00093193 | 2023, SHA-256 abde4990…b3b9a7 | Read a copy | Free (US government work) |
| Harness | Any chat assistant or coding agent | Not available. Not fixed; an assistant may explain an equation or draft code, and every number it gives is checked against FAO's worked examples | Reads what you paste in; give it a copy of the record only | Not available. Depends on your assistant and plan; not measured |
Stack recipes
- Python standard library
Why this stack
The standard library is enough for these equations, runs offline with nothing to install, and gives the same numbers on every machine. CI runs the identical script on every pipeline.
Alternatives
- A ready-made evapotranspiration package or FAO's ETo Calculator. Faster, but hides the equations this pathway is about. Not tried for this pathway, so its numbers are not compared here. Not tested for this recipe.
Agents and review gates
Explaining assistant
Explains a GHCN-Daily column or flag you paste in, and drafts the Python to count it.
Review gate: You check the explanation against NOAA's documentation and run the code on the file.
Learner as reviewer
Compares the record with the file and with the Dojo's CI output.
Depends on: Explaining assistant
Review gate: A claim stays only if it cites a column, row or flag.
Setup and smoke test
- Install Python 3.12 or later. Nothing else is needed.
- Download the record and the pathway script from /katas/agriculture-pathway into a new, empty folder. Work on copies; keep the original.
Sign-in and access: None. Nothing here needs an account.
Smoke test
- Do
- Run: python3 -I tools/agri_pathway.py . out (from the folder that holds inputs/ and tools/)
- Expect
- 13 reference checks pass and out/inspection.json reports 365 rows
- Result
- Passed /examples/agriculture-pathway/generated/inspection.json, recomputed by CI on every pipeline
Prompts
Copy a prompt into the assistant you use. Replace anything that does not fit your situation, and never paste private or personal data you are not allowed to share.
Explain the flags
Learn what each attribute on a GHCN-Daily value means, without trusting the explanation blindly.
Practice exercise
Global Historical Climatology Network - Daily (GHCN-Daily). From Global Historical Climatology Network - Daily (GHCN-Daily) (NOAA National Centers for Environmental Information).
Terms: US government work from NOAA NCEI; NCEI asks for a citation and gives no warranty.
Execution and handoffs
- Learner: Open the CSV in a text editor or spreadsheet and find the station columns, the dates and the attribute columns.
- Explaining assistant: Drafts a script that counts values, gaps and flags per element. Hand-off: You run it and compare the output with the file.
- Learner: Write the inspection record and compare it with the CI output.
Tests, failures and corrections
| Check | Expected | Result | Evidence |
|---|---|---|---|
| Inspect the record with the pathway script | Station USW00093193, 2023-01-01 to 2023-12-31, 365 rows, no missing dates, no missing values, no quality flags, 23 rain values flagged T (trace), rain total 346.6 mm | Passed on | /examples/agriculture-pathway/generated/inspection.json, recomputed by CI on every pipeline |
| Your own inspection record matches the CI output | Same station, dates, counts, ranges and flags | Not run | Not run, so there is no evidence. This is not a pass. |
Failures and corrections
- Observed: A trace of rain is recorded as 0 mm Correction: That is how NOAA records it; the T flag says some rain fell but too little to measure. Count trace days separately; do not treat them as missing.
Adapt it
- Use another station or year Expect gaps and quality flags. Report each gap as unavailable and decide, before computing, how a result handles it.
Unseen Randori
See the agriculture Randori recipe, AGR-R01.
Constraints
- Every claim cites the file
How it is judged: The record matches the CI output for the same file.
Belt evidence
Belt stages are proposed practice stages, not issued credentials. Evidence below is what a reviewer would look for; it is not a record that anyone has shown it.
Evidence a reviewer looks for
- An inspection record (station, dates, units, missing values and flags per element) that matches the Dojo's CI output for the same file (Automated check)
- Each claim in the record points to a column, row or flag in the CSV (Self-check)
Belt criteria
- Practice: Reproduces the inspection for the record and explains what the trace flag T means for rain totals
- Adapt: Downloads another GHCN-Daily station-year and inspects it the same way, recording any gaps as unavailable
- Demonstrate: Explains to a reviewer which uses the record supports and which it does not, citing NOAA's own limits
Connections
- Used by
- No other kata names this one as a foundation yet.
- Transfers to
- Professional review
- Required. Any real use of this outcome needs independent validation and any approval required from a qualified professional. Practice here does not grant a licence.
Sources
NOAA National Centers for Environmental Information
Global Historical Climatology Network - Daily (GHCN-Daily) (opens the publisher's site in a new tab)
- Free
- Docs
- Intermediate
NOAA's archive of daily station weather: maximum and minimum temperature, rain and more, with measurement, quality and source flags for every value. Not homogenized, so check a station's record before you trust a trend from it.
Food and Agriculture Organization of the United Nations
Crop evapotranspiration (FAO Irrigation and Drainage Paper 56) (opens the publisher's site in a new tab)
- Free
- Book
- Advanced
The reference method for reference evapotranspiration (FAO Penman-Monteith), how to estimate missing humidity, radiation and wind, and crop coefficients by growth stage, with worked examples you can reproduce.
Food and Agriculture Organization of the United Nations
Irrigation Water Management: Irrigation Water Needs (Training Manual No. 3) (opens the publisher's site in a new tab)
- Free
- Book
- Beginner
FAO's introductory chapter on irrigation water needs: effective rainfall with two simple monthly formulas, and the irrigation need as crop water need minus effective rainfall, with a worked question and answer.
Maintenance and caveats
Review cadence: Every six months, or when NOAA changes the GHCN-Daily format or terms
- This recipe is a draft: the example was built and checked by the Dojo maintainers and CI, and no learner has run it yet.
- Nothing here is an irrigation recommendation. No agronomist, irrigation engineer or water authority has reviewed it, and real water use needs the qualified people and local rules that apply to it.
- Humidity, radiation and wind are estimated from temperature, as FAO-56 describes for missing data. The results are estimates, not measurements.
- NOAA says GHCN-Daily is not homogenized. One station and one year say nothing about a trend.



