What would real-time collaborative cellular automata editing look like?

For general discussion about Conway's Game of Life.
Post Reply
User avatar
wirehead
Posts: 253
Joined: June 18th, 2022, 2:37 pm
Location: fish: wirehead: command not found
Contact:

What would real-time collaborative cellular automata editing look like?

Post by wirehead » January 9th, 2024, 4:02 pm

So we all know that Google Docs is really neat. If two people are in the same document at the same time, you can see each others' cursors and selections as you edit the document (nearly) simultaneously.

Now I was wondering what, or how, this kind of real-time collaboration on cellular automata patterns would look like or function. In Golly, for example, you can edit a pattern, run it for a bit, and edit some more. This really throws a monkey wrench in any kind of diffing to sync state because two people might have the pattern at different generation counts.

I'm interested in hearing what the community thinks about something like this, if it would even be possible with current technology and algorithms, and if it is, how it would function.
Langton's ant: Can't play the drums, can be taught.

User avatar
dvgrn
Moderator
Posts: 10694
Joined: May 17th, 2009, 11:00 pm
Location: Madison, WI
Contact:

Re: What would real-time collaborative cellular automata editing look like?

Post by dvgrn » January 9th, 2024, 4:18 pm

wirehead wrote:
January 9th, 2024, 4:02 pm
So we all know that Google Docs is really neat. If two people are in the same document at the same time, you can see each others' cursors and selections as you edit the document (nearly) simultaneously.

Now I was wondering what, or how, this kind of real-time collaboration on cellular automata patterns would look like or function. In Golly, for example, you can edit a pattern, run it for a bit, and edit some more. This really throws a monkey wrench in any kind of diffing to sync state because two people might have the pattern at different generation counts.

I'm interested in hearing what the community thinks about something like this, if it would even be possible with current technology and algorithms, and if it is, how it would function.
Have you seen the LifeCompetes website? Currently in working order here, I think, though you might need to recruit a few more people to try it out with you simultaneously.

It can be either a competitive game or a highly collaborative one, depending on who shows up! People have managed to work together, and/or to build bots that work together, to build some very complicated and delicately balanced structures.

User avatar
wirehead
Posts: 253
Joined: June 18th, 2022, 2:37 pm
Location: fish: wirehead: command not found
Contact:

Re: What would real-time collaborative cellular automata editing look like?

Post by wirehead » January 9th, 2024, 4:40 pm

dvgrn wrote:
January 9th, 2024, 4:18 pm
Have you seen the LifeCompetes website? Currently in working order here, I think, though you might need to recruit a few more people to try it out with you simultaneously.

It can be either a competitive game or a highly collaborative one, depending on who shows up! People have managed to work together, and/or to build bots that work together, to build some very complicated and delicately balanced structures.
I saw that. Aaaaand the problem with it is it has a global (and very slow) clock. That is, no one person controls when the cells advance generations.

What I was thinking about is more like Golly in that you can run as fast as you want for as long as you want, and then edit, and then undo, and then step by a few generations until you see something happen, and then edit some more, etc. Is something like this even possible?
Langton's ant: Can't play the drums, can be taught.

User avatar
otismo
Posts: 1218
Joined: August 18th, 2010, 1:41 pm
Location: Florida
Contact:

Re: What would real-time collaborative cellular automata editing look like?

Post by otismo » January 9th, 2024, 4:49 pm

there are threads on these forums where astonishing global real time collaboration is taking place...
"One picture is worth 1000 words; but one thousand words, carefully crafted, can paint an infinite number of pictures."
- autonomic writing
forFUN : http://viropet.com
Art Gallery : http://cgol.art
Video WebSite : http://conway.life

User avatar
wirehead
Posts: 253
Joined: June 18th, 2022, 2:37 pm
Location: fish: wirehead: command not found
Contact:

Re: What would real-time collaborative cellular automata editing look like?

Post by wirehead » January 9th, 2024, 5:24 pm

otismo wrote:
January 9th, 2024, 4:49 pm
there are threads on these forums where astonishing global real time collaboration is taking place...
These forum are about as real-time as Git is for code collaboration.

I'm looking for something where you literally get to see what other people are doing with the pattern at the instant they are doing it.
Langton's ant: Can't play the drums, can be taught.

User avatar
otismo
Posts: 1218
Joined: August 18th, 2010, 1:41 pm
Location: Florida
Contact:

Re: What would real-time collaborative cellular automata editing look like?

Post by otismo » January 9th, 2024, 7:57 pm

wirehead wrote:
January 9th, 2024, 5:24 pm
otismo wrote:
January 9th, 2024, 4:49 pm
there are threads on these forums where astonishing global real time collaboration is taking place...
These forum are about as real-time as Git is for code collaboration.

I'm looking for something where you literally get to see what other people are doing with the pattern at the instant they are doing it.
I think you would absolutely love the stock market...
"One picture is worth 1000 words; but one thousand words, carefully crafted, can paint an infinite number of pictures."
- autonomic writing
forFUN : http://viropet.com
Art Gallery : http://cgol.art
Video WebSite : http://conway.life

User avatar
dvgrn
Moderator
Posts: 10694
Joined: May 17th, 2009, 11:00 pm
Location: Madison, WI
Contact:

Re: What would real-time collaborative cellular automata editing look like?

Post by dvgrn » January 9th, 2024, 8:50 pm

wirehead wrote:
January 9th, 2024, 4:40 pm
I saw that. Aaaaand the problem with it is it has a global (and very slow) clock. That is, no one person controls when the cells advance generations.

What I was thinking about is more like Golly in that you can run as fast as you want for as long as you want, and then edit, and then undo, and then step by a few generations until you see something happen, and then edit some more, etc. Is something like this even possible?
I would think that it would be a fairly minor modification to LifeCompetes code -- not that I'm volunteering to do it myself! -- to turn off the automatic one-tick-per-second clock, and instead just have a button that everybody can click on if they want to, to turn the clock back on again ... or maybe just to advance one tick (and keep clicking to advance more ticks).

An "undo" button would be a bit trickier, especially if you want to be able to support truly universal undo, where nothing can ever get lost (but it might be on a rather far-away branch of the tree of edits, hard to get to from the current view location).

hkoenig
Posts: 259
Joined: June 20th, 2009, 11:40 am

Re: What would real-time collaborative cellular automata editing look like?

Post by hkoenig » January 9th, 2024, 9:14 pm

Since Life is deterministic, if everyone starts with the same pattern, then everyone will see the same set of generations and same results. So all that is needed is to agree on which gen they will "stop" at and in order to do their next round of editing. The viewers can move forward at whatever speed they desire (or move backwards) without having any effect on other viewers until it's time to send the "I want to look at this" message, or receive the "advance to this generation" message.

This also means there is no need for a centralized server to do the calculations. The users just need a peer-to-peer way to pass along where they are at and what pattern they are looking at, and how that pattern is being modified to provide a new starting point.

hkoenig
Posts: 259
Joined: June 20th, 2009, 11:40 am

Re: What would real-time collaborative cellular automata editing look like?

Post by hkoenig » January 10th, 2024, 11:27 am

I took a quick look at that webpage, and whatever it may be, it's not the Game of Life. It has incorporated elements of Life, but one of the key factors to Life is the deterministic behavior. In Life, cells don't magically or randomly change state because of an act of God or some other external action.

Then again it's also possible to have a deterministic multiplayer life game.

Start with an empty field.

A turn consists of:
* Everyone simultaneously places a Glider at least n cells outside of the currently active frame, (or an arbitrary frame at the start of play) as if they are coming from infinity.
* Run pattern for n generations. (or n generations after the first of the new Gliders interacts with an object within the frame.
* Score the resulting pattern.

If two or more players place Gliders that cannot come from infinity, because they overlap, or would have interacted earlier (or with escaping Gliders), those Gliders are removed before the run phase.

What would scoring be? Several possibilities.

1) A multi-state where every player has a different color. Count the number of cells of a player's color and increase score. Goal is to eliminate the opposition.

2) Players secretly create a list of objects they intend to create. At the end of a run phase, tally up the objects in stablized areas. If objects survive to the next scoring phase, they will score again. (Perhaps use Catagolue occurrance statistics, the more rare an object, the more it scores.)

3) An iterative tournament cooperative version where a set of randomly chosen players must build a pattern. Scoring is by number of Gliders used or generations needed, or some other criteria, where everyone scores the same. Then the players are reassigned to new teams to repeat. Complexity of the patterns dependent on team's starting scores.

The current pattern is always equivalent to a large set of Gliders, coming from infinity, interacting with each other. Gliders that are placed in a turn are just Gliders that just happened to be so far away that they are "beyond the event horizon" of the local pattern in question. A "slow salvo" construction in progress.

User avatar
silversmith
Posts: 334
Joined: June 15th, 2020, 6:20 pm
Location: Pennsylvania, USA, Earth, Sector 5ff63D6
Contact:

Re: What would real-time collaborative cellular automata editing look like?

Post by silversmith » January 10th, 2024, 1:57 pm

I made a prototype collaborative editor, which functions by having a shared generation zero. Edits to that generation are shared, while running the simulation is done locally. You can also see the viewport of other editors who are online.
https://collab.silversimulations.com/
Edit: Since it's unlikely to see anyone else online, you can test it yourself by opening the website on multiple tabs, or on multiple windows.
A simulator with the tools I couldn’t find elsewhere: https://www.silversimulations.com/caplayer/
Documentation:https://github.com/teraxtech/caplayer

Post Reply