A comprehensive collection of Java libraries for logical aspects of artificial intelligence and knowledge representation
Home Libraries Downloads Documentation Web Interfaces Contact

Brought to you by

Supported by


Installation of Tweety Libraries on the command line

The following step-by-step guide can be used for installing the Tweety libraries via Maven on the command line. This works for all Linux derivatives/Max OS X (the guide is given for Ubuntu Linux but works similarly for other systems).

  1. Install Maven
    $ sudo apt-get install maven
  2. Create empty Maven project
    $ mvn archetype:generate
  3. Add Tweety as dependency
    $ cd mytweetyapp
    $ nano pom.xml

    <project ...>
  4. Configure Maven for automatic dependency inclusion (recommended for beginners)
    <project ...>
  5. Write code
    $ nano src/main/java/mytweety/mytweetyapp/

    package mytweety.mytweetyapp;


    public class App{
       public static void main( String[] args ) {
          PropositionalFormula helloWorld = new Proposition("HelloWorld");
          System.out.println(helloWorld); }
  6. Compile and run
    $ mvn package
    $ java -cp target/mytweetyapp -1.0-SNAPSHOT-jar-with-dependencies.jar
       mytweety.mytweetyapp.App HelloWorld


Last updated 16.01.2018, Matthias Thimm