<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>Federation on Touhami&#39;s Space</title>
    <link>https://touha.me/tags/federation/index.xml</link>
    <description>Recent content in Federation on Touhami&#39;s Space</description>
    <generator>Hugo -- gohugo.io</generator>
    <language>en-US</language>
    <copyright>All rights reserved - 2017</copyright>
    <atom:link href="https://touha.me/tags/federation/index.xml" rel="self" type="application/rss+xml" />
    
    <item>
      <title>The meta-federated social network</title>
      <link>https://touha.me/post/meta-federated-social-network.en/</link>
      <pubDate>Sat, 03 Oct 2015 17:02:31 +0100</pubDate>
      
      <guid>https://touha.me/post/meta-federated-social-network.en/</guid>
      <description>

&lt;p&gt;Today&amp;rsquo;s social network are all introvert in a way or an other at varying
degrees. Some are fully centralized where interaction is done only with users
from the same network and server. Some are decentralized and interactions occur
between users on the same network spread on different servers. Some others go
even further and let interactions occur between users from different networks
and servers. This is the &lt;a href=&#34;https://en.wikipedia.org/wiki/Federation_%28information_technology%29&#34;&gt;federation&lt;/a&gt;. Networks falling in the last
category are few and a real federation is not there yet.&lt;/p&gt;

&lt;h2 id=&#34;the-fediverse-is-not-federated&#34;&gt;The fediverse is not federated&lt;/h2&gt;

&lt;p&gt;Networks should settle on a common protocol in order to understand each
other. This certainly won&amp;rsquo;t happen. Years have passed and no unified protocol
have been defined yet. Who said &lt;a href=&#34;https://en.wikipedia.org/wiki/OStatus&#34;&gt;OStatus&lt;/a&gt;?  &lt;a href=&#34;https://xmpp.org/&#34;&gt;XMPP&lt;/a&gt; you say?&lt;/p&gt;

&lt;p&gt;I might say that each network speaks its own language and doesn&amp;rsquo;t do any effort
to learn a foreign one. It eventually learns a word or two as a second languages
like &amp;ldquo;&lt;em&gt;Hello&lt;/em&gt;&amp;rdquo;, and &amp;ldquo;&lt;em&gt;show me your picture pelase&lt;/em&gt;&amp;rdquo;. Please take note of the
typo the the second sentence.&lt;/p&gt;

&lt;p&gt;A huge hindrance to federation on the one hand is jailing networks like the Eff,
Tee or Gee+ ones that are completely centralized and introverts by design. On
the other hand federated networks provide the poorest and outdated documentation
possible making it difficult for other developers to bypass the lack of a
standard protocol.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;The current state&lt;/strong&gt; of things is that if a network talks to another, the
communication is poor. For example, a user from &lt;a href=&#34;https://gnu.io/social&#34;&gt;GNU Social&lt;/a&gt; can
subscribe to a user from &lt;a href=&#34;https://diasporafoundation.org/&#34;&gt;diaspora*&lt;/a&gt; but not the inverse. More than
that, the GNU Social user would stop receiving updates from that diaspora* user
after a period of time.&lt;/p&gt;

&lt;p&gt;You cannot subscribe to a user living in a jail network.&lt;/p&gt;

&lt;p&gt;There exist bridges that allows a user post on a jail network and have his
updates mirrored on an open network and vice versa. Even though, you still need
to have two accounts to use a bridge.&lt;/p&gt;

&lt;h2 id=&#34;my-proposition&#34;&gt;My proposition&lt;/h2&gt;

&lt;p&gt;I propose to create a network that is polyglot. A network that &lt;em&gt;thinks&lt;/em&gt; in its
own way and &lt;em&gt;expresses&lt;/em&gt; itself in the language of the one it communicates
with. Lets name this social network &lt;strong&gt;The Polyglot&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;A polyglot account would provide access to as many networks as network-languages
it can speak. E.g. A polyglot account gives an account on GNU Social,
diaspora*, &lt;a href=&#34;https://redmatrix.me/&#34;&gt;Redmatrix&lt;/a&gt;, &lt;a href=&#34;http://pump.io/&#34;&gt;pump.io&lt;/a&gt;, &lt;a href=&#34;http://friendica.com/&#34;&gt;friendica&lt;/a&gt;,
and XMPP all in the same place under one user identifier. Speak to it in
OStatus, it replies in OStatus. Ask it in pump.io, it answers in pump.io.&lt;/p&gt;

&lt;p&gt;The polyglot, like humans, can understand (read-only) what jail networks say,
but is too afraid to speak to them. It may resort to brokers or intermediaries
to speak to them.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;How to achieve this&lt;/strong&gt; is rather simple. The polyglot needs to know the basics
of all the networks-languages it wants to talk to. Those basics are:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Get a user&amp;rsquo;s profile including his avatar, header, bio, location, email and
URL&lt;/li&gt;
&lt;li&gt;Get a user&amp;rsquo;s publications. Also known as notices, dents, updates, statuses,
queets, tweets, etc.&lt;/li&gt;
&lt;li&gt;Post a publication&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;These basics can be extended by basics level 2:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Post a reply&lt;/li&gt;
&lt;li&gt;Get replies to a notice&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;A post has a textual content, a posting user, a created at date and can have a
type or not. It has also many meta-data.&lt;/p&gt;

&lt;p&gt;A reply is a post that replies to another post. Depending on the network, a
reply may be considered a comment.&lt;/p&gt;

&lt;p&gt;The polyglot is intelligent enough to understand if it dealing with posts,
replies, comments, photos, videos, check-ins or a personalized post type.&lt;/p&gt;

&lt;p&gt;When the polyglots learns how to talk to enough networks, it can then &lt;em&gt;formulate
complex sentences&lt;/em&gt; and &lt;em&gt;take complex actions&lt;/em&gt; like one-click remote
subscriptions, reply to any post anywhere or populate a user photo gallery from
a user on a network with no gallery notion. It is real smart a polyglot, isn&amp;rsquo;t
it?&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;On a more technical side&lt;/strong&gt; this polyglot should know all the important API
end-points and how to use them. The polyglot should be developed in &lt;strong&gt;Object
Oriented Programming&lt;/strong&gt; and makes extensive use of &lt;strong&gt;Inheritance&lt;/strong&gt; and
&lt;strong&gt;abstraction&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;This network is better written in a framework like &lt;a href=&#34;https://symfony.com/&#34;&gt;Symfony2&lt;/a&gt; so it
benefits from a strong MVC architecture, routing and templating. By templating I
mean it either replies in HTML5, JSON, plain XML, Atom, RSS, RSS2,
ActivityStream or anything.&lt;/p&gt;

&lt;p&gt;Lets say we have an abstract base class &lt;code&gt;Polyglot&lt;/code&gt; defining all the vital and
necessary operations. This is what I referred to as thinking in its own way. The
common parts would take care of storing updates, profile information and all the
data in a unified and structured way. The remaining methods will all be
abstract, obliging any class inheriting from it to implement the basic operation
we want.&lt;/p&gt;

&lt;p&gt;What I want to come to is that if we need our polyglot to speak a new
network-language, we just create a new class defining how those basic operations
work on that new network.&lt;/p&gt;

&lt;p&gt;When we have all the data we want, we do what ever we want with it like
translating it to other networks in their own languages.&lt;/p&gt;

&lt;p&gt;For jail networks, we only need an API key and secret that would power a
broker. This broker will get a list of users, read what they say, and replicate
their statements locally. In other words, the broker monitors the subscription
process and look for all the remote that are in the jail it is in charge of, and
dresses a list of them. It will then, depending on the configuration of the
local server, retrieve all the updates and data of the selected users in
real-time, near real-time or at intervals. Once the brokers does its work, the
polyglot knows what the jailed users said, and inform its local users. Local
users might also ask the broker to transmit messages to jailed users.&lt;/p&gt;

&lt;p&gt;Practically, you might subscribe to @user@twitter.com, mention him and the
broker will take care of informing the polyglot and thus the local user of all
what @user@twitter.com says, and even transmit queets to him inform
tweets. Obviously, those tweet will be posted by a bot, the broker, and contain
the original user username and all the data needed by the jail network in the
format it wants. Given enough permissions, the broker can do the same for any
network of any kind as long as it has public API or is decentralized.&lt;/p&gt;

&lt;h2 id=&#34;eventual-problem-we-might-face&#34;&gt;Eventual problem we might face&lt;/h2&gt;

&lt;p&gt;We might have a problem if two networks use the same API end point while using
different data structure and format. API end points are the principal indicator
of the protocol. If a social network doesn&amp;rsquo;t identify itself in the headers,
which certainly no network does, then there is no other way than the API end
point to identify it. This can be problematic. Really.&lt;/p&gt;

&lt;p&gt;&lt;del&gt;&lt;strong&gt;An eventual solution&lt;/strong&gt; is to give a Schrodinger reply. We first determine
all networks using this API endpoint and generate a response to all of
them. Then if all those networks use the same data structure. e.g. all use JSON,
try to put somehow all the response one after the other hoping the network would
choose the right one for it. If they use different data structure, it is more
problematic. We may give a response using some kind of separator, or multiple
successive replies. If the network doesn&amp;rsquo;t understand the response will drop it
but hopefully takes the next one in consideration.&lt;/del&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;A real solution&lt;/em&gt; is prefixing APIs with the name of the protocol. Instead of
having &lt;code&gt;example.com/api/&lt;/code&gt; as the base, we would have example.com/ostatus and
example.com/diaspora as bases. This is possible since networks have absolutely
no clue on how that base should look like and just search for it in the &lt;code&gt;&amp;lt;head&amp;gt;&lt;/code&gt;
section of a DOM page.&lt;/p&gt;

&lt;h2 id=&#34;conclusion&#34;&gt;Conclusion&lt;/h2&gt;

&lt;p&gt;Only a polyglot can decide what language (protocol) is the most practical and
efficient. So while nobody knows what any protocol should look like, how
efficient it should be federation wise, lets all feed our polyglot so it tells
us. This proposition is practical and feasible. Clients
like &lt;a href=&#34;http://andstatus.org/&#34;&gt;Andstatus&lt;/a&gt; can operate on many networks, but they don&amp;rsquo;t do so
under one and same identity.&lt;/p&gt;

&lt;h2 id=&#34;update&#34;&gt;Update&lt;/h2&gt;

&lt;p&gt;&lt;a href=&#34;http://friendica.com/&#34;&gt;Friendica&lt;/a&gt; apparently does most of what I describe and
is the most federated. It can interact with, GNU Social, diaspora, redmatrix and
itself. Why isn&amp;rsquo;t as wide spread as others?&lt;/p&gt;
</description>
    </item>
    
  </channel>
</rss>