RDF:我如何将schema.org:travelaction:agent:organization链接到health-lifesci.schema.org:MedicalBusiness子类别?

时间:2017-01-27 23:24:25

标签: html5 rdf schema.org

我有这样的情况:

<div prefix='schema: http://schema.org/ health-lifesci: https://health-lifesci.schema.org' typeof='schema:TravelAction'>
...  
  <div property='schema:agent' typeof='health-lifesci:Dermatology'>
    <meta property='schema:name' content='My Doctor' />
...
  </div>
</div>

DermatologyMedicalBusinessOrganization。这显示在schema.org的relevant page中。

但是,structured data tool会将其识别为Thing

agent

   @type        Thing

   name         My Doctor

我做错了什么?

1 个答案:

答案 0 :(得分:1)

Schema.org扩展程序(如health-lifesci)也使用核心名称空间http://schema.org/

扩展中的每个术语都列出了应该使用的规范URI。在http://health-lifesci.schema.org/Dermatology,它说:

  

规范网址:http://schema.org/Dermatology

所以你的HTML + RDFa应该是:

<div prefix='schema: http://schema.org/' typeof='schema:TravelAction'>
  <div property='schema:agent' typeof='schema:Dermatology'>
    <meta property='schema:name' content='My Doctor' />
  </div>
</div>

但是,Dermatology type不是agent property的预期值。它需要OrganizationPerson值,但Dermatology不是;它是MedicalSpecialty枚举值。

(我不确定为什么Dermatology被列为MedicalBusiness的子类型,但未将其列为its page的父级。)