Scintilla · Station · workshop · 23 September 2026

Context Lens 2 — the lens on real Station charts, up, down and sideways

Every chart below is drawn by the Station's own chart code, with the Station's own clouds, on real prices from the chart API. The lens is the small inset. This page is about one thing only: where the lens goes on a chart, and how it reads once it is there. No replay, no Geiger motion, no Visual Engine.

What you are looking at

The big chart is the window you are standing in. The lens answers the other question — either where this window sits in the whole history (context view) or what the last few sessions look like close up (detail view). It never covers the price line. It goes in the emptiest corner that is left.

Six real cases are shown: a strong uptrend, a strong downtrend, a sideways range, a turn up, a turn down, and a gap. Each one is a real symbol over a real period, named on the card. On each chart the chosen spot is drawn solid and the corners it did not choose are drawn faded, each with the share of it that is already painted on, so you can see why one corner won.

Adjustment — every number here is a baseline you can move

recommended Medium
recommended Top right
recommended 8 px
recommended Context
recommended 24 sessions
recommended 55%
recommended 0.96
recommended shown here, off in Station
 

The rule, in plain words

  1. Never cover the price. A corner is only allowed if the price line — every visible bar and the line drawn between them — stays at least the clearance you set away from the box. Default 8 pixels.
  2. Then take the emptiest corner. Of the corners that are allowed, the lens takes the one with the least already painted on it. "Painted" means anything the chart drew there: the price fill, the cloud ribbon, the average names, the axis numbers.
  3. A corner that is already painted over is refused too. Clearing the price line is not enough: if more than the share you set is already drawn on — cloud ribbon, price shading, average names — the lens will not sit there, because a lens on top of the ribbon is as hard to read as one on top of price.
  4. A near tie goes to your preferred corner. If your preferred corner is within two percentage points of the emptiest one, it wins, so the lens does not hop about between charts that look alike.
  5. If it does not fit, it shrinks. Large, then medium, then small.
  6. If it still does not fit, it parks below the chart rather than sitting on top of the price.

This is the v4 rule carried forward (safety before position, 8-pixel margin, shrink, then the shelf) with one change: v4 chose the allowed corner nearest your preference, which on a busy chart can pick a corner full of cloud ribbon. Here the chart is measured, so "emptiest" is a number rather than a guess.

What this was built from — and v4 is not missing

The brief said a v4 of the lens had existed and was lost. It is on this Mac. I found three versions before building anything:

WhatWhereState
v4 — "Context Lens — Bubble-Only Review v4" _worktrees/context-lens-20260919/prototypes/context-lens/index.html 73,151 bytes, sha256 3f4fc79c…, 19 Sep. Committed on the unmerged branch candidate/context-lens-20260919, which is why it looks lost: it was never released.
v2 — "Context Lens — Review Workshop v2" ~/Downloads/SCINTILLA_Context_Lens_Interactive_Review.html 66,382 bytes, 11 Sep. The catalogued one.
Today's workshop (lane M5)deliverables/20260923/context-lens/CONTEXT-LENS.html 28,280 bytes. This is the one that mixed in the replay, the Geiger and the Visual Engine.

Carried forward from v4: safety before position, the 8-pixel margin, context and detail as the two bubble states, shrink before shelf, minimal furniture in the bubble, and the rule that the main chart never changes when the bubble does.

Changed, on purpose: v4 drew synthetic fixtures on its own renderer — these are real prices on the Station's renderer. v4 chose the allowed corner nearest your preference; here the chart is measured and the emptiest allowed corner wins, with preference only breaking a near tie. v4's fixed 280–440 pixel boxes are replaced by shares of the pane, because a Station chart is a wide short band, not v4's tall stage. No replay was ever part of the lens — nothing in v4 or v2 has one, and none is here.

What happens on a phone

At 1680 pixels wide, five of the six cases keep the lens inside the chart and the sideways case parks it below. At 390 pixels — a phone — four keep it inside (one of them shrunk to small) and two park below: the sideways range and the turn down. That is the rule protecting price on a small pane, and it is the main thing to decide: on a phone, is a lens below the chart better than no lens, or should the phone simply not show one?

Recommended settings

KnobRecommendedWhy
SizeMedium — 30% of the chart's width, 44% of its height Big enough to read two price levels and two dates; small enough that a corner is usually free. Large needs a quiet chart; small is hard to read on a phone.
Corner preferenceTop right Prices more often rise into the top right than sit there, and the live price marker is already on the right edge, so a tie broken to the top right keeps the eye in one place. The rule still moves it when that corner is busy — the uptrend case below is exactly that.
Clear of price8 pixels Under about 4 the lens visually touches the line; over about 16 the lens is pushed onto the shelf on ordinary charts. 8 is the v4 value and it holds up on all six cases.
Busiest corner allowed55% drawn on Above about 60% the lens sits on solid cloud ribbon and neither reads. Below about 40% almost every corner is refused on a busy chart and the lens ends up on the shelf. 55% keeps a corner on five of the six cases here at desktop width, four of six on a phone.
Lens showsContext The main chart already shows the recent window in detail. The question the lens is there to answer is "where am I in the whole history".
Detail sessions24 About five weeks of daily bars — enough to see the shape of the last move at this size.
Opacity0.96 Slightly short of solid: the chart underneath stays faintly visible, so the lens reads as part of the chart rather than a sticker on it.
Other cornersShown here, off in Station The faded boxes are a workshop aid for this decision. In the Station they would be noise. They are left off when the lens parks below the chart, because the chart is resized at that moment and boxes measured before the resize would be drawn in the wrong place.

Where each number comes from

What could be wrong

What I did not do

Screenshots

The gallery at 1680 pixels wide
The page at 1680 wide — the top of it; the whole strip is in screens/gallery-1680.jpg.
The gallery at 390 pixels wide
The page at 390 wide (phone) — the top of it; the whole strip is in screens/gallery-390.jpg.
The uptrend case at 1680 wide
The uptrend case on its own: the lens sits top left, and the bottom right is refused as too painted on rather than as covering price.
The sideways case at 1680 wide
The sideways case: no corner survives, so the lens parks below the chart.
The turn-down case at 1680 wide
The turn-down case: the preferred top right is free, and the lens stays there.