Re: Actions in Schema.org and ActivityStrea.ms

On Thu, May 16, 2013 at 2:25 PM, Yaar Schnitman <yaar@google.com> wrote:
> Multiple people commented about the relationship of ActivityStrea.ms and
> Schema.org. We discussed Actions with various ActivityStrea.ms contributors
> as the proposal evolved. Here is a summary
>
> Schema.org actions focus on being able to fully and precisely describe an
> action, so it can be understood and executed reliably in a distributed
> system. ActivityStrea.ms is focused on the aggregation of actions into long
> streams, and focuses less on the preciseness of the actions themselves.
>

That's not completely true, really. Activity Streams objects are
entirely capable of "standing alone" without the notion of a stream.

The key difference between the schema.org and activitystrea.ms
approach, from what I can see, is that the schema.org proposal takes a
more strongly-typed point of view, preferring to define individual
types of actions in much more concrete and specific terms than
activitystrea.ms.. which takes a more generic, loosely bound approach.

> Therefore, in schema.org, verbs are 1st class types with modifiers that can
> precisely express nuances about the action. In addition, schema.org
> standardizes of the list of common actions and their properties.
>
> Here are some thoughts of how ActiviyStrea.ms & Schema.org Actions could
> play along:
>
> 1. Surely the schema.org/Action type needs some extra properties to line up
> with ActivityStrea.ms. For example, "provider". This is trivial to do.
>
> 2. ActivityStrea.ms's "verb" property could line up with the "type" property
> of the action. For instance. I think this is achievable, and one idea is
> that just like ActivityStrea.ms may use schema.org for objects (e.g.
> http://schema.org/Movie), it can use schema.org types for verbs (e.g.
> http://schema.org/ViewAction).
>

It is trivially possible to use schema.org identifiers as Verb and
Object identifiers in an activitystrea.ms object. It is also possible
to extend the activitystrea.ms vocabulary to include the full range of
schema.org properties. See [1]...

[1] http://activitystrea.ms/specs/json/schema/activity-schema.html#schema_org

Using this approach, we can already model a JSON Activity Streams
object in schema.org terms... for instance...

{
  "verb": "http://schema.org/LogInAction",
  "object": {
    "objectType": "service",
    "displayName": "mysite.com"
  },
  "schema_org": {
    "status": "TENTATIVE",
    "handler": {
      "@type": "http://schema.org/WebHandler",
      "url": "http://mysite.com/login"
    }
  }
}

It's certainly less concise than the schema.org examples, due to
activitystrea.ms focus on generic, extensible object descriptions, but
it works.

> 3. Unlike ActivityStrea.ms, schema.org Actions don't have common "object"
> and "target" properties. This is intentional (reasoning will follow shortly
> in another thread). Instead, each action sub-type has its own named, typed
> properties. There is actually an effort in ActivityStrea.ms to standardize
> which verb/object/target combinations go together. If there is a strong
> need, we can also standardize to which schema.org action type and its
> properties these combinations map too.
>

Well... there's been discussion about whether we need to standardize
verb/object/target combinations... and I have a proposal on the table
for how to describe various verb/object/target combinations.

The main focus in activitystrea.ms has always been on more generic
definitions, with more specificity provided through extension.

- James

> These are just thoughts, and the schema.org & activitystrea.ms should
> continue discussing how to make things fit together nicely.
>
> -Yaar

Received on Monday, 20 May 2013 22:38:53 UTC