Can a LocalBusiness have more than one Schema tag?

492 views
Skip to first unread message

alex b

unread,
Jun 16, 2011, 4:51:18 PM6/16/11
to Schema.org Discussion
I can imagine that some businesses may fit into more than one Schema
tag. Will there be a problem with applying more than one? For
example I might want to apply the following tags to a car dealer:
AutoDealer,
AutoRepair, AutoPartsStore if they perform all of these functions of
course. Is this going to fly or is this something we're not
supposed to do?

Guha

unread,
Jun 16, 2011, 6:16:10 PM6/16/11
to schemaorg-...@googlegroups.com
This is certainly a use case that has come up. We are looking into possible solutions for this.

guha

Stéphane Corlosquet

unread,
Jun 16, 2011, 6:21:53 PM6/16/11
to schemaorg-...@googlegroups.com
itemtype is limited to one token/type indeed. I wrote a piece on that limitation, with some ugly markup workarounds (the best I could find):

Steph.

Guha

unread,
Jun 16, 2011, 6:25:36 PM6/16/11
to schemaorg-...@googlegroups.com
We really need to find a solution for this problem.

One of the options that has been proposed is to introduce an explicit property (type) which can be used to specify additional categories that an item is an instance of. 

Would appreciate any thoughts on that.

guha

Philip Jägenstedt

unread,
Jun 17, 2011, 2:43:29 AM6/17/11
to schemaorg-...@googlegroups.com
Jeni Tennison suggested in http://jenitennison.com/blog/node/156 that
Microdata needs to "enable itemtype to take multiple values to support
extensibility". Hixie asked "Did you report these problems to the
schema.org people?" and here we are. I would suggest bringing it up in
the WHATWG together with use cases. This sounds like something to be
addressed in Microdata, rather than with additional properties in the
vocabulary to work around it, if it should be addressed at all.

As for the problem at hand, I think the kind of extensibility you
would get by allowing multiple itemtype's is not very impressive. It
only makes sense if all the types you're using have the exact same
properties, which suggests that perhaps they shouldn't have distinct
types to begin with.

Philip

--
Philip Jägenstedt

Martin Hepp

unread,
Jun 17, 2011, 3:34:45 AM6/17/11
to schemaorg-...@googlegroups.com, Philip Jägenstedt
Hi,
you can use multiple types in Microdata, at least if you eventually consume it in an RDF-based graph environment:


<div itemscope itemtype="http://www.foo.com/Type1" itemid="http://acme.org/things#1">
<a itemprop="http://www.w3.org/1999/02/22-rdf-syntax-ns#type" href="http://www.foo.com/Type2"></a>
</div>

This is e.g. useful if you want to combine schema.org and GoodRelations (http://purl.org/goodrelations/) elements in the same page.

Best
Martin Hepp

--------------------------------------------------------
martin hepp
e-business & web science research group
universitaet der bundeswehr muenchen

e-mail: he...@ebusiness-unibw.org
phone: +49-(0)89-6004-4217
fax: +49-(0)89-6004-4620
www: http://www.unibw.de/ebusiness/ (group)
http://www.heppnetz.de/ (personal)
skype: mfhepp
twitter: mfhepp

Martin Hepp

unread,
Jun 17, 2011, 3:40:20 AM6/17/11
to schemaorg-...@googlegroups.com
Hi,

as said - simply using the full URI of rdf:type would do the trick. This would be compatible with other W3C standards.
Also - using a full URI in such advanced scenarios seems fine from my perspective.

--------------------------------------------------------

alex b

unread,
Jun 17, 2011, 11:23:02 AM6/17/11
to Schema.org Discussion
Just for clarification my initial post did not have to do with using
multiple vocabularies as in:

<div itemscope itemtype="http://schema.org/School" itemref=a></div>
<div itemscope itemtype="http://facebook.com/School" itemref=a></div>
<span id=a itemprop="http://schema.org/classname http://facebook.com/class">A</span>

but in assigning multiple itemTypes from the same vocabulary to some
markup as in:

<div itemscope itemtype="http://schema.org/AutoDealer" itemref=a></
div>
<div itemscope itemtype="http://schema.org/AutoPartsStore" itemref=a></
div>
<div itemscope itemtype="http://schema.org/AutoRepair" itemref=a></
div>

From the second post it sounds like this use case has not been
addressed.



On Jun 17, 12:40 am, Martin Hepp <mfh...@gmail.com> wrote:
> Hi,
>
> as said - simply using the full URI of rdf:type would do the trick. This would be compatible with other W3C standards.
> Also - using a full URI in such advanced scenarios seems fine from my perspective.
>
> MartinOn Jun 17, 2011, at 12:25 AM, Guha wrote:
>
>
>
>
>
> > We really need to find a solution for this problem.
>
> > One of the options that has been proposed is to introduce an explicit property (type) which can be used to specify additional categories that an item is an instance of.
>
> > Would appreciate any thoughts on that.
>
> > guha
>
> > On Thu, Jun 16, 2011 at 3:21 PM, Stéphane Corlosquet <scorlosq...@gmail.com> wrote:
> > itemtype is limited to one token/type indeed. I wrote a piece on that limitation, with some ugly markup workarounds (the best I could find):
> >http://openspring.net/blog/2011/06/10/microdata-multiple-vocabularies
>
> > Steph.
>
> > On Thu, Jun 16, 2011 at 6:16 PM, Guha <g...@google.com> wrote:
> > This is certainly a use case that has come up. We are looking into possible solutions for this.
>
> > guha
>
> > On Thu, Jun 16, 2011 at 1:51 PM, alex b <alex_bramb...@yahoo.com> wrote:
> > I can imagine that some businesses may fit into more than one Schema
> > tag.  Will there be a problem with applying more than one?  For
> > example I might want to apply the following tags to a car dealer:
> > AutoDealer,
> > AutoRepair, AutoPartsStore if they perform all of these functions of
> > course.    Is this going to fly or is this something we're not
> > supposed to do?
>
> --------------------------------------------------------
> martin hepp
> e-business & web science research group
> universitaet der bundeswehr muenchen
>
> e-mail:  h...@ebusiness-unibw.org
> phone:   +49-(0)89-6004-4217
> fax:     +49-(0)89-6004-4620
> www:    http://www.unibw.de/ebusiness/(group)
>          http://www.heppnetz.de/(personal)
> skype:   mfhepp
> twitter: mfhepp- Hide quoted text -
>
> - Show quoted text -

Dzonatas Sol

unread,
Jun 17, 2011, 1:43:25 PM6/17/11
to schemaorg-...@googlegroups.com
On 06/17/2011 08:23 AM, alex b wrote:
> Just for clarification my initial post did not have to do with using
> multiple vocabularies as in:
>
> <div itemscope itemtype="http://schema.org/School" itemref=a></div>
> <div itemscope itemtype="http://facebook.com/School" itemref=a></div>
> <span id=a itemprop="http://schema.org/classname http://facebook.com/class">A</span>
>

And that is the difference in <... class=name style="school:class;
school:classname;">

>> e-business& web science research group


>> universitaet der bundeswehr muenchen
>>
>> e-mail: �h...@ebusiness-unibw.org
>> phone: � +49-(0)89-6004-4217
>> fax: � � +49-(0)89-6004-4620
>> www: � �http://www.unibw.de/ebusiness/(group)
>> � � � � �http://www.heppnetz.de/(personal)
>> skype: � mfhepp
>> twitter: mfhepp- Hide quoted text -
>>
>> - Show quoted text -
>>
>


--
--- http://twitter.com/Dzonatas_Sol ---
Web Development, Software Engineering
Ag-Biotech, Virtual Reality, Consultant

CPa...@muevue.com

unread,
Jun 18, 2011, 1:37:41 AM6/18/11
to schemaorg-...@googlegroups.com
In it's current form it may be flawed as it is being represented. Things fall within multiple categories all the time, whether they be businesses or creative works.  Its just one of those facts of life you live with in knowledge management.  
 Me and my partner are discussing using schema.org for our startup, one of the design aspects is things can have multiple categories in addition to tags.    As it is currently shown you do the specific category on the high level, but this does create issues as it was stated since you cannot do multiple categories at this level.  We have a thought this may not be the best approach, instead we thought keeping the general category at the high level, ie creative work, and not delving into the specific category at this level (ie photograph).  Instead the idea is to nest the multiple categories below this high level. 

Not sure how the schema.org and google folks feel about this, but it is what my CTO (an old manager from AOL search during its heyday in the 1990s) thought would work.  

Basically (arbitrary example):

ex.
Creative Work
       Photograph
       Recipe

Suggestion in terms of HTML:
  <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" >
<head>
    <title>Untitled Page</title>
</head>
<body itemscope itemtype="http://schema.org/WebPage">
    <div itemprop="breadcrumb">
        <a href="category/photographs.html">Photographs</a>
        <a href="category/photographsOfReceipies">Photographs of Receipes</a>
    </div>
 
    <!--Alternate BreadCrumbs... -->
    
    <div itemprop="breadcrumb">
        <a href="category/Receipes.html">Receipes</a>
        <a href="category/ReceipiesInPhotographcs">Receipies in Photographs</a>
    </div>
 
    <div itemscope itemtype="http://schema.org/CreativeWork">
        <span itemprop="name">Mom's World Famous Banana Bread</span> By <span itemprop="author">
            John Smith</span>,
        <meta itemprop="publishDate" content="2009-05-08">
        May 8, 2009
        <img itemprop="image" src="bananabread.jpg" />
        <span itemprop="description">This classic banana bread recipe comes from my mom -- the
            walnuts add a nice texture and flavor to the banana bread.</span>
 
        <div itemscope itemtype="http://schema.org/Photograph">
        </div>
        <div itemscope itemtype="http://schema.org/Recipe">
             Prep Time:
            <meta itemprop="prepTime" content="PT15M">
            15 minutes Cook time:
            <meta itemprop="cookTime" content="PT1H">
            1 hour Yield: <span itemprop="recipeYield">1 loaf</span>
            <div itemprop="nutrition" itemscope itemtype="http://schema.org/NutritionInformation">
                Nutrition facts: <span itemprop="calories">240 calories</span><span itemprop="fatContent">
                    9 grams fat</span>
            </div>
            Ingredients: - <span itemprop="ingredients">3 or 4 ripe bananas, smashed</span>
            - <span itemprop="ingredients">1 egg</span> - <span itemprop="ingredients">3/4 cup of
                sugar</span> ... Instructions: <span itemprop="recipeInstructions">Preheat the oven
                    to 350 degrees. Mix in the ingredients in a bowl. Add the flour last. Pour the mixture
                    into a loaf pan and bake for one hour. </span>140 comments:
            <meta itemprop="interactionCount" content="UserComments:140" />
            From Janel, May 5 -- thank you, great recipe! ...
        </div>
    </div>
    
</body>
</html>
 

chj...@microsoft.com

unread,
Jun 18, 2011, 2:21:15 AM6/18/11
to Schema.org Discussion

This could be one potential solution. What is the original thinking
behind not allowing multiple types in microdata? Is it to prevent
multiple inheritance issue just like in OO programming? If that is
the case, ensuring no conflict in property names from different paths
could be challenging.

chj...@microsoft.com

unread,
Jun 18, 2011, 2:27:11 AM6/18/11
to Schema.org Discussion
The previous post is meant for replying Philip's post.

chj...@microsoft.com

unread,
Jun 18, 2011, 2:51:51 AM6/18/11
to Schema.org Discussion
To CPaluch,

The problem with your approach is that you are treating Recipe and
Photograph as contained by, rather than inherit from, CreativeWork. In
the example you provided, the Recipe item actually lost values of
"name", "publishDate", "image" and description" provided in the
CreativeWork item.

Your specific example can actually be solved by introducing a "photos"
property in Recipe.
Message has been deleted

Charlie Jiang

unread,
Jun 18, 2011, 1:08:49 PM6/18/11
to schemaorg-...@googlegroups.com
This is an interesting perspective. If I parse it right, the following two lines in your example:

<div itemscope itemtype="http://schema.org/Photograph">

<div itemscope itemtype="http://schema.org/Recipe">

are not meant to introduce two items, but rather to introduce a set of properties for each category the creative work item may belongs to.

-----Original Message-----
From: schemaorg-...@googlegroups.com [mailto:schemaorg-...@googlegroups.com] On Behalf Of Christine Paluch
Sent: Saturday, June 18, 2011 9:08 AM
To: Schema.org Discussion
Subject: Re: Can a LocalBusiness have more than one Schema tag?

You are saying the recipe itself lost those properties, not the creative work?
The thing is from our perspective it is just a creative work, but creative works have multiple categories. This is not an inherit of situation as you may think. We will not necessarily know at the category level if one thing is inherit of another. To us it is a creative work with multiple categories. Better example...a mixed media art piece.

These are the categories
Photograph
Painting
Mixed Media
Digital Art


We don't know what the art piece looks like. We cannot manipulate or figure out what categories there are and how they relate. To us this is just a creative work somebody submitted with multiple categories.
The art piece probably falls under all of these categories. What should we do...
Call it a creative work, and contain the categories within it. You are not saying you lose the properties of creative work are you? No these categories are contained within a creative work, it is still in fact a creative work. But these categories are all important, they are what the thing is. The creative work is multiple things, but ultimately still a creative work. You cannot have painting and photograph both at the high level, the inherit of level, but this piece from our perspective contains both (it is inherently a painting and a photograph, among other things). It may be a painting which contained a photograph that was then digitally manipulated. The system itself is blind, and it is not individuals doing the markup, its programmed machines.

Ultimately though, we do not know. To us the categories are always "contained within" a creative work, rather than "inherit of", that may be the flaw of schema, the "inherit of" and limiting things to one category at top. Since there is no way of knowing the primary nature of a creative work. That is the problem with putting a category at a high level as the examples are on schema, a thing can have multiple categories, be it a business or a creative work. Making something "inherit of" on a category basis, and only allowing it once, loses something. The best thing to do is expand on what can be contained within creative work, and allow "contained within" to deal with categories as an alternative.

The advice may be to expand creative work, and what can be contained within a creative work, derived from it.

To us the recipe and the photograph are one creative work. We don't see the recipe as the "inherit of" part of what it is, again the photograph may be the "inherit of". We have no way of knowing, it may be a photographers artistic picture of an old recipe, rather than a recipe that contains an image. To us it is a single creative work that contains multiple categories, and while something may be lost, it is still just a single creative work with user assigned categories, and the relationship of these categories we are blind to as well.

Again...our perspective and may be a different way of thinking out it. Custom doing attributes to each creative work and the "inherit of" aspect at the high level for what are essentially categories may be what is part of the problem. You may have to treat creative work in a general sense and allow for multiple attributes, including multiple categories in our perspective.
Yes, something may be lost, but in reality it may be more reflective of how things whether they be creative works or businesses, often have multiple categories.

Christine Paluch

unread,
Jun 18, 2011, 1:36:08 PM6/18/11
to Schema.org Discussion
That is the thought CJ. We may have come up with a better solution
though if another message of mine pop up other than this I will be
deleting it.
Message has been deleted

chj...@microsoft.com

unread,
Jun 18, 2011, 8:31:47 PM6/18/11
to Schema.org Discussion
Where is it? Can you re-post? I am hoping you resolved the syntax
problem ;-)

Guha

unread,
Jun 19, 2011, 6:51:16 PM6/19/11
to schemaorg-...@googlegroups.com
The markup you are using here should work fine. You can also use itemID instead of itemref.

guha

Guha

unread,
Jun 19, 2011, 6:53:19 PM6/19/11
to schemaorg-...@googlegroups.com
Just to be clear, something can be in multiple categories currently. The problem is that the syntax is not as simple as we would like it to be.

guha
Reply all
Reply to author
Forward
0 new messages