
This guide explains what HIP-3 markets on HyperLiquid are and how to build a basic futures market making algorithm for them using Origami Tech. You will see how to structure a top-of-book quoting grid, manage inventory risk, and adapt quotes dynamically to order book conditions.
HIP-3 markets are permissionless perpetual futures deployed by external developers on HyperLiquid. Instead of relying only on centrally curated listings, HyperLiquid allows third parties to launch their own perpetual pairs, creating a constantly expanding ecosystem of experimental assets, niche narratives, and alternative volatility profiles.
For traders, this means earlier access to emerging markets, faster price discovery, and more diverse trading conditions. HIP-3 pairs often exhibit higher volatility, sharper liquidity shifts, and frequent micro swings, making them particularly suitable for automated strategies such as grid trading, market making, scalping, and structured execution.
Origami Tech integrates directly with HyperLiquid and treats HIP-3 markets as first-class instruments. You can deploy bots, grids, and formula-based strategies on HIP-3 pairs using the same workflow and infrastructure as standard perpetual markets.
This setup demonstrates how to create a simple top-of-book futures market maker using a single grid in Origami Tech. The goal is to continuously quote one bid and one ask near the best prices in the order book while actively managing inventory risk.
The configuration refreshes frequently, reacts to order book pressure, enforces hard position limits, and avoids quoting when the spread is too tight.
Below is the full grid configuration.
This grid is a fast top-of-book futures market maker. It continuously places one limit bid and one limit ask near the top of the order book, updates them frequently (≈ once per second), and actively manages risk using your current futures position. Specifically, it:
• quotes 1 bid + 1 ask at all times;
• uses L1 imbalance to tilt its reference price (microprice);
• uses your signed futures position to skew quotes and reduce inventory, and to enforce hard max position limits;
• refuses to quote when the spread is too tight.
Each cycle, the bot pulls the best prices from the futures order book:
• bid0 = best bid price
• ask0 = best ask price
From that, it computes:
• spr = ask0 - bid0 (the spread)
• mid = (bid0 + ask0) / 2 (the midpoint)
These values anchor where the bot quotes.
The bot looks at the amount available at the best bid and best ask:
• bidAmt0 = size at best bid
• askAmt0 = size at best ask
Then it computes a normalized imbalance:
imb = (bidAmt0 - askAmt0) / (bidAmt0 + askAmt0)
Interpretation:
• If imb > 0, bids are “heavier” → buy pressure is stronger
• If imb < 0, asks are “heavier” → sell pressure is stronger
Instead of quoting around the midpoint, it uses a microprice:
micro = mid + 0.5 imb spr
So:
• strong bid-side imbalance nudges the reference price up
• strong ask-side imbalance nudges it down
This helps the bot lean slightly into short-term pressure without fully becoming directional.
For futures, inventory is your position, not a base-asset wallet balance.
The grid uses:
• ps = grid().position_side (e.g., one_way, or long/short in hedge mode)
• mm = grid().margin_mode (cross/isolated)
Then it reads:
• pos_raw = position(ps, mm).quantity
Important nuance to point out:
In one_way mode, quantity is already signed: long = positive, short = negative.
So the grid defines:
• pos_signed = pos_raw when ps == 'one_way' - this works for most of the DEXes and a default position mode for centralized venues
• otherwise, it forces the hedge “short” leg to be negative
The result is a consistent internal variable:
• pos_signed > 0 means net long exposure
• pos_signed < 0 means net short exposure
The grid defines a maximum allowed inventory:
• max_pos (example: 0.05)
Then normalizes your position:
• pos_norm = pos_signed / max_pos
This gives the bot a scaled view of exposure (roughly -1 to +1 inside limits).
To avoid quoting too tightly (and getting picked off or fee-bled), it computes a quoting distance:
• tick = symbol().price_precision
• min_half = max(2*tick, 0.0002*mid)
• half = max(min_half, 0.25*spr)
What this means in practice:
• it will never quote closer than ~2 ticks (or ~0.02% of price)
• it also widens when the market spread widens
This is the core market-making risk control.
It sets a reservation (center) price:
r = micro - k_inv pos_norm spr
Intuition:
• If you’re too long, pos_norm > 0 → r shifts down
•→ bids get less aggressive, asks get more aggressive (you sell more)
• If you’re too short, pos_norm < 0 → r shifts up
•→ bids get more aggressive (you buy more to reduce short)
It proposes raw quote levels:
•raw_bid = r - half
•raw_ask = r + half
Then it clamps prices so they remain passive:
• bid must be ≤ ask0 - tick
• ask must be ≥ bid0 + tick
So the bot avoids becoming a taker by accidentally crossing the spread.
It applies a simple “edge” filter:
edge_ok = 1 if spr > 2*tick else 0
If the spread is too tight, it posts no orders. That reduces low-edge churn where fees and adverse selection dominate.
It prevents the position from growing beyond ±max_pos:
• if pos_signed >= max_pos → stop placing buys
• if pos_signed <= -max_pos → stop placing sells
So in limit conditions, it can become one-sided temporarily to reduce risk, then return to two-sided quoting once back inside limits.
Instead of a fixed contract size, it targets a consistent quote-currency value:
• order_notional_counter = 25
• execute_volume = notional / execute_price
This keeps the trade size roughly stable as the price moves.
Two timing controls give it the high-frequency feel:
• sleep_after_seconds = 1.0 → recompute/requote roughly every second
• time_between_orders = 0.2 → small delay between buy and sell placement in a cycle
Both these variables can be completely removed from the grid, then the bot will start to replace orders after every market trade. But this approach may eat the rate limit quota too fast.
The integration between the Origami Tech trading automation platform and the HyperLiquid exchange now allows users to trade on experimental perpetual markets known as HIP-3. This collaboration enables traders to apply automated strategies to a new class of assets created by third-party developers, all while using the familiar Origami Tech toolset.
Unified Access: Traders can automate strategies across standard perpetuals, spot markets, and HIP-3 markets through a single, unified interface without altering their existing infrastructure or strategic logic.
HIP-3 Market Support: HIP-3 markets are permissionless perpetual futures created by external developers on the HyperLiquid platform. This structure provides traders with early-stage access to new, potentially high-volatility assets before they are listed on major centralized exchanges. Projects deploying such markets include Trade.xyz, Ventuals, and Felix Protocol.
Web3 API Connection: The integration is powered by a new Web3-based API flow, facilitating direct interaction with the HyperLiquid ecosystem.
The HIP-3 market environment is defined by increased volatility, frequent directional moves, and diverse trading conditions. Origami Tech offers several automated strategy types that are particularly well-suited for these markets:

The recent HIP-4 proposal introduces "outcome" trading to the platform—fully collateralized contracts with a fixed price range and non-linear payouts, which are essentially prediction markets and options . The payout for a basic Call option at its expiration time T can be expressed as:
Payout = max(S_T - K, 0)
Unlike perpetual futures, HIP-4 contracts do not carry liquidation or margin leverage risks.
Take your crypto trading to the next level with our powerful automated trading terminal. Maximize profits, minimize risks, and stay ahead of the market 24/7.