lsc 6 ماه پیش
والد
کامیت
a7a8bbcd00

+ 1 - 1
dist/index.html

@@ -32,7 +32,7 @@
       width: 100%;
       background: #e6eaf0;
       font-family: '黑体';
-    }</style><link href=./static/css/app.e29fcea520ae81b3d7b8fd531e8828b5.css rel=stylesheet></head><body><div id=app></div><script type=text/javascript src=./static/js/manifest.00bfcafc8431113801f1.js></script><script type=text/javascript src=./static/js/vendor.a285ee7d73c7e5aca603.js></script><script type=text/javascript src=./static/js/app.ec9fc7e609cf32e4f538.js></script></body></html><script>function stopSafari() {
+    }</style><link href=./static/css/app.64220cce724e8009d1e0f08b0c990718.css rel=stylesheet></head><body><div id=app></div><script type=text/javascript src=./static/js/manifest.571c38d63f24b1ae9e16.js></script><script type=text/javascript src=./static/js/vendor.382e92fdebaf6164bf93.js></script><script type=text/javascript src=./static/js/app.d9ad142a47ce19af6efe.js></script></body></html><script>function stopSafari() {
     //阻止safari浏览器双击放大功能
     let lastTouchEnd = 0  //更新手指弹起的时间
     document.documentElement.addEventListener("touchstart", function (event) {

تفاوت فایلی نمایش داده نمی شود زیرا این فایل بسیار بزرگ است
+ 0 - 0
dist/static/css/app.64220cce724e8009d1e0f08b0c990718.css


تفاوت فایلی نمایش داده نمی شود زیرا این فایل بسیار بزرگ است
+ 0 - 0
dist/static/css/app.64220cce724e8009d1e0f08b0c990718.css.map


تفاوت فایلی نمایش داده نمی شود زیرا این فایل بسیار بزرگ است
+ 0 - 0
dist/static/css/app.e29fcea520ae81b3d7b8fd531e8828b5.css


تفاوت فایلی نمایش داده نمی شود زیرا این فایل بسیار بزرگ است
+ 0 - 0
dist/static/css/app.e29fcea520ae81b3d7b8fd531e8828b5.css.map


+ 0 - 0
dist/static/img/videoFile.2273786.svg → dist/static/img/videoFile.8b2406f.svg


تفاوت فایلی نمایش داده نمی شود زیرا این فایل بسیار بزرگ است
+ 0 - 0
dist/static/js/0.4f3b05586c3acc102a54.js.map


تفاوت فایلی نمایش داده نمی شود زیرا این فایل بسیار بزرگ است
+ 0 - 0
dist/static/js/0.7da288988865a9378b49.js


تفاوت فایلی نمایش داده نمی شود زیرا این فایل بسیار بزرگ است
+ 0 - 0
dist/static/js/0.7da288988865a9378b49.js.map


تفاوت فایلی نمایش داده نمی شود زیرا این فایل بسیار بزرگ است
+ 0 - 0
dist/static/js/app.d9ad142a47ce19af6efe.js


تفاوت فایلی نمایش داده نمی شود زیرا این فایل بسیار بزرگ است
+ 0 - 0
dist/static/js/app.d9ad142a47ce19af6efe.js.map


+ 2 - 2
dist/static/js/manifest.00bfcafc8431113801f1.js → dist/static/js/manifest.571c38d63f24b1ae9e16.js

@@ -1,2 +1,2 @@
-!function(e){var n=window.webpackJsonp;window.webpackJsonp=function(r,c,a){for(var i,u,f,s=0,l=[];s<r.length;s++)u=r[s],t[u]&&l.push(t[u][0]),t[u]=0;for(i in c)Object.prototype.hasOwnProperty.call(c,i)&&(e[i]=c[i]);for(n&&n(r,c,a);l.length;)l.shift()();if(a)for(s=0;s<a.length;s++)f=o(o.s=a[s]);return f};var r={},t={6:0};function o(n){if(r[n])return r[n].exports;var t=r[n]={i:n,l:!1,exports:{}};return e[n].call(t.exports,t,t.exports,o),t.l=!0,t.exports}o.e=function(e){var n=t[e];if(0===n)return new Promise(function(e){e()});if(n)return n[2];var r=new Promise(function(r,o){n=t[e]=[r,o]});n[2]=r;var c=document.getElementsByTagName("head")[0],a=document.createElement("script");a.type="text/javascript",a.charset="utf-8",a.async=!0,a.timeout=12e4,o.nc&&a.setAttribute("nonce",o.nc),a.src=o.p+"static/js/"+e+"."+{0:"4f3b05586c3acc102a54",1:"d8d4e9b1fe43bbb0a681",2:"94e1427bfc7ef0b4c685",3:"3a9f53a78da16650e6b8"}[e]+".js";var i=setTimeout(u,12e4);function u(){a.onerror=a.onload=null,clearTimeout(i);var n=t[e];0!==n&&(n&&n[1](new Error("Loading chunk "+e+" failed.")),t[e]=void 0)}return a.onerror=a.onload=u,c.appendChild(a),r},o.m=e,o.c=r,o.d=function(e,n,r){o.o(e,n)||Object.defineProperty(e,n,{configurable:!1,enumerable:!0,get:r})},o.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return o.d(n,"a",n),n},o.o=function(e,n){return Object.prototype.hasOwnProperty.call(e,n)},o.p="./",o.oe=function(e){throw console.error(e),e}}([]);
-//# sourceMappingURL=manifest.00bfcafc8431113801f1.js.map
+!function(e){var n=window.webpackJsonp;window.webpackJsonp=function(r,a,c){for(var i,u,f,s=0,l=[];s<r.length;s++)u=r[s],t[u]&&l.push(t[u][0]),t[u]=0;for(i in a)Object.prototype.hasOwnProperty.call(a,i)&&(e[i]=a[i]);for(n&&n(r,a,c);l.length;)l.shift()();if(c)for(s=0;s<c.length;s++)f=o(o.s=c[s]);return f};var r={},t={6:0};function o(n){if(r[n])return r[n].exports;var t=r[n]={i:n,l:!1,exports:{}};return e[n].call(t.exports,t,t.exports,o),t.l=!0,t.exports}o.e=function(e){var n=t[e];if(0===n)return new Promise(function(e){e()});if(n)return n[2];var r=new Promise(function(r,o){n=t[e]=[r,o]});n[2]=r;var a=document.getElementsByTagName("head")[0],c=document.createElement("script");c.type="text/javascript",c.charset="utf-8",c.async=!0,c.timeout=12e4,o.nc&&c.setAttribute("nonce",o.nc),c.src=o.p+"static/js/"+e+"."+{0:"7da288988865a9378b49",1:"d8d4e9b1fe43bbb0a681",2:"94e1427bfc7ef0b4c685",3:"3a9f53a78da16650e6b8"}[e]+".js";var i=setTimeout(u,12e4);function u(){c.onerror=c.onload=null,clearTimeout(i);var n=t[e];0!==n&&(n&&n[1](new Error("Loading chunk "+e+" failed.")),t[e]=void 0)}return c.onerror=c.onload=u,a.appendChild(c),r},o.m=e,o.c=r,o.d=function(e,n,r){o.o(e,n)||Object.defineProperty(e,n,{configurable:!1,enumerable:!0,get:r})},o.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return o.d(n,"a",n),n},o.o=function(e,n){return Object.prototype.hasOwnProperty.call(e,n)},o.p="./",o.oe=function(e){throw console.error(e),e}}([]);
+//# sourceMappingURL=manifest.571c38d63f24b1ae9e16.js.map

تفاوت فایلی نمایش داده نمی شود زیرا این فایل بسیار بزرگ است
+ 0 - 0
dist/static/js/manifest.571c38d63f24b1ae9e16.js.map


تفاوت فایلی نمایش داده نمی شود زیرا این فایل بسیار بزرگ است
+ 0 - 0
dist/static/js/vendor.382e92fdebaf6164bf93.js


تفاوت فایلی نمایش داده نمی شود زیرا این فایل بسیار بزرگ است
+ 0 - 0
dist/static/js/vendor.382e92fdebaf6164bf93.js.map


+ 27 - 0
src/assets/css/button.css

@@ -53,6 +53,33 @@
   margin-left: 20px;
 }
 
+.c_pub_button_confirm3 {
+  color: #478cff;
+  background-color: #e2eeff;
+  padding: 0 24px;
+  font-size: 14px;
+  min-width: 64px;
+  font-weight: 500;
+  border-radius: 4px;
+  box-sizing: border-box;
+  border: none;
+  cursor: pointer;
+  transition: all 0.2s ease-in-out;
+  height: 36px;
+  display: flex;
+  align-items: center;
+  justify-content: center;
+  line-height: 1;
+}
+
+.c_pub_button_confirm3:hover {
+  background-color: #d3e6ff !important;
+  color: #478cff !important;
+}
+
+.c_pub_button_confirm3 + .c_pub_button_confirm3 {
+  margin-left: 20px;
+}
 
 .c_pub_button_add {
   color: #0061FF;

BIN
src/assets/icon/course/courseName.png


+ 1 - 1
src/common/axios.config.js

@@ -28,7 +28,7 @@ axios.interceptors.request.use((config) => {
     // }
     if (config.url === 'https://gpt.cocorobo.cn/search_image' || config.url === 'https://gpt.cocorobo.cn/chat' || config.url === 'https://gpt4.cocorobo.cn/create_free_assistants' || config.url === 'https://gpt4.cocorobo.cn/assistants_completion_response') {
         config.data = config.data//序列化post 参数
-    } else if (config.url.indexOf('https://gpt4.cocorobo.cn/') != -1 || config.url.indexOf('https://claude3.cocorobo.cn/') != -1) {
+    } else if (config.url.indexOf('https://gpt4.cocorobo.cn/') != -1 || config.url.indexOf('https://claude3.cocorobo.cn/') != -1 || config.url.indexOf('https://llm.cocorobo.cn/') != -1) {
         config.headers = {
             'Content-Type': 'application/json',
         }

+ 29 - 9
src/components/pages/aiAddCourse/addCourse.vue

@@ -2404,19 +2404,17 @@
               </div>
               <div class="rb_c_box_right">
                 <div class="rb_c_box_btn" style="justify-content: flex-end">
+                  <span class="title">{{ courseName }}</span>
                   <!-- <button class="c_pub_button_add pub_btn_paste_img" @click="pasteTask" v-if="steps == 3">智能粘贴</button> -->
-                  <button class="c_pub_button_return pub_btn_last_img"
-                    v-if="steps > 1 && steps != 5 && istemplate != 1" @click="lastSteps" style="background: #dbdbdb">
+                  <button class="c_pub_button_return"
+                    v-if="steps > 1 && steps != 5 && istemplate != 1" @click="lastSteps" style="margin-left: auto;border: none;">
                     {{ steps == 4 ? "返回课程" : "上一步" }}
                   </button>
-                  <button class="c_pub_button_confirm" v-if="steps < 4 && istemplate != 1" @click="nextSteps" :class="{
-                    pub_btn_next_img: steps != 3,
-                    pub_btn_finish_img: steps == 3,
-                  }">
+                  <button class="c_pub_button_confirm3" style="margin: 0 0 0 10px;" @click="openAiDialog2(2, 'aiTask3','all'), addCourseBehavior('courseBehavior', `点击学历案-重新生成所有任务按钮`)">重新生成所有任务</button>
+                  <button class="c_pub_button_confirm3" style="margin: 0 0 0 10px;" @click="allEvaCan(), addCourseBehavior('courseBehavior', `点击学历案-一键生成所有评价按钮`)" v-if="panTaskElist() == 0 && panEvaCont() == 0">一键生成所有评价</button>
+                  <button class="c_pub_button_confirm" style="margin: 0 0 0 10px;" v-if="steps < 4 && istemplate != 1" @click="nextSteps">
                     {{ steps == 3 ? "确认上传" : "下一步" }}
-                  </button>
-                  <button class="c_pub_button_confirm" style="margin: 0 0 0 20px;" @click="openAiDialog2(2, 'aiTask3','all'), addCourseBehavior('courseBehavior', `点击学历案-重新生成所有任务按钮`)">重新生成所有任务</button>
-                  <button class="c_pub_button_confirm" style="margin: 0 0 0 20px;" @click="allEvaCan(), addCourseBehavior('courseBehavior', `点击学历案-一键生成所有评价按钮`)" v-if="panTaskElist() == 0 && panEvaCont() == 0">一键生成所有评价</button>
+                  </button> 
                 </div>
                 <div class="basic_box" ref="unitBox" @scroll="taskScroll">
                   <div v-if="false" style="
@@ -2802,6 +2800,8 @@
                 </div> -->
                     <div class="taskBorder" :style="{
                       minHeight: unitJson[unitIndex].easy && 'unset',
+                      borderRadius: itemTaskIndex == 0 ? '0px 0px 10px 10px' : '10px',
+                      marginTop: itemTaskIndex == 0 ? '0' : '10px',
                     }" :class="{ smallTaskBorder: itemTask.isFold === 1 }"
                       v-for="(itemTask, itemTaskIndex) in item.taskJson" :key="itemTaskIndex" v-loading="taskLoading[itemTaskIndex]" element-loading-text="小可正在努力生成中,请稍等...">
                       <div style="background: #fff; border-radius: 5px" v-loading="taskGLoading[itemTaskIndex] && taskGLoading[itemTaskIndex][0]" element-loading-text="小可正在努力生成中,请稍等...">
@@ -28398,6 +28398,26 @@ ol {
   justify-content: flex-start;
   height: 50px;
   align-items: center;
+  background: #fff;
+  padding: 0 20px;
+  border-radius: 10px 10px 0px 0px;
+  border-bottom: 1px solid #cad1dc;
+}
+
+.rb_c_box_btn > .title{
+  font-size: 24px;
+  font-weight: bold;
+  display: flex;
+  align-items: center;
+}
+
+.rb_c_box_btn > .title:before{
+  content: '';
+  background-image: url(../../../assets/icon/course/courseName.png);
+  width: 24px;
+  height: 24px;
+  background-size: 100% 100%;
+  margin-right: 10px;
 }
 
 .rb_c_box_right>.basic_box {

+ 71 - 7
src/components/pages/aiAddCourse/aiBoxRight.vue

@@ -835,6 +835,8 @@ export default {
       }
     },
     morePrompt(uid, data){
+      this.$emit('addCourseBehavior', 'courseBehavior', '点击对话框-推荐更多按钮')
+
       if(this.array.find(i => i.uid == uid).moreloading){
         this.$message.error('生成中请稍后')
         return
@@ -919,6 +921,11 @@ Instruction: Based on the context, follow "Format example", write content.`
 
     },
     quickAdd(data, pr){
+      if(this.faloading){
+        this.$message.error('请等待回答完毕在发送')
+        return
+      }
+      this.$emit('addCourseBehavior', 'courseBehavior', '点击对话框-推荐按钮发送')
       this.faloading = true;
       let string = `## 参考资料
 ${data.area + ':' + data.value}
@@ -950,7 +957,7 @@ ${data.area + ':' + data.value}
         this.$refs.chatDialog.scrollTop = this.$refs.chatDialog.scrollHeight;
       });
       let params = {
-        assistant_id: 'b19f1a1a-7586-11ef-8ce0-12e77c4cb76b',
+        id: 'adfdb66c-9108-11ef-a04e-12e77c4cb76b',
         userId: this.userid,
         message: _replaceText,
         session_name: this.continuous ? `${this.courseId}-addCourseA` : uuidv4(),
@@ -961,7 +968,7 @@ ${data.area + ':' + data.value}
       };
 
       this.ajax
-        .post("https://gpt4.cocorobo.cn/ai_agent_park_chat_new", params)
+        .post("https://llm.cocorobo.cn/agent/ai_agent_chat_new", params)
         .then(res => {
           if (
             converter(res.data.FunctionResponse.result) ==
@@ -974,13 +981,17 @@ ${data.area + ':' + data.value}
         .catch(err => {
           console.log(err);
         });
-      this.getAtAuContent(_uuid);
+      this.getAtAuContent2(_uuid);
       this.saveUid = _uuid;
       this.courseText = "";
     },
     addContent() {
       if (this.courseText.trim().length == 0)
         return this.$message.error("请输入内容");
+      if(this.faloading){
+        this.$message.error('请等待回答完毕在发送')
+        return
+      }
       let message = this.courseText;
       this.$emit('addCourseBehavior', 'courseBehavior', '点击对话框-发送按钮')
 
@@ -1107,7 +1118,7 @@ ${message}`;
               session_name: `${this.courseId}-addCourseA`,
               uid: _uid,
               file_ids: [...this.fileids],
-              // model: "gpt-4o-mini"
+              model: "gpt-4o-mini"
               // model: "qwen-plus"
             };
 
@@ -1187,7 +1198,7 @@ ${message}`;
             this.$refs.chatDialog.scrollTop = this.$refs.chatDialog.scrollHeight;
           });
           let params = {
-            assistant_id: 'b19f1a1a-7586-11ef-8ce0-12e77c4cb76b',
+            id: 'adfdb66c-9108-11ef-a04e-12e77c4cb76b',
             userId: this.userid,
             message: _replaceText,
             session_name: this.continuous ? `${this.courseId}-addCourseA` : uuidv4(),
@@ -1198,7 +1209,7 @@ ${message}`;
           };
 
           this.ajax
-            .post("https://gpt4.cocorobo.cn/ai_agent_park_chat_new", params)
+            .post("https://llm.cocorobo.cn/agent/ai_agent_chat_new", params)
             .then(res => {
               if (
                 converter(res.data.FunctionResponse.result) ==
@@ -1211,7 +1222,7 @@ ${message}`;
             .catch(err => {
               console.log(err);
             });
-          this.getAtAuContent(_uuid);
+          this.getAtAuContent2(_uuid);
           this.saveUid = _uuid;
           this.courseText = "";
           // let params = JSON.stringify({
@@ -1349,6 +1360,58 @@ ${message}`;
         }
       };
     },
+    getAtAuContent2(_uid) {
+      this.fasource = new EventSource(
+        `https://llm.cocorobo.cn/question/${_uid}`
+      ); //http://gpt4.cocorobo.cn:8011/question/   https://gpt4.cocorobo.cn/question/
+      let _allText = "";
+      let _mdText = "";
+      const md = new MarkdownIt();
+      this.fasource.onmessage = _e => {
+        let _eData = JSON.parse(_e.data);
+        if (_eData.content.replace("'", "").replace("'", "") == "[DONE]") {
+          let _result = [];
+          if ("result" in _eData) {
+            _result = _eData.result;
+            for (let i = 0; i < _result.length; i++) {
+              _mdText = _mdText.replace(_result[i].text, _result[i].fileName);
+            }
+          }
+          _mdText = _mdText.replace("_", "");
+          this.array.find(i => i.uid == _uid).aiContent = _mdText;
+          this.array.find(i => i.uid == _uid).isalltext = true;
+          this.array.find(i => i.uid == _uid).isShowSynchronization = true;
+          this.array.find(i => i.uid == _uid).loading = false;
+          this.$nextTick(() => {
+            this.$refs.chatDialog.scrollTop = this.$refs.chatDialog.scrollHeight;
+          });
+          this.fasource.close();
+          this.fasource = null;
+          if (this.courseId) {
+            this.insertChat(_uid);
+          }
+        } else {
+          let _text = _eData.content.replace("'", "").replace("'", "");
+          if (_allText == "") {
+            _allText = _text.replace(/^\n+/, ""); //去掉回复消息中偶尔开头就存在的连续换行符
+          } else {
+            _allText += _text;
+          }
+          _mdText = _allText + "_";
+          _mdText = _mdText.replace(/\\n/g, "\n");
+          _mdText = _mdText.replace(/\\/g, "");
+          if (_allText.split("```").length % 2 == 0) _mdText += "\n```\n";
+          //转化返回的回复流数据
+          _mdText = md.render(_mdText);
+          this.array.find(i => i.uid == _uid).aiContent = _mdText;
+          this.array.find(i => i.uid == _uid).loading = false;
+          this.$nextTick(() => {
+            this.$refs.chatDialog.scrollTop = this.$refs.chatDialog.scrollHeight;
+          });
+          // 处理流数据
+        }
+      };
+    },
     async getUserName() {
       let params = { uid: this.userid };
       try {
@@ -1617,6 +1680,7 @@ ${message}`;
       this.showRoleList = false;
     },
     onCopy(content) {
+      this.$emit('addCourseBehavior', 'courseBehavior', '点击对话框-复制信息')
       const turndownService = new TurndownService();
       // 添加自定义规则来处理表格
       turndownService.addRule("table", {

برخی فایل ها در این مقایسه diff نمایش داده نمی شوند زیرا تعداد فایل ها بسیار زیاد است