1F · Methodology

Bridge Tx Pairing Methodology

How /api/cross-chain/follow/{txHash} tries to identify the destination transaction for a given bridge deposit.

Inputs

If either is missing, the endpoint returns tx_not_found. We do not synthesize candidates from address heuristics alone.

Per-bridge windows

Each bridge has a (windowSec, valueLogTol) heuristic in CrossChainAdvancedApi.BridgePairingHeuristics:

BridgeWindowvalueLog toleranceWhy
LayerZero V2 Endpoint180 s±2Deterministic relayers, fast
Stargate Router180 s±2Same as LayerZero
Wormhole Core1,800 s (30 min)±2Guardian relay typically 15–30 min
Across HubPool / SpokePool300 s±2UMA-relayer, fast
Arbitrum L1 Inbox / ERC-20 Gateway1,500 s±4Native bridge, fee deductions
Optimism L1 Standard Bridge1,500 s±4Native bridge
Base L1 Standard Bridge1,500 s±4Native bridge
Polygon ERC-20 PoS Bridge3,600 s±4Heimdall checkpoint cadence
Polygon Plasma Bridge604,800 s (7 d)±6Plasma withdrawals
(default for unknown bridges)600 s±4Conservative fallback

valueLog is the discretized base-2 log of the wei value stored on each edge. ±2 lets us tolerate small fee deductions without false-negative-ing genuine pairs.

Confidence formula

For every candidate destination edge inside the window, we score:


tier      = 40 if exact valueTier match
          else max(0, 40 - 15 * |Δ valueTier|)
value     = 40 if |Δ valueLog| ≤ tolerance
          else max(0, 40 - 8 * (|Δ valueLog| - tolerance))
time      = round(20 * (1 - latencySec / windowSec))   # immediate=20, edge=0
confidence = clamp(tier + value + time, 0, 100)

Labels:

We return the top-N by confidence (N = 5 by default), highest first. The header includes the heuristic so callers can audit.

Known limitations

Endpoint surface


GET /api/cross-chain/follow/{txHash}
  → { src: {...}, candidates: [ {confidenceScore, confidenceLabel, ...} ],
      heuristic: "...", bridgeHeuristic: { bridge, windowSec, valueLogTol },
      latencyMs }

Disclaimer

Bridge pairing is investigative-grade, not evidentiary. A high-confidence pair is a strong lead; it is not on-chain proof of a same-message hop. Use the result to direct a human investigator to the candidate destination tx, then confirm via the bridge's own message-id / receipt log.