3,057 karma · joined May 5, 2012
https://invisible.college/@toomim
https://braid.org
Here's a prototype of it: https://peeryview.org. Check out the /about page. It's like Reddit or HN, but instead if having a single "moderator" with monopoly power over a set of "voters" with one vote each; you weight everyone's vote for your unique feed. And they weight a second layer of people's votes, etc.
We call this network a Web-of-Opinions, or a WoO. The Woo is subjective. It's soft. It's social. It determines your attention (in the news feed).
As it grows, it creates a new game-resistant reputation system, aka a "Liquid Democracy", that can be used for many things: like a Proof of Personhood, or an actual Democracy.
We just announced a protocol draft last week at https://braid.org/meeting-99. If you're interested, please give feedback here, in the braid group, or write me directly at toomim@gmail. This is the time!
I was in a similar situation to you. The doctor said it wasn't indicated for me, but I said I wanted it anyway, and the doctor said ok, and it cleared up my existing HPV infections after dose #2.
HPV functions by cloaking itself from your immune system. The reason why treatments like freezing work is not by removing the HPV -- it's by stimulating your immune system to look at the area around the wart. Then your immune system can get past the cloaking, and recognize the HPV, and then it destroys it.
So functionally, it makes total sense that the HPV vaccine would clear existing infections, and anecdotally, lots of patients (such as myself) have seen HPV clear after getting the vaccine. It's a shame that our bureaucracy doesn't have the incentives to run the studies to acknowledge it institutionally.
So from a privacy perspective, you see the metadata of edit history (the DAG of character positions edited), but are blind to the text.
> [the officer] bristled at the idea of calling the groups “deputy gangs” ... state penal code uses the term “gangs” to describe rogue law enforcement groups. Repeatedly, Murakami insisted that the tattoos symbolize hard work and “station pride” and that there was “no nefarious connotation” to having deputy subgroups operate inside the department.
Obviously law enforcement isn't perfect, but we should show both sides of the issue, and this wikipedia article is selecting only one side from already-biased articles.
The result is to dilute the term "gang." We have actual gangs to deal with, like MS13, which literally worships satan and seeks out and kills babies when "the beast" demands it. E.g. https://www.nzherald.co.nz/world/ms-13-gang-members-accused-...
That's a far cry from sherrifs with tattoos.
Weaves are the same thing as modern text CRDTs!
I started approaching the IETF to learn how to standardize State Synchronization in HTTP. I ran across this HN comment by JosephG [1] making a call to the same mission. I sent him an email, we decided to team up, and we went to dwebcamp in California and then IETF in Montreal together, and made a presentation to the HTTPWG proposing to extend HTTP into a state sync protocol. We got an enthusiastic reception, and I have been working on it ever since.
The HTTP extension is getting into pretty good shape, and we're now manifesting the promises on that /what page. They aren't all production-ready (e.g. no blockchains built on statebus/braid yet), but they are coming true at a steady clip!
That's not true. We want to use Braid to distribute OS updates, sending patches to multi-GB binary blobs; and for filesystem synchronization (think Dropbox/SyncThing/Resilio) with large binary files.
Braiders have put an impressive amount of work into compressing data: https://josephg.com/blog/crdts-go-brrr/. Data compression is critical, because these mutation histories can grow very large. There would be very strong resistance to a 33% overhead without a good reason.
> whether you emit an update over SSE or a HTTP subscription doesn't change that. Both are literally just TCP connections.
You're failing to consider a P2P mesh network. TCP only connects two computers. Braid enables a P2P mesh network where any peer can come and go, work offline, or switch connections, and nonetheless the whole network must synchronize with strong eventual consistency. Think distributed. Watch the distributed network partition, repartition, and reconfigure in https://braid.org/antimatter#viz. This won't make sense until you flip your mindset to distributed.
> You can package that data not as in the shape of a HTTP response.
Then we wouldn't be using HTTP. We wouldn't be able to re-use HTTP parsers and generators. We would lose a huge amount of interoperability with existing code.
It's confusing that you're arguing against using HTTP in order to use SSE -- while insinuating that using SSE means using HTTP. SSE is built on, but is not itself HTTP. It wasn't even standardized in the IETF HTTPWG. It's a way to tunnel a specific, limited, use-case of centralized, text-only, server-to-client-only event streaming over a HTTP response, without bothering to specify anything about how those events might change actual HTTP resource state. It's time to do better, and to bake that into HTTP more generally. We are making something way more powerful than SSE.
As for the rest of your comment, I am trying, but cannot understand what you are trying to say. Perhaps you could rephrase it.
As a programmer, you'll no longer have to write any networking code. You won't be touching HTTP headers and methods. That will all be handled by libraries for you, which will let you read and write any state, anywhere on the network, as if it's a local variable on your own computer—already downloaded, and always up-to-date.
The CRDT handles network delays, and race conditions, under multiple writers, so that everything merges automatically, and you don't have to think about them.
The Braid Protocol ensures that all servers, everywhere on the network, speak "state sync" in a standard way, even if they have different implementations behind the scenes, even with different algorithms.
This means that our libraries will be able to detect which algorithms need to be employed to synchronize with any service you are connecting to, and implement all that for you. You, as the application programmer, will just read and write variables like:
state['https://foo.com/news-feed'].push({
author: 'me',
post: 'hey guys!!!',
inreplyto: state['https://bar.net/post/2423h'].id
})
The reason why HTTP gets abused today is that it doesn't provide full synchronization support, which means that programmers have to abuse it in order to actually write web apps, which becomes a pain in the ass, and then everything feels a lot easier when you drop down into a WebSocket and get rid of the cruft. But now you're writing a custom WebSocket protocol, that only you will fully understand......unless you document it, and try to follow a standard like AsyncAPI, which gets you part of the way there...
...but what you really need is a State Synchronization protocol, and libraries that abstract away all the networking for you, and guarantee interoperability, creating a system of shared state. We're getting closer to this glorious world. The magical statebus in the sky that connects all our state together. When the abstraction is complete, it's going to blow everything else away.
We don't need Web Browsers to implement this natively -- that'll just be a performance improvement, like when JSON.stringify() and parse() became native in browsers. The important part is defining a standard that allows us to invest in robust State Sync algorithms and libraries, and lets developers invest in the applications that share this beautifully interoperable state, and make this new abstraction succeed across the globe.
Braid is not trying to be "application logic" or "transport protocol" -- it is a State Synchronization Protocol. If you can think of a more elegant method to support all of state synchronization within SSE, we're all ears!
But AFAICS you end up having to embed base64-encoded HTTP responses within SSE events within HTTP responses, which is gross pile of russian dolls, where both the innermost and outermost dolls are the same type of doll -- an HTTP response! So why all the intermediate dolls?
It's more elegant and simpler to extend HTTP at the root level, and say: "Instead of returning 1 HTTP response, a Braid server can return N HTTP responses, concatenated together with optional newline separators."
> SSE frames or subscription events ... arrive in the order the server sent them by virtue of being sent over TCP.
We support situations more complex than that. Multiple clients can make simultaneous edits with multiple PUTs. They can arrive in different orders to a server that relays them to other clients. Each peer in the system needs to know which versions the edits were parented from, so they can reconstruct the version DAG and merge consistently.
> The headers don't need to be a part of the protocol.
Yes, they do. Not only headers, but also status lines, and bodies. We are streaming entire HTTP responses. A HTTP response consists of a status line, headers, and a body. We need all of these. For instance, if a resource is deleted, we need to send a new 404 status line in the update. If the version changes, we need to update the Version: header. These need to be a part of the protocol so that all peers can update themselves in the same way, otherwise you don't get consistency.
How would your suggestion work? Can you give an example HTTP response to explain what it would look like?
The purpose of standards is interoperability. What software would this mixed/braid or multipart/braid mime-type help us be interoperable with?
I think we are working from a common inspiration!
See our current work on the "feed" spec in Braidmail: https://braid.org/apps/braidmail/spec2.
To support event-sourcing, you could replace those {link: ...} objects with event objects, and just treat each event as data. Then you'd have a url like /event-stream that peers would subscribe to.
Or, you could go deeper, and come up with a custom `Patch-Type:` for your events, which could make your events first-class HTTP citizens that could also be applied to a server using the PATCH method. Then your url might be /system-state, and represent the state for the whole system.
Braid supports such custom events, but be aware that this model is limited in a few ways:
- It's less interoperable, because all peers must know and implement the custom event types (aka patch-type) in order to read or write state.
- You don't get to re-use the beautiful and complicated merge algorithms that support eventual consistency with multiple writers (the OT/CRDT algorithms).
- It doesn't allow summarization of history. It's hard to prune history when each peer needs to know all events in order to do anything.
You might also be interested in PREP, which is a pure event-update protocol being worked on by my colleague Rahul Gupta: https://github.com/CxRes/prep We're trying to merge our work together, if we can.
You might also be interested in our deliberation on the pros/cons of "events" vs. "state updates" here: https://github.com/braid-org/braid-spec/issues/102#issuecomm...
The meeting is open. You're all welcome to join. :)
Hope that helps.
As for text/event-stream -- braid responses are not text (they can contain binary updates to things like images) and they are not an "event" stream. Braid provides an "update" stream, as a stream of HTTP responses. Each response can specify an update using a status code, headers, and a body.
If we were to use SSE, we would be encoding an HTTP response, within a base64-encoding (to fit as text), within a sequence of `data: ` lines, in an "event", within an event stream, within a text/event-stream content-type, within an HTTP response. It's a lot simpler to just extend HTTP to say "instead of one response, a server can provide N responses" than to go through all this rigamorale to encode responses within an event stream within a response.
As for events vs. updates, an update may or may not describe the raw underlying events. Updates can also be summaries of many events. For instance, a normal HTTP response body provides a snapshot that summarizes all of the edits up to that point that created the resource. This is an update, but is not the raw sequence of events.
Indeed, text sync requires old history to merge with old edits. However, Braid does not force you to hold everything. Peers can implement their own policies for deciding who to sync with. They can also ask each other for modules of old history they've forgotten if they realize they need it to merge something. This is made possible with the new Time Machine architecture that we are writing up.
This architecture also allows you to sync at multiple time resolutions -- realtime, fine grained, or slower, course grained -- within the same system. Different peers can hold and share at different resolutions. And they can all guarantee consistency with each other in the end. See the recent simpleton algorithm work for an example.
PATCH is supported in Braid, but only works for client->server. It does not support updates from server->client. So we need a way to express general updates, in both directions. Braid lets you use existing PATCH specs (as Patch-Type) if you want.
The PATCH specification also confounds multiple concerns (versioning, conflicts, validation, data formatting, applicable data types) into a single spec. It's nicer for these aspects to be modular and independent. Partial PUT happens to be already a modular, independent way to specify just the patch format, and can be extended to new data types by "Range Units." But use PATCH if you prefer!
The reason is that almost every use WebSockets is actually for Synchronizing State. What you really want to do is to synchronize state. Braid is a protocol for doing just that. So you don't need to turn to WebSockets anymore!