LogicLab is a sandbox playground environment for compiling manifests into logics, simulating logic calls and participant interactions with logics on MOI. It has capabilities to handle basic argument parsing and is agnostic to engine runtime implementations but currently only supports PISA
.
LogicLab comes bundled with your Cocolang installation
It works on a REPL and runs within an environment that has persistent information for config, context states and compiled logics. This environment is a directory that needs to be initialised with the logiclab init
command. Every time the REPL starts, it starts within a specified environment. You may have multiple environments side-by-side.
View the LogicLab Version
The command logiclab docs
will generate a detailed LogicLab Command Documentation, offering insights into the various functionalities of LogicLab. if you're actively using a LogicLab session, you can access the documentation directly by entering the 'help' command.
- In CLI
logiclab version
Running LogicLab Formulas
logiclab run
will execute a LogicLab formula within the designated environment. The path to the script file should be provided as an argument. Ensure that the target environment directory already exists and includes an inventory.json file. The directory to custom environment can be mentioned using the —env
flag. If no env path is specified, it will use ./logiclab
as the target environment directory.
The --suppress
flag will just print the output of the last command of the script.
- Syntax
logiclab run [labscript] [flags]
- Example
logiclab run ./flipper/labscript
// Prints the output of each command in the script
Exit LogicLab REPL
>> exit