-
Notifications
You must be signed in to change notification settings - Fork 0
LabCeGoR 2021
Lab course at the KBSG in the winter term 2021/2022, see also the KBSG website.
- Oct 13: Intro Meeting (slides)
- Oct 18: Goal Reasoning Fundamentals (slides), CLIPS Executive Implmentation (slides), CLIPS code example and CLIPS manual
- Oct 25: Simulation Setup
See instructions here: KBSG-VNC
See instructions here: Simulation-Setup
- Group 1: Anna, Jonathan, Tarek
- Group 2: Christina, Dominik
- Group 3: Alessandra, David
- Group 4: Achim, Donijor
In order to get used to working with the Clips Executive, the first task is to write an agent that visits all machines on the field.
You can use the fawkes-robotino branch common/labcegor21
as baseline.
There you can find an agent that lets the first robot drive to a base station.
The configuration for the agent can be found in fawkes-robotino/cfg/conf.d/visitall-agent.yaml
a) Get familiar with the current behavior of that agent, focus on the main components that are located in fawkes-robotino/src/clips-specs/visit-all/
b) Adapt the agent to control a robot, such that it visits all machines of your team
c) Use more than one robot to visit all machines of your team
If you completed the tasks above, provide me with a link to a corresponding buildkite build and move on to task 2.
Pull the latest revision of common/labcegor21
and the latest fawkes master
. There you find a similar structure to the one from the visitall task:
- The default agent that is started by the clips-executive is now called
rcll-labcegor21
(seefawkes-robotino/cfg/conf.d/clips-executive.yaml
) - The agent specification for that agent can be found in
fawkes-robotino/cfg/conf.d/labcegor21-agent.yaml
. - Some skeleton code can be found in
fawkes-robotino/src/clips-specs/rcll-labcegor21/
, which lets a robot drive to the cap station C-CS1 to buffer a cap. You might find thefixed-sequence.clp
helpful as it contains plans for most of the sub-tasks you need to solve. You can of course change them as you please. - The old refbox-shell is now replaced by a webfrontend (
rcll-refbox-frontend
). In order to use it, make sure to add the correct path to your.bashrc
(by adding a lineexport RCLL_REFBOX_FRONTEND_DIR=~/rcll-refbox-frontend
).
Your task is to build an agent that can produce the orders that are given by the refbox, the rules of the game can be found here. You can follow along the following milestones to achieve this:
a) Get familiar with the current behavior of that agent
b) Adapt the agent to control a robot to produce a simple product to completion
c) Collaborate with multiple robots to complete a product
d) Build multiple orders simultaneously
You have 3 different sources of information when debugging available to you:
- The running terminal sessions: Straightforward, try to keep the terminal output free from spam so you can quickly spot important messages
- The debug logs:
debug11_latest.log
contains detailed information about the last agent execution, including all rules that fired and facts that changed (except unwatched rules/facts). A fast text editor with regular expression search support is strongly recommended. For vim users i recommend https://vim.fandom.com/wiki/Searching and https://vim.fandom.com/wiki/Power_of_g - Frontends: The refbox frontend runs on
localhost:8080
, the fawkes frontend for the central agent runs on localhost:8091. Make sure the frontend is actually deployed (in thefawkes
submodule navigate tosrc/plugins/webview/frontend
and runmake deploy
if it does not show up when running the simulation). Frontends are very handy to look into the running system. Be mindful that they will not show anything once you terminated the execution. The fawkes frontend provides two especially useful views when working with the agent, the Goal graph and access to the current Clips fact list. It also supports continuous refreshes. A useful tip: Before stopping your agent, go the the fawkes frontend and open the clips fact list without continuous refresh. Once you close the agent, the list can still be accessed as it is loaded on the page (until you refresh the page or the fact list, of course).
Q: Does fact <fact>
exist in the current working memory?
A: If the agent is still running: Fawkes webview -> Clips -> search for <fact>
Else: Search in the debug log from bottom to top to find last occurrence of '' (e.g., in vim: jump to begin of file with gg
followed by a backwards search ?<fact>
)
Q: Did rule <rule>
fire?
A: Search the log for FIRE
followed later by <rule>
(e.g., in vim /FIRE.*<rule>
)
Q: A rule <rule>
fired, that i did not write, where does it come from?
A: A good starting point is your specs folder (e.g., src/clips-specs/rcll-labcegor21
). Navigate there and search the files for the rule name (e.g., using grep: grep -r "<rule>"
. If the rule is defined elsewhere, you may want to check your agent configuration in cfg/conf.d/labcegor21-agent.yaml
to see a list of loaded files. The files are specified relative to src/clips-specs/
or fawkes/src/plugins/clips-executive/clips
.