Faish logo. It should really have 'Squl' on it instead, I guess?


The Declarative Programming Language

What is Squl?

Squl is a declarative programming language, like Prolog.

A Squl application consists of modules containing statements. Each statement states some logical thought about the world. Statements look like this:

father:arnold of:bob.

father:bob of:charles.

then:( grandfather:X of:Z )
	if:( father:X of:Y )
	if:( father:Y of:Z ).

Here, we declare three bits of information. Firstly, arnold is the father of bob. Secondly, bob is the father of charles. Thirdly, somebody's father's father is their grandfather.

Note: don't get too attached to the syntax. It will change radically in version 0.4.

Running Faish

Squl is the language. Faish is a prototype Squl interpreter, written using VisualWorks Smalltalk.

Download the file "Faish_0.3.zip" and extract the contents to a suitable location.

Unzip the zip file to, for example, "C:\Faish\", and double-click on "Faish.exe".
Unzip the zip file somewhere, for example, "~/faish/" and double-click on "faish.sh", or in a console window, run "faish faish.im".
Download Cincom VisualWorks Smalltalk from http://www.cincomsmalltalk.com/ for your platform, locate the bin/visual executable for your platform and follow Cincom's documentation to run the faish.im image. Alternatively, check out the source code and see the instructions in readme.txt

Using Faish

When started, you should get a "Your Modules" window. Click on "New", choose a nice name, then double-click on the resulting module to open a module editing window.

In the "module editing window", you will see three panes. The left pane shows your statements. The right pane shows your queries. The bottom pane is where you edit whatever you just clicked on.

Type "CTRL+n" to create a new statement. Enter the text "father:alfred of:bob." (remember the full-stop at the end!) and press CTRL-Enter.

Now enter the text "father:X of:Y?" (remember the question-mark!) and press CTRL-Enter.

To save your work, either export your module to a file or repository, or "Commit" the image (which will save all modules and windows in faish.im).

Now go read the documentation.

Differences from Prolog


Faish is released under the MIT license. If you do anything cool with it, let me know on the mailing list! If you make bucketloads of money with it, feel free to send some my way.

Sourceforge project page