← Charlie Yan

deskboard

2026 — Python · asyncio · Panel · httpx

Repository ↗

Quotes, fills and positions go onto an asyncio event bus. A Book computes Black-Scholes Greeks and dollar-Greeks per leg and attributes P&L. A snapshot feeds two consumers that only read: a Panel UI, and a Telegram bot. The same session file gives the same screens, at any replay speed, and CI checks the state hash to prove it.

The identity

For every position and for the book, realized == delta + gamma + vega + theta + execution + residual holds to 1e-9. The residual is a reported component, never a plug. On the demo day that reads: +$412 today is delta (+$427) less short-gamma bleed on the afternoon air pocket (−$58), plus vega from the post-lunch vol bump (+$57), a little theta, the spread paid opening one position (−$13.50), and −$6.90 the Greeks don’t explain and the screen doesn’t hide.

Alerts that carry a reason

The limit engine fires on state change only, with the value and the bound: ν$ per vol pt −265 < limit −250. Clearing needs the value 5% back inside the bound, so a number hovering at a limit doesn’t page you every tick. The Telegram bot pushes each event and answers /risk, /pnl, /positions and /alerts. It’s read-only, answers one configured chat, and talks to the Bot API directly over HTTPS with no framework and no token in the repo.

Design rules, all tested

Determinism across platforms (raw Greeks differ in the last bits between Linux and macOS; the hash rounds to 1e-6 and the difference is measured, in DESIGN.md). Bus dispatch p99 under 10 ms, measured on every run. The pricer is an interface: BSM today, a surface pricer later, attribution untouched. It never submits orders. Positions come from a blotter file.

Numbers, and a reason for each number. No AI-insight widgets.