"""Self-contained live dashboard for the swarm. Served at ``/`` so the Hugging Face Space is something you can *watch* rather than only curl. No CDN, no build step, no external requests — one inline HTML string that polls the server's own JSON endpoints. Renders the loss curve as hand-built SVG so there is no charting dependency to ship to the Space. """ from __future__ import annotations DASHBOARD_HTML = """ Swarm Parameter Server

🐝 Swarm Parameter Server

Gradient accumulation over HTTP — a software interconnect in place of NVLink.

Global loss

Swarm contributors

WorkerAcceptedStepsLocal steps StaleCompressionUploadedLast lossIdle

Sample the global model

The model starts from random weights — early samples are noise. Watch them
become English as the swarm trains.
"""