Matrix and IRC - Mozillians custom client?

I like the UI already

I’ve been making quite a few changes today to Relai. While the way the app looks as a whole hasn’t change massively, I’ve done smaller tweaks throughout to make it ‘better’, such as switching from my own custom header to gaia-header.

In addition to the smaller tweaks, I’ve added a connection page, which is now set as index.html and the chat page has been moved to chat.html. You can switch from the connections page to the chat page by pressing connect, and switching back to the connections page from the chat page is done by pressing the close/disconnect button in the header.

The app isn’t functional right now in any way, and probably won’t be for quite a while as I’m far from knowledgeable in much more than UX and UI, with only basic understanding of actually making things work. All changes have been committed into the repository.

1 Like

tad came across a really interesting option called Matrix - http://matrix.org/

It integrates with IRC, and provides the function a bouncer would. We have someone from the matrix team hanging out in #communityit if people have questions.

@tad - you could explain in better detail the problems you think matrix solves?

I look after Matrix, and @Kensie invited me to chip in with the pros and cons as we see them:

Matrix pros:

  • Matrix is entirely 100% FOSS (Apache License 2), both servers, clients, client sdks and gateways.
  • You can run your own matrix servers entirely for free.
  • Matrix is more than just an IRC client; it’s actually a new open standard HTTP API for decentralised comms. The big differences with IRC are:
    • Conversation history (scrollback) is a first class citizen, with infinite scrollback/logging available for free on every room
    • Open federation (like email or xmpp); if folks on remote Matrix servers join a room, the history is replicated over both servers such that no single server controls the conversation (signed with a git-like scheme for cryptographic integrity over a directed acyclic graph). Obviously you can also have closed-federation rooms too.
    • End-to-end encryption. We use a variant of the Axolotl cryptographic ratchet to optionally provide better-than-OTR end-to-end crypto as part of the spec.
    • Open standard HTTP API, making it trivial to write clients, bots or slack-style integrations.
    • Support for storing any JSON data in a room; not just text messages, but images, videos, files, etc.
    • Support for WebRTC-based VoIP/video calling (with multiway coming real soon now)
    • Presence, typing notifications, read reports, server-side configurable push notifications, etc.
    • Mobile clients (iOS and Android) as first class citizens.
    • Extensible gateways to other networks - we already have SMS, SIP and so PSTN gateways; meanwhile XMPP, Slack, Lync and other ones are in development. Building a bridge for something like Discourse into Matrix would be really easy and fun, for instance.
  • That said, you can use Matrix as a glorified IRC bouncer if you like. Matrix’s name comes from the fact that it matrixes together different existing communication networks, and for folks like Mozilla (and my workplace as it happens) which live and breathe from IRC driven, the bridging works great.
  • Clientwise there’s a range of clients that talk Matrix - http://matrix.org/blog/try-matrix-now has the list. The most advanced one is http://vector.im, which is converging on slack-style UI/UX. However, all of these are FOSS and Vector in particular is very easily customised and branded via the matrix-react-sdk. So, if Mozilla wanted to use a Moz-branded version of Vector which skinned things to smell and look more like IRC rather than ‘pure’ Matrix, that’s absolutely trivial (a few hour’s work) to do. Meanwhile IRC diehards can still connect to IRC itself.
  • Clientwise we also provide a large range of SDKs, both for wrapping the HTTP APIs and providing reusable UI components. Includes Python, Perl, Android, iOS. The community’s written a bunch of others too (Erlang, Ruby, Lisp, etc).

Matrix cons:

  • It’s still beta. We’ve been dogfooding it since we launched in September 2014 and it’s very usable, but we’re still polishing the specs, the server and the clients.
  • The reference server is written for experimenting with the APIs rather than performance. It’s written in Python/Twisted, and as such is basically single-threaded and doesn’t horizontally scale yet. On the matrix.org server we currently have 25,000 accounts and a few thousand rooms and a few hundred simultaneous users and things work fine, but there’s a lot of HA and performance work we’re doing currently in order to exit beta.
  • There are some thinkos in the v1 API that we’re fixing currently with an upgrade to v2. Specifically, messages can rarely get out of order on bad connections; invitations to join a room don’t give enough info about what you’re being invited to and can’t be rejected; clients can take a while to sync on launch for powerusers; etc. We’re working through these quite aggressively though.

Hopefully this gives a bit more context about what we’re up to. If you want to give it a go, check out the react client at vector.im or perhaps the older clunkier but maturer angularjs client at matrix.org/beta. Meanwhile, you can get a server from http://github.com/matrix-org/synapse, or an IRC bridge from http://github.com/matrix-org/matrix-appservice-irc. Finally, if you were hypothetically customising Vector to brand and reskin it to work nicely with Moz, you’d fork https://github.com/vector-im/vector-web.

All of moznet is now bridged into Matrix, so you can already join anywhere on IRC from Matrix by joining #mozilla_#channelname:matrix.org (e.g. #mozilla_#communityit:matrix.org), and you can catch me there as M-Matthew on IRC or @matthew:matrix.org on Matrix if anyone has any questions.

Quick screenshot of how #communityit appears on Vector, for the record:

5 Likes

In the meeting yesterday it was rightly pointed out that nobody had responded to this topic after @matthew posted, possibly giving the impression that the idea was dead in the water - when that definitely isn’t the case.

I think a few of us have now have had the opportunity to try Matrix and Vector out, and asked @matthew various questions on IRC, and I’m convinced that it’ll go a huge way towards improving out real time communication problems within Mozilla… (cough Telegram cough) …and serve as a great base to build extra, Mozilla-specific (Mozillians integration, for instance), features on.

The next step (which we started in the meeting yesterday) is explicitly stating how it fixes some of the problems which we’ve stated, work which is happening here: https://communityit.etherpad.mozilla.org/matrix

Thanks for the heads up, @leo. I’ve scribbled some feedback on https://communityit.etherpad.mozilla.org/matrix. We’d love to help you folks roll out Matrix in earnest and customise Vector etc, so let me know what we can do.

1 Like

That’s great! I think you basically answered that most of the things we want are possible. I think the next step might be to find some hard-core telegram users and get them to demo Vector, let us know what feels uncomfortable.

¡Hola!

For the brave… https://vector.im/#/room/#mozilla_#communityit:matrix.org

=)

I didn’t have time to test vector and other clients, but this basically will work for a user as IRCCloud works right now?

That is true, but I wouldn’t say that’s the basic summary. The idea for checking out this client is really more about the UX. People dislike IRC because clients are usually not designed for a novice user, hence the appeal of Telegram. But Telegram is incredibly similar to IRC. With the right client, it could be indistinguishable.

I feel people like Telegram because they are already there for other groups and conversations so they don’t have to care about having another app just for other specific case. Same happens with Facebook, people are already there and the effort to use it is zero.

But that’s not always true. People had to sign up for Telegram for some reason, it’s not a very popular app, but it’s popular among Mozillians. So that has to be because of the UX and not because they were already using it. Otherwise they’d just use Facebook. Facebook can do chat pretty much exactly the same way as telegram. Or IRC, many people who use telegram had been using IRC and just didn’t like it as much.

I wouldn’t jump into conclusions that quickly. Telegram IS a very popular app in Europe and Asia, some people use it instead of Whatsapp (it’s free and have a few improvements over whatsapp).

I’m not going to comment on specific tools. Tooling is not my priority for communication (though it should be somebody’s!)

However, I will make this note
Currently, communication is really decentralised. Right now, I have the following text based things on my phone just so I can talk to mozillians.

  • WhatsApp
  • Telegram
  • IRC
  • Skype
  • Facebook Messenger

Then there’s iMessage and SMS which I use 70/30 for personal/mozilla stuff.

Condensing is needed, and here’s the list of requirements that people seem to generally have

  • Free as in Speech
  • Free as in Beer
  • Simple to use, but with some advanced functionality
  • Private messages
  • Groups
  • Not disclose personal info

I know which tool I’d choose to meet all of those requirements. But let’s reverse this discussion and look at the problems, build requirements/MVP, and then how each tool fits in to the requirements

Maybe there’s another thread that I’m missing. This one seems really tool focused. Partially my fault for saying “OOOOH MATRIXXXXXX. SHINY”

1 Like

Yes, you’re missing another one, this one was specifically for discussing a
Mozillians’ specific IRC client, and we settled on Matrix as our experiment.

We actually did discuss the problems, and the functionality people seem to
like/dislike, which is why when you saw matrix you went “ooooh shiny!”

It checks more than enough of the boxes to be worth trying out, including us
not requiring yet another platform, which is the problem with slack.

I think it’s no longer going to be possible to centralize communications. As long as different apps are popular in different demographics, there’ll be fragmentation. The best we can do is bridge communications. And matrix can probably do that. With that, everyone can continue using what they’re using. (Not to forget FOSS and openness and decentralization)

Matrix vs Telegram, for me

  • As a Telegram user, what I think lead to easy popularity of Telegram is that the contact discovery relies on phone number. This makes it possible for people to figure out when their friends are on Telegram without having to ask. I will go on and say (with no evidence as such) that this single feature is the reason why Telegram became very popular (even among Mozillians). All dinoblah had to do to get drawn into the conversation was join Telegram. A friend (with phone number) would get the notification “dinoblah joined Telegram”. They’d immediately add dinoblah to all relevant groups.

    With matrix, this contact discovery could rely on email address, I guess. (And among mozillians, that might be much more efficient getting new people join conversations).

  • Except the polish, Matrix has everything that Telegram had for me - multi device support, cloud synchronization, large groups.

  • Although replying to messages looks like a small feature, it is a very useful feature in instant messaging where topics drift very fast and your reply becomes confusing if you take more than 30 seconds to type it.

What is definitely going to be useful

  • A matrix integration with Telegram that allows messages to be synced across each other = instant win
1 Like

@leo - @JLensmeister would like to help with setting up the back-end stuff. We wanted to make sure we had your blessing before letting him go with it. When we were triaging we saw how much stuff is attached to you. :wink:

Ah so you’re staying the key is that you get notified when one of your contacts joins Telegram? This is an interesting feature. Though in the context of Mozillians I don’t think this would be a leading wanted feature.

Do facebook and google not also let you search by your contacts to find friends on a messenger service? Or is the process significantly different?

If the vouching process on Mozillians were to work a bit more like friends, and create social links, then we could use the Mozillians API to replicate this sort of notification that a friend has made an account. Also the idea of remembering contacts is not a feature of IRC servers, but could probably be done with matrix.

I’m not sure this is key. But it just occurred to me when I started thinking about it.

Contact discovery. Google shows Google+ profile of people we communicate with right next to emails, also sends notifications when contact joins Google+. Facebook has friend suggestions (which uses gmail contacts if we upload gmail contacts). Instagram notifies you when your facebook friend joins Instagram. LinkedIn has suggestions based on email contacts. Twitter notifies you when your email contact joins Twitter.

Upload contact emails, compare it with email address of new users when they signup, send notifications. (And manage the privacy :P)

Totally! I don’t think I have any secret knowledge which isn’t available in the public documentation, but if @JLensmeister wants some help/advice/whatever with config I’m happy to provide it. For the time being I really should be focusing on SSO (when I’m not doing Physics Coursework…)