Funding arbitrage
HyperliquidMarket-neutralPerpetuals (leverage/short)Lower riskcapture perp funding while hedged spot/perp — market-neutral carry
Track record
Return
+3.0%
Sharpe
2.38
Max DD
0.6%
AUM
$0
Created
2026-07-06
Investors
0
Pools
0
Settled days
0
Market fit
Market-neutralNo directional bet — harvests spreads and funding- ✓Runs in any market; steadier but smaller returns
- ⚠Spreads and funding can blow out in extreme conditions
Backtest (deterministic simulator)
Parameters: hedge_ratio / funding_floor / sizeBacktest curve is an example on a deterministic simulated price path — not real returns.
Core source
Source on GitHub ↗"""资金费套利(Funding-rate arbitrage / carry)—— 对冲收永续资金费。
思路:永续资金费为正(多头付费)且超过阈值时,空永续 + 多现货代理腿,净 delta ≈ 0,权益随资金费
结算稳定累积;费率转负则镜像操作(多永续 + 空现货腿)。费率回到阈值内(带迟滞)平掉双腿。这是
市场中性 carry 的标准形态(Hyperliquid 官方文档及各开源框架均有描述;此处为独立重写)。
参数:hedge_ratio(对冲腿比例)、funding_floor(费率阈值)、size(永续腿数量)。
降级行为:feed 未提供配对(现货)行情、或连接器不支持做空时保持空仓——本策略的收益来源是对冲后
的费率,拒绝退化成裸方向敞口。实盘单一 venue 需场馆支持现货腿或由操盘手在外部对冲。
"""
from __future__ import annotations
from ..base import StrategyBase
from ..context import StrategyContext
from ..registry import register
@register("资金费套利")
class FundingArb(StrategyBase):
description = "费率超阈值时空永续+多现货对冲收资金费;市场中性 carry。"
params = {"hedge_ratio": 1.0, "funding_floor": 0.00005, "size": 4.0}
def __init__(self, hedge_ratio: float = 1.0, funding_floor: float = 0.00005, size: float = 4.0) -> None:
self.hedge_ratio = float(hedge_ratio)
self.funding_floor = float(funding_floor)
self.size = float(size)
async def on_tick(self, ctx: StrategyContext) -> None:
sym = ctx.conn_symbol()
pair = ctx.pair_symbol()
if pair is None or not getattr(ctx.conn, "allow_short", False):
return # 无法构成对冲:保持空仓
rate = await ctx.funding(sym)
band = self.size * 0.1
hedge = self.size * self.hedge_ratio
if rate > self.funding_floor:
await ctx.target(sym, -self.size, band=band) # 空永续收正费率
await ctx.target(pair, hedge, band=band) # 多现货对冲
elif rate < -self.funding_floor:
await ctx.target(sym, self.size, band=band) # 多永续收负费率
await ctx.target(pair, -hedge, band=band)
elif abs(rate) < self.funding_floor * 0.5: # 迟滞退出,避免阈值附近来回换仓
await ctx.target(sym, 0.0, band=band)
await ctx.target(pair, 0.0, band=band)
The full SDK and all strategies are MIT-licensed open source — backtest, paper-trade, or fork them directly.
Pools running this strategy
No pools are running this strategy yet — be the first to launch one.