You are viewing archived messages.
Go here to search the history.

Arcade Wise 2023-11-09 01:31:59

Does anyone know of any systems that let you take the output value on a repl, edit it, and then edit the code so that your edit is true?

Personal Dynamic Media 2023-11-09 01:34:05

Prolog can create data structures that will make an assertion you provide be true. Within a sufficiently limited world, it might be possible to make those data structures be code of some sort.

Arcade Wise 2023-11-09 01:44:53

oh interesting! I've played with prolog a little, maybe i'll look further down that data

Joshua Horowitz 2023-11-09 01:53:57

It’s not clear to me whether “edit the code so that your edit is true” refers to a human editing the code (like a programmer trying to make a unit test pass) or a computer system editing the code automatically. If you’re going for the latter, you might be interested in “output-directed programming” / “bidirectional programming”, as exemplified by

Arcade Wise 2023-11-09 02:02:57

it's the latter, and thank you!

Paul Tarvydas 2023-11-09 02:25:49

Not sure if this is what you’re asking for... Barliman (Byrd, Rosenblatt) inputs “test results” and tries to infer code that produces those same results. “miniKanren” is a newer Relational Language, kinda like Prolog in intent, except different. . I find the youtube to be impressive (Clojure/conj). hth?

Arcade Wise 2023-11-09 02:27:10

Oo yeah, that does seem helpful.

Ivan Reese 2023-11-09 03:11:00

If you want something less text-centric, @Toby Schachman's Apparatus might be of interest. (I'm pretty wildly re-interpreting your inquiry, though, so it might ~not~ be of interest. Talking about the ~output~ of a REPL implies either a non-live or only slightly live programming environment. Apparatus is an ~extremely~ live environment.)

Arcade Wise 2023-11-09 03:40:36

Yeah, aparatus feels more like the code is the output in a sense?

Ivan Reese 2023-11-09 03:55:31

Yes, in a sense. Though there is still a distinction between the stuff on the canvas and the stuff in the sidebar. Sidebar stuff is abstracted away from canvas stuff in a similar way that source text is abstracted away from program output.

Arvind Thyagarajan 2023-11-09 15:14:38

sidebar sidebar: I keep forgetting this wonderfulness exists (apparatus) and I'm thankful every time it reemerges in my view!

Eli Mellen 2023-11-10 16:07:06

I am probably misunderstanding something, in which case, feel free to relegate me to the depths from whence I came, but, would an image based system support what you are after @Arcade Wise? Or maybe a simpler thing, like a block-based system, e.g. UF for uxn?

Arcade Wise 2023-11-11 01:21:31

Hm, what do you mean?

Paul Tarvydas 2023-11-11 11:14:20

Jimmy Miller FYI - the code for this is now apparently online.

Arcade Wise 2023-11-11 22:31:33

oh yeah! I found the barliman paper and code, it's marked as to-be-read in my zotero folder for this :>

Dane Filipczak 2023-11-10 23:54:06

What are some examples of successful UIs over constraint solving systems?

I'm about to do a bit of research on this topic but thought I'd start here.

Off the dome I can think of excel (numerical constraints) and rhino grasshopper (architectural / physical constraints).

I realize this is vague, but what I have in mind is a UI that allows for constraints to be defined which are then composed together and solved behind the scenes.

In particular, I'm wondering how to represent the case where there are multiple valid solutions and offer cycling through them to the user.

Ivan Reese 2023-11-11 00:11:13

This is exactly what I'm working on at Ink & Switch, but I'm not sure how much I can talk about it publicly yet. I'll get back to you in a bit!

George Campbell 2023-11-11 00:28:51

parametric CAD like solidworks/fussion 360/onshape are very successful

Ivan Reese 2023-11-11 04:41:34

So yeah! I don't have anything I can show yet, but I'll talk about some stuff that's relevant here.

George mentioned parametric CAD, and that's an excellent example. I'd also point to video games — the way their physics engines work is often quite similar to a constraint solver, and the "UI" over the solver is the game itself. Some games like World of Goo or the new Legend of Zelda: Tears of the Kingdom expose the constraint system quite directly as a core part of the gameplay. I'd also point to artistic 3D modelling tools, which differ a bit from CAD in that the interface(s) to the constraint system(s) are more focused on creative expression (eg: "make this thing 'look at' that thing") rather than precision (eg: "make the angle between these two lines 90º").

For the part where you're wondering about multiple valid solutions, I think it depends on how continuous vs discrete your domain feels. If it's very continuous, you might want some of the approaches in Bret Victor's essay Ladder of Abstraction. If it's more discrete, check out the Ink & Switch essay Untangle.

I hope that helps. Feel free to ask for more examples or more explanation of anything I referenced.

Jasmine Otto 2023-11-11 06:56:50

I've had some success with various flavors of heatmap ('expressive range analysis'), similar to 'three steps up' in Ladder of Abstraction but whose axes arise from either parameter space (as shown) or phase space (esp. time, in the special case where artifacts are sequences of events). If you can picture the latent space that artifacts are drawn from by queries (going through the constraint solver), that can help to discover something cleverer.

Tbh, I'm abusing heatmap here to describe density distributions of artifacts in latent space (to be accessed by drilling down, although the selection can be multiple) - not the uniform parameter grid that Victor shows, although that could be understood as the empty query.

(I'm assuming you do want to mingle phase space with parameter space - rather than animating the constraint like in Zelda, or building it into the user's brushes like in CAD, if I understand.)

Jack Rusher 2023-11-11 07:40:36

Depending how you mean the question, you might want to check out the gemstone systems from Brad Myers (amethyst, garnet, &c), in which UIs are built using constraint satisfaction.

Dane Filipczak 2023-11-11 14:33:46

Thanks everyone for the interesting pointers.

Ivan Reese I'm in the domain of music composition, which has continuous and discreet aspects. The most straightforward applications of constraints would be in the discreet areas, and I'm intrigued by the untangle work.

Jasmine Otto 2023-11-11 16:59:58

Oh, fantastic. Oxman's work was not on my radar; I see why you mention them in the same breath as DeLanda. Very excited to read your thesis. I will point at the 'musical metacreation' literature over at the ICCC and AIIDE conferences, although the selective pressures are very CS and tend to screen out interface work.

Here's folks using non-diatonic notes in chord progressions, from this year: HarmonyMapper: Generating Emotionally Diverse Chord Progressions for Games

Jasmine Otto 2023-11-11 17:00:33

and here's an incredibly search-oriented survey paper from '09 (sections 5.3 and 5.4 briefly discuss frontend): Constraint Programming Systems for Modeling Music Theories and Composition

Dane Filipczak 2023-11-11 21:31:19

@Jasmine Otto I'm embarrassed that you found my thesis 🙈 : )

there's some interesting conceptual stuff at the beginning but the work feels very primitive to me now.

Thanks for the links - I gave a paper at ICCC/MuMe once and love a lot of the work that comes out of there.

As with many areas in academia, the literature is overflowing with great ideas but I'm frustrated by the lack of a stable platform by which to compare and contrast the various approaches and expose them to non-expert users - one of the goals of this project is to reach towards a 'productization' of such research.

Xavier Lambein 2023-11-11 10:20:07

I'm thinking about ways to represent/interact with a (computational) graph. I could come up with three different interfaces off the top of my head: 1) names/identifiers and application, 2) combinators/stack operations, and 3) boxes and wires. I'm curious to know if y'all can think of any other?

Arvind Thyagarajan 2023-11-11 17:08:51

i'm heavily invested (both in effort and ideologically) in boxes and wires so I'll take door 3, but it must be live/reactive/flow node & wire with embedded output previews

one issue is that the expressive power of the visual programming is only as good as your primitives -- so one of the boxes should be a "get outta jail free" box that embeds other more expressive albeit more arcane paradigms (code, structured editors, etc.)

and as long as the blocks are purely functional, in/out, maintain and display state, it's the computational tool-for-thought of choice for me

Xavier Lambein 2023-11-12 14:13:42

Interesting. I have a sort of long-standing feud with boxes and wires, so I'm actually quite curious to know more about your investment in that paradigm. What have you used it for, why do you like it?

One of my biggest beef with those systems is that I find them often quite cumbersome to write and edit in, compared to the speed I can have by typing code. I also find them often low in information density, and complex code can get very difficult to understand. I'm very curious to hear your thoughts on that, if you'd be inclined to share them.