# Strategies with Validator Nodes - Elixir Finance

By [0xOuterGod](https://paragraph.com/@0xoutergod) · 2024-01-19

---

Given the strong interest in this category of posts, we return to the topic. Staying in the EVM environment, let's look together at **Elixir Finance** and why it might be interesting to launch a node.

But first, **_what’s Elixir Finance?_**

A Quick Introduction to Elixir Finance
--------------------------------------

![](https://storage.googleapis.com/papyrus_images/367987fdade94dd8243e5f48ee4294f0acefc169c2953247fc7cf6eb3011b70c.png)

Elixir Finance is a _Delegated-Proof-of-Stake network_ that allows to provide liquidity to orderbook DEXes. The protocol allows to provide liquidity to books by adopting a **_variation of the Avellaneda & Stoikov algorithm_**, the orderbook’s equivalent of Uniswap v2 _xy=k_ formula.

What problems are to be solved?

Market makers have 2 main issues:

*   inventory risk;
    
*   quoting an optimal bid-ask spread.
    

Elixir Finance introduces the concept of "**_reserve price_**": in a _sideways market_, the market maker sets _bids and asks at an equivalent distance from the market price_ as it functions properly without emptying inventory on either side, whereas **this does not happen in directional markets**.

So it is necessary to find a way to establish the **ideal bid/ask spread**, and Elixir Finance has developed it from what they call the "reserve price."

$$r(s,t) = s-qγσ^2(T-t)$$

**s** = current market price  
**q** = quantity base asset / units to desidered asset target  
**σ** = volatility  
**T** = closing time normalized at 1  
**t** = current time, represented as a time fraction**γ** = inventory risk parameter

This formula allows the network to determine the distance between **current inventory** and **target inventory**, _adjusting bids and asks_ appropriately, dividing liquidity on both sides of the orderbook without causing inventory imbalances should the asset price begin to have directionality.

![](https://storage.googleapis.com/papyrus_images/334df0190fb22286b4468e646b3c817896f79298741e05d1d6b0c0b11b55960f.png)

**Avellaneda & Stoikov** developed a formula that determines the _density of the orderbook_ that allows a reference price to be established, from which the optimal spread between bids and asks will then be determined.

$$δa+δb = γσ^2(T-t) + ln(1+γ/κ)$$

**δa**, **δb** = bid/ask spread  
**δa = δb** --→ symmetrical spread  
**κ** = order book liquidity parameter

Starting with the _reserve price_, the ideal market price to be used based on the target inventory set by the user is calculated, and then the optimal bid/ask spread of a pair is calculated based on the depth of the book. Only then bids and asks are placed, **thus making liquidity better distributed**.

I refer you to the [**complete paper**](https://stanford.edu/class/msande448/2018/Final/Reports/gr5.pdf) to better understand how this orderbook DEX model works.

In the Elixir Finance model, the intention is to **eliminate any element of potential gamification** in the application of the Avellaneda-Stoikov algorithm, and to do so, one does not linearly progress $$(T-t)$$ to zero, but rather **randomly generates a value between 0 and 1** via _SGX-secure enclaves_, which will then be shared to validators.

Each pair listed in the DEX will have a _different parameter_, generating enough entropy to make it more difficult to calculate future values from an input data set for both the optimal spread $$(δa, δb)$$ and the reserve price **$$r(s,t)$$.**

An additional element of randomness must be added to the timing of orders by applying so-called "flickering orders," preventing experienced market makers from playing with network orders.

### Token $ELX

**$ELX** token has already been confirmed by the team and will be used to _ensure the security and proper operation of the entire network_. All validators and all nodes will have to staking a certain amount of ELX token to keep the infrastructure up and running.

**$ELX** is the **only governance token** in the ecosystem, as well as the only tool to _control the direction of fees generated_ by the network. Those who participate in governance how network fees are generated and where they will be directed.

### Who is supporting the project?

![](https://storage.googleapis.com/papyrus_images/3ab14cff9ba8bad2a41c1dbb7488771c24fac84696cf2d6885bbb796b2779443.png)

Elixir Finance has closed a $7.5M Series A fundraising round and a $2.1M Seed Round, at a $100M valuation.

It is supported by Hack VC, FalconX, Arthur Hayes, Kucoin, Commonwealth, NGC Ventures, AngelList Venture, Bloccelerate and Chapter One, already presenting several native integrations, including:

*   **_Perpetual Protocol_** and **_Perennial_**, perpDEX on Optimism and Arbitrum, respectively;
    
*   **_SudoSwap_**, AMM NFT-to-Token Marketplace;
    
*   **_dYdX_**, **_Magpie Protocol_** and many other DeFi protocols.
    

An airdrop has not been confirmed, but it costs nothing to try to launch a node, given also the low entry barrier.

> _Don’t forget to subscribe on Mirror to stay tuned to all future articles._

[Subscribe](null)

Elixir Node Validator **\- Step-by-Step Guide**
-----------------------------------------------

To begin the procedure, you need a computer with any Linux distro installed, Ubuntu 20.04 or later will do, an SSD with +30 GB and a fast Internet connection (at least 100Mbit/s).

For those without resources capable of supporting a validator node at home, you can fall back on **VPS (Virtual Private Server)** solutions, that is, you can rent a virtual server.

There are several solutions, which I recommend below:

*   [**Contabo**](https://contabo.com/en/vps/), I recommend the **Cloud VPS S model**, with 4 vCPU Cores, 8 GB RAM, 200 GB SSD SATA3;
    
*   [**Aeza**](https://aeza.net/?ref=432182), I recommend at least the **VIEs-3** or **PARs-3** model, with 4 vCPU Cores, 8 GB RAM, 120 GB NVMe. This is a Russian VPS service and payment by credit/debit card is not possible from many Western countries, but payments in crypto (BTC, BEP20, ERC20, TRC20, DASH, LTC, XMR...) are possible.
    

After payment is made, you will receive the **IP address** to access.

![Contabo doesn't pay me in advertising them...yet. Referral link is possible? 👉🏻👈🏻](https://storage.googleapis.com/papyrus_images/ce955069c6e5becac5334e686ddec0cfb6de6ee5161fb5bb44a2ce3357a848dc.png)

Contabo doesn't pay me in advertising them...yet. Referral link is possible? 👉🏻👈🏻

If operating from Windows, download the [**PuTTy**](https://www.putty.org/) app - SSH and telnet client - and enter the IP address of the VPS. A Linux terminal screen will open for you.

Enter the **username** (usually _root_) and **password** you chose at the time of purchase. If you have done everything correctly, the following screen will appear:

![After login on PuTTy on VPS provided by Contabo](https://storage.googleapis.com/papyrus_images/de3453100b6b0dd5434f1930ffb4d9e296cbff21e1dd4bf0c7cf575bff61ca02.png)

After login on PuTTy on VPS provided by Contabo

We can start by preparing the environment and installing **docker**.

    sudo apt -y update
    sudo apt -y upgrade
    sudo apt -y install git curl build-essential screen gnupg lsb-release
    sudo apt -y autoremove
    

Create the keyrings folder and install `docker`:

    sudo mkdir -p /etc/apt/keyrings
    
    curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo gpg --dearmor -o /etc/apt/keyrings/docker.gpg
    
    echo \
      "deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.gpg] https://download.docker.com/linux/ubuntu \
      $(lsb_release -cs) stable" | sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
    
    sudo apt -y update
    sudo apt -y install docker-ce docker-ce-cli containerd.io docker-compose-plugin
    

To make sure that everything has been installed correctly, run the following command, it should return the message shown in the comment:

    sudo docker run hello-world
    
    # Hello from Docker!
    # This message shows that your installation appears to be working correctly
    

Download Elixir Finance’s `DockerFile` file via `wget` and open it in `nano`:

    wget https://files.elixir.finance/Dockerfile
    sudo nano Dockerfile
    

Let’s create a new Etherum wallet (I recommend Metamask since Elixir Finance’s dashboard is still very immature) and edit:

    ENV ADDRESS = 0xC929C76e437630761f5157aFbfAB753c74B1C3dc
    ENV PRIVATE_KEY = private_key_from_Metamask
    ENV VALIDATOR_NAME = 0xOuterGod
    

*   Paste your public address instead of `0x` in `ENV ADDRESS`;
    
*   Paste your private key instead of `0x` in `ENV PRIVATE_KEY`;
    
*   Choose what name you want to use for your validator node in `ENV VALIDATOR_NAME`.
    

Save the `.env` file as reported earlier by pressing `Ctrl + X`, `Y` and then `Enter`.  
Now launch `build` command, start the node with `screen` and run the node:

    docker build . -f Dockerfile -t elixir-validator
    screen -S elixir
    docker run -it --name ev elixir-validator
    

![Launching docker logs ev](https://storage.googleapis.com/papyrus_images/c00fdceba665bd51107e32c3717c236a9a0c646f0f057edb341f2e1f8473c9dd.png)

Launching docker logs ev

Request ETH Goerli on the [following faucet](https://goerli-faucet.pk910.de/).  
Join the Discord channel --→ [**Link**](https://discord.com/invite/elixirnetwork)

![Nyan ETH go brrr](https://storage.googleapis.com/papyrus_images/3da6b595f53ab46da0159aa494a481a088f1bc815a2b2ea84cda634dbf34ae3b.png)

Nyan ETH go brrr

Visit the Elixir Finance dashboard [at the following link](https://dashboard.elixir.finance/), connect with Metamask and claim the 1000 **$ELXR**. Stake via the “`Stake`” button and register the wallet validator with the “`Enroll`” button.

![Dashboard on Elixir Finance](https://storage.googleapis.com/papyrus_images/84c2742af451f12509e9a61fb74e45c45e3adc6f68b5c0bcbaab57a06a894c4d.png)

Dashboard on Elixir Finance

It is necessary to delegate tokens to other validators, I recommend doing that at my wallet as a way to support my work. You probably won't find it these days, but a team member has already confirmed that there will be an update soon and that the dashboard will be improved.

I'll leave you the public address of my node validator, so you can delegate your tokens to it: `0xC929C76e437630761f5157aFbfAB753c74B1C3dc`

On the dashboard **connect Twitter** and **Discord accounts** and click on "`Claim Role`," which you can confirm on Discord.

**Congratulations, you have successfully completed the installation of your node!**

![](https://storage.googleapis.com/papyrus_images/9cf755ef9966d17e14cf3a099b988f94db9e0026ca525859dcd198c0cc5cba8e.png)

To update the node, run the following commands:

    docker kill ev
    docker rm ev
    docker pull elixirprotocol/validator:testnet-2
    docker build . -f Dockerfile -t elixir-validator
    
    docker run -d --restart unless-stopped --name ev elixir-validator
    

To read the logs and make sure everything is working properly, run the command:

_If you like my work, I suggest you to subscribe and mint the entry in order to support my work. The cost is insignificant for you, but it helps me to know that you like this kind of content._

[Subscribe](null)

---

*Originally published on [0xOuterGod](https://paragraph.com/@0xoutergod/strategies-with-validator-nodes-elixir-finance)*
