The source code and dockerfile for the GSW2024 AI Lab.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
This repo is archived. You can view files and clone it, but cannot push or open issues/pull-requests.

42 lines
1.5 KiB

2 months ago
  1. // PRISM Model of a decision for a shortcut
  2. // - A hiker has to make a decision of taking a shortcut.
  3. // - On the shortcut a native can be asked for getting to the target waypoint.
  4. // - The native can lead the hiker to the goal or can give a proposal for getting to 0.9 to the target.
  5. smg
  6. player hiker
  7. [startShortcut], [startWay], [waypoint1], [waypoint2target], [waypoint2start], [target], [lost]
  8. endplayer
  9. player native
  10. [wait], [shortcutBad], [shortcutGood]
  11. endplayer
  12. // 0 bob, 1 native,
  13. global move : [0..1] init 0;
  14. global shortcut : [0..1] init 0;
  15. global target : [0..1] init 0;
  16. global lost : [0..1] init 0;
  17. label "target" = target=1;
  18. module hikerModule
  19. startpoint : [0..1] init 1;
  20. waypoints : [0..2] init 0;
  21. [startShortcut] move=0 & startpoint=1 -> (shortcut'=1) & (startpoint'=0) & (move'=1);
  22. [startWay] move=0 & startpoint=1 -> (waypoints'=1) & (startpoint'=0) & (move'=1);
  23. [waypoint1] move=0 & waypoints=1 -> (waypoints'=2) & (move'=1);
  24. [waypoint2target] move=0 & waypoints=2 -> (waypoints'=0) & (target'=1) & (move'=1);
  25. [waypoint2start] move=0 & waypoints=2 -> (waypoints'=0) & (startpoint'=1) & (move'=1);
  26. [target] move=0 & target=1 -> (move'=1);
  27. [lost] move=0 & lost=1 -> (move'=1);
  28. endmodule
  29. module nativeModule
  30. [wait] move=1 & !(shortcut=1) -> (move'=0);
  31. [shortcutBad] move=1 & shortcut=1 -> 0.9: (shortcut'=0) & (target'=1) & (move'=0) + 0.1: (shortcut'=0) & (lost'=1) & (move'=0);
  32. [shortcutGood] move=1 & shortcut=1 -> (shortcut'=0) & (target'=1) & (move'=0);
  33. endmodule