Smart Contract Layer

The smart contract layer serves as the foundation of the Merin system, responsible for event definition, market creation, token issuance, and settlement logic.

1 Event and Market Structure

Each predictive event is defined as a standardized Market Object:

EventID → {Question, Resolution Source, Expiration, Collateral Type, Payout Structure}

  • Question: Initiated by users or the governance DAO; can be binary, range-based, or multiple-choice events.

  • Resolution Source: Bound to one or more oracle feeds.

  • Collateral Type: Supports stablecoins or native tokens as collateral assets.

  • Payout Structure: Issued in the form of “YES/NO Tokens” or “Multi-Outcome Tokens.”

All markets are created via the Merin Factory Contract module to ensure structural consistency and settlement security.


2 Automated Settlement and Verifiable Proofs

Market settlement logic is executed by the Settlement Contract:

  • Once oracles return event results, the system automatically calculates the token share ratio between winning and losing sides.

  • The zk-Verify module performs zero-knowledge verification on the oracle-submitted data hash, ensuring the data source has not been tampered with.

  • Settlement results are written into an on-chain Merkle Tree, and a ZK-SNARK proof is generated for third-party verification.

This mechanism achieves “transparent yet non-intrusive” on-chain settlement: Users can verify the correctness of results without inferring specific account positions or trading details.


3 Modular Interfaces and Cross-Chain Compatibility

The smart contracts support interaction with both EVM and non-EVM ecosystems through the Merin-Bridge SDK:

  • Natively compatible with Ethereum, Arbitrum, BNB Chain, and Solana;

  • Supports Layer2 batch settlements to reduce gas costs;

  • Can be embedded into any DApp to enable event trading functionality via the Merin SDK.

Last updated