News for hackers. Stuff that matters.
Re:Pipes: A spiritual successor to Yahoo Pipes by wild_egg on Sunday June 30, 2024 @11:55PM (#40842398)
Anyone know of an example of any other style? Would love to see any half-baked experiments even.

Seems like a space that could really use some innovation

Re:Pipes: A spiritual successor to Yahoo Pipes by __MatrixMan__ on Monday July 01, 2024 @12:05AM (#40842443)
I don't have any code for this, but I always thought it would be better if the boxes represented data types and the arrows represented functions.

Then you could use the arrow as a progress bar, and you'd have something that's a bit more focused on the inputs and outputs.

Also, the data types could show up as a stack of boxes (like a deck of cards) so you can see when you've calculated a novel dataset (highlight new card on top the deck) or when you've recalculated a previous dataset (highlight the nth card).

Such a view would resemble a commutative diagram (from category theory) and if you let the cards pile up for a while you could use their sizes to reason about which functions are bijective, which are good candidates for memorization, etc.

When you want to know why a certain datum is the way it is, you can use the same view to trace it back to it's inputs (in the boxes-as-tasks mode, you end up zooming in on some imperative artifact... logs usually... And discerning the inputs is left as an exercise to the reader). I think this goes by the buzzword "data lineage" and it's usually this extra thing but I think it should be the main thing. Which is why I want to make the nodes into edges and the edges into nodes.

Re:Pipes: A spiritual successor to Yahoo Pipes by andyferris on Monday July 01, 2024 @01:54AM (#40842926)
This is interesting.

How do you visually identify a function with multiple inputs and outputs? I tend to imagine it as a bi-graph - with boxes for values and for functions, and arrows in between. The stack idea is interesting and can work here too.

I could get behind saying "all functions have exactly one input value and one output value" but you really need to be able to construct and deconstruct structs/records/tuples to be able to e.g. pass two values to one function.

Re:Pipes: A spiritual successor to Yahoo Pipes by __MatrixMan__ on Monday July 01, 2024 @10:51AM (#40846341)
Ah, yeah, you caught me. It's not so simple as a transform from nodes to edges. What I actually have in mind is a bit stranger, but the node/edge swap was my stepping stone towards it, which is why I mentioned it.

The structs/records/tuples approach would work (I think this would correspond with "currying"), but I have this weird idea that certain types of reasoning have a "shape" and that we might be able to more heavily lean on analagous reasoning if we could easily show that shape in correspondence with explanations of our reasoning. I worry that currying everything would force us further away from the "natural" shape (if there even is such a thing).

I've been working on something called plibs (simPlical mad LIBS, since really we're showing a https://en.m.wikipedia.org/wiki/Simplicial_complex here). The functions are represented as tuples of the same arity, and described via sentences with blanks in them (e.g. when you run ____ code in ____ environment you get ____ from stdout). One with three blanks would then appear like a triangle and then I'd fill it in with a gradient indicating which sides are inputs and which are outputs. Functions sharing a mad lib would appear as a regular polygon in the same color (one edge for each blank). Or maybe they're sort of starfish shaped so that each leg can reach out an touch whatever the data representation ends up being.

One could imagine algorithms that generate patchwork quilts or 3D structures (like how protein folding is represented) out of such things. These could be computed only in one direction (from inputs towards outputs) but they could be traversed in any direction if one wanted to explore the relationships.

I'm hoping it will be a nice way of citing your computational sources. You would attach them to any computational result (alongside a scientific paper, perhaps) as a way if saying "here's how I came up with this, rerun it to verify my result". Aside from the computational pathway that yielded the result that's being scrutinized, you could explore adjacent plibs to understand why certain inputs were chosen or to gain other contextual hints.

Now that I'm describing it it sounds a bit like that awful zooming-through-towers-of-data visualization in "Hackers" the movie.

So the "edge" that I was using as a progress bar in my previous description is really a series of paths through a space made of these things. The details of the functions being called (and of the datasets being generated) are attached to the polygonal regions that the paths connect. The paths may merge or branch. It could get unwieldy, so the user would have to be explicit about which plibs to show and which to highlight as a chain of computation.

As for how the represent the intermediate data and their types, I keep changing my mind. Some days I like the stacks of cards thing, some days not. Hopefully something will sick soon, then I'll try to build it.

Re:Pipes: A spiritual successor to Yahoo Pipes by andyferris on Saturday July 06, 2024 @07:43AM (#40889815)
This is late, but I just saw this.

Wow that’s a pretty wild idea. Quite interesting.

I’m not sure what to consider “natural”. I know category theory (I’m a physicist by training, not CS, so I’m not talking Haskell or whatnot) tells us that these 2D drawings of computation graphs have a well-defined meaning (eg you can deform the lines continuously and it doesn’t change the result, etc). In particular, we have these monoidal categories where we can e.g. draw two lines in parallel to represent two pieces of data flowing.

The thing is the “monoid” can either by the product (two values in a struct, say) or a sum (two possible values in a variant) and you get the same “rules” for how to draw it. Back when I was drawing tensor network diagrams it would really tricky to include both monoids on the one diagram. You could kinda do it in 3D but that’s not natural or easy. What people do in practice (in flowcharts, etc) is we tend to have these AND and OR junctions (and their inverses) where a human can kinda infer what’s going on (e.g. does this split and join refer to two parallel computations or branching logic?).

I think both monoids are critical to expressing computation and I still don’t know what the “natural” yet “rigorous” way to draw these things is.

Re:Pipes: A spiritual successor to Yahoo Pipes by ninetyninenine on Monday July 01, 2024 @12:07AM (#40842455)
Text itself is a form of visual programming.

We really have only two styles of visual programming:

1. Some sort language formed by left to right based alphabetic symbols in some pattern called "grammar". There's an almost infinite amount of possible grammars

2. Boxes and lines. Where boxes represent state or function and lines connect the boxes and state together. There's less formalization in this area so the axioms are vague but it can form something of a "grammar" similar to the above.

That's it. It's not a space that could really use innovation. It's the fact that the entire space has never innovated. We've just been drilling down on a very specific and biased way of seeing the universe. The concept of a compiler literally illustrates how deep it goes and how tied the idea of a program is to a "language".

Re:Pipes: A spiritual successor to Yahoo Pipes by DonHopkins on Monday July 01, 2024 @04:44AM (#40843798)
I disagree that "It's not a space that could really use innovation." There's quite a lot of innovation and experimentation in the visual programming space, and many vastly different approaches to visual programming.

You forgot about block based visual programming languages like Scratch, Snap!, and Nassi-Shneiderman diagrams, and also the most ubiquitous, widely used, universally known, commonly taught, extremely powerful, and easily accessible style of visual programming language, which the worldwide economy depends on and would collapse if millions of people didn't regularly use them every day: spreadsheets.

Re:Pipes: A spiritual successor to Yahoo Pipes by viraptor on Monday July 01, 2024 @12:05AM (#40842447)
Depends how literally you mean programming and processing. For example UML is a programming diagram. If you don't have the definitions anywhere else and always merge the diagram with specific methods implementation when compiling, is that an good example?

What about ERD? If you materialise that into schema, is that programming?

I think you'll run only into those two categories - boxes represent literal code you join together, or boxes represent something declarative that gets compiled into code but not necessarily in a straightforward way.

I guess visual reporting like in MS Access could be thought of as a separate category?

Depending on whether prose is programming, there's also https://visar.app/

And then there's CUBE https://marc.najork.org/papers/vl1992.pdf

Re:Pipes: A spiritual successor to Yahoo Pipes by Ringz on Monday July 01, 2024 @02:15AM (#40843047)
Thank you for the very interesting links. I used UML extensively during my studies in the nineties, back then on Unix machines. Interestingly, even then, it was possible to work together on a UML concept. I'm not sure anymore if the novelty of working with a graphical UML program was the motivation, or the opportunity to program in something other than Modula. In the end, after my studies, I still had to program only in C++. Once accustomed to the relative directness, it is difficult to embrace new innovative concepts. But I would welcome it.
Re:Pipes: A spiritual successor to Yahoo Pipes by NaOH on Monday July 01, 2024 @12:02AM (#40842434)
Keyboard Maestro foregoes the lines between boxes, but it still presents the same general format.

https://www.keyboardmaestro.com/img/v11/[email protected]

Re:Pipes: A spiritual successor to Yahoo Pipes by jdougan on Monday July 01, 2024 @12:00AM (#40842422)
Scratch is arguably a style of visual programming
Re:Pipes: A spiritual successor to Yahoo Pipes by viraptor on Monday July 01, 2024 @12:10AM (#40842473)
Scratch is boxes and arrows with arrows of zero length ; )
Re:Pipes: A spiritual successor to Yahoo Pipes by jdougan on Monday July 01, 2024 @01:56AM (#40842941)
I know that's a joke, but in that case every screen is a grid of (v. small) boxes with arrows of zero length.
Re:Pipes: A spiritual successor to Yahoo Pipes by philsnow on Monday July 01, 2024 @02:04AM (#40842988)
Blockly (the visual editor used by Scratch) elegantly shows hierarchy of control flow. I've never seen a boxes-and-lines visual editor where loops are as easily understood as Blockly pieces.
Re:Pipes: A spiritual successor to Yahoo Pipes by okennedy on Monday July 01, 2024 @12:44AM (#40842591)
Spreadsheets.
Re:Pipes: A spiritual successor to Yahoo Pipes by smegger001 on Monday July 01, 2024 @03:19PM (#40849476)
Spreadsheets are to visual box and line programming what goto spaghetti-code is to traditional programming languages.
Re:Pipes: A spiritual successor to Yahoo Pipes by jes5199 on Monday July 01, 2024 @01:34AM (#40842834)
I’ve seen a demo - cannot immediately remember where - where instead of data flowing through lines, it actually had a physics engine where the data was shot out of the boxes in various directions, and did computation with whatever box it intersected with next
Re:Pipes: A spiritual successor to Yahoo Pipes by CannisterFlux on Monday July 01, 2024 @03:58AM (#40843538)
The only other thing I can think of is GB Studio - https://www.gbstudio.dev/ - but the visual scripting there is like regular coding, but with visual blocks. It doesn't use boxes and lines. Instead, the script elements are more like blocks within blocks.