Top-level Files of trunk
Not logged in

Files in the top-level directory from the latest check-in of branch trunk


Orderbookkit

Orderbookkit is a permissionless Stylus-based RFQ and CLOB hybrid.

Roadmap

orderbookkit

orderbookkit is a contract that implements the on-chain orderbook and RFQ sliplane. It can use risc-runner to run smat contracts from its application space using risc-runner's feature system and delegatecall to simultaneously provide the application with the book without extensive copying, but without violating constraints (for example, writing to storage without restrictions). This functions similarly to a seccomp/pledge jail type of situation of opting into the features the code call supports.

This application is left outside of the workspace thanks to alloy-primitives bringing in std with const-hex.

risc-loader

risc-loader is a contract that decodes transaction input data, verifies the supplied data, and creates a new implementation contract of the code given with a 0xaf magic byte to prevent execution under normal circumstances. Contracts are unpacked from lzss compression at this stage.

risc-runner

risc-runner is a contract that runs the RISC-V 32IM contracts. Features are enabled by passing them as an argument to the runner in the form of a u16 word. These can gate storage access, orderbook lookup, and more.

libguest

libguest is a library with a collection of helpers and calls for executing code inside Orderbookkit using the risc-v engine.

competition

competition is a proof of work algorithm that generates market making algorithms that "win" a specific trading "scenario" by permuting a reference existing program (the "seed") using "signals" given to it and having a certain amount of orders filled.

User journey

Onramping

sequenceDiagram
    Visits site --> Clicks deploy: Deploy button should be in the center of the page.
    Clicks deploy --> Asks to fund address: Asks to fund address, and for RPC.
    Asks to fund address --> Does deployment: Shows dashboard for theming and assets.
    Does deployment --> Dashboard: Shows users to the dashboard.

Product details

Infrastructure story

Infrastructure BOM

direction: down

frontend: {
  nextjs
  zustand
}

infrastructure: {
  postgres "For database"
  tarsnap "For backing up"
  geodns "For IP load balancing at the DNS level"
  ansible "For configuring our servers"
  framer "For landing page"
  raspberry pi: {
    fossil "Wiki subdomain hosted on a Raspberry Pi"
  }
  applicationserver: {
    go: {
      gqlgen "For servicing a graph. Also caches and does websocket"
      pprof
      net/http
    }
  }
  intercom "Live chat feature"
  birdie "For recording issues"
  betterstack "For reporting isuses"
  sentry "For frontend reporting issues"
  cron: {
    update fossil
    check for ansible
  }
}

datacenters: {
  yourdcau "Adelaide"
}

payment: {
  stripe
}