AI开发平台MODELARTS-从Manifest文件导入规范说明:文本命名实体

时间:2024-08-16 20:38:57

文本命名实体

{
    "source":"content://Michael Jordan is the most famous basketball player in the world.",
    "usage":"TRAIN",
    "annotation":[
        {
            "type":"modelarts/text_entity",
            "name":"Person",
            "property":{
                "@modelarts:start_index":0,
                "@modelarts:end_index":14
            },
            "annotated-by":"human",
            "creation-time":"2019-01-23 11:30:30"
        },
        {
            "type":"modelarts/text_entity",
            "name":"Category",
            "property":{
                "@modelarts:start_index":34,
                "@modelarts:end_index":44
            },
            "annotated-by":"human",
            "creation-time":"2019-01-23 11:30:30"
        }
    ]
}

“source”“usage”“annotation”等参数说明与图像分类一致,详细说明请参见表1

其中,property的参数解释如表6所示。例如,当“"source":"content://Michael Jordan"”时,如果要提取“Michael”,则对应的“start_index”“0”“end_index”“7”

表6 property参数说明

参数名

数据类型

说明

@modelarts:start_index

Integer

文本的起始位置,值从0开始,包括start_index所指的字符。

@modelarts:end_index

Integer

文本的结束位置,但不包括end_index所指的字符。

support.huaweicloud.com/usermanual-standard-modelarts/dataprepare-modelarts-0015.html