Wednesday, 20 July 2016

Art, AI and Google I/O 2016

What if there are interesting things waiting to be discovered where artificial intelligence meets art?

At Google I/O 2016 Ramzi Rizk told me there's a field called Computational Aesthetics. It is so nascent that it doesn't even have a Wikipedia page. Computational Aesthetics is where computers can actually tell us if a picture is pretty or not. This is different from systems like Flickr's Interestingness because the system infers beauty from the image itself rather than from the social signals generated by people's interactions with the image. In fact there's already been research showing that social signals lead communities like Flickr to overlook hidden gems. This research raises the tantalising possibility that there may be large numbers of overlooked masterpieces hiding in the historical corpus of art.

I find this intersection of art and machine learning interesting because at scale it leads to the discovery of new tools and new perspectives on something that we consider to be uniquely human. For example the spatial visualisation used in the "Machine learning & art" talk at I/O lead me to t-SNE as a mechanism for building two-dimensional maps of high-dimensional spaces.

This raises the possibility of building pirate maps of information spaces or hypertexts and connecting that to Vannevar Bush's ideas about stigmergy in the Memex. Imagine being able to create and share your own trail through the space of all art? Or being able to reinvent the idea of the traditional slideshow of the family's holiday photos.


Today apps like Prisma merely help us make alternative versions of existing photos. At the same time apps like The Roll and Google Photos help us identify our best photos. In the future they might help photographers to create photos from scratch and tell new kinds of hypertextual stories.

A photo posted by Ade Oshineye (@ade_oshineye) on

Wednesday, 29 June 2016

Cargo cults and progressive web app stores

Every city needs a curator
People are seeing that native app platforms have some feature and are then asking for the exact same feature for the web. Instead they should be asking about the job to be done and the benefits users or developers see from a given feature. For example app stores :
  • give an obvious place to find apps that have particular functionality (try searching for "games that don't need wifi" in the Play Store). 
  • give developers an obvious place to find large numbers of users. 
  • give developers a structured mechanism for exposing the features of their app so that users can filter the set of available apps for apps that have those features. 
  • give users an obvious place to review apps. 
  • give developers an obvious place to accrue reputation for their apps. 
  • give platform vendors a place to assert policies that drive developer behaviour.
  • give every app on a platform a canonical URL ( for example here are iOS and Android URLs for the same game).
It's easy to forget that app stores emerged as a response to the difficulties of dealing with carriers to get your content 'on deck'getting your apps preinstalled and the extremely closed nature of that ecosystem. However that's not the job to be done on today's web. Instead what we need is:
  • a plurality of voices and projects pushing the web forwards. 
  • a mechanism where submitting a PWA is as easy as providing a URL therefore anyone can do it.
  • a mechanism where web sites and web apps don't have to provide anything proprietary in order to have a chance of being featured.
  • to build upon the lessons learned from Mozilla's Firefox Marketplace and Chrome's Web Store.
  • something that feels like it's part of the hypertextual web of links rather than a poor copy of native app stores.
Instead of 'cargo culting' the app stores we should be asking what web-centric solutions to the problem would look like. For me that means lots of competing and opinionated PWA directories rather than one central PWA Store or even a popular search engine.

Friday, 10 June 2016

The Social Stack: what’s in and what’s out at the various layers

I wrote this back in late 2010 from August to November. This was around the time of the first and only OpenWebFoo so I was trying to think through the stack of specifications, protocols and standards that would have let us build a federated social web.

I've ensured that all the links still work as of June 2016 but apart from that this represents what I believed all those years ago. I'm posting it here because I want to remember the past. At the same time it's a marker of the end of that particular phase of my life.

Today I can clearly see the connection between

At the time I remember pointing out the incongruity of a closed event about the open and social web. In hindsight I should have been asking questions:
  • Who isn't represented in this room?
  • Why is that?
  • What will be the consequences?

IMG_1234

Discovery
Prefer WebFinger

Security: Identity
OpenId

Relationships
XFN

Security: Authentication
OpenID Connect 

Security: Authorisation
Prefer OpenID Connect/OAuth2

Cross-Site Syndication
Activity Streams
Salmon

Syndication
Prefer Activity Streams (Atom or JSON) over simple Atom or RSS

Realtime syndication
Prefer PubSubHubbub

Profile Data
Prefer Portable Contacts
hCard


Wednesday, 30 September 2015

Guide to implementing App Linking on Android 6.0 Marshmallow

Knives and forks
Android Marshmallow has a feature that can make life better for developers who feel that their app experience is better than their web experience. It's called App Linking and it ensures that your app always handles links for your domain without the disambiguation dialog you would normally see. 
This is the disambiguation dialog I see when I click on a link to Stack Overflow. The feature is called App Linking but the connection between the app and the web site is called an App Link. And, in case you're wondering, it's unrelated to Facebook's AppLinks.org initiative.

This is a short guide to implementing and testing the feature. Let's start.
  1. Go through your manifest and identify the domains (and subdomains) your app claims to be able to support.
  2. Add an assetlinks.json file pointing to your app (or apps) to each of these domains or subdomains. If there's a domain or subdomain that you don't control then the verification process will fail. You can either remove that host from your manifest or you can remove the CATEGORY_BROWSABLE category from the manifest as this will have the same effect: your app won't intercept request for other people's domains or subdomains.
  3. Make sure you serve the assetlinks.json file over HTTPS on every domain or subdomain that you support. Your entire site doesn't have to support HTTPS. Serving just the assetlinks.json file over HTTPS will suffice.
  4. Make sure the assetlinks.json file is served with content-type “application/json” since it won’t work with any other content type.
  5. As documented here you should use our debugging tool to verify that each domain or subdomain has a valid assetlinks.json file. Here's an example for one of my sites.
If everything works you should see a message like this:
Add an autoVerify attribute to the intents in your manifest for each of these domains.
Be aware that the verifier doesn't follow redirects so it won't work if you try to shortcut this by having one canonical file that all the other URLs redirect towards. You can find more details about the install-time verification process by reading this excellent but now outdated guide from Christopher Orr.

Don't forget that all of these files must match exactly so if you update one of them you must update all of them. Fortunately the SHA256 in the assetlinks.json is based on your app's private keys so once you've added your release and debug keys you should never need to change it.

Between this guide and the official documentation you now know everything you need to make App Linking work on Android Marshmallow. If you still have any questions then ask on Stack Overflow using the tag: android-app-linking.

Friday, 19 June 2015

Omnivorous inclusiveness and the closing of the browser parenthesis

In the past I've thought of the web as a convoy of browsers. That turns out to be wrong.

Nowadays (thanks to a long lunch with Paul Downey, Jeni Tennison,  et al) I've begun thinking of the web as a ship of Theseus where, despite replacing every single part of the stack, what's left is still recognisably the web.

This made me realise that we are surrounded by unexamined and ossified metaphors that are in danger of becoming thought-terminating cliches. For example:
- open web versus (presumably) closed web
- the web browser is the web platform is the web
- the web as a platform
- web apps
- web versus native

One of the reasons I present at conferences like OpenTech is because I want to have my mind changed and my complacent metaphors jolted. This year my presentation came out of asking myself "what do I most like about the web?" My initial list was:
- its universality (view source meant everybody everywhere could cut and paste their way to something that sort of worked).
- its omnivorous inclusiveness (it tended to absorb neighbouring or competing technologies like WAIS, Gopher, NNTP and FTP).
- its hypertextuality, intertwingularity and document orientation because they open the door to new forms of argumentation as well as letting us create living documents.
- its peculiar notion of addressability without guarantees about the nature of the resources at the end of the links.

This presentation started out as my oft-repeated but never documented "HTML 3.2 was the last good version of HTML" rant. It channeled some of my distress with the ideas behind HTML 5 and the notion that there is a "web platform" which arbitrarily excludes certain technologies (like Flash and native apps) but includes others (like JavaScript). In its final form it asked if today's open web platform is still the web. Now I have my answer.

That answer is driven by two realisations. Firstly it turns out that browsers are not the only user agent. They're not even the only kind of user agent. Secondly now that deeplinking is becoming mere linking it is clearer than ever that apps are just domain-specific user-agents. As a consequence it becomes clear that native versus web is merely a debate about whether we should use 1 universal user-agent or N domain-specific user-agents.

Since browsers and native apps are merely different kinds of user-agents I think it's a mistake to conflate browsers and the web. I think we run the risk of mistaking the capabilities and roadmap of today's most popular kind of user agent for the capabilities and roadmap of the web. For example user-agents that don't support Javascript or CSS are equally legitimate but less popular constituents of the web. However there's a strong temptation to consider them to be obsolete or lagging members of our convoy and thus leave them behind.

So.

The web has changed, is changing and will keep on changing. The convoy is bigger than I originally thought because there are lots of overlooked user-agents out there. These apps aren't part of the web any more than browsers are but their addressable/linkable content most definitely is part of the web. Just because that content has a preferred user-agent doesn't change this.

Perhaps, like the Gutenberg Parenthesis, there is a 'Browser Parenthesis' that is also closing?



Update: The audio from my OpenTech 2015 talk is now available.

Friday, 2 January 2015

Awkward questions for those boarding the microservices bandwagon

Why isn't this a library?
What heuristics do you use to decide when to build (or extract) a service versus building (or extracting) a library?

How do you plan to deploy your microservices?
What is your deployable unit?
Will you be deploying each microservice in isolation or deploying the set of microservices needed to implement some business functionality?
Are you capable of deploying different instances (where an instance may represent multiple processes on multiple machines) of the same microservice with different configurations?

Is it acceptable for another team to take your code and spin up another instance of your microservice?
Can team A use team B's microservice or are they only used within rather than between teams?
Do you have consumer contacts for your microservices or is it the consumer's responsibility to keep up with the changes to your API?

Is each microservice a snowflake or are there common conventions?
How are these conventions enforced?
How are these conventions documented?
What's involved in supporting these conventions?
Are there common libraries that help with supporting these conventions?

How do you plan to monitor your microservices?
How do you plan to trace the interactions between different microservices in a production environment?

What constitutes a production-ready microservice in your environment?
What does the smallest possible deployable microservice look like in your environment?

2015 technology wishlist

The start of the year is a good time to be thinking about the end of the year and the kind of world I would like to see. Usually this leads to resolutions and predictions. Unfortunately I find most predictions worthless since the pundits seldom go back to check on their previous predictions. The other problem is that people start out making predictions and then the articles turn into wishlists. That's why this year I'm just going to write a wishlist.

I'd like to see:
  • more viable identity providers.
  • more social environments that understand the benefits of Reed's Law and ridiculously easy group-forming.
  • Wikipedia starting to use identity technology to improve the user experience. For example if I donate or become a member then I'd like to stop seeing obnoxious adverts (and they really are adverts) asking for money. The Guardian's membership programme is a good model that Wikipedia should adopt.
  • a viable successor to the Leica M9. The Leica M Type 240 just isn't a big enough improvement.
  • a viable replacement for Aperture. I have zero faith in the upcoming Apple Photos app and there isn't enough official  support for migrating from Aperture to Lightroom.
  • a viable replacement for the old Mac Pro. The new Mac Pro abandons all of the strengths of the old Mac Pro.
  • more mujicomp and less ryanaircomp.
  • fewer people bemoaning the web we lost and more people asking new questions about the world we actually live in where everything gets touched by the network.
  • more device-native apps. I'd like to see more apps that are designed to really exploit the capabilities of our current generation of interconnected mobile devices.
  • more apps that provide multi-device workflows
  • more experience reports about the issues involved in building backend services that support multiple native mobile and web apps.
  • the Software Craftsmanship community changing its focus from converting new people to helping each other learn and grow.
  • less hype/advocacy for microservices and more documentation/descriptions of techniques that work with collections of small services. You'll be able to tell if you're seeing hype by the number of awkward questions that they raise.