mal-lang / mal-simulator

Apache License 2.0
2 stars 1 forks source link

Streamline observations and define terms and scope #14

Open nkakouros opened 6 months ago

nkakouros commented 6 months ago

After each simulation step, the first item returned is the observations. A single observation currently contains the following keys:

dict_keys(['is_observable', 'observed_state', 'remaining_ttc', 'asset_type', 'asset_id', 'step_name', 'edges'])

I suggest we do the following:

kasanari commented 6 months ago
kasanari commented 6 months ago

For example: I am considering doing some offline RL. Then I would save a 'dataset' of observations that can then be used to train in a supervised manner. If the observations contains all the required info, then I can just save a list of observations in a text file and train on it without even importing the mal-toolbox.

andrewbwm commented 6 months ago

I categorically agree with everything you've said. I just require a clarification on one point.

* Cache these lists. Since we do not do DynaMAL, we could have these lists be properties of the attack graph that are set during graph generation. If in the future we want dynamic stuff and we need to dynamically generate these lists again, we can easily do it in python with `@property`.

What do you mean by this? Just adding the cache hint like we have for the observation space? Because the list is not regenerated, but I think you know this already.

nkakouros commented 4 months ago

What do you mean by this? Just adding the cache hint like we have for the observation space? Because the list is not regenerated, but I think you know this already.

I am not sure I remember. But given that these are already cached, moving these lists to the attack graph is the still relevant part of that comment of mine.