moves-rwth / stormvogel

Storm for almost everyone
2 stars 0 forks source link

Added more documentation. #17

Closed YouGuessedMyName closed 1 month ago

YouGuessedMyName commented 1 month ago

I wasn't really sure what to do with state names. Don't they already kind of exist in the form of labels? I opted to delete them. What do you think? I added action labels using frozensets because they are hashable. The most important change was added documentation.

linusheck commented 1 month ago

I agree about not having state names. Frozensets are a good idea!

The point of the shorthand stuff was to create a transition without creating an object like this: https://github.com/moves-rwth/stormvogel/blob/a6968754224514783fd4e41f46fb81dcd02eabd9/examples/die.py#L9 I agree that the shorthand type is unreadable.

linusheck commented 1 month ago

Oh, there was a typo in the type. Can you change

TransitionShorthand = list[tuple[Number, State]]

to

TransitionShorthand = list[tuple[Number, State]] | list[tuple[Action, State]]

that was what that was supposed to say. Thanks :)

So you can easily add a transition like (0.5, s) or (action, s).

I should add a test about it.