Remix.run Logo
yumaikas 2 days ago

(Nova dev here)

Nova's execution model is a lot friendlier to implement vs Prolog, for one.

One big reason reach for Nova are when I have something -very- state-machine shaped. It is quite good at that.

I'll try to come back later with more explanations

ModernMech 2 days ago | parent | next [-]

When you say "friendlier" does that also mean "less powerful"? Prolog's execution engine is very capable, so does Nova give up some of that power in exchange for friendliness or does it somehow retain it?

yumaikas 2 days ago | parent [-]

Depends on what you mean by power, I suppose. Nova is Turing complete, so there's that.

One big difference between Nova and -most- logic languages is that "forgetting" things is a normal part of operation. Nova is also forward chaining, rather than backtracking.

The end result ends up with Nova programs being something closer to an interpreter in a lot of cases, and writing inputs for said interpreter.

So, Nova doesn't do as much on your behalf as Prolog does, deliberately trying to be easier to reason about, and to have more predictable performance characteristics.

smaudet 2 days ago | parent | prev [-]

I think the focus on the state machine may be the problem. I don't know much about prolog, or why it doesn't really enjoy more status in the programming world, but I suspect that while it is good at repesenting states, it is not very useful for writing programs...

Case in point, the pong programs. Looking at the impl, vs a <50 line js impl, this looks more like an assembly language for state, not necessarily something that makes state more visible or readily apparent...

Having a nice dialect for a (is this formally provable?) state machine is nice, but I'm not convinced founding the language from state machines is the correct approach vs merely using a fluent library e.g. https://stately.ai/docs/xstate

Not saying that I'm correct, but would be interesting to hear more of the philosophy of why Nova, vs just a simplisitic implementation of some card game rules...