OCSxAI/ocs_config.json

19 lines
546 B
JSON

[
{
"url": "http://127.0.0.1:8777/api/search",
"name": "AI 智能搜题",
"method": "post",
"contentType": "json",
"data": {
"title": "${title}",
"type": "${type}",
"options": "${options}",
"images": {
"handler": "return (env)=> env.images || []"
},
"suggestion_title": "${suggestion_title}",
"suggestion_options": "${suggestion_options}"
},
"handler": "return (res)=> res.code === 1 ? [res.question, res.answer] : (res.msg ? [res.msg, undefined] : undefined)"
}
]