Bo Jackson Player Profile - difficulty describing team he plays for

21 views
Skip to first unread message

Jason Johnson

unread,
Jan 15, 2014, 9:41:54 PM1/15/14
to sports-sch...@googlegroups.com
I was working through an example testing out of ability to define the relationship between a player and an organization and I'm struggling with what appears to be a need to switch back and forth between different item scopes.  I'm about as rusty in writing HTML markup as you can get, so excuse any poor or improper structure (in fact, feel free to re-write it if you want :P).  See comments inline for where I'm looking for your thoughts.

http://espn.go.com/mlb/player/stats/_/id/1744/bo-jackson

 

<!-- original markup -->

<table>

  <tr>

    <td>Name</td>

  </tr>

  <tr>

    <td>Bo Jackson</td>

  </tr>

</table>

<table>

  <tr>

    <td>Year</td>

    <td>Team</td>

    <td>Batting Avg</td>

    <td>Hits</td>

  </tr>

  <tr>

    <td>1997</td>

    <td>KC Royals</td>

    <td>.300</td>

    <td>256</td>

  </tr>

</table>

 

<!-- add new schema.org sports semantics -->

<table>

  <tr>

    <td>Name</td>

  </tr>

  <tr>

    <td>

      <div itemscope itemtype="Person" itemid="/mlb/players/BoJackson">

        <span itemprop="name">Bo Jackson</span>

      </div>

    </td>

  </tr>

</table>

<table>

  <tr>

    <td>Year</td>

    <td>Team</td>

    <td>Batting Avg</td>

    <td>Hits</td>

  </tr>

  <tr>

    <td>1997</td>

    <td>

      <div itemscope itemtype="BaseballTeam" itemid="/mlb/teams/kansasCityRoyals">

        <span itemprop="name">Kansas City Royals</span>

        <!-- is this the only way to tie this information back to the person this page is about? -->

        <!-- in other words, is this the only way to indicate Bo Jackson played for the Kansas City Royals? -->

        <!-- do we need syntactic sugar of inverse property 'playsLeftFieldFor' ... -->

        <!-- ... to allow for staying in context of original itemscope? -->

        <meta itemprop="leftFielder" itemid="/mlb/players/BoJackson">

      <div>

    </td>

    <td>

      <!-- since we had to step out of scope to define the team the person played for -->

      <!-- we have to re-establish the scope as the person -->

      <div itemscope itemtype="Person" itemid="/mlb/players/BoJackson">

        <div itemprop="statistics" itemscope itemtype="BaseballStatistic">

          <span itemprop="battingAvg">.300</span>

        </div>

      </div>

    </td>

    <td>256</td>

  </tr>

</table>

Jason Johnson

unread,
Jan 15, 2014, 9:46:12 PM1/15/14
to sports-sch...@googlegroups.com
For further illustration, let's assume we had a property called 'leftFielderFor' on 'Person', then we could simplify things and instead have something like this:

<div itemscope itemtype="Person" itemid="/mlb/players/BoJackson">

<table>

  <tr>

    <td>Name</td>

  </tr>

  <tr>

    <td>

      <span itemprop="name">Bo Jackson</span>     

    </td>

  </tr>

</table>

<table>

  <tr>

    <td>Year</td>

    <td>Team</td>

    <td>Batting Avg</td>

    <td>Hits</td>

  </tr>

  <tr>

    <td>1997</td>

    <td>

      <div itemprop="leftFielderFor" itemscope itemtype="BaseballTeam">

        <span itemprop="name">Kansas City Royals</span>

      <div>

    </td>

    <td>

      <div itemprop="statistics" itemscope itemtype="BaseballStatistic">

        <span itemprop="battingAvg">.300</span>

      </div>

     </td>

    <td>256</td>

  </tr>

</table>

</div>

Tom Grahame

unread,
Jan 16, 2014, 9:21:10 AM1/16/14
to sports-sch...@googlegroups.com
I'd suggest that inverse properties applied on one property might have to be applied to many, I'm not sure if Schema.org has a recommendation about that.

The direction of properties is important and should probably be consistent within this model.

There may also be design patterns concerning modifying HTML to accommodate the semantic markup, again I'm not sure what the precedent here might be. Certainly the Yandex structured data tester appears to prefer the second example, where the total is wrapped in a <div> element:

Vicki Tardif Holland

unread,
Jan 16, 2014, 9:48:34 AM1/16/14
to sports-sch...@googlegroups.com
Examples like this are why people are pushing for using JSON-LD. Mixing up the presentation markup with the semantic markup can only go so far.

One idea is to split up the semantics. You could state that Bo Jackson "playsLeftField" and then in another section state he is a member of the Kansas City Royals. It would require having a BaseBallPlayer type to hold the position properties.

- Vicki


Vicki Tardif Holland | Ontologist | vta...@google.com 
 


--
You received this message because you are subscribed to the Google Groups "sports-schema-collab" group.
To unsubscribe from this group and stop receiving emails from it, send an email to sports-schema-co...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Reply all
Reply to author
Forward
0 new messages