A rule-based language for modeling protein interaction networks
Jean Krivine teaching page provides matierial to start with KaSim.
The easiest way to use KaSim is to use pre-compiled versions available in the release section on the github repository. Download the version that corresponds to your operating system (Windows, Linux or Mac OSX) and rename the downloaded file into KaSim (or KaSa). Note that on Mac OSX or Linux, it might be necessary to give executable permissions to KaSim (and KaSa). This can be done using the shell commands:
chmod u+x KaSim (and
chmod u+x KaSa).
To test whether your program does work, simply type
./KaSim \dd version on a terminal, from the directory that contains the binaries. If the version is displayed it means that the binaries are indeed compatible with your OS. Otherwise you may need to compile KaSim from the sources (see below).
Download the source code from https://github.com/Kappa-Dev/KaSim. Make sure you have a recent OCaml compiler (KaSim/KaSa~currently requires Ocaml 4.02.3 to compile) as well as
findlib and the
yojson library installed.
You can check if it is the case from a terminal window by typing
ocamlfind ocamlopt -v. If it fails or prints an outdated version number, then you need to install OCaml Native compiler and/or findlib .
ocamlfind query yojson. The answer should be a path. If it is not, install yojson using a package manager.
OCamlbuild is hosted on https://github.com/ocaml/ocamlbuild.
Once OCaml is safely installed, decompress the KaSim archive and compile it following these few steps:
At the end of these steps, there should be an executable file named KaSim in the
tar xzvf kasim.tar.gz -d Kappa cd Kappa make bin/KaSim make bin/KaSa
bindirectory of the
Kappadirectory. In order to check the compilation went fine, simply type
ocamlbuildis not in your path, you may set the variable
OCAMLBINPATHto point to the location of the compiler by doing
make OCAMLBINPATH='the\_correct\_dir' bin/KaSim.
Maybe the most valuable place to see how to compile KaSim is our continuous integration script.
Installing the packages listed in the apt section allows you to go from a fresh ubuntu installation to somewhere where KaSim compiles. The build section shows that make should be enough to get the binaries when the dependencies are there.
The graphical interface of KaSa and KaDE requires tk-dev and labltk. By default, the graphical interface is not compiled. The compilation of this interface can be toggled on by using the following command:
make USE\_TK=1 bin/KaSa (or
make USE\_TK=1 bin/KaDE).
Common compilation errors are the following:
occurs when the module tk-dev is not installed.
/usr/bin/ld: cannot find -ltk collect2: error: ld returned 1 exit status File "caml_startup", line 1: Error: Error during linking Command exited with code 2.
occurs when OCaml cannot link the labltk library. Please document the variable
File "_none_", line 1: Error: Cannot find file jpflib.cmxa Command exited with code 2.
LABLTKLIBREPin the Makefile.
To install, just download the highlighter .xml file, then go to Notepad++'s Language Menu -> DefineYourLanguage -> Import, and select the file you just downloaded.
In any case, you will need Graphviz or any graph vizualizator that understands the dot format to draw generated graphs.
A google group of Kappa users is there to handle communication between us.
Please report any issue.
You could use KaSim as an OCaml library. The detail of the API is online.
KaSim can be turned into a REST service. Here is a description of the HTTP commands.