Assymetrix Launches the Deepest Independent Prediction Market Data APIs
Read more
Read more
Assymetrix Launches the Deepest Independent Prediction Market Data APIs
Read more
Read more
Wallet PnL Analytics for Prediction Markets: A Builder's Guide
Wallet PnL Analytics for Prediction Markets: A Builder's Guide
Wallet PnL Analytics for Prediction Markets: A Builder's Guide
Discover how wallet PnL analytics enhances prediction markets. Learn to compute realized profits and losses effectively with real-time data.

Wallet PnL Analytics for Prediction Markets: A Builder’s Guide
Wallet PnL analytics for prediction markets means computing trade-level, USDC-denominated realized profit and loss per ConditionId: sum of sell collateral minus sum of buy collateral, net of taker fees, matched with FIFO logic. The recommended data source is trade-level, ground-truth history rather than classifier-inferred direction. Assymetrix’s Data API supplies that history across venues, built on roughly 1.5 TB of historical trading data, making it a practical starting point for reconstruction.
TL;DR:
Accurate wallet P&L reconstruction relies on trade-level, ground-truth history across venues, with no inference needed from classifiers which perform at near random chance.
FIFO matching and consistent fee deduction at execution are essential to accurately compute realized P&L, especially when handling partial fills and multi-outcome contracts.
Establishing a reliable ingestion schema with key data points and building materialized views help produce trustworthy leaderboards and behavioral metrics.
Assymetrix’s Data API provides normalized, comprehensive trade history, resolution, and fee metadata, easing cross-venue analysis and validation efforts.
Focusing on ground-truth P&L before adding complexity ensures better alignment with actual resolution payouts and reduces common reconciliation errors.
Table of Contents
What Wallet PnL Analytics Reveals for Prediction-Market Wallets
Methodological Challenges and Best Practices for Accurate PnL Reconstruction
How to Build a Wallet PnL Leaderboard From Trade-Level, Cross-Venue Data
Integrating a Data Provider: API Checklist and What Assymetrix Supplies
Author Perspective: Priorities and Research Directions for Builders
Assymetrix Data API: Built for Wallet PnL Reconstruction
Sources
What Wallet PnL Analytics Reveals for Prediction-Market Wallets
A wallet’s trading history on Polymarket or Kalshi is not a black box the way it is in most financial markets. Every buy, sell, and resolution event lives on-chain, timestamped and denominated in USDC, which means you can reconstruct a trader’s entire performance record from raw execution data instead of inferring it from statements or broker feeds.
That transparency unlocks a specific set of metrics worth prioritizing:
Cumulative realized P&L — the running sum of closed-position profit across all resolved conditions
Win rate by category — resolution outcomes segmented by market type (politics, sports, macro events), since skill rarely transfers evenly across domains
Average position size — a proxy for conviction and risk tolerance that also flags wash-trading patterns
Entry-timing accuracy — how a wallet’s fills compare to subsequent price movement, isolating execution skill from pure forecasting
Resolution accuracy over time — whether a wallet’s hit rate is improving, decaying, or noise
Trader Skill Score — a composite that blends the above into a single ranking input
Computing these requires grouping every trade by wallet and ConditionId, summing collateral USD on both sides of the ledger, then deriving win rate and calibration statistics from the aggregated positions. Because winning shares redeem at a fixed $1.00 USDC at resolution, the payout side of the equation is deterministic. There’s no marking to a stale NAV or waiting on a custodian’s month-end statement.
On-chain wallet transparency is the real differentiator here. Traditional markets force you to infer directional intent from tick data, and standard classifiers, the tick rule and bulk-volume classification, perform close to a coin flip. Research on Polymarket’s settlement layer found classification accuracy in the range of 49.8% to 50.5% across a large sample, which is statistically indistinguishable from random guessing. Prediction markets sidestep that problem entirely: the aggressor direction is recorded in the trade itself, not reconstructed after the fact. See this Market Order Trading: A Beginner’s Guide for more on how aggressor behavior is captured in trade execution.
Methodological Challenges and Best Practices for Accurate PnL Reconstruction
Getting the math right sounds trivial until you hit partial fills, multi-outcome contracts, and fee accounting that quietly corrupts your totals. Here’s where most homegrown pipelines break.
Match trades per ConditionId, not per wallet. A wallet trading five different markets needs five independent ledgers. Aggregate outcome buys and sells by ConditionId, then compute realized P&L per condition as sell collateral minus buy collateral, which is the pattern Bitquery documents for querying Polymarket trade data directly.
Use FIFO cost basis for partial fills. When a wallet buys in three tranches and sells in two, first-in-first-out matching gives a defensible, auditable cost basis. LIFO or weighted-average methods will produce different realized figures for the exact same trade sequence, sometimes by a meaningful margin, so pick one method and apply it consistently across your entire dataset rather than switching between markets.
Deduct taker fees at execution, not at settlement. Net collateral flow should already reflect fees before it enters your aggregation layer. Double-counting fees at both entry and reconciliation is the single most common bug in first-pass P&L scripts. 4** Treat NegRisk and multi-outcome contracts as a set of correlated binary positions.** Each outcome in a NegRisk market needs its own row, but the resolution logic must recognize that only one outcome across the set can pay out, so your reconciliation step has to sum exposure across the full outcome group before declaring a wallet’s position closed.
Reconcile against redemption events. Every resolved position generates an on-chain redemption. If your computed realized P&L doesn’t match the sum of redemption payouts minus entry cost, you have a matching bug, not a data problem.
Pro Tip: Build a reconciliation test that compares your FIFO-matched realized P&L against a wallet’s raw USDC balance delta over a fixed window. If the two diverge by more than a few basis points, the gap is almost always an unmatched partial fill or a fee applied twice.
The realized P&L formula itself is straightforward once the matching logic is solid: sum of sell collateral USD minus sum of buy collateral USD, net of taker fees, computed at execution granularity rather than batched daily. Batching introduces timing drift that becomes visible only when you cross-check against redemption totals.
How to Build a Wallet PnL Leaderboard From Trade-Level, Cross-Venue Data
A leaderboard is only as trustworthy as the ingestion layer beneath it. Skipping steps here produces rankings that look plausible and fall apart the moment someone audits a top wallet.
Define your ingestion schema. Every trade record needs: wallet address, ConditionId, outcome index, collateral USD amount, timestamp, taker fee, transaction hash, and resolution status. Partition by venue and date to keep query costs manageable as row counts climb into the hundreds of millions.
Build materialized views for the three query patterns you’ll actually run. Per-wallet realized P&L by ConditionId for leaderboard scoring, daily snapshots for mark-to-market on open positions, and category-level aggregations for segmented rankings (sports vs. politics vs. macro).
Score wallets on more than raw P&L. Realized P&L over a rolling window matters, but so does ROI normalized by exposure, since a wallet risking $500 to make $5,000 is a different animal than one risking $500,000 for the same return. Layer in a calibration score, mapping predicted price against realized resolution frequency, to separate genuine forecasting skill from lucky streaks.
Apply anti-abuse filters before publishing rankings. Minimum trade counts, minimum holding periods, and wash-trade heuristics (same-wallet-cluster round-tripping) all belong in the QA layer, not as an afterthought.
Benchmark your pipeline against a known dataset. Public archives of reconciled Polymarket user trades with daily mark-to-market P&L and behavioral features give you a ground truth to validate your matching logic before trusting it at scale.
Practical filters worth encoding directly into your ranking query:
Minimum 20 resolved trades before a wallet appears on any public leaderboard
Exclusion of wallets with holding periods under 60 seconds across more than half their trades
ROI capped or flagged above a threshold that suggests a single lucky outlier bet rather than sustained skill
Cross-venue deduplication so the same beneficial owner isn’t double-counted across separate wallet addresses
Store the raw trade layer in a columnar format like Parquet for efficient scan performance, and run incremental pipelines rather than full reprocessing on every update. A leaderboard that recomputes a billion rows nightly is a leaderboard that will eventually miss its refresh window.
Integrating a Data Provider: API Checklist and What Assymetrix Supplies
Before wiring a data provider into a production pipeline, run it against a short checklist: trade-level history (not just top-of-book snapshots), ground-truth aggressor direction, ConditionId mapping across venues, resolution event feeds, fee metadata per execution, a normalized cross-venue schema, and both streaming and bulk delivery options.
Streaming vs. bulk. Real-time leaderboards need a websocket or stream endpoint; retrospective research and calibration-surface modeling are usually better served by bulk historical export, which is cheaper to query at scale.
Coverage depth matters more than breadth. A provider covering three venues shallowly is less useful than one covering Polymarket, Kalshi, and Limitless with full trade-level granularity.
Assymetrix’s Data API at data.assymetrix.com is built on roughly 1.5 terabytes of historical data spanning nearly a billion rows of trading activity, with normalized cross-venue schemas, Smart Money wallet tracking, and Trader Skill Scores exposed as first-class endpoints rather than derived client-side.
Resolution and fee metadata should arrive pre-normalized. If you’re still parsing raw contract events to figure out which outcome paid out, the provider hasn’t done its job.
Author Perspective: Priorities and Research Directions for Builders
Most teams building this get the sequencing backward. They start with skill scores and calibration surfaces before they’ve validated realized P&L against a single ConditionId. Fix the foundation first: ingest ground-truth trades, compute realized P&L with fees netted correctly, then layer in win-rate and calibration metrics once the base numbers reconcile against redemption events.
The fastest real win is a minimum-activity leaderboard ranked purely on realized P&L per condition. Everything after that, calibration surfaces, execution-quality metrics, is refinement. If you’re choosing a research benchmark, prefer ground-truth microstructure data over classifier proxies. The classifiers look fine until you check them against the actual settlement record, and then they don’t.
— Dean
Assymetrix Data API: Built for Wallet PnL Reconstruction
Reconstructing accurate wallet P&L across Polymarket, Kalshi, and Limitless from raw contract calls means building and maintaining your own ingestion, normalization, and fee-reconciliation layer, work that most quant teams would rather not repeat. Assymetrix’s Data API already does that normalization, delivering trade-level history, resolution events, and Smart Money signals in one schema instead of three separate venue integrations.

The developer guide walks through endpoint structure for pulling wallet-level trade history and resolution feeds, and the Python integration guide covers ingestion patterns for teams building pipelines in that stack. Bulk CSV export is available for teams validating a pipeline offline before committing to a streaming integration. If you’re building a leaderboard or a Trader Skill Score model, benchmark your matching logic against the Polymarket-v1 findings first, then request sample exports from the Assymetrix Data API to see how cross-venue coverage compares against a single-venue scraper you’ve already built.
FAQ
What Is Wallet PnL Analytics in Prediction Markets?
It’s the trade-level reconstruction of realized and unrealized profit and loss for a wallet address, computed per ConditionId in USDC and net of fees, rather than an inferred portfolio balance.
How Do You Calculate Realized PnL on Polymarket?
Sum the USDC collateral from sell executions, subtract the USDC collateral from buy executions, net out taker fees, and match fills using FIFO cost basis per ConditionId.
Why Do Trade Classifiers Fail on Prediction Market Data?
Standard classifiers like the tick rule perform near random, in the 49.8% to 50.5% accuracy range, because they infer direction rather than reading it from the settlement record itself.
How Does a NegRisk Contract Affect PnL Calculation?
Each outcome in a NegRisk market needs its own ledger row, but resolution logic must sum exposure across the full correlated outcome set before a position counts as closed.
What Data Do You Need to Build a Wallet PnL Leaderboard?
Wallet address, ConditionId, outcome, collateral USD per execution, timestamp, fee amount, transaction hash, and resolution status, ideally sourced from a unified cross-venue provider like the Assymetrix Data API rather than assembled from separate venue scrapers.
Wallet PnL Analytics for Prediction Markets: A Builder’s Guide
Wallet PnL analytics for prediction markets means computing trade-level, USDC-denominated realized profit and loss per ConditionId: sum of sell collateral minus sum of buy collateral, net of taker fees, matched with FIFO logic. The recommended data source is trade-level, ground-truth history rather than classifier-inferred direction. Assymetrix’s Data API supplies that history across venues, built on roughly 1.5 TB of historical trading data, making it a practical starting point for reconstruction.
TL;DR:
Accurate wallet P&L reconstruction relies on trade-level, ground-truth history across venues, with no inference needed from classifiers which perform at near random chance.
FIFO matching and consistent fee deduction at execution are essential to accurately compute realized P&L, especially when handling partial fills and multi-outcome contracts.
Establishing a reliable ingestion schema with key data points and building materialized views help produce trustworthy leaderboards and behavioral metrics.
Assymetrix’s Data API provides normalized, comprehensive trade history, resolution, and fee metadata, easing cross-venue analysis and validation efforts.
Focusing on ground-truth P&L before adding complexity ensures better alignment with actual resolution payouts and reduces common reconciliation errors.
Table of Contents
What Wallet PnL Analytics Reveals for Prediction-Market Wallets
Methodological Challenges and Best Practices for Accurate PnL Reconstruction
How to Build a Wallet PnL Leaderboard From Trade-Level, Cross-Venue Data
Integrating a Data Provider: API Checklist and What Assymetrix Supplies
Author Perspective: Priorities and Research Directions for Builders
Assymetrix Data API: Built for Wallet PnL Reconstruction
Sources
What Wallet PnL Analytics Reveals for Prediction-Market Wallets
A wallet’s trading history on Polymarket or Kalshi is not a black box the way it is in most financial markets. Every buy, sell, and resolution event lives on-chain, timestamped and denominated in USDC, which means you can reconstruct a trader’s entire performance record from raw execution data instead of inferring it from statements or broker feeds.
That transparency unlocks a specific set of metrics worth prioritizing:
Cumulative realized P&L — the running sum of closed-position profit across all resolved conditions
Win rate by category — resolution outcomes segmented by market type (politics, sports, macro events), since skill rarely transfers evenly across domains
Average position size — a proxy for conviction and risk tolerance that also flags wash-trading patterns
Entry-timing accuracy — how a wallet’s fills compare to subsequent price movement, isolating execution skill from pure forecasting
Resolution accuracy over time — whether a wallet’s hit rate is improving, decaying, or noise
Trader Skill Score — a composite that blends the above into a single ranking input
Computing these requires grouping every trade by wallet and ConditionId, summing collateral USD on both sides of the ledger, then deriving win rate and calibration statistics from the aggregated positions. Because winning shares redeem at a fixed $1.00 USDC at resolution, the payout side of the equation is deterministic. There’s no marking to a stale NAV or waiting on a custodian’s month-end statement.
On-chain wallet transparency is the real differentiator here. Traditional markets force you to infer directional intent from tick data, and standard classifiers, the tick rule and bulk-volume classification, perform close to a coin flip. Research on Polymarket’s settlement layer found classification accuracy in the range of 49.8% to 50.5% across a large sample, which is statistically indistinguishable from random guessing. Prediction markets sidestep that problem entirely: the aggressor direction is recorded in the trade itself, not reconstructed after the fact. See this Market Order Trading: A Beginner’s Guide for more on how aggressor behavior is captured in trade execution.
Methodological Challenges and Best Practices for Accurate PnL Reconstruction
Getting the math right sounds trivial until you hit partial fills, multi-outcome contracts, and fee accounting that quietly corrupts your totals. Here’s where most homegrown pipelines break.
Match trades per ConditionId, not per wallet. A wallet trading five different markets needs five independent ledgers. Aggregate outcome buys and sells by ConditionId, then compute realized P&L per condition as sell collateral minus buy collateral, which is the pattern Bitquery documents for querying Polymarket trade data directly.
Use FIFO cost basis for partial fills. When a wallet buys in three tranches and sells in two, first-in-first-out matching gives a defensible, auditable cost basis. LIFO or weighted-average methods will produce different realized figures for the exact same trade sequence, sometimes by a meaningful margin, so pick one method and apply it consistently across your entire dataset rather than switching between markets.
Deduct taker fees at execution, not at settlement. Net collateral flow should already reflect fees before it enters your aggregation layer. Double-counting fees at both entry and reconciliation is the single most common bug in first-pass P&L scripts. 4** Treat NegRisk and multi-outcome contracts as a set of correlated binary positions.** Each outcome in a NegRisk market needs its own row, but the resolution logic must recognize that only one outcome across the set can pay out, so your reconciliation step has to sum exposure across the full outcome group before declaring a wallet’s position closed.
Reconcile against redemption events. Every resolved position generates an on-chain redemption. If your computed realized P&L doesn’t match the sum of redemption payouts minus entry cost, you have a matching bug, not a data problem.
Pro Tip: Build a reconciliation test that compares your FIFO-matched realized P&L against a wallet’s raw USDC balance delta over a fixed window. If the two diverge by more than a few basis points, the gap is almost always an unmatched partial fill or a fee applied twice.
The realized P&L formula itself is straightforward once the matching logic is solid: sum of sell collateral USD minus sum of buy collateral USD, net of taker fees, computed at execution granularity rather than batched daily. Batching introduces timing drift that becomes visible only when you cross-check against redemption totals.
How to Build a Wallet PnL Leaderboard From Trade-Level, Cross-Venue Data
A leaderboard is only as trustworthy as the ingestion layer beneath it. Skipping steps here produces rankings that look plausible and fall apart the moment someone audits a top wallet.
Define your ingestion schema. Every trade record needs: wallet address, ConditionId, outcome index, collateral USD amount, timestamp, taker fee, transaction hash, and resolution status. Partition by venue and date to keep query costs manageable as row counts climb into the hundreds of millions.
Build materialized views for the three query patterns you’ll actually run. Per-wallet realized P&L by ConditionId for leaderboard scoring, daily snapshots for mark-to-market on open positions, and category-level aggregations for segmented rankings (sports vs. politics vs. macro).
Score wallets on more than raw P&L. Realized P&L over a rolling window matters, but so does ROI normalized by exposure, since a wallet risking $500 to make $5,000 is a different animal than one risking $500,000 for the same return. Layer in a calibration score, mapping predicted price against realized resolution frequency, to separate genuine forecasting skill from lucky streaks.
Apply anti-abuse filters before publishing rankings. Minimum trade counts, minimum holding periods, and wash-trade heuristics (same-wallet-cluster round-tripping) all belong in the QA layer, not as an afterthought.
Benchmark your pipeline against a known dataset. Public archives of reconciled Polymarket user trades with daily mark-to-market P&L and behavioral features give you a ground truth to validate your matching logic before trusting it at scale.
Practical filters worth encoding directly into your ranking query:
Minimum 20 resolved trades before a wallet appears on any public leaderboard
Exclusion of wallets with holding periods under 60 seconds across more than half their trades
ROI capped or flagged above a threshold that suggests a single lucky outlier bet rather than sustained skill
Cross-venue deduplication so the same beneficial owner isn’t double-counted across separate wallet addresses
Store the raw trade layer in a columnar format like Parquet for efficient scan performance, and run incremental pipelines rather than full reprocessing on every update. A leaderboard that recomputes a billion rows nightly is a leaderboard that will eventually miss its refresh window.
Integrating a Data Provider: API Checklist and What Assymetrix Supplies
Before wiring a data provider into a production pipeline, run it against a short checklist: trade-level history (not just top-of-book snapshots), ground-truth aggressor direction, ConditionId mapping across venues, resolution event feeds, fee metadata per execution, a normalized cross-venue schema, and both streaming and bulk delivery options.
Streaming vs. bulk. Real-time leaderboards need a websocket or stream endpoint; retrospective research and calibration-surface modeling are usually better served by bulk historical export, which is cheaper to query at scale.
Coverage depth matters more than breadth. A provider covering three venues shallowly is less useful than one covering Polymarket, Kalshi, and Limitless with full trade-level granularity.
Assymetrix’s Data API at data.assymetrix.com is built on roughly 1.5 terabytes of historical data spanning nearly a billion rows of trading activity, with normalized cross-venue schemas, Smart Money wallet tracking, and Trader Skill Scores exposed as first-class endpoints rather than derived client-side.
Resolution and fee metadata should arrive pre-normalized. If you’re still parsing raw contract events to figure out which outcome paid out, the provider hasn’t done its job.
Author Perspective: Priorities and Research Directions for Builders
Most teams building this get the sequencing backward. They start with skill scores and calibration surfaces before they’ve validated realized P&L against a single ConditionId. Fix the foundation first: ingest ground-truth trades, compute realized P&L with fees netted correctly, then layer in win-rate and calibration metrics once the base numbers reconcile against redemption events.
The fastest real win is a minimum-activity leaderboard ranked purely on realized P&L per condition. Everything after that, calibration surfaces, execution-quality metrics, is refinement. If you’re choosing a research benchmark, prefer ground-truth microstructure data over classifier proxies. The classifiers look fine until you check them against the actual settlement record, and then they don’t.
— Dean
Assymetrix Data API: Built for Wallet PnL Reconstruction
Reconstructing accurate wallet P&L across Polymarket, Kalshi, and Limitless from raw contract calls means building and maintaining your own ingestion, normalization, and fee-reconciliation layer, work that most quant teams would rather not repeat. Assymetrix’s Data API already does that normalization, delivering trade-level history, resolution events, and Smart Money signals in one schema instead of three separate venue integrations.

The developer guide walks through endpoint structure for pulling wallet-level trade history and resolution feeds, and the Python integration guide covers ingestion patterns for teams building pipelines in that stack. Bulk CSV export is available for teams validating a pipeline offline before committing to a streaming integration. If you’re building a leaderboard or a Trader Skill Score model, benchmark your matching logic against the Polymarket-v1 findings first, then request sample exports from the Assymetrix Data API to see how cross-venue coverage compares against a single-venue scraper you’ve already built.
FAQ
What Is Wallet PnL Analytics in Prediction Markets?
It’s the trade-level reconstruction of realized and unrealized profit and loss for a wallet address, computed per ConditionId in USDC and net of fees, rather than an inferred portfolio balance.
How Do You Calculate Realized PnL on Polymarket?
Sum the USDC collateral from sell executions, subtract the USDC collateral from buy executions, net out taker fees, and match fills using FIFO cost basis per ConditionId.
Why Do Trade Classifiers Fail on Prediction Market Data?
Standard classifiers like the tick rule perform near random, in the 49.8% to 50.5% accuracy range, because they infer direction rather than reading it from the settlement record itself.
How Does a NegRisk Contract Affect PnL Calculation?
Each outcome in a NegRisk market needs its own ledger row, but resolution logic must sum exposure across the full correlated outcome set before a position counts as closed.
What Data Do You Need to Build a Wallet PnL Leaderboard?
Wallet address, ConditionId, outcome, collateral USD per execution, timestamp, fee amount, transaction hash, and resolution status, ideally sourced from a unified cross-venue provider like the Assymetrix Data API rather than assembled from separate venue scrapers.
Other Blog



