index.html 4.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778
  1. <!DOCTYPE HTML>
  2. <html lang="zh-CN">
  3. <head>
  4. <title>AI,请帮帮忙</title>
  5. <meta charset="UTF-8">
  6. <link rel="shortcut icon" href="../static/img/favicon.ico">
  7. <link rel="stylesheet" href="index.css"/>
  8. <script type="text/javascript" src="../static/vendor/evalCore.min.js"></script>
  9. <script type="text/javascript" src="../static/vendor/vue/vue.js"></script>
  10. </head>
  11. <body>
  12. <div class="wrapper" id="pageContainer">
  13. <div class="panel panel-default" style="margin-bottom: 0px;">
  14. <div class="panel-heading">
  15. <h3 class="panel-title">
  16. <a href="https://www.baidufe.com/fehelper/index/index.html" target="_blank" class="x-a-high">
  17. <img src="../static/img/fe-16.png" alt="fehelper"/> FeHelper:</a>AI,请帮帮忙
  18. </h3>
  19. </div>
  20. </div>
  21. <div class="panel-body">
  22. <div class="row mod-inputs box-prompt">
  23. <form class="ui-mt-10" @submit.prevent="goChat">
  24. <textarea type="text" id="prompt" ref="prompt" v-model="prompt" class="form-control" placeholder="你有什么内容想要咨询AI的?"
  25. data-key="c2stNEJUbWRxYW00eENTUXJXRnlNajFUM0JsYmtGSlVlbDJnZ2dGbjI5MVBKQVdzZnZR"></textarea>
  26. <input class="btn btn-sm btn-primary btn-chat" type="button" value="发送" @click="goChat">
  27. </form>
  28. </div>
  29. <div class="row mod-inputs box-result" ref="boxResult">
  30. <div class="row box-tips" v-if="!hideDemo">
  31. <div>你好,我是你的专属AI助理,不管你是要查BUG、写代码、还是要咨询什么技术问题,你都可以跟我说,我会竭尽全力帮你解决,比如你可以这样问我👇👇👇</div>
  32. <ul class="x-demos clearfix">
  33. <li v-for="demo in demos" @click="sendMessage(demo)">{{demo}}</li>
  34. </ul>
  35. </div>
  36. <div class="row box-message">
  37. <table>
  38. <template v-for="msg in history">
  39. <tr class="x-from-fh">
  40. <td class="td-icon x-me"><img src="../static/img/me.png" alt="me"/></td>
  41. <td class="td-content"><b class="x-time">{{msg.sendTime}} </b><div class="x-xcontent">{{msg.message}}</div></td>
  42. </tr>
  43. <tr class="x-back-gpt">
  44. <td class="td-icon">
  45. <img src="../static/img/fe-16.png" alt="fehelper"/></td></td>
  46. <td class="td-content"><b class="x-time">{{msg.respTime}}</b>
  47. <div :id="msg.id" class="x-xcontent" v-html="msg.respContent"></div>
  48. </td>
  49. </tr>
  50. </template>
  51. <template v-if="respResult.id">
  52. <tr class="x-from-fh">
  53. <td class="td-icon x-me"><img src="../static/img/me.png" alt="me"/></td>
  54. <td class="td-content"><b class="x-time">{{respResult.sendTime}} </b><div class="x-xcontent">{{respResult.message}}</div></td>
  55. </tr>
  56. <tr class="x-back-gpt">
  57. <td class="td-icon">
  58. <img src="../static/img/fe-16.png" alt="fehelper"/></td>
  59. <td class="td-content"><b class="x-time">{{respResult.respTime}}</b>
  60. <div :id="respResult.id" class="x-xcontent" v-html="respResult.respContent"></div>
  61. </td>
  62. </tr>
  63. </template>
  64. </table>
  65. </div>
  66. </div>
  67. </div>
  68. </div>
  69. <script type="text/javascript" src="../static/vendor/highlight/highlight.js"></script>
  70. <script type="text/javascript" src="../html2markdown/libs/marked.js"></script>
  71. <script type="text/javascript" src="../html2markdown/libs/rawdeflate.js"></script>
  72. <script type="text/javascript" src="../html2markdown/libs/rawinflate.js"></script>
  73. <script type="text/javascript" src="../static/js/utils.js"></script>
  74. <script type="module" src="index.js"></script>
  75. </body>
  76. </html>