AI写作智能体 自主规划任务,支持联网查询和网页读取,多模态高效创作各类分析报告、商业计划、营销方案、教学内容等。 广告
安装gateway worker 在服务器站点配置文件里编辑: 添加一下内容 ``` location /wss { proxy_pass http://127.0.0.1:2348; proxy_http_version 1.1; proxy_set_header Upgrade $http_upgrade; proxy_set_header Connection "Upgrade"; proxy_set_header X-Real-IP $remote_addr; } ``` 在js调用里使用以下地址: ~~~ var url = "wss://网站网址域名/wss"; socket = new WebSocket(url); socket.onopen = function () { console.log('连接成功~~~~') } socket.onmessage = function (res) { let getRes = jQuery.parseJSON(res.data); if(getRes.type=='print_shuiba'){ } socket.onclose = function () { console.log('断开连接') } } ~~~