Re: A question about action matching

On Wed, Apr 18, 2012 at 1:12 AM, cheng zheng
<czheng4mailinglist@gmail.com>wrote:

> Hi
>
> I've been thinking this for some time and got several simple ideas.
>
> It seems the spec draft has not *required* (only recommended) that the
> developer should use a fully qualified URI for the action string. I think
> the currently action can be broken down into three parts:
>
> protocol, domain name, real action words
>
> Taking http://webintents.org/edit for example, above three parts are
> http, webintent.org and edit. Among them I think "edit" may take the main
> semantic part because what the developer really want to invoke might be an
> "edit" service.
>
> In android the intent action is composed of package name and action words.
> For example in 'android.intent.action.EDIT", edit may represent the major
> intent of the user.
>
> I agree with Greg that the UA should be responsible for the translation
> part. I was just thinking fully qualification URI for intent invocation
> might not very good if the number of intent grows up. For example, is the
> user more preferable to using simple phrase like "EDIT", or "hotel
> reservation" to invoke intents instead? The process is very similar as what
> we use search engines for searching web pages by a simple bag of words.
>
>
We disagree on this point.  Using (not requiring) fully-qualified URLs
helps intents scale to the level of the web, as opposed to hurting that
effort, because it prevents collisions.  The smaller the namespace, the
more likely collisions are to happen.  Collisions lead to be user
experiences when a service is picked by the user which cannot fulfill the
intent due to collision.  See below for an example.


> As a conclusion, I think exact matching for the action string might not
> have a good scalability to potentially huge amounts of intent action on the
> web. For example, Twitter might more prefer to registering by the intent of
> "https://twitter.com/share", and the developer would like to use "share"
> as a generic action invocation. In that case semantic matching may be more
> appropriate than exact matching.
>
>
Semantic matching will guarantee a high rate of collisions.  In the case
you mentioned, it is perhaps likely that Twitter would like to create a new
intent which has a slightly different protocol than webintents.org/share.
 If we force semantic matching, say by matching x.com/share and y.com/share,
then we'll create a collision.  Clients are explicit about which action
they intend to be serviced; if we try to guess the original intent of the
client, services will be picked by the user which cannot service the intent.

Thanks,
James


>
> On Mon, Apr 16, 2012 at 10:37 AM, Greg Billock <gbillock@google.com>wrote:
>
>> It'd be the responsibility of the UA to translate intents into any
>> kind of system-level construct, including any kind of mapping like
>> this. Windows 8 contracts are another similar system to and from which
>> translation is likely possible.
>>
>>
>> On Mon, Apr 16, 2012 at 12:56 AM, Friedger Müffke
>> <friedger@googlemail.com> wrote:
>> > That sounds like allowing some kind of alias for an action. I don't
>> > think that will work or is intended.
>> > If an Android app wants to take part in the web intents game a
>> > one-to-one translation has to be done by the user agent such that
>> > "android.intent.action.EDIT" is translated into the semantically equal
>> > string "http://webintents.org/edit"
>> >
>> > Friedger
>> >
>> >
>>
>>
>

Received on Thursday, 3 May 2012 18:46:04 UTC