Arbitrage Trading
Identify executable price differences while assuming that every apparent spread may compensate for latency, liquidity, settlement, or venue risk.
Note: Agent can identify arbitrage opportunities via price comparison but cannot execute cross-exchange trades directly. Use this skill to detect and report opportunities.
Arbitrage Types
| Type |
Mechanism |
Key Cost Factor |
| Cross-Exchange |
Same asset priced differently on two venues |
Transfer fees |
| Triangular |
Three-pair cycle (BTC->ETH->USDT->BTC) |
Trading fees x3 |
| Futures-Spot |
Premium between spot and perp/futures |
Funding rate |
| DEX-CEX |
Price gap between decentralized and centralized |
Gas fees |
Profitability Check
Cross-Exchange:
- Gross P&L = executable sell proceeds − executable buy cost for the same quantity
- Net P&L = Gross P&L − fees − slippage − funding/borrow − transfer/gas − hedge and rebalancing costs
Triangular:
- Expected cross rate = Price_A / Price_B
- Actual cross rate = observed market rate
- Spread % = (Actual - Expected) / Expected x 100
Require a positive buffer above estimated costs and model error; Net Profit > 0 on stale top-of-book quotes is not sufficient.
Workflow
- Fetch synchronized executable quotes from every leg. Candle closes are a coarse screening proxy only; do not call the result actionable without bid/ask, depth, size, timestamp, and venue status.
get_candles(symbol="BTC/USD", exchange="binance", interval="5m", count=1)
get_candles(symbol="ETH/USD", exchange="binance", interval="5m", count=1)
get_candles(symbol="ETH/BTC", exchange="binance", interval="5m", count=1)
Simulate the exact path using the correct bid or ask at each leg, lot/tick rules, rounding, and available depth.
Check carry and convergence terms from the venue's contract specification, funding history, margin rules, and settlement index—not a news summary alone:
get_financial_news(topic="BTC funding rate perpetual futures premium")
Stress all costs and failures: one-leg fill, reject, latency, transfer halt, depeg, funding flip, liquidation, borrow recall, and exchange default.
Report opportunity with: pair(s), spread %, estimated fees, net profit, and time sensitivity.
Triangular Arbitrage Example
BTC/USDT: 50,000 | ETH/USDT: 2,000 | ETH/BTC: 0.041
Expected ETH/BTC: 2000/50000 = 0.040
Actual: 0.041 → ~2.5% spread (before fees)
Path: USDT → BTC → ETH → USDT
Evidence and Validation
- Treat the setup as a testable hypothesis, not a prediction. Define thresholds, entry, invalidation, and exit before evaluating outcomes.
- Calibrate on the same instrument, venue, session, and timeframe. Use closed candles and a held-out or walk-forward sample; record every variant tried.
- Include spread, fees, slippage, borrow or funding, partial fills, and latency. Reject the setup when net expectancy is not positive or depends on one narrow parameter.
- Return observed inputs, missing data, cost assumptions, entry, invalidation, exit, and a valid, watch, or no-trade status.
- Research basis: John, Li & Liu and Vidal-Tomás show that observed crypto spreads reflect liquidity, settlement, fees, and exchange-default risk—not risk-free profit.
Key Rules
- NEVER report an opportunity without deducting all fees (trading, transfer, gas, slippage)
- NEVER assume execution is instant -- note that cross-exchange opportunities decay in seconds
- Pre-funded accounts on both sides are required for cross-exchange arb; transfers kill the edge
- Use a venue-, size-, and latency-specific minimum edge; no universal spread floor is valid
- Check order book depth: thin liquidity means slippage will eat the spread
Related Skills
- funding-rate-trading -- funding rate arb (spot + perp) is a specific delta-neutral strategy
- altcoin-rotation -- cross-pair price analysis overlaps with rotation screening
1---2name: arbitrage-trading3description: Screen execution-sensitive price differences across exchanges, pairs, spot, and derivatives. Use when evaluating synchronized spreads, triangular conversion paths, or basis trades after fees, depth, settlement, counterparty, and inventory risk.4license: Apache-2.05---67# Arbitrage Trading89Identify executable price differences while assuming that every apparent spread may compensate for latency, liquidity, settlement, or venue risk.1011> **Note:** Agent can identify arbitrage opportunities via price comparison but cannot execute cross-exchange trades directly. Use this skill to detect and report opportunities.1213## Arbitrage Types1415| Type | Mechanism | Key Cost Factor |16| ---------------- | ------------------------------------------ | ----------------- |17| Cross-Exchange | Same asset priced differently on two venues | Transfer fees |18| Triangular | Three-pair cycle (BTC->ETH->USDT->BTC) | Trading fees x3 |19| Futures-Spot | Premium between spot and perp/futures | Funding rate |20| DEX-CEX | Price gap between decentralized and centralized | Gas fees |2122## Profitability Check2324**Cross-Exchange:**25- Gross P&L = executable sell proceeds − executable buy cost for the same quantity26- Net P&L = Gross P&L − fees − slippage − funding/borrow − transfer/gas − hedge and rebalancing costs2728**Triangular:**29- Expected cross rate = Price_A / Price_B30- Actual cross rate = observed market rate31- Spread % = (Actual - Expected) / Expected x 1003233Require a positive buffer above estimated costs and model error; `Net Profit > 0` on stale top-of-book quotes is not sufficient.3435## Workflow36371. **Fetch synchronized executable quotes** from every leg. Candle closes are a coarse screening proxy only; do not call the result actionable without bid/ask, depth, size, timestamp, and venue status.38```39get_candles(symbol="BTC/USD", exchange="binance", interval="5m", count=1)40get_candles(symbol="ETH/USD", exchange="binance", interval="5m", count=1)41get_candles(symbol="ETH/BTC", exchange="binance", interval="5m", count=1)42```43442. **Simulate the exact path** using the correct bid or ask at each leg, lot/tick rules, rounding, and available depth.45463. **Check carry and convergence terms** from the venue's contract specification, funding history, margin rules, and settlement index—not a news summary alone:47```48get_financial_news(topic="BTC funding rate perpetual futures premium")49```50514. **Stress all costs and failures**: one-leg fill, reject, latency, transfer halt, depeg, funding flip, liquidation, borrow recall, and exchange default.52535. **Report opportunity** with: pair(s), spread %, estimated fees, net profit, and time sensitivity.5455## Triangular Arbitrage Example5657```58BTC/USDT: 50,000 | ETH/USDT: 2,000 | ETH/BTC: 0.04159Expected ETH/BTC: 2000/50000 = 0.04060Actual: 0.041 → ~2.5% spread (before fees)61Path: USDT → BTC → ETH → USDT62```6364## Evidence and Validation6566- Treat the setup as a testable hypothesis, not a prediction. Define thresholds, entry, invalidation, and exit before evaluating outcomes.67- Calibrate on the same instrument, venue, session, and timeframe. Use closed candles and a held-out or walk-forward sample; record every variant tried.68- Include spread, fees, slippage, borrow or funding, partial fills, and latency. Reject the setup when net expectancy is not positive or depends on one narrow parameter.69- Return observed inputs, missing data, cost assumptions, entry, invalidation, exit, and a valid, watch, or no-trade status.70- Research basis: [John, Li & Liu](https://papers.ssrn.com/sol3/papers.cfm?abstract_id=4816710) and [Vidal-Tomás](https://www.sciencedirect.com/science/article/pii/S154461232401393X) show that observed crypto spreads reflect liquidity, settlement, fees, and exchange-default risk—not risk-free profit.7172## Key Rules7374- NEVER report an opportunity without deducting all fees (trading, transfer, gas, slippage)75- NEVER assume execution is instant -- note that cross-exchange opportunities decay in seconds76- Pre-funded accounts on both sides are required for cross-exchange arb; transfers kill the edge77- Use a venue-, size-, and latency-specific minimum edge; no universal spread floor is valid78- Check order book depth: thin liquidity means slippage will eat the spread7980## Related Skills8182- **funding-rate-trading** -- funding rate arb (spot + perp) is a specific delta-neutral strategy83- **altcoin-rotation** -- cross-pair price analysis overlaps with rotation screening