Search projects, hackathons, sponsors and tech

    ← All projects

    Perpetra

    AI-powered perp DEX with dark pool execution.

    Demo

    About

    The problem it solves ### Problem On-chain perpetual DEXes expose order intent before execution, turning large trades into public signals. This leads to **frontrunning**, **MEV attacks**, and unpredictable **slippage**. Traders have no privacy or control over execution. ### Solution We built an **AI-powered perpetual DEX with dark pool execution** to keep orders hidden until filled. Chainlink services handle pricing, automation, and cross-chain deposits, while **zk checkpoints** verify execution. An autonomous agent manages trade timing and risk, enabling private, high-quality perp trading. ### Links to code Chainlink Functions smart contract: [open](https://github.com/Perpetra/perpetra-protocol-contracts/blob/main/contracts/PerpetraFunctionsOpenOrders.sol#L37) and [close](https://github.com/Perpetra/perpetra-protocol-contracts/blob/main/contracts/PerpetraFunctionsClosePositions.sol#L37) positions Chainlink Functions executable code: [open](https://github.com/Perpetra/perpetra-protocol-contracts/blob/main/chainlink-functions/open-orders.js) and [close](https://github.com/Perpetra/perpetra-protocol-contracts/blob/main/chainlink-functions/close-positions.js) positions [Chanlink CCIP code](https://github.com/Perpetra/perpetra-protocol-contracts/blob/main/contracts/PerpetraDeposit.sol#L66-L172) [Chanlink Data Feeds code](https://github.com/Perpetra/perpetra-protocol-contracts/blob/main/contracts/PerpetraSafeVault.sol#L65-L69) Chainlink Functions interact with ElizaOS code: [open](https://github.com/Perpetra/perpetra-protocol-contracts/blob/main/chainlink-functions/open-orders.js#L45-L60) and [close](https://github.com/Perpetra/perpetra-protocol-contracts/blob/main/chainlink-functions/close-positions.js#L43-L63) positions [Backend code for Chainlink Function to providing open orders](https://github.com/Perpetra/perpetra-backend-service/blob/main/src/orders/orders.service.ts#L56-L76)

    How it's made

    Challenges we ran into ### Challenges I ran into Coordinating multiple Chainlink services across chains was a key challenge. Getting **Functions**, **Automation**, **Data Feeds** and **CCIP** to work reliably together — while interacting with our AI agents — required careful contract architecture and testing. Another hurdle was ensuring **private execution logic** remained off-chain while still being verifiable. We overcame this by using **zkSync** for post-trade checkpoints and minimizing on-chain data exposure. Finally, synchronizing agent decisions (via **ElizaOS**) with on-chain triggers involved edge cases around timing and gas management — solved through simulation and modular agent design.