首页 > 解决方案 > GATE 手动注释:一种类型的更多功能

问题描述

我正在对 GATE 中的语料库进行手动注释。所以我在 xml 中创建了我的注释模式:

<element name="extragraphique">
    <complexType>
      <attribute name="kind" use="optional" value="other" >
        <simpleType>
          <restriction base="string">
            <enumeration value="confusion_voyelle"/>
            <enumeration value="confusion_consonne"/>
          </restriction>
        </simpleType>   
      </attribute>
    </complexType>
  </element>
</schema>

结果注释如下所示:

门注释

但我想为一种注释类型(元素)注释更多特征(值)。这可能吗?再声明一个值不是一种选择,因为 GATE 只会让我选择一个特征值:

注释工具

标签: xmlgate

解决方案


我认为您需要向架构添加第二个属性:

<?xml version="1.0"?> 
<schema xmlns="http://www.w3.org/2000/10/XMLSchema">  
  <element name="extragraphique">
    <complexType>
      <attribute name="kind" use="optional" value="other" >
        <simpleType>
          <restriction base="string">
            <enumeration value="confusion_voyelle"/>
            <enumeration value="confusion_consonne"/>
          </restriction>
        </simpleType>   
      </attribute>
      <attribute name="confidence" use="optional" value="other" >
        <simpleType>
          <restriction base="string">
            <enumeration value="low"/>
            <enumeration value="high"/>
          </restriction>
        </simpleType> 
      </attribute>
    </complexType>
  </element>
</schema>

GATE 截图:

门截图

来自 GATE 文档的附加信息:


推荐阅读