Data Visualization with an Agent · Challenge 04 · 中文版

Challenge 04: Numbers match the charts

Checkpoint l0410 ptsgated by test suiteAny coding agent + matplotlib

summary.json is checked against ground truth; a chart disagreeing with the JSON is a failed chart.

Doing this with your agent? One sentence starts the whole course:

Read https://flypython.com/skills/flypython/SKILL.md and start the FlyPython course `da-visualization`.

Challenge 04: Numbers match the charts

Gate: objective — both suites · Points: 10

The suite verifies summary.json against the dataset’s ground truth (East 12334.94, North 14294.7, South 11200.48, grand total 37830.12, 45 days). A chart that shows different numbers than the JSON is a failed chart — the JSON is the auditable layer.

python verify.py starter --expect-failure must now exit nonzero; python verify.py solution must be green.

Checkpoint: both gates pass. Objective claim code via python verify.py.

Hints

Stuck? Open one at a time.

Hint 1 — What this checkpoint tests

Both suites: summary.json against ground truth — East 12334.94, North 14294.7, South 11200.48, grand 37830.12, 45 days.

Hint 2 — JSON is the audit layer

A chart showing numbers that differ from the JSON is a failed chart — if the PNG and JSON disagree, the JSON loses the argument only when the PNG is right, which it almost never is.

Hint 3 — When you are done

Every figure in summary.json matches the dataset's truth and you can trace each to its aggregation.

Submit

Done? Record it.

The 8-character code verify.py progress printed for this checkpoint — from the browser, or straight from your agent.

Youbrowser

Submit the claim code

Your agentauto-submit

Let the agent solve and submit

Hand it this checkpoint (copy button on hover) — it solves, verifies, and submits on its own:

Work on the FlyPython challenge "Data Visualization with an Agent" (course id course-da-visualization), checkpoint l04.
Machine-readable brief: https://flypython.com/api/challenges/da-visualization
Open the course folder and read TASK.md first — it is the contract.
Rules: smallest change, no new dependencies, never edit tests/ or solution/.
Check with python verify.py until its gates pass, then report each claim code to me.
Target: solve only checkpoint l04, and submit it as soon as it passes.

With a token from your agent page (env FLYPYTHON_TOKEN), it records the result directly:

curl -X POST https://flypython.com/api/claims \
  -H "Authorization: Bearer $FLYPYTHON_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"claims":[{"course":"da-visualization","checkpoint":"l04","code":"<8-char code>"}]}'

Or install the full FlyPython agent skill once and skip the paste.

Files

The starter and verifier

Solving runs on your machine — your agent fetches the course files itself via /api/challenges/da-visualization/files; you download nothing by hand. Prefer reading the source? Browse the folder on GitHub ↗