It has never been told what a circle is.
One rule decides every dot on this page. A coordinate is inside if it is no further from the centre than the radius, and the radius is half the side of the square โ so the circle's diameter is the side of the square and the circle touches all four edges. Nobody draws that circle here. The learner is shown two numbers, says inside or outside, and is told whether it was right.
What appears on the stage is its own conclusion: a boundary computed from 97 numbers, which starts as a wobble and arrives at the shape of the rule. It was never given the distance from the centre, and it has never seen a picture of the answer.
three.js for the stage ยท one hidden layer and 97 numbers, in plain TypeScript with no library for the learning ยท trained in your own tab and gone when you close it ยท no server, no account, no keys, nothing uploaded.
Watch it guess
This page draws its stage with WebGL through three.js, and this browser would not start it. Nothing else on the page needs it โ the numbers below are real either way.
ReadingBlue is a right guess and red is a wrong one, and each dot is coloured by the answer the network gave before it was told anything. The green wash is where it currently believes the inside is; the bright line is where that belief crosses a half. That line is computed from the network's own numbers โ nothing here drew a circle for it to copy โ which is why it is a wobble at the start and the rule's shape later. The square is drawn because the rule is about a square; the circle is not, because finding it is the whole job.
It is not allowed to settle for nearly right. Every coordinate it gets wrong is kept, and the next steps push back on those hardest, so the effort goes where its boundary is still in the wrong place. The run is working towards the only answer that counts as finished here: a hundred out of the last hundred. Confidence is a different number and it is the one on the left of it โ how sure the network is of itself, on average, where a half is a coin. It climbs towards a hundred and stops a little under it, because a coordinate sitting exactly on the boundary is one it is right to be unsure about. Being certain is not the same as being right, and only the second one is the target.
What it can see, and what it is
Both lists are printed, because "it learned" means very little unless you can say what it was allowed to look at and what it was made of.
- What it can see: two numbers โ x and y, both between minus one and one. Not the distance from the centre. Not the squares. Not the radius. Give it the distance and the job collapses into one subtraction, which is why it is not given it.
- What it is: twenty-four units that each bend the plane along one straight line, and a single output that adds them up. Ninety-seven numbers in total. One straight line cannot enclose anything, which is the entire reason the hidden layer exists โ and it is measured, not asserted, in the list below.
- How it learns: after each guess it is told the rule's answer, and then it takes sixteen small steps drawn at random from the last five hundred coordinates it has seen. It learns from its own recent history rather than from the newest coordinate alone, because learning from the newest alone forgets.
- The honest limits of the model: it is not learning the rule, it is approximating it โ near the boundary it is genuinely unsure, and that is where the red dots are. The network has no memory of any individual coordinate beyond the five hundred in the ring, and nothing is stored anywhere; closing the tab throws the whole thing away.
The honest bits
Ten things this project found by measuring rather than by assuming. Every number here comes out of the run described in the repository, on five seeds, and every one of them is a number that disagreed with a belief first.
- A straight line is worth exactly nothing here. Trained to convergence with the same optimiser, the best straight line reaches 78.44%. Answering "inside" to everything reaches 78.54%, because that is the fraction of the square the circle covers. So a line lands a hair below the score of knowing nothing โ which is the whole argument for a hidden layer, in one number.
- It starts below knowing nothing. An untrained network scores 61.42% on coordinates it has never seen โ and depending on the seed, anywhere from 35.50% to 78.48%. The first thing this page shows is a learner doing worse than a machine that always says yes.
- Remembering beats learning from the newest coordinate alone, by six points. Learning from the newest coordinate only reaches 92.83% after four thousand coordinates. Remembering five hundred of them and taking sixteen steps from a sample of them reaches 99.06%. Same network, same learning rate, same coordinates โ the only difference is whether it remembers.
- Working on its own mistakes is worth more than everything above it. Treating every coordinate alike reaches 98.24%. Sending 65% of each step at the coordinates it has just got wrong reaches 99.35% โ and the boundary moves from radius 1.0067 with a 12.99% spread to radius 1.0008 with 5.26%. The effort goes where the boundary is still in the wrong place, which is the one thing that cannot be done by treating every coordinate as equally interesting.
- A step size that shrinks is what makes it settle. At twenty thousand coordinates a fixed step is still taking full-size strides: the boundary sits at radius 1.0022 with a 6.10% spread, almost exactly where it was at eight thousand. Halving the step every three thousand coordinates leaves it at radius 0.9998 with a 2.92% spread. It is not that the fixed step is inaccurate โ it is that it never stops moving.
- And it has to be told, explicitly, not to settle for nearly right. Left alone, the learner is perfectly happy at 99% โ it cannot tell that "nearly right" is not the goal. With the two changes above, over five seeds and twelve thousand coordinates each, it was right about every one of its last hundred answers 41% of the time, and its longest unbroken run of them was 795 coordinates. Held-out accuracy at the end: 99.51%.
- Its confidence stops short of 100%, and it should. Its own confidence โ how far its belief sits from a coin, averaged โ reaches 97.27% and stays there. It stops short because a coordinate sitting on the boundary is one it is right to be unsure about, and the only way to be certain of every coordinate is to be certain about a line it is never shown. That is the reason the page shows this number next to the score rather than instead of it.
- How round it is, and when. After a thousand coordinates the boundary sits at radius 1.0251 with a 52.81% spread โ visibly lumpy. After two thousand: radius 1.0086 and 21.72%. After eight thousand: 1.0008 and 5.26%. After twelve thousand: 1.0002 and 3.55%. The stage is looking at the end of that, and the true radius is exactly 1.
- "Or on the border" is a rule that almost never fires, and it is written as one anyway. The test is "no further than", so a coordinate exactly on the border counts as inside. A random coordinate is a pair of real numbers, and landing exactly on the border happened 0 times in 20,000,000. The comparison is written that way because that is the rule โ not because it is expected to happen.
- Twenty-four units beat forty-eight, and four units are within half a point. Over five seeds at four thousand coordinates: 4 units reach 98.53% with seventeen numbers, 24 units reach 99.00% with ninety-seven, and 48 units reach 98.88% with a hundred and ninety-three. The size on this page is the middle one โ the small end costs almost nothing and the big end buys nothing โ and the honest reading is that the shape here is simple enough that extra capacity is just more to be wrong with, more slowly.
- The picture of the network's own belief costs about four milliseconds. Six thousand four hundred forward passes across an eighty by eighty grid, repainted about seven times a second. The figure is on the stage as it changes, because it is a real cost and it belongs on the page rather than in a footnote.
Right answers against coordinates asked
Out of the last hundred guesses, how many were right, against how many coordinates the network has been asked about. The rolling hundred rather than the running total, because a running total is dominated by whatever happened at the start and flatly refuses to move afterwards. The dashed line is the free score โ 78.54%, which is what answering "inside" to everything gets. Everything below that line is a learner doing worse than a machine that knows nothing, which is exactly where it begins.
Questions this page gets asked
Where is the circle?
Not on the stage. There is no circle geometry anywhere in the scene and no circle drawn in the page's own code either. The circle exists as one comparison โ x squared plus y squared, no greater than r squared โ and that comparison only ever decides whether a dot was right. Everything round on the stage is the network's own conclusion.
Is it memorising the coordinates?
No. Every accuracy figure on this page is measured on coordinates the network has never been shown, and ninety-seven numbers cannot hold a square full of coordinates. The page hands its own measurements over rather than asking you to take its word: the object called __circle is on the console, and its status() prints a score measured on four thousand coordinates it has never seen.
Why do the red dots sit where they sit?
Because that is where the job is hard. A red dot is a coordinate where the belief was on the wrong side of a half, and the belief is close to a half only near the boundary โ so the wrong answers collect in a ring. Measured against the true radius over a hundred and eighty directions, the learned boundary's mean error is 0.016.
Does anything I do here leave my browser?
No. The network, the training and the stage all run in this tab, and they are gone when it closes. The site sets no cookie of its own, and it asks Google for nothing at all unless you say yes to being counted.
Privacy
There is no account here, nothing to sign into, and nothing that is uploaded. The network is created, trained and thrown away inside this tab. Close it and nothing of it is left anywhere โ not on this site's servers, because there are none doing any work, and not in this browser either.
What is stored. One value in this browser's local storage, recording whether you agreed to be counted. No cookie of the site's own is set, and nothing you do is sent anywhere.
Analytics. The page does not carry Google's tag. The script that could load it is in the page with an empty measurement identifier, and it asks Google for nothing at all until you say yes. Refusing makes no request to Google, and the question is not asked again.
Your answer is changeable. The footer carries a door back into the same panel.
Where the data is. On your device, and nowhere else. The one thing a page usually fetches from somebody else is its typeface, and this one does not: the stylesheet uses the fonts your machine already has, so a visit that refuses makes no third-party request whatsoever.
When the page breaks. One thing is sent without being asked about, and this is it. If the page fails on your machine โ a browser that will not start the drawing stage, an error nobody caught โ a short note describing the fault goes to this site's own address, which passes it to the fault-tracking service Rollbar, where it is kept for a short period. It is not a cookie and it stores nothing in your browser; it carries no identifier, no account, no address and no search term, and the page path is sent without its query string. It is the only thing here that runs before you answer the question, because a breakage nobody hears about is a breakage nobody can fix. Reject all stops the counting and does not stop this.
Last changed: 4 October 2026.