登录
原创

分支文档描述

发布于 2023-11-08 阅读 7565
  • Java EE
原创

测试地址

http://10.0.49.18:8208/

请求参数为json格式

{
"model": "3QqaHp",
"question": "用java写一段 选择排序的代码",
"sid": "eaf1e520-F00-43b9-89de-2e2130dacbeb",
"regenerate": 0
}



参数名 参数类型 是否必须 示例 说明 备注
model string Fbv78 表示渠道,可从渠道列表获取
regenerate int 0 1:是,0:否;1表示重新生成,如果确认为重新生成,则sid必填
question string 苏州最大的湖是什么 表示问题,建议限制7000字以内
sid string 否(regenerate为1时必填) eaf1e520-F00-43b9-89de-2e2130dacbeb 表示聊天id,string类型,如果不填写,表示新建聊天,如果有值,则表示继续上一次对话id为sid的对话进行继续聊天

返回数据格式说明

  • 以data:开头表示正常数据
  • data:[DONE]表示数据结束
  • 不以data:开头的,例如:{“code”:500,“msg”:“数据异常”}表示异常

示例

不同分支对话的效果展示

第一个分支

image.png

第二个分支

image.png

所使用的对话语句

苏州有几个区


curl -H 'content-type: application/json' -H 'Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjE2OTk1OTM5MzYsInVzZXJfaWQiOiI2In0.MkYG3nBcR-ROHvARpEfnWiw-Jsplap73qEeDn-L7v8I'  -d '{"model":"K5-Xj","question":"苏州有几个区"}' http://localhost:8000/api/v1/sse
data:{"code":"0","msg":"success","data":{"content":"苏州市","seq_id":0,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"F00-2a5c-1$HNoJ-NibIlV6-2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"下辖5","seq_id":1,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"F00-2a5c-1$HNoJ-NibIlV6-2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"个区,","seq_id":2,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"F00-2a5c-1$HNoJ-NibIlV6-2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"分别是吴中区","seq_id":3,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"F00-2a5c-1$HNoJ-NibIlV6-2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"、相城区、姑","seq_id":4,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"F00-2a5c-1$HNoJ-NibIlV6-2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"苏区(原平江区、沧浪区、金阊区合并成立)、工业园区、高新区(虎丘区)。","seq_id":5,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"F00-2a5c-1$HNoJ-NibIlV6-2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"同时代管4个县级市:常熟市、昆山市、张家港市、太仓市。","seq_id":6,"is_end":true,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"F00-2a5c-1$HNoJ-NibIlV6-2ea3156e584e"}}

data:[DONE]

有几个镇


curl -H 'content-type: application/json' -H 'Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjE2OTk1OTM5MzYsInVzZXJfaWQiOiI2In0.MkYG3nBcR-ROHvARpEfnWiw-Jsplap73qEeDn-L7v8I'  -d '{"model":"K5-Xj","question":"有几个镇","sid":"F00-2a5c-1$HNoJ-NibIlV6-2ea3156e584e"}' http://localhost:8000/api/v1/sse
data:{"code":"0","msg":"success","data":{"content":"苏州市","seq_id":0,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"V00-2a5c-1$HNoh-NibIr$o-2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"共有**","seq_id":1,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"V00-2a5c-1$HNoh-NibIr$o-2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"51个","seq_id":2,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"V00-2a5c-1$HNoh-NibIr$o-2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"镇**,分别是","seq_id":3,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"V00-2a5c-1$HNoh-NibIr$o-2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":":姑苏区(","seq_id":4,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"V00-2a5c-1$HNoh-NibIr$o-2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"原沧浪区)、虎丘区、吴中区、相城区、工业园区 。","seq_id":5,"is_end":true,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"V00-2a5c-1$HNoh-NibIr$o-2ea3156e584e"}}

data:[DONE]

有几个山

curl -H 'content-type: application/json' -H 'Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjE2OTk1OTM5MzYsInVzZXJfaWQiOiI2In0.MkYG3nBcR-ROHvARpEfnWiw-Jsplap73qEeDn-L7v8I'  -d '{"model":"K5-Xj","question":"有几个山","sid":"V00-2a5c-1$HNoh-NibIr$o-2ea3156e584e"}' http://localhost:8000/api/v1/sse
data:{"code":"0","msg":"success","data":{"content":"苏州市","seq_id":0,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"k00-2a5c-1$HNp3-NibIx2G-2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"共有**","seq_id":1,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"k00-2a5c-1$HNp3-NibIx2G-2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"100","seq_id":2,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"k00-2a5c-1$HNp3-NibIx2G-2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"余座大小山","seq_id":3,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"k00-2a5c-1$HNp3-NibIx2G-2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"体**,主要分布在","seq_id":4,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"k00-2a5c-1$HNp3-NibIx2G-2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"吴中区、虎丘区和常熟市。","seq_id":5,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"k00-2a5c-1$HNp3-NibIx2G-2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"其中穹窿山是苏州市最高峰,海拔341.7米。其他有名的山还有天平山、上方山、灵岩山等等  。","seq_id":6,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"k00-2a5c-1$HNp3-NibIx2G-2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"","seq_id":7,"is_end":true,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"k00-2a5c-1$HNp3-NibIx2G-2ea3156e584e"}}

data:[DONE]

有几个湖

curl -H 'content-type: application/json' -H 'Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjE2OTk1OTM5MzYsInVzZXJfaWQiOiI2In0.MkYG3nBcR-ROHvARpEfnWiw-Jsplap73qEeDn-L7v8I'  -d '{"model":"K5-Xj","question":"有几个湖","sid":"k00-2a5c-1$HNp3-NibIx2G-2ea3156e584e"}' http://localhost:8000/api/v1/sse
data:{"code":"0","msg":"success","data":{"content":"苏州市","seq_id":0,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"1000-2a5c-1$HNpW-NibJ4Hq-2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"有**","seq_id":1,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"1000-2a5c-1$HNpW-NibJ4Hq-2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"154","seq_id":2,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"1000-2a5c-1$HNpW-NibJ4Hq-2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"个湖泊**,","seq_id":3,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"1000-2a5c-1$HNpW-NibJ4Hq-2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"其中苏州占48","seq_id":4,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"1000-2a5c-1$HNpW-NibJ4Hq-2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"个湖泊,几乎是三分之一。","seq_id":5,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"1000-2a5c-1$HNpW-NibJ4Hq-2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"   ","seq_id":6,"is_end":true,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"1000-2a5c-1$HNpW-NibJ4Hq-2ea3156e584e"}}

data:[DONE]

有几个著名的山

curl -H 'content-type: application/json' -H 'Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjE2OTk1OTM5MzYsInVzZXJfaWQiOiI2In0.MkYG3nBcR-ROHvARpEfnWiw-Jsplap73qEeDn-L7v8I'  -d '{"model":"K5-Xj","question":"有几个著名的山","sid":"V00-2a5c-1$HNoh-NibIr$o-2ea3156e584e","regenerate":1}' http://localhost:8000/api/v1/sse
data:{"code":"0","msg":"success","data":{"content":"苏州市","seq_id":0,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"1F00-2a5c-1$HNrs-NibJd-A-2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"有很多著名的","seq_id":1,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"1F00-2a5c-1$HNrs-NibJd-A-2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"山,其中","seq_id":2,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"1F00-2a5c-1$HNrs-NibJd-A-2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"比较有名的有:","seq_id":3,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"1F00-2a5c-1$HNrs-NibJd-A-2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"\n\n","seq_id":4,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"1F00-2a5c-1$HNrs-NibJd-A-2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"- 穹窿山(苏州市)\n- 虎丘山(苏州市)\n","seq_id":5,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"1F00-2a5c-1$HNrs-NibJd-A-2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"- 苏州天平山\n- 西山·缥缈峰(苏州市吴中区)\n- 洞庭东山·莫厘峰(苏州市吴中区)\n","seq_id":6,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"1F00-2a5c-1$HNrs-NibJd-A-2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"- 木渎灵岩山·灵岩山寺(苏州市吴中区)","seq_id":7,"is_end":true,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"1F00-2a5c-1$HNrs-NibJd-A-2ea3156e584e"}}

data:[DONE]

介绍一下天平山


curl -H 'content-type: application/json' -H 'Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjE2OTk1OTM5MzYsInVzZXJfaWQiOiI2In0.MkYG3nBcR-ROHvARpEfnWiw-Jsplap73qEeDn-L7v8I'  -d '{"model":"K5-Xj","question":"介绍一下天平山","sid":"1F00-2a5c-1$HNrs-NibJd-A-2ea3156e584e"}' http://localhost:8000/api/v1/sse
data:{"code":"0","msg":"success","data":{"content":"天","seq_id":0,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"1V00-2a5c-1$HNwS-NibKkg--2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"平山","seq_id":1,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"1V00-2a5c-1$HNwS-NibKkg--2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"是苏州市吴","seq_id":2,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"1V00-2a5c-1$HNwS-NibKkg--2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"中区的一个风景","seq_id":3,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"1V00-2a5c-1$HNwS-NibKkg--2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"名胜区,位于","seq_id":4,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"1V00-2a5c-1$HNwS-NibKkg--2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"苏州市区西边15公里处,海拔201米。","seq_id":5,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"1V00-2a5c-1$HNwS-NibKkg--2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"它因山顶平正而得名,是一个人文及自然景观都比较丰富的景区。天平山山势峭峻奇险,古称白云山,又名赐山,系北宋名臣范仲淹先祖归葬之地。","seq_id":6,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"1V00-2a5c-1$HNwS-NibKkg--2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":" \n\n景区占地近百顷,向以“红枫、奇石、清泉”三绝著称,有万笏朝天、高义叠翠等十八胜景。  每年10-12月红枫节时,斑斓秋色总能吸引无数长枪短炮。","seq_id":7,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"1V00-2a5c-1$HNwS-NibKkg--2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"","seq_id":8,"is_end":true,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"1V00-2a5c-1$HNwS-NibKkg--2ea3156e584e"}}

data:[DONE]

有几个湖

curl -H 'content-type: application/json' -H 'Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjE2OTk1OTM5MzYsInVzZXJfaWQiOiI2In0.MkYG3nBcR-ROHvARpEfnWiw-Jsplap73qEeDn-L7v8I'  -d '{"model":"K5-Xj","question":"有几个湖","sid":"1000-2a5c-1$HNpW-NibJ4Hq-2ea3156e584e"}' http://localhost:8000/api/v1/sse
data:{"code":"0","msg":"success","data":{"content":"苏州市","seq_id":0,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"1k00-2a5c-1$HNxN-NibKzB4-2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"有很多湖","seq_id":1,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"1k00-2a5c-1$HNxN-NibKzB4-2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":",其中最","seq_id":2,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"1k00-2a5c-1$HNxN-NibKzB4-2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"著名的是太湖","seq_id":3,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"1k00-2a5c-1$HNxN-NibKzB4-2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"。","seq_id":4,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"1k00-2a5c-1$HNxN-NibKzB4-2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"此外,苏州市还有阳澄湖、金鸡湖、独墅湖、石湖、后塘湖、盛泽湖、塘大湖、漕湖、尹山湖、沙湖、春申湖、青剑湖、下淹湖等。","seq_id":5,"is_end":true,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"1k00-2a5c-1$HNxN-NibKzB4-2ea3156e584e"}}

data:[DONE]

介绍一下独墅湖

curl -H 'content-type: application/json' -H 'Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjE2OTk1OTM5MzYsInVzZXJfaWQiOiI2In0.MkYG3nBcR-ROHvARpEfnWiw-Jsplap73qEeDn-L7v8I'  -d '{"model":"K5-Xj","question":"介绍一下独墅湖","sid":"1k00-2a5c-1$HNxN-NibKzB4-2ea3156e584e"}' http://localhost:8000/api/v1/sse
data:{"code":"0","msg":"success","data":{"content":"独","seq_id":0,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"2000-2a5c-1$HNyJ-NibLCq6-2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"墅湖","seq_id":1,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"2000-2a5c-1$HNyJ-NibLCq6-2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"又名渎墅","seq_id":2,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"2000-2a5c-1$HNyJ-NibLCq6-2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"湖","seq_id":3,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"2000-2a5c-1$HNyJ-NibLCq6-2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"、渎树","seq_id":4,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"2000-2a5c-1$HNyJ-NibLCq6-2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"湖,属中小型湖泊,是《江苏省湖泊保护名录》中的湖泊之一,位于苏州市工业园区西南部,与吴中区交界,北通","seq_id":5,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"2000-2a5c-1$HNyJ-NibLCq6-2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"金鸡湖与娄江相连,南经斜港接通吴淞江。\n\n独墅湖景色秀丽,湖水清澈,是苏州地区较大的淡水湖之一,比金鸡湖大一倍。","seq_id":6,"is_end":false,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"2000-2a5c-1$HNyJ-NibLCq6-2ea3156e584e"}}

data:{"code":"0","msg":"success","data":{"content":"  独墅湖生态公园位于独墅湖一隅,游人稀少,里面有芦苇、荷塘、河流、桥梁、种类繁多的植物、蛙叫蝉鸣、鸟儿飞翔等自然景观。","seq_id":7,"is_end":true,"uuid":"6ed1f60c-F00-40b3-b56d-2ea3156e584e","sid":"2000-2a5c-1$HNyJ-NibLCq6-2ea3156e584e"}}

data:[DONE]

评论区

眉上的汗水,眉下的泪水,你总要选择一样

0

0

0

举报