跳转到主要内容

WRITING

I Built My Kid His Own Market Dashboard, and He Checks It Every Day to See How Much He's Up

August 9, 202611 min read曾田力
EducationEngineering PracticeProduct
I Built My Kid His Own Market Dashboard, and He Checks It Every Day to See How Much He's Up

The problem with stickers and gold stars isn't that they don't work, it's that they don't add up.

By the seventeenth one, nobody remembers what the first one was for, and nobody remembers whether last week was up or down. The kid can't see himself getting better. All he sees is whether he got one today.

So I turned it into a ledger — every point earned or docked has a reason, a timestamp, and the balance at that moment, with that accumulated total sitting right at the top, like watching a ticker.

Now he opens it himself every day when he gets home to see how much he's up.

1. This Is What Opens Up

Points home screen: total market cap, today's change, 30-day trend, contribution broken out by subject

That big number at the top is his total points. Next to it: how much he gained today, what percent that is, what it converts to in money, plus an "all-time high" marker — it lights up when he beats his own record.

Below that is the thirty-day trend. This line is where the whole thing actually earns its keep: getting 10 points today doesn't feel like much on its own, but seeing the line climb from the start of the month to now feels completely different.

Further down it breaks out by subject. Whichever column stays short, he can see it himself. I don't have to say it.

2. How One Award Actually Goes Through

Points aren't handed out on a whim. They're handed out off a table.

We already had a "Points Rulebook" at home, an Excel sheet — Chinese, math, English, science, PE, trumpet, ethics, chores, all the way down to "Dad's Special Award," with awards and deductions listed side by side. I moved that whole sheet into the system — 83 rules, not one changed, not one left out.

The parent panel while locked: you need a password to award points

Open "award him points" and the first thing you see is a lock. You can read the rules, you just can't award anything — the parent password comes first.

The rule wall once unlocked: grouped by subject, awards and deductions side by side

Once unlocked, the whole wall spreads out, one button per rule, one tap and it's recorded. Those little tags on the buttons say how that rule is computed:

TagWhat it meansExample
(none)Fixed points, one tap and it's recordedA perfect dictation +10
by countYou enter a number, it's scored per unitDictation mistakes −1 each
you pickThe sheet gives a range, you pick inside itReciting poems and classical prose 10~50
compute itThere are tiers, fill it in and it computesJump rope · sit-ups · exams
for TV timeWhat you earn isn't points, it's TV timeLearning new characters +1 minute per 2 characters

The "compute it" kind is the most telling. The original sheet lists seven tiers for jump rope, with a note at the end: "does not stack."

Jump rope calculator: enter 3 sets, 190 per minute, the server computes +120

Enter "3 sets, 190 per minute" and it computes +120 points on its own, and tells you why it's 120 — the tier it hit was "3 sets, 190 or more."

No flipping through the sheet, and no mixing up the 180 tier with the 190 tier. Do this by hand and sooner or later you mix it up once; mix it up once and the kid learns the rules are negotiable.

3. What It Guards Against

A points system where you can award yourself points turns into a point-farming game by day two. So these are hard:

What will happenHow it's handled
Kid gets hold of an already-logged-in tablet and awards himself pointsAwarding needs the parent password, and it's typed in every single time. However long he stays logged in on his side, he can't award himself a single point
He's short on points but wants to redeem anywayHe can't. The card says "N points short"
Farming unlimited points by grinding practice questionsPoints from practice are capped at 30 a day, and the cap lives on the server — whatever the front end reports doesn't count
Submitting a set without answering a single questionNo points
Recorded it wrong, tapped the wrong thingEvery entry has an "undo" behind it. Undo records a reversing entry; the original stays on the books and isn't deleted
Deductions pushing the balance negativeAllowed. He owes it and earns it back next time — that's how the deduction clauses in the sheet were written in the first place

That last one deserves a note: this ledger doesn't delete records. Undo isn't an erase, it's a reversal. Look back six months later and every time something was recorded wrong, every time it was corrected, it's all still there.

A ledger that can be quietly edited is worse than no ledger.

4. The One That's Almost Within Reach Stays in Front of Him

Redemption shop: 12 items, the affordable ones lit up, the unaffordable ones showing how much is missing

There are 12 things in the shop, from "one extra episode of a cartoon" at 150 points to "a short trip" at 20000 points. The affordable ones are lit, the unaffordable ones are grayed — but the grayed ones say how many points are still missing.

I set up this particular state on purpose for the screenshot, because it's the single most effective screen in the whole thing:

"Grant one wish," 1500 points, 60 points short.

What does 60 points look like? A perfect dictation is +10, washing all the family's dishes is +10, a half-hour morning run is +20. A few more things today and he's there.

That works far better than "keep it up." "Almost there" is something you can compute. "Keep it up" isn't.

5. Every Point Can Be Traced Back

The full ledger: time, reason, points, balance at that moment, every entry reversible

This is the screen I care about most.

Every entry has a time, a reason, and the balance at that moment. Not "you have 1440 points," but "August 8, Dad's Special Award +300, balance went from 1080 to 1380."

That balance column isn't a number stored off to the side. It's summed up from the entries, one at a time. So the ledger and the balance can never disagree.

Up top you can also filter to "awards only" or "spending only." Where did the money go this month — one tap and there it is.

6. What's There Right Now

First, the scope: what's counted below is entries in the rule table and the shop, not the mechanics built into the system (practice points, the daily cap, undo — those don't count as rules), and not the question bank over on the practice platform.

ItemCountNotes
Rules83All from that sheet at home, moved over one by one
Subjects covered9Chinese 28 · math 13 · chores 10 · English 9 · PE 8 · ethics 7 · trumpet 4 · daily life 3 · Dad's Special Award 1
Of which, deduction clauses23Awards and deductions side by side, not just good news
Rule forms5Fixed points 49 · parent-picked range 17 · by count 9 · tier calculator 5 · TV time 3
Tier calculators5Jump rope · sit-ups · Chinese exams · improvement over last time · essay length
Shop items12150 points to 20000 points
Currencies3Points · TV time · wishes, all on the same timeline
Exchange rate100 points = 1 yuanThe sheet originally said 10 points for 1 yuan; going by the point values in the sheet, a month comes out to about 1700 points, which at ten-to-one is 170 yuan a month — pocket money for a third grader, I judged that too high and cut it by a factor of ten

Still empty: the "science" column in the rule table has zero rules — that sheet at home never had any. That card on the home screen will keep showing 0 until it's filled in. I'm not making up rules for the empty spots; rules you make up don't get followed.

7. If You Want One

This thing was built for my own family, running on my own server, with no open registration, and I'm not posting the address in this post — what's inside is one specific kid's ledger, his mistakes, and his exam papers.

If you want one, tell me and I can help you set up your own: your family's own rule table, your own ledger, with the data in your own hands. The rule table can look like anything; mine was moved over line by line from the Excel sheet we already had at home.

8. A Section for Fellow Engineers

Zero third-party dependencies. The server is an HTTP service written with the Python standard library, and it serves both the static files and the API, with the data in a single JSON ledger file. The whole thing doesn't have a single pip install.

A few constraints I think are worth mentioning:

  • The login gate is in the application layer, not in nginx. With auth_request, the login gate can't be tested locally at all, which amounts to no gate. As it stands, you spin up a local copy and it runs the same path — you're testing the actual gate.
  • The parent password doesn't set a cookie. That's on purpose — if it did, the kid could award himself points the moment he got hold of an already-logged-in tablet.
  • Point values are always computed on the server, and the page preview and the actual recording go through the same function. If the two sides each compute their own, sooner or later they compute different numbers — and the parent is looking at the preview while the kid gets the recorded entry.
  • Tier expressions are evaluated against an ast allowlist, never with eval. The expressions come from a config file, and eval amounts to handing over arbitrary code execution.
  • The ledger is append-only, and the balance is always accumulated from the entries. Store a separate balance field and it will drift from the entries.
  • Every point value has to be traceable to a spot in the original sheet. For anything the sheet didn't give (say "other discretionary awards," which has no number), the rule has to be marked "this value is ours" — there's a machine gate watching for it, and if you can't point to a source, it goes red. That one was bought with the lesson from the previous post.

About these screenshots

They're all real pages with real operations, captured live, not drawn mockups: a real server started, a real login, a real tap on unlock, real taps on the rule buttons — one command reruns all of it. Before a screenshot is taken it also has to pass three gates — whether the things that should be there are there, whether the page is blank (a blank page screenshots just fine, so you have to check the pixels), and blurring out third-party real names before anything goes public.

The ledger in the pictures is fabricated demo data; not a byte of the real ledger came in: the server runs in a temp directory and is gone when it's done, and the rule numbers and shop items are pulled live from the product's own config — if they can't be pulled, it errors out and exits rather than making them up.

In the first version I made up 8 nonexistent rule numbers in the demo script, and that check caught it on the spot — right after writing the previous post about the lesson on making up numbers, I turned around and did it again. Which is probably exactly why that check has to be written into the code and not into the docs.

FOLLOW

New posts land here first. Subscribe via RSS: /feed.xml

AUTHOR

Tianli Zeng

Hydraulic engineer. I write about AI methodology, daily investment reviews, and engineering practice.

Found a mistake, or have something to add?