Skip to content

AIMA4e Using IntelliJ IDEA

Ciaran O'Reilly edited this page Mar 8, 2017 · 2 revisions

Note: You will require a GitHub account for these steps to work correctly.

  • Select the menu item VCS->Checkout from Version Control->GitHub
  • In the Clone Repository dialog enter the Git Repository URL: https://github.com/aimacode/aima-java.git :

  • Hit the Clone button (you will need to wait a little bit while the repository is downloaded to your local drive).
  • When the Checkout From Version Dialog pops up press Yes:

  • In the Import Project dialog select the Import project from external model radio button and select Eclipse:

  • Hit the Next > button.
  • In the following Import Project dialog select options that suit your workspace:

  • Hit the Next > button.
  • In the following Import Project1 dialog:

    The three projects, aima-core, aima-gui, and aimax-osm should be listed and be automatically selected (you can deselect aima-all as it is not required).
  • Hit the Next > button.
  • In the final Import Project dialog ensure you have selected at minimum a version of the JDK equal or greater than 1.8:

  • Hit the Finish > button.
  • Currently, the default branch is still AIMA3e. To switch to the AIMA4e branch, from the menu go to VCS->Git->Branches... and then select origin/AIMA4e->Checkout as new local branch:


  • The core, extra, gui directories may not appear in the Project tool window. To resolve this, close (File->Close Project) and then reopen the project. Upon reopening, you should receive a notification about an unlinked Gradle project in the Event Log.

    Click the Import Gradle Project link to bring up this dialog:

    Hit OK and then the project should refresh and show folders from the AIMA4e branch.
  • A dialog to import Gradle Project data should appear. Leave everything selected (default) and hit OK:


  • At this point, if you try to build the project through Build->Build Project, you may see errors similar to the picture below:

    Apparently, IntelliJ gets confused with the build settings in the default AIMA3e branch. One way to resolve this is to configure the project through Gradle.
  • Select the menu item View->Tool Windows->Gradle which will bring up the Gradle tool window. Click on Execute Gradle Task:


  • Type build in the Gradle command line (gradle build) and then hit OK. You should see the build process execute and succeed:

    Building the project from the menu item Build->Build Project from this point onwards should also succeed.
  • You should now be able to work with the AIMA4e projects in IntelliJ. Try to run the AIMADemoApp through aima-java/gui/src/main/java/aima.gui/app/AIMADemoApp.java.