Like this repository first, then request access / 请先点赞再申请
Approval is automatic for users who have liked (♥) this repository; a bot checks every few minutes. Requests from accounts that have not liked the repository stay pending. 点赞(页面右上 ♥ Like)的账号每几分钟自动放行;未点赞的申请会一直挂起。
By requesting access you confirm academic or non-commercial research use under the repository LICENSE, and that rights in the underlying market data remain with their owners. 申请即表示你确认仅用于学术或非商业研究(见 LICENSE),并承认底层行情数据的权利归属于原权利人。
Log in or Sign Up to review the conditions and access this dataset content.
China A-Share Level-2 Archive
2017–2026 · Quotes, orders and trades · Parquet
A historical archive of Chinese exchange Level-2 data, supplied through a vendor export. It includes ten-level quote snapshots, individual order messages and trade-stream records. The files cover A-share stocks and non-stock instruments such as ETFs and bonds. “Full-market” describes the export's scope, not a guarantee that every instrument or message is present.
中国证券市场 Level-2 历史数据归档,包含十档行情、逐笔委托、逐笔成交,按交易日保存为 Parquet。 数据来自供应商历史导出,范围含 A 股、ETF、债券等品种。 “全市场”指收录范围,不表示每个品种、每条消息都完整。 线上文件仍在分批上传。
English · 中文完整版 · Quickstart / 下载示例 · Files / 文件目录
Archive at a glance / 归档概览
| Historical manifest / 历史清单 | Verified scope / 统计范围 |
|---|---|
| 2,346 trading days / 交易日 | 2017-01-03 to 2026-08-31 |
| 555.85 billion rows / 5,558.55 亿行 | All three streams / 三类消息合计 |
| 6.18 TB | 7,038 compressed Parquet files / 压缩文件 |
These totals describe the published manifest snapshot, not the amount available to download. 以上是已发布清单的统计口径,不是线上已传完的数量。
English
What you can download
Inventory checked 2026-09-04, 23:08 UTC. Snapshot: b27b4bf.
The counts below will change as uploads continue.
| On the Hub at this revision | Amount |
|---|---|
| Day directories with all three files | 794 |
| Day directories still missing a file | 1 |
| Market-data Parquet files | 2,384 |
| Compressed market data | 2.10 TB |
Of the manifest's 2,346 dates, 793 have all three files online: 33.8%.
The other complete date, 2026-09-01, is newer than the manifest cutoff.
The partial directory is 2026-02-05, which lacks 逐笔成交.parquet at this revision.
Here, complete means three files exist. It does not certify a complete trading session.
Uploads span all ten calendar years but are not a continuous date range or a random sample. Check each required date before a multi-day study. A wildcard download can succeed even when most dates in the requested period are absent.
Coverage by year
Exact counts and percentages
| Year | Manifest days | Hub complete¹ | Complete |
|---|---|---|---|
| 2017 | 244 | 84 | 34.4% |
| 2018 | 243 | 71 | 29.2% |
| 2019 | 244 | 77 | 31.6% |
| 2020 | 243 | 90 | 37.0% |
| 2021 | 243 | 89 | 36.6% |
| 2022 | 242 | 88 | 36.4% |
| 2023 | 242 | 88 | 36.4% |
| 2024 | 242 | 78 | 32.2% |
| 2025 | 243 | 79 | 32.5% |
| 2026² | 160 | 49 | 30.6% |
¹ Only dates inside the manifest. The extra complete date, 2026-09-01, is excluded. ² 2026 covers January through August. These are file-availability ratios, not message-completeness ratios.
Quickstart
Start with the small quality-control ledger and a repository listing. Download market files only after checking dates.
pip install -U huggingface_hub pyarrow duckdb
hf auth login # gated repository: any read token works once your access request is approved
Access is gated. Click ♥ Like at the top of this page, then Request access. Likes are checked every few minutes and approved automatically; requests without a Like stay pending. Downloads need a logged-in token.
Check file availability at one fixed revision. This downloads only manifests.parquet, about 900 KB.
It distinguishes missing dates, partial directories and dates newer than the ledger.
from collections import defaultdict
from huggingface_hub import HfApi, hf_hub_download
import pyarrow.parquet as pq
REPO = "venvoo/china-a-share-l2-level2-limit-order-book-tick-data"
api = HfApi()
REV = api.dataset_info(REPO).sha # Freeze one revision for this run.
NEEDED = {"行情.parquet", "逐笔委托.parquet", "逐笔成交.parquet"}
files_by_day = defaultdict(set)
for path in api.list_repo_files(REPO, repo_type="dataset", revision=REV):
parts = path.split("/")
if (len(parts) == 2 and len(parts[0]) == 8
and parts[0].isdigit() and parts[1] in NEEDED):
files_by_day[parts[0]].add(parts[1])
complete = {d for d, files in files_by_day.items() if files == NEEDED}
partial = {d: sorted(NEEDED - files) for d, files in files_by_day.items()
if files != NEEDED}
manifest_file = hf_hub_download(
REPO, "manifests.parquet", repo_type="dataset", revision=REV
)
ledger = pq.read_table(manifest_file)
indexed = set(ledger["date"].to_pylist())
print("Revision:", REV)
print("Complete within manifest:", len(complete & indexed), "/", len(indexed))
print("Partial directories:", partial)
print("Manifest dates not complete:", len(indexed - complete))
print("Complete dates newer than/outside manifest:", sorted(complete - indexed))
Download one file and select one symbol. This example downloads the whole orders file,
about 2.43 GB, then prunes row groups locally. It does not download only the matching rows.
Run it after the availability check above, keeping the same REV.
DAY = "20260828"
if DAY not in complete:
raise RuntimeError(f"{DAY} is not complete at revision {REV}")
orders_file = hf_hub_download(
REPO, f"{DAY}/逐笔委托.parquet", repo_type="dataset", revision=REV
)
orders = pq.read_table(
orders_file,
columns=["wind_code", "time", "order_type", "order_code", "price", "volume"],
filters=[("wind_code", "=", "600519.SH")],
)
print(orders.num_rows)
For a small remote query, DuckDB supports hf:// paths through httpfs:
INSTALL httpfs;
LOAD httpfs;
SELECT time, price / 10000.0 AS price_cny,
bid_px1 / 10000.0 AS best_bid_cny,
ask_px1 / 10000.0 AS best_ask_cny
FROM 'hf://datasets/venvoo/china-a-share-l2-level2-limit-order-book-tick-data@b27b4bf2b895f0b582c904da921800ef8f871720/20260828/行情.parquet'
WHERE wind_code = '600519.SH'
ORDER BY time;
Remote queries can skip row groups but still incur HTTP requests and transfer costs. Use local files for repeated scans. Pin and cite the repository commit for reproducible work.
Three streams, three schemas
| File | Contents | Columns |
|---|---|---|
| 行情.parquet | Ten-level quote snapshots, roughly every 3 seconds per symbol | 66 |
| 逐笔委托.parquet | Individual order messages; cancellation encoding depends on venue | 10 |
| 逐笔成交.parquet | Executions and, for Shenzhen, cancellation records | 12 |
Trade-stream rows include Shenzhen cancellations, not only executions.
Exact message counts
| Stream | Rows | Share |
|---|---|---|
| Quotes | 42,905,444,709 | 7.7% |
| Orders | 287,847,312,166 | 51.8% |
| Trades | 225,101,951,708 | 40.5% |
The file names are Chinese; the field names are English. The three schemas should not be concatenated into one table.
YYYYMMDD/
行情.parquet
逐笔委托.parquet
逐笔成交.parquet
manifests.parquet
Field reference
Quotes: wind_code, ex_code, date, time, price, volume, amount,
num_trades, iopv, trade_flag, bs_flag, cum_volume, cum_amount, high, low,
open, prev_close; ask_px1..10, ask_vol1..10, bid_px1..10, bid_vol1..10;
wavg_ask_px, wavg_bid_px, tot_ask_vol, tot_bid_vol;
idx_unweighted, n_sym, n_up, n_down, n_flat.
Orders: wind_code, ex_code, date, time, order_id, ex_order_id,
order_type, order_code, price, volume.
Trades: wind_code, ex_code, date, time, trade_id, trade_code,
order_code, bs_flag, price, volume, ask_order_id, bid_order_id.
- Market-file
dateis uint32YYYYMMDD. Manifestdateis a string. timeis uint32HHMMSSmmm:103807810means 10:38:07.810, Asia/Shanghai.- IDs are uint64. Numeric payload fields use DOUBLE. Empty source fields become NULL.
- Text is generally Arrow
large_string; some early files usestring. Cast when needed before concatenation.
Read before calculating features
Venue attribution. Do not infer the exchange from the .SH or .SZ suffix.
Shanghai ETFs, bonds and other non-stock instruments can carry .SZ in this export.
For example, Shanghai-listed 510300 appears as 510300.SZ.
On 2026-08-28, 23.3% of order rows had a .SZ suffix but Shanghai-style message codes.
ex_code is a security code, not a venue identifier. Use a date-appropriate instrument reference.
Some dates, including 2017-12-01, use lowercase suffixes; case normalization does not fix venue attribution.
Historical order coverage. Shanghai stock-order messages enter this archive on 2021-07-23. Do not treat the earlier absence as zero order activity. A measured suffix-bucket comparison follows; it is not a clean venue census, and the July 22 files start late in the session.
| Order rows by suffix bucket | 2021-07-22 | 2021-07-23 |
|---|---|---|
.SH |
0 | 44,650,953 |
.SZ |
60,126,847 | 86,185,512 |
Cancellation and order codes. Apply venue-specific rules:
| Venue | Cancellation stream | Code |
|---|---|---|
| Shanghai | Orders / 逐笔委托 | order_type = 'D' |
| Shenzhen | Trades / 逐笔成交 | trade_code = 'C' |
Shenzhen publishes original orders; Shanghai order messages can describe the remainder after fills.
For Shenzhen limit orders, include order_type IN ('0','2'): this export uses both encodings.
A '0'-only filter can remove entire sessions, including 2024-06-17.
On 2022-08-19 the encoding changes within the day; do not hard-code an unverified crossover time.
The order_code field uses B / S for direction.
Prices and invalid values. Divide stock prices and quote-price levels by 10,000 to obtain CNY.
For example, 12,978,900 means 1,297.89 CNY. This conversion does not establish the units of
amount, iopv or other derived fields. Unsigned representations of negative/sentinel values can appear
as huge positive numbers in numeric columns. Check magnitudes before computing means or notionals.
Identity and reconstruction. Order and trade IDs are sequence identifiers, not accounts or brokers. They can support lifecycle matching where the required messages exist. This vendor archive does not guarantee lossless order-book reconstruction or complete queue positions. It has no exchange-feed receive timestamps.
Session coverage: inspect the recorded times
The table below reports full-market manifest observations for 2026-08-28. These are earliest/latest records, not exchange session schedules.
| Stream | First recorded time | Last recorded time |
|---|---|---|
| Quotes | 08:00:00.000 | 15:00:58.911 |
| Orders | 08:33:44.320 | 15:00:58.992 |
| Trades | 09:15:00.010 | 15:00:58.992 |
All times are Asia/Shanghai. Orders can include pre-auction records. Other dates have missing session prefixes: on 2021-07-22, all three streams start around 09:48:05. Passing conversion checks does not establish full-session coverage. Inspect each date and symbol before auction, event-window or book-reconstruction research.
Download size by year
Average compressed size of all three streams per included trading day, in decimal GB. These numbers summarize the historical manifest, not just the uploaded subset.
Exact average download sizes
| Year | Average GB/day |
|---|---|
| 2017 | 0.95 |
| 2018 | 0.93 |
| 2019 | 1.18 |
| 2020 | 1.77 |
| 2021 | 2.46 |
| 2022 | 3.05 |
| 2023 | 2.91 |
| 2024 | 3.52 |
| 2025 | 4.44 |
| 2026² | 6.46 |
² 2026 through August. The 2026-08-28 example day totals 5.89 GB; it is below the 2026 average. For scale, the full 2017 manifest year totals 231.77 GB, while 2025 totals 1,079.28 GB.
Message volume over time
Exact annual mean message counts
Millions of rows per trading day, annual means. Trades-stream rows include Shenzhen cancellations; they are not all executions. The Shanghai order-coverage change affects the 2021 comparison.
| Year | Quotes | Orders | Trades |
|---|---|---|---|
| 2017 | 10.3 | 19.7 | 26.9 |
| 2018 | 10.5 | 19.5 | 26.5 |
| 2019 | 12.5 | 29.6 | 39.7 |
| 2020 | 15.2 | 49.2 | 63.6 |
| 2021 | 17.0 | 92.8 | 91.7 |
| 2022 | 19.8 | 142.9 | 113.9 |
| 2023 | 20.9 | 140.1 | 103.3 |
| 2024 | 24.7 | 200.1 | 133.4 |
| 2025 | 26.8 | 255.9 | 172.9 |
| 2026² | 28.9 | 359.2 | 236.4 |
² 2026 through August. These are annual means, not rolling averages.
Query performance
Rows are clustered by wind_code, and the sampled files have row-group min/max statistics.
Symbol filters can therefore skip most row groups. A prior measurement for 600519 on 2026-08-28:
| Stream | Whole-file size | Read after pruning |
|---|---|---|
| Orders | 2,432 MB | 9.1 MB |
| Trades | 2,105 MB | 15.4 MB |
| Quotes | 1,349 MB | 57.9 MB |
These are sample measurements, not download-size guarantees. hf_hub_download downloads the full file.
Remote query engines may use range requests. Pruning varies with date, stream, columns and query engine;
earlier files often have fewer row groups. Check Parquet footers rather than assuming every payload column
has statistics. A prefix filter such as wind_code LIKE '600519%' also matches lowercase-suffix dates.
Quality checks and known gaps
The ledger contains 2,346 rows and 77 columns. All indexed dates passed the conversion pipeline's five checks:
| Gate | Check |
|---|---|
| G0 | Source listing fingerprint |
| G1 | File inventory |
| G2 | Partition integrity |
| G3 | Row reconciliation with the vendor export |
| G4 | Conversion semantic checks |
These checks concern the conversion, not independent completeness against exchange records. The ledger includes source sizes, row counts, instrument counts, observed time ranges, repairs and the original JSON record. Source-archive SHA-256 hashes exist for 2,295 dates; 51 are missing.
| Repair | Affected dates¹ | Amount |
|---|---|---|
Drop date=0 filler |
203 | 17,287,885 rows |
| Restore dates on real payloads | 285 | 15,783,503 rows |
| Strip embedded NUL bytes | 11 | 677,759,395 bytes |
| Drop stray-date duplicate rows | 1 | 1,057,825 rows |
| Drop extra trailing columns | 5 | See ledger |
¹ Distinct dates across streams; categories can overlap. The stray-date repair affects the 2020-02-25 archive, which contained duplicate rows dated 2020-02-28. Do not sum these date counts as a unique total.
Repair fields and a local ledger query
Fields use the prefix streams_<stream>_, where stream is 行情, 逐笔委托 or 逐笔成交.
Only stream/repair combinations that occurred have a column.
| Suffix | Meaning |
|---|---|
date0_sentinel_junked |
Dropped filler rows |
date0_repaired |
Restored payload dates |
nul_bytes_stripped |
Removed NUL bytes |
stray_date_rows_dropped_20200228 |
Dropped 2020-02-28 rows from the 2020-02-25 archive |
extra_tail_cols_dropped |
Removed trailing fields |
Run this after the Quickstart's ledger download:
import duckdb
con = duckdb.connect()
con.register("ledger", ledger)
print(con.sql("""
SELECT count(*) AS days,
count(*) FILTER (WHERE gates_all_green) AS passed_conversion,
count("7z_sha256") AS source_hashes,
min(date) AS first_day, max(date) AS last_day
FROM ledger
""").fetchall())
# Historical snapshot: 2346, 2346, 2295, '20170103', '20260831'
lean_stats_deferred=true does not mean the shipped files lack statistics.
fingerprint_col_counts_行情 counts the source CSV header, not the shipped quote schema.
Read the Parquet footers for actual field types and statistics.
Updates and terms
The mirror grows through batch uploads, not necessarily in date order. The published manifest can lag newly uploaded dates. There is no guaranteed daily delivery time. Enumerate the files and check the ledger cutoff before each download.
For academic and non-commercial research only; see LICENSE. Rights in the underlying market data remain with their respective owners. The repository license covers compilation, cleaning and documentation, not ownership of the source market data. No warranty of fitness applies. Do not use this archive as the sole basis for trading decisions. Rights holders can contact the maintainer through repository discussions.
中文说明
这份数据包含什么
这是一份中国证券市场 Level-2 历史数据归档,来自供应商的历史导出,按交易日保存为 Parquet。 你可以读取十档行情快照、逐笔委托消息和逐笔成交记录,研究盘口、订单流及成交行为。 逐笔成交文件中还包含深圳市场的撤单记录,因此消息行数不等于成交笔数。
收录范围不仅有 A 股,也有 ETF、债券、回购等非股票品种。文件中的证券数量不能当作 A 股股票数量。 历史清单覆盖 2017-01-03 至 2026-08-31,共 2,346 个交易日、5,558.55 亿行消息、6.18 TB 压缩文件。 这些数字描述清单所覆盖的归档,并不表示线上已经全部上传。
现在能下载多少
核对时间:2026-09-04 23:08 UTC,也就是北京时间 2026-09-05 07:08。
以下数字对应固定版本 b27b4bf,上传继续后会发生变化。
| 线上文件状态 | 数量 |
|---|---|
| 三份文件都已上传的日期 | 794 天 |
| 仍缺少一份文件的日期 | 1 天 |
| 行情、委托、成交 Parquet 文件 | 2,384 份 |
| 已上传压缩体积 | 2.10 TB |
清单中的日期有 793 / 2,346 天三份文件齐全,比例为 33.8%。 另有 2026-09-01 已传齐,但它晚于清单截止日,因此不计入这个比例。 2026-02-05 的目录还缺逐笔成交文件。 这里的“齐全”只表示三份文件都存在,不代表整天的每条消息都完整。
已上传日期分散在各年,并不连续,也不是经过随机抽样得到的研究样本。 研究连续事件窗口、隔夜衔接或订单生命周期前,请先核对所需日期。 通配符下载成功,只代表匹配到的文件已下载,不代表请求的日期范围完整。
各年上传覆盖
展开精确天数与比例
| 年份 | 清单天数 | 线上三份齐全¹ | 比例 |
|---|---|---|---|
| 2017 | 244 | 84 | 34.4% |
| 2018 | 243 | 71 | 29.2% |
| 2019 | 244 | 77 | 31.6% |
| 2020 | 243 | 90 | 37.0% |
| 2021 | 243 | 89 | 36.6% |
| 2022 | 242 | 88 | 36.4% |
| 2023 | 242 | 88 | 36.4% |
| 2024 | 242 | 78 | 32.2% |
| 2025 | 243 | 79 | 32.5% |
| 2026² | 160 | 49 | 30.6% |
¹ 只统计历史清单中的日期,不含清单截止日之后的 2026-09-01。 ² 2026 年只到 8 月底。这里统计的是文件上传比例,不是交易消息的完整率。
如何开始使用
本仓库需申请访问。 先点页面右上角 ♥ Like,再点 Request access。机器人每几分钟核对一次点赞名单并自动放行;
未点赞的申请会一直挂起。下载时需要先 hf auth login(已放行账号的任意 read token 即可)。
建议先下载约 900 KB 的 manifests.parquet,核对日期和转换记录,再下载大文件。
上方 Quickstart 提供可直接运行的安装、清点、下载和查询代码。
- 清点代码固定同一个提交版本,分别统计清单内已传齐、部分上传、尚未传齐以及清单之外的日期。
- 单股票示例先下载整份逐笔委托文件,再按股票代码读取。示例日整份文件约 2.43 GB,不是只下载这一只股票。
- DuckDB 远程查询可以利用行组统计跳过部分内容,但仍会产生网络请求;反复研究同一批日期,建议下载后本地查询。
- 复现实验需要保存并引用提交 SHA。直接使用不断变化的
main,不能保证之后得到同一份数据。
文件结构与字段
| 文件 | 含义 | 列数 |
|---|---|---|
| 行情.parquet | 十档行情快照,每个证券通常约 3 秒一条 | 66 |
| 逐笔委托.parquet | 委托消息;撤单在哪个文件取决于交易所 | 10 |
| 逐笔成交.parquet | 成交消息,以及深圳市场的撤单记录 | 12 |
逐笔成交流包含深圳撤单,不全是真实成交。
展开各类消息行数
| 消息流 | 行数 | 比例 |
|---|---|---|
| 行情 | 42,905,444,709 | 7.7% |
| 逐笔委托 | 287,847,312,166 | 51.8% |
| 逐笔成交 | 225,101,951,708 | 40.5% |
每个交易日一个目录,三份文件各用自己的字段结构,不能直接上下拼成一张表。
文件名为中文,字段名为英文。根目录的 manifests.parquet 是按日转换清单。
展开字段说明
行情: 证券代码、日期、时间、价格、成交量/额,以及 ask_px1..10、ask_vol1..10、
bid_px1..10、bid_vol1..10 四组十档字段。还包括累计量额、开高低、昨收、加权价及部分指数统计字段。
英文版的 Field reference 保留完整字段列表。
逐笔委托: wind_code、ex_code、date、time、order_id、ex_order_id、
order_type、order_code、price、volume。
逐笔成交: wind_code、ex_code、date、time、trade_id、trade_code、
order_code、bs_flag、price、volume、ask_order_id、bid_order_id。
- 日期: 行情文件中的
date为 uint32,格式YYYYMMDD;清单中的date为字符串。 - 时间:
time为 uint32,格式HHMMSSmmm。例如103807810表示 10:38:07.810,时区为上海。 - 类型: 订单和成交标识为 uint64;数值载荷为 DOUBLE;原始空字段为 NULL。文本通常为
large_string,部分早期日期为string。
使用前必须了解的口径
证券后缀不能确定交易所。 部分上交所 ETF、债券等品种在这份导出里也带 .SZ,
例如上交所 ETF 510300 以 510300.SZ 出现。
2026-08-28 的委托消息中,23.3% 带 .SZ 后缀,却使用上交所消息编码。
ex_code 同样只是证券代码,不是交易所编号。请使用与日期匹配的证券名录。
部分日期的后缀为小写;统一大小写只能解决文本匹配,不能修复交易所归属。
上海逐笔委托有历史起点。 本归档从 2021-07-23 开始出现上海股票的逐笔委托。 此前缺失不能解释为没有委托活动。跨越这一天比较订单流时,要区分交易所和覆盖变化。 英文版保留了相邻日期按后缀分组的行数;该分组不等于干净的交易所分组,而且前一天的文件还缺少早盘前段。
撤单和限价单需要按交易所解码。
| 交易所 | 撤单所在文件 | 判断字段 |
|---|---|---|
| 上海 | 逐笔委托 | order_type = 'D' |
| 深圳 | 逐笔成交 | trade_code = 'C' |
深圳发布原始委托,上海消息可能描述部分成交后的剩余委托。
筛选深圳限价单时需兼容 order_type IN ('0','2')。
仅保留 '0' 会漏掉某些整天的数据,例如 2024-06-17。
2022-08-19 存在日内编码切换,不应把未经确认的具体切换时刻写死。方向字段 order_code 使用 B / S。
股票价格需要除以 10,000。 例如 12,978,900 对应 1,297.89 元,盘口价位同样需要换算。
不要把这个比例直接套到 amount、iopv 等未核实字段。
负数或哨兵值可能以无符号形式存储,读成异常大的正数;计算均值、金额前要检查取值范围。
标识不是投资者身份。 订单号、成交号及买卖方订单关联号是序列标识,不能识别账户、券商或个人。 只有相关消息确实存在时,才可能做订单生命周期匹配。供应商归档不保证无损盘口重建,也没有接收时间戳或完整队列位置。
日内覆盖不能只看文件是否存在
下表是 2026-08-28 全市场清单记录的最早和最晚时间,不是交易所的开收盘日程。
| 消息流 | 最早记录 | 最晚记录 |
|---|---|---|
| 行情 | 08:00:00.000 | 15:00:58.911 |
| 逐笔委托 | 08:33:44.320 | 15:00:58.992 |
| 逐笔成交 | 09:15:00.010 | 15:00:58.992 |
以上均为上海时间。委托文件可能包含集合竞价开始前的记录。 另一些日期缺少交易时段开头的一段记录,例如 2021-07-22 三类消息都从约 09:48:05 才开始。 转换校验通过,不等于全天覆盖完整。研究集合竞价、事件窗口和盘口重建时,请逐日、逐证券核对。
下载体积要按年份估算
下表统计历史清单中,每个交易日三类压缩文件合计的平均体积。 GB 使用十进制,不等同于 GiB;2026 年只到 8 月底。
展开各年日均下载体积
| 年份 | 日均压缩体积 GB |
|---|---|
| 2017 | 0.95 |
| 2018 | 0.93 |
| 2019 | 1.18 |
| 2020 | 1.77 |
| 2021 | 2.46 |
| 2022 | 3.05 |
| 2023 | 2.91 |
| 2024 | 3.52 |
| 2025 | 4.44 |
| 2026² | 6.46 |
² 2026 年只到 8 月底。示例日 2026-08-28 合计 5.89 GB,不能代表整个 2026 年的均值。 2017 全年合计 231.77 GB;2025 全年合计 1,079.28 GB。
三类消息的规模变化
展开各年日均消息量
单位:百万行/交易日,按年取平均。 逐笔成交流包含深圳撤单,所以不能把这一列当作真实成交笔数。 2021 年上海委托覆盖变化会影响年度对比。
| 年份 | 行情 | 逐笔委托 | 逐笔成交 |
|---|---|---|---|
| 2017 | 10.3 | 19.7 | 26.9 |
| 2018 | 10.5 | 19.5 | 26.5 |
| 2019 | 12.5 | 29.6 | 39.7 |
| 2020 | 15.2 | 49.2 | 63.6 |
| 2021 | 17.0 | 92.8 | 91.7 |
| 2022 | 19.8 | 142.9 | 113.9 |
| 2023 | 20.9 | 140.1 | 103.3 |
| 2024 | 24.7 | 200.1 | 133.4 |
| 2025 | 26.8 | 255.9 | 172.9 |
| 2026² | 28.9 | 359.2 | 236.4 |
² 2026 年只到 8 月底。这里使用年度均值,不是移动均值。
查询性能
文件按 wind_code 聚集排列,抽查文件的行组带有最小/最大值统计。
按证券筛选时,查询引擎可以跳过许多不相关的行组。
此前对 2026-08-28 的 600519 做过如下测量:
| 文件 | 整份大小 | 行组裁剪后读取量 |
|---|---|---|
| 逐笔委托 | 2,432 MB | 9.1 MB |
| 逐笔成交 | 2,105 MB | 15.4 MB |
| 行情 | 1,349 MB | 57.9 MB |
这些是特定日期、证券和查询的测量,不是所有下载都会达到的结果。
hf_hub_download 下载整份文件;支持范围请求的远程查询引擎才可能只读取部分字节。
不同年份、字段和行组划分会改变裁剪效果。实际类型与统计信息请看 Parquet 文件尾部元数据。
质量检查、修复与局限
历史清单有 2,346 行、77 列,所有列入清单的日期都通过了转换流程中的检查:
| 检查 | 内容 |
|---|---|
| G0 | 原始文件列表指纹 |
| G1 | 文件清点 |
| G2 | 分区完整性 |
| G3 | 与供应商导出的行数核对 |
| G4 | 转换语义检查 |
这些检查核对的是供应商导出到 Parquet 的转换,不等于与交易所独立核对过所有消息。 清单还记录文件体积、行数、证券数、观测时间范围、修复记录和原始 JSON。 2,295 天有源压缩包 SHA-256,另有 51 天缺失,不能声称每天都有完整哈希链。
| 修复类型 | 涉及日期数¹ | 数量 |
|---|---|---|
丢弃 date=0 填充记录 |
203 | 17,287,885 行 |
| 恢复有效记录的缺失日期 | 285 | 15,783,503 行 |
| 去除嵌入的 NUL 字节 | 11 | 677,759,395 字节 |
| 丢弃混入的异日重复记录 | 1 | 1,057,825 行 |
| 去除多余尾列 | 5 | 见清单 |
¹ 日期数按三类流合并去重,不同修复类型之间可能重叠,不能相加得到总受影响天数。 异日重复记录问题出在 2020-02-25 的归档,里面混入了日期为 2020-02-28 的重复行。 修复字段及查询示例见英文版的 Repair fields。
lean_stats_deferred=true 不能用来判断已发布文件是否没有统计信息。
fingerprint_col_counts_行情 记录原始 CSV 表头列数,不是最终 Parquet 列数;行情文件实际为 66 列。
更新方式与使用条款
线上副本按批次补充,上传顺序不一定按日期排列,清单也可能落后于新上传的日期。 不保证每日固定时间交付。 使用前请重新清点目录并检查清单截止日。
仅供学术与非商业研究,具体条款见 LICENSE。 底层行情数据权利仍属于相应权利人;仓库许可证只覆盖汇编、清洗和文档工作,不代表对源行情数据拥有全部权利。 数据按现状提供,不保证适合某一用途,也不应成为交易决策的唯一依据。 权利人如有疑问,可通过仓库讨论区联系维护者。
Citation / 引用
@misc{ashare_l2_2026,
title = {{China A-Share Full-Market Level-2 Order Book and Tick Archive (2017--2026)}},
author = {{venvoo}},
year = {2026},
publisher = {{Hugging Face}},
howpublished = {\url{https://huggingface.co/datasets/venvoo/china-a-share-l2-level2-limit-order-book-tick-data}},
note = {Dataset. Cite the repository commit used for the experiment.}
}
- Downloads last month
- 4,878