from Hacker News

Rete: JavaScript framework for visual programming and creating node editor

by thisisastopsign on 1/12/20, 3:07 AM with 59 comments

  • by neuromute on 1/12/20, 9:53 AM

    Oddly, I’ve been playing with this library just this week. I’ve also been looking at various alternatives (some of which have already been mentioned in the comments here).

    The only functionality I’m actually looking for is the ability to connect and disconnect elements using virtual cables (that flex and look good, just like those in rete). It’s for a software synth patchbay (like those used in the Reason digital audio workstation software). So, ultimately, even though this library is impressive, it isn’t quite the right fit for my project.

    If anyone can recommend an alternative that focuses purely on cabling, I’d love to hear about it!

  • by mark_l_watson on 1/12/20, 2:00 PM

    Neat looking project but maybe the naming is off because of possible confusion with Rete Networks (one of the coolest computer science algorithms and data structures to optimize expert system rules engines for efficiently handling very large numbers of production rules).
  • by sls on 1/12/20, 4:49 AM

    Apparently nothing to do with the Rete algorithm (fwiw). [1]

    [1] https://en.wikipedia.org/wiki/Rete_algorithm

  • by newcrobuzon on 1/12/20, 11:48 AM

    Looks really nice! Looking forward to playing with it a bit.

    Shameless plug: I built something similar as a part of my workflow platform for JVM (for Java and Clojure):

    https://github.com/mikub/titanoboa

    The main focus of my tool is enterprise integration and data processing, but I still love to play and experiment with the ideas of developing code directly in browser and how to visualize its execution flow. So I built a live coding / visualization also as a part of my tool. This becomes non-trivial if you apply it to languages other then js (so browser integration becomes a bit harder).

    I also think the main challenge here is the server-side part of things, especially when you make such solution distributed - i.e. how you achieve high availability and assure everything gets executed (at least) once even in case of failover, how you cater for multitenancy while achieving sufficient security/isolation between users etc. edit:spelling/formatting

  • by sansnomme on 1/12/20, 6:40 AM

  • by freeqaz on 1/12/20, 10:20 PM

    Shameless shill: We've been building a set of tools to make software development more visual, kind of like this. There are some examples on our site here, https://refinery.io

    More specifically, you still write code and you visually connect pieces of code together. Think "pipelines of transformations" in a functional programming way. Then you click "deploy" and have it all running on AWS Lambda with rich logging and other goodies.

    A lot my inspiration comes from being a former game dev who has used Scratch and UE4's Blueprint engine. I've personally found that it's difficult to get the abstraction right in a way that keeps complexity in check (as others in this thread have commented). That's why you still write code in Refinery -- you're just visually chaining microservice calls.

    Would love to hear feedback + thoughts, if anybody is interested in sharing. free at refinery.io is a good email for me. :)

  • by pbiggar on 1/12/20, 7:45 AM

    We started with trying to create something like this when we started Dark (https://darklang.com). We ultimately moved away from this style of programming, as we couldn't figure out a way to make it feel "code-y" enough for people to want to write programs in it.

    I'm super interested in what folks want to use this for?

  • by yboris on 1/12/20, 2:59 PM

    Related: Node-RED - Low-code programming for event-driven applications

    https://nodered.org/

  • by emmanueloga_ on 1/12/20, 7:29 AM

    There's also http://nodes.io/ which is in alpha release state the last thing I heard.
  • by mentos on 1/12/20, 1:58 PM

    Owner of this project should check out visual programming in Unreal Engine 4 it’s completely production ready and has shipped in many AAA titles.
  • by gardenfelder on 1/12/20, 6:25 PM

    WebbleWorld 3 is at once similar, and different: https://github.com/truemrwalker/wblwrld3 with several academic papers and a book about the concept. Professor Yuzuru Tanaka pioneered the concept of Meme Media.
  • by lovetocode on 1/12/20, 1:22 PM

    Awesome project. Reminds me of my days of using Apache NiFi. https://nifi.apache.org/
  • by goblin89 on 1/12/20, 10:37 AM

    I’d be curious if there was a node interface framework for React (Rete is Vue-oriented, which is not made obvious until you follows installation docs).
  • by dreamling on 1/14/20, 7:03 PM

    Have you tried Adafruit's make code? https://makecode.adafruit.com/ Visual programming for javascript with options to interact with their Circuit Playground hardware.

    It's from Microsoft, with flavors for Mincraft and Legostorm too, https://www.microsoft.com/en-us/makecode .

    It's, of course, not an entire ecosystem for everything, but they do a lot of visual things that may be worth evaluating. I like the colors/shapes of the code pieces, and the ability to switch between the visual code editor and the plain js.

  • by ninetax on 1/12/20, 8:59 AM

    Really cool! Is there a way to export a data representation of your graph, like in json or something? Would there be a standard for that, like some control flow representation?
  • by reggieband on 1/12/20, 9:40 PM

    I've had building something like this in the back of my mind for a while. Free idea (the reason I wanted this): use this to build an interface to crypto smart contracts (e.g. Ethereum). Payment processing seems similar to signal processing (which these node editors are good at, e.g. Max/MSP, Unity shader graph).
  • by winrid on 1/12/20, 7:45 AM

    Anyone invest their time learning something like this and have it pay off? Interested in success stories I suppose.

    (Edit - I mean something more like nodes.io)

  • by Deukhoofd on 1/12/20, 9:59 AM

    Very neat, but don't try and sell it to your Dutch consumers with a name like that.