RizeLabs / bfv-clob

CLOB implementation in BFV

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Private CLOB

Implementation of simple matching algorithm which can find match for encrypted orders. Algorithm proposed in this paper. This matching algorithms is implemented with bfv fully homomorphic encryption algorithm to facilitate order matching for encrypted orders. We used bfv and operator library by Janmajayamall

πŸ§‘β€πŸ’» Usage

  1. Define buy and sell orders here
  2. Build project by running cargo build in bfv, caird/operators and private-clob directories. As the algorithm uses bfv and operators library and apis.
  3. Run the matching algorithm using cargo run in private-clob directory. For your convenience some sample orders has been already defined in order.json.

πŸ“ Interpretation

On successfull execution of the algorithm you'll see two arrays buy and sell array. In which non-zero element conveys order settlement and zero element indicates that the order can't be fullfilled.

About

CLOB implementation in BFV


Languages

Language:Rust 100.0%