suspended-chord.info :: software-development :: programming-language-zoo :: jedi

jedi

The following is from the readme on github:

Overview

jedi is a small, experimental language focused on two fundamental concepts: immutable state and dataflow. jedi is not a dataflow language (such as Mana), nor is it a functional language (such as Haskell).

Rather, jedi is a representational language founded upon a few featured data types: disturbances and contemplations, which map directly to edges and states of a finite state machine model of computation, here modeled as a meditation.

Syntax example

The syntax might look a little like this:

// this is a comment
fib_machine [  // this is a meditation (a FSM)
  start -> // this is a contemplation (a state) without output (Mealy style)
    | (_,y,0) :: fn((_,y,0)) = y -> end // this is a disturbance 
                                        // (edge) with output (Mealy)
    | (x,y,z) :: fn((x,y,z)) = (y, x+y, z-1) -> start // Mealy disturbance

  end :: fn(x) = die(echo(x)) -> . // this is a contemplation with output
                                   // (Moore style).  The . denotes an end state.
] // end fib_machine

reflect --
(1,1,5) :> fib_machine // this attaches the tuple (1,1,5) to fib_machine's input
--

meditate // this starts the clock

The above would calculate the 5th number in the Fibonacci sequence.
Using the example above as a guide, a hello world example could be built as follows:

echo_machine [
  start :: fn(x) = echo(x) -> .
]

reflect --
"hello, world!" :> echo_machine
--

meditate

Simple enough, right?

Get it

You can get jedi at its official github repo: gatesphere/jedi