- M8 N0 Numeric Equity Ranking
- Task and outputs
- Input design
- Network architecture
- Forward temporal validation
- Exploratory portfolio diagnostics after transaction-cost assumptions
- Three temporal folds
- Reproduction record
- Installation and inference
- Repository contents
- Research uses
- License and release scope
- What reviewers can inspect
- Citation
- Use statement
- Task and outputs
M8 N0 Numeric Equity Ranking
5,345 parameters · 298,769 validation records · 1,350 trading days · mean daily IC 0.02088 · IC t-statistic 5.07
M8 N0 ranks US equity vendor-symbol-day observations within each decision date. The model receives a 48-dimensional numeric input and assigns a continuous score to each symbol. That score expresses relative preference within the day's equity universe.
The input combines 23 market, liquidity, event-coverage, and publisher-structure features with 23 missingness indicators and two log-transformed event-count features. The network has 5,345 parameters. Each of the three temporal-fold weight files occupies 22,132 bytes and uses Safetensors. The same inference program runs on CPU and CUDA and accepts CSV or Parquet input.
The repository places the field order, preprocessing rules, architecture, fold-level scalers, evaluation definitions, cost calculations, weight checks, and executable examples in one release. A reviewer can start with the synthetic example row, inspect every preprocessing step, load any temporal fold, produce scores, cross-check the aggregate reports, and verify the distributed file hashes.
Task and outputs
M8 N0 performs same-day cross-sectional equity ranking. A higher score records a higher model preference within that decision date; a lower score records a lower preference.
The supervised target is constructed within each decision date from eligible
stocks' same-day open-to-close returns. Ties receive average ranks. Each rank is
converted to a percentile with (average_rank - 0.5) / cross_section_count,
clipped to [0.0001, 0.9999], and mapped through the standard-normal inverse
cumulative distribution function. This construction gives the network a daily
relative objective with a defined cross-sectional interpretation.
The inference program writes two outputs:
| Output | Definition |
|---|---|
m8_n0_score |
Direct network output in the standardized target space |
m8_n0_prediction |
Fold-specific target-scale reconstruction using the stored mean and standard deviation |
Both fields support within-date ranking. Comparisons across years, vendors, or feature revisions require a fresh check of input and score distributions.
Input design
The 48 model inputs are organized as follows:
| Input group | Count | Contents |
|---|---|---|
| Asset-market features | 10 | Lagged returns, rolling means, volatility, volume, dollar volume, and liquidity statistics |
| Market-context features | 6 | Cross-sectional market-return statistics and lagged QQQ return, mean, and volatility |
| Event and publisher metadata | 7 | Event-to-security breadth, relation weights, multi-security event share, publisher count, and concentration |
| Missingness indicators | 23 | One indicator for every numeric feature |
| Event counts | 2 | log1p transforms of raw and deduplicated event counts |
config.json fixes the name and order of every numeric field.
docs/FEATURE_SCHEMA.md documents the field meanings and the corresponding
requirements for trading calendars, decision cutoffs, event cutoffs, universe
freezing, corporate actions, and event deduplication.
Each temporal fold carries its own training-period statistics. Inference performs the following operations:
- identify non-finite numeric values;
- fill them with the training-period median;
- center and scale each value;
- clip scaled values to
[-10, 10]; - append 23 missingness indicators;
- apply
log1pto the two event-count fields; - require a finite 48-dimensional result.
Missing columns, negative event counts, invalid tensor dimensions, and non-finite count values produce explicit errors.
Network architecture
48 inputs
→ LayerNorm(48)
→ Linear(48, 64)
→ GELU
→ Dropout(0.10)
→ Linear(64, 32)
→ GELU
→ Linear(32, 1)
Inference uses evaluation mode, which disables Dropout. config.json records
the input width, hidden width, projection width, dropout rate, random seed, and
default fold. Weight loading uses strict state-dictionary matching.
The network contains 5,345 parameters. Its three temporal-fold weight files occupy about 65 KiB in total. Runtime dependencies are NumPy, pandas, PyArrow, PyTorch, and Safetensors. Every layer and every trainable tensor can be inspected directly from the release.
Forward temporal validation
The three checkpoints come from training windows that advance through time. Each checkpoint was evaluated on chronologically later observations. The combined validation set contains 298,769 vendor-symbol-day records across 1,350 trading days.
| Fold | Records | Trading days | Mean daily Spearman IC | IC t-statistic | Positive-IC days |
|---|---|---|---|---|---|
| 0 | 65,036 | 448 | 0.01633 | 2.71 | 54.9% |
| 1 | 107,457 | 455 | 0.02948 | 3.76 | 58.5% |
| 2 | 126,276 | 447 | 0.01668 | 2.25 | 53.0% |
| Combined | 298,769 | 1,350 | 0.02088 | 5.07 | 55.5% |
These chronologically later windows supported checkpoint selection. Untouched tests and prospective paper-trading results remain future evidence. The reported t-statistics use conventional daily-series formulas without serial-correlation or multiple-selection adjustments.
All three folds recorded a positive mean daily IC. The combined mean daily IC is 0.02088, the median daily IC is 0.01957, and the daily-IC t-statistic is 5.07. The result appears across validation windows of 448, 455, and 447 trading days.
Sorting by prediction into quintiles produced the following top-minus-bottom differences in the standardized target:
| Fold | Top-minus-bottom target-z |
|---|---|
| 0 | 0.0571 |
| 1 | 0.0818 |
| 2 | 0.0575 |
| Combined | 0.0655 |
The combined quintile-spread t-statistic is 5.79. The release reports the mean, median, positive-day share, quintile spread, and spread t-statistic so that the ranking result can be examined from several statistical views.
Exploratory portfolio diagnostics after transaction-cost assumptions
These figures are exploratory diagnostics computed from checkpoint-selection validation labels under simplified portfolio and transaction-cost assumptions. They quantify how the learned ranking orders the validation target within the development protocol. Realized PnL and confirmatory performance require executed-trade or untouched prospective evidence.
The diagnostic ranks eligible equity symbols by the model score each day and
forms an equal-weight long-short portfolio. The selected development portfolio
holds the highest-scoring 10% on the long side and the lowest-scoring 10% on
the short side, for 2.0 gross exposure. Returns use the open-to-close target
window. Annualized arithmetic return equals 252 × mean daily return.
| Cost convention | Annualized arithmetic return | Annualized volatility | Sharpe |
|---|---|---|---|
| Before costs | 26.7% | 20.0% | 1.34 |
| 1 bp per side | 16.6% | 20.0% | 0.83 |
| 2 bps per side | 6.6% | 20.0% | 0.33 |
One basis point equals 0.01%. The “1 bp per side” convention charges long entry, long exit, short entry, and short exit, producing a simplified daily deduction of 4 bps. The 2 bp convention produces an 8 bp daily deduction. Under this cost model, the estimated one-way break-even cost for the 10% portfolio is 2.65 bps.
The 10% side fraction was chosen after inspecting a development sweep covering 5%, 10%, 15%, 20%, and 30%. Its portfolio figures are exploratory and carry selection bias. The repository publishes the full sweep and separately reports the unswept 20% long-short baseline:
| Cost convention | Annualized arithmetic return | Annualized volatility | Sharpe | Maximum drawdown |
|---|---|---|---|---|
| Before costs | 17.05% | 14.92% | 1.14 | -19.64% |
| 1 bp per side | 6.97% | 14.92% | 0.47 | -26.15% |
| 2 bps per side | -3.11% | 14.92% | -0.21 | -34.32% |
| 5 bps per side | -33.35% | 14.92% | -2.24 | -84.47% |
docs/EVALUATION.md contains the complete side-fraction sweep, basis-point
convention, statistical definitions, and the next-stage validation
requirements.
Three temporal folds
The repository provides fold 0, fold 1, and fold 2 checkpoints.
Fold 2 uses the latest training interval and is the inference program's default. Fold 0 and fold 1 support temporal sensitivity analysis, distribution-shift checks, and research ensembles. Each fold has its own numeric scaler and target scale.
folds/
fold0/model.safetensors
fold0/scaler.json
fold1/model.safetensors
fold1/scaler.json
fold2/model.safetensors
fold2/scaler.json
The --fold argument selects the corresponding weights and training-period
statistics.
Reproduction record
The release completed weight-level and prediction-level reproduction checks.
Each Safetensors checkpoint was compared with the eight trainable tensors in its original training artifact. Across three folds, all 24 tensors matched bit-for-bit.
Fold 2 was then evaluated on 2,048 fixed validation examples with the standalone release code. CUDA reproduction produced:
maximum absolute difference in m8_n0_score: 0
maximum absolute difference in m8_n0_prediction: 0
The second comparison includes the target-scale reconstruction.
After the Hugging Face upload, all 23 remote files were downloaded and compared with the local release. File counts, byte sizes, and SHA-256 digests matched. The downloaded inference program also completed a scoring test.
integrity.json records the path, byte size, and SHA-256 digest of every other
release artifact. The manifest covers weights, scalers, configuration, code,
examples, evaluation files, and documentation.
Installation and inference
Python 3.10 or later is recommended.
python -m venv .venv
source .venv/bin/activate
pip install -r requirements.txt
python inference.py \
--input example_input.csv \
--output example_scores.csv \
--fold 2 \
--keep-columns row_id
PowerShell:
python -m venv .venv
.\.venv\Scripts\activate
pip install -r requirements.txt
python .\inference.py `
--input .\example_input.csv `
--output .\example_scores.csv `
--fold 2 `
--keep-columns row_id
The CLI supports CSV and Parquet, CPU and CUDA selection, configurable batch size, and preservation of requested identifier columns. Output uses create-only behavior: an existing destination path triggers an error before a file is overwritten.
Repository contents
| Path | Purpose |
|---|---|
folds/fold*/model.safetensors |
Three temporal-fold checkpoints |
folds/fold*/scaler.json |
Fold-level numeric and target scaling statistics |
inference.py |
CSV/Parquet and CPU/CUDA scoring entry point |
config.json |
Architecture, field order, and defaults |
evaluation.json |
Machine-readable aggregate evaluation results |
example_input.csv |
Synthetic input example |
integrity.json |
SHA-256 and byte-size manifest |
docs/FEATURE_SCHEMA.md |
Field definitions and timing requirements |
docs/EVALUATION.md |
Validation method, portfolio sweep, and cost results |
docs/COMPLIANCE.md |
Data provenance, release scope, and licensing review |
SECURITY.md |
Local inference and input-file guidance |
CITATION.cff |
Repository citation metadata |
LICENSE and NOTICE |
License terms and source attribution |
The full release is about 114 KiB and contains three models, executable code, fold scalers, a synthetic example, evaluation records, and licensing material.
Research uses
M8 N0 supports non-commercial cross-sectional equity research, numeric-network experiments, candidate-factor comparisons, and temporal-fold sensitivity analysis. Its explicit field order, missing-value rules, scaling statistics, and event-cutoff requirements also support temporal data-pipeline reviews.
The model produces a same-day relative ranking score. Portfolio and risk systems can add a tradable universe, position sizing, industry and style exposure controls, corporate-action handling, borrow constraints, impact estimates, and deactivation rules.
The published figures come from forward temporal validation. Independent test periods and prospective paper trading provide the next measurements of signal persistence. Live-market studies can add spreads, borrow fees, participation limits, and order latency according to the target venue.
License and release scope
The repository uses CC BY-NC 4.0 for non-commercial research and education. The current license excludes commercial use. Commercial deployment, paid services, and production use for commercial advantage require separate permission from the repository rights holder, the relevant data permissions, and an independent legal review.
The release package consists of model weights, fold scalers, inference code,
aggregate metrics, a synthetic example, feature documentation, citation files,
and integrity records. docs/COMPLIANCE.md records the data and distribution
scope.
The repository records the FNSPID source, paper citation, repository citation, modification requirements, and disclaimer. Safetensors provides the weight loading format; Hugging Face CLI credentials remain in the user's local authentication store.
References:
- FNSPID dataset: https://huggingface.co/datasets/khaihernlow/fnspid
- FNSPID paper: https://arxiv.org/abs/2402.06698
- CC BY-NC 4.0: https://creativecommons.org/licenses/by-nc/4.0/
What reviewers can inspect
example_input.csv exercises the complete inference path. config.json
defines the 48-dimensional contract. evaluation.json and
portfolio_cost_sweep.json expose the reported aggregate statistics and
portfolio assumptions. The three Safetensors checkpoints support tensor-level
weight checks, and integrity.json records the byte size and SHA-256 digest of
every other release artifact.
Citation
If this model supports your research, cite this repository and the FNSPID
paper. Repository citation metadata is available in CITATION.cff.
@misc{dong2024fnspid,
title={FNSPID: A Comprehensive Financial News Dataset in Time Series},
author={Zihan Dong and Xinyu Fan and Zhiyuan Peng},
year={2024},
eprint={2402.06698},
archivePrefix={arXiv},
primaryClass={q-fin.ST}
}
Use statement
This repository is provided for research and education under CC BY-NC 4.0. Historical validation measures past samples. Future performance requires new evidence. Investment decisions, market-data rights, deployment controls, and regulatory obligations remain the user's responsibility.
- Downloads last month
- 18
Dataset used to train NeoZJX/m8-n0-numeric-equity-ranking
Paper for NeoZJX/m8-n0-numeric-equity-ranking
Evaluation results
- Mean daily Spearman IC on FNSPID-derived temporal research datasetself-reported0.021