Weekly update on development process (Oct 16, 2023)

Fairpool
3 min readOct 16, 2023

Fairpool is a DEX for personal tokens. Create your own token & receive royalties from trading volume. Increase volume by offering dividends / selling content for your token. Subscribe to our Telegram / Twitter to get notified about updates.

Weekly progress

  • ⚒ Worked on the code actions (faster way to write code).
  • ⚒ Worked on our decision-making system.

UI for a decision-making system

Every system needs a user interface, and a decision-making system is no exception.

However, the big difference between regular systems and a decision-making system is that the data format is different: in addition to regular data, we have code.

Of course, the code can also be represented as a static data structure. However, the code should be directly editable, so it should be stored in a text format, not in a binary format.

On one hand, this makes the UI of a decision-making system more complicated. However, it is possible to design an architecture that allows the user to work with both the regular data & the code.

First, we need to examine some examples of the tasks:

  • “I want to convert the files in this directory from HEIC to JPG”: this task implies that the new files should be similar to the original files. However, it also implies that the original files should be deleted. In this case, we will lose the connection between the task result and the task source (task output and task input), because the source will be destroyed in the process. To prevent that, we can use a two-phase commit: 1) create new files while preserving the original ones 2) group the files by similarity of content, for each group sort the files by modification timestamp, remove all files except the latest one. This flow has an additional benefit of ensuring that we won’t lose user data, and the user will be able to check the conversion results before applying the destructive operation (deletion).
  • “I want to remove the files in this directory”: since the directory itself is preserved, this task can be expressed as a predicate on the length of the list of files in the directory: `dir.files.length = 0`. In other words, destructive operations may be applied safely if the task predicate doesn’t depend on the data being destroyed.

Every task can be expressed as a predicate on the current state. If the predicate returns false, the task is incomplete. If it is true, then it is complete. This switches the question from “how to reach the desired state?” to “what is the desired state?” (which is arguably more important).

A task can be completed in many ways. For example, we may remove the whole directory and create a new one, or we may just remove each file in the directory. The ideal implementation depends on the low-level details of the specific filesystem (for some filesystems, it is faster to unlink the whole directory & create a new one).

So the full task is:

  • A predicate.
  • A slice of data that produced the task (with endpoints to explore the surrounding data).
  • A list of prefilled calls that can be executed to complete the task (change the data in a way that makes the predicate return true).

An ideal UI should display exactly those three elements. In addition, the UI may allow the user to pull extra data (which may be necessary to figure out the best way to complete the task). Also, for an admin user, the UI may allow editing the code that produced the task in the first place.

We notice that in machine learning, the task generation is circumvented — the neural network receives the current state & outputs an action directly. However, at the current stage, the neural networks can’t yet solve extremely complex tasks — these still require human intervention.

Next week’s focus

  1. ⚒ Develop our decision-making system.

About Fairpool

Fairpool is a DEX for personal tokens. Create your own token & receive royalties from trading volume. Increase volume by offering dividends / selling content for your token. If you want to get notified about updates to our products, please follow our Telegram & Twitter.

Any questions? Reach out to us:

Website: fairpool.io

Telegram: @FairpoolDEX

Twitter: @FairpoolDEX

Anchor Podcasts: @FairpoolDEX

Medium: fairpool-dex.medium.com

$FAIR token: Uniswap

--

--

Fairpool

Fairpool is a DEX for personal tokens. Create your token & receive royalties from trading volume. Increase volume by offering dividends / selling content.