From 6e684ebbe881c11dfe9b6c5c893cab151f664ce7 Mon Sep 17 00:00:00 2001 From: jinfengli Date: Tue, 31 Aug 2021 15:03:05 +0800 Subject: [PATCH] 意图搜索第二版api文档更新 --- dramaeditor/intent_search.md | 58 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 57 insertions(+), 1 deletion(-) diff --git a/dramaeditor/intent_search.md b/dramaeditor/intent_search.md index 6a207d8..35f5472 100644 --- a/dramaeditor/intent_search.md +++ b/dramaeditor/intent_search.md @@ -1,6 +1,6 @@ BaseURL: https://hw-gz26.heyqiwu.cn -##### 获取领域配置 +##### 意图搜索 URL: {backUrl}/api/juben/intent/query?secret=f1fvo0Yhw199PIHWTmCbbQ @@ -52,4 +52,60 @@ curl --location --request POST 'https://hw-gz26.heyqiwu.cn/api/juben/intent/quer "看看我" ] }' +``` + +BaseURL: https://hw-gz26.heyqiwu.cn + +##### 意图搜索第二版 + +URL: {backUrl}/api/juben/intent/query/v2?secret=f1fvo0Yhw199PIHWTmCbbQ + +METHOD: POST + +RequestHeaders: + +| key | value | +| :----------- | :------------ | +| Content-Type | application/json;charset=utf-8 | +| Authorization | TOKEN | + +RequestBody: + +``` +{ + "sents":[ // 句子列表 + "同意陪伴" + ] +} +``` + +ResponseBody: + +``` +SUCCESS: +{ + "code": 1, + "msg": "成功", + "data": [ + { + "intentName": "同意陪", // 意图名称 + "allMatch": true // true表示全匹配, false表示模糊匹配 + }, + { + "intentName": "质疑对方是假的", + "allMatch": false + } + ] +} +``` + +Example: +``` +curl --location --request POST 'https://hw-gz26.heyqiwu.cn/api/juben/intent/query/v2?secret=f1fvo0Yhw199PIHWTmCbbQ' \ +--header 'Content-Type: application/json' \ +--data-raw '{ + "sents":[ + "同意陪伴" + ] +}' ``` \ No newline at end of file -- libgit2 0.27.1