Skip to content

Commit

Permalink
feat: 添加工蜂智能研发工具指引文档 (#1458)
Browse files Browse the repository at this point in the history
  • Loading branch information
leafage-collb authored Jul 8, 2024
1 parent 5be426b commit a12645b
Show file tree
Hide file tree
Showing 9 changed files with 84 additions and 2 deletions.
3 changes: 3 additions & 0 deletions webfe/package_vue/.bk.production.env
Original file line number Diff line number Diff line change
Expand Up @@ -25,3 +25,6 @@ BK_PAAS_BUILD_VERSION = '\$BKPAAS_BUILD_VERSION'
BK_MAX_PACKAGE_SIZE = '\$BK_MAX_PACKAGE_SIZE'

BK_SHARED_RES_URL = '\$BK_SHARED_RES_URL'

BK_TCGIT_COPILOT_URL = '\$BK_TCGIT_COPILOT_URL'

1 change: 1 addition & 0 deletions webfe/package_vue/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
var BK_STATIC_URL = '<%= process.env.BK_STATIC_URL %>' || ''
var BK_PAAS_VERSION = '<%= process.env.BK_PAAS_VERSION %>' || ''
var BK_SHARED_RES_URL = '<%= process.env.BK_SHARED_RES_URL %>' || ''
var BK_TCGIT_COPILOT_URL = '<%= process.env.BK_TCGIT_COPILOT_URL %>' || ''
var GLOBAL_CONFIG = {
APP_VERSION: '<%= process.env.BK_APP_VERSION %>',
LOGIN_SERVICE_URL: '<%= process.env.BK_LOGIN_URL %>',
Expand Down
7 changes: 7 additions & 0 deletions webfe/package_vue/src/language/lang/en.js
Original file line number Diff line number Diff line change
Expand Up @@ -2682,4 +2682,11 @@ export default {
指定端口可访问: 'Specified Port Accessible',
'探测容器是否正常,不正常则会重启容器,在容器生命周期中,该探针会按照设定频率持续运行': 'Checks if the container is functioning properly; if not, the container will be restarted. This probe will continue to run at the set frequency throughout the containers lifecycle.',
'探测容器是否就绪,若未就绪则不会转发流量到该实例,在容器就绪之前该探针会按照设定频率持续运行': 'Checks if the container is ready; if not, traffic will not be forwarded to the instance. This probe will continue to run at the set frequency until the container is ready.',
体验: 'Experience ',
'工蜂 Copilot': 'TcGit Copilot',
代码补全与生成目前支持语言: 'Languages Currently Supported for Code Completion and Generation',
'工蜂 Copilot 是由工蜂智能化团队推出的一款 AI 代码助手工具。采用腾讯混元代码领域大模型,同时结合开源模型、以及工蜂领域数据进行业务精调。': 'TcGit Copilot is an AI code assistant tool launched by the TcGit Intelligence team. It uses Tencent Hunyuans large model for the code domain, combined with open-source models and TcGits domain data for business fine-tuning.',
'目前支持 IDE': 'Currently Supported IDEs',
'Python, JavaScript/TypeScript, Java, C/C++, Go, C#, Lua, Kotlin, TSX/JSX, Vue, Proto, PHP 等 100+ 语言/框架': 'Python, JavaScript/TypeScript, Java, C/C++, Go, C#, Lua, Kotlin, TSX/JSX, Vue, Proto, PHP, and over 100 other languages/frameworks',
'Visual Studio Code, Jetbrains IDEs(GoLand, Pycharm, IDEA, WebStorm, Rider, Android Studio, 鸿蒙 IDE 等), Visual Studio, Vim / NeoVim': 'Visual Studio Code, Jetbrains IDEs (GoLand, Pycharm, IDEA, WebStorm, Rider, Android Studio, Hongmeng IDE, etc.), Visual Studio, Vim / NeoVim',
};
7 changes: 7 additions & 0 deletions webfe/package_vue/src/language/lang/zh.js
Original file line number Diff line number Diff line change
Expand Up @@ -2821,4 +2821,11 @@ export default {
指定端口可访问: '指定端口可访问',
'探测容器是否正常,不正常则会重启容器,在容器生命周期中,该探针会按照设定频率持续运行': '探测容器是否正常,不正常则会重启容器,在容器生命周期中,该探针会按照设定频率持续运行',
'探测容器是否就绪,若未就绪则不会转发流量到该实例,在容器就绪之前该探针会按照设定频率持续运行': '探测容器是否就绪,若未就绪则不会转发流量到该实例,在容器就绪之前该探针会按照设定频率持续运行',
体验: '体验',
'工蜂 Copilot': '工蜂 Copilot',
代码补全与生成目前支持语言: '代码补全与生成目前支持语言',
'工蜂 Copilot 是由工蜂智能化团队推出的一款 AI 代码助手工具。采用腾讯混元代码领域大模型,同时结合开源模型、以及工蜂领域数据进行业务精调。': '工蜂 Copilot 是由工蜂智能化团队推出的一款 AI 代码助手工具。采用腾讯混元代码领域大模型,同时结合开源模型、以及工蜂领域数据进行业务精调。',
'目前支持 IDE': '目前支持 IDE',
'Python, JavaScript/TypeScript, Java, C/C++, Go, C#, Lua, Kotlin, TSX/JSX, Vue, Proto, PHP 等 100+ 语言/框架': 'Python, JavaScript/TypeScript, Java, C/C++, Go, C#, Lua, Kotlin, TSX/JSX, Vue, Proto, PHP 等 100+ 语言/框架',
'Visual Studio Code, Jetbrains IDEs(GoLand, Pycharm, IDEA, WebStorm, Rider, Android Studio, 鸿蒙 IDE 等), Visual Studio, Vim / NeoVim': 'Visual Studio Code, Jetbrains IDEs(GoLand, Pycharm, IDEA, WebStorm, Rider, Android Studio, 鸿蒙 IDE 等), Visual Studio, Vim / NeoVim',
};
9 changes: 9 additions & 0 deletions webfe/package_vue/src/router/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -294,6 +294,10 @@ const srvStaticLesscode = () => import(/* webpackChunkName: 'services-info' */'@
window.showDeployTip(error);
});

const serviceCopilot = () => import(/* webpackChunkName: 'services-info' */'@/views/services/static/copilot').then(module => module).catch((error) => {
window.showDeployTip(error);
});

const srvStaticSDKBlueapps = () => import(/* webpackChunkName: 'services-info' */'@/views/services/static/sdk-blueapps').then(module => module).catch((error) => {
window.showDeployTip(error);
});
Expand Down Expand Up @@ -982,6 +986,11 @@ const router = new Router({
component: srvStaticLesscode,
name: 'serviceLesscode',
},
{
path: 'copilot',
component: serviceCopilot,
name: 'serviceCopilot',
},
{
path: 'framework',
component: srvStaticSDKBlueapps,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,14 @@
<bk-form :model="sourceCodeData">
<bk-form-item :label="`${$t('代码源')}:`">
<span class="form-text">{{curAppModule.repo?.display_name || '--'}}</span>
<a
v-if="sourceControlType === 'tc_git'"
:href="tcgitCopilotUrl"
target="_blank"
class="copilot-link">
{{`${$t('体验')}${$t('工蜂 Copilot')}`}}
<i class="paasng-icon paasng-jump-link"></i>
</a>
</bk-form-item>
<bk-form-item :label="`${$t('代码仓库')}:`">
<a
Expand Down Expand Up @@ -336,6 +344,9 @@ export default {
isShowEdit() {
return !this.isCodeSourceEdit ? this.isEmptyData : false;
},
tcgitCopilotUrl() {
return window.BK_TCGIT_COPILOT_URL;
},
},
created() {
Expand Down Expand Up @@ -766,8 +777,16 @@ export default {
display: flex;
}
.code-detail .code-link {
color: #3A84FF;
.code-detail {
.code-link {
color: #3A84FF;
}
.copilot-link {
margin-left: 10px;
i {
font-size: 16px;
}
}
}
.form-group-dir {
Expand Down
34 changes: 34 additions & 0 deletions webfe/package_vue/src/views/services/static/copilot.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
<template lang="html">
<service-general :data="apiData" />
</template>

<script>
import serviceGeneral from '@/components/serviceGeneral';
export default {
components: {
serviceGeneral,
},
data() {
return {
apiData: {
name: this.$t('工蜂 Copilot'),
hasLink: true,
link: window.BK_TCGIT_COPILOT_URL,
apititle: this.$t('工蜂 Copilot'),
image: '/static/images/tc_git.png',
apiexplain: this.$t('工蜂 Copilot 是由工蜂智能化团队推出的一款 AI 代码助手工具。采用腾讯混元代码领域大模型,同时结合开源模型、以及工蜂领域数据进行业务精调。'),
apiList: [
{
title: this.$t('代码补全与生成目前支持语言'),
explain: this.$t('Python, JavaScript/TypeScript, Java, C/C++, Go, C#, Lua, Kotlin, TSX/JSX, Vue, Proto, PHP 等 100+ 语言/框架'),
},
{
title: this.$t('目前支持 IDE'),
explain: this.$t('Visual Studio Code, Jetbrains IDEs(GoLand, Pycharm, IDEA, WebStorm, Rider, Android Studio, 鸿蒙 IDE 等), Visual Studio, Vim / NeoVim'),
},
],
},
};
},
};
</script>
1 change: 1 addition & 0 deletions webfe/package_vue/static/runtime/runtime.ce.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ var BK_ANALYSIS_JS = process.env.BK_ANALYSIS_JS || '' //上报js 内部版需要
var BK_PAAS_VERSION = process.env.BK_PAAS_VERSION || ''
var BK_MAX_PACKAGE_SIZE = process.env.BK_MAX_PACKAGE_SIZE || ''
var BK_SHARED_RES_URL = process.env.BK_SHARED_RES_URL || ''
var BK_TCGIT_COPILOT_URL = process.env.BK_TCGIT_COPILOT_URL || ''

var BACKEND_URL = `${SITE_URL}/backend` // 后端接口前缀
var DOCS_URL_PREFIX = `${BK_DOCS_URL_PREFIX}/markdown/PaaS/DevelopTools/BaseGuide`
Expand Down
1 change: 1 addition & 0 deletions webfe/package_vue/static/runtime/runtime.ee.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ var BK_ANALYSIS_JS = process.env.BK_ANALYSIS_JS || '' //上报js 内部版需要
var BK_PAAS_VERSION = process.env.BK_PAAS_VERSION || ''
var BK_MAX_PACKAGE_SIZE = process.env.BK_MAX_PACKAGE_SIZE || ''
var BK_SHARED_RES_URL = process.env.BK_SHARED_RES_URL || ''
var BK_TCGIT_COPILOT_URL = process.env.BK_TCGIT_COPILOT_URL || ''

var BACKEND_URL = `${SITE_URL}/backend` // 后端接口前缀
var DOCS_URL_PREFIX = `${BK_DOCS_URL_PREFIX}/markdown/PaaS/DevelopTools/BaseGuide`
Expand Down

0 comments on commit a12645b

Please sign in to comment.