Quay lại Trending
Dataset
mileswangs

mileswangs/polymarket-btc-updown-5m-orderbook-tick-data

Polymarket BTC Up/Down 5m Order Book Tick Data (L2) with Chainlink TWAP Everything you need to research Polymarket BTC Up/Down 5m markets in one dataset: tick-level L2 order books, on-chain trades, and the Chainlink price they settle on. 14 consecutive days (2026-08-08 to 2026-08-21), all 4,032 BTC Up/Down 5m markets. Every order book update as Polymarket sent it, every trade and on-chain fill, plus Chainlink Data Streams and the 60s TWAP that decides each market. Collected… See the full description on the dataset page: https://huggingface.co/datasets/mileswangs/polymarket-btc-updown-5m-orderbook-tick-data.

3thích
15.2ktải xuống
1lượt xem

Thành tựu nổi bật

Những danh hiệu mới nhất của dự án

1
TINIX TRENDING·Chủ đề: hft

#1 Repository của ngày

1
TINIX TRENDING·Chủ đề: l2

#1 Repository của ngày

1
TINIX TRENDING·Chủ đề: orderbook

#1 Repository của ngày

Polymarket BTC Up/Down 5m Order Book Tick Data (L2) with Chainlink TWAP

Everything you need to research Polymarket BTC Up/Down 5m markets in one dataset: tick-level L2 order books, on-chain trades, and the Chainlink price they settle on.

14 consecutive days (2026-08-08 to 2026-08-21), all 4,032 BTC Up/Down 5m markets. Every order book update as Polymarket sent it, every trade and on-chain fill, plus Chainlink Data Streams and the 60s TWAP that decides each market. Collected colocated with Polymarket in AWS London at 4.6 ms median latency, over two redundant WebSocket connections per market. Free sample from PMData.

Polymarket's API returns the order book as it is now. There is no endpoint for the book as it was, so past depth exists only if someone recorded the WebSocket feed while the market was live. This dataset is that recording: two weeks of complete market lifecycles, from open to resolution, nothing sampled or aggregated, long enough to backtest a strategy across different days.

What makes it different

  • Raw WebSocket messages, tick by tick. Every book and price_change message exactly as Polymarket sent it, so you can rebuild the book at any moment.
  • Two timestamps on every row. Polymarket's event time and PMData's receive time, both at microsecond precision. Collected in AWS London (eu-west-2), colocated with Polymarket's exchange: 4.6 ms median collection latency on best bid/ask changes (method); across all price_change rows in this dataset the median is 4.9 ms. The collector clock is synced to AWS PHC, which AWS documents with a clock error bound typically under 40 µs.
  • Redundant collection. Each market is recorded over two WebSocket connections on separate networks.
  • The resolution price is included. Chainlink Data Streams prices and 60s TWAP for BTC/USD, collected directly from Chainlink rather than through the Polymarket proxy. From 2026-08-14 on, the TWAP reproduces 2,263 of 2,265 recorded outcomes (see Quick start).

Coverage

Seriesbtc-updown-5m (Bitcoin Up or Down, 5 minutes)
Days2026-08-08 to 2026-08-21 UTC (14 consecutive days), by market start time
Markets4,032 (288 a day); 3,990 with a recorded outcome (2,013 Up, 1,977 Down)
Order book events456,962,342
Trades6,706,897
On-chain fills21,336,165
Chainlink BTC/USD1,151,517 stream reports, 1,151,543 TWAP 60s reports
Size5.6 GB, zstd-compressed Parquet, one file per table per day

Each market is complete from open to resolution, so a day's files run from a few minutes before 00:00 to a few minutes after 24:00 UTC.

Files

FileRowsContents
markets.parquet4,032One row per market: slug, start and end time, winning outcome
l2/date=YYYY-MM-DD/part-0.parquet456,962,342Order book events: book, price_change, tick_size_change, market_resolved
trades/date=YYYY-MM-DD/part-0.parquet6,706,897last_trade_price messages
onchain_fills/date=YYYY-MM-DD/part-0.parquet21,336,165Fills settled on Polygon, with maker and taker wallets
chainlink_streams/date=YYYY-MM-DD/BTCUSD.parquet1,151,517Chainlink Data Streams BTC/USD price, bid and ask
chainlink_streams_twap60s/date=YYYY-MM-DD/BTCUSD.parquet1,151,543Chainlink BTC/USD 60s TWAP

One file per table per UTC day; read a whole table with a glob such as l2/*/*.parquet.

Join tables on market_slug. The files use the same columns as the PMData API, so code written against this sample runs unchanged on the full archive. The only addition is market_slug in onchain_fills, which the API carries in the file name.

Schema

markets

ColumnTypeDescription
market_slugstringPolymarket market slug, e.g. btc-updown-5m-1786147200 (the number is the start time in Unix seconds)
start_timetimestamp[us, UTC]Market window start
end_timetimestamp[us, UTC]Market window end (start + 5 minutes)
winning_outcomestringyes (Up) or no (Down), from Polymarket's market_resolved message; null for 42 markets without that message
resolved_received_attimestamp[us]PMData receive time of the market_resolved message
l2_rowsint64Number of l2 rows for the market

l2

ColumnTypeDescription
market_slugstringPolymarket market slug
timestamptimestamp[us]Polymarket event timestamp
local_timestamptimestamp[us]PMData receive timestamp
event_typestringbook, price_change, tick_size_change or market_resolved
ask_priceslistAsk prices, best first. book rows only
ask_sizeslistSize at each price in ask_prices. book rows only
bid_priceslistBid prices, best first. book rows only
bid_sizeslistSize at each price in bid_prices. book rows only
best_askfloatBest ask after the change. price_change rows only
best_bidfloatBest bid after the change. price_change rows only
pc_pricefloatPrice level that changed. price_change rows only
pc_sizefloatNew total size at pc_price; 0 removes the level. price_change rows only
pc_sidestringBUY (bid) or SELL (ask). price_change rows only
new_tick_sizestringNew minimum tick size. tick_size_change rows only
winning_outcomestringWinning outcome. market_resolved rows only

trades

ColumnTypeDescription
market_slugstringPolymarket market slug
timestamptimestamp[us]Polymarket event timestamp
local_timestamptimestamp[us]PMData receive timestamp
event_typestringlast_trade_price
outcomestringTraded outcome: yes (Up) or no (Down)
pricefloatExecution price from 0 to 1
sizefloatOutcome tokens traded
sidestringAggressor side: BUY or SELL

onchain_fills

ColumnTypeDescription
market_slugstringPolymarket market slug
timestamptimestamp[us]Polygon block timestamp
makerstringMaker wallet address
takerstringTaker wallet address
outcomestringOutcome token
maker_sidestringBUY or SELL
taker_sidestringBUY or SELL
pricefloatExecution price
usd_amountfloatNotional in USD
token_amountfloatOutcome tokens transferred
transactionHashstringPolygon transaction hash
_log_indexint64Log index of the fill within the transaction
ColumnTypeDescription
observationsTimestamptimestamp[us]Chainlink observation time
receiveMicrosecondTimestamptimestamp[us]PMData receive timestamp
pricestringPrice (or 60s TWAP) scaled by 10^18. 63890200665000000000000 = 63,890.200665
bidstringBid scaled by 10^18; "none" for TWAP
askstringAsk scaled by 10^18; "none" for TWAP
validFromTimestamptimestamp[us]Report validity start
expiresAttimestamp[us]Report expiry
versionstringChainlink report version

Quick start

import polars as pl

l2 = pl.scan_parquet("l2/*/*.parquet")
markets = pl.read_parquet("markets.parquet")

# 1. Collection latency: receive time minus Polymarket event time, on price changes.
latency_ms = (
    l2.filter(pl.col("event_type") == "price_change")
    .select(((pl.col("local_timestamp") - pl.col("timestamp")).dt.total_microseconds() / 1000).alias("ms"))
    .collect()
)
print(latency_ms.describe())

# 2. Rebuild one market's book at any moment: start from the last `book` snapshot,
#    then apply each `price_change` (pc_size = new total size at pc_price, 0 removes it).
slug = markets["market_slug"][144]
events = l2.filter(pl.col("market_slug") == slug).collect()

# 3. Reproduce the outcome from Chainlink 60s TWAP: Up wins if the TWAP at the end of the
#    window is at least the TWAP at the start. Use the last report at or before each time.
twap = (
    pl.read_parquet("chainlink_streams_twap60s/*/*.parquet")
    .select("observationsTimestamp", (pl.col("price").cast(pl.Float64) / 1e18).alias("twap"))
    .unique("observationsTimestamp", keep="last")
    .sort("observationsTimestamp")
)
m = markets.with_columns(
    pl.col("start_time").dt.replace_time_zone(None),
    pl.col("end_time").dt.replace_time_zone(None),
)
for col in ["start_time", "end_time"]:
    m = m.sort(col).join_asof(
        twap.rename({"observationsTimestamp": f"{col}_obs", "twap": f"{col}_twap"}),
        left_on=col, right_on=f"{col}_obs", strategy="backward",
    )
m = m.with_columns(
    pl.when(pl.col("end_time_twap") >= pl.col("start_time_twap")).then(pl.lit("yes")).otherwise(pl.lit("no")).alias("twap_outcome")
)
m = m.filter(pl.col("winning_outcome").is_not_null())
print(m.group_by(pl.col("start_time").dt.date()).agg((pl.col("twap_outcome") == pl.col("winning_outcome")).mean().alias("match")).sort("start_time"))

For fill-level backtests that model queue position and latency, see pm-hftbacktest, a Polymarket fork of hftbacktest. Across 547 BTC 5-minute markets, its backtests matched live trading in 95.32% of markets.

Collection

  • Polymarket CLOB WebSocket, market channel; every message stored without modification.
  • AWS eu-west-2 (London), the same region as Polymarket's exchange.
  • Two WebSocket connections per market, in separate processes on separate networks.
  • Chainlink Data Streams collected from Chainlink's WebSocket, not the Polymarket proxy.
  • On-chain fills from Polygon OrderFilled events.

Limitations

  • 14 days and one series only. For more days, coins (ETH, SOL, XRP, DOGE, BNB, HYPE, ZEC), timeframes (5m, 15m, 1h) and every other Polymarket market, see below.
  • 42 markets have no market_resolved message, so winning_outcome is null for them.
  • On-chain fills are absent for 32 markets: 2026-08-13 05:50 and 05:55 UTC, and 30 markets between 04:15 and 10:45 UTC on 2026-08-19.
  • The TWAP rule in the Quick start matches 2,263 of 2,265 outcomes from 2026-08-14 on, and 1,621 of 1,725 (94%) on 2026-08-08 to 2026-08-13, the first days after the switch to TWAP resolution.
  • Measure collection latency on price_change rows, as in the Quick start; book rows are full snapshots rather than single changes.
  • The Chainlink TWAP series has a few one- or two-second gaps; use the last report at or before a given time, as in the Quick start.

More data

This sample comes from PMData, which records every Polymarket market tick by tick:

  • All Polymarket markets since 2026-05-01; crypto Up/Down markets since 2026-02-01.
  • L2 order books, trades, on-chain fills, Chainlink Data Streams and TWAP.
  • Daily Parquet files over an HTTP API, or one ZIP per Up/Down series per day.
  • Free trial with 600 downloads. Docs · Pricing · GitHub

License and citation

CC BY 4.0. Please credit PMData and link to https://pmdata.dev.

@misc{pmdata_polymarket_btc_updown_5m_2026_08,
  title  = {Polymarket BTC Up/Down 5m Order Book Tick Data (L2) with Chainlink TWAP},
  author = {PMData},
  year   = {2026},
  url    = {https://pmdata.dev}
}

Dự án tương tự

Khám phá các dự án và mô hình AI khác có sự tương đồng.

Dataset
secemp9/arxiv-complete

arXiv Complete Corpus A snapshot of arXiv's metadata, version history, submission files and rendered documents. It covers 3,148,796 papers and includes file contents, paths, sizes and SHA-256 digests. Metadata comes from arXiv's OAI-PMH arXivRaw interface; files come from the GCS mirror, S3 source archives and direct PDF fetches. This release holds a PDF for 99.47% of papers and 99.54% of versions reported with a non-zero submission size. It is a one-off snapshot; coverage gaps… See the full description on the dataset page: https://huggingface.co/datasets/secemp9/arxiv-complete.

♥0
104.9k
Sep 19, 2026
Dataset
HuggingFaceFW/fineweb

🍷 FineWeb 15 trillion tokens of the finest data the 🌐 web has to offer What is it? The 🍷 FineWeb dataset consists of more than 18.5T tokens (originally 15T tokens) of cleaned and deduplicated english web data from CommonCrawl. The data processing pipeline is optimized for LLM performance and ran on the 🏭 datatrove library, our large scale data processing library. 🍷 FineWeb was originally meant to be a fully open replication of 🦅 RefinedWeb, with a… See the full description on the dataset page: https://huggingface.co/datasets/HuggingFaceFW/fineweb.

♥0
419.5k
Jul 11, 2025
Dataset
HuggingFaceFW/fineweb-edu

📚 FineWeb-Edu 1.3 trillion tokens of the finest educational data the 🌐 web has to offer Paper: https://arxiv.org/abs/2406.17557 What is it? 📚 FineWeb-Edu dataset consists of 1.3T tokens and 5.4T tokens (FineWeb-Edu-score-2) of educational web pages filtered from 🍷 FineWeb dataset. This is the 1.3 trillion version. To enhance FineWeb's quality, we developed an educational quality classifier using annotations generated by LLama3-70B-Instruct. We… See the full description on the dataset page: https://huggingface.co/datasets/HuggingFaceFW/fineweb-edu.

♥0
524.8k
Jul 11, 2025
Dataset
bigcode/the-stack

Dataset Card for The Stack Changelog Release Description v1.0 Initial release of the Stack. Included 30 programming languages and 18 permissive licenses. Note: Three included licenses (MPL/EPL/LGPL) are considered weak copyleft licenses. The resulting near-deduplicated dataset is 3TB in size. v1.1 The three copyleft licenses ((MPL/EPL/LGPL) were excluded and the list of permissive licenses extended to 193 licenses in total. The list of programming… See the full description on the dataset page: https://huggingface.co/datasets/bigcode/the-stack.

♥0
116.9k
Aug 3, 2026
Dataset
tiiuae/falcon-refinedweb

📀 Falcon RefinedWeb Falcon RefinedWeb is a massive English web dataset built by TII and released under an ODC-By 1.0 license. See the 📓 paper on arXiv for more details. RefinedWeb is built through stringent filtering and large-scale deduplication of CommonCrawl; we found models trained on RefinedWeb to achieve performance in-line or better than models trained on curated datasets, while only relying on web data. RefinedWeb is also "multimodal-friendly": it contains links and… See the full description on the dataset page: https://huggingface.co/datasets/tiiuae/falcon-refinedweb.

♥0
23.9k
Jun 20, 2023
Dataset
HuggingFaceFW/finepdfs

Liberating 3T of the finest tokens from PDFs What is this? As we run out of web pages to process, the natural question has always been: what to do next? Only a few knew about a data source that everyone avoided for ages, due to its incredible extraction cost and complexity: PDFs. 📄 FinePDFs is exactly that. It is the largest publicly available corpus sourced exclusively from PDFs, containing about 3 trillion tokens across 475 million documents in 1733 languages. Compared to… See the full description on the dataset page: https://huggingface.co/datasets/HuggingFaceFW/finepdfs.

♥0
80.8k
Apr 3, 2026
Dataset
BAAI/Infinity-Instruct

Infinity Instruct Beijing Academy of Artificial Intelligence (BAAI) [Paper][Code][🤗] The quality and scale of instruction data are crucial for model performance. Recently, open-source models have increasingly relied on fine-tuning datasets comprising millions of instances, necessitating both high quality and large scale. However, the open-source community has long been constrained by the high costs associated with building such extensive and high-quality instruction… See the full description on the dataset page: https://huggingface.co/datasets/BAAI/Infinity-Instruct.

♥0
14.1k
Dec 4, 2025
Dataset
wikimedia/wikipedia

Dataset Card for Wikimedia Wikipedia Dataset Summary Wikipedia dataset containing cleaned articles of all languages. The dataset is built from the Wikipedia dumps (https://dumps.wikimedia.org/) with one subset per language, each containing a single train split. Each example contains the content of one full Wikipedia article with cleaning to strip markdown and unwanted sections (references, etc.). All language subsets have already been processed for recent dump… See the full description on the dataset page: https://huggingface.co/datasets/wikimedia/wikipedia.

♥0
385.4k
Jan 9, 2024
Dataset
OpenAssistant/oasst1

OpenAssistant Conversations Dataset (OASST1) Dataset Summary In an effort to democratize research on large-scale alignment, we release OpenAssistant Conversations (OASST1), a human-generated, human-annotated assistant-style conversation corpus consisting of 161,443 messages in 35 different languages, annotated with 461,292 quality ratings, resulting in over 10,000 fully annotated conversation trees. The corpus is a product of a worldwide crowd-sourcing effort… See the full description on the dataset page: https://huggingface.co/datasets/OpenAssistant/oasst1.

♥0
73.6k
May 2, 2023