Skip to content

quicknode/hl-priority-fees

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

THE SPEED MARKET

Live two-panel dashboard visualizing Hyperliquid's priority-fee mechanisms (April 2026 alpha) via Quicknode's ORDER_PRIORITY and GOSSIP_PRIORITY gRPC streams.

  • Panel 1 — READ PRIORITY: the gossip Dutch auctions (decaying ask from gossipPriorityAuctionStatus polls, bid events from the stream, resets, recent winners).
  • Panel 2 — WRITE PRIORITY: the order queue (each priority order is a block offset by ≈45ms/bp, mempool ghosts solidify on confirmation, a YOUR ORDER slider, session stats).
  • Sonification: Tone.js layer, off until clicked. Drone tracks the ask, plucks for bids, percussive hits per order scaled by bps, quantized to a 16th grid @112 BPM (toggleable to realtime).

Setup

pnpm install
cp relay/.env.example relay/.env   # fill in your Quicknode endpoint + token
# drop Quicknode's streaming.proto into relay/proto/streaming.proto

Run

pnpm dev:relay    # gRPC → WS relay on ws://localhost:8788
pnpm dev:web      # dashboard on http://localhost:5173

Record / replay

Order-priority adoption is early and live events can be sparse. Record a session once and replay it anytime to work with a consistent, busy dataset:

pnpm --filter relay dev -- --record                                   # writes recordings/session-<ts>.ndjson
pnpm --filter relay dev -- --replay recordings/session-<ts>.ndjson    # optional: --speed 2

Replay mode is announced in the relay's hello message and the frontend shows a persistent REPLAY badge — replayed data is never presented as live.

No credentials yet? A synthetic sample session is committed — try the full UI with:

pnpm --filter relay dev -- --replay fixtures/sample-session.ndjson

(relay/scripts/make-fixture.mjs regenerates it.)

Notes

  • The gossip ask decays linearly from startGas to endGas over durationSeconds per the API (in the wild endGas is startGas / 10; currentGas is set while the auction is live and null once it has cleared). The UI interpolates the price smoothly between 4s polls.
  • A new cycle's startGas is 10× the previous winner — the winners table is derived from resets.
  • GOSSIP_PRIORITY surfaces bids, not delivery speed; nothing here measures actual latency improvement. The "≈45ms per bp" figure is Hyperliquid's published estimate.
  • If the Quicknode HTTP endpoint rejects gossipPriorityAuctionStatus, the relay falls back to the public HL API for that one call and warns loudly.

Schema notes (observed production data, 2026-07)

  • block_time / first_seen_time are naive ISO strings with nanosecond precision and no timezone — treat as UTC (trim the fraction to ms, append Z). Either can be null; the relay normalizes to ts = first non-null of (first_seen_time, block_time, relay receive time) as epoch ms.
  • block_number can be null even for replica_cmds — never sort or key on it. Mempool→confirmed matching uses tx_hash.
  • px / sz / startGas / endGas arrive as strings; the relay parses them to numbers (null when absent/unparseable). p can be as small as 1 (0.0001 bp) — the UI shows sub-0.1 values as <0.1bp.
  • outcome is an open set ("error" observed, with a sibling error message string; "filled" and others assumed). The UI categorizes known values and renders unknowns neutrally — it never crashes on new ones.
  • Non-IOC events appear on mainnet (observed tif: "Alo") carrying a p grouping even though priority applies to IOC only — they render dimmed rather than being filtered, and the fees-paid stat counts only fill outcomes.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages