龙空技术网

免费中文分词接口

黄禅宗dogstar 118

前言:

此时咱们对“中文分词接口”大约比较注重,各位老铁们都需要剖析一些“中文分词接口”的相关文章。那么小编同时在网络上收集了一些有关“中文分词接口””的相关资讯,希望小伙伴们能喜欢,朋友们快快来了解一下吧!

接口文档:

接口路径:

示例:

对【我爱你中国】这一句进行分词,接口返回结果是:

{    "ret": 200,    "data": {        "err_code": 0,        "err_msg": "",        "words": [        {            "word": "我爱你",            "off": 0,            "len": 9,            "idf": 4.929999828338623,            "attr": "n"        },        {            "word": "中国",            "off": 9,            "len": 6,            "idf": 6.260000228881836,            "attr": "ns"        }        ]    },    "msg": "小白开放接口:App.Scws.GetWords"}

又如,对以下这句话进行分词。

曾经有一段真挚的爱情摆在我面前我没有珍惜

接口结果是:

{    "err_code": 0,    "err_msg": "V3.3.0 YesApi App.Scws.GetWords 2022-04-29 14:14:53",    "words": [        {            "word": "曾经",            "off": 0,            "len": 6,            "idf": 4.909999847412109,            "attr": "d"        },        {            "word": "有",            "off": 6,            "len": 3,            "idf": 0,            "attr": "v"        },        {            "word": "一",            "off": 9,            "len": 3,            "idf": 0,            "attr": "m"        },        {            "word": "段",            "off": 12,            "len": 3,            "idf": 0,            "attr": "q"        },        {            "word": "真挚",            "off": 15,            "len": 6,            "idf": 5.889999866485596,            "attr": "an"        },        {            "word": "的",            "off": 21,            "len": 3,            "idf": 0,            "attr": "uj"        },        {            "word": "爱情",            "off": 24,            "len": 6,            "idf": 4.53000020980835,            "attr": "n"        },        {            "word": "摆在",            "off": 30,            "len": 6,            "idf": 5.639999866485596,            "attr": "v"        },        {            "word": "我",            "off": 36,            "len": 3,            "idf": 0,            "attr": "r"        },        {            "word": "面前",            "off": 39,            "len": 6,            "idf": 4.949999809265137,            "attr": "f"        },        {            "word": "我",            "off": 45,            "len": 3,            "idf": 0,            "attr": "r"        },        {            "word": "没有",            "off": 48,            "len": 6,            "idf": 4.650000095367432,            "attr": "v"        },        {            "word": "珍惜",            "off": 54,            "len": 6,            "idf": 4.940000057220459,            "attr": "v"        }    ]}

标签: #中文分词接口