Skip to main content

Simulator

Simulator

The simulator is at the heart of the Almanak platform and offers the capability to execute simulation runs with customizable market scenario(s) and agents. The Simulator is an Agent-Based Simulation (ABS) engine; mimicking interactions between entities. A simulation may contain multiple simulation runs which involves agents interacting with each other in a pre-defined environment.

The simulation is happening in the cloud where all blockchain transactions are executed on a customized Ethereum Virtual Machine (EVM) to offer a realistic simulation accounting for the intricacies of the Ethereum blockchain.

The simulator aggregates the different components and launches the respective EVM environment to iterate over the market scenarios and let the agent(s) take actions based on their respective roles and strategies.

Almanak provides support for three types of simulations:

  1. Single Simulation
  2. Montecarlo Simulation
  3. Optimization Simulation - (coming in beta)

Single Simulation

A single simulation allows the execution of one scenario using a specific configuration within the stack. This is particularly useful for testing individual variables or scenarios that don't require different price series to be tested.

To initiate a single simulation, a pre-defined configuration is necessary. Learn more about configuration creation here. The configuration acts as the directive for the simulator, which efficiently processes the specified scenario. Conclusions can be derived from the simulation by looking into the three outputs:

  1. Metrics
  2. Logs
  3. Result
  4. Status

Metrics offer a structured logging method that supports the aggregation and analysis of over 10,000 data points, enabling detailed graphical representations of the simulation process.

Logging provides straightforward, real-time feedback and is mainly used for informational purposes rather than detailed analysis.

Result defines the outcome metrics of a simulation. Once calculated, the simulator archives the result for subsequent retrieval and review.

Status provides information about the outcome of the single simulation, indicating whether it succeeded or failed.

Montecarlo Simulation

A Montecarlo simulation expands upon the single simulation by running multiple iterations under varied conditions. This approach allows for testing a range from a few to several hundred scenarios simultaneously, each differing slightly in configuration to assess a wide spectrum of outcomes.

While replicating the same simulation may not yield diverse results, Montecarlo simulations excel in variability and flexibility, permitting precise control over the differences among each scenario.

Optimization Simulation

Optimization in the context of machine learning involves iterative model training to achieve optimal function evaluations, a crucial aspect for enhancing performance. More about this can be found here.

The simulator utilizes this optimization principle to balance parameters effectively, employing advanced algorithms to optimize and potentially perfect the simulation outputs. This feature grants extensive control over the optimization processes, fostering tailored and efficient simulations.