5 ms·
This is why I think 2D and 3D languages are the future (and of course, are a big part of the present and past, just not in traditional programming languages). H
by breck 5y ago
This is why I think 2D and 3D languages are the future (and of course, are a big part of the present and past, just not in traditional programming languages). Human minds are highly evolved to work in 2D and 3D.
Further reading: 1972 - Mark Wells' A Review of Two-Dimensional Programming Languages
https://github.com/breck7/wells/blob/main/wells1972.pdf https://github.com/breck7/wells/blob/main/wells1972.pdf
- nexuist 5y agoOh man I'm excited to read the replies to this thread. I'm working on my own 2D language right now as a layer above JS. Let me know if you'd be interested to beta test! I have a sense that the programming community at large will reject it at first, but if it helps non-technical people ship it's a win in my book.
- oh_sigh 5y agoIs it better the befunge? If so, how?
- nexuist 5y agoBefunge is very cool, although a bit difficult to onboard users onto :) My language is a lot simpler: it uses functional programming principles to transform input to output without storing state. The programmer would place down blocks on the screen and draw lines between them to indicate where they want data to flow. They'd start on the left (input side) and end on the right (output side). The cool benefit of this paradigm is that it's recursive; you can build blocks that contain blocks that contain blocks etc... all of which shuttle and transform data from the left to the right. The other part of this is that it won't just be a language, I'm planning on building an actual cloud environment where you can click a button to deploy your code onto a REST endpoint, so you can integrate it with your existing websites + scripts + apps.
- sdenton4 5y agopitch: 'buzz tracker for data transforms.' https://en.wikipedia.org/wiki/Jeskola_Buzz https://en.wikipedia.org/wiki/Jeskola_Buzz (which is admittedly a terrible pitch, unless you're trying to hook an old demo scenester...)
- nexuist 5y agoMy vision is closer to Yahoo Pipes / LabView / GNU Radio, but yeah I think you've got the right idea!
- LargoLasskhyfv 5y agoHm. You can have that in modern and multiplatform from: https://warmplace.ru/soft/sunvox/ https://warmplace.ru/soft/sunvox/
- sdenton4 5y agoOh, yes, sunvox is great, and probably less obscure than the long defunct buzz tracker at this point in history...
- pabs3 5y agoThat sounds a bit like Pure Data but on the web. https://puredata.info/ https://puredata.info/
- loa_in_ 5y agoHave a look at NodeRed and VVVV
- pugio 5y agoI would love to beta test such a thing. My number one current frustration with programming languages is my inability to represent core language concepts / objects in a 2D space. There's constant overhead mapping from my internal spatial representation of a program to the linear 1D that text provides. EDIT: Ahh, I see another comments that this is more of a block based no code kind of thing. I'm not looking to replace my program with purely visual constructs, I'm more interested in representing the file, object, and function layout on a 2D space. Nested folders of files seems so limiting when I want to put particular functions next to each other, and grouped over _here_, while another set of functions should be placed over _there_. I don't think the greatest power comes from doing away with textual code, I would just prefer that the units which compose a program can be organized, described, and related to each other in a richer way.
- nexuist 5y agoFor what it's worth, I do plan to support code blocks where you can drop in arbitrary code where you need it, and you can integrate it with the rest of the diagram by defining the input and output types itself. The goal isn't to replace textual programming entirely, but to build an integrated environment where you reach for visual constructs first and drop down into text when necessary. For your file example, you could have a "File Open" block that takes a filename as input and outputs a "File Reference" datatype, and then wire that reference to various file blocks (File Read / File Seek / File Write / etc) to perform operations on the file. When needed you could wire a reference to an arbitrary code block, perform whatever operations you want on the file using textural programming, and then output the reference to continue putting it through other blocks. Objects (as in JSON objects) could be represented in the same way, twisting and turning throughout your program as they are manipulated. Ditto for databases, file storage (like S3 or hard drives), sensors and their values, etc. As for functions, you'd be able to build your own blocks from existing ones, so you could take a textual function and turn it into a visual block that integrates with the rest of your code. You could group blocks together in the editor so that they are literally next to each other as you said, but one feature I'm particularly excited about that was inspired by SmallTalk is the Block Search: instead of searching by name, you describe the input and output types of the block, and the editor will search through the global database for any kind of block that matches your description. For example, you could describe a block that takes two strings and outputs one, and you could get a block back like "String Append." For our hypothetical file example, you would just search for blocks that take in File References, and you'd be able to find every block that does anything to a file, including your own. I know it's hard to imagine, which is why I'm working on building a demo ASAP so I can show and not tell. I saw from your bio that you're interested in STEM edutech so if this doesn't scratch your itch it may still be helpful for students to get started with software a la Scratch! Let me know if you're still interested - no worries if not though!
- Swizec 5y agoA benefit of consistently programming since I was a kid is that a lot of programming, especially code architecture, feels very plastic to me. Not quite visualized in a way I could draw, but sort of using the same circuitry as imagining a 3D model of mechanical engineering. It’s sort of there in my mind and I can see how things are connected, grab stuff and move it around, etc. Super handy for dealing with systems complexity
- psalminen 5y agoI thought developing these mantal maps was fairly common? Or maybe it's just me.
- beaconstudios 5y agoyeah I'm not sure if I could work effectively if I wasn't imagining a list interface like an actual list, a hashmap like a pigeonhole cabinet etc. Not literally in the sense of imagining those physical manifestations, but in the sense of relating to objects by their metaphorical interface.
- king_magic 5y agoI think it is common for many of us here, but I do think that the inability to construct these kinds of mental maps and manipulate them in one’s mind is one of the reasons that not everyone can code.
- andyxor 5y agointeresting, so 2D would be a "matrix language" somewhat similar to Matlab/Octave? it would be interesting to evolve a language from 2D or 3D to more abstract, higher dimensional representation of objects and topologies, like the cognitive spaces described in the article which operate on sparse vectors in a multidimensional system of coordinates (aka "grid cells"). i'm wondering if there is a language for defining network topologies like that, having some abstractions for JOIN/LINK operators to form & evolve a network [0] and FIND or FIND_SIMILAR operator for traversing that graph (looking for similar objects or clusters of objects), and something that allows to simulate "small world networks" effects, heuristics and shortcuts we see in real world graphs (including neural connectivity and distributed communication we observe in the brain) [0] Leslie Valiant, Memorization and Association on a Realistic Neural Model https://web.stanford.edu/class/cs379c/archive/2012/suggested_reading_list/supplements/documents/ValiantNC-05.pdf https://web.stanford.edu/class/cs379c/archive/2012/suggested...
- breck 5y ago> interesting, so 2D would be a "matrix language" somewhat similar to Matlab/Octave? Not only are the data structures 2D/3D, but the language itself is homoiconic. I'm thinking of things like 2D+ spreadsheets. Like this from Alan Kay in 1984 (https://pbs.twimg.com/media/E1UAukcUYAAI9lS?format=png&name=900x900 https://pbs.twimg.com/media/E1UAukcUYAAI9lS?format=png&name=...). A more recent things along these lines that I worked on: https://www.youtube.com/watch?v=0l2QWH-iV3k https://www.youtube.com/watch?v=0l2QWH-iV3k
- robotresearcher 5y agoSpreadsheets are a specialized spatial DSL. They are phenomenally successful, and have been around for more than 40 years.
- breck 5y agoYup. The most successful PL by pretty much 2 OOMs (1B spreadsheet users vs 20M JS programmers). I think the future will be the best ideas from traditional 1D programming languages merged into a spatial hybrid like spreadsheets.
- deleted 5y ago[deleted]
- enchiridion 5y agoSeems like notebook programming is a trend in this directing.
- keithalewis 5y agoA purely function language people can understand and use to solve problems they find important without dealing with their IT department. What a subversive notion!
- 11235813213455 5y agoSpreadsheets look 3-dimendional to me, but the first 2 dimensions are just about data (rows/columns), the 3rd dimension is the language itself (cell value), even though you can specify data ranges in the cell value, the language still looks 1D to me
- deleted 5y ago[deleted]
- resource0x 5y agoIt's not obvious how representing your program in 2D or 3D can help the brain to reconstruct its inner workings in its own version of 2D or 3D, even if it really needs to do this transformation. There might be a subtle difference between a program and a coffee cup.
- taeric 5y agoThis resonates well! Is there even a reason to think that a single version of a representation is all the brain works with?
- dopidopHN 5y agoProgram have majors business flow, happy paths, that would be rivers of transformations. Then small affluents attach to it as branches appears. Not so far fetched but I’m not sure you need a new language to support that. You could press a button and get this view. But I think the idea is to build with always this view on sight ? I have no idea.
- harperlee 5y agoThis is why Powerpoint has been so popular, imho. It can lead to information atrocities but a sensible use of layout can provide a lot of information that the brain can parse much more quickly than text, and directly provides a spacial layout for recalling it later as a mental model (for example, if you paint subsequent phases as actual boxes, instead of describing how something follows something). The idea also rhymes a lot with George Lakoff theory that we build concepts as towers of analogies and metaphors, whose bases are quite instinctive and frequently spacial (high is good, broad space gives you options, etc.)
- MrPatan 5y agoI think they are already. I don't see a file with code as linear text but as a shape. And several files are the other dimension. And I think not everybody is like this, though! I think there's a difference between "visual programmers" and "text programmers", and this is what causes the flamewars between people who want to "remove noise" by getting rid of parens, braces and semicolons, and people like me who use them as a sort of "signage". The real problem is that I bet the "text programmers" also write more, well, normal text, and are overrepresented in blogs, articles, and whatnot. (Even though they're wrong XD)
- hansvm 5y ago> between people who want to "remove noise" by getting rid of parens, braces and semicolons, and people like me who use them as a sort of "signage" I'm not sure this characterization appropriately divides "text" from "visual" programmers. The argument I usually see for removing symbols is that the general shape and flow of your program should be able to stand on its own and that minutiae like a misplaced semicolon shouldn't be allowed to play tricks on your eyes -- it's not that the visuals are unimportant, but that they _are_ important and that too many extra symbols lead to hard-to-parse visual clutter and more easily facilitate deceptive control flow. Whether that argument has any merit or not is its own debate of course.
- dmos62 5y agoPrograms are already cyclic trees. It's just that code is a somewhat cumbersome representation. Or rather, it's not a very natural one. At first I actually thought you meant human languages, which are already 3d to a large extent, because they're full of movement metaphors.
- isaacimagine 5y agoA cyclic tree is a graph, fwiw.
- dmos62 5y agoA cyclic tree is a cyclic directed graph.
- tigerBL00D 5y agoIs python not sufficiently 2D? You could see it as characters in a grid.
- breck 5y agoIt only uses a tiny bit of 2D (the indenting of parent child nodes). Most of it is still 1D (parens, quotes, etc). Python programs to not copy/paste well into spreadsheets (a simple test for "2Dness").