Zeitgeist Save

An evolving blockchain for prediction markets and futarchy.

Project README

Zeitgeist: An Evolving Blockchain for Prediction Markets and Futarchy

Rust Codecov Discord Telegram X

Zeitgeist is a decentralized network for creating, betting on, and resolving prediction markets, allowing traders to create complex financial contracts on virtually anything. The platform's native currency ZTG is used to sway the direction of the network, and as a means of last-call dispute resolution in the decentralized court.

Modules

  • asset-router - Routes all asset classes to the respective pallets and provides a garbage collection for destructible assets.
  • authorized - Offers authorized resolution of disputes.
  • court - An implementation of a court mechanism used to resolve disputes in a decentralized fashion.
  • global-disputes - Global disputes sets one out of multiple outcomes with the most locked ZTG tokens as the canonical outcome. This is the default process if a dispute mechanism fails to resolve.
  • macros - Contains macros shared by the other modules.
  • market-commons - Contains common operations on markets that are used by multiple pallets.
  • neo-swaps - An implementation of the Logarithmic Market Scoring Rule as constant function market maker, tailor-made for decentralized combinatorial markets and futarchy.
  • orderbook - An order book implementation.
  • parimutuel - A straightforward parimutuel market maker for categorical markets.
  • prediction-markets - The core implementation of the prediction market logic for creating and resolving markets.
  • swaps - An implementation of the Balancer CFMM that allows any user to create pools, provide liquidity or swap assets.
  • primitives - Contains custom and common types, traits and constants.
  • rikiddo - The module contains a completely modular implementation of our novel market maker Rikiddo. It also offers a pallet that other pallets can use to utilize the Rikiddo market maker. Rikiddo can be used by the automated market maker to determine swap prices.

How to Build and Run a Zeitgeist Node

Zeitgeist node comes in two flavors, one for standalone self-contained execution and another for Kusama/Polkadot parachain integration.

To build the standalone version for testing, simply point to the top directory of this project and type:

cargo build --release

The standalone version uses the runtime defined for Zeitgeist's testnet Battery Station in runtimes/battery-station and is run in --dev mode by default.

To build the parachain version, execute the following command:

cargo build --features parachain --release

By default, the parachain version will connect to the Zeitgeist main network, which launched as a parachain of Kusama and has since been migrated to Polkadot. The runtime of the main network is defined in runtimes/zeitgeist.

To connect to Zeitgeist's testnet Battery Station, which runs as a parachain of Rococo, run:

cargo run --features parachain --release -- --chain=battery-station

Optimized binaries (--release) are usually used for production (faster and smaller), but this behavior is optional and up to you.

Using Docker

We publish the latest standalone and parachain version to the Docker Hub, from where it can be pulled and ran locally to connect to the network with relatively low effort and high compatibility. In order to fetch the latest docker image, ensure you have Docker installed locally, then type (or paste) the following commands in your terminal.

For parachain Zeitgeist node:

docker pull zeitgeistpm/zeitgeist-node-parachain

For standalone, non-parachain Zeitgeist node:

docker pull zeitgeistpm/zeitgeist-node

To connect your Zeitgeist parachain node using Docker, follow the tutorial at our documentation site.

Alternatively you can run a non-parachain node, which is usually only necessary for testing purposes, by executing the following command:

docker run zeitgeistpm/zeitgeist-node -- <node-options-and-flags>
Open Source Agenda is not affiliated with "Zeitgeist" Project. README Source: zeitgeistpm/zeitgeist
Stars
168
Open Issues
98
Last Commit
1 day ago
License

Open Source Agenda Badge

Open Source Agenda Rating