Projog is an implementation of the Prolog logic programming language for the Java platform. The open source Projog library can be used to integrate Java and Prolog.
- What is Projog?
- What is Prolog?
- What are logic programming languages?
- What is Java?
- Why Projog?
- What open source license does Projog use?
- How can I get started with Projog?
- Where can I find examples of using Projog?
- Where can I learn more about the design of Projog?
- What are the future plans for Projog?
- Where can I learn more about Prolog?
- Where can I learn more about Java?
- How can I raise a bug or request a new feature?
What is Projog?
What is Prolog?
Prolog is a logic programming language. Prolog's main use has been in areas of Artificial Intelligence (AI), including Expert Systems and Natural Language Processing (NLP).
What are logic programming languages?
Logic programming languages differ from more conventional programming languages. Logic programs describe facts and relationships about a problem, rather than describing the sequence of steps required to solve the problem.
What is Java?
Java is a general purpose object-oriented programming language. Java has been used to develop a wide range of software applications. Java applications are compiled to bytecode that can run on any Java Virtual Machine (JVM). The JVM is the core component of the "Java Platform".
Why Projog?
Projog allows Java developers to take advantage of the logic programming features of Prolog alongside their existing object-oriented Java codebase. (See Using Prolog in Java Applications.)
Projog allows Prolog developers to benefit from the strengths of the Java platform, including:
- Stable, multi-threaded, freely available virtual machines for most major operating systems, including Windows, Linux and OS X.
- A vast collection of libraries that can be used to extend the functionality of Prolog. (See Adding Extra Functionality to Prolog Using Java.)
- Opportunity to make Prolog logic available via a graphical user interface or web based frontend.
What open source license does Projog use?
Projog uses the Apache License, Version 2.0. You may obtain a copy of the License at: http://apache.org/licenses/LICENSE-2.0
How can I get started with Projog?
See the getting started section of the manual.
Where can I find examples of using Projog?
The following GitHub projects provide examples of how Projog can be used to construct applications that combine Java and Prolog:
- Projog Examples - simple examples of how the Projog library can be used to integrate Java and Prolog.
- Prolog Expert System - expert system with rules written in Prolog and UI written in Java.
- Prolog Wumpus World - wumpus world simulator using Prolog for agent logic and Java for UI.
Where can I learn more about the design of Projog?
This website contains class diagrams and a description of the design decisions made in the development of this project. The source code is available to browse on GitHub.
What are the future plans for Projog?
Ongoing tasks include:
- Adding more examples - including some larger programs.
- Working towards ISO compatibility.
- Bug fixing in response to any new issues being raised.
- Continuing to improve performance.
- Improving the constraint logic programming functionality.
Where can I learn more about Prolog?
A good starting point for learning about Prolog is Projog's own manual containing Prolog code examples.
The following sites contain introductory courses about Prolog programming:
The following sites contain problems that you can try to solve using Prolog (example solutions are also provided):
I Don't Know Prolog, and so Can You is a presentation by Corey Haines which provides an introduction to Prolog. Markus Triska's The Power of Prolog YouTube channel contains a collection of videos about Prolog.
Prolog is one of the languages mentioned in Bruce A. Tate, Seven Languages in Seven Weeks: A Pragmatic Guide to Learning Programming Languages, Pragmatic Bookshelf, 1st ed., Published: 2010, ISBN: 978-1-93435-659-3
. A sample extract from the chapter dedicated to Prolog can be downloaded from The Pragmatic Bookshelf.
A book that provides a good introduction to Prolog is: William F. Clocksin and Christopher S. Mellish, Programming in Prolog: Using the ISO Standard. Springer, 5th ed., Published: 2003, ISBN: 978-3-540-00678-7
Where can I learn more about Java?
There are lots of websites and books about Java. A good place to start is The Java Tutorials.
How can I raise a bug or request a new feature?
We would be grateful for any feedback. If you would like to report a bug, suggest an enhancement or ask a question then please create a new issue.